API
Core Resources

Customers

The Customer object holds account information. Email is unique on the Customer; no two customers for a store can have the same email. Address is a child of the Customer object. There can be many child Addresses on a customer, but only one parent Customer per Address.

64 additions in V2, marked New

Everything marked New also works when you send X-Recharge-Version: 2021-11.

How Customers relate to other resources

#The customer object

Attributes

  • idinteger
    Unique numeric identifier for the Customer.
  • An object containing analytics data associated with the customer.
    Show child attributesHide child attributes1
  • A boolean that indicates whether Recharge credits will be applied to the next checkout charge.
  • A boolean that indicates whether Recharge credits will be applied to the next recurring charge.
  • backup_payment_methods_enabledboolean · nullableNew
    A boolean that indicates whether backup payment methods can be used for the customer when a charge fails. null when no preference has been set for the customer, in which case the store's default applies.
  • A boolean that indicates whether a payment method can be added to the customer in Recharge.
  • includeobjectNew
    An object containing the related resources requested with the include query parameter.
    Only returned when the include query parameter is passed.
    Show child attributesHide child attributes920 new
    • addressesarrayNew
      The Addresses associated with the Customer. Returned when include contains addresses.
    • announcementsarray of objectsNew
      The most recent customer portal announcement for the Customer. Returned when include contains announcements.
      Empty unless the store uses customer portal announcements.
      Show child attributesHide child attributes66 new
      • idintegerNew
        Unique numeric identifier for the announcement.
      • customer_idintegerNew
        Unique numeric identifier for the Customer the announcement is for.
      • flow_idintegerNew
        Unique numeric identifier for the flow that created the announcement.
      • view_schemaobjectNew
        An object describing the content of the announcement shown in the customer portal.
      • created_atdatetimeNew
        The date and time when the announcement was created.
      • updated_atdatetimeNew
        The date and time when the announcement was last updated.
    • The gift purchases for which the Customer is the recipient. Returned when include contains gift_purchases. Requires the read_gift_purchases scope.
    • membershipsarray of objectsNew
      The memberships of the Customer. Returned when include contains memberships. Requires the read_memberships scope.
      Show child attributesHide child attributes22 new
    • metafieldsarrayNew
      The Metafields owned by the Customer. Returned when include contains metafields.
    • The Payment Methods of the Customer. Returned when include contains payment_methods. Requires the read_payment_methods scope.
    • An object keyed by punch card id that contains the progress of the Customer in each punch card: punch_card_order_count, punch_card_streak_count, punch_card_total_order_value_in_store_currency and the punch_card_previous_* values recorded before the latest order. Returned when include contains punch_card_progress.
    • referral_infoobjectNew
      An object containing referral information for the Customer. Returned when include contains referral_info.
      Show child attributesHide child attributes13 new
      • referral_urlobjectNew
        The referral link of the Customer. Empty when the store has no active referral program.
        Show child attributesHide child attributes22 new
        • urlstringNew
          The URL the Customer can share to refer others.
        • slugstringNew
          The unique identifier of the Customer used in the referral URL.
    • The Subscriptions of the Customer. Returned when include contains subscriptions. Requires the read_subscriptions scope.
  • The number of active memberships the customer has.
    Only returned when retrieving or listing customers on stores that have memberships enabled.
  • The total number of memberships created for the customer.
    Only returned when retrieving or listing customers on stores that have memberships enabled.
  • A boolean that indicates whether falling back to the customer's default payment method with the payment processor is disabled when a charge on the assigned payment method fails.
  • The lifetime value of the customer in Recharge, expressed in the store's default currency.
  • The total number of charges successfully processed for the customer.
  • created_atdatetime
    The date and time when the customer was created.
  • emailstring
    The email address of the customer.
  • An object containing external ids for the customer record.
    Show child attributesHide child attributes1
    • ecommercestring
      The customer ID as it appears in the external e-commerce platform.
  • Date when first charge was processed for the customer.
  • The customer’s first name.
  • A boolean that indicates if the customer has a payment method that is in dunning (failed charge).
  • Is the payment method valid or not.
  • hashstring
    The unique string identifier used in a customers portal link.
  • last_namestring
    The customer’s last name.
  • phonestring
    The customer's phone number.
  • The number of active subscriptions on addresses associated with the customer.
  • The total number of subscriptions created on addresses associated with the customer.
  • tax_exemptboolean
    Whether the customer tax exempt or not.
  • updated_atdatetime
    The date and time when the customer was last updated.
