This object represents files hosted on Stripe’s servers. You can upload files with the create file request (for example, when uploading dispute evidence). Stripe also creates files independently (for example, the results of a Sigma scheduled query).
Related guide: File upload guide
Attributes
- idstring
Unique identifier for the object.
- purposeenum
The purpose of the uploaded file.
Possible enum valuesaccount_requirement Additional documentation requirements that can be requested for an account.
additional_verification Additional verification for custom accounts.
business_icon A business icon.
business_logo A business logo.
customer_signature Customer signature image.
dispute_evidence Evidence to submit with a dispute response.
finance_report_ run User-accessible copies of query results from the Reporting dataset.
financial_account_ statement Financial account statements.
identity_document A document to verify the identity of an account owner during account provisioning.
identity_document_ downloadable Image of a document collected by Stripe Identity.
Show 10 more - typenullable string
The returned file type (for example,
csv,pdf,jpg, orpng).
More attributes
- objectstring
- createdtimestamp
- expires_
atnullable timestamp - filenamenullable string
- linksnullable object
- sizeinteger
- titlenullable string
- urlnullable string
{ "id": "file_1Mr4LDLkdIwHu7ixFCz0dZiH", "object": "file", "created": 1680116847, "expires_at": 1703444847, "filename": "file.png", "links": { "object": "list", "data": [], "has_more": false, "url": "/v1/file_links?file=file_1Mr4LDLkdIwHu7ixFCz0dZiH" }, "purpose": "dispute_evidence", "size": 8429, "title": null, "type": "png", "url": "https://files.stripe.com/v1/files/file_1Mr4LDLkdIwHu7ixFCz0dZiH/contents"}To upload a file to Stripe, you need to send a request of type multipart/form-data. Include the file you want to upload in the request, and the parameters for creating a file.
All of Stripe’s officially supported Client libraries support sending multipart/form-data.
Parameters
- fileobjectRequired
A file to upload. Make sure that the specifications follow RFC 2388, which defines file transfers for the
multipart/form-dataprotocol. - purposeenumRequired
The purpose of the uploaded file.
Possible enum valuesaccount_requirement Additional documentation requirements that can be requested for an account.
additional_verification Additional verification for custom accounts.
business_icon A business icon.
business_logo A business logo.
customer_signature Customer signature image.
dispute_evidence Evidence to submit with a dispute response.
identity_document A document to verify the identity of an account owner during account provisioning.
issuing_regulatory_ reporting Additional regulatory reporting requirements for Issuing.
pci_document A self-assessment PCI questionnaire.
platform_terms_ of_ service A copy of the platform’s Terms of Service.
Show 5 more
More parameters
- file_
link_ dataobject
Returns
Returns the file object.
{ "id": "file_1Mr4LDLkdIwHu7ixFCz0dZiH", "object": "file", "created": 1680116847, "expires_at": 1703444847, "filename": "file.png", "links": { "object": "list", "data": [], "has_more": false, "url": "/v1/file_links?file=file_1Mr4LDLkdIwHu7ixFCz0dZiH" }, "purpose": "dispute_evidence", "size": 8429, "title": null, "type": "png", "url": "https://files.stripe.com/v1/files/file_1Mr4LDLkdIwHu7ixFCz0dZiH/contents"}