> For the complete documentation index, see [llms.txt](https://docs.verifone.com/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.verifone.com/api-reference/open-api-references/order-service/aml-documents.md).

# Aml Documents

The **Merchant Order AML Documents** endpoints manage AML and KYC documents for merchant orders that require them. Use these endpoints to list required documents, generate temporary upload URLs, and delete uploaded documents.

{% hint style="info" %}
Upload URLs expire after a short period. Request new URLs if the previous ones expire before upload completes.
{% endhint %}

## How It Works

{% stepper %}
{% step %}

## Check which documents are required

`GET /orders/{orderId}/required-documents` — Return the documents required for the merchant order.
{% endstep %}

{% step %}

## Generate upload URLs

`POST /orders/{orderId}/upload-urls` — Generate temporary URLs for document upload.
{% endstep %}

{% step %}

## Upload the files

Use the returned URLs to upload each document. If a URL expires, request a new one.
{% endstep %}

{% step %}

## Delete and replace a document if needed

`DELETE /orders/{orderId}/documents/{documentId}` — Delete a document by ID before re-uploading the correct file.
{% endstep %}
{% endstepper %}

## API Reference

### Documents required for merchant order

## Documents required for merchant order

> Docs required for merchant order

```json
{"openapi":"3.0.0","info":{"title":"Verifone Order Internal API","version":"2.63.1-SNAPSHOT"},"tags":[{"name":"Merchant Orders Documentation","description":"Operations to manage documents for merchant orders that require them for AML/KYC."}],"servers":[{"url":"https://api.verifone.com"}],"paths":{"/orders/{orderId}/required-documents":{"get":{"tags":["Merchant Orders Documentation"],"summary":"Documents required for merchant order","description":"Docs required for merchant order","operationId":"requiredDocuments","parameters":[{"$ref":"#/components/parameters/orderIdPathParam"}],"responses":{"202":{"description":"Required Document list","content":{"application/json":{"schema":{"type":"array","items":{"$ref":"#/components/schemas/RequiredDocument"}}}}},"400":{"$ref":"#/components/responses/400"},"401":{"$ref":"#/components/responses/401"},"403":{"$ref":"#/components/responses/403"},"404":{"$ref":"#/components/responses/404"},"429":{"$ref":"#/components/responses/429"},"500":{"$ref":"#/components/responses/500"},"503":{"$ref":"#/components/responses/503"},"504":{"$ref":"#/components/responses/504"}}}}},"components":{"parameters":{"orderIdPathParam":{"name":"orderId","in":"path","description":"Verifone allocated ID for the Order.","required":true,"schema":{"$ref":"#/components/schemas/OrderId"}}},"schemas":{"OrderId":{"description":"Verifone allocated ID for the Order.","type":"string","format":"uuid"},"RequiredDocument":{"type":"object","description":"Merchant Required Document Details","properties":{"documentId":{"type":"string","format":"uuid","description":"Unique identifier for the document."},"documentName":{"type":"string","maxLength":100,"description":"Name of the document."},"displayName":{"type":"string","maxLength":100,"description":"Display name of the document shown to end user."},"status":{"$ref":"#/components/schemas/DocumentStatusEnum","description":"Current status of the document."},"allowedContentTypes":{"type":"array","description":"List of supported content types.","minItems":1,"maxItems":100,"items":{"$ref":"#/components/schemas/ContentTypeEnum"}},"allowedContentLength":{"type":"integer","format":"int64","description":"Size of the uploaded document in bytes.  Default is 2 MB (2097152 bytes), maximum allowed is 8 MB (8388608 bytes).\n","default":2097152,"maximum":8388608},"contact":{"$ref":"#/components/schemas/ContractContactType"}},"required":["documentId","documentName","status","allowedContentTypes"]},"DocumentStatusEnum":{"type":"string","description":"Current status of the document. Rejected documents must be re-uploaded.","enum":["PENDING_UPLOAD","UPLOADED","PENDING_SCAN","ACCEPTED_CLEAN","REJECTED_INFECTED"]},"ContentTypeEnum":{"type":"string","description":"Supported content type for documents.","enum":["application/pdf","image/png","image/jpeg","application/msword","application/vnd.openxmlformats-officedocument.wordprocessingml.document","application/vnd.openxmlformats-officedocument.spreadsheetml.sheet","application/vnd.ms-excel"]},"ContractContactType":{"type":"object","required":["contactType","name"],"properties":{"contactType":{"$ref":"#/components/schemas/ContactTypeEnum"},"name":{"$ref":"#/components/schemas/ContactName"},"phoneNumbers":{"description":"The phone numbers to be used for the Contact. If you include this property there should be at least one phone number.","items":{"$ref":"#/components/schemas/Phone"},"minItems":1,"uniqueItems":true,"type":"array"},"email":{"$ref":"#/components/schemas/EmailAddress"},"businessTitle":{"$ref":"#/components/schemas/BusinessTitle"},"passportId":{"type":"string","description":"Passport Identity Identifier.","minLength":1,"maxLength":100},"nationality":{"type":"string","description":"Nationality","minLength":1,"maxLength":100},"additionalNationalities":{"type":"array","description":"Additional Nationalities","uniqueItems":true,"maxItems":20,"items":{"type":"string","minLength":1,"maxLength":100}},"nationalIdentifer":{"type":"string","description":"Contact's national identity identifier.","minLength":1,"maxLength":20}}},"ContactTypeEnum":{"title":"Contact Type","description":"An indicator for the type of contact.\n\n|Value|Description|\n|----|-----------|\n|BUSINESS|Generic business contact information, e.g. info@example.com|\n|DISPUTE_HANDLING|Generic contact information specific to dispute handling, e.g. disputes@example.com|\n|OWNER|Individual contact information of the owner of the Entity, e.g. ben.jerry@example.com|\n|PERSONAL|Personal contact information of the person representing the Entity, e.g. bjerr83@example-personal-email-domain.com|","type":"string","enum":["BUSINESS","DISPUTE_HANDLING","OWNER","PERSONAL"],"default":"BUSINESS"},"ContactName":{"allOf":[{"$ref":"#/components/schemas/Name"}]},"Name":{"title":"Name Details","description":"An object representing the name or component names of a party, person or business. No elements are mandatory due to the different usages, but the business rules need to be applied in the context where name is used.","type":"object","uniqueItems":false,"properties":{"firstName":{"description":"The given name of contact.","type":"string","minLength":1,"maxLength":120},"lastName":{"description":"The surname name or family name of the contact. This is required when the name is for a party or person. Can also include the matronymic or mother's family name where this is customarily used.","minLength":1,"maxLength":120,"type":"string"},"prefix":{"description":"The prefix to the party name. This is sometimes referred to as a title, salutation or appellation.","maxLength":120,"type":"string"},"alternateFullName":{"description":"The alternate name for the party. This can be a business name or nickname. This should be used where the name of the party cannot be parsed into its constituent parts such as first name or last name. If the party is a business then this should always be present.","maxLength":200,"type":"string"},"middleName":{"description":"The middle name or names for a party or person.","maxLength":120,"type":"string"},"suffix":{"description":"The name suffix for the party.","maxLength":120,"type":"string"}},"required":["firstName","lastName"]},"Phone":{"title":"Phone number","description":"A simple Phone Number","type":"object","additionalProperties":false,"properties":{"callingCode":{"description":"Country Calling Code. Mapped to PARTY_PHONE.CALLING_CODE or VENUE_PHONE.CALLING_CODE","type":"string"},"value":{"description":"The actual phone number less country code and/or extension.","type":"string","minLength":5},"extension":{"description":"The internal extension number where applicable or known.","type":"string"},"isPrimary":{"description":"Indicates that the phone is a the primary phone. Mapped to PARTY_PHONE_PRIMARY","type":"boolean","default":false},"phoneType":{"$ref":"#/components/schemas/PhoneTypeEnum"}},"required":["value","phoneType"]},"PhoneTypeEnum":{"title":"Phone Type","description":"Phone type in PHONE_TYPE_CON. Mapped to PARTY_PHONE.PHONE_TYPE_CON_ID or VENUE_PHONE.PHONE_TYPE_CON_ID","type":"string","enum":["HOME","MOBILE","WORK","FAX","OTHER"],"default":"HOME"},"EmailAddress":{"title":"Email Address","maxLength":254,"minLength":3,"type":"string","format":"email","pattern":"^[a-zA-Z0-9!#$%&'*+=?^_`{|}~.-]+@[a-zA-Z0-9-]+[.].+$","description":"A valid internationalized email address, as defined by RFC 5322, RFC 6530, and other RFCs. Due to RFC 5321, an email address can be up to 254 characters long even though up to 64 characters are allowed before and 255 characters are allowed after the @ sign. This pattern verifies only that the string contains an unquoted @ sign. See https://tools.ietf.org/html/rfc5322#section-3.4.1."},"BusinessTitle":{"type":"string","maxLength":100},"httpError400":{"title":"HTTP 400 Error","type":"object","description":"The request could not be understood by the server due to malformed syntax.","allOf":[{"$ref":"#/components/schemas/ErrorResp"},{"properties":{"code":{"type":"string","enum":["400"],"default":"400"},"title":{"type":"string","enum":["Bad Request"],"default":"Bad Request"},"message":{"type":"string","default":"The request could not be understood by the server due to malformed syntax. The client SHOULD NOT repeat the request without modifications."},"timestamp":{"description":"The time that the error occurred. All dates in the JSON payloads are represented in ISO 8601 date-time format. \nAll date-time fields in responses must include the timezone.","type":"string","format":"date-time"},"type":{"type":"string","enum":["INVALID_REQUEST_ERROR"],"default":"INVALID_REQUEST_ERROR"},"param":{"description":"The parameter the error relates to if the error is parameter-specific. You can use this to display a message near the correct form field, for example.","type":"string"}}}],"required":["code","title","message","type"],"additionalProperties":false},"ErrorResp":{"title":"Error","description":"A common Error object returned as part of the API layer.\n\n. This is modified to become the base class for all of the derived HTTP Error Responses.","type":"object","properties":{"reversalStatus":{"description":"Indicates to the API client if a technical reversal is required or has been completed by Verifone.\n\n|Value|Description|\n|-|-|\n|NONE|Reversal status is not set. This indicates the status of reversal processing is not known and the client should implement default reversal processing.|\n|REQUIRED|A reversal is required by the client.|\n|COMPLETED|A reversal has been completed by verifone or a reversal is not required for this transaction.|","type":"string","enum":["NONE","REQUIRED","COMPLETED"],"default":"NONE"}},"required":["code"]},"httpError401":{"title":"HTTP 401 Error","type":"object","description":"The request must be authenticated to access the resource.","allOf":[{"$ref":"#/components/schemas/ErrorResp"},{"properties":{"code":{"type":"string","enum":["401"],"default":"401"},"title":{"type":"string","enum":["Unauthorised"],"default":"Unauthorised"},"message":{"type":"string","default":"The request requires client authentication."},"timestamp":{"description":"The time that the error occurred. All dates in the JSON payloads are represented in ISO 8601 date-time format. \nAll date-time fields in responses must include the timezone.","type":"string","format":"date-time"},"type":{"type":"string","enum":["AUTHENTICATION_ERROR"],"default":"AUTHENTICATION_ERROR"},"param":{"description":"The parameter the error relates to if the error is parameter-specific. You can use this to display a message near the correct form field, for example.","type":"string"}}}],"required":["code","title","message","type"],"additionalProperties":false},"httpError403":{"title":"HTTP 403 Error","type":"object","description":"The request must be authorised to access the resource.","allOf":[{"$ref":"#/components/schemas/ErrorResp"},{"properties":{"code":{"type":"string","enum":["403"],"default":"403"},"title":{"type":"string","enum":["Forbidden"],"default":"Forbidden"},"message":{"type":"string","default":"The request requires client authorisation to access resource."},"timestamp":{"description":"The time that the error occurred. All dates in the JSON payloads are represented in ISO 8601 date-time format. \nAll date-time fields in responses must include the timezone.","type":"string","format":"date-time"},"type":{"type":"string","enum":["AUTHENTICATION_ERROR"],"default":"AUTHENTICATION_ERROR"},"param":{"description":"The parameter the error relates to if the error is parameter-specific. You can use this to display a message near the correct form field, for example.","type":"string"}}}],"required":["code","title","message","type"],"additionalProperties":false},"httpError404":{"title":"HTTP 404 Error","type":"object","description":"The server cannot find the requested resource.","allOf":[{"$ref":"#/components/schemas/ErrorResp"},{"properties":{"code":{"type":"string","enum":["404"],"default":"404"},"title":{"type":"string","enum":["Not Found"],"default":"Not Found"},"message":{"type":"string","default":"The server cannot find the requested resource."},"timestamp":{"description":"The time that the error occurred. All dates in the JSON payloads are represented in ISO 8601 date-time format. \nAll date-time fields in responses must include the timezone.","type":"string","format":"date-time"},"type":{"type":"string","enum":["INVALID_REQUEST_ERROR"],"default":"INVALID_REQUEST_ERROR"},"param":{"description":"The parameter the error relates to if the error is parameter-specific. You can use this to display a message near the correct form field, for example.","type":"string"}}}],"required":["code","title","message","type"],"additionalProperties":false},"httpError429":{"title":"HTTP 429 Error","type":"object","description":"The resource exists the number of requests has exceeded the specified quota.","allOf":[{"$ref":"#/components/schemas/ErrorResp"},{"properties":{"code":{"type":"string","enum":["429"],"default":"429"},"title":{"type":"string","enum":["Too Many Requests"],"default":"Too Many Requests"},"message":{"type":"string","default":"The number of requests from this client is restricted to a specified quota."},"timestamp":{"description":"The time that the error occurred. All dates in the JSON payloads are represented in ISO 8601 date-time format. \nAll date-time fields in responses must include the timezone.","type":"string","format":"date-time"},"type":{"type":"string","enum":["RATE_LIMIT_ERROR"],"default":"RATE_LIMIT_ERROR"},"param":{"description":"The parameter the error relates to if the error is parameter-specific. You can use this to display a message near the correct form field, for example.","type":"string"}}}],"required":["code","title","message","type"],"additionalProperties":false},"httpError500":{"title":"HTTP 500 Error","type":"object","description":"Unexpected Server Error","allOf":[{"$ref":"#/components/schemas/ErrorResp"},{"properties":{"code":{"type":"string","enum":["500"],"default":"500"},"title":{"type":"string","enum":["Internal Server Error"],"default":"Internal Server Error"},"message":{"type":"string","default":"The server encountered an unexpected condition which prevented it from fulfilling the request."},"timestamp":{"description":"The time that the error occurred. All dates in the JSON payloads are represented in ISO 8601 date-time format. \nAll date-time fields in responses must include the timezone.","type":"string","format":"date-time"},"type":{"type":"string","enum":["API_ERROR"],"default":"API_ERROR"},"param":{"description":"The parameter the error relates to if the error is parameter-specific. You can use this to display a message near the correct form field, for example.","type":"string"}}}],"required":["code","title","message","type"],"additionalProperties":false},"httpError503":{"title":"HTTP 503 Error","type":"object","description":"Service Unavailable Error","allOf":[{"$ref":"#/components/schemas/ErrorResp"},{"properties":{"code":{"type":"string","enum":["503"],"default":"503"},"title":{"type":"string","enum":["Service Unavailable"],"default":"Service Unavailable"},"message":{"type":"string","default":"The server is not ready to handle the request. If specified please check the <strong>Retry-After</strong> for the time period specified for recovery/re-attempt of request."},"timestamp":{"description":"The time that the error occurred. All dates in the JSON payloads are represented in ISO 8601 date-time format. \nAll date-time fields in responses must include the timezone.","type":"string","format":"date-time"},"type":{"type":"string","enum":["API_ERROR"],"default":"API_ERROR"},"param":{"description":"The parameter the error relates to if the error is parameter-specific. You can use this to display a message near the correct form field, for example.","type":"string"}}}],"required":["code","title","message","type"],"additionalProperties":false},"httpError504":{"title":"HTTP 504 Error","type":"object","description":"Gateway Timeout Error","allOf":[{"$ref":"#/components/schemas/ErrorResp"},{"properties":{"code":{"type":"string","enum":["504"],"default":"504"},"title":{"type":"string","enum":["Gateway Timeout"],"default":"Gateway Timeout"},"message":{"type":"string","default":"The server, while acting as a gateway or proxy, did not get a response in time from the upstream server that it needed in order to complete the request."},"timestamp":{"description":"The time that the error occurred. All dates in the JSON payloads are represented in ISO 8601 date-time format. \nAll date-time fields in responses must include the timezone.","type":"string","format":"date-time"},"type":{"type":"string","enum":["API_ERROR"],"default":"API_ERROR"},"param":{"description":"The parameter the error relates to if the error is parameter-specific. You can use this to display a message near the correct form field, for example.","type":"string"}}}],"required":["code","title","message","type"],"additionalProperties":false}},"responses":{"400":{"description":"Bad Request","content":{"application/json":{"schema":{"allOf":[{"$ref":"#/components/schemas/httpError400"},{"properties":{"param":{"description":"The parameter the error relates to if the error is parameter-specific. You can use this to display a message near the correct form field, for example.","type":"string"},"additionalProperties":{"type":"object","additionalProperties":{"type":"object"}}}}],"required":["code","title","message","type"]}}}},"401":{"description":"Unauthorised Request","content":{"application/json":{"schema":{"allOf":[{"$ref":"#/components/schemas/httpError401"},{"properties":{"param":{"description":"The parameter the error relates to if the error is parameter-specific. You can use this to display a message near the correct form field, for example.","type":"string"},"additionalProperties":{"type":"object","additionalProperties":{"type":"object"}}}}],"required":["code","title","message","type"]}}}},"403":{"description":"Forbidden Request.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/httpError403"}}}},"404":{"description":"Not Found Request","content":{"application/json":{"schema":{"allOf":[{"$ref":"#/components/schemas/httpError404"},{"properties":{"param":{"description":"The parameter the error relates to if the error is parameter-specific. You can use this to display a message near the correct form field, for example.","type":"string"},"additionalProperties":{"type":"object","additionalProperties":{"type":"object"}}}}],"required":["code","title","message","type"]}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"allOf":[{"$ref":"#/components/schemas/httpError429"},{"properties":{"param":{"description":"The parameter the error relates to if the error is parameter-specific. You can use this to display a message near the correct form field, for example.","type":"string"},"additionalProperties":{"type":"object","additionalProperties":{"type":"object"}}}}],"required":["code","title","message","type"]}}}},"500":{"description":"Internal Error","content":{"application/json":{"schema":{"allOf":[{"$ref":"#/components/schemas/httpError500"},{"properties":{"param":{"description":"The parameter the error relates to if the error is parameter-specific. You can use this to display a message near the correct form field, for example.","type":"string"},"additionalProperties":{"type":"object","additionalProperties":{"type":"object"}}}}],"required":["code","title","message","type"]}}}},"503":{"description":"Service Not Available","content":{"application/json":{"schema":{"allOf":[{"$ref":"#/components/schemas/httpError503"},{"properties":{"param":{"description":"The parameter the error relates to if the error is parameter-specific. You can use this to display a message near the correct form field, for example.","type":"string"},"additionalProperties":{"type":"object","additionalProperties":{"type":"object"}}}}],"required":["code","title","message","type"]}}}},"504":{"description":"Service Timeout","content":{"application/json":{"schema":{"allOf":[{"$ref":"#/components/schemas/httpError504"},{"properties":{"param":{"description":"The parameter the error relates to if the error is parameter-specific. You can use this to display a message near the correct form field, for example.","type":"string"},"additionalProperties":{"type":"object","additionalProperties":{"type":"object"}}}}],"required":["code","title","message","type"]}}}}}}}
```

***

### Generate URLs for document upload

{% hint style="warning" %}
Generated upload URLs are short-lived. Do not cache them for later use.
{% endhint %}

## Generate URLs for document upload

> Generate URLs for document upload. These will expire after a short period to which you will need to request new URLs.

```json
{"openapi":"3.0.0","info":{"title":"Verifone Order Internal API","version":"2.63.1-SNAPSHOT"},"tags":[{"name":"Merchant Orders Documentation","description":"Operations to manage documents for merchant orders that require them for AML/KYC."}],"servers":[{"url":"https://api.verifone.com"}],"paths":{"/orders/{orderId}/upload-urls":{"post":{"tags":["Merchant Orders Documentation"],"summary":"Generate URLs for document upload","description":"Generate URLs for document upload. These will expire after a short period to which you will need to request new URLs.","operationId":"generateDocumentURLs","parameters":[{"$ref":"#/components/parameters/orderIdPathParam"}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"array","items":{"$ref":"#/components/schemas/AdditionalDocument"}}}}},"responses":{"202":{"description":"URLs to upload the required documents.","content":{"application/json":{"schema":{"type":"array","items":{"allOf":[{"$ref":"#/components/schemas/AdditionalDocument"},{"properties":{"uploadUrl":{"type":"string","description":"Upload URL for this document."}},"required":["uploadUrl"]}]}}}}},"400":{"$ref":"#/components/responses/400"},"401":{"$ref":"#/components/responses/401"},"403":{"$ref":"#/components/responses/403"},"404":{"$ref":"#/components/responses/404"},"429":{"$ref":"#/components/responses/429"},"500":{"$ref":"#/components/responses/500"},"503":{"$ref":"#/components/responses/503"},"504":{"$ref":"#/components/responses/504"}}}}},"components":{"parameters":{"orderIdPathParam":{"name":"orderId","in":"path","description":"Verifone allocated ID for the Order.","required":true,"schema":{"$ref":"#/components/schemas/OrderId"}}},"schemas":{"OrderId":{"description":"Verifone allocated ID for the Order.","type":"string","format":"uuid"},"AdditionalDocument":{"type":"object","description":"Upload Document Meta Info.","properties":{"documentName":{"type":"string","maxLength":100,"description":"Name of the document."},"contentType":{"type":"string","$ref":"#/components/schemas/ContentTypeEnum","maxLength":100,"description":"Content type of the document."},"contentLength":{"type":"integer","format":"int64","description":"Size of the uploaded document in bytes.  Maximum allowed is 8 MB (8388608 bytes).\n","maximum":8388608}},"required":["documentName","contentType"]},"ContentTypeEnum":{"type":"string","description":"Supported content type for documents.","enum":["application/pdf","image/png","image/jpeg","application/msword","application/vnd.openxmlformats-officedocument.wordprocessingml.document","application/vnd.openxmlformats-officedocument.spreadsheetml.sheet","application/vnd.ms-excel"]},"httpError400":{"title":"HTTP 400 Error","type":"object","description":"The request could not be understood by the server due to malformed syntax.","allOf":[{"$ref":"#/components/schemas/ErrorResp"},{"properties":{"code":{"type":"string","enum":["400"],"default":"400"},"title":{"type":"string","enum":["Bad Request"],"default":"Bad Request"},"message":{"type":"string","default":"The request could not be understood by the server due to malformed syntax. The client SHOULD NOT repeat the request without modifications."},"timestamp":{"description":"The time that the error occurred. All dates in the JSON payloads are represented in ISO 8601 date-time format. \nAll date-time fields in responses must include the timezone.","type":"string","format":"date-time"},"type":{"type":"string","enum":["INVALID_REQUEST_ERROR"],"default":"INVALID_REQUEST_ERROR"},"param":{"description":"The parameter the error relates to if the error is parameter-specific. You can use this to display a message near the correct form field, for example.","type":"string"}}}],"required":["code","title","message","type"],"additionalProperties":false},"ErrorResp":{"title":"Error","description":"A common Error object returned as part of the API layer.\n\n. This is modified to become the base class for all of the derived HTTP Error Responses.","type":"object","properties":{"reversalStatus":{"description":"Indicates to the API client if a technical reversal is required or has been completed by Verifone.\n\n|Value|Description|\n|-|-|\n|NONE|Reversal status is not set. This indicates the status of reversal processing is not known and the client should implement default reversal processing.|\n|REQUIRED|A reversal is required by the client.|\n|COMPLETED|A reversal has been completed by verifone or a reversal is not required for this transaction.|","type":"string","enum":["NONE","REQUIRED","COMPLETED"],"default":"NONE"}},"required":["code"]},"httpError401":{"title":"HTTP 401 Error","type":"object","description":"The request must be authenticated to access the resource.","allOf":[{"$ref":"#/components/schemas/ErrorResp"},{"properties":{"code":{"type":"string","enum":["401"],"default":"401"},"title":{"type":"string","enum":["Unauthorised"],"default":"Unauthorised"},"message":{"type":"string","default":"The request requires client authentication."},"timestamp":{"description":"The time that the error occurred. All dates in the JSON payloads are represented in ISO 8601 date-time format. \nAll date-time fields in responses must include the timezone.","type":"string","format":"date-time"},"type":{"type":"string","enum":["AUTHENTICATION_ERROR"],"default":"AUTHENTICATION_ERROR"},"param":{"description":"The parameter the error relates to if the error is parameter-specific. You can use this to display a message near the correct form field, for example.","type":"string"}}}],"required":["code","title","message","type"],"additionalProperties":false},"httpError403":{"title":"HTTP 403 Error","type":"object","description":"The request must be authorised to access the resource.","allOf":[{"$ref":"#/components/schemas/ErrorResp"},{"properties":{"code":{"type":"string","enum":["403"],"default":"403"},"title":{"type":"string","enum":["Forbidden"],"default":"Forbidden"},"message":{"type":"string","default":"The request requires client authorisation to access resource."},"timestamp":{"description":"The time that the error occurred. All dates in the JSON payloads are represented in ISO 8601 date-time format. \nAll date-time fields in responses must include the timezone.","type":"string","format":"date-time"},"type":{"type":"string","enum":["AUTHENTICATION_ERROR"],"default":"AUTHENTICATION_ERROR"},"param":{"description":"The parameter the error relates to if the error is parameter-specific. You can use this to display a message near the correct form field, for example.","type":"string"}}}],"required":["code","title","message","type"],"additionalProperties":false},"httpError404":{"title":"HTTP 404 Error","type":"object","description":"The server cannot find the requested resource.","allOf":[{"$ref":"#/components/schemas/ErrorResp"},{"properties":{"code":{"type":"string","enum":["404"],"default":"404"},"title":{"type":"string","enum":["Not Found"],"default":"Not Found"},"message":{"type":"string","default":"The server cannot find the requested resource."},"timestamp":{"description":"The time that the error occurred. All dates in the JSON payloads are represented in ISO 8601 date-time format. \nAll date-time fields in responses must include the timezone.","type":"string","format":"date-time"},"type":{"type":"string","enum":["INVALID_REQUEST_ERROR"],"default":"INVALID_REQUEST_ERROR"},"param":{"description":"The parameter the error relates to if the error is parameter-specific. You can use this to display a message near the correct form field, for example.","type":"string"}}}],"required":["code","title","message","type"],"additionalProperties":false},"httpError429":{"title":"HTTP 429 Error","type":"object","description":"The resource exists the number of requests has exceeded the specified quota.","allOf":[{"$ref":"#/components/schemas/ErrorResp"},{"properties":{"code":{"type":"string","enum":["429"],"default":"429"},"title":{"type":"string","enum":["Too Many Requests"],"default":"Too Many Requests"},"message":{"type":"string","default":"The number of requests from this client is restricted to a specified quota."},"timestamp":{"description":"The time that the error occurred. All dates in the JSON payloads are represented in ISO 8601 date-time format. \nAll date-time fields in responses must include the timezone.","type":"string","format":"date-time"},"type":{"type":"string","enum":["RATE_LIMIT_ERROR"],"default":"RATE_LIMIT_ERROR"},"param":{"description":"The parameter the error relates to if the error is parameter-specific. You can use this to display a message near the correct form field, for example.","type":"string"}}}],"required":["code","title","message","type"],"additionalProperties":false},"httpError500":{"title":"HTTP 500 Error","type":"object","description":"Unexpected Server Error","allOf":[{"$ref":"#/components/schemas/ErrorResp"},{"properties":{"code":{"type":"string","enum":["500"],"default":"500"},"title":{"type":"string","enum":["Internal Server Error"],"default":"Internal Server Error"},"message":{"type":"string","default":"The server encountered an unexpected condition which prevented it from fulfilling the request."},"timestamp":{"description":"The time that the error occurred. All dates in the JSON payloads are represented in ISO 8601 date-time format. \nAll date-time fields in responses must include the timezone.","type":"string","format":"date-time"},"type":{"type":"string","enum":["API_ERROR"],"default":"API_ERROR"},"param":{"description":"The parameter the error relates to if the error is parameter-specific. You can use this to display a message near the correct form field, for example.","type":"string"}}}],"required":["code","title","message","type"],"additionalProperties":false},"httpError503":{"title":"HTTP 503 Error","type":"object","description":"Service Unavailable Error","allOf":[{"$ref":"#/components/schemas/ErrorResp"},{"properties":{"code":{"type":"string","enum":["503"],"default":"503"},"title":{"type":"string","enum":["Service Unavailable"],"default":"Service Unavailable"},"message":{"type":"string","default":"The server is not ready to handle the request. If specified please check the <strong>Retry-After</strong> for the time period specified for recovery/re-attempt of request."},"timestamp":{"description":"The time that the error occurred. All dates in the JSON payloads are represented in ISO 8601 date-time format. \nAll date-time fields in responses must include the timezone.","type":"string","format":"date-time"},"type":{"type":"string","enum":["API_ERROR"],"default":"API_ERROR"},"param":{"description":"The parameter the error relates to if the error is parameter-specific. You can use this to display a message near the correct form field, for example.","type":"string"}}}],"required":["code","title","message","type"],"additionalProperties":false},"httpError504":{"title":"HTTP 504 Error","type":"object","description":"Gateway Timeout Error","allOf":[{"$ref":"#/components/schemas/ErrorResp"},{"properties":{"code":{"type":"string","enum":["504"],"default":"504"},"title":{"type":"string","enum":["Gateway Timeout"],"default":"Gateway Timeout"},"message":{"type":"string","default":"The server, while acting as a gateway or proxy, did not get a response in time from the upstream server that it needed in order to complete the request."},"timestamp":{"description":"The time that the error occurred. All dates in the JSON payloads are represented in ISO 8601 date-time format. \nAll date-time fields in responses must include the timezone.","type":"string","format":"date-time"},"type":{"type":"string","enum":["API_ERROR"],"default":"API_ERROR"},"param":{"description":"The parameter the error relates to if the error is parameter-specific. You can use this to display a message near the correct form field, for example.","type":"string"}}}],"required":["code","title","message","type"],"additionalProperties":false}},"responses":{"400":{"description":"Bad Request","content":{"application/json":{"schema":{"allOf":[{"$ref":"#/components/schemas/httpError400"},{"properties":{"param":{"description":"The parameter the error relates to if the error is parameter-specific. You can use this to display a message near the correct form field, for example.","type":"string"},"additionalProperties":{"type":"object","additionalProperties":{"type":"object"}}}}],"required":["code","title","message","type"]}}}},"401":{"description":"Unauthorised Request","content":{"application/json":{"schema":{"allOf":[{"$ref":"#/components/schemas/httpError401"},{"properties":{"param":{"description":"The parameter the error relates to if the error is parameter-specific. You can use this to display a message near the correct form field, for example.","type":"string"},"additionalProperties":{"type":"object","additionalProperties":{"type":"object"}}}}],"required":["code","title","message","type"]}}}},"403":{"description":"Forbidden Request.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/httpError403"}}}},"404":{"description":"Not Found Request","content":{"application/json":{"schema":{"allOf":[{"$ref":"#/components/schemas/httpError404"},{"properties":{"param":{"description":"The parameter the error relates to if the error is parameter-specific. You can use this to display a message near the correct form field, for example.","type":"string"},"additionalProperties":{"type":"object","additionalProperties":{"type":"object"}}}}],"required":["code","title","message","type"]}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"allOf":[{"$ref":"#/components/schemas/httpError429"},{"properties":{"param":{"description":"The parameter the error relates to if the error is parameter-specific. You can use this to display a message near the correct form field, for example.","type":"string"},"additionalProperties":{"type":"object","additionalProperties":{"type":"object"}}}}],"required":["code","title","message","type"]}}}},"500":{"description":"Internal Error","content":{"application/json":{"schema":{"allOf":[{"$ref":"#/components/schemas/httpError500"},{"properties":{"param":{"description":"The parameter the error relates to if the error is parameter-specific. You can use this to display a message near the correct form field, for example.","type":"string"},"additionalProperties":{"type":"object","additionalProperties":{"type":"object"}}}}],"required":["code","title","message","type"]}}}},"503":{"description":"Service Not Available","content":{"application/json":{"schema":{"allOf":[{"$ref":"#/components/schemas/httpError503"},{"properties":{"param":{"description":"The parameter the error relates to if the error is parameter-specific. You can use this to display a message near the correct form field, for example.","type":"string"},"additionalProperties":{"type":"object","additionalProperties":{"type":"object"}}}}],"required":["code","title","message","type"]}}}},"504":{"description":"Service Timeout","content":{"application/json":{"schema":{"allOf":[{"$ref":"#/components/schemas/httpError504"},{"properties":{"param":{"description":"The parameter the error relates to if the error is parameter-specific. You can use this to display a message near the correct form field, for example.","type":"string"},"additionalProperties":{"type":"object","additionalProperties":{"type":"object"}}}}],"required":["code","title","message","type"]}}}}}}}
```

***

### Delete document by id

## Delete document by id

> Delete document by id

```json
{"openapi":"3.0.0","info":{"title":"Verifone Order Internal API","version":"2.63.1-SNAPSHOT"},"tags":[{"name":"Merchant Orders Documentation","description":"Operations to manage documents for merchant orders that require them for AML/KYC."}],"servers":[{"url":"https://api.verifone.com"}],"paths":{"/orders/{orderId}/documents/{documentId}":{"delete":{"tags":["Merchant Orders Documentation"],"summary":"Delete document by id","description":"Delete document by id","operationId":"deleteDocumentById","parameters":[{"$ref":"#/components/parameters/orderIdPathParam"},{"name":"documentId","in":"path","required":true,"description":"Id of the document to be deleted.","schema":{"type":"string","format":"uuid"}}],"responses":{"204":{"description":"Document Deleted"},"400":{"$ref":"#/components/responses/400"},"401":{"$ref":"#/components/responses/401"},"403":{"$ref":"#/components/responses/403"},"404":{"$ref":"#/components/responses/404"},"429":{"$ref":"#/components/responses/429"},"500":{"$ref":"#/components/responses/500"},"503":{"$ref":"#/components/responses/503"},"504":{"$ref":"#/components/responses/504"}}}}},"components":{"parameters":{"orderIdPathParam":{"name":"orderId","in":"path","description":"Verifone allocated ID for the Order.","required":true,"schema":{"$ref":"#/components/schemas/OrderId"}}},"schemas":{"OrderId":{"description":"Verifone allocated ID for the Order.","type":"string","format":"uuid"},"httpError400":{"title":"HTTP 400 Error","type":"object","description":"The request could not be understood by the server due to malformed syntax.","allOf":[{"$ref":"#/components/schemas/ErrorResp"},{"properties":{"code":{"type":"string","enum":["400"],"default":"400"},"title":{"type":"string","enum":["Bad Request"],"default":"Bad Request"},"message":{"type":"string","default":"The request could not be understood by the server due to malformed syntax. The client SHOULD NOT repeat the request without modifications."},"timestamp":{"description":"The time that the error occurred. All dates in the JSON payloads are represented in ISO 8601 date-time format. \nAll date-time fields in responses must include the timezone.","type":"string","format":"date-time"},"type":{"type":"string","enum":["INVALID_REQUEST_ERROR"],"default":"INVALID_REQUEST_ERROR"},"param":{"description":"The parameter the error relates to if the error is parameter-specific. You can use this to display a message near the correct form field, for example.","type":"string"}}}],"required":["code","title","message","type"],"additionalProperties":false},"ErrorResp":{"title":"Error","description":"A common Error object returned as part of the API layer.\n\n. This is modified to become the base class for all of the derived HTTP Error Responses.","type":"object","properties":{"reversalStatus":{"description":"Indicates to the API client if a technical reversal is required or has been completed by Verifone.\n\n|Value|Description|\n|-|-|\n|NONE|Reversal status is not set. This indicates the status of reversal processing is not known and the client should implement default reversal processing.|\n|REQUIRED|A reversal is required by the client.|\n|COMPLETED|A reversal has been completed by verifone or a reversal is not required for this transaction.|","type":"string","enum":["NONE","REQUIRED","COMPLETED"],"default":"NONE"}},"required":["code"]},"httpError401":{"title":"HTTP 401 Error","type":"object","description":"The request must be authenticated to access the resource.","allOf":[{"$ref":"#/components/schemas/ErrorResp"},{"properties":{"code":{"type":"string","enum":["401"],"default":"401"},"title":{"type":"string","enum":["Unauthorised"],"default":"Unauthorised"},"message":{"type":"string","default":"The request requires client authentication."},"timestamp":{"description":"The time that the error occurred. All dates in the JSON payloads are represented in ISO 8601 date-time format. \nAll date-time fields in responses must include the timezone.","type":"string","format":"date-time"},"type":{"type":"string","enum":["AUTHENTICATION_ERROR"],"default":"AUTHENTICATION_ERROR"},"param":{"description":"The parameter the error relates to if the error is parameter-specific. You can use this to display a message near the correct form field, for example.","type":"string"}}}],"required":["code","title","message","type"],"additionalProperties":false},"httpError403":{"title":"HTTP 403 Error","type":"object","description":"The request must be authorised to access the resource.","allOf":[{"$ref":"#/components/schemas/ErrorResp"},{"properties":{"code":{"type":"string","enum":["403"],"default":"403"},"title":{"type":"string","enum":["Forbidden"],"default":"Forbidden"},"message":{"type":"string","default":"The request requires client authorisation to access resource."},"timestamp":{"description":"The time that the error occurred. All dates in the JSON payloads are represented in ISO 8601 date-time format. \nAll date-time fields in responses must include the timezone.","type":"string","format":"date-time"},"type":{"type":"string","enum":["AUTHENTICATION_ERROR"],"default":"AUTHENTICATION_ERROR"},"param":{"description":"The parameter the error relates to if the error is parameter-specific. You can use this to display a message near the correct form field, for example.","type":"string"}}}],"required":["code","title","message","type"],"additionalProperties":false},"httpError404":{"title":"HTTP 404 Error","type":"object","description":"The server cannot find the requested resource.","allOf":[{"$ref":"#/components/schemas/ErrorResp"},{"properties":{"code":{"type":"string","enum":["404"],"default":"404"},"title":{"type":"string","enum":["Not Found"],"default":"Not Found"},"message":{"type":"string","default":"The server cannot find the requested resource."},"timestamp":{"description":"The time that the error occurred. All dates in the JSON payloads are represented in ISO 8601 date-time format. \nAll date-time fields in responses must include the timezone.","type":"string","format":"date-time"},"type":{"type":"string","enum":["INVALID_REQUEST_ERROR"],"default":"INVALID_REQUEST_ERROR"},"param":{"description":"The parameter the error relates to if the error is parameter-specific. You can use this to display a message near the correct form field, for example.","type":"string"}}}],"required":["code","title","message","type"],"additionalProperties":false},"httpError429":{"title":"HTTP 429 Error","type":"object","description":"The resource exists the number of requests has exceeded the specified quota.","allOf":[{"$ref":"#/components/schemas/ErrorResp"},{"properties":{"code":{"type":"string","enum":["429"],"default":"429"},"title":{"type":"string","enum":["Too Many Requests"],"default":"Too Many Requests"},"message":{"type":"string","default":"The number of requests from this client is restricted to a specified quota."},"timestamp":{"description":"The time that the error occurred. All dates in the JSON payloads are represented in ISO 8601 date-time format. \nAll date-time fields in responses must include the timezone.","type":"string","format":"date-time"},"type":{"type":"string","enum":["RATE_LIMIT_ERROR"],"default":"RATE_LIMIT_ERROR"},"param":{"description":"The parameter the error relates to if the error is parameter-specific. You can use this to display a message near the correct form field, for example.","type":"string"}}}],"required":["code","title","message","type"],"additionalProperties":false},"httpError500":{"title":"HTTP 500 Error","type":"object","description":"Unexpected Server Error","allOf":[{"$ref":"#/components/schemas/ErrorResp"},{"properties":{"code":{"type":"string","enum":["500"],"default":"500"},"title":{"type":"string","enum":["Internal Server Error"],"default":"Internal Server Error"},"message":{"type":"string","default":"The server encountered an unexpected condition which prevented it from fulfilling the request."},"timestamp":{"description":"The time that the error occurred. All dates in the JSON payloads are represented in ISO 8601 date-time format. \nAll date-time fields in responses must include the timezone.","type":"string","format":"date-time"},"type":{"type":"string","enum":["API_ERROR"],"default":"API_ERROR"},"param":{"description":"The parameter the error relates to if the error is parameter-specific. You can use this to display a message near the correct form field, for example.","type":"string"}}}],"required":["code","title","message","type"],"additionalProperties":false},"httpError503":{"title":"HTTP 503 Error","type":"object","description":"Service Unavailable Error","allOf":[{"$ref":"#/components/schemas/ErrorResp"},{"properties":{"code":{"type":"string","enum":["503"],"default":"503"},"title":{"type":"string","enum":["Service Unavailable"],"default":"Service Unavailable"},"message":{"type":"string","default":"The server is not ready to handle the request. If specified please check the <strong>Retry-After</strong> for the time period specified for recovery/re-attempt of request."},"timestamp":{"description":"The time that the error occurred. All dates in the JSON payloads are represented in ISO 8601 date-time format. \nAll date-time fields in responses must include the timezone.","type":"string","format":"date-time"},"type":{"type":"string","enum":["API_ERROR"],"default":"API_ERROR"},"param":{"description":"The parameter the error relates to if the error is parameter-specific. You can use this to display a message near the correct form field, for example.","type":"string"}}}],"required":["code","title","message","type"],"additionalProperties":false},"httpError504":{"title":"HTTP 504 Error","type":"object","description":"Gateway Timeout Error","allOf":[{"$ref":"#/components/schemas/ErrorResp"},{"properties":{"code":{"type":"string","enum":["504"],"default":"504"},"title":{"type":"string","enum":["Gateway Timeout"],"default":"Gateway Timeout"},"message":{"type":"string","default":"The server, while acting as a gateway or proxy, did not get a response in time from the upstream server that it needed in order to complete the request."},"timestamp":{"description":"The time that the error occurred. All dates in the JSON payloads are represented in ISO 8601 date-time format. \nAll date-time fields in responses must include the timezone.","type":"string","format":"date-time"},"type":{"type":"string","enum":["API_ERROR"],"default":"API_ERROR"},"param":{"description":"The parameter the error relates to if the error is parameter-specific. You can use this to display a message near the correct form field, for example.","type":"string"}}}],"required":["code","title","message","type"],"additionalProperties":false}},"responses":{"400":{"description":"Bad Request","content":{"application/json":{"schema":{"allOf":[{"$ref":"#/components/schemas/httpError400"},{"properties":{"param":{"description":"The parameter the error relates to if the error is parameter-specific. You can use this to display a message near the correct form field, for example.","type":"string"},"additionalProperties":{"type":"object","additionalProperties":{"type":"object"}}}}],"required":["code","title","message","type"]}}}},"401":{"description":"Unauthorised Request","content":{"application/json":{"schema":{"allOf":[{"$ref":"#/components/schemas/httpError401"},{"properties":{"param":{"description":"The parameter the error relates to if the error is parameter-specific. You can use this to display a message near the correct form field, for example.","type":"string"},"additionalProperties":{"type":"object","additionalProperties":{"type":"object"}}}}],"required":["code","title","message","type"]}}}},"403":{"description":"Forbidden Request.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/httpError403"}}}},"404":{"description":"Not Found Request","content":{"application/json":{"schema":{"allOf":[{"$ref":"#/components/schemas/httpError404"},{"properties":{"param":{"description":"The parameter the error relates to if the error is parameter-specific. You can use this to display a message near the correct form field, for example.","type":"string"},"additionalProperties":{"type":"object","additionalProperties":{"type":"object"}}}}],"required":["code","title","message","type"]}}}},"429":{"description":"Too Many Requests","content":{"application/json":{"schema":{"allOf":[{"$ref":"#/components/schemas/httpError429"},{"properties":{"param":{"description":"The parameter the error relates to if the error is parameter-specific. You can use this to display a message near the correct form field, for example.","type":"string"},"additionalProperties":{"type":"object","additionalProperties":{"type":"object"}}}}],"required":["code","title","message","type"]}}}},"500":{"description":"Internal Error","content":{"application/json":{"schema":{"allOf":[{"$ref":"#/components/schemas/httpError500"},{"properties":{"param":{"description":"The parameter the error relates to if the error is parameter-specific. You can use this to display a message near the correct form field, for example.","type":"string"},"additionalProperties":{"type":"object","additionalProperties":{"type":"object"}}}}],"required":["code","title","message","type"]}}}},"503":{"description":"Service Not Available","content":{"application/json":{"schema":{"allOf":[{"$ref":"#/components/schemas/httpError503"},{"properties":{"param":{"description":"The parameter the error relates to if the error is parameter-specific. You can use this to display a message near the correct form field, for example.","type":"string"},"additionalProperties":{"type":"object","additionalProperties":{"type":"object"}}}}],"required":["code","title","message","type"]}}}},"504":{"description":"Service Timeout","content":{"application/json":{"schema":{"allOf":[{"$ref":"#/components/schemas/httpError504"},{"properties":{"param":{"description":"The parameter the error relates to if the error is parameter-specific. You can use this to display a message near the correct form field, for example.","type":"string"},"additionalProperties":{"type":"object","additionalProperties":{"type":"object"}}}}],"required":["code","title","message","type"]}}}}}}}
```


---

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

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://docs.verifone.com/api-reference/open-api-references/order-service/aml-documents.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
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.
