@inductiv/node-red-openai-api 1.103.0 → 6.27.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (69) hide show
  1. package/README.md +213 -86
  2. package/examples/realtime/client-secrets.json +182 -0
  3. package/examples/responses/computer-use.json +142 -0
  4. package/examples/responses/mcp.json +1 -1
  5. package/examples/responses/phase.json +102 -0
  6. package/examples/responses/tool-search.json +107 -0
  7. package/examples/responses/websocket.json +172 -0
  8. package/internals/openai-api-features-v6.23.0-v6.27.0.md +96 -0
  9. package/lib.js +12696 -15003
  10. package/locales/en-US/node.json +50 -1
  11. package/node.html +1723 -1012
  12. package/node.js +204 -54
  13. package/package.json +9 -7
  14. package/src/assistants/help.html +1 -77
  15. package/src/audio/help.html +1 -37
  16. package/src/batch/help.html +3 -17
  17. package/src/chat/help.html +11 -89
  18. package/src/container-files/help.html +1 -27
  19. package/src/containers/help.html +8 -18
  20. package/src/conversations/help.html +135 -0
  21. package/src/conversations/methods.js +73 -0
  22. package/src/conversations/template.html +10 -0
  23. package/src/embeddings/help.html +1 -11
  24. package/src/evals/help.html +249 -0
  25. package/src/evals/methods.js +114 -0
  26. package/src/evals/template.html +14 -0
  27. package/src/files/help.html +4 -17
  28. package/src/fine-tuning/help.html +1 -35
  29. package/src/images/help.html +1 -45
  30. package/src/lib.js +53 -1
  31. package/src/messages/help.html +19 -39
  32. package/src/messages/methods.js +13 -0
  33. package/src/messages/template.html +7 -18
  34. package/src/models/help.html +1 -5
  35. package/src/moderations/help.html +1 -5
  36. package/src/node.html +126 -37
  37. package/src/realtime/help.html +209 -0
  38. package/src/realtime/methods.js +45 -0
  39. package/src/realtime/template.html +7 -0
  40. package/src/responses/help.html +286 -63
  41. package/src/responses/methods.js +234 -16
  42. package/src/responses/template.html +21 -1
  43. package/src/responses/websocket.js +150 -0
  44. package/src/runs/help.html +1 -123
  45. package/src/skills/help.html +183 -0
  46. package/src/skills/methods.js +99 -0
  47. package/src/skills/template.html +13 -0
  48. package/src/threads/help.html +1 -15
  49. package/src/uploads/help.html +1 -21
  50. package/src/vector-store-file-batches/help.html +1 -27
  51. package/src/vector-store-file-batches/methods.js +5 -5
  52. package/src/vector-store-files/help.html +1 -25
  53. package/src/vector-store-files/methods.js +4 -7
  54. package/src/vector-stores/help.html +2 -31
  55. package/src/vector-stores/methods.js +5 -11
  56. package/src/vector-stores/template.html +7 -22
  57. package/src/videos/help.html +113 -0
  58. package/src/videos/methods.js +50 -0
  59. package/src/videos/template.html +8 -0
  60. package/src/webhooks/help.html +61 -0
  61. package/src/webhooks/methods.js +40 -0
  62. package/src/webhooks/template.html +4 -0
  63. package/test/openai-methods-mapping.test.js +1559 -0
  64. package/test/openai-node-auth-routing.test.js +206 -0
  65. package/test/openai-responses-websocket.test.js +472 -0
  66. package/test/service-host-editor-template.test.js +56 -0
  67. package/test/service-host-node.test.js +185 -0
  68. package/test/services.test.js +150 -0
  69. package/test/utils.test.js +78 -0
@@ -0,0 +1,183 @@
1
+ <section>
2
+ <details>
3
+ <summary style="font-weight: bold;">🧩 Skills</summary>
4
+ <a href="https://developers.openai.com/api/reference/typescript/resources/skills/" target="_blank">Official Documentation
5
+ <i class="fa fa-external-link fa-sm" aria-hidden="true"></i></a>
6
+
7
+ <h4 style="font-weight: bolder;"> ⋙ List Skills</h4>
8
+ <p>List skills.</p>
9
+ <dl class="message-properties">
10
+ <h4>msg.payload Properties</h4>
11
+ <dt class="optional">
12
+ after
13
+ <span class="property-type">string</span>
14
+ </dt>
15
+ <dd>Pagination cursor for items after this id.</dd>
16
+ <dt class="optional">
17
+ limit
18
+ <span class="property-type">integer</span>
19
+ </dt>
20
+ <dd>Maximum number of skills to return.</dd>
21
+ <dt class="optional">
22
+ order
23
+ <span class="property-type">string</span>
24
+ </dt>
25
+ <dd>Sort order by timestamp. Use <code>asc</code> or <code>desc</code>.</dd>
26
+ </dl>
27
+
28
+ <h4 style="font-weight: bolder;"> ⋙ Create Skill</h4>
29
+ <p>Create a skill.</p>
30
+ <dl class="message-properties">
31
+ <h4>msg.payload Properties</h4>
32
+ <dt class="optional">
33
+ files
34
+ <span class="property-type">file | array</span>
35
+ </dt>
36
+ <dd>Skill files to upload (directory upload) or one zip file.</dd>
37
+ </dl>
38
+
39
+ <h4 style="font-weight: bolder;"> ⋙ Retrieve Skill</h4>
40
+ <p>Retrieve a skill by id.</p>
41
+ <dl class="message-properties">
42
+ <h4>msg.payload Properties</h4>
43
+ <dt>
44
+ skill_id
45
+ <span class="property-type">string</span>
46
+ </dt>
47
+ <dd>The skill id.</dd>
48
+ </dl>
49
+
50
+ <h4 style="font-weight: bolder;"> ⋙ Modify Skill</h4>
51
+ <p>Update the default version for a skill.</p>
52
+ <dl class="message-properties">
53
+ <h4>msg.payload Properties</h4>
54
+ <dt>
55
+ skill_id
56
+ <span class="property-type">string</span>
57
+ </dt>
58
+ <dd>The skill id.</dd>
59
+ <dt>
60
+ default_version
61
+ <span class="property-type">string</span>
62
+ </dt>
63
+ <dd>Version to set as the skill default.</dd>
64
+ </dl>
65
+
66
+ <h4 style="font-weight: bolder;"> ⋙ Delete Skill</h4>
67
+ <p>Delete a skill by id.</p>
68
+ <dl class="message-properties">
69
+ <h4>msg.payload Properties</h4>
70
+ <dt>
71
+ skill_id
72
+ <span class="property-type">string</span>
73
+ </dt>
74
+ <dd>The skill id.</dd>
75
+ </dl>
76
+
77
+ <h4 style="font-weight: bolder;"> ⋙ Get Skill Content</h4>
78
+ <p>Fetch the packaged content for a skill.</p>
79
+ <dl class="message-properties">
80
+ <h4>msg.payload Properties</h4>
81
+ <dt>
82
+ skill_id
83
+ <span class="property-type">string</span>
84
+ </dt>
85
+ <dd>The skill id.</dd>
86
+ </dl>
87
+
88
+ <h4 style="font-weight: bolder;"> ⋙ List Skill Versions</h4>
89
+ <p>List versions for a skill.</p>
90
+ <dl class="message-properties">
91
+ <h4>msg.payload Properties</h4>
92
+ <dt>
93
+ skill_id
94
+ <span class="property-type">string</span>
95
+ </dt>
96
+ <dd>The skill id.</dd>
97
+ <dt class="optional">
98
+ after
99
+ <span class="property-type">string</span>
100
+ </dt>
101
+ <dd>Pagination cursor for versions after this id.</dd>
102
+ <dt class="optional">
103
+ limit
104
+ <span class="property-type">integer</span>
105
+ </dt>
106
+ <dd>Maximum number of versions to return.</dd>
107
+ <dt class="optional">
108
+ order
109
+ <span class="property-type">string</span>
110
+ </dt>
111
+ <dd>Sort order by version number. Use <code>asc</code> or <code>desc</code>.</dd>
112
+ </dl>
113
+
114
+ <h4 style="font-weight: bolder;"> ⋙ Create Skill Version</h4>
115
+ <p>Create a new version for an existing skill.</p>
116
+ <dl class="message-properties">
117
+ <h4>msg.payload Properties</h4>
118
+ <dt>
119
+ skill_id
120
+ <span class="property-type">string</span>
121
+ </dt>
122
+ <dd>The skill id.</dd>
123
+ <dt class="optional">
124
+ default
125
+ <span class="property-type">boolean</span>
126
+ </dt>
127
+ <dd>Whether to set the created version as default.</dd>
128
+ <dt class="optional">
129
+ files
130
+ <span class="property-type">file | array</span>
131
+ </dt>
132
+ <dd>Skill files to upload (directory upload) or one zip file.</dd>
133
+ </dl>
134
+
135
+ <h4 style="font-weight: bolder;"> ⋙ Retrieve Skill Version</h4>
136
+ <p>Retrieve one version from a skill.</p>
137
+ <dl class="message-properties">
138
+ <h4>msg.payload Properties</h4>
139
+ <dt>
140
+ skill_id
141
+ <span class="property-type">string</span>
142
+ </dt>
143
+ <dd>The skill id.</dd>
144
+ <dt>
145
+ version
146
+ <span class="property-type">string</span>
147
+ </dt>
148
+ <dd>The version identifier.</dd>
149
+ </dl>
150
+
151
+ <h4 style="font-weight: bolder;"> ⋙ Delete Skill Version</h4>
152
+ <p>Delete a version from a skill.</p>
153
+ <dl class="message-properties">
154
+ <h4>msg.payload Properties</h4>
155
+ <dt>
156
+ skill_id
157
+ <span class="property-type">string</span>
158
+ </dt>
159
+ <dd>The skill id.</dd>
160
+ <dt>
161
+ version
162
+ <span class="property-type">string</span>
163
+ </dt>
164
+ <dd>The version identifier.</dd>
165
+ </dl>
166
+
167
+ <h4 style="font-weight: bolder;"> ⋙ Get Skill Version Content</h4>
168
+ <p>Fetch packaged content for a specific skill version.</p>
169
+ <dl class="message-properties">
170
+ <h4>msg.payload Properties</h4>
171
+ <dt>
172
+ skill_id
173
+ <span class="property-type">string</span>
174
+ </dt>
175
+ <dd>The skill id.</dd>
176
+ <dt>
177
+ version
178
+ <span class="property-type">string</span>
179
+ </dt>
180
+ <dd>The version identifier.</dd>
181
+ </dl>
182
+ </details>
183
+ </section>
@@ -0,0 +1,99 @@
1
+ const OpenAI = require("openai").OpenAI;
2
+
3
+ async function createSkill(parameters) {
4
+ const openai = new OpenAI(this.clientParams);
5
+ const response = await openai.skills.create(parameters.payload);
6
+ return response;
7
+ }
8
+
9
+ async function getSkill(parameters) {
10
+ const openai = new OpenAI(this.clientParams);
11
+ const { skill_id, ...params } = parameters.payload;
12
+ const response = await openai.skills.retrieve(skill_id, params);
13
+ return response;
14
+ }
15
+
16
+ async function modifySkill(parameters) {
17
+ const openai = new OpenAI(this.clientParams);
18
+ const { skill_id, ...body } = parameters.payload;
19
+ const response = await openai.skills.update(skill_id, body);
20
+ return response;
21
+ }
22
+
23
+ async function deleteSkill(parameters) {
24
+ const openai = new OpenAI(this.clientParams);
25
+ const { skill_id, ...params } = parameters.payload;
26
+ const response = await openai.skills.delete(skill_id, params);
27
+ return response;
28
+ }
29
+
30
+ async function listSkills(parameters) {
31
+ const openai = new OpenAI(this.clientParams);
32
+ const list = await openai.skills.list(parameters.payload);
33
+ return [...list.data];
34
+ }
35
+
36
+ async function getSkillContent(parameters) {
37
+ const openai = new OpenAI(this.clientParams);
38
+ const { skill_id, ...params } = parameters.payload;
39
+ const response = await openai.skills.content.retrieve(skill_id, params);
40
+ return response;
41
+ }
42
+
43
+ async function createSkillVersion(parameters) {
44
+ const openai = new OpenAI(this.clientParams);
45
+ const { skill_id, ...body } = parameters.payload;
46
+ const response = await openai.skills.versions.create(skill_id, body);
47
+ return response;
48
+ }
49
+
50
+ async function getSkillVersion(parameters) {
51
+ const openai = new OpenAI(this.clientParams);
52
+ const { skill_id, version, ...params } = parameters.payload;
53
+ const response = await openai.skills.versions.retrieve(version, {
54
+ skill_id,
55
+ ...params,
56
+ });
57
+ return response;
58
+ }
59
+
60
+ async function listSkillVersions(parameters) {
61
+ const openai = new OpenAI(this.clientParams);
62
+ const { skill_id, ...params } = parameters.payload;
63
+ const list = await openai.skills.versions.list(skill_id, params);
64
+ return [...list.data];
65
+ }
66
+
67
+ async function deleteSkillVersion(parameters) {
68
+ const openai = new OpenAI(this.clientParams);
69
+ const { skill_id, version, ...params } = parameters.payload;
70
+ const response = await openai.skills.versions.delete(version, {
71
+ skill_id,
72
+ ...params,
73
+ });
74
+ return response;
75
+ }
76
+
77
+ async function getSkillVersionContent(parameters) {
78
+ const openai = new OpenAI(this.clientParams);
79
+ const { skill_id, version, ...params } = parameters.payload;
80
+ const response = await openai.skills.versions.content.retrieve(version, {
81
+ skill_id,
82
+ ...params,
83
+ });
84
+ return response;
85
+ }
86
+
87
+ module.exports = {
88
+ createSkill,
89
+ getSkill,
90
+ modifySkill,
91
+ deleteSkill,
92
+ listSkills,
93
+ getSkillContent,
94
+ createSkillVersion,
95
+ getSkillVersion,
96
+ listSkillVersions,
97
+ deleteSkillVersion,
98
+ getSkillVersionContent,
99
+ };
@@ -0,0 +1,13 @@
1
+ <optgroup style="font-style: normal;" label="🧩 Skills">
2
+ <option value="listSkills" data-i18n="OpenaiApi.parameters.listSkills"></option>
3
+ <option value="createSkill" data-i18n="OpenaiApi.parameters.createSkill"></option>
4
+ <option value="getSkill" data-i18n="OpenaiApi.parameters.getSkill"></option>
5
+ <option value="modifySkill" data-i18n="OpenaiApi.parameters.modifySkill"></option>
6
+ <option value="deleteSkill" data-i18n="OpenaiApi.parameters.deleteSkill"></option>
7
+ <option value="getSkillContent" data-i18n="OpenaiApi.parameters.getSkillContent"></option>
8
+ <option value="listSkillVersions" data-i18n="OpenaiApi.parameters.listSkillVersions"></option>
9
+ <option value="createSkillVersion" data-i18n="OpenaiApi.parameters.createSkillVersion"></option>
10
+ <option value="getSkillVersion" data-i18n="OpenaiApi.parameters.getSkillVersion"></option>
11
+ <option value="deleteSkillVersion" data-i18n="OpenaiApi.parameters.deleteSkillVersion"></option>
12
+ <option value="getSkillVersionContent" data-i18n="OpenaiApi.parameters.getSkillVersionContent"></option>
13
+ </optgroup>
@@ -1,7 +1,7 @@
1
1
  <section>
