Mono Colombia

List of ledger accounts

Lists all the ledger accounts related to the tenant

Considerations:

  1. This endpoint doesn't return the account balance for every account, so you can use the endpoint to get the balance for a specific account /v1/ledger/account/:id/balances
  2. You couldn't retrieve more than 500 registers in a single request.
GET
/v1/ledger/accounts

Authorization

authorization

AuthorizationBearer <token>

In: header

Query Parameters

page_number?integer

Number of the page

Default1
Range1 <= value
Example1
page_size?integer

Amount of registers that must be listed by page

Default10
Range10 <= value <= 500
Example10
inserted_at?object

Filter accounts based on the range of insertion date and time.

metadata?object

Filter by account's metadata

Example{ "id": 3, "reference": 123 }
nickname?object

Filter by account's name

type?array<string>

Filter by account's type

holder?array<string>

Filter by account holder ID

currency_code?array<string>

Filter by the account's currency code

state?array<string>

Filter by the account's state

Response Body

application/json

application/json

application/json

application/json

application/json

curl -X GET "https://api.cert.monoban.co/v1/ledger/accounts"
{
  "accounts": [
    {
      "currency_code": "COP",
      "holder_id": "acch_5tgliBmzjZ6mpQPRbQjfKj",
      "id": "lacc_5tgliBmzjZ6mpQPRbQjfKj",
      "inserted_at": "2022-01-01T01:00:00Z",
      "metadata": {
        "id": 3,
        "reference": 123
      },
      "name": "Main account",
      "program_id": "pro_5tgliBmzjZ6mpQPRbQjfKj",
      "provider": "mono_ledger",
      "state": "active",
      "state_reason": "temporary",
      "state_reason_detail": "string",
      "type": "subaccount",
      "updated_at": "2022-01-01T01:00:00Z"
    }
  ],
  "pagination": {
    "page_number": 1,
    "page_size": 10,
    "total_items": 100,
    "total_pages": 10
  }
}
{
  "code": "400 Bad Request",
  "errors": [
    {
      "error_code": "validation_error",
      "message": "Generic changeset errors",
      "path": null,
      "url": null
    }
  ],
  "id": "log_7MkWaFqvfosB8fzHhb1Eql",
  "message": "Malformed request"
}
{
  "code": "401 Unauthorized",
  "errors": [
    {
      "error_code": "expired_token",
      "message": "The token is expired, inactive, or doesn't exist.",
      "path": null,
      "url": null
    }
  ],
  "id": "log_7MkWaFqvfosB8fzHhb1Eql",
  "message": "Authorization header is missing or invalid."
}
{
  "code": "403 Forbidden",
  "errors": [
    {
      "error_code": "not_authorized",
      "message": "Not authorized to have access to this resource.",
      "path": null,
      "url": null
    }
  ],
  "id": "log_7MkWaFqvfosB8fzHhb1Eql",
  "message": "Not authorized to have access to this resource"
}
{
  "code": "422 Unprocessable Entity",
  "errors": [
    {
      "error_code": "missing_field",
      "message": "The field is missing on the request body or parameters.",
      "path": "#/path/to/field",
      "url": null
    }
  ],
  "id": "log_7MkWaFqvfosB8fzHhb1Eql",
  "message": "Validation errors"
}