Skip to main content
Upload a document to OpenAI for use with Vector Stores and file search. Return an OpenAI file ID that can be referenced in subsequent vector store actions.
External DocumentationTo learn more, visit the OpenAI documentation.

Parameters

ParameterDescription
Expires After - SecondsThe number of seconds after which the file will expire. Must be between 3600 (1 hour) and 2592000 (30 days).

Note: By default, files with Purpose - Batch expire after 30 days and all other files are persisted until they are manually deleted.
File IdentifierThe identifier of the file.

A file identifier represents a file created or referenced earlier in the workflow (for example, from a file action or another step that produces a file).

See Using with Files in Workflows for more details.
PurposeThe intended purpose of the uploaded file.

Example Output

{
	"id": "file-XjGxS3KTG0uNmNOK362iJua3",
	"object": "file",
	"bytes": 140,
	"created_at": 1613779121,
	"filename": "document.txt",
	"purpose": "user_data"
}

Workflow Library Example

Upload File with Openai and Send Results Via Email
Workflow LibraryPreview this Workflow on desktop