2
2
  <details>
3
3
  <summary style="font-weight: bold;">🧵 Threads</summary>
4
- <a href="https://platform.openai.com/docs/api-reference/threads" target="_blank">Official Documentation
4
+ <a href="https://developers.openai.com/api/reference/typescript/resources/beta/threads/" target="_blank">Official Documentation
5
5
  <i class="fa fa-external-link fa-sm" aria-hidden="true"></i></a>
6
6
  <h4 style="font-weight: bolder;"> ⋙ Create Thread</h4>
7
7
  <p>Create a thread.</p>
@@ -10,24 +10,18 @@
10
10
 
11
11
  <dt class="optional">
12
12
  messages
13
- <a href="https://platform.openai.com/docs/api-reference/threads/createThread#threads-createthread-messages"
14
- target="_blank"><i class="fa fa-external-link fa-sm" aria-hidden="true"></i></a>
15
13
  <span class="property-type">array</span>
16
14
  </dt>
17
15
  <dd>A list of messages to start the thread with.</dd>
18
16
 
19
17
  <dt class="optional">
20
18
  tool_resources
21
- <a href="https://platform.openai.com/docs/api-reference/threads/createThread#threads-createthread-tool_resources"
22
- target="_blank"><i class="fa fa-external-link fa-sm" aria-hidden="true"></i></a>
23
19
  <span class="property-type">array</span>
