API REST 🚀

Introduction

This documentation aims to describe the way in which the Damepay API can be integrated, starting with authentication and later the operations that can be done by consuming the different End-Points.

1. Authentication 🔑

1.1 API keys

This section describes what API keys are and how to retrieve them.

Damepay authenticates your API requests using your account's API keys. If you don't include your key when you make an API request or use an incorrect or outdated one, Damepay returns an error.

We use two types of API keys in Damepay: secret keys and encryption keys

Secret keys should be kept confidential and should only be stored on your own servers. Your account's secret API key can make any API request to Damepay without restrictions. The secret key is used to authorize all your API calls in Damepay. Encryption key This is primarily required to encrypt your payload where it is needed.

1.2 Getting your API keys

Your API keys are available on your Damepay Dashboard. Follow the steps below to access them:

  • Login to your Damepay dashboard
  • Navigate to settings
  • Select API in the configuration tab

1.3 Authorization

This document will show you how to authorize API calls

With Damepay, you can authorize your API calls by including your secret key in the Authorization header of every request you make.

  • Secret keys should be kept confidential and only stored on your own servers. Your account's secret API key can make any API request to Damepay without restriction. You also need to pass it as a value to the Authorization header on every request you make.

Authorization sample

    {
        "Authorization" : "Bearer DPSECK-rav2jdea1EcWyRDjrIQUImxYf5kuqSrx-61",
        "Content-Type" : "application/json",
        "X-Requested-With" : "XMLHttpRequest"
    }

1.4 Errors in Damepay's response

Damepay API errors can be grouped into three main categories. Validation errors, Damepay errors, and provider errors.

Authorization Errors

Each call to our endpoints must be authorized by passing its secret key as a bearer token in the request header. When this is not the case, we return an unauthorized 401 response:

    {
        "status": "error",
        "message": "Authorization required",
        "data": null
    }

Validation errors

Validation errors are returned when one or more validation rules fail. Examples include failing to pass the required parameters, for example failing to pass the vendor transaction / reference during a re-inquiry call will result in a validation error. Here's a sample below:

    {
        "status": "error",
        "message": "Cardno is required",
        "data": null
    }

2. API consumption 🔧

To make a REST API request, you can use the HTTP methods: GET, POST, PUT, PATCH or DELETE, the URL to the API service, the URI to a resource to query, send data, update or delete, and one or more HTTP request headers.

The URL to consume the Damepay API is:

https://damepay.com/dashboard/api/{end_points}
  • {end_points}: It is the part of the URL that will change depending on the different API end-points that can be consulted.

2.1 Customers

This section describes the different end-points for handling the data of the customers registered in the user's account:

2.1.1 Obtain all the information of the Clients registered in the account

Check the registered information of all the clients belonging to the account

  GET            https://damepay.com/dashboard/api/customers

Headers

    {
        "Authorization" : "Bearer {your_access_token}",
        "Content-Type" : "application/json",
        "X-Requested-With" : "XMLHttpRequest"
    }
  • {your_access_token}: Secret account key.

Example Response

    {
        "status": "OK",
        "code": 200,
        "customers": []
    }

2.1.2 Obtain the information of a Client by id

Find the transaction whose id matches the supplied one:

  GET            https://damepay.com/dashboard/api/customers/details/{id}
  • {id}: ID of the Client to be consulted.

Headers

    {
        "Authorization" : "Bearer {your_access_token}",
        "Content-Type" : "application/json",
        "X-Requested-With" : "XMLHttpRequest"
    }
  • {your_access_token}: Secret account key.

Example Response

    {
        "code": 200,
        "status": "OK",
        "response": {
            "id_customer": 3,
            "name": "Dev Developeee",
            "email": "dev@gmail.com",
            "phone": "584125732391",
            "blacklist": "0",
            "created_at": "2021-10-30T06:57:49.000000Z",
            "updated_at": "2021-10-30T07:12:35.000000Z",
            "deleted_at": null,
            "transactions": [],
            "card_transactions": []
        }
    }

2.1.3 Create a new Customer

Create a new customer on the account.

  POST            https://damepay.com/dashboard/api/customers/create

Validations

  • {name}: required
  • {email}: required | email | registered in damepay
  • {phone}: required

