Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.
  • Added since PJS Profound.js 7.6.0.

The httpRequestAPITimeout setting is used to replace shortHttpTimeout which is used as the default timeout setting for By default, requests made via pjs.httpRequest() use a timeout of 10 seconds. When specified, The pjs.httpRequest call accepts a “timeout” parameter that overrides the default timeout.

The httpRequestAPITimeout setting overrides the default timeout for requests sent via pjs.httpRequest() will time out using the value of this setting if a timeout value is not included in the request parameters. If this setting is not included in config.js, it will internally use a default value of 10 seconds (1000ms) that do not specify a timeout in their parameters. Overriding the default can be useful for using low-code plugins or when the 10-second timeout is not appropriate for most requests made via pjs.httpRequest.

Example
Code Block
httpRequestAPITimeout: 3000   // Set API request time-out to 3 seconds.

Click here for information on how to modify this setting.

httpRequestAPITimeout replaces the deprecated, shortHttpTimeout, which in past releases worked with the deprecated pjs.sendRequest API but not with pjs.httpRequest.