MCPcopy Index your code
hub / github.com/triggerdotdev/trigger.dev / del

Method del

integrations/openai/src/threads.ts:225–250  ·  view source on GitHub ↗

* Delete a thread.

(
    key: IntegrationTaskKey,
    threadId: string,
    options: OpenAIRequestOptions = {}
  )

Source from the content-addressed store, hash-verified

223 * Delete a thread.
224 */
225 async del(
226 key: IntegrationTaskKey,
227 threadId: string,
228 options: OpenAIRequestOptions = {}
229 ): Promise<OpenAI.Beta.ThreadDeleted> {
230 return this.runTask(
231 key,
232 async (client, task) => {
233 const { data, response } = await client.beta.threads
234 .del(threadId, {
235 idempotencyKey: task.idempotencyKey,
236 ...options,
237 })
238 .withResponse();
239
240 task.outputProperties = createTaskOutputProperties(undefined, response.headers);
241
242 return data;
243 },
244 {
245 name: "Delete Thread",
246 properties: [{ label: "threadId", text: threadId }],
247 },
248 handleOpenAIError
249 );
250 }
251
252 get runs() {
253 return new Runs(this.runTask.bind(this), this.options);

Callers 6

delMaxSizeForFlagMethod · 0.45
deleteMethod · 0.45
openai.tsFile · 0.45
doEnvVarsFunction · 0.45
doSchedulesFunction · 0.45

Calls 3

withResponseMethod · 0.80
runTaskMethod · 0.45

Tested by

no test coverage detected