24
20
  </dt>
25
21
  <dd>A set of resources that are made available to the assistant's tools in this thread.</dd>
26
22
 
27
23
  <dt class="optional">
28
24
  metadata
29
- <a href="https://platform.openai.com/docs/api-reference/threads/createThread#threads-createthread-metadata"
30
- target="_blank"><i class="fa fa-external-link fa-sm" aria-hidden="true"></i></a>
31
25
  <span class="property-type">object</span>
32
26
  </dt>
33
27
  <dd>Set of 16 key-value pairs that can be attached to an object.</dd>
@@ -40,8 +34,6 @@
40
34
 
41
35
  <dt>
42
36
  thread_id
43
- <a href="https://platform.openai.com/docs/api-reference/threads/getThread#threads-getthread-thread_id"
44
- target="_blank"><i class="fa fa-external-link fa-sm" aria-hidden="true"></i></a>
45
37
  <span class="property-type">string</span>
46
38
  </dt>
47
39
  <dd>The ID of the thread to retrieve.</dd>
@@ -54,8 +46,6 @@
54
46
 
55
47
  <dt>
56
48
  thread_id
57
- <a href="https://platform.openai.com/docs/api-reference/threads/modifyThread#threads-modifythread-thread_id"
58
- target="_blank"><i class="fa fa-external-link fa-sm" aria-hidden="true"></i></a>
59
49
  <span class="property-type">string</span>
