Readonly
[toStatic
Readonly
[species]Gets the raw Response
instance instead of parsing the response
data.
If you want to parse the response body but still get the Response
instance, you can use ().
👋 Getting the wrong TypeScript type for Response
?
Try setting "moduleResolution": "NodeNext"
or add "lib": ["DOM"]
to your tsconfig.json
.
Attaches a callback that is invoked when the Promise is settled (fulfilled or rejected). The resolved value cannot be modified from the callback.
Optional
onfinally: null | (() => void)The callback to execute when the Promise is settled (fulfilled or rejected).
A Promise for the completion of the callback.
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 ().
👋 Getting the wrong TypeScript type for Response
?
Try setting "moduleResolution": "NodeNext"
or add "lib": ["DOM"]
to your tsconfig.json
.
Static
allCreates a Promise that is resolved with an array of results when all of the provided Promises resolve, or rejected when any Promise is rejected.
An array of Promises.
A new Promise.
Static
allCreates a Promise that is resolved with an array of results when all of the provided Promises resolve or reject.
An array of Promises.
A new Promise.
Static
raceStatic
rejectCreates a new rejected promise for the provided reason.
Optional
reason: anyThe reason the promise was rejected.
A new rejected Promise.
Static
resolveCreates a new resolved promise.
A resolved promise.
A subclass of
Promise
providing additional helper methods for interacting with the SDK.