The customer object
{
  "id": 18819267,
  "analytics_data": {
    "utm_params": [
      {
        "utm_source": "facebook",
        "utm_medium": "cpc"
      }
    ]
  },
  "apply_credit_to_next_checkout_charge": false,
  "backup_payment_methods_enabled": null,
  "can_add_payment_method": true,
  "created_at": "2018-11-14T08:40:38+00:00",
  "email": "example_mail@gmail.com",
  "external_customer_id": {
    "ecommerce": "126576412310131454"
  },
  "first_charge_processed_at": null,
  "first_name": "Jacob",
  "has_payment_method_in_dunning": false,
  "has_valid_payment_method": false,
  "hash": "18819267b1f9095be98f13a8",
  "last_name": "Bronowski",
  "payment_method_fallback_on_failure_disabled": false,
  "phone": "+16175551212",
  "recharge_lifetime_value_total_amount_store_default_currency": null,
  "subscriptions_active_count": 0,
  "subscriptions_total_count": 1,
  "tax_exempt": false,
  "total_processed_charge_count": 0,
  "updated_at": "2020-11-14T08:40:38+00:00"
}

#Create a customer

POST/customers
CustomRCSSCI
Create a customer in Recharge.
Scopewrite_customers
If you plan to add payment information, it must be the tokenized customer representation. We do not accept card data directly. For Stripe users, please make sure it starts with ‘cus’ and not with a 'tok’, as the 'cus’ is prefix for customer token, and 'tok’ is prefix for payment token.

Creating a customer in Recharge will not create the customer on any other platform at this time.

write_payment_methods permission is only required when creating customers with payment token information, or updating payment token information on a customer.

phone must be in E.164 format, such as +16175551212.

Returns 201 on success.

Body parameters

  • An object containing analytics data associated with the customer.
    Show child attributesHide child attributes18 new
    • utm_paramsarray of objectsNew
      An array containing utm_param objects.
      Show child attributesHide child attributes77 new
  • custom_event_attributesarray of objectsNew
    A list of up to 10 custom attributes to attach to the Event created by this request. They are returned in the custom_attributes of that Event.
    Show child attributesHide child attributes22 new
    • keystringNew
      A user-defined key for the custom attribute.
    • valuestring · nullableNew
      A user-defined value for the custom attribute. Maximum length is 255 characters.
  • emailstringRequired
    The customer’s email address.
  • An object containing external ids for the customer record.
    Show child attributesHide child attributes1
    • ecommercestring
      The customer ID as it appears in the external e-commerce platform.
  • first_namestringRequired
    The customer’s first name.
  • last_namestringRequired
    The customer’s last name.
  • phonestring
    The customer's phone number.
  • tax_exemptboolean
    Whether or not the customer is tax exempt.
POST/customers
curl -X POST 'https://api.rechargeapps.com/customers' \
  -H 'X-Recharge-Version: v2' \
  -H 'Content-Type: application/json' \
  -H 'X-Recharge-Access-Token: your_api_token' \
  -d '{
  "first_name": "Niels",
  "last_name": "Bohr",
  "email": "fake@example.com"
}'
Response
{
  "customer": {
    "id": 37657002,
    "analytics_data": {
      "utm_params": [
        {
          "utm_source": "facebook",
          "utm_medium": "cpc"
        }
      ]
    },
    "apply_credit_to_next_checkout_charge": false,
    "backup_payment_methods_enabled": null,
    "can_add_payment_method": true,
    "created_at": "2020-02-19T17:40:07+00:00",
    "email": "fake@example.com",
    "external_customer_id": {
      "ecommerce": "2879413682227"
    },
    "first_charge_processed_at": "2020-02-19T17:40:11+00:00",
    "first_name": "Jane",
    "has_payment_method_in_dunning": false,
    "has_valid_payment_method": true,
    "hash": "7e706455cbd13e40",
    "last_name": "Doe",
    "payment_method_fallback_on_failure_disabled": false,
    "phone": null,
    "recharge_lifetime_value_total_amount_store_default_currency": null,
    "subscriptions_active_count": 0,
    "subscriptions_total_count": 0,
    "subscription_related_charge_streak": 0,
    "tax_exempt": false,
    "total_processed_charge_count": 0,
    "updated_at": "2020-12-17T18:50:39+00:00"
  }
}

#Retrieve a customer

