Register a synthetic shopper
POST/shoppers
RegisterShopper. The email is unique, compared case-insensitively; a duplicate is refused with 409 shopper-exists (ErrShopperExists).
Request
Responses
- 201
- 400
- 409
- 422
Shopper registered.
Response Headers
Relative URI of the registered shopper, /shoppers/{shopperId}.
"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.
The request is not valid JSON, has an unknown field contains a NUL character or is larger than 64 KiB (malformed-request; there is no 413), or the Idempotency-Key header is missing (idempotency-key-required) or is not 1 to 128 printable ASCII characters (idempotency-key-invalid).
shopper-exists (ErrShopperExists; stored under the Idempotency-Key, the e-mail stays taken), or the Idempotency-Key was already used with a different request (idempotency-key-reused).
The body is well-formed JSON but breaks a value-object rule, or names a shopper or a saved address that does not exist (validation-failed). Not stored under the Idempotency-Key, so a retry with the same key runs again.