import datetime

from google.api import annotations_pb2 as _annotations_pb2
from google.api import field_behavior_pb2 as _field_behavior_pb2
from google.protobuf import empty_pb2 as _empty_pb2
from google.protobuf import timestamp_pb2 as _timestamp_pb2
from tars.auth.v1 import auth_options_pb2 as _auth_options_pb2
from tars.cli.v1 import cli_pb2 as _cli_pb2
from tars.common.v1 import types_pb2 as _types_pb2
from tars.docs.v1 import docs_pb2 as _docs_pb2
from google.protobuf.internal import containers as _containers
from google.protobuf import descriptor as _descriptor
from google.protobuf import message as _message
from collections.abc import Iterable as _Iterable, Mapping as _Mapping
from typing import ClassVar as _ClassVar, Optional as _Optional, Union as _Union

DESCRIPTOR: _descriptor.FileDescriptor

class Provider(_message.Message):
    __slots__ = ("id", "name", "display_name", "base_url", "supported_auth_schemes", "credential_suffix", "created_at", "updated_at")
    ID_FIELD_NUMBER: _ClassVar[int]
    NAME_FIELD_NUMBER: _ClassVar[int]
    DISPLAY_NAME_FIELD_NUMBER: _ClassVar[int]
    BASE_URL_FIELD_NUMBER: _ClassVar[int]
    SUPPORTED_AUTH_SCHEMES_FIELD_NUMBER: _ClassVar[int]
    CREDENTIAL_SUFFIX_FIELD_NUMBER: _ClassVar[int]
    CREATED_AT_FIELD_NUMBER: _ClassVar[int]
    UPDATED_AT_FIELD_NUMBER: _ClassVar[int]
    id: str
    name: str
    display_name: str
    base_url: str
    supported_auth_schemes: _containers.RepeatedScalarFieldContainer[str]
    credential_suffix: str
    created_at: _timestamp_pb2.Timestamp
    updated_at: _timestamp_pb2.Timestamp
    def __init__(self, id: _Optional[str] = ..., name: _Optional[str] = ..., display_name: _Optional[str] = ..., base_url: _Optional[str] = ..., supported_auth_schemes: _Optional[_Iterable[str]] = ..., credential_suffix: _Optional[str] = ..., created_at: _Optional[_Union[datetime.datetime, _timestamp_pb2.Timestamp, _Mapping]] = ..., updated_at: _Optional[_Union[datetime.datetime, _timestamp_pb2.Timestamp, _Mapping]] = ...) -> None: ...

class Pricing(_message.Message):
    __slots__ = ("input_per_million", "output_per_million", "cache_read_per_million", "max_cost_per_request")
    INPUT_PER_MILLION_FIELD_NUMBER: _ClassVar[int]
    OUTPUT_PER_MILLION_FIELD_NUMBER: _ClassVar[int]
    CACHE_READ_PER_MILLION_FIELD_NUMBER: _ClassVar[int]
    MAX_COST_PER_REQUEST_FIELD_NUMBER: _ClassVar[int]
    input_per_million: str
    output_per_million: str
    cache_read_per_million: str
    max_cost_per_request: str
    def __init__(self, input_per_million: _Optional[str] = ..., output_per_million: _Optional[str] = ..., cache_read_per_million: _Optional[str] = ..., max_cost_per_request: _Optional[str] = ...) -> None: ...

class Model(_message.Message):
    __slots__ = ("id", "provider_id", "name", "upstream_model", "pricing", "max_context_tokens", "capabilities", "created_at", "updated_at")
    ID_FIELD_NUMBER: _ClassVar[int]
    PROVIDER_ID_FIELD_NUMBER: _ClassVar[int]
    NAME_FIELD_NUMBER: _ClassVar[int]
    UPSTREAM_MODEL_FIELD_NUMBER: _ClassVar[int]
    PRICING_FIELD_NUMBER: _ClassVar[int]
    MAX_CONTEXT_TOKENS_FIELD_NUMBER: _ClassVar[int]
    CAPABILITIES_FIELD_NUMBER: _ClassVar[int]
    CREATED_AT_FIELD_NUMBER: _ClassVar[int]
    UPDATED_AT_FIELD_NUMBER: _ClassVar[int]
    id: str
    provider_id: str
    name: str
    upstream_model: str
    pricing: Pricing
    max_context_tokens: int
    capabilities: _containers.RepeatedScalarFieldContainer[str]
    created_at: _timestamp_pb2.Timestamp
    updated_at: _timestamp_pb2.Timestamp
    def __init__(self, id: _Optional[str] = ..., provider_id: _Optional[str] = ..., name: _Optional[str] = ..., upstream_model: _Optional[str] = ..., pricing: _Optional[_Union[Pricing, _Mapping]] = ..., max_context_tokens: _Optional[int] = ..., capabilities: _Optional[_Iterable[str]] = ..., created_at: _Optional[_Union[datetime.datetime, _timestamp_pb2.Timestamp, _Mapping]] = ..., updated_at: _Optional[_Union[datetime.datetime, _timestamp_pb2.Timestamp, _Mapping]] = ...) -> None: ...

