> For the complete documentation index, see [llms.txt](https://docs.chord.co/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.chord.co/chord-oms/api-reference/addresses.md).

# Addresses

## Get checkout address

> Retrieves a checkout's address.

```json
{"openapi":"3.0.0","info":{"title":"OMS API","version":"1.1"},"tags":[{"name":"Addresses"}],"servers":[{"url":"https://{host}/api","description":"Chord OMS instance","variables":{"host":{"default":"plant-staging.assembly-api.com","description":"Your tenant host, as configured in Chord OMS. The default is a Chord staging sandbox: replace it with your own host before making real requests."}}}],"security":[{"api-key":[]},{"order-token":[]}],"components":{"securitySchemes":{"api-key":{"type":"http","scheme":"bearer","description":"This is an admin level API token used for priviliged storefront\noperations. This should never be used in public contexts.\n"},"order-token":{"type":"apiKey","name":"X-Spree-Order-Token","in":"header","description":"This is a token that is assoicated with an order that allows operations\non that order. It is to be used as a means of authentication for guest\ncheckout sessions.\n"}},"schemas":{"address":{"type":"object","title":"Address","properties":{"id":{"type":"integer"},"name":{"type":"string"},"address1":{"type":"string"},"address2":{"type":"string","nullable":true},"city":{"type":"string"},"zipcode":{"type":"string"},"country":{"$ref":"#/components/schemas/country"},"alternative_phone":{"type":"string","nullable":true},"company":{"type":"string","nullable":true},"country_id":{"type":"integer"},"country_iso":{"type":"string"},"phone":{"type":"string","nullable":true},"state":{"$ref":"#/components/schemas/state"},"state_id":{"type":"integer"},"state_name":{"type":"string"},"state_text":{"type":"string"}}},"country":{"type":"object","properties":{"id":{"type":"integer"},"iso":{"type":"string"},"iso3":{"type":"string"},"iso_name":{"type":"string"},"name":{"type":"string"},"numcode":{"type":"integer"}},"title":"Country"},"state":{"type":"object","properties":{"id":{"type":"integer"},"name":{"type":"string"},"abbr":{"type":"string"},"country_id":{"type":"integer"}},"title":"State"}},"responses":{"invalid-api-key":{"description":"Invalid API Key provided","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"}}}}}},"not-found":{"description":"Resource is not found","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"}}}}}}}},"paths":{"/checkouts/{checkout_id}/addresses/{id}":{"get":{"summary":"Get checkout address","description":"Retrieves a checkout's address.","operationId":"get-checkout-address","tags":["Addresses"],"responses":{"200":{"description":"","content":{"application/json":{"schema":{"$ref":"#/components/schemas/address"}}}},"401":{"$ref":"#/components/responses/invalid-api-key"},"404":{"$ref":"#/components/responses/not-found"}}}}}}
```

## Update checkout address

> Updates a checkout's address.

```json
{"openapi":"3.0.0","info":{"title":"OMS API","version":"1.1"},"tags":[{"name":"Addresses"}],"servers":[{"url":"https://{host}/api","description":"Chord OMS instance","variables":{"host":{"default":"plant-staging.assembly-api.com","description":"Your tenant host, as configured in Chord OMS. The default is a Chord staging sandbox: replace it with your own host before making real requests."}}}],"security":[{"api-key":[]},{"order-token":[]}],"components":{"securitySchemes":{"api-key":{"type":"http","scheme":"bearer","description":"This is an admin level API token used for priviliged storefront\noperations. This should never be used in public contexts.\n"},"order-token":{"type":"apiKey","name":"X-Spree-Order-Token","in":"header","description":"This is a token that is assoicated with an order that allows operations\non that order. It is to be used as a means of authentication for guest\ncheckout sessions.\n"}},"schemas":{"address-input":{"type":"object","title":"Address Input","required":["address1","city"],"properties":{"name":{"type":"string","description":"The full name of the user. You must provide this field OR one of OR both of `firstname` and `lastname` for\nthe payload to be valid.\n\nThis field will override `firstname` and `lastname` if both are provided.\n"},"firstname":{"type":"string","description":"The first name of the user. This field will be ignored if `name` is provided.\n"},"lastname":{"type":"string","description":"The last name of the user. This field will be ignored if `name` is provided.\n"},"address1":{"type":"string"},"address2":{"type":"string","nullable":true},"city":{"type":"string"},"state_name":{"type":"string","description":"Either the name of the state (\"New York\") or it's abbreviation (\"NY\").\n\nThis field (or `state_id`) is required if [`/api/countries/{country_id}/states`](#/paths/list-country-states)\nreturns `\"states_required\": true` in it's body.\n"},"state_id":{"type":"integer","description":"This ID can be found by calling [`/api/countries/{country_id}/states`](#/paths/list-country-states).\n\nThis field (or `state_name`) is required if the above endpoint returns `\"states_required\": true`.\n"},"country_id":{"type":"integer","description":"This ID can be found by calling [`/api/countries`](#/paths/list-countries). Either `country_id` OR `country_iso`\nmust be provided for this payload to be valid.\n"},"country_iso":{"type":"string","description":"The [ISO 3166-1 Alpha-2 country code](https://en.wikipedia.org/wiki/List_of_ISO_3166_country_codes) that the\nuser resides in. This list can be fetched from [`/api/countries`](#/paths/list-countries), where the key is\n`iso`.\n\nThis field OR `country_id` must be provided for this payload to be valid.\n"},"zipcode":{"type":"string","nullable":true,"description":"This field is required if the country requires a ZIP code, like the United States (`233`).\n"},"phone":{"type":"string","nullable":true},"alternative_phone":{"type":"string","nullable":true},"company":{"type":"string","nullable":true}}},"address":{"type":"object","title":"Address","properties":{"id":{"type":"integer"},"name":{"type":"string"},"address1":{"type":"string"},"address2":{"type":"string","nullable":true},"city":{"type":"string"},"zipcode":{"type":"string"},"country":{"$ref":"#/components/schemas/country"},"alternative_phone":{"type":"string","nullable":true},"company":{"type":"string","nullable":true},"country_id":{"type":"integer"},"country_iso":{"type":"string"},"phone":{"type":"string","nullable":true},"state":{"$ref":"#/components/schemas/state"},"state_id":{"type":"integer"},"state_name":{"type":"string"},"state_text":{"type":"string"}}},"country":{"type":"object","properties":{"id":{"type":"integer"},"iso":{"type":"string"},"iso3":{"type":"string"},"iso_name":{"type":"string"},"name":{"type":"string"},"numcode":{"type":"integer"}},"title":"Country"},"state":{"type":"object","properties":{"id":{"type":"integer"},"name":{"type":"string"},"abbr":{"type":"string"},"country_id":{"type":"integer"}},"title":"State"}},"responses":{"invalid-api-key":{"description":"Invalid API Key provided","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"}}}}}},"not-found":{"description":"Resource is not found","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"}}}}}},"unprocessable-entity":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"errors":{"type":"object"}}}}}}}},"paths":{"/checkouts/{checkout_id}/addresses/{id}":{"patch":{"summary":"Update checkout address","description":"Updates a checkout's address.","operationId":"update-checkout-address","tags":["Addresses"],"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/address-input"}}}},"responses":{"200":{"description":"","content":{"application/json":{"schema":{"$ref":"#/components/schemas/address"}}}},"401":{"$ref":"#/components/responses/invalid-api-key"},"404":{"$ref":"#/components/responses/not-found"},"422":{"$ref":"#/components/responses/unprocessable-entity"}}}}}}
```

## Get order address

> Retrieves an order's address.

```json
{"openapi":"3.0.0","info":{"title":"OMS API","version":"1.1"},"tags":[{"name":"Addresses"}],"servers":[{"url":"https://{host}/api","description":"Chord OMS instance","variables":{"host":{"default":"plant-staging.assembly-api.com","description":"Your tenant host, as configured in Chord OMS. The default is a Chord staging sandbox: replace it with your own host before making real requests."}}}],"security":[{"api-key":[]},{"order-token":[]}],"components":{"securitySchemes":{"api-key":{"type":"http","scheme":"bearer","description":"This is an admin level API token used for priviliged storefront\noperations. This should never be used in public contexts.\n"},"order-token":{"type":"apiKey","name":"X-Spree-Order-Token","in":"header","description":"This is a token that is assoicated with an order that allows operations\non that order. It is to be used as a means of authentication for guest\ncheckout sessions.\n"}},"schemas":{"address":{"type":"object","title":"Address","properties":{"id":{"type":"integer"},"name":{"type":"string"},"address1":{"type":"string"},"address2":{"type":"string","nullable":true},"city":{"type":"string"},"zipcode":{"type":"string"},"country":{"$ref":"#/components/schemas/country"},"alternative_phone":{"type":"string","nullable":true},"company":{"type":"string","nullable":true},"country_id":{"type":"integer"},"country_iso":{"type":"string"},"phone":{"type":"string","nullable":true},"state":{"$ref":"#/components/schemas/state"},"state_id":{"type":"integer"},"state_name":{"type":"string"},"state_text":{"type":"string"}}},"country":{"type":"object","properties":{"id":{"type":"integer"},"iso":{"type":"string"},"iso3":{"type":"string"},"iso_name":{"type":"string"},"name":{"type":"string"},"numcode":{"type":"integer"}},"title":"Country"},"state":{"type":"object","properties":{"id":{"type":"integer"},"name":{"type":"string"},"abbr":{"type":"string"},"country_id":{"type":"integer"}},"title":"State"}},"responses":{"invalid-api-key":{"description":"Invalid API Key provided","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"}}}}}},"not-found":{"description":"Resource is not found","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"}}}}}}}},"paths":{"/orders/{order_number}/addresses/{id}":{"get":{"summary":"Get order address","description":"Retrieves an order's address.","operationId":"get-order-address","tags":["Addresses"],"responses":{"200":{"description":"","content":{"application/json":{"schema":{"$ref":"#/components/schemas/address"}}}},"401":{"$ref":"#/components/responses/invalid-api-key"},"404":{"$ref":"#/components/responses/not-found"}}}}}}
```

## Update order address

> Updates an order's address.

```json
{"openapi":"3.0.0","info":{"title":"OMS API","version":"1.1"},"tags":[{"name":"Addresses"}],"servers":[{"url":"https://{host}/api","description":"Chord OMS instance","variables":{"host":{"default":"plant-staging.assembly-api.com","description":"Your tenant host, as configured in Chord OMS. The default is a Chord staging sandbox: replace it with your own host before making real requests."}}}],"security":[{"api-key":[]},{"order-token":[]}],"components":{"securitySchemes":{"api-key":{"type":"http","scheme":"bearer","description":"This is an admin level API token used for priviliged storefront\noperations. This should never be used in public contexts.\n"},"order-token":{"type":"apiKey","name":"X-Spree-Order-Token","in":"header","description":"This is a token that is assoicated with an order that allows operations\non that order. It is to be used as a means of authentication for guest\ncheckout sessions.\n"}},"schemas":{"address-input":{"type":"object","title":"Address Input","required":["address1","city"],"properties":{"name":{"type":"string","description":"The full name of the user. You must provide this field OR one of OR both of `firstname` and `lastname` for\nthe payload to be valid.\n\nThis field will override `firstname` and `lastname` if both are provided.\n"},"firstname":{"type":"string","description":"The first name of the user. This field will be ignored if `name` is provided.\n"},"lastname":{"type":"string","description":"The last name of the user. This field will be ignored if `name` is provided.\n"},"address1":{"type":"string"},"address2":{"type":"string","nullable":true},"city":{"type":"string"},"state_name":{"type":"string","description":"Either the name of the state (\"New York\") or it's abbreviation (\"NY\").\n\nThis field (or `state_id`) is required if [`/api/countries/{country_id}/states`](#/paths/list-country-states)\nreturns `\"states_required\": true` in it's body.\n"},"state_id":{"type":"integer","description":"This ID can be found by calling [`/api/countries/{country_id}/states`](#/paths/list-country-states).\n\nThis field (or `state_name`) is required if the above endpoint returns `\"states_required\": true`.\n"},"country_id":{"type":"integer","description":"This ID can be found by calling [`/api/countries`](#/paths/list-countries). Either `country_id` OR `country_iso`\nmust be provided for this payload to be valid.\n"},"country_iso":{"type":"string","description":"The [ISO 3166-1 Alpha-2 country code](https://en.wikipedia.org/wiki/List_of_ISO_3166_country_codes) that the\nuser resides in. This list can be fetched from [`/api/countries`](#/paths/list-countries), where the key is\n`iso`.\n\nThis field OR `country_id` must be provided for this payload to be valid.\n"},"zipcode":{"type":"string","nullable":true,"description":"This field is required if the country requires a ZIP code, like the United States (`233`).\n"},"phone":{"type":"string","nullable":true},"alternative_phone":{"type":"string","nullable":true},"company":{"type":"string","nullable":true}}},"address":{"type":"object","title":"Address","properties":{"id":{"type":"integer"},"name":{"type":"string"},"address1":{"type":"string"},"address2":{"type":"string","nullable":true},"city":{"type":"string"},"zipcode":{"type":"string"},"country":{"$ref":"#/components/schemas/country"},"alternative_phone":{"type":"string","nullable":true},"company":{"type":"string","nullable":true},"country_id":{"type":"integer"},"country_iso":{"type":"string"},"phone":{"type":"string","nullable":true},"state":{"$ref":"#/components/schemas/state"},"state_id":{"type":"integer"},"state_name":{"type":"string"},"state_text":{"type":"string"}}},"country":{"type":"object","properties":{"id":{"type":"integer"},"iso":{"type":"string"},"iso3":{"type":"string"},"iso_name":{"type":"string"},"name":{"type":"string"},"numcode":{"type":"integer"}},"title":"Country"},"state":{"type":"object","properties":{"id":{"type":"integer"},"name":{"type":"string"},"abbr":{"type":"string"},"country_id":{"type":"integer"}},"title":"State"}},"responses":{"invalid-api-key":{"description":"Invalid API Key provided","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"}}}}}},"not-found":{"description":"Resource is not found","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"}}}}}},"unprocessable-entity":{"description":"Unprocessable Entity","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"errors":{"type":"object"}}}}}}}},"paths":{"/orders/{order_number}/addresses/{id}":{"patch":{"summary":"Update order address","description":"Updates an order's address.","operationId":"update-order-address","requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/address-input"}}}},"tags":["Addresses"],"responses":{"200":{"description":"","content":{"application/json":{"schema":{"$ref":"#/components/schemas/address"}}}},"401":{"$ref":"#/components/responses/invalid-api-key"},"404":{"$ref":"#/components/responses/not-found"},"422":{"$ref":"#/components/responses/unprocessable-entity"}}}}}}
```


---

# 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 by asking a question.

Perform an HTTP GET request on the following URL with the `ask` and `goal` query parameters:

```
GET https://docs.chord.co/chord-oms/api-reference/addresses.md?ask=<question>&goal=<user_goal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is what the user is ultimately trying to achieve, the reason they need the answer. Sharing it helps GitBook give you a better, more relevant answer. A goal is most helpful when it describes the outcome the user wants rather than restating the question. For example, with `ask=how do I create an API token`, a goal like `automate deployments from our CI pipeline` lets GitBook tailor the answer to that use case.

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.