Headers

    {
        "Authorization" : "Bearer {your_access_token}",
        "Content-Type" : "application/json",
        "X-Requested-With" : "XMLHttpRequest"
    }
  • {your_access_token}: Secret account key.

Body

    {
        "name": "{expected_name}",
        "email": "{expected_email}",
        "phone": "{expected_phone}"
    }
  • {expected_name}: Name to assign to the client.
  • {expected_email}: Email belonging to the client, this email must be valid and registered in our damepay platform.
  • {expected_phone}: Telephone to be assigned to the client.

Example Response

    {
        "code": 201,
        "status": "Created",
        "message": "Registered Customer.",
        "response": {
            "id_customer": 3,
            "name": "Dev Developeee",
            "email": "dev@gmail.com",
            "phone": "584125732391",
            "blacklist": false,
            "created_at": "2021-10-30T06:57:49.000000Z",
            "updated_at": "2021-10-30T07:12:35.000000Z",
            "deleted_at": null
        }
    }

2.1.4 Edit Client

The registered data of a client that matches the id supplied will be updated.

  PUT            https://damepay.com/dashboard/api/customers/edit/{id}
  • {id}: Customer ID to update.

Validations

  • {name}: required
  • {email}: required | email | registered in damepay
  • {phone}: required

Headers

    {
        "Authorization" : "Bearer {your_access_token}",
        "Content-Type" : "application/json",
        "X-Requested-With" : "XMLHttpRequest"
    }
  • {your_access_token}: Secret account key.

Body

    {
        "name": "{expected_name}",
        "email": "{expected_email}",
        "phone": "{expected_phone}"
    }
  • {expected_name}: Name to assign to the client.
  • {expected_email}: Email belonging to the client, this email must be valid and registered in our damepay platform.
  • {expected_phone}: Telephone to be assigned to the client.

Example Response

    {
        "code": 201,
        "status": "Updated",
        "message": "Update Customer.",
        "response": {
            "id_customer": 3,
            "name": "Dev Developeee",
            "email": "dev@gmail.com",
            "phone": "584125732391",
            "blacklist": false,
            "created_at": "2021-10-30T06:57:49.000000Z",
            "updated_at": "2021-11-01T02:13:06.000000Z",
            "deleted_at": null
        }
    }

2.2 Balance

This section describes the different end-points for consulting the account balances.

2.2.1 Get all the information about the account balances

Check all available balances in the account.

  GET            https://damepay.com/dashboard/api/balances

Headers

    {
        "Authorization" : "Bearer {your_access_token}",
        "Content-Type" : "application/json",
        "X-Requested-With" : "XMLHttpRequest"
    }
  • {your_access_token}: Secret account key.

Example Response

    {
        "code": 200,
        "status": "OK",
        "response": [
        {
            "ledger": 231.36,
            "avalible": 46.26,
            "total_transfer": 105.1,
            "amount": 5,
            "currency": "USD",
            "type": "Debit",
            "before": 71.26,
            "after": 46.26,
            "details": "Withdraw Crypto to daniel.rl@gmail.comdaniel.rl@gmail.com",
            "transaction_id": 7,
            "created_at": "2021-10-30T07:42:52.000000Z",
            "updated_at": "2021-10-30T07:42:52.000000Z",
            "deleted_at": null
        },
        {
            "ledger": 231.36,
            "avalible": 71.26,
            "total_transfer": 100.1,
            "amount": 20,
            "currency": "USD",
            "type": "Debit",
            "before": 111.26,
            "after": 71.26,
            "details": "Withdraw Bank Account to daniel.rl@gmail.comdaniel.rl@gmail.com",
            "transaction_id": 6,
            "created_at": "2021-10-30T07:39:53.000000Z",
            "updated_at": "2021-10-30T07:39:53.000000Z",
            "deleted_at": null
        }
        ]
    }

2.3 Transactions

This section describes the different end-points referring to all the transactions carried out in the user's account:

2.3.1 Get all transactions

View all account transactions:

  GET            https://damepay.com/dashboard/api/transactions

Headers

    {
        "Authorization" : "Bearer {your_access_token}",
        "Content-Type" : "application/json",
        "X-Requested-With" : "XMLHttpRequest"
    }
  • {your_access_token}: Secret account key.

Example Response

    {
        "code": 200,
        "status": "OK",
        "data": [
        {
            "id_transactions": 1,
            "currency": "USD",
            "amount": 250,
            "status": "successful",
            "transaction_id": "DP-PAY_LINK-DqXZLlmPptWl4p9smnNmPNuw4S1JSH",
            "flw_ref": "FLW-MOCK-35c2cbeac5365996b9e8a38d93608873",
            "app_fee": 18.64,
            "amount_settled": 231.36,
            "description": "Payment from payment links",
            "payment_type": "Credit/Debit Card",
            "device_fingerprint": "def2834f9c3553783c2db205de53e861015754af",
            "ip_address": "127.0.0.1",
            "created_at": "2021-10-29T02:39:19.000000Z",
            "updated_at": "2021-10-29T02:39:19.000000Z",
            "deleted_at": null
        },
        {
            "id_transactions": 2,
            "currency": "USD",
            "amount": 20,
            "status": "successful",
            "transaction_id": "DP-WITHDRAW-dyJNvJStOC8o9wodIS32PoShljOC2V",
            "flw_ref": "N/A",
            "app_fee": 20,
            "amount_settled": 20,
            "description": "Withdraw Bank Account by lenierrivas.rl@gmail.comlenierrivas.rl@gmail.com",
            "payment_type": "Withdraw to Bank Account",
            "device_fingerprint": "ee359d7765abd983b6d2b76f11ecdc1d7315db84",
            "ip_address": "127.0.0.1",
            "created_at": "2021-10-29T02:40:02.000000Z",
            "updated_at": "2021-10-29T02:55:38.000000Z",
            "deleted_at": null
        }
        ]
    }

2.3.2 Get a transaction for id

Find the transaction whose id matches the supplied one:

  GET            https://damepay.com/dashboard/api/transactions/{id}
  • {id}: ID of the transaction to be queried.

Headers

    {
        "Authorization" : "Bearer {your_access_token}",
        "Content-Type" : "application/json",
        "X-Requested-With" : "XMLHttpRequest"
    }
  • {your_access_token}: Secret account key.

Example Response

    {
        "code": 200,
        "status": "OK",
        "response": {
            "currency": "USD",
            "amount": 250,
            "status": "successful",
            "transaction_id": "DP-PAY_LINK-DqXZLlmPptWl4p9smnNmPNuw4S1JSH",
            "flw_ref": "FLW-MOCK-35c2cbeac5365996b9e8a38d93608873",
            "app_fee": 18.64,
            "amount_settled": 231.36,
            "description": "Payment from payment links",
            "account_wallet": null,
            "account_bank": null,
            "crypto": null,
            "device_fingerprint": "def2834f9c3553783c2db205de53e861015754af",
            "ip_address": "127.0.0.1",
            "created_at": "2021-10-29T02:39:19.000000Z",
            "customer": {
                "id_customer": 1,
                "name": "DamePay",
                "email": "Paypay@gmail.com",
                "phone": "584125732391",
                "created_at": "2021-10-28 22:36:45"
            },
            "card": {
                "first_6digits": "553188",
                "last_4digits": "2950",
                "type": "MASTERCARD",
                "country": "NIGERIA NG",
                "expiry": "09/32"
            }
        }
    }

2.4 Transfers and Withdrawals

This section describes the different end-points regarding account transfers and withdrawals:

2.4.1 Get all transfers

See all user transfers:

  GET            https://damepay.com/dashboard/api/transfers

Headers

    {
        "Authorization" : "Bearer {your_access_token}",
        "Content-Type" : "application/json",
        "X-Requested-With" : "XMLHttpRequest"
    }
  • {your_access_token}: Secret account key.

