API Reference

Rated transactions

External read API for rated transactions and their rating dimensions.

Rated transactions

Prefix: /api/v1/external/rated-transactions

See Overview for authentication, pagination, and errors.

Read-only access to billing RatedTransaction records (header plus rating dimensions). These rows are produced by rating; this API does not create or edit them.

Picklists (usageType, chargeType) and currency / convCurrency are returned as names / ISO codes, not UUIDs.

Endpoint summary

MethodPath
GET/rated-transactions
GET/rated-transactions/{transactionId}

List rated transactions

GET /api/v1/external/rated-transactions?page=0&size=20&q=evt-10&accountId=11111111-1111-1111-1111-111111111111&fromDate=2026-08-01&toDate=2026-08-31
Authorization: Bearer YOUR_API_TOKEN
QueryDescription
page0-based page index (default 0)
sizePage size (default 20, max 20)
qOptional search on externalTranId
accountIdOptional billing account UUID
fromDateOptional inclusive start of transaction date (YYYY-MM-DD)
toDateOptional inclusive end of transaction date (YYYY-MM-DD)

Either date bound may be omitted. If both are sent, fromDate must be on or before toDate (400 otherwise). List rows are transaction headers only (no dimensions), sorted by transaction date descending. Envelope: Overview.

Response 200

{
  "requestId": "req-1",
  "success": true,
  "status": 200,
  "errors": [],
  "data": {
    "content": [
      {
        "__type__": "RatedTransaction",
        "Id": "88888888-8888-8888-8888-888888888888",
        "ExternalTranId": "evt-1001",
        "AccountId": "11111111-1111-1111-1111-111111111111",
        "ServiceId": "e6cbd28a-f34c-482e-8da5-34e21dbd5eb7",
        "Amount": 2.5
      }
    ],
    "totalElements": 1,
    "size": 20,
    "number": 0
  }
}

Response 400 when the date range is inverted.

{
  "status": 400,
  "error": "Validation Error",
  "message": "fromDate must be on or before toDate",
  "path": "uri=/api/v1/external/rated-transactions"
}

Get rated transaction

GET /api/v1/external/rated-transactions/{transactionId}
Authorization: Bearer YOUR_API_TOKEN

Returns the same PascalCase + __r header row as list (no nested dimensions).

Response 200

{
  "id": "88888888-8888-8888-8888-888888888888",
  "externalTranId": "evt-1001",
  "transactionDate": "2026-08-15",
  "accountId": "11111111-1111-1111-1111-111111111111",
  "accountNumber": "ACC-1001",
  "masterAccountId": "11111111-1111-1111-1111-111111111111",
  "serviceId": "e6cbd28a-f34c-482e-8da5-34e21dbd5eb7",
  "serviceInstanceId": "SI-1",
  "contractId": "3a2f1c5d-9b7e-4c1a-8f36-2d4b6e8a0c11",
  "amount": 2.5,
  "discount": 0.0,
  "taxAmount": 0.0,
  "quantity": 1000,
  "currency": "USD",
  "usageType": "Charge",
  "chargeType": "Usage",
  "billed": false,
  "dimensions": [
    {
      "id": "99999999-9999-9999-9999-999999999999",
      "transactionId": "88888888-8888-8888-8888-888888888888",
      "dimensionId": "2f8b4c16-7d39-4a52-b1e8-6c0f9a3d5e77",
      "dimensionName": "Input_Tokens",
      "volume": 1000,
      "rate": 0.0025,
      "calcAmount": 2.5,
      "currency": "USD",
      "priceMethodType": "QUANTITY",
      "billStartDate": "2026-08-01",
      "billEndDate": "2026-08-31",
      "isProrated": false,
      "itemType": "Usage"
    }
  ]
}

Response 404 when the transaction does not exist.

{
  "status": 404,
  "error": "Not Found",
  "message": "Rated transaction not found",
  "path": "uri=/api/v1/external/rated-transactions/88888888-8888-8888-8888-888888888888"
}