"""Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT."""

from __future__ import annotations
from .httpmetadata import HTTPMetadata, HTTPMetadataTypedDict
import pydantic
from typing import Optional
from typing_extensions import Annotated, NotRequired, TypedDict
from unkey_py.types import BaseModel


class DeleteKeysRequestBodyTypedDict(TypedDict):
    api_id: str
    r"""The id of the api, that the keys belong to."""
    permanent: NotRequired[bool]
    r"""Delete the keys permanently, if false the keys will be marked as deleted but not removed from the database. In either case, the keys will no longer be valid when verifying them."""


class DeleteKeysRequestBody(BaseModel):
    api_id: Annotated[str, pydantic.Field(alias="apiId")]
    r"""The id of the api, that the keys belong to."""

    permanent: Optional[bool] = False
    r"""Delete the keys permanently, if false the keys will be marked as deleted but not removed from the database. In either case, the keys will no longer be valid when verifying them."""


class DeleteKeysResponseBodyTypedDict(TypedDict):
    r"""The keys have been deleted"""

    deleted_keys: int
    r"""The number of keys that were deleted"""


class DeleteKeysResponseBody(BaseModel):
    r"""The keys have been deleted"""

    deleted_keys: Annotated[int, pydantic.Field(alias="deletedKeys")]
    r"""The number of keys that were deleted"""


class DeleteKeysResponseTypedDict(TypedDict):
    http_meta: HTTPMetadataTypedDict
    object: NotRequired[DeleteKeysResponseBodyTypedDict]
    r"""The keys have been deleted"""


class DeleteKeysResponse(BaseModel):
    http_meta: Annotated[Optional[HTTPMetadata], pydantic.Field(exclude=True)] = None

    object: Optional[DeleteKeysResponseBody] = None
    r"""The keys have been deleted"""
