Retrieve a customer's lifetime summary metrics

Retrieves lifetime summary metrics for a customer with a specified ID.

SecuritySecretApiKey or JWT
Request
path Parameters
customerId
required
string

ID of the customer.

Responses
200

Metrics retrieved.

Response Schema: application/json
currency
string = 3 characters

Currency code in ISO 4217 format.

refundsAmount
number <double>

Total amount of all refunded transactions.

revenueAmount
number <double>

Total amount of all approved sales and captures.

disputesAmount
number <double>

Total amount of all disputed transactions.

401

Unauthorized access. Invalid credentials used.

403

Access forbidden.

get/experimental/customers/{customerId}/summary-metrics
Request samples
const metrics = await api.customers.getCustomerLifetimeSummaryMetrics({id: 'foobar-0001'});
console.log(metrics.fields.revenueAmount);
Response samples
application/json
{
  • "currency": "USD",
  • "refundsAmount": 0,
  • "revenueAmount": 0,
  • "disputesAmount": 0
}