{"library":"undici-retry","type":"library","category":null,"description":"undici-retry is a JavaScript/TypeScript library designed to integrate robust retry logic with the undici HTTP client. As of version 7.0.0, it provides mechanisms to automatically re-attempt failed HTTP requests based on configurable criteria such as status codes, timeouts, and custom delay resolvers. It is tightly coupled with `undici`, requiring `undici` version 7.0.0 or higher as a peer dependency, and is compatible with Node.js environments version 20 or newer. The library offers two primary functions: `sendWithRetry` for operations where the response body is consumed directly (e.g., JSON parsing), and `sendWithRetryReturnStream` for scenarios requiring stream-based body handling, which is crucial for large responses or custom stream processing. Its release cadence typically aligns with major `undici` releases, adapting to `undici`'s API changes and Node.js version support. Key differentiators include its tight integration with `undici`'s `Dispatcher` and `Client` types, and its `Either` pattern for error handling.","language":"javascript","status":"active","version":"7.0.0","tags":["javascript","undici","retry","error","http","client","https","typescript"],"last_verified":"Wed May 27","install":[{"cmd":"npm install undici-retry","imports":["import { sendWithRetry } from 'undici-retry'","import { sendWithRetryReturnStream } from 'undici-retry'","import { DEFAULT_RETRYABLE_STATUS_CODES } from 'undici-retry'","import type { RetryConfig, RequestParams } from 'undici-retry'"]},{"cmd":"yarn add undici-retry","imports":[]},{"cmd":"pnpm add undici-retry","imports":[]}],"homepage":null,"github":"https://github.com/kibertoad/undici-retry","docs":null,"changelog":null,"pypi":null,"npm":"https://www.npmjs.com/package/undici-retry","openapi_spec":null,"status_page":null,"smithery":null,"compatibility":{"summary":{"python_range":"18–22","success_rate":0,"avg_install_s":null,"avg_import_s":null,"wheel_type":null},"url":"https://checklist.day/v1/registry/undici-retry/compatibility"}}