60
50
  </dt>
61
51
  <dd>
@@ -63,8 +53,6 @@
63
53
  </dd>
64
54
  <dt class="optional">
65
55
  metadata
66
- <a href="https://platform.openai.com/docs/api-reference/threads/modifyThread#threads-modifythread-metadata"
67
- target="_blank"><i class="fa fa-external-link fa-sm" aria-hidden="true"></i></a>
68
56
  <span class="property-type">object</span>
69
57
  </dt>
70
58
  <dd>Set of 16 key-value pairs that can be attached to an object.</dd>
@@ -77,8 +65,6 @@
77
65
 
78
66
  <dt>
79
67
  thread_id
80
- <a href="https://platform.openai.com/docs/api-reference/threads/deleteThread#threads-deletethread-thread_id"
81
- target="_blank"><i class="fa fa-external-link fa-sm" aria-hidden="true"></i></a>
82
68
  <span class="property-type">string</span>
83
69
  </dt>
84
70
  <dd>The ID of the thread to delete.</dd>
@@ -1,7 +1,7 @@
1
1
  <section>
2
2
  <details>
3
3
  <summary style="font-weight: bold;">☁️ Uploads</summary>
4
- <a href="https://platform.openai.com/docs/api-reference/uploads" target="_blank">Official Documentation
4
+ <a href="https://developers.openai.com/api/reference/typescript/resources/uploads/" target="_blank">Official Documentation
5
5
  <i class="fa fa-external-link fa-sm" aria-hidden="true"></i></a>
6
6
  <h4 style="font-weight: bolder;"> ⋙ Create Upload</h4>
7
7
  <p>Creates an intermediate Upload object that you can add Parts to. </p>
@@ -10,32 +10,24 @@
10
10
 
11
11
  <dt>
12
12
  filename
13
- <a href="https://platform.openai.com/docs/api-reference/uploads/create#uploads-create-filename"
14
- target="_blank"><i class="fa fa-external-link fa-sm" aria-hidden="true"></i></a>
15
13
  <span class="property-type">string</span>
16
14
  </dt>
17
15
  <dd>The name of the file to upload.</dd>
18
16
 
19
17
  <dt>
20
18
  purpose
21
- <a href="https://platform.openai.com/docs/api-reference/uploads/create#uploads-create-purpose"
22
- target="_blank"><i class="fa fa-external-link fa-sm" aria-hidden="true"></i></a>
23
19
  <span class="property-type">string</span>
24
20
  </dt>
25
21
  <dd>The intended purpose of the uploaded file.</dd>
26
22
 
27
23
  <dt>
28
24
  bytes
29
- <a href="https://platform.openai.com/docs/api-reference/uploads/create#uploads-create-bytes"
30
- target="_blank"><i class="fa fa-external-link fa-sm" aria-hidden="true"></i></a>
31
25
  <span class="property-type">integer</span>
32
26
  </dt>
33
27
  <dd>The number of bytes in the file you are uploading.</dd>
34
28
 
35
29
  <dt>
36
30
  mime_type
