use conjure_http::endpoint;
/// The spatial asset service manages spatial assets (point clouds, etc.) and their metadata.
/// Spatial asset data is stored in Dagger; Scout tracks metadata and references.
#[conjure_http::conjure_endpoints(
    name = "SpatialService",
    use_legacy_error_serialization
)]
pub trait SpatialService {
    /// Returns spatial asset metadata associated with a spatial asset rid.
    #[endpoint(
        method = GET,
        path = "/spatial/v1/spatials/{spatialRid}",
        name = "get",
        produces = conjure_http::server::StdResponseSerializer
    )]
    fn get(
        &self,
        #[auth]
        auth_: conjure_object::BearerToken,
        #[path(
            name = "spatialRid",
            decoder = conjure_http::server::conjure::FromPlainDecoder,
            log_as = "spatialRid"
        )]
        spatial_rid: conjure_object::ResourceIdentifier,
    ) -> Result<
        super::super::super::super::objects::scout::spatial::api::Spatial,
        conjure_http::private::Error,
    >;
    /// Returns spatial asset metadata for each given spatial asset rid.
    #[endpoint(
        method = POST,
        path = "/spatial/v1/spatials/batchGet",
        name = "batchGet",
        produces = conjure_http::server::StdResponseSerializer
    )]
    fn batch_get(
        &self,
        #[auth]
        auth_: conjure_object::BearerToken,
        #[body(deserializer = conjure_http::server::StdRequestDeserializer)]
        request: super::super::super::super::objects::scout::spatial::api::GetSpatialsRequest,
    ) -> Result<
        super::super::super::super::objects::scout::spatial::api::GetSpatialsResponse,
        conjure_http::private::Error,
    >;
    /// Returns metadata about spatial assets that match a given query.
    #[endpoint(
        method = POST,
        path = "/spatial/v1/spatials/search",
        name = "search",
        produces = conjure_http::server::StdResponseSerializer
    )]
    fn search(
        &self,
        #[auth]
        auth_: conjure_object::BearerToken,
        #[body(deserializer = conjure_http::server::StdRequestDeserializer)]
        request: super::super::super::super::objects::scout::spatial::api::SearchSpatialsRequest,
    ) -> Result<
        super::super::super::super::objects::scout::spatial::api::SearchSpatialsResponse,
        conjure_http::private::Error,
    >;
    /// Creates and persists a spatial asset entity with the given metadata.
    #[endpoint(
        method = POST,
        path = "/spatial/v1/spatials",
        name = "create",
        produces = conjure_http::server::StdResponseSerializer
    )]
    fn create(
        &self,
        #[auth]
        auth_: conjure_object::BearerToken,
        #[body(deserializer = conjure_http::server::StdRequestDeserializer)]
        request: super::super::super::super::objects::scout::spatial::api::CreateSpatialRequest,
    ) -> Result<
        super::super::super::super::objects::scout::spatial::api::Spatial,
        conjure_http::private::Error,
    >;
    /// Updates the metadata for a spatial asset associated with the given rid.
    #[endpoint(
        method = PUT,
        path = "/spatial/v1/spatials/{spatialRid}",
        name = "updateMetadata",
        produces = conjure_http::server::StdResponseSerializer
    )]
    fn update_metadata(
        &self,
        #[auth]
        auth_: conjure_object::BearerToken,
        #[path(
            name = "spatialRid",
            decoder = conjure_http::server::conjure::FromPlainDecoder,
            log_as = "spatialRid"
        )]
        spatial_rid: conjure_object::ResourceIdentifier,
        #[body(deserializer = conjure_http::server::StdRequestDeserializer)]
        request: super::super::super::super::objects::scout::spatial::api::UpdateSpatialMetadataRequest,
    ) -> Result<
        super::super::super::super::objects::scout::spatial::api::Spatial,
        conjure_http::private::Error,
    >;
    /// Archives a spatial asset, excluding it from search. Can be unarchived.
    #[endpoint(
        method = PUT,
        path = "/spatial/v1/spatials/{spatialRid}/archive",
        name = "archive"
    )]
    fn archive(
        &self,
        #[auth]
        auth_: conjure_object::BearerToken,
        #[path(
            name = "spatialRid",
            decoder = conjure_http::server::conjure::FromPlainDecoder,
            log_as = "spatialRid"
        )]
        spatial_rid: conjure_object::ResourceIdentifier,
    ) -> Result<(), conjure_http::private::Error>;
    /// Unarchives a previously archived spatial asset.
    #[endpoint(
        method = PUT,
        path = "/spatial/v1/spatials/{spatialRid}/unarchive",
        name = "unarchive"
    )]
    fn unarchive(
        &self,
        #[auth]
        auth_: conjure_object::BearerToken,
        #[path(
            name = "spatialRid",
            decoder = conjure_http::server::conjure::FromPlainDecoder,
            log_as = "spatialRid"
        )]
        spatial_rid: conjure_object::ResourceIdentifier,
    ) -> Result<(), conjure_http::private::Error>;
}
/// The spatial asset service manages spatial assets (point clouds, etc.) and their metadata.
/// Spatial asset data is stored in Dagger; Scout tracks metadata and references.
#[conjure_http::conjure_endpoints(
    name = "SpatialService",
    use_legacy_error_serialization
)]
pub trait AsyncSpatialService {
    /// Returns spatial asset metadata associated with a spatial asset rid.
    #[endpoint(
        method = GET,
        path = "/spatial/v1/spatials/{spatialRid}",
        name = "get",
        produces = conjure_http::server::StdResponseSerializer
    )]
    async fn get(
        &self,
        #[auth]
        auth_: conjure_object::BearerToken,
        #[path(
            name = "spatialRid",
            decoder = conjure_http::server::conjure::FromPlainDecoder,
            log_as = "spatialRid"
        )]
        spatial_rid: conjure_object::ResourceIdentifier,
    ) -> Result<
        super::super::super::super::objects::scout::spatial::api::Spatial,
        conjure_http::private::Error,
    >;
    /// Returns spatial asset metadata for each given spatial asset rid.
    #[endpoint(
        method = POST,
        path = "/spatial/v1/spatials/batchGet",
        name = "batchGet",
        produces = conjure_http::server::StdResponseSerializer
    )]
    async fn batch_get(
        &self,
        #[auth]
        auth_: conjure_object::BearerToken,
        #[body(deserializer = conjure_http::server::StdRequestDeserializer)]
        request: super::super::super::super::objects::scout::spatial::api::GetSpatialsRequest,
    ) -> Result<
        super::super::super::super::objects::scout::spatial::api::GetSpatialsResponse,
        conjure_http::private::Error,
    >;
    /// Returns metadata about spatial assets that match a given query.
    #[endpoint(
        method = POST,
        path = "/spatial/v1/spatials/search",
        name = "search",
        produces = conjure_http::server::StdResponseSerializer
    )]
    async fn search(
        &self,
        #[auth]
        auth_: conjure_object::BearerToken,
        #[body(deserializer = conjure_http::server::StdRequestDeserializer)]
        request: super::super::super::super::objects::scout::spatial::api::SearchSpatialsRequest,
    ) -> Result<
        super::super::super::super::objects::scout::spatial::api::SearchSpatialsResponse,
        conjure_http::private::Error,
    >;
    /// Creates and persists a spatial asset entity with the given metadata.
    #[endpoint(
        method = POST,
        path = "/spatial/v1/spatials",
        name = "create",
        produces = conjure_http::server::StdResponseSerializer
    )]
    async fn create(
        &self,
        #[auth]
        auth_: conjure_object::BearerToken,
        #[body(deserializer = conjure_http::server::StdRequestDeserializer)]
        request: super::super::super::super::objects::scout::spatial::api::CreateSpatialRequest,
    ) -> Result<
        super::super::super::super::objects::scout::spatial::api::Spatial,
        conjure_http::private::Error,
    >;
    /// Updates the metadata for a spatial asset associated with the given rid.
    #[endpoint(
        method = PUT,
        path = "/spatial/v1/spatials/{spatialRid}",
        name = "updateMetadata",
        produces = conjure_http::server::StdResponseSerializer
    )]
    async fn update_metadata(
        &self,
        #[auth]
        auth_: conjure_object::BearerToken,
        #[path(
            name = "spatialRid",
            decoder = conjure_http::server::conjure::FromPlainDecoder,
            log_as = "spatialRid"
        )]
        spatial_rid: conjure_object::ResourceIdentifier,
        #[body(deserializer = conjure_http::server::StdRequestDeserializer)]
        request: super::super::super::super::objects::scout::spatial::api::UpdateSpatialMetadataRequest,
    ) -> Result<
        super::super::super::super::objects::scout::spatial::api::Spatial,
        conjure_http::private::Error,
    >;
    /// Archives a spatial asset, excluding it from search. Can be unarchived.
    #[endpoint(
        method = PUT,
        path = "/spatial/v1/spatials/{spatialRid}/archive",
        name = "archive"
    )]
    async fn archive(
        &self,
        #[auth]
        auth_: conjure_object::BearerToken,
        #[path(
            name = "spatialRid",
            decoder = conjure_http::server::conjure::FromPlainDecoder,
            log_as = "spatialRid"
        )]
        spatial_rid: conjure_object::ResourceIdentifier,
    ) -> Result<(), conjure_http::private::Error>;
    /// Unarchives a previously archived spatial asset.
    #[endpoint(
        method = PUT,
        path = "/spatial/v1/spatials/{spatialRid}/unarchive",
        name = "unarchive"
    )]
    async fn unarchive(
        &self,
        #[auth]
        auth_: conjure_object::BearerToken,
        #[path(
            name = "spatialRid",
            decoder = conjure_http::server::conjure::FromPlainDecoder,
            log_as = "spatialRid"
        )]
        spatial_rid: conjure_object::ResourceIdentifier,
    ) -> Result<(), conjure_http::private::Error>;
}
/// The spatial asset service manages spatial assets (point clouds, etc.) and their metadata.
/// Spatial asset data is stored in Dagger; Scout tracks metadata and references.
#[conjure_http::conjure_endpoints(
    name = "SpatialService",
    use_legacy_error_serialization,
    local
)]
pub trait LocalAsyncSpatialService {
    /// Returns spatial asset metadata associated with a spatial asset rid.
    #[endpoint(
        method = GET,
        path = "/spatial/v1/spatials/{spatialRid}",
        name = "get",
        produces = conjure_http::server::StdResponseSerializer
    )]
    async fn get(
        &self,
        #[auth]
        auth_: conjure_object::BearerToken,
        #[path(
            name = "spatialRid",
            decoder = conjure_http::server::conjure::FromPlainDecoder,
            log_as = "spatialRid"
        )]
        spatial_rid: conjure_object::ResourceIdentifier,
    ) -> Result<
        super::super::super::super::objects::scout::spatial::api::Spatial,
        conjure_http::private::Error,
    >;
    /// Returns spatial asset metadata for each given spatial asset rid.
    #[endpoint(
        method = POST,
        path = "/spatial/v1/spatials/batchGet",
        name = "batchGet",
        produces = conjure_http::server::StdResponseSerializer
    )]
    async fn batch_get(
        &self,
        #[auth]
        auth_: conjure_object::BearerToken,
        #[body(deserializer = conjure_http::server::StdRequestDeserializer)]
        request: super::super::super::super::objects::scout::spatial::api::GetSpatialsRequest,
    ) -> Result<
        super::super::super::super::objects::scout::spatial::api::GetSpatialsResponse,
        conjure_http::private::Error,
    >;
    /// Returns metadata about spatial assets that match a given query.
    #[endpoint(
        method = POST,
        path = "/spatial/v1/spatials/search",
        name = "search",
        produces = conjure_http::server::StdResponseSerializer
    )]
    async fn search(
        &self,
        #[auth]
        auth_: conjure_object::BearerToken,
        #[body(deserializer = conjure_http::server::StdRequestDeserializer)]
        request: super::super::super::super::objects::scout::spatial::api::SearchSpatialsRequest,
    ) -> Result<
        super::super::super::super::objects::scout::spatial::api::SearchSpatialsResponse,
        conjure_http::private::Error,
    >;
    /// Creates and persists a spatial asset entity with the given metadata.
    #[endpoint(
        method = POST,
        path = "/spatial/v1/spatials",
        name = "create",
        produces = conjure_http::server::StdResponseSerializer
    )]
    async fn create(
        &self,
        #[auth]
        auth_: conjure_object::BearerToken,
        #[body(deserializer = conjure_http::server::StdRequestDeserializer)]
        request: super::super::super::super::objects::scout::spatial::api::CreateSpatialRequest,
    ) -> Result<
        super::super::super::super::objects::scout::spatial::api::Spatial,
        conjure_http::private::Error,
    >;
    /// Updates the metadata for a spatial asset associated with the given rid.
    #[endpoint(
        method = PUT,
        path = "/spatial/v1/spatials/{spatialRid}",
        name = "updateMetadata",
        produces = conjure_http::server::StdResponseSerializer
    )]
    async fn update_metadata(
        &self,
        #[auth]
        auth_: conjure_object::BearerToken,
        #[path(
            name = "spatialRid",
            decoder = conjure_http::server::conjure::FromPlainDecoder,
            log_as = "spatialRid"
        )]
        spatial_rid: conjure_object::ResourceIdentifier,
        #[body(deserializer = conjure_http::server::StdRequestDeserializer)]
        request: super::super::super::super::objects::scout::spatial::api::UpdateSpatialMetadataRequest,
    ) -> Result<
        super::super::super::super::objects::scout::spatial::api::Spatial,
        conjure_http::private::Error,
    >;
    /// Archives a spatial asset, excluding it from search. Can be unarchived.
    #[endpoint(
        method = PUT,
        path = "/spatial/v1/spatials/{spatialRid}/archive",
        name = "archive"
    )]
    async fn archive(
        &self,
        #[auth]
        auth_: conjure_object::BearerToken,
        #[path(
            name = "spatialRid",
            decoder = conjure_http::server::conjure::FromPlainDecoder,
            log_as = "spatialRid"
        )]
        spatial_rid: conjure_object::ResourceIdentifier,
    ) -> Result<(), conjure_http::private::Error>;
    /// Unarchives a previously archived spatial asset.
    #[endpoint(
        method = PUT,
        path = "/spatial/v1/spatials/{spatialRid}/unarchive",
        name = "unarchive"
    )]
    async fn unarchive(
        &self,
        #[auth]
        auth_: conjure_object::BearerToken,
        #[path(
            name = "spatialRid",
            decoder = conjure_http::server::conjure::FromPlainDecoder,
            log_as = "spatialRid"
        )]
        spatial_rid: conjure_object::ResourceIdentifier,
    ) -> Result<(), conjure_http::private::Error>;
}
