Skip to navigation

Retry behavior

View as Markdown

The x-fern-retries extension configures retry behavior per endpoint in your OpenAPI specification, overriding any retry settings configured by SDK users. Use it to disable retries for non-idempotent operations like payment processing or order creation. It’s supported across all SDK languages.

To disable retries for specific endpoints, set disabled: true.

openapi.yml
paths:
/plants/{plantId}:
get:
x-fern-retries:
disabled: true
operationId: get_plant
parameters:
- name: plantId
in: path
required: true
schema:
type: string
/plants:
post:
x-fern-retries:
disabled: true
operationId: create_plant
requestBody:
required: true
content:
application/json:
schema:
type: object
properties:
name:
type: string
species:
type: string
responses:
'201':
description: Plant created successfully

When retries are disabled at the endpoint level, the generated SDK won’t retry failed requests to that endpoint, regardless of client-level or per-request retry settings.