Skip to main content

List all carts

GET 

https://api.freemius.com/v1/products/{product_id}/carts.json

Auth:Bearer TokenSCOPE: PRODUCT

Product-scoped API tokens allow you to operate on the product itself. This token usually allows read-only access to the product configuration and write access to several operations on subscriptions, customers, payments, and more. For most SaaS or app integrations, this is the token you will need.

  1. Go to the Freemius Developer Dashboard.
  2. Open the Settings page of the relevant product.
  3. Click the API & Keys tab.
  4. Copy the API Bearer Authorization Token from the UI.

Retrieve the cart collection associated with your product.

If enriched=true you will get more details about the cart for example the gross, coupon_code and licenses fields.

You can use the filter or email or count parameters to get more refined results from your query. Please learn more about the individual parameters below.

Request

Path Parameters

    product_id integer<int64>required

    The ID of the product.

    Possible values: >= 1

    Example: 1234

Query Parameters

    filter string
    Default value: all

    You can use the filter parameter to filter by status. If you don't provide a status, the endpoint will return all carts.

    Possible values: [all, abandoned, completed, recovered, recovery, active]

    offset integer
    Default value: 0

    The number of records to skip before starting to return records. Default is 0.

    Possible values: >= 0

    Example: 10
    fields string

    Comma separated list of fields to return in the response. If not specified, all fields are returned.

    Example: id,name,slug
    enriched boolean
    Default value: false

    Defaults to false, if true returns enriched cart details.

    email string

    Filter the cart collections by the email address.

    count integer
    Default value: 50

    Number of carts to retrieve.

Responses

Provides a collection of carts associated with the product. All carts are listed under the carts key.

Schema
carts object[]
  • Array [
  • idstring<int64>

    The unique identifier of the entity.

    Possible values: >= 1

    Example: 123456
    createdstring<date-time>

    The date and time the entity was created, under UTC timezone.

    Example: 2025-01-01 00:00:00
    updatedstring<date-time>nullable

    The date and time the entity was updated, under UTC timezone. If null then the entity was never updated since its creation.

    Example: 2025-01-01 00:00:00
    statusstring
    Default value: visit

    The status of the cart.

    Possible values: [pricing_visit, visit, abandoned, completed, email_1_sent, email_2_sent, email_3_sent, recovered]

    modestring
    Default value: dialog

    The mode the checkout app was opened in, when the cart was created. For example

    • dashboard: The checkout was opened through our WordPress SDK.
    • dialog: The checkout was opened through our JavaScript SDK.
    • page: The checkout was opened directly.

    Possible values: [dashboard, dialog, page]

    payment_methodstring
    Default value: cc

    The payment method selected for the purchase.

    Possible values: [cc, paypal, ideal]

    plugin_idstring<int64>

    The ID of the product the entity belongs to.

    Possible values: >= 1

    Example: 123456
    plan_idstring<int64>nullable

    The ID of the plan associated with the entity.

    Possible values: >= 1

    Example: 123456
    pricing_idstring<int64>nullable

    The ID of the pricing associated with the entity.

    Possible values: >= 1

    Example: 123456
    is_trialboolean

    Whether the plan is a trial.

    billing_cyclenumber

    The billing cycle of the subscription in number of months. 1 means monthly, 12 means annually, 0 means lifetime usually when subscriptions are created for lifetime trials.

    Possible values: [1, 12, 0]

    install_idstring<int64>nullable

    The ID of the installation or site the entity is associated with, a null value means it has not been associated with an installation yet.

    Possible values: >= 1

    Example: 123456
    coupon_idstring<int64>nullable

    The ID of the coupon associated with the entity.

    Possible values: >= 1

    Example: 123456
    country_codestringnullable

    The ISO 3166-1 alpha 2 two-letter country code associated with the entity.

    Example: us
    zip_postal_codestring

    The postal/zip code of the location.

    Example: 92710
    vat_idstringnullable

    The business VAT number (EU or UK territories) or other tax ID (for example Sales Tax ID for the US).

    Example: GB12345678
    user_idstring<int64>nullable

    The ID of the user the entity belongs to. If NULL then still not associated to any user.

    Possible values: >= 1

    Example: 123456
    emailstring

    The prospect's email address.

    firststring

    The prospect's first name.

    Example: John
    laststring

    The prospect's last name.

    Example: Doe
    ipstring<ipv4|ipv6>

    The IP address associated with the entity.

    Example: 0.0.0.0
    urlstring

    The page URL containing the checkout.

    Example: https://example.com/pricing
    environmentnumber

    The environment the entity belongs to. 0 means it belongs to the production environment, 1 means it belongs to the sandbox environment.

    Possible values: [1, 0]

    Example: 0
    is_disabledboolean
    Default value: false

    Cart supports recovery campaign. If disabled, the recovery campaign will be stopped.

    is_unsubscribedboolean
    Default value: false

    If set to true, the cart recovery campaign will be non-functional and cannot be re-enabled. This happens if the prospect has clicked the "unsubscribe" link from any of the cart recovery emails.

    visitedstring<date-time>nullable

    The first time the prospect visited the checkout when the cart was being created.

    Example: 2025-01-01 00:00:00
    completedstring<date-time>nullable

    The cart completion date.

    Example: 2025-01-01 00:00:00
    pricenumber<float>

    The cart's original price.

    Example: 19.99
    grossnumber<float>nullable

    Email of the user associated with the cart. (Only available when enriched is set to true.)

    Example: 359.64
    coupon_codestringnullable

    Coupon code associated with the cart. (Only available when enriched is set to true.)

    Example: BLACKFRIDAY2024
    licensesnumbernullable

    Number of licenses associated with the cart. (Only available when enriched is set to true.)

    Example: 10
  • ]
  • We use essential cookies to enable our site to function. With your consent, we also use analytics and advertising cookies to understand how visitors interact with our site and to improve our services.
    Learn More