37
- <a href="https://platform.openai.com/docs/api-reference/uploads/create#uploads-create-mime_type"
38
- target="_blank"><i class="fa fa-external-link fa-sm" aria-hidden="true"></i></a>
39
31
  <span class="property-type">integer</span>
40
32
  </dt>
41
33
  <dd>This must fall within the supported MIME types for your file purpose.</dd>
@@ -49,16 +41,12 @@
49
41
 
50
42
  <dt>
51
43
  upload_id
52
- <a href="https://platform.openai.com/docs/api-reference/uploads/add-part#uploads-add-part-upload_id"
53
- target="_blank"><i class="fa fa-external-link fa-sm" aria-hidden="true"></i></a>
54
44
  <span class="property-type">string</span>
55
45
  </dt>
56
46
  <dd>The ID of the Upload.</dd>
57
47
 
58
48
  <dt>
59
49
  data
60
- <a href="https://platform.openai.com/docs/api-reference/uploads/add-part#uploads-add-part-data"
61
- target="_blank"><i class="fa fa-external-link fa-sm" aria-hidden="true"></i></a>
62
50
  <span class="property-type">file</span>
63
51
  </dt>
64
52
  <dd>The chunk of bytes for this Part.</dd>
@@ -72,8 +60,6 @@
72
60
 
73
61
  <dt>
74
62
  upload_id
75
- <a href="https://platform.openai.com/docs/api-reference/uploads/complete#uploads-complete-upload_id"
76
- target="_blank"><i class="fa fa-external-link fa-sm" aria-hidden="true"></i></a>
77
63
  <span class="property-type">string</span>
78
64
  </dt>
79
65
  <dd>
@@ -82,16 +68,12 @@
82
68
 
83
69
  <dt>
84
70
  part_ids
85
- <a href="https://platform.openai.com/docs/api-reference/uploads/complete#uploads-complete-part_ids"
86
- target="_blank"><i class="fa fa-external-link fa-sm" aria-hidden="true"></i></a>
87
71
  <span class="property-type">array</span>
88
72
  </dt>
89
73
  <dd>The ordered list of Part IDs.</dd>
90
74
 
91
75
  <dt>
92
76
  md5
93
- <a href="https://platform.openai.com/docs/api-reference/uploads/complete#uploads-complete-md5"
94
- target="_blank"><i class="fa fa-external-link fa-sm" aria-hidden="true"></i></a>
95
77
  <span class="property-type">string</span>
96
78
  </dt>
97
79
  <dd>The optional md5 checksum for the file contents.</dd>
@@ -105,8 +87,6 @@
105
87
 
106
88
  <dt>
107
89
  upload_id
108
- <a href="https://platform.openai.com/docs/api-reference/uploads/cancel#uploads-cancel-upload_id"
109
- target="_blank"><i class="fa fa-external-link fa-sm" aria-hidden="true"></i></a>
110
90
  <span class="property-type">string</span>
111
91
  </dt>
112
92
  <dd>The ID of the Upload.</dd>
@@ -1,7 +1,7 @@
1
1
  <section>
2
2
  <details>
3
3
  <summary style="font-weight: bold;">📥 Vector Store File Batches</summary>
4
- <a href="https://platform.openai.com/docs/api-reference/vector-stores-file-batches" target="_blank">Official
4
+ <a href="https://developers.openai.com/api/reference/typescript/resources/vector_stores/file_batches/" target="_blank">Official
5
5
  Documentation
6
6
  <i class="fa fa-external-link fa-sm" aria-hidden="true"></i></a>
7
7
  <h4 style="font-weight: bolder;"> ⋙ Create Vector Store File Batch</h4>
@@ -10,16 +10,12 @@
10
10
  <h4>msg.payload Properties</h4>
11
11
  <dt>
12
12
  vector_store_id
13
- <a href="https://platform.openai.com/docs/api-reference/vector-stores-file-batches/createBatch#vector-stores-file-batches-createbatch-vector_store_id"
14
- target="_blank"><i class="fa fa-external-link fa-sm" aria-hidden="true"></i></a>
15
13
  <span class="property-type">string</span>
16
14
  </dt>
17
15
  <dd>The ID of the vector store for which to create a File Batch.</dd>
18
16
 
19
17
  <dt>
20
18
  file_ids
