* Extract the amount of time (in seconds) the platform has recommended this client wait before sending another request * from a rate-limited HTTP response (statusCode = 429).
(response: AxiosResponse)
| 827 | * from a rate-limited HTTP response (statusCode = 429). |
| 828 | */ |
| 829 | function parseRetryHeaders(response: AxiosResponse): number | undefined { |
| 830 | if (response.headers['retry-after'] !== undefined) { |
| 831 | return parseInt((response.headers['retry-after'] as string), 10); |
| 832 | } |
| 833 | return undefined; |
| 834 | } |
no outgoing calls
no test coverage detected