Configure idempotency headers
Pro and Enterprise feature
This feature is available only for the Pro and Enterprise plans. To get started, reach out to support@buildwithfern.com.
For endpoints you’ve configured as idempotent, Fern’s SDKs allow users to
specify idempotency headers for safe request retries. Typically the headers include Idempotency-Key,
but you can also specify additional headers.
Generated SDK behavior
The generated SDKs expose idempotency headers as parameters only for endpoints marked as idempotent, ensuring users know exactly which invocations are idempotent.
Setting up idempotency headers
Configure the idempotency headers your API uses, then mark individual endpoints as idempotent:
OpenAPI
Fern Definition
openapi.yml
For full configuration details, see the docs for your API definition format: