OhentPay
API Reference

Transactions

Transactions operations

Fetch transactions list

GET
/transactions
AuthorizationBearer <token>

In: header

Query Parameters

order_id?string

Fetch by order_id

recipient_id?string

Filter by Recipient ID

recipient_country?string

Filter by Recipient country

balance_id?string

Filter by balance_id

Formatuuid
virtual_account_id?string

Filter by Virtual account ID

scheduled_payment_id?string

Filter by Scheduled payment ID

transaction_type?string

Filter by transaction type

currency?string

Filter by currency code

to_currency?string

Filter by To currency code

status?string

Filter by status

from_datetime?string

Filter by start datetime - ISO8601

Formatdatetime
to_datetime?string

Filter by end datetime - ISO8601

Formatdatetime
search?string

Filter by search. We search the reference, payer name, recipient account_name etc.

Response Body

curl -X GET "https://api.ohentpay.com/transactions?order_id=9b0682dc3a6611e9a490b56deb33d08b&recipient_id=88fe6e8a-cd7b-11e9-821e-4180c1a9232a&recipient_country=DE&balance_id=88fe6e8a-bd3b-11e9-821e-4180c1a9232a&virtual_account_id=88fe6e8a-cd7b-11e9-821e-4180c1a9232a&scheduled_payment_id=88fe6e8a-cd7b-11e9-821e-4180c1a9232a&transaction_type=payment&currency=GBP&to_currency=EUR&status=processed&from_datetime=2020-12-21T15%3A52%3A01%2B00%3A00&to_datetime=2021-12-31T15%3A52%3A01%2B00%3A00&search=invoice"
[
  {
    "id": "88fe6e8a-cd7b-11e9-821e-4180c1a9232a",
    "amount": 1000,
    "fees": 0,
    "currency": "EUR",
    "to_currency": "GBP",
    "balance_id": "88fe6e8a-bd3b-11e9-821e-4180c1a9232a",
    "virtual_account_id": "9d4b1522-4c4e-11e9-900f-2d9954c22966",
    "order_id": "9d4b15224c4e11e9900f2d9954c22966",
    "payment_reference": "bwN23dZWLRU6E65gJRfJ",
    "status": "initiated",
    "failure_reason": "Beneficiary Bank not available",
    "transaction_type": "payment",
    "payment_method": "balance",
    "recipient": {
      "id": "88fe6e8a-cd7b-11e9-821e-4180c1a9232a",
      "country": "GB",
      "default_reference": "Invoice",
      "alias": "John's Savings",
      "type": "personal",
      "created": "2019-09-02T13:16:47+01:00",
      "bank_account": {
        "account_name": "John Doe",
        "sort_code": "040004",
        "account_number": "12345678",
        "bank_name": "Monzo Bank Limited",
        "currency": "GBP"
      }
    },
    "exchange_rate": {
      "rate": 1093239,
      "single_rate": 469
    },
    "reference": "For invoice",
    "created": "2019-09-02T13:16:47+01:00"
  }
]

Initiate a new transaction

POST
/transactions
AuthorizationBearer <token>

In: header

transaction_typestring
amountinteger
to_amountinteger

You can also pass the recipient amount to us

balance_idstring
Formatuuid
recipient_idstring
Formatuuid
order_id?string

Unique order ID to prevent duplicate transactions

Rangevalue <= 50
reference?string

Response Body

curl -X POST "https://api.ohentpay.com/transactions" \
  -H "Content-Type: application/json" \
  -d '{
    "transaction_type": "payment",
    "amount": 1000000,
    "balance_id": "88fe6e8a-bd3b-11e9-821e-4180c1a9232a",
    "recipient_id": "e5a82d28-ae27-11ea-bad1-000c299aeb4b",
    "order_id": "9d4b15224c4e11e9900f2d9954c22966",
    "reference": "For invoice"
  }'
{
  "id": "88fe6e8a-cd7b-11e9-821e-4180c1a9232a",
  "amount": 1000,
  "fees": 0,
  "currency": "EUR",
  "to_currency": "GBP",
  "balance_id": "88fe6e8a-bd3b-11e9-821e-4180c1a9232a",
  "virtual_account_id": "9d4b1522-4c4e-11e9-900f-2d9954c22966",
  "order_id": "9d4b15224c4e11e9900f2d9954c22966",
  "payment_reference": "bwN23dZWLRU6E65gJRfJ",
  "status": "initiated",
  "failure_reason": "Beneficiary Bank not available",
  "transaction_type": "payment",
  "payment_method": "balance",
  "recipient": {
    "id": "88fe6e8a-cd7b-11e9-821e-4180c1a9232a",
    "country": "GB",
    "default_reference": "Invoice",
    "alias": "John's Savings",
    "type": "personal",
    "created": "2019-09-02T13:16:47+01:00",
    "bank_account": {
      "account_name": "John Doe",
      "sort_code": "040004",
      "account_number": "12345678",
      "bank_name": "Monzo Bank Limited",
      "currency": "GBP"
    }
  },
  "exchange_rate": {
    "rate": 1093239,
    "single_rate": 469
  },
  "reference": "For invoice",
  "created": "2019-09-02T13:16:47+01:00"
}
{
  "request": "error",
  "code": 400,
  "message": "Invalid request"
}

Fetch single transaction

GET
/transactions/{id}
AuthorizationBearer <token>

In: header

Path Parameters

idstring

Transaction ID

Formatuuid

Response Body

curl -X GET "https://api.ohentpay.com/transactions/88fe6e8a-cd7b-11e9-821e-4180c1a9232a"
{
  "id": "88fe6e8a-cd7b-11e9-821e-4180c1a9232a",
  "amount": 1000,
  "fees": 0,
  "currency": "EUR",
  "to_currency": "GBP",
  "balance_id": "88fe6e8a-bd3b-11e9-821e-4180c1a9232a",
  "virtual_account_id": "9d4b1522-4c4e-11e9-900f-2d9954c22966",
  "order_id": "9d4b15224c4e11e9900f2d9954c22966",
  "payment_reference": "bwN23dZWLRU6E65gJRfJ",
  "status": "initiated",
  "failure_reason": "Beneficiary Bank not available",
  "transaction_type": "payment",
  "payment_method": "balance",
  "recipient": {
    "id": "88fe6e8a-cd7b-11e9-821e-4180c1a9232a",
    "country": "GB",
    "default_reference": "Invoice",
    "alias": "John's Savings",
    "type": "personal",
    "created": "2019-09-02T13:16:47+01:00",
    "bank_account": {
      "account_name": "John Doe",
      "sort_code": "040004",
      "account_number": "12345678",
      "bank_name": "Monzo Bank Limited",
      "currency": "GBP"
    }
  },
  "exchange_rate": {
    "rate": 1093239,
    "single_rate": 469
  },
  "reference": "For invoice",
  "created": "2019-09-02T13:16:47+01:00"
}
Empty