Update subscription delivery method
Updates the delivery method for a subscription contract, supporting standard shipping, local delivery, and customer pickup options. The delivery method determines how future orders will be fulfilled.
Delivery Method Types: The system automatically determines the type based on the subscription’s current delivery address:
- SHIPPING: Standard shipping to customer address (default)
- LOCAL: Local delivery within merchant’s delivery zones
- PICK_UP: Customer pickup at designated location
Two Ways to Update:
- Manual Parameters: Omit delivery-method-id and provide title, code, and presentment title directly. This preserves the delivery price on both legacy and market-driven shops and enables the contract’s manual price override.
- Delivery Method ID: Provide a Shopify DeliveryMethodDefinition ID or a full Market delivery-option GraphQL ID returned by the shop delivery-options catalogue.
Using Delivery Method ID: When providing a delivery-method-id:
- Legacy shops fetch the method from Shopify’s delivery profiles
- Automatically sets title, code, and presentment title
- Applies associated delivery price if defined
- DeliveryMethodDefinition IDs can be numeric or full GraphQL IDs; Market option IDs must be full GraphQL IDs
- On market-driven shops, the server resolves the selected option’s title and applies a unique current quote for the contract under its draft lock
- A missing or ambiguous live quote rejects the update without changing the contract
- Applying a live quote resumes automatic shipping price synchronization
Delivery Type Requirements:
- Standard Shipping: No additional requirements
- Local Delivery: Phone number must exist in delivery address
- Pickup: Pickup location must be configured in subscription
Price Updates:
- If using delivery-method-id with a fixed price, updates delivery price
- Manual updates don’t change the delivery price
- Price changes affect all future orders
Side Effects:
- Creates activity log entry with method details
- May remove invalid discount codes automatically
- Updates apply to all future orders immediately
- No customer notification sent
Common Use Cases:
- Switch from standard shipping to express shipping
- Change pickup location for customer convenience
- Update local delivery options based on availability
- Apply seasonal delivery methods
Important Notes:
- Cannot change the delivery type (shipping/local/pickup) - only the method within that type
- Delivery methods must be configured in Shopify’s shipping settings
- Changes don’t affect orders already in fulfillment
Authentication: Requires valid X-API-Key header
curl --request PUT \
--url https://subscription-admin.appstle.com/api/external/v2/subscription-contracts-update-delivery-method \
--header 'X-API-Key: <x-api-key>'import requests
url = "https://subscription-admin.appstle.com/api/external/v2/subscription-contracts-update-delivery-method"
headers = {"X-API-Key": "<x-api-key>"}
response = requests.put(url, headers=headers)
print(response.text)const options = {method: 'PUT', headers: {'X-API-Key': '<x-api-key>'}};
fetch('https://subscription-admin.appstle.com/api/external/v2/subscription-contracts-update-delivery-method', 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-contracts-update-delivery-method';
const options = {method: 'PUT', 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-contracts-update-delivery-method",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "PUT",
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-contracts-update-delivery-method"
req, _ := http.NewRequest("PUT", 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-contracts-update-delivery-method")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Put.new(url)
request["X-API-Key"] = '<x-api-key>'
response = http.request(request)
puts response.read_bodyHeaders
API Key for authentication
Query Parameters
Subscription contract ID to update
x >= 1Display name of the delivery method. This is what customers see. Ignored if delivery-method-id is provided.
255Internal code for the delivery method. Often same as title. Used for system identification. Ignored if delivery-method-id is provided.
255Localized version of the title for multi-language stores. Often same as title for single-language stores. Ignored if delivery-method-id is provided.
255Optional DeliveryMethodDefinition ID (numeric or full GraphQL ID), or a full Market option ID such as gid://shopify/DeliveryFlatRateOptionDefinition/123. Market-driven shops apply a current eligible quote for the selected option. Omit for a custom title/code edit that preserves the current delivery price and enables manual price override.
Response
Delivery method successfully updated
curl --request PUT \
--url https://subscription-admin.appstle.com/api/external/v2/subscription-contracts-update-delivery-method \
--header 'X-API-Key: <x-api-key>'import requests
url = "https://subscription-admin.appstle.com/api/external/v2/subscription-contracts-update-delivery-method"
headers = {"X-API-Key": "<x-api-key>"}
response = requests.put(url, headers=headers)
print(response.text)const options = {method: 'PUT', headers: {'X-API-Key': '<x-api-key>'}};
fetch('https://subscription-admin.appstle.com/api/external/v2/subscription-contracts-update-delivery-method', 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-contracts-update-delivery-method';
const options = {method: 'PUT', 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-contracts-update-delivery-method",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "PUT",
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-contracts-update-delivery-method"
req, _ := http.NewRequest("PUT", 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-contracts-update-delivery-method")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Put.new(url)
request["X-API-Key"] = '<x-api-key>'
response = http.request(request)
puts response.read_body