Inventory Pro
Skip to main content

Contents

api

Reports

Reports

The Reports endpoint executes system reports and returns paginated results — the same reports available in the desktop application.

The Report Object

GET /Report returns a flat array of report metadata (not a paginated wrapper):

[
  {
    "reportId": 15,
    "reportName": "Stock Valuation",
    "reportType": "Query",
    "reportTypeId": 1,
    "availableFlags": [
      { "flag": "WID", "description": "Warehouse ID", "required": true }
    ],
    "columns": [
      { "name": "PartNo", "type": "number", "width": 80, "filterable": true, "filterType": "N" }
    ]
  }
]

Fields

FieldTypeDescription
reportIdintegerReport identifier
reportNamestringDisplay name
reportTypestringReport type description
reportTypeIdintegerReport type code
availableFlagsarrayFilter flags the report accepts
columnsarrayColumn metadata for the report

Flag Fields

FieldTypeDescription
flagstringPlaceholder name (e.g. WID, UID)
descriptionstringHuman-readable description
requiredbooleanWhether the flag must be provided

Column Fields

FieldTypeDescription
namestringColumn name
typestringData type: string, number, date, or time
widthintegerDisplay width
filterablebooleanWhether the column supports filtering
filterTypestringFilter type code (S=string, N=number, D=date, T=time)

List Reports

GET /Report

Returns the reports available to your API credentials. Reports that require unsupported flags or cannot be executed via the API are omitted.

Response

[
  {
    "reportId": 15,
    "reportName": "Stock Valuation",
    "reportType": "Query",
    "reportTypeId": 1,
    "availableFlags": [],
    "columns": []
  },
  {
    "reportId": 22,
    "reportName": "Inventory Activity",
    "reportType": "Query",
    "reportTypeId": 1,
    "availableFlags": [],
    "columns": []
  }
]

Execute a Report

GET /Report/{id}

Runs the report and returns paginated results. Maximum page size is 250 (the standard Query cap).

Parameters

FieldTypeRequiredDescription
pageintegerNoPage number (default 1)
pageSizeintegerNoResults per page (max 250)
sortstringNoColumn to sort by
directionstringNoasc or desc
flagsstringNoFilter flags, e.g. !WID!=5;!UID!=1
includeHiddenbooleanNoInclude hidden columns (default false)

Response

Each report returns its own column structure. The value array contains one object per result row. The response extends the standard paged shape with report metadata:

{
  "reportId": 15,
  "reportName": "Stock Valuation",
  "columns": [
    { "name": "PartNo", "type": "number", "width": 80, "filterable": true, "filterType": "N" }
  ],
  "availableFlags": [],
  "sortBy": "PartNo",
  "sortDirection": "asc",
  "value": [
    { "PartNo": 42, "ShortID": "BOLT-M8-30", "Units": 1500.0, "UnitCost": 0.45, "TotalValue": 675.00 }
  ],
  "totalCount": 2340,
  "page": 1,
  "pageSize": 100,
  "pageCount": 24,
  "hasMore": true
}

Column names and types vary per report. Run GET /Report to discover available reports, then query a specific report to inspect its result shape.

Convenience Endpoint

GET /Report/{id}/{count}

Returns the first count rows (clamped to 1–1000) of a report. Accepts the same flags query parameter.

Error Cases

StatusCause
400Invalid sort column, flags, or pagination parameters
404Report not found or not enabled

Permissions

Report access uses a per-report rights string separate from endpoint security. The list endpoint only returns reports your credentials can access.