Create a file
POST https://files.stripe.com/v1/files
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
.
Request Body
[{"name"=>"file", "value"=>nil, "datatype"=>"null"}, {"name"=>"purpose", "value"=>"<string>", "datatype"=>"string"}, {"name"=>"expand", "value"=>"[\"<string>\",\"<string>\"]", "datatype"=>"string"}, {"name"=>"file_link_data", "value"=>"{\"create\":\"<boolean>\",\"expires_at\":\"<unix-time>\",\"metadata\":\"<object>\"}", "datatype"=>"string"}]
HEADERS
Key | Datatype | Required | Description |
---|---|---|---|
Content-Type | string |