Skip to main content

Validate an address

POST /v2/fulfillment/lastmile/users/{user_id}/validate_address

Validates an address for a user. Send this request before you create an order to reduce the possible errors that can be returned from the order creation endpoint. When you create the order, ensure that you use the validated address.

tip

Alternatively, create a user and validate an address in one request.

Security#

NameInDescription
AuthorizationheaderThe Authorization header with the bearer token acquired during authentication.

Parameters#

NameInRequiredDescription
user_idpathโœ…The ID of the user.

Request#

FieldTypeRequiredDescription
address_line_1stringโœ…The first address line.
address_line_2stringThe second address line.
address_typestringThe type of address, e.g., "residential".
postal_codestringโœ…The postal/zip code of the address.

Request Examples#

curl --request POST \  --url 'https://connect.instacart.com/v2/fulfillment/lastmile/users/{user_id}/validate_address' \  --header 'Accept: application/json' \  --header 'Authorization: Bearer <token>' \  --header 'Content-Type: application/json' \  --data '{  "address_line_1": "string",  "address_line_2": "string",  "address_type": "string",  "postal_code": "string"}'

Response#

FieldTypeRequiredDescription
address_line_1stringโœ…The first address line.
postal_codestringโœ…The postal/zip code of the address.

Response Examples#

{  "address_line_1": "499 Gainsville",  "postal_code": "81910"}