Skip to content

§00Connect

Shopify ↔ SAP S/4HANA

Shopify orders become SAP sales orders. SAP deliveries become Shopify fulfillments.

A storefront moves at checkout speed; SAP moves by document flow — sales order, delivery, goods issue, billing. Connecting them by hand means exporting orders, keying them into SAP and updating Shopify’s stock from a report that is already out of date. PartnerMCP creates each Shopify order in SAP S/4HANA through SAP’s published sales order API, publishes SAP stock to Shopify locations, turns goods issue into a Shopify fulfillment and carries refunds, returns and cancellations into SAP’s own documents.

Shopify → S/4HANA
Sandbox

You

“Create SAP orders from Shopify, synchronize inventory, fulfillment, refunds and cancellations.”

PartnerMCP· I will:

  1. Subscribe to orders/paid, orders/cancelled, refunds/create and the returns webhooks, verify every HMAC signature and de-duplicate on X-Shopify-Webhook-Id.
  2. Map each shopper to an SAP customer — one per buyer, or the shared web-sales customer your SAP team uses — and take the sales area from your rules.
  3. Create the SAP sales order in one deep insert — header, to_Item lines with Material and RequestedQuantity, and to_Partner — with the Shopify order name as PurchaseOrderByCustomer.
  4. Where prices must match SAP, simulate first: the simulation API runs pricing and availability without saving, and differences go to review.
  5. Publish stock: read SAP material stock for the plants and storage locations you map, and set Shopify’s available quantities with inventorySetQuantities — idempotent and compare-and-set.
  6. When SAP posts goods issue on the outbound delivery, create the Shopify fulfillment on the order’s fulfillment orders.
  7. Turn refunds into credit memo requests and returned goods into customer returns; cancel open orders the way your SAP process does, never by deleting them.
  8. Reconcile every day — Shopify deletes a webhook subscription after 8 consecutive failed deliveries, so nothing depends on webhooks alone.
Order placedCustomer matchSchema mappingCreate sales orderMonitor fulfillmentShipmentFulfill + trackingInventory levelsRefunds & cancellations
Integration plan: Shopify ↔ SAP S/4HANA. Shopify to SAP S/4HANA.
  1. Order placed — Shopify: Trigger · webhooks
  2. Customer match — PartnerMCP: Customer ⇄ A_BusinessPartner
  3. Schema mapping — PartnerMCP: SKUs · taxes · shipping
  4. Create sales order — SAP S/4HANA: A_SalesOrder + A_SalesOrderItem
  5. Monitor fulfillment — PartnerMCP: picking · shipping · returns
  6. Shipment — SAP S/4HANA: A_OutbDeliveryHeader
  7. Fulfill + tracking — Shopify: Fulfillment
  8. Inventory levels — Shopify: InventoryLevel
  9. Refunds & cancellations — SAP S/4HANA: API_CREDIT_MEMO_REQUEST_SRV
Product preview · sample data
§01—What syncs

What syncs, and which way.

Every record that moves between Shopify and S/4HANA: what starts it, and what it produces on the other side.

ShopifyS/4HANA
  1. Shopify to SAP S/4HANA:

    Order → A_SalesOrder + A_SalesOrderItem
    When
    orders/paid webhook, HMAC-verified
    Result
    SAP sales order by deep insert through API_SALES_ORDER_SRV; the SAP order number kept against the Shopify order.
  2. SAP S/4HANA to Shopify:

    A_MatlStkInAcctMod → InventoryLevel
    When
    Scheduled read of API_MATERIAL_STOCK_SRV for the mapped plants and storage locations
    Result
    Shopify’s available quantity set per location with inventorySetQuantities.
  3. SAP S/4HANA to Shopify:

    A_OutbDeliveryHeader → Fulfillment
    When
    Goods issue posted (PostGoodsIssue) on the outbound delivery
    Result
    fulfillmentCreate on the order’s FulfillmentOrders.
  4. Shopify to SAP S/4HANA:

    Refund → credit memo request
    When
    refunds/create webhook
    Result
    A credit memo request through API_CREDIT_MEMO_REQUEST_SRV, so SAP billing issues the credit memo.
  5. Shopify to SAP S/4HANA:

    Return → customer return
    When
    returns webhooks, when goods come back
    Result
    A customer return through API_CUSTOMER_RETURN_SRV.
  6. Shopify to SAP S/4HANA:

    Cancellation → A_SalesOrder
    When
    orders/cancelled webhook
    Result
    Open order canceled by your SAP rule; held for review once a delivery exists.
§02—Field mapping

Field by field.

Every mapping PartnerMCP proposes, with its transformation and confidence. Rules — keys, reconciliation, duplicate guards — carry no confidence: they’re decided and approved, not inferred.

