{"openapi":"3.1.0","info":{"title":"Products and Customers","version":"1.0.0","description":"API reference for storing a seller's product catalogue and customer records: create, list, update and delete products and customers, authenticated with a JWT from `POST /auth/token`."},"servers":[{"url":"https://payme-store-staging.payme.io/api","description":"Sandbox"},{"url":"https://payme-store.payme.io/api","description":"Production"}],"components":{"securitySchemes":{"bearerAuth":{"type":"http","scheme":"bearer"},"partnerKey":{"type":"apiKey","in":"header","name":"PayMe-Partner-Key"},"merchantKey":{"type":"apiKey","in":"header","name":"PayMe-Merchant-Key"}}},"tags":[{"name":"Customers"}],"paths":{"/customers":{"get":{"security":[{"bearerAuth":[]}],"operationId":"get-customers","summary":"List customers","tags":["Customers"],"description":"Lists the seller's customers, one page at a time. `page` and `items_per_page` are required. Filter by status, name, email, phone or creation date, or search across the names, the email and the `guid`. Sort by first name, last name, email or creation date; without `sort_by` the order isn't defined.\n\nPass the date range in deep-object form, e.g. `?created_at[from]=2026-01-01&created_at[to]=2026-06-30`.\n\nSend `Authorization: Bearer <auth_token>`, the token from [`POST /auth-tokens`](/products-and-customers/authentication/post-auth-token). Hosts, tokens and the error format: [Hosts, authentication and errors](/products-and-customers/authentication).","parameters":[{"name":"page","in":"query","required":true,"description":"Page number, from `1`.","schema":{"type":"integer"}},{"name":"items_per_page","in":"query","required":true,"description":"Customers per page, from `1` to `100`.","schema":{"type":"integer"}},{"name":"status","in":"query","required":false,"description":"`0` – inactive, `1` – active, `2` – draft.","schema":{"type":"integer"}},{"name":"search","in":"query","required":false,"description":"Case-insensitive text to find in the first, middle or last name, the full name, the `guid` or the email.","schema":{"type":"string"}},{"name":"first_name","in":"query","required":false,"description":"First name, exact match.","schema":{"type":"string"}},{"name":"last_name","in":"query","required":false,"description":"Last name, exact match.","schema":{"type":"string"}},{"name":"email","in":"query","required":false,"description":"Email address, exact match.","schema":{"type":"string"}},{"name":"mobile_number","in":"query","required":false,"description":"Phone number, exact match against the main or the additional phone.","schema":{"type":"string"}},{"name":"created_at[from]","in":"query","required":false,"description":"Created at or after this time: `YYYY-MM-DD` or `YYYY-MM-DD HH:MM:SS`.","schema":{"type":"string"}},{"name":"created_at[to]","in":"query","required":false,"description":"Created at or before this time, in the same formats.","schema":{"type":"string"}},{"name":"sort_by","in":"query","required":false,"description":"`first_name`, `last_name`, `email` or `created_at`.","schema":{"type":"string"}},{"name":"sort_direction","in":"query","required":false,"description":"`asc` or `desc`. Default `desc`. Applies only together with `sort_by`.","schema":{"type":"string"}}],"responses":{"200":{"description":"A page of customers.","x-response-kind":"success","content":{"application/json":{"schema":{"type":"object","properties":{"items":{"type":"array","description":"The customers on this page.","items":{"type":"object","properties":{"guid":{"type":"string","description":"Customer id (a UUID) assigned by PayMe. Use it in `/customers/{guid}`."},"first_name":{"type":"string","description":"First name."},"middle_name":{"type":"string","description":"Middle name."},"last_name":{"type":"string","description":"Last name."},"email":{"type":"string","description":"Email address."},"phone_number":{"type":"string","description":"Main phone number. You send it as `phone`."},"additional_phone_number":{"type":"string","description":"Second phone number. You send it as `additional_phone`."},"address":{"type":"object","description":"Postal address. You send these fields at the top level of the request.","properties":{"country":{"type":"string","description":"Country."},"city":{"type":"string","description":"City."},"street":{"type":"string","description":"Street."},"building_number":{"type":"string","description":"Building number, e.g. `12A`."},"floor":{"type":"string","description":"Floor."},"zip":{"type":"string","description":"Postal code."}}},"company_name":{"type":"string","description":"Company name."},"description":{"type":"string","description":"Your note about the customer."},"birthday":{"type":"string","description":"Date of birth, `YYYY-MM-DD`."},"status":{"type":"integer","description":"`0` – inactive, `1` – active, `2` – draft."},"payment_tokens":{"type":"array","description":"The customer's saved payment tokens.","items":{"type":"object","properties":{"token":{"type":"string","description":"A payment token you saved for the customer."},"token_data":{"type":"string","description":"The JSON string you saved with the token, e.g. the card mask and brand."}}}}}}},"total":{"type":"integer","description":"How many customers match the filters, across all pages."},"page":{"type":"integer","description":"The page returned."},"items_per_page":{"type":"integer","description":"The page size you asked for."}}},"example":{"items":[{"guid":"6c1d2e3f-4a5b-4c6d-8e7f-9a0b1c2d3e4f","first_name":"Dana","middle_name":null,"last_name":"Levi","email":"dana@example.com","phone_number":"0501234567","additional_phone_number":null,"address":{"country":"Israel","city":"Tel Aviv","street":"Rothschild","building_number":"12A","floor":"3","zip":"6688101"},"company_name":"Example Ltd","description":"Prefers email contact","birthday":"1990-05-17","status":1,"payment_tokens":[{"token":"8f3a2c1d9e7b4a60","token_data":"{\"card_mask\":\"4580 **** **** 0000\",\"card_brand\":\"visa\"}"}]}],"total":1,"page":1,"items_per_page":20}}}},"400":{"description":"A required parameter is missing or a parameter is invalid, e.g. `items_per_page` above `100`.","x-response-kind":"error","content":{"application/json":{"schema":{"type":"object","properties":{"status_error_details":{"type":"string","description":"What went wrong. Validation messages are in Hebrew unless you send `Accept-Language: en`."},"status_error_code":{"type":"integer","description":"`501` for a validation error or a body that isn't valid JSON, `999` for any other error."},"validation_errors":{"type":"object","description":"The fields that failed validation. Each key is a field name; its value maps each failed rule to a message."},"session":{"type":"string","description":"Trace id of the request. Quote it when you contact PayMe support."}}},"example":{"status_error_details":"Field validation failed.","validation_errors":{"items_per_page":{"max":"The value must be less than max amount."}},"status_error_code":501,"session":"f3a1c2b0-9e4d-11ef-8c1a-0242ac120002"}}}},"401":{"description":"The `Authorization` header is missing, or the access token is invalid or expired. Get a new token with `POST /refresh-exchanges` or `POST /auth-tokens`.","x-response-kind":"error","content":{"application/json":{"schema":{"type":"object","properties":{"status_error_details":{"type":"string","description":"What went wrong."},"status_error_code":{"type":"integer","description":"`999`."},"session":{"type":"string","description":"Trace id of the request. Quote it when you contact PayMe support."}}},"example":{"status_error_details":"Unauthorized","status_error_code":999,"session":"f3a1c2b0-9e4d-11ef-8c1a-0242ac120002"}}}},"500":{"description":"Server error. Contact PayMe support and quote the `session`.","x-response-kind":"error","content":{"application/json":{"schema":{"type":"object","properties":{"status_error_details":{"type":"string","description":"What went wrong."},"status_error_code":{"type":"integer","description":"`999`."},"session":{"type":"string","description":"Trace id of the request. Quote it when you contact PayMe support."}}}}}}}},"post":{"security":[{"bearerAuth":[]}],"operationId":"post-customers","summary":"Create a customer","tags":["Customers"],"description":"Adds a customer to the seller's customer list. `first_name`, `last_name`, `email`, `phone` and `status` are required. The response returns the new customer's `guid`; use it with `/customers/{guid}`.\n\nThe request names the phone fields `phone` and `additional_phone` and sends the address fields at the top level; responses name them `phone_number` and `additional_phone_number` and nest the address in `address`. Fields the API doesn't know are ignored.\n\nSend `Authorization: Bearer <auth_token>`, the token from [`POST /auth-tokens`](/products-and-customers/authentication/post-auth-token). Hosts, tokens and the error format: [Hosts, authentication and errors](/products-and-customers/authentication).","requestBody":{"content":{"application/json":{"schema":{"type":"object","properties":{"customer_external_id":{"type":"string","description":"Your own customer id, unique among the seller's customers (`409` otherwise). It isn't returned when you read the customer."},"first_name":{"type":"string","description":"First name, at least 2 characters."},"middle_name":{"type":"string","description":"Middle name, at least 2 characters."},"last_name":{"type":"string","description":"Last name, at least 2 characters."},"email":{"type":"string","description":"A valid email address."},"phone":{"type":"string","description":"Main phone number, 3–20 characters. Returned as `phone_number`."},"additional_phone":{"type":"string","description":"Second phone number, 3–20 characters. Returned as `additional_phone_number`."},"company_name":{"type":"string","description":"Company name, at least 2 characters."},"country":{"type":"string","description":"Country, at least 2 characters. Returned inside `address`."},"city":{"type":"string","description":"City, at least 2 characters. Returned inside `address`."},"street":{"type":"string","description":"Street, at least 2 characters. Returned inside `address`."},"building_number":{"type":"string","description":"Building number, e.g. `12` or `12A`. Returned inside `address`."},"floor":{"type":"string","description":"Floor, at least 1 character. Returned inside `address`."},"zip":{"type":"string","description":"Postal code. Returned inside `address`."},"description":{"type":"string","description":"Your note about the customer."},"birthday":{"type":"string","description":"Date of birth, `YYYY-MM-DD`."},"status":{"type":"integer","description":"`0` – inactive, `1` – active, `2` – draft."},"payment_tokens":{"type":"array","description":"Payment tokens to save for the customer.","items":{"type":"object","properties":{"token":{"type":"string","description":"The payment token to save. PayMe stores it as given."},"token_data":{"type":"string","description":"A JSON object encoded as a string, e.g. the card mask and brand: `{\"card_mask\":\"4580 **** **** 0000\",\"card_brand\":\"visa\"}`. Must be valid JSON."}},"required":["token"]}}},"required":["first_name","last_name","email","phone","status"]},"example":{"customer_external_id":"CUST-1001","first_name":"Dana","last_name":"Levi","email":"dana@example.com","phone":"0501234567","status":1,"country":"Israel","city":"Tel Aviv","street":"Rothschild","building_number":"12A","birthday":"1990-05-17","payment_tokens":[{"token":"8f3a2c1d9e7b4a60","token_data":"{\"card_mask\":\"4580 **** **** 0000\",\"card_brand\":\"visa\"}"}]}}},"description":"The customer to create."},"responses":{"201":{"description":"Customer created.","x-response-kind":"success","content":{"application/json":{"schema":{"type":"object","properties":{"guid":{"type":"string","description":"The new customer's id (a UUID). Use it in `/customers/{guid}`."},"created_at":{"type":"string","description":"Creation time, ISO 8601 (UTC)."}}},"example":{"guid":"6c1d2e3f-4a5b-4c6d-8e7f-9a0b1c2d3e4f","created_at":"2026-11-09T10:00:00.000Z"}}}},"400":{"description":"A required field is missing, a field is invalid, or the body isn't valid JSON.","x-response-kind":"error","content":{"application/json":{"schema":{"type":"object","properties":{"status_error_details":{"type":"string","description":"What went wrong. Validation messages are in Hebrew unless you send `Accept-Language: en`."},"status_error_code":{"type":"integer","description":"`501` for a validation error or a body that isn't valid JSON, `999` for any other error."},"validation_errors":{"type":"object","description":"The fields that failed validation. Each key is a field name; its value maps each failed rule to a message."},"session":{"type":"string","description":"Trace id of the request. Quote it when you contact PayMe support."}}},"example":{"status_error_details":"Field validation failed.","validation_errors":{"email":{"is_email":"The value must be a valid email address."}},"status_error_code":501,"session":"f3a1c2b0-9e4d-11ef-8c1a-0242ac120002"}}}},"401":{"description":"The `Authorization` header is missing, or the access token is invalid or expired. Get a new token with `POST /refresh-exchanges` or `POST /auth-tokens`.","x-response-kind":"error","content":{"application/json":{"schema":{"type":"object","properties":{"status_error_details":{"type":"string","description":"What went wrong."},"status_error_code":{"type":"integer","description":"`999`."},"session":{"type":"string","description":"Trace id of the request. Quote it when you contact PayMe support."}}},"example":{"status_error_details":"Unauthorized","status_error_code":999,"session":"f3a1c2b0-9e4d-11ef-8c1a-0242ac120002"}}}},"409":{"description":"`customer_external_id` is already used by another of the seller's customers.","x-response-kind":"error","content":{"application/json":{"schema":{"type":"object","properties":{"status_error_details":{"type":"string","description":"What went wrong."},"status_error_code":{"type":"integer","description":"`999`."},"session":{"type":"string","description":"Trace id of the request. Quote it when you contact PayMe support."}}},"example":{"status_error_details":"Customer external id already exist","status_error_code":999,"session":"f3a1c2b0-9e4d-11ef-8c1a-0242ac120002"}}}},"500":{"description":"Server error. Contact PayMe support and quote the `session`.","x-response-kind":"error","content":{"application/json":{"schema":{"type":"object","properties":{"status_error_details":{"type":"string","description":"What went wrong."},"status_error_code":{"type":"integer","description":"`999`."},"session":{"type":"string","description":"Trace id of the request. Quote it when you contact PayMe support."}}}}}}}}},"/customers/{guid}":{"get":{"security":[{"bearerAuth":[]}],"operationId":"get-customers-guid","summary":"Get a customer","tags":["Customers"],"description":"Returns one of the seller's customers by its `guid`. A customer that doesn't exist, was deleted or belongs to another seller returns `404`.\n\nSend `Authorization: Bearer <auth_token>`, the token from [`POST /auth-tokens`](/products-and-customers/authentication/post-auth-token). Hosts, tokens and the error format: [Hosts, authentication and errors](/products-and-customers/authentication).","parameters":[{"name":"guid","in":"path","required":true,"description":"The customer `guid` (a UUID) that `POST /customers` returned. Any other format returns `400`.","schema":{"type":"string"}}],"responses":{"200":{"description":"The customer.","x-response-kind":"success","content":{"application/json":{"schema":{"type":"object","properties":{"guid":{"type":"string","description":"Customer id (a UUID) assigned by PayMe. Use it in `/customers/{guid}`."},"first_name":{"type":"string","description":"First name."},"middle_name":{"type":"string","description":"Middle name."},"last_name":{"type":"string","description":"Last name."},"email":{"type":"string","description":"Email address."},"phone_number":{"type":"string","description":"Main phone number. You send it as `phone`."},"additional_phone_number":{"type":"string","description":"Second phone number. You send it as `additional_phone`."},"address":{"type":"object","description":"Postal address. You send these fields at the top level of the request.","properties":{"country":{"type":"string","description":"Country."},"city":{"type":"string","description":"City."},"street":{"type":"string","description":"Street."},"building_number":{"type":"string","description":"Building number, e.g. `12A`."},"floor":{"type":"string","description":"Floor."},"zip":{"type":"string","description":"Postal code."}}},"company_name":{"type":"string","description":"Company name."},"description":{"type":"string","description":"Your note about the customer."},"birthday":{"type":"string","description":"Date of birth, `YYYY-MM-DD`."},"status":{"type":"integer","description":"`0` – inactive, `1` – active, `2` – draft."},"payment_tokens":{"type":"array","description":"The customer's saved payment tokens.","items":{"type":"object","properties":{"token":{"type":"string","description":"A payment token you saved for the customer."},"token_data":{"type":"string","description":"The JSON string you saved with the token, e.g. the card mask and brand."}}}}}},"example":{"guid":"6c1d2e3f-4a5b-4c6d-8e7f-9a0b1c2d3e4f","first_name":"Dana","middle_name":null,"last_name":"Levi","email":"dana@example.com","phone_number":"0501234567","additional_phone_number":null,"address":{"country":"Israel","city":"Tel Aviv","street":"Rothschild","building_number":"12A","floor":"3","zip":"6688101"},"company_name":"Example Ltd","description":"Prefers email contact","birthday":"1990-05-17","status":1,"payment_tokens":[{"token":"8f3a2c1d9e7b4a60","token_data":"{\"card_mask\":\"4580 **** **** 0000\",\"card_brand\":\"visa\"}"}]}}}},"400":{"description":"`guid` isn't a UUID.","x-response-kind":"error","content":{"application/json":{"schema":{"type":"object","properties":{"status_error_details":{"type":"string","description":"What went wrong."},"status_error_code":{"type":"integer","description":"`999`."},"session":{"type":"string","description":"Trace id of the request. Quote it when you contact PayMe support."}}},"example":{"status_error_details":"Validation failed (uuid is expected)","status_error_code":999,"session":"f3a1c2b0-9e4d-11ef-8c1a-0242ac120002"}}}},"401":{"description":"The `Authorization` header is missing, or the access token is invalid or expired. Get a new token with `POST /refresh-exchanges` or `POST /auth-tokens`.","x-response-kind":"error","content":{"application/json":{"schema":{"type":"object","properties":{"status_error_details":{"type":"string","description":"What went wrong."},"status_error_code":{"type":"integer","description":"`999`."},"session":{"type":"string","description":"Trace id of the request. Quote it when you contact PayMe support."}}},"example":{"status_error_details":"Unauthorized","status_error_code":999,"session":"f3a1c2b0-9e4d-11ef-8c1a-0242ac120002"}}}},"404":{"description":"The customer doesn't exist, was deleted, or belongs to another seller.","x-response-kind":"error","content":{"application/json":{"schema":{"type":"object","properties":{"status_error_details":{"type":"string","description":"What went wrong."},"status_error_code":{"type":"integer","description":"`999`."},"session":{"type":"string","description":"Trace id of the request. Quote it when you contact PayMe support."}}},"example":{"status_error_details":"Customer not found","status_error_code":999,"session":"f3a1c2b0-9e4d-11ef-8c1a-0242ac120002"}}}},"500":{"description":"Server error. Contact PayMe support and quote the `session`.","x-response-kind":"error","content":{"application/json":{"schema":{"type":"object","properties":{"status_error_details":{"type":"string","description":"What went wrong."},"status_error_code":{"type":"integer","description":"`999`."},"session":{"type":"string","description":"Trace id of the request. Quote it when you contact PayMe support."}}}}}}}},"patch":{"security":[{"bearerAuth":[]}],"operationId":"patch-customers","summary":"Update a customer","tags":["Customers"],"description":"Changes some fields of one of the seller's customers. Fields you don't send, or send empty, keep their values. A `payment_tokens` array you send replaces all of the customer's saved tokens.\n\nThe request names the phone fields `phone` and `additional_phone` and sends the address fields at the top level; responses name them `phone_number` and `additional_phone_number` and nest the address in `address`. Fields the API doesn't know are ignored.\n\nTo replace the whole customer in one call, `PUT /customers/{guid}` takes the same body as [`POST /customers`](/products-and-customers/customers/post-customers), with the same required fields.\n\nSend `Authorization: Bearer <auth_token>`, the token from [`POST /auth-tokens`](/products-and-customers/authentication/post-auth-token). Hosts, tokens and the error format: [Hosts, authentication and errors](/products-and-customers/authentication).","parameters":[{"name":"guid","in":"path","required":true,"description":"The customer `guid` (a UUID) that `POST /customers` returned. Any other format returns `400`.","schema":{"type":"string"}}],"requestBody":{"content":{"application/json":{"schema":{"type":"object","properties":{"customer_external_id":{"type":"string","description":"Your own customer id, unique among the seller's customers (`409` otherwise). It isn't returned when you read the customer. Send it only to change it: resending the customer's current value also returns `409`."},"first_name":{"type":"string","description":"First name, at least 2 characters."},"middle_name":{"type":"string","description":"Middle name, at least 2 characters."},"last_name":{"type":"string","description":"Last name, at least 2 characters."},"email":{"type":"string","description":"A valid email address."},"phone":{"type":"string","description":"Main phone number, 3–20 characters. Returned as `phone_number`."},"additional_phone":{"type":"string","description":"Second phone number, 3–20 characters. Returned as `additional_phone_number`."},"company_name":{"type":"string","description":"Company name, at least 2 characters."},"country":{"type":"string","description":"Country, at least 2 characters. Returned inside `address`."},"city":{"type":"string","description":"City, at least 2 characters. Returned inside `address`."},"street":{"type":"string","description":"Street, at least 2 characters. Returned inside `address`."},"building_number":{"type":"string","description":"Building number, e.g. `12` or `12A`. Returned inside `address`."},"floor":{"type":"string","description":"Floor, at least 1 character. Returned inside `address`."},"zip":{"type":"string","description":"Postal code. Returned inside `address`."},"description":{"type":"string","description":"Your note about the customer."},"status":{"type":"integer","description":"`1` – active, `2` – draft. This call can't set `0` (inactive)."},"payment_tokens":{"type":"array","description":"Payment tokens to save for the customer. The array replaces all of the customer's saved tokens.","items":{"type":"object","properties":{"token":{"type":"string","description":"The payment token to save. PayMe stores it as given."},"token_data":{"type":"string","description":"A JSON object encoded as a string, e.g. the card mask and brand: `{\"card_mask\":\"4580 **** **** 0000\",\"card_brand\":\"visa\"}`. Must be valid JSON."}},"required":["token"]}}}},"example":{"email":"dana.levi@example.com","phone":"0527654321","city":"Haifa"}}},"description":"The fields to change."},"responses":{"200":{"description":"Customer updated.","x-response-kind":"success","content":{"application/json":{"schema":{"type":"object","properties":{"guid":{"type":"string","description":"The customer id (a UUID)."},"created_at":{"type":"string","description":"Creation time, ISO 8601 (UTC)."},"updated_at":{"type":"string","description":"Time of this update, ISO 8601 (UTC)."}}},"example":{"guid":"6c1d2e3f-4a5b-4c6d-8e7f-9a0b1c2d3e4f","created_at":"2026-11-01T09:30:00.000Z","updated_at":"2026-11-09T10:00:00.000Z"}}}},"400":{"description":"A field is invalid, the body isn't valid JSON, or `guid` isn't a UUID.","x-response-kind":"error","content":{"application/json":{"schema":{"type":"object","properties":{"status_error_details":{"type":"string","description":"What went wrong. Validation messages are in Hebrew unless you send `Accept-Language: en`."},"status_error_code":{"type":"integer","description":"`501` for a validation error or a body that isn't valid JSON, `999` for any other error."},"validation_errors":{"type":"object","description":"The fields that failed validation. Each key is a field name; its value maps each failed rule to a message."},"session":{"type":"string","description":"Trace id of the request. Quote it when you contact PayMe support."}}},"example":{"status_error_details":"Field validation failed.","validation_errors":{"email":{"is_email":"The value must be a valid email address."}},"status_error_code":501,"session":"f3a1c2b0-9e4d-11ef-8c1a-0242ac120002"}}}},"401":{"description":"The `Authorization` header is missing, or the access token is invalid or expired. Get a new token with `POST /refresh-exchanges` or `POST /auth-tokens`.","x-response-kind":"error","content":{"application/json":{"schema":{"type":"object","properties":{"status_error_details":{"type":"string","description":"What went wrong."},"status_error_code":{"type":"integer","description":"`999`."},"session":{"type":"string","description":"Trace id of the request. Quote it when you contact PayMe support."}}},"example":{"status_error_details":"Unauthorized","status_error_code":999,"session":"f3a1c2b0-9e4d-11ef-8c1a-0242ac120002"}}}},"404":{"description":"The customer doesn't exist, was deleted, or belongs to another seller.","x-response-kind":"error","content":{"application/json":{"schema":{"type":"object","properties":{"status_error_details":{"type":"string","description":"What went wrong."},"status_error_code":{"type":"integer","description":"`999`."},"session":{"type":"string","description":"Trace id of the request. Quote it when you contact PayMe support."}}},"example":{"status_error_details":"Customer not found","status_error_code":999,"session":"f3a1c2b0-9e4d-11ef-8c1a-0242ac120002"}}}},"409":{"description":"`customer_external_id` is already used by another of the seller's customers.","x-response-kind":"error","content":{"application/json":{"schema":{"type":"object","properties":{"status_error_details":{"type":"string","description":"What went wrong."},"status_error_code":{"type":"integer","description":"`999`."},"session":{"type":"string","description":"Trace id of the request. Quote it when you contact PayMe support."}}},"example":{"status_error_details":"Customer external id already exist","status_error_code":999,"session":"f3a1c2b0-9e4d-11ef-8c1a-0242ac120002"}}}},"500":{"description":"Server error. Contact PayMe support and quote the `session`.","x-response-kind":"error","content":{"application/json":{"schema":{"type":"object","properties":{"status_error_details":{"type":"string","description":"What went wrong."},"status_error_code":{"type":"integer","description":"`999`."},"session":{"type":"string","description":"Trace id of the request. Quote it when you contact PayMe support."}}}}}}}},"delete":{"security":[{"bearerAuth":[]}],"operationId":"delete-customers","summary":"Delete a customer","tags":["Customers"],"description":"Deletes one of the seller's customers. Deleted customers no longer appear in lists or reads, and their `guid` returns `404`. The call has no request body and returns `204 No Content`.\n\nSend `Authorization: Bearer <auth_token>`, the token from [`POST /auth-tokens`](/products-and-customers/authentication/post-auth-token). Hosts, tokens and the error format: [Hosts, authentication and errors](/products-and-customers/authentication).","parameters":[{"name":"guid","in":"path","required":true,"description":"The customer `guid` (a UUID) that `POST /customers` returned. Any other format returns `400`.","schema":{"type":"string"}}],"responses":{"204":{"description":"Customer deleted. The response has no body.","x-response-kind":"success"},"400":{"description":"`guid` isn't a UUID.","x-response-kind":"error","content":{"application/json":{"schema":{"type":"object","properties":{"status_error_details":{"type":"string","description":"What went wrong."},"status_error_code":{"type":"integer","description":"`999`."},"session":{"type":"string","description":"Trace id of the request. Quote it when you contact PayMe support."}}},"example":{"status_error_details":"Validation failed (uuid is expected)","status_error_code":999,"session":"f3a1c2b0-9e4d-11ef-8c1a-0242ac120002"}}}},"401":{"description":"The `Authorization` header is missing, or the access token is invalid or expired. Get a new token with `POST /refresh-exchanges` or `POST /auth-tokens`.","x-response-kind":"error","content":{"application/json":{"schema":{"type":"object","properties":{"status_error_details":{"type":"string","description":"What went wrong."},"status_error_code":{"type":"integer","description":"`999`."},"session":{"type":"string","description":"Trace id of the request. Quote it when you contact PayMe support."}}},"example":{"status_error_details":"Unauthorized","status_error_code":999,"session":"f3a1c2b0-9e4d-11ef-8c1a-0242ac120002"}}}},"404":{"description":"The customer doesn't exist, was deleted, or belongs to another seller.","x-response-kind":"error","content":{"application/json":{"schema":{"type":"object","properties":{"status_error_details":{"type":"string","description":"What went wrong."},"status_error_code":{"type":"integer","description":"`999`."},"session":{"type":"string","description":"Trace id of the request. Quote it when you contact PayMe support."}}},"example":{"status_error_details":"Customer not found","status_error_code":999,"session":"f3a1c2b0-9e4d-11ef-8c1a-0242ac120002"}}}},"500":{"description":"Server error. Contact PayMe support and quote the `session`.","x-response-kind":"error","content":{"application/json":{"schema":{"type":"object","properties":{"status_error_details":{"type":"string","description":"What went wrong."},"status_error_code":{"type":"integer","description":"`999`."},"session":{"type":"string","description":"Trace id of the request. Quote it when you contact PayMe support."}}}}}}}}}}}