import { Crevio } from "@crevio/sdk";
const crevio = new Crevio({
apiKey: process.env["CREVIO_API_KEY"] ?? "",
});
async function run() {
const result = await crevio.files.get({
id: "<id>",
});
console.log(result);
}
run();{
"object": "<string>",
"id": "<string>",
"source_type": {},
"upload_status": {},
"url": {},
"created_at": {},
"updated_at": {},
"filename": "<string>",
"content_type": "<string>",
"size": 123,
"provider": "<string>",
"file_url": "<string>"
}Returns a single file by its ID
import { Crevio } from "@crevio/sdk";
const crevio = new Crevio({
apiKey: process.env["CREVIO_API_KEY"] ?? "",
});
async function run() {
const result = await crevio.files.get({
id: "<id>",
});
console.log(result);
}
run();{
"object": "<string>",
"id": "<string>",
"source_type": {},
"upload_status": {},
"url": {},
"created_at": {},
"updated_at": {},
"filename": "<string>",
"content_type": "<string>",
"size": 123,
"provider": "<string>",
"file_url": "<string>"
}API key in the format: Bearer {api_token}
File ID (e.g., "file_abc123")
Was this page helpful?