openapi: 3.0.2 info: title: Finix Authorizations Files API description: $ref: api-descriptions/main.md contact: name: Finix url: https://finix.com email: support@finixpayments.com version: '2022-02-01' servers: - description: Sandbox server to be used for testing and development url: https://finix.sandbox-payments-api.com security: - BasicAuth: [] tags: - name: Files description: $ref: api-descriptions/tags/files.md paths: /files: post: summary: Create a File operationId: createFiles responses: '200': $ref: '#/components/responses/File' '401': $ref: '#/components/responses/ErrorUnauthorized' '403': $ref: '#/components/responses/ErrorForbidden403' '404': $ref: '#/components/responses/ErrorNotFound' '406': $ref: '#/components/responses/Error406NotAcceptable' x-codeSamples: - lang: cURL label: curl source: $ref: xcode/curl/files/createfile.md description: "Before uploading a file, you need to create a `File` resource. \n\nOnce created, you can [upload](/guides/onboarding/uploading-files-to-finix/#how-to-upload-a-file-to-finix) your file to the new `File` resource." requestBody: $ref: '#/components/requestBodies/CreateFileRequest' tags: - Files x-java-method-name: create x-python-method-name: create get: summary: List All Files tags: - Files responses: '200': $ref: '#/components/responses/FilesList' '401': $ref: '#/components/responses/ErrorUnauthorized' '403': $ref: '#/components/responses/ErrorForbidden403' '404': $ref: '#/components/responses/ErrorNotFound' '406': $ref: '#/components/responses/Error406NotAcceptable' operationId: listFiles description: List all the `File` resources you've created. parameters: - $ref: '#/components/parameters/QueryAfterCursor' - $ref: '#/components/parameters/QueryLimit' - $ref: '#/components/parameters/QueryIdFilter' - $ref: '#/components/parameters/QueryCreatedAtGteFilter' - $ref: '#/components/parameters/QueryCreatedAtLteFilter' - $ref: '#/components/parameters/QueryUpdatedAtGteFilter' - $ref: '#/components/parameters/QueryUpdatedAtLteFilter' - $ref: '#/components/parameters/QueryBeforeCursor' x-java-method-name: list x-group-parameters: true x-codeSamples: - lang: cURL label: curl source: 'curl "https://finix.sandbox-payments-api.com/files" \ -H "Finix-Version: 2022-02-01" \ -u USsRhsHYZGBPnQw8CByJyEQW:8a14c2f9-d94b-4c72-8f5c-a62908e5b30e ' x-python-method-name: list x-returns-list: true /files/{file_id}: parameters: - schema: type: string name: file_id in: path required: true description: Your `File` ID. get: summary: Fetch a File tags: - Files responses: '200': $ref: '#/components/responses/File' '401': $ref: '#/components/responses/ErrorUnauthorized' '403': $ref: '#/components/responses/ErrorForbidden403' '404': $ref: '#/components/responses/ErrorNotFound' '406': $ref: '#/components/responses/Error406NotAcceptable' operationId: getFile description: Retrieve the details of a `File` resource. x-java-method-name: get x-codeSamples: - lang: cURL label: curl source: 'curl "https://finix.sandbox-payments-api.com/files/FILE_abki8bFEjq51eZ5w2pYFik" \ -H "Finix-Version: 2022-02-01" \ -u USsRhsHYZGBPnQw8CByJyEQW:8a14c2f9-d94b-4c72-8f5c-a62908e5b30e ' x-python-method-name: get /files/{file_id}/external_links: parameters: - schema: type: string name: file_id in: path required: true description: Your `File` ID. get: summary: List All External Links tags: - Files responses: '200': $ref: '#/components/responses/ExternalLinksList' '401': $ref: '#/components/responses/ErrorUnauthorized' '403': $ref: '#/components/responses/ErrorForbidden403' '404': $ref: '#/components/responses/ErrorNotFound' '406': description: Not Acceptable operationId: listExternalLinks description: List the previously created `external_links` for a `File`. parameters: - $ref: '#/components/parameters/QueryAfterCursor' - $ref: '#/components/parameters/QueryLimit' - $ref: '#/components/parameters/QueryIdFilter' - $ref: '#/components/parameters/QueryCreatedAtGteFilter' - $ref: '#/components/parameters/QueryCreatedAtLteFilter' - $ref: '#/components/parameters/QueryUpdatedAtGteFilter' - $ref: '#/components/parameters/QueryUpdatedAtLteFilter' - $ref: '#/components/parameters/QueryBeforeCursor' x-group-parameters: true x-codeSamples: - lang: cURL label: curl source: 'curl "https://finix.sandbox-payments-api.com/files/FILE_abki8bFEjq51eZ5w2pYFik/external_links" \ -H "Finix-Version: 2022-02-01" \ -u USsRhsHYZGBPnQw8CByJyEQW:8a14c2f9-d94b-4c72-8f5c-a62908e5b30e ' x-python-method-name: list_external_links x-returns-list: true post: summary: Create an External Link operationId: createExternalLink responses: '200': $ref: '#/components/responses/ExternalLink' '401': $ref: '#/components/responses/ErrorUnauthorized' '403': $ref: '#/components/responses/ErrorForbidden403' '404': $ref: '#/components/responses/ErrorNotFound' '406': $ref: '#/components/responses/Error406NotAcceptable' x-codeSamples: - lang: cURL label: curl source: $ref: xcode/curl/files/external-link.md description: Create an `external_link` resource to share with users so they can upload files directly from their browser. For more info, see [Uploading files to Finix](/guides/onboarding/uploading-files-to-finix/). requestBody: $ref: '#/components/requestBodies/CreateExternalLinkRequest' tags: - Files x-python-method-name: create_external_link /files/{file_id}/upload: parameters: - schema: type: string name: file_id in: path required: true description: The ID of the `File` that was created to upload the file. post: summary: Upload files Directly operationId: uploadFile responses: '200': $ref: '#/components/responses/File' '401': $ref: '#/components/responses/ErrorUnauthorized' '403': $ref: '#/components/responses/ErrorForbidden403' '404': $ref: '#/components/responses/ErrorNotFound' '406': $ref: '#/components/responses/Error406NotAcceptable' description: Upload files directly with a `multipart/form-data` request. parameters: null x-java-method-name: upload x-codeSamples: - lang: cURL label: curl source: $ref: xcode/curl/files/uploadfile.md tags: - Files requestBody: $ref: '#/components/requestBodies/UploadFileRequest' x-python-method-name: upload /files/{file_id}/download: parameters: - schema: type: string name: file_id in: path required: true description: The ID of the `File` that was created to upload the file. get: summary: Download a File tags: - Files responses: '200': $ref: '#/components/responses/FileDownload' '401': $ref: '#/components/responses/ErrorUnauthorized' '403': $ref: '#/components/responses/ErrorForbidden403' '404': $ref: '#/components/responses/ErrorNotFound' '406': $ref: '#/components/responses/Error406NotAcceptable' operationId: downloadFile x-java-method-name: download description: Download a file that was uploaded to a `File` resource. x-codeSamples: - lang: cURL label: curl source: "curl \"https://finix.sandbox-payments-api.com/files/FILE_bJecqoRPasStGPVpvKHtgA/download\" \\\n -H \"Finix-Version: 2022-02-01\" \\\n -u USsRhsHYZGBPnQw8CByJyEQW:8a14c2f9-d94b-4c72-8f5c-a62908e5b30e\n" parameters: - schema: type: string enum: - 'true' - 'false' in: query name: stream description: Stream the contents of the `File` so it's displayed inline in the user's web browser. x-python-method-name: download /files/{file_id}/external_links/{external_link_id}: parameters: - schema: type: string name: file_id in: path required: true description: The ID of the `File` that has the links you want to retrieve. - schema: type: string name: external_link_id in: path required: true description: The ID of the `external_link` that you want to retireve. get: summary: Fetch an External LInk tags: - Files responses: '200': $ref: '#/components/responses/ExternalLink' '401': $ref: '#/components/responses/ErrorUnauthorized' '403': $ref: '#/components/responses/ErrorForbidden403' '404': $ref: '#/components/responses/ErrorNotFound' '406': $ref: '#/components/responses/Error406NotAcceptable' operationId: getExternalLink description: Fetch a previously created `external_link` resource. x-codeSamples: - lang: cURL label: curl source: "curl \"https://finix.sandbox-payments-api.com/files/FILE_bJecqoRPasStEPVpvKHtgA/external_links/EL_dh5YS66GePpkeSVyL4VdBL\" \\\n -H \"Finix-Version: 2022-02-01\" \\\n -u USsRhsHYZGBPnQw8CByJyEQW:8a14c2f9-d94b-4c72-8f5c-a62908e5b30e\n" x-python-method-name: get_external_link components: schemas: Error406NotAcceptable: type: object properties: total: type: integer _embedded: type: object properties: errors: type: array items: type: object additionalProperties: true properties: code: type: string enum: - NOT_FOUND logref: $ref: '#/components/schemas/LogRef' message: type: string _links: type: object properties: source: type: object properties: href: type: string title: '' File: type: object x-examples: {} title: File properties: id: type: string description: The ID of the `File` resource. created_at: $ref: '#/components/schemas/CreatedAt' updated_at: $ref: '#/components/schemas/UpdatedAt' application_id: type: string description: The ID of the `Application` that the `File` was created under. display_name: type: string description: 'The name of the `File` object. If you don''t provide a name, Finix will name the object with the convention: **FILE_(file_id)**.' extension: description: The extension of the file. type: string nullable: true identity_id: type: string description: ID of the `Identity` that created the `File`. nullable: true linked_to: type: string description: The resource ID the `File` is linked to. linked_type: type: string description: Autofills to **Merchant**. platform_id: type: string description: The ID of the `Platform` that the `File` was created under. status: type: string description: 'The status of the file''s review. The statuses available includes:
  • REQUIRES_UPLOAD: A file still needs to be uploaded to the file object.
  • PENDING: Finix''s underwriting team is still reviewing the uploaded files.
  • INVALID: The file couldn''t be read.
  • UPLOADED: The file has been uploaded to the resource.' tags: $ref: '#/components/schemas/Tags' type: type: string description: The type of document. ExternalLink: type: object x-examples: {} properties: id: type: string description: The ID of the `external_Link` resource. created_at: $ref: '#/components/schemas/CreatedAt' duration: type: string description: Details how long the `url` will be avalible for users to upload files to. nullable: true expired: type: boolean description: