Skip to content
For the complete documentation index, see llms.txt. Markdown versions of documentation pages are available by appending .md to the page URL.
Primary navigation
Theme

Retrieve container file content

client.containers.files.content.retrieve(fileID, params, options?): Response
GET
/containers/{container_id}/files/{file_id}/content

Retrieve Container File Content

Parameters
fileID: string
params: ContentRetrieveParams { container_id }
Returns
unnamed_schema_5 = Response

Retrieve container file content

import OpenAI from 'openai';

const client = new OpenAI({
  apiKey: process.env['OPENAI_API_KEY'], // This is the default and can be omitted
});

const content = await client.containers.files.content.retrieve('file_id', {
  container_id: 'container_id',
});

console.log(content);

const data = await content.blob();
console.log(data);
Response example
<binary content of the file>
Returns Examples
Response example
<binary content of the file>