> For the complete documentation index, see [llms.txt](https://docs.shipide.com/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.shipide.com/labels.md).

# Labels

## List labels

> Requires the labels:read scope.

```json
{"openapi":"3.1.0","info":{"title":"Shipide API","version":"1.0.0"},"servers":[{"url":"https://portal.shipide.com/api/v1"}],"security":[{"ApiKey":[]}],"components":{"securitySchemes":{"ApiKey":{"type":"http","scheme":"bearer","bearerFormat":"shipide_test_... or shipide_live_...","description":"Create scoped API keys in Portal > Account > Developer."}},"schemas":{"Label":{"type":"object","properties":{"id":{"type":"string","description":"Opaque Shipide resource ID."},"object":{"const":"label"},"shipment_id":{"type":"string","description":"Opaque Shipide resource ID."},"status":{"enum":["created","voided"]},"carrier":{"const":"shipide_sandbox"},"tracking_number":{"type":"string"},"format":{"const":"pdf"},"download_path":{"type":"string"},"charge":{"type":"object","properties":{"currency":{"const":"EUR"},"amount":{"type":"number","const":0}},"required":["currency","amount"]},"test":{"const":true},"created_at":{"type":"string","format":"date-time"},"voided_at":{"type":"string","format":"date-time"}},"required":["id","object","shipment_id","status","carrier","tracking_number","format","download_path","charge","test","created_at"]},"Error":{"type":"object","properties":{"error":{"type":"object","properties":{"code":{"type":"string"},"message":{"type":"string"},"request_id":{"type":"string"}},"required":["code","message","request_id"]}},"required":["error"]}}},"paths":{"/labels":{"get":{"operationId":"listLabels","summary":"List labels","description":"Requires the labels:read scope.","tags":["labels"],"parameters":[{"name":"limit","in":"query","schema":{"type":"integer","minimum":1,"maximum":100,"default":25}},{"name":"after","in":"query","description":"Use next_cursor from the previous page. ID order, not chronological order.","schema":{"type":"string"}}],"responses":{"200":{"description":"Success","headers":{"X-Request-Id":{"schema":{"type":"string"}},"Idempotency-Replayed":{"schema":{"type":"string","enum":["true"]},"description":"Present when returning a stored response."}},"content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"array","items":{"$ref":"#/components/schemas/Label"}},"next_cursor":{"type":["string","null"]}},"required":["data","next_cursor"]}}}},"400":{"description":"400 API error; inspect error.code and error.message.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"401 API error; inspect error.code and error.message.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"403 API error; inspect error.code and error.message.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"404 API error; inspect error.code and error.message.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"409 API error; inspect error.code and error.message.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"413":{"description":"413 API error; inspect error.code and error.message.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"415":{"description":"415 API error; inspect error.code and error.message.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"422 API error; inspect error.code and error.message.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"429 API error; inspect error.code and error.message.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"500":{"description":"500 API error; inspect error.code and error.message.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"503":{"description":"503 API error; inspect error.code and error.message.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}}}}
```

## Create a sandbox label

> Requires the labels:write scope. Sandbox only. Test PDFs are not valid postage. No charges are made.

```json
{"openapi":"3.1.0","info":{"title":"Shipide API","version":"1.0.0"},"servers":[{"url":"https://portal.shipide.com/api/v1"}],"security":[{"ApiKey":[]}],"components":{"securitySchemes":{"ApiKey":{"type":"http","scheme":"bearer","bearerFormat":"shipide_test_... or shipide_live_...","description":"Create scoped API keys in Portal > Account > Developer."}},"schemas":{"Label":{"type":"object","properties":{"id":{"type":"string","description":"Opaque Shipide resource ID."},"object":{"const":"label"},"shipment_id":{"type":"string","description":"Opaque Shipide resource ID."},"status":{"enum":["created","voided"]},"carrier":{"const":"shipide_sandbox"},"tracking_number":{"type":"string"},"format":{"const":"pdf"},"download_path":{"type":"string"},"charge":{"type":"object","properties":{"currency":{"const":"EUR"},"amount":{"type":"number","const":0}},"required":["currency","amount"]},"test":{"const":true},"created_at":{"type":"string","format":"date-time"},"voided_at":{"type":"string","format":"date-time"}},"required":["id","object","shipment_id","status","carrier","tracking_number","format","download_path","charge","test","created_at"]},"Error":{"type":"object","properties":{"error":{"type":"object","properties":{"code":{"type":"string"},"message":{"type":"string"},"request_id":{"type":"string"}},"required":["code","message","request_id"]}},"required":["error"]}}},"paths":{"/labels":{"post":{"operationId":"createLabel","summary":"Create a sandbox label","description":"Requires the labels:write scope. Sandbox only. Test PDFs are not valid postage. No charges are made.","tags":["labels"],"parameters":[{"name":"Idempotency-Key","in":"header","required":true,"description":"Persist a unique key per logical operation. Retry the identical request with the same key. Successful keys do not currently expire.","schema":{"type":"string","minLength":1,"maxLength":128}}],"responses":{"201":{"description":"Success","headers":{"X-Request-Id":{"schema":{"type":"string"}},"Idempotency-Replayed":{"schema":{"type":"string","enum":["true"]},"description":"Present when returning a stored response."}},"content":{"application/json":{"schema":{"type":"object","properties":{"data":{"$ref":"#/components/schemas/Label"}},"required":["data"]}}}},"400":{"description":"400 API error; inspect error.code and error.message.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"401 API error; inspect error.code and error.message.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"403 API error; inspect error.code and error.message.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"404 API error; inspect error.code and error.message.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"409 API error; inspect error.code and error.message.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"413":{"description":"413 API error; inspect error.code and error.message.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"415":{"description":"415 API error; inspect error.code and error.message.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"422 API error; inspect error.code and error.message.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"429 API error; inspect error.code and error.message.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"500":{"description":"500 API error; inspect error.code and error.message.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"503":{"description":"503 API error; inspect error.code and error.message.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}},"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"shipment_id":{"type":"string","description":"Opaque Shipide resource ID."},"rate_id":{"type":"string","description":"Opaque Shipide resource ID."},"format":{"type":"string","enum":["pdf"],"default":"pdf"}},"required":["shipment_id","rate_id"],"additionalProperties":false}}}}}}}}
```

## Retrieve label

> Requires the labels:read scope.

```json
{"openapi":"3.1.0","info":{"title":"Shipide API","version":"1.0.0"},"servers":[{"url":"https://portal.shipide.com/api/v1"}],"security":[{"ApiKey":[]}],"components":{"securitySchemes":{"ApiKey":{"type":"http","scheme":"bearer","bearerFormat":"shipide_test_... or shipide_live_...","description":"Create scoped API keys in Portal > Account > Developer."}},"schemas":{"Label":{"type":"object","properties":{"id":{"type":"string","description":"Opaque Shipide resource ID."},"object":{"const":"label"},"shipment_id":{"type":"string","description":"Opaque Shipide resource ID."},"status":{"enum":["created","voided"]},"carrier":{"const":"shipide_sandbox"},"tracking_number":{"type":"string"},"format":{"const":"pdf"},"download_path":{"type":"string"},"charge":{"type":"object","properties":{"currency":{"const":"EUR"},"amount":{"type":"number","const":0}},"required":["currency","amount"]},"test":{"const":true},"created_at":{"type":"string","format":"date-time"},"voided_at":{"type":"string","format":"date-time"}},"required":["id","object","shipment_id","status","carrier","tracking_number","format","download_path","charge","test","created_at"]},"Error":{"type":"object","properties":{"error":{"type":"object","properties":{"code":{"type":"string"},"message":{"type":"string"},"request_id":{"type":"string"}},"required":["code","message","request_id"]}},"required":["error"]}}},"paths":{"/labels/{id}":{"get":{"operationId":"getLabel","summary":"Retrieve label","description":"Requires the labels:read scope.","tags":["labels"],"parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string","description":"Opaque Shipide resource ID."}}],"responses":{"200":{"description":"Success","headers":{"X-Request-Id":{"schema":{"type":"string"}},"Idempotency-Replayed":{"schema":{"type":"string","enum":["true"]},"description":"Present when returning a stored response."}},"content":{"application/json":{"schema":{"type":"object","properties":{"data":{"$ref":"#/components/schemas/Label"}},"required":["data"]}}}},"400":{"description":"400 API error; inspect error.code and error.message.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"401 API error; inspect error.code and error.message.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"403 API error; inspect error.code and error.message.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"404 API error; inspect error.code and error.message.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"409 API error; inspect error.code and error.message.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"413":{"description":"413 API error; inspect error.code and error.message.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"415":{"description":"415 API error; inspect error.code and error.message.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"422 API error; inspect error.code and error.message.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"429 API error; inspect error.code and error.message.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"500":{"description":"500 API error; inspect error.code and error.message.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"503":{"description":"503 API error; inspect error.code and error.message.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}}}}
```

## Void a sandbox label

> Requires the labels:write scope.

```json
{"openapi":"3.1.0","info":{"title":"Shipide API","version":"1.0.0"},"servers":[{"url":"https://portal.shipide.com/api/v1"}],"security":[{"ApiKey":[]}],"components":{"securitySchemes":{"ApiKey":{"type":"http","scheme":"bearer","bearerFormat":"shipide_test_... or shipide_live_...","description":"Create scoped API keys in Portal > Account > Developer."}},"schemas":{"Label":{"type":"object","properties":{"id":{"type":"string","description":"Opaque Shipide resource ID."},"object":{"const":"label"},"shipment_id":{"type":"string","description":"Opaque Shipide resource ID."},"status":{"enum":["created","voided"]},"carrier":{"const":"shipide_sandbox"},"tracking_number":{"type":"string"},"format":{"const":"pdf"},"download_path":{"type":"string"},"charge":{"type":"object","properties":{"currency":{"const":"EUR"},"amount":{"type":"number","const":0}},"required":["currency","amount"]},"test":{"const":true},"created_at":{"type":"string","format":"date-time"},"voided_at":{"type":"string","format":"date-time"}},"required":["id","object","shipment_id","status","carrier","tracking_number","format","download_path","charge","test","created_at"]},"Error":{"type":"object","properties":{"error":{"type":"object","properties":{"code":{"type":"string"},"message":{"type":"string"},"request_id":{"type":"string"}},"required":["code","message","request_id"]}},"required":["error"]}}},"paths":{"/labels/{id}/void":{"post":{"operationId":"voidLabel","summary":"Void a sandbox label","description":"Requires the labels:write scope.","tags":["labels"],"parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string","description":"Opaque Shipide resource ID."}},{"name":"Idempotency-Key","in":"header","required":true,"description":"Persist a unique key per logical operation. Retry the identical request with the same key. Successful keys do not currently expire.","schema":{"type":"string","minLength":1,"maxLength":128}}],"responses":{"200":{"description":"Success","headers":{"X-Request-Id":{"schema":{"type":"string"}},"Idempotency-Replayed":{"schema":{"type":"string","enum":["true"]},"description":"Present when returning a stored response."}},"content":{"application/json":{"schema":{"type":"object","properties":{"data":{"$ref":"#/components/schemas/Label"}},"required":["data"]}}}},"400":{"description":"400 API error; inspect error.code and error.message.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"401 API error; inspect error.code and error.message.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"403 API error; inspect error.code and error.message.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"404 API error; inspect error.code and error.message.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"409 API error; inspect error.code and error.message.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"413":{"description":"413 API error; inspect error.code and error.message.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"415":{"description":"415 API error; inspect error.code and error.message.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"422 API error; inspect error.code and error.message.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"429 API error; inspect error.code and error.message.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"500":{"description":"500 API error; inspect error.code and error.message.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"503":{"description":"503 API error; inspect error.code and error.message.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}},"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{},"required":[],"additionalProperties":false}}}}}}}}
```

## Download a sandbox PDF

> Requires the labels:read scope.

```json
{"openapi":"3.1.0","info":{"title":"Shipide API","version":"1.0.0"},"servers":[{"url":"https://portal.shipide.com/api/v1"}],"security":[{"ApiKey":[]}],"components":{"securitySchemes":{"ApiKey":{"type":"http","scheme":"bearer","bearerFormat":"shipide_test_... or shipide_live_...","description":"Create scoped API keys in Portal > Account > Developer."}},"schemas":{"Error":{"type":"object","properties":{"error":{"type":"object","properties":{"code":{"type":"string"},"message":{"type":"string"},"request_id":{"type":"string"}},"required":["code","message","request_id"]}},"required":["error"]}}},"paths":{"/labels/{id}/file":{"get":{"operationId":"downloadLabel","summary":"Download a sandbox PDF","description":"Requires the labels:read scope.","tags":["labels"],"parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string","description":"Opaque Shipide resource ID."}}],"responses":{"200":{"description":"4 by 6 inch test label. Not valid for shipping.","content":{"application/pdf":{"schema":{"type":"string","format":"binary"}}}},"400":{"description":"400 API error; inspect error.code and error.message.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"401 API error; inspect error.code and error.message.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"403 API error; inspect error.code and error.message.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"404 API error; inspect error.code and error.message.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"409 API error; inspect error.code and error.message.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"413":{"description":"413 API error; inspect error.code and error.message.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"415":{"description":"415 API error; inspect error.code and error.message.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"422 API error; inspect error.code and error.message.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"429 API error; inspect error.code and error.message.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"500":{"description":"500 API error; inspect error.code and error.message.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"503":{"description":"503 API error; inspect error.code and error.message.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}}}}
```


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## Querying This Documentation
If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter, and the optional `goal` query parameter:

```
GET https://docs.shipide.com/labels.md?ask=<question>&goal=<endgoal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is optional and describes the broader end goal you are ultimately trying to accomplish on behalf of the user. GitBook uses it to tailor the answer towards what is most useful for that goal.

The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
