Create File
Changed onCreates a file and returns a presigned destination to upload its bytes to. PUT the bytes to upload_url (single-part), or to each of multipart_upload_urls and then call Complete File Multipart Upload. Once the bytes land the file becomes ready, and its ID can be attached wherever a file is accepted — account legal documents, dispute evidence documents. For a step-by-step walkthrough of single-part and multipart uploads, see the direct file uploads guide.
Request
- Base URL: https://api.whop.com/api/v1
- URL: https://api.whop.com/api/v1/files
- Auth: HTTP bearer
Headers
A unique key that makes this request safe to retry. See Idempotent requests.
Request body
Example request
{
"byte_size": 15728640,
"filename": "terms.pdf",
"multipart": true,
"visibility": "public"
}Response
file created with a single-part upload destination
Example response
{
"content_type": "application/pdf",
"created_at": "2026-01-01T12:00:00.000Z",
"filename": "evidence.pdf",
"id": "file_xxxxxxxxxxxxxx",
"multipart_chunk_size": 5242880,
"multipart_upload_id": "upload-id",
"multipart_upload_urls": [
{
"part_number": 1,
"url": "https://whop-assets-example.s3.amazonaws.com/uploads/2026-01-01/xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx/application.pdf"
}
],
"object": "file",
"size": 9670,
"upload_headers": {},
"upload_status": "pending",
"upload_url": "https://whop-assets-example.s3.amazonaws.com/uploads/2026-01-01/xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx/application.pdf",
"url": "https://whop-assets-example.s3.amazonaws.com/uploads/audio/2026-01-01/xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx",
"visibility": "private"
}Changes
- info
added the required property
to the response with the status - info
added the required property
to the response with the status - info
added the required property
to the response with the status - info
added the required property
to the response with the status - info
added the required property
to the response with the status - info
added the required property
to the response with the status
- info
- breaking
request property
was restricted to a list of enum values - breaking
removed
subschema #2from therequest propertyoneOflist - breaking
the
request property type changed from no type tostring - breaking
removed the success response with the status
- warning
removed the optional property
/from the response with the status - warning
removed the optional property
/from the response with the status - info
added the new optional
headerrequest parameterApi-Version-Dateto all path's operations - info
added the new optional
headerrequest parameterIdempotency-Key - info
added the new optional request property
- info
added the new optional request property
- info
request body became optional
- info
added the new
privateenum value to the request property - info
added the new
publicenum value to the request property - info
added the non-success response with the status
- info
removed the non-success response with the status
- info
removed the non-success response with the status
- info
removed the non-success response with the status
- info
removed the non-success response with the status
- info
removed the non-success response with the status
- info
added the success response with the status
- breaking