GET/customers/{id}
Retrieve one customer using customer_id.
Scoperead_customers

Query parameters

  • includestringNew
    A comma-separated list of related resources to embed in the include attribute of each Customer.
    Possible values
    addressesannouncementsgift_purchasesmembershipsmetafieldspayment_methodspunch_card_progressreferral_infosubscriptions
GET/customers/{id}
curl 'https://api.rechargeapps.com/customers/37657002' \
  -H 'X-Recharge-Version: v2' \
  -H 'X-Recharge-Access-Token: your_api_token'
Response
{
  "customer": {
    "id": 37657002,
    "analytics_data": {
      "utm_params": [
        {
          "utm_source": "facebook",
          "utm_medium": "cpc"
        }
      ]
    },
    "apply_credit_to_next_checkout_charge": false,
    "backup_payment_methods_enabled": null,
    "can_add_payment_method": true,
    "created_at": "2020-02-19T17:40:07+00:00",
    "email": "fake@example.com",
    "external_customer_id": {
      "ecommerce": "2879413682227"
    },
    "first_charge_processed_at": "2020-02-19T17:40:11+00:00",
    "first_name": "Jane",
    "has_payment_method_in_dunning": false,
    "has_valid_payment_method": true,
    "hash": "7e706455cbd13e40",
    "last_name": "Doe",
    "payment_method_fallback_on_failure_disabled": false,
    "phone": "+16175551212",
    "recharge_lifetime_value_total_amount_store_default_currency": null,
    "subscriptions_active_count": 0,
    "subscriptions_total_count": 1,
    "subscription_related_charge_streak": 0,
    "tax_exempt": false,
    "total_processed_charge_count": 0,
    "updated_at": "2020-12-17T18:50:39+00:00"
  }
}

#Update a customer

PUT/customers/{id}
Modify an existing Customer to match the specified parameters.
Scopewrite_customers
For US citizens, parameter billing_zip is required when updating customer’s billing_country parameter.

phone must be in E.164 format, such as +16175551212.

Body parameters

  • An object containing analytics data associated with the customer. UTM parameters passed in the request are added to the customer's existing utm_params.
    Show child attributesHide child attributes18 new
    • utm_paramsarray of objectsNew
      An array containing utm_param objects.
      Show child attributesHide child attributes77 new
  • A boolean that indicates whether Recharge credits will be applied to the next checkout charge. Cannot be changed when the store's credit settings always or never apply credits to checkout charges.
  • A boolean that indicates whether Recharge credits will be applied to the next recurring charge.
    This property is dependent upon the store's credit settings. If a call is made attempting to update this and the store has recurring redemption turned off or set to automatically redeem, the API will return a 422 response.
  • The channel recorded as the origin of the change when apply_credit_to_next_recurring_charge is set to true. Default is api.
    Possible values
    merchant_portalcustomer_portalcheckoutcancellation_preventionwinbacksapi
  • A boolean that indicates whether backup payment methods can be used for the customer when a charge fails.
  • custom_event_attributesarray of objectsNew
    A list of up to 10 custom attributes to attach to the Event created by this request. They are returned in the custom_attributes of that Event.
    Show child attributesHide child attributes22 new
    • keystringNew
      A user-defined key for the custom attribute.
    • valuestring · nullableNew
      A user-defined value for the custom attribute. Maximum length is 255 characters.
  • emailstring
    Email address of the customer.
  • An object containing external ids for the customer record.
    Show child attributesHide child attributes1
    • ecommercestring
      The customer ID as it appears in the external e-commerce platform.
  • Customer’s first name.
  • last_namestring
    Customer’s last name.
  • A boolean that indicates whether falling back to the customer's default payment method with the payment processor is disabled when a charge on the assigned payment method fails.
  • phonestring
    The customer's phone number.
  • tax_exemptboolean
    Whether or not the customer is tax exempt.
