> ## Documentation Index
> Fetch the complete documentation index at: https://developers.appstle.com/llms.txt
> Use this file to discover all available pages before exploring further.

# Get delivery options for subscription contract

> Retrieves all valid delivery methods available for a specific subscription contract. Returns shipping profiles and delivery options based on the contract's delivery address and product characteristics.

**Delivery Information Returned:**
- Available shipping profiles
- Delivery methods for each profile
- Shipping rates and costs
- Delivery speed (standard, express, etc.)
- Method names and descriptions
- Eligibility based on address and products

**Filtering Behavior:**
By default, returns only delivery methods valid for the contract:
- Matches delivery address country/region
- Compatible with subscription products
- Available for contract weight/dimensions

**Include All Methods:**
Use header `X-Include-All-Methods: true` to return all delivery methods regardless of eligibility. Useful for admin UIs where you want to show all options.

**Use Cases:**
- Display delivery method selector in customer portal
- Allow customers to change shipping method
- Calculate shipping costs for subscription
- Validate delivery method during subscription updates
- Show upgrade options (standard to express)

**Common Scenarios:**

**Customer Portal - Change Delivery Speed:**
1. Call this endpoint with contractId
2. Display available methods to customer
3. Customer selects preferred method
4. Update subscription with new delivery method ID

**Subscription Creation - Delivery Selection:**
1. Get delivery options for draft contract
2. Present options during checkout/signup
3. Create subscription with selected method

**Important Notes:**
- Delivery options depend on current contract address
- Changing address may change available methods
- Costs may vary based on products in subscription
- Some methods may have minimum order requirements
- International shipping may have additional restrictions

**Authentication:** Requires X-API-Key header



## OpenAPI

````yaml /subscription/admin-api-swagger.json get /api/external/v2/data/contract-delivery-options
openapi: 3.0.1
info:
  description: >-
    Comprehensive API documentation for managing subscriptions, payments, and
    related operations. These APIs allow you to programmatically manage
    subscription lifecycles, handle payments, configure products, and integrate
    subscription functionality into your applications.
  title: Admin APIs
  version: 0.0.1
servers:
  - url: https://subscription-admin.appstle.com
security: []
tags:
  - description: >-
      Core APIs for managing the complete subscription lifecycle including
      creation, updates, pausing, resuming, and cancellation of subscriptions.
    name: Subscription Management
  - description: >-
      APIs for managing subscription payment methods, processing payments,
      handling payment retries, and updating billing information.
    name: Subscription Payments
  - description: >-
      APIs for managing subscription contracts including delivery schedules,
      pricing, order notes, billing cycles, and shipping addresses.
    name: Subscription Contracts
  - description: >-
      APIs for managing products within subscriptions including adding,
      removing, updating quantities, and swapping products.
    name: Subscription Products
  - description: >-
      APIs for handling billing operations, payment processing, and financial
      transactions related to subscriptions.
    name: Billing & Payments
  - description: >-
      APIs for managing discounts and promotional codes applied to
      subscriptions.
    name: Subscription Discounts
  - description: >-
      APIs for managing one-time add-on products that can be purchased alongside
      recurring subscription items.
    name: Subscription One-Time Products
  - description: >-
      APIs for managing subscription plans, pricing tiers, and plan
      configurations.
    name: Subscription Plans
  - description: >-
      APIs for managing customizable product boxes and bundles where customers
      can select multiple items.
    name: Build-a-Box & Bundles
  - description: >-
      APIs for managing the product catalog including product information,
      variants, and inventory.
    name: Product Catalog
  - description: >-
      APIs for managing operational settings, configurations, and administrative
      functions.
    name: Operations & Settings
  - description: >-
      APIs powering the customer-facing portal where subscribers can manage
      their own subscriptions.
    name: Customer Portal
  - description: APIs for managing customer information, profiles, and account details.
    name: Customers
  - description: >-
      APIs for retrieving aggregated subscription data, customer subscription
      history, and account-level subscription information.
    name: Subscription Data
  - description: >-
      APIs for managing delivery profiles, shipping rates, free shipping
      configuration, and delivery method options on subscriptions.
    name: Delivery & Shipping
  - description: >-
      APIs for managing storefront customization including custom CSS, theme
      settings, label translations, and merchant-defined widget configuration.
    name: Customization
  - description: >-
      APIs for configuring cancellation flows, retention offers, cancellation
      reason management, and win-back automation.
    name: Customer Retention
paths:
  /api/external/v2/data/contract-delivery-options:
    get:
      tags:
        - Subscription Data
        - Subscription Management
      summary: Get delivery options for subscription contract
      description: >-
        Retrieves all valid delivery methods available for a specific
        subscription contract. Returns shipping profiles and delivery options
        based on the contract's delivery address and product characteristics.


        **Delivery Information Returned:**

        - Available shipping profiles

        - Delivery methods for each profile

        - Shipping rates and costs

        - Delivery speed (standard, express, etc.)

        - Method names and descriptions

        - Eligibility based on address and products


        **Filtering Behavior:**

        By default, returns only delivery methods valid for the contract:

        - Matches delivery address country/region

        - Compatible with subscription products

        - Available for contract weight/dimensions


        **Include All Methods:**

        Use header `X-Include-All-Methods: true` to return all delivery methods
        regardless of eligibility. Useful for admin UIs where you want to show
        all options.


        **Use Cases:**

        - Display delivery method selector in customer portal

        - Allow customers to change shipping method

        - Calculate shipping costs for subscription

        - Validate delivery method during subscription updates

        - Show upgrade options (standard to express)


        **Common Scenarios:**


        **Customer Portal - Change Delivery Speed:**

        1. Call this endpoint with contractId

        2. Display available methods to customer

        3. Customer selects preferred method

        4. Update subscription with new delivery method ID


        **Subscription Creation - Delivery Selection:**

        1. Get delivery options for draft contract

        2. Present options during checkout/signup

        3. Create subscription with selected method


        **Important Notes:**

        - Delivery options depend on current contract address

        - Changing address may change available methods

        - Costs may vary based on products in subscription

        - Some methods may have minimum order requirements

        - International shipping may have additional restrictions


        **Authentication:** Requires X-API-Key header
      operationId: getContractDeliveryOptions
      parameters:
        - in: header
          name: X-API-Key
          required: false
          schema:
            type: string
        - description: Contract Id
          in: query
          name: contractId
          required: true
          schema:
            format: int64
            type: integer
        - in: header
          name: X-Include-All-Methods
          required: false
          schema:
            type: string
      responses:
        '200':
          content:
            application/json:
              examples:
                Success Response:
                  description: Success Response
                  value:
                    - 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
          description: Delivery options retrieved successfully
        '401':
          content:
            application/json:
              example:
                error: Invalid API key
          description: Invalid API key
        '403':
          content:
            application/json:
              example:
                error: Unauthorized access to contract
          description: Access denied - Contract belongs to different shop
        '404':
          content:
            application/json:
              example:
                error: Subscription contract not found
          description: Contract not found

````