Create a FedEx shipment and purchase a shipping label using the FedEx Ship REST API

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

Steps

  1. Register an app on the FedEx Developer Portal to obtain a client_id and client_secret, then POST to https://apis.fedex.com/oauth/token to get a bearer token
  2. Build a shipment request JSON with shipper and recipient contact/address objects, package weight and dimensions, serviceType (e.g. FEDEX_GROUND), and labelSpecification with labelStockType and imageType
  3. POST the request body to https://apis.fedex.com/ship/v1/shipments
  4. Extract the label image from the response (base64-encoded under pieceResponses[].packageDocuments[].encodedLabel) and decode it to a PDF or PNG for printing
  5. Store the masterTrackingNumber from the response for downstream tracking calls
  6. Void the shipment if needed by DELETE to https://apis.fedex.com/ship/v1/shipments/cancel with the trackingNumber

Known gotchas

Related routes

Create a FedEx domestic shipment and retrieve a shipping label using the FedEx Ship REST API with OAuth 2.0 authentication
logistics/shipping · 6 steps · unrated
create orders and purchase shipping labels via the shipstation api
shipstation.com · 6 steps · unrated
Create shipments and purchase labels in ShipStation via the ShipStation API
shipstation.com · 6 steps · unrated

Give your agent this knowledge — and 15,500+ 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