Skip to content

/merchant/files Upload Onboarding File ​

Background ​

/merchant/files is the second step of sub-merchant creation. One request uploads one file and attaches it to the onboarding record returned by Submit sub-merchant profile. The record must belong to the primary merchant in the request header, and its status must be draft.

Before confirmation, upload at least one file in each of the five required categories. The same onboarding record can be uploaded to more than once. A later file in the same category is appended and does not replace earlier files. After the uploads, call Confirm submission.

Integration ​

The request headers X-Merchant-Id, X-Timestamp, X-Nonce, Digest, and Authorization are required. Digest is computed over the final raw multipart bytes. This endpoint does not accept seqNo.

Endpoint ​

ItemValue
MethodPOST
Path/merchant/files
Content-Typemultipart/form-data
PurposeUpload one material and attach it to the onboarding record

The request Content-Type must be multipart/form-data. It only means the body is a form that contains a file. The file format is declared by the form field contentType below. The Content-Type of the file part itself is neither read nor stored.

Request Fields ​

FieldLocationTypeLengthRequiredDescription
onboardingNoformstring36YesOnboarding number returned by the profile endpoint.
categoryformstring32YesMaterial category. See the enum below.
contentTypeformstring32YesFile format. See the enum below. After validation, this value is stored. The response does not return it.
fileformfile-YesFile content. Greater than 0 and no larger than 8MB. The file name is the last segment of filename.

category enum ​

PSP and ISV sub-merchants use the same document checklist. Send one category and one file per upload. The platform attaches the file by category; do not send arrays of file IDs in the create or confirm JSON.

Upload categoryCorresponding document fieldDocumentRequired for review
oms_company_registrationcompanyRegistrationFileCompany registration certificateAt least one
oms_articles_of_associationarticlesOfAssociationFileArticles of association and applicable amendmentsAt least one
oms_legal_rep_identitylegalRepIdentityFileLegal representative’s identity documentAt least one
oms_shareholder_ubo_proofshareholderUboProofFileEvidence of shareholders and ultimate beneficial ownersAt least one
oms_company_address_proofcompanyAddressProofFileProof of company addressAt least one
oms_other_fileotherFileOther supporting documentsOptional

contentType enum ​

ValueDescription
application/pdfPDF
image/jpegJPEG
image/pngPNG
image/webpWebP
image/gifGIF

Request Example ​

http
POST /merchant/files HTTP/1.1
Content-Type: multipart/form-data; boundary=----AdopayBoundary
X-Merchant-Id: 92315566000120
X-Timestamp: 1790200000
X-Nonce: 550e8400-e29b-41d4-a716-446655440001
Digest: SHA-256=<Base64 digest>
Authorization: Signature keyId="v1",alg="ES256",headers="(request-target) x-timestamp x-nonce digest",signature="<ES256_SIGNATURE_BASE64>"

------AdopayBoundary
Content-Disposition: form-data; name="onboardingNo"

6f1c0e3a-1b2c-4d5e-8f90-a1b2c3d4e5f6
------AdopayBoundary
Content-Disposition: form-data; name="category"

oms_company_registration
------AdopayBoundary
Content-Disposition: form-data; name="contentType"

application/pdf
------AdopayBoundary
Content-Disposition: form-data; name="file"; filename="business-license.pdf"
Content-Type: application/octet-stream

<file bytes>
------AdopayBoundary--

The Content-Type: application/octet-stream on the file part in this example is not the format. The format is the form field contentType.

Response Fields ​

status 200 means the file has been stored and attached to the matching material. Confirm does not send fileId again.

FieldTypeLengthAlways ReturnedDescription
statusint4YesResponse code.
msgstring128YesCorresponds to status.
data.fileIdstring32YesFile id.
data.fileNamestring255YesStored file name.
data.fileSizeint19YesSize in bytes.
data.categorystring32YesSame as the request category. Values are in the enum above.

Response Example ​

json
{
  "status": 200,
  "msg": "sucesso",
  "data": {
    "fileId": "10086001",
    "fileName": "business-license.pdf",
    "fileSize": 204800,
    "category": "oms_company_registration"
  }
}

Business Rules ​

The following cases are rejected and do not produce a fileId:

  • The onboarding number does not exist, does not belong to this primary merchant, or the status is not draft.
  • category is not in the enum, or does not match the access mode of the onboarding record.
  • contentType is empty, is not in the enum, or does not match the file content.
  • The file is empty, or larger than 8MB.

Each category may contain at most 5 files when the partner confirms submission. This endpoint still appends one file per call and does not reject by count.

Response Codes ​