Skip to main content

nominal_api/conjure/endpoints/scout/
versioning_service.rs

1use conjure_http::endpoint;
2/// This is the external-facing portion of VersioningService which
3/// gives clients access to functionality that doesn't create new
4/// commits. The creation of new commits should be done via the
5/// resource-specific services.
6#[conjure_http::conjure_endpoints(
7    name = "VersioningService",
8    use_legacy_error_serialization
9)]
10pub trait VersioningService {
11    /// Creates a mutable pointer to the provided commit.
12    /// "Saves"/"commits" can be performed on this pointer.
13    /// Throws if the name is already used as a commit
14    /// pointer for this resource.
15    /// Throws if the provided commit doesn't exist.
16    #[endpoint(
17        method = POST,
18        path = "/scout/v1/versioning/{resourceRid}/branch",
19        name = "createBranch",
20        produces = conjure_http::server::StdResponseSerializer
21    )]
22    fn create_branch(
23        &self,
24        #[auth]
25        auth_: conjure_object::BearerToken,
26        #[path(
27            name = "resourceRid",
28            decoder = conjure_http::server::conjure::FromPlainDecoder,
29            log_as = "resourceRid"
30        )]
31        resource_rid: conjure_object::ResourceIdentifier,
32        #[body(deserializer = conjure_http::server::StdRequestDeserializer)]
33        request: super::super::super::objects::scout::versioning::api::CreateBranchRequest,
34    ) -> Result<
35        super::super::super::objects::scout::versioning::api::Branch,
36        conjure_http::private::Error,
37    >;
38    /// Creates an immutable pointer to the provided commit.
39    /// Throws if the name is already used as a commit
40    /// pointer for this resource.
41    /// Throws if the provided commit doesn't exist.
42    #[endpoint(
43        method = POST,
44        path = "/scout/v1/versioning/{resourceRid}/tag",
45        name = "createTag",
46        produces = conjure_http::server::StdResponseSerializer
47    )]
48    fn create_tag(
49        &self,
50        #[auth]
51        auth_: conjure_object::BearerToken,
52        #[path(
53            name = "resourceRid",
54            decoder = conjure_http::server::conjure::FromPlainDecoder,
55            log_as = "resourceRid"
56        )]
57        resource_rid: conjure_object::ResourceIdentifier,
58        #[body(deserializer = conjure_http::server::StdRequestDeserializer)]
59        request: super::super::super::objects::scout::versioning::api::CreateTagRequest,
60    ) -> Result<
61        super::super::super::objects::scout::versioning::api::Tag,
62        conjure_http::private::Error,
63    >;
64    /// Throws if the commit doesn't exist.
65    #[endpoint(
66        method = GET,
67        path = "/scout/v1/versioning/{resourceRid}/commit/{commitId}",
68        name = "getCommit",
69        produces = conjure_http::server::StdResponseSerializer
70    )]
71    fn get_commit(
72        &self,
73        #[auth]
74        auth_: conjure_object::BearerToken,
75        #[path(
76            name = "resourceRid",
77            decoder = conjure_http::server::conjure::FromPlainDecoder,
78            log_as = "resourceRid"
79        )]
80        resource_rid: conjure_object::ResourceIdentifier,
81        #[path(
82            name = "commitId",
83            decoder = conjure_http::server::conjure::FromPlainDecoder,
84            log_as = "commitId",
85            safe
86        )]
87        commit_id: super::super::super::objects::scout::versioning::api::CommitId,
88    ) -> Result<
89        super::super::super::objects::scout::versioning::api::Commit,
90        conjure_http::private::Error,
91    >;
92    /// Filters out resources that are not authorized.
93    #[endpoint(
94        method = POST,
95        path = "/scout/v1/versioning/commit/batch-get",
96        name = "batchGetCommits",
97        produces = conjure_http::server::conjure::CollectionResponseSerializer
98    )]
99    fn batch_get_commits(
100        &self,
101        #[auth]
102        auth_: conjure_object::BearerToken,
103        #[body(
104            deserializer = conjure_http::server::StdRequestDeserializer,
105            log_as = "resourceAndCommitIds"
106        )]
107        resource_and_commit_ids: std::collections::BTreeSet<
108            super::super::super::objects::scout::versioning::api::ResourceAndCommitId,
109        >,
110    ) -> Result<
111        std::collections::BTreeSet<
112            super::super::super::objects::scout::versioning::api::Commit,
113        >,
114        conjure_http::private::Error,
115    >;
116    /// Returns the commit pointed to by the branch.
117    /// Throws if the branch doesn't exist.
118    #[endpoint(
119        method = GET,
120        path = "/scout/v1/versioning/{resourceRid}/branch/{branchName}/commit",
121        name = "getCommitByBranch",
122        produces = conjure_http::server::StdResponseSerializer
123    )]
124    fn get_commit_by_branch(
125        &self,
126        #[auth]
127        auth_: conjure_object::BearerToken,
128        #[path(
129            name = "resourceRid",
130            decoder = conjure_http::server::conjure::FromPlainDecoder,
131            log_as = "resourceRid"
132        )]
133        resource_rid: conjure_object::ResourceIdentifier,
134        #[path(
135            name = "branchName",
136            decoder = conjure_http::server::conjure::FromPlainDecoder,
137            log_as = "branchName"
138        )]
139        branch_name: super::super::super::objects::scout::versioning::api::BranchName,
140    ) -> Result<
141        super::super::super::objects::scout::versioning::api::Commit,
142        conjure_http::private::Error,
143    >;
144    /// Returns the commit pointed to by the tag.
145    /// Throws if the tag doesn't exist.
146    #[endpoint(
147        method = GET,
148        path = "/scout/v1/versioning/{resourceRid}/tag/{tagName}/commit",
149        name = "getCommitByTag",
150        produces = conjure_http::server::StdResponseSerializer
151    )]
152    fn get_commit_by_tag(
153        &self,
154        #[auth]
155        auth_: conjure_object::BearerToken,
156        #[path(
157            name = "resourceRid",
158            decoder = conjure_http::server::conjure::FromPlainDecoder,
159            log_as = "resourceRid"
160        )]
161        resource_rid: conjure_object::ResourceIdentifier,
162        #[path(
163            name = "tagName",
164            decoder = conjure_http::server::conjure::FromPlainDecoder,
165            log_as = "tagName"
166        )]
167        tag_name: super::super::super::objects::scout::versioning::api::TagName,
168    ) -> Result<
169        super::super::super::objects::scout::versioning::api::Commit,
170        conjure_http::private::Error,
171    >;
172    /// Returns the least common ancestor of the two commits.
173    /// Throws if either commit doesn't exist.
174    #[endpoint(
175        method = POST,
176        path = "/scout/v1/versioning/{resourceRid}/commit/least-common-ancestor",
177        name = "getLeastCommonAncestor",
178        produces = conjure_http::server::StdResponseSerializer
179    )]
180    fn get_least_common_ancestor(
181        &self,
182        #[auth]
183        auth_: conjure_object::BearerToken,
184        #[path(
185            name = "resourceRid",
186            decoder = conjure_http::server::conjure::FromPlainDecoder,
187            log_as = "resourceRid"
188        )]
189        resource_rid: conjure_object::ResourceIdentifier,
190        #[body(deserializer = conjure_http::server::StdRequestDeserializer, safe)]
191        request: super::super::super::objects::scout::versioning::api::GetLeastCommonAncestorRequest,
192    ) -> Result<
193        super::super::super::objects::scout::versioning::api::CommitId,
194        conjure_http::private::Error,
195    >;
196    /// Returns the commit history sorted by creation time descending.
197    /// Excludes working state commits.
198    /// Throws if the commit doesn't exist.
199    #[endpoint(
200        method = GET,
201        path = "/scout/v1/versioning/{resourceRid}/commit/{commitId}/history",
202        name = "getCommitHistory",
203        produces = conjure_http::server::StdResponseSerializer
204    )]
205    fn get_commit_history(
206        &self,
207        #[auth]
208        auth_: conjure_object::BearerToken,
209        #[path(
210            name = "resourceRid",
211            decoder = conjure_http::server::conjure::FromPlainDecoder,
212            log_as = "resourceRid"
213        )]
214        resource_rid: conjure_object::ResourceIdentifier,
215        #[path(
216            name = "commitId",
217            decoder = conjure_http::server::conjure::FromPlainDecoder,
218            log_as = "commitId",
219            safe
220        )]
221        commit_id: super::super::super::objects::scout::versioning::api::CommitId,
222        #[query(
223            name = "pageSize",
224            decoder = conjure_http::server::conjure::FromPlainOptionDecoder,
225            log_as = "pageSize"
226        )]
227        page_size: Option<i32>,
228        #[query(
229            name = "nextPageToken",
230            decoder = conjure_http::server::conjure::FromPlainOptionDecoder,
231            log_as = "nextPageToken"
232        )]
233        next_page_token: Option<super::super::super::objects::api::Token>,
234    ) -> Result<
235        super::super::super::objects::scout::versioning::api::CommitHistory,
236        conjure_http::private::Error,
237    >;
238    /// Persists the commits so that they are not compacted.
239    /// This operation is atomic - either all commits are persisted
240    /// or none are (in the case of an error).
241    #[endpoint(
242        method = POST,
243        path = "/scout/v1/versioning/commit/persist",
244        name = "persistCommits"
245    )]
246    fn persist_commits(
247        &self,
248        #[auth]
249        auth_: conjure_object::BearerToken,
250        #[body(deserializer = conjure_http::server::StdRequestDeserializer)]
251        request: std::collections::BTreeSet<
252            super::super::super::objects::scout::versioning::api::ResourceAndCommitId,
253        >,
254    ) -> Result<(), conjure_http::private::Error>;
255    /// Throws if the branch doesn't exist.
256    #[endpoint(
257        method = GET,
258        path = "/scout/v1/versioning/{resourceRid}/branch/{branchName}",
259        name = "getBranch",
260        produces = conjure_http::server::StdResponseSerializer
261    )]
262    fn get_branch(
263        &self,
264        #[auth]
265        auth_: conjure_object::BearerToken,
266        #[path(
267            name = "resourceRid",
268            decoder = conjure_http::server::conjure::FromPlainDecoder,
269            log_as = "resourceRid"
270        )]
271        resource_rid: conjure_object::ResourceIdentifier,
272        #[path(
273            name = "branchName",
274            decoder = conjure_http::server::conjure::FromPlainDecoder,
275            log_as = "branchName"
276        )]
277        branch_name: super::super::super::objects::scout::versioning::api::BranchName,
278    ) -> Result<
279        super::super::super::objects::scout::versioning::api::Branch,
280        conjure_http::private::Error,
281    >;
282    /// Returns all branches for the resource in order of
283    /// most recently updated.
284    #[endpoint(
285        method = GET,
286        path = "/scout/v1/versioning/{resourceRid}/branch",
287        name = "getBranches",
288        produces = conjure_http::server::conjure::CollectionResponseSerializer
289    )]
290    fn get_branches(
291        &self,
292        #[auth]
293        auth_: conjure_object::BearerToken,
294        #[path(
295            name = "resourceRid",
296            decoder = conjure_http::server::conjure::FromPlainDecoder,
297            log_as = "resourceRid"
298        )]
299        resource_rid: conjure_object::ResourceIdentifier,
300    ) -> Result<
301        Vec<super::super::super::objects::scout::versioning::api::Branch>,
302        conjure_http::private::Error,
303    >;
304    /// Omits branches that are not authorized.
305    #[endpoint(
306        method = POST,
307        path = "/scout/v1/versioning/branch/batch-get",
308        name = "batchGetBranches",
309        produces = conjure_http::server::conjure::CollectionResponseSerializer
310    )]
311    fn batch_get_branches(
312        &self,
313        #[auth]
314        auth_: conjure_object::BearerToken,
315        #[body(
316            deserializer = conjure_http::server::StdRequestDeserializer,
317            log_as = "resourceAndBranches"
318        )]
319        resource_and_branches: std::collections::BTreeSet<
320            super::super::super::objects::scout::versioning::api::ResourceAndBranchName,
321        >,
322    ) -> Result<
323        std::collections::BTreeSet<
324            super::super::super::objects::scout::versioning::api::Branch,
325        >,
326        conjure_http::private::Error,
327    >;
328    /// Throws if the tag doesn't exist.
329    #[endpoint(
330        method = GET,
331        path = "/scout/v1/versioning/{resourceRid}/tag/{tagName}",
332        name = "getTag",
333        produces = conjure_http::server::StdResponseSerializer
334    )]
335    fn get_tag(
336        &self,
337        #[auth]
338        auth_: conjure_object::BearerToken,
339        #[path(
340            name = "resourceRid",
341            decoder = conjure_http::server::conjure::FromPlainDecoder,
342            log_as = "resourceRid"
343        )]
344        resource_rid: conjure_object::ResourceIdentifier,
345        #[path(
346            name = "tagName",
347            decoder = conjure_http::server::conjure::FromPlainDecoder,
348            log_as = "tagName"
349        )]
350        tag_name: super::super::super::objects::scout::versioning::api::TagName,
351    ) -> Result<
352        super::super::super::objects::scout::versioning::api::Tag,
353        conjure_http::private::Error,
354    >;
355    /// Omits tags that are not authorized.
356    #[endpoint(
357        method = POST,
358        path = "/scout/v1/versioning/tag/batch-get",
359        name = "batchGetTags",
360        produces = conjure_http::server::conjure::CollectionResponseSerializer
361    )]
362    fn batch_get_tags(
363        &self,
364        #[auth]
365        auth_: conjure_object::BearerToken,
366        #[body(
367            deserializer = conjure_http::server::StdRequestDeserializer,
368            log_as = "resourceAndCommits"
369        )]
370        resource_and_commits: std::collections::BTreeSet<
371            super::super::super::objects::scout::versioning::api::ResourceAndCommitId,
372        >,
373    ) -> Result<
374        std::collections::BTreeSet<
375            super::super::super::objects::scout::versioning::api::Tag,
376        >,
377        conjure_http::private::Error,
378    >;
379    /// Returns all tags for the resource in order of
380    /// most recently created.
381    #[endpoint(
382        method = GET,
383        path = "/scout/v1/versioning/{resourceRid}/tag",
384        name = "getTagsByResource",
385        produces = conjure_http::server::conjure::CollectionResponseSerializer
386    )]
387    fn get_tags_by_resource(
388        &self,
389        #[auth]
390        auth_: conjure_object::BearerToken,
391        #[path(
392            name = "resourceRid",
393            decoder = conjure_http::server::conjure::FromPlainDecoder,
394            log_as = "resourceRid"
395        )]
396        resource_rid: conjure_object::ResourceIdentifier,
397    ) -> Result<
398        Vec<super::super::super::objects::scout::versioning::api::Tag>,
399        conjure_http::private::Error,
400    >;
401    /// Deletes the branch pointer.
402    /// Throws if the branch doesn't exist.
403    /// Throws if you attempt to delete the "main" branch.
404    #[endpoint(
405        method = DELETE,
406        path = "/scout/v1/versioning/{resourceRid}/branch/{branchName}",
407        name = "deleteBranch"
408    )]
409    fn delete_branch(
410        &self,
411        #[auth]
412        auth_: conjure_object::BearerToken,
413        #[path(
414            name = "resourceRid",
415            decoder = conjure_http::server::conjure::FromPlainDecoder,
416            log_as = "resourceRid"
417        )]
418        resource_rid: conjure_object::ResourceIdentifier,
419        #[path(
420            name = "branchName",
421            decoder = conjure_http::server::conjure::FromPlainDecoder,
422            log_as = "branchName"
423        )]
424        branch_name: super::super::super::objects::scout::versioning::api::BranchName,
425    ) -> Result<(), conjure_http::private::Error>;
426    /// Deletes the branch pointers.
427    /// Throws if any resource or branch is non-existent
428    /// or unauthorized.
429    /// Throws if any attempt is made to delete "main".
430    #[endpoint(
431        method = POST,
432        path = "/scout/v1/versioning/branch/batch-delete",
433        name = "deleteBranches"
434    )]
435    fn delete_branches(
436        &self,
437        #[auth]
438        auth_: conjure_object::BearerToken,
439        #[body(
440            deserializer = conjure_http::server::StdRequestDeserializer,
441            log_as = "resourceAndBranches"
442        )]
443        resource_and_branches: std::collections::BTreeSet<
444            super::super::super::objects::scout::versioning::api::ResourceAndBranchName,
445        >,
446    ) -> Result<(), conjure_http::private::Error>;
447    /// Deletes the tag pointer.
448    /// Throws if the tag doesn't exist.
449    #[endpoint(
450        method = DELETE,
451        path = "/scout/v1/versioning/{resourceRid}/tag/{tagName}",
452        name = "deleteTag"
453    )]
454    fn delete_tag(
455        &self,
456        #[auth]
457        auth_: conjure_object::BearerToken,
458        #[path(
459            name = "resourceRid",
460            decoder = conjure_http::server::conjure::FromPlainDecoder,
461            log_as = "resourceRid"
462        )]
463        resource_rid: conjure_object::ResourceIdentifier,
464        #[path(
465            name = "tagName",
466            decoder = conjure_http::server::conjure::FromPlainDecoder,
467            log_as = "tagName"
468        )]
469        tag_name: super::super::super::objects::scout::versioning::api::TagName,
470    ) -> Result<(), conjure_http::private::Error>;
471}
472/// This is the external-facing portion of VersioningService which
473/// gives clients access to functionality that doesn't create new
474/// commits. The creation of new commits should be done via the
475/// resource-specific services.
476#[conjure_http::conjure_endpoints(
477    name = "VersioningService",
478    use_legacy_error_serialization
479)]
480pub trait AsyncVersioningService {
481    /// Creates a mutable pointer to the provided commit.
482    /// "Saves"/"commits" can be performed on this pointer.
483    /// Throws if the name is already used as a commit
484    /// pointer for this resource.
485    /// Throws if the provided commit doesn't exist.
486    #[endpoint(
487        method = POST,
488        path = "/scout/v1/versioning/{resourceRid}/branch",
489        name = "createBranch",
490        produces = conjure_http::server::StdResponseSerializer
491    )]
492    async fn create_branch(
493        &self,
494        #[auth]
495        auth_: conjure_object::BearerToken,
496        #[path(
497            name = "resourceRid",
498            decoder = conjure_http::server::conjure::FromPlainDecoder,
499            log_as = "resourceRid"
500        )]
501        resource_rid: conjure_object::ResourceIdentifier,
502        #[body(deserializer = conjure_http::server::StdRequestDeserializer)]
503        request: super::super::super::objects::scout::versioning::api::CreateBranchRequest,
504    ) -> Result<
505        super::super::super::objects::scout::versioning::api::Branch,
506        conjure_http::private::Error,
507    >;
508    /// Creates an immutable pointer to the provided commit.
509    /// Throws if the name is already used as a commit
510    /// pointer for this resource.
511    /// Throws if the provided commit doesn't exist.
512    #[endpoint(
513        method = POST,
514        path = "/scout/v1/versioning/{resourceRid}/tag",
515        name = "createTag",
516        produces = conjure_http::server::StdResponseSerializer
517    )]
518    async fn create_tag(
519        &self,
520        #[auth]
521        auth_: conjure_object::BearerToken,
522        #[path(
523            name = "resourceRid",
524            decoder = conjure_http::server::conjure::FromPlainDecoder,
525            log_as = "resourceRid"
526        )]
527        resource_rid: conjure_object::ResourceIdentifier,
528        #[body(deserializer = conjure_http::server::StdRequestDeserializer)]
529        request: super::super::super::objects::scout::versioning::api::CreateTagRequest,
530    ) -> Result<
531        super::super::super::objects::scout::versioning::api::Tag,
532        conjure_http::private::Error,
533    >;
534    /// Throws if the commit doesn't exist.
535    #[endpoint(
536        method = GET,
537        path = "/scout/v1/versioning/{resourceRid}/commit/{commitId}",
538        name = "getCommit",
539        produces = conjure_http::server::StdResponseSerializer
540    )]
541    async fn get_commit(
542        &self,
543        #[auth]
544        auth_: conjure_object::BearerToken,
545        #[path(
546            name = "resourceRid",
547            decoder = conjure_http::server::conjure::FromPlainDecoder,
548            log_as = "resourceRid"
549        )]
550        resource_rid: conjure_object::ResourceIdentifier,
551        #[path(
552            name = "commitId",
553            decoder = conjure_http::server::conjure::FromPlainDecoder,
554            log_as = "commitId",
555            safe
556        )]
557        commit_id: super::super::super::objects::scout::versioning::api::CommitId,
558    ) -> Result<
559        super::super::super::objects::scout::versioning::api::Commit,
560        conjure_http::private::Error,
561    >;
562    /// Filters out resources that are not authorized.
563    #[endpoint(
564        method = POST,
565        path = "/scout/v1/versioning/commit/batch-get",
566        name = "batchGetCommits",
567        produces = conjure_http::server::conjure::CollectionResponseSerializer
568    )]
569    async fn batch_get_commits(
570        &self,
571        #[auth]
572        auth_: conjure_object::BearerToken,
573        #[body(
574            deserializer = conjure_http::server::StdRequestDeserializer,
575            log_as = "resourceAndCommitIds"
576        )]
577        resource_and_commit_ids: std::collections::BTreeSet<
578            super::super::super::objects::scout::versioning::api::ResourceAndCommitId,
579        >,
580    ) -> Result<
581        std::collections::BTreeSet<
582            super::super::super::objects::scout::versioning::api::Commit,
583        >,
584        conjure_http::private::Error,
585    >;
586    /// Returns the commit pointed to by the branch.
587    /// Throws if the branch doesn't exist.
588    #[endpoint(
589        method = GET,
590        path = "/scout/v1/versioning/{resourceRid}/branch/{branchName}/commit",
591        name = "getCommitByBranch",
592        produces = conjure_http::server::StdResponseSerializer
593    )]
594    async fn get_commit_by_branch(
595        &self,
596        #[auth]
597        auth_: conjure_object::BearerToken,
598        #[path(
599            name = "resourceRid",
600            decoder = conjure_http::server::conjure::FromPlainDecoder,
601            log_as = "resourceRid"
602        )]
603        resource_rid: conjure_object::ResourceIdentifier,
604        #[path(
605            name = "branchName",
606            decoder = conjure_http::server::conjure::FromPlainDecoder,
607            log_as = "branchName"
608        )]
609        branch_name: super::super::super::objects::scout::versioning::api::BranchName,
610    ) -> Result<
611        super::super::super::objects::scout::versioning::api::Commit,
612        conjure_http::private::Error,
613    >;
614    /// Returns the commit pointed to by the tag.
615    /// Throws if the tag doesn't exist.
616    #[endpoint(
617        method = GET,
618        path = "/scout/v1/versioning/{resourceRid}/tag/{tagName}/commit",
619        name = "getCommitByTag",
620        produces = conjure_http::server::StdResponseSerializer
621    )]
622    async fn get_commit_by_tag(
623        &self,
624        #[auth]
625        auth_: conjure_object::BearerToken,
626        #[path(
627            name = "resourceRid",
628            decoder = conjure_http::server::conjure::FromPlainDecoder,
629            log_as = "resourceRid"
630        )]
631        resource_rid: conjure_object::ResourceIdentifier,
632        #[path(
633            name = "tagName",
634            decoder = conjure_http::server::conjure::FromPlainDecoder,
635            log_as = "tagName"
636        )]
637        tag_name: super::super::super::objects::scout::versioning::api::TagName,
638    ) -> Result<
639        super::super::super::objects::scout::versioning::api::Commit,
640        conjure_http::private::Error,
641    >;
642    /// Returns the least common ancestor of the two commits.
643    /// Throws if either commit doesn't exist.
644    #[endpoint(
645        method = POST,
646        path = "/scout/v1/versioning/{resourceRid}/commit/least-common-ancestor",
647        name = "getLeastCommonAncestor",
648        produces = conjure_http::server::StdResponseSerializer
649    )]
650    async fn get_least_common_ancestor(
651        &self,
652        #[auth]
653        auth_: conjure_object::BearerToken,
654        #[path(
655            name = "resourceRid",
656            decoder = conjure_http::server::conjure::FromPlainDecoder,
657            log_as = "resourceRid"
658        )]
659        resource_rid: conjure_object::ResourceIdentifier,
660        #[body(deserializer = conjure_http::server::StdRequestDeserializer, safe)]
661        request: super::super::super::objects::scout::versioning::api::GetLeastCommonAncestorRequest,
662    ) -> Result<
663        super::super::super::objects::scout::versioning::api::CommitId,
664        conjure_http::private::Error,
665    >;
666    /// Returns the commit history sorted by creation time descending.
667    /// Excludes working state commits.
668    /// Throws if the commit doesn't exist.
669    #[endpoint(
670        method = GET,
671        path = "/scout/v1/versioning/{resourceRid}/commit/{commitId}/history",
672        name = "getCommitHistory",
673        produces = conjure_http::server::StdResponseSerializer
674    )]
675    async fn get_commit_history(
676        &self,
677        #[auth]
678        auth_: conjure_object::BearerToken,
679        #[path(
680            name = "resourceRid",
681            decoder = conjure_http::server::conjure::FromPlainDecoder,
682            log_as = "resourceRid"
683        )]
684        resource_rid: conjure_object::ResourceIdentifier,
685        #[path(
686            name = "commitId",
687            decoder = conjure_http::server::conjure::FromPlainDecoder,
688            log_as = "commitId",
689            safe
690        )]
691        commit_id: super::super::super::objects::scout::versioning::api::CommitId,
692        #[query(
693            name = "pageSize",
694            decoder = conjure_http::server::conjure::FromPlainOptionDecoder,
695            log_as = "pageSize"
696        )]
697        page_size: Option<i32>,
698        #[query(
699            name = "nextPageToken",
700            decoder = conjure_http::server::conjure::FromPlainOptionDecoder,
701            log_as = "nextPageToken"
702        )]
703        next_page_token: Option<super::super::super::objects::api::Token>,
704    ) -> Result<
705        super::super::super::objects::scout::versioning::api::CommitHistory,
706        conjure_http::private::Error,
707    >;
708    /// Persists the commits so that they are not compacted.
709    /// This operation is atomic - either all commits are persisted
710    /// or none are (in the case of an error).
711    #[endpoint(
712        method = POST,
713        path = "/scout/v1/versioning/commit/persist",
714        name = "persistCommits"
715    )]
716    async fn persist_commits(
717        &self,
718        #[auth]
719        auth_: conjure_object::BearerToken,
720        #[body(deserializer = conjure_http::server::StdRequestDeserializer)]
721        request: std::collections::BTreeSet<
722            super::super::super::objects::scout::versioning::api::ResourceAndCommitId,
723        >,
724    ) -> Result<(), conjure_http::private::Error>;
725    /// Throws if the branch doesn't exist.
726    #[endpoint(
727        method = GET,
728        path = "/scout/v1/versioning/{resourceRid}/branch/{branchName}",
729        name = "getBranch",
730        produces = conjure_http::server::StdResponseSerializer
731    )]
732    async fn get_branch(
733        &self,
734        #[auth]
735        auth_: conjure_object::BearerToken,
736        #[path(
737            name = "resourceRid",
738            decoder = conjure_http::server::conjure::FromPlainDecoder,
739            log_as = "resourceRid"
740        )]
741        resource_rid: conjure_object::ResourceIdentifier,
742        #[path(
743            name = "branchName",
744            decoder = conjure_http::server::conjure::FromPlainDecoder,
745            log_as = "branchName"
746        )]
747        branch_name: super::super::super::objects::scout::versioning::api::BranchName,
748    ) -> Result<
749        super::super::super::objects::scout::versioning::api::Branch,
750        conjure_http::private::Error,
751    >;
752    /// Returns all branches for the resource in order of
753    /// most recently updated.
754    #[endpoint(
755        method = GET,
756        path = "/scout/v1/versioning/{resourceRid}/branch",
757        name = "getBranches",
758        produces = conjure_http::server::conjure::CollectionResponseSerializer
759    )]
760    async fn get_branches(
761        &self,
762        #[auth]
763        auth_: conjure_object::BearerToken,
764        #[path(
765            name = "resourceRid",
766            decoder = conjure_http::server::conjure::FromPlainDecoder,
767            log_as = "resourceRid"
768        )]
769        resource_rid: conjure_object::ResourceIdentifier,
770    ) -> Result<
771        Vec<super::super::super::objects::scout::versioning::api::Branch>,
772        conjure_http::private::Error,
773    >;
774    /// Omits branches that are not authorized.
775    #[endpoint(
776        method = POST,
777        path = "/scout/v1/versioning/branch/batch-get",
778        name = "batchGetBranches",
779        produces = conjure_http::server::conjure::CollectionResponseSerializer
780    )]
781    async fn batch_get_branches(
782        &self,
783        #[auth]
784        auth_: conjure_object::BearerToken,
785        #[body(
786            deserializer = conjure_http::server::StdRequestDeserializer,
787            log_as = "resourceAndBranches"
788        )]
789        resource_and_branches: std::collections::BTreeSet<
790            super::super::super::objects::scout::versioning::api::ResourceAndBranchName,
791        >,
792    ) -> Result<
793        std::collections::BTreeSet<
794            super::super::super::objects::scout::versioning::api::Branch,
795        >,
796        conjure_http::private::Error,
797    >;
798    /// Throws if the tag doesn't exist.
799    #[endpoint(
800        method = GET,
801        path = "/scout/v1/versioning/{resourceRid}/tag/{tagName}",
802        name = "getTag",
803        produces = conjure_http::server::StdResponseSerializer
804    )]
805    async fn get_tag(
806        &self,
807        #[auth]
808        auth_: conjure_object::BearerToken,
809        #[path(
810            name = "resourceRid",
811            decoder = conjure_http::server::conjure::FromPlainDecoder,
812            log_as = "resourceRid"
813        )]
814        resource_rid: conjure_object::ResourceIdentifier,
815        #[path(
816            name = "tagName",
817            decoder = conjure_http::server::conjure::FromPlainDecoder,
818            log_as = "tagName"
819        )]
820        tag_name: super::super::super::objects::scout::versioning::api::TagName,
821    ) -> Result<
822        super::super::super::objects::scout::versioning::api::Tag,
823        conjure_http::private::Error,
824    >;
825    /// Omits tags that are not authorized.
826    #[endpoint(
827        method = POST,
828        path = "/scout/v1/versioning/tag/batch-get",
829        name = "batchGetTags",
830        produces = conjure_http::server::conjure::CollectionResponseSerializer
831    )]
832    async fn batch_get_tags(
833        &self,
834        #[auth]
835        auth_: conjure_object::BearerToken,
836        #[body(
837            deserializer = conjure_http::server::StdRequestDeserializer,
838            log_as = "resourceAndCommits"
839        )]
840        resource_and_commits: std::collections::BTreeSet<
841            super::super::super::objects::scout::versioning::api::ResourceAndCommitId,
842        >,
843    ) -> Result<
844        std::collections::BTreeSet<
845            super::super::super::objects::scout::versioning::api::Tag,
846        >,
847        conjure_http::private::Error,
848    >;
849    /// Returns all tags for the resource in order of
850    /// most recently created.
851    #[endpoint(
852        method = GET,
853        path = "/scout/v1/versioning/{resourceRid}/tag",
854        name = "getTagsByResource",
855        produces = conjure_http::server::conjure::CollectionResponseSerializer
856    )]
857    async fn get_tags_by_resource(
858        &self,
859        #[auth]
860        auth_: conjure_object::BearerToken,
861        #[path(
862            name = "resourceRid",
863            decoder = conjure_http::server::conjure::FromPlainDecoder,
864            log_as = "resourceRid"
865        )]
866        resource_rid: conjure_object::ResourceIdentifier,
867    ) -> Result<
868        Vec<super::super::super::objects::scout::versioning::api::Tag>,
869        conjure_http::private::Error,
870    >;
871    /// Deletes the branch pointer.
872    /// Throws if the branch doesn't exist.
873    /// Throws if you attempt to delete the "main" branch.
874    #[endpoint(
875        method = DELETE,
876        path = "/scout/v1/versioning/{resourceRid}/branch/{branchName}",
877        name = "deleteBranch"
878    )]
879    async fn delete_branch(
880        &self,
881        #[auth]
882        auth_: conjure_object::BearerToken,
883        #[path(
884            name = "resourceRid",
885            decoder = conjure_http::server::conjure::FromPlainDecoder,
886            log_as = "resourceRid"
887        )]
888        resource_rid: conjure_object::ResourceIdentifier,
889        #[path(
890            name = "branchName",
891            decoder = conjure_http::server::conjure::FromPlainDecoder,
892            log_as = "branchName"
893        )]
894        branch_name: super::super::super::objects::scout::versioning::api::BranchName,
895    ) -> Result<(), conjure_http::private::Error>;
896    /// Deletes the branch pointers.
897    /// Throws if any resource or branch is non-existent
898    /// or unauthorized.
899    /// Throws if any attempt is made to delete "main".
900    #[endpoint(
901        method = POST,
902        path = "/scout/v1/versioning/branch/batch-delete",
903        name = "deleteBranches"
904    )]
905    async fn delete_branches(
906        &self,
907        #[auth]
908        auth_: conjure_object::BearerToken,
909        #[body(
910            deserializer = conjure_http::server::StdRequestDeserializer,
911            log_as = "resourceAndBranches"
912        )]
913        resource_and_branches: std::collections::BTreeSet<
914            super::super::super::objects::scout::versioning::api::ResourceAndBranchName,
915        >,
916    ) -> Result<(), conjure_http::private::Error>;
917    /// Deletes the tag pointer.
918    /// Throws if the tag doesn't exist.
919    #[endpoint(
920        method = DELETE,
921        path = "/scout/v1/versioning/{resourceRid}/tag/{tagName}",
922        name = "deleteTag"
923    )]
924    async fn delete_tag(
925        &self,
926        #[auth]
927        auth_: conjure_object::BearerToken,
928        #[path(
929            name = "resourceRid",
930            decoder = conjure_http::server::conjure::FromPlainDecoder,
931            log_as = "resourceRid"
932        )]
933        resource_rid: conjure_object::ResourceIdentifier,
934        #[path(
935            name = "tagName",
936            decoder = conjure_http::server::conjure::FromPlainDecoder,
937            log_as = "tagName"
938        )]
939        tag_name: super::super::super::objects::scout::versioning::api::TagName,
940    ) -> Result<(), conjure_http::private::Error>;
941}
942/// This is the external-facing portion of VersioningService which
943/// gives clients access to functionality that doesn't create new
944/// commits. The creation of new commits should be done via the
945/// resource-specific services.
946#[conjure_http::conjure_endpoints(
947    name = "VersioningService",
948    use_legacy_error_serialization,
949    local
950)]
951pub trait LocalAsyncVersioningService {
952    /// Creates a mutable pointer to the provided commit.
953    /// "Saves"/"commits" can be performed on this pointer.
954    /// Throws if the name is already used as a commit
955    /// pointer for this resource.
956    /// Throws if the provided commit doesn't exist.
957    #[endpoint(
958        method = POST,
959        path = "/scout/v1/versioning/{resourceRid}/branch",
960        name = "createBranch",
961        produces = conjure_http::server::StdResponseSerializer
962    )]
963    async fn create_branch(
964        &self,
965        #[auth]
966        auth_: conjure_object::BearerToken,
967        #[path(
968            name = "resourceRid",
969            decoder = conjure_http::server::conjure::FromPlainDecoder,
970            log_as = "resourceRid"
971        )]
972        resource_rid: conjure_object::ResourceIdentifier,
973        #[body(deserializer = conjure_http::server::StdRequestDeserializer)]
974        request: super::super::super::objects::scout::versioning::api::CreateBranchRequest,
975    ) -> Result<
976        super::super::super::objects::scout::versioning::api::Branch,
977        conjure_http::private::Error,
978    >;
979    /// Creates an immutable pointer to the provided commit.
980    /// Throws if the name is already used as a commit
981    /// pointer for this resource.
982    /// Throws if the provided commit doesn't exist.
983    #[endpoint(
984        method = POST,
985        path = "/scout/v1/versioning/{resourceRid}/tag",
986        name = "createTag",
987        produces = conjure_http::server::StdResponseSerializer
988    )]
989    async fn create_tag(
990        &self,
991        #[auth]
992        auth_: conjure_object::BearerToken,
993        #[path(
994            name = "resourceRid",
995            decoder = conjure_http::server::conjure::FromPlainDecoder,
996            log_as = "resourceRid"
997        )]
998        resource_rid: conjure_object::ResourceIdentifier,
999        #[body(deserializer = conjure_http::server::StdRequestDeserializer)]
1000        request: super::super::super::objects::scout::versioning::api::CreateTagRequest,
1001    ) -> Result<
1002        super::super::super::objects::scout::versioning::api::Tag,
1003        conjure_http::private::Error,
1004    >;
1005    /// Throws if the commit doesn't exist.
1006    #[endpoint(
1007        method = GET,
1008        path = "/scout/v1/versioning/{resourceRid}/commit/{commitId}",
1009        name = "getCommit",
1010        produces = conjure_http::server::StdResponseSerializer
1011    )]
1012    async fn get_commit(
1013        &self,
1014        #[auth]
1015        auth_: conjure_object::BearerToken,
1016        #[path(
1017            name = "resourceRid",
1018            decoder = conjure_http::server::conjure::FromPlainDecoder,
1019            log_as = "resourceRid"
1020        )]
1021        resource_rid: conjure_object::ResourceIdentifier,
1022        #[path(
1023            name = "commitId",
1024            decoder = conjure_http::server::conjure::FromPlainDecoder,
1025            log_as = "commitId",
1026            safe
1027        )]
1028        commit_id: super::super::super::objects::scout::versioning::api::CommitId,
1029    ) -> Result<
1030        super::super::super::objects::scout::versioning::api::Commit,
1031        conjure_http::private::Error,
1032    >;
1033    /// Filters out resources that are not authorized.
1034    #[endpoint(
1035        method = POST,
1036        path = "/scout/v1/versioning/commit/batch-get",
1037        name = "batchGetCommits",
1038        produces = conjure_http::server::conjure::CollectionResponseSerializer
1039    )]
1040    async fn batch_get_commits(
1041        &self,
1042        #[auth]
1043        auth_: conjure_object::BearerToken,
1044        #[body(
1045            deserializer = conjure_http::server::StdRequestDeserializer,
1046            log_as = "resourceAndCommitIds"
1047        )]
1048        resource_and_commit_ids: std::collections::BTreeSet<
1049            super::super::super::objects::scout::versioning::api::ResourceAndCommitId,
1050        >,
1051    ) -> Result<
1052        std::collections::BTreeSet<
1053            super::super::super::objects::scout::versioning::api::Commit,
1054        >,
1055        conjure_http::private::Error,
1056    >;
1057    /// Returns the commit pointed to by the branch.
1058    /// Throws if the branch doesn't exist.
1059    #[endpoint(
1060        method = GET,
1061        path = "/scout/v1/versioning/{resourceRid}/branch/{branchName}/commit",
1062        name = "getCommitByBranch",
1063        produces = conjure_http::server::StdResponseSerializer
1064    )]
1065    async fn get_commit_by_branch(
1066        &self,
1067        #[auth]
1068        auth_: conjure_object::BearerToken,
1069        #[path(
1070            name = "resourceRid",
1071            decoder = conjure_http::server::conjure::FromPlainDecoder,
1072            log_as = "resourceRid"
1073        )]
1074        resource_rid: conjure_object::ResourceIdentifier,
1075        #[path(
1076            name = "branchName",
1077            decoder = conjure_http::server::conjure::FromPlainDecoder,
1078            log_as = "branchName"
1079        )]
1080        branch_name: super::super::super::objects::scout::versioning::api::BranchName,
1081    ) -> Result<
1082        super::super::super::objects::scout::versioning::api::Commit,
1083        conjure_http::private::Error,
1084    >;
1085    /// Returns the commit pointed to by the tag.
1086    /// Throws if the tag doesn't exist.
1087    #[endpoint(
1088        method = GET,
1089        path = "/scout/v1/versioning/{resourceRid}/tag/{tagName}/commit",
1090        name = "getCommitByTag",
1091        produces = conjure_http::server::StdResponseSerializer
1092    )]
1093    async fn get_commit_by_tag(
1094        &self,
1095        #[auth]
1096        auth_: conjure_object::BearerToken,
1097        #[path(
1098            name = "resourceRid",
1099            decoder = conjure_http::server::conjure::FromPlainDecoder,
1100            log_as = "resourceRid"
1101        )]
1102        resource_rid: conjure_object::ResourceIdentifier,
1103        #[path(
1104            name = "tagName",
1105            decoder = conjure_http::server::conjure::FromPlainDecoder,
1106            log_as = "tagName"
1107        )]
1108        tag_name: super::super::super::objects::scout::versioning::api::TagName,
1109    ) -> Result<
1110        super::super::super::objects::scout::versioning::api::Commit,
1111        conjure_http::private::Error,
1112    >;
1113    /// Returns the least common ancestor of the two commits.
1114    /// Throws if either commit doesn't exist.
1115    #[endpoint(
1116        method = POST,
1117        path = "/scout/v1/versioning/{resourceRid}/commit/least-common-ancestor",
1118        name = "getLeastCommonAncestor",
1119        produces = conjure_http::server::StdResponseSerializer
1120    )]
1121    async fn get_least_common_ancestor(
1122        &self,
1123        #[auth]
1124        auth_: conjure_object::BearerToken,
1125        #[path(
1126            name = "resourceRid",
1127            decoder = conjure_http::server::conjure::FromPlainDecoder,
1128            log_as = "resourceRid"
1129        )]
1130        resource_rid: conjure_object::ResourceIdentifier,
1131        #[body(deserializer = conjure_http::server::StdRequestDeserializer, safe)]
1132        request: super::super::super::objects::scout::versioning::api::GetLeastCommonAncestorRequest,
1133    ) -> Result<
1134        super::super::super::objects::scout::versioning::api::CommitId,
1135        conjure_http::private::Error,
1136    >;
1137    /// Returns the commit history sorted by creation time descending.
1138    /// Excludes working state commits.
1139    /// Throws if the commit doesn't exist.
1140    #[endpoint(
1141        method = GET,
1142        path = "/scout/v1/versioning/{resourceRid}/commit/{commitId}/history",
1143        name = "getCommitHistory",
1144        produces = conjure_http::server::StdResponseSerializer
1145    )]
1146    async fn get_commit_history(
1147        &self,
1148        #[auth]
1149        auth_: conjure_object::BearerToken,
1150        #[path(
1151            name = "resourceRid",
1152            decoder = conjure_http::server::conjure::FromPlainDecoder,
1153            log_as = "resourceRid"
1154        )]
1155        resource_rid: conjure_object::ResourceIdentifier,
1156        #[path(
1157            name = "commitId",
1158            decoder = conjure_http::server::conjure::FromPlainDecoder,
1159            log_as = "commitId",
1160            safe
1161        )]
1162        commit_id: super::super::super::objects::scout::versioning::api::CommitId,
1163        #[query(
1164            name = "pageSize",
1165            decoder = conjure_http::server::conjure::FromPlainOptionDecoder,
1166            log_as = "pageSize"
1167        )]
1168        page_size: Option<i32>,
1169        #[query(
1170            name = "nextPageToken",
1171            decoder = conjure_http::server::conjure::FromPlainOptionDecoder,
1172            log_as = "nextPageToken"
1173        )]
1174        next_page_token: Option<super::super::super::objects::api::Token>,
1175    ) -> Result<
1176        super::super::super::objects::scout::versioning::api::CommitHistory,
1177        conjure_http::private::Error,
1178    >;
1179    /// Persists the commits so that they are not compacted.
1180    /// This operation is atomic - either all commits are persisted
1181    /// or none are (in the case of an error).
1182    #[endpoint(
1183        method = POST,
1184        path = "/scout/v1/versioning/commit/persist",
1185        name = "persistCommits"
1186    )]
1187    async fn persist_commits(
1188        &self,
1189        #[auth]
1190        auth_: conjure_object::BearerToken,
1191        #[body(deserializer = conjure_http::server::StdRequestDeserializer)]
1192        request: std::collections::BTreeSet<
1193            super::super::super::objects::scout::versioning::api::ResourceAndCommitId,
1194        >,
1195    ) -> Result<(), conjure_http::private::Error>;
1196    /// Throws if the branch doesn't exist.
1197    #[endpoint(
1198        method = GET,
1199        path = "/scout/v1/versioning/{resourceRid}/branch/{branchName}",
1200        name = "getBranch",
1201        produces = conjure_http::server::StdResponseSerializer
1202    )]
1203    async fn get_branch(
1204        &self,
1205        #[auth]
1206        auth_: conjure_object::BearerToken,
1207        #[path(
1208            name = "resourceRid",
1209            decoder = conjure_http::server::conjure::FromPlainDecoder,
1210            log_as = "resourceRid"
1211        )]
1212        resource_rid: conjure_object::ResourceIdentifier,
1213        #[path(
1214            name = "branchName",
1215            decoder = conjure_http::server::conjure::FromPlainDecoder,
1216            log_as = "branchName"
1217        )]
1218        branch_name: super::super::super::objects::scout::versioning::api::BranchName,
1219    ) -> Result<
1220        super::super::super::objects::scout::versioning::api::Branch,
1221        conjure_http::private::Error,
1222    >;
1223    /// Returns all branches for the resource in order of
1224    /// most recently updated.
1225    #[endpoint(
1226        method = GET,
1227        path = "/scout/v1/versioning/{resourceRid}/branch",
1228        name = "getBranches",
1229        produces = conjure_http::server::conjure::CollectionResponseSerializer
1230    )]
1231    async fn get_branches(
1232        &self,
1233        #[auth]
1234        auth_: conjure_object::BearerToken,
1235        #[path(
1236            name = "resourceRid",
1237            decoder = conjure_http::server::conjure::FromPlainDecoder,
1238            log_as = "resourceRid"
1239        )]
1240        resource_rid: conjure_object::ResourceIdentifier,
1241    ) -> Result<
1242        Vec<super::super::super::objects::scout::versioning::api::Branch>,
1243        conjure_http::private::Error,
1244    >;
1245    /// Omits branches that are not authorized.
1246    #[endpoint(
1247        method = POST,
1248        path = "/scout/v1/versioning/branch/batch-get",
1249        name = "batchGetBranches",
1250        produces = conjure_http::server::conjure::CollectionResponseSerializer
1251    )]
1252    async fn batch_get_branches(
1253        &self,
1254        #[auth]
1255        auth_: conjure_object::BearerToken,
1256        #[body(
1257            deserializer = conjure_http::server::StdRequestDeserializer,
1258            log_as = "resourceAndBranches"
1259        )]
1260        resource_and_branches: std::collections::BTreeSet<
1261            super::super::super::objects::scout::versioning::api::ResourceAndBranchName,
1262        >,
1263    ) -> Result<
1264        std::collections::BTreeSet<
1265            super::super::super::objects::scout::versioning::api::Branch,
1266        >,
1267        conjure_http::private::Error,
1268    >;
1269    /// Throws if the tag doesn't exist.
1270    #[endpoint(
1271        method = GET,
1272        path = "/scout/v1/versioning/{resourceRid}/tag/{tagName}",
1273        name = "getTag",
1274        produces = conjure_http::server::StdResponseSerializer
1275    )]
1276    async fn get_tag(
1277        &self,
1278        #[auth]
1279        auth_: conjure_object::BearerToken,
1280        #[path(
1281            name = "resourceRid",
1282            decoder = conjure_http::server::conjure::FromPlainDecoder,
1283            log_as = "resourceRid"
1284        )]
1285        resource_rid: conjure_object::ResourceIdentifier,
1286        #[path(
1287            name = "tagName",
1288            decoder = conjure_http::server::conjure::FromPlainDecoder,
1289            log_as = "tagName"
1290        )]
1291        tag_name: super::super::super::objects::scout::versioning::api::TagName,
1292    ) -> Result<
1293        super::super::super::objects::scout::versioning::api::Tag,
1294        conjure_http::private::Error,
1295    >;
1296    /// Omits tags that are not authorized.
1297    #[endpoint(
1298        method = POST,
1299        path = "/scout/v1/versioning/tag/batch-get",
1300        name = "batchGetTags",
1301        produces = conjure_http::server::conjure::CollectionResponseSerializer
1302    )]
1303    async fn batch_get_tags(
1304        &self,
1305        #[auth]
1306        auth_: conjure_object::BearerToken,
1307        #[body(
1308            deserializer = conjure_http::server::StdRequestDeserializer,
1309            log_as = "resourceAndCommits"
1310        )]
1311        resource_and_commits: std::collections::BTreeSet<
1312            super::super::super::objects::scout::versioning::api::ResourceAndCommitId,
1313        >,
1314    ) -> Result<
1315        std::collections::BTreeSet<
1316            super::super::super::objects::scout::versioning::api::Tag,
1317        >,
1318        conjure_http::private::Error,
1319    >;
1320    /// Returns all tags for the resource in order of
1321    /// most recently created.
1322    #[endpoint(
1323        method = GET,
1324        path = "/scout/v1/versioning/{resourceRid}/tag",
1325        name = "getTagsByResource",
1326        produces = conjure_http::server::conjure::CollectionResponseSerializer
1327    )]
1328    async fn get_tags_by_resource(
1329        &self,
1330        #[auth]
1331        auth_: conjure_object::BearerToken,
1332        #[path(
1333            name = "resourceRid",
1334            decoder = conjure_http::server::conjure::FromPlainDecoder,
1335            log_as = "resourceRid"
1336        )]
1337        resource_rid: conjure_object::ResourceIdentifier,
1338    ) -> Result<
1339        Vec<super::super::super::objects::scout::versioning::api::Tag>,
1340        conjure_http::private::Error,
1341    >;
1342    /// Deletes the branch pointer.
1343    /// Throws if the branch doesn't exist.
1344    /// Throws if you attempt to delete the "main" branch.
1345    #[endpoint(
1346        method = DELETE,
1347        path = "/scout/v1/versioning/{resourceRid}/branch/{branchName}",
1348        name = "deleteBranch"
1349    )]
1350    async fn delete_branch(
1351        &self,
1352        #[auth]
1353        auth_: conjure_object::BearerToken,
1354        #[path(
1355            name = "resourceRid",
1356            decoder = conjure_http::server::conjure::FromPlainDecoder,
1357            log_as = "resourceRid"
1358        )]
1359        resource_rid: conjure_object::ResourceIdentifier,
1360        #[path(
1361            name = "branchName",
1362            decoder = conjure_http::server::conjure::FromPlainDecoder,
1363            log_as = "branchName"
1364        )]
1365        branch_name: super::super::super::objects::scout::versioning::api::BranchName,
1366    ) -> Result<(), conjure_http::private::Error>;
1367    /// Deletes the branch pointers.
1368    /// Throws if any resource or branch is non-existent
1369    /// or unauthorized.
1370    /// Throws if any attempt is made to delete "main".
1371    #[endpoint(
1372        method = POST,
1373        path = "/scout/v1/versioning/branch/batch-delete",
1374        name = "deleteBranches"
1375    )]
1376    async fn delete_branches(
1377        &self,
1378        #[auth]
1379        auth_: conjure_object::BearerToken,
1380        #[body(
1381            deserializer = conjure_http::server::StdRequestDeserializer,
1382            log_as = "resourceAndBranches"
1383        )]
1384        resource_and_branches: std::collections::BTreeSet<
1385            super::super::super::objects::scout::versioning::api::ResourceAndBranchName,
1386        >,
1387    ) -> Result<(), conjure_http::private::Error>;
1388    /// Deletes the tag pointer.
1389    /// Throws if the tag doesn't exist.
1390    #[endpoint(
1391        method = DELETE,
1392        path = "/scout/v1/versioning/{resourceRid}/tag/{tagName}",
1393        name = "deleteTag"
1394    )]
1395    async fn delete_tag(
1396        &self,
1397        #[auth]
1398        auth_: conjure_object::BearerToken,
1399        #[path(
1400            name = "resourceRid",
1401            decoder = conjure_http::server::conjure::FromPlainDecoder,
1402            log_as = "resourceRid"
1403        )]
1404        resource_rid: conjure_object::ResourceIdentifier,
1405        #[path(
1406            name = "tagName",
1407            decoder = conjure_http::server::conjure::FromPlainDecoder,
1408            log_as = "tagName"
1409        )]
1410        tag_name: super::super::super::objects::scout::versioning::api::TagName,
1411    ) -> Result<(), conjure_http::private::Error>;
1412}