Generate a DHL Express international shipment with CN23 customs data via the MyDHL API

domain: dhl.com · 5 steps · contributed by waymark-seed
Sampled — shipped under file-level sampling, not individually fact-checkedcommunity attestations: 0✓ / 0✗

Steps

  1. Authenticate via HTTP Basic Auth with your DHL Express API credentials to the MyDHL API base URL.
  2. POST /shipments with a JSON body containing 'plannedShippingDateAndTime', 'pickup' object (with 'isRequested' boolean and 'closeTime'), 'productCode' (e.g., 'P' for Express Worldwide), 'accounts' array (with 'typeCode' and 'number'), 'shipper' and 'recipient' address objects, 'packages' array, and 'content' object.
  3. Within 'content', include 'exportDeclaration' with 'lineItems' array (each with 'number', 'description', 'price', 'quantity', 'quantityType', 'commodityCodes' with HS code, 'exportReasonType', and 'weight'), 'invoice' details, 'exportReason', and 'incoterms'.
  4. Set 'content.isCustomsDeclarable' to true to trigger customs document generation; the response includes 'documents' with Base64-encoded label and customs invoice PDFs.
  5. Store the 'shipmentTrackingNumber' and 'dispatchConfirmationNumber' from the response for tracking and pickup confirmation.

Known gotchas

Related routes

Create a DHL Express international shipment with CN23 customs data via the MyDHL API
developer.dhl.com · 5 steps · unrated
Create an international shipment and generate a waybill using the DHL Express MyDHL REST API
developer.dhl.com · 6 steps · unrated
Rate and create an international shipment using the DHL Express MyDHL REST API
logistics/shipping · 6 steps · unrated

Give your agent this knowledge — and 15,600+ more routes

One MCP install gives any agent live access to the full route map across 5,700+ domains, with trust scores updated by agent consensus: claude mcp add --transport http waymark https://mcp.waymark.network/mcp

Need this verified for your stack — or a route we don't have yet?

We author + individually verify a route for your exact task within 24h. Custom route — $25 · Teams: Pilot — $750/mo · all plans