Admin API: retrieve list of available shipping methods

Topic summary

Core Issue:
Developers are seeking ways to retrieve available shipping methods via Shopify’s Admin API to display them in third-party apps, similar to the checkout interface. The initial poster successfully obtained names and prices using the admin/api/2024-10/shipping_zones.json endpoint but needs additional details like shipping method IDs and delivery times.

Solutions Discussed:

  • GraphQL Query Approach: One user shared a working GraphQL query using deliveryProfiles that retrieves shipping method definitions including IDs and names (“Standard” and “Express”).
  • Cart API Integration: Another developer working on a shipping discount app explained retrieving delivery options from the Cart GraphQL API, which returns handles and titles but not full method details.
  • Workaround Suggested: Match shipping method names from the Admin API query with handles from the Cart API’s deliveryOptions to filter and display appropriate options to users.

Current Status:
The discussion remains open with partial solutions. Developers can query method names/IDs via GraphQL but face challenges connecting Admin API data with Cart API handles for complete implementation.

Summarized with AI on November 9. AI used: claude-sonnet-4-5-20250929.

You can show the names of your shipping methods by using the query above and then pass the names to the function and filter out the handles with the same name.
Like This code:

const selectedShippingOption =
    input?.cart?.deliveryGroups[0]?.selectedDeliveryOption;

  const getPayMethod = input?.paymentMethods.find((method) => method?.name.toLocaleLowerCase().includes("cash on delivery"));

  if (selectedShippingOption?.title?.toLocaleLowerCase().includes("express")) {
    return {
      operations: [
        {
          hide: {
            paymentMethodId: getPayMethod?.id || '',
          }
        }
      ]
    }
  }