21
- <a href="https://platform.openai.com/docs/api-reference/vector-stores-file-batches/createBatch#vector-stores-file-batches-createbatch-file_ids"
22
- target="_blank"><i class="fa fa-external-link fa-sm" aria-hidden="true"></i></a>
23
19
  <span class="property-type">array</span>
24
20
  </dt>
25
21
  <dd>A list of File IDs that the vector store should use. Useful for tools like file_search that can access
@@ -33,16 +29,12 @@
33
29
  <h4>msg.payload Properties</h4>
34
30
  <dt>
35
31
  vector_store_id
36
- <a href="https://platform.openai.com/docs/api-reference/vector-stores-file-batches/getBatch#vector-stores-file-batches-getbatch-vector_store_id"
37
- target="_blank"><i class="fa fa-external-link fa-sm" aria-hidden="true"></i></a>
38
32
  <span class="property-type">string</span>
39
33
  </dt>
40
34
  <dd>The ID of the vector store that the file batch belongs to.</dd>
41
35
 
42
36
  <dt>
43
37
  batch_id
44
- <a href="https://platform.openai.com/docs/api-reference/vector-stores-file-batches/getBatch#vector-stores-file-batches-getbatch-batch_id"
45
- target="_blank"><i class="fa fa-external-link fa-sm" aria-hidden="true"></i></a>
46
38
  <span class="property-type">string</span>
47
39
  </dt>
48
40
  <dd>The ID of the file batch being retrieved.</dd>
@@ -54,16 +46,12 @@
54
46
  <h4>msg.payload Properties</h4>
55
47
  <dt>
56
48
  vector_store_id
57
- <a href="https://platform.openai.com/docs/api-reference/vector-stores-file-batches/cancelBatch#vector-stores-file-batches-cancelbatch-vector_store_id"
58
- target="_blank"><i class="fa fa-external-link fa-sm" aria-hidden="true"></i></a>
59
49
  <span class="property-type">string</span>
60
50
  </dt>
61
51
  <dd>The ID of the vector store that the file batch belongs to.</dd>
62
52
 
63
53
  <dt>
64
54
  batch_id
65
- <a href="https://platform.openai.com/docs/api-reference/vector-stores-file-batches/cancelBatch#vector-stores-file-batches-cancelbatch-batch_id"
66
- target="_blank"><i class="fa fa-external-link fa-sm" aria-hidden="true"></i></a>
67
55
  <span class="property-type">string</span>
68
56
  </dt>
69
57
  <dd>The ID of the file batch to cancel.</dd>
@@ -75,24 +63,18 @@
75
63
  <h4>msg.payload Properties</h4>
76
64
  <dt>
77
65
  vector_store_id
78
- <a href="https://platform.openai.com/docs/api-reference/vector-stores-file-batches/listBatchFiles#vector-stores-file-batches-listbatchfiles-vector_store_id"
79
- target="_blank"><i class="fa fa-external-link fa-sm" aria-hidden="true"></i></a>
80
66
  <span class="property-type">string</span>
81
67
  </dt>
82
68
  <dd>The ID of the vector store that the files belong to.</dd>
83
69
 
84
70
  <dt>
85
71
  batch_id
86
- <a href="https://platform.openai.com/docs/api-reference/vector-stores-file-batches/listBatchFiles#vector-stores-file-batches-listbatchfiles-batch_id"
87
- target="_blank"><i class="fa fa-external-link fa-sm" aria-hidden="true"></i></a>
88
72
  <span class="property-type">string</span>
89
73
  </dt>
90
74
  <dd>The ID of the file batch that the files belong to.</dd>
91
75
 
92
76
  <dt class="optional">
93
77
  limit
94
- <a href="https://platform.openai.com/docs/api-reference/vector-stores-file-batches/listBatchFiles#vector-stores-file-batches-listbatchfiles-limit"
95
- target="_blank"><i class="fa fa-external-link fa-sm" aria-hidden="true"></i></a>
96
78
  <span class="property-type">integer</span>
97
79
  </dt>
98
80
  <dd>A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is
@@ -100,8 +82,6 @@
100
82
 
101
83
  <dt class="optional">
102
84
  order
103
- <a href="https://platform.openai.com/docs/api-reference/vector-stores-file-batches/listBatchFiles#vector-stores-file-batches-listbatchfiles-order"
104
- target="_blank"><i class="fa fa-external-link fa-sm" aria-hidden="true"></i></a>
105
85
  <span class="property-type">string</span>
