Create presigned URL for request file upload to S3

Generates a presigned URL for uploading a file to S3. This endpoint handles deduplication by checking if a file with the same MD5 hash already exists.

Authentication

x-api-keystring
API key authentication

Request

This endpoint expects an object.
toolkit_slugstringRequired

Slug of the app where this file belongs to. Example: “gmail”, “slack”, “github”

tool_slugstringRequired

Slug of the action where this file belongs to. Example: “GMAIL_SEND_EMAIL”, “SLACK_UPLOAD_FILE”

filenamestringRequired

Name of the original file. Example: “quarterly_report.pdf”

mimetypestringRequired

Mime type of the original file. Example: “application/pdf”, “image/png”

md5stringRequired

MD5 hash of the file for deduplication and integrity verification. Example: “a1b2c3d4e5f6a7b8c9d0e1f2a3b4c5d6”

Response

Successfully created upload URL for request file
idstring

ID of the request file. Example: “req_file_9mZn4qR8sXwT”

keystring

Object storage upload location. Example: “projects/prj_xyz789/requests/slack/SLACK_UPLOAD_FILE/document_9mZn4q.docx”

new_presigned_urlstring
Presigned URL for upload. Example: "https://storage.composio.dev/projects/prj_xyz789/requests/slack/document_9mZn4q.docx?X-Amz-Algorithm=AWS4-HMAC-SHA256&X-Amz-Expires=3600..."
metadataobject
newPresignedUrlstringDeprecated
[DEPRECATED] Use new_presigned_url instead. Presigned URL for upload. Example: "https://storage.composio.dev/projects/prj_xyz789/requests/slack/document_9mZn4q.docx?X-Amz-Algorithm=AWS4-HMAC-SHA256&X-Amz-Expires=3600..."
typeenumDeprecated

[DEPRECATED] Indicates this is a new file that needs to be uploaded

Allowed values:

Errors