use conjure_http::endpoint;
/// The Checklist Service is responsible for managing checklists and checks.
/// A checklist is a collection of checks that can be executed against a set of data sources.
#[conjure_http::conjure_endpoints(
    name = "ChecklistService",
    use_legacy_error_serialization
)]
pub trait ChecklistService {
    /// Creates a new checklist with the provided checks.
    #[endpoint(
        method = POST,
        path = "/scout/v1/checklists",
        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::super::objects::scout::checks::api::CreateChecklistRequest,
    ) -> Result<
        super::super::super::super::super::objects::scout::checks::api::VersionedChecklist,
        conjure_http::private::Error,
    >;
    /// Creates a permanent commit with a commit message.
    /// Throws if the checklist or branch doesn't exist.
    /// Throws if the latest commit doesn't match the provided id.
    /// Throws if you commit to an archived checklist.
    #[endpoint(
        method = POST,
        path = "/scout/v1/checklists/{checklistRid}/commit",
        name = "commit",
        produces = conjure_http::server::StdResponseSerializer
    )]
    fn commit(
        &self,
        #[auth]
        auth_: conjure_object::BearerToken,
        #[path(
            name = "checklistRid",
            decoder = conjure_http::server::conjure::FromPlainDecoder,
            log_as = "checklistRid",
            safe
        )]
        checklist_rid: super::super::super::super::super::objects::scout::rids::api::ChecklistRid,
        #[query(
            name = "branch",
            decoder = conjure_http::server::conjure::FromPlainOptionDecoder
        )]
        branch: Option<
            super::super::super::super::super::objects::scout::versioning::api::BranchName,
        >,
        #[body(deserializer = conjure_http::server::StdRequestDeserializer)]
        request: super::super::super::super::super::objects::scout::checks::api::CommitChecklistRequest,
    ) -> Result<
        super::super::super::super::super::objects::scout::checks::api::VersionedChecklist,
        conjure_http::private::Error,
    >;
    /// Creates a commit that may be compacted, e.g cleaned up and not exist anymore.
    /// Throws if the checklist or branch doesn't exist.
    /// Throws if the latest commit doesn't match the provided id.
    /// Throws if you save to an archived checklist.
    #[endpoint(
        method = POST,
        path = "/scout/v1/checklists/{checklistRid}/save-working-state",
        name = "saveWorkingState",
        produces = conjure_http::server::StdResponseSerializer
    )]
    fn save_working_state(
        &self,
        #[auth]
        auth_: conjure_object::BearerToken,
        #[path(
            name = "checklistRid",
            decoder = conjure_http::server::conjure::FromPlainDecoder,
            log_as = "checklistRid",
            safe
        )]
        checklist_rid: super::super::super::super::super::objects::scout::rids::api::ChecklistRid,
        #[query(
            name = "branch",
            decoder = conjure_http::server::conjure::FromPlainOptionDecoder
        )]
        branch: Option<
            super::super::super::super::super::objects::scout::versioning::api::BranchName,
        >,
        #[body(deserializer = conjure_http::server::StdRequestDeserializer)]
        request: super::super::super::super::super::objects::scout::checks::api::SaveChecklistRequest,
    ) -> Result<
        super::super::super::super::super::objects::scout::checks::api::VersionedChecklist,
        conjure_http::private::Error,
    >;
    /// Merges the given branch to the "main" branch.
    /// Throws if the checklist or branch doesn't exist.
    /// Throws if the latest commit doesn't match the provided id.
    /// Throws if you merge with an archived checklist.
    #[endpoint(
        method = POST,
        path = "/scout/v1/checklists/{checklistRid}/merge-to-main",
        name = "mergeToMain",
        produces = conjure_http::server::StdResponseSerializer
    )]
    fn merge_to_main(
        &self,
        #[auth]
        auth_: conjure_object::BearerToken,
        #[path(
            name = "checklistRid",
            decoder = conjure_http::server::conjure::FromPlainDecoder,
            log_as = "checklistRid",
            safe
        )]
        checklist_rid: super::super::super::super::super::objects::scout::rids::api::ChecklistRid,
        #[body(deserializer = conjure_http::server::StdRequestDeserializer)]
        request: super::super::super::super::super::objects::scout::checks::api::MergeToMainRequest,
    ) -> Result<
        super::super::super::super::super::objects::scout::checks::api::VersionedChecklist,
        conjure_http::private::Error,
    >;
    /// Updates the data source ref names for all checks within a checklist.
    /// Throws if the checklist doesn't exist.
    #[endpoint(
        method = POST,
        path = "/scout/v1/checklists/{checklistRid}/update-ref-names",
        name = "updateDataSourceRefNames",
        produces = conjure_http::server::StdResponseSerializer
    )]
    fn update_data_source_ref_names(
        &self,
        #[auth]
        auth_: conjure_object::BearerToken,
        #[path(
            name = "checklistRid",
            decoder = conjure_http::server::conjure::FromPlainDecoder,
            log_as = "checklistRid",
            safe
        )]
        checklist_rid: super::super::super::super::super::objects::scout::rids::api::ChecklistRid,
        #[query(
            name = "branch",
            decoder = conjure_http::server::conjure::FromPlainOptionDecoder
        )]
        branch: Option<
            super::super::super::super::super::objects::scout::versioning::api::BranchName,
        >,
        #[body(
            deserializer = conjure_http::server::StdRequestDeserializer,
            log_as = "refNameUpdates"
        )]
        ref_name_updates: std::collections::BTreeMap<
            super::super::super::super::super::objects::scout::api::DataSourceRefName,
            super::super::super::super::super::objects::scout::api::DataSourceRefName,
        >,
    ) -> Result<
        super::super::super::super::super::objects::scout::checks::api::VersionedChecklist,
        conjure_http::private::Error,
    >;
    /// Updates the metadata of a checklist.
    #[endpoint(
        method = PUT,
        path = "/scout/v1/checklists/{rid}/update-metadata",
        name = "updateMetadata",
        produces = conjure_http::server::StdResponseSerializer
    )]
    fn update_metadata(
        &self,
        #[auth]
        auth_: conjure_object::BearerToken,
        #[path(
            name = "rid",
            decoder = conjure_http::server::conjure::FromPlainDecoder,
            safe
        )]
        rid: super::super::super::super::super::objects::scout::rids::api::ChecklistRid,
        #[body(deserializer = conjure_http::server::StdRequestDeserializer)]
        request: super::super::super::super::super::objects::scout::checks::api::UpdateChecklistMetadataRequest,
    ) -> Result<
        super::super::super::super::super::objects::scout::checks::api::ChecklistMetadata,
        conjure_http::private::Error,
    >;
    /// Specify at most one of (branch, commit).
    /// If neither is specified, branch = "main" is the default.
    #[endpoint(
        method = GET,
        path = "/scout/v1/checklists/{rid}",
        name = "get",
        produces = conjure_http::server::StdResponseSerializer
    )]
    fn get(
        &self,
        #[auth]
        auth_: conjure_object::BearerToken,
        #[path(
            name = "rid",
            decoder = conjure_http::server::conjure::FromPlainDecoder,
            safe
        )]
        rid: super::super::super::super::super::objects::scout::rids::api::ChecklistRid,
        #[query(
            name = "branch",
            decoder = conjure_http::server::conjure::FromPlainOptionDecoder
        )]
        branch: Option<
            super::super::super::super::super::objects::scout::versioning::api::BranchName,
        >,
        #[query(
            name = "commit",
            decoder = conjure_http::server::conjure::FromPlainOptionDecoder,
            safe
        )]
        commit: Option<
            super::super::super::super::super::objects::scout::versioning::api::CommitId,
        >,
    ) -> Result<
        super::super::super::super::super::objects::scout::checks::api::VersionedChecklist,
        conjure_http::private::Error,
    >;
    /// Returns the pinned commit for each provided checklist reference.
    #[endpoint(
        method = POST,
        path = "/scout/v1/checklists/batch-get",
        name = "batchGet",
        produces = conjure_http::server::conjure::CollectionResponseSerializer
    )]
    fn batch_get(
        &self,
        #[auth]
        auth_: conjure_object::BearerToken,
        #[body(
            deserializer = conjure_http::server::StdRequestDeserializer,
            log_as = "checklistRefs",
            safe
        )]
        checklist_refs: std::collections::BTreeSet<
            super::super::super::super::super::objects::scout::checks::api::PinnedChecklistRef,
        >,
    ) -> Result<
        std::collections::BTreeSet<
            super::super::super::super::super::objects::scout::checks::api::VersionedChecklist,
        >,
        conjure_http::private::Error,
    >;
    /// Returns the metadata for each provided checklist.
    #[endpoint(
        method = POST,
        path = "/scout/v1/checklists/batch-get-metadata",
        name = "batchGetMetadata",
        produces = conjure_http::server::StdResponseSerializer
    )]
    fn batch_get_metadata(
        &self,
        #[auth]
        auth_: conjure_object::BearerToken,
        #[body(deserializer = conjure_http::server::StdRequestDeserializer, safe)]
        request: super::super::super::super::super::objects::scout::checks::api::BatchGetChecklistMetadataRequest,
    ) -> Result<
        super::super::super::super::super::objects::scout::checks::api::BatchGetChecklistMetadataResponse,
        conjure_http::private::Error,
    >;
    /// Results will be the latest commit on main for each checklist.
    #[endpoint(
        method = POST,
        path = "/scout/v1/checklists/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::super::objects::scout::checks::api::SearchChecklistsRequest,
    ) -> Result<
        super::super::super::super::super::objects::scout::checks::api::VersionedChecklistPage,
        conjure_http::private::Error,
    >;
    /// Archives the provided checklists.
    #[endpoint(method = POST, path = "/scout/v1/checklists/archive", name = "archive")]
    fn archive(
        &self,
        #[auth]
        auth_: conjure_object::BearerToken,
        #[body(deserializer = conjure_http::server::StdRequestDeserializer, safe)]
        request: super::super::super::super::super::objects::scout::checks::api::ArchiveChecklistsRequest,
    ) -> Result<(), conjure_http::private::Error>;
    /// Unarchives the provided checklists.
    #[endpoint(
        method = POST,
        path = "/scout/v1/checklists/unarchive",
        name = "unarchive"
    )]
    fn unarchive(
        &self,
        #[auth]
        auth_: conjure_object::BearerToken,
        #[body(deserializer = conjure_http::server::StdRequestDeserializer, safe)]
        request: super::super::super::super::super::objects::scout::checks::api::UnarchiveChecklistsRequest,
    ) -> Result<(), conjure_http::private::Error>;
    /// Returns the check with the given rid.
    #[endpoint(
        method = GET,
        path = "/scout/v1/checklists/check/{rid}",
        name = "getCheck",
        produces = conjure_http::server::StdResponseSerializer
    )]
    fn get_check(
        &self,
        #[auth]
        auth_: conjure_object::BearerToken,
        #[path(
            name = "rid",
            decoder = conjure_http::server::conjure::FromPlainDecoder,
            safe
        )]
        rid: super::super::super::super::super::objects::scout::rids::api::CheckRid,
    ) -> Result<
        super::super::super::super::super::objects::scout::checks::api::Check,
        conjure_http::private::Error,
    >;
    /// Returns the checks with the given rids.
    #[endpoint(
        method = POST,
        path = "/scout/v1/checklists/check/batch-get",
        name = "batchGetChecks",
        produces = conjure_http::server::conjure::CollectionResponseSerializer
    )]
    fn batch_get_checks(
        &self,
        #[auth]
        auth_: conjure_object::BearerToken,
        #[body(deserializer = conjure_http::server::StdRequestDeserializer, safe)]
        rids: std::collections::BTreeSet<
            super::super::super::super::super::objects::scout::rids::api::CheckRid,
        >,
    ) -> Result<
        std::collections::BTreeSet<
            super::super::super::super::super::objects::scout::checks::api::Check,
        >,
        conjure_http::private::Error,
    >;
    /// Returns all labels and properties.
    #[endpoint(
        method = GET,
        path = "/scout/v1/checklists/get-all-labels-properties",
        name = "getAllLabelsAndProperties",
        produces = conjure_http::server::StdResponseSerializer
    )]
    fn get_all_labels_and_properties(
        &self,
        #[auth]
        auth_: conjure_object::BearerToken,
        #[query(
            name = "workspaces",
            decoder = conjure_http::server::conjure::FromPlainSeqDecoder<_>
        )]
        workspaces: std::collections::BTreeSet<conjure_object::ResourceIdentifier>,
    ) -> Result<
        super::super::super::super::super::objects::scout::checks::api::GetAllLabelsAndPropertiesResponse,
        conjure_http::private::Error,
    >;
    /// Batch edits metadata across multiple checklists. Supports rename/merge for labels and properties.
    /// If more than 1000 checklists are targeted, this endpoint will throw a 400.
    #[endpoint(
        method = POST,
        path = "/scout/v1/checklists/metadata/batch-edit",
        name = "batchEditChecklistMetadata",
        produces = conjure_http::server::StdResponseSerializer
    )]
    fn batch_edit_checklist_metadata(
        &self,
        #[auth]
        auth_: conjure_object::BearerToken,
        #[body(deserializer = conjure_http::server::StdRequestDeserializer)]
        request: super::super::super::super::super::objects::scout::checks::api::BatchEditChecklistMetadataRequest,
    ) -> Result<
        super::super::super::super::super::objects::scout::checks::api::BatchEditChecklistMetadataResponse,
        conjure_http::private::Error,
    >;
}
/// The Checklist Service is responsible for managing checklists and checks.
/// A checklist is a collection of checks that can be executed against a set of data sources.
#[conjure_http::conjure_endpoints(
    name = "ChecklistService",
    use_legacy_error_serialization
)]
pub trait AsyncChecklistService {
    /// Creates a new checklist with the provided checks.
    #[endpoint(
        method = POST,
        path = "/scout/v1/checklists",
        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::super::objects::scout::checks::api::CreateChecklistRequest,
    ) -> Result<
        super::super::super::super::super::objects::scout::checks::api::VersionedChecklist,
        conjure_http::private::Error,
    >;
    /// Creates a permanent commit with a commit message.
    /// Throws if the checklist or branch doesn't exist.
    /// Throws if the latest commit doesn't match the provided id.
    /// Throws if you commit to an archived checklist.
    #[endpoint(
        method = POST,
        path = "/scout/v1/checklists/{checklistRid}/commit",
        name = "commit",
        produces = conjure_http::server::StdResponseSerializer
    )]
    async fn commit(
        &self,
        #[auth]
        auth_: conjure_object::BearerToken,
        #[path(
            name = "checklistRid",
            decoder = conjure_http::server::conjure::FromPlainDecoder,
            log_as = "checklistRid",
            safe
        )]
        checklist_rid: super::super::super::super::super::objects::scout::rids::api::ChecklistRid,
        #[query(
            name = "branch",
            decoder = conjure_http::server::conjure::FromPlainOptionDecoder
        )]
        branch: Option<
            super::super::super::super::super::objects::scout::versioning::api::BranchName,
        >,
        #[body(deserializer = conjure_http::server::StdRequestDeserializer)]
        request: super::super::super::super::super::objects::scout::checks::api::CommitChecklistRequest,
    ) -> Result<
        super::super::super::super::super::objects::scout::checks::api::VersionedChecklist,
        conjure_http::private::Error,
    >;
    /// Creates a commit that may be compacted, e.g cleaned up and not exist anymore.
    /// Throws if the checklist or branch doesn't exist.
    /// Throws if the latest commit doesn't match the provided id.
    /// Throws if you save to an archived checklist.
    #[endpoint(
        method = POST,
        path = "/scout/v1/checklists/{checklistRid}/save-working-state",
        name = "saveWorkingState",
        produces = conjure_http::server::StdResponseSerializer
    )]
    async fn save_working_state(
        &self,
        #[auth]
        auth_: conjure_object::BearerToken,
        #[path(
            name = "checklistRid",
            decoder = conjure_http::server::conjure::FromPlainDecoder,
            log_as = "checklistRid",
            safe
        )]
        checklist_rid: super::super::super::super::super::objects::scout::rids::api::ChecklistRid,
        #[query(
            name = "branch",
            decoder = conjure_http::server::conjure::FromPlainOptionDecoder
        )]
        branch: Option<
            super::super::super::super::super::objects::scout::versioning::api::BranchName,
        >,
        #[body(deserializer = conjure_http::server::StdRequestDeserializer)]
        request: super::super::super::super::super::objects::scout::checks::api::SaveChecklistRequest,
    ) -> Result<
        super::super::super::super::super::objects::scout::checks::api::VersionedChecklist,
        conjure_http::private::Error,
    >;
    /// Merges the given branch to the "main" branch.
    /// Throws if the checklist or branch doesn't exist.
    /// Throws if the latest commit doesn't match the provided id.
    /// Throws if you merge with an archived checklist.
    #[endpoint(
        method = POST,
        path = "/scout/v1/checklists/{checklistRid}/merge-to-main",
        name = "mergeToMain",
        produces = conjure_http::server::StdResponseSerializer
    )]
    async fn merge_to_main(
        &self,
        #[auth]
        auth_: conjure_object::BearerToken,
        #[path(
            name = "checklistRid",
            decoder = conjure_http::server::conjure::FromPlainDecoder,
            log_as = "checklistRid",
            safe
        )]
        checklist_rid: super::super::super::super::super::objects::scout::rids::api::ChecklistRid,
        #[body(deserializer = conjure_http::server::StdRequestDeserializer)]
        request: super::super::super::super::super::objects::scout::checks::api::MergeToMainRequest,
    ) -> Result<
        super::super::super::super::super::objects::scout::checks::api::VersionedChecklist,
        conjure_http::private::Error,
    >;
    /// Updates the data source ref names for all checks within a checklist.
    /// Throws if the checklist doesn't exist.
    #[endpoint(
        method = POST,
        path = "/scout/v1/checklists/{checklistRid}/update-ref-names",
        name = "updateDataSourceRefNames",
        produces = conjure_http::server::StdResponseSerializer
    )]
    async fn update_data_source_ref_names(
        &self,
        #[auth]
        auth_: conjure_object::BearerToken,
        #[path(
            name = "checklistRid",
            decoder = conjure_http::server::conjure::FromPlainDecoder,
            log_as = "checklistRid",
            safe
        )]
        checklist_rid: super::super::super::super::super::objects::scout::rids::api::ChecklistRid,
        #[query(
            name = "branch",
            decoder = conjure_http::server::conjure::FromPlainOptionDecoder
        )]
        branch: Option<
            super::super::super::super::super::objects::scout::versioning::api::BranchName,
        >,
        #[body(
            deserializer = conjure_http::server::StdRequestDeserializer,
            log_as = "refNameUpdates"
        )]
        ref_name_updates: std::collections::BTreeMap<
            super::super::super::super::super::objects::scout::api::DataSourceRefName,
            super::super::super::super::super::objects::scout::api::DataSourceRefName,
        >,
    ) -> Result<
        super::super::super::super::super::objects::scout::checks::api::VersionedChecklist,
        conjure_http::private::Error,
    >;
    /// Updates the metadata of a checklist.
    #[endpoint(
        method = PUT,
        path = "/scout/v1/checklists/{rid}/update-metadata",
        name = "updateMetadata",
        produces = conjure_http::server::StdResponseSerializer
    )]
    async fn update_metadata(
        &self,
        #[auth]
        auth_: conjure_object::BearerToken,
        #[path(
            name = "rid",
            decoder = conjure_http::server::conjure::FromPlainDecoder,
            safe
        )]
        rid: super::super::super::super::super::objects::scout::rids::api::ChecklistRid,
        #[body(deserializer = conjure_http::server::StdRequestDeserializer)]
        request: super::super::super::super::super::objects::scout::checks::api::UpdateChecklistMetadataRequest,
    ) -> Result<
        super::super::super::super::super::objects::scout::checks::api::ChecklistMetadata,
        conjure_http::private::Error,
    >;
    /// Specify at most one of (branch, commit).
    /// If neither is specified, branch = "main" is the default.
    #[endpoint(
        method = GET,
        path = "/scout/v1/checklists/{rid}",
        name = "get",
        produces = conjure_http::server::StdResponseSerializer
    )]
    async fn get(
        &self,
        #[auth]
        auth_: conjure_object::BearerToken,
        #[path(
            name = "rid",
            decoder = conjure_http::server::conjure::FromPlainDecoder,
            safe
        )]
        rid: super::super::super::super::super::objects::scout::rids::api::ChecklistRid,
        #[query(
            name = "branch",
            decoder = conjure_http::server::conjure::FromPlainOptionDecoder
        )]
        branch: Option<
            super::super::super::super::super::objects::scout::versioning::api::BranchName,
        >,
        #[query(
            name = "commit",
            decoder = conjure_http::server::conjure::FromPlainOptionDecoder,
            safe
        )]
        commit: Option<
            super::super::super::super::super::objects::scout::versioning::api::CommitId,
        >,
    ) -> Result<
        super::super::super::super::super::objects::scout::checks::api::VersionedChecklist,
        conjure_http::private::Error,
    >;
    /// Returns the pinned commit for each provided checklist reference.
    #[endpoint(
        method = POST,
        path = "/scout/v1/checklists/batch-get",
        name = "batchGet",
        produces = conjure_http::server::conjure::CollectionResponseSerializer
    )]
    async fn batch_get(
        &self,
        #[auth]
        auth_: conjure_object::BearerToken,
        #[body(
            deserializer = conjure_http::server::StdRequestDeserializer,
            log_as = "checklistRefs",
            safe
        )]
        checklist_refs: std::collections::BTreeSet<
            super::super::super::super::super::objects::scout::checks::api::PinnedChecklistRef,
        >,
    ) -> Result<
        std::collections::BTreeSet<
            super::super::super::super::super::objects::scout::checks::api::VersionedChecklist,
        >,
        conjure_http::private::Error,
    >;
    /// Returns the metadata for each provided checklist.
    #[endpoint(
        method = POST,
        path = "/scout/v1/checklists/batch-get-metadata",
        name = "batchGetMetadata",
        produces = conjure_http::server::StdResponseSerializer
    )]
    async fn batch_get_metadata(
        &self,
        #[auth]
        auth_: conjure_object::BearerToken,
        #[body(deserializer = conjure_http::server::StdRequestDeserializer, safe)]
        request: super::super::super::super::super::objects::scout::checks::api::BatchGetChecklistMetadataRequest,
    ) -> Result<
        super::super::super::super::super::objects::scout::checks::api::BatchGetChecklistMetadataResponse,
        conjure_http::private::Error,
    >;
    /// Results will be the latest commit on main for each checklist.
    #[endpoint(
        method = POST,
        path = "/scout/v1/checklists/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::super::objects::scout::checks::api::SearchChecklistsRequest,
    ) -> Result<
        super::super::super::super::super::objects::scout::checks::api::VersionedChecklistPage,
        conjure_http::private::Error,
    >;
    /// Archives the provided checklists.
    #[endpoint(method = POST, path = "/scout/v1/checklists/archive", name = "archive")]
    async fn archive(
        &self,
        #[auth]
        auth_: conjure_object::BearerToken,
        #[body(deserializer = conjure_http::server::StdRequestDeserializer, safe)]
        request: super::super::super::super::super::objects::scout::checks::api::ArchiveChecklistsRequest,
    ) -> Result<(), conjure_http::private::Error>;
    /// Unarchives the provided checklists.
    #[endpoint(
        method = POST,
        path = "/scout/v1/checklists/unarchive",
        name = "unarchive"
    )]
    async fn unarchive(
        &self,
        #[auth]
        auth_: conjure_object::BearerToken,
        #[body(deserializer = conjure_http::server::StdRequestDeserializer, safe)]
        request: super::super::super::super::super::objects::scout::checks::api::UnarchiveChecklistsRequest,
    ) -> Result<(), conjure_http::private::Error>;
    /// Returns the check with the given rid.
    #[endpoint(
        method = GET,
        path = "/scout/v1/checklists/check/{rid}",
        name = "getCheck",
        produces = conjure_http::server::StdResponseSerializer
    )]
    async fn get_check(
        &self,
        #[auth]
        auth_: conjure_object::BearerToken,
        #[path(
            name = "rid",
            decoder = conjure_http::server::conjure::FromPlainDecoder,
            safe
        )]
        rid: super::super::super::super::super::objects::scout::rids::api::CheckRid,
    ) -> Result<
        super::super::super::super::super::objects::scout::checks::api::Check,
        conjure_http::private::Error,
    >;
    /// Returns the checks with the given rids.
    #[endpoint(
        method = POST,
        path = "/scout/v1/checklists/check/batch-get",
        name = "batchGetChecks",
        produces = conjure_http::server::conjure::CollectionResponseSerializer
    )]
    async fn batch_get_checks(
        &self,
        #[auth]
        auth_: conjure_object::BearerToken,
        #[body(deserializer = conjure_http::server::StdRequestDeserializer, safe)]
        rids: std::collections::BTreeSet<
            super::super::super::super::super::objects::scout::rids::api::CheckRid,
        >,
    ) -> Result<
        std::collections::BTreeSet<
            super::super::super::super::super::objects::scout::checks::api::Check,
        >,
        conjure_http::private::Error,
    >;
    /// Returns all labels and properties.
    #[endpoint(
        method = GET,
        path = "/scout/v1/checklists/get-all-labels-properties",
        name = "getAllLabelsAndProperties",
        produces = conjure_http::server::StdResponseSerializer
    )]
    async fn get_all_labels_and_properties(
        &self,
        #[auth]
        auth_: conjure_object::BearerToken,
        #[query(
            name = "workspaces",
            decoder = conjure_http::server::conjure::FromPlainSeqDecoder<_>
        )]
        workspaces: std::collections::BTreeSet<conjure_object::ResourceIdentifier>,
    ) -> Result<
        super::super::super::super::super::objects::scout::checks::api::GetAllLabelsAndPropertiesResponse,
        conjure_http::private::Error,
    >;
    /// Batch edits metadata across multiple checklists. Supports rename/merge for labels and properties.
    /// If more than 1000 checklists are targeted, this endpoint will throw a 400.
    #[endpoint(
        method = POST,
        path = "/scout/v1/checklists/metadata/batch-edit",
        name = "batchEditChecklistMetadata",
        produces = conjure_http::server::StdResponseSerializer
    )]
    async fn batch_edit_checklist_metadata(
        &self,
        #[auth]
        auth_: conjure_object::BearerToken,
        #[body(deserializer = conjure_http::server::StdRequestDeserializer)]
        request: super::super::super::super::super::objects::scout::checks::api::BatchEditChecklistMetadataRequest,
    ) -> Result<
        super::super::super::super::super::objects::scout::checks::api::BatchEditChecklistMetadataResponse,
        conjure_http::private::Error,
    >;
}
/// The Checklist Service is responsible for managing checklists and checks.
/// A checklist is a collection of checks that can be executed against a set of data sources.
#[conjure_http::conjure_endpoints(
    name = "ChecklistService",
    use_legacy_error_serialization,
    local
)]
pub trait LocalAsyncChecklistService {
    /// Creates a new checklist with the provided checks.
    #[endpoint(
        method = POST,
        path = "/scout/v1/checklists",
        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::super::objects::scout::checks::api::CreateChecklistRequest,
    ) -> Result<
        super::super::super::super::super::objects::scout::checks::api::VersionedChecklist,
        conjure_http::private::Error,
    >;
    /// Creates a permanent commit with a commit message.
    /// Throws if the checklist or branch doesn't exist.
    /// Throws if the latest commit doesn't match the provided id.
    /// Throws if you commit to an archived checklist.
    #[endpoint(
        method = POST,
        path = "/scout/v1/checklists/{checklistRid}/commit",
        name = "commit",
        produces = conjure_http::server::StdResponseSerializer
    )]
    async fn commit(
        &self,
        #[auth]
        auth_: conjure_object::BearerToken,
        #[path(
            name = "checklistRid",
            decoder = conjure_http::server::conjure::FromPlainDecoder,
            log_as = "checklistRid",
            safe
        )]
        checklist_rid: super::super::super::super::super::objects::scout::rids::api::ChecklistRid,
        #[query(
            name = "branch",
            decoder = conjure_http::server::conjure::FromPlainOptionDecoder
        )]
        branch: Option<
            super::super::super::super::super::objects::scout::versioning::api::BranchName,
        >,
        #[body(deserializer = conjure_http::server::StdRequestDeserializer)]
        request: super::super::super::super::super::objects::scout::checks::api::CommitChecklistRequest,
    ) -> Result<
        super::super::super::super::super::objects::scout::checks::api::VersionedChecklist,
        conjure_http::private::Error,
    >;
    /// Creates a commit that may be compacted, e.g cleaned up and not exist anymore.
    /// Throws if the checklist or branch doesn't exist.
    /// Throws if the latest commit doesn't match the provided id.
    /// Throws if you save to an archived checklist.
    #[endpoint(
        method = POST,
        path = "/scout/v1/checklists/{checklistRid}/save-working-state",
        name = "saveWorkingState",
        produces = conjure_http::server::StdResponseSerializer
    )]
    async fn save_working_state(
        &self,
        #[auth]
        auth_: conjure_object::BearerToken,
        #[path(
            name = "checklistRid",
            decoder = conjure_http::server::conjure::FromPlainDecoder,
            log_as = "checklistRid",
            safe
        )]
        checklist_rid: super::super::super::super::super::objects::scout::rids::api::ChecklistRid,
        #[query(
            name = "branch",
            decoder = conjure_http::server::conjure::FromPlainOptionDecoder
        )]
        branch: Option<
            super::super::super::super::super::objects::scout::versioning::api::BranchName,
        >,
        #[body(deserializer = conjure_http::server::StdRequestDeserializer)]
        request: super::super::super::super::super::objects::scout::checks::api::SaveChecklistRequest,
    ) -> Result<
        super::super::super::super::super::objects::scout::checks::api::VersionedChecklist,
        conjure_http::private::Error,
    >;
    /// Merges the given branch to the "main" branch.
    /// Throws if the checklist or branch doesn't exist.
    /// Throws if the latest commit doesn't match the provided id.
    /// Throws if you merge with an archived checklist.
    #[endpoint(
        method = POST,
        path = "/scout/v1/checklists/{checklistRid}/merge-to-main",
        name = "mergeToMain",
        produces = conjure_http::server::StdResponseSerializer
    )]
    async fn merge_to_main(
        &self,
        #[auth]
        auth_: conjure_object::BearerToken,
        #[path(
            name = "checklistRid",
            decoder = conjure_http::server::conjure::FromPlainDecoder,
            log_as = "checklistRid",
            safe
        )]
        checklist_rid: super::super::super::super::super::objects::scout::rids::api::ChecklistRid,
        #[body(deserializer = conjure_http::server::StdRequestDeserializer)]
        request: super::super::super::super::super::objects::scout::checks::api::MergeToMainRequest,
    ) -> Result<
        super::super::super::super::super::objects::scout::checks::api::VersionedChecklist,
        conjure_http::private::Error,
    >;
    /// Updates the data source ref names for all checks within a checklist.
    /// Throws if the checklist doesn't exist.
    #[endpoint(
        method = POST,
        path = "/scout/v1/checklists/{checklistRid}/update-ref-names",
        name = "updateDataSourceRefNames",
        produces = conjure_http::server::StdResponseSerializer
    )]
    async fn update_data_source_ref_names(
        &self,
        #[auth]
        auth_: conjure_object::BearerToken,
        #[path(
            name = "checklistRid",
            decoder = conjure_http::server::conjure::FromPlainDecoder,
            log_as = "checklistRid",
            safe
        )]
        checklist_rid: super::super::super::super::super::objects::scout::rids::api::ChecklistRid,
        #[query(
            name = "branch",
            decoder = conjure_http::server::conjure::FromPlainOptionDecoder
        )]
        branch: Option<
            super::super::super::super::super::objects::scout::versioning::api::BranchName,
        >,
        #[body(
            deserializer = conjure_http::server::StdRequestDeserializer,
            log_as = "refNameUpdates"
        )]
        ref_name_updates: std::collections::BTreeMap<
            super::super::super::super::super::objects::scout::api::DataSourceRefName,
            super::super::super::super::super::objects::scout::api::DataSourceRefName,
        >,
    ) -> Result<
        super::super::super::super::super::objects::scout::checks::api::VersionedChecklist,
        conjure_http::private::Error,
    >;
    /// Updates the metadata of a checklist.
    #[endpoint(
        method = PUT,
        path = "/scout/v1/checklists/{rid}/update-metadata",
        name = "updateMetadata",
        produces = conjure_http::server::StdResponseSerializer
    )]
    async fn update_metadata(
        &self,
        #[auth]
        auth_: conjure_object::BearerToken,
        #[path(
            name = "rid",
            decoder = conjure_http::server::conjure::FromPlainDecoder,
            safe
        )]
        rid: super::super::super::super::super::objects::scout::rids::api::ChecklistRid,
        #[body(deserializer = conjure_http::server::StdRequestDeserializer)]
        request: super::super::super::super::super::objects::scout::checks::api::UpdateChecklistMetadataRequest,
    ) -> Result<
        super::super::super::super::super::objects::scout::checks::api::ChecklistMetadata,
        conjure_http::private::Error,
    >;
    /// Specify at most one of (branch, commit).
    /// If neither is specified, branch = "main" is the default.
    #[endpoint(
        method = GET,
        path = "/scout/v1/checklists/{rid}",
        name = "get",
        produces = conjure_http::server::StdResponseSerializer
    )]
    async fn get(
        &self,
        #[auth]
        auth_: conjure_object::BearerToken,
        #[path(
            name = "rid",
            decoder = conjure_http::server::conjure::FromPlainDecoder,
            safe
        )]
        rid: super::super::super::super::super::objects::scout::rids::api::ChecklistRid,
        #[query(
            name = "branch",
            decoder = conjure_http::server::conjure::FromPlainOptionDecoder
        )]
        branch: Option<
            super::super::super::super::super::objects::scout::versioning::api::BranchName,
        >,
        #[query(
            name = "commit",
            decoder = conjure_http::server::conjure::FromPlainOptionDecoder,
            safe
        )]
        commit: Option<
            super::super::super::super::super::objects::scout::versioning::api::CommitId,
        >,
    ) -> Result<
        super::super::super::super::super::objects::scout::checks::api::VersionedChecklist,
        conjure_http::private::Error,
    >;
    /// Returns the pinned commit for each provided checklist reference.
    #[endpoint(
        method = POST,
        path = "/scout/v1/checklists/batch-get",
        name = "batchGet",
        produces = conjure_http::server::conjure::CollectionResponseSerializer
    )]
    async fn batch_get(
        &self,
        #[auth]
        auth_: conjure_object::BearerToken,
        #[body(
            deserializer = conjure_http::server::StdRequestDeserializer,
            log_as = "checklistRefs",
            safe
        )]
        checklist_refs: std::collections::BTreeSet<
            super::super::super::super::super::objects::scout::checks::api::PinnedChecklistRef,
        >,
    ) -> Result<
        std::collections::BTreeSet<
            super::super::super::super::super::objects::scout::checks::api::VersionedChecklist,
        >,
        conjure_http::private::Error,
    >;
    /// Returns the metadata for each provided checklist.
    #[endpoint(
        method = POST,
        path = "/scout/v1/checklists/batch-get-metadata",
        name = "batchGetMetadata",
        produces = conjure_http::server::StdResponseSerializer
    )]
    async fn batch_get_metadata(
        &self,
        #[auth]
        auth_: conjure_object::BearerToken,
        #[body(deserializer = conjure_http::server::StdRequestDeserializer, safe)]
        request: super::super::super::super::super::objects::scout::checks::api::BatchGetChecklistMetadataRequest,
    ) -> Result<
        super::super::super::super::super::objects::scout::checks::api::BatchGetChecklistMetadataResponse,
        conjure_http::private::Error,
    >;
    /// Results will be the latest commit on main for each checklist.
    #[endpoint(
        method = POST,
        path = "/scout/v1/checklists/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::super::objects::scout::checks::api::SearchChecklistsRequest,
    ) -> Result<
        super::super::super::super::super::objects::scout::checks::api::VersionedChecklistPage,
        conjure_http::private::Error,
    >;
    /// Archives the provided checklists.
    #[endpoint(method = POST, path = "/scout/v1/checklists/archive", name = "archive")]
    async fn archive(
        &self,
        #[auth]
        auth_: conjure_object::BearerToken,
        #[body(deserializer = conjure_http::server::StdRequestDeserializer, safe)]
        request: super::super::super::super::super::objects::scout::checks::api::ArchiveChecklistsRequest,
    ) -> Result<(), conjure_http::private::Error>;
    /// Unarchives the provided checklists.
    #[endpoint(
        method = POST,
        path = "/scout/v1/checklists/unarchive",
        name = "unarchive"
    )]
    async fn unarchive(
        &self,
        #[auth]
        auth_: conjure_object::BearerToken,
        #[body(deserializer = conjure_http::server::StdRequestDeserializer, safe)]
        request: super::super::super::super::super::objects::scout::checks::api::UnarchiveChecklistsRequest,
    ) -> Result<(), conjure_http::private::Error>;
    /// Returns the check with the given rid.
    #[endpoint(
        method = GET,
        path = "/scout/v1/checklists/check/{rid}",
        name = "getCheck",
        produces = conjure_http::server::StdResponseSerializer
    )]
    async fn get_check(
        &self,
        #[auth]
        auth_: conjure_object::BearerToken,
        #[path(
            name = "rid",
            decoder = conjure_http::server::conjure::FromPlainDecoder,
            safe
        )]
        rid: super::super::super::super::super::objects::scout::rids::api::CheckRid,
    ) -> Result<
        super::super::super::super::super::objects::scout::checks::api::Check,
        conjure_http::private::Error,
    >;
    /// Returns the checks with the given rids.
    #[endpoint(
        method = POST,
        path = "/scout/v1/checklists/check/batch-get",
        name = "batchGetChecks",
        produces = conjure_http::server::conjure::CollectionResponseSerializer
    )]
    async fn batch_get_checks(
        &self,
        #[auth]
        auth_: conjure_object::BearerToken,
        #[body(deserializer = conjure_http::server::StdRequestDeserializer, safe)]
        rids: std::collections::BTreeSet<
            super::super::super::super::super::objects::scout::rids::api::CheckRid,
        >,
    ) -> Result<
        std::collections::BTreeSet<
            super::super::super::super::super::objects::scout::checks::api::Check,
        >,
        conjure_http::private::Error,
    >;
    /// Returns all labels and properties.
    #[endpoint(
        method = GET,
        path = "/scout/v1/checklists/get-all-labels-properties",
        name = "getAllLabelsAndProperties",
        produces = conjure_http::server::StdResponseSerializer
    )]
    async fn get_all_labels_and_properties(
        &self,
        #[auth]
        auth_: conjure_object::BearerToken,
        #[query(
            name = "workspaces",
            decoder = conjure_http::server::conjure::FromPlainSeqDecoder<_>
        )]
        workspaces: std::collections::BTreeSet<conjure_object::ResourceIdentifier>,
    ) -> Result<
        super::super::super::super::super::objects::scout::checks::api::GetAllLabelsAndPropertiesResponse,
        conjure_http::private::Error,
    >;
    /// Batch edits metadata across multiple checklists. Supports rename/merge for labels and properties.
    /// If more than 1000 checklists are targeted, this endpoint will throw a 400.
    #[endpoint(
        method = POST,
        path = "/scout/v1/checklists/metadata/batch-edit",
        name = "batchEditChecklistMetadata",
        produces = conjure_http::server::StdResponseSerializer
    )]
    async fn batch_edit_checklist_metadata(
        &self,
        #[auth]
        auth_: conjure_object::BearerToken,
        #[body(deserializer = conjure_http::server::StdRequestDeserializer)]
        request: super::super::super::super::super::objects::scout::checks::api::BatchEditChecklistMetadataRequest,
    ) -> Result<
        super::super::super::super::super::objects::scout::checks::api::BatchEditChecklistMetadataResponse,
        conjure_http::private::Error,
    >;
}
