Retrieve customer prepaid credit wallet
1 min
GET
https://app.amberflo.io/payments/billing/customer-prepaid-wallet
Query Parameters
- customerIdstringrequiredExampleDescription
- productIdstringExampleDescription
Responses
200
- payment.billing.prepaid_to_product.detailed.DetailedCustomerPrepaidWallet.outDescription
- keypayment.billing.prepaid_to_product.CustomerPrepaidWalletKey.outDescription
- accountIdstringDescription
- customerIdstringDescription
- productIdstringDescription
- prepaidCardspayment.billing.prepaid_to_product.detailed.DetailedPrepaidCard.out[]Description
- prepaidUristringDescription
- sourceUristringDescription
- paymentIdstringDescription
- paymentSystemNamestringDescription
- cardTypepayment.billing.prepaid_to_product.PrepaidCardType.outDescription
- paymentStatuspayment.payment.PaymentStatus.inDescription
- pricenumberDescription
- priceInBaseCurrencynumberDescription
- paymentCurrencyInfopayment.billing.PaymentCurrencyInfo.outDescription
- basePlanCurrencystringExampleDescription
- paymentCurrencystringExampleDescription
- exchangeRatenumberDescription
- worthnumberDescription
- startTimeInMillisinteger<int64>Description
- expirationTimeInMillisinteger<int64>Description
- productInvoicespayment.billing.prepaid_to_product.detailed.DetailedPrepaidProductInvoice.out[]Description
- invoiceUristringDescription
- createdTimeInSecondsinteger<int64>Description
- amountnumberDescription
- amountInCreditsnumberDescription
- invoiceAmountnumberDescription
- usedAmountnumberDescription
- amountLeftnumberDescription
- priceInCreditsnumberDescription
- worthInCreditsnumberDescription
- prepaidConditionspayment.billing.prepaid_to_product.PrepaidConditions.outDescription
- prepaidConditionsListpayment.billing.prepaid_to_product.PrepaidCondition.out[]Description
- payment.billing.prepaid_to_product.DimensionValueMapPrepaidCondition.in
- typestringDescriptionDefaultDimensionValueMapPrepaidCondition
- dimensionMapValuemap<string, string>Description
- payment.billing.prepaid_to_product.ProductItemDimensionPrepaidCondition.in
- typestringDescriptionDefaultProductItemDimensionPrepaidCondition
- productItemIdstringDescription
- dimensionsmap<string, string>Description
- payment.billing.prepaid_to_product.ProductItemPrepaidCondition.in
- Max depth limit reached
- prepaidConditionsHistorymap<string, payment.billing.prepaid_to_product.PrepaidCondition.out[]>Description
- labelstringDescription
- orderIdstringDescription
- installmentspayment.billing.prepaid_to_product.PrepaidInstallments.outDescription
- prepaidInstallmentspayment.billing.prepaid_to_product.PrepaidInstallmentSchedule.in[]requiredDescription
- amountPricenumberrequiredDescription
- scheduledPurchaseTimeInSecondsinteger<int64>requiredDescription
- creditUnitpayment.pricing.CreditUnit.outDescription
- idstringDescription
- shortNamestringDescription
- namestringDescription
- ratioToCurrencynumberDescription
- descriptionstringDescription
- activebooleanDescription
- lastUpdateTimeInMillisinteger<int64>Description
400
401
403
404
500
curl
curl --request GET \
--url 'https://app.amberflo.io/payments/billing/customer-prepaid-wallet?customerId=customer_12345' \
--header 'accept: application/json'javascript
var myHeaders = new Headers();
myHeaders.append("accept", "application/json");
myHeaders.append("content-type", "application/json");
var requestOptions = {
method: 'GET',
headers: myHeaders,
redirect: 'follow'
};
fetch("https://app.amberflo.io/payments/billing/customer-prepaid-wallet?customerId=customer_12345", requestOptions)
.then(response => response.text())
.then(result => console.log(result))
.catch(error => console.log('error', error));ruby
require "uri"
require "json"
require "net/http"
url = URI("https://app.amberflo.io/payments/billing/customer-prepaid-wallet?customerId=customer_12345")
https = Net::HTTP.new(url.host, url.port)
https.use_ssl = true
request = Net::HTTP::Get.new(url)
request["accept"] = "application/json"
request["content-type"] = "application/json"
response = https.request(request)
puts response.read_body
python
import requests
import json
url = "https://app.amberflo.io/payments/billing/customer-prepaid-wallet?customerId=customer_12345"
payload = {}
headers = {
'accept': 'application/json',
'content-type': 'application/json'
}
response = requests.request("GET", url, headers=headers, data=payload)
print(response.text)
200
// Returns detailed customer prepaid wallet with credit balances, usage history, and expiration details
{
"key": {
"accountId": "",
"customerId": "",
"productId": ""
},
"prepaidCards": [
{
"prepaidUri": "",
"sourceUri": "",
"paymentId": "",
"paymentSystemName": "",
"cardType": "",
"paymentStatus": "",
"price": 0,
"priceInBaseCurrency": 0,
"paymentCurrencyInfo": {
"basePlanCurrency": "USD",
"paymentCurrency": "USD",
"exchangeRate": 0
},
"worth": 0,
"startTimeInMillis": "",
"expirationTimeInMillis": "",
"productInvoices": [
{
"invoiceUri": "",
"createdTimeInSeconds": "",
"amount": 0,
"amountInCredits": 0,
"invoiceAmount": 0
}
],
"usedAmount": 0,
"amountLeft": 0,
"priceInCredits": 0,
"worthInCredits": 0,
"prepaidConditions": {
"prepaidConditionsList": {},
"prepaidConditionsHistory": ""
},
"label": "",
"orderId": "",
"installments": {
"prepaidInstallments": [
{
"amountPrice": 0,
"scheduledPurchaseTimeInSeconds": ""
}
]
}
}
],
"creditUnit": {
"id": "",
"shortName": "",
"name": "",
"ratioToCurrency": 0,
"description": "",
"active": false,
"lastUpdateTimeInMillis": ""
}
}400
// Invalid customer ID or malformed wallet request parameters
401
// Authentication required or invalid API key provided
403
// Insufficient permissions to access customer prepaid wallet data
404
// Customer not found or no prepaid wallet configured
500
// Internal server error occurred while retrieving wallet information