106
86
  </dt>
107
87
  <dd>Sort order by the created_at timestamp of the objects. asc for ascending order and desc for descending
@@ -109,24 +89,18 @@
109
89
 
110
90
  <dt class="optional">
111
91
  after
112
- <a href="https://platform.openai.com/docs/api-reference/vector-stores-file-batches/listBatchFiles#vector-stores-file-batches-listbatchfiles-after"
113
- target="_blank"><i class="fa fa-external-link fa-sm" aria-hidden="true"></i></a>
114
92
  <span class="property-type">string</span>
115
93
  </dt>
116
94
  <dd>A cursor for use in pagination. after is an object ID that defines your place in the list.</dd>
117
95
 
118
96
  <dt class="optional">
119
97
  before
120
- <a href="https://platform.openai.com/docs/api-reference/vector-stores-file-batches/listBatchFiles#vector-stores-file-batches-listbatchfiles-before"
121
- target="_blank"><i class="fa fa-external-link fa-sm" aria-hidden="true"></i></a>
122
98
  <span class="property-type">string</span>
123
99
  </dt>
124
100
  <dd>A cursor for use in pagination. before is an object ID that defines your place in the list.</dd>
125
101
 
126
102
  <dt class="optional">
127
103
  filter
128
- <a href="https://platform.openai.com/docs/api-reference/vector-stores-file-batches/listBatchFiles#vector-stores-file-batches-listbatchfiles-filter"
129
- target="_blank"><i class="fa fa-external-link fa-sm" aria-hidden="true"></i></a>
130
104
  <span class="property-type">string</span>
131
105
  </dt>
132
106
  <dd>Filter by file status. One of in_progress, completed, failed, cancelled.</dd>
@@ -4,7 +4,7 @@ const fs = require("fs");
4
4
  async function createVectorStoreFileBatch(parameters) {
5
5
  const openai = new OpenAI(this.clientParams);
6
6
  const { vector_store_id, ...params } = parameters.payload;
7
- const response = await openai.beta.vectorStores.fileBatches.create(
7
+ const response = await openai.vectorStores.fileBatches.create(
8
8
  vector_store_id,
9
9
  params
10
10
  );
@@ -15,7 +15,7 @@ async function createVectorStoreFileBatch(parameters) {
15
15
  async function retrieveVectorStoreFileBatch(parameters) {
16
16
  const openai = new OpenAI(this.clientParams);
17
17
  const { vector_store_id, batch_id, ...params } = parameters.payload;
18
- const response = await openai.beta.vectorStores.fileBatches.retrieve(
18
+ const response = await openai.vectorStores.fileBatches.retrieve(
19
19
  vector_store_id,
20
20
  batch_id,
21
21
  params
@@ -27,7 +27,7 @@ async function retrieveVectorStoreFileBatch(parameters) {
27
27
  async function cancelVectorStoreFileBatch(parameters) {
28
28
  const openai = new OpenAI(this.clientParams);
29
29
  const { vector_store_id, batch_id, ...params } = parameters.payload;
30
- const response = await openai.beta.vectorStores.fileBatches.retrieve(
30
+ const response = await openai.vectorStores.fileBatches.cancel(
31
31
  vector_store_id,
32
32
  batch_id,
33
33
  params
@@ -39,7 +39,7 @@ async function cancelVectorStoreFileBatch(parameters) {
39
39
  async function listVectorStoreBatchFiles(parameters) {
40
40
  const openai = new OpenAI(this.clientParams);
41
41
  const { vector_store_id, batch_id, ...params } = parameters.payload;
42
- const list = await openai.beta.vectorStores.fileBatches.listFiles(
42
+ const list = await openai.vectorStores.fileBatches.listFiles(
43
43
  vector_store_id,
44
44
  batch_id,
45
45
  params
@@ -66,7 +66,7 @@ async function uploadAndPollVectorStoreFileBatch(parameters) {
66
66
 
67
67
  const fileStreams = files.map((path) => fs.createReadStream(path));
68
68
 
69
- const response = await openai.beta.vectorStores.fileBatches.uploadAndPoll(
69
+ const response = await openai.vectorStores.fileBatches.uploadAndPoll(
70
70
  vector_store_id,
71
71
  { files: fileStreams, fileIds: file_ids },
72
72
  params