Example Response

    {
        "code": 200,
        "status": "OK",
        "response": [
        {
            "id_transactions": 2,
            "status": "successful",
            "amount_settled": 20,
            "payment_type": "Withdraw to Bank Account",
            "account_wallet": null,
            "account_bank": "4444444444444444",
            "crypto": null,
            "currency": "USD",
            "app_fee": 20,
            "amount": 20,
            "email": "daniel.rl@gmail.com",
            "name": "Daniel Rivas",
            "created_at": "2021-10-29T02:40:02.000000Z",
            "updated_at": "2021-10-29T02:55:37.000000Z",
            "deleted_at": null
        },
        {
            "id_transactions": 3,
            "status": "successful",
            "amount_settled": 60,
            "payment_type": "Withdraw to Crypto",
            "account_wallet": "DPpb457P2WJSBTL18LENY69UH4Xurt8TMZ",
            "account_bank": null,
            "crypto": "BTC",
            "currency": "USD",
            "app_fee": 20,
            "amount": 60,
            "email": "daniel.rl@gmail.com",
            "name": "Daniel Rivas",
            "created_at": "2021-10-29T02:40:09.000000Z",
            "updated_at": "2021-10-29T02:51:18.000000Z",
            "deleted_at": null
        }
        ]
    }

2.4.2 Account to account transfers.

Make transfer between accounts.

  GET            https://damepay.com/dashboard/api/transfers/toAccount

Validations

  • {to_send}: required | numeric
  • {to_receive}: required | email | registered in damepay
  • {name}: required
  • {phone}: required

Headers

    {
        "Authorization" : "Bearer {your_access_token}",
        "Content-Type" : "application/json",
        "X-Requested-With" : "XMLHttpRequest"
    }
  • {your_access_token}: Secret account key.

Body

    {
        "to_send": "{expected_value}",
        "to_receive": "{expected_email}",
        "name": "{expected_name}",
        "phone": "{expected_phone}",
        "note": "{expected_note}"
    }
  • {expected_value}: Amount to send.
  • {expected_email}: Amount to send.
  • {expected_name}: Customer name.
  • {expected_phone}: Customer phone.
  • {expected_note}: Note of the transaction.

Example Response

    {
        "code": 201,
        "status": "Created",
        "message": "Transfer successful!",
        "response": {
            "id_transactions": 8,
            "currency": "USD",
            "amount": 0.1,
            "status": "successful",
            "transaction_id": "DP-TRANSFER-5CikTuHiJwRrMA9lMWsWIGyqiba7ps",
            "flw_ref": "N/A",
            "app_fee": 0,
            "amount_settled": 0.1,
            "description": "Transfer to dev@gmail.comdev@gmail.com",
            "payment_type": "Transfer to Account",
            "account_bank": null,
            "account_wallet": null,
            "crypto": null,
            "device_fingerprint": "907a7c355ce6120fdf4baa60a30d45dc7023495c",
            "ip_address": "127.0.0.1",
            "created_at": "2021-11-01T02:19:36.000000Z",
            "updated_at": "2021-11-01T02:19:36.000000Z",
            "deleted_at": null
        }
    }

2.4.3 Withdraw to Bank Account.

Withdraw money from the account to a bank account.

  GET            https://damepay.com/dashboard/api/withdraws/toBank

Validations

  • {to_bank}: required
  • {to_withdraw}: required | numeric
  • {divisa}: required

Headers

    {
        "Authorization" : "Bearer {your_access_token}",
        "Content-Type" : "application/json",
        "X-Requested-With" : "XMLHttpRequest"
    }
  • {your_access_token}: Secret account key.

Body

    {
        "to_bank": "{expected_bank}",
        "to_withdraw": "{expected_withdraw}",
        "divisa": "{expected_divisa}",
        "note": "{expected_note}"
    }
  • {expected_bank}: id from the bank account to which you want to withdraw the money. Consult section of Bank account.
  • {expected_withdraw}: Amount to withdraw.
  • {expected_divisa}: Type of currency expected to be received, currently only 2 are accepted: USD (Dollars) and EUR (Euros).
  • {expected_note}: Note of the transaction.

Example Response

    {
        "code": 201,
        "status": "Created",
        "message": "Withdraw Bank Pending!",
        "response": {
            "id_transactions": 11,
            "currency": "USD",
            "amount": 20,
            "status": "pending",
            "transaction_id": "DP-WITHDRAW-HePRSyDFV4soSnFKMXDGDm9nmVeYnX",
            "flw_ref": "N/A",
            "app_fee": 20,
            "amount_settled": 20,
            "description": "Withdraw Bank Account by lenierrivas.rl@gmail.comlenierrivas.rl@gmail.com",
            "payment_type": "Withdraw to Bank Account",
            "account_bank": "4444444444444444",
            "account_wallet": null,
            "crypto": null,
            "device_fingerprint": "c542b4535b47e60ef103b97c2775b2dd3e7f4cf1",
            "ip_address": "127.0.0.1",
            "created_at": "2021-11-01T02:23:19.000000Z",
            "updated_at": "2021-11-01T02:23:19.000000Z",
            "deleted_at": null
        }
    }

