Skip to main content

Documentation Index

Fetch the complete documentation index at: https://appstleinc-aeca3e0a.mintlify.app/llms.txt

Use this file to discover all available pages before exploring further.

This guide walks you through the three steps needed to make your first successful API call: creating an API key, sending an authenticated request, and reading the response. By the end you will have verified that your credentials work and seen what subscription data looks like.
You need an active Appstle Subscriptions installation on a Shopify store to follow this guide. If you do not have one yet, install the app from the Shopify App Store first.

Step 1 — Get your API key

1

Navigate to API Key Management

Log in to your Appstle admin panel and go to Settings → API Key Management.
2

Create a key

Click Create New Key. Give it a name like Quickstart Test so you can identify it later.
3

Copy the key

The key is shown only once. Copy it now — you cannot retrieve it again. It will look like apst_abc123....
Keep this key secret. Do not commit it to source control or include it in client-side code. For production use, store it in an environment variable or a secrets manager.

Step 2 — Make your first request

The simplest useful call checks whether a specific customer has any active subscriptions. Replace YOUR_API_KEY with your key and CUSTOMER_ID with a numeric Shopify customer ID from your store.
curl -X GET \
  "https://subscription-admin.appstle.com/api/external/v2/subscription-customers/valid/CUSTOMER_ID" \
  -H "X-API-Key: YOUR_API_KEY"

Step 3 — Check the response

A successful response returns an HTTP 200 with a JSON array of Shopify subscription contract IDs for that customer:
[5234567890, 5234567891]
An empty array means the customer has no active subscriptions. If you receive a 401, double-check that you copied the API key correctly and that it has not been revoked.
ResponseMeaning
200 with arrayCustomer has subscriptions — the array contains their contract IDs
200 with []Customer exists but has no active subscriptions
401API key is missing or invalid
404No customer found with that ID

Step 4 — Retrieve full subscription details

Now that you have a contract ID, you can fetch the complete details for that subscription:
curl -X GET \
  "https://subscription-admin.appstle.com/api/external/v2/subscription-contract-details?contractId=5234567890" \
  -H "X-API-Key: YOUR_API_KEY"
The response includes the subscription status, next billing date, products, customer details, shipping address, payment method, and applied discounts.

What’s next?

Integration guide

Full walkthrough of subscription management, product operations, discounts, shipping, and more.

Webhooks

Receive real-time notifications when subscriptions change.

Shopify Flow

Automate subscription workflows without writing backend code.