PUT/customers/{id}
curl -X PUT 'https://api.rechargeapps.com/customers/37657002' \
  -H 'X-Recharge-Version: v2' \
  -H 'Content-Type: application/json' \
  -H 'X-Recharge-Access-Token: your_api_token' \
  -d '{
  "last_name": "Doe"
}'
Response
{
  "customer": {
    "id": 37657002,
    "analytics_data": {
      "utm_params": [
        {
          "utm_source": "facebook",
          "utm_medium": "cpc"
        }
      ]
    },
    "apply_credit_to_next_checkout_charge": false,
    "backup_payment_methods_enabled": null,
    "can_add_payment_method": true,
    "created_at": "2020-02-19T17:40:07+00:00",
    "email": "fake@example.com",
    "external_customer_id": {
      "ecommerce": "2879413682227"
    },
    "first_charge_processed_at": "2020-02-19T17:40:11+00:00",
    "first_name": "Jane",
    "has_payment_method_in_dunning": false,
    "has_valid_payment_method": true,
    "hash": "7e706455cbd13e40",
    "last_name": "Doe",
    "payment_method_fallback_on_failure_disabled": false,
    "phone": "+16175551212",
    "recharge_lifetime_value_total_amount_store_default_currency": null,
    "subscriptions_active_count": 0,
    "subscriptions_total_count": 1,
    "tax_exempt": false,
    "total_processed_charge_count": 0,
    "updated_at": "2020-12-17T18:50:39+00:00"
  }
}

#Delete a customer

DELETE/customers/{id}
Customer deletion will automatically cancel and delete all child Address, Subscription, Onetime, etc. resources of that customer to eliminate orphaned child data.

To delete a certain address without deleting the customer you can use the Delete Address endpoint.
Scopewrite_customers
DELETE/customers/{id}
curl -X DELETE 'https://api.rechargeapps.com/customers/37657002' \
  -H 'X-Recharge-Version: v2' \
  -H 'X-Recharge-Access-Token: your_api_token'
Response
{}

#List customers

GET/customers
Return a list of customers in your store.

HTTP request examples

GET /customers

GET /customers?email=example@email.com

GET /customers?hash=143806234a9ff87a8d9e

GET /customers?limit=250

GET /customers?page=2

GET /customers?external_customer_id=98273498
Scoperead_customers
If emails contain special characters such as 'john+doe@example.com', you will need to encode them in the URLs, i.e. ?email=john%2Bdoe@example.com

Passing external_customer_id with an empty value returns a 422 error.

Query parameters

  • emailstring
    Returns the user linked to the email address provided.
  • Gets all customers created before this date.
  • Gets all customers created after this date.
  • hashstring
    Returns the user linked to the given recharge customer hash.
  • idsstring
    Filter customers by id. If passing multiple values, must be comma separated. Non-integer values will result in a 422 error
  • limitstring
    Number of results.
    Default 50Maximum 250
  • pagestringDeprecated
    Page to show.
    Default 1
    Page-based pagination has been deprecated but still available to use for pages up to a 100. If you need data past this point, use cursor pagination.
  • Returns the user linked to the given external_customer_id.
  • Gets all customers updated before this date.
  • Gets all customers updated after this date.
  • includestringNew
    A comma-separated list of related resources to embed in the include attribute of each Customer.
    Possible values
    addressesannouncementsgift_purchasesmembershipsmetafieldspayment_methodspunch_card_progressreferral_infosubscriptions
  • phonestringNew
    Returns the customer linked to the given phone number. Must be in E.164 format, including the country code.
  • sort_bystringNew
    Sort order of the results. Default is id-desc.
    Possible values
    id-ascid-descupdated_at-ascupdated_at-desccreated_at-asccreated_at-desc
  • cursorstringNew
    The next_cursor or previous_cursor value from a previous response, used to retrieve the next or previous page of results. When cursor is passed, only limit can be passed with it.
GET/customers
curl 'https://api.rechargeapps.com/customers?limit=3' \
  -H 'X-Recharge-Version: v2' \
  -H 'X-Recharge-Access-Token: your_api_token'
Response
{
  "next_cursor": "next_cursor",
  "previous_cursor": "previous_cursor",
  "customers": [
    {
      "id": 37657002,
      "analytics_data": {
        "utm_params": [
          {
            "utm_source": "facebook",
            "utm_medium": "cpc"
          }
        ]
      },
      "apply_credit_to_next_checkout_charge": false,
      "backup_payment_methods_enabled": null,
      "can_add_payment_method": true,
      "created_at": "2020-02-19T17:40:07+00:00",
      "email": "fake@example.com",
      "external_customer_id": {
        "ecommerce": "2879413682227"
      },
      "first_charge_processed_at": "2020-02-19T17:40:11+00:00",
      "first_name": "Jane",
      "has_payment_method_in_dunning": false,
      "has_valid_payment_method": true,
      "hash": "7e706455cbd13e40",
      "last_name": "Doe",
      "payment_method_fallback_on_failure_disabled": false,
      "phone": "+16175551212",
      "recharge_lifetime_value_total_amount_store_default_currency": null,
      "subscriptions_active_count": 0,
      "subscriptions_total_count": 1,
      "tax_exempt": false,
      "total_processed_charge_count": 0,
      "updated_at": "2020-12-17T18:50:39+00:00"
    }
  ]
}