2.4.4 Withdraw Crypto Currency.

Withdraw money from the account to a cryptocurrency wallet.

  GET            https://damepay.com/dashboard/api/withdraws/toCrypto

Validations

  • {to_wallet}: required
  • {to_withdraw}: required | numeric
  • {crypto}: required

Headers

    {
        "Authorization" : "Bearer {your_access_token}",
        "Content-Type" : "application/json",
        "X-Requested-With" : "XMLHttpRequest"
    }
  • {your_access_token}: Secret account key.

Body

    {
        "to_wallet": "{expected_wallet}",
        "to_withdraw": "{expected_withdraw}",
        "crypto": "{expected_crypto}",
        "note": "{expected_note}"
    }
  • {expected_wallet}: Wallet to which you want to withdraw the money.
  • {expected_withdraw}: Amount to withdraw.
  • {expected_crypto}: Type of crypto currency expected to be received, Example BTC, SLP.
  • {expected_note}: Note of the transaction.

Example Response

    {
        "code": 201,
        "status": "Created",
        "message": "Withdraw Bank Pending!",
        "response": {
            "id_transactions": 13,
            "currency": "USD",
            "amount": 5,
            "status": "pending",
            "transaction_id": "DP-WITHDRAW-oMWzyw0EEddE9IXgLfBt56JuuuKRTJ",
            "flw_ref": "N/A",
            "app_fee": 20,
            "amount_settled": 5,
            "description": "Withdraw Crypto to lenierrivas.rl@gmail.comlenierrivas.rl@gmail.com",
            "payment_type": "Withdraw to Crypto",
            "account_bank": null,
            "account_wallet": "1asdasd2sds",
            "crypto": "BTC",
            "device_fingerprint": "2a3784d59713c439f90bb87295ee01bbb3fcb2b9",
            "ip_address": "127.0.0.1",
            "created_at": "2021-11-01T02:24:23.000000Z",
            "updated_at": "2021-11-01T02:24:23.000000Z",
            "deleted_at": null
        }
    }

2.5 Payment Links

This section describes the different end-points for handling payment linkages:

2.5.1Get all the information from the Payment Links

Check the registered information of all payment links.

  GET            https://damepay.com/dashboard/api/paymentLinks

Headers

    {
        "Authorization" : "Bearer {your_access_token}",
        "Content-Type" : "application/json",
        "X-Requested-With" : "XMLHttpRequest"
    }
  • {your_access_token}: Secret account key.

Example Response

    {
        "code": 200,
        "status": "OK",
        "response": [
        {
            "id_payment_link": 1,
            "link_name": "Instalacion y Suscripcion InternetSpeed",
            "type": "Single Charge",
            "amount": 250,
            "currency": "USD",
            "status": "0",
            "custon_url": "0HUwk0UdlIDY0oQ",
            "accep_currency": "[]",
            "redirect": "http://damepaygit/paymentsLink/pay-",
            "inputs": "[]",
            "created_at": "2021-10-29T02:36:26.000000Z",
            "updated_at": "2021-10-29T02:36:26.000000Z",
            "deleted_at": null
        },
        {
            "id_payment_link": 2,
            "link_name": "Sistema de prueba",
            "type": "Single Charge",
            "amount": 150,
            "currency": "USD",
            "status": "0",
            "custon_url": "HpN3jkCvfcPUI1Y",
            "accep_currency": "[\"USD\",\"EUR\"]",
            "redirect": "http://damepaygit/paymentsLink/pay-",
            "inputs": "[\"Phone\",\"Tax\"]",
            "created_at": "2021-10-30T07:55:03.000000Z",
            "updated_at": "2021-10-30T07:56:16.000000Z",
            "deleted_at": null
        }
        ]
    }

2.5.2 Get the information of a Payment Link by id

Find the payment link whose id matches the one supplied:

  GET            https://damepay.com/dashboard/api/paymentLinks/details/{id}
  • {id}: ID of the payment link that you want to consult.

