{"templateId":"markdown","versions":[{"version":"shipstation-v2","label":"ShipStation V2 API","link":"/apis/shipstation-v2/docs/shipping/use-a-carrier-service","default":true,"active":false,"folderId":"58c9a61d"},{"version":"shipengine","label":"ShipStation API (formerly ShipEngine)","link":"/apis/shipengine/docs/shipping/use-a-carrier-service","default":false,"active":true,"folderId":"58c9a61d"},{"version":"shipstation-v1","label":"ShipStation V1 API","link":"/apis/shipstation-v1/docs/shipping/use-a-carrier-service","default":false,"active":false,"folderId":"58c9a61d"}],"sharedDataIds":{"sidebar":"sidebar-apis/@shipengine/sidebars.yaml"},"props":{"metadata":{"markdoc":{"tagList":[]},"type":"markdown"},"seo":{"title":"Specify a Carrier Service","keywords":"shipping, labels, shipstation, documentation, api","siteUrl":"https://docs.shipstation.com","lang":"en-US","llmstxt":{"hide":false,"title":"ShipStation API LLM Docs","description":"Find links and references to all markdown documentation for use with LLMs","excludeFiles":[]}},"dynamicMarkdocComponents":[],"compilationErrors":[],"ast":{"$$mdtype":"Tag","name":"article","attributes":{},"children":[{"$$mdtype":"Tag","name":"Heading","attributes":{"level":1,"id":"specify-a-carrier-service","__idx":0},"children":["Specify a Carrier Service"]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":["A shipment must specify the carrier and service that will be used to deliver the shipment to the recipient. These values are defined by the ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["carrier_id"]}," (the carrier that will deliver the package) and ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["service_code"]}," (the service class to use for the delivery, which also determines the transit time and the cost of the label)."]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":["While this was breifly covered in the ",{"$$mdtype":"Tag","name":"a","attributes":{"href":"/apis/shipengine/docs/labels/create-a-label"},"children":["create a label guide"]},", here we'll provide a more detailed explanation about using these properties to create shipments and labels."]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":["You can retrieve the ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["carrier_id"]}," (and ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["carrier_code"]},") when you ",{"$$mdtype":"Tag","name":"a","attributes":{"href":"/apis/shipengine/docs/reference/list-carriers"},"children":["list carriers"]}," and the ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["service_code"]}," when you ",{"$$mdtype":"Tag","name":"a","attributes":{"href":"/apis/shipengine/docs/reference/list-carrier-services"},"children":["ist carrier services"]},"."]},{"$$mdtype":"Tag","name":"Heading","attributes":{"level":2,"id":"example-label-request--response","__idx":1},"children":["Example Label Request & Response"]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":["In our ",{"$$mdtype":"Tag","name":"a","attributes":{"href":"/apis/shipengine/docs/labels/create-a-label"},"children":["create a label guide"]}," example, we used UPS as the carrier and ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["ups_ground"]}," as the service. In the following example, we've determined we ",{"$$mdtype":"Tag","name":"em","attributes":{},"children":["really"]}," need to get this package to it's destination quickly, so we'll use USPS Priority Mail Express™ as the carrier and service to accomplish this."]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":[{"$$mdtype":"Tag","name":"strong","attributes":{},"children":["POST /v1/labels/"]}]},{"$$mdtype":"Tag","name":"CodeBlock","attributes":{"data-language":"http","header":{"controls":{"copy":{}}},"source":"POST /v1/labels HTTP/1.1\nHost: api.shipengine.com\nAPI-Key: __YOUR_API_KEY_HERE__\nContent-Type: application/json\n\n{\n  \"shipment\": {\n    \"carrier_id\": \"se-123890\",\n    \"service_code\": \"usps_priority_mail_express\",\n    \"ship_to\": {\n      \"name\": \"Amanda Miller\",\n      \"phone\": \"555-555-5555\",\n      \"address_line1\": \"525 S Winchester Blvd\",\n      \"city_locality\": \"San Jose\",\n      \"state_province\": \"CA\",\n      \"postal_code\": \"95128\",\n      \"country_code\": \"US\",\n      \"address_residential_indicator\": \"yes\"\n    },\n    \"ship_from\": {\n      \"company_name\": \"Example Corp.\",\n      \"name\": \"John Doe\",\n      \"phone\": \"111-111-1111\",\n      \"address_line1\": \"4009 Marathon Blvd\",\n      \"address_line2\": \"Suite 300\",\n      \"city_locality\": \"Austin\",\n      \"state_province\": \"TX\",\n      \"postal_code\": \"78756\",\n      \"country_code\": \"US\",\n      \"address_residential_indicator\": \"no\"\n    },\n    \"packages\": [\n      {\n        \"weight\": {\n          \"value\": 9.6,\n          \"unit\": \"ounce\"\n        },\n        \"dimensions\": {\n          \"unit\": \"inch\",\n          \"length\": 12.0,\n          \"width\": 7.1,\n          \"height\": 6.0\n        }\n      }\n    ]\n  }\n}\n","lang":"http"},"children":[]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":[{"$$mdtype":"Tag","name":"strong","attributes":{},"children":["Example Response"]}]},{"$$mdtype":"Tag","name":"CodeBlock","attributes":{"data-language":"json","header":{"controls":{"copy":{}}},"source":"{\n  \"label_id\": \"se-test-202923025\",\n  \"status\": \"processing\",\n  \"shipment_id\": \"se-202923025\",\n  \"ship_date\": \"2019-07-25T05:00:00.000Z\",\n  \"created_at\": \"2019-07-25T15:24:46.657Z\",\n  \"shipment_cost\": {\n    \"currency\": \"usd\",\n    \"amount\": 0.0\n  },\n  \"insurance_cost\": {\n    \"currency\": \"usd\",\n    \"amount\": 0.0\n  },\n  \"tracking_number\": \"9999999999999\",\n  \"is_return_label\": false,\n  \"is_international\": false,\n  \"batch_id\": \"\",\n  \"carrier_id\": \"se-123890\",\n  \"service_code\": \"usps_priority_mail_express\",\n  \"package_code\": \"package\",\n  \"voided\": false,\n  \"label_format\": \"pdf\",\n  \"label_layout\": \"4x6\",\n  \"trackable\": false,\n  \"carrier_code\": \"stamps_com\",\n  \"tracking_status\": \"unknown\",\n  \"label_download\": {\n    \"pdf\": \"https://api.shipengine.com/v1/downloads/6/Q2OLdnGaqk-UzkN6pFH0lg/testlabel-202923521.pdf\",\n    \"png\": \"https://api.shipengine.com/v1/downloads/6/Q2OLdnGaqk-UzkN6pFH0lg/testlabel-202923521.png\",\n    \"zpl\": \"https://api.shipengine.com/v1/downloads/6/Q2OLdnGaqk-UzkN6pFH0lg/testlabel-202923521.zpl\",\n    \"href\": \"https://api.shipengine.com/v1/downloads/6/Q2OLdnGaqk-UzkN6pFH0lg/testlabel-202923521.pdf\"\n  },\n  \"form_download\": null,\n  \"insurance_claim\": null\n}\n","lang":"json"},"children":[]}]},"headings":[{"value":"Specify a Carrier Service","id":"specify-a-carrier-service","depth":1},{"value":"Example Label Request & Response","id":"example-label-request--response","depth":2}],"frontmatter":{"seo":{"title":"Specify a Carrier Service"}},"lastModified":"2026-04-08T10:47:45.000Z","pagePropGetterError":{"message":"","name":""}},"slug":"/apis/shipengine/docs/shipping/use-a-carrier-service","userData":{"isAuthenticated":false,"teams":["anonymous"]},"isPublic":true}