Membership Contracts
Get billing interval options for selling plans
Retrieves available billing frequency/interval options for specified Shopify selling plans (membership plans). This endpoint returns all configured billing frequencies that customers can choose from for their memberships.
Key Information Returned:
- Frequency Options: List of available billing intervals (e.g., weekly, monthly, quarterly)
- Interval Units: Time unit for each option (DAYS, WEEKS, MONTHS, YEARS)
- Interval Count: Number of units between billings (e.g., 2 = every 2 weeks)
- Display Names: Customer-friendly names for each frequency option
- Plan IDs: Associated selling plan IDs for each frequency
Billing Frequency Structure: Each FrequencyInfoDTO contains:
- id: Selling plan ID (Shopify membership plan identifier)
- name: Display name (e.g., “Deliver every 2 weeks”, “Monthly membership”)
- intervalUnit: Time unit (DAY, WEEK, MONTH, YEAR)
- intervalCount: Number of units between deliveries
- billingPolicy: How billing is configured (EXACT_DAY, ANNIVERSARY)
- deliveryPolicy: How delivery is scheduled
Common Billing Intervals:
- Weekly: intervalUnit=WEEK, intervalCount=1
- Bi-Weekly: intervalUnit=WEEK, intervalCount=2
- Monthly: intervalUnit=MONTH, intervalCount=1
- Every 2 Months: intervalUnit=MONTH, intervalCount=2
- Quarterly: intervalUnit=MONTH, intervalCount=3
- Semi-Annual: intervalUnit=MONTH, intervalCount=6
- Annual: intervalUnit=YEAR, intervalCount=1
Request Parameters:
- sellingPlanIds: Comma-separated list of Shopify selling plan IDs (required)
- Example: “123456,123457,123458”
- Returns frequency options for all specified plans
Common Use Cases:
- Display available billing frequencies in customer portal
- Allow customers to change membership delivery frequency
- Build frequency selector UI components
- Validate frequency options before updating membership
- Sync available billing options with external systems
- Show frequency options during membership checkout
Integration Example:
- Get customer’s current membership selling plan ID
- Call this endpoint with that selling plan ID
- Display returned frequency options to customer
- Customer selects new frequency
- Update membership with selected frequency
Authentication: Requires API key authentication via X-API-Key header or api_key parameter
GET
/
api
/
external
/
v2
/
subscription-contract-details
/
billing-interval
Get billing interval options for selling plans
curl --request GET \
--url https://membership-admin.appstle.com/api/external/v2/subscription-contract-details/billing-intervalimport requests
url = "https://membership-admin.appstle.com/api/external/v2/subscription-contract-details/billing-interval"
response = requests.get(url)
print(response.text)const options = {method: 'GET'};
fetch('https://membership-admin.appstle.com/api/external/v2/subscription-contract-details/billing-interval', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));const url = 'https://membership-admin.appstle.com/api/external/v2/subscription-contract-details/billing-interval';
const options = {method: 'GET'};
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://membership-admin.appstle.com/api/external/v2/subscription-contract-details/billing-interval",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
]);
$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://membership-admin.appstle.com/api/external/v2/subscription-contract-details/billing-interval"
req, _ := http.NewRequest("GET", url, nil)
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://membership-admin.appstle.com/api/external/v2/subscription-contract-details/billing-interval")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
response = http.request(request)
puts response.read_body{
"afterCycle1": 123,
"afterCycle2": 123,
"allowedForUpgradeDowngrade": true,
"billingFrequencyCount": 123,
"billingFrequencyInterval": "DAY",
"cutOff": 123,
"deliveryPolicyPreAnchorBehavior": "ASAP",
"discountEnabled": true,
"discountEnabled2": true,
"discountEnabled2Masked": true,
"discountEnabledMasked": true,
"discountOffer": 123,
"discountOffer2": 123,
"discountType": "PERCENTAGE",
"discountType2": "PERCENTAGE",
"freeTrialCount": 123,
"freeTrialEnabled": true,
"freeTrialInterval": "DAY",
"frequencyCount": 123,
"frequencyDescription": "<string>",
"frequencyInterval": "DAY",
"frequencyName": "<string>",
"frequencyType": "ON_PURCHASE_DAY",
"groupId": 123,
"groupName": "<string>",
"id": "<string>",
"idNew": "<string>",
"keepOriginalNextBillingDateAfterTrial": true,
"lifeTimeMembership": true,
"maxCycles": 123,
"memberExclusiveTags": "<string>",
"memberInclusiveTags": "<string>",
"memberOnly": true,
"minCycles": 123,
"nonMemberOnly": true,
"planSequence": 123,
"planType": "PAY_AS_YOU_GO",
"prepaidFlag": "<string>",
"rulesJson": "<string>",
"specificDayEnabled": true,
"specificDayValue": 123,
"specificMonthValue": 123
}[
{
"afterCycle1": 123,
"afterCycle2": 123,
"allowedForUpgradeDowngrade": true,
"billingFrequencyCount": 123,
"billingFrequencyInterval": "DAY",
"cutOff": 123,
"deliveryPolicyPreAnchorBehavior": "ASAP",
"discountEnabled": true,
"discountEnabled2": true,
"discountEnabled2Masked": true,
"discountEnabledMasked": true,
"discountOffer": 123,
"discountOffer2": 123,
"discountType": "PERCENTAGE",
"discountType2": "PERCENTAGE",
"freeTrialCount": 123,
"freeTrialEnabled": true,
"freeTrialInterval": "DAY",
"frequencyCount": 123,
"frequencyDescription": "<string>",
"frequencyInterval": "DAY",
"frequencyName": "<string>",
"frequencyType": "ON_PURCHASE_DAY",
"groupId": 123,
"groupName": "<string>",
"id": "<string>",
"idNew": "<string>",
"keepOriginalNextBillingDateAfterTrial": true,
"lifeTimeMembership": true,
"maxCycles": 123,
"memberExclusiveTags": "<string>",
"memberInclusiveTags": "<string>",
"memberOnly": true,
"minCycles": 123,
"nonMemberOnly": true,
"planSequence": 123,
"planType": "PAY_AS_YOU_GO",
"prepaidFlag": "<string>",
"rulesJson": "<string>",
"specificDayEnabled": true,
"specificDayValue": 123,
"specificMonthValue": 123
}
][
{
"afterCycle1": 123,
"afterCycle2": 123,
"allowedForUpgradeDowngrade": true,
"billingFrequencyCount": 123,
"billingFrequencyInterval": "DAY",
"cutOff": 123,
"deliveryPolicyPreAnchorBehavior": "ASAP",
"discountEnabled": true,
"discountEnabled2": true,
"discountEnabled2Masked": true,
"discountEnabledMasked": true,
"discountOffer": 123,
"discountOffer2": 123,
"discountType": "PERCENTAGE",
"discountType2": "PERCENTAGE",
"freeTrialCount": 123,
"freeTrialEnabled": true,
"freeTrialInterval": "DAY",
"frequencyCount": 123,
"frequencyDescription": "<string>",
"frequencyInterval": "DAY",
"frequencyName": "<string>",
"frequencyType": "ON_PURCHASE_DAY",
"groupId": 123,
"groupName": "<string>",
"id": "<string>",
"idNew": "<string>",
"keepOriginalNextBillingDateAfterTrial": true,
"lifeTimeMembership": true,
"maxCycles": 123,
"memberExclusiveTags": "<string>",
"memberInclusiveTags": "<string>",
"memberOnly": true,
"minCycles": 123,
"nonMemberOnly": true,
"planSequence": 123,
"planType": "PAY_AS_YOU_GO",
"prepaidFlag": "<string>",
"rulesJson": "<string>",
"specificDayEnabled": true,
"specificDayValue": 123,
"specificMonthValue": 123
}
]Headers
Query Parameters
API Key (Deprecated - Use Header X-API-Key instead)
Comma-separated list of Shopify selling plan IDs
Response
Billing interval options successfully retrieved
Available options:
DAY, WEEK, MONTH, YEAR Available options:
ASAP, NEXT, $UNKNOWN Available options:
PERCENTAGE, FIXED, PRICE Available options:
PERCENTAGE, FIXED, PRICE Available options:
DAY, WEEK, MONTH, YEAR Available options:
DAY, WEEK, MONTH, YEAR Available options:
ON_PURCHASE_DAY, ON_SPECIFIC_DAY Available options:
PAY_AS_YOU_GO, PREPAID, ADVANCED_PREPAID ⌘I
Get billing interval options for selling plans
curl --request GET \
--url https://membership-admin.appstle.com/api/external/v2/subscription-contract-details/billing-intervalimport requests
url = "https://membership-admin.appstle.com/api/external/v2/subscription-contract-details/billing-interval"
response = requests.get(url)
print(response.text)const options = {method: 'GET'};
fetch('https://membership-admin.appstle.com/api/external/v2/subscription-contract-details/billing-interval', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));const url = 'https://membership-admin.appstle.com/api/external/v2/subscription-contract-details/billing-interval';
const options = {method: 'GET'};
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://membership-admin.appstle.com/api/external/v2/subscription-contract-details/billing-interval",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
]);
$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://membership-admin.appstle.com/api/external/v2/subscription-contract-details/billing-interval"
req, _ := http.NewRequest("GET", url, nil)
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://membership-admin.appstle.com/api/external/v2/subscription-contract-details/billing-interval")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
response = http.request(request)
puts response.read_body{
"afterCycle1": 123,
"afterCycle2": 123,
"allowedForUpgradeDowngrade": true,
"billingFrequencyCount": 123,
"billingFrequencyInterval": "DAY",
"cutOff": 123,
"deliveryPolicyPreAnchorBehavior": "ASAP",
"discountEnabled": true,
"discountEnabled2": true,
"discountEnabled2Masked": true,
"discountEnabledMasked": true,
"discountOffer": 123,
"discountOffer2": 123,
"discountType": "PERCENTAGE",
"discountType2": "PERCENTAGE",
"freeTrialCount": 123,
"freeTrialEnabled": true,
"freeTrialInterval": "DAY",
"frequencyCount": 123,
"frequencyDescription": "<string>",
"frequencyInterval": "DAY",
"frequencyName": "<string>",
"frequencyType": "ON_PURCHASE_DAY",
"groupId": 123,
"groupName": "<string>",
"id": "<string>",
"idNew": "<string>",
"keepOriginalNextBillingDateAfterTrial": true,
"lifeTimeMembership": true,
"maxCycles": 123,
"memberExclusiveTags": "<string>",
"memberInclusiveTags": "<string>",
"memberOnly": true,
"minCycles": 123,
"nonMemberOnly": true,
"planSequence": 123,
"planType": "PAY_AS_YOU_GO",
"prepaidFlag": "<string>",
"rulesJson": "<string>",
"specificDayEnabled": true,
"specificDayValue": 123,
"specificMonthValue": 123
}[
{
"afterCycle1": 123,
"afterCycle2": 123,
"allowedForUpgradeDowngrade": true,
"billingFrequencyCount": 123,
"billingFrequencyInterval": "DAY",
"cutOff": 123,
"deliveryPolicyPreAnchorBehavior": "ASAP",
"discountEnabled": true,
"discountEnabled2": true,
"discountEnabled2Masked": true,
"discountEnabledMasked": true,
"discountOffer": 123,
"discountOffer2": 123,
"discountType": "PERCENTAGE",
"discountType2": "PERCENTAGE",
"freeTrialCount": 123,
"freeTrialEnabled": true,
"freeTrialInterval": "DAY",
"frequencyCount": 123,
"frequencyDescription": "<string>",
"frequencyInterval": "DAY",
"frequencyName": "<string>",
"frequencyType": "ON_PURCHASE_DAY",
"groupId": 123,
"groupName": "<string>",
"id": "<string>",
"idNew": "<string>",
"keepOriginalNextBillingDateAfterTrial": true,
"lifeTimeMembership": true,
"maxCycles": 123,
"memberExclusiveTags": "<string>",
"memberInclusiveTags": "<string>",
"memberOnly": true,
"minCycles": 123,
"nonMemberOnly": true,
"planSequence": 123,
"planType": "PAY_AS_YOU_GO",
"prepaidFlag": "<string>",
"rulesJson": "<string>",
"specificDayEnabled": true,
"specificDayValue": 123,
"specificMonthValue": 123
}
][
{
"afterCycle1": 123,
"afterCycle2": 123,
"allowedForUpgradeDowngrade": true,
"billingFrequencyCount": 123,
"billingFrequencyInterval": "DAY",
"cutOff": 123,
"deliveryPolicyPreAnchorBehavior": "ASAP",
"discountEnabled": true,
"discountEnabled2": true,
"discountEnabled2Masked": true,
"discountEnabledMasked": true,
"discountOffer": 123,
"discountOffer2": 123,
"discountType": "PERCENTAGE",
"discountType2": "PERCENTAGE",
"freeTrialCount": 123,
"freeTrialEnabled": true,
"freeTrialInterval": "DAY",
"frequencyCount": 123,
"frequencyDescription": "<string>",
"frequencyInterval": "DAY",
"frequencyName": "<string>",
"frequencyType": "ON_PURCHASE_DAY",
"groupId": 123,
"groupName": "<string>",
"id": "<string>",
"idNew": "<string>",
"keepOriginalNextBillingDateAfterTrial": true,
"lifeTimeMembership": true,
"maxCycles": 123,
"memberExclusiveTags": "<string>",
"memberInclusiveTags": "<string>",
"memberOnly": true,
"minCycles": 123,
"nonMemberOnly": true,
"planSequence": 123,
"planType": "PAY_AS_YOU_GO",
"prepaidFlag": "<string>",
"rulesJson": "<string>",
"specificDayEnabled": true,
"specificDayValue": 123,
"specificMonthValue": 123
}
]