#Retrieve a customer delivery schedule

GET/customers/{id}/delivery_schedule
Returns the list of projected deliveries in a specific interval.
Scoperead_customers
If several filters are passed in parameters, the most restrictive will dominate.
The maximum length of the future delivery interval is 365 days.

Query parameters

  • The count of delivery objects that should be included that reference projected orders.
    Will not return deliveries past 365 days in the future.
  • The count of days forward to report deliveries on.
    Defaults to store setting or 90. Maximum of 365 days.
  • date_maxstring
    The end date of the requested delivery schedule.
    Cannot be in the past. Cannot exceed 365 days in the future.

Response attributes

  • customerobject
    Customer details relevant for deliveries.
    Show child attributesHide child attributes4
    • idinteger
      Unique numeric identifier of the customer.
    • emailstring
      Email address of the customer.
    • The customer’s first name.
    • last_namestring
      The customer’s last name.
  • deliveriesarray of objects
    The order details of all deliveries due in the specified timeframe grouped by delivery date and address if customer has multiple addresses.
    Show child attributesHide child attributes2
    • datedate
      Date for the scheduled deliveries in Eastern Standard Time
    • ordersarray of objects
      The order details for a given delivery.
      Show child attributesHide child attributes7
      • idinteger
        Unique numeric identifier for the order
        Defaults to null if the Charge linked to this order has not been processed yet.
      • address_idinteger
        Unique numeric identifier for the customer's address for which the delivery is due.
      • charge_idinteger
        Unique numeric identifier for the Charge linked to the order. May be null for projected orders with no charge yet created.
      • line_itemsarray of objects
        List of order details.
        Show child attributesHide child attributes15
        • Unique numeric identifier for the subscription linked to this line_item in the order.
        • An object containing external product ids.
          Show child attributesHide child attributes1
          • ecommercestring
            The product id as it appears in the external e-commerce platform. The external_product_id of the Product record in Recharge, linking a Plan to a Product.
        • An object containing external variant ids.
          Show child attributesHide child attributes1
          • ecommercestring
            The variant id as it appears in the external e-commerce platform. The external_variant_id of the Product record in Recharge, linking a Plan to a Product.
        • imagesobject
          An object containing the product's images.
          Show child attributesHide child attributes5
          • largestring
            The url where a large image file is located.
          • mediumstring
            The url where a medium image file is located.
          • smallstring
            The url where a small image file is located.
          • originalstring
            The url of the original sized product image.
          • sort_orderinteger
            The sort order in which the x image from the array should appear when displayed.
        • is_prepaidboolean
          Value is set to true if it is a prepaid item
        • Value is set to true if it is not a onetime or a prepaid item
        • is_skippedboolean
          Value is set to true if the order is skipped.
        • The original price of the item without discounts or taxes.
        • plan_typestring
          The type of the plan. May return null value in certain cases.
          Possible values
          subscriptiononetime
        • The name of the product in a store's catalog.
        • propertiesarray of objects
          A list of line item objects, each one containing information about the subscription. Custom key-value pairs can be installed here, they will appear on the connected queued charge and after it is processed on the order itself.
          Show child attributesHide child attributes2
          • namestring
            The name of the property.
          • valuestring
            The value of the property.
        • quantityinteger
          The number of items in the subscription.
        • The subtotal price (sum of all line items * their quantity) of the order less discounts.
        • The unit price of the variant.
        • The name of the variant in a store's catalog.
      • The order subtotal price (sum of all individual order subtotals). May be "0.00" for subsequent prepaid orders not attributed to a charge.
      • The customer’s first name.
        Show child attributesHide child attributes3
        • idinteger
          The unique payment method id for a customer.
        • An object with the customer’s address information.
          Show child attributesHide child attributes10
          • address1string
            Line one of the billing address.
          • address2string
            Line two of the billing address.
          • citystring
            The city of the billing address.
          • companystring
            The company name of the billing address.
          • 2-letter country code.
          • The first name of the billing address.
          • last_namestring
            The last name of the billing address.
          • phonestring
            The phone number of the billing address.
          • provincestring
            The name of the province or state associated with the billing address.
          • zipstring
            The zip code or postcode of the address.
        • Details about the specific payment method
          Those details will vary based on the payment_type
          Show child attributesHide child attributes8
          • brandstring
            Payment_method brand or company powering it.
            valid for CREDIT_CARD only.
          • exp_monthstring
            Payment_method expiry month.
            valid for CREDIT_CARD only.
          • exp_yearstring
            Payment_method expiry year.
            valid for CREDIT_CARD only.
          • last4string
            last 4-digits of the identifier.
            valid for CREDIT_CARD only.
          • email linked to .
            valid for PAYPAL only.
          • paypal user identifier.
            valid for PAYPAL only.
          • If a digital wallet.
          • Type of funding for the Payment Method.
      • The shipping address where the order will be shipped.
        Show child attributesHide child attributes10
        • address1string
          Line one of the billing address.
        • address2string
          Line two of the billing address.
        • citystring
          The city of the billing address.
        • companystring
          The company name of the billing address.
        • 2-letter country code.
        • The first name of the billing address.
        • last_namestring
          The last name of the billing address.
        • phonestring
          The phone number of the billing address.
        • provincestring
          The name of the province or state associated with the billing address.
        • zipstring
          The zip code or postcode of the address.