Headers

    {
        "Authorization" : "Bearer {your_access_token}",
        "Content-Type" : "application/json",
        "X-Requested-With" : "XMLHttpRequest"
    }
  • {your_access_token}: Secret account key.

Example Response

    {
        "code": 200,
        "status": "OK",
        "response": {
            "id_payment_link": 1,
            "link_name": "Instalacion y Suscripcion InternetSpeed",
            "type": "Single Charge",
            "amount": 250,
            "currency": "USD",
            "details": "Instalacion y Suscripcion InternetSpeed",
            "status": "active",
            "custon_url": "http://damepaygit/paymentsLink/pay/0HUwk0UdlIDY0oQ",
            "accep_currency": "[]",
            "redirect": "",
            "inputs": "[]",
            "created_at": "2021-10-29T02:36:26.000000Z",
            "updated_at": "2021-10-29T02:36:26.000000Z",
            "deleted_at": null,
            "transactions_link": [
            {
                "id_transactions": 1,
                "currency": "USD",
                "amount": 250,
                "status": "successful",
                "link_transaction_id": "DP-PAY_LINK-DqXZLlmPptWl4p9smnNmPNuw4S1JSH",
                "app_fee": 18.64,
                "amount_settled": 231.36,
                "description": "Payment from payment links",
                "payment_type": "Credit/Debit Card",
                "device_fingerprint": "def2834f9c3553783c2db205de53e861015754af",
                "ip_address": "127.0.0.1",
                "created_at": "2021-10-29T02:36:45.000000Z"
            }
            ]
        }
    }

2.5.3 Create a new Payment Link

Add a new payment link to the account.

  POST            https://damepay.com/dashboard/api/paymentLinks/create

Validations

  • {link_name}: required
  • {amount}: required | numeric
  • {currency}: required | allowed values: USD or EUR
  • {details}: required

Headers

    {
        "Authorization" : "Bearer {your_access_token}",
        "Content-Type" : "application/json",
        "X-Requested-With" : "XMLHttpRequest"
    }
  • {your_access_token}: Secret account key.

Body

    {
        "link_name": "{expected_link_name}",
        "currency": "{expected_currency}",
        "details": "{expected_details}",
        "custon_url": "{expected_custon_url}",
        "accept_currency": "{expected_accept_currency}",
        "redirect": "{expected_redirect}",
        "inputs": "{expected_inputs}",
        "amount": "{expected_amount}"
    }
  • {expected_link_name}: Name of the payment link.
  • {expected_currency}: Type of currency expected to be received, currently only 2 are accepted: USD (Dollars) and EUR (Euros).
  • {expected_details}: Description of payment link.
  • {expected_custon_url}: URL in case you have your own payment view.
  • {expected_accept_currency}: Additional currencies to receive payments, currently only 2 are accepted: USD (Dollars) and EUR (Euros).
  • {expected_redirect}: Webhook to redirect once the payment is made.
  • {expected_inputs}: Extra fields that the client wants to add to the payment links.
  • {expected_amount}: Amount that will be charged to customers who access the payment link.

Example Response

    {
        "code": 201,
        "status": "Created",
        "message": "Registered Payment Links.",
        "response": {
            "id_payment_link": 3,
            "link_name": "Sistema de prueba",
            "type": "Single Charge",
            "amount": 2150,
            "currency": "USD",
            "details": "Prueba de almacenamiento API",
            "status": "active",
            "custon_url": "http://damepaygit/paymentsLink/pay/GSzMlYKalBY5Bm3",
            "accep_currency": [
            "USD",
            "EUR"
            ],
            "redirect": "",
            "inputs": [
            "Phone",
            "Tax"
            ],
            "created_at": "2021-11-01T02:25:59.000000Z",
            "updated_at": "2021-11-01T02:25:59.000000Z",
            "deleted_at": null
        }
    }

2.5.4 Edit payment link

The registered data of a payment link will be updated by id.

  PUT            https://damepay.com/dashboard/api/paymentLinks/edit/{id}
  • {id}: ID of the payment link to update.

Validations

  • {link_name}: required
  • {amount}: required | numeric
  • {currency}: required | allowed values: USD or EUR
  • {details}: required

