Skip to content

Commit 3059f8d

Browse files
committed
feat: files readme
1 parent 04b35e5 commit 3059f8d

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

README.md

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -70,10 +70,10 @@ const client = new AI21({
7070
apiKey: process.env.AI21_API_KEY, // or pass it in directly
7171
});
7272

73-
const fileUploadResponse = await client.files.upload({
74-
file: 'path/to/file',
73+
const fileUploadResponse = await client.files.create({
74+
file: './articles/article1.pdf',
7575
labels: ['science', 'biology'],
76-
path: 'path/to/file',
76+
path: 'virtual-path/to/science-articles',
7777
});
7878

7979

0 commit comments

Comments
 (0)