Search Documentation

Search API endpoints, webhooks, tools, and guides

On this page6 sections
Is this helpful?
Quick Actions
Download OpenAPI.json
POST/api/reports/product-salesReportsPermission: reports.view

Get Realtime Product Sales Breakdown

Aggregates sold product quantity and revenue filtered by server persistence timestamp (`Invoice.createdAt`), outlet scope, category, and search query.

Authentication: Requires Authorization: Bearer <ACCESS_TOKEN> (Supabase JWT, OAuth2 M2M token, or integration token).

Outlet Scope Enforcement: Results and mutations are automatically scoped to the actor's accessible outlets when the reports module restriction applies.

Request

Provide the following fields in the request payload.

Body application/json
startDatestring (date-time)optional

start Date parameter.

endDatestring (date-time)optional

end Date parameter.

outletIdstring (uuid)optional

outlet Id parameter.

outletstringoptional

outlet parameter.

categorystringoptional

category parameter.

querystringoptional

query parameter.

pageIndexinteger | nulloptionaldefault: 0

page Index parameter.

pageSizeintegeroptionaldefault: 20

page Size parameter.

Responses

Select a status code to inspect schema.

OK — Product sales breakdown retrieved.application/json
successenum('true')

Success (true).

messagestring

Message.

dataobject | null

Response payload or null.

POST/api/reports/product-sales
curl -X POST "https://api.invoger.com/api/reports/product-sales" \
  -H "Authorization: Bearer <ACCESS_TOKEN>" \
  -H "Content-Type: application/json" \
  -d '{ "startDate": "2026-11-01T00:00:00.000Z", "endDate": "2026-11-26T23:59:59.999Z", "category": "Beverages", "pageIndex": 0, "pageSize": 20 }'
Interactive playground

Response

application/json
{
  "success": true,
  "message": "Success",
  "data": {
    "rows": [],
    "total": 0
  }
}