# This file was auto-generated by Fern from our API Definition.

import typing_extensions
from ..core.serialization import FieldMetadata


class ApiErrorParams(typing_extensions.TypedDict):
    """
    Standard error response format for all Extend API errors.

    See the [Error Codes documentation](https://docs.extend.ai/2026-02-09/developers/error-codes) for error handling recommendations.
    """

    code: str
    """
    Error code for programmatic handling.
    """

    message: str
    """
    Human-readable error message suitable for displaying to developers. 
    Do not rely on the exact text of this message as it may change.
    """

    retryable: bool
    """
    Whether the request can be retried. When true, retry with exponential backoff.
    When false, fix the underlying issue before retrying.
    """

    request_id: typing_extensions.NotRequired[typing_extensions.Annotated[str, FieldMetadata(alias="requestId")]]
    """
    Unique request identifier for support purposes. Always include this 
    when contacting Extend support about an error.
    """