Shopify ⇄ S/4HANA
Draft
  1. Order.name

    to A_SalesOrder.PurchaseOrderByCustomer

    Customer reference (#1001), checked before every create

    94% confidence
  2. Order.customer

    to A_SalesOrder.SoldToParty

    One SAP customer per shopper, or your shared web-sales customer

    85% confidence
  3. Store / market rule

    to SalesOrderType · SalesOrganization · DistributionChannel · OrganizationDivision

    Fixed per store or market; you approve the rule

    Rule
    The sales area decides pricing, tax and routing in SAP — never guessed per order.
  4. LineItem.sku

    to to_Item.Material

    Must be set up for the order’s sales area

    94% confidence
  5. LineItem.currentQuantity

    to to_Item.RequestedQuantity

    Excludes refunded and removed units

    93% confidence
    LineItem.quantity still counts removed units.
  6. LineItem.discountedUnitPriceAfterAllDiscountsSet

    to to_PricingElement (manual price condition)

    Only if your pricing procedure accepts it

    70% confidence
    Otherwise SAP prices the order and PartnerMCP reconciles it against what Shopify charged.
  7. Order.shippingAddress

    to to_Partner (ship-to party)

    Ship-to party with the delivery address

    82% confidence
  8. Order.shippingLines

    to to_PricingElement (freight) or a freight item

    Whichever your SAP setup uses

    75% confidence
  9. A_MatlStkInAcctMod · plant / storage location

    to InventoryLevel · available

    Location by location; inventorySetQuantities with changeFromQuantity

    85% confidence
  10. A_OutbDeliveryHeader · goods issue

    to Fulfillment (fulfillmentCreate)

    On the order’s FulfillmentOrders

    90% confidence
  11. Refund

    to API_CREDIT_MEMO_REQUEST_SRV

    Refunded lines and amounts → credit memo request

    85% confidence
10 field mappings · 1 rule Confidence Lower, or verify on tenant
Product preview · sample data
§03—Edge cases

Edge cases, handled.

What goes wrong between Shopify and S/4HANA in production, and what PartnerMCP does about it.

  1. 01

    Webhooks are not a ledger

    Shopify retries a failed delivery 8 times over 4 hours and then deletes a subscription created through the Admin API; deliveries come in no guaranteed order. PartnerMCP verifies X-Shopify-Hmac-SHA256, de-duplicates on X-Shopify-Webhook-Id and runs the reconciliation job Shopify recommends against the GraphQL Admin API.

  2. 02

    Stock writes must be idempotent

    Since API 2026-04, inventorySetQuantities needs an idempotency key and checks the current quantity with changeFromQuantity before it writes. PartnerMCP sends both, so a retried update never double-counts and a stale one fails safely with CHANGE_FROM_QUANTITY_STALE.

  3. 03

    Order-level discounts

    discountedUnitPriceSet leaves out order-level and code-based discounts; discountedUnitPriceAfterAllDiscountsSet includes them. When Shopify’s price stands, PartnerMCP uses discountedUnitPriceAfterAllDiscountsSet; when SAP prices the order, it reconciles SAP’s result against what the customer paid.

  4. 04

    Cancellations meet document flow

    SAP’s V4 Sales Order API can’t delete whole orders, and an order with a delivery is already part of SAP’s document flow. A Shopify cancellation becomes the cancellation your SAP process defines — never a delete — and once a delivery exists, it goes to review instead.

  5. 05

    Older orders need permission

    Shopify exposes only the last 60 days of orders by default. Bringing older ones into SAP needs the read_all_orders scope, which Shopify approves separately — PartnerMCP checks for it before planning a backfill.

  6. 06

    APIs move on both sides

    Shopify ships a new API version every quarter and supports each for at least 12 months; SAP’s Public Edition retires APIs between releases — API_OUTBOUND_DELIVERY_SRV now has a successor, API_OUTBOUND_DELIVERY_SRV_0002. PartnerMCP pins the versions it tested and plans upgrades as reviewed changes.

  7. 07

    Sale-day traffic

    Shopify limits GraphQL by calculated query cost — 100 points per second on Standard plans, up to 2,000 for enterprise — and a single query can’t exceed 1,000 points. PartnerMCP queues orders during a sale, creates them in SAP at a steady pace and runs backfills as bulk operations, which bypass query-cost limits.

§04—Questions

Questions about Shopify and S/4HANA.

Which SAP — S/4HANA, Business One or Sales Cloud?

This page covers SAP S/4HANA, in the public cloud, private cloud or on-premise. SAP Business One has a different API — the Service Layer, with webhooks since 10.0 FP 2602 — and SAP Sales Cloud is a CRM. PartnerMCP names the exact SAP product in every plan.

Does SAP’s API Policy affect a storefront integration?

SAP’s 2026 API Policy restricts autonomous AI access to SAP APIs; its FAQ puts deterministic, pre-defined call sequences outside that restriction. PartnerMCP plans and tests with AI, and what runs on every order is a reviewed, versioned integration on SAP’s Published APIs. Your SAP agreement has the final word.

Can stock come from several plants?

Yes. Each SAP plant and storage location you map feeds the Shopify location you choose; stock you don’t map isn’t published to the store.

Can Shopify’s MCP servers do this instead?

No. Shopify’s MCP surfaces are buyer-side — catalog, cart and checkout through the Universal Commerce Protocol — or developer tooling. Back-office orders, stock and fulfillment go through the GraphQL Admin API, which is what PartnerMCP uses.

Do we need Shopify Plus?

No. PartnerMCP works within your plan’s GraphQL limits — 100 cost points per second on Standard, 200 on Advanced, 1,000 on Plus — and queues work when a sale pushes past them.

§05—References

§06Build

Build this integration.

Start from this plan, or change it in your own words. PartnerMCP builds it against your Shopify and S/4HANA: sandbox first, production when you approve.