About Partner Files API

Overview

The Partner Files API enables merchants to both upload and download files pertaining to their disputes. The Partner Files API provides you with the following actions:

Explore the sections below to learn about the files endpoints and their requirements.


Basic Requirements

Authentication

All Partner Files API endpoints require partner authentication.

Idempotency

For idempotent requests, the idempotency key has an expiration date of 24 hours. Idempotency keys are passed in using the Idempotency-Key header.


Upload Dispute Evidence (Upload File)

POST /api/partner/v1/files

This endpoint is designed to upload the file (evidence) by making a multipart/form-data request on an open dispute.

Idempotency: Yes

Request Body Parameters:

Field NameData TypeDescription
file_name requiredstringName of the file. The filename can be a maximum length of 25 characters long and may include alphanumeric characters, hyphens, underscores, spaces, and periods.
file requiredstringA file to upload (binary format).
purpose requiredstringAn enum indicating the purpose of the uploaded file. Additional purpose enums can be added depending on the use case
Value:

-dispute_evidence
merchant_idstringThe ID of the merchant that the file is associated with.

Response Object:

Field NameData TypeDescription
file_idstringID of the file.
createdstringTime at which the file is uploaded, in ISO 8601 UTC format.
purposestringThe purpose of the file. Possible values:

-dispute_evidence
file_namestringName of the file.

File Purpose Restrictions:

Field PurposeSupported MimetypesMax Size
dispute_evidencePDF5MB

Download Dispute Evidence (Download File)

GET /api/partner/v1/files/{file_id}

Idempotency: No

Request Body Parameters:

Field NameData TypeDescription
merchant_idstringThe ID of the merchant that the file is associated with. merchant_id is required if the file is uploaded with a merchant_id in POST /api/partner/v1/files.

Response Object:

Field NameData TypeDescription
idstringUnique identifier for the File object.
download_urlstringThe URL from which the file can be downloaded.
download_url_expires_attimestampA future timestamp after which the download_url will no longer be usable. (15 minutes)