Skip to content
Niu DocsNiu 牛元文档
Dashboard控制台

Page Provider settlement history

Generated from the checked-in source. Do not edit this reference by hand.

GET /api/v1/providers/{provider}/settlements

Platform administration or active membership of this Provider required. Lists immutable records of externally confirmed payments; does not initiate payment or claim a bank balance. Ordered by created_at then id descending, with 1–100 rows per page. All amounts are exact currency nanounit strings. No customer, workspace, request, attempt, credential, or procurement detail is included. Time range is from_ms-inclusive and to_ms-exclusive (Unix milliseconds). Keep filters fixed while following next_cursor; a cursor outside this Provider or the filters returns 409. Inserts newer than the cursor do not shift later pages; pages do not constitute a frozen multi-request snapshot. All responses are no-store. Existing POST recording semantics are unchanged.

Operation: listProviderSettlements.

Use the credential and permission scope described above. Each object below is an alternative; schemes within one object are required together.

JSON
[
{
"bearerAuth": []
}
]

Set NIU_ORIGIN to your installation origin (without /v1). Replace path, query and header placeholders with the required values. Query examples use curl 7.87 or newer to encode values with --url-query. Use the credential scope described above; a bearer token must have the authority required by this operation.

Shell
curl --fail-with-body -X GET "$NIU_ORIGIN/api/v1/providers/{provider}/settlements" \
-H "Authorization: Bearer $NIU_BEARER_TOKEN"

Location: path. Required.

JSON
{
"type": "string",
"format": "uuid"
}

Location: path. Required.

JSON
{
"type": "string",
"format": "uuid"
}

Location: query. Optional. Prior next_cursor; omit for the first page.

JSON
{
"type": "string",
"format": "uuid"
}

Location: query. Optional. Filter one currency without conversion.

JSON
{
"type": "string",
"pattern": "^[A-Z]{3}$"
}

Location: query. Optional. Inclusive payment-record creation time. Unix milliseconds.

JSON
{
"type": "integer",
"format": "int64",
"minimum": 0,
"maximum": 253402300799999
}

Location: query. Optional. Exclusive payment-record creation time; must follow from. Unix milliseconds.

JSON
{
"type": "integer",
"format": "int64",
"minimum": 0,
"maximum": 253402300799999
}

Location: query. Optional. Maximum page size.

JSON
{
"type": "integer",
"minimum": 1,
"maximum": 100,
"default": 50
}

No request body is declared.

Settlement page; null next_cursor means the end.

Content type: application/json.

JSON
{
"type": "object",
"required": [
"data",
"next_cursor"
],
"additionalProperties": false,
"properties": {
"data": {
"type": "array",
"items": {
"type": "object",
"required": [
"id",
"currency",
"amount_nanos",
"payment_reference",
"created_at"
],
"additionalProperties": false,
"properties": {
"id": {
"type": "string",
"format": "uuid"
},
"currency": {
"type": "string",
"pattern": "^[A-Z]{3}$"
},
"amount_nanos": {
"type": "string",
"pattern": "^[0-9]+$"
},
"payment_reference": {
"type": "string"
},
"created_at": {
"type": "string",
"format": "date-time"
}
}
}
},
"next_cursor": {
"type": [
"string",
"null"
],
"format": "uuid"
}
}
}

Invalid filters, range or page size.

Invalid credential.

Unsupported administrative authority.

Provider not found or membership unavailable.

Cursor not in this Provider and filter scope.

Storage unavailable.

Platform administration or active membership of this Provider required. Lists immutable records of externally confirmed payments; does not initiate payment or claim a bank balance. Ordered by created_at then id descending, with 1–100 rows per page. All amounts are exact currency nanounit strings. No customer, workspace, request, attempt, credential, or procurement detail is included. Time range is from_ms-inclusive and to_ms-exclusive (Unix milliseconds). Keep filters fixed while following next_cursor; a cursor outside this Provider or the filters returns 409. Inserts newer than the cursor do not shift later pages; pages do not constitute a frozen multi-request snapshot. All responses are no-store. Existing POST recording semantics are unchanged.

Supported scope: implemented