shared_contracts
Transport-independent validated data shared by application layers.
- class bedrock_server_manager.contracts.DataContract
- model_config = {'allow_inf_nan': False, 'extra': 'forbid', 'frozen': True, 'hide_input_in_errors': True, 'revalidate_instances': 'always', 'strict': True, 'validate_default': True}
Configuration for the model, should be a dictionary conforming to [ConfigDict][pydantic.config.ConfigDict].
- class bedrock_server_manager.contracts.FailureInfo(*, code: ~typing.Literal['validation_error', 'not_found', 'conflict', 'forbidden', 'unauthorized', 'http_error', 'operation_canceled', 'invalid_server_name', 'server_start_failed', 'server_stop_failed', 'server_error', 'application_error', 'internal_error', 'unavailable', 'operation_incomplete', 'file_error', 'storage_error', 'configuration_error', 'network_error', 'system_error'], message: str, details: dict[str, ~pydantic.types.JsonValue] = <factory>)
- model_config = {'allow_inf_nan': False, 'extra': 'forbid', 'frozen': True, 'hide_input_in_errors': True, 'revalidate_instances': 'always', 'strict': True, 'validate_default': True}
Configuration for the model, should be a dictionary conforming to [ConfigDict][pydantic.config.ConfigDict].
- class bedrock_server_manager.contracts.ClassifiedFailure(*, error: FailureInfo, status_code: Annotated[int, Ge(ge=400), Le(le=599)], expected: bool)
- model_config = {'allow_inf_nan': False, 'extra': 'forbid', 'frozen': True, 'hide_input_in_errors': True, 'revalidate_instances': 'always', 'strict': True, 'validate_default': True}
Configuration for the model, should be a dictionary conforming to [ConfigDict][pydantic.config.ConfigDict].
- class bedrock_server_manager.contracts.CompletedItem(*, outcome: Literal['completed'] = 'completed', path: str | None = None, reason: None = None, error: None = None)
- model_config = {'allow_inf_nan': False, 'extra': 'forbid', 'frozen': True, 'hide_input_in_errors': True, 'revalidate_instances': 'always', 'strict': True, 'validate_default': True}
Configuration for the model, should be a dictionary conforming to [ConfigDict][pydantic.config.ConfigDict].
- class bedrock_server_manager.contracts.SkippedItem(*, outcome: Literal['skipped'] = 'skipped', path: None = None, reason: str, error: None = None)
- model_config = {'allow_inf_nan': False, 'extra': 'forbid', 'frozen': True, 'hide_input_in_errors': True, 'revalidate_instances': 'always', 'strict': True, 'validate_default': True}
Configuration for the model, should be a dictionary conforming to [ConfigDict][pydantic.config.ConfigDict].
- class bedrock_server_manager.contracts.FailedItem(*, outcome: Literal['failed'] = 'failed', path: None = None, reason: str | None = None, error: FailureInfo)
- model_config = {'allow_inf_nan': False, 'extra': 'forbid', 'frozen': True, 'hide_input_in_errors': True, 'revalidate_instances': 'always', 'strict': True, 'validate_default': True}
Configuration for the model, should be a dictionary conforming to [ConfigDict][pydantic.config.ConfigDict].
- class bedrock_server_manager.contracts.ComponentResults(*, components: dict[str, ~typing.Annotated[~bedrock_server_manager.contracts.CompletedItem | ~bedrock_server_manager.contracts.SkippedItem | ~bedrock_server_manager.contracts.FailedItem, FieldInfo(annotation=NoneType, required=True, discriminator='outcome')]] = <factory>, outcome: Literal['completed', 'partial', 'failed', 'noop']='noop')
- model_config = {'allow_inf_nan': False, 'extra': 'forbid', 'frozen': True, 'hide_input_in_errors': True, 'revalidate_instances': 'always', 'strict': True, 'validate_default': True}
Configuration for the model, should be a dictionary conforming to [ConfigDict][pydantic.config.ConfigDict].
- class bedrock_server_manager.contracts.CleanupResult(*, deleted: list[str] = <factory>, retained: list[str] = <factory>, failures: dict[str, ~bedrock_server_manager.contracts.FailureInfo]=<factory>, outcome: Literal['completed', 'partial', 'failed', 'noop']='noop')
- model_config = {'allow_inf_nan': False, 'extra': 'forbid', 'frozen': True, 'hide_input_in_errors': True, 'revalidate_instances': 'always', 'strict': True, 'validate_default': True}
Configuration for the model, should be a dictionary conforming to [ConfigDict][pydantic.config.ConfigDict].
- class bedrock_server_manager.contracts.DeliveryResult(*, targeted: Annotated[int, Ge(ge=0)] = 0, sent: Annotated[int, Ge(ge=0)] = 0, unavailable: Annotated[int, Ge(ge=0)] = 0, failed: Annotated[int, Ge(ge=0)] = 0)
- model_config = {'allow_inf_nan': False, 'extra': 'forbid', 'frozen': True, 'hide_input_in_errors': True, 'revalidate_instances': 'always', 'strict': True, 'validate_default': True}
Configuration for the model, should be a dictionary conforming to [ConfigDict][pydantic.config.ConfigDict].
- class bedrock_server_manager.contracts.BanMutation(*, outcome: Literal['added', 'updated', 'removed'], message: str)
- model_config = {'allow_inf_nan': False, 'extra': 'forbid', 'frozen': True, 'hide_input_in_errors': True, 'revalidate_instances': 'always', 'strict': True, 'validate_default': True}
Configuration for the model, should be a dictionary conforming to [ConfigDict][pydantic.config.ConfigDict].
- class bedrock_server_manager.contracts.ResourceFailure(*, resource: str, error: FailureInfo)
- model_config = {'allow_inf_nan': False, 'extra': 'forbid', 'frozen': True, 'hide_input_in_errors': True, 'revalidate_instances': 'always', 'strict': True, 'validate_default': True}
Configuration for the model, should be a dictionary conforming to [ConfigDict][pydantic.config.ConfigDict].
- class bedrock_server_manager.contracts.PlayerScanError(*, server: str, error: FailureInfo)
- model_config = {'allow_inf_nan': False, 'extra': 'forbid', 'frozen': True, 'hide_input_in_errors': True, 'revalidate_instances': 'always', 'strict': True, 'validate_default': True}
Configuration for the model, should be a dictionary conforming to [ConfigDict][pydantic.config.ConfigDict].
- class bedrock_server_manager.contracts.PlayerScanDetails(*, total_entries_in_logs: ~typing.Annotated[int, ~annotated_types.Ge(ge=0)], unique_players_submitted_for_saving: ~typing.Annotated[int, ~annotated_types.Ge(ge=0)], actually_saved_or_updated_in_db: ~typing.Annotated[int, ~annotated_types.Ge(ge=0)], scan_errors: list[~bedrock_server_manager.contracts.PlayerScanError] = <factory>)
- model_config = {'allow_inf_nan': False, 'extra': 'forbid', 'frozen': True, 'hide_input_in_errors': True, 'revalidate_instances': 'always', 'strict': True, 'validate_default': True}
Configuration for the model, should be a dictionary conforming to [ConfigDict][pydantic.config.ConfigDict].
- class bedrock_server_manager.contracts.CommittedMutationResult(*, committed: Literal[True] = True, action: str, resource: str, recovery_error: FailureInfo)
- model_config = {'allow_inf_nan': False, 'extra': 'forbid', 'frozen': True, 'hide_input_in_errors': True, 'revalidate_instances': 'always', 'strict': True, 'validate_default': True}
Configuration for the model, should be a dictionary conforming to [ConfigDict][pydantic.config.ConfigDict].