class ListProvidersRequest(_message.Message):
    __slots__ = ("page",)
    PAGE_FIELD_NUMBER: _ClassVar[int]
    page: _types_pb2.PageRequest
    def __init__(self, page: _Optional[_Union[_types_pb2.PageRequest, _Mapping]] = ...) -> None: ...

class ListProvidersResponse(_message.Message):
    __slots__ = ("providers", "page")
    PROVIDERS_FIELD_NUMBER: _ClassVar[int]
    PAGE_FIELD_NUMBER: _ClassVar[int]
    providers: _containers.RepeatedCompositeFieldContainer[Provider]
    page: _types_pb2.PageResponse
    def __init__(self, providers: _Optional[_Iterable[_Union[Provider, _Mapping]]] = ..., page: _Optional[_Union[_types_pb2.PageResponse, _Mapping]] = ...) -> None: ...

class GetProviderRequest(_message.Message):
    __slots__ = ("id",)
    ID_FIELD_NUMBER: _ClassVar[int]
    id: str
    def __init__(self, id: _Optional[str] = ...) -> None: ...

class GetProviderResponse(_message.Message):
    __slots__ = ("provider",)
    PROVIDER_FIELD_NUMBER: _ClassVar[int]
    provider: Provider
    def __init__(self, provider: _Optional[_Union[Provider, _Mapping]] = ...) -> None: ...

class ListModelsRequest(_message.Message):
    __slots__ = ("provider_id", "page")
    PROVIDER_ID_FIELD_NUMBER: _ClassVar[int]
    PAGE_FIELD_NUMBER: _ClassVar[int]
    provider_id: str
    page: _types_pb2.PageRequest
    def __init__(self, provider_id: _Optional[str] = ..., page: _Optional[_Union[_types_pb2.PageRequest, _Mapping]] = ...) -> None: ...

class ListModelsResponse(_message.Message):
    __slots__ = ("models", "page")
    MODELS_FIELD_NUMBER: _ClassVar[int]
    PAGE_FIELD_NUMBER: _ClassVar[int]
    models: _containers.RepeatedCompositeFieldContainer[Model]
    page: _types_pb2.PageResponse
    def __init__(self, models: _Optional[_Iterable[_Union[Model, _Mapping]]] = ..., page: _Optional[_Union[_types_pb2.PageResponse, _Mapping]] = ...) -> None: ...

class GetModelRequest(_message.Message):
    __slots__ = ("id",)
    ID_FIELD_NUMBER: _ClassVar[int]
    id: str
    def __init__(self, id: _Optional[str] = ...) -> None: ...

class GetModelResponse(_message.Message):
    __slots__ = ("model",)
    MODEL_FIELD_NUMBER: _ClassVar[int]
    model: Model
    def __init__(self, model: _Optional[_Union[Model, _Mapping]] = ...) -> None: ...

class ProjectModelEntry(_message.Message):
    __slots__ = ("id", "customer_id", "project_id", "model_id", "model", "created_at")
    ID_FIELD_NUMBER: _ClassVar[int]
    CUSTOMER_ID_FIELD_NUMBER: _ClassVar[int]
    PROJECT_ID_FIELD_NUMBER: _ClassVar[int]
    MODEL_ID_FIELD_NUMBER: _ClassVar[int]
    MODEL_FIELD_NUMBER: _ClassVar[int]
    CREATED_AT_FIELD_NUMBER: _ClassVar[int]
    id: str
    customer_id: str
    project_id: str
    model_id: str
    model: Model
    created_at: _timestamp_pb2.Timestamp
    def __init__(self, id: _Optional[str] = ..., customer_id: _Optional[str] = ..., project_id: _Optional[str] = ..., model_id: _Optional[str] = ..., model: _Optional[_Union[Model, _Mapping]] = ..., created_at: _Optional[_Union[datetime.datetime, _timestamp_pb2.Timestamp, _Mapping]] = ...) -> None: ...

class UpsertProviderRequest(_message.Message):
    __slots__ = ("id", "display_name", "base_url", "supported_auth_schemes")
    ID_FIELD_NUMBER: _ClassVar[int]
    DISPLAY_NAME_FIELD_NUMBER: _ClassVar[int]
    BASE_URL_FIELD_NUMBER: _ClassVar[int]
    SUPPORTED_AUTH_SCHEMES_FIELD_NUMBER: _ClassVar[int]
    id: str
    display_name: str
    base_url: str
    supported_auth_schemes: _containers.RepeatedScalarFieldContainer[str]
    def __init__(self, id: _Optional[str] = ..., display_name: _Optional[str] = ..., base_url: _Optional[str] = ..., supported_auth_schemes: _Optional[_Iterable[str]] = ...) -> None: ...

