Reports

A report is a collection of data built via the ItemPath application. This collection of data is available through the API.

Attributes

  • id integer

    Unique identifier for the object.

  • name string

    A non-unique name given to the object.

  • baseTable string

    The base table of the report.

  • reportTypeId string

    Either 1 (Table) or 2 (Timeline).

  • sortDescending boolean

    The report's sort direction, if set to "descending".

  • columns array

    Details about the columns in the report.

  • filters array

    Details about what variables the report is filtering by.

  • snapshots array

    Details about snapshots set up to measure report data.

Endpoints

List Reports

get /api/reports

Get the list of reports created from the ItemPath application, and return a response.

Arguments

  • name string

    A non-unique name given to the object.

  • reportTypeId integer

    Either 1 (Table) or 2 (Timeline).

  • baseTable string

    The base table of the report.

  • limit integer

    A limit on the number of objects to be returned. Limit can range between 1 and 1000, and the default is 250.

  • offset integer

    Will return items, but only those after the integer amount.

Request with curl
curl "http://[Your IP] /api/reports" \ -X get \ -H "Content-Type: application/json" \ -H "Authorization: Bearer [Your JWT Access Token]"
Example Response
{
    "reports": [
        {
            "sortDirection": null,
            "sortDescending": "False",
            "sortColumnId": null,
            "id": 105,
            "name": "Count Transactions",
            "groupColumnId": null,
            "baseTable": "History",
            "columns": [
                {
                    "originalName": "Creation Date",
                    "id": 730,
                    "tableColumn": "creationDate",
                    "name": "Creation Date",
                    "position": "0",
                    "filterType": "DateTime",
                    "reportColumnTypeId": "11",
                    "sortingMethod": "",
                    "table": "History",
                    "baseTable": "History"
                }
            ],
            "userId": null,
            "reportTypeId": 1,
            "snapshots": [
                {
                    "sortDirection": null,
                    "type": "count",
                    "id": 56,
                    "name": "Counts Today",
                    "reportId": 105,
                    "groupColumnId": null,
                    "limit": null,
                    "userId": null,
                    "trigger": {
                        "triggerFrequency": "hour",
                        "triggerType": null,
                        "id": 66,
                        "snapshotId": 56,
                        "triggerTime": null,
                        "nextTrigger": "2022-06-15T19:00:00",
                        "lastTriggered": "2022-06-15T18:00:11",
                        "triggerNumber": null,
                        "triggerInterval": "1",
                        "workflowId": null
                    },
                    "reportColumnId": null,
                    "subGroupColumnId": null
                }
            ],
            "defaultSnapshotId": null,
            "table": "History",
            "filters": [
                {
                    "value": "6",
                    "dateRange": null,
                    "id": 169,
                    "reportId": 105,
                    "reportColumnId": 732,
                    "verb": "equals"
                },
                {
                    "value": "5,6",
                    "dateRange": null,
                    "id": 170,
                    "reportId": 105,
                    "reportColumnId": 737,
                    "verb": "not"
                }
            ]
        }
    ]
}

Show Report

get /api/reports/[id]

Get a specific report from ItemPath by its ID and return a JSON response.

Arguments

Request with curl
curl "http://[Your IP] /api/reports/[id]" \ -X get \ -H "Content-Type: application/json" \ -H "Authorization: Bearer [Your JWT Access Token]"
Example Response
{
    "reports": [
        {
            "sortDirection": null,
            "sortDescending": "False",
            "sortColumnId": null,
            "id": 105,
            "name": "Count Transactions",
            "groupColumnId": null,
            "baseTable": "History",
            "columns": [
                {
                    "originalName": "Creation Date",
                    "id": 730,
                    "tableColumn": "creationDate",
                    "name": "Creation Date",
                    "position": "0",
                    "filterType": "DateTime",
                    "reportColumnTypeId": "11",
                    "sortingMethod": "",
                    "table": "History",
                    "baseTable": "History"
                }
            ],
            "userId": null,
            "reportTypeId": 1,
            "snapshots": [
                {
                    "sortDirection": null,
                    "type": "count",
                    "id": 56,
                    "name": "Counts Today",
                    "reportId": 105,
                    "groupColumnId": null,
                    "limit": null,
                    "userId": null,
                    "trigger": {
                        "triggerFrequency": "hour",
                        "triggerType": null,
                        "id": 66,
                        "snapshotId": 56,
                        "triggerTime": null,
                        "nextTrigger": "2022-06-15T19:00:00",
                        "lastTriggered": "2022-06-15T18:00:11",
                        "triggerNumber": null,
                        "triggerInterval": "1",
                        "workflowId": null
                    },
                    "reportColumnId": null,
                    "subGroupColumnId": null
                }
            ],
            "defaultSnapshotId": null,
            "table": "History",
            "filters": [
                {
                    "value": "6",
                    "dateRange": null,
                    "id": 169,
                    "reportId": 105,
                    "reportColumnId": 732,
                    "verb": "equals"
                },
                {
                    "value": "5,6",
                    "dateRange": null,
                    "id": 170,
                    "reportId": 105,
                    "reportColumnId": 737,
                    "verb": "not"
                }
            ]
        }
    ]
}

Create Report

post /api/reports

Create a Report.

Arguments

  • name string

    The name of the report.

  • reportTypeId integer

    Either 1 (Table) or 2 (Timeline).

  • baseTable string

    The base table for the report. Options: Batch, Bin, Carrier, Cost Center, Client, History, Job, Job Lines, Kit, Kit Line, Location, Location Content, Location Content Breakdown, Log, Material, Material Family, Order, Order Line, Shelf, Storage Rule, Storage Unit, Task, User, Warehouse, Zone

Request with curl
curl "http://[Your IP] /api/reports" \ -X post \ -H "Content-Type: application/json" \ -H "Authorization: Bearer [Your JWT Access Token]"
Example Response
{ "reports": [{ "id": " integer ", "name": " string ", "baseTable": " string ", "reportTypeId": " string ", "sortDescending": " boolean ", "columns": " array ", "filters": " array ", "snapshots": " array ", }] }] }

Delete Report

get /api/reports/[id]/delete

Delete a specific report from ItemPath Connect and return a JSON response.

Request with curl
curl "http://[Your IP] /api/reports/[id]/delete" \ -X get \ -H "Content-Type: application/json" \ -H "Authorization: Bearer [Your JWT Access Token]"
Example Response
{ "deleted": "true" }