// Code generated by cmd/lexgen (see Makefile's lexgen); DO NOT EDIT.

package atproto

// schema: com.atproto.sync.getCheckout

import (
	"bytes"
	"context"

	"github.com/bluesky-social/indigo/xrpc"
)

// SyncGetCheckout calls the XRPC method "com.atproto.sync.getCheckout".
//
// did: The DID of the repo.
func SyncGetCheckout(ctx context.Context, c *xrpc.Client, did string) ([]byte, error) {
	buf := new(bytes.Buffer)

	params := map[string]interface{}{
		"did": did,
	}
	if err := c.Do(ctx, xrpc.Query, "", "com.atproto.sync.getCheckout", params, nil, buf); err != nil {
		return nil, err
	}

	return buf.Bytes(), nil
}
