Speakeasy Logo
Skip to Content

List of Speakeasy extensions

Extension
x-speakeasy-name-override
Description
Use it globally to change method names or inline to change the name of a method, parameter, or class.
x-speakeasy-group
Description
Defines custom namespaces when adding this property to any operation in the OpenAPI spec. If added, the tags for that method will be ignored
x-speakeasy-ignore
Description
Exclude certain methods from your SDK with this extension.
x-speakeasy-include
Description
Can be used to force the generation of an unused or orphaned schema from the
section inside the main document.
x-speakeasy-enums
Description
Use this extension to control generated enum members by providing alternative names for each value in the enum field.
x-speakeasy-enum-format
Description
Customize how the enum type is generated for the schema, either
for a native enum type or
for a union of values.
x-speakeasy-retries
Description
Enable retries globally or on a per-request basis. A backoff strategy is applied to specified status codes.
x-speakeasy-pagination
Description
Use to customize offset- or cursor-based pagination rules for each API operation.
x-speakeasy-usage-example
Description
Feature a method in your SDK's
by adding this property to the method.
x-speakeasy-example
Description
The OpenAPI specification doesn't allow example values for
property. Using this extension overcomes this limitation.
x-speakeasy-docs
Description
Configure comments that only show up in the SDK for a single language.
x-speakeasy-globals
Description
Define parameters that can be configured globally on the main SDK instance and populated automatically for any operations that use them.
x-speakeasy-globals-hidden
Description
Define parameters that can be configured globally on the main SDK instance but are not shown in the matching method's signature.
x-speakeasy-errors
Description
Apply this extension at the level of
,
, or
in the document to override the default error-handling behavior of the SDKs.
x-speakeasy-error-message
Description
Used to mark a field in an error response as containing the error message to use.
x-speakeasy-server-id
Description
Enable users to pick a server when instantiating the SDK. Use this extension to define an ID for each server in the
array in the OpenAPI spec.
x-speakeasy-deprecation-message
Description
Allows you to add a message to deprecated operations, parameters, and schemas.
x-speakeasy-deprecation-replacement
Description
Allows you to specify an alternate operation to use in place of a deprecated operation.
x-speakeasy-type-override
Description
Use this to override a schema's type, forcing it to be handled as
to accept arbitrary data.
x-speakeasy-max-method-params
Description
Allows you to set the maximum number of parameters that can be passed to a method. If the number of parameters exceeds this value, a request object will be used.
x-speakeasy-param-encoding-override
Description
When set with a value of
, path parameters will appear in a request URL with reserved characters
unencoded.

You can use x-speakeasy-extension-rewrite to map any extension from the wider OpenAPI ecosystem or another vendor to the equivalent Speakeasy extension. This allows you to use your existing OpenAPI spec without needing to make changes to it, if necessary.

Terraform-specific extensions

Terraform extension
x-speakeasy-conflicts-with
Description
Indicate conflicting properties to prevent incompatible combinations in Terraform configurations.
x-speakeasy-entity
Description
Map API entities to Terraform resources by annotating objects in your OpenAPI spec as entities in the Terraform provider.
x-speakeasy-entity-operation
Description
Specify CRUD operations for API endpoints to map to Terraform resources, such as create, read, update, or delete operations.
x-speakeasy-entity-version
Description
Specify the version of a Terraform resource to support state migrations for breaking changes.
x-speakeasy-name-override
Description
Remap API properties to Terraform attribute names while keeping API data handling intact.
x-speakeasy-param-force-new
Description
Force resource recreation in Terraform when certain property values change.
x-speakeasy-param-computed
Description
Force a property to be computed in resource schemas, causing Terraform to allow unknown values after apply. Explicitly setting to false will always respect configuration values when sending API request data, however the API must never change the value as compared to the configuration on create/update.
x-speakeasy-param-optional
Description
Force a property to be optional, overriding the required attribute in JSON Schema specifications.
x-speakeasy-param-readonly
Description
Mark properties as read-only in Terraform, preventing modifications by the user.
x-speakeasy-param-sensitive
Description
Hide sensitive properties from Terraform console output for security purposes.
x-speakeasy-param-suppress-computed-diff
Description
Mark that the property will never change value after create. Use to reduce known after apply (unknown value) output in managed resource update plans.
x-speakeasy-plan-modifiers
Description
Add custom plan modification logic to Terraform plan operations for advanced default values or resource replacement logic.
x-speakeasy-plan-validators
Description
Add custom validation logic to Terraform plan operations to ensure configurations meet predefined criteria before execution.
x-speakeasy-required-with
Description
Indicate mutually necessary properties to prevent incompatible Terraform configurations.
x-speakeasy-soft-delete-property
Description
Automatically cause managed resource state removal and recreation in plans if property is not null, such as a 'deleted' property.
x-speakeasy-terraform-alias-to
Description
Remap API response data to another property.
x-speakeasy-terraform-custom-type
Description
Use a terraform-plugin-framework custom type instead of a base type.
x-speakeasy-terraform-ignore
Description
Use this extension to exclude properties from Terraform state management.
x-speakeasy-terraform-plan-only
Description
Ensure that only values from the Terraform plan are used during updates, overriding prior state or default values.
x-speakeasy-type-override
Description
Allows the conversion of an attribute to a JSON string, accommodating dynamic structures in Terraform configurations.
x-speakeasy-wrapped-attribute
Description
Enables additional API operation data to be placed under a specifically named attribute.
x-speakeasy-xor-with
Description
Indicate mutually exclusive properties to prevent incompatible combinations in Terraform configurations.
x-speakeasy-match
Description
Adjusts an API parameter name to align with a Terraform state property.

Last updated on