Skip to content

Customer Portal APIs (0.0.1)

Comprehensive API documentation for the customer-facing subscription portal. These APIs enable customers to manage their subscriptions, update billing information, modify delivery schedules, and access their account details through your storefront.

Important: These APIs must be called from your shop's domain (e.g., https://www.myshop.com/apps/subscriptions/cp/api/**) and require customer authentication. Unauthenticated requests will return a 401 Unauthorized error.

Languages
Servers
https://www.myshop.com/apps

Customer Portal

Core customer portal APIs for managing customer account settings, authentication, and portal configurations.

Operations

Subscription Management

APIs for customers to view and manage their subscription contracts including status updates, frequency changes, and cancellations.

Operations

Get variant contextual pricing

Request

Retrieves contextual pricing information for a product variant based on currency and country. This endpoint provides localized pricing data for international subscriptions and multi-currency support.

Pricing Information Returned:

  • Base price in specified currency
  • Compare-at price (if applicable)
  • Country-specific pricing adjustments
  • Tax information for the region
  • Currency conversion data

Parameters:

  • variantId - Shopify variant ID (required)
  • currencyCode - ISO 4217 currency code (e.g., USD, EUR, GBP) (required)
  • countryCode - ISO 3166-1 country code (e.g., US, GB, CA) (optional)

Use Cases:

  • Display localized pricing in customer portal
  • Calculate subscription totals for international customers
  • Support multi-currency subscriptions
  • Show accurate pricing based on customer location
  • Validate pricing before subscription creation

Important Notes:

  • Requires Shopify Markets or multi-currency setup
  • Prices are returned in the requested currency
  • Country-specific pricing takes precedence over currency-only pricing
  • Returns 404 if variant doesn't exist or isn't available in specified market

Authentication: Requires valid api_key parameter

Query
variantIdinteger(int64)required
countryCodestring
currencyCodestringrequired
curl -i -X GET \
  'https://www.myshop.com/apps/subscriptions/cp/api/data/variant-contextual-pricing?variantId=0&countryCode=string&currencyCode=string'

Responses

Contextual pricing retrieved successfully

Body*/*
get__typenamestring
idstring
titlestring
mediaobject(Media)
productobject(Product)
priceobject
contextualPricingobject(ContextualPricing)
skustring

Get selling plans for products

Request

Retrieves all selling plans (subscription plans) associated with a set of products. This endpoint is useful for determining which subscription options are available for specific products.

Selling Plan Information:

  • Selling plan ID and name
  • Billing and delivery frequencies
  • Pricing policies (discounts)
  • Plan description and options
  • Product associations

Use Cases:

  • Display subscription options on product pages
  • Validate subscription plan availability
  • Build subscription plan selector UI
  • Sync plan data across systems

Request:

  • Accepts multiple product IDs as comma-separated values
  • Returns aggregated selling plans from all products

Authentication: Requires valid api_key parameter

Query
productIdsArray of integers(int64)uniquerequired

Product IDs

curl -i -X GET \
  'https://www.myshop.com/apps/subscriptions/cp/api/data/products-selling-plans?productIds=0'

Responses

Selling plans retrieved successfully

Body*/*Array [
get__typenamestring
idstring
sellingPlanIdstring
sellingPlanNamestring
productIdstring
skustring
titlestring
variantIdstring
quantityinteger(int32)
customAttributesArray of objects(CustomAttribute)
lineDiscountedPriceobject(LineDiscountedPrice)
variantImageobject(VariantImage)
variantTitlestring
currentPriceobject(CurrentPrice)
discountAllocationsArray of objects(DiscountAllocation)
pricingPolicyobject(PricingPolicy)
taxableboolean
]

Get products data with pagination

Request

Retrieves paginated product catalog data from Shopify, optionally filtered by search term, selling plans, or subscription contracts. This endpoint provides access to your store's product catalog with subscription-specific information.

What This Endpoint Returns: Product information including:

  • Product ID, title, handle, and description
  • Product images and media
  • Variants with pricing and availability
  • Associated selling plans (subscription plans)
  • Product status and tags
  • Vendor and product type

Pagination: Uses cursor-based pagination for efficient data retrieval:

  • next=true - Get next page of results
  • cursor - Pagination cursor from previous response
  • Returns cursor for next page in response

Filtering Options:

  1. Search (search parameter):

    • Search by product title, description, or SKU
    • Partial matching supported
    • Case-insensitive
  2. Selling Plan Filter (sellingPlanIds parameter):

    • Filter products by subscription plans
    • Comma-separated list of selling plan IDs
    • Only returns products with specified plans
  3. Contract Filter (contractId parameter):

    • Get products available for specific subscription
    • Useful for product swap functionality
    • Returns products compatible with contract

Use Cases:

  • Display product catalog in custom subscription UI
  • Build product selection for subscription creation
  • Implement product swap functionality
  • Search products for subscription management
  • Sync product data to external systems

Authentication: Requires valid api_key parameter

Query
searchstring
nextboolean
Default false
cursorstring
contractIdinteger(int64)
sellingPlanIdsstring
sendAllDataboolean
purchaseOptionstring
curl -i -X GET \
  'https://www.myshop.com/apps/subscriptions/cp/api/data/products?search=string&next=false&cursor=string&contractId=0&sellingPlanIds=string&sendAllData=true&purchaseOption=string'

Responses

Products retrieved successfully

Body*/*
productsArray of objects(Product)
pageInfoobject(PageInfo)
productHandleDataobject

Billing & Payments

APIs for managing payment methods, billing information, and processing subscription payments.

Operations

Product Catalog

APIs for retrieving product information, selling plans, variant data, and subscription-enabled products available to customers.

Operations

Delivery & Shipping

APIs for managing delivery schedules, shipping addresses, delivery methods, and tracking order status.

Customer Retention

APIs for handling subscription cancellations, retention activities, and customer feedback management.

Loyalty Integration

APIs for integrating loyalty programs with subscriptions including points redemption and earning options.

Customization

APIs for accessing portal customization settings, translations, and theme configurations.