class UpsertModelRequest(_message.Message):
    __slots__ = ("provider_id", "name", "upstream_model", "input_per_million", "output_per_million", "cache_read_per_million", "max_cost_per_request", "max_context_tokens", "capabilities")
    PROVIDER_ID_FIELD_NUMBER: _ClassVar[int]
    NAME_FIELD_NUMBER: _ClassVar[int]
    UPSTREAM_MODEL_FIELD_NUMBER: _ClassVar[int]
    INPUT_PER_MILLION_FIELD_NUMBER: _ClassVar[int]
    OUTPUT_PER_MILLION_FIELD_NUMBER: _ClassVar[int]
    CACHE_READ_PER_MILLION_FIELD_NUMBER: _ClassVar[int]
    MAX_COST_PER_REQUEST_FIELD_NUMBER: _ClassVar[int]
    MAX_CONTEXT_TOKENS_FIELD_NUMBER: _ClassVar[int]
    CAPABILITIES_FIELD_NUMBER: _ClassVar[int]
    provider_id: str
    name: str
    upstream_model: str
    input_per_million: str
    output_per_million: str
    cache_read_per_million: str
    max_cost_per_request: str
    max_context_tokens: int
    capabilities: _containers.RepeatedScalarFieldContainer[str]
    def __init__(self, provider_id: _Optional[str] = ..., name: _Optional[str] = ..., upstream_model: _Optional[str] = ..., input_per_million: _Optional[str] = ..., output_per_million: _Optional[str] = ..., cache_read_per_million: _Optional[str] = ..., max_cost_per_request: _Optional[str] = ..., max_context_tokens: _Optional[int] = ..., capabilities: _Optional[_Iterable[str]] = ...) -> None: ...

class SetProviderCredentialRequest(_message.Message):
    __slots__ = ("id", "credential")
    ID_FIELD_NUMBER: _ClassVar[int]
    CREDENTIAL_FIELD_NUMBER: _ClassVar[int]
    id: str
    credential: str
    def __init__(self, id: _Optional[str] = ..., credential: _Optional[str] = ...) -> None: ...

class DeleteProviderRequest(_message.Message):
    __slots__ = ("id",)
    ID_FIELD_NUMBER: _ClassVar[int]
    id: str
    def __init__(self, id: _Optional[str] = ...) -> None: ...

class DeleteModelRequest(_message.Message):
    __slots__ = ("id",)
    ID_FIELD_NUMBER: _ClassVar[int]
    id: str
    def __init__(self, id: _Optional[str] = ...) -> None: ...

class AssignModelToProjectRequest(_message.Message):
    __slots__ = ("customer_id", "project_id", "model_id")
    CUSTOMER_ID_FIELD_NUMBER: _ClassVar[int]
    PROJECT_ID_FIELD_NUMBER: _ClassVar[int]
    MODEL_ID_FIELD_NUMBER: _ClassVar[int]
    customer_id: str
    project_id: str
    model_id: str
    def __init__(self, customer_id: _Optional[str] = ..., project_id: _Optional[str] = ..., model_id: _Optional[str] = ...) -> None: ...

class AssignModelToProjectResponse(_message.Message):
    __slots__ = ("entry",)
    ENTRY_FIELD_NUMBER: _ClassVar[int]
    entry: ProjectModelEntry
    def __init__(self, entry: _Optional[_Union[ProjectModelEntry, _Mapping]] = ...) -> None: ...

class ListProjectModelsRequest(_message.Message):
    __slots__ = ("customer_id", "project_id")
    CUSTOMER_ID_FIELD_NUMBER: _ClassVar[int]
    PROJECT_ID_FIELD_NUMBER: _ClassVar[int]
    customer_id: str
    project_id: str
    def __init__(self, customer_id: _Optional[str] = ..., project_id: _Optional[str] = ...) -> None: ...

class ListProjectModelsResponse(_message.Message):
    __slots__ = ("entries",)
    ENTRIES_FIELD_NUMBER: _ClassVar[int]
    entries: _containers.RepeatedCompositeFieldContainer[ProjectModelEntry]
    def __init__(self, entries: _Optional[_Iterable[_Union[ProjectModelEntry, _Mapping]]] = ...) -> None: ...

class UnassignModelFromProjectRequest(_message.Message):
    __slots__ = ("customer_id", "project_id", "model_id")
    CUSTOMER_ID_FIELD_NUMBER: _ClassVar[int]
    PROJECT_ID_FIELD_NUMBER: _ClassVar[int]
    MODEL_ID_FIELD_NUMBER: _ClassVar[int]
    customer_id: str
    project_id: str
    model_id: str
    def __init__(self, customer_id: _Optional[str] = ..., project_id: _Optional[str] = ..., model_id: _Optional[str] = ...) -> None: ...

class UnassignModelFromProjectResponse(_message.Message):
    __slots__ = ("success",)
    SUCCESS_FIELD_NUMBER: _ClassVar[int]
    success: bool
    def __init__(self, success: _Optional[bool] = ...) -> None: ...
