Skip to main content

List subscription pricing options

GET 

https://euwest.api.elasticpath.com/v2/subscriptions/subscriptions/:subscription_uuid/pricing-options

Retrieves a list of pricing options associated with the specified subscription. Using this endpoint you can see the pricing options that are currently active in a subscription. If active_pricing_option is true, a pricing option is active in a subscription. If active_pricing_option is null, the pricing option is not active.

Request

Path Parameters

    subscription_uuid UUIDrequired

    The unique identifier of the subscription.

Responses

Success. A list of subscription pricing options is returned.

Schema
    data OfferingPricingOption[]
  • Array [
  • idUUID (string)

    The unique identifier.

    Example: 11111111-2222-3333-4444-555555555555
    typeSubscriptionOfferingPricingOptionType (string)required

    Possible values: [subscription_offering_pricing_option]

    Example: subscription_offering_pricing_option
    attributes PricingOptionResponseAttributes
    external_refExternalRef (string)

    A unique attribute that you could use to contain information from another company system, for example. The maximum length is 2048 characters.

    Possible values: <= 2048 characters

    Example: abc123
    namestringrequired

    A name for the pricing option.

    Possible values: >= 3 characters and <= 1024 characters

    Example: Monthly
    descriptionstring

    The pricing option description to display to customers.

    Possible values: <= 1024 characters

    Example: A monthly subscription.
    billing_interval_typestringrequired

    The unit of time that billing intervals are measured.

    Possible values: [day, week, month, year]

    Example: month
    billing_frequencyintegerrequired

    The number of intervals between issuing bills.

    Possible values: >= 1

    Example: 1
    trial_periodinteger

    The number of intervals from the start of the subscription before billing starts. Used with billing_interval_type. For example, if billing_interval_type is months, and trial_period is 1, the trial period is 1 month.

    Possible values: >= 0

    Example: 7
    plan_lengthintegerrequired

    The number of intervals that the subscription runs for.

    Possible values: >= 1

    Example: 12
    end_behaviorstringrequired

    Enables you to specify recurring payments. If end_behavior is roll, customers pay regularly and repeatedly. If end_behavior is close, customers pay a total amount in a limited number of partial payments.

    Possible values: [close, roll]

    Example: close
    can_pausebooleanrequired

    The subscriber can pause a subscription.

    Example: false
    can_resumebooleanrequired

    The subscriber can resume a paused subscription.

    Example: false
    can_cancelbooleanrequired

    The subscriber can cancel a subscription.

    Example: false
    base_price_percentagenumber<double>

    A percentage discount on the total cost of any plans within an offering. For example, you can configure a percentage that equates the cost of a pricing option to the total value of all plans within the offering, reduced by a percentage. For example, if you specify 10, a 10% discount is applied to the total value of all repeat plans in an offering.

    Possible values: >= 0 and <= 100

    Example: 90
    fixed_price Price
    property name* object

    The base price.

    amountinteger<int64>required

    The value as a whole number of the currency's smallest subdivision.

    Example: 100
    includes_taxboolean

    Indicates whether the amount includes any taxes.

    Example: true
    updated_atstringrequired

    The date and time a resource was updated.

    Example: 2017-01-10T11:41:19.244842Z
    created_atstringrequired

    The date and time a resource was created.

    Example: 2017-01-10T11:41:19.244842Z
    relationships Relationships

    Relationships are established between different subscription entities. For example, a plan and a pricing option are related to an offering, as both are attached to it.

    property name* Relationship
    anyOf
    meta OfferingPricingOptionMetarequired
    prices object

    The price of each plan within the offering that this pricing option may be applied to.

    property name* OfferingPricingOptionPriceForPlan
    price Price
    property name* object

    The base price.

    amountinteger<int64>required

    The value as a whole number of the currency's smallest subdivision.

    Example: 100
    includes_taxboolean

    Indicates whether the amount includes any taxes.

    Example: true
    display_price DisplayPrice
    without_tax PriceFormatting
    amountinteger<int64>required

    The unformatted amount for the objects.

    Example: 100
    currencystring<string>required

    The three-letter ISO currency code in uppercase, associated with a price.

    Example: USD
    formattedstring<string>required

    The formatted amount for the objects.

    Example: $1.00
    with_tax PriceFormatting
    amountinteger<int64>required

    The unformatted amount for the objects.

    Example: 100
    currencystring<string>required

    The three-letter ISO currency code in uppercase, associated with a price.

    Example: USD
    formattedstring<string>required

    The formatted amount for the objects.

    Example: $1.00
    price Price
    property name* object

    The base price.

    amountinteger<int64>required

    The value as a whole number of the currency's smallest subdivision.

    Example: 100
    includes_taxboolean

    Indicates whether the amount includes any taxes.

    Example: true
    display_price DisplayPrice
    without_tax PriceFormatting
    amountinteger<int64>required

    The unformatted amount for the objects.

    Example: 100
    currencystring<string>required

    The three-letter ISO currency code in uppercase, associated with a price.

    Example: USD
    formattedstring<string>required

    The formatted amount for the objects.

    Example: $1.00
    with_tax PriceFormatting
    amountinteger<int64>required

    The unformatted amount for the objects.

    Example: 100
    currencystring<string>required

    The three-letter ISO currency code in uppercase, associated with a price.

    Example: USD
    formattedstring<string>required

    The formatted amount for the objects.

    Example: $1.00
    active_pricing_optionActivePricingOption (boolean)

    Whether a pricing option is active on a subscription using that offering. The active_pricing_option attribute is null if a pricing option is not active in a subscription.

    Example: true
    ownerstring<string>required

    The owner of a resource, either store or organization.

    Example: store
    timestamps Timestampsrequired
    updated_atstringrequired

    The date and time a resource was updated.

    Example: 2017-01-10T11:41:19.244842Z
    created_atstringrequired

    The date and time a resource was created.

    Example: 2017-01-10T11:41:19.244842Z
  • ]

Authorization: http

name: BearerTokentype: httpscheme: bearer
var client = new HttpClient();
var request = new HttpRequestMessage(HttpMethod.Get, "https://euwest.api.elasticpath.com/v2/subscriptions/subscriptions/:subscription_uuid/pricing-options");
request.Headers.Add("Accept", "application/json");
request.Headers.Add("Authorization", "Bearer <token>");
var response = await client.SendAsync(request);
response.EnsureSuccessStatusCode();
Console.WriteLine(await response.Content.ReadAsStringAsync());
Request Collapse all
Base URL
https://euwest.api.elasticpath.com/v2
Auth
Parameters
— pathrequired
ResponseClear

Click the Send API Request button above and see the response here!