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

Method upsertCustomTimelineEntry

integrations/plain/src/index.ts:162–191  ·  view source on GitHub ↗
(
    key: IntegrationTaskKey,
    params: UpsertCustomTimelineEntryParams
  )

Source from the content-addressed store, hash-verified

160 }
161
162 upsertCustomTimelineEntry(
163 key: IntegrationTaskKey,
164 params: UpsertCustomTimelineEntryParams
165 ): Promise<UpsertCustomTimelineEntryResponse> {
166 return this.runTask(
167 key,
168 async (client) => {
169 const response = await client.upsertCustomTimelineEntry(params);
170
171 if (response.error) {
172 throw response.error;
173 } else {
174 return recursivelyRemoveTypenameProperties(response.data);
175 }
176 },
177 {
178 name: "Upsert Customer Timeline Entry",
179 params,
180 icon: "plain",
181 properties: [
182 { label: "Customer ID", text: params.customerId },
183 { label: "Title", text: params.title },
184 {
185 label: "Components count",
186 text: params.components.length.toString(),
187 },
188 ],
189 }
190 );
191 }
192}
193
194function isPlainError(error: unknown): error is PlainSDKError {

Callers 1

plain.tsFile · 0.80

Calls 3

runTaskMethod · 0.95
toStringMethod · 0.80

Tested by

no test coverage detected