GET/customers/{id}/delivery_schedule
curl 'https://api.rechargeapps.com/customers/37657002/delivery_schedule' \
  -H 'X-Recharge-Version: v2' \
  -H 'X-Recharge-Access-Token: your_api_token'
Response
{
  "deliverySchedule": {
    "customer": {
      "id": 73720164,
      "email": "test@example.com",
      "first_name": "Aria",
      "last_name": "Beciu"
    },
    "deliveries": [
      {
        "date": "2022-02-07",
        "orders": [
          {
            "id": null,
            "address_id": 79342717,
            "charge_id": 507503288,
            "line_items": [
              {
                "subscription_id": 186930285,
                "external_product_id": {
                  "ecommerce": "1642443555555"
                },
                "external_variant_id": {
                  "ecommerce": null
                },
                "images": {},
                "is_skippable": true,
                "is_skipped": false,
                "is_prepaid": false,
                "original_price": "17.00",
                "plan_type": "subscription",
                "product_title": "Organic coffee beans",
                "properties": [
                  {
                    "name": "shipping_interval_unit_type",
                    "value": "month"
                  },
                  {
                    "name": "shipping_interval_frequency",
                    "value": "1"
                  },
                  {
                    "name": "subscription_id",
                    "value": null
                  }
                ],
                "quantity": 1,
                "subtotal_price": "17.00",
                "unit_price": "17.00",
                "variant_title": "Refill large"
              }
            ],
            "order_subtotal": "17.00",
            "payment_method": {
              "id": 769874,
              "billing_address": {
                "address1": "90 avenue du Rouergue",
                "address2": null,
                "city": "Rodez",
                "company": null,
                "country_code": "FR",
                "first_name": "Diane",
                "last_name": "Farley",
                "phone": null,
                "province": null,
                "zip": "12000"
              },
              "payment_details": {}
            },
            "shipping_address": {
              "address1": "149 Forest Avenue",
              "address2": null,
              "city": "New York City",
              "company": null,
              "country_code": "US",
              "first_name": "Aria",
              "last_name": "Beciu",
              "phone": "1234567890",
              "province": "New York",
              "zip": "10019"
            }
          }
        ]
      }
    ]
  }
}

#Retrieve a customer's credit summary

GET/customers/{id}/credit_summary
Returns a credit summary for the customer.
Scoperead_credit_summary
The response is returned under the credit_summary key.

The response is returned under the credit_summary key.

Query parameters

  • includestringNew
    If credit_details is passed, the response includes the individual credit accounts of the customer in include.credit_details.
    Possible values
    credit_details
  • A 3-letter currency code. When passed, the response also includes the balances converted to this currency.

Response attributes

GET/customers/{id}/credit_summary
curl 'https://api.rechargeapps.com/customers/37657002/credit_summary' \
  -H 'X-Recharge-Version: v2' \
  -H 'X-Recharge-Access-Token: your_api_token'
Response
{
  "credit_summary": {
    "customer_id": 37657002,
    "total_available_balance": "0.00",
    "currency_code": "USD"
  }
}