1// Code generated by cmd/lexgen (see Makefile's lexgen); DO NOT EDIT.
2
3package atproto
4
5// schema: com.atproto.sync.getLatestCommit
6
7import (
8 "context"
9
10 "github.com/bluesky-social/indigo/lex/util"
11)
12
13// SyncGetLatestCommit_Output is the output of a com.atproto.sync.getLatestCommit call.
14type SyncGetLatestCommit_Output struct {
15 Cid string `json:"cid" cborgen:"cid"`
16 Rev string `json:"rev" cborgen:"rev"`
17}
18
19// SyncGetLatestCommit calls the XRPC method "com.atproto.sync.getLatestCommit".
20//
21// did: The DID of the repo.
22func SyncGetLatestCommit(ctx context.Context, c util.LexClient, did string) (*SyncGetLatestCommit_Output, error) {
23 var out SyncGetLatestCommit_Output
24
25 params := map[string]interface{}{}
26 params["did"] = did
27 if err := c.LexDo(ctx, util.Query, "", "com.atproto.sync.getLatestCommit", params, nil, &out); err != nil {
28 return nil, err
29 }
30
31 return &out, nil
32}