setRateLimitRetryCallback
fun setRateLimitRetryCallback(rateLimitRetryCallback: (retryCount: Int) -> RateLimitRetryConfig?): OAuth2ClientBuilder
Sets the callback invoked when an HTTP 429 rate-limit response is received.
Return a RateLimitRetryConfig from rateLimitRetryCallback to retry the request, or null to surface the failure immediately. The retryCount parameter is 0-based: 0 on the first retry opportunity.
Return
This builder for chaining.
Parameters
rateLimitRetryCallback
The callback to invoke on a 429 response.