A vibe coded tangled fork which supports pijul.
1// Code generated by cmd/lexgen (see Makefile's lexgen); DO NOT EDIT.
2
3package tangled
4
5// schema: sh.tangled.repo.channelList
6
7import (
8 "context"
9
10 "github.com/bluesky-social/indigo/lex/util"
11)
12
13const (
14 RepoChannelListNSID = "sh.tangled.repo.channelList"
15)
16
17// RepoChannelList_Channel is a "channel" in the sh.tangled.repo.channelList schema.
18type RepoChannelList_Channel struct {
19 // is_current: Whether this is the currently active channel
20 Is_current *bool `json:"is_current,omitempty" cborgen:"is_current,omitempty"`
21 // name: Channel name
22 Name string `json:"name" cborgen:"name"`
23}
24
25// RepoChannelList_Output is the output of a sh.tangled.repo.channelList call.
26type RepoChannelList_Output struct {
27 Channels []*RepoChannelList_Channel `json:"channels" cborgen:"channels"`
28}
29
30// RepoChannelList calls the XRPC method "sh.tangled.repo.channelList".
31//
32// cursor: Pagination cursor (offset)
33// limit: Maximum number of channels to return
34// repo: Repository identifier in format 'did:plc:.../repoName'
35func RepoChannelList(ctx context.Context, c util.LexClient, cursor string, limit int64, repo string) (*RepoChannelList_Output, error) {
36 var out RepoChannelList_Output
37
38 params := map[string]interface{}{}
39 if cursor != "" {
40 params["cursor"] = cursor
41 }
42 if limit != 0 {
43 params["limit"] = limit
44 }
45 params["repo"] = repo
46 if err := c.LexDo(ctx, util.Query, "", "sh.tangled.repo.channelList", params, nil, &out); err != nil {
47 return nil, err
48 }
49
50 return &out, nil
51}