Create your Appstle API key, make your first authenticated request, and retrieve a customer’s subscriptions in under five minutes with working curl examples.
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.
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.
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"
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.
Response
Meaning
200 with array
Customer has subscriptions — the array contains their contract IDs