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

Method withResponse

packages/core/src/v3/apiClient/core.ts:566–569  ·  view source on GitHub ↗

* Gets the parsed response data and the raw `Response` instance. * * If you just want to get the raw `Response` instance without parsing it, * you can use asResponse().

()

Source from the content-addressed store, hash-verified

564 * you can use {@link asResponse()}.
565 */
566 async withResponse(): Promise<{ data: T; response: Response }> {
567 const [data, response] = await Promise.all([this.parse(), this.asResponse()]);
568 return { data, response };
569 }
570
571 private parse(): Promise<T> {
572 return this.responsePromise.then((result) => result.data);

Callers 15

createMethod · 0.80
updateMethod · 0.80
listMethod · 0.80
delMethod · 0.80
retrieveMethod · 0.80
createAndRunMethod · 0.80
createMethod · 0.80
retrieveMethod · 0.80
updateMethod · 0.80
delMethod · 0.80

Calls 3

parseMethod · 0.95
asResponseMethod · 0.95
allMethod · 0.45

Tested by

no test coverage detected