Subscription Plans
Get all subscription groups
Retrieves a list of all subscription groups (selling plan groups) configured in the store. This endpoint provides a complete overview of all subscription offerings available.
Response includes:
- All subscription groups with their configurations
- Complete selling plan details for each group
- Product and variant assignments (as JSON strings)
- Discount configurations and tiers
- Member restrictions and settings
Use Cases:
- Display all subscription options in a custom interface
- Audit subscription configurations
- Export subscription data for analysis
- Synchronize with external systems
Performance Notes:
- Returns all groups in a single response (no pagination)
- Response size grows with number of groups and plans
- Product/variant lists are JSON-encoded strings within the response
Authentication: Requires valid X-API-Key header
GET
/
api
/
external
/
v2
/
subscription-groups
Get all subscription groups
curl --request GET \
--url https://subscription-admin.appstle.com/api/external/v2/subscription-groups \
--header 'X-API-Key: <x-api-key>'import requests
url = "https://subscription-admin.appstle.com/api/external/v2/subscription-groups"
headers = {"X-API-Key": "<x-api-key>"}
response = requests.get(url, headers=headers)
print(response.text)const options = {method: 'GET', headers: {'X-API-Key': '<x-api-key>'}};
fetch('https://subscription-admin.appstle.com/api/external/v2/subscription-groups', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));const url = 'https://subscription-admin.appstle.com/api/external/v2/subscription-groups';
const options = {method: 'GET', headers: {'X-API-Key': '<x-api-key>'}};
fetch(url, options)
.then(res => res.json())
.then(json => console.log(json))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://subscription-admin.appstle.com/api/external/v2/subscription-groups",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
CURLOPT_HTTPHEADER => [
"X-API-Key: <x-api-key>"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"net/http"
"io"
)
func main() {
url := "https://subscription-admin.appstle.com/api/external/v2/subscription-groups"
req, _ := http.NewRequest("GET", url, nil)
req.Header.Add("X-API-Key", "<x-api-key>")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}require 'uri'
require 'net/http'
url = URI("https://subscription-admin.appstle.com/api/external/v2/subscription-groups")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
request["X-API-Key"] = '<x-api-key>'
response = http.request(request)
puts response.read_body[
{
"groupName": "Monthly Coffee Subscription",
"id": 123456789,
"productCount": 10,
"productIds": "[{\"id\":987654321,\"title\":\"Premium Coffee Blend\",\"status\":\"ACTIVE\"}]",
"productVariantCount": 35,
"subscriptionPlans": [
{
"afterCycle1": 0,
"billingFrequencyCount": 1,
"billingFrequencyInterval": "MONTH",
"discountEnabled": true,
"discountOffer": 10,
"discountType": "PERCENTAGE",
"frequencyCount": 1,
"frequencyDescription": "Save 10% on monthly deliveries",
"frequencyInterval": "MONTH",
"frequencyName": "Delivered Monthly",
"id": "gid://shopify/SellingPlan/111111",
"inventoryPolicyReserve": "ON_SALE",
"minCycles": 3,
"planType": "PAY_AS_YOU_GO"
}
],
"variantIds": "[]"
},
{
"groupName": "Premium Tea Collection",
"id": 123456790,
"productCount": 15,
"productIds": "[{\"id\":987654324,\"title\":\"Organic Green Tea\"},{\"id\":987654325,\"title\":\"Earl Grey Premium\"}]",
"productVariantCount": 45,
"subscriptionPlans": [
{
"afterCycle1": 0,
"discountEnabled": true,
"discountOffer": 15,
"discountType": "PERCENTAGE",
"frequencyCount": 1,
"frequencyDescription": "Fresh tea every week with 15% savings",
"frequencyInterval": "WEEK",
"frequencyName": "Weekly Tea Box",
"id": "gid://shopify/SellingPlan/222222",
"planType": "PAY_AS_YOU_GO"
},
{
"afterCycle1": 0,
"discountEnabled": true,
"discountOffer": 10,
"discountType": "PERCENTAGE",
"frequencyCount": 1,
"frequencyDescription": "Monthly delivery with 10% discount",
"frequencyInterval": "MONTH",
"frequencyName": "Monthly Tea Box",
"id": "gid://shopify/SellingPlan/333333",
"planType": "PAY_AS_YOU_GO"
}
],
"variantIds": "[]"
}
]{
"detail": "Invalid or missing API key",
"status": 401,
"title": "Unauthorized",
"type": "https://example.com/errors/unauthorized"
}[
{
"accessoryProductIds": "<string>",
"deleteProducts": {
"allProduct": true,
"collectionId": "<string>",
"deleteAllProduct": true,
"productDetails": "<string>",
"productIds": [
123
],
"variantDetails": "<string>",
"variantIds": [
123
]
},
"groupName": "<string>",
"id": 123,
"productCount": 123,
"productId": "<string>",
"productIds": "<string>",
"productVariantCount": 123,
"subscriptionPlans": [
{
"afterCycle1": 123,
"afterCycle2": 123,
"appstleCycles": [
{
"afterCycle": 3,
"discountType": "PERCENTAGE",
"freeProductHandle": "free-gift-product",
"freeProductImage": "https://cdn.shopify.com/s/files/1/0000/0000/products/mug.jpg",
"freeProductTitle": "Ceramic Mug",
"freeProducts": [
{
"freeProductHandle": "free-gift-product",
"freeProductImage": "https://cdn.shopify.com/s/files/1/0000/0000/products/mug.jpg",
"freeProductTitle": "Ceramic Mug",
"freeVariantId": 42549172011164
}
],
"freeVariantId": 42549172011164,
"preventDuplicationFreeProduct": true,
"repeatingCycle": true,
"repeatingNumberOfCycle": 6,
"tierRole": "<string>",
"value": 10
}
],
"billingFrequencyCount": 123,
"billingFrequencyInterval": "DAY",
"cutOff": 123,
"defaultSelectedPlan": true,
"deliveryPolicyPreAnchorBehavior": "ASAP",
"discountEnabled": true,
"discountEnabled2": true,
"discountEnabled2Masked": true,
"discountEnabledMasked": true,
"discountOffer": 123,
"discountOffer2": 123,
"discountType": "PERCENTAGE",
"discountType2": "PERCENTAGE",
"fixedBillingDates": [
{
"day": 123,
"month": 123
}
],
"formFieldJson": "<string>",
"freeTrialCount": 123,
"freeTrialEnabled": true,
"freeTrialInterval": "DAY",
"frequencyCount": 123,
"frequencyDescription": "<string>",
"frequencyInterval": "DAY",
"frequencyName": "<string>",
"frequencyNameTranslations": {},
"frequencySequence": 123,
"frequencyType": "ON_PURCHASE_DAY",
"groupId": 123,
"groupName": "<string>",
"id": "<string>",
"idNew": "<string>",
"inventoryPolicyReserve": "ON_FULFILLMENT",
"keepOriginalNextBillingDateAfterTrial": true,
"maxCycles": 123,
"memberExclusiveTags": "<string>",
"memberInclusiveTags": "<string>",
"memberOnly": true,
"minCycles": 123,
"minQuantity": 123,
"nonMemberOnly": true,
"payAsYouGoPrepaidBillingFrequencyCount": 123,
"planType": "PAY_AS_YOU_GO",
"prepaidFlag": "<string>",
"repeatingCycle": true,
"repeatingNumberOfCycle": 123,
"specificDayEnabled": true,
"specificDayValue": 123,
"specificMonthValue": 123,
"upcomingOrderEmailBuffer": 123
}
],
"translations": "<string>",
"updateProducts": {
"allProduct": true,
"collectionId": "<string>",
"deleteAllProduct": true,
"productDetails": "<string>",
"productIds": [
123
],
"variantDetails": "<string>",
"variantIds": [
123
]
},
"variantIds": "<string>"
}
]{
"detail": "Error retrieving subscription groups from Shopify",
"status": 500,
"title": "Internal Server Error",
"type": "https://example.com/errors/internal-server-error"
}Headers
API Key for authentication
Query Parameters
API Key (Deprecated - Use X-API-Key header instead)
Response
Successfully retrieved all subscription groups
Show child attributes
Show child attributes
Show child attributes
Show child attributes
Show child attributes
Show child attributes
⌘I
Get all subscription groups
curl --request GET \
--url https://subscription-admin.appstle.com/api/external/v2/subscription-groups \
--header 'X-API-Key: <x-api-key>'import requests
url = "https://subscription-admin.appstle.com/api/external/v2/subscription-groups"
headers = {"X-API-Key": "<x-api-key>"}
response = requests.get(url, headers=headers)
print(response.text)const options = {method: 'GET', headers: {'X-API-Key': '<x-api-key>'}};
fetch('https://subscription-admin.appstle.com/api/external/v2/subscription-groups', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));const url = 'https://subscription-admin.appstle.com/api/external/v2/subscription-groups';
const options = {method: 'GET', headers: {'X-API-Key': '<x-api-key>'}};
fetch(url, options)
.then(res => res.json())
.then(json => console.log(json))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://subscription-admin.appstle.com/api/external/v2/subscription-groups",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
CURLOPT_HTTPHEADER => [
"X-API-Key: <x-api-key>"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"net/http"
"io"
)
func main() {
url := "https://subscription-admin.appstle.com/api/external/v2/subscription-groups"
req, _ := http.NewRequest("GET", url, nil)
req.Header.Add("X-API-Key", "<x-api-key>")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}require 'uri'
require 'net/http'
url = URI("https://subscription-admin.appstle.com/api/external/v2/subscription-groups")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
request["X-API-Key"] = '<x-api-key>'
response = http.request(request)
puts response.read_body[
{
"groupName": "Monthly Coffee Subscription",
"id": 123456789,
"productCount": 10,
"productIds": "[{\"id\":987654321,\"title\":\"Premium Coffee Blend\",\"status\":\"ACTIVE\"}]",
"productVariantCount": 35,
"subscriptionPlans": [
{
"afterCycle1": 0,
"billingFrequencyCount": 1,
"billingFrequencyInterval": "MONTH",
"discountEnabled": true,
"discountOffer": 10,
"discountType": "PERCENTAGE",
"frequencyCount": 1,
"frequencyDescription": "Save 10% on monthly deliveries",
"frequencyInterval": "MONTH",
"frequencyName": "Delivered Monthly",
"id": "gid://shopify/SellingPlan/111111",
"inventoryPolicyReserve": "ON_SALE",
"minCycles": 3,
"planType": "PAY_AS_YOU_GO"
}
],
"variantIds": "[]"
},
{
"groupName": "Premium Tea Collection",
"id": 123456790,
"productCount": 15,
"productIds": "[{\"id\":987654324,\"title\":\"Organic Green Tea\"},{\"id\":987654325,\"title\":\"Earl Grey Premium\"}]",
"productVariantCount": 45,
"subscriptionPlans": [
{
"afterCycle1": 0,
"discountEnabled": true,
"discountOffer": 15,
"discountType": "PERCENTAGE",
"frequencyCount": 1,
"frequencyDescription": "Fresh tea every week with 15% savings",
"frequencyInterval": "WEEK",
"frequencyName": "Weekly Tea Box",
"id": "gid://shopify/SellingPlan/222222",
"planType": "PAY_AS_YOU_GO"
},
{
"afterCycle1": 0,
"discountEnabled": true,
"discountOffer": 10,
"discountType": "PERCENTAGE",
"frequencyCount": 1,
"frequencyDescription": "Monthly delivery with 10% discount",
"frequencyInterval": "MONTH",
"frequencyName": "Monthly Tea Box",
"id": "gid://shopify/SellingPlan/333333",
"planType": "PAY_AS_YOU_GO"
}
],
"variantIds": "[]"
}
]{
"detail": "Invalid or missing API key",
"status": 401,
"title": "Unauthorized",
"type": "https://example.com/errors/unauthorized"
}[
{
"accessoryProductIds": "<string>",
"deleteProducts": {
"allProduct": true,
"collectionId": "<string>",
"deleteAllProduct": true,
"productDetails": "<string>",
"productIds": [
123
],
"variantDetails": "<string>",
"variantIds": [
123
]
},
"groupName": "<string>",
"id": 123,
"productCount": 123,
"productId": "<string>",
"productIds": "<string>",
"productVariantCount": 123,
"subscriptionPlans": [
{
"afterCycle1": 123,
"afterCycle2": 123,
"appstleCycles": [
{
"afterCycle": 3,
"discountType": "PERCENTAGE",
"freeProductHandle": "free-gift-product",
"freeProductImage": "https://cdn.shopify.com/s/files/1/0000/0000/products/mug.jpg",
"freeProductTitle": "Ceramic Mug",
"freeProducts": [
{
"freeProductHandle": "free-gift-product",
"freeProductImage": "https://cdn.shopify.com/s/files/1/0000/0000/products/mug.jpg",
"freeProductTitle": "Ceramic Mug",
"freeVariantId": 42549172011164
}
],
"freeVariantId": 42549172011164,
"preventDuplicationFreeProduct": true,
"repeatingCycle": true,
"repeatingNumberOfCycle": 6,
"tierRole": "<string>",
"value": 10
}
],
"billingFrequencyCount": 123,
"billingFrequencyInterval": "DAY",
"cutOff": 123,
"defaultSelectedPlan": true,
"deliveryPolicyPreAnchorBehavior": "ASAP",
"discountEnabled": true,
"discountEnabled2": true,
"discountEnabled2Masked": true,
"discountEnabledMasked": true,
"discountOffer": 123,
"discountOffer2": 123,
"discountType": "PERCENTAGE",
"discountType2": "PERCENTAGE",
"fixedBillingDates": [
{
"day": 123,
"month": 123
}
],
"formFieldJson": "<string>",
"freeTrialCount": 123,
"freeTrialEnabled": true,
"freeTrialInterval": "DAY",
"frequencyCount": 123,
"frequencyDescription": "<string>",
"frequencyInterval": "DAY",
"frequencyName": "<string>",
"frequencyNameTranslations": {},
"frequencySequence": 123,
"frequencyType": "ON_PURCHASE_DAY",
"groupId": 123,
"groupName": "<string>",
"id": "<string>",
"idNew": "<string>",
"inventoryPolicyReserve": "ON_FULFILLMENT",
"keepOriginalNextBillingDateAfterTrial": true,
"maxCycles": 123,
"memberExclusiveTags": "<string>",
"memberInclusiveTags": "<string>",
"memberOnly": true,
"minCycles": 123,
"minQuantity": 123,
"nonMemberOnly": true,
"payAsYouGoPrepaidBillingFrequencyCount": 123,
"planType": "PAY_AS_YOU_GO",
"prepaidFlag": "<string>",
"repeatingCycle": true,
"repeatingNumberOfCycle": 123,
"specificDayEnabled": true,
"specificDayValue": 123,
"specificMonthValue": 123,
"upcomingOrderEmailBuffer": 123
}
],
"translations": "<string>",
"updateProducts": {
"allProduct": true,
"collectionId": "<string>",
"deleteAllProduct": true,
"productDetails": "<string>",
"productIds": [
123
],
"variantDetails": "<string>",
"variantIds": [
123
]
},
"variantIds": "<string>"
}
]{
"detail": "Error retrieving subscription groups from Shopify",
"status": 500,
"title": "Internal Server Error",
"type": "https://example.com/errors/internal-server-error"
}