Get recent billing periods

Prev Next

Retrieves the nine most recent billing periods in reverse chronological order, with the most recent billing period returned first.

Endpoint

{{apiUrl}}/api/billingperiods

Endpoint Parameters

ParameterRequiredDescription
{{apiUrl}}YesC3 Portal API URL.

Request Headers

HeaderValue
AuthorizationBearer <access_token>
Content-Typeapplication/json

Request Body

No request body is required for this endpoint.

Successful Response

A successful request returns a list of billing periods available for reporting, invoicing, and consumption-related operations.

Sample Response

{
  "OperationType": null,
  "Status": "Success",
  "RequestCorrelationID": "73e71bda-50b5-49a0-a70e-a000af402487",
  "ErrorMessage": null,
  "ErrorDetail": null,
  "Data": [
    {
      "ID": 24,
      "StartDate": "2022-05-16T00:00:00",
      "EndDate": "2022-06-15T00:00:00",
      "BillingId": "20220618"
    },
    {
      "ID": 23,
      "StartDate": "2022-04-16T00:00:00",
      "EndDate": "2022-05-15T00:00:00",
      "BillingId": "20220518"
    }
  ]
}

Response Properties

PropertyDescription
OperationTypeReserved for internal use. Can be ignored.
StatusIndicates the result of the request. Possible values: Success, Error.
RequestCorrelationIDUnique identifier generated by C3 for request tracking and troubleshooting.
ErrorMessageContains the error message if request processing fails.
ErrorDetailContains additional error information.
DataCollection of billing period records.

Billing Period Attributes

AttributeDescription
IDUnique identifier of the billing period.
StartDateStart date of the billing period.
EndDateEnd date of the billing period.
BillingIdFriendly representation of the billing period. This value corresponds to the invoice generation date in yyyyMMdd format.
Note

The API returns the nine most recent billing periods in reverse chronological order, with the latest billing period appearing first in the response.

Error Response

The API validates the request and authorization context before processing the request. If the request cannot be processed, an appropriate error response is returned.