Deposit

On this page, we’ll dive into the different disbursement endpoints you can use to manage disbursement transactions programmatically. You can disburse both fiat and cryptocurrency.

The disbursement model

The disbursement model is the data structure that represents a disbursement transaction in Rampable. The following attributes are associated with the disbursement model:

Properties

  • Name
    disbursementId
    Type
    string
    Description

    Unique identifier for the disbursement transaction.

  • Name
    recipient
    Type
    object
    Description

    Details of the recipient.

  • Name
    recipient.recipientId
    Type
    string
    Description

    Unique identifier for the recipient.

  • Name
    recipient.email
    Type
    string
    Description

    Email address of the recipient.

  • Name
    recipient.name
    Type
    string
    Description

    Name of the recipient.

  • Name
    recipient.bank
    Type
    object
    Description

    Bank details of the recipient.

  • Name
    recipient.bank.bankName
    Type
    string
    Description

    Name of the bank.

  • Name
    recipient.bank.accountName
    Type
    string
    Description

    Name on the bank account.

  • Name
    recipient.bank.accountNumber
    Type
    string
    Description

    Bank account number.

  • Name
    recipient.bank.bankCode
    Type
    string
    Description

    Code of the bank.

  • Name
    recipient.bank.currency
    Type
    string
    Description

    Currency of the bank account.

  • Name
    recipient.bank.country
    Type
    string
    Description

    Country of the bank.

  • Name
    amount
    Type
    number
    Description

    The amount of the disbursement.

  • Name
    currency
    Type
    string
    Description

    The currency of the disbursement.

  • Name
    feeAmount
    Type
    number
    Description

    The amount of the fee.

  • Name
    feePercentage
    Type
    number
    Description

    The percentage of the fee.

  • Name
    status
    Type
    string
    Description

    The status of the disbursement transaction. This can be either pending, failed or completed.

  • Name
    createdBy
    Type
    string
    Description

    Unique identifier of the user who created the disbursement.

  • Name
    createdAt
    Type
    string
    Description

    Timestamp when the disbursement was created.

  • Name
    updatedAt
    Type
    string
    Description

    Timestamp when the disbursement was last updated.


POST/v1/disbursement/fiat

Disbursement Fiat

This endpoint is used to initiate a fiat disbursement transaction. In order to initiate a disbursement, you must provide the amount, currency, recipient, and paymentMethod.

Required attributes

  • Name
    disburseData
    Type
    array
    Description

    This is an array of disbursement data.

  • Name
    currency
    Type
    string
    Description

    This is the currency of the disbursement.

  • Name
    recipientId
    Type
    string
    Description

    This is the unique identifier of the recipient.

  • Name
    amount
    Type
    number
    Description

    This is the amount of the disbursement.

Request

GET
/v1/deposit/fiat
curl --location \
https://sandbox.rampable.co/v1/disbursement/fiat \
--header 'x-client-secret: ••••••' \
--header 'Content-Type: application/json' \
--header 'Authorization: ••••••' \
--data '{
    "disburseData": [
        {
            "currency" : "IDR",
            "recipientId": "670f8112cd0b0ddab0a03860",
            "amount": 10000
        },
        {
            "currency" : "IDR",
            "recipientId": "670f8112cd0b0ddab0a03860",
            "amount": 200000
        },
        {
            "currency" : "IDR",
            "recipientId": "670f8112cd0b0ddab0a03860",
            "amount": 3000000
        }
    ]
}'

Response

{
  "statusCode": 200,
  "message": "Disbursement created successfully",
  "data": {
      "totalRecipient": 2,
      "disburseData": [
          {
              "disbursementId": "82dc0772-1b4c-4894-8b14-7ebd74ffec58",
              "recipient": {
                  "recipientId": "666b127a8a1656b0d892cf8b",
                  "email": "email@gmail.com",
                  "name": "test recipient",
                  "bank": {
                      "bankName": "BANK DIGITAL BCA",
                      "accountName": "accountName",
                      "accountNumber": "1234567890",
                      "bankCode": "051",
                      "currency": "IDR",
                      "country": "INDONESIA"
                  }
              },
              "currency": "IDR",
              "amount": 12000,
              "status": "pending",
              "feeAmount": 5000,
              "feePercentage": 41.67
          },
          {
              "disbursementId": "182cd82d-c2c8-48fc-a0e1-1742dd28cff6",
              "recipient": {
                  "recipientId": "666b127a8a1656b0d892cf8b",
                  "email": "email@gmail.com",
                  "name": "test recipient",
                  "bank": {
                      "bankName": "BANK NEGARA INDONESIA",
                      "accountName": "accountName",
                      "accountNumber": "0987654321",
                      "bankCode": "009",
                      "currency": "IDR",
                      "country": "INDONESIA"
                  }
              },
              "currency": "IDR",
              "amount": 7800,
              "status": "pending",
              "feeAmount": 5000,
              "feePercentage": 64.1
          }
      ],
      "sumFees": [
          {
              "currency": "IDR",
              "totalAmount": 10000
          }
      ],
      "sumAmount": [
          {
              "currency": "IDR",
              "totalAmount": 19800
          }
      ]
  }
}

HTTP Status 400 Example

Error Response

{
    "statusCode": 400,
    "error": "Not Found",
    "message": "Payment method not found"
}

Was this page helpful?