Headers

    {
        "Authorization" : "Bearer {your_access_token}",
        "Content-Type" : "application/json",
        "X-Requested-With" : "XMLHttpRequest"
    }
  • {your_access_token}: Secret account key.

Body

    {
        "link_name": "{expected_link_name}",
        "currency": "{expected_currency}",
        "details": "{expected_details}",
        "custon_url": "{expected_custon_url}",
        "accept_currency": "{expected_accept_currency}",
        "redirect": "{expected_redirect}",
        "inputs": "{expected_inputs}",
        "amount": "{expected_amount}"
    }
  • {expected_link_name}: Name of the payment link.
  • {expected_currency}: Type of currency expected to be received, currently only 2 are accepted: USD (Dollars) and EUR (Euros).
  • {expected_details}: Description of payment link.
  • {expected_custon_url}: URL in case you have your own payment view.
  • {expected_accept_currency}: Additional currencies to receive payments, currently only 2 are accepted: USD (Dollars) and EUR (Euros).
  • {expected_redirect}: Webhook to redirect once the payment is made.
  • {expected_inputs}: Extra fields that the client wants to add to the payment links.
  • {expected_amount}: Amount that will be charged to customers who access the payment link.

Example Response

    {
        "code": 201,
        "status": "Updated",
        "message": "Update Payment Links.",
        "response": {
            "id_payment_link": 2,
            "link_name": "Sistema de prueba",
            "type": "Single Charge",
            "amount": 150,
            "currency": "USD",
            "details": "Prueba de almacenamiento API",
            "status": "active",
            "custon_url": "http://damepaygit/paymentsLink/pay/2EAcwOZcstrShaH",
            "accep_currency": [
            "USD",
            "EUR"
            ],
            "redirect": "",
            "inputs": [
            "Phone",
            "Tax"
            ],
            "created_at": "2021-10-30T07:55:03.000000Z",
            "updated_at": "2021-11-01T02:26:25.000000Z",
            "deleted_at": null
        }
    }

2.6 Bank Accounts

This section describes the different end-points for handling bank account data:

2.6.1 Get all the information of the bank accounts

Check the registered information of bank accounts

  GET            https://damepay.com/dashboard/api/banks

Headers

    {
        "Authorization" : "Bearer {your_access_token}",
        "Content-Type" : "application/json",
        "X-Requested-With" : "XMLHttpRequest"
    }
  • {your_access_token}: Secret account key.

Example Response

    {
        "code": 200,
        "status": "OK",
        "response": [
        {
            "id_bank_accounts": 1,
            "country": "Australia",
            "currency": "USD",
            "account_number": "4444444444444444",
            "account_address": "Argentina",
            "swift_code": "102010",
            "bank_name": "Banco de Venezuela",
            "primary_bank": false,
            "created_at": "2021-10-29T02:39:47.000000Z",
            "updated_at": "2021-10-31T22:00:30.000000Z",
            "deleted_at": null
        },
        {
            "id_bank_accounts": 2,
            "country": "United States",
            "currency": "USD",
            "account_number": "1111111111111111",
            "account_address": "Los Teques",
            "swift_code": "0102",
            "bank_name": "Provincial",
            "primary_bank": false,
            "created_at": "2021-11-01T00:40:07.000000Z",
            "updated_at": "2021-11-01T00:58:31.000000Z",
            "deleted_at": null
        }
        ]
    }

2.1.2 Obtain the information of a Client by id

Find the bank account whose id matches the one supplied:

  GET            https://damepay.com/dashboard/api/banks/details/{id}
  • {id}: ID of the bank account to be consulted.

Headers

    {
        "Authorization" : "Bearer {your_access_token}",
        "Content-Type" : "application/json",
        "X-Requested-With" : "XMLHttpRequest"
    }
  • {your_access_token}: Secret account key.

Example Response

    {
        "code": 200,
        "status": "OK",
        "response": {
            "id_bank_accounts": 1,
            "country": "Australia",
            "currency": "USD",
            "account_number": "4444444444444444",
            "account_address": "Argentina",
            "bank_name": "Banco de Venezuela",
            "swift_code": "102010",
            "primary_bank": false,
            "created_at": "2021-10-29T02:39:47.000000Z",
            "updated_at": "2021-10-31T22:00:30.000000Z",
            "deleted_at": null,
            "transactions": []
        }
    }

2.1.3 Create a bank account

Add a new bank account.

  POST            https://damepay.com/dashboard/api/banks/create

Validations

  • {country}: required
  • {currency}: required
  • {account_number}: required | unique
  • {bank_name}: required
  • {account_address}: required
  • {swift_code}: required
  • {primary_bank}: required | boolean

Headers

    {
        "Authorization" : "Bearer {your_access_token}",
        "Content-Type" : "application/json",
        "X-Requested-With" : "XMLHttpRequest"
    }
  • {your_access_token}: Secret account key.

Body

    {
        "country": "{expected_country}",
        "currency": "{expected_currency}",
        "account_number": "{expected_account_number}",
        "bank_name": "{expected_bank_name}",
        "account_address": "{expected_account_address}",
        "swift_code": "{expected_swift_code}",
        "primary_bank": "{expected_primary_bank}"
    }
  • {expected_bank_name}: Bank account name.
  • {expected_account_number}: Bank account number.
  • {expected_swift_code}: Swift Code.
  • {expected_currency}: Type of currency expected to be received, currently only 2 are accepted: USD (Dollars) and EUR (Euros).
  • {expected_country}: Country where the bank is located.
  • {expected_account_address}: Exact address of the bank.
  • {expected_primary_bank}: Main account?.

Example Response

    {
        "code": 201,
        "status": "Created",
        "message": "Registered Customer.",
        "response": {
            "country": "VE",
            "currency": "USD",
            "account_number": "9999999999999232",
            "bank_name": "Provincial",
            "account_address": "Los Teques",
            "swift_code": "0102",
            "primary_bank": false,
            "updated_at": "2021-11-01T02:41:09.000000Z",
            "created_at": "2021-11-01T02:41:09.000000Z",
            "id_bank_accounts": 13
        }
    }

2.1.4 Edit Bank Account

The registered data of the bank account that matches the id supplied will be updated.

PUT            https://damepay.com/dashboard/api/banks/edit/{id}
  • {id}: ID of the bank account to update.

Validations

  • {country}: required
  • {currency}: required
  • {account_number}: required | unique
  • {bank_name}: required
  • {account_address}: required
  • {swift_code}: required
  • {primary_bank}: required | boolean

Headers

    {
        "Authorization" : "Bearer {your_access_token}",
        "Content-Type" : "application/json",
        "X-Requested-With" : "XMLHttpRequest"
    }
  • {your_access_token}: Secret account key.

Body

    {
        "country": "{expected_country}",
        "currency": "{expected_currency}",
        "account_number": "{expected_account_number}",
        "bank_name": "{expected_bank_name}",
        "account_address": "{expected_account_address}",
        "swift_code": "{expected_swift_code}",
        "primary_bank": "{expected_primary_bank}"
    }
  • {expected_bank_name}: Bank account name.
  • {expected_account_number}: Bank account number.
  • {expected_swift_code}: Swift Code.
  • {expected_currency}: Type of currency expected to be received, currently only 2 are accepted: USD (Dollars) and EUR (Euros).
  • {expected_country}: Country where the bank is located.
  • {expected_account_address}: Exact address of the bank.
  • {expected_primary_bank}: Main account?.

Example Response

    {
        "code": 201,
        "status": "Updated",
        "message": "Updated Bank Account",
        "response": {
            "id_bank_accounts": 2,
            "country": "VE",
            "currency": "USD",
            "account_number": "1111111111111111",
            "account_address": "Los Teques",
            "bank_name": "Venezuela",
            "swift_code": "0102",
            "primary_bank": false,
            "created_at": "2021-11-01T00:40:07.000000Z",
            "updated_at": "2021-11-01T02:42:26.000000Z",
            "deleted_at": null
        }
    }

2.1.5 Delete Bank Account

The bank account that matches the id supplied will be deleted.

  DELETE            https://damepay.com/dashboard/api/banks/edit/{id}
  • {id}: ID of the bank account to delete.

Headers

    {
        "Authorization" : "Bearer {your_access_token}",
        "Content-Type" : "application/json",
        "X-Requested-With" : "XMLHttpRequest"
    }
  • {your_access_token}: Secret account key.

Example Response

    {
        "code": 201,
        "status": "Deleted",
        "message": "Delete Bank Account"
    }