Skip to main content

Save an address on a shopper

POST 

/shoppers/:shopperId/addresses

AddSavedAddress. The addressId derives from the Idempotency-Key, so a replay (even after the idempotency record expired) returns the same address. A shopper holds at most 20 saved addresses; the twenty-first is 422 too-many-addresses (ErrTooManyAddresses). A checkout can then name the address by its id (CheckoutRequest.shipToAddressId) and the address is copied into the order at placement.

Request​

Responses​

Address saved.

Response Headers
    Location

    Relative URI of the saved address, /shoppers/{shopperId}/addresses/{addressId}.

    Idempotency-Replayed

    "true" when the answer is the stored one of an earlier request with the same Idempotency-Key (a stored 2xx or a stored final 4xx answer, replayed with its original status and body); absent on the first execution. A refusal that a retry could pass (a RETRYABLE problem type, see the Idempotency-Key parameter) and a 5xx are never stored.