ExOpenAI.Files (ex_openai.ex v0.2.1) View Source

Modules for interacting with the files group of OpenAI APIs

API Reference: https://platform.openai.com/docs/api-reference/files

Link to this section Summary

Functions

Returns the contents of the specified file

Link to this section Functions

Link to this function

download_file(file_id, opts \\ [])

View Source

Specs

download_file(String.t(), []) :: {:ok, String.t()} | {:error, any()}

Returns the contents of the specified file

Endpoint: https://api.openai.com/v1/files/{file_id}/content

Method: GET

Docs: https://platform.openai.com/docs/api-reference/files


Required Arguments:

  • file_id

Optional Arguments: