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

Method updateWebhook

integrations/linear/src/webhooks.ts:108–133  ·  view source on GitHub ↗
(
    key: IntegrationTaskKey,
    params: { id: string; input: L.WebhookUpdateInput }
  )

Source from the content-addressed store, hash-verified

106 }
107
108 updateWebhook(
109 key: IntegrationTaskKey,
110 params: { id: string; input: L.WebhookUpdateInput }
111 ): LinearReturnType<Omit<WebhookPayload, "webhook"> & { webhook: Webhook | undefined }> {
112 return this.runTask(
113 key,
114 async (client, task) => {
115 const payload = await client.updateWebhook(params.id, params.input);
116 return serializeLinearOutput({
117 ...payload,
118 webhook: await payload.webhook,
119 });
120 },
121 {
122 name: "Update Webhook",
123 params,
124 properties: [
125 { label: "Webhook ID", text: params.id },
126 ...(params.input.url ? [{ label: "Webhook URL", text: params.input.url }] : []),
127 ...(params.input.resourceTypes
128 ? [{ label: "Resource Types", text: params.input.resourceTypes.join(", ") }]
129 : []),
130 ],
131 }
132 );
133 }
134}
135
136type LinearEvents = (typeof events)[keyof typeof events];

Callers 1

createWebhookEventSourceFunction · 0.45

Calls 2

serializeLinearOutputFunction · 0.90
runTaskMethod · 0.45

Tested by

no test coverage detected