Skip to main content

Checkout a product or subscription

Checkout a product to buy it one time or start a subscription plan on a billing account manually. It bypasses billing engine.

Path Parameters
    org_id string required
Request Body required
    billing_id ID of the billing account to update the subscription for
    subscription_body object
    plan string
    skip_trial boolean
    cancel_after_trial boolean
    provider_coupon_id provider_coupon_id is the coupon code that will be applied to the subscription generated by the billing provider, this will be deprecated once coupons are managed by the platform
    product_body object
    product string
    quantity int64
Responses

A successful response.


Schema
    subscription object
    id string
    customer_id string
    provider_id string
    plan_id string
    state string
    metadata object
    created_at date-time
    updated_at date-time
    canceled_at date-time
    ended_at date-time
    trial_ends_at date-time
    current_period_start_at date-time
    current_period_end_at date-time
    billing_cycle_anchor_at date-time
    phases object[]
  • Array [
  • effective_at date-time
    plan_id string
  • ]
  • customer object
    id string
    org_id string
    name string
    email string
    phone string
    address object
    line1 string
    line2 string
    city string
    state string
    postal_code string
    country string
    provider_id string
    provider string
    currency string
    state string
    tax_data object[]
  • Array [
  • type tax type like "vat", "gst", "sales_tax" or if it's provider specific us_ein, uk_vat, in_gst, etc
    id unique identifier provided by the tax agency
  • ]
  • metadata object
    created_at date-time
    updated_at date-time
    organization object
    id string
    name string
    title string
    metadata object
    created_at date-time

    The time the organization was created.

    updated_at date-time

    The time the organization was last updated.

    state string

    The state of the organization (enabled or disabled).

    avatar string

    The base64 encoded image string of the organization avatar. Should be less than 2MB.

    plan object
    id string
    name string
    title string
    description string
    products object[]
  • Array [
  • id string
    name string
    title string
    description string
    plan_ids string[]
    state string
    prices object[]
  • Array [
  • id string
    product_id string
    provider_id string
    name string
    interval known intervals are "day", "week", "month", and "year"
    usage_type usage_type known types are "licensed" and "metered"
    billing_scheme billing_scheme known schemes are "tiered" and "flat"
    state string
    currency currency like "usd", "eur", "gbp"
    amount int64
    metered_aggregate metered_aggregate known aggregations are "sum", "last_during_period" and "max"
    tier_mode tier_mode known modes are "graduated" and "volume"
    metadata object
    created_at date-time
    updated_at date-time
  • ]
  • behavior string
    features object[]
  • Array [
  • id string
    name machine friendly name
    product_ids string[]
    title human friendly name
    metadata object
    created_at date-time
    updated_at date-time
  • ]
  • behavior_config object
    credit_amount int64
    seat_limit int64
    min_quantity int64
    max_quantity int64
    metadata object
    created_at date-time
    updated_at date-time
  • ]
  • interval known intervals are "day", "week", "month", and "year"
    on_start_credits int64
    trial_days int64
    metadata object
    created_at date-time
    updated_at date-time
    product object
    id string
    name string
    title string
    description string
    plan_ids string[]
    state string
    prices object[]
  • Array [
  • id string
    product_id string
    provider_id string
    name string
    interval known intervals are "day", "week", "month", and "year"
    usage_type usage_type known types are "licensed" and "metered"
    billing_scheme billing_scheme known schemes are "tiered" and "flat"
    state string
    currency currency like "usd", "eur", "gbp"
    amount int64
    metered_aggregate metered_aggregate known aggregations are "sum", "last_during_period" and "max"
    tier_mode tier_mode known modes are "graduated" and "volume"
    metadata object
    created_at date-time
    updated_at date-time
  • ]
  • behavior string
    features object[]
  • Array [
  • id string
    name machine friendly name
    product_ids string[]
    title human friendly name
    metadata object
    created_at date-time
    updated_at date-time
  • ]
  • behavior_config object
    credit_amount int64
    seat_limit int64
    min_quantity int64
    max_quantity int64
    metadata object
    created_at date-time
    updated_at date-time
Loading...