Skip to main content
GET
/
api
/
external
/
v2
/
data
/
contract-delivery-options
Get delivery options for subscription contract
curl --request GET \
  --url https://subscription-admin.appstle.com/api/external/v2/data/contract-delivery-options
import requests

url = "https://subscription-admin.appstle.com/api/external/v2/data/contract-delivery-options"

response = requests.get(url)

print(response.text)
const options = {method: 'GET'};

fetch('https://subscription-admin.appstle.com/api/external/v2/data/contract-delivery-options', 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/data/contract-delivery-options';
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://subscription-admin.appstle.com/api/external/v2/data/contract-delivery-options",
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://subscription-admin.appstle.com/api/external/v2/data/contract-delivery-options"

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://subscription-admin.appstle.com/api/external/v2/data/contract-delivery-options")

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
[
  {
    "methods": [
      {
        "code": "STANDARD",
        "currency": "USD",
        "id": "method_123",
        "name": "Standard Delivery (5-7 days)",
        "price": "5.99"
      },
      {
        "code": "EXPRESS",
        "currency": "USD",
        "id": "method_124",
        "name": "Express Delivery (2-3 days)",
        "price": "12.99"
      }
    ],
    "profileId": 12345,
    "profileName": "Standard Shipping"
  }
]
{
"error": "Invalid API key"
}
{
"error": "Unauthorized access to contract"
}
{
"error": "Subscription contract not found"
}

Headers

X-API-Key
string
X-Include-All-Methods
string

Query Parameters

contractId
integer<int64>
required

Contract Id

Response

Delivery options retrieved successfully