forked from
tangled.org/core
fork
Configure Feed
Select the types of activity you want to include in your feed.
Monorepo for Tangled
fork
Configure Feed
Select the types of activity you want to include in your feed.
1// Code generated by cmd/lexgen (see Makefile's lexgen); DO NOT EDIT.
2
3package tangled
4
5// schema: sh.tangled.repo.branches
6
7import (
8 "bytes"
9 "context"
10
11 "github.com/bluesky-social/indigo/lex/util"
12)
13
14const (
15 RepoBranchesNSID = "sh.tangled.repo.branches"
16)
17
18// RepoBranches calls the XRPC method "sh.tangled.repo.branches".
19//
20// cursor: Pagination cursor
21// limit: Maximum number of branches to return
22// repo: Repository identifier in format 'did:plc:.../repoName'
23func RepoBranches(ctx context.Context, c util.LexClient, cursor string, limit int64, repo string) ([]byte, error) {
24 buf := new(bytes.Buffer)
25
26 params := map[string]interface{}{}
27 if cursor != "" {
28 params["cursor"] = cursor
29 }
30 if limit != 0 {
31 params["limit"] = limit
32 }
33 params["repo"] = repo
34 if err := c.LexDo(ctx, util.Query, "", "sh.tangled.repo.branches", params, nil, buf); err != nil {
35 return nil, err
36 }
37
38 return buf.Bytes(), nil
39}