Account payments
API DocumentationEndpoint
GET
https://dev.usermetric.io/api/payments/
Parameters
| Parameters | Details | Description |
|---|---|---|
processor
|
Optional
String
|
Allowed values: paypal, stripe, offline_payment, payu, iyzico, paystack, razorpay, mollie, yookassa, crypto_com, paddle, paddle_billing, mercadopago, midtrans, flutterwave, lemonsqueezy, myfatoorah, klarna, plisio, revolut |
status
|
Optional
String
|
Allowed values: paid, pending, cancelled, refunded |
type
|
Optional
String
|
Allowed values: one_time, recurring |
frequency
|
Optional
String
|
Allowed values: monthly, quarterly, biannual, annual, lifetime |
datetime_field
|
Optional
String
|
Allowed values: datetime |
datetime_start
|
Optional
String
|
Filter results starting from this datetime. Y-m-d H:i:s format. |
datetime_end
|
Optional
String
|
Filter results up to this datetime. Y-m-d H:i:s format. |
order_by
|
Optional
String
|
What field to order the results by. Allowed values are: id, datetime, total_amount. |
order_type
|
Optional
String
|
The ordering of the results. Allowed values are: ASC for ascending ordering, and DESC for descending ordering. |
page
|
Optional
Integer
|
The page number that you want results from. Defaults to 1. |
results_per_page
|
Optional
Integer
|
How many results you want per page. Allowed values are: 10, 25, 50, 100, 250, 500, 1000. Defaults to 25. |
Example
curl --request GET \
--url 'https://dev.usermetric.io/api/payments/' \
--header 'Authorization: Bearer {api_key}' \
Response example
{
"data": [
{
"id": 1,
"user_id": 1,
"plan_id": 1,
"payment_id": "ch_3QxExampleStripeCharge",
"base_amount": 4.99,
"processor": "stripe",
"type": "recurring",
"frequency": "monthly",
"code": null,
"discount_amount": 0,
"email": "example@example.com",
"name": null,
"total_amount": 4.99,
"total_amount_default_currency": 4.99,
"currency": "USD",
"status": "paid",
"plan": {
"plan_id": 1,
"name": "Starter",
"frequency": "monthly"
},
"billing": {
"type": "personal",
"name": "Example Person",
"address": "1 Example Street",
"city": "Example City",
"county": "Example County",
"zip": "00001",
"country": "US",
"tax_id": null
},
"business": {
"name": "Example Business Ltd",
"address": "2 Example Avenue",
"tax_id": "EX123456789",
"invoice_nr_prefix": "INV-"
},
"taxes_ids": [],
"payment_proof": null,
"payment_proof_url": null,
"refunds": [],
"refunded_total": 0,
"refunded_status": "none",
"datetime": "2026-09-22 02:52:19"
},
{
"id": 2,
"user_id": 1,
"plan_id": 2,
"payment_id": "manual-0002",
"base_amount": 34.8,
"processor": "offline_payment",
"type": "one_time",
"frequency": "annual",
"code": "EXAMPLE20",
"discount_amount": 8.7,
"email": "example@example.com",
"name": "Example Person",
"total_amount": 26.1,
"total_amount_default_currency": 26.1,
"currency": "USD",
"status": "refunded",
"plan": {
"plan_id": 2,
"name": "Growth",
"frequency": "annual"
},
"billing": {
"type": "business",
"name": "Example Person",
"address": "1 Example Street",
"city": "Example City",
"county": "Example County",
"zip": "00001",
"country": "DE",
"tax_id": "DE123456789"
},
"business": {
"name": "Example Business Ltd",
"address": "2 Example Avenue",
"tax_id": "EX123456789",
"invoice_nr_prefix": "INV-"
},
"taxes_ids": [2],
"payment_proof": "e1f2a3b4c5d6e7f8a9b0c1d2e3f4a5b6.jpg",
"payment_proof_url": "https://dev.usermetric.io/view/payment-proof/e1f2a3b4c5d6e7f8a9b0c1d2e3f4a5b6.jpg",
"refunds": [
{
"id": 1,
"amount": "26.10",
"reason": "Example refund reason",
"datetime": "2026-09-22 02:52:19"
}
],
"refunded_total": 26.1,
"refunded_status": "fully_refunded",
"datetime": "2026-09-22 02:52:19"
}
],
"meta": {
"page": 1,
"results_per_page": 25,
"total_results": 2,
"total_pages": 1
},
"links": {
"first": "https://dev.usermetric.io/api/payments?page=1",
"last": "https://dev.usermetric.io/api/payments?page=1",
"next": null,
"prev": null,
"self": "https://dev.usermetric.io/api/payments?page=1"
}
}
Endpoint
GET
https://dev.usermetric.io/api/payments/{payment_id}
Example
curl --request GET \
--url 'https://dev.usermetric.io/api/payments/{payment_id}' \
--header 'Authorization: Bearer {api_key}' \
Response example
{
"data": {
"id": 1,
"user_id": 1,
"plan_id": 1,
"payment_id": "ch_3QxExampleStripeCharge",
"base_amount": 4.99,
"processor": "stripe",
"type": "recurring",
"frequency": "monthly",
"code": null,
"discount_amount": 0,
"email": "example@example.com",
"name": null,
"total_amount": 4.99,
"total_amount_default_currency": 4.99,
"currency": "USD",
"status": "paid",
"plan": {
"plan_id": 1,
"name": "Starter",
"frequency": "monthly"
},
"billing": {
"type": "personal",
"name": "Example Person",
"address": "1 Example Street",
"city": "Example City",
"county": "Example County",
"zip": "00001",
"country": "US",
"tax_id": null
},
"business": {
"name": "Example Business Ltd",
"address": "2 Example Avenue",
"tax_id": "EX123456789",
"invoice_nr_prefix": "INV-"
},
"taxes_ids": [],
"payment_proof": null,
"payment_proof_url": null,
"refunds": [],
"refunded_total": 0,
"refunded_status": "none",
"datetime": "2026-09-22 02:52:19"
}
}