-
Couldn't load subscription status.
- Fork 2.2k
Open
Labels
APIRelated to REST API issuesRelated to REST API issuesfeature-requestRequest a new featureRequest a new featureneed-product-inputNeeds non-technical requirements or direction to proceedNeeds non-technical requirements or direction to proceed
Description
Describe the solution you'd like
It would be nice to configure a timeout value for a REST API endpoint. Currently the default is 0, which isn't a great idea, as users will be stuck loading indefinitely if there's a network issue.
Describe alternatives you've considered
The only workaround is to pass a timeout with every call, e.g.:
const data = await RestAPI.get('private', '/tracks', {
queryStringParameters: {
omit: 'name_tok,metadata_tok',
folder_id: folderId,
},
timeout: 10000,
});IMO a sensible implementation of this could look like this:
RestAPI.configure({
endpoints: [
{
name: 'endpoint1',
endpoint: 'xxx',
timeout: 10000,
},
],
});johnf and zenpi-me
Metadata
Metadata
Assignees
Labels
APIRelated to REST API issuesRelated to REST API issuesfeature-requestRequest a new featureRequest a new featureneed-product-inputNeeds non-technical requirements or direction to proceedNeeds non-technical requirements or direction to proceed