Get a payment
const options = {method: 'GET', headers: {Authorization: 'Bearer <token>'}};
fetch('https://prod-payments-api.forebit.io/v1/businesses/{businessId}/payments/{paymentId}', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));{
"data": {
"endAmount": 123,
"prePaymentAmount": 123,
"currency": "<string>",
"createdAt": "2023-11-07T05:31:56Z",
"expiresAt": "2023-11-07T05:31:56Z",
"timeline": [
{
"time": "2023-11-07T05:31:56Z"
}
],
"id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"name": "<string>",
"description": "<string>",
"customer": {
"id": 123,
"email": "<string>",
"ipAddresses": [
{
"city": "<string>",
"ip": "<string>",
"country": "<string>",
"riskScore": 123,
"isp": "<string>",
"dateCreated": "2023-11-07T05:31:56Z"
}
]
},
"metadata": {},
"forebitCryptoCharge": {
"amount": 123,
"coinName": "<string>",
"exchangeRate": 123,
"isUnderpaid": true,
"address": "<string>",
"transaction": {
"amount": 123,
"toAddress": "<string>",
"id": "<string>",
"confirmations": 123,
"blockNumber": "<string>",
"fromAddress": "<string>"
},
"transactions": [
{
"amount": 123,
"toAddress": "<string>",
"id": "<string>",
"confirmations": 123,
"blockNumber": "<string>",
"fromAddress": "<string>"
}
],
"walletName": "<string>"
},
"contractCharge": {
"amount": 123,
"exchangeRate": 123,
"isUnderpaid": true,
"address": "<string>",
"transaction": {
"amount": 123,
"toAddress": "<string>",
"id": "<string>",
"confirmations": 123,
"blockNumber": "<string>",
"fromAddress": "<string>"
},
"walletName": "<string>",
"coinName": "<string>"
},
"forebitFee": 123,
"note": "<string>",
"onBehalfOfBusinessId": 123,
"netAmountUsd": 123
},
"message": "<string>",
"errors": [
"<string>"
]
}Payments
Get a payment
Retrieve the full record for a single payment, including customer info, event timeline, on-chain transaction data, and fee details.
GET
/
v1
/
businesses
/
{businessId}
/
payments
/
{paymentId}
Get a payment
const options = {method: 'GET', headers: {Authorization: 'Bearer <token>'}};
fetch('https://prod-payments-api.forebit.io/v1/businesses/{businessId}/payments/{paymentId}', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));{
"data": {
"endAmount": 123,
"prePaymentAmount": 123,
"currency": "<string>",
"createdAt": "2023-11-07T05:31:56Z",
"expiresAt": "2023-11-07T05:31:56Z",
"timeline": [
{
"time": "2023-11-07T05:31:56Z"
}
],
"id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"name": "<string>",
"description": "<string>",
"customer": {
"id": 123,
"email": "<string>",
"ipAddresses": [
{
"city": "<string>",
"ip": "<string>",
"country": "<string>",
"riskScore": 123,
"isp": "<string>",
"dateCreated": "2023-11-07T05:31:56Z"
}
]
},
"metadata": {},
"forebitCryptoCharge": {
"amount": 123,
"coinName": "<string>",
"exchangeRate": 123,
"isUnderpaid": true,
"address": "<string>",
"transaction": {
"amount": 123,
"toAddress": "<string>",
"id": "<string>",
"confirmations": 123,
"blockNumber": "<string>",
"fromAddress": "<string>"
},
"transactions": [
{
"amount": 123,
"toAddress": "<string>",
"id": "<string>",
"confirmations": 123,
"blockNumber": "<string>",
"fromAddress": "<string>"
}
],
"walletName": "<string>"
},
"contractCharge": {
"amount": 123,
"exchangeRate": 123,
"isUnderpaid": true,
"address": "<string>",
"transaction": {
"amount": 123,
"toAddress": "<string>",
"id": "<string>",
"confirmations": 123,
"blockNumber": "<string>",
"fromAddress": "<string>"
},
"walletName": "<string>",
"coinName": "<string>"
},
"forebitFee": 123,
"note": "<string>",
"onBehalfOfBusinessId": 123,
"netAmountUsd": 123
},
"message": "<string>",
"errors": [
"<string>"
]
}Authorizations
Pass your JWT token in the Authorization header as a Bearer token.
Path Parameters
The target business ID.
The payment ID to look up.
Was this page helpful?
⌘I