this repo has no description
0
fork

Configure Feed

Select the types of activity you want to include in your feed.

more (existing) lexgen tweaks (#1180)

Updates style of output code, but should have no behavioral or API
impact.

authored by

bnewbold and committed by
GitHub
aa029b5f 8c31d8b8

+1260 -1423
+13 -13
api/atproto/admindefs.go
··· 5 5 package atproto 6 6 7 7 import ( 8 - "github.com/bluesky-social/indigo/lex/util" 8 + lexutil "github.com/bluesky-social/indigo/lex/util" 9 9 ) 10 10 11 11 // AdminDefs_AccountView is a "accountView" in the com.atproto.admin.defs schema. 12 12 type AdminDefs_AccountView struct { 13 - DeactivatedAt *string `json:"deactivatedAt,omitempty" cborgen:"deactivatedAt,omitempty"` 14 - Did string `json:"did" cborgen:"did"` 15 - Email *string `json:"email,omitempty" cborgen:"email,omitempty"` 16 - EmailConfirmedAt *string `json:"emailConfirmedAt,omitempty" cborgen:"emailConfirmedAt,omitempty"` 17 - Handle string `json:"handle" cborgen:"handle"` 18 - IndexedAt string `json:"indexedAt" cborgen:"indexedAt"` 19 - InviteNote *string `json:"inviteNote,omitempty" cborgen:"inviteNote,omitempty"` 20 - InvitedBy *ServerDefs_InviteCode `json:"invitedBy,omitempty" cborgen:"invitedBy,omitempty"` 21 - Invites []*ServerDefs_InviteCode `json:"invites,omitempty" cborgen:"invites,omitempty"` 22 - InvitesDisabled *bool `json:"invitesDisabled,omitempty" cborgen:"invitesDisabled,omitempty"` 23 - RelatedRecords []*util.LexiconTypeDecoder `json:"relatedRecords,omitempty" cborgen:"relatedRecords,omitempty"` 24 - ThreatSignatures []*AdminDefs_ThreatSignature `json:"threatSignatures,omitempty" cborgen:"threatSignatures,omitempty"` 13 + DeactivatedAt *string `json:"deactivatedAt,omitempty" cborgen:"deactivatedAt,omitempty"` 14 + Did string `json:"did" cborgen:"did"` 15 + Email *string `json:"email,omitempty" cborgen:"email,omitempty"` 16 + EmailConfirmedAt *string `json:"emailConfirmedAt,omitempty" cborgen:"emailConfirmedAt,omitempty"` 17 + Handle string `json:"handle" cborgen:"handle"` 18 + IndexedAt string `json:"indexedAt" cborgen:"indexedAt"` 19 + InviteNote *string `json:"inviteNote,omitempty" cborgen:"inviteNote,omitempty"` 20 + InvitedBy *ServerDefs_InviteCode `json:"invitedBy,omitempty" cborgen:"invitedBy,omitempty"` 21 + Invites []*ServerDefs_InviteCode `json:"invites,omitempty" cborgen:"invites,omitempty"` 22 + InvitesDisabled *bool `json:"invitesDisabled,omitempty" cborgen:"invitesDisabled,omitempty"` 23 + RelatedRecords []*lexutil.LexiconTypeDecoder `json:"relatedRecords,omitempty" cborgen:"relatedRecords,omitempty"` 24 + ThreatSignatures []*AdminDefs_ThreatSignature `json:"threatSignatures,omitempty" cborgen:"threatSignatures,omitempty"` 25 25 } 26 26 27 27 // AdminDefs_RepoBlobRef is a "repoBlobRef" in the com.atproto.admin.defs schema.
+3 -3
api/atproto/admindeleteAccount.go
··· 7 7 import ( 8 8 "context" 9 9 10 - "github.com/bluesky-social/indigo/lex/util" 10 + lexutil "github.com/bluesky-social/indigo/lex/util" 11 11 ) 12 12 13 13 // AdminDeleteAccount_Input is the input argument to a com.atproto.admin.deleteAccount call. ··· 16 16 } 17 17 18 18 // AdminDeleteAccount calls the XRPC method "com.atproto.admin.deleteAccount". 19 - func AdminDeleteAccount(ctx context.Context, c util.LexClient, input *AdminDeleteAccount_Input) error { 20 - if err := c.LexDo(ctx, util.Procedure, "application/json", "com.atproto.admin.deleteAccount", nil, input, nil); err != nil { 19 + func AdminDeleteAccount(ctx context.Context, c lexutil.LexClient, input *AdminDeleteAccount_Input) error { 20 + if err := c.LexDo(ctx, lexutil.Procedure, "application/json", "com.atproto.admin.deleteAccount", nil, input, nil); err != nil { 21 21 return err 22 22 } 23 23
+3 -3
api/atproto/admindisableAccountInvites.go
··· 7 7 import ( 8 8 "context" 9 9 10 - "github.com/bluesky-social/indigo/lex/util" 10 + lexutil "github.com/bluesky-social/indigo/lex/util" 11 11 ) 12 12 13 13 // AdminDisableAccountInvites_Input is the input argument to a com.atproto.admin.disableAccountInvites call. ··· 18 18 } 19 19 20 20 // AdminDisableAccountInvites calls the XRPC method "com.atproto.admin.disableAccountInvites". 21 - func AdminDisableAccountInvites(ctx context.Context, c util.LexClient, input *AdminDisableAccountInvites_Input) error { 22 - if err := c.LexDo(ctx, util.Procedure, "application/json", "com.atproto.admin.disableAccountInvites", nil, input, nil); err != nil { 21 + func AdminDisableAccountInvites(ctx context.Context, c lexutil.LexClient, input *AdminDisableAccountInvites_Input) error { 22 + if err := c.LexDo(ctx, lexutil.Procedure, "application/json", "com.atproto.admin.disableAccountInvites", nil, input, nil); err != nil { 23 23 return err 24 24 } 25 25
+3 -3
api/atproto/admindisableInviteCodes.go
··· 7 7 import ( 8 8 "context" 9 9 10 - "github.com/bluesky-social/indigo/lex/util" 10 + lexutil "github.com/bluesky-social/indigo/lex/util" 11 11 ) 12 12 13 13 // AdminDisableInviteCodes_Input is the input argument to a com.atproto.admin.disableInviteCodes call. ··· 17 17 } 18 18 19 19 // AdminDisableInviteCodes calls the XRPC method "com.atproto.admin.disableInviteCodes". 20 - func AdminDisableInviteCodes(ctx context.Context, c util.LexClient, input *AdminDisableInviteCodes_Input) error { 21 - if err := c.LexDo(ctx, util.Procedure, "application/json", "com.atproto.admin.disableInviteCodes", nil, input, nil); err != nil { 20 + func AdminDisableInviteCodes(ctx context.Context, c lexutil.LexClient, input *AdminDisableInviteCodes_Input) error { 21 + if err := c.LexDo(ctx, lexutil.Procedure, "application/json", "com.atproto.admin.disableInviteCodes", nil, input, nil); err != nil { 22 22 return err 23 23 } 24 24
+3 -3
api/atproto/adminenableAccountInvites.go
··· 7 7 import ( 8 8 "context" 9 9 10 - "github.com/bluesky-social/indigo/lex/util" 10 + lexutil "github.com/bluesky-social/indigo/lex/util" 11 11 ) 12 12 13 13 // AdminEnableAccountInvites_Input is the input argument to a com.atproto.admin.enableAccountInvites call. ··· 18 18 } 19 19 20 20 // AdminEnableAccountInvites calls the XRPC method "com.atproto.admin.enableAccountInvites". 21 - func AdminEnableAccountInvites(ctx context.Context, c util.LexClient, input *AdminEnableAccountInvites_Input) error { 22 - if err := c.LexDo(ctx, util.Procedure, "application/json", "com.atproto.admin.enableAccountInvites", nil, input, nil); err != nil { 21 + func AdminEnableAccountInvites(ctx context.Context, c lexutil.LexClient, input *AdminEnableAccountInvites_Input) error { 22 + if err := c.LexDo(ctx, lexutil.Procedure, "application/json", "com.atproto.admin.enableAccountInvites", nil, input, nil); err != nil { 23 23 return err 24 24 } 25 25
+3 -3
api/atproto/admingetAccountInfo.go
··· 7 7 import ( 8 8 "context" 9 9 10 - "github.com/bluesky-social/indigo/lex/util" 10 + lexutil "github.com/bluesky-social/indigo/lex/util" 11 11 ) 12 12 13 13 // AdminGetAccountInfo calls the XRPC method "com.atproto.admin.getAccountInfo". 14 - func AdminGetAccountInfo(ctx context.Context, c util.LexClient, did string) (*AdminDefs_AccountView, error) { 14 + func AdminGetAccountInfo(ctx context.Context, c lexutil.LexClient, did string) (*AdminDefs_AccountView, error) { 15 15 var out AdminDefs_AccountView 16 16 17 17 params := map[string]interface{}{} 18 18 params["did"] = did 19 - if err := c.LexDo(ctx, util.Query, "", "com.atproto.admin.getAccountInfo", params, nil, &out); err != nil { 19 + if err := c.LexDo(ctx, lexutil.Query, "", "com.atproto.admin.getAccountInfo", params, nil, &out); err != nil { 20 20 return nil, err 21 21 } 22 22
+3 -3
api/atproto/admingetAccountInfos.go
··· 7 7 import ( 8 8 "context" 9 9 10 - "github.com/bluesky-social/indigo/lex/util" 10 + lexutil "github.com/bluesky-social/indigo/lex/util" 11 11 ) 12 12 13 13 // AdminGetAccountInfos_Output is the output of a com.atproto.admin.getAccountInfos call. ··· 16 16 } 17 17 18 18 // AdminGetAccountInfos calls the XRPC method "com.atproto.admin.getAccountInfos". 19 - func AdminGetAccountInfos(ctx context.Context, c util.LexClient, dids []string) (*AdminGetAccountInfos_Output, error) { 19 + func AdminGetAccountInfos(ctx context.Context, c lexutil.LexClient, dids []string) (*AdminGetAccountInfos_Output, error) { 20 20 var out AdminGetAccountInfos_Output 21 21 22 22 params := map[string]interface{}{} 23 23 params["dids"] = dids 24 - if err := c.LexDo(ctx, util.Query, "", "com.atproto.admin.getAccountInfos", params, nil, &out); err != nil { 24 + if err := c.LexDo(ctx, lexutil.Query, "", "com.atproto.admin.getAccountInfos", params, nil, &out); err != nil { 25 25 return nil, err 26 26 } 27 27
+3 -3
api/atproto/admingetInviteCodes.go
··· 7 7 import ( 8 8 "context" 9 9 10 - "github.com/bluesky-social/indigo/lex/util" 10 + lexutil "github.com/bluesky-social/indigo/lex/util" 11 11 ) 12 12 13 13 // AdminGetInviteCodes_Output is the output of a com.atproto.admin.getInviteCodes call. ··· 17 17 } 18 18 19 19 // AdminGetInviteCodes calls the XRPC method "com.atproto.admin.getInviteCodes". 20 - func AdminGetInviteCodes(ctx context.Context, c util.LexClient, cursor string, limit int64, sort string) (*AdminGetInviteCodes_Output, error) { 20 + func AdminGetInviteCodes(ctx context.Context, c lexutil.LexClient, cursor string, limit int64, sort string) (*AdminGetInviteCodes_Output, error) { 21 21 var out AdminGetInviteCodes_Output 22 22 23 23 params := map[string]interface{}{} ··· 30 30 if sort != "" { 31 31 params["sort"] = sort 32 32 } 33 - if err := c.LexDo(ctx, util.Query, "", "com.atproto.admin.getInviteCodes", params, nil, &out); err != nil { 33 + if err := c.LexDo(ctx, lexutil.Query, "", "com.atproto.admin.getInviteCodes", params, nil, &out); err != nil { 34 34 return nil, err 35 35 } 36 36
+4 -5
api/atproto/admingetSubjectStatus.go
··· 9 9 "encoding/json" 10 10 "fmt" 11 11 12 - "github.com/bluesky-social/indigo/lex/util" 12 + lexutil "github.com/bluesky-social/indigo/lex/util" 13 13 ) 14 14 15 15 // AdminGetSubjectStatus_Output is the output of a com.atproto.admin.getSubjectStatus call. ··· 42 42 } 43 43 44 44 func (t *AdminGetSubjectStatus_Output_Subject) UnmarshalJSON(b []byte) error { 45 - typ, err := util.TypeExtract(b) 45 + typ, err := lexutil.TypeExtract(b) 46 46 if err != nil { 47 47 return err 48 48 } ··· 57 57 case "com.atproto.admin.defs#repoBlobRef": 58 58 t.AdminDefs_RepoBlobRef = new(AdminDefs_RepoBlobRef) 59 59 return json.Unmarshal(b, t.AdminDefs_RepoBlobRef) 60 - 61 60 default: 62 61 return nil 63 62 } 64 63 } 65 64 66 65 // AdminGetSubjectStatus calls the XRPC method "com.atproto.admin.getSubjectStatus". 67 - func AdminGetSubjectStatus(ctx context.Context, c util.LexClient, blob string, did string, uri string) (*AdminGetSubjectStatus_Output, error) { 66 + func AdminGetSubjectStatus(ctx context.Context, c lexutil.LexClient, blob string, did string, uri string) (*AdminGetSubjectStatus_Output, error) { 68 67 var out AdminGetSubjectStatus_Output 69 68 70 69 params := map[string]interface{}{} ··· 77 76 if uri != "" { 78 77 params["uri"] = uri 79 78 } 80 - if err := c.LexDo(ctx, util.Query, "", "com.atproto.admin.getSubjectStatus", params, nil, &out); err != nil { 79 + if err := c.LexDo(ctx, lexutil.Query, "", "com.atproto.admin.getSubjectStatus", params, nil, &out); err != nil { 81 80 return nil, err 82 81 } 83 82
+3 -3
api/atproto/adminsearchAccounts.go
··· 7 7 import ( 8 8 "context" 9 9 10 - "github.com/bluesky-social/indigo/lex/util" 10 + lexutil "github.com/bluesky-social/indigo/lex/util" 11 11 ) 12 12 13 13 // AdminSearchAccounts_Output is the output of a com.atproto.admin.searchAccounts call. ··· 17 17 } 18 18 19 19 // AdminSearchAccounts calls the XRPC method "com.atproto.admin.searchAccounts". 20 - func AdminSearchAccounts(ctx context.Context, c util.LexClient, cursor string, email string, limit int64) (*AdminSearchAccounts_Output, error) { 20 + func AdminSearchAccounts(ctx context.Context, c lexutil.LexClient, cursor string, email string, limit int64) (*AdminSearchAccounts_Output, error) { 21 21 var out AdminSearchAccounts_Output 22 22 23 23 params := map[string]interface{}{} ··· 30 30 if limit != 0 { 31 31 params["limit"] = limit 32 32 } 33 - if err := c.LexDo(ctx, util.Query, "", "com.atproto.admin.searchAccounts", params, nil, &out); err != nil { 33 + if err := c.LexDo(ctx, lexutil.Query, "", "com.atproto.admin.searchAccounts", params, nil, &out); err != nil { 34 34 return nil, err 35 35 } 36 36
+3 -3
api/atproto/adminsendEmail.go
··· 7 7 import ( 8 8 "context" 9 9 10 - "github.com/bluesky-social/indigo/lex/util" 10 + lexutil "github.com/bluesky-social/indigo/lex/util" 11 11 ) 12 12 13 13 // AdminSendEmail_Input is the input argument to a com.atproto.admin.sendEmail call. ··· 26 26 } 27 27 28 28 // AdminSendEmail calls the XRPC method "com.atproto.admin.sendEmail". 29 - func AdminSendEmail(ctx context.Context, c util.LexClient, input *AdminSendEmail_Input) (*AdminSendEmail_Output, error) { 29 + func AdminSendEmail(ctx context.Context, c lexutil.LexClient, input *AdminSendEmail_Input) (*AdminSendEmail_Output, error) { 30 30 var out AdminSendEmail_Output 31 - if err := c.LexDo(ctx, util.Procedure, "application/json", "com.atproto.admin.sendEmail", nil, input, &out); err != nil { 31 + if err := c.LexDo(ctx, lexutil.Procedure, "application/json", "com.atproto.admin.sendEmail", nil, input, &out); err != nil { 32 32 return nil, err 33 33 } 34 34
+3 -3
api/atproto/adminupdateAccountEmail.go
··· 7 7 import ( 8 8 "context" 9 9 10 - "github.com/bluesky-social/indigo/lex/util" 10 + lexutil "github.com/bluesky-social/indigo/lex/util" 11 11 ) 12 12 13 13 // AdminUpdateAccountEmail_Input is the input argument to a com.atproto.admin.updateAccountEmail call. ··· 18 18 } 19 19 20 20 // AdminUpdateAccountEmail calls the XRPC method "com.atproto.admin.updateAccountEmail". 21 - func AdminUpdateAccountEmail(ctx context.Context, c util.LexClient, input *AdminUpdateAccountEmail_Input) error { 22 - if err := c.LexDo(ctx, util.Procedure, "application/json", "com.atproto.admin.updateAccountEmail", nil, input, nil); err != nil { 21 + func AdminUpdateAccountEmail(ctx context.Context, c lexutil.LexClient, input *AdminUpdateAccountEmail_Input) error { 22 + if err := c.LexDo(ctx, lexutil.Procedure, "application/json", "com.atproto.admin.updateAccountEmail", nil, input, nil); err != nil { 23 23 return err 24 24 } 25 25
+3 -3
api/atproto/adminupdateAccountHandle.go
··· 7 7 import ( 8 8 "context" 9 9 10 - "github.com/bluesky-social/indigo/lex/util" 10 + lexutil "github.com/bluesky-social/indigo/lex/util" 11 11 ) 12 12 13 13 // AdminUpdateAccountHandle_Input is the input argument to a com.atproto.admin.updateAccountHandle call. ··· 17 17 } 18 18 19 19 // AdminUpdateAccountHandle calls the XRPC method "com.atproto.admin.updateAccountHandle". 20 - func AdminUpdateAccountHandle(ctx context.Context, c util.LexClient, input *AdminUpdateAccountHandle_Input) error { 21 - if err := c.LexDo(ctx, util.Procedure, "application/json", "com.atproto.admin.updateAccountHandle", nil, input, nil); err != nil { 20 + func AdminUpdateAccountHandle(ctx context.Context, c lexutil.LexClient, input *AdminUpdateAccountHandle_Input) error { 21 + if err := c.LexDo(ctx, lexutil.Procedure, "application/json", "com.atproto.admin.updateAccountHandle", nil, input, nil); err != nil { 22 22 return err 23 23 } 24 24
+3 -3
api/atproto/adminupdateAccountPassword.go
··· 7 7 import ( 8 8 "context" 9 9 10 - "github.com/bluesky-social/indigo/lex/util" 10 + lexutil "github.com/bluesky-social/indigo/lex/util" 11 11 ) 12 12 13 13 // AdminUpdateAccountPassword_Input is the input argument to a com.atproto.admin.updateAccountPassword call. ··· 17 17 } 18 18 19 19 // AdminUpdateAccountPassword calls the XRPC method "com.atproto.admin.updateAccountPassword". 20 - func AdminUpdateAccountPassword(ctx context.Context, c util.LexClient, input *AdminUpdateAccountPassword_Input) error { 21 - if err := c.LexDo(ctx, util.Procedure, "application/json", "com.atproto.admin.updateAccountPassword", nil, input, nil); err != nil { 20 + func AdminUpdateAccountPassword(ctx context.Context, c lexutil.LexClient, input *AdminUpdateAccountPassword_Input) error { 21 + if err := c.LexDo(ctx, lexutil.Procedure, "application/json", "com.atproto.admin.updateAccountPassword", nil, input, nil); err != nil { 22 22 return err 23 23 } 24 24
+3 -3
api/atproto/adminupdateAccountSigningKey.go
··· 7 7 import ( 8 8 "context" 9 9 10 - "github.com/bluesky-social/indigo/lex/util" 10 + lexutil "github.com/bluesky-social/indigo/lex/util" 11 11 ) 12 12 13 13 // AdminUpdateAccountSigningKey_Input is the input argument to a com.atproto.admin.updateAccountSigningKey call. ··· 18 18 } 19 19 20 20 // AdminUpdateAccountSigningKey calls the XRPC method "com.atproto.admin.updateAccountSigningKey". 21 - func AdminUpdateAccountSigningKey(ctx context.Context, c util.LexClient, input *AdminUpdateAccountSigningKey_Input) error { 22 - if err := c.LexDo(ctx, util.Procedure, "application/json", "com.atproto.admin.updateAccountSigningKey", nil, input, nil); err != nil { 21 + func AdminUpdateAccountSigningKey(ctx context.Context, c lexutil.LexClient, input *AdminUpdateAccountSigningKey_Input) error { 22 + if err := c.LexDo(ctx, lexutil.Procedure, "application/json", "com.atproto.admin.updateAccountSigningKey", nil, input, nil); err != nil { 23 23 return err 24 24 } 25 25
+5 -7
api/atproto/adminupdateSubjectStatus.go
··· 9 9 "encoding/json" 10 10 "fmt" 11 11 12 - "github.com/bluesky-social/indigo/lex/util" 12 + lexutil "github.com/bluesky-social/indigo/lex/util" 13 13 ) 14 14 15 15 // AdminUpdateSubjectStatus_Input is the input argument to a com.atproto.admin.updateSubjectStatus call. ··· 42 42 } 43 43 44 44 func (t *AdminUpdateSubjectStatus_Input_Subject) UnmarshalJSON(b []byte) error { 45 - typ, err := util.TypeExtract(b) 45 + typ, err := lexutil.TypeExtract(b) 46 46 if err != nil { 47 47 return err 48 48 } ··· 57 57 case "com.atproto.admin.defs#repoBlobRef": 58 58 t.AdminDefs_RepoBlobRef = new(AdminDefs_RepoBlobRef) 59 59 return json.Unmarshal(b, t.AdminDefs_RepoBlobRef) 60 - 61 60 default: 62 61 return nil 63 62 } ··· 92 91 } 93 92 94 93 func (t *AdminUpdateSubjectStatus_Output_Subject) UnmarshalJSON(b []byte) error { 95 - typ, err := util.TypeExtract(b) 94 + typ, err := lexutil.TypeExtract(b) 96 95 if err != nil { 97 96 return err 98 97 } ··· 107 106 case "com.atproto.admin.defs#repoBlobRef": 108 107 t.AdminDefs_RepoBlobRef = new(AdminDefs_RepoBlobRef) 109 108 return json.Unmarshal(b, t.AdminDefs_RepoBlobRef) 110 - 111 109 default: 112 110 return nil 113 111 } 114 112 } 115 113 116 114 // AdminUpdateSubjectStatus calls the XRPC method "com.atproto.admin.updateSubjectStatus". 117 - func AdminUpdateSubjectStatus(ctx context.Context, c util.LexClient, input *AdminUpdateSubjectStatus_Input) (*AdminUpdateSubjectStatus_Output, error) { 115 + func AdminUpdateSubjectStatus(ctx context.Context, c lexutil.LexClient, input *AdminUpdateSubjectStatus_Input) (*AdminUpdateSubjectStatus_Output, error) { 118 116 var out AdminUpdateSubjectStatus_Output 119 - if err := c.LexDo(ctx, util.Procedure, "application/json", "com.atproto.admin.updateSubjectStatus", nil, input, &out); err != nil { 117 + if err := c.LexDo(ctx, lexutil.Procedure, "application/json", "com.atproto.admin.updateSubjectStatus", nil, input, &out); err != nil { 120 118 return nil, err 121 119 } 122 120
+6 -6
api/atproto/identitygetRecommendedDidCredentials.go
··· 7 7 import ( 8 8 "context" 9 9 10 - "github.com/bluesky-social/indigo/lex/util" 10 + lexutil "github.com/bluesky-social/indigo/lex/util" 11 11 ) 12 12 13 13 // IdentityGetRecommendedDidCredentials_Output is the output of a com.atproto.identity.getRecommendedDidCredentials call. 14 14 type IdentityGetRecommendedDidCredentials_Output struct { 15 15 AlsoKnownAs []string `json:"alsoKnownAs,omitempty" cborgen:"alsoKnownAs,omitempty"` 16 16 // rotationKeys: Recommended rotation keys for PLC dids. Should be undefined (or ignored) for did:webs. 17 - RotationKeys []string `json:"rotationKeys,omitempty" cborgen:"rotationKeys,omitempty"` 18 - Services *util.LexiconTypeDecoder `json:"services,omitempty" cborgen:"services,omitempty"` 19 - VerificationMethods *util.LexiconTypeDecoder `json:"verificationMethods,omitempty" cborgen:"verificationMethods,omitempty"` 17 + RotationKeys []string `json:"rotationKeys,omitempty" cborgen:"rotationKeys,omitempty"` 18 + Services *lexutil.LexiconTypeDecoder `json:"services,omitempty" cborgen:"services,omitempty"` 19 + VerificationMethods *lexutil.LexiconTypeDecoder `json:"verificationMethods,omitempty" cborgen:"verificationMethods,omitempty"` 20 20 } 21 21 22 22 // IdentityGetRecommendedDidCredentials calls the XRPC method "com.atproto.identity.getRecommendedDidCredentials". 23 - func IdentityGetRecommendedDidCredentials(ctx context.Context, c util.LexClient) (*IdentityGetRecommendedDidCredentials_Output, error) { 23 + func IdentityGetRecommendedDidCredentials(ctx context.Context, c lexutil.LexClient) (*IdentityGetRecommendedDidCredentials_Output, error) { 24 24 var out IdentityGetRecommendedDidCredentials_Output 25 - if err := c.LexDo(ctx, util.Query, "", "com.atproto.identity.getRecommendedDidCredentials", nil, nil, &out); err != nil { 25 + if err := c.LexDo(ctx, lexutil.Query, "", "com.atproto.identity.getRecommendedDidCredentials", nil, nil, &out); err != nil { 26 26 return nil, err 27 27 } 28 28
+3 -3
api/atproto/identityrefreshIdentity.go
··· 7 7 import ( 8 8 "context" 9 9 10 - "github.com/bluesky-social/indigo/lex/util" 10 + lexutil "github.com/bluesky-social/indigo/lex/util" 11 11 ) 12 12 13 13 // IdentityRefreshIdentity_Input is the input argument to a com.atproto.identity.refreshIdentity call. ··· 16 16 } 17 17 18 18 // IdentityRefreshIdentity calls the XRPC method "com.atproto.identity.refreshIdentity". 19 - func IdentityRefreshIdentity(ctx context.Context, c util.LexClient, input *IdentityRefreshIdentity_Input) (*IdentityDefs_IdentityInfo, error) { 19 + func IdentityRefreshIdentity(ctx context.Context, c lexutil.LexClient, input *IdentityRefreshIdentity_Input) (*IdentityDefs_IdentityInfo, error) { 20 20 var out IdentityDefs_IdentityInfo 21 - if err := c.LexDo(ctx, util.Procedure, "application/json", "com.atproto.identity.refreshIdentity", nil, input, &out); err != nil { 21 + if err := c.LexDo(ctx, lexutil.Procedure, "application/json", "com.atproto.identity.refreshIdentity", nil, input, &out); err != nil { 22 22 return nil, err 23 23 } 24 24
+3 -3
api/atproto/identityrequestPlcOperationSignature.go
··· 7 7 import ( 8 8 "context" 9 9 10 - "github.com/bluesky-social/indigo/lex/util" 10 + lexutil "github.com/bluesky-social/indigo/lex/util" 11 11 ) 12 12 13 13 // IdentityRequestPlcOperationSignature calls the XRPC method "com.atproto.identity.requestPlcOperationSignature". 14 - func IdentityRequestPlcOperationSignature(ctx context.Context, c util.LexClient) error { 15 - if err := c.LexDo(ctx, util.Procedure, "", "com.atproto.identity.requestPlcOperationSignature", nil, nil, nil); err != nil { 14 + func IdentityRequestPlcOperationSignature(ctx context.Context, c lexutil.LexClient) error { 15 + if err := c.LexDo(ctx, lexutil.Procedure, "", "com.atproto.identity.requestPlcOperationSignature", nil, nil, nil); err != nil { 16 16 return err 17 17 } 18 18
+3 -3
api/atproto/identityresolveDid.go
··· 7 7 import ( 8 8 "context" 9 9 10 - "github.com/bluesky-social/indigo/lex/util" 10 + lexutil "github.com/bluesky-social/indigo/lex/util" 11 11 ) 12 12 13 13 // IdentityResolveDid_Output is the output of a com.atproto.identity.resolveDid call. ··· 19 19 // IdentityResolveDid calls the XRPC method "com.atproto.identity.resolveDid". 20 20 // 21 21 // did: DID to resolve. 22 - func IdentityResolveDid(ctx context.Context, c util.LexClient, did string) (*IdentityResolveDid_Output, error) { 22 + func IdentityResolveDid(ctx context.Context, c lexutil.LexClient, did string) (*IdentityResolveDid_Output, error) { 23 23 var out IdentityResolveDid_Output 24 24 25 25 params := map[string]interface{}{} 26 26 params["did"] = did 27 - if err := c.LexDo(ctx, util.Query, "", "com.atproto.identity.resolveDid", params, nil, &out); err != nil { 27 + if err := c.LexDo(ctx, lexutil.Query, "", "com.atproto.identity.resolveDid", params, nil, &out); err != nil { 28 28 return nil, err 29 29 } 30 30
+3 -3
api/atproto/identityresolveHandle.go
··· 7 7 import ( 8 8 "context" 9 9 10 - "github.com/bluesky-social/indigo/lex/util" 10 + lexutil "github.com/bluesky-social/indigo/lex/util" 11 11 ) 12 12 13 13 // IdentityResolveHandle_Output is the output of a com.atproto.identity.resolveHandle call. ··· 18 18 // IdentityResolveHandle calls the XRPC method "com.atproto.identity.resolveHandle". 19 19 // 20 20 // handle: The handle to resolve. 21 - func IdentityResolveHandle(ctx context.Context, c util.LexClient, handle string) (*IdentityResolveHandle_Output, error) { 21 + func IdentityResolveHandle(ctx context.Context, c lexutil.LexClient, handle string) (*IdentityResolveHandle_Output, error) { 22 22 var out IdentityResolveHandle_Output 23 23 24 24 params := map[string]interface{}{} 25 25 params["handle"] = handle 26 - if err := c.LexDo(ctx, util.Query, "", "com.atproto.identity.resolveHandle", params, nil, &out); err != nil { 26 + if err := c.LexDo(ctx, lexutil.Query, "", "com.atproto.identity.resolveHandle", params, nil, &out); err != nil { 27 27 return nil, err 28 28 } 29 29
+3 -3
api/atproto/identityresolveIdentity.go
··· 7 7 import ( 8 8 "context" 9 9 10 - "github.com/bluesky-social/indigo/lex/util" 10 + lexutil "github.com/bluesky-social/indigo/lex/util" 11 11 ) 12 12 13 13 // IdentityResolveIdentity calls the XRPC method "com.atproto.identity.resolveIdentity". 14 14 // 15 15 // identifier: Handle or DID to resolve. 16 - func IdentityResolveIdentity(ctx context.Context, c util.LexClient, identifier string) (*IdentityDefs_IdentityInfo, error) { 16 + func IdentityResolveIdentity(ctx context.Context, c lexutil.LexClient, identifier string) (*IdentityDefs_IdentityInfo, error) { 17 17 var out IdentityDefs_IdentityInfo 18 18 19 19 params := map[string]interface{}{} 20 20 params["identifier"] = identifier 21 - if err := c.LexDo(ctx, util.Query, "", "com.atproto.identity.resolveIdentity", params, nil, &out); err != nil { 21 + if err := c.LexDo(ctx, lexutil.Query, "", "com.atproto.identity.resolveIdentity", params, nil, &out); err != nil { 22 22 return nil, err 23 23 } 24 24
+9 -9
api/atproto/identitysignPlcOperation.go
··· 7 7 import ( 8 8 "context" 9 9 10 - "github.com/bluesky-social/indigo/lex/util" 10 + lexutil "github.com/bluesky-social/indigo/lex/util" 11 11 ) 12 12 13 13 // IdentitySignPlcOperation_Input is the input argument to a com.atproto.identity.signPlcOperation call. 14 14 type IdentitySignPlcOperation_Input struct { 15 - AlsoKnownAs []string `json:"alsoKnownAs,omitempty" cborgen:"alsoKnownAs,omitempty"` 16 - RotationKeys []string `json:"rotationKeys,omitempty" cborgen:"rotationKeys,omitempty"` 17 - Services *util.LexiconTypeDecoder `json:"services,omitempty" cborgen:"services,omitempty"` 15 + AlsoKnownAs []string `json:"alsoKnownAs,omitempty" cborgen:"alsoKnownAs,omitempty"` 16 + RotationKeys []string `json:"rotationKeys,omitempty" cborgen:"rotationKeys,omitempty"` 17 + Services *lexutil.LexiconTypeDecoder `json:"services,omitempty" cborgen:"services,omitempty"` 18 18 // token: A token received through com.atproto.identity.requestPlcOperationSignature 19 - Token *string `json:"token,omitempty" cborgen:"token,omitempty"` 20 - VerificationMethods *util.LexiconTypeDecoder `json:"verificationMethods,omitempty" cborgen:"verificationMethods,omitempty"` 19 + Token *string `json:"token,omitempty" cborgen:"token,omitempty"` 20 + VerificationMethods *lexutil.LexiconTypeDecoder `json:"verificationMethods,omitempty" cborgen:"verificationMethods,omitempty"` 21 21 } 22 22 23 23 // IdentitySignPlcOperation_Output is the output of a com.atproto.identity.signPlcOperation call. 24 24 type IdentitySignPlcOperation_Output struct { 25 25 // operation: A signed DID PLC operation. 26 - Operation *util.LexiconTypeDecoder `json:"operation" cborgen:"operation"` 26 + Operation *lexutil.LexiconTypeDecoder `json:"operation" cborgen:"operation"` 27 27 } 28 28 29 29 // IdentitySignPlcOperation calls the XRPC method "com.atproto.identity.signPlcOperation". 30 - func IdentitySignPlcOperation(ctx context.Context, c util.LexClient, input *IdentitySignPlcOperation_Input) (*IdentitySignPlcOperation_Output, error) { 30 + func IdentitySignPlcOperation(ctx context.Context, c lexutil.LexClient, input *IdentitySignPlcOperation_Input) (*IdentitySignPlcOperation_Output, error) { 31 31 var out IdentitySignPlcOperation_Output 32 - if err := c.LexDo(ctx, util.Procedure, "application/json", "com.atproto.identity.signPlcOperation", nil, input, &out); err != nil { 32 + if err := c.LexDo(ctx, lexutil.Procedure, "application/json", "com.atproto.identity.signPlcOperation", nil, input, &out); err != nil { 33 33 return nil, err 34 34 } 35 35
+4 -4
api/atproto/identitysubmitPlcOperation.go
··· 7 7 import ( 8 8 "context" 9 9 10 - "github.com/bluesky-social/indigo/lex/util" 10 + lexutil "github.com/bluesky-social/indigo/lex/util" 11 11 ) 12 12 13 13 // IdentitySubmitPlcOperation_Input is the input argument to a com.atproto.identity.submitPlcOperation call. 14 14 type IdentitySubmitPlcOperation_Input struct { 15 - Operation *util.LexiconTypeDecoder `json:"operation" cborgen:"operation"` 15 + Operation *lexutil.LexiconTypeDecoder `json:"operation" cborgen:"operation"` 16 16 } 17 17 18 18 // IdentitySubmitPlcOperation calls the XRPC method "com.atproto.identity.submitPlcOperation". 19 - func IdentitySubmitPlcOperation(ctx context.Context, c util.LexClient, input *IdentitySubmitPlcOperation_Input) error { 20 - if err := c.LexDo(ctx, util.Procedure, "application/json", "com.atproto.identity.submitPlcOperation", nil, input, nil); err != nil { 19 + func IdentitySubmitPlcOperation(ctx context.Context, c lexutil.LexClient, input *IdentitySubmitPlcOperation_Input) error { 20 + if err := c.LexDo(ctx, lexutil.Procedure, "application/json", "com.atproto.identity.submitPlcOperation", nil, input, nil); err != nil { 21 21 return err 22 22 } 23 23
+3 -3
api/atproto/identityupdateHandle.go
··· 7 7 import ( 8 8 "context" 9 9 10 - "github.com/bluesky-social/indigo/lex/util" 10 + lexutil "github.com/bluesky-social/indigo/lex/util" 11 11 ) 12 12 13 13 // IdentityUpdateHandle_Input is the input argument to a com.atproto.identity.updateHandle call. ··· 17 17 } 18 18 19 19 // IdentityUpdateHandle calls the XRPC method "com.atproto.identity.updateHandle". 20 - func IdentityUpdateHandle(ctx context.Context, c util.LexClient, input *IdentityUpdateHandle_Input) error { 21 - if err := c.LexDo(ctx, util.Procedure, "application/json", "com.atproto.identity.updateHandle", nil, input, nil); err != nil { 20 + func IdentityUpdateHandle(ctx context.Context, c lexutil.LexClient, input *IdentityUpdateHandle_Input) error { 21 + if err := c.LexDo(ctx, lexutil.Procedure, "application/json", "com.atproto.identity.updateHandle", nil, input, nil); err != nil { 22 22 return err 23 23 } 24 24
+2 -2
api/atproto/labeldefs.go
··· 5 5 package atproto 6 6 7 7 import ( 8 - "github.com/bluesky-social/indigo/lex/util" 8 + lexutil "github.com/bluesky-social/indigo/lex/util" 9 9 ) 10 10 11 11 // LabelDefs_Label is a "label" in the com.atproto.label.defs schema. ··· 21 21 // neg: If true, this is a negation label, overwriting a previous label. 22 22 Neg *bool `json:"neg,omitempty" cborgen:"neg,omitempty"` 23 23 // sig: Signature of dag-cbor encoded label. 24 - Sig util.LexBytes `json:"sig,omitempty" cborgen:"sig,omitempty"` 24 + Sig lexutil.LexBytes `json:"sig,omitempty" cborgen:"sig,omitempty"` 25 25 // src: DID of the actor who created this label. 26 26 Src string `json:"src" cborgen:"src"` 27 27 // uri: AT URI of the record, repository (account), or other resource that this label applies to.
+3 -3
api/atproto/labelqueryLabels.go
··· 7 7 import ( 8 8 "context" 9 9 10 - "github.com/bluesky-social/indigo/lex/util" 10 + lexutil "github.com/bluesky-social/indigo/lex/util" 11 11 ) 12 12 13 13 // LabelQueryLabels_Output is the output of a com.atproto.label.queryLabels call. ··· 20 20 // 21 21 // sources: Optional list of label sources (DIDs) to filter on. 22 22 // uriPatterns: List of AT URI patterns to match (boolean 'OR'). Each may be a prefix (ending with '*'; will match inclusive of the string leading to '*'), or a full URI. 23 - func LabelQueryLabels(ctx context.Context, c util.LexClient, cursor string, limit int64, sources []string, uriPatterns []string) (*LabelQueryLabels_Output, error) { 23 + func LabelQueryLabels(ctx context.Context, c lexutil.LexClient, cursor string, limit int64, sources []string, uriPatterns []string) (*LabelQueryLabels_Output, error) { 24 24 var out LabelQueryLabels_Output 25 25 26 26 params := map[string]interface{}{} ··· 34 34 params["sources"] = sources 35 35 } 36 36 params["uriPatterns"] = uriPatterns 37 - if err := c.LexDo(ctx, util.Query, "", "com.atproto.label.queryLabels", params, nil, &out); err != nil { 37 + if err := c.LexDo(ctx, lexutil.Query, "", "com.atproto.label.queryLabels", params, nil, &out); err != nil { 38 38 return nil, err 39 39 } 40 40
+2 -2
api/atproto/lexiconschema.go
··· 5 5 package atproto 6 6 7 7 import ( 8 - "github.com/bluesky-social/indigo/lex/util" 8 + lexutil "github.com/bluesky-social/indigo/lex/util" 9 9 ) 10 10 11 11 func init() { 12 - util.RegisterType("com.atproto.lexicon.schema", &LexiconSchema{}) 12 + lexutil.RegisterType("com.atproto.lexicon.schema", &LexiconSchema{}) 13 13 } 14 14 15 15 type LexiconSchema struct {
+5 -7
api/atproto/moderationcreateReport.go
··· 9 9 "encoding/json" 10 10 "fmt" 11 11 12 - "github.com/bluesky-social/indigo/lex/util" 12 + lexutil "github.com/bluesky-social/indigo/lex/util" 13 13 ) 14 14 15 15 // ModerationCreateReport_Input is the input argument to a com.atproto.moderation.createReport call. ··· 40 40 } 41 41 42 42 func (t *ModerationCreateReport_Input_Subject) UnmarshalJSON(b []byte) error { 43 - typ, err := util.TypeExtract(b) 43 + typ, err := lexutil.TypeExtract(b) 44 44 if err != nil { 45 45 return err 46 46 } ··· 52 52 case "com.atproto.repo.strongRef": 53 53 t.RepoStrongRef = new(RepoStrongRef) 54 54 return json.Unmarshal(b, t.RepoStrongRef) 55 - 56 55 default: 57 56 return nil 58 57 } ··· 96 95 } 97 96 98 97 func (t *ModerationCreateReport_Output_Subject) UnmarshalJSON(b []byte) error { 99 - typ, err := util.TypeExtract(b) 98 + typ, err := lexutil.TypeExtract(b) 100 99 if err != nil { 101 100 return err 102 101 } ··· 108 107 case "com.atproto.repo.strongRef": 109 108 t.RepoStrongRef = new(RepoStrongRef) 110 109 return json.Unmarshal(b, t.RepoStrongRef) 111 - 112 110 default: 113 111 return nil 114 112 } 115 113 } 116 114 117 115 // ModerationCreateReport calls the XRPC method "com.atproto.moderation.createReport". 118 - func ModerationCreateReport(ctx context.Context, c util.LexClient, input *ModerationCreateReport_Input) (*ModerationCreateReport_Output, error) { 116 + func ModerationCreateReport(ctx context.Context, c lexutil.LexClient, input *ModerationCreateReport_Input) (*ModerationCreateReport_Output, error) { 119 117 var out ModerationCreateReport_Output 120 - if err := c.LexDo(ctx, util.Procedure, "application/json", "com.atproto.moderation.createReport", nil, input, &out); err != nil { 118 + if err := c.LexDo(ctx, lexutil.Procedure, "application/json", "com.atproto.moderation.createReport", nil, input, &out); err != nil { 121 119 return nil, err 122 120 } 123 121
+11 -13
api/atproto/repoapplyWrites.go
··· 9 9 "encoding/json" 10 10 "fmt" 11 11 12 - "github.com/bluesky-social/indigo/lex/util" 12 + lexutil "github.com/bluesky-social/indigo/lex/util" 13 13 ) 14 14 15 15 // RepoApplyWrites_Create is a "create" in the com.atproto.repo.applyWrites schema. ··· 19 19 LexiconTypeID string `json:"$type" cborgen:"$type,const=com.atproto.repo.applyWrites#create"` 20 20 Collection string `json:"collection" cborgen:"collection"` 21 21 // rkey: NOTE: maxLength is redundant with record-key format. Keeping it temporarily to ensure backwards compatibility. 22 - Rkey *string `json:"rkey,omitempty" cborgen:"rkey,omitempty"` 23 - Value *util.LexiconTypeDecoder `json:"value" cborgen:"value"` 22 + Rkey *string `json:"rkey,omitempty" cborgen:"rkey,omitempty"` 23 + Value *lexutil.LexiconTypeDecoder `json:"value" cborgen:"value"` 24 24 } 25 25 26 26 // RepoApplyWrites_CreateResult is a "createResult" in the com.atproto.repo.applyWrites schema. ··· 79 79 } 80 80 81 81 func (t *RepoApplyWrites_Input_Writes_Elem) UnmarshalJSON(b []byte) error { 82 - typ, err := util.TypeExtract(b) 82 + typ, err := lexutil.TypeExtract(b) 83 83 if err != nil { 84 84 return err 85 85 } ··· 94 94 case "com.atproto.repo.applyWrites#delete": 95 95 t.RepoApplyWrites_Delete = new(RepoApplyWrites_Delete) 96 96 return json.Unmarshal(b, t.RepoApplyWrites_Delete) 97 - 98 97 default: 99 98 return fmt.Errorf("closed unions must match a listed schema") 100 99 } ··· 129 128 } 130 129 131 130 func (t *RepoApplyWrites_Output_Results_Elem) UnmarshalJSON(b []byte) error { 132 - typ, err := util.TypeExtract(b) 131 + typ, err := lexutil.TypeExtract(b) 133 132 if err != nil { 134 133 return err 135 134 } ··· 144 143 case "com.atproto.repo.applyWrites#deleteResult": 145 144 t.RepoApplyWrites_DeleteResult = new(RepoApplyWrites_DeleteResult) 146 145 return json.Unmarshal(b, t.RepoApplyWrites_DeleteResult) 147 - 148 146 default: 149 147 return fmt.Errorf("closed unions must match a listed schema") 150 148 } ··· 154 152 // 155 153 // Operation which updates an existing record. 156 154 type RepoApplyWrites_Update struct { 157 - LexiconTypeID string `json:"$type" cborgen:"$type,const=com.atproto.repo.applyWrites#update"` 158 - Collection string `json:"collection" cborgen:"collection"` 159 - Rkey string `json:"rkey" cborgen:"rkey"` 160 - Value *util.LexiconTypeDecoder `json:"value" cborgen:"value"` 155 + LexiconTypeID string `json:"$type" cborgen:"$type,const=com.atproto.repo.applyWrites#update"` 156 + Collection string `json:"collection" cborgen:"collection"` 157 + Rkey string `json:"rkey" cborgen:"rkey"` 158 + Value *lexutil.LexiconTypeDecoder `json:"value" cborgen:"value"` 161 159 } 162 160 163 161 // RepoApplyWrites_UpdateResult is a "updateResult" in the com.atproto.repo.applyWrites schema. ··· 169 167 } 170 168 171 169 // RepoApplyWrites calls the XRPC method "com.atproto.repo.applyWrites". 172 - func RepoApplyWrites(ctx context.Context, c util.LexClient, input *RepoApplyWrites_Input) (*RepoApplyWrites_Output, error) { 170 + func RepoApplyWrites(ctx context.Context, c lexutil.LexClient, input *RepoApplyWrites_Input) (*RepoApplyWrites_Output, error) { 173 171 var out RepoApplyWrites_Output 174 - if err := c.LexDo(ctx, util.Procedure, "application/json", "com.atproto.repo.applyWrites", nil, input, &out); err != nil { 172 + if err := c.LexDo(ctx, lexutil.Procedure, "application/json", "com.atproto.repo.applyWrites", nil, input, &out); err != nil { 175 173 return nil, err 176 174 } 177 175
+4 -4
api/atproto/repocreateRecord.go
··· 7 7 import ( 8 8 "context" 9 9 10 - "github.com/bluesky-social/indigo/lex/util" 10 + lexutil "github.com/bluesky-social/indigo/lex/util" 11 11 ) 12 12 13 13 // RepoCreateRecord_Input is the input argument to a com.atproto.repo.createRecord call. ··· 15 15 // collection: The NSID of the record collection. 16 16 Collection string `json:"collection" cborgen:"collection"` 17 17 // record: The record itself. Must contain a $type field. 18 - Record *util.LexiconTypeDecoder `json:"record" cborgen:"record"` 18 + Record *lexutil.LexiconTypeDecoder `json:"record" cborgen:"record"` 19 19 // repo: The handle or DID of the repo (aka, current account). 20 20 Repo string `json:"repo" cborgen:"repo"` 21 21 // rkey: The Record Key. ··· 35 35 } 36 36 37 37 // RepoCreateRecord calls the XRPC method "com.atproto.repo.createRecord". 38 - func RepoCreateRecord(ctx context.Context, c util.LexClient, input *RepoCreateRecord_Input) (*RepoCreateRecord_Output, error) { 38 + func RepoCreateRecord(ctx context.Context, c lexutil.LexClient, input *RepoCreateRecord_Input) (*RepoCreateRecord_Output, error) { 39 39 var out RepoCreateRecord_Output 40 - if err := c.LexDo(ctx, util.Procedure, "application/json", "com.atproto.repo.createRecord", nil, input, &out); err != nil { 40 + if err := c.LexDo(ctx, lexutil.Procedure, "application/json", "com.atproto.repo.createRecord", nil, input, &out); err != nil { 41 41 return nil, err 42 42 } 43 43
+3 -3
api/atproto/repodeleteRecord.go
··· 7 7 import ( 8 8 "context" 9 9 10 - "github.com/bluesky-social/indigo/lex/util" 10 + lexutil "github.com/bluesky-social/indigo/lex/util" 11 11 ) 12 12 13 13 // RepoDeleteRecord_Input is the input argument to a com.atproto.repo.deleteRecord call. ··· 30 30 } 31 31 32 32 // RepoDeleteRecord calls the XRPC method "com.atproto.repo.deleteRecord". 33 - func RepoDeleteRecord(ctx context.Context, c util.LexClient, input *RepoDeleteRecord_Input) (*RepoDeleteRecord_Output, error) { 33 + func RepoDeleteRecord(ctx context.Context, c lexutil.LexClient, input *RepoDeleteRecord_Input) (*RepoDeleteRecord_Output, error) { 34 34 var out RepoDeleteRecord_Output 35 - if err := c.LexDo(ctx, util.Procedure, "application/json", "com.atproto.repo.deleteRecord", nil, input, &out); err != nil { 35 + if err := c.LexDo(ctx, lexutil.Procedure, "application/json", "com.atproto.repo.deleteRecord", nil, input, &out); err != nil { 36 36 return nil, err 37 37 } 38 38
+3 -3
api/atproto/repodescribeRepo.go
··· 7 7 import ( 8 8 "context" 9 9 10 - "github.com/bluesky-social/indigo/lex/util" 10 + lexutil "github.com/bluesky-social/indigo/lex/util" 11 11 ) 12 12 13 13 // RepoDescribeRepo_Output is the output of a com.atproto.repo.describeRepo call. ··· 25 25 // RepoDescribeRepo calls the XRPC method "com.atproto.repo.describeRepo". 26 26 // 27 27 // repo: The handle or DID of the repo. 28 - func RepoDescribeRepo(ctx context.Context, c util.LexClient, repo string) (*RepoDescribeRepo_Output, error) { 28 + func RepoDescribeRepo(ctx context.Context, c lexutil.LexClient, repo string) (*RepoDescribeRepo_Output, error) { 29 29 var out RepoDescribeRepo_Output 30 30 31 31 params := map[string]interface{}{} 32 32 params["repo"] = repo 33 - if err := c.LexDo(ctx, util.Query, "", "com.atproto.repo.describeRepo", params, nil, &out); err != nil { 33 + if err := c.LexDo(ctx, lexutil.Query, "", "com.atproto.repo.describeRepo", params, nil, &out); err != nil { 34 34 return nil, err 35 35 } 36 36
+6 -6
api/atproto/repogetRecord.go
··· 7 7 import ( 8 8 "context" 9 9 10 - "github.com/bluesky-social/indigo/lex/util" 10 + lexutil "github.com/bluesky-social/indigo/lex/util" 11 11 ) 12 12 13 13 // RepoGetRecord_Output is the output of a com.atproto.repo.getRecord call. 14 14 type RepoGetRecord_Output struct { 15 - Cid *string `json:"cid,omitempty" cborgen:"cid,omitempty"` 16 - Uri string `json:"uri" cborgen:"uri"` 17 - Value *util.LexiconTypeDecoder `json:"value" cborgen:"value"` 15 + Cid *string `json:"cid,omitempty" cborgen:"cid,omitempty"` 16 + Uri string `json:"uri" cborgen:"uri"` 17 + Value *lexutil.LexiconTypeDecoder `json:"value" cborgen:"value"` 18 18 } 19 19 20 20 // RepoGetRecord calls the XRPC method "com.atproto.repo.getRecord". ··· 23 23 // collection: The NSID of the record collection. 24 24 // repo: The handle or DID of the repo. 25 25 // rkey: The Record Key. 26 - func RepoGetRecord(ctx context.Context, c util.LexClient, cid string, collection string, repo string, rkey string) (*RepoGetRecord_Output, error) { 26 + func RepoGetRecord(ctx context.Context, c lexutil.LexClient, cid string, collection string, repo string, rkey string) (*RepoGetRecord_Output, error) { 27 27 var out RepoGetRecord_Output 28 28 29 29 params := map[string]interface{}{} ··· 33 33 params["collection"] = collection 34 34 params["repo"] = repo 35 35 params["rkey"] = rkey 36 - if err := c.LexDo(ctx, util.Query, "", "com.atproto.repo.getRecord", params, nil, &out); err != nil { 36 + if err := c.LexDo(ctx, lexutil.Query, "", "com.atproto.repo.getRecord", params, nil, &out); err != nil { 37 37 return nil, err 38 38 } 39 39
+3 -3
api/atproto/repoimportRepo.go
··· 8 8 "context" 9 9 "io" 10 10 11 - "github.com/bluesky-social/indigo/lex/util" 11 + lexutil "github.com/bluesky-social/indigo/lex/util" 12 12 ) 13 13 14 14 // RepoImportRepo calls the XRPC method "com.atproto.repo.importRepo". 15 - func RepoImportRepo(ctx context.Context, c util.LexClient, input io.Reader) error { 16 - if err := c.LexDo(ctx, util.Procedure, "application/vnd.ipld.car", "com.atproto.repo.importRepo", nil, input, nil); err != nil { 15 + func RepoImportRepo(ctx context.Context, c lexutil.LexClient, input io.Reader) error { 16 + if err := c.LexDo(ctx, lexutil.Procedure, "application/vnd.ipld.car", "com.atproto.repo.importRepo", nil, input, nil); err != nil { 17 17 return err 18 18 } 19 19
+3 -3
api/atproto/repolistMissingBlobs.go
··· 7 7 import ( 8 8 "context" 9 9 10 - "github.com/bluesky-social/indigo/lex/util" 10 + lexutil "github.com/bluesky-social/indigo/lex/util" 11 11 ) 12 12 13 13 // RepoListMissingBlobs_Output is the output of a com.atproto.repo.listMissingBlobs call. ··· 23 23 } 24 24 25 25 // RepoListMissingBlobs calls the XRPC method "com.atproto.repo.listMissingBlobs". 26 - func RepoListMissingBlobs(ctx context.Context, c util.LexClient, cursor string, limit int64) (*RepoListMissingBlobs_Output, error) { 26 + func RepoListMissingBlobs(ctx context.Context, c lexutil.LexClient, cursor string, limit int64) (*RepoListMissingBlobs_Output, error) { 27 27 var out RepoListMissingBlobs_Output 28 28 29 29 params := map[string]interface{}{} ··· 33 33 if limit != 0 { 34 34 params["limit"] = limit 35 35 } 36 - if err := c.LexDo(ctx, util.Query, "", "com.atproto.repo.listMissingBlobs", params, nil, &out); err != nil { 36 + if err := c.LexDo(ctx, lexutil.Query, "", "com.atproto.repo.listMissingBlobs", params, nil, &out); err != nil { 37 37 return nil, err 38 38 } 39 39
+6 -6
api/atproto/repolistRecords.go
··· 7 7 import ( 8 8 "context" 9 9 10 - "github.com/bluesky-social/indigo/lex/util" 10 + lexutil "github.com/bluesky-social/indigo/lex/util" 11 11 ) 12 12 13 13 // RepoListRecords_Output is the output of a com.atproto.repo.listRecords call. ··· 18 18 19 19 // RepoListRecords_Record is a "record" in the com.atproto.repo.listRecords schema. 20 20 type RepoListRecords_Record struct { 21 - Cid string `json:"cid" cborgen:"cid"` 22 - Uri string `json:"uri" cborgen:"uri"` 23 - Value *util.LexiconTypeDecoder `json:"value" cborgen:"value"` 21 + Cid string `json:"cid" cborgen:"cid"` 22 + Uri string `json:"uri" cborgen:"uri"` 23 + Value *lexutil.LexiconTypeDecoder `json:"value" cborgen:"value"` 24 24 } 25 25 26 26 // RepoListRecords calls the XRPC method "com.atproto.repo.listRecords". ··· 29 29 // limit: The number of records to return. 30 30 // repo: The handle or DID of the repo. 31 31 // reverse: Flag to reverse the order of the returned records. 32 - func RepoListRecords(ctx context.Context, c util.LexClient, collection string, cursor string, limit int64, repo string, reverse bool) (*RepoListRecords_Output, error) { 32 + func RepoListRecords(ctx context.Context, c lexutil.LexClient, collection string, cursor string, limit int64, repo string, reverse bool) (*RepoListRecords_Output, error) { 33 33 var out RepoListRecords_Output 34 34 35 35 params := map[string]interface{}{} ··· 44 44 if reverse { 45 45 params["reverse"] = reverse 46 46 } 47 - if err := c.LexDo(ctx, util.Query, "", "com.atproto.repo.listRecords", params, nil, &out); err != nil { 47 + if err := c.LexDo(ctx, lexutil.Query, "", "com.atproto.repo.listRecords", params, nil, &out); err != nil { 48 48 return nil, err 49 49 } 50 50
+4 -4
api/atproto/repoputRecord.go
··· 7 7 import ( 8 8 "context" 9 9 10 - "github.com/bluesky-social/indigo/lex/util" 10 + lexutil "github.com/bluesky-social/indigo/lex/util" 11 11 ) 12 12 13 13 // RepoPutRecord_Input is the input argument to a com.atproto.repo.putRecord call. ··· 15 15 // collection: The NSID of the record collection. 16 16 Collection string `json:"collection" cborgen:"collection"` 17 17 // record: The record to write. 18 - Record *util.LexiconTypeDecoder `json:"record" cborgen:"record"` 18 + Record *lexutil.LexiconTypeDecoder `json:"record" cborgen:"record"` 19 19 // repo: The handle or DID of the repo (aka, current account). 20 20 Repo string `json:"repo" cborgen:"repo"` 21 21 // rkey: The Record Key. ··· 37 37 } 38 38 39 39 // RepoPutRecord calls the XRPC method "com.atproto.repo.putRecord". 40 - func RepoPutRecord(ctx context.Context, c util.LexClient, input *RepoPutRecord_Input) (*RepoPutRecord_Output, error) { 40 + func RepoPutRecord(ctx context.Context, c lexutil.LexClient, input *RepoPutRecord_Input) (*RepoPutRecord_Output, error) { 41 41 var out RepoPutRecord_Output 42 - if err := c.LexDo(ctx, util.Procedure, "application/json", "com.atproto.repo.putRecord", nil, input, &out); err != nil { 42 + if err := c.LexDo(ctx, lexutil.Procedure, "application/json", "com.atproto.repo.putRecord", nil, input, &out); err != nil { 43 43 return nil, err 44 44 } 45 45
+2 -2
api/atproto/repostrongRef.go
··· 5 5 package atproto 6 6 7 7 import ( 8 - "github.com/bluesky-social/indigo/lex/util" 8 + lexutil "github.com/bluesky-social/indigo/lex/util" 9 9 ) 10 10 11 11 func init() { 12 - util.RegisterType("com.atproto.repo.strongRef#main", &RepoStrongRef{}) 12 + lexutil.RegisterType("com.atproto.repo.strongRef#main", &RepoStrongRef{}) 13 13 } 14 14 15 15 // RepoStrongRef is a "main" in the com.atproto.repo.strongRef schema.
+4 -4
api/atproto/repouploadBlob.go
··· 8 8 "context" 9 9 "io" 10 10 11 - "github.com/bluesky-social/indigo/lex/util" 11 + lexutil "github.com/bluesky-social/indigo/lex/util" 12 12 ) 13 13 14 14 // RepoUploadBlob_Output is the output of a com.atproto.repo.uploadBlob call. 15 15 type RepoUploadBlob_Output struct { 16 - Blob *util.LexBlob `json:"blob" cborgen:"blob"` 16 + Blob *lexutil.LexBlob `json:"blob" cborgen:"blob"` 17 17 } 18 18 19 19 // RepoUploadBlob calls the XRPC method "com.atproto.repo.uploadBlob". 20 - func RepoUploadBlob(ctx context.Context, c util.LexClient, input io.Reader) (*RepoUploadBlob_Output, error) { 20 + func RepoUploadBlob(ctx context.Context, c lexutil.LexClient, input io.Reader) (*RepoUploadBlob_Output, error) { 21 21 var out RepoUploadBlob_Output 22 - if err := c.LexDo(ctx, util.Procedure, "*/*", "com.atproto.repo.uploadBlob", nil, input, &out); err != nil { 22 + if err := c.LexDo(ctx, lexutil.Procedure, "*/*", "com.atproto.repo.uploadBlob", nil, input, &out); err != nil { 23 23 return nil, err 24 24 } 25 25
+3 -3
api/atproto/serveractivateAccount.go
··· 7 7 import ( 8 8 "context" 9 9 10 - "github.com/bluesky-social/indigo/lex/util" 10 + lexutil "github.com/bluesky-social/indigo/lex/util" 11 11 ) 12 12 13 13 // ServerActivateAccount calls the XRPC method "com.atproto.server.activateAccount". 14 - func ServerActivateAccount(ctx context.Context, c util.LexClient) error { 15 - if err := c.LexDo(ctx, util.Procedure, "", "com.atproto.server.activateAccount", nil, nil, nil); err != nil { 14 + func ServerActivateAccount(ctx context.Context, c lexutil.LexClient) error { 15 + if err := c.LexDo(ctx, lexutil.Procedure, "", "com.atproto.server.activateAccount", nil, nil, nil); err != nil { 16 16 return err 17 17 } 18 18
+3 -3
api/atproto/servercheckAccountStatus.go
··· 7 7 import ( 8 8 "context" 9 9 10 - "github.com/bluesky-social/indigo/lex/util" 10 + lexutil "github.com/bluesky-social/indigo/lex/util" 11 11 ) 12 12 13 13 // ServerCheckAccountStatus_Output is the output of a com.atproto.server.checkAccountStatus call. ··· 24 24 } 25 25 26 26 // ServerCheckAccountStatus calls the XRPC method "com.atproto.server.checkAccountStatus". 27 - func ServerCheckAccountStatus(ctx context.Context, c util.LexClient) (*ServerCheckAccountStatus_Output, error) { 27 + func ServerCheckAccountStatus(ctx context.Context, c lexutil.LexClient) (*ServerCheckAccountStatus_Output, error) { 28 28 var out ServerCheckAccountStatus_Output 29 - if err := c.LexDo(ctx, util.Query, "", "com.atproto.server.checkAccountStatus", nil, nil, &out); err != nil { 29 + if err := c.LexDo(ctx, lexutil.Query, "", "com.atproto.server.checkAccountStatus", nil, nil, &out); err != nil { 30 30 return nil, err 31 31 } 32 32
+3 -3
api/atproto/serverconfirmEmail.go
··· 7 7 import ( 8 8 "context" 9 9 10 - "github.com/bluesky-social/indigo/lex/util" 10 + lexutil "github.com/bluesky-social/indigo/lex/util" 11 11 ) 12 12 13 13 // ServerConfirmEmail_Input is the input argument to a com.atproto.server.confirmEmail call. ··· 17 17 } 18 18 19 19 // ServerConfirmEmail calls the XRPC method "com.atproto.server.confirmEmail". 20 - func ServerConfirmEmail(ctx context.Context, c util.LexClient, input *ServerConfirmEmail_Input) error { 21 - if err := c.LexDo(ctx, util.Procedure, "application/json", "com.atproto.server.confirmEmail", nil, input, nil); err != nil { 20 + func ServerConfirmEmail(ctx context.Context, c lexutil.LexClient, input *ServerConfirmEmail_Input) error { 21 + if err := c.LexDo(ctx, lexutil.Procedure, "application/json", "com.atproto.server.confirmEmail", nil, input, nil); err != nil { 22 22 return err 23 23 } 24 24
+3 -3
api/atproto/servercreateAccount.go
··· 7 7 import ( 8 8 "context" 9 9 10 - "github.com/bluesky-social/indigo/lex/util" 10 + lexutil "github.com/bluesky-social/indigo/lex/util" 11 11 ) 12 12 13 13 // ServerCreateAccount_Input is the input argument to a com.atproto.server.createAccount call. ··· 42 42 } 43 43 44 44 // ServerCreateAccount calls the XRPC method "com.atproto.server.createAccount". 45 - func ServerCreateAccount(ctx context.Context, c util.LexClient, input *ServerCreateAccount_Input) (*ServerCreateAccount_Output, error) { 45 + func ServerCreateAccount(ctx context.Context, c lexutil.LexClient, input *ServerCreateAccount_Input) (*ServerCreateAccount_Output, error) { 46 46 var out ServerCreateAccount_Output 47 - if err := c.LexDo(ctx, util.Procedure, "application/json", "com.atproto.server.createAccount", nil, input, &out); err != nil { 47 + if err := c.LexDo(ctx, lexutil.Procedure, "application/json", "com.atproto.server.createAccount", nil, input, &out); err != nil { 48 48 return nil, err 49 49 } 50 50
+3 -3
api/atproto/servercreateAppPassword.go
··· 7 7 import ( 8 8 "context" 9 9 10 - "github.com/bluesky-social/indigo/lex/util" 10 + lexutil "github.com/bluesky-social/indigo/lex/util" 11 11 ) 12 12 13 13 // ServerCreateAppPassword_AppPassword is a "appPassword" in the com.atproto.server.createAppPassword schema. ··· 27 27 } 28 28 29 29 // ServerCreateAppPassword calls the XRPC method "com.atproto.server.createAppPassword". 30 - func ServerCreateAppPassword(ctx context.Context, c util.LexClient, input *ServerCreateAppPassword_Input) (*ServerCreateAppPassword_AppPassword, error) { 30 + func ServerCreateAppPassword(ctx context.Context, c lexutil.LexClient, input *ServerCreateAppPassword_Input) (*ServerCreateAppPassword_AppPassword, error) { 31 31 var out ServerCreateAppPassword_AppPassword 32 - if err := c.LexDo(ctx, util.Procedure, "application/json", "com.atproto.server.createAppPassword", nil, input, &out); err != nil { 32 + if err := c.LexDo(ctx, lexutil.Procedure, "application/json", "com.atproto.server.createAppPassword", nil, input, &out); err != nil { 33 33 return nil, err 34 34 } 35 35
+3 -3
api/atproto/servercreateInviteCode.go
··· 7 7 import ( 8 8 "context" 9 9 10 - "github.com/bluesky-social/indigo/lex/util" 10 + lexutil "github.com/bluesky-social/indigo/lex/util" 11 11 ) 12 12 13 13 // ServerCreateInviteCode_Input is the input argument to a com.atproto.server.createInviteCode call. ··· 22 22 } 23 23 24 24 // ServerCreateInviteCode calls the XRPC method "com.atproto.server.createInviteCode". 25 - func ServerCreateInviteCode(ctx context.Context, c util.LexClient, input *ServerCreateInviteCode_Input) (*ServerCreateInviteCode_Output, error) { 25 + func ServerCreateInviteCode(ctx context.Context, c lexutil.LexClient, input *ServerCreateInviteCode_Input) (*ServerCreateInviteCode_Output, error) { 26 26 var out ServerCreateInviteCode_Output 27 - if err := c.LexDo(ctx, util.Procedure, "application/json", "com.atproto.server.createInviteCode", nil, input, &out); err != nil { 27 + if err := c.LexDo(ctx, lexutil.Procedure, "application/json", "com.atproto.server.createInviteCode", nil, input, &out); err != nil { 28 28 return nil, err 29 29 } 30 30
+3 -3
api/atproto/servercreateInviteCodes.go
··· 7 7 import ( 8 8 "context" 9 9 10 - "github.com/bluesky-social/indigo/lex/util" 10 + lexutil "github.com/bluesky-social/indigo/lex/util" 11 11 ) 12 12 13 13 // ServerCreateInviteCodes_AccountCodes is a "accountCodes" in the com.atproto.server.createInviteCodes schema. ··· 29 29 } 30 30 31 31 // ServerCreateInviteCodes calls the XRPC method "com.atproto.server.createInviteCodes". 32 - func ServerCreateInviteCodes(ctx context.Context, c util.LexClient, input *ServerCreateInviteCodes_Input) (*ServerCreateInviteCodes_Output, error) { 32 + func ServerCreateInviteCodes(ctx context.Context, c lexutil.LexClient, input *ServerCreateInviteCodes_Input) (*ServerCreateInviteCodes_Output, error) { 33 33 var out ServerCreateInviteCodes_Output 34 - if err := c.LexDo(ctx, util.Procedure, "application/json", "com.atproto.server.createInviteCodes", nil, input, &out); err != nil { 34 + if err := c.LexDo(ctx, lexutil.Procedure, "application/json", "com.atproto.server.createInviteCodes", nil, input, &out); err != nil { 35 35 return nil, err 36 36 } 37 37
+3 -3
api/atproto/servercreateSession.go
··· 7 7 import ( 8 8 "context" 9 9 10 - "github.com/bluesky-social/indigo/lex/util" 10 + lexutil "github.com/bluesky-social/indigo/lex/util" 11 11 ) 12 12 13 13 // ServerCreateSession_Input is the input argument to a com.atproto.server.createSession call. ··· 36 36 } 37 37 38 38 // ServerCreateSession calls the XRPC method "com.atproto.server.createSession". 39 - func ServerCreateSession(ctx context.Context, c util.LexClient, input *ServerCreateSession_Input) (*ServerCreateSession_Output, error) { 39 + func ServerCreateSession(ctx context.Context, c lexutil.LexClient, input *ServerCreateSession_Input) (*ServerCreateSession_Output, error) { 40 40 var out ServerCreateSession_Output 41 - if err := c.LexDo(ctx, util.Procedure, "application/json", "com.atproto.server.createSession", nil, input, &out); err != nil { 41 + if err := c.LexDo(ctx, lexutil.Procedure, "application/json", "com.atproto.server.createSession", nil, input, &out); err != nil { 42 42 return nil, err 43 43 } 44 44
+3 -3
api/atproto/serverdeactivateAccount.go
··· 7 7 import ( 8 8 "context" 9 9 10 - "github.com/bluesky-social/indigo/lex/util" 10 + lexutil "github.com/bluesky-social/indigo/lex/util" 11 11 ) 12 12 13 13 // ServerDeactivateAccount_Input is the input argument to a com.atproto.server.deactivateAccount call. ··· 17 17 } 18 18 19 19 // ServerDeactivateAccount calls the XRPC method "com.atproto.server.deactivateAccount". 20 - func ServerDeactivateAccount(ctx context.Context, c util.LexClient, input *ServerDeactivateAccount_Input) error { 21 - if err := c.LexDo(ctx, util.Procedure, "application/json", "com.atproto.server.deactivateAccount", nil, input, nil); err != nil { 20 + func ServerDeactivateAccount(ctx context.Context, c lexutil.LexClient, input *ServerDeactivateAccount_Input) error { 21 + if err := c.LexDo(ctx, lexutil.Procedure, "application/json", "com.atproto.server.deactivateAccount", nil, input, nil); err != nil { 22 22 return err 23 23 } 24 24
+3 -3
api/atproto/serverdeleteAccount.go
··· 7 7 import ( 8 8 "context" 9 9 10 - "github.com/bluesky-social/indigo/lex/util" 10 + lexutil "github.com/bluesky-social/indigo/lex/util" 11 11 ) 12 12 13 13 // ServerDeleteAccount_Input is the input argument to a com.atproto.server.deleteAccount call. ··· 18 18 } 19 19 20 20 // ServerDeleteAccount calls the XRPC method "com.atproto.server.deleteAccount". 21 - func ServerDeleteAccount(ctx context.Context, c util.LexClient, input *ServerDeleteAccount_Input) error { 22 - if err := c.LexDo(ctx, util.Procedure, "application/json", "com.atproto.server.deleteAccount", nil, input, nil); err != nil { 21 + func ServerDeleteAccount(ctx context.Context, c lexutil.LexClient, input *ServerDeleteAccount_Input) error { 22 + if err := c.LexDo(ctx, lexutil.Procedure, "application/json", "com.atproto.server.deleteAccount", nil, input, nil); err != nil { 23 23 return err 24 24 } 25 25
+3 -3
api/atproto/serverdeleteSession.go
··· 7 7 import ( 8 8 "context" 9 9 10 - "github.com/bluesky-social/indigo/lex/util" 10 + lexutil "github.com/bluesky-social/indigo/lex/util" 11 11 ) 12 12 13 13 // ServerDeleteSession calls the XRPC method "com.atproto.server.deleteSession". 14 - func ServerDeleteSession(ctx context.Context, c util.LexClient) error { 15 - if err := c.LexDo(ctx, util.Procedure, "", "com.atproto.server.deleteSession", nil, nil, nil); err != nil { 14 + func ServerDeleteSession(ctx context.Context, c lexutil.LexClient) error { 15 + if err := c.LexDo(ctx, lexutil.Procedure, "", "com.atproto.server.deleteSession", nil, nil, nil); err != nil { 16 16 return err 17 17 } 18 18
+3 -3
api/atproto/serverdescribeServer.go
··· 7 7 import ( 8 8 "context" 9 9 10 - "github.com/bluesky-social/indigo/lex/util" 10 + lexutil "github.com/bluesky-social/indigo/lex/util" 11 11 ) 12 12 13 13 // ServerDescribeServer_Contact is a "contact" in the com.atproto.server.describeServer schema. ··· 37 37 } 38 38 39 39 // ServerDescribeServer calls the XRPC method "com.atproto.server.describeServer". 40 - func ServerDescribeServer(ctx context.Context, c util.LexClient) (*ServerDescribeServer_Output, error) { 40 + func ServerDescribeServer(ctx context.Context, c lexutil.LexClient) (*ServerDescribeServer_Output, error) { 41 41 var out ServerDescribeServer_Output 42 - if err := c.LexDo(ctx, util.Query, "", "com.atproto.server.describeServer", nil, nil, &out); err != nil { 42 + if err := c.LexDo(ctx, lexutil.Query, "", "com.atproto.server.describeServer", nil, nil, &out); err != nil { 43 43 return nil, err 44 44 } 45 45
+3 -3
api/atproto/servergetAccountInviteCodes.go
··· 7 7 import ( 8 8 "context" 9 9 10 - "github.com/bluesky-social/indigo/lex/util" 10 + lexutil "github.com/bluesky-social/indigo/lex/util" 11 11 ) 12 12 13 13 // ServerGetAccountInviteCodes_Output is the output of a com.atproto.server.getAccountInviteCodes call. ··· 18 18 // ServerGetAccountInviteCodes calls the XRPC method "com.atproto.server.getAccountInviteCodes". 19 19 // 20 20 // createAvailable: Controls whether any new 'earned' but not 'created' invites should be created. 21 - func ServerGetAccountInviteCodes(ctx context.Context, c util.LexClient, createAvailable bool, includeUsed bool) (*ServerGetAccountInviteCodes_Output, error) { 21 + func ServerGetAccountInviteCodes(ctx context.Context, c lexutil.LexClient, createAvailable bool, includeUsed bool) (*ServerGetAccountInviteCodes_Output, error) { 22 22 var out ServerGetAccountInviteCodes_Output 23 23 24 24 params := map[string]interface{}{} ··· 28 28 if includeUsed { 29 29 params["includeUsed"] = includeUsed 30 30 } 31 - if err := c.LexDo(ctx, util.Query, "", "com.atproto.server.getAccountInviteCodes", params, nil, &out); err != nil { 31 + if err := c.LexDo(ctx, lexutil.Query, "", "com.atproto.server.getAccountInviteCodes", params, nil, &out); err != nil { 32 32 return nil, err 33 33 } 34 34
+3 -3
api/atproto/servergetServiceAuth.go
··· 7 7 import ( 8 8 "context" 9 9 10 - "github.com/bluesky-social/indigo/lex/util" 10 + lexutil "github.com/bluesky-social/indigo/lex/util" 11 11 ) 12 12 13 13 // ServerGetServiceAuth_Output is the output of a com.atproto.server.getServiceAuth call. ··· 20 20 // aud: The DID of the service that the token will be used to authenticate with 21 21 // exp: The time in Unix Epoch seconds that the JWT expires. Defaults to 60 seconds in the future. The service may enforce certain time bounds on tokens depending on the requested scope. 22 22 // lxm: Lexicon (XRPC) method to bind the requested token to 23 - func ServerGetServiceAuth(ctx context.Context, c util.LexClient, aud string, exp int64, lxm string) (*ServerGetServiceAuth_Output, error) { 23 + func ServerGetServiceAuth(ctx context.Context, c lexutil.LexClient, aud string, exp int64, lxm string) (*ServerGetServiceAuth_Output, error) { 24 24 var out ServerGetServiceAuth_Output 25 25 26 26 params := map[string]interface{}{} ··· 31 31 if lxm != "" { 32 32 params["lxm"] = lxm 33 33 } 34 - if err := c.LexDo(ctx, util.Query, "", "com.atproto.server.getServiceAuth", params, nil, &out); err != nil { 34 + if err := c.LexDo(ctx, lexutil.Query, "", "com.atproto.server.getServiceAuth", params, nil, &out); err != nil { 35 35 return nil, err 36 36 } 37 37
+3 -3
api/atproto/servergetSession.go
··· 7 7 import ( 8 8 "context" 9 9 10 - "github.com/bluesky-social/indigo/lex/util" 10 + lexutil "github.com/bluesky-social/indigo/lex/util" 11 11 ) 12 12 13 13 // ServerGetSession_Output is the output of a com.atproto.server.getSession call. ··· 24 24 } 25 25 26 26 // ServerGetSession calls the XRPC method "com.atproto.server.getSession". 27 - func ServerGetSession(ctx context.Context, c util.LexClient) (*ServerGetSession_Output, error) { 27 + func ServerGetSession(ctx context.Context, c lexutil.LexClient) (*ServerGetSession_Output, error) { 28 28 var out ServerGetSession_Output 29 - if err := c.LexDo(ctx, util.Query, "", "com.atproto.server.getSession", nil, nil, &out); err != nil { 29 + if err := c.LexDo(ctx, lexutil.Query, "", "com.atproto.server.getSession", nil, nil, &out); err != nil { 30 30 return nil, err 31 31 } 32 32
+3 -3
api/atproto/serverlistAppPasswords.go
··· 7 7 import ( 8 8 "context" 9 9 10 - "github.com/bluesky-social/indigo/lex/util" 10 + lexutil "github.com/bluesky-social/indigo/lex/util" 11 11 ) 12 12 13 13 // ServerListAppPasswords_AppPassword is a "appPassword" in the com.atproto.server.listAppPasswords schema. ··· 23 23 } 24 24 25 25 // ServerListAppPasswords calls the XRPC method "com.atproto.server.listAppPasswords". 26 - func ServerListAppPasswords(ctx context.Context, c util.LexClient) (*ServerListAppPasswords_Output, error) { 26 + func ServerListAppPasswords(ctx context.Context, c lexutil.LexClient) (*ServerListAppPasswords_Output, error) { 27 27 var out ServerListAppPasswords_Output 28 - if err := c.LexDo(ctx, util.Query, "", "com.atproto.server.listAppPasswords", nil, nil, &out); err != nil { 28 + if err := c.LexDo(ctx, lexutil.Query, "", "com.atproto.server.listAppPasswords", nil, nil, &out); err != nil { 29 29 return nil, err 30 30 } 31 31
+3 -3
api/atproto/serverrefreshSession.go
··· 7 7 import ( 8 8 "context" 9 9 10 - "github.com/bluesky-social/indigo/lex/util" 10 + lexutil "github.com/bluesky-social/indigo/lex/util" 11 11 ) 12 12 13 13 // ServerRefreshSession_Output is the output of a com.atproto.server.refreshSession call. ··· 23 23 } 24 24 25 25 // ServerRefreshSession calls the XRPC method "com.atproto.server.refreshSession". 26 - func ServerRefreshSession(ctx context.Context, c util.LexClient) (*ServerRefreshSession_Output, error) { 26 + func ServerRefreshSession(ctx context.Context, c lexutil.LexClient) (*ServerRefreshSession_Output, error) { 27 27 var out ServerRefreshSession_Output 28 - if err := c.LexDo(ctx, util.Procedure, "", "com.atproto.server.refreshSession", nil, nil, &out); err != nil { 28 + if err := c.LexDo(ctx, lexutil.Procedure, "", "com.atproto.server.refreshSession", nil, nil, &out); err != nil { 29 29 return nil, err 30 30 } 31 31
+3 -3
api/atproto/serverrequestAccountDelete.go
··· 7 7 import ( 8 8 "context" 9 9 10 - "github.com/bluesky-social/indigo/lex/util" 10 + lexutil "github.com/bluesky-social/indigo/lex/util" 11 11 ) 12 12 13 13 // ServerRequestAccountDelete calls the XRPC method "com.atproto.server.requestAccountDelete". 14 - func ServerRequestAccountDelete(ctx context.Context, c util.LexClient) error { 15 - if err := c.LexDo(ctx, util.Procedure, "", "com.atproto.server.requestAccountDelete", nil, nil, nil); err != nil { 14 + func ServerRequestAccountDelete(ctx context.Context, c lexutil.LexClient) error { 15 + if err := c.LexDo(ctx, lexutil.Procedure, "", "com.atproto.server.requestAccountDelete", nil, nil, nil); err != nil { 16 16 return err 17 17 } 18 18
+3 -3
api/atproto/serverrequestEmailConfirmation.go
··· 7 7 import ( 8 8 "context" 9 9 10 - "github.com/bluesky-social/indigo/lex/util" 10 + lexutil "github.com/bluesky-social/indigo/lex/util" 11 11 ) 12 12 13 13 // ServerRequestEmailConfirmation calls the XRPC method "com.atproto.server.requestEmailConfirmation". 14 - func ServerRequestEmailConfirmation(ctx context.Context, c util.LexClient) error { 15 - if err := c.LexDo(ctx, util.Procedure, "", "com.atproto.server.requestEmailConfirmation", nil, nil, nil); err != nil { 14 + func ServerRequestEmailConfirmation(ctx context.Context, c lexutil.LexClient) error { 15 + if err := c.LexDo(ctx, lexutil.Procedure, "", "com.atproto.server.requestEmailConfirmation", nil, nil, nil); err != nil { 16 16 return err 17 17 } 18 18
+3 -3
api/atproto/serverrequestEmailUpdate.go
··· 7 7 import ( 8 8 "context" 9 9 10 - "github.com/bluesky-social/indigo/lex/util" 10 + lexutil "github.com/bluesky-social/indigo/lex/util" 11 11 ) 12 12 13 13 // ServerRequestEmailUpdate_Output is the output of a com.atproto.server.requestEmailUpdate call. ··· 16 16 } 17 17 18 18 // ServerRequestEmailUpdate calls the XRPC method "com.atproto.server.requestEmailUpdate". 19 - func ServerRequestEmailUpdate(ctx context.Context, c util.LexClient) (*ServerRequestEmailUpdate_Output, error) { 19 + func ServerRequestEmailUpdate(ctx context.Context, c lexutil.LexClient) (*ServerRequestEmailUpdate_Output, error) { 20 20 var out ServerRequestEmailUpdate_Output 21 - if err := c.LexDo(ctx, util.Procedure, "", "com.atproto.server.requestEmailUpdate", nil, nil, &out); err != nil { 21 + if err := c.LexDo(ctx, lexutil.Procedure, "", "com.atproto.server.requestEmailUpdate", nil, nil, &out); err != nil { 22 22 return nil, err 23 23 } 24 24
+3 -3
api/atproto/serverrequestPasswordReset.go
··· 7 7 import ( 8 8 "context" 9 9 10 - "github.com/bluesky-social/indigo/lex/util" 10 + lexutil "github.com/bluesky-social/indigo/lex/util" 11 11 ) 12 12 13 13 // ServerRequestPasswordReset_Input is the input argument to a com.atproto.server.requestPasswordReset call. ··· 16 16 } 17 17 18 18 // ServerRequestPasswordReset calls the XRPC method "com.atproto.server.requestPasswordReset". 19 - func ServerRequestPasswordReset(ctx context.Context, c util.LexClient, input *ServerRequestPasswordReset_Input) error { 20 - if err := c.LexDo(ctx, util.Procedure, "application/json", "com.atproto.server.requestPasswordReset", nil, input, nil); err != nil { 19 + func ServerRequestPasswordReset(ctx context.Context, c lexutil.LexClient, input *ServerRequestPasswordReset_Input) error { 20 + if err := c.LexDo(ctx, lexutil.Procedure, "application/json", "com.atproto.server.requestPasswordReset", nil, input, nil); err != nil { 21 21 return err 22 22 } 23 23
+3 -3
api/atproto/serverreserveSigningKey.go
··· 7 7 import ( 8 8 "context" 9 9 10 - "github.com/bluesky-social/indigo/lex/util" 10 + lexutil "github.com/bluesky-social/indigo/lex/util" 11 11 ) 12 12 13 13 // ServerReserveSigningKey_Input is the input argument to a com.atproto.server.reserveSigningKey call. ··· 23 23 } 24 24 25 25 // ServerReserveSigningKey calls the XRPC method "com.atproto.server.reserveSigningKey". 26 - func ServerReserveSigningKey(ctx context.Context, c util.LexClient, input *ServerReserveSigningKey_Input) (*ServerReserveSigningKey_Output, error) { 26 + func ServerReserveSigningKey(ctx context.Context, c lexutil.LexClient, input *ServerReserveSigningKey_Input) (*ServerReserveSigningKey_Output, error) { 27 27 var out ServerReserveSigningKey_Output 28 - if err := c.LexDo(ctx, util.Procedure, "application/json", "com.atproto.server.reserveSigningKey", nil, input, &out); err != nil { 28 + if err := c.LexDo(ctx, lexutil.Procedure, "application/json", "com.atproto.server.reserveSigningKey", nil, input, &out); err != nil { 29 29 return nil, err 30 30 } 31 31
+3 -3
api/atproto/serverresetPassword.go
··· 7 7 import ( 8 8 "context" 9 9 10 - "github.com/bluesky-social/indigo/lex/util" 10 + lexutil "github.com/bluesky-social/indigo/lex/util" 11 11 ) 12 12 13 13 // ServerResetPassword_Input is the input argument to a com.atproto.server.resetPassword call. ··· 17 17 } 18 18 19 19 // ServerResetPassword calls the XRPC method "com.atproto.server.resetPassword". 20 - func ServerResetPassword(ctx context.Context, c util.LexClient, input *ServerResetPassword_Input) error { 21 - if err := c.LexDo(ctx, util.Procedure, "application/json", "com.atproto.server.resetPassword", nil, input, nil); err != nil { 20 + func ServerResetPassword(ctx context.Context, c lexutil.LexClient, input *ServerResetPassword_Input) error { 21 + if err := c.LexDo(ctx, lexutil.Procedure, "application/json", "com.atproto.server.resetPassword", nil, input, nil); err != nil { 22 22 return err 23 23 } 24 24
+3 -3
api/atproto/serverrevokeAppPassword.go
··· 7 7 import ( 8 8 "context" 9 9 10 - "github.com/bluesky-social/indigo/lex/util" 10 + lexutil "github.com/bluesky-social/indigo/lex/util" 11 11 ) 12 12 13 13 // ServerRevokeAppPassword_Input is the input argument to a com.atproto.server.revokeAppPassword call. ··· 16 16 } 17 17 18 18 // ServerRevokeAppPassword calls the XRPC method "com.atproto.server.revokeAppPassword". 19 - func ServerRevokeAppPassword(ctx context.Context, c util.LexClient, input *ServerRevokeAppPassword_Input) error { 20 - if err := c.LexDo(ctx, util.Procedure, "application/json", "com.atproto.server.revokeAppPassword", nil, input, nil); err != nil { 19 + func ServerRevokeAppPassword(ctx context.Context, c lexutil.LexClient, input *ServerRevokeAppPassword_Input) error { 20 + if err := c.LexDo(ctx, lexutil.Procedure, "application/json", "com.atproto.server.revokeAppPassword", nil, input, nil); err != nil { 21 21 return err 22 22 } 23 23
+3 -3
api/atproto/serverupdateEmail.go
··· 7 7 import ( 8 8 "context" 9 9 10 - "github.com/bluesky-social/indigo/lex/util" 10 + lexutil "github.com/bluesky-social/indigo/lex/util" 11 11 ) 12 12 13 13 // ServerUpdateEmail_Input is the input argument to a com.atproto.server.updateEmail call. ··· 19 19 } 20 20 21 21 // ServerUpdateEmail calls the XRPC method "com.atproto.server.updateEmail". 22 - func ServerUpdateEmail(ctx context.Context, c util.LexClient, input *ServerUpdateEmail_Input) error { 23 - if err := c.LexDo(ctx, util.Procedure, "application/json", "com.atproto.server.updateEmail", nil, input, nil); err != nil { 22 + func ServerUpdateEmail(ctx context.Context, c lexutil.LexClient, input *ServerUpdateEmail_Input) error { 23 + if err := c.LexDo(ctx, lexutil.Procedure, "application/json", "com.atproto.server.updateEmail", nil, input, nil); err != nil { 24 24 return err 25 25 } 26 26
+3 -3
api/atproto/syncgetBlob.go
··· 8 8 "bytes" 9 9 "context" 10 10 11 - "github.com/bluesky-social/indigo/lex/util" 11 + lexutil "github.com/bluesky-social/indigo/lex/util" 12 12 ) 13 13 14 14 // SyncGetBlob calls the XRPC method "com.atproto.sync.getBlob". 15 15 // 16 16 // cid: The CID of the blob to fetch 17 17 // did: The DID of the account. 18 - func SyncGetBlob(ctx context.Context, c util.LexClient, cid string, did string) ([]byte, error) { 18 + func SyncGetBlob(ctx context.Context, c lexutil.LexClient, cid string, did string) ([]byte, error) { 19 19 buf := new(bytes.Buffer) 20 20 21 21 params := map[string]interface{}{} 22 22 params["cid"] = cid 23 23 params["did"] = did 24 - if err := c.LexDo(ctx, util.Query, "", "com.atproto.sync.getBlob", params, nil, buf); err != nil { 24 + if err := c.LexDo(ctx, lexutil.Query, "", "com.atproto.sync.getBlob", params, nil, buf); err != nil { 25 25 return nil, err 26 26 } 27 27
+3 -3
api/atproto/syncgetBlocks.go
··· 8 8 "bytes" 9 9 "context" 10 10 11 - "github.com/bluesky-social/indigo/lex/util" 11 + lexutil "github.com/bluesky-social/indigo/lex/util" 12 12 ) 13 13 14 14 // SyncGetBlocks calls the XRPC method "com.atproto.sync.getBlocks". 15 15 // 16 16 // did: The DID of the repo. 17 - func SyncGetBlocks(ctx context.Context, c util.LexClient, cids []string, did string) ([]byte, error) { 17 + func SyncGetBlocks(ctx context.Context, c lexutil.LexClient, cids []string, did string) ([]byte, error) { 18 18 buf := new(bytes.Buffer) 19 19 20 20 params := map[string]interface{}{} 21 21 params["cids"] = cids 22 22 params["did"] = did 23 - if err := c.LexDo(ctx, util.Query, "", "com.atproto.sync.getBlocks", params, nil, buf); err != nil { 23 + if err := c.LexDo(ctx, lexutil.Query, "", "com.atproto.sync.getBlocks", params, nil, buf); err != nil { 24 24 return nil, err 25 25 } 26 26
+3 -3
api/atproto/syncgetCheckout.go
··· 8 8 "bytes" 9 9 "context" 10 10 11 - "github.com/bluesky-social/indigo/lex/util" 11 + lexutil "github.com/bluesky-social/indigo/lex/util" 12 12 ) 13 13 14 14 // SyncGetCheckout calls the XRPC method "com.atproto.sync.getCheckout". 15 15 // 16 16 // did: The DID of the repo. 17 - func SyncGetCheckout(ctx context.Context, c util.LexClient, did string) ([]byte, error) { 17 + func SyncGetCheckout(ctx context.Context, c lexutil.LexClient, did string) ([]byte, error) { 18 18 buf := new(bytes.Buffer) 19 19 20 20 params := map[string]interface{}{} 21 21 params["did"] = did 22 - if err := c.LexDo(ctx, util.Query, "", "com.atproto.sync.getCheckout", params, nil, buf); err != nil { 22 + if err := c.LexDo(ctx, lexutil.Query, "", "com.atproto.sync.getCheckout", params, nil, buf); err != nil { 23 23 return nil, err 24 24 } 25 25
+3 -3
api/atproto/syncgetHead.go
··· 7 7 import ( 8 8 "context" 9 9 10 - "github.com/bluesky-social/indigo/lex/util" 10 + lexutil "github.com/bluesky-social/indigo/lex/util" 11 11 ) 12 12 13 13 // SyncGetHead_Output is the output of a com.atproto.sync.getHead call. ··· 18 18 // SyncGetHead calls the XRPC method "com.atproto.sync.getHead". 19 19 // 20 20 // did: The DID of the repo. 21 - func SyncGetHead(ctx context.Context, c util.LexClient, did string) (*SyncGetHead_Output, error) { 21 + func SyncGetHead(ctx context.Context, c lexutil.LexClient, did string) (*SyncGetHead_Output, error) { 22 22 var out SyncGetHead_Output 23 23 24 24 params := map[string]interface{}{} 25 25 params["did"] = did 26 - if err := c.LexDo(ctx, util.Query, "", "com.atproto.sync.getHead", params, nil, &out); err != nil { 26 + if err := c.LexDo(ctx, lexutil.Query, "", "com.atproto.sync.getHead", params, nil, &out); err != nil { 27 27 return nil, err 28 28 } 29 29
+3 -3
api/atproto/syncgetHostStatus.go
··· 7 7 import ( 8 8 "context" 9 9 10 - "github.com/bluesky-social/indigo/lex/util" 10 + lexutil "github.com/bluesky-social/indigo/lex/util" 11 11 ) 12 12 13 13 // SyncGetHostStatus_Output is the output of a com.atproto.sync.getHostStatus call. ··· 23 23 // SyncGetHostStatus calls the XRPC method "com.atproto.sync.getHostStatus". 24 24 // 25 25 // hostname: Hostname of the host (eg, PDS or relay) being queried. 26 - func SyncGetHostStatus(ctx context.Context, c util.LexClient, hostname string) (*SyncGetHostStatus_Output, error) { 26 + func SyncGetHostStatus(ctx context.Context, c lexutil.LexClient, hostname string) (*SyncGetHostStatus_Output, error) { 27 27 var out SyncGetHostStatus_Output 28 28 29 29 params := map[string]interface{}{} 30 30 params["hostname"] = hostname 31 - if err := c.LexDo(ctx, util.Query, "", "com.atproto.sync.getHostStatus", params, nil, &out); err != nil { 31 + if err := c.LexDo(ctx, lexutil.Query, "", "com.atproto.sync.getHostStatus", params, nil, &out); err != nil { 32 32 return nil, err 33 33 } 34 34
+3 -3
api/atproto/syncgetLatestCommit.go
··· 7 7 import ( 8 8 "context" 9 9 10 - "github.com/bluesky-social/indigo/lex/util" 10 + lexutil "github.com/bluesky-social/indigo/lex/util" 11 11 ) 12 12 13 13 // SyncGetLatestCommit_Output is the output of a com.atproto.sync.getLatestCommit call. ··· 19 19 // SyncGetLatestCommit calls the XRPC method "com.atproto.sync.getLatestCommit". 20 20 // 21 21 // did: The DID of the repo. 22 - func SyncGetLatestCommit(ctx context.Context, c util.LexClient, did string) (*SyncGetLatestCommit_Output, error) { 22 + func SyncGetLatestCommit(ctx context.Context, c lexutil.LexClient, did string) (*SyncGetLatestCommit_Output, error) { 23 23 var out SyncGetLatestCommit_Output 24 24 25 25 params := map[string]interface{}{} 26 26 params["did"] = did 27 - if err := c.LexDo(ctx, util.Query, "", "com.atproto.sync.getLatestCommit", params, nil, &out); err != nil { 27 + if err := c.LexDo(ctx, lexutil.Query, "", "com.atproto.sync.getLatestCommit", params, nil, &out); err != nil { 28 28 return nil, err 29 29 } 30 30
+3 -3
api/atproto/syncgetRecord.go
··· 8 8 "bytes" 9 9 "context" 10 10 11 - "github.com/bluesky-social/indigo/lex/util" 11 + lexutil "github.com/bluesky-social/indigo/lex/util" 12 12 ) 13 13 14 14 // SyncGetRecord calls the XRPC method "com.atproto.sync.getRecord". 15 15 // 16 16 // did: The DID of the repo. 17 17 // rkey: Record Key 18 - func SyncGetRecord(ctx context.Context, c util.LexClient, collection string, did string, rkey string) ([]byte, error) { 18 + func SyncGetRecord(ctx context.Context, c lexutil.LexClient, collection string, did string, rkey string) ([]byte, error) { 19 19 buf := new(bytes.Buffer) 20 20 21 21 params := map[string]interface{}{} 22 22 params["collection"] = collection 23 23 params["did"] = did 24 24 params["rkey"] = rkey 25 - if err := c.LexDo(ctx, util.Query, "", "com.atproto.sync.getRecord", params, nil, buf); err != nil { 25 + if err := c.LexDo(ctx, lexutil.Query, "", "com.atproto.sync.getRecord", params, nil, buf); err != nil { 26 26 return nil, err 27 27 } 28 28
+3 -3
api/atproto/syncgetRepo.go
··· 8 8 "bytes" 9 9 "context" 10 10 11 - "github.com/bluesky-social/indigo/lex/util" 11 + lexutil "github.com/bluesky-social/indigo/lex/util" 12 12 ) 13 13 14 14 // SyncGetRepo calls the XRPC method "com.atproto.sync.getRepo". 15 15 // 16 16 // did: The DID of the repo. 17 17 // since: The revision ('rev') of the repo to create a diff from. 18 - func SyncGetRepo(ctx context.Context, c util.LexClient, did string, since string) ([]byte, error) { 18 + func SyncGetRepo(ctx context.Context, c lexutil.LexClient, did string, since string) ([]byte, error) { 19 19 buf := new(bytes.Buffer) 20 20 21 21 params := map[string]interface{}{} ··· 23 23 if since != "" { 24 24 params["since"] = since 25 25 } 26 - if err := c.LexDo(ctx, util.Query, "", "com.atproto.sync.getRepo", params, nil, buf); err != nil { 26 + if err := c.LexDo(ctx, lexutil.Query, "", "com.atproto.sync.getRepo", params, nil, buf); err != nil { 27 27 return nil, err 28 28 } 29 29
+3 -3
api/atproto/syncgetRepoStatus.go
··· 7 7 import ( 8 8 "context" 9 9 10 - "github.com/bluesky-social/indigo/lex/util" 10 + lexutil "github.com/bluesky-social/indigo/lex/util" 11 11 ) 12 12 13 13 // SyncGetRepoStatus_Output is the output of a com.atproto.sync.getRepoStatus call. ··· 23 23 // SyncGetRepoStatus calls the XRPC method "com.atproto.sync.getRepoStatus". 24 24 // 25 25 // did: The DID of the repo. 26 - func SyncGetRepoStatus(ctx context.Context, c util.LexClient, did string) (*SyncGetRepoStatus_Output, error) { 26 + func SyncGetRepoStatus(ctx context.Context, c lexutil.LexClient, did string) (*SyncGetRepoStatus_Output, error) { 27 27 var out SyncGetRepoStatus_Output 28 28 29 29 params := map[string]interface{}{} 30 30 params["did"] = did 31 - if err := c.LexDo(ctx, util.Query, "", "com.atproto.sync.getRepoStatus", params, nil, &out); err != nil { 31 + if err := c.LexDo(ctx, lexutil.Query, "", "com.atproto.sync.getRepoStatus", params, nil, &out); err != nil { 32 32 return nil, err 33 33 } 34 34
+3 -3
api/atproto/synclistBlobs.go
··· 7 7 import ( 8 8 "context" 9 9 10 - "github.com/bluesky-social/indigo/lex/util" 10 + lexutil "github.com/bluesky-social/indigo/lex/util" 11 11 ) 12 12 13 13 // SyncListBlobs_Output is the output of a com.atproto.sync.listBlobs call. ··· 20 20 // 21 21 // did: The DID of the repo. 22 22 // since: Optional revision of the repo to list blobs since. 23 - func SyncListBlobs(ctx context.Context, c util.LexClient, cursor string, did string, limit int64, since string) (*SyncListBlobs_Output, error) { 23 + func SyncListBlobs(ctx context.Context, c lexutil.LexClient, cursor string, did string, limit int64, since string) (*SyncListBlobs_Output, error) { 24 24 var out SyncListBlobs_Output 25 25 26 26 params := map[string]interface{}{} ··· 34 34 if since != "" { 35 35 params["since"] = since 36 36 } 37 - if err := c.LexDo(ctx, util.Query, "", "com.atproto.sync.listBlobs", params, nil, &out); err != nil { 37 + if err := c.LexDo(ctx, lexutil.Query, "", "com.atproto.sync.listBlobs", params, nil, &out); err != nil { 38 38 return nil, err 39 39 } 40 40
+3 -3
api/atproto/synclistHosts.go
··· 7 7 import ( 8 8 "context" 9 9 10 - "github.com/bluesky-social/indigo/lex/util" 10 + lexutil "github.com/bluesky-social/indigo/lex/util" 11 11 ) 12 12 13 13 // SyncListHosts_Host is a "host" in the com.atproto.sync.listHosts schema. ··· 28 28 } 29 29 30 30 // SyncListHosts calls the XRPC method "com.atproto.sync.listHosts". 31 - func SyncListHosts(ctx context.Context, c util.LexClient, cursor string, limit int64) (*SyncListHosts_Output, error) { 31 + func SyncListHosts(ctx context.Context, c lexutil.LexClient, cursor string, limit int64) (*SyncListHosts_Output, error) { 32 32 var out SyncListHosts_Output 33 33 34 34 params := map[string]interface{}{} ··· 38 38 if limit != 0 { 39 39 params["limit"] = limit 40 40 } 41 - if err := c.LexDo(ctx, util.Query, "", "com.atproto.sync.listHosts", params, nil, &out); err != nil { 41 + if err := c.LexDo(ctx, lexutil.Query, "", "com.atproto.sync.listHosts", params, nil, &out); err != nil { 42 42 return nil, err 43 43 } 44 44
+3 -3
api/atproto/synclistRepos.go
··· 7 7 import ( 8 8 "context" 9 9 10 - "github.com/bluesky-social/indigo/lex/util" 10 + lexutil "github.com/bluesky-social/indigo/lex/util" 11 11 ) 12 12 13 13 // SyncListRepos_Output is the output of a com.atproto.sync.listRepos call. ··· 28 28 } 29 29 30 30 // SyncListRepos calls the XRPC method "com.atproto.sync.listRepos". 31 - func SyncListRepos(ctx context.Context, c util.LexClient, cursor string, limit int64) (*SyncListRepos_Output, error) { 31 + func SyncListRepos(ctx context.Context, c lexutil.LexClient, cursor string, limit int64) (*SyncListRepos_Output, error) { 32 32 var out SyncListRepos_Output 33 33 34 34 params := map[string]interface{}{} ··· 38 38 if limit != 0 { 39 39 params["limit"] = limit 40 40 } 41 - if err := c.LexDo(ctx, util.Query, "", "com.atproto.sync.listRepos", params, nil, &out); err != nil { 41 + if err := c.LexDo(ctx, lexutil.Query, "", "com.atproto.sync.listRepos", params, nil, &out); err != nil { 42 42 return nil, err 43 43 } 44 44
+3 -3
api/atproto/synclistReposByCollection.go
··· 7 7 import ( 8 8 "context" 9 9 10 - "github.com/bluesky-social/indigo/lex/util" 10 + lexutil "github.com/bluesky-social/indigo/lex/util" 11 11 ) 12 12 13 13 // SyncListReposByCollection_Output is the output of a com.atproto.sync.listReposByCollection call. ··· 24 24 // SyncListReposByCollection calls the XRPC method "com.atproto.sync.listReposByCollection". 25 25 // 26 26 // limit: Maximum size of response set. Recommend setting a large maximum (1000+) when enumerating large DID lists. 27 - func SyncListReposByCollection(ctx context.Context, c util.LexClient, collection string, cursor string, limit int64) (*SyncListReposByCollection_Output, error) { 27 + func SyncListReposByCollection(ctx context.Context, c lexutil.LexClient, collection string, cursor string, limit int64) (*SyncListReposByCollection_Output, error) { 28 28 var out SyncListReposByCollection_Output 29 29 30 30 params := map[string]interface{}{} ··· 35 35 if limit != 0 { 36 36 params["limit"] = limit 37 37 } 38 - if err := c.LexDo(ctx, util.Query, "", "com.atproto.sync.listReposByCollection", params, nil, &out); err != nil { 38 + if err := c.LexDo(ctx, lexutil.Query, "", "com.atproto.sync.listReposByCollection", params, nil, &out); err != nil { 39 39 return nil, err 40 40 } 41 41
+3 -3
api/atproto/syncnotifyOfUpdate.go
··· 7 7 import ( 8 8 "context" 9 9 10 - "github.com/bluesky-social/indigo/lex/util" 10 + lexutil "github.com/bluesky-social/indigo/lex/util" 11 11 ) 12 12 13 13 // SyncNotifyOfUpdate_Input is the input argument to a com.atproto.sync.notifyOfUpdate call. ··· 17 17 } 18 18 19 19 // SyncNotifyOfUpdate calls the XRPC method "com.atproto.sync.notifyOfUpdate". 20 - func SyncNotifyOfUpdate(ctx context.Context, c util.LexClient, input *SyncNotifyOfUpdate_Input) error { 21 - if err := c.LexDo(ctx, util.Procedure, "application/json", "com.atproto.sync.notifyOfUpdate", nil, input, nil); err != nil { 20 + func SyncNotifyOfUpdate(ctx context.Context, c lexutil.LexClient, input *SyncNotifyOfUpdate_Input) error { 21 + if err := c.LexDo(ctx, lexutil.Procedure, "application/json", "com.atproto.sync.notifyOfUpdate", nil, input, nil); err != nil { 22 22 return err 23 23 } 24 24
+3 -3
api/atproto/syncrequestCrawl.go
··· 7 7 import ( 8 8 "context" 9 9 10 - "github.com/bluesky-social/indigo/lex/util" 10 + lexutil "github.com/bluesky-social/indigo/lex/util" 11 11 ) 12 12 13 13 // SyncRequestCrawl_Input is the input argument to a com.atproto.sync.requestCrawl call. ··· 17 17 } 18 18 19 19 // SyncRequestCrawl calls the XRPC method "com.atproto.sync.requestCrawl". 20 - func SyncRequestCrawl(ctx context.Context, c util.LexClient, input *SyncRequestCrawl_Input) error { 21 - if err := c.LexDo(ctx, util.Procedure, "application/json", "com.atproto.sync.requestCrawl", nil, input, nil); err != nil { 20 + func SyncRequestCrawl(ctx context.Context, c lexutil.LexClient, input *SyncRequestCrawl_Input) error { 21 + if err := c.LexDo(ctx, lexutil.Procedure, "application/json", "com.atproto.sync.requestCrawl", nil, input, nil); err != nil { 22 22 return err 23 23 } 24 24
+9 -9
api/atproto/syncsubscribeRepos.go
··· 5 5 package atproto 6 6 7 7 import ( 8 - "github.com/bluesky-social/indigo/lex/util" 8 + lexutil "github.com/bluesky-social/indigo/lex/util" 9 9 ) 10 10 11 11 // SyncSubscribeRepos_Account is a "account" in the com.atproto.sync.subscribeRepos schema. ··· 25 25 // 26 26 // Represents an update of repository state. Note that empty commits are allowed, which include no repo data changes, but an update to rev and signature. 27 27 type SyncSubscribeRepos_Commit struct { 28 - Blobs []util.LexLink `json:"blobs" cborgen:"blobs"` 28 + Blobs []lexutil.LexLink `json:"blobs" cborgen:"blobs"` 29 29 // blocks: CAR file containing relevant blocks, as a diff since the previous repo state. The commit must be included as a block, and the commit block CID must be the first entry in the CAR header 'roots' list. 30 - Blocks util.LexBytes `json:"blocks,omitempty" cborgen:"blocks,omitempty"` 30 + Blocks lexutil.LexBytes `json:"blocks,omitempty" cborgen:"blocks,omitempty"` 31 31 // commit: Repo commit object CID. 32 - Commit util.LexLink `json:"commit" cborgen:"commit"` 32 + Commit lexutil.LexLink `json:"commit" cborgen:"commit"` 33 33 Ops []*SyncSubscribeRepos_RepoOp `json:"ops" cborgen:"ops"` 34 34 // prevData: The root CID of the MST tree for the previous commit from this repo (indicated by the 'since' revision field in this message). Corresponds to the 'data' field in the repo commit object. NOTE: this field is effectively required for the 'inductive' version of firehose. 35 - PrevData *util.LexLink `json:"prevData,omitempty" cborgen:"prevData,omitempty"` 35 + PrevData *lexutil.LexLink `json:"prevData,omitempty" cborgen:"prevData,omitempty"` 36 36 // rebase: DEPRECATED -- unused 37 37 Rebase bool `json:"rebase" cborgen:"rebase"` 38 38 // repo: The repo this event comes from. Note that all other message types name this field 'did'. ··· 72 72 type SyncSubscribeRepos_RepoOp struct { 73 73 Action string `json:"action" cborgen:"action"` 74 74 // cid: For creates and updates, the new record CID. For deletions, null. 75 - Cid *util.LexLink `json:"cid" cborgen:"cid"` 76 - Path string `json:"path" cborgen:"path"` 75 + Cid *lexutil.LexLink `json:"cid" cborgen:"cid"` 76 + Path string `json:"path" cborgen:"path"` 77 77 // prev: For updates and deletes, the previous record CID (required for inductive firehose). For creations, field should not be defined. 78 - Prev *util.LexLink `json:"prev,omitempty" cborgen:"prev,omitempty"` 78 + Prev *lexutil.LexLink `json:"prev,omitempty" cborgen:"prev,omitempty"` 79 79 } 80 80 81 81 // SyncSubscribeRepos_Sync is a "sync" in the com.atproto.sync.subscribeRepos schema. ··· 83 83 // Updates the repo to a new state, without necessarily including that state on the firehose. Used to recover from broken commit streams, data loss incidents, or in situations where upstream host does not know recent state of the repository. 84 84 type SyncSubscribeRepos_Sync struct { 85 85 // blocks: CAR file containing the commit, as a block. The CAR header must include the commit block CID as the first 'root'. 86 - Blocks util.LexBytes `json:"blocks,omitempty" cborgen:"blocks,omitempty"` 86 + Blocks lexutil.LexBytes `json:"blocks,omitempty" cborgen:"blocks,omitempty"` 87 87 // did: The account this repo event corresponds to. Must match that in the commit object. 88 88 Did string `json:"did" cborgen:"did"` 89 89 // rev: The rev of the commit. This value must match that in the commit object.
+3 -3
api/atproto/tempaddReservedHandle.go
··· 7 7 import ( 8 8 "context" 9 9 10 - "github.com/bluesky-social/indigo/lex/util" 10 + lexutil "github.com/bluesky-social/indigo/lex/util" 11 11 ) 12 12 13 13 // TempAddReservedHandle_Input is the input argument to a com.atproto.temp.addReservedHandle call. ··· 20 20 } 21 21 22 22 // TempAddReservedHandle calls the XRPC method "com.atproto.temp.addReservedHandle". 23 - func TempAddReservedHandle(ctx context.Context, c util.LexClient, input *TempAddReservedHandle_Input) (*TempAddReservedHandle_Output, error) { 23 + func TempAddReservedHandle(ctx context.Context, c lexutil.LexClient, input *TempAddReservedHandle_Input) (*TempAddReservedHandle_Output, error) { 24 24 var out TempAddReservedHandle_Output 25 - if err := c.LexDo(ctx, util.Procedure, "application/json", "com.atproto.temp.addReservedHandle", nil, input, &out); err != nil { 25 + if err := c.LexDo(ctx, lexutil.Procedure, "application/json", "com.atproto.temp.addReservedHandle", nil, input, &out); err != nil { 26 26 return nil, err 27 27 } 28 28
+4 -5
api/atproto/tempcheckHandleAvailability.go
··· 9 9 "encoding/json" 10 10 "fmt" 11 11 12 - "github.com/bluesky-social/indigo/lex/util" 12 + lexutil "github.com/bluesky-social/indigo/lex/util" 13 13 ) 14 14 15 15 // TempCheckHandleAvailability_Output is the output of a com.atproto.temp.checkHandleAvailability call. ··· 37 37 } 38 38 39 39 func (t *TempCheckHandleAvailability_Output_Result) UnmarshalJSON(b []byte) error { 40 - typ, err := util.TypeExtract(b) 40 + typ, err := lexutil.TypeExtract(b) 41 41 if err != nil { 42 42 return err 43 43 } ··· 49 49 case "com.atproto.temp.checkHandleAvailability#resultUnavailable": 50 50 t.TempCheckHandleAvailability_ResultUnavailable = new(TempCheckHandleAvailability_ResultUnavailable) 51 51 return json.Unmarshal(b, t.TempCheckHandleAvailability_ResultUnavailable) 52 - 53 52 default: 54 53 return nil 55 54 } ··· 83 82 // birthDate: User-provided birth date. Might be used to build handle suggestions. 84 83 // email: User-provided email. Might be used to build handle suggestions. 85 84 // handle: Tentative handle. Will be checked for availability or used to build handle suggestions. 86 - func TempCheckHandleAvailability(ctx context.Context, c util.LexClient, birthDate string, email string, handle string) (*TempCheckHandleAvailability_Output, error) { 85 + func TempCheckHandleAvailability(ctx context.Context, c lexutil.LexClient, birthDate string, email string, handle string) (*TempCheckHandleAvailability_Output, error) { 87 86 var out TempCheckHandleAvailability_Output 88 87 89 88 params := map[string]interface{}{} ··· 94 93 params["email"] = email 95 94 } 96 95 params["handle"] = handle 97 - if err := c.LexDo(ctx, util.Query, "", "com.atproto.temp.checkHandleAvailability", params, nil, &out); err != nil { 96 + if err := c.LexDo(ctx, lexutil.Query, "", "com.atproto.temp.checkHandleAvailability", params, nil, &out); err != nil { 98 97 return nil, err 99 98 } 100 99
+3 -3
api/atproto/tempcheckSignupQueue.go
··· 7 7 import ( 8 8 "context" 9 9 10 - "github.com/bluesky-social/indigo/lex/util" 10 + lexutil "github.com/bluesky-social/indigo/lex/util" 11 11 ) 12 12 13 13 // TempCheckSignupQueue_Output is the output of a com.atproto.temp.checkSignupQueue call. ··· 18 18 } 19 19 20 20 // TempCheckSignupQueue calls the XRPC method "com.atproto.temp.checkSignupQueue". 21 - func TempCheckSignupQueue(ctx context.Context, c util.LexClient) (*TempCheckSignupQueue_Output, error) { 21 + func TempCheckSignupQueue(ctx context.Context, c lexutil.LexClient) (*TempCheckSignupQueue_Output, error) { 22 22 var out TempCheckSignupQueue_Output 23 - if err := c.LexDo(ctx, util.Query, "", "com.atproto.temp.checkSignupQueue", nil, nil, &out); err != nil { 23 + if err := c.LexDo(ctx, lexutil.Query, "", "com.atproto.temp.checkSignupQueue", nil, nil, &out); err != nil { 24 24 return nil, err 25 25 } 26 26
+3 -3
api/atproto/tempdereferenceScope.go
··· 7 7 import ( 8 8 "context" 9 9 10 - "github.com/bluesky-social/indigo/lex/util" 10 + lexutil "github.com/bluesky-social/indigo/lex/util" 11 11 ) 12 12 13 13 // TempDereferenceScope_Output is the output of a com.atproto.temp.dereferenceScope call. ··· 19 19 // TempDereferenceScope calls the XRPC method "com.atproto.temp.dereferenceScope". 20 20 // 21 21 // scope: The scope reference (starts with 'ref:') 22 - func TempDereferenceScope(ctx context.Context, c util.LexClient, scope string) (*TempDereferenceScope_Output, error) { 22 + func TempDereferenceScope(ctx context.Context, c lexutil.LexClient, scope string) (*TempDereferenceScope_Output, error) { 23 23 var out TempDereferenceScope_Output 24 24 25 25 params := map[string]interface{}{} 26 26 params["scope"] = scope 27 - if err := c.LexDo(ctx, util.Query, "", "com.atproto.temp.dereferenceScope", params, nil, &out); err != nil { 27 + if err := c.LexDo(ctx, lexutil.Query, "", "com.atproto.temp.dereferenceScope", params, nil, &out); err != nil { 28 28 return nil, err 29 29 } 30 30
+3 -3
api/atproto/tempfetchLabels.go
··· 7 7 import ( 8 8 "context" 9 9 10 - "github.com/bluesky-social/indigo/lex/util" 10 + lexutil "github.com/bluesky-social/indigo/lex/util" 11 11 ) 12 12 13 13 // TempFetchLabels_Output is the output of a com.atproto.temp.fetchLabels call. ··· 16 16 } 17 17 18 18 // TempFetchLabels calls the XRPC method "com.atproto.temp.fetchLabels". 19 - func TempFetchLabels(ctx context.Context, c util.LexClient, limit int64, since int64) (*TempFetchLabels_Output, error) { 19 + func TempFetchLabels(ctx context.Context, c lexutil.LexClient, limit int64, since int64) (*TempFetchLabels_Output, error) { 20 20 var out TempFetchLabels_Output 21 21 22 22 params := map[string]interface{}{} ··· 26 26 if since != 0 { 27 27 params["since"] = since 28 28 } 29 - if err := c.LexDo(ctx, util.Query, "", "com.atproto.temp.fetchLabels", params, nil, &out); err != nil { 29 + if err := c.LexDo(ctx, lexutil.Query, "", "com.atproto.temp.fetchLabels", params, nil, &out); err != nil { 30 30 return nil, err 31 31 } 32 32
+3 -3
api/atproto/temprequestPhoneVerification.go
··· 7 7 import ( 8 8 "context" 9 9 10 - "github.com/bluesky-social/indigo/lex/util" 10 + lexutil "github.com/bluesky-social/indigo/lex/util" 11 11 ) 12 12 13 13 // TempRequestPhoneVerification_Input is the input argument to a com.atproto.temp.requestPhoneVerification call. ··· 16 16 } 17 17 18 18 // TempRequestPhoneVerification calls the XRPC method "com.atproto.temp.requestPhoneVerification". 19 - func TempRequestPhoneVerification(ctx context.Context, c util.LexClient, input *TempRequestPhoneVerification_Input) error { 20 - if err := c.LexDo(ctx, util.Procedure, "application/json", "com.atproto.temp.requestPhoneVerification", nil, input, nil); err != nil { 19 + func TempRequestPhoneVerification(ctx context.Context, c lexutil.LexClient, input *TempRequestPhoneVerification_Input) error { 20 + if err := c.LexDo(ctx, lexutil.Procedure, "application/json", "com.atproto.temp.requestPhoneVerification", nil, input, nil); err != nil { 21 21 return err 22 22 } 23 23
+3 -3
api/atproto/temprevokeAccountCredentials.go
··· 7 7 import ( 8 8 "context" 9 9 10 - "github.com/bluesky-social/indigo/lex/util" 10 + lexutil "github.com/bluesky-social/indigo/lex/util" 11 11 ) 12 12 13 13 // TempRevokeAccountCredentials_Input is the input argument to a com.atproto.temp.revokeAccountCredentials call. ··· 16 16 } 17 17 18 18 // TempRevokeAccountCredentials calls the XRPC method "com.atproto.temp.revokeAccountCredentials". 19 - func TempRevokeAccountCredentials(ctx context.Context, c util.LexClient, input *TempRevokeAccountCredentials_Input) error { 20 - if err := c.LexDo(ctx, util.Procedure, "application/json", "com.atproto.temp.revokeAccountCredentials", nil, input, nil); err != nil { 19 + func TempRevokeAccountCredentials(ctx context.Context, c lexutil.LexClient, input *TempRevokeAccountCredentials_Input) error { 20 + if err := c.LexDo(ctx, lexutil.Procedure, "application/json", "com.atproto.temp.revokeAccountCredentials", nil, input, nil); err != nil { 21 21 return err 22 22 } 23 23
+52 -56
api/bsky/actordefs.go
··· 8 8 "encoding/json" 9 9 "fmt" 10 10 11 - comatprototypes "github.com/bluesky-social/indigo/api/atproto" 12 - "github.com/bluesky-social/indigo/lex/util" 11 + comatproto "github.com/bluesky-social/indigo/api/atproto" 12 + lexutil "github.com/bluesky-social/indigo/lex/util" 13 13 ) 14 14 15 15 // ActorDefs_AdultContentPref is a "adultContentPref" in the app.bsky.actor.defs schema. ··· 161 161 } 162 162 163 163 func (t *ActorDefs_PostInteractionSettingsPref_PostgateEmbeddingRules_Elem) UnmarshalJSON(b []byte) error { 164 - typ, err := util.TypeExtract(b) 164 + typ, err := lexutil.TypeExtract(b) 165 165 if err != nil { 166 166 return err 167 167 } ··· 170 170 case "app.bsky.feed.postgate#disableRule": 171 171 t.FeedPostgate_DisableRule = new(FeedPostgate_DisableRule) 172 172 return json.Unmarshal(b, t.FeedPostgate_DisableRule) 173 - 174 173 default: 175 174 return nil 176 175 } ··· 204 203 } 205 204 206 205 func (t *ActorDefs_PostInteractionSettingsPref_ThreadgateAllowRules_Elem) UnmarshalJSON(b []byte) error { 207 - typ, err := util.TypeExtract(b) 206 + typ, err := lexutil.TypeExtract(b) 208 207 if err != nil { 209 208 return err 210 209 } ··· 222 221 case "app.bsky.feed.threadgate#listRule": 223 222 t.FeedThreadgate_ListRule = new(FeedThreadgate_ListRule) 224 223 return json.Unmarshal(b, t.FeedThreadgate_ListRule) 225 - 226 224 default: 227 225 return nil 228 226 } ··· 306 304 } 307 305 308 306 func (t *ActorDefs_Preferences_Elem) UnmarshalJSON(b []byte) error { 309 - typ, err := util.TypeExtract(b) 307 + typ, err := lexutil.TypeExtract(b) 310 308 if err != nil { 311 309 return err 312 310 } ··· 354 352 case "app.bsky.actor.defs#verificationPrefs": 355 353 t.ActorDefs_VerificationPrefs = new(ActorDefs_VerificationPrefs) 356 354 return json.Unmarshal(b, t.ActorDefs_VerificationPrefs) 357 - 358 355 default: 359 356 return nil 360 357 } ··· 382 379 383 380 // ActorDefs_ProfileView is a "profileView" in the app.bsky.actor.defs schema. 384 381 type ActorDefs_ProfileView struct { 385 - Associated *ActorDefs_ProfileAssociated `json:"associated,omitempty" cborgen:"associated,omitempty"` 386 - Avatar *string `json:"avatar,omitempty" cborgen:"avatar,omitempty"` 387 - CreatedAt *string `json:"createdAt,omitempty" cborgen:"createdAt,omitempty"` 388 - Description *string `json:"description,omitempty" cborgen:"description,omitempty"` 389 - Did string `json:"did" cborgen:"did"` 390 - DisplayName *string `json:"displayName,omitempty" cborgen:"displayName,omitempty"` 391 - Handle string `json:"handle" cborgen:"handle"` 392 - IndexedAt *string `json:"indexedAt,omitempty" cborgen:"indexedAt,omitempty"` 393 - Labels []*comatprototypes.LabelDefs_Label `json:"labels,omitempty" cborgen:"labels,omitempty"` 394 - Pronouns *string `json:"pronouns,omitempty" cborgen:"pronouns,omitempty"` 395 - Status *ActorDefs_StatusView `json:"status,omitempty" cborgen:"status,omitempty"` 396 - Verification *ActorDefs_VerificationState `json:"verification,omitempty" cborgen:"verification,omitempty"` 397 - Viewer *ActorDefs_ViewerState `json:"viewer,omitempty" cborgen:"viewer,omitempty"` 382 + Associated *ActorDefs_ProfileAssociated `json:"associated,omitempty" cborgen:"associated,omitempty"` 383 + Avatar *string `json:"avatar,omitempty" cborgen:"avatar,omitempty"` 384 + CreatedAt *string `json:"createdAt,omitempty" cborgen:"createdAt,omitempty"` 385 + Description *string `json:"description,omitempty" cborgen:"description,omitempty"` 386 + Did string `json:"did" cborgen:"did"` 387 + DisplayName *string `json:"displayName,omitempty" cborgen:"displayName,omitempty"` 388 + Handle string `json:"handle" cborgen:"handle"` 389 + IndexedAt *string `json:"indexedAt,omitempty" cborgen:"indexedAt,omitempty"` 390 + Labels []*comatproto.LabelDefs_Label `json:"labels,omitempty" cborgen:"labels,omitempty"` 391 + Pronouns *string `json:"pronouns,omitempty" cborgen:"pronouns,omitempty"` 392 + Status *ActorDefs_StatusView `json:"status,omitempty" cborgen:"status,omitempty"` 393 + Verification *ActorDefs_VerificationState `json:"verification,omitempty" cborgen:"verification,omitempty"` 394 + Viewer *ActorDefs_ViewerState `json:"viewer,omitempty" cborgen:"viewer,omitempty"` 398 395 } 399 396 400 397 // ActorDefs_ProfileViewBasic is a "profileViewBasic" in the app.bsky.actor.defs schema. 401 398 type ActorDefs_ProfileViewBasic struct { 402 - Associated *ActorDefs_ProfileAssociated `json:"associated,omitempty" cborgen:"associated,omitempty"` 403 - Avatar *string `json:"avatar,omitempty" cborgen:"avatar,omitempty"` 404 - CreatedAt *string `json:"createdAt,omitempty" cborgen:"createdAt,omitempty"` 405 - Did string `json:"did" cborgen:"did"` 406 - DisplayName *string `json:"displayName,omitempty" cborgen:"displayName,omitempty"` 407 - Handle string `json:"handle" cborgen:"handle"` 408 - Labels []*comatprototypes.LabelDefs_Label `json:"labels,omitempty" cborgen:"labels,omitempty"` 409 - Pronouns *string `json:"pronouns,omitempty" cborgen:"pronouns,omitempty"` 410 - Status *ActorDefs_StatusView `json:"status,omitempty" cborgen:"status,omitempty"` 411 - Verification *ActorDefs_VerificationState `json:"verification,omitempty" cborgen:"verification,omitempty"` 412 - Viewer *ActorDefs_ViewerState `json:"viewer,omitempty" cborgen:"viewer,omitempty"` 399 + Associated *ActorDefs_ProfileAssociated `json:"associated,omitempty" cborgen:"associated,omitempty"` 400 + Avatar *string `json:"avatar,omitempty" cborgen:"avatar,omitempty"` 401 + CreatedAt *string `json:"createdAt,omitempty" cborgen:"createdAt,omitempty"` 402 + Did string `json:"did" cborgen:"did"` 403 + DisplayName *string `json:"displayName,omitempty" cborgen:"displayName,omitempty"` 404 + Handle string `json:"handle" cborgen:"handle"` 405 + Labels []*comatproto.LabelDefs_Label `json:"labels,omitempty" cborgen:"labels,omitempty"` 406 + Pronouns *string `json:"pronouns,omitempty" cborgen:"pronouns,omitempty"` 407 + Status *ActorDefs_StatusView `json:"status,omitempty" cborgen:"status,omitempty"` 408 + Verification *ActorDefs_VerificationState `json:"verification,omitempty" cborgen:"verification,omitempty"` 409 + Viewer *ActorDefs_ViewerState `json:"viewer,omitempty" cborgen:"viewer,omitempty"` 413 410 } 414 411 415 412 // ActorDefs_ProfileViewDetailed is a "profileViewDetailed" in the app.bsky.actor.defs schema. 416 413 type ActorDefs_ProfileViewDetailed struct { 417 - Associated *ActorDefs_ProfileAssociated `json:"associated,omitempty" cborgen:"associated,omitempty"` 418 - Avatar *string `json:"avatar,omitempty" cborgen:"avatar,omitempty"` 419 - Banner *string `json:"banner,omitempty" cborgen:"banner,omitempty"` 420 - CreatedAt *string `json:"createdAt,omitempty" cborgen:"createdAt,omitempty"` 421 - Description *string `json:"description,omitempty" cborgen:"description,omitempty"` 422 - Did string `json:"did" cborgen:"did"` 423 - DisplayName *string `json:"displayName,omitempty" cborgen:"displayName,omitempty"` 424 - FollowersCount *int64 `json:"followersCount,omitempty" cborgen:"followersCount,omitempty"` 425 - FollowsCount *int64 `json:"followsCount,omitempty" cborgen:"followsCount,omitempty"` 426 - Handle string `json:"handle" cborgen:"handle"` 427 - IndexedAt *string `json:"indexedAt,omitempty" cborgen:"indexedAt,omitempty"` 428 - JoinedViaStarterPack *GraphDefs_StarterPackViewBasic `json:"joinedViaStarterPack,omitempty" cborgen:"joinedViaStarterPack,omitempty"` 429 - Labels []*comatprototypes.LabelDefs_Label `json:"labels,omitempty" cborgen:"labels,omitempty"` 430 - PinnedPost *comatprototypes.RepoStrongRef `json:"pinnedPost,omitempty" cborgen:"pinnedPost,omitempty"` 431 - PostsCount *int64 `json:"postsCount,omitempty" cborgen:"postsCount,omitempty"` 432 - Pronouns *string `json:"pronouns,omitempty" cborgen:"pronouns,omitempty"` 433 - Status *ActorDefs_StatusView `json:"status,omitempty" cborgen:"status,omitempty"` 434 - Verification *ActorDefs_VerificationState `json:"verification,omitempty" cborgen:"verification,omitempty"` 435 - Viewer *ActorDefs_ViewerState `json:"viewer,omitempty" cborgen:"viewer,omitempty"` 436 - Website *string `json:"website,omitempty" cborgen:"website,omitempty"` 414 + Associated *ActorDefs_ProfileAssociated `json:"associated,omitempty" cborgen:"associated,omitempty"` 415 + Avatar *string `json:"avatar,omitempty" cborgen:"avatar,omitempty"` 416 + Banner *string `json:"banner,omitempty" cborgen:"banner,omitempty"` 417 + CreatedAt *string `json:"createdAt,omitempty" cborgen:"createdAt,omitempty"` 418 + Description *string `json:"description,omitempty" cborgen:"description,omitempty"` 419 + Did string `json:"did" cborgen:"did"` 420 + DisplayName *string `json:"displayName,omitempty" cborgen:"displayName,omitempty"` 421 + FollowersCount *int64 `json:"followersCount,omitempty" cborgen:"followersCount,omitempty"` 422 + FollowsCount *int64 `json:"followsCount,omitempty" cborgen:"followsCount,omitempty"` 423 + Handle string `json:"handle" cborgen:"handle"` 424 + IndexedAt *string `json:"indexedAt,omitempty" cborgen:"indexedAt,omitempty"` 425 + JoinedViaStarterPack *GraphDefs_StarterPackViewBasic `json:"joinedViaStarterPack,omitempty" cborgen:"joinedViaStarterPack,omitempty"` 426 + Labels []*comatproto.LabelDefs_Label `json:"labels,omitempty" cborgen:"labels,omitempty"` 427 + PinnedPost *comatproto.RepoStrongRef `json:"pinnedPost,omitempty" cborgen:"pinnedPost,omitempty"` 428 + PostsCount *int64 `json:"postsCount,omitempty" cborgen:"postsCount,omitempty"` 429 + Pronouns *string `json:"pronouns,omitempty" cborgen:"pronouns,omitempty"` 430 + Status *ActorDefs_StatusView `json:"status,omitempty" cborgen:"status,omitempty"` 431 + Verification *ActorDefs_VerificationState `json:"verification,omitempty" cborgen:"verification,omitempty"` 432 + Viewer *ActorDefs_ViewerState `json:"viewer,omitempty" cborgen:"viewer,omitempty"` 433 + Website *string `json:"website,omitempty" cborgen:"website,omitempty"` 437 434 } 438 435 439 436 // ActorDefs_SavedFeed is a "savedFeed" in the app.bsky.actor.defs schema. ··· 465 462 // expiresAt: The date when this status will expire. The application might choose to no longer return the status after expiration. 466 463 ExpiresAt *string `json:"expiresAt,omitempty" cborgen:"expiresAt,omitempty"` 467 464 // isActive: True if the status is not expired, false if it is expired. Only present if expiration was set. 468 - IsActive *bool `json:"isActive,omitempty" cborgen:"isActive,omitempty"` 469 - Record *util.LexiconTypeDecoder `json:"record" cborgen:"record"` 465 + IsActive *bool `json:"isActive,omitempty" cborgen:"isActive,omitempty"` 466 + Record *lexutil.LexiconTypeDecoder `json:"record" cborgen:"record"` 470 467 // status: The status for the account. 471 468 Status string `json:"status" cborgen:"status"` 472 469 } ··· 485 482 } 486 483 487 484 func (t *ActorDefs_StatusView_Embed) UnmarshalJSON(b []byte) error { 488 - typ, err := util.TypeExtract(b) 485 + typ, err := lexutil.TypeExtract(b) 489 486 if err != nil { 490 487 return err 491 488 } ··· 494 491 case "app.bsky.embed.external#view": 495 492 t.EmbedExternal_View = new(EmbedExternal_View) 496 493 return json.Unmarshal(b, t.EmbedExternal_View) 497 - 498 494 default: 499 495 return nil 500 496 }
+3 -3
api/bsky/actorgetPreferences.go
··· 7 7 import ( 8 8 "context" 9 9 10 - "github.com/bluesky-social/indigo/lex/util" 10 + lexutil "github.com/bluesky-social/indigo/lex/util" 11 11 ) 12 12 13 13 // ActorGetPreferences_Output is the output of a app.bsky.actor.getPreferences call. ··· 16 16 } 17 17 18 18 // ActorGetPreferences calls the XRPC method "app.bsky.actor.getPreferences". 19 - func ActorGetPreferences(ctx context.Context, c util.LexClient) (*ActorGetPreferences_Output, error) { 19 + func ActorGetPreferences(ctx context.Context, c lexutil.LexClient) (*ActorGetPreferences_Output, error) { 20 20 var out ActorGetPreferences_Output 21 21 22 22 params := map[string]interface{}{} 23 - if err := c.LexDo(ctx, util.Query, "", "app.bsky.actor.getPreferences", params, nil, &out); err != nil { 23 + if err := c.LexDo(ctx, lexutil.Query, "", "app.bsky.actor.getPreferences", params, nil, &out); err != nil { 24 24 return nil, err 25 25 } 26 26
+3 -3
api/bsky/actorgetProfile.go
··· 7 7 import ( 8 8 "context" 9 9 10 - "github.com/bluesky-social/indigo/lex/util" 10 + lexutil "github.com/bluesky-social/indigo/lex/util" 11 11 ) 12 12 13 13 // ActorGetProfile calls the XRPC method "app.bsky.actor.getProfile". 14 14 // 15 15 // actor: Handle or DID of account to fetch profile of. 16 - func ActorGetProfile(ctx context.Context, c util.LexClient, actor string) (*ActorDefs_ProfileViewDetailed, error) { 16 + func ActorGetProfile(ctx context.Context, c lexutil.LexClient, actor string) (*ActorDefs_ProfileViewDetailed, error) { 17 17 var out ActorDefs_ProfileViewDetailed 18 18 19 19 params := map[string]interface{}{} 20 20 params["actor"] = actor 21 - if err := c.LexDo(ctx, util.Query, "", "app.bsky.actor.getProfile", params, nil, &out); err != nil { 21 + if err := c.LexDo(ctx, lexutil.Query, "", "app.bsky.actor.getProfile", params, nil, &out); err != nil { 22 22 return nil, err 23 23 } 24 24
+3 -3
api/bsky/actorgetProfiles.go
··· 7 7 import ( 8 8 "context" 9 9 10 - "github.com/bluesky-social/indigo/lex/util" 10 + lexutil "github.com/bluesky-social/indigo/lex/util" 11 11 ) 12 12 13 13 // ActorGetProfiles_Output is the output of a app.bsky.actor.getProfiles call. ··· 16 16 } 17 17 18 18 // ActorGetProfiles calls the XRPC method "app.bsky.actor.getProfiles". 19 - func ActorGetProfiles(ctx context.Context, c util.LexClient, actors []string) (*ActorGetProfiles_Output, error) { 19 + func ActorGetProfiles(ctx context.Context, c lexutil.LexClient, actors []string) (*ActorGetProfiles_Output, error) { 20 20 var out ActorGetProfiles_Output 21 21 22 22 params := map[string]interface{}{} 23 23 params["actors"] = actors 24 - if err := c.LexDo(ctx, util.Query, "", "app.bsky.actor.getProfiles", params, nil, &out); err != nil { 24 + if err := c.LexDo(ctx, lexutil.Query, "", "app.bsky.actor.getProfiles", params, nil, &out); err != nil { 25 25 return nil, err 26 26 } 27 27
+3 -3
api/bsky/actorgetSuggestions.go
··· 7 7 import ( 8 8 "context" 9 9 10 - "github.com/bluesky-social/indigo/lex/util" 10 + lexutil "github.com/bluesky-social/indigo/lex/util" 11 11 ) 12 12 13 13 // ActorGetSuggestions_Output is the output of a app.bsky.actor.getSuggestions call. ··· 19 19 } 20 20 21 21 // ActorGetSuggestions calls the XRPC method "app.bsky.actor.getSuggestions". 22 - func ActorGetSuggestions(ctx context.Context, c util.LexClient, cursor string, limit int64) (*ActorGetSuggestions_Output, error) { 22 + func ActorGetSuggestions(ctx context.Context, c lexutil.LexClient, cursor string, limit int64) (*ActorGetSuggestions_Output, error) { 23 23 var out ActorGetSuggestions_Output 24 24 25 25 params := map[string]interface{}{} ··· 29 29 if limit != 0 { 30 30 params["limit"] = limit 31 31 } 32 - if err := c.LexDo(ctx, util.Query, "", "app.bsky.actor.getSuggestions", params, nil, &out); err != nil { 32 + if err := c.LexDo(ctx, lexutil.Query, "", "app.bsky.actor.getSuggestions", params, nil, &out); err != nil { 33 33 return nil, err 34 34 } 35 35
+17 -18
api/bsky/actorprofile.go
··· 10 10 "fmt" 11 11 "io" 12 12 13 - comatprototypes "github.com/bluesky-social/indigo/api/atproto" 14 - "github.com/bluesky-social/indigo/lex/util" 13 + comatproto "github.com/bluesky-social/indigo/api/atproto" 14 + lexutil "github.com/bluesky-social/indigo/lex/util" 15 15 cbg "github.com/whyrusleeping/cbor-gen" 16 16 ) 17 17 18 18 func init() { 19 - util.RegisterType("app.bsky.actor.profile", &ActorProfile{}) 19 + lexutil.RegisterType("app.bsky.actor.profile", &ActorProfile{}) 20 20 } 21 21 22 22 type ActorProfile struct { 23 23 LexiconTypeID string `json:"$type" cborgen:"$type,const=app.bsky.actor.profile"` 24 24 // avatar: Small image to be displayed next to posts from account. AKA, 'profile picture' 25 - Avatar *util.LexBlob `json:"avatar,omitempty" cborgen:"avatar,omitempty"` 25 + Avatar *lexutil.LexBlob `json:"avatar,omitempty" cborgen:"avatar,omitempty"` 26 26 // banner: Larger horizontal image to display behind profile view. 27 - Banner *util.LexBlob `json:"banner,omitempty" cborgen:"banner,omitempty"` 28 - CreatedAt *string `json:"createdAt,omitempty" cborgen:"createdAt,omitempty"` 27 + Banner *lexutil.LexBlob `json:"banner,omitempty" cborgen:"banner,omitempty"` 28 + CreatedAt *string `json:"createdAt,omitempty" cborgen:"createdAt,omitempty"` 29 29 // description: Free-form profile description text. 30 - Description *string `json:"description,omitempty" cborgen:"description,omitempty"` 31 - DisplayName *string `json:"displayName,omitempty" cborgen:"displayName,omitempty"` 32 - JoinedViaStarterPack *comatprototypes.RepoStrongRef `json:"joinedViaStarterPack,omitempty" cborgen:"joinedViaStarterPack,omitempty"` 30 + Description *string `json:"description,omitempty" cborgen:"description,omitempty"` 31 + DisplayName *string `json:"displayName,omitempty" cborgen:"displayName,omitempty"` 32 + JoinedViaStarterPack *comatproto.RepoStrongRef `json:"joinedViaStarterPack,omitempty" cborgen:"joinedViaStarterPack,omitempty"` 33 33 // labels: Self-label values, specific to the Bluesky application, on the overall account. 34 - Labels *ActorProfile_Labels `json:"labels,omitempty" cborgen:"labels,omitempty"` 35 - PinnedPost *comatprototypes.RepoStrongRef `json:"pinnedPost,omitempty" cborgen:"pinnedPost,omitempty"` 34 + Labels *ActorProfile_Labels `json:"labels,omitempty" cborgen:"labels,omitempty"` 35 + PinnedPost *comatproto.RepoStrongRef `json:"pinnedPost,omitempty" cborgen:"pinnedPost,omitempty"` 36 36 // pronouns: Free-form pronouns text. 37 37 Pronouns *string `json:"pronouns,omitempty" cborgen:"pronouns,omitempty"` 38 38 Website *string `json:"website,omitempty" cborgen:"website,omitempty"` ··· 40 40 41 41 // Self-label values, specific to the Bluesky application, on the overall account. 42 42 type ActorProfile_Labels struct { 43 - LabelDefs_SelfLabels *comatprototypes.LabelDefs_SelfLabels 43 + LabelDefs_SelfLabels *comatproto.LabelDefs_SelfLabels 44 44 } 45 45 46 46 func (t *ActorProfile_Labels) MarshalJSON() ([]byte, error) { ··· 52 52 } 53 53 54 54 func (t *ActorProfile_Labels) UnmarshalJSON(b []byte) error { 55 - typ, err := util.TypeExtract(b) 55 + typ, err := lexutil.TypeExtract(b) 56 56 if err != nil { 57 57 return err 58 58 } 59 59 60 60 switch typ { 61 61 case "com.atproto.label.defs#selfLabels": 62 - t.LabelDefs_SelfLabels = new(comatprototypes.LabelDefs_SelfLabels) 62 + t.LabelDefs_SelfLabels = new(comatproto.LabelDefs_SelfLabels) 63 63 return json.Unmarshal(b, t.LabelDefs_SelfLabels) 64 - 65 64 default: 66 65 return nil 67 66 } ··· 78 77 } 79 78 return fmt.Errorf("can not marshal empty union as CBOR") 80 79 } 80 + 81 81 func (t *ActorProfile_Labels) UnmarshalCBOR(r io.Reader) error { 82 - typ, b, err := util.CborTypeExtractReader(r) 82 + typ, b, err := lexutil.CborTypeExtractReader(r) 83 83 if err != nil { 84 84 return err 85 85 } 86 86 87 87 switch typ { 88 88 case "com.atproto.label.defs#selfLabels": 89 - t.LabelDefs_SelfLabels = new(comatprototypes.LabelDefs_SelfLabels) 89 + t.LabelDefs_SelfLabels = new(comatproto.LabelDefs_SelfLabels) 90 90 return t.LabelDefs_SelfLabels.UnmarshalCBOR(bytes.NewReader(b)) 91 - 92 91 default: 93 92 return nil 94 93 }
+3 -3
api/bsky/actorputPreferences.go
··· 7 7 import ( 8 8 "context" 9 9 10 - "github.com/bluesky-social/indigo/lex/util" 10 + lexutil "github.com/bluesky-social/indigo/lex/util" 11 11 ) 12 12 13 13 // ActorPutPreferences_Input is the input argument to a app.bsky.actor.putPreferences call. ··· 16 16 } 17 17 18 18 // ActorPutPreferences calls the XRPC method "app.bsky.actor.putPreferences". 19 - func ActorPutPreferences(ctx context.Context, c util.LexClient, input *ActorPutPreferences_Input) error { 20 - if err := c.LexDo(ctx, util.Procedure, "application/json", "app.bsky.actor.putPreferences", nil, input, nil); err != nil { 19 + func ActorPutPreferences(ctx context.Context, c lexutil.LexClient, input *ActorPutPreferences_Input) error { 20 + if err := c.LexDo(ctx, lexutil.Procedure, "application/json", "app.bsky.actor.putPreferences", nil, input, nil); err != nil { 21 21 return err 22 22 } 23 23
+3 -3
api/bsky/actorsearchActors.go
··· 7 7 import ( 8 8 "context" 9 9 10 - "github.com/bluesky-social/indigo/lex/util" 10 + lexutil "github.com/bluesky-social/indigo/lex/util" 11 11 ) 12 12 13 13 // ActorSearchActors_Output is the output of a app.bsky.actor.searchActors call. ··· 20 20 // 21 21 // q: Search query string. Syntax, phrase, boolean, and faceting is unspecified, but Lucene query syntax is recommended. 22 22 // term: DEPRECATED: use 'q' instead. 23 - func ActorSearchActors(ctx context.Context, c util.LexClient, cursor string, limit int64, q string, term string) (*ActorSearchActors_Output, error) { 23 + func ActorSearchActors(ctx context.Context, c lexutil.LexClient, cursor string, limit int64, q string, term string) (*ActorSearchActors_Output, error) { 24 24 var out ActorSearchActors_Output 25 25 26 26 params := map[string]interface{}{} ··· 36 36 if term != "" { 37 37 params["term"] = term 38 38 } 39 - if err := c.LexDo(ctx, util.Query, "", "app.bsky.actor.searchActors", params, nil, &out); err != nil { 39 + if err := c.LexDo(ctx, lexutil.Query, "", "app.bsky.actor.searchActors", params, nil, &out); err != nil { 40 40 return nil, err 41 41 } 42 42
+3 -3
api/bsky/actorsearchActorsTypeahead.go
··· 7 7 import ( 8 8 "context" 9 9 10 - "github.com/bluesky-social/indigo/lex/util" 10 + lexutil "github.com/bluesky-social/indigo/lex/util" 11 11 ) 12 12 13 13 // ActorSearchActorsTypeahead_Output is the output of a app.bsky.actor.searchActorsTypeahead call. ··· 19 19 // 20 20 // q: Search query prefix; not a full query string. 21 21 // term: DEPRECATED: use 'q' instead. 22 - func ActorSearchActorsTypeahead(ctx context.Context, c util.LexClient, limit int64, q string, term string) (*ActorSearchActorsTypeahead_Output, error) { 22 + func ActorSearchActorsTypeahead(ctx context.Context, c lexutil.LexClient, limit int64, q string, term string) (*ActorSearchActorsTypeahead_Output, error) { 23 23 var out ActorSearchActorsTypeahead_Output 24 24 25 25 params := map[string]interface{}{} ··· 32 32 if term != "" { 33 33 params["term"] = term 34 34 } 35 - if err := c.LexDo(ctx, util.Query, "", "app.bsky.actor.searchActorsTypeahead", params, nil, &out); err != nil { 35 + if err := c.LexDo(ctx, lexutil.Query, "", "app.bsky.actor.searchActorsTypeahead", params, nil, &out); err != nil { 36 36 return nil, err 37 37 } 38 38
+5 -6
api/bsky/actorstatus.go
··· 10 10 "fmt" 11 11 "io" 12 12 13 - "github.com/bluesky-social/indigo/lex/util" 13 + lexutil "github.com/bluesky-social/indigo/lex/util" 14 14 cbg "github.com/whyrusleeping/cbor-gen" 15 15 ) 16 16 17 17 func init() { 18 - util.RegisterType("app.bsky.actor.status", &ActorStatus{}) 18 + lexutil.RegisterType("app.bsky.actor.status", &ActorStatus{}) 19 19 } 20 20 21 21 type ActorStatus struct { ··· 43 43 } 44 44 45 45 func (t *ActorStatus_Embed) UnmarshalJSON(b []byte) error { 46 - typ, err := util.TypeExtract(b) 46 + typ, err := lexutil.TypeExtract(b) 47 47 if err != nil { 48 48 return err 49 49 } ··· 52 52 case "app.bsky.embed.external": 53 53 t.EmbedExternal = new(EmbedExternal) 54 54 return json.Unmarshal(b, t.EmbedExternal) 55 - 56 55 default: 57 56 return nil 58 57 } ··· 69 68 } 70 69 return fmt.Errorf("can not marshal empty union as CBOR") 71 70 } 71 + 72 72 func (t *ActorStatus_Embed) UnmarshalCBOR(r io.Reader) error { 73 - typ, b, err := util.CborTypeExtractReader(r) 73 + typ, b, err := lexutil.CborTypeExtractReader(r) 74 74 if err != nil { 75 75 return err 76 76 } ··· 79 79 case "app.bsky.embed.external": 80 80 t.EmbedExternal = new(EmbedExternal) 81 81 return t.EmbedExternal.UnmarshalCBOR(bytes.NewReader(b)) 82 - 83 82 default: 84 83 return nil 85 84 }
+3 -3
api/bsky/bookmarkcreateBookmark.go
··· 7 7 import ( 8 8 "context" 9 9 10 - "github.com/bluesky-social/indigo/lex/util" 10 + lexutil "github.com/bluesky-social/indigo/lex/util" 11 11 ) 12 12 13 13 // BookmarkCreateBookmark_Input is the input argument to a app.bsky.bookmark.createBookmark call. ··· 17 17 } 18 18 19 19 // BookmarkCreateBookmark calls the XRPC method "app.bsky.bookmark.createBookmark". 20 - func BookmarkCreateBookmark(ctx context.Context, c util.LexClient, input *BookmarkCreateBookmark_Input) error { 21 - if err := c.LexDo(ctx, util.Procedure, "application/json", "app.bsky.bookmark.createBookmark", nil, input, nil); err != nil { 20 + func BookmarkCreateBookmark(ctx context.Context, c lexutil.LexClient, input *BookmarkCreateBookmark_Input) error { 21 + if err := c.LexDo(ctx, lexutil.Procedure, "application/json", "app.bsky.bookmark.createBookmark", nil, input, nil); err != nil { 22 22 return err 23 23 } 24 24
+5 -6
api/bsky/bookmarkdefs.go
··· 8 8 "encoding/json" 9 9 "fmt" 10 10 11 - comatprototypes "github.com/bluesky-social/indigo/api/atproto" 12 - "github.com/bluesky-social/indigo/lex/util" 11 + comatproto "github.com/bluesky-social/indigo/api/atproto" 12 + lexutil "github.com/bluesky-social/indigo/lex/util" 13 13 ) 14 14 15 15 // BookmarkDefs_Bookmark is a "bookmark" in the app.bsky.bookmark.defs schema. ··· 17 17 // Object used to store bookmark data in stash. 18 18 type BookmarkDefs_Bookmark struct { 19 19 // subject: A strong ref to the record to be bookmarked. Currently, only `app.bsky.feed.post` records are supported. 20 - Subject *comatprototypes.RepoStrongRef `json:"subject" cborgen:"subject"` 20 + Subject *comatproto.RepoStrongRef `json:"subject" cborgen:"subject"` 21 21 } 22 22 23 23 // BookmarkDefs_BookmarkView is a "bookmarkView" in the app.bsky.bookmark.defs schema. ··· 25 25 CreatedAt *string `json:"createdAt,omitempty" cborgen:"createdAt,omitempty"` 26 26 Item *BookmarkDefs_BookmarkView_Item `json:"item" cborgen:"item"` 27 27 // subject: A strong ref to the bookmarked record. 28 - Subject *comatprototypes.RepoStrongRef `json:"subject" cborgen:"subject"` 28 + Subject *comatproto.RepoStrongRef `json:"subject" cborgen:"subject"` 29 29 } 30 30 31 31 type BookmarkDefs_BookmarkView_Item struct { ··· 51 51 } 52 52 53 53 func (t *BookmarkDefs_BookmarkView_Item) UnmarshalJSON(b []byte) error { 54 - typ, err := util.TypeExtract(b) 54 + typ, err := lexutil.TypeExtract(b) 55 55 if err != nil { 56 56 return err 57 57 } ··· 66 66 case "app.bsky.feed.defs#postView": 67 67 t.FeedDefs_PostView = new(FeedDefs_PostView) 68 68 return json.Unmarshal(b, t.FeedDefs_PostView) 69 - 70 69 default: 71 70 return nil 72 71 }
+3 -3
api/bsky/bookmarkdeleteBookmark.go
··· 7 7 import ( 8 8 "context" 9 9 10 - "github.com/bluesky-social/indigo/lex/util" 10 + lexutil "github.com/bluesky-social/indigo/lex/util" 11 11 ) 12 12 13 13 // BookmarkDeleteBookmark_Input is the input argument to a app.bsky.bookmark.deleteBookmark call. ··· 16 16 } 17 17 18 18 // BookmarkDeleteBookmark calls the XRPC method "app.bsky.bookmark.deleteBookmark". 19 - func BookmarkDeleteBookmark(ctx context.Context, c util.LexClient, input *BookmarkDeleteBookmark_Input) error { 20 - if err := c.LexDo(ctx, util.Procedure, "application/json", "app.bsky.bookmark.deleteBookmark", nil, input, nil); err != nil { 19 + func BookmarkDeleteBookmark(ctx context.Context, c lexutil.LexClient, input *BookmarkDeleteBookmark_Input) error { 20 + if err := c.LexDo(ctx, lexutil.Procedure, "application/json", "app.bsky.bookmark.deleteBookmark", nil, input, nil); err != nil { 21 21 return err 22 22 } 23 23
+3 -3
api/bsky/bookmarkgetBookmarks.go
··· 7 7 import ( 8 8 "context" 9 9 10 - "github.com/bluesky-social/indigo/lex/util" 10 + lexutil "github.com/bluesky-social/indigo/lex/util" 11 11 ) 12 12 13 13 // BookmarkGetBookmarks_Output is the output of a app.bsky.bookmark.getBookmarks call. ··· 17 17 } 18 18 19 19 // BookmarkGetBookmarks calls the XRPC method "app.bsky.bookmark.getBookmarks". 20 - func BookmarkGetBookmarks(ctx context.Context, c util.LexClient, cursor string, limit int64) (*BookmarkGetBookmarks_Output, error) { 20 + func BookmarkGetBookmarks(ctx context.Context, c lexutil.LexClient, cursor string, limit int64) (*BookmarkGetBookmarks_Output, error) { 21 21 var out BookmarkGetBookmarks_Output 22 22 23 23 params := map[string]interface{}{} ··· 27 27 if limit != 0 { 28 28 params["limit"] = limit 29 29 } 30 - if err := c.LexDo(ctx, util.Query, "", "app.bsky.bookmark.getBookmarks", params, nil, &out); err != nil { 30 + if err := c.LexDo(ctx, lexutil.Query, "", "app.bsky.bookmark.getBookmarks", params, nil, &out); err != nil { 31 31 return nil, err 32 32 } 33 33
+6 -6
api/bsky/embedexternal.go
··· 5 5 package bsky 6 6 7 7 import ( 8 - "github.com/bluesky-social/indigo/lex/util" 8 + lexutil "github.com/bluesky-social/indigo/lex/util" 9 9 ) 10 10 11 11 func init() { 12 - util.RegisterType("app.bsky.embed.external#main", &EmbedExternal{}) 12 + lexutil.RegisterType("app.bsky.embed.external#main", &EmbedExternal{}) 13 13 } 14 14 15 15 // EmbedExternal is a "main" in the app.bsky.embed.external schema. ··· 22 22 23 23 // EmbedExternal_External is a "external" in the app.bsky.embed.external schema. 24 24 type EmbedExternal_External struct { 25 - Description string `json:"description" cborgen:"description"` 26 - Thumb *util.LexBlob `json:"thumb,omitempty" cborgen:"thumb,omitempty"` 27 - Title string `json:"title" cborgen:"title"` 28 - Uri string `json:"uri" cborgen:"uri"` 25 + Description string `json:"description" cborgen:"description"` 26 + Thumb *lexutil.LexBlob `json:"thumb,omitempty" cborgen:"thumb,omitempty"` 27 + Title string `json:"title" cborgen:"title"` 28 + Uri string `json:"uri" cborgen:"uri"` 29 29 } 30 30 31 31 // EmbedExternal_View is a "view" in the app.bsky.embed.external schema.
+3 -3
api/bsky/embedimages.go
··· 5 5 package bsky 6 6 7 7 import ( 8 - "github.com/bluesky-social/indigo/lex/util" 8 + lexutil "github.com/bluesky-social/indigo/lex/util" 9 9 ) 10 10 11 11 func init() { 12 - util.RegisterType("app.bsky.embed.images#main", &EmbedImages{}) 12 + lexutil.RegisterType("app.bsky.embed.images#main", &EmbedImages{}) 13 13 } 14 14 15 15 // EmbedImages is a "main" in the app.bsky.embed.images schema. ··· 23 23 // alt: Alt text description of the image, for accessibility. 24 24 Alt string `json:"alt" cborgen:"alt"` 25 25 AspectRatio *EmbedDefs_AspectRatio `json:"aspectRatio,omitempty" cborgen:"aspectRatio,omitempty"` 26 - Image *util.LexBlob `json:"image" cborgen:"image"` 26 + Image *lexutil.LexBlob `json:"image" cborgen:"image"` 27 27 } 28 28 29 29 // EmbedImages_View is a "view" in the app.bsky.embed.images schema.
+9 -11
api/bsky/embedrecord.go
··· 8 8 "encoding/json" 9 9 "fmt" 10 10 11 - comatprototypes "github.com/bluesky-social/indigo/api/atproto" 12 - "github.com/bluesky-social/indigo/lex/util" 11 + comatproto "github.com/bluesky-social/indigo/api/atproto" 12 + lexutil "github.com/bluesky-social/indigo/lex/util" 13 13 ) 14 14 15 15 func init() { 16 - util.RegisterType("app.bsky.embed.record#main", &EmbedRecord{}) 16 + lexutil.RegisterType("app.bsky.embed.record#main", &EmbedRecord{}) 17 17 } 18 18 19 19 // EmbedRecord is a "main" in the app.bsky.embed.record schema. 20 20 type EmbedRecord struct { 21 - LexiconTypeID string `json:"$type" cborgen:"$type,const=app.bsky.embed.record"` 22 - Record *comatprototypes.RepoStrongRef `json:"record" cborgen:"record"` 21 + LexiconTypeID string `json:"$type" cborgen:"$type,const=app.bsky.embed.record"` 22 + Record *comatproto.RepoStrongRef `json:"record" cborgen:"record"` 23 23 } 24 24 25 25 // EmbedRecord_View is a "view" in the app.bsky.embed.record schema. ··· 57 57 Cid string `json:"cid" cborgen:"cid"` 58 58 Embeds []*EmbedRecord_ViewRecord_Embeds_Elem `json:"embeds,omitempty" cborgen:"embeds,omitempty"` 59 59 IndexedAt string `json:"indexedAt" cborgen:"indexedAt"` 60 - Labels []*comatprototypes.LabelDefs_Label `json:"labels,omitempty" cborgen:"labels,omitempty"` 60 + Labels []*comatproto.LabelDefs_Label `json:"labels,omitempty" cborgen:"labels,omitempty"` 61 61 LikeCount *int64 `json:"likeCount,omitempty" cborgen:"likeCount,omitempty"` 62 62 QuoteCount *int64 `json:"quoteCount,omitempty" cborgen:"quoteCount,omitempty"` 63 63 ReplyCount *int64 `json:"replyCount,omitempty" cborgen:"replyCount,omitempty"` 64 64 RepostCount *int64 `json:"repostCount,omitempty" cborgen:"repostCount,omitempty"` 65 65 Uri string `json:"uri" cborgen:"uri"` 66 66 // value: The record data itself. 67 - Value *util.LexiconTypeDecoder `json:"value" cborgen:"value"` 67 + Value *lexutil.LexiconTypeDecoder `json:"value" cborgen:"value"` 68 68 } 69 69 70 70 type EmbedRecord_ViewRecord_Embeds_Elem struct { ··· 100 100 } 101 101 102 102 func (t *EmbedRecord_ViewRecord_Embeds_Elem) UnmarshalJSON(b []byte) error { 103 - typ, err := util.TypeExtract(b) 103 + typ, err := lexutil.TypeExtract(b) 104 104 if err != nil { 105 105 return err 106 106 } ··· 121 121 case "app.bsky.embed.recordWithMedia#view": 122 122 t.EmbedRecordWithMedia_View = new(EmbedRecordWithMedia_View) 123 123 return json.Unmarshal(b, t.EmbedRecordWithMedia_View) 124 - 125 124 default: 126 125 return nil 127 126 } ··· 175 174 } 176 175 177 176 func (t *EmbedRecord_View_Record) UnmarshalJSON(b []byte) error { 178 - typ, err := util.TypeExtract(b) 177 + typ, err := lexutil.TypeExtract(b) 179 178 if err != nil { 180 179 return err 181 180 } ··· 205 204 case "app.bsky.graph.defs#starterPackViewBasic": 206 205 t.GraphDefs_StarterPackViewBasic = new(GraphDefs_StarterPackViewBasic) 207 206 return json.Unmarshal(b, t.GraphDefs_StarterPackViewBasic) 208 - 209 207 default: 210 208 return nil 211 209 }
+6 -8
api/bsky/embedrecordWithMedia.go
··· 10 10 "fmt" 11 11 "io" 12 12 13 - "github.com/bluesky-social/indigo/lex/util" 13 + lexutil "github.com/bluesky-social/indigo/lex/util" 14 14 cbg "github.com/whyrusleeping/cbor-gen" 15 15 ) 16 16 17 17 func init() { 18 - util.RegisterType("app.bsky.embed.recordWithMedia#main", &EmbedRecordWithMedia{}) 18 + lexutil.RegisterType("app.bsky.embed.recordWithMedia#main", &EmbedRecordWithMedia{}) 19 19 } 20 20 21 21 // EmbedRecordWithMedia is a "main" in the app.bsky.embed.recordWithMedia schema. ··· 48 48 } 49 49 50 50 func (t *EmbedRecordWithMedia_Media) UnmarshalJSON(b []byte) error { 51 - typ, err := util.TypeExtract(b) 51 + typ, err := lexutil.TypeExtract(b) 52 52 if err != nil { 53 53 return err 54 54 } ··· 63 63 case "app.bsky.embed.external": 64 64 t.EmbedExternal = new(EmbedExternal) 65 65 return json.Unmarshal(b, t.EmbedExternal) 66 - 67 66 default: 68 67 return nil 69 68 } ··· 86 85 } 87 86 return fmt.Errorf("can not marshal empty union as CBOR") 88 87 } 88 + 89 89 func (t *EmbedRecordWithMedia_Media) UnmarshalCBOR(r io.Reader) error { 90 - typ, b, err := util.CborTypeExtractReader(r) 90 + typ, b, err := lexutil.CborTypeExtractReader(r) 91 91 if err != nil { 92 92 return err 93 93 } ··· 102 102 case "app.bsky.embed.external": 103 103 t.EmbedExternal = new(EmbedExternal) 104 104 return t.EmbedExternal.UnmarshalCBOR(bytes.NewReader(b)) 105 - 106 105 default: 107 106 return nil 108 107 } ··· 138 137 } 139 138 140 139 func (t *EmbedRecordWithMedia_View_Media) UnmarshalJSON(b []byte) error { 141 - typ, err := util.TypeExtract(b) 140 + typ, err := lexutil.TypeExtract(b) 142 141 if err != nil { 143 142 return err 144 143 } ··· 153 152 case "app.bsky.embed.external#view": 154 153 t.EmbedExternal_View = new(EmbedExternal_View) 155 154 return json.Unmarshal(b, t.EmbedExternal_View) 156 - 157 155 default: 158 156 return nil 159 157 }
+5 -5
api/bsky/embedvideo.go
··· 5 5 package bsky 6 6 7 7 import ( 8 - "github.com/bluesky-social/indigo/lex/util" 8 + lexutil "github.com/bluesky-social/indigo/lex/util" 9 9 ) 10 10 11 11 func init() { 12 - util.RegisterType("app.bsky.embed.video#main", &EmbedVideo{}) 12 + lexutil.RegisterType("app.bsky.embed.video#main", &EmbedVideo{}) 13 13 } 14 14 15 15 // EmbedVideo is a "main" in the app.bsky.embed.video schema. ··· 20 20 AspectRatio *EmbedDefs_AspectRatio `json:"aspectRatio,omitempty" cborgen:"aspectRatio,omitempty"` 21 21 Captions []*EmbedVideo_Caption `json:"captions,omitempty" cborgen:"captions,omitempty"` 22 22 // video: The mp4 video file. May be up to 100mb, formerly limited to 50mb. 23 - Video *util.LexBlob `json:"video" cborgen:"video"` 23 + Video *lexutil.LexBlob `json:"video" cborgen:"video"` 24 24 } 25 25 26 26 // EmbedVideo_Caption is a "caption" in the app.bsky.embed.video schema. 27 27 type EmbedVideo_Caption struct { 28 - File *util.LexBlob `json:"file" cborgen:"file"` 29 - Lang string `json:"lang" cborgen:"lang"` 28 + File *lexutil.LexBlob `json:"file" cborgen:"file"` 29 + Lang string `json:"lang" cborgen:"lang"` 30 30 } 31 31 32 32 // EmbedVideo_View is a "view" in the app.bsky.embed.video schema.
+43 -50
api/bsky/feeddefs.go
··· 8 8 "encoding/json" 9 9 "fmt" 10 10 11 - comatprototypes "github.com/bluesky-social/indigo/api/atproto" 12 - "github.com/bluesky-social/indigo/lex/util" 11 + comatproto "github.com/bluesky-social/indigo/api/atproto" 12 + lexutil "github.com/bluesky-social/indigo/lex/util" 13 13 ) 14 14 15 15 // FeedDefs_BlockedAuthor is a "blockedAuthor" in the app.bsky.feed.defs schema. ··· 55 55 } 56 56 57 57 func (t *FeedDefs_FeedViewPost_Reason) UnmarshalJSON(b []byte) error { 58 - typ, err := util.TypeExtract(b) 58 + typ, err := lexutil.TypeExtract(b) 59 59 if err != nil { 60 60 return err 61 61 } ··· 67 67 case "app.bsky.feed.defs#reasonPin": 68 68 t.FeedDefs_ReasonPin = new(FeedDefs_ReasonPin) 69 69 return json.Unmarshal(b, t.FeedDefs_ReasonPin) 70 - 71 70 default: 72 71 return nil 73 72 } ··· 75 74 76 75 // FeedDefs_GeneratorView is a "generatorView" in the app.bsky.feed.defs schema. 77 76 type FeedDefs_GeneratorView struct { 78 - LexiconTypeID string `json:"$type" cborgen:"$type,const=app.bsky.feed.defs#generatorView"` 79 - AcceptsInteractions *bool `json:"acceptsInteractions,omitempty" cborgen:"acceptsInteractions,omitempty"` 80 - Avatar *string `json:"avatar,omitempty" cborgen:"avatar,omitempty"` 81 - Cid string `json:"cid" cborgen:"cid"` 82 - ContentMode *string `json:"contentMode,omitempty" cborgen:"contentMode,omitempty"` 83 - Creator *ActorDefs_ProfileView `json:"creator" cborgen:"creator"` 84 - Description *string `json:"description,omitempty" cborgen:"description,omitempty"` 85 - DescriptionFacets []*RichtextFacet `json:"descriptionFacets,omitempty" cborgen:"descriptionFacets,omitempty"` 86 - Did string `json:"did" cborgen:"did"` 87 - DisplayName string `json:"displayName" cborgen:"displayName"` 88 - IndexedAt string `json:"indexedAt" cborgen:"indexedAt"` 89 - Labels []*comatprototypes.LabelDefs_Label `json:"labels,omitempty" cborgen:"labels,omitempty"` 90 - LikeCount *int64 `json:"likeCount,omitempty" cborgen:"likeCount,omitempty"` 91 - Uri string `json:"uri" cborgen:"uri"` 92 - Viewer *FeedDefs_GeneratorViewerState `json:"viewer,omitempty" cborgen:"viewer,omitempty"` 77 + LexiconTypeID string `json:"$type" cborgen:"$type,const=app.bsky.feed.defs#generatorView"` 78 + AcceptsInteractions *bool `json:"acceptsInteractions,omitempty" cborgen:"acceptsInteractions,omitempty"` 79 + Avatar *string `json:"avatar,omitempty" cborgen:"avatar,omitempty"` 80 + Cid string `json:"cid" cborgen:"cid"` 81 + ContentMode *string `json:"contentMode,omitempty" cborgen:"contentMode,omitempty"` 82 + Creator *ActorDefs_ProfileView `json:"creator" cborgen:"creator"` 83 + Description *string `json:"description,omitempty" cborgen:"description,omitempty"` 84 + DescriptionFacets []*RichtextFacet `json:"descriptionFacets,omitempty" cborgen:"descriptionFacets,omitempty"` 85 + Did string `json:"did" cborgen:"did"` 86 + DisplayName string `json:"displayName" cborgen:"displayName"` 87 + IndexedAt string `json:"indexedAt" cborgen:"indexedAt"` 88 + Labels []*comatproto.LabelDefs_Label `json:"labels,omitempty" cborgen:"labels,omitempty"` 89 + LikeCount *int64 `json:"likeCount,omitempty" cborgen:"likeCount,omitempty"` 90 + Uri string `json:"uri" cborgen:"uri"` 91 + Viewer *FeedDefs_GeneratorViewerState `json:"viewer,omitempty" cborgen:"viewer,omitempty"` 93 92 } 94 93 95 94 // FeedDefs_GeneratorViewerState is a "generatorViewerState" in the app.bsky.feed.defs schema. ··· 116 115 117 116 // FeedDefs_PostView is a "postView" in the app.bsky.feed.defs schema. 118 117 type FeedDefs_PostView struct { 119 - LexiconTypeID string `json:"$type" cborgen:"$type,const=app.bsky.feed.defs#postView"` 120 - Author *ActorDefs_ProfileViewBasic `json:"author" cborgen:"author"` 121 - BookmarkCount *int64 `json:"bookmarkCount,omitempty" cborgen:"bookmarkCount,omitempty"` 122 - Cid string `json:"cid" cborgen:"cid"` 123 - Embed *FeedDefs_PostView_Embed `json:"embed,omitempty" cborgen:"embed,omitempty"` 124 - IndexedAt string `json:"indexedAt" cborgen:"indexedAt"` 125 - Labels []*comatprototypes.LabelDefs_Label `json:"labels,omitempty" cborgen:"labels,omitempty"` 126 - LikeCount *int64 `json:"likeCount,omitempty" cborgen:"likeCount,omitempty"` 127 - QuoteCount *int64 `json:"quoteCount,omitempty" cborgen:"quoteCount,omitempty"` 128 - Record *util.LexiconTypeDecoder `json:"record" cborgen:"record"` 129 - ReplyCount *int64 `json:"replyCount,omitempty" cborgen:"replyCount,omitempty"` 130 - RepostCount *int64 `json:"repostCount,omitempty" cborgen:"repostCount,omitempty"` 131 - Threadgate *FeedDefs_ThreadgateView `json:"threadgate,omitempty" cborgen:"threadgate,omitempty"` 132 - Uri string `json:"uri" cborgen:"uri"` 133 - Viewer *FeedDefs_ViewerState `json:"viewer,omitempty" cborgen:"viewer,omitempty"` 118 + LexiconTypeID string `json:"$type" cborgen:"$type,const=app.bsky.feed.defs#postView"` 119 + Author *ActorDefs_ProfileViewBasic `json:"author" cborgen:"author"` 120 + BookmarkCount *int64 `json:"bookmarkCount,omitempty" cborgen:"bookmarkCount,omitempty"` 121 + Cid string `json:"cid" cborgen:"cid"` 122 + Embed *FeedDefs_PostView_Embed `json:"embed,omitempty" cborgen:"embed,omitempty"` 123 + IndexedAt string `json:"indexedAt" cborgen:"indexedAt"` 124 + Labels []*comatproto.LabelDefs_Label `json:"labels,omitempty" cborgen:"labels,omitempty"` 125 + LikeCount *int64 `json:"likeCount,omitempty" cborgen:"likeCount,omitempty"` 126 + QuoteCount *int64 `json:"quoteCount,omitempty" cborgen:"quoteCount,omitempty"` 127 + Record *lexutil.LexiconTypeDecoder `json:"record" cborgen:"record"` 128 + ReplyCount *int64 `json:"replyCount,omitempty" cborgen:"replyCount,omitempty"` 129 + RepostCount *int64 `json:"repostCount,omitempty" cborgen:"repostCount,omitempty"` 130 + Threadgate *FeedDefs_ThreadgateView `json:"threadgate,omitempty" cborgen:"threadgate,omitempty"` 131 + Uri string `json:"uri" cborgen:"uri"` 132 + Viewer *FeedDefs_ViewerState `json:"viewer,omitempty" cborgen:"viewer,omitempty"` 134 133 } 135 134 136 135 type FeedDefs_PostView_Embed struct { ··· 166 165 } 167 166 168 167 func (t *FeedDefs_PostView_Embed) UnmarshalJSON(b []byte) error { 169 - typ, err := util.TypeExtract(b) 168 + typ, err := lexutil.TypeExtract(b) 170 169 if err != nil { 171 170 return err 172 171 } ··· 187 186 case "app.bsky.embed.recordWithMedia#view": 188 187 t.EmbedRecordWithMedia_View = new(EmbedRecordWithMedia_View) 189 188 return json.Unmarshal(b, t.EmbedRecordWithMedia_View) 190 - 191 189 default: 192 190 return nil 193 191 } ··· 238 236 } 239 237 240 238 func (t *FeedDefs_ReplyRef_Parent) UnmarshalJSON(b []byte) error { 241 - typ, err := util.TypeExtract(b) 239 + typ, err := lexutil.TypeExtract(b) 242 240 if err != nil { 243 241 return err 244 242 } ··· 253 251 case "app.bsky.feed.defs#blockedPost": 254 252 t.FeedDefs_BlockedPost = new(FeedDefs_BlockedPost) 255 253 return json.Unmarshal(b, t.FeedDefs_BlockedPost) 256 - 257 254 default: 258 255 return nil 259 256 } ··· 282 279 } 283 280 284 281 func (t *FeedDefs_ReplyRef_Root) UnmarshalJSON(b []byte) error { 285 - typ, err := util.TypeExtract(b) 282 + typ, err := lexutil.TypeExtract(b) 286 283 if err != nil { 287 284 return err 288 285 } ··· 297 294 case "app.bsky.feed.defs#blockedPost": 298 295 t.FeedDefs_BlockedPost = new(FeedDefs_BlockedPost) 299 296 return json.Unmarshal(b, t.FeedDefs_BlockedPost) 300 - 301 297 default: 302 298 return nil 303 299 } ··· 329 325 } 330 326 331 327 func (t *FeedDefs_SkeletonFeedPost_Reason) UnmarshalJSON(b []byte) error { 332 - typ, err := util.TypeExtract(b) 328 + typ, err := lexutil.TypeExtract(b) 333 329 if err != nil { 334 330 return err 335 331 } ··· 341 337 case "app.bsky.feed.defs#skeletonReasonPin": 342 338 t.FeedDefs_SkeletonReasonPin = new(FeedDefs_SkeletonReasonPin) 343 339 return json.Unmarshal(b, t.FeedDefs_SkeletonReasonPin) 344 - 345 340 default: 346 341 return nil 347 342 } ··· 397 392 } 398 393 399 394 func (t *FeedDefs_ThreadViewPost_Parent) UnmarshalJSON(b []byte) error { 400 - typ, err := util.TypeExtract(b) 395 + typ, err := lexutil.TypeExtract(b) 401 396 if err != nil { 402 397 return err 403 398 } ··· 412 407 case "app.bsky.feed.defs#blockedPost": 413 408 t.FeedDefs_BlockedPost = new(FeedDefs_BlockedPost) 414 409 return json.Unmarshal(b, t.FeedDefs_BlockedPost) 415 - 416 410 default: 417 411 return nil 418 412 } ··· 441 435 } 442 436 443 437 func (t *FeedDefs_ThreadViewPost_Replies_Elem) UnmarshalJSON(b []byte) error { 444 - typ, err := util.TypeExtract(b) 438 + typ, err := lexutil.TypeExtract(b) 445 439 if err != nil { 446 440 return err 447 441 } ··· 456 450 case "app.bsky.feed.defs#blockedPost": 457 451 t.FeedDefs_BlockedPost = new(FeedDefs_BlockedPost) 458 452 return json.Unmarshal(b, t.FeedDefs_BlockedPost) 459 - 460 453 default: 461 454 return nil 462 455 } ··· 464 457 465 458 // FeedDefs_ThreadgateView is a "threadgateView" in the app.bsky.feed.defs schema. 466 459 type FeedDefs_ThreadgateView struct { 467 - Cid *string `json:"cid,omitempty" cborgen:"cid,omitempty"` 468 - Lists []*GraphDefs_ListViewBasic `json:"lists,omitempty" cborgen:"lists,omitempty"` 469 - Record *util.LexiconTypeDecoder `json:"record,omitempty" cborgen:"record,omitempty"` 470 - Uri *string `json:"uri,omitempty" cborgen:"uri,omitempty"` 460 + Cid *string `json:"cid,omitempty" cborgen:"cid,omitempty"` 461 + Lists []*GraphDefs_ListViewBasic `json:"lists,omitempty" cborgen:"lists,omitempty"` 462 + Record *lexutil.LexiconTypeDecoder `json:"record,omitempty" cborgen:"record,omitempty"` 463 + Uri *string `json:"uri,omitempty" cborgen:"uri,omitempty"` 471 464 } 472 465 473 466 // FeedDefs_ViewerState is a "viewerState" in the app.bsky.feed.defs schema.
+3 -3
api/bsky/feeddescribeFeedGenerator.go
··· 7 7 import ( 8 8 "context" 9 9 10 - "github.com/bluesky-social/indigo/lex/util" 10 + lexutil "github.com/bluesky-social/indigo/lex/util" 11 11 ) 12 12 13 13 // FeedDescribeFeedGenerator_Feed is a "feed" in the app.bsky.feed.describeFeedGenerator schema. ··· 29 29 } 30 30 31 31 // FeedDescribeFeedGenerator calls the XRPC method "app.bsky.feed.describeFeedGenerator". 32 - func FeedDescribeFeedGenerator(ctx context.Context, c util.LexClient) (*FeedDescribeFeedGenerator_Output, error) { 32 + func FeedDescribeFeedGenerator(ctx context.Context, c lexutil.LexClient) (*FeedDescribeFeedGenerator_Output, error) { 33 33 var out FeedDescribeFeedGenerator_Output 34 - if err := c.LexDo(ctx, util.Query, "", "app.bsky.feed.describeFeedGenerator", nil, nil, &out); err != nil { 34 + if err := c.LexDo(ctx, lexutil.Query, "", "app.bsky.feed.describeFeedGenerator", nil, nil, &out); err != nil { 35 35 return nil, err 36 36 } 37 37
+10 -11
api/bsky/feedgenerator.go
··· 10 10 "fmt" 11 11 "io" 12 12 13 - comatprototypes "github.com/bluesky-social/indigo/api/atproto" 14 - "github.com/bluesky-social/indigo/lex/util" 13 + comatproto "github.com/bluesky-social/indigo/api/atproto" 14 + lexutil "github.com/bluesky-social/indigo/lex/util" 15 15 cbg "github.com/whyrusleeping/cbor-gen" 16 16 ) 17 17 18 18 func init() { 19 - util.RegisterType("app.bsky.feed.generator", &FeedGenerator{}) 19 + lexutil.RegisterType("app.bsky.feed.generator", &FeedGenerator{}) 20 20 } 21 21 22 22 type FeedGenerator struct { 23 23 LexiconTypeID string `json:"$type" cborgen:"$type,const=app.bsky.feed.generator"` 24 24 // acceptsInteractions: Declaration that a feed accepts feedback interactions from a client through app.bsky.feed.sendInteractions 25 25 AcceptsInteractions *bool `json:"acceptsInteractions,omitempty" cborgen:"acceptsInteractions,omitempty"` 26 - Avatar *util.LexBlob `json:"avatar,omitempty" cborgen:"avatar,omitempty"` 26 + Avatar *lexutil.LexBlob `json:"avatar,omitempty" cborgen:"avatar,omitempty"` 27 27 ContentMode *string `json:"contentMode,omitempty" cborgen:"contentMode,omitempty"` 28 28 CreatedAt string `json:"createdAt" cborgen:"createdAt"` 29 29 Description *string `json:"description,omitempty" cborgen:"description,omitempty"` ··· 36 36 37 37 // Self-label values 38 38 type FeedGenerator_Labels struct { 39 - LabelDefs_SelfLabels *comatprototypes.LabelDefs_SelfLabels 39 + LabelDefs_SelfLabels *comatproto.LabelDefs_SelfLabels 40 40 } 41 41 42 42 func (t *FeedGenerator_Labels) MarshalJSON() ([]byte, error) { ··· 48 48 } 49 49 50 50 func (t *FeedGenerator_Labels) UnmarshalJSON(b []byte) error { 51 - typ, err := util.TypeExtract(b) 51 + typ, err := lexutil.TypeExtract(b) 52 52 if err != nil { 53 53 return err 54 54 } 55 55 56 56 switch typ { 57 57 case "com.atproto.label.defs#selfLabels": 58 - t.LabelDefs_SelfLabels = new(comatprototypes.LabelDefs_SelfLabels) 58 + t.LabelDefs_SelfLabels = new(comatproto.LabelDefs_SelfLabels) 59 59 return json.Unmarshal(b, t.LabelDefs_SelfLabels) 60 - 61 60 default: 62 61 return nil 63 62 } ··· 74 73 } 75 74 return fmt.Errorf("can not marshal empty union as CBOR") 76 75 } 76 + 77 77 func (t *FeedGenerator_Labels) UnmarshalCBOR(r io.Reader) error { 78 - typ, b, err := util.CborTypeExtractReader(r) 78 + typ, b, err := lexutil.CborTypeExtractReader(r) 79 79 if err != nil { 80 80 return err 81 81 } 82 82 83 83 switch typ { 84 84 case "com.atproto.label.defs#selfLabels": 85 - t.LabelDefs_SelfLabels = new(comatprototypes.LabelDefs_SelfLabels) 85 + t.LabelDefs_SelfLabels = new(comatproto.LabelDefs_SelfLabels) 86 86 return t.LabelDefs_SelfLabels.UnmarshalCBOR(bytes.NewReader(b)) 87 - 88 87 default: 89 88 return nil 90 89 }
+3 -3
api/bsky/feedgetActorFeeds.go
··· 7 7 import ( 8 8 "context" 9 9 10 - "github.com/bluesky-social/indigo/lex/util" 10 + lexutil "github.com/bluesky-social/indigo/lex/util" 11 11 ) 12 12 13 13 // FeedGetActorFeeds_Output is the output of a app.bsky.feed.getActorFeeds call. ··· 17 17 } 18 18 19 19 // FeedGetActorFeeds calls the XRPC method "app.bsky.feed.getActorFeeds". 20 - func FeedGetActorFeeds(ctx context.Context, c util.LexClient, actor string, cursor string, limit int64) (*FeedGetActorFeeds_Output, error) { 20 + func FeedGetActorFeeds(ctx context.Context, c lexutil.LexClient, actor string, cursor string, limit int64) (*FeedGetActorFeeds_Output, error) { 21 21 var out FeedGetActorFeeds_Output 22 22 23 23 params := map[string]interface{}{} ··· 28 28 if limit != 0 { 29 29 params["limit"] = limit 30 30 } 31 - if err := c.LexDo(ctx, util.Query, "", "app.bsky.feed.getActorFeeds", params, nil, &out); err != nil { 31 + if err := c.LexDo(ctx, lexutil.Query, "", "app.bsky.feed.getActorFeeds", params, nil, &out); err != nil { 32 32 return nil, err 33 33 } 34 34
+3 -3
api/bsky/feedgetActorLikes.go
··· 7 7 import ( 8 8 "context" 9 9 10 - "github.com/bluesky-social/indigo/lex/util" 10 + lexutil "github.com/bluesky-social/indigo/lex/util" 11 11 ) 12 12 13 13 // FeedGetActorLikes_Output is the output of a app.bsky.feed.getActorLikes call. ··· 17 17 } 18 18 19 19 // FeedGetActorLikes calls the XRPC method "app.bsky.feed.getActorLikes". 20 - func FeedGetActorLikes(ctx context.Context, c util.LexClient, actor string, cursor string, limit int64) (*FeedGetActorLikes_Output, error) { 20 + func FeedGetActorLikes(ctx context.Context, c lexutil.LexClient, actor string, cursor string, limit int64) (*FeedGetActorLikes_Output, error) { 21 21 var out FeedGetActorLikes_Output 22 22 23 23 params := map[string]interface{}{} ··· 28 28 if limit != 0 { 29 29 params["limit"] = limit 30 30 } 31 - if err := c.LexDo(ctx, util.Query, "", "app.bsky.feed.getActorLikes", params, nil, &out); err != nil { 31 + if err := c.LexDo(ctx, lexutil.Query, "", "app.bsky.feed.getActorLikes", params, nil, &out); err != nil { 32 32 return nil, err 33 33 } 34 34
+3 -3
api/bsky/feedgetAuthorFeed.go
··· 7 7 import ( 8 8 "context" 9 9 10 - "github.com/bluesky-social/indigo/lex/util" 10 + lexutil "github.com/bluesky-social/indigo/lex/util" 11 11 ) 12 12 13 13 // FeedGetAuthorFeed_Output is the output of a app.bsky.feed.getAuthorFeed call. ··· 19 19 // FeedGetAuthorFeed calls the XRPC method "app.bsky.feed.getAuthorFeed". 20 20 // 21 21 // filter: Combinations of post/repost types to include in response. 22 - func FeedGetAuthorFeed(ctx context.Context, c util.LexClient, actor string, cursor string, filter string, includePins bool, limit int64) (*FeedGetAuthorFeed_Output, error) { 22 + func FeedGetAuthorFeed(ctx context.Context, c lexutil.LexClient, actor string, cursor string, filter string, includePins bool, limit int64) (*FeedGetAuthorFeed_Output, error) { 23 23 var out FeedGetAuthorFeed_Output 24 24 25 25 params := map[string]interface{}{} ··· 36 36 if limit != 0 { 37 37 params["limit"] = limit 38 38 } 39 - if err := c.LexDo(ctx, util.Query, "", "app.bsky.feed.getAuthorFeed", params, nil, &out); err != nil { 39 + if err := c.LexDo(ctx, lexutil.Query, "", "app.bsky.feed.getAuthorFeed", params, nil, &out); err != nil { 40 40 return nil, err 41 41 } 42 42
+3 -3
api/bsky/feedgetFeed.go
··· 7 7 import ( 8 8 "context" 9 9 10 - "github.com/bluesky-social/indigo/lex/util" 10 + lexutil "github.com/bluesky-social/indigo/lex/util" 11 11 ) 12 12 13 13 // FeedGetFeed_Output is the output of a app.bsky.feed.getFeed call. ··· 17 17 } 18 18 19 19 // FeedGetFeed calls the XRPC method "app.bsky.feed.getFeed". 20 - func FeedGetFeed(ctx context.Context, c util.LexClient, cursor string, feed string, limit int64) (*FeedGetFeed_Output, error) { 20 + func FeedGetFeed(ctx context.Context, c lexutil.LexClient, cursor string, feed string, limit int64) (*FeedGetFeed_Output, error) { 21 21 var out FeedGetFeed_Output 22 22 23 23 params := map[string]interface{}{} ··· 28 28 if limit != 0 { 29 29 params["limit"] = limit 30 30 } 31 - if err := c.LexDo(ctx, util.Query, "", "app.bsky.feed.getFeed", params, nil, &out); err != nil { 31 + if err := c.LexDo(ctx, lexutil.Query, "", "app.bsky.feed.getFeed", params, nil, &out); err != nil { 32 32 return nil, err 33 33 } 34 34
+3 -3
api/bsky/feedgetFeedGenerator.go
··· 7 7 import ( 8 8 "context" 9 9 10 - "github.com/bluesky-social/indigo/lex/util" 10 + lexutil "github.com/bluesky-social/indigo/lex/util" 11 11 ) 12 12 13 13 // FeedGetFeedGenerator_Output is the output of a app.bsky.feed.getFeedGenerator call. ··· 22 22 // FeedGetFeedGenerator calls the XRPC method "app.bsky.feed.getFeedGenerator". 23 23 // 24 24 // feed: AT-URI of the feed generator record. 25 - func FeedGetFeedGenerator(ctx context.Context, c util.LexClient, feed string) (*FeedGetFeedGenerator_Output, error) { 25 + func FeedGetFeedGenerator(ctx context.Context, c lexutil.LexClient, feed string) (*FeedGetFeedGenerator_Output, error) { 26 26 var out FeedGetFeedGenerator_Output 27 27 28 28 params := map[string]interface{}{} 29 29 params["feed"] = feed 30 - if err := c.LexDo(ctx, util.Query, "", "app.bsky.feed.getFeedGenerator", params, nil, &out); err != nil { 30 + if err := c.LexDo(ctx, lexutil.Query, "", "app.bsky.feed.getFeedGenerator", params, nil, &out); err != nil { 31 31 return nil, err 32 32 } 33 33
+3 -3
api/bsky/feedgetFeedGenerators.go
··· 7 7 import ( 8 8 "context" 9 9 10 - "github.com/bluesky-social/indigo/lex/util" 10 + lexutil "github.com/bluesky-social/indigo/lex/util" 11 11 ) 12 12 13 13 // FeedGetFeedGenerators_Output is the output of a app.bsky.feed.getFeedGenerators call. ··· 16 16 } 17 17 18 18 // FeedGetFeedGenerators calls the XRPC method "app.bsky.feed.getFeedGenerators". 19 - func FeedGetFeedGenerators(ctx context.Context, c util.LexClient, feeds []string) (*FeedGetFeedGenerators_Output, error) { 19 + func FeedGetFeedGenerators(ctx context.Context, c lexutil.LexClient, feeds []string) (*FeedGetFeedGenerators_Output, error) { 20 20 var out FeedGetFeedGenerators_Output 21 21 22 22 params := map[string]interface{}{} 23 23 params["feeds"] = feeds 24 - if err := c.LexDo(ctx, util.Query, "", "app.bsky.feed.getFeedGenerators", params, nil, &out); err != nil { 24 + if err := c.LexDo(ctx, lexutil.Query, "", "app.bsky.feed.getFeedGenerators", params, nil, &out); err != nil { 25 25 return nil, err 26 26 } 27 27
+3 -3
api/bsky/feedgetFeedSkeleton.go
··· 7 7 import ( 8 8 "context" 9 9 10 - "github.com/bluesky-social/indigo/lex/util" 10 + lexutil "github.com/bluesky-social/indigo/lex/util" 11 11 ) 12 12 13 13 // FeedGetFeedSkeleton_Output is the output of a app.bsky.feed.getFeedSkeleton call. ··· 21 21 // FeedGetFeedSkeleton calls the XRPC method "app.bsky.feed.getFeedSkeleton". 22 22 // 23 23 // feed: Reference to feed generator record describing the specific feed being requested. 24 - func FeedGetFeedSkeleton(ctx context.Context, c util.LexClient, cursor string, feed string, limit int64) (*FeedGetFeedSkeleton_Output, error) { 24 + func FeedGetFeedSkeleton(ctx context.Context, c lexutil.LexClient, cursor string, feed string, limit int64) (*FeedGetFeedSkeleton_Output, error) { 25 25 var out FeedGetFeedSkeleton_Output 26 26 27 27 params := map[string]interface{}{} ··· 32 32 if limit != 0 { 33 33 params["limit"] = limit 34 34 } 35 - if err := c.LexDo(ctx, util.Query, "", "app.bsky.feed.getFeedSkeleton", params, nil, &out); err != nil { 35 + if err := c.LexDo(ctx, lexutil.Query, "", "app.bsky.feed.getFeedSkeleton", params, nil, &out); err != nil { 36 36 return nil, err 37 37 } 38 38
+3 -3
api/bsky/feedgetLikes.go
··· 7 7 import ( 8 8 "context" 9 9 10 - "github.com/bluesky-social/indigo/lex/util" 10 + lexutil "github.com/bluesky-social/indigo/lex/util" 11 11 ) 12 12 13 13 // FeedGetLikes_Like is a "like" in the app.bsky.feed.getLikes schema. ··· 29 29 // 30 30 // cid: CID of the subject record (aka, specific version of record), to filter likes. 31 31 // uri: AT-URI of the subject (eg, a post record). 32 - func FeedGetLikes(ctx context.Context, c util.LexClient, cid string, cursor string, limit int64, uri string) (*FeedGetLikes_Output, error) { 32 + func FeedGetLikes(ctx context.Context, c lexutil.LexClient, cid string, cursor string, limit int64, uri string) (*FeedGetLikes_Output, error) { 33 33 var out FeedGetLikes_Output 34 34 35 35 params := map[string]interface{}{} ··· 43 43 params["limit"] = limit 44 44 } 45 45 params["uri"] = uri 46 - if err := c.LexDo(ctx, util.Query, "", "app.bsky.feed.getLikes", params, nil, &out); err != nil { 46 + if err := c.LexDo(ctx, lexutil.Query, "", "app.bsky.feed.getLikes", params, nil, &out); err != nil { 47 47 return nil, err 48 48 } 49 49
+3 -3
api/bsky/feedgetListFeed.go
··· 7 7 import ( 8 8 "context" 9 9 10 - "github.com/bluesky-social/indigo/lex/util" 10 + lexutil "github.com/bluesky-social/indigo/lex/util" 11 11 ) 12 12 13 13 // FeedGetListFeed_Output is the output of a app.bsky.feed.getListFeed call. ··· 19 19 // FeedGetListFeed calls the XRPC method "app.bsky.feed.getListFeed". 20 20 // 21 21 // list: Reference (AT-URI) to the list record. 22 - func FeedGetListFeed(ctx context.Context, c util.LexClient, cursor string, limit int64, list string) (*FeedGetListFeed_Output, error) { 22 + func FeedGetListFeed(ctx context.Context, c lexutil.LexClient, cursor string, limit int64, list string) (*FeedGetListFeed_Output, error) { 23 23 var out FeedGetListFeed_Output 24 24 25 25 params := map[string]interface{}{} ··· 30 30 params["limit"] = limit 31 31 } 32 32 params["list"] = list 33 - if err := c.LexDo(ctx, util.Query, "", "app.bsky.feed.getListFeed", params, nil, &out); err != nil { 33 + if err := c.LexDo(ctx, lexutil.Query, "", "app.bsky.feed.getListFeed", params, nil, &out); err != nil { 34 34 return nil, err 35 35 } 36 36
+4 -5
api/bsky/feedgetPostThread.go
··· 9 9 "encoding/json" 10 10 "fmt" 11 11 12 - "github.com/bluesky-social/indigo/lex/util" 12 + lexutil "github.com/bluesky-social/indigo/lex/util" 13 13 ) 14 14 15 15 // FeedGetPostThread_Output is the output of a app.bsky.feed.getPostThread call. ··· 41 41 } 42 42 43 43 func (t *FeedGetPostThread_Output_Thread) UnmarshalJSON(b []byte) error { 44 - typ, err := util.TypeExtract(b) 44 + typ, err := lexutil.TypeExtract(b) 45 45 if err != nil { 46 46 return err 47 47 } ··· 56 56 case "app.bsky.feed.defs#blockedPost": 57 57 t.FeedDefs_BlockedPost = new(FeedDefs_BlockedPost) 58 58 return json.Unmarshal(b, t.FeedDefs_BlockedPost) 59 - 60 59 default: 61 60 return nil 62 61 } ··· 67 66 // depth: How many levels of reply depth should be included in response. 68 67 // parentHeight: How many levels of parent (and grandparent, etc) post to include. 69 68 // uri: Reference (AT-URI) to post record. 70 - func FeedGetPostThread(ctx context.Context, c util.LexClient, depth int64, parentHeight int64, uri string) (*FeedGetPostThread_Output, error) { 69 + func FeedGetPostThread(ctx context.Context, c lexutil.LexClient, depth int64, parentHeight int64, uri string) (*FeedGetPostThread_Output, error) { 71 70 var out FeedGetPostThread_Output 72 71 73 72 params := map[string]interface{}{} ··· 78 77 params["parentHeight"] = parentHeight 79 78 } 80 79 params["uri"] = uri 81 - if err := c.LexDo(ctx, util.Query, "", "app.bsky.feed.getPostThread", params, nil, &out); err != nil { 80 + if err := c.LexDo(ctx, lexutil.Query, "", "app.bsky.feed.getPostThread", params, nil, &out); err != nil { 82 81 return nil, err 83 82 } 84 83
+3 -3
api/bsky/feedgetPosts.go
··· 7 7 import ( 8 8 "context" 9 9 10 - "github.com/bluesky-social/indigo/lex/util" 10 + lexutil "github.com/bluesky-social/indigo/lex/util" 11 11 ) 12 12 13 13 // FeedGetPosts_Output is the output of a app.bsky.feed.getPosts call. ··· 18 18 // FeedGetPosts calls the XRPC method "app.bsky.feed.getPosts". 19 19 // 20 20 // uris: List of post AT-URIs to return hydrated views for. 21 - func FeedGetPosts(ctx context.Context, c util.LexClient, uris []string) (*FeedGetPosts_Output, error) { 21 + func FeedGetPosts(ctx context.Context, c lexutil.LexClient, uris []string) (*FeedGetPosts_Output, error) { 22 22 var out FeedGetPosts_Output 23 23 24 24 params := map[string]interface{}{} 25 25 params["uris"] = uris 26 - if err := c.LexDo(ctx, util.Query, "", "app.bsky.feed.getPosts", params, nil, &out); err != nil { 26 + if err := c.LexDo(ctx, lexutil.Query, "", "app.bsky.feed.getPosts", params, nil, &out); err != nil { 27 27 return nil, err 28 28 } 29 29
+3 -3
api/bsky/feedgetQuotes.go
··· 7 7 import ( 8 8 "context" 9 9 10 - "github.com/bluesky-social/indigo/lex/util" 10 + lexutil "github.com/bluesky-social/indigo/lex/util" 11 11 ) 12 12 13 13 // FeedGetQuotes_Output is the output of a app.bsky.feed.getQuotes call. ··· 22 22 // 23 23 // cid: If supplied, filters to quotes of specific version (by CID) of the post record. 24 24 // uri: Reference (AT-URI) of post record 25 - func FeedGetQuotes(ctx context.Context, c util.LexClient, cid string, cursor string, limit int64, uri string) (*FeedGetQuotes_Output, error) { 25 + func FeedGetQuotes(ctx context.Context, c lexutil.LexClient, cid string, cursor string, limit int64, uri string) (*FeedGetQuotes_Output, error) { 26 26 var out FeedGetQuotes_Output 27 27 28 28 params := map[string]interface{}{} ··· 36 36 params["limit"] = limit 37 37 } 38 38 params["uri"] = uri 39 - if err := c.LexDo(ctx, util.Query, "", "app.bsky.feed.getQuotes", params, nil, &out); err != nil { 39 + if err := c.LexDo(ctx, lexutil.Query, "", "app.bsky.feed.getQuotes", params, nil, &out); err != nil { 40 40 return nil, err 41 41 } 42 42
+3 -3
api/bsky/feedgetRepostedBy.go
··· 7 7 import ( 8 8 "context" 9 9 10 - "github.com/bluesky-social/indigo/lex/util" 10 + lexutil "github.com/bluesky-social/indigo/lex/util" 11 11 ) 12 12 13 13 // FeedGetRepostedBy_Output is the output of a app.bsky.feed.getRepostedBy call. ··· 22 22 // 23 23 // cid: If supplied, filters to reposts of specific version (by CID) of the post record. 24 24 // uri: Reference (AT-URI) of post record 25 - func FeedGetRepostedBy(ctx context.Context, c util.LexClient, cid string, cursor string, limit int64, uri string) (*FeedGetRepostedBy_Output, error) { 25 + func FeedGetRepostedBy(ctx context.Context, c lexutil.LexClient, cid string, cursor string, limit int64, uri string) (*FeedGetRepostedBy_Output, error) { 26 26 var out FeedGetRepostedBy_Output 27 27 28 28 params := map[string]interface{}{} ··· 36 36 params["limit"] = limit 37 37 } 38 38 params["uri"] = uri 39 - if err := c.LexDo(ctx, util.Query, "", "app.bsky.feed.getRepostedBy", params, nil, &out); err != nil { 39 + if err := c.LexDo(ctx, lexutil.Query, "", "app.bsky.feed.getRepostedBy", params, nil, &out); err != nil { 40 40 return nil, err 41 41 } 42 42
+3 -3
api/bsky/feedgetSuggestedFeeds.go
··· 7 7 import ( 8 8 "context" 9 9 10 - "github.com/bluesky-social/indigo/lex/util" 10 + lexutil "github.com/bluesky-social/indigo/lex/util" 11 11 ) 12 12 13 13 // FeedGetSuggestedFeeds_Output is the output of a app.bsky.feed.getSuggestedFeeds call. ··· 17 17 } 18 18 19 19 // FeedGetSuggestedFeeds calls the XRPC method "app.bsky.feed.getSuggestedFeeds". 20 - func FeedGetSuggestedFeeds(ctx context.Context, c util.LexClient, cursor string, limit int64) (*FeedGetSuggestedFeeds_Output, error) { 20 + func FeedGetSuggestedFeeds(ctx context.Context, c lexutil.LexClient, cursor string, limit int64) (*FeedGetSuggestedFeeds_Output, error) { 21 21 var out FeedGetSuggestedFeeds_Output 22 22 23 23 params := map[string]interface{}{} ··· 27 27 if limit != 0 { 28 28 params["limit"] = limit 29 29 } 30 - if err := c.LexDo(ctx, util.Query, "", "app.bsky.feed.getSuggestedFeeds", params, nil, &out); err != nil { 30 + if err := c.LexDo(ctx, lexutil.Query, "", "app.bsky.feed.getSuggestedFeeds", params, nil, &out); err != nil { 31 31 return nil, err 32 32 } 33 33
+3 -3
api/bsky/feedgetTimeline.go
··· 7 7 import ( 8 8 "context" 9 9 10 - "github.com/bluesky-social/indigo/lex/util" 10 + lexutil "github.com/bluesky-social/indigo/lex/util" 11 11 ) 12 12 13 13 // FeedGetTimeline_Output is the output of a app.bsky.feed.getTimeline call. ··· 19 19 // FeedGetTimeline calls the XRPC method "app.bsky.feed.getTimeline". 20 20 // 21 21 // algorithm: Variant 'algorithm' for timeline. Implementation-specific. NOTE: most feed flexibility has been moved to feed generator mechanism. 22 - func FeedGetTimeline(ctx context.Context, c util.LexClient, algorithm string, cursor string, limit int64) (*FeedGetTimeline_Output, error) { 22 + func FeedGetTimeline(ctx context.Context, c lexutil.LexClient, algorithm string, cursor string, limit int64) (*FeedGetTimeline_Output, error) { 23 23 var out FeedGetTimeline_Output 24 24 25 25 params := map[string]interface{}{} ··· 32 32 if limit != 0 { 33 33 params["limit"] = limit 34 34 } 35 - if err := c.LexDo(ctx, util.Query, "", "app.bsky.feed.getTimeline", params, nil, &out); err != nil { 35 + if err := c.LexDo(ctx, lexutil.Query, "", "app.bsky.feed.getTimeline", params, nil, &out); err != nil { 36 36 return nil, err 37 37 } 38 38
+7 -7
api/bsky/feedlike.go
··· 5 5 package bsky 6 6 7 7 import ( 8 - comatprototypes "github.com/bluesky-social/indigo/api/atproto" 9 - "github.com/bluesky-social/indigo/lex/util" 8 + comatproto "github.com/bluesky-social/indigo/api/atproto" 9 + lexutil "github.com/bluesky-social/indigo/lex/util" 10 10 ) 11 11 12 12 func init() { 13 - util.RegisterType("app.bsky.feed.like", &FeedLike{}) 13 + lexutil.RegisterType("app.bsky.feed.like", &FeedLike{}) 14 14 } 15 15 16 16 type FeedLike struct { 17 - LexiconTypeID string `json:"$type" cborgen:"$type,const=app.bsky.feed.like"` 18 - CreatedAt string `json:"createdAt" cborgen:"createdAt"` 19 - Subject *comatprototypes.RepoStrongRef `json:"subject" cborgen:"subject"` 20 - Via *comatprototypes.RepoStrongRef `json:"via,omitempty" cborgen:"via,omitempty"` 17 + LexiconTypeID string `json:"$type" cborgen:"$type,const=app.bsky.feed.like"` 18 + CreatedAt string `json:"createdAt" cborgen:"createdAt"` 19 + Subject *comatproto.RepoStrongRef `json:"subject" cborgen:"subject"` 20 + Via *comatproto.RepoStrongRef `json:"via,omitempty" cborgen:"via,omitempty"` 21 21 }
+14 -16
api/bsky/feedpost.go
··· 10 10 "fmt" 11 11 "io" 12 12 13 - comatprototypes "github.com/bluesky-social/indigo/api/atproto" 14 - "github.com/bluesky-social/indigo/lex/util" 13 + comatproto "github.com/bluesky-social/indigo/api/atproto" 14 + lexutil "github.com/bluesky-social/indigo/lex/util" 15 15 cbg "github.com/whyrusleeping/cbor-gen" 16 16 ) 17 17 18 18 func init() { 19 - util.RegisterType("app.bsky.feed.post", &FeedPost{}) 19 + lexutil.RegisterType("app.bsky.feed.post", &FeedPost{}) 20 20 } 21 21 22 22 type FeedPost struct { ··· 72 72 } 73 73 74 74 func (t *FeedPost_Embed) UnmarshalJSON(b []byte) error { 75 - typ, err := util.TypeExtract(b) 75 + typ, err := lexutil.TypeExtract(b) 76 76 if err != nil { 77 77 return err 78 78 } ··· 93 93 case "app.bsky.embed.recordWithMedia": 94 94 t.EmbedRecordWithMedia = new(EmbedRecordWithMedia) 95 95 return json.Unmarshal(b, t.EmbedRecordWithMedia) 96 - 97 96 default: 98 97 return nil 99 98 } ··· 122 121 } 123 122 return fmt.Errorf("can not marshal empty union as CBOR") 124 123 } 124 + 125 125 func (t *FeedPost_Embed) UnmarshalCBOR(r io.Reader) error { 126 - typ, b, err := util.CborTypeExtractReader(r) 126 + typ, b, err := lexutil.CborTypeExtractReader(r) 127 127 if err != nil { 128 128 return err 129 129 } ··· 144 144 case "app.bsky.embed.recordWithMedia": 145 145 t.EmbedRecordWithMedia = new(EmbedRecordWithMedia) 146 146 return t.EmbedRecordWithMedia.UnmarshalCBOR(bytes.NewReader(b)) 147 - 148 147 default: 149 148 return nil 150 149 } ··· 162 161 163 162 // Self-label values for this post. Effectively content warnings. 164 163 type FeedPost_Labels struct { 165 - LabelDefs_SelfLabels *comatprototypes.LabelDefs_SelfLabels 164 + LabelDefs_SelfLabels *comatproto.LabelDefs_SelfLabels 166 165 } 167 166 168 167 func (t *FeedPost_Labels) MarshalJSON() ([]byte, error) { ··· 174 173 } 175 174 176 175 func (t *FeedPost_Labels) UnmarshalJSON(b []byte) error { 177 - typ, err := util.TypeExtract(b) 176 + typ, err := lexutil.TypeExtract(b) 178 177 if err != nil { 179 178 return err 180 179 } 181 180 182 181 switch typ { 183 182 case "com.atproto.label.defs#selfLabels": 184 - t.LabelDefs_SelfLabels = new(comatprototypes.LabelDefs_SelfLabels) 183 + t.LabelDefs_SelfLabels = new(comatproto.LabelDefs_SelfLabels) 185 184 return json.Unmarshal(b, t.LabelDefs_SelfLabels) 186 - 187 185 default: 188 186 return nil 189 187 } ··· 200 198 } 201 199 return fmt.Errorf("can not marshal empty union as CBOR") 202 200 } 201 + 203 202 func (t *FeedPost_Labels) UnmarshalCBOR(r io.Reader) error { 204 - typ, b, err := util.CborTypeExtractReader(r) 203 + typ, b, err := lexutil.CborTypeExtractReader(r) 205 204 if err != nil { 206 205 return err 207 206 } 208 207 209 208 switch typ { 210 209 case "com.atproto.label.defs#selfLabels": 211 - t.LabelDefs_SelfLabels = new(comatprototypes.LabelDefs_SelfLabels) 210 + t.LabelDefs_SelfLabels = new(comatproto.LabelDefs_SelfLabels) 212 211 return t.LabelDefs_SelfLabels.UnmarshalCBOR(bytes.NewReader(b)) 213 - 214 212 default: 215 213 return nil 216 214 } ··· 218 216 219 217 // FeedPost_ReplyRef is a "replyRef" in the app.bsky.feed.post schema. 220 218 type FeedPost_ReplyRef struct { 221 - Parent *comatprototypes.RepoStrongRef `json:"parent" cborgen:"parent"` 222 - Root *comatprototypes.RepoStrongRef `json:"root" cborgen:"root"` 219 + Parent *comatproto.RepoStrongRef `json:"parent" cborgen:"parent"` 220 + Root *comatproto.RepoStrongRef `json:"root" cborgen:"root"` 223 221 } 224 222 225 223 // FeedPost_TextSlice is a "textSlice" in the app.bsky.feed.post schema.
+5 -6
api/bsky/feedpostgate.go
··· 10 10 "fmt" 11 11 "io" 12 12 13 - "github.com/bluesky-social/indigo/lex/util" 13 + lexutil "github.com/bluesky-social/indigo/lex/util" 14 14 cbg "github.com/whyrusleeping/cbor-gen" 15 15 ) 16 16 17 17 func init() { 18 - util.RegisterType("app.bsky.feed.postgate", &FeedPostgate{}) 18 + lexutil.RegisterType("app.bsky.feed.postgate", &FeedPostgate{}) 19 19 } 20 20 21 21 type FeedPostgate struct { ··· 49 49 } 50 50 51 51 func (t *FeedPostgate_EmbeddingRules_Elem) UnmarshalJSON(b []byte) error { 52 - typ, err := util.TypeExtract(b) 52 + typ, err := lexutil.TypeExtract(b) 53 53 if err != nil { 54 54 return err 55 55 } ··· 58 58 case "app.bsky.feed.postgate#disableRule": 59 59 t.FeedPostgate_DisableRule = new(FeedPostgate_DisableRule) 60 60 return json.Unmarshal(b, t.FeedPostgate_DisableRule) 61 - 62 61 default: 63 62 return nil 64 63 } ··· 75 74 } 76 75 return fmt.Errorf("can not marshal empty union as CBOR") 77 76 } 77 + 78 78 func (t *FeedPostgate_EmbeddingRules_Elem) UnmarshalCBOR(r io.Reader) error { 79 - typ, b, err := util.CborTypeExtractReader(r) 79 + typ, b, err := lexutil.CborTypeExtractReader(r) 80 80 if err != nil { 81 81 return err 82 82 } ··· 85 85 case "app.bsky.feed.postgate#disableRule": 86 86 t.FeedPostgate_DisableRule = new(FeedPostgate_DisableRule) 87 87 return t.FeedPostgate_DisableRule.UnmarshalCBOR(bytes.NewReader(b)) 88 - 89 88 default: 90 89 return nil 91 90 }
+7 -7
api/bsky/feedrepost.go
··· 5 5 package bsky 6 6 7 7 import ( 8 - comatprototypes "github.com/bluesky-social/indigo/api/atproto" 9 - "github.com/bluesky-social/indigo/lex/util" 8 + comatproto "github.com/bluesky-social/indigo/api/atproto" 9 + lexutil "github.com/bluesky-social/indigo/lex/util" 10 10 ) 11 11 12 12 func init() { 13 - util.RegisterType("app.bsky.feed.repost", &FeedRepost{}) 13 + lexutil.RegisterType("app.bsky.feed.repost", &FeedRepost{}) 14 14 } 15 15 16 16 type FeedRepost struct { 17 - LexiconTypeID string `json:"$type" cborgen:"$type,const=app.bsky.feed.repost"` 18 - CreatedAt string `json:"createdAt" cborgen:"createdAt"` 19 - Subject *comatprototypes.RepoStrongRef `json:"subject" cborgen:"subject"` 20 - Via *comatprototypes.RepoStrongRef `json:"via,omitempty" cborgen:"via,omitempty"` 17 + LexiconTypeID string `json:"$type" cborgen:"$type,const=app.bsky.feed.repost"` 18 + CreatedAt string `json:"createdAt" cborgen:"createdAt"` 19 + Subject *comatproto.RepoStrongRef `json:"subject" cborgen:"subject"` 20 + Via *comatproto.RepoStrongRef `json:"via,omitempty" cborgen:"via,omitempty"` 21 21 }
+3 -3
api/bsky/feedsearchPosts.go
··· 7 7 import ( 8 8 "context" 9 9 10 - "github.com/bluesky-social/indigo/lex/util" 10 + lexutil "github.com/bluesky-social/indigo/lex/util" 11 11 ) 12 12 13 13 // FeedSearchPosts_Output is the output of a app.bsky.feed.searchPosts call. ··· 31 31 // tag: Filter to posts with the given tag (hashtag), based on rich-text facet or tag field. Do not include the hash (#) prefix. Multiple tags can be specified, with 'AND' matching. 32 32 // until: Filter results for posts before the indicated datetime (not inclusive). Expected to use 'sortAt' timestamp, which may not match 'createdAt'. Can be a datetime, or just an ISO date (YYY-MM-DD). 33 33 // url: Filter to posts with links (facet links or embeds) pointing to this URL. Server may apply URL normalization or fuzzy matching. 34 - func FeedSearchPosts(ctx context.Context, c util.LexClient, author string, cursor string, domain string, lang string, limit int64, mentions string, q string, since string, sort string, tag []string, until string, url string) (*FeedSearchPosts_Output, error) { 34 + func FeedSearchPosts(ctx context.Context, c lexutil.LexClient, author string, cursor string, domain string, lang string, limit int64, mentions string, q string, since string, sort string, tag []string, until string, url string) (*FeedSearchPosts_Output, error) { 35 35 var out FeedSearchPosts_Output 36 36 37 37 params := map[string]interface{}{} ··· 69 69 if url != "" { 70 70 params["url"] = url 71 71 } 72 - if err := c.LexDo(ctx, util.Query, "", "app.bsky.feed.searchPosts", params, nil, &out); err != nil { 72 + if err := c.LexDo(ctx, lexutil.Query, "", "app.bsky.feed.searchPosts", params, nil, &out); err != nil { 73 73 return nil, err 74 74 } 75 75
+3 -3
api/bsky/feedsendInteractions.go
··· 7 7 import ( 8 8 "context" 9 9 10 - "github.com/bluesky-social/indigo/lex/util" 10 + lexutil "github.com/bluesky-social/indigo/lex/util" 11 11 ) 12 12 13 13 // FeedSendInteractions_Input is the input argument to a app.bsky.feed.sendInteractions call. ··· 20 20 } 21 21 22 22 // FeedSendInteractions calls the XRPC method "app.bsky.feed.sendInteractions". 23 - func FeedSendInteractions(ctx context.Context, c util.LexClient, input *FeedSendInteractions_Input) (*FeedSendInteractions_Output, error) { 23 + func FeedSendInteractions(ctx context.Context, c lexutil.LexClient, input *FeedSendInteractions_Input) (*FeedSendInteractions_Output, error) { 24 24 var out FeedSendInteractions_Output 25 - if err := c.LexDo(ctx, util.Procedure, "application/json", "app.bsky.feed.sendInteractions", nil, input, &out); err != nil { 25 + if err := c.LexDo(ctx, lexutil.Procedure, "application/json", "app.bsky.feed.sendInteractions", nil, input, &out); err != nil { 26 26 return nil, err 27 27 } 28 28
+5 -6
api/bsky/feedthreadgate.go
··· 10 10 "fmt" 11 11 "io" 12 12 13 - "github.com/bluesky-social/indigo/lex/util" 13 + lexutil "github.com/bluesky-social/indigo/lex/util" 14 14 cbg "github.com/whyrusleeping/cbor-gen" 15 15 ) 16 16 17 17 func init() { 18 - util.RegisterType("app.bsky.feed.threadgate", &FeedThreadgate{}) 18 + lexutil.RegisterType("app.bsky.feed.threadgate", &FeedThreadgate{}) 19 19 } 20 20 21 21 type FeedThreadgate struct { ··· 57 57 } 58 58 59 59 func (t *FeedThreadgate_Allow_Elem) UnmarshalJSON(b []byte) error { 60 - typ, err := util.TypeExtract(b) 60 + typ, err := lexutil.TypeExtract(b) 61 61 if err != nil { 62 62 return err 63 63 } ··· 75 75 case "app.bsky.feed.threadgate#listRule": 76 76 t.FeedThreadgate_ListRule = new(FeedThreadgate_ListRule) 77 77 return json.Unmarshal(b, t.FeedThreadgate_ListRule) 78 - 79 78 default: 80 79 return nil 81 80 } ··· 101 100 } 102 101 return fmt.Errorf("can not marshal empty union as CBOR") 103 102 } 103 + 104 104 func (t *FeedThreadgate_Allow_Elem) UnmarshalCBOR(r io.Reader) error { 105 - typ, b, err := util.CborTypeExtractReader(r) 105 + typ, b, err := lexutil.CborTypeExtractReader(r) 106 106 if err != nil { 107 107 return err 108 108 } ··· 120 120 case "app.bsky.feed.threadgate#listRule": 121 121 t.FeedThreadgate_ListRule = new(FeedThreadgate_ListRule) 122 122 return t.FeedThreadgate_ListRule.UnmarshalCBOR(bytes.NewReader(b)) 123 - 124 123 default: 125 124 return nil 126 125 }
+2 -2
api/bsky/graphblock.go
··· 5 5 package bsky 6 6 7 7 import ( 8 - "github.com/bluesky-social/indigo/lex/util" 8 + lexutil "github.com/bluesky-social/indigo/lex/util" 9 9 ) 10 10 11 11 func init() { 12 - util.RegisterType("app.bsky.graph.block", &GraphBlock{}) 12 + lexutil.RegisterType("app.bsky.graph.block", &GraphBlock{}) 13 13 } 14 14 15 15 type GraphBlock struct {
+45 -45
api/bsky/graphdefs.go
··· 5 5 package bsky 6 6 7 7 import ( 8 - comatprototypes "github.com/bluesky-social/indigo/api/atproto" 9 - "github.com/bluesky-social/indigo/lex/util" 8 + comatproto "github.com/bluesky-social/indigo/api/atproto" 9 + lexutil "github.com/bluesky-social/indigo/lex/util" 10 10 ) 11 11 12 12 // GraphDefs_ListItemView is a "listItemView" in the app.bsky.graph.defs schema. ··· 17 17 18 18 // GraphDefs_ListView is a "listView" in the app.bsky.graph.defs schema. 19 19 type GraphDefs_ListView struct { 20 - LexiconTypeID string `json:"$type" cborgen:"$type,const=app.bsky.graph.defs#listView"` 21 - Avatar *string `json:"avatar,omitempty" cborgen:"avatar,omitempty"` 22 - Cid string `json:"cid" cborgen:"cid"` 23 - Creator *ActorDefs_ProfileView `json:"creator" cborgen:"creator"` 24 - Description *string `json:"description,omitempty" cborgen:"description,omitempty"` 25 - DescriptionFacets []*RichtextFacet `json:"descriptionFacets,omitempty" cborgen:"descriptionFacets,omitempty"` 26 - IndexedAt string `json:"indexedAt" cborgen:"indexedAt"` 27 - Labels []*comatprototypes.LabelDefs_Label `json:"labels,omitempty" cborgen:"labels,omitempty"` 28 - ListItemCount *int64 `json:"listItemCount,omitempty" cborgen:"listItemCount,omitempty"` 29 - Name string `json:"name" cborgen:"name"` 30 - Purpose *string `json:"purpose" cborgen:"purpose"` 31 - Uri string `json:"uri" cborgen:"uri"` 32 - Viewer *GraphDefs_ListViewerState `json:"viewer,omitempty" cborgen:"viewer,omitempty"` 20 + LexiconTypeID string `json:"$type" cborgen:"$type,const=app.bsky.graph.defs#listView"` 21 + Avatar *string `json:"avatar,omitempty" cborgen:"avatar,omitempty"` 22 + Cid string `json:"cid" cborgen:"cid"` 23 + Creator *ActorDefs_ProfileView `json:"creator" cborgen:"creator"` 24 + Description *string `json:"description,omitempty" cborgen:"description,omitempty"` 25 + DescriptionFacets []*RichtextFacet `json:"descriptionFacets,omitempty" cborgen:"descriptionFacets,omitempty"` 26 + IndexedAt string `json:"indexedAt" cborgen:"indexedAt"` 27 + Labels []*comatproto.LabelDefs_Label `json:"labels,omitempty" cborgen:"labels,omitempty"` 28 + ListItemCount *int64 `json:"listItemCount,omitempty" cborgen:"listItemCount,omitempty"` 29 + Name string `json:"name" cborgen:"name"` 30 + Purpose *string `json:"purpose" cborgen:"purpose"` 31 + Uri string `json:"uri" cborgen:"uri"` 32 + Viewer *GraphDefs_ListViewerState `json:"viewer,omitempty" cborgen:"viewer,omitempty"` 33 33 } 34 34 35 35 // GraphDefs_ListViewBasic is a "listViewBasic" in the app.bsky.graph.defs schema. 36 36 type GraphDefs_ListViewBasic struct { 37 - Avatar *string `json:"avatar,omitempty" cborgen:"avatar,omitempty"` 38 - Cid string `json:"cid" cborgen:"cid"` 39 - IndexedAt *string `json:"indexedAt,omitempty" cborgen:"indexedAt,omitempty"` 40 - Labels []*comatprototypes.LabelDefs_Label `json:"labels,omitempty" cborgen:"labels,omitempty"` 41 - ListItemCount *int64 `json:"listItemCount,omitempty" cborgen:"listItemCount,omitempty"` 42 - Name string `json:"name" cborgen:"name"` 43 - Purpose *string `json:"purpose" cborgen:"purpose"` 44 - Uri string `json:"uri" cborgen:"uri"` 45 - Viewer *GraphDefs_ListViewerState `json:"viewer,omitempty" cborgen:"viewer,omitempty"` 37 + Avatar *string `json:"avatar,omitempty" cborgen:"avatar,omitempty"` 38 + Cid string `json:"cid" cborgen:"cid"` 39 + IndexedAt *string `json:"indexedAt,omitempty" cborgen:"indexedAt,omitempty"` 40 + Labels []*comatproto.LabelDefs_Label `json:"labels,omitempty" cborgen:"labels,omitempty"` 41 + ListItemCount *int64 `json:"listItemCount,omitempty" cborgen:"listItemCount,omitempty"` 42 + Name string `json:"name" cborgen:"name"` 43 + Purpose *string `json:"purpose" cborgen:"purpose"` 44 + Uri string `json:"uri" cborgen:"uri"` 45 + Viewer *GraphDefs_ListViewerState `json:"viewer,omitempty" cborgen:"viewer,omitempty"` 46 46 } 47 47 48 48 // GraphDefs_ListViewerState is a "listViewerState" in the app.bsky.graph.defs schema. ··· 74 74 75 75 // GraphDefs_StarterPackView is a "starterPackView" in the app.bsky.graph.defs schema. 76 76 type GraphDefs_StarterPackView struct { 77 - Cid string `json:"cid" cborgen:"cid"` 78 - Creator *ActorDefs_ProfileViewBasic `json:"creator" cborgen:"creator"` 79 - Feeds []*FeedDefs_GeneratorView `json:"feeds,omitempty" cborgen:"feeds,omitempty"` 80 - IndexedAt string `json:"indexedAt" cborgen:"indexedAt"` 81 - JoinedAllTimeCount *int64 `json:"joinedAllTimeCount,omitempty" cborgen:"joinedAllTimeCount,omitempty"` 82 - JoinedWeekCount *int64 `json:"joinedWeekCount,omitempty" cborgen:"joinedWeekCount,omitempty"` 83 - Labels []*comatprototypes.LabelDefs_Label `json:"labels,omitempty" cborgen:"labels,omitempty"` 84 - List *GraphDefs_ListViewBasic `json:"list,omitempty" cborgen:"list,omitempty"` 85 - ListItemsSample []*GraphDefs_ListItemView `json:"listItemsSample,omitempty" cborgen:"listItemsSample,omitempty"` 86 - Record *util.LexiconTypeDecoder `json:"record" cborgen:"record"` 87 - Uri string `json:"uri" cborgen:"uri"` 77 + Cid string `json:"cid" cborgen:"cid"` 78 + Creator *ActorDefs_ProfileViewBasic `json:"creator" cborgen:"creator"` 79 + Feeds []*FeedDefs_GeneratorView `json:"feeds,omitempty" cborgen:"feeds,omitempty"` 80 + IndexedAt string `json:"indexedAt" cborgen:"indexedAt"` 81 + JoinedAllTimeCount *int64 `json:"joinedAllTimeCount,omitempty" cborgen:"joinedAllTimeCount,omitempty"` 82 + JoinedWeekCount *int64 `json:"joinedWeekCount,omitempty" cborgen:"joinedWeekCount,omitempty"` 83 + Labels []*comatproto.LabelDefs_Label `json:"labels,omitempty" cborgen:"labels,omitempty"` 84 + List *GraphDefs_ListViewBasic `json:"list,omitempty" cborgen:"list,omitempty"` 85 + ListItemsSample []*GraphDefs_ListItemView `json:"listItemsSample,omitempty" cborgen:"listItemsSample,omitempty"` 86 + Record *lexutil.LexiconTypeDecoder `json:"record" cborgen:"record"` 87 + Uri string `json:"uri" cborgen:"uri"` 88 88 } 89 89 90 90 // GraphDefs_StarterPackViewBasic is a "starterPackViewBasic" in the app.bsky.graph.defs schema. 91 91 type GraphDefs_StarterPackViewBasic struct { 92 - LexiconTypeID string `json:"$type" cborgen:"$type,const=app.bsky.graph.defs#starterPackViewBasic"` 93 - Cid string `json:"cid" cborgen:"cid"` 94 - Creator *ActorDefs_ProfileViewBasic `json:"creator" cborgen:"creator"` 95 - IndexedAt string `json:"indexedAt" cborgen:"indexedAt"` 96 - JoinedAllTimeCount *int64 `json:"joinedAllTimeCount,omitempty" cborgen:"joinedAllTimeCount,omitempty"` 97 - JoinedWeekCount *int64 `json:"joinedWeekCount,omitempty" cborgen:"joinedWeekCount,omitempty"` 98 - Labels []*comatprototypes.LabelDefs_Label `json:"labels,omitempty" cborgen:"labels,omitempty"` 99 - ListItemCount *int64 `json:"listItemCount,omitempty" cborgen:"listItemCount,omitempty"` 100 - Record *util.LexiconTypeDecoder `json:"record" cborgen:"record"` 101 - Uri string `json:"uri" cborgen:"uri"` 92 + LexiconTypeID string `json:"$type" cborgen:"$type,const=app.bsky.graph.defs#starterPackViewBasic"` 93 + Cid string `json:"cid" cborgen:"cid"` 94 + Creator *ActorDefs_ProfileViewBasic `json:"creator" cborgen:"creator"` 95 + IndexedAt string `json:"indexedAt" cborgen:"indexedAt"` 96 + JoinedAllTimeCount *int64 `json:"joinedAllTimeCount,omitempty" cborgen:"joinedAllTimeCount,omitempty"` 97 + JoinedWeekCount *int64 `json:"joinedWeekCount,omitempty" cborgen:"joinedWeekCount,omitempty"` 98 + Labels []*comatproto.LabelDefs_Label `json:"labels,omitempty" cborgen:"labels,omitempty"` 99 + ListItemCount *int64 `json:"listItemCount,omitempty" cborgen:"listItemCount,omitempty"` 100 + Record *lexutil.LexiconTypeDecoder `json:"record" cborgen:"record"` 101 + Uri string `json:"uri" cborgen:"uri"` 102 102 }
+2 -2
api/bsky/graphfollow.go
··· 5 5 package bsky 6 6 7 7 import ( 8 - "github.com/bluesky-social/indigo/lex/util" 8 + lexutil "github.com/bluesky-social/indigo/lex/util" 9 9 ) 10 10 11 11 func init() { 12 - util.RegisterType("app.bsky.graph.follow", &GraphFollow{}) 12 + lexutil.RegisterType("app.bsky.graph.follow", &GraphFollow{}) 13 13 } 14 14 15 15 type GraphFollow struct {
+3 -3
api/bsky/graphgetActorStarterPacks.go
··· 7 7 import ( 8 8 "context" 9 9 10 - "github.com/bluesky-social/indigo/lex/util" 10 + lexutil "github.com/bluesky-social/indigo/lex/util" 11 11 ) 12 12 13 13 // GraphGetActorStarterPacks_Output is the output of a app.bsky.graph.getActorStarterPacks call. ··· 17 17 } 18 18 19 19 // GraphGetActorStarterPacks calls the XRPC method "app.bsky.graph.getActorStarterPacks". 20 - func GraphGetActorStarterPacks(ctx context.Context, c util.LexClient, actor string, cursor string, limit int64) (*GraphGetActorStarterPacks_Output, error) { 20 + func GraphGetActorStarterPacks(ctx context.Context, c lexutil.LexClient, actor string, cursor string, limit int64) (*GraphGetActorStarterPacks_Output, error) { 21 21 var out GraphGetActorStarterPacks_Output 22 22 23 23 params := map[string]interface{}{} ··· 28 28 if limit != 0 { 29 29 params["limit"] = limit 30 30 } 31 - if err := c.LexDo(ctx, util.Query, "", "app.bsky.graph.getActorStarterPacks", params, nil, &out); err != nil { 31 + if err := c.LexDo(ctx, lexutil.Query, "", "app.bsky.graph.getActorStarterPacks", params, nil, &out); err != nil { 32 32 return nil, err 33 33 } 34 34
+3 -3
api/bsky/graphgetBlocks.go
··· 7 7 import ( 8 8 "context" 9 9 10 - "github.com/bluesky-social/indigo/lex/util" 10 + lexutil "github.com/bluesky-social/indigo/lex/util" 11 11 ) 12 12 13 13 // GraphGetBlocks_Output is the output of a app.bsky.graph.getBlocks call. ··· 17 17 } 18 18 19 19 // GraphGetBlocks calls the XRPC method "app.bsky.graph.getBlocks". 20 - func GraphGetBlocks(ctx context.Context, c util.LexClient, cursor string, limit int64) (*GraphGetBlocks_Output, error) { 20 + func GraphGetBlocks(ctx context.Context, c lexutil.LexClient, cursor string, limit int64) (*GraphGetBlocks_Output, error) { 21 21 var out GraphGetBlocks_Output 22 22 23 23 params := map[string]interface{}{} ··· 27 27 if limit != 0 { 28 28 params["limit"] = limit 29 29 } 30 - if err := c.LexDo(ctx, util.Query, "", "app.bsky.graph.getBlocks", params, nil, &out); err != nil { 30 + if err := c.LexDo(ctx, lexutil.Query, "", "app.bsky.graph.getBlocks", params, nil, &out); err != nil { 31 31 return nil, err 32 32 } 33 33
+3 -3
api/bsky/graphgetFollowers.go
··· 7 7 import ( 8 8 "context" 9 9 10 - "github.com/bluesky-social/indigo/lex/util" 10 + lexutil "github.com/bluesky-social/indigo/lex/util" 11 11 ) 12 12 13 13 // GraphGetFollowers_Output is the output of a app.bsky.graph.getFollowers call. ··· 18 18 } 19 19 20 20 // GraphGetFollowers calls the XRPC method "app.bsky.graph.getFollowers". 21 - func GraphGetFollowers(ctx context.Context, c util.LexClient, actor string, cursor string, limit int64) (*GraphGetFollowers_Output, error) { 21 + func GraphGetFollowers(ctx context.Context, c lexutil.LexClient, actor string, cursor string, limit int64) (*GraphGetFollowers_Output, error) { 22 22 var out GraphGetFollowers_Output 23 23 24 24 params := map[string]interface{}{} ··· 29 29 if limit != 0 { 30 30 params["limit"] = limit 31 31 } 32 - if err := c.LexDo(ctx, util.Query, "", "app.bsky.graph.getFollowers", params, nil, &out); err != nil { 32 + if err := c.LexDo(ctx, lexutil.Query, "", "app.bsky.graph.getFollowers", params, nil, &out); err != nil { 33 33 return nil, err 34 34 } 35 35
+3 -3
api/bsky/graphgetFollows.go
··· 7 7 import ( 8 8 "context" 9 9 10 - "github.com/bluesky-social/indigo/lex/util" 10 + lexutil "github.com/bluesky-social/indigo/lex/util" 11 11 ) 12 12 13 13 // GraphGetFollows_Output is the output of a app.bsky.graph.getFollows call. ··· 18 18 } 19 19 20 20 // GraphGetFollows calls the XRPC method "app.bsky.graph.getFollows". 21 - func GraphGetFollows(ctx context.Context, c util.LexClient, actor string, cursor string, limit int64) (*GraphGetFollows_Output, error) { 21 + func GraphGetFollows(ctx context.Context, c lexutil.LexClient, actor string, cursor string, limit int64) (*GraphGetFollows_Output, error) { 22 22 var out GraphGetFollows_Output 23 23 24 24 params := map[string]interface{}{} ··· 29 29 if limit != 0 { 30 30 params["limit"] = limit 31 31 } 32 - if err := c.LexDo(ctx, util.Query, "", "app.bsky.graph.getFollows", params, nil, &out); err != nil { 32 + if err := c.LexDo(ctx, lexutil.Query, "", "app.bsky.graph.getFollows", params, nil, &out); err != nil { 33 33 return nil, err 34 34 } 35 35
+3 -3
api/bsky/graphgetKnownFollowers.go
··· 7 7 import ( 8 8 "context" 9 9 10 - "github.com/bluesky-social/indigo/lex/util" 10 + lexutil "github.com/bluesky-social/indigo/lex/util" 11 11 ) 12 12 13 13 // GraphGetKnownFollowers_Output is the output of a app.bsky.graph.getKnownFollowers call. ··· 18 18 } 19 19 20 20 // GraphGetKnownFollowers calls the XRPC method "app.bsky.graph.getKnownFollowers". 21 - func GraphGetKnownFollowers(ctx context.Context, c util.LexClient, actor string, cursor string, limit int64) (*GraphGetKnownFollowers_Output, error) { 21 + func GraphGetKnownFollowers(ctx context.Context, c lexutil.LexClient, actor string, cursor string, limit int64) (*GraphGetKnownFollowers_Output, error) { 22 22 var out GraphGetKnownFollowers_Output 23 23 24 24 params := map[string]interface{}{} ··· 29 29 if limit != 0 { 30 30 params["limit"] = limit 31 31 } 32 - if err := c.LexDo(ctx, util.Query, "", "app.bsky.graph.getKnownFollowers", params, nil, &out); err != nil { 32 + if err := c.LexDo(ctx, lexutil.Query, "", "app.bsky.graph.getKnownFollowers", params, nil, &out); err != nil { 33 33 return nil, err 34 34 } 35 35
+3 -3
api/bsky/graphgetList.go
··· 7 7 import ( 8 8 "context" 9 9 10 - "github.com/bluesky-social/indigo/lex/util" 10 + lexutil "github.com/bluesky-social/indigo/lex/util" 11 11 ) 12 12 13 13 // GraphGetList_Output is the output of a app.bsky.graph.getList call. ··· 20 20 // GraphGetList calls the XRPC method "app.bsky.graph.getList". 21 21 // 22 22 // list: Reference (AT-URI) of the list record to hydrate. 23 - func GraphGetList(ctx context.Context, c util.LexClient, cursor string, limit int64, list string) (*GraphGetList_Output, error) { 23 + func GraphGetList(ctx context.Context, c lexutil.LexClient, cursor string, limit int64, list string) (*GraphGetList_Output, error) { 24 24 var out GraphGetList_Output 25 25 26 26 params := map[string]interface{}{} ··· 31 31 params["limit"] = limit 32 32 } 33 33 params["list"] = list 34 - if err := c.LexDo(ctx, util.Query, "", "app.bsky.graph.getList", params, nil, &out); err != nil { 34 + if err := c.LexDo(ctx, lexutil.Query, "", "app.bsky.graph.getList", params, nil, &out); err != nil { 35 35 return nil, err 36 36 } 37 37
+3 -3
api/bsky/graphgetListBlocks.go
··· 7 7 import ( 8 8 "context" 9 9 10 - "github.com/bluesky-social/indigo/lex/util" 10 + lexutil "github.com/bluesky-social/indigo/lex/util" 11 11 ) 12 12 13 13 // GraphGetListBlocks_Output is the output of a app.bsky.graph.getListBlocks call. ··· 17 17 } 18 18 19 19 // GraphGetListBlocks calls the XRPC method "app.bsky.graph.getListBlocks". 20 - func GraphGetListBlocks(ctx context.Context, c util.LexClient, cursor string, limit int64) (*GraphGetListBlocks_Output, error) { 20 + func GraphGetListBlocks(ctx context.Context, c lexutil.LexClient, cursor string, limit int64) (*GraphGetListBlocks_Output, error) { 21 21 var out GraphGetListBlocks_Output 22 22 23 23 params := map[string]interface{}{} ··· 27 27 if limit != 0 { 28 28 params["limit"] = limit 29 29 } 30 - if err := c.LexDo(ctx, util.Query, "", "app.bsky.graph.getListBlocks", params, nil, &out); err != nil { 30 + if err := c.LexDo(ctx, lexutil.Query, "", "app.bsky.graph.getListBlocks", params, nil, &out); err != nil { 31 31 return nil, err 32 32 } 33 33
+3 -3
api/bsky/graphgetListMutes.go
··· 7 7 import ( 8 8 "context" 9 9 10 - "github.com/bluesky-social/indigo/lex/util" 10 + lexutil "github.com/bluesky-social/indigo/lex/util" 11 11 ) 12 12 13 13 // GraphGetListMutes_Output is the output of a app.bsky.graph.getListMutes call. ··· 17 17 } 18 18 19 19 // GraphGetListMutes calls the XRPC method "app.bsky.graph.getListMutes". 20 - func GraphGetListMutes(ctx context.Context, c util.LexClient, cursor string, limit int64) (*GraphGetListMutes_Output, error) { 20 + func GraphGetListMutes(ctx context.Context, c lexutil.LexClient, cursor string, limit int64) (*GraphGetListMutes_Output, error) { 21 21 var out GraphGetListMutes_Output 22 22 23 23 params := map[string]interface{}{} ··· 27 27 if limit != 0 { 28 28 params["limit"] = limit 29 29 } 30 - if err := c.LexDo(ctx, util.Query, "", "app.bsky.graph.getListMutes", params, nil, &out); err != nil { 30 + if err := c.LexDo(ctx, lexutil.Query, "", "app.bsky.graph.getListMutes", params, nil, &out); err != nil { 31 31 return nil, err 32 32 } 33 33
+3 -3
api/bsky/graphgetLists.go
··· 7 7 import ( 8 8 "context" 9 9 10 - "github.com/bluesky-social/indigo/lex/util" 10 + lexutil "github.com/bluesky-social/indigo/lex/util" 11 11 ) 12 12 13 13 // GraphGetLists_Output is the output of a app.bsky.graph.getLists call. ··· 20 20 // 21 21 // actor: The account (actor) to enumerate lists from. 22 22 // purposes: Optional filter by list purpose. If not specified, all supported types are returned. 23 - func GraphGetLists(ctx context.Context, c util.LexClient, actor string, cursor string, limit int64, purposes []string) (*GraphGetLists_Output, error) { 23 + func GraphGetLists(ctx context.Context, c lexutil.LexClient, actor string, cursor string, limit int64, purposes []string) (*GraphGetLists_Output, error) { 24 24 var out GraphGetLists_Output 25 25 26 26 params := map[string]interface{}{} ··· 34 34 if len(purposes) != 0 { 35 35 params["purposes"] = purposes 36 36 } 37 - if err := c.LexDo(ctx, util.Query, "", "app.bsky.graph.getLists", params, nil, &out); err != nil { 37 + if err := c.LexDo(ctx, lexutil.Query, "", "app.bsky.graph.getLists", params, nil, &out); err != nil { 38 38 return nil, err 39 39 } 40 40
+3 -3
api/bsky/graphgetListsWithMembership.go
··· 7 7 import ( 8 8 "context" 9 9 10 - "github.com/bluesky-social/indigo/lex/util" 10 + lexutil "github.com/bluesky-social/indigo/lex/util" 11 11 ) 12 12 13 13 // GraphGetListsWithMembership_ListWithMembership is a "listWithMembership" in the app.bsky.graph.getListsWithMembership schema. ··· 28 28 // 29 29 // actor: The account (actor) to check for membership. 30 30 // purposes: Optional filter by list purpose. If not specified, all supported types are returned. 31 - func GraphGetListsWithMembership(ctx context.Context, c util.LexClient, actor string, cursor string, limit int64, purposes []string) (*GraphGetListsWithMembership_Output, error) { 31 + func GraphGetListsWithMembership(ctx context.Context, c lexutil.LexClient, actor string, cursor string, limit int64, purposes []string) (*GraphGetListsWithMembership_Output, error) { 32 32 var out GraphGetListsWithMembership_Output 33 33 34 34 params := map[string]interface{}{} ··· 42 42 if len(purposes) != 0 { 43 43 params["purposes"] = purposes 44 44 } 45 - if err := c.LexDo(ctx, util.Query, "", "app.bsky.graph.getListsWithMembership", params, nil, &out); err != nil { 45 + if err := c.LexDo(ctx, lexutil.Query, "", "app.bsky.graph.getListsWithMembership", params, nil, &out); err != nil { 46 46 return nil, err 47 47 } 48 48
+3 -3
api/bsky/graphgetMutes.go
··· 7 7 import ( 8 8 "context" 9 9 10 - "github.com/bluesky-social/indigo/lex/util" 10 + lexutil "github.com/bluesky-social/indigo/lex/util" 11 11 ) 12 12 13 13 // GraphGetMutes_Output is the output of a app.bsky.graph.getMutes call. ··· 17 17 } 18 18 19 19 // GraphGetMutes calls the XRPC method "app.bsky.graph.getMutes". 20 - func GraphGetMutes(ctx context.Context, c util.LexClient, cursor string, limit int64) (*GraphGetMutes_Output, error) { 20 + func GraphGetMutes(ctx context.Context, c lexutil.LexClient, cursor string, limit int64) (*GraphGetMutes_Output, error) { 21 21 var out GraphGetMutes_Output 22 22 23 23 params := map[string]interface{}{} ··· 27 27 if limit != 0 { 28 28 params["limit"] = limit 29 29 } 30 - if err := c.LexDo(ctx, util.Query, "", "app.bsky.graph.getMutes", params, nil, &out); err != nil { 30 + if err := c.LexDo(ctx, lexutil.Query, "", "app.bsky.graph.getMutes", params, nil, &out); err != nil { 31 31 return nil, err 32 32 } 33 33
+4 -5
api/bsky/graphgetRelationships.go
··· 9 9 "encoding/json" 10 10 "fmt" 11 11 12 - "github.com/bluesky-social/indigo/lex/util" 12 + lexutil "github.com/bluesky-social/indigo/lex/util" 13 13 ) 14 14 15 15 // GraphGetRelationships_Output is the output of a app.bsky.graph.getRelationships call. ··· 36 36 } 37 37 38 38 func (t *GraphGetRelationships_Output_Relationships_Elem) UnmarshalJSON(b []byte) error { 39 - typ, err := util.TypeExtract(b) 39 + typ, err := lexutil.TypeExtract(b) 40 40 if err != nil { 41 41 return err 42 42 } ··· 48 48 case "app.bsky.graph.defs#notFoundActor": 49 49 t.GraphDefs_NotFoundActor = new(GraphDefs_NotFoundActor) 50 50 return json.Unmarshal(b, t.GraphDefs_NotFoundActor) 51 - 52 51 default: 53 52 return nil 54 53 } ··· 58 57 // 59 58 // actor: Primary account requesting relationships for. 60 59 // others: List of 'other' accounts to be related back to the primary. 61 - func GraphGetRelationships(ctx context.Context, c util.LexClient, actor string, others []string) (*GraphGetRelationships_Output, error) { 60 + func GraphGetRelationships(ctx context.Context, c lexutil.LexClient, actor string, others []string) (*GraphGetRelationships_Output, error) { 62 61 var out GraphGetRelationships_Output 63 62 64 63 params := map[string]interface{}{} ··· 66 65 if len(others) != 0 { 67 66 params["others"] = others 68 67 } 69 - if err := c.LexDo(ctx, util.Query, "", "app.bsky.graph.getRelationships", params, nil, &out); err != nil { 68 + if err := c.LexDo(ctx, lexutil.Query, "", "app.bsky.graph.getRelationships", params, nil, &out); err != nil { 70 69 return nil, err 71 70 } 72 71
+3 -3
api/bsky/graphgetStarterPack.go
··· 7 7 import ( 8 8 "context" 9 9 10 - "github.com/bluesky-social/indigo/lex/util" 10 + lexutil "github.com/bluesky-social/indigo/lex/util" 11 11 ) 12 12 13 13 // GraphGetStarterPack_Output is the output of a app.bsky.graph.getStarterPack call. ··· 18 18 // GraphGetStarterPack calls the XRPC method "app.bsky.graph.getStarterPack". 19 19 // 20 20 // starterPack: Reference (AT-URI) of the starter pack record. 21 - func GraphGetStarterPack(ctx context.Context, c util.LexClient, starterPack string) (*GraphGetStarterPack_Output, error) { 21 + func GraphGetStarterPack(ctx context.Context, c lexutil.LexClient, starterPack string) (*GraphGetStarterPack_Output, error) { 22 22 var out GraphGetStarterPack_Output 23 23 24 24 params := map[string]interface{}{} 25 25 params["starterPack"] = starterPack 26 - if err := c.LexDo(ctx, util.Query, "", "app.bsky.graph.getStarterPack", params, nil, &out); err != nil { 26 + if err := c.LexDo(ctx, lexutil.Query, "", "app.bsky.graph.getStarterPack", params, nil, &out); err != nil { 27 27 return nil, err 28 28 } 29 29
+3 -3
api/bsky/graphgetStarterPacks.go
··· 7 7 import ( 8 8 "context" 9 9 10 - "github.com/bluesky-social/indigo/lex/util" 10 + lexutil "github.com/bluesky-social/indigo/lex/util" 11 11 ) 12 12 13 13 // GraphGetStarterPacks_Output is the output of a app.bsky.graph.getStarterPacks call. ··· 16 16 } 17 17 18 18 // GraphGetStarterPacks calls the XRPC method "app.bsky.graph.getStarterPacks". 19 - func GraphGetStarterPacks(ctx context.Context, c util.LexClient, uris []string) (*GraphGetStarterPacks_Output, error) { 19 + func GraphGetStarterPacks(ctx context.Context, c lexutil.LexClient, uris []string) (*GraphGetStarterPacks_Output, error) { 20 20 var out GraphGetStarterPacks_Output 21 21 22 22 params := map[string]interface{}{} 23 23 params["uris"] = uris 24 - if err := c.LexDo(ctx, util.Query, "", "app.bsky.graph.getStarterPacks", params, nil, &out); err != nil { 24 + if err := c.LexDo(ctx, lexutil.Query, "", "app.bsky.graph.getStarterPacks", params, nil, &out); err != nil { 25 25 return nil, err 26 26 } 27 27
+3 -3
api/bsky/graphgetStarterPacksWithMembership.go
··· 7 7 import ( 8 8 "context" 9 9 10 - "github.com/bluesky-social/indigo/lex/util" 10 + lexutil "github.com/bluesky-social/indigo/lex/util" 11 11 ) 12 12 13 13 // GraphGetStarterPacksWithMembership_Output is the output of a app.bsky.graph.getStarterPacksWithMembership call. ··· 27 27 // GraphGetStarterPacksWithMembership calls the XRPC method "app.bsky.graph.getStarterPacksWithMembership". 28 28 // 29 29 // actor: The account (actor) to check for membership. 30 - func GraphGetStarterPacksWithMembership(ctx context.Context, c util.LexClient, actor string, cursor string, limit int64) (*GraphGetStarterPacksWithMembership_Output, error) { 30 + func GraphGetStarterPacksWithMembership(ctx context.Context, c lexutil.LexClient, actor string, cursor string, limit int64) (*GraphGetStarterPacksWithMembership_Output, error) { 31 31 var out GraphGetStarterPacksWithMembership_Output 32 32 33 33 params := map[string]interface{}{} ··· 38 38 if limit != 0 { 39 39 params["limit"] = limit 40 40 } 41 - if err := c.LexDo(ctx, util.Query, "", "app.bsky.graph.getStarterPacksWithMembership", params, nil, &out); err != nil { 41 + if err := c.LexDo(ctx, lexutil.Query, "", "app.bsky.graph.getStarterPacksWithMembership", params, nil, &out); err != nil { 42 42 return nil, err 43 43 } 44 44
+3 -3
api/bsky/graphgetSuggestedFollowsByActor.go
··· 7 7 import ( 8 8 "context" 9 9 10 - "github.com/bluesky-social/indigo/lex/util" 10 + lexutil "github.com/bluesky-social/indigo/lex/util" 11 11 ) 12 12 13 13 // GraphGetSuggestedFollowsByActor_Output is the output of a app.bsky.graph.getSuggestedFollowsByActor call. ··· 20 20 } 21 21 22 22 // GraphGetSuggestedFollowsByActor calls the XRPC method "app.bsky.graph.getSuggestedFollowsByActor". 23 - func GraphGetSuggestedFollowsByActor(ctx context.Context, c util.LexClient, actor string) (*GraphGetSuggestedFollowsByActor_Output, error) { 23 + func GraphGetSuggestedFollowsByActor(ctx context.Context, c lexutil.LexClient, actor string) (*GraphGetSuggestedFollowsByActor_Output, error) { 24 24 var out GraphGetSuggestedFollowsByActor_Output 25 25 26 26 params := map[string]interface{}{} 27 27 params["actor"] = actor 28 - if err := c.LexDo(ctx, util.Query, "", "app.bsky.graph.getSuggestedFollowsByActor", params, nil, &out); err != nil { 28 + if err := c.LexDo(ctx, lexutil.Query, "", "app.bsky.graph.getSuggestedFollowsByActor", params, nil, &out); err != nil { 29 29 return nil, err 30 30 } 31 31
+10 -11
api/bsky/graphlist.go
··· 10 10 "fmt" 11 11 "io" 12 12 13 - comatprototypes "github.com/bluesky-social/indigo/api/atproto" 14 - "github.com/bluesky-social/indigo/lex/util" 13 + comatproto "github.com/bluesky-social/indigo/api/atproto" 14 + lexutil "github.com/bluesky-social/indigo/lex/util" 15 15 cbg "github.com/whyrusleeping/cbor-gen" 16 16 ) 17 17 18 18 func init() { 19 - util.RegisterType("app.bsky.graph.list", &GraphList{}) 19 + lexutil.RegisterType("app.bsky.graph.list", &GraphList{}) 20 20 } 21 21 22 22 type GraphList struct { 23 23 LexiconTypeID string `json:"$type" cborgen:"$type,const=app.bsky.graph.list"` 24 - Avatar *util.LexBlob `json:"avatar,omitempty" cborgen:"avatar,omitempty"` 24 + Avatar *lexutil.LexBlob `json:"avatar,omitempty" cborgen:"avatar,omitempty"` 25 25 CreatedAt string `json:"createdAt" cborgen:"createdAt"` 26 26 Description *string `json:"description,omitempty" cborgen:"description,omitempty"` 27 27 DescriptionFacets []*RichtextFacet `json:"descriptionFacets,omitempty" cborgen:"descriptionFacets,omitempty"` ··· 33 33 } 34 34 35 35 type GraphList_Labels struct { 36 - LabelDefs_SelfLabels *comatprototypes.LabelDefs_SelfLabels 36 + LabelDefs_SelfLabels *comatproto.LabelDefs_SelfLabels 37 37 } 38 38 39 39 func (t *GraphList_Labels) MarshalJSON() ([]byte, error) { ··· 45 45 } 46 46 47 47 func (t *GraphList_Labels) UnmarshalJSON(b []byte) error { 48 - typ, err := util.TypeExtract(b) 48 + typ, err := lexutil.TypeExtract(b) 49 49 if err != nil { 50 50 return err 51 51 } 52 52 53 53 switch typ { 54 54 case "com.atproto.label.defs#selfLabels": 55 - t.LabelDefs_SelfLabels = new(comatprototypes.LabelDefs_SelfLabels) 55 + t.LabelDefs_SelfLabels = new(comatproto.LabelDefs_SelfLabels) 56 56 return json.Unmarshal(b, t.LabelDefs_SelfLabels) 57 - 58 57 default: 59 58 return nil 60 59 } ··· 71 70 } 72 71 return fmt.Errorf("can not marshal empty union as CBOR") 73 72 } 73 + 74 74 func (t *GraphList_Labels) UnmarshalCBOR(r io.Reader) error { 75 - typ, b, err := util.CborTypeExtractReader(r) 75 + typ, b, err := lexutil.CborTypeExtractReader(r) 76 76 if err != nil { 77 77 return err 78 78 } 79 79 80 80 switch typ { 81 81 case "com.atproto.label.defs#selfLabels": 82 - t.LabelDefs_SelfLabels = new(comatprototypes.LabelDefs_SelfLabels) 82 + t.LabelDefs_SelfLabels = new(comatproto.LabelDefs_SelfLabels) 83 83 return t.LabelDefs_SelfLabels.UnmarshalCBOR(bytes.NewReader(b)) 84 - 85 84 default: 86 85 return nil 87 86 }
+2 -2
api/bsky/graphlistblock.go
··· 5 5 package bsky 6 6 7 7 import ( 8 - "github.com/bluesky-social/indigo/lex/util" 8 + lexutil "github.com/bluesky-social/indigo/lex/util" 9 9 ) 10 10 11 11 func init() { 12 - util.RegisterType("app.bsky.graph.listblock", &GraphListblock{}) 12 + lexutil.RegisterType("app.bsky.graph.listblock", &GraphListblock{}) 13 13 } 14 14 15 15 type GraphListblock struct {
+2 -2
api/bsky/graphlistitem.go
··· 5 5 package bsky 6 6 7 7 import ( 8 - "github.com/bluesky-social/indigo/lex/util" 8 + lexutil "github.com/bluesky-social/indigo/lex/util" 9 9 ) 10 10 11 11 func init() { 12 - util.RegisterType("app.bsky.graph.listitem", &GraphListitem{}) 12 + lexutil.RegisterType("app.bsky.graph.listitem", &GraphListitem{}) 13 13 } 14 14 15 15 type GraphListitem struct {
+3 -3
api/bsky/graphmuteActor.go
··· 7 7 import ( 8 8 "context" 9 9 10 - "github.com/bluesky-social/indigo/lex/util" 10 + lexutil "github.com/bluesky-social/indigo/lex/util" 11 11 ) 12 12 13 13 // GraphMuteActor_Input is the input argument to a app.bsky.graph.muteActor call. ··· 16 16 } 17 17 18 18 // GraphMuteActor calls the XRPC method "app.bsky.graph.muteActor". 19 - func GraphMuteActor(ctx context.Context, c util.LexClient, input *GraphMuteActor_Input) error { 20 - if err := c.LexDo(ctx, util.Procedure, "application/json", "app.bsky.graph.muteActor", nil, input, nil); err != nil { 19 + func GraphMuteActor(ctx context.Context, c lexutil.LexClient, input *GraphMuteActor_Input) error { 20 + if err := c.LexDo(ctx, lexutil.Procedure, "application/json", "app.bsky.graph.muteActor", nil, input, nil); err != nil { 21 21 return err 22 22 } 23 23
+3 -3
api/bsky/graphmuteActorList.go
··· 7 7 import ( 8 8 "context" 9 9 10 - "github.com/bluesky-social/indigo/lex/util" 10 + lexutil "github.com/bluesky-social/indigo/lex/util" 11 11 ) 12 12 13 13 // GraphMuteActorList_Input is the input argument to a app.bsky.graph.muteActorList call. ··· 16 16 } 17 17 18 18 // GraphMuteActorList calls the XRPC method "app.bsky.graph.muteActorList". 19 - func GraphMuteActorList(ctx context.Context, c util.LexClient, input *GraphMuteActorList_Input) error { 20 - if err := c.LexDo(ctx, util.Procedure, "application/json", "app.bsky.graph.muteActorList", nil, input, nil); err != nil { 19 + func GraphMuteActorList(ctx context.Context, c lexutil.LexClient, input *GraphMuteActorList_Input) error { 20 + if err := c.LexDo(ctx, lexutil.Procedure, "application/json", "app.bsky.graph.muteActorList", nil, input, nil); err != nil { 21 21 return err 22 22 } 23 23
+3 -3
api/bsky/graphmuteThread.go
··· 7 7 import ( 8 8 "context" 9 9 10 - "github.com/bluesky-social/indigo/lex/util" 10 + lexutil "github.com/bluesky-social/indigo/lex/util" 11 11 ) 12 12 13 13 // GraphMuteThread_Input is the input argument to a app.bsky.graph.muteThread call. ··· 16 16 } 17 17 18 18 // GraphMuteThread calls the XRPC method "app.bsky.graph.muteThread". 19 - func GraphMuteThread(ctx context.Context, c util.LexClient, input *GraphMuteThread_Input) error { 20 - if err := c.LexDo(ctx, util.Procedure, "application/json", "app.bsky.graph.muteThread", nil, input, nil); err != nil { 19 + func GraphMuteThread(ctx context.Context, c lexutil.LexClient, input *GraphMuteThread_Input) error { 20 + if err := c.LexDo(ctx, lexutil.Procedure, "application/json", "app.bsky.graph.muteThread", nil, input, nil); err != nil { 21 21 return err 22 22 } 23 23
+3 -3
api/bsky/graphsearchStarterPacks.go
··· 7 7 import ( 8 8 "context" 9 9 10 - "github.com/bluesky-social/indigo/lex/util" 10 + lexutil "github.com/bluesky-social/indigo/lex/util" 11 11 ) 12 12 13 13 // GraphSearchStarterPacks_Output is the output of a app.bsky.graph.searchStarterPacks call. ··· 19 19 // GraphSearchStarterPacks calls the XRPC method "app.bsky.graph.searchStarterPacks". 20 20 // 21 21 // q: Search query string. Syntax, phrase, boolean, and faceting is unspecified, but Lucene query syntax is recommended. 22 - func GraphSearchStarterPacks(ctx context.Context, c util.LexClient, cursor string, limit int64, q string) (*GraphSearchStarterPacks_Output, error) { 22 + func GraphSearchStarterPacks(ctx context.Context, c lexutil.LexClient, cursor string, limit int64, q string) (*GraphSearchStarterPacks_Output, error) { 23 23 var out GraphSearchStarterPacks_Output 24 24 25 25 params := map[string]interface{}{} ··· 30 30 params["limit"] = limit 31 31 } 32 32 params["q"] = q 33 - if err := c.LexDo(ctx, util.Query, "", "app.bsky.graph.searchStarterPacks", params, nil, &out); err != nil { 33 + if err := c.LexDo(ctx, lexutil.Query, "", "app.bsky.graph.searchStarterPacks", params, nil, &out); err != nil { 34 34 return nil, err 35 35 } 36 36
+2 -2
api/bsky/graphstarterpack.go
··· 5 5 package bsky 6 6 7 7 import ( 8 - "github.com/bluesky-social/indigo/lex/util" 8 + lexutil "github.com/bluesky-social/indigo/lex/util" 9 9 ) 10 10 11 11 func init() { 12 - util.RegisterType("app.bsky.graph.starterpack", &GraphStarterpack{}) 12 + lexutil.RegisterType("app.bsky.graph.starterpack", &GraphStarterpack{}) 13 13 } 14 14 15 15 type GraphStarterpack struct {
+3 -3
api/bsky/graphunmuteActor.go
··· 7 7 import ( 8 8 "context" 9 9 10 - "github.com/bluesky-social/indigo/lex/util" 10 + lexutil "github.com/bluesky-social/indigo/lex/util" 11 11 ) 12 12 13 13 // GraphUnmuteActor_Input is the input argument to a app.bsky.graph.unmuteActor call. ··· 16 16 } 17 17 18 18 // GraphUnmuteActor calls the XRPC method "app.bsky.graph.unmuteActor". 19 - func GraphUnmuteActor(ctx context.Context, c util.LexClient, input *GraphUnmuteActor_Input) error { 20 - if err := c.LexDo(ctx, util.Procedure, "application/json", "app.bsky.graph.unmuteActor", nil, input, nil); err != nil { 19 + func GraphUnmuteActor(ctx context.Context, c lexutil.LexClient, input *GraphUnmuteActor_Input) error { 20 + if err := c.LexDo(ctx, lexutil.Procedure, "application/json", "app.bsky.graph.unmuteActor", nil, input, nil); err != nil { 21 21 return err 22 22 } 23 23
+3 -3
api/bsky/graphunmuteActorList.go
··· 7 7 import ( 8 8 "context" 9 9 10 - "github.com/bluesky-social/indigo/lex/util" 10 + lexutil "github.com/bluesky-social/indigo/lex/util" 11 11 ) 12 12 13 13 // GraphUnmuteActorList_Input is the input argument to a app.bsky.graph.unmuteActorList call. ··· 16 16 } 17 17 18 18 // GraphUnmuteActorList calls the XRPC method "app.bsky.graph.unmuteActorList". 19 - func GraphUnmuteActorList(ctx context.Context, c util.LexClient, input *GraphUnmuteActorList_Input) error { 20 - if err := c.LexDo(ctx, util.Procedure, "application/json", "app.bsky.graph.unmuteActorList", nil, input, nil); err != nil { 19 + func GraphUnmuteActorList(ctx context.Context, c lexutil.LexClient, input *GraphUnmuteActorList_Input) error { 20 + if err := c.LexDo(ctx, lexutil.Procedure, "application/json", "app.bsky.graph.unmuteActorList", nil, input, nil); err != nil { 21 21 return err 22 22 } 23 23
+3 -3
api/bsky/graphunmuteThread.go
··· 7 7 import ( 8 8 "context" 9 9 10 - "github.com/bluesky-social/indigo/lex/util" 10 + lexutil "github.com/bluesky-social/indigo/lex/util" 11 11 ) 12 12 13 13 // GraphUnmuteThread_Input is the input argument to a app.bsky.graph.unmuteThread call. ··· 16 16 } 17 17 18 18 // GraphUnmuteThread calls the XRPC method "app.bsky.graph.unmuteThread". 19 - func GraphUnmuteThread(ctx context.Context, c util.LexClient, input *GraphUnmuteThread_Input) error { 20 - if err := c.LexDo(ctx, util.Procedure, "application/json", "app.bsky.graph.unmuteThread", nil, input, nil); err != nil { 19 + func GraphUnmuteThread(ctx context.Context, c lexutil.LexClient, input *GraphUnmuteThread_Input) error { 20 + if err := c.LexDo(ctx, lexutil.Procedure, "application/json", "app.bsky.graph.unmuteThread", nil, input, nil); err != nil { 21 21 return err 22 22 } 23 23
+2 -2
api/bsky/graphverification.go
··· 5 5 package bsky 6 6 7 7 import ( 8 - "github.com/bluesky-social/indigo/lex/util" 8 + lexutil "github.com/bluesky-social/indigo/lex/util" 9 9 ) 10 10 11 11 func init() { 12 - util.RegisterType("app.bsky.graph.verification", &GraphVerification{}) 12 + lexutil.RegisterType("app.bsky.graph.verification", &GraphVerification{}) 13 13 } 14 14 15 15 type GraphVerification struct {
-1
api/bsky/init.go
··· 1 - package bsky
+17 -17
api/bsky/labelerdefs.go
··· 5 5 package bsky 6 6 7 7 import ( 8 - comatprototypes "github.com/bluesky-social/indigo/api/atproto" 8 + comatproto "github.com/bluesky-social/indigo/api/atproto" 9 9 ) 10 10 11 11 // LabelerDefs_LabelerPolicies is a "labelerPolicies" in the app.bsky.labeler.defs schema. 12 12 type LabelerDefs_LabelerPolicies struct { 13 13 // labelValueDefinitions: Label values created by this labeler and scoped exclusively to it. Labels defined here will override global label definitions for this labeler. 14 - LabelValueDefinitions []*comatprototypes.LabelDefs_LabelValueDefinition `json:"labelValueDefinitions,omitempty" cborgen:"labelValueDefinitions,omitempty"` 14 + LabelValueDefinitions []*comatproto.LabelDefs_LabelValueDefinition `json:"labelValueDefinitions,omitempty" cborgen:"labelValueDefinitions,omitempty"` 15 15 // labelValues: The label values which this labeler publishes. May include global or custom labels. 16 16 LabelValues []*string `json:"labelValues" cborgen:"labelValues"` 17 17 } 18 18 19 19 // LabelerDefs_LabelerView is a "labelerView" in the app.bsky.labeler.defs schema. 20 20 type LabelerDefs_LabelerView struct { 21 - LexiconTypeID string `json:"$type" cborgen:"$type,const=app.bsky.labeler.defs#labelerView"` 22 - Cid string `json:"cid" cborgen:"cid"` 23 - Creator *ActorDefs_ProfileView `json:"creator" cborgen:"creator"` 24 - IndexedAt string `json:"indexedAt" cborgen:"indexedAt"` 25 - Labels []*comatprototypes.LabelDefs_Label `json:"labels,omitempty" cborgen:"labels,omitempty"` 26 - LikeCount *int64 `json:"likeCount,omitempty" cborgen:"likeCount,omitempty"` 27 - Uri string `json:"uri" cborgen:"uri"` 28 - Viewer *LabelerDefs_LabelerViewerState `json:"viewer,omitempty" cborgen:"viewer,omitempty"` 21 + LexiconTypeID string `json:"$type" cborgen:"$type,const=app.bsky.labeler.defs#labelerView"` 22 + Cid string `json:"cid" cborgen:"cid"` 23 + Creator *ActorDefs_ProfileView `json:"creator" cborgen:"creator"` 24 + IndexedAt string `json:"indexedAt" cborgen:"indexedAt"` 25 + Labels []*comatproto.LabelDefs_Label `json:"labels,omitempty" cborgen:"labels,omitempty"` 26 + LikeCount *int64 `json:"likeCount,omitempty" cborgen:"likeCount,omitempty"` 27 + Uri string `json:"uri" cborgen:"uri"` 28 + Viewer *LabelerDefs_LabelerViewerState `json:"viewer,omitempty" cborgen:"viewer,omitempty"` 29 29 } 30 30 31 31 // LabelerDefs_LabelerViewDetailed is a "labelerViewDetailed" in the app.bsky.labeler.defs schema. 32 32 type LabelerDefs_LabelerViewDetailed struct { 33 - LexiconTypeID string `json:"$type" cborgen:"$type,const=app.bsky.labeler.defs#labelerViewDetailed"` 34 - Cid string `json:"cid" cborgen:"cid"` 35 - Creator *ActorDefs_ProfileView `json:"creator" cborgen:"creator"` 36 - IndexedAt string `json:"indexedAt" cborgen:"indexedAt"` 37 - Labels []*comatprototypes.LabelDefs_Label `json:"labels,omitempty" cborgen:"labels,omitempty"` 38 - LikeCount *int64 `json:"likeCount,omitempty" cborgen:"likeCount,omitempty"` 39 - Policies *LabelerDefs_LabelerPolicies `json:"policies" cborgen:"policies"` 33 + LexiconTypeID string `json:"$type" cborgen:"$type,const=app.bsky.labeler.defs#labelerViewDetailed"` 34 + Cid string `json:"cid" cborgen:"cid"` 35 + Creator *ActorDefs_ProfileView `json:"creator" cborgen:"creator"` 36 + IndexedAt string `json:"indexedAt" cborgen:"indexedAt"` 37 + Labels []*comatproto.LabelDefs_Label `json:"labels,omitempty" cborgen:"labels,omitempty"` 38 + LikeCount *int64 `json:"likeCount,omitempty" cborgen:"likeCount,omitempty"` 39 + Policies *LabelerDefs_LabelerPolicies `json:"policies" cborgen:"policies"` 40 40 // reasonTypes: The set of report reason 'codes' which are in-scope for this service to review and action. These usually align to policy categories. If not defined (distinct from empty array), all reason types are allowed. 41 41 ReasonTypes []*string `json:"reasonTypes,omitempty" cborgen:"reasonTypes,omitempty"` 42 42 // subjectCollections: Set of record types (collection NSIDs) which can be reported to this service. If not defined (distinct from empty array), default is any record type.
+4 -5
api/bsky/labelergetServices.go
··· 9 9 "encoding/json" 10 10 "fmt" 11 11 12 - "github.com/bluesky-social/indigo/lex/util" 12 + lexutil "github.com/bluesky-social/indigo/lex/util" 13 13 ) 14 14 15 15 // LabelerGetServices_Output is the output of a app.bsky.labeler.getServices call. ··· 35 35 } 36 36 37 37 func (t *LabelerGetServices_Output_Views_Elem) UnmarshalJSON(b []byte) error { 38 - typ, err := util.TypeExtract(b) 38 + typ, err := lexutil.TypeExtract(b) 39 39 if err != nil { 40 40 return err 41 41 } ··· 47 47 case "app.bsky.labeler.defs#labelerViewDetailed": 48 48 t.LabelerDefs_LabelerViewDetailed = new(LabelerDefs_LabelerViewDetailed) 49 49 return json.Unmarshal(b, t.LabelerDefs_LabelerViewDetailed) 50 - 51 50 default: 52 51 return nil 53 52 } 54 53 } 55 54 56 55 // LabelerGetServices calls the XRPC method "app.bsky.labeler.getServices". 57 - func LabelerGetServices(ctx context.Context, c util.LexClient, detailed bool, dids []string) (*LabelerGetServices_Output, error) { 56 + func LabelerGetServices(ctx context.Context, c lexutil.LexClient, detailed bool, dids []string) (*LabelerGetServices_Output, error) { 58 57 var out LabelerGetServices_Output 59 58 60 59 params := map[string]interface{}{} ··· 62 61 params["detailed"] = detailed 63 62 } 64 63 params["dids"] = dids 65 - if err := c.LexDo(ctx, util.Query, "", "app.bsky.labeler.getServices", params, nil, &out); err != nil { 64 + if err := c.LexDo(ctx, lexutil.Query, "", "app.bsky.labeler.getServices", params, nil, &out); err != nil { 66 65 return nil, err 67 66 } 68 67
+9 -10
api/bsky/labelerservice.go
··· 10 10 "fmt" 11 11 "io" 12 12 13 - comatprototypes "github.com/bluesky-social/indigo/api/atproto" 14 - "github.com/bluesky-social/indigo/lex/util" 13 + comatproto "github.com/bluesky-social/indigo/api/atproto" 14 + lexutil "github.com/bluesky-social/indigo/lex/util" 15 15 cbg "github.com/whyrusleeping/cbor-gen" 16 16 ) 17 17 18 18 func init() { 19 - util.RegisterType("app.bsky.labeler.service", &LabelerService{}) 19 + lexutil.RegisterType("app.bsky.labeler.service", &LabelerService{}) 20 20 } 21 21 22 22 type LabelerService struct { ··· 33 33 } 34 34 35 35 type LabelerService_Labels struct { 36 - LabelDefs_SelfLabels *comatprototypes.LabelDefs_SelfLabels 36 + LabelDefs_SelfLabels *comatproto.LabelDefs_SelfLabels 37 37 } 38 38 39 39 func (t *LabelerService_Labels) MarshalJSON() ([]byte, error) { ··· 45 45 } 46 46 47 47 func (t *LabelerService_Labels) UnmarshalJSON(b []byte) error { 48 - typ, err := util.TypeExtract(b) 48 + typ, err := lexutil.TypeExtract(b) 49 49 if err != nil { 50 50 return err 51 51 } 52 52 53 53 switch typ { 54 54 case "com.atproto.label.defs#selfLabels": 55 - t.LabelDefs_SelfLabels = new(comatprototypes.LabelDefs_SelfLabels) 55 + t.LabelDefs_SelfLabels = new(comatproto.LabelDefs_SelfLabels) 56 56 return json.Unmarshal(b, t.LabelDefs_SelfLabels) 57 - 58 57 default: 59 58 return nil 60 59 } ··· 71 70 } 72 71 return fmt.Errorf("can not marshal empty union as CBOR") 73 72 } 73 + 74 74 func (t *LabelerService_Labels) UnmarshalCBOR(r io.Reader) error { 75 - typ, b, err := util.CborTypeExtractReader(r) 75 + typ, b, err := lexutil.CborTypeExtractReader(r) 76 76 if err != nil { 77 77 return err 78 78 } 79 79 80 80 switch typ { 81 81 case "com.atproto.label.defs#selfLabels": 82 - t.LabelDefs_SelfLabels = new(comatprototypes.LabelDefs_SelfLabels) 82 + t.LabelDefs_SelfLabels = new(comatproto.LabelDefs_SelfLabels) 83 83 return t.LabelDefs_SelfLabels.UnmarshalCBOR(bytes.NewReader(b)) 84 - 85 84 default: 86 85 return nil 87 86 }
+2 -2
api/bsky/notificationdeclaration.go
··· 5 5 package bsky 6 6 7 7 import ( 8 - "github.com/bluesky-social/indigo/lex/util" 8 + lexutil "github.com/bluesky-social/indigo/lex/util" 9 9 ) 10 10 11 11 func init() { 12 - util.RegisterType("app.bsky.notification.declaration", &NotificationDeclaration{}) 12 + lexutil.RegisterType("app.bsky.notification.declaration", &NotificationDeclaration{}) 13 13 } 14 14 15 15 type NotificationDeclaration struct {
+3 -3
api/bsky/notificationgetPreferences.go
··· 7 7 import ( 8 8 "context" 9 9 10 - "github.com/bluesky-social/indigo/lex/util" 10 + lexutil "github.com/bluesky-social/indigo/lex/util" 11 11 ) 12 12 13 13 // NotificationGetPreferences_Output is the output of a app.bsky.notification.getPreferences call. ··· 16 16 } 17 17 18 18 // NotificationGetPreferences calls the XRPC method "app.bsky.notification.getPreferences". 19 - func NotificationGetPreferences(ctx context.Context, c util.LexClient) (*NotificationGetPreferences_Output, error) { 19 + func NotificationGetPreferences(ctx context.Context, c lexutil.LexClient) (*NotificationGetPreferences_Output, error) { 20 20 var out NotificationGetPreferences_Output 21 21 22 22 params := map[string]interface{}{} 23 - if err := c.LexDo(ctx, util.Query, "", "app.bsky.notification.getPreferences", params, nil, &out); err != nil { 23 + if err := c.LexDo(ctx, lexutil.Query, "", "app.bsky.notification.getPreferences", params, nil, &out); err != nil { 24 24 return nil, err 25 25 } 26 26
+3 -3
api/bsky/notificationgetUnreadCount.go
··· 7 7 import ( 8 8 "context" 9 9 10 - "github.com/bluesky-social/indigo/lex/util" 10 + lexutil "github.com/bluesky-social/indigo/lex/util" 11 11 ) 12 12 13 13 // NotificationGetUnreadCount_Output is the output of a app.bsky.notification.getUnreadCount call. ··· 16 16 } 17 17 18 18 // NotificationGetUnreadCount calls the XRPC method "app.bsky.notification.getUnreadCount". 19 - func NotificationGetUnreadCount(ctx context.Context, c util.LexClient, priority bool, seenAt string) (*NotificationGetUnreadCount_Output, error) { 19 + func NotificationGetUnreadCount(ctx context.Context, c lexutil.LexClient, priority bool, seenAt string) (*NotificationGetUnreadCount_Output, error) { 20 20 var out NotificationGetUnreadCount_Output 21 21 22 22 params := map[string]interface{}{} ··· 26 26 if seenAt != "" { 27 27 params["seenAt"] = seenAt 28 28 } 29 - if err := c.LexDo(ctx, util.Query, "", "app.bsky.notification.getUnreadCount", params, nil, &out); err != nil { 29 + if err := c.LexDo(ctx, lexutil.Query, "", "app.bsky.notification.getUnreadCount", params, nil, &out); err != nil { 30 30 return nil, err 31 31 } 32 32
+3 -3
api/bsky/notificationlistActivitySubscriptions.go
··· 7 7 import ( 8 8 "context" 9 9 10 - "github.com/bluesky-social/indigo/lex/util" 10 + lexutil "github.com/bluesky-social/indigo/lex/util" 11 11 ) 12 12 13 13 // NotificationListActivitySubscriptions_Output is the output of a app.bsky.notification.listActivitySubscriptions call. ··· 17 17 } 18 18 19 19 // NotificationListActivitySubscriptions calls the XRPC method "app.bsky.notification.listActivitySubscriptions". 20 - func NotificationListActivitySubscriptions(ctx context.Context, c util.LexClient, cursor string, limit int64) (*NotificationListActivitySubscriptions_Output, error) { 20 + func NotificationListActivitySubscriptions(ctx context.Context, c lexutil.LexClient, cursor string, limit int64) (*NotificationListActivitySubscriptions_Output, error) { 21 21 var out NotificationListActivitySubscriptions_Output 22 22 23 23 params := map[string]interface{}{} ··· 27 27 if limit != 0 { 28 28 params["limit"] = limit 29 29 } 30 - if err := c.LexDo(ctx, util.Query, "", "app.bsky.notification.listActivitySubscriptions", params, nil, &out); err != nil { 30 + if err := c.LexDo(ctx, lexutil.Query, "", "app.bsky.notification.listActivitySubscriptions", params, nil, &out); err != nil { 31 31 return nil, err 32 32 } 33 33
+13 -13
api/bsky/notificationlistNotifications.go
··· 7 7 import ( 8 8 "context" 9 9 10 - comatprototypes "github.com/bluesky-social/indigo/api/atproto" 11 - "github.com/bluesky-social/indigo/lex/util" 10 + comatproto "github.com/bluesky-social/indigo/api/atproto" 11 + lexutil "github.com/bluesky-social/indigo/lex/util" 12 12 ) 13 13 14 14 // NotificationListNotifications_Notification is a "notification" in the app.bsky.notification.listNotifications schema. 15 15 type NotificationListNotifications_Notification struct { 16 - Author *ActorDefs_ProfileView `json:"author" cborgen:"author"` 17 - Cid string `json:"cid" cborgen:"cid"` 18 - IndexedAt string `json:"indexedAt" cborgen:"indexedAt"` 19 - IsRead bool `json:"isRead" cborgen:"isRead"` 20 - Labels []*comatprototypes.LabelDefs_Label `json:"labels,omitempty" cborgen:"labels,omitempty"` 16 + Author *ActorDefs_ProfileView `json:"author" cborgen:"author"` 17 + Cid string `json:"cid" cborgen:"cid"` 18 + IndexedAt string `json:"indexedAt" cborgen:"indexedAt"` 19 + IsRead bool `json:"isRead" cborgen:"isRead"` 20 + Labels []*comatproto.LabelDefs_Label `json:"labels,omitempty" cborgen:"labels,omitempty"` 21 21 // reason: The reason why this notification was delivered - e.g. your post was liked, or you received a new follower. 22 - Reason string `json:"reason" cborgen:"reason"` 23 - ReasonSubject *string `json:"reasonSubject,omitempty" cborgen:"reasonSubject,omitempty"` 24 - Record *util.LexiconTypeDecoder `json:"record" cborgen:"record"` 25 - Uri string `json:"uri" cborgen:"uri"` 22 + Reason string `json:"reason" cborgen:"reason"` 23 + ReasonSubject *string `json:"reasonSubject,omitempty" cborgen:"reasonSubject,omitempty"` 24 + Record *lexutil.LexiconTypeDecoder `json:"record" cborgen:"record"` 25 + Uri string `json:"uri" cborgen:"uri"` 26 26 } 27 27 28 28 // NotificationListNotifications_Output is the output of a app.bsky.notification.listNotifications call. ··· 36 36 // NotificationListNotifications calls the XRPC method "app.bsky.notification.listNotifications". 37 37 // 38 38 // reasons: Notification reasons to include in response. 39 - func NotificationListNotifications(ctx context.Context, c util.LexClient, cursor string, limit int64, priority bool, reasons []string, seenAt string) (*NotificationListNotifications_Output, error) { 39 + func NotificationListNotifications(ctx context.Context, c lexutil.LexClient, cursor string, limit int64, priority bool, reasons []string, seenAt string) (*NotificationListNotifications_Output, error) { 40 40 var out NotificationListNotifications_Output 41 41 42 42 params := map[string]interface{}{} ··· 55 55 if seenAt != "" { 56 56 params["seenAt"] = seenAt 57 57 } 58 - if err := c.LexDo(ctx, util.Query, "", "app.bsky.notification.listNotifications", params, nil, &out); err != nil { 58 + if err := c.LexDo(ctx, lexutil.Query, "", "app.bsky.notification.listNotifications", params, nil, &out); err != nil { 59 59 return nil, err 60 60 } 61 61
+3 -3
api/bsky/notificationputActivitySubscription.go
··· 7 7 import ( 8 8 "context" 9 9 10 - "github.com/bluesky-social/indigo/lex/util" 10 + lexutil "github.com/bluesky-social/indigo/lex/util" 11 11 ) 12 12 13 13 // NotificationPutActivitySubscription_Input is the input argument to a app.bsky.notification.putActivitySubscription call. ··· 23 23 } 24 24 25 25 // NotificationPutActivitySubscription calls the XRPC method "app.bsky.notification.putActivitySubscription". 26 - func NotificationPutActivitySubscription(ctx context.Context, c util.LexClient, input *NotificationPutActivitySubscription_Input) (*NotificationPutActivitySubscription_Output, error) { 26 + func NotificationPutActivitySubscription(ctx context.Context, c lexutil.LexClient, input *NotificationPutActivitySubscription_Input) (*NotificationPutActivitySubscription_Output, error) { 27 27 var out NotificationPutActivitySubscription_Output 28 - if err := c.LexDo(ctx, util.Procedure, "application/json", "app.bsky.notification.putActivitySubscription", nil, input, &out); err != nil { 28 + if err := c.LexDo(ctx, lexutil.Procedure, "application/json", "app.bsky.notification.putActivitySubscription", nil, input, &out); err != nil { 29 29 return nil, err 30 30 } 31 31
+3 -3
api/bsky/notificationputPreferences.go
··· 7 7 import ( 8 8 "context" 9 9 10 - "github.com/bluesky-social/indigo/lex/util" 10 + lexutil "github.com/bluesky-social/indigo/lex/util" 11 11 ) 12 12 13 13 // NotificationPutPreferences_Input is the input argument to a app.bsky.notification.putPreferences call. ··· 16 16 } 17 17 18 18 // NotificationPutPreferences calls the XRPC method "app.bsky.notification.putPreferences". 19 - func NotificationPutPreferences(ctx context.Context, c util.LexClient, input *NotificationPutPreferences_Input) error { 20 - if err := c.LexDo(ctx, util.Procedure, "application/json", "app.bsky.notification.putPreferences", nil, input, nil); err != nil { 19 + func NotificationPutPreferences(ctx context.Context, c lexutil.LexClient, input *NotificationPutPreferences_Input) error { 20 + if err := c.LexDo(ctx, lexutil.Procedure, "application/json", "app.bsky.notification.putPreferences", nil, input, nil); err != nil { 21 21 return err 22 22 } 23 23
+3 -3
api/bsky/notificationputPreferencesV2.go
··· 7 7 import ( 8 8 "context" 9 9 10 - "github.com/bluesky-social/indigo/lex/util" 10 + lexutil "github.com/bluesky-social/indigo/lex/util" 11 11 ) 12 12 13 13 // NotificationPutPreferencesV2_Input is the input argument to a app.bsky.notification.putPreferencesV2 call. ··· 33 33 } 34 34 35 35 // NotificationPutPreferencesV2 calls the XRPC method "app.bsky.notification.putPreferencesV2". 36 - func NotificationPutPreferencesV2(ctx context.Context, c util.LexClient, input *NotificationPutPreferencesV2_Input) (*NotificationPutPreferencesV2_Output, error) { 36 + func NotificationPutPreferencesV2(ctx context.Context, c lexutil.LexClient, input *NotificationPutPreferencesV2_Input) (*NotificationPutPreferencesV2_Output, error) { 37 37 var out NotificationPutPreferencesV2_Output 38 - if err := c.LexDo(ctx, util.Procedure, "application/json", "app.bsky.notification.putPreferencesV2", nil, input, &out); err != nil { 38 + if err := c.LexDo(ctx, lexutil.Procedure, "application/json", "app.bsky.notification.putPreferencesV2", nil, input, &out); err != nil { 39 39 return nil, err 40 40 } 41 41
+3 -3
api/bsky/notificationregisterPush.go
··· 7 7 import ( 8 8 "context" 9 9 10 - "github.com/bluesky-social/indigo/lex/util" 10 + lexutil "github.com/bluesky-social/indigo/lex/util" 11 11 ) 12 12 13 13 // NotificationRegisterPush_Input is the input argument to a app.bsky.notification.registerPush call. ··· 21 21 } 22 22 23 23 // NotificationRegisterPush calls the XRPC method "app.bsky.notification.registerPush". 24 - func NotificationRegisterPush(ctx context.Context, c util.LexClient, input *NotificationRegisterPush_Input) error { 25 - if err := c.LexDo(ctx, util.Procedure, "application/json", "app.bsky.notification.registerPush", nil, input, nil); err != nil { 24 + func NotificationRegisterPush(ctx context.Context, c lexutil.LexClient, input *NotificationRegisterPush_Input) error { 25 + if err := c.LexDo(ctx, lexutil.Procedure, "application/json", "app.bsky.notification.registerPush", nil, input, nil); err != nil { 26 26 return err 27 27 } 28 28
+3 -3
api/bsky/notificationunregisterPush.go
··· 7 7 import ( 8 8 "context" 9 9 10 - "github.com/bluesky-social/indigo/lex/util" 10 + lexutil "github.com/bluesky-social/indigo/lex/util" 11 11 ) 12 12 13 13 // NotificationUnregisterPush_Input is the input argument to a app.bsky.notification.unregisterPush call. ··· 19 19 } 20 20 21 21 // NotificationUnregisterPush calls the XRPC method "app.bsky.notification.unregisterPush". 22 - func NotificationUnregisterPush(ctx context.Context, c util.LexClient, input *NotificationUnregisterPush_Input) error { 23 - if err := c.LexDo(ctx, util.Procedure, "application/json", "app.bsky.notification.unregisterPush", nil, input, nil); err != nil { 22 + func NotificationUnregisterPush(ctx context.Context, c lexutil.LexClient, input *NotificationUnregisterPush_Input) error { 23 + if err := c.LexDo(ctx, lexutil.Procedure, "application/json", "app.bsky.notification.unregisterPush", nil, input, nil); err != nil { 24 24 return err 25 25 } 26 26
+3 -3
api/bsky/notificationupdateSeen.go
··· 7 7 import ( 8 8 "context" 9 9 10 - "github.com/bluesky-social/indigo/lex/util" 10 + lexutil "github.com/bluesky-social/indigo/lex/util" 11 11 ) 12 12 13 13 // NotificationUpdateSeen_Input is the input argument to a app.bsky.notification.updateSeen call. ··· 16 16 } 17 17 18 18 // NotificationUpdateSeen calls the XRPC method "app.bsky.notification.updateSeen". 19 - func NotificationUpdateSeen(ctx context.Context, c util.LexClient, input *NotificationUpdateSeen_Input) error { 20 - if err := c.LexDo(ctx, util.Procedure, "application/json", "app.bsky.notification.updateSeen", nil, input, nil); err != nil { 19 + func NotificationUpdateSeen(ctx context.Context, c lexutil.LexClient, input *NotificationUpdateSeen_Input) error { 20 + if err := c.LexDo(ctx, lexutil.Procedure, "application/json", "app.bsky.notification.updateSeen", nil, input, nil); err != nil { 21 21 return err 22 22 } 23 23
+4 -5
api/bsky/richtextfacet.go
··· 10 10 "fmt" 11 11 "io" 12 12 13 - "github.com/bluesky-social/indigo/lex/util" 13 + lexutil "github.com/bluesky-social/indigo/lex/util" 14 14 cbg "github.com/whyrusleeping/cbor-gen" 15 15 ) 16 16 ··· 53 53 } 54 54 55 55 func (t *RichtextFacet_Features_Elem) UnmarshalJSON(b []byte) error { 56 - typ, err := util.TypeExtract(b) 56 + typ, err := lexutil.TypeExtract(b) 57 57 if err != nil { 58 58 return err 59 59 } ··· 68 68 case "app.bsky.richtext.facet#tag": 69 69 t.RichtextFacet_Tag = new(RichtextFacet_Tag) 70 70 return json.Unmarshal(b, t.RichtextFacet_Tag) 71 - 72 71 default: 73 72 return nil 74 73 } ··· 91 90 } 92 91 return fmt.Errorf("can not marshal empty union as CBOR") 93 92 } 93 + 94 94 func (t *RichtextFacet_Features_Elem) UnmarshalCBOR(r io.Reader) error { 95 - typ, b, err := util.CborTypeExtractReader(r) 95 + typ, b, err := lexutil.CborTypeExtractReader(r) 96 96 if err != nil { 97 97 return err 98 98 } ··· 107 107 case "app.bsky.richtext.facet#tag": 108 108 t.RichtextFacet_Tag = new(RichtextFacet_Tag) 109 109 return t.RichtextFacet_Tag.UnmarshalCBOR(bytes.NewReader(b)) 110 - 111 110 default: 112 111 return nil 113 112 }
-26
api/bsky/unspeccedapplyLabels.go
··· 1 - // Code generated by cmd/lexgen (see Makefile's lexgen); DO NOT EDIT. 2 - 3 - package bsky 4 - 5 - // schema: app.bsky.unspecced.applyLabels 6 - 7 - import ( 8 - "context" 9 - 10 - comatprototypes "github.com/bluesky-social/indigo/api/atproto" 11 - "github.com/bluesky-social/indigo/xrpc" 12 - ) 13 - 14 - // UnspeccedApplyLabels_Input is the input argument to a app.bsky.unspecced.applyLabels call. 15 - type UnspeccedApplyLabels_Input struct { 16 - Labels []*comatprototypes.LabelDefs_Label `json:"labels" cborgen:"labels"` 17 - } 18 - 19 - // UnspeccedApplyLabels calls the XRPC method "app.bsky.unspecced.applyLabels". 20 - func UnspeccedApplyLabels(ctx context.Context, c *xrpc.Client, input *UnspeccedApplyLabels_Input) error { 21 - if err := c.Do(ctx, xrpc.Procedure, "application/json", "app.bsky.unspecced.applyLabels", nil, input, nil); err != nil { 22 - return err 23 - } 24 - 25 - return nil 26 - }
+3 -3
api/bsky/unspeccedgetAgeAssuranceState.go
··· 7 7 import ( 8 8 "context" 9 9 10 - "github.com/bluesky-social/indigo/lex/util" 10 + lexutil "github.com/bluesky-social/indigo/lex/util" 11 11 ) 12 12 13 13 // UnspeccedGetAgeAssuranceState calls the XRPC method "app.bsky.unspecced.getAgeAssuranceState". 14 - func UnspeccedGetAgeAssuranceState(ctx context.Context, c util.LexClient) (*UnspeccedDefs_AgeAssuranceState, error) { 14 + func UnspeccedGetAgeAssuranceState(ctx context.Context, c lexutil.LexClient) (*UnspeccedDefs_AgeAssuranceState, error) { 15 15 var out UnspeccedDefs_AgeAssuranceState 16 - if err := c.LexDo(ctx, util.Query, "", "app.bsky.unspecced.getAgeAssuranceState", nil, nil, &out); err != nil { 16 + if err := c.LexDo(ctx, lexutil.Query, "", "app.bsky.unspecced.getAgeAssuranceState", nil, nil, &out); err != nil { 17 17 return nil, err 18 18 } 19 19
+3 -3
api/bsky/unspeccedgetConfig.go
··· 7 7 import ( 8 8 "context" 9 9 10 - "github.com/bluesky-social/indigo/lex/util" 10 + lexutil "github.com/bluesky-social/indigo/lex/util" 11 11 ) 12 12 13 13 // UnspeccedGetConfig_LiveNowConfig is a "liveNowConfig" in the app.bsky.unspecced.getConfig schema. ··· 23 23 } 24 24 25 25 // UnspeccedGetConfig calls the XRPC method "app.bsky.unspecced.getConfig". 26 - func UnspeccedGetConfig(ctx context.Context, c util.LexClient) (*UnspeccedGetConfig_Output, error) { 26 + func UnspeccedGetConfig(ctx context.Context, c lexutil.LexClient) (*UnspeccedGetConfig_Output, error) { 27 27 var out UnspeccedGetConfig_Output 28 - if err := c.LexDo(ctx, util.Query, "", "app.bsky.unspecced.getConfig", nil, nil, &out); err != nil { 28 + if err := c.LexDo(ctx, lexutil.Query, "", "app.bsky.unspecced.getConfig", nil, nil, &out); err != nil { 29 29 return nil, err 30 30 } 31 31
+3 -3
api/bsky/unspeccedgetOnboardingSuggestedStarterPacks.go
··· 7 7 import ( 8 8 "context" 9 9 10 - "github.com/bluesky-social/indigo/lex/util" 10 + lexutil "github.com/bluesky-social/indigo/lex/util" 11 11 ) 12 12 13 13 // UnspeccedGetOnboardingSuggestedStarterPacks_Output is the output of a app.bsky.unspecced.getOnboardingSuggestedStarterPacks call. ··· 16 16 } 17 17 18 18 // UnspeccedGetOnboardingSuggestedStarterPacks calls the XRPC method "app.bsky.unspecced.getOnboardingSuggestedStarterPacks". 19 - func UnspeccedGetOnboardingSuggestedStarterPacks(ctx context.Context, c util.LexClient, limit int64) (*UnspeccedGetOnboardingSuggestedStarterPacks_Output, error) { 19 + func UnspeccedGetOnboardingSuggestedStarterPacks(ctx context.Context, c lexutil.LexClient, limit int64) (*UnspeccedGetOnboardingSuggestedStarterPacks_Output, error) { 20 20 var out UnspeccedGetOnboardingSuggestedStarterPacks_Output 21 21 22 22 params := map[string]interface{}{} 23 23 if limit != 0 { 24 24 params["limit"] = limit 25 25 } 26 - if err := c.LexDo(ctx, util.Query, "", "app.bsky.unspecced.getOnboardingSuggestedStarterPacks", params, nil, &out); err != nil { 26 + if err := c.LexDo(ctx, lexutil.Query, "", "app.bsky.unspecced.getOnboardingSuggestedStarterPacks", params, nil, &out); err != nil { 27 27 return nil, err 28 28 } 29 29
+3 -3
api/bsky/unspeccedgetOnboardingSuggestedStarterPacksSkeleton.go
··· 7 7 import ( 8 8 "context" 9 9 10 - "github.com/bluesky-social/indigo/lex/util" 10 + lexutil "github.com/bluesky-social/indigo/lex/util" 11 11 ) 12 12 13 13 // UnspeccedGetOnboardingSuggestedStarterPacksSkeleton_Output is the output of a app.bsky.unspecced.getOnboardingSuggestedStarterPacksSkeleton call. ··· 18 18 // UnspeccedGetOnboardingSuggestedStarterPacksSkeleton calls the XRPC method "app.bsky.unspecced.getOnboardingSuggestedStarterPacksSkeleton". 19 19 // 20 20 // viewer: DID of the account making the request (not included for public/unauthenticated queries). 21 - func UnspeccedGetOnboardingSuggestedStarterPacksSkeleton(ctx context.Context, c util.LexClient, limit int64, viewer string) (*UnspeccedGetOnboardingSuggestedStarterPacksSkeleton_Output, error) { 21 + func UnspeccedGetOnboardingSuggestedStarterPacksSkeleton(ctx context.Context, c lexutil.LexClient, limit int64, viewer string) (*UnspeccedGetOnboardingSuggestedStarterPacksSkeleton_Output, error) { 22 22 var out UnspeccedGetOnboardingSuggestedStarterPacksSkeleton_Output 23 23 24 24 params := map[string]interface{}{} ··· 28 28 if viewer != "" { 29 29 params["viewer"] = viewer 30 30 } 31 - if err := c.LexDo(ctx, util.Query, "", "app.bsky.unspecced.getOnboardingSuggestedStarterPacksSkeleton", params, nil, &out); err != nil { 31 + if err := c.LexDo(ctx, lexutil.Query, "", "app.bsky.unspecced.getOnboardingSuggestedStarterPacksSkeleton", params, nil, &out); err != nil { 32 32 return nil, err 33 33 } 34 34
-33
api/bsky/unspeccedgetPopular.go
··· 1 - // Code generated by cmd/lexgen (see Makefile's lexgen); DO NOT EDIT. 2 - 3 - package bsky 4 - 5 - // schema: app.bsky.unspecced.getPopular 6 - 7 - import ( 8 - "context" 9 - 10 - "github.com/bluesky-social/indigo/xrpc" 11 - ) 12 - 13 - // UnspeccedGetPopular_Output is the output of a app.bsky.unspecced.getPopular call. 14 - type UnspeccedGetPopular_Output struct { 15 - Cursor *string `json:"cursor,omitempty" cborgen:"cursor,omitempty"` 16 - Feed []*FeedDefs_FeedViewPost `json:"feed" cborgen:"feed"` 17 - } 18 - 19 - // UnspeccedGetPopular calls the XRPC method "app.bsky.unspecced.getPopular". 20 - func UnspeccedGetPopular(ctx context.Context, c *xrpc.Client, cursor string, includeNsfw bool, limit int64) (*UnspeccedGetPopular_Output, error) { 21 - var out UnspeccedGetPopular_Output 22 - 23 - params := map[string]interface{}{ 24 - "cursor": cursor, 25 - "includeNsfw": includeNsfw, 26 - "limit": limit, 27 - } 28 - if err := c.Do(ctx, xrpc.Query, "", "app.bsky.unspecced.getPopular", params, nil, &out); err != nil { 29 - return nil, err 30 - } 31 - 32 - return &out, nil 33 - }
+3 -3
api/bsky/unspeccedgetPopularFeedGenerators.go
··· 7 7 import ( 8 8 "context" 9 9 10 - "github.com/bluesky-social/indigo/lex/util" 10 + lexutil "github.com/bluesky-social/indigo/lex/util" 11 11 ) 12 12 13 13 // UnspeccedGetPopularFeedGenerators_Output is the output of a app.bsky.unspecced.getPopularFeedGenerators call. ··· 17 17 } 18 18 19 19 // UnspeccedGetPopularFeedGenerators calls the XRPC method "app.bsky.unspecced.getPopularFeedGenerators". 20 - func UnspeccedGetPopularFeedGenerators(ctx context.Context, c util.LexClient, cursor string, limit int64, query string) (*UnspeccedGetPopularFeedGenerators_Output, error) { 20 + func UnspeccedGetPopularFeedGenerators(ctx context.Context, c lexutil.LexClient, cursor string, limit int64, query string) (*UnspeccedGetPopularFeedGenerators_Output, error) { 21 21 var out UnspeccedGetPopularFeedGenerators_Output 22 22 23 23 params := map[string]interface{}{} ··· 30 30 if query != "" { 31 31 params["query"] = query 32 32 } 33 - if err := c.LexDo(ctx, util.Query, "", "app.bsky.unspecced.getPopularFeedGenerators", params, nil, &out); err != nil { 33 + if err := c.LexDo(ctx, lexutil.Query, "", "app.bsky.unspecced.getPopularFeedGenerators", params, nil, &out); err != nil { 34 34 return nil, err 35 35 } 36 36
+4 -5
api/bsky/unspeccedgetPostThreadOtherV2.go
··· 9 9 "encoding/json" 10 10 "fmt" 11 11 12 - "github.com/bluesky-social/indigo/lex/util" 12 + lexutil "github.com/bluesky-social/indigo/lex/util" 13 13 ) 14 14 15 15 // UnspeccedGetPostThreadOtherV2_Output is the output of a app.bsky.unspecced.getPostThreadOtherV2 call. ··· 39 39 } 40 40 41 41 func (t *UnspeccedGetPostThreadOtherV2_ThreadItem_Value) UnmarshalJSON(b []byte) error { 42 - typ, err := util.TypeExtract(b) 42 + typ, err := lexutil.TypeExtract(b) 43 43 if err != nil { 44 44 return err 45 45 } ··· 48 48 case "app.bsky.unspecced.defs#threadItemPost": 49 49 t.UnspeccedDefs_ThreadItemPost = new(UnspeccedDefs_ThreadItemPost) 50 50 return json.Unmarshal(b, t.UnspeccedDefs_ThreadItemPost) 51 - 52 51 default: 53 52 return nil 54 53 } ··· 58 57 // 59 58 // anchor: Reference (AT-URI) to post record. This is the anchor post. 60 59 // prioritizeFollowedUsers: Whether to prioritize posts from followed users. It only has effect when the user is authenticated. 61 - func UnspeccedGetPostThreadOtherV2(ctx context.Context, c util.LexClient, anchor string, prioritizeFollowedUsers bool) (*UnspeccedGetPostThreadOtherV2_Output, error) { 60 + func UnspeccedGetPostThreadOtherV2(ctx context.Context, c lexutil.LexClient, anchor string, prioritizeFollowedUsers bool) (*UnspeccedGetPostThreadOtherV2_Output, error) { 62 61 var out UnspeccedGetPostThreadOtherV2_Output 63 62 64 63 params := map[string]interface{}{} ··· 66 65 if prioritizeFollowedUsers { 67 66 params["prioritizeFollowedUsers"] = prioritizeFollowedUsers 68 67 } 69 - if err := c.LexDo(ctx, util.Query, "", "app.bsky.unspecced.getPostThreadOtherV2", params, nil, &out); err != nil { 68 + if err := c.LexDo(ctx, lexutil.Query, "", "app.bsky.unspecced.getPostThreadOtherV2", params, nil, &out); err != nil { 70 69 return nil, err 71 70 } 72 71
+4 -5
api/bsky/unspeccedgetPostThreadV2.go
··· 9 9 "encoding/json" 10 10 "fmt" 11 11 12 - "github.com/bluesky-social/indigo/lex/util" 12 + lexutil "github.com/bluesky-social/indigo/lex/util" 13 13 ) 14 14 15 15 // UnspeccedGetPostThreadV2_Output is the output of a app.bsky.unspecced.getPostThreadV2 call. ··· 57 57 } 58 58 59 59 func (t *UnspeccedGetPostThreadV2_ThreadItem_Value) UnmarshalJSON(b []byte) error { 60 - typ, err := util.TypeExtract(b) 60 + typ, err := lexutil.TypeExtract(b) 61 61 if err != nil { 62 62 return err 63 63 } ··· 75 75 case "app.bsky.unspecced.defs#threadItemBlocked": 76 76 t.UnspeccedDefs_ThreadItemBlocked = new(UnspeccedDefs_ThreadItemBlocked) 77 77 return json.Unmarshal(b, t.UnspeccedDefs_ThreadItemBlocked) 78 - 79 78 default: 80 79 return nil 81 80 } ··· 89 88 // branchingFactor: Maximum of replies to include at each level of the thread, except for the direct replies to the anchor, which are (NOTE: currently, during unspecced phase) all returned (NOTE: later they might be paginated). 90 89 // prioritizeFollowedUsers: Whether to prioritize posts from followed users. It only has effect when the user is authenticated. 91 90 // sort: Sorting for the thread replies. 92 - func UnspeccedGetPostThreadV2(ctx context.Context, c util.LexClient, above bool, anchor string, below int64, branchingFactor int64, prioritizeFollowedUsers bool, sort string) (*UnspeccedGetPostThreadV2_Output, error) { 91 + func UnspeccedGetPostThreadV2(ctx context.Context, c lexutil.LexClient, above bool, anchor string, below int64, branchingFactor int64, prioritizeFollowedUsers bool, sort string) (*UnspeccedGetPostThreadV2_Output, error) { 93 92 var out UnspeccedGetPostThreadV2_Output 94 93 95 94 params := map[string]interface{}{} ··· 109 108 if sort != "" { 110 109 params["sort"] = sort 111 110 } 112 - if err := c.LexDo(ctx, util.Query, "", "app.bsky.unspecced.getPostThreadV2", params, nil, &out); err != nil { 111 + if err := c.LexDo(ctx, lexutil.Query, "", "app.bsky.unspecced.getPostThreadV2", params, nil, &out); err != nil { 113 112 return nil, err 114 113 } 115 114
+3 -3
api/bsky/unspeccedgetSuggestedFeeds.go
··· 7 7 import ( 8 8 "context" 9 9 10 - "github.com/bluesky-social/indigo/lex/util" 10 + lexutil "github.com/bluesky-social/indigo/lex/util" 11 11 ) 12 12 13 13 // UnspeccedGetSuggestedFeeds_Output is the output of a app.bsky.unspecced.getSuggestedFeeds call. ··· 16 16 } 17 17 18 18 // UnspeccedGetSuggestedFeeds calls the XRPC method "app.bsky.unspecced.getSuggestedFeeds". 19 - func UnspeccedGetSuggestedFeeds(ctx context.Context, c util.LexClient, limit int64) (*UnspeccedGetSuggestedFeeds_Output, error) { 19 + func UnspeccedGetSuggestedFeeds(ctx context.Context, c lexutil.LexClient, limit int64) (*UnspeccedGetSuggestedFeeds_Output, error) { 20 20 var out UnspeccedGetSuggestedFeeds_Output 21 21 22 22 params := map[string]interface{}{} 23 23 if limit != 0 { 24 24 params["limit"] = limit 25 25 } 26 - if err := c.LexDo(ctx, util.Query, "", "app.bsky.unspecced.getSuggestedFeeds", params, nil, &out); err != nil { 26 + if err := c.LexDo(ctx, lexutil.Query, "", "app.bsky.unspecced.getSuggestedFeeds", params, nil, &out); err != nil { 27 27 return nil, err 28 28 } 29 29
+3 -3
api/bsky/unspeccedgetSuggestedFeedsSkeleton.go
··· 7 7 import ( 8 8 "context" 9 9 10 - "github.com/bluesky-social/indigo/lex/util" 10 + lexutil "github.com/bluesky-social/indigo/lex/util" 11 11 ) 12 12 13 13 // UnspeccedGetSuggestedFeedsSkeleton_Output is the output of a app.bsky.unspecced.getSuggestedFeedsSkeleton call. ··· 18 18 // UnspeccedGetSuggestedFeedsSkeleton calls the XRPC method "app.bsky.unspecced.getSuggestedFeedsSkeleton". 19 19 // 20 20 // viewer: DID of the account making the request (not included for public/unauthenticated queries). 21 - func UnspeccedGetSuggestedFeedsSkeleton(ctx context.Context, c util.LexClient, limit int64, viewer string) (*UnspeccedGetSuggestedFeedsSkeleton_Output, error) { 21 + func UnspeccedGetSuggestedFeedsSkeleton(ctx context.Context, c lexutil.LexClient, limit int64, viewer string) (*UnspeccedGetSuggestedFeedsSkeleton_Output, error) { 22 22 var out UnspeccedGetSuggestedFeedsSkeleton_Output 23 23 24 24 params := map[string]interface{}{} ··· 28 28 if viewer != "" { 29 29 params["viewer"] = viewer 30 30 } 31 - if err := c.LexDo(ctx, util.Query, "", "app.bsky.unspecced.getSuggestedFeedsSkeleton", params, nil, &out); err != nil { 31 + if err := c.LexDo(ctx, lexutil.Query, "", "app.bsky.unspecced.getSuggestedFeedsSkeleton", params, nil, &out); err != nil { 32 32 return nil, err 33 33 } 34 34
+3 -3
api/bsky/unspeccedgetSuggestedStarterPacks.go
··· 7 7 import ( 8 8 "context" 9 9 10 - "github.com/bluesky-social/indigo/lex/util" 10 + lexutil "github.com/bluesky-social/indigo/lex/util" 11 11 ) 12 12 13 13 // UnspeccedGetSuggestedStarterPacks_Output is the output of a app.bsky.unspecced.getSuggestedStarterPacks call. ··· 16 16 } 17 17 18 18 // UnspeccedGetSuggestedStarterPacks calls the XRPC method "app.bsky.unspecced.getSuggestedStarterPacks". 19 - func UnspeccedGetSuggestedStarterPacks(ctx context.Context, c util.LexClient, limit int64) (*UnspeccedGetSuggestedStarterPacks_Output, error) { 19 + func UnspeccedGetSuggestedStarterPacks(ctx context.Context, c lexutil.LexClient, limit int64) (*UnspeccedGetSuggestedStarterPacks_Output, error) { 20 20 var out UnspeccedGetSuggestedStarterPacks_Output 21 21 22 22 params := map[string]interface{}{} 23 23 if limit != 0 { 24 24 params["limit"] = limit 25 25 } 26 - if err := c.LexDo(ctx, util.Query, "", "app.bsky.unspecced.getSuggestedStarterPacks", params, nil, &out); err != nil { 26 + if err := c.LexDo(ctx, lexutil.Query, "", "app.bsky.unspecced.getSuggestedStarterPacks", params, nil, &out); err != nil { 27 27 return nil, err 28 28 } 29 29
+3 -3
api/bsky/unspeccedgetSuggestedStarterPacksSkeleton.go
··· 7 7 import ( 8 8 "context" 9 9 10 - "github.com/bluesky-social/indigo/lex/util" 10 + lexutil "github.com/bluesky-social/indigo/lex/util" 11 11 ) 12 12 13 13 // UnspeccedGetSuggestedStarterPacksSkeleton_Output is the output of a app.bsky.unspecced.getSuggestedStarterPacksSkeleton call. ··· 18 18 // UnspeccedGetSuggestedStarterPacksSkeleton calls the XRPC method "app.bsky.unspecced.getSuggestedStarterPacksSkeleton". 19 19 // 20 20 // viewer: DID of the account making the request (not included for public/unauthenticated queries). 21 - func UnspeccedGetSuggestedStarterPacksSkeleton(ctx context.Context, c util.LexClient, limit int64, viewer string) (*UnspeccedGetSuggestedStarterPacksSkeleton_Output, error) { 21 + func UnspeccedGetSuggestedStarterPacksSkeleton(ctx context.Context, c lexutil.LexClient, limit int64, viewer string) (*UnspeccedGetSuggestedStarterPacksSkeleton_Output, error) { 22 22 var out UnspeccedGetSuggestedStarterPacksSkeleton_Output 23 23 24 24 params := map[string]interface{}{} ··· 28 28 if viewer != "" { 29 29 params["viewer"] = viewer 30 30 } 31 - if err := c.LexDo(ctx, util.Query, "", "app.bsky.unspecced.getSuggestedStarterPacksSkeleton", params, nil, &out); err != nil { 31 + if err := c.LexDo(ctx, lexutil.Query, "", "app.bsky.unspecced.getSuggestedStarterPacksSkeleton", params, nil, &out); err != nil { 32 32 return nil, err 33 33 } 34 34
+3 -3
api/bsky/unspeccedgetSuggestedUsers.go
··· 7 7 import ( 8 8 "context" 9 9 10 - "github.com/bluesky-social/indigo/lex/util" 10 + lexutil "github.com/bluesky-social/indigo/lex/util" 11 11 ) 12 12 13 13 // UnspeccedGetSuggestedUsers_Output is the output of a app.bsky.unspecced.getSuggestedUsers call. ··· 18 18 // UnspeccedGetSuggestedUsers calls the XRPC method "app.bsky.unspecced.getSuggestedUsers". 19 19 // 20 20 // category: Category of users to get suggestions for. 21 - func UnspeccedGetSuggestedUsers(ctx context.Context, c util.LexClient, category string, limit int64) (*UnspeccedGetSuggestedUsers_Output, error) { 21 + func UnspeccedGetSuggestedUsers(ctx context.Context, c lexutil.LexClient, category string, limit int64) (*UnspeccedGetSuggestedUsers_Output, error) { 22 22 var out UnspeccedGetSuggestedUsers_Output 23 23 24 24 params := map[string]interface{}{} ··· 28 28 if limit != 0 { 29 29 params["limit"] = limit 30 30 } 31 - if err := c.LexDo(ctx, util.Query, "", "app.bsky.unspecced.getSuggestedUsers", params, nil, &out); err != nil { 31 + if err := c.LexDo(ctx, lexutil.Query, "", "app.bsky.unspecced.getSuggestedUsers", params, nil, &out); err != nil { 32 32 return nil, err 33 33 } 34 34
+3 -3
api/bsky/unspeccedgetSuggestedUsersSkeleton.go
··· 7 7 import ( 8 8 "context" 9 9 10 - "github.com/bluesky-social/indigo/lex/util" 10 + lexutil "github.com/bluesky-social/indigo/lex/util" 11 11 ) 12 12 13 13 // UnspeccedGetSuggestedUsersSkeleton_Output is the output of a app.bsky.unspecced.getSuggestedUsersSkeleton call. ··· 19 19 // 20 20 // category: Category of users to get suggestions for. 21 21 // viewer: DID of the account making the request (not included for public/unauthenticated queries). 22 - func UnspeccedGetSuggestedUsersSkeleton(ctx context.Context, c util.LexClient, category string, limit int64, viewer string) (*UnspeccedGetSuggestedUsersSkeleton_Output, error) { 22 + func UnspeccedGetSuggestedUsersSkeleton(ctx context.Context, c lexutil.LexClient, category string, limit int64, viewer string) (*UnspeccedGetSuggestedUsersSkeleton_Output, error) { 23 23 var out UnspeccedGetSuggestedUsersSkeleton_Output 24 24 25 25 params := map[string]interface{}{} ··· 32 32 if viewer != "" { 33 33 params["viewer"] = viewer 34 34 } 35 - if err := c.LexDo(ctx, util.Query, "", "app.bsky.unspecced.getSuggestedUsersSkeleton", params, nil, &out); err != nil { 35 + if err := c.LexDo(ctx, lexutil.Query, "", "app.bsky.unspecced.getSuggestedUsersSkeleton", params, nil, &out); err != nil { 36 36 return nil, err 37 37 } 38 38
+3 -3
api/bsky/unspeccedgetSuggestionsSkeleton.go
··· 7 7 import ( 8 8 "context" 9 9 10 - "github.com/bluesky-social/indigo/lex/util" 10 + lexutil "github.com/bluesky-social/indigo/lex/util" 11 11 ) 12 12 13 13 // UnspeccedGetSuggestionsSkeleton_Output is the output of a app.bsky.unspecced.getSuggestionsSkeleton call. ··· 24 24 // 25 25 // relativeToDid: DID of the account to get suggestions relative to. If not provided, suggestions will be based on the viewer. 26 26 // viewer: DID of the account making the request (not included for public/unauthenticated queries). Used to boost followed accounts in ranking. 27 - func UnspeccedGetSuggestionsSkeleton(ctx context.Context, c util.LexClient, cursor string, limit int64, relativeToDid string, viewer string) (*UnspeccedGetSuggestionsSkeleton_Output, error) { 27 + func UnspeccedGetSuggestionsSkeleton(ctx context.Context, c lexutil.LexClient, cursor string, limit int64, relativeToDid string, viewer string) (*UnspeccedGetSuggestionsSkeleton_Output, error) { 28 28 var out UnspeccedGetSuggestionsSkeleton_Output 29 29 30 30 params := map[string]interface{}{} ··· 40 40 if viewer != "" { 41 41 params["viewer"] = viewer 42 42 } 43 - if err := c.LexDo(ctx, util.Query, "", "app.bsky.unspecced.getSuggestionsSkeleton", params, nil, &out); err != nil { 43 + if err := c.LexDo(ctx, lexutil.Query, "", "app.bsky.unspecced.getSuggestionsSkeleton", params, nil, &out); err != nil { 44 44 return nil, err 45 45 } 46 46
+3 -3
api/bsky/unspeccedgetTaggedSuggestions.go
··· 7 7 import ( 8 8 "context" 9 9 10 - "github.com/bluesky-social/indigo/lex/util" 10 + lexutil "github.com/bluesky-social/indigo/lex/util" 11 11 ) 12 12 13 13 // UnspeccedGetTaggedSuggestions_Output is the output of a app.bsky.unspecced.getTaggedSuggestions call. ··· 23 23 } 24 24 25 25 // UnspeccedGetTaggedSuggestions calls the XRPC method "app.bsky.unspecced.getTaggedSuggestions". 26 - func UnspeccedGetTaggedSuggestions(ctx context.Context, c util.LexClient) (*UnspeccedGetTaggedSuggestions_Output, error) { 26 + func UnspeccedGetTaggedSuggestions(ctx context.Context, c lexutil.LexClient) (*UnspeccedGetTaggedSuggestions_Output, error) { 27 27 var out UnspeccedGetTaggedSuggestions_Output 28 28 29 29 params := map[string]interface{}{} 30 - if err := c.LexDo(ctx, util.Query, "", "app.bsky.unspecced.getTaggedSuggestions", params, nil, &out); err != nil { 30 + if err := c.LexDo(ctx, lexutil.Query, "", "app.bsky.unspecced.getTaggedSuggestions", params, nil, &out); err != nil { 31 31 return nil, err 32 32 } 33 33
-32
api/bsky/unspeccedgetTimelineSkeleton.go
··· 1 - // Code generated by cmd/lexgen (see Makefile's lexgen); DO NOT EDIT. 2 - 3 - package bsky 4 - 5 - // schema: app.bsky.unspecced.getTimelineSkeleton 6 - 7 - import ( 8 - "context" 9 - 10 - "github.com/bluesky-social/indigo/xrpc" 11 - ) 12 - 13 - // UnspeccedGetTimelineSkeleton_Output is the output of a app.bsky.unspecced.getTimelineSkeleton call. 14 - type UnspeccedGetTimelineSkeleton_Output struct { 15 - Cursor *string `json:"cursor,omitempty" cborgen:"cursor,omitempty"` 16 - Feed []*FeedDefs_SkeletonFeedPost `json:"feed" cborgen:"feed"` 17 - } 18 - 19 - // UnspeccedGetTimelineSkeleton calls the XRPC method "app.bsky.unspecced.getTimelineSkeleton". 20 - func UnspeccedGetTimelineSkeleton(ctx context.Context, c *xrpc.Client, cursor string, limit int64) (*UnspeccedGetTimelineSkeleton_Output, error) { 21 - var out UnspeccedGetTimelineSkeleton_Output 22 - 23 - params := map[string]interface{}{ 24 - "cursor": cursor, 25 - "limit": limit, 26 - } 27 - if err := c.Do(ctx, xrpc.Query, "", "app.bsky.unspecced.getTimelineSkeleton", params, nil, &out); err != nil { 28 - return nil, err 29 - } 30 - 31 - return &out, nil 32 - }
+3 -3
api/bsky/unspeccedgetTrendingTopics.go
··· 7 7 import ( 8 8 "context" 9 9 10 - "github.com/bluesky-social/indigo/lex/util" 10 + lexutil "github.com/bluesky-social/indigo/lex/util" 11 11 ) 12 12 13 13 // UnspeccedGetTrendingTopics_Output is the output of a app.bsky.unspecced.getTrendingTopics call. ··· 19 19 // UnspeccedGetTrendingTopics calls the XRPC method "app.bsky.unspecced.getTrendingTopics". 20 20 // 21 21 // viewer: DID of the account making the request (not included for public/unauthenticated queries). Used to boost followed accounts in ranking. 22 - func UnspeccedGetTrendingTopics(ctx context.Context, c util.LexClient, limit int64, viewer string) (*UnspeccedGetTrendingTopics_Output, error) { 22 + func UnspeccedGetTrendingTopics(ctx context.Context, c lexutil.LexClient, limit int64, viewer string) (*UnspeccedGetTrendingTopics_Output, error) { 23 23 var out UnspeccedGetTrendingTopics_Output 24 24 25 25 params := map[string]interface{}{} ··· 29 29 if viewer != "" { 30 30 params["viewer"] = viewer 31 31 } 32 - if err := c.LexDo(ctx, util.Query, "", "app.bsky.unspecced.getTrendingTopics", params, nil, &out); err != nil { 32 + if err := c.LexDo(ctx, lexutil.Query, "", "app.bsky.unspecced.getTrendingTopics", params, nil, &out); err != nil { 33 33 return nil, err 34 34 } 35 35
+3 -3
api/bsky/unspeccedgetTrends.go
··· 7 7 import ( 8 8 "context" 9 9 10 - "github.com/bluesky-social/indigo/lex/util" 10 + lexutil "github.com/bluesky-social/indigo/lex/util" 11 11 ) 12 12 13 13 // UnspeccedGetTrends_Output is the output of a app.bsky.unspecced.getTrends call. ··· 16 16 } 17 17 18 18 // UnspeccedGetTrends calls the XRPC method "app.bsky.unspecced.getTrends". 19 - func UnspeccedGetTrends(ctx context.Context, c util.LexClient, limit int64) (*UnspeccedGetTrends_Output, error) { 19 + func UnspeccedGetTrends(ctx context.Context, c lexutil.LexClient, limit int64) (*UnspeccedGetTrends_Output, error) { 20 20 var out UnspeccedGetTrends_Output 21 21 22 22 params := map[string]interface{}{} 23 23 if limit != 0 { 24 24 params["limit"] = limit 25 25 } 26 - if err := c.LexDo(ctx, util.Query, "", "app.bsky.unspecced.getTrends", params, nil, &out); err != nil { 26 + if err := c.LexDo(ctx, lexutil.Query, "", "app.bsky.unspecced.getTrends", params, nil, &out); err != nil { 27 27 return nil, err 28 28 } 29 29
+3 -3
api/bsky/unspeccedgetTrendsSkeleton.go
··· 7 7 import ( 8 8 "context" 9 9 10 - "github.com/bluesky-social/indigo/lex/util" 10 + lexutil "github.com/bluesky-social/indigo/lex/util" 11 11 ) 12 12 13 13 // UnspeccedGetTrendsSkeleton_Output is the output of a app.bsky.unspecced.getTrendsSkeleton call. ··· 18 18 // UnspeccedGetTrendsSkeleton calls the XRPC method "app.bsky.unspecced.getTrendsSkeleton". 19 19 // 20 20 // viewer: DID of the account making the request (not included for public/unauthenticated queries). 21 - func UnspeccedGetTrendsSkeleton(ctx context.Context, c util.LexClient, limit int64, viewer string) (*UnspeccedGetTrendsSkeleton_Output, error) { 21 + func UnspeccedGetTrendsSkeleton(ctx context.Context, c lexutil.LexClient, limit int64, viewer string) (*UnspeccedGetTrendsSkeleton_Output, error) { 22 22 var out UnspeccedGetTrendsSkeleton_Output 23 23 24 24 params := map[string]interface{}{} ··· 28 28 if viewer != "" { 29 29 params["viewer"] = viewer 30 30 } 31 - if err := c.LexDo(ctx, util.Query, "", "app.bsky.unspecced.getTrendsSkeleton", params, nil, &out); err != nil { 31 + if err := c.LexDo(ctx, lexutil.Query, "", "app.bsky.unspecced.getTrendsSkeleton", params, nil, &out); err != nil { 32 32 return nil, err 33 33 } 34 34
+3 -3
api/bsky/unspeccedinitAgeAssurance.go
··· 7 7 import ( 8 8 "context" 9 9 10 - "github.com/bluesky-social/indigo/lex/util" 10 + lexutil "github.com/bluesky-social/indigo/lex/util" 11 11 ) 12 12 13 13 // UnspeccedInitAgeAssurance_Input is the input argument to a app.bsky.unspecced.initAgeAssurance call. ··· 21 21 } 22 22 23 23 // UnspeccedInitAgeAssurance calls the XRPC method "app.bsky.unspecced.initAgeAssurance". 24 - func UnspeccedInitAgeAssurance(ctx context.Context, c util.LexClient, input *UnspeccedInitAgeAssurance_Input) (*UnspeccedDefs_AgeAssuranceState, error) { 24 + func UnspeccedInitAgeAssurance(ctx context.Context, c lexutil.LexClient, input *UnspeccedInitAgeAssurance_Input) (*UnspeccedDefs_AgeAssuranceState, error) { 25 25 var out UnspeccedDefs_AgeAssuranceState 26 - if err := c.LexDo(ctx, util.Procedure, "application/json", "app.bsky.unspecced.initAgeAssurance", nil, input, &out); err != nil { 26 + if err := c.LexDo(ctx, lexutil.Procedure, "application/json", "app.bsky.unspecced.initAgeAssurance", nil, input, &out); err != nil { 27 27 return nil, err 28 28 } 29 29
+3 -3
api/bsky/unspeccedsearchActorsSkeleton.go
··· 7 7 import ( 8 8 "context" 9 9 10 - "github.com/bluesky-social/indigo/lex/util" 10 + lexutil "github.com/bluesky-social/indigo/lex/util" 11 11 ) 12 12 13 13 // UnspeccedSearchActorsSkeleton_Output is the output of a app.bsky.unspecced.searchActorsSkeleton call. ··· 24 24 // q: Search query string; syntax, phrase, boolean, and faceting is unspecified, but Lucene query syntax is recommended. For typeahead search, only simple term match is supported, not full syntax. 25 25 // typeahead: If true, acts as fast/simple 'typeahead' query. 26 26 // viewer: DID of the account making the request (not included for public/unauthenticated queries). Used to boost followed accounts in ranking. 27 - func UnspeccedSearchActorsSkeleton(ctx context.Context, c util.LexClient, cursor string, limit int64, q string, typeahead bool, viewer string) (*UnspeccedSearchActorsSkeleton_Output, error) { 27 + func UnspeccedSearchActorsSkeleton(ctx context.Context, c lexutil.LexClient, cursor string, limit int64, q string, typeahead bool, viewer string) (*UnspeccedSearchActorsSkeleton_Output, error) { 28 28 var out UnspeccedSearchActorsSkeleton_Output 29 29 30 30 params := map[string]interface{}{} ··· 41 41 if viewer != "" { 42 42 params["viewer"] = viewer 43 43 } 44 - if err := c.LexDo(ctx, util.Query, "", "app.bsky.unspecced.searchActorsSkeleton", params, nil, &out); err != nil { 44 + if err := c.LexDo(ctx, lexutil.Query, "", "app.bsky.unspecced.searchActorsSkeleton", params, nil, &out); err != nil { 45 45 return nil, err 46 46 } 47 47
+3 -3
api/bsky/unspeccedsearchPostsSkeleton.go
··· 7 7 import ( 8 8 "context" 9 9 10 - "github.com/bluesky-social/indigo/lex/util" 10 + lexutil "github.com/bluesky-social/indigo/lex/util" 11 11 ) 12 12 13 13 // UnspeccedSearchPostsSkeleton_Output is the output of a app.bsky.unspecced.searchPostsSkeleton call. ··· 32 32 // until: Filter results for posts before the indicated datetime (not inclusive). Expected to use 'sortAt' timestamp, which may not match 'createdAt'. Can be a datetime, or just an ISO date (YYY-MM-DD). 33 33 // url: Filter to posts with links (facet links or embeds) pointing to this URL. Server may apply URL normalization or fuzzy matching. 34 34 // viewer: DID of the account making the request (not included for public/unauthenticated queries). Used for 'from:me' queries. 35 - func UnspeccedSearchPostsSkeleton(ctx context.Context, c util.LexClient, author string, cursor string, domain string, lang string, limit int64, mentions string, q string, since string, sort string, tag []string, until string, url string, viewer string) (*UnspeccedSearchPostsSkeleton_Output, error) { 35 + func UnspeccedSearchPostsSkeleton(ctx context.Context, c lexutil.LexClient, author string, cursor string, domain string, lang string, limit int64, mentions string, q string, since string, sort string, tag []string, until string, url string, viewer string) (*UnspeccedSearchPostsSkeleton_Output, error) { 36 36 var out UnspeccedSearchPostsSkeleton_Output 37 37 38 38 params := map[string]interface{}{} ··· 73 73 if viewer != "" { 74 74 params["viewer"] = viewer 75 75 } 76 - if err := c.LexDo(ctx, util.Query, "", "app.bsky.unspecced.searchPostsSkeleton", params, nil, &out); err != nil { 76 + if err := c.LexDo(ctx, lexutil.Query, "", "app.bsky.unspecced.searchPostsSkeleton", params, nil, &out); err != nil { 77 77 return nil, err 78 78 } 79 79
+3 -3
api/bsky/unspeccedsearchStarterPacksSkeleton.go
··· 7 7 import ( 8 8 "context" 9 9 10 - "github.com/bluesky-social/indigo/lex/util" 10 + lexutil "github.com/bluesky-social/indigo/lex/util" 11 11 ) 12 12 13 13 // UnspeccedSearchStarterPacksSkeleton_Output is the output of a app.bsky.unspecced.searchStarterPacksSkeleton call. ··· 23 23 // cursor: Optional pagination mechanism; may not necessarily allow scrolling through entire result set. 24 24 // q: Search query string; syntax, phrase, boolean, and faceting is unspecified, but Lucene query syntax is recommended. 25 25 // viewer: DID of the account making the request (not included for public/unauthenticated queries). 26 - func UnspeccedSearchStarterPacksSkeleton(ctx context.Context, c util.LexClient, cursor string, limit int64, q string, viewer string) (*UnspeccedSearchStarterPacksSkeleton_Output, error) { 26 + func UnspeccedSearchStarterPacksSkeleton(ctx context.Context, c lexutil.LexClient, cursor string, limit int64, q string, viewer string) (*UnspeccedSearchStarterPacksSkeleton_Output, error) { 27 27 var out UnspeccedSearchStarterPacksSkeleton_Output 28 28 29 29 params := map[string]interface{}{} ··· 37 37 if viewer != "" { 38 38 params["viewer"] = viewer 39 39 } 40 - if err := c.LexDo(ctx, util.Query, "", "app.bsky.unspecced.searchStarterPacksSkeleton", params, nil, &out); err != nil { 40 + if err := c.LexDo(ctx, lexutil.Query, "", "app.bsky.unspecced.searchStarterPacksSkeleton", params, nil, &out); err != nil { 41 41 return nil, err 42 42 } 43 43
+6 -6
api/bsky/videodefs.go
··· 5 5 package bsky 6 6 7 7 import ( 8 - "github.com/bluesky-social/indigo/lex/util" 8 + lexutil "github.com/bluesky-social/indigo/lex/util" 9 9 ) 10 10 11 11 // VideoDefs_JobStatus is a "jobStatus" in the app.bsky.video.defs schema. 12 12 type VideoDefs_JobStatus struct { 13 - Blob *util.LexBlob `json:"blob,omitempty" cborgen:"blob,omitempty"` 14 - Did string `json:"did" cborgen:"did"` 15 - Error *string `json:"error,omitempty" cborgen:"error,omitempty"` 16 - JobId string `json:"jobId" cborgen:"jobId"` 17 - Message *string `json:"message,omitempty" cborgen:"message,omitempty"` 13 + Blob *lexutil.LexBlob `json:"blob,omitempty" cborgen:"blob,omitempty"` 14 + Did string `json:"did" cborgen:"did"` 15 + Error *string `json:"error,omitempty" cborgen:"error,omitempty"` 16 + JobId string `json:"jobId" cborgen:"jobId"` 17 + Message *string `json:"message,omitempty" cborgen:"message,omitempty"` 18 18 // progress: Progress within the current processing state. 19 19 Progress *int64 `json:"progress,omitempty" cborgen:"progress,omitempty"` 20 20 // state: The state of the video processing job. All values not listed as a known value indicate that the job is in process.
+3 -3
api/bsky/videogetJobStatus.go
··· 7 7 import ( 8 8 "context" 9 9 10 - "github.com/bluesky-social/indigo/lex/util" 10 + lexutil "github.com/bluesky-social/indigo/lex/util" 11 11 ) 12 12 13 13 // VideoGetJobStatus_Output is the output of a app.bsky.video.getJobStatus call. ··· 16 16 } 17 17 18 18 // VideoGetJobStatus calls the XRPC method "app.bsky.video.getJobStatus". 19 - func VideoGetJobStatus(ctx context.Context, c util.LexClient, jobId string) (*VideoGetJobStatus_Output, error) { 19 + func VideoGetJobStatus(ctx context.Context, c lexutil.LexClient, jobId string) (*VideoGetJobStatus_Output, error) { 20 20 var out VideoGetJobStatus_Output 21 21 22 22 params := map[string]interface{}{} 23 23 params["jobId"] = jobId 24 - if err := c.LexDo(ctx, util.Query, "", "app.bsky.video.getJobStatus", params, nil, &out); err != nil { 24 + if err := c.LexDo(ctx, lexutil.Query, "", "app.bsky.video.getJobStatus", params, nil, &out); err != nil { 25 25 return nil, err 26 26 } 27 27
+3 -3
api/bsky/videogetUploadLimits.go
··· 7 7 import ( 8 8 "context" 9 9 10 - "github.com/bluesky-social/indigo/lex/util" 10 + lexutil "github.com/bluesky-social/indigo/lex/util" 11 11 ) 12 12 13 13 // VideoGetUploadLimits_Output is the output of a app.bsky.video.getUploadLimits call. ··· 20 20 } 21 21 22 22 // VideoGetUploadLimits calls the XRPC method "app.bsky.video.getUploadLimits". 23 - func VideoGetUploadLimits(ctx context.Context, c util.LexClient) (*VideoGetUploadLimits_Output, error) { 23 + func VideoGetUploadLimits(ctx context.Context, c lexutil.LexClient) (*VideoGetUploadLimits_Output, error) { 24 24 var out VideoGetUploadLimits_Output 25 - if err := c.LexDo(ctx, util.Query, "", "app.bsky.video.getUploadLimits", nil, nil, &out); err != nil { 25 + if err := c.LexDo(ctx, lexutil.Query, "", "app.bsky.video.getUploadLimits", nil, nil, &out); err != nil { 26 26 return nil, err 27 27 } 28 28
+3 -3
api/bsky/videouploadVideo.go
··· 8 8 "context" 9 9 "io" 10 10 11 - "github.com/bluesky-social/indigo/lex/util" 11 + lexutil "github.com/bluesky-social/indigo/lex/util" 12 12 ) 13 13 14 14 // VideoUploadVideo_Output is the output of a app.bsky.video.uploadVideo call. ··· 17 17 } 18 18 19 19 // VideoUploadVideo calls the XRPC method "app.bsky.video.uploadVideo". 20 - func VideoUploadVideo(ctx context.Context, c util.LexClient, input io.Reader) (*VideoUploadVideo_Output, error) { 20 + func VideoUploadVideo(ctx context.Context, c lexutil.LexClient, input io.Reader) (*VideoUploadVideo_Output, error) { 21 21 var out VideoUploadVideo_Output 22 - if err := c.LexDo(ctx, util.Procedure, "video/mp4", "app.bsky.video.uploadVideo", nil, input, &out); err != nil { 22 + if err := c.LexDo(ctx, lexutil.Procedure, "video/mp4", "app.bsky.video.uploadVideo", nil, input, &out); err != nil { 23 23 return nil, err 24 24 } 25 25
+2 -2
api/chat/actordeclaration.go
··· 5 5 package chat 6 6 7 7 import ( 8 - "github.com/bluesky-social/indigo/lex/util" 8 + lexutil "github.com/bluesky-social/indigo/lex/util" 9 9 ) 10 10 11 11 func init() { 12 - util.RegisterType("chat.bsky.actor.declaration", &ActorDeclaration{}) 12 + lexutil.RegisterType("chat.bsky.actor.declaration", &ActorDeclaration{}) 13 13 } 14 14 15 15 type ActorDeclaration struct {
+11 -11
api/chat/actordefs.go
··· 5 5 package chat 6 6 7 7 import ( 8 - comatprototypes "github.com/bluesky-social/indigo/api/atproto" 9 - appbskytypes "github.com/bluesky-social/indigo/api/bsky" 8 + comatproto "github.com/bluesky-social/indigo/api/atproto" 9 + appbsky "github.com/bluesky-social/indigo/api/bsky" 10 10 ) 11 11 12 12 // ActorDefs_ProfileViewBasic is a "profileViewBasic" in the chat.bsky.actor.defs schema. 13 13 type ActorDefs_ProfileViewBasic struct { 14 - Associated *appbskytypes.ActorDefs_ProfileAssociated `json:"associated,omitempty" cborgen:"associated,omitempty"` 15 - Avatar *string `json:"avatar,omitempty" cborgen:"avatar,omitempty"` 14 + Associated *appbsky.ActorDefs_ProfileAssociated `json:"associated,omitempty" cborgen:"associated,omitempty"` 15 + Avatar *string `json:"avatar,omitempty" cborgen:"avatar,omitempty"` 16 16 // chatDisabled: Set to true when the actor cannot actively participate in conversations 17 - ChatDisabled *bool `json:"chatDisabled,omitempty" cborgen:"chatDisabled,omitempty"` 18 - Did string `json:"did" cborgen:"did"` 19 - DisplayName *string `json:"displayName,omitempty" cborgen:"displayName,omitempty"` 20 - Handle string `json:"handle" cborgen:"handle"` 21 - Labels []*comatprototypes.LabelDefs_Label `json:"labels,omitempty" cborgen:"labels,omitempty"` 22 - Verification *appbskytypes.ActorDefs_VerificationState `json:"verification,omitempty" cborgen:"verification,omitempty"` 23 - Viewer *appbskytypes.ActorDefs_ViewerState `json:"viewer,omitempty" cborgen:"viewer,omitempty"` 17 + ChatDisabled *bool `json:"chatDisabled,omitempty" cborgen:"chatDisabled,omitempty"` 18 + Did string `json:"did" cborgen:"did"` 19 + DisplayName *string `json:"displayName,omitempty" cborgen:"displayName,omitempty"` 20 + Handle string `json:"handle" cborgen:"handle"` 21 + Labels []*comatproto.LabelDefs_Label `json:"labels,omitempty" cborgen:"labels,omitempty"` 22 + Verification *appbsky.ActorDefs_VerificationState `json:"verification,omitempty" cborgen:"verification,omitempty"` 23 + Viewer *appbsky.ActorDefs_ViewerState `json:"viewer,omitempty" cborgen:"viewer,omitempty"` 24 24 }
+3 -3
api/chat/actordeleteAccount.go
··· 7 7 import ( 8 8 "context" 9 9 10 - "github.com/bluesky-social/indigo/lex/util" 10 + lexutil "github.com/bluesky-social/indigo/lex/util" 11 11 ) 12 12 13 13 // ActorDeleteAccount_Output is the output of a chat.bsky.actor.deleteAccount call. ··· 15 15 } 16 16 17 17 // ActorDeleteAccount calls the XRPC method "chat.bsky.actor.deleteAccount". 18 - func ActorDeleteAccount(ctx context.Context, c util.LexClient) (*ActorDeleteAccount_Output, error) { 18 + func ActorDeleteAccount(ctx context.Context, c lexutil.LexClient) (*ActorDeleteAccount_Output, error) { 19 19 var out ActorDeleteAccount_Output 20 - if err := c.LexDo(ctx, util.Procedure, "", "chat.bsky.actor.deleteAccount", nil, nil, &out); err != nil { 20 + if err := c.LexDo(ctx, lexutil.Procedure, "", "chat.bsky.actor.deleteAccount", nil, nil, &out); err != nil { 21 21 return nil, err 22 22 } 23 23
+3 -3
api/chat/actorexportAccountData.go
··· 8 8 "bytes" 9 9 "context" 10 10 11 - "github.com/bluesky-social/indigo/lex/util" 11 + lexutil "github.com/bluesky-social/indigo/lex/util" 12 12 ) 13 13 14 14 // ActorExportAccountData calls the XRPC method "chat.bsky.actor.exportAccountData". 15 - func ActorExportAccountData(ctx context.Context, c util.LexClient) ([]byte, error) { 15 + func ActorExportAccountData(ctx context.Context, c lexutil.LexClient) ([]byte, error) { 16 16 buf := new(bytes.Buffer) 17 - if err := c.LexDo(ctx, util.Query, "", "chat.bsky.actor.exportAccountData", nil, nil, buf); err != nil { 17 + if err := c.LexDo(ctx, lexutil.Query, "", "chat.bsky.actor.exportAccountData", nil, nil, buf); err != nil { 18 18 return nil, err 19 19 } 20 20
+3 -3
api/chat/convoacceptConvo.go
··· 7 7 import ( 8 8 "context" 9 9 10 - "github.com/bluesky-social/indigo/lex/util" 10 + lexutil "github.com/bluesky-social/indigo/lex/util" 11 11 ) 12 12 13 13 // ConvoAcceptConvo_Input is the input argument to a chat.bsky.convo.acceptConvo call. ··· 22 22 } 23 23 24 24 // ConvoAcceptConvo calls the XRPC method "chat.bsky.convo.acceptConvo". 25 - func ConvoAcceptConvo(ctx context.Context, c util.LexClient, input *ConvoAcceptConvo_Input) (*ConvoAcceptConvo_Output, error) { 25 + func ConvoAcceptConvo(ctx context.Context, c lexutil.LexClient, input *ConvoAcceptConvo_Input) (*ConvoAcceptConvo_Output, error) { 26 26 var out ConvoAcceptConvo_Output 27 - if err := c.LexDo(ctx, util.Procedure, "application/json", "chat.bsky.convo.acceptConvo", nil, input, &out); err != nil { 27 + if err := c.LexDo(ctx, lexutil.Procedure, "application/json", "chat.bsky.convo.acceptConvo", nil, input, &out); err != nil { 28 28 return nil, err 29 29 } 30 30
+3 -3
api/chat/convoaddReaction.go
··· 7 7 import ( 8 8 "context" 9 9 10 - "github.com/bluesky-social/indigo/lex/util" 10 + lexutil "github.com/bluesky-social/indigo/lex/util" 11 11 ) 12 12 13 13 // ConvoAddReaction_Input is the input argument to a chat.bsky.convo.addReaction call. ··· 23 23 } 24 24 25 25 // ConvoAddReaction calls the XRPC method "chat.bsky.convo.addReaction". 26 - func ConvoAddReaction(ctx context.Context, c util.LexClient, input *ConvoAddReaction_Input) (*ConvoAddReaction_Output, error) { 26 + func ConvoAddReaction(ctx context.Context, c lexutil.LexClient, input *ConvoAddReaction_Input) (*ConvoAddReaction_Output, error) { 27 27 var out ConvoAddReaction_Output 28 - if err := c.LexDo(ctx, util.Procedure, "application/json", "chat.bsky.convo.addReaction", nil, input, &out); err != nil { 28 + if err := c.LexDo(ctx, lexutil.Procedure, "application/json", "chat.bsky.convo.addReaction", nil, input, &out); err != nil { 29 29 return nil, err 30 30 } 31 31
+19 -28
api/chat/convodefs.go
··· 8 8 "encoding/json" 9 9 "fmt" 10 10 11 - appbskytypes "github.com/bluesky-social/indigo/api/bsky" 12 - "github.com/bluesky-social/indigo/lex/util" 11 + appbsky "github.com/bluesky-social/indigo/api/bsky" 12 + lexutil "github.com/bluesky-social/indigo/lex/util" 13 13 ) 14 14 15 15 // ConvoDefs_ConvoView is a "convoView" in the chat.bsky.convo.defs schema. ··· 42 42 } 43 43 44 44 func (t *ConvoDefs_ConvoView_LastMessage) UnmarshalJSON(b []byte) error { 45 - typ, err := util.TypeExtract(b) 45 + typ, err := lexutil.TypeExtract(b) 46 46 if err != nil { 47 47 return err 48 48 } ··· 54 54 case "chat.bsky.convo.defs#deletedMessageView": 55 55 t.ConvoDefs_DeletedMessageView = new(ConvoDefs_DeletedMessageView) 56 56 return json.Unmarshal(b, t.ConvoDefs_DeletedMessageView) 57 - 58 57 default: 59 58 return nil 60 59 } ··· 73 72 } 74 73 75 74 func (t *ConvoDefs_ConvoView_LastReaction) UnmarshalJSON(b []byte) error { 76 - typ, err := util.TypeExtract(b) 75 + typ, err := lexutil.TypeExtract(b) 77 76 if err != nil { 78 77 return err 79 78 } ··· 82 81 case "chat.bsky.convo.defs#messageAndReactionView": 83 82 t.ConvoDefs_MessageAndReactionView = new(ConvoDefs_MessageAndReactionView) 84 83 return json.Unmarshal(b, t.ConvoDefs_MessageAndReactionView) 85 - 86 84 default: 87 85 return nil 88 86 } ··· 131 129 } 132 130 133 131 func (t *ConvoDefs_LogAddReaction_Message) UnmarshalJSON(b []byte) error { 134 - typ, err := util.TypeExtract(b) 132 + typ, err := lexutil.TypeExtract(b) 135 133 if err != nil { 136 134 return err 137 135 } ··· 143 141 case "chat.bsky.convo.defs#deletedMessageView": 144 142 t.ConvoDefs_DeletedMessageView = new(ConvoDefs_DeletedMessageView) 145 143 return json.Unmarshal(b, t.ConvoDefs_DeletedMessageView) 146 - 147 144 default: 148 145 return nil 149 146 } ··· 182 179 } 183 180 184 181 func (t *ConvoDefs_LogCreateMessage_Message) UnmarshalJSON(b []byte) error { 185 - typ, err := util.TypeExtract(b) 182 + typ, err := lexutil.TypeExtract(b) 186 183 if err != nil { 187 184 return err 188 185 } ··· 194 191 case "chat.bsky.convo.defs#deletedMessageView": 195 192 t.ConvoDefs_DeletedMessageView = new(ConvoDefs_DeletedMessageView) 196 193 return json.Unmarshal(b, t.ConvoDefs_DeletedMessageView) 197 - 198 194 default: 199 195 return nil 200 196 } ··· 226 222 } 227 223 228 224 func (t *ConvoDefs_LogDeleteMessage_Message) UnmarshalJSON(b []byte) error { 229 - typ, err := util.TypeExtract(b) 225 + typ, err := lexutil.TypeExtract(b) 230 226 if err != nil { 231 227 return err 232 228 } ··· 238 234 case "chat.bsky.convo.defs#deletedMessageView": 239 235 t.ConvoDefs_DeletedMessageView = new(ConvoDefs_DeletedMessageView) 240 236 return json.Unmarshal(b, t.ConvoDefs_DeletedMessageView) 241 - 242 237 default: 243 238 return nil 244 239 } ··· 284 279 } 285 280 286 281 func (t *ConvoDefs_LogReadMessage_Message) UnmarshalJSON(b []byte) error { 287 - typ, err := util.TypeExtract(b) 282 + typ, err := lexutil.TypeExtract(b) 288 283 if err != nil { 289 284 return err 290 285 } ··· 296 291 case "chat.bsky.convo.defs#deletedMessageView": 297 292 t.ConvoDefs_DeletedMessageView = new(ConvoDefs_DeletedMessageView) 298 293 return json.Unmarshal(b, t.ConvoDefs_DeletedMessageView) 299 - 300 294 default: 301 295 return nil 302 296 } ··· 329 323 } 330 324 331 325 func (t *ConvoDefs_LogRemoveReaction_Message) UnmarshalJSON(b []byte) error { 332 - typ, err := util.TypeExtract(b) 326 + typ, err := lexutil.TypeExtract(b) 333 327 if err != nil { 334 328 return err 335 329 } ··· 341 335 case "chat.bsky.convo.defs#deletedMessageView": 342 336 t.ConvoDefs_DeletedMessageView = new(ConvoDefs_DeletedMessageView) 343 337 return json.Unmarshal(b, t.ConvoDefs_DeletedMessageView) 344 - 345 338 default: 346 339 return nil 347 340 } ··· 365 358 type ConvoDefs_MessageInput struct { 366 359 Embed *ConvoDefs_MessageInput_Embed `json:"embed,omitempty" cborgen:"embed,omitempty"` 367 360 // facets: Annotations of text (mentions, URLs, hashtags, etc) 368 - Facets []*appbskytypes.RichtextFacet `json:"facets,omitempty" cborgen:"facets,omitempty"` 369 - Text string `json:"text" cborgen:"text"` 361 + Facets []*appbsky.RichtextFacet `json:"facets,omitempty" cborgen:"facets,omitempty"` 362 + Text string `json:"text" cborgen:"text"` 370 363 } 371 364 372 365 type ConvoDefs_MessageInput_Embed struct { 373 - EmbedRecord *appbskytypes.EmbedRecord 366 + EmbedRecord *appbsky.EmbedRecord 374 367 } 375 368 376 369 func (t *ConvoDefs_MessageInput_Embed) MarshalJSON() ([]byte, error) { ··· 382 375 } 383 376 384 377 func (t *ConvoDefs_MessageInput_Embed) UnmarshalJSON(b []byte) error { 385 - typ, err := util.TypeExtract(b) 378 + typ, err := lexutil.TypeExtract(b) 386 379 if err != nil { 387 380 return err 388 381 } 389 382 390 383 switch typ { 391 384 case "app.bsky.embed.record": 392 - t.EmbedRecord = new(appbskytypes.EmbedRecord) 385 + t.EmbedRecord = new(appbsky.EmbedRecord) 393 386 return json.Unmarshal(b, t.EmbedRecord) 394 - 395 387 default: 396 388 return nil 397 389 } ··· 410 402 LexiconTypeID string `json:"$type" cborgen:"$type,const=chat.bsky.convo.defs#messageView"` 411 403 Embed *ConvoDefs_MessageView_Embed `json:"embed,omitempty" cborgen:"embed,omitempty"` 412 404 // facets: Annotations of text (mentions, URLs, hashtags, etc) 413 - Facets []*appbskytypes.RichtextFacet `json:"facets,omitempty" cborgen:"facets,omitempty"` 414 - Id string `json:"id" cborgen:"id"` 405 + Facets []*appbsky.RichtextFacet `json:"facets,omitempty" cborgen:"facets,omitempty"` 406 + Id string `json:"id" cborgen:"id"` 415 407 // reactions: Reactions to this message, in ascending order of creation time. 416 408 Reactions []*ConvoDefs_ReactionView `json:"reactions,omitempty" cborgen:"reactions,omitempty"` 417 409 Rev string `json:"rev" cborgen:"rev"` ··· 426 418 } 427 419 428 420 type ConvoDefs_MessageView_Embed struct { 429 - EmbedRecord_View *appbskytypes.EmbedRecord_View 421 + EmbedRecord_View *appbsky.EmbedRecord_View 430 422 } 431 423 432 424 func (t *ConvoDefs_MessageView_Embed) MarshalJSON() ([]byte, error) { ··· 438 430 } 439 431 440 432 func (t *ConvoDefs_MessageView_Embed) UnmarshalJSON(b []byte) error { 441 - typ, err := util.TypeExtract(b) 433 + typ, err := lexutil.TypeExtract(b) 442 434 if err != nil { 443 435 return err 444 436 } 445 437 446 438 switch typ { 447 439 case "app.bsky.embed.record#view": 448 - t.EmbedRecord_View = new(appbskytypes.EmbedRecord_View) 440 + t.EmbedRecord_View = new(appbsky.EmbedRecord_View) 449 441 return json.Unmarshal(b, t.EmbedRecord_View) 450 - 451 442 default: 452 443 return nil 453 444 }
+3 -3
api/chat/convodeleteMessageForSelf.go
··· 7 7 import ( 8 8 "context" 9 9 10 - "github.com/bluesky-social/indigo/lex/util" 10 + lexutil "github.com/bluesky-social/indigo/lex/util" 11 11 ) 12 12 13 13 // ConvoDeleteMessageForSelf_Input is the input argument to a chat.bsky.convo.deleteMessageForSelf call. ··· 17 17 } 18 18 19 19 // ConvoDeleteMessageForSelf calls the XRPC method "chat.bsky.convo.deleteMessageForSelf". 20 - func ConvoDeleteMessageForSelf(ctx context.Context, c util.LexClient, input *ConvoDeleteMessageForSelf_Input) (*ConvoDefs_DeletedMessageView, error) { 20 + func ConvoDeleteMessageForSelf(ctx context.Context, c lexutil.LexClient, input *ConvoDeleteMessageForSelf_Input) (*ConvoDefs_DeletedMessageView, error) { 21 21 var out ConvoDefs_DeletedMessageView 22 - if err := c.LexDo(ctx, util.Procedure, "application/json", "chat.bsky.convo.deleteMessageForSelf", nil, input, &out); err != nil { 22 + if err := c.LexDo(ctx, lexutil.Procedure, "application/json", "chat.bsky.convo.deleteMessageForSelf", nil, input, &out); err != nil { 23 23 return nil, err 24 24 } 25 25
+3 -3
api/chat/convogetConvo.go
··· 7 7 import ( 8 8 "context" 9 9 10 - "github.com/bluesky-social/indigo/lex/util" 10 + lexutil "github.com/bluesky-social/indigo/lex/util" 11 11 ) 12 12 13 13 // ConvoGetConvo_Output is the output of a chat.bsky.convo.getConvo call. ··· 16 16 } 17 17 18 18 // ConvoGetConvo calls the XRPC method "chat.bsky.convo.getConvo". 19 - func ConvoGetConvo(ctx context.Context, c util.LexClient, convoId string) (*ConvoGetConvo_Output, error) { 19 + func ConvoGetConvo(ctx context.Context, c lexutil.LexClient, convoId string) (*ConvoGetConvo_Output, error) { 20 20 var out ConvoGetConvo_Output 21 21 22 22 params := map[string]interface{}{} 23 23 params["convoId"] = convoId 24 - if err := c.LexDo(ctx, util.Query, "", "chat.bsky.convo.getConvo", params, nil, &out); err != nil { 24 + if err := c.LexDo(ctx, lexutil.Query, "", "chat.bsky.convo.getConvo", params, nil, &out); err != nil { 25 25 return nil, err 26 26 } 27 27
+3 -3
api/chat/convogetConvoAvailability.go
··· 7 7 import ( 8 8 "context" 9 9 10 - "github.com/bluesky-social/indigo/lex/util" 10 + lexutil "github.com/bluesky-social/indigo/lex/util" 11 11 ) 12 12 13 13 // ConvoGetConvoAvailability_Output is the output of a chat.bsky.convo.getConvoAvailability call. ··· 17 17 } 18 18 19 19 // ConvoGetConvoAvailability calls the XRPC method "chat.bsky.convo.getConvoAvailability". 20 - func ConvoGetConvoAvailability(ctx context.Context, c util.LexClient, members []string) (*ConvoGetConvoAvailability_Output, error) { 20 + func ConvoGetConvoAvailability(ctx context.Context, c lexutil.LexClient, members []string) (*ConvoGetConvoAvailability_Output, error) { 21 21 var out ConvoGetConvoAvailability_Output 22 22 23 23 params := map[string]interface{}{} 24 24 params["members"] = members 25 - if err := c.LexDo(ctx, util.Query, "", "chat.bsky.convo.getConvoAvailability", params, nil, &out); err != nil { 25 + if err := c.LexDo(ctx, lexutil.Query, "", "chat.bsky.convo.getConvoAvailability", params, nil, &out); err != nil { 26 26 return nil, err 27 27 } 28 28
+3 -3
api/chat/convogetConvoForMembers.go
··· 7 7 import ( 8 8 "context" 9 9 10 - "github.com/bluesky-social/indigo/lex/util" 10 + lexutil "github.com/bluesky-social/indigo/lex/util" 11 11 ) 12 12 13 13 // ConvoGetConvoForMembers_Output is the output of a chat.bsky.convo.getConvoForMembers call. ··· 16 16 } 17 17 18 18 // ConvoGetConvoForMembers calls the XRPC method "chat.bsky.convo.getConvoForMembers". 19 - func ConvoGetConvoForMembers(ctx context.Context, c util.LexClient, members []string) (*ConvoGetConvoForMembers_Output, error) { 19 + func ConvoGetConvoForMembers(ctx context.Context, c lexutil.LexClient, members []string) (*ConvoGetConvoForMembers_Output, error) { 20 20 var out ConvoGetConvoForMembers_Output 21 21 22 22 params := map[string]interface{}{} 23 23 params["members"] = members 24 - if err := c.LexDo(ctx, util.Query, "", "chat.bsky.convo.getConvoForMembers", params, nil, &out); err != nil { 24 + if err := c.LexDo(ctx, lexutil.Query, "", "chat.bsky.convo.getConvoForMembers", params, nil, &out); err != nil { 25 25 return nil, err 26 26 } 27 27
+4 -5
api/chat/convogetLog.go
··· 9 9 "encoding/json" 10 10 "fmt" 11 11 12 - "github.com/bluesky-social/indigo/lex/util" 12 + lexutil "github.com/bluesky-social/indigo/lex/util" 13 13 ) 14 14 15 15 // ConvoGetLog_Output is the output of a chat.bsky.convo.getLog call. ··· 76 76 } 77 77 78 78 func (t *ConvoGetLog_Output_Logs_Elem) UnmarshalJSON(b []byte) error { 79 - typ, err := util.TypeExtract(b) 79 + typ, err := lexutil.TypeExtract(b) 80 80 if err != nil { 81 81 return err 82 82 } ··· 112 112 case "chat.bsky.convo.defs#logRemoveReaction": 113 113 t.ConvoDefs_LogRemoveReaction = new(ConvoDefs_LogRemoveReaction) 114 114 return json.Unmarshal(b, t.ConvoDefs_LogRemoveReaction) 115 - 116 115 default: 117 116 return nil 118 117 } 119 118 } 120 119 121 120 // ConvoGetLog calls the XRPC method "chat.bsky.convo.getLog". 122 - func ConvoGetLog(ctx context.Context, c util.LexClient, cursor string) (*ConvoGetLog_Output, error) { 121 + func ConvoGetLog(ctx context.Context, c lexutil.LexClient, cursor string) (*ConvoGetLog_Output, error) { 123 122 var out ConvoGetLog_Output 124 123 125 124 params := map[string]interface{}{} 126 125 if cursor != "" { 127 126 params["cursor"] = cursor 128 127 } 129 - if err := c.LexDo(ctx, util.Query, "", "chat.bsky.convo.getLog", params, nil, &out); err != nil { 128 + if err := c.LexDo(ctx, lexutil.Query, "", "chat.bsky.convo.getLog", params, nil, &out); err != nil { 130 129 return nil, err 131 130 } 132 131
+4 -5
api/chat/convogetMessages.go
··· 9 9 "encoding/json" 10 10 "fmt" 11 11 12 - "github.com/bluesky-social/indigo/lex/util" 12 + lexutil "github.com/bluesky-social/indigo/lex/util" 13 13 ) 14 14 15 15 // ConvoGetMessages_Output is the output of a chat.bsky.convo.getMessages call. ··· 36 36 } 37 37 38 38 func (t *ConvoGetMessages_Output_Messages_Elem) UnmarshalJSON(b []byte) error { 39 - typ, err := util.TypeExtract(b) 39 + typ, err := lexutil.TypeExtract(b) 40 40 if err != nil { 41 41 return err 42 42 } ··· 48 48 case "chat.bsky.convo.defs#deletedMessageView": 49 49 t.ConvoDefs_DeletedMessageView = new(ConvoDefs_DeletedMessageView) 50 50 return json.Unmarshal(b, t.ConvoDefs_DeletedMessageView) 51 - 52 51 default: 53 52 return nil 54 53 } 55 54 } 56 55 57 56 // ConvoGetMessages calls the XRPC method "chat.bsky.convo.getMessages". 58 - func ConvoGetMessages(ctx context.Context, c util.LexClient, convoId string, cursor string, limit int64) (*ConvoGetMessages_Output, error) { 57 + func ConvoGetMessages(ctx context.Context, c lexutil.LexClient, convoId string, cursor string, limit int64) (*ConvoGetMessages_Output, error) { 59 58 var out ConvoGetMessages_Output 60 59 61 60 params := map[string]interface{}{} ··· 66 65 if limit != 0 { 67 66 params["limit"] = limit 68 67 } 69 - if err := c.LexDo(ctx, util.Query, "", "chat.bsky.convo.getMessages", params, nil, &out); err != nil { 68 + if err := c.LexDo(ctx, lexutil.Query, "", "chat.bsky.convo.getMessages", params, nil, &out); err != nil { 70 69 return nil, err 71 70 } 72 71
+3 -3
api/chat/convoleaveConvo.go
··· 7 7 import ( 8 8 "context" 9 9 10 - "github.com/bluesky-social/indigo/lex/util" 10 + lexutil "github.com/bluesky-social/indigo/lex/util" 11 11 ) 12 12 13 13 // ConvoLeaveConvo_Input is the input argument to a chat.bsky.convo.leaveConvo call. ··· 22 22 } 23 23 24 24 // ConvoLeaveConvo calls the XRPC method "chat.bsky.convo.leaveConvo". 25 - func ConvoLeaveConvo(ctx context.Context, c util.LexClient, input *ConvoLeaveConvo_Input) (*ConvoLeaveConvo_Output, error) { 25 + func ConvoLeaveConvo(ctx context.Context, c lexutil.LexClient, input *ConvoLeaveConvo_Input) (*ConvoLeaveConvo_Output, error) { 26 26 var out ConvoLeaveConvo_Output 27 - if err := c.LexDo(ctx, util.Procedure, "application/json", "chat.bsky.convo.leaveConvo", nil, input, &out); err != nil { 27 + if err := c.LexDo(ctx, lexutil.Procedure, "application/json", "chat.bsky.convo.leaveConvo", nil, input, &out); err != nil { 28 28 return nil, err 29 29 } 30 30
+3 -3
api/chat/convolistConvos.go
··· 7 7 import ( 8 8 "context" 9 9 10 - "github.com/bluesky-social/indigo/lex/util" 10 + lexutil "github.com/bluesky-social/indigo/lex/util" 11 11 ) 12 12 13 13 // ConvoListConvos_Output is the output of a chat.bsky.convo.listConvos call. ··· 17 17 } 18 18 19 19 // ConvoListConvos calls the XRPC method "chat.bsky.convo.listConvos". 20 - func ConvoListConvos(ctx context.Context, c util.LexClient, cursor string, limit int64, readState string, status string) (*ConvoListConvos_Output, error) { 20 + func ConvoListConvos(ctx context.Context, c lexutil.LexClient, cursor string, limit int64, readState string, status string) (*ConvoListConvos_Output, error) { 21 21 var out ConvoListConvos_Output 22 22 23 23 params := map[string]interface{}{} ··· 33 33 if status != "" { 34 34 params["status"] = status 35 35 } 36 - if err := c.LexDo(ctx, util.Query, "", "chat.bsky.convo.listConvos", params, nil, &out); err != nil { 36 + if err := c.LexDo(ctx, lexutil.Query, "", "chat.bsky.convo.listConvos", params, nil, &out); err != nil { 37 37 return nil, err 38 38 } 39 39
+3 -3
api/chat/convomuteConvo.go
··· 7 7 import ( 8 8 "context" 9 9 10 - "github.com/bluesky-social/indigo/lex/util" 10 + lexutil "github.com/bluesky-social/indigo/lex/util" 11 11 ) 12 12 13 13 // ConvoMuteConvo_Input is the input argument to a chat.bsky.convo.muteConvo call. ··· 21 21 } 22 22 23 23 // ConvoMuteConvo calls the XRPC method "chat.bsky.convo.muteConvo". 24 - func ConvoMuteConvo(ctx context.Context, c util.LexClient, input *ConvoMuteConvo_Input) (*ConvoMuteConvo_Output, error) { 24 + func ConvoMuteConvo(ctx context.Context, c lexutil.LexClient, input *ConvoMuteConvo_Input) (*ConvoMuteConvo_Output, error) { 25 25 var out ConvoMuteConvo_Output 26 - if err := c.LexDo(ctx, util.Procedure, "application/json", "chat.bsky.convo.muteConvo", nil, input, &out); err != nil { 26 + if err := c.LexDo(ctx, lexutil.Procedure, "application/json", "chat.bsky.convo.muteConvo", nil, input, &out); err != nil { 27 27 return nil, err 28 28 } 29 29
+3 -3
api/chat/convoremoveReaction.go
··· 7 7 import ( 8 8 "context" 9 9 10 - "github.com/bluesky-social/indigo/lex/util" 10 + lexutil "github.com/bluesky-social/indigo/lex/util" 11 11 ) 12 12 13 13 // ConvoRemoveReaction_Input is the input argument to a chat.bsky.convo.removeReaction call. ··· 23 23 } 24 24 25 25 // ConvoRemoveReaction calls the XRPC method "chat.bsky.convo.removeReaction". 26 - func ConvoRemoveReaction(ctx context.Context, c util.LexClient, input *ConvoRemoveReaction_Input) (*ConvoRemoveReaction_Output, error) { 26 + func ConvoRemoveReaction(ctx context.Context, c lexutil.LexClient, input *ConvoRemoveReaction_Input) (*ConvoRemoveReaction_Output, error) { 27 27 var out ConvoRemoveReaction_Output 28 - if err := c.LexDo(ctx, util.Procedure, "application/json", "chat.bsky.convo.removeReaction", nil, input, &out); err != nil { 28 + if err := c.LexDo(ctx, lexutil.Procedure, "application/json", "chat.bsky.convo.removeReaction", nil, input, &out); err != nil { 29 29 return nil, err 30 30 } 31 31
+3 -3
api/chat/convosendMessage.go
··· 7 7 import ( 8 8 "context" 9 9 10 - "github.com/bluesky-social/indigo/lex/util" 10 + lexutil "github.com/bluesky-social/indigo/lex/util" 11 11 ) 12 12 13 13 // ConvoSendMessage_Input is the input argument to a chat.bsky.convo.sendMessage call. ··· 17 17 } 18 18 19 19 // ConvoSendMessage calls the XRPC method "chat.bsky.convo.sendMessage". 20 - func ConvoSendMessage(ctx context.Context, c util.LexClient, input *ConvoSendMessage_Input) (*ConvoDefs_MessageView, error) { 20 + func ConvoSendMessage(ctx context.Context, c lexutil.LexClient, input *ConvoSendMessage_Input) (*ConvoDefs_MessageView, error) { 21 21 var out ConvoDefs_MessageView 22 - if err := c.LexDo(ctx, util.Procedure, "application/json", "chat.bsky.convo.sendMessage", nil, input, &out); err != nil { 22 + if err := c.LexDo(ctx, lexutil.Procedure, "application/json", "chat.bsky.convo.sendMessage", nil, input, &out); err != nil { 23 23 return nil, err 24 24 } 25 25
+3 -3
api/chat/convosendMessageBatch.go
··· 7 7 import ( 8 8 "context" 9 9 10 - "github.com/bluesky-social/indigo/lex/util" 10 + lexutil "github.com/bluesky-social/indigo/lex/util" 11 11 ) 12 12 13 13 // ConvoSendMessageBatch_BatchItem is a "batchItem" in the chat.bsky.convo.sendMessageBatch schema. ··· 27 27 } 28 28 29 29 // ConvoSendMessageBatch calls the XRPC method "chat.bsky.convo.sendMessageBatch". 30 - func ConvoSendMessageBatch(ctx context.Context, c util.LexClient, input *ConvoSendMessageBatch_Input) (*ConvoSendMessageBatch_Output, error) { 30 + func ConvoSendMessageBatch(ctx context.Context, c lexutil.LexClient, input *ConvoSendMessageBatch_Input) (*ConvoSendMessageBatch_Output, error) { 31 31 var out ConvoSendMessageBatch_Output 32 - if err := c.LexDo(ctx, util.Procedure, "application/json", "chat.bsky.convo.sendMessageBatch", nil, input, &out); err != nil { 32 + if err := c.LexDo(ctx, lexutil.Procedure, "application/json", "chat.bsky.convo.sendMessageBatch", nil, input, &out); err != nil { 33 33 return nil, err 34 34 } 35 35
+3 -3
api/chat/convounmuteConvo.go
··· 7 7 import ( 8 8 "context" 9 9 10 - "github.com/bluesky-social/indigo/lex/util" 10 + lexutil "github.com/bluesky-social/indigo/lex/util" 11 11 ) 12 12 13 13 // ConvoUnmuteConvo_Input is the input argument to a chat.bsky.convo.unmuteConvo call. ··· 21 21 } 22 22 23 23 // ConvoUnmuteConvo calls the XRPC method "chat.bsky.convo.unmuteConvo". 24 - func ConvoUnmuteConvo(ctx context.Context, c util.LexClient, input *ConvoUnmuteConvo_Input) (*ConvoUnmuteConvo_Output, error) { 24 + func ConvoUnmuteConvo(ctx context.Context, c lexutil.LexClient, input *ConvoUnmuteConvo_Input) (*ConvoUnmuteConvo_Output, error) { 25 25 var out ConvoUnmuteConvo_Output 26 - if err := c.LexDo(ctx, util.Procedure, "application/json", "chat.bsky.convo.unmuteConvo", nil, input, &out); err != nil { 26 + if err := c.LexDo(ctx, lexutil.Procedure, "application/json", "chat.bsky.convo.unmuteConvo", nil, input, &out); err != nil { 27 27 return nil, err 28 28 } 29 29
+3 -3
api/chat/convoupdateAllRead.go
··· 7 7 import ( 8 8 "context" 9 9 10 - "github.com/bluesky-social/indigo/lex/util" 10 + lexutil "github.com/bluesky-social/indigo/lex/util" 11 11 ) 12 12 13 13 // ConvoUpdateAllRead_Input is the input argument to a chat.bsky.convo.updateAllRead call. ··· 22 22 } 23 23 24 24 // ConvoUpdateAllRead calls the XRPC method "chat.bsky.convo.updateAllRead". 25 - func ConvoUpdateAllRead(ctx context.Context, c util.LexClient, input *ConvoUpdateAllRead_Input) (*ConvoUpdateAllRead_Output, error) { 25 + func ConvoUpdateAllRead(ctx context.Context, c lexutil.LexClient, input *ConvoUpdateAllRead_Input) (*ConvoUpdateAllRead_Output, error) { 26 26 var out ConvoUpdateAllRead_Output 27 - if err := c.LexDo(ctx, util.Procedure, "application/json", "chat.bsky.convo.updateAllRead", nil, input, &out); err != nil { 27 + if err := c.LexDo(ctx, lexutil.Procedure, "application/json", "chat.bsky.convo.updateAllRead", nil, input, &out); err != nil { 28 28 return nil, err 29 29 } 30 30
+3 -3
api/chat/convoupdateRead.go
··· 7 7 import ( 8 8 "context" 9 9 10 - "github.com/bluesky-social/indigo/lex/util" 10 + lexutil "github.com/bluesky-social/indigo/lex/util" 11 11 ) 12 12 13 13 // ConvoUpdateRead_Input is the input argument to a chat.bsky.convo.updateRead call. ··· 22 22 } 23 23 24 24 // ConvoUpdateRead calls the XRPC method "chat.bsky.convo.updateRead". 25 - func ConvoUpdateRead(ctx context.Context, c util.LexClient, input *ConvoUpdateRead_Input) (*ConvoUpdateRead_Output, error) { 25 + func ConvoUpdateRead(ctx context.Context, c lexutil.LexClient, input *ConvoUpdateRead_Input) (*ConvoUpdateRead_Output, error) { 26 26 var out ConvoUpdateRead_Output 27 - if err := c.LexDo(ctx, util.Procedure, "application/json", "chat.bsky.convo.updateRead", nil, input, &out); err != nil { 27 + if err := c.LexDo(ctx, lexutil.Procedure, "application/json", "chat.bsky.convo.updateRead", nil, input, &out); err != nil { 28 28 return nil, err 29 29 } 30 30
+3 -3
api/chat/moderationgetActorMetadata.go
··· 7 7 import ( 8 8 "context" 9 9 10 - "github.com/bluesky-social/indigo/lex/util" 10 + lexutil "github.com/bluesky-social/indigo/lex/util" 11 11 ) 12 12 13 13 // ModerationGetActorMetadata_Metadata is a "metadata" in the chat.bsky.moderation.getActorMetadata schema. ··· 26 26 } 27 27 28 28 // ModerationGetActorMetadata calls the XRPC method "chat.bsky.moderation.getActorMetadata". 29 - func ModerationGetActorMetadata(ctx context.Context, c util.LexClient, actor string) (*ModerationGetActorMetadata_Output, error) { 29 + func ModerationGetActorMetadata(ctx context.Context, c lexutil.LexClient, actor string) (*ModerationGetActorMetadata_Output, error) { 30 30 var out ModerationGetActorMetadata_Output 31 31 32 32 params := map[string]interface{}{} 33 33 params["actor"] = actor 34 - if err := c.LexDo(ctx, util.Query, "", "chat.bsky.moderation.getActorMetadata", params, nil, &out); err != nil { 34 + if err := c.LexDo(ctx, lexutil.Query, "", "chat.bsky.moderation.getActorMetadata", params, nil, &out); err != nil { 35 35 return nil, err 36 36 } 37 37
+4 -5
api/chat/moderationgetMessageContext.go
··· 9 9 "encoding/json" 10 10 "fmt" 11 11 12 - "github.com/bluesky-social/indigo/lex/util" 12 + lexutil "github.com/bluesky-social/indigo/lex/util" 13 13 ) 14 14 15 15 // ModerationGetMessageContext_Output is the output of a chat.bsky.moderation.getMessageContext call. ··· 35 35 } 36 36 37 37 func (t *ModerationGetMessageContext_Output_Messages_Elem) UnmarshalJSON(b []byte) error { 38 - typ, err := util.TypeExtract(b) 38 + typ, err := lexutil.TypeExtract(b) 39 39 if err != nil { 40 40 return err 41 41 } ··· 47 47 case "chat.bsky.convo.defs#deletedMessageView": 48 48 t.ConvoDefs_DeletedMessageView = new(ConvoDefs_DeletedMessageView) 49 49 return json.Unmarshal(b, t.ConvoDefs_DeletedMessageView) 50 - 51 50 default: 52 51 return nil 53 52 } ··· 56 55 // ModerationGetMessageContext calls the XRPC method "chat.bsky.moderation.getMessageContext". 57 56 // 58 57 // convoId: Conversation that the message is from. NOTE: this field will eventually be required. 59 - func ModerationGetMessageContext(ctx context.Context, c util.LexClient, after int64, before int64, convoId string, messageId string) (*ModerationGetMessageContext_Output, error) { 58 + func ModerationGetMessageContext(ctx context.Context, c lexutil.LexClient, after int64, before int64, convoId string, messageId string) (*ModerationGetMessageContext_Output, error) { 60 59 var out ModerationGetMessageContext_Output 61 60 62 61 params := map[string]interface{}{} ··· 70 69 params["convoId"] = convoId 71 70 } 72 71 params["messageId"] = messageId 73 - if err := c.LexDo(ctx, util.Query, "", "chat.bsky.moderation.getMessageContext", params, nil, &out); err != nil { 72 + if err := c.LexDo(ctx, lexutil.Query, "", "chat.bsky.moderation.getMessageContext", params, nil, &out); err != nil { 74 73 return nil, err 75 74 } 76 75
+3 -3
api/chat/moderationupdateActorAccess.go
··· 7 7 import ( 8 8 "context" 9 9 10 - "github.com/bluesky-social/indigo/lex/util" 10 + lexutil "github.com/bluesky-social/indigo/lex/util" 11 11 ) 12 12 13 13 // ModerationUpdateActorAccess_Input is the input argument to a chat.bsky.moderation.updateActorAccess call. ··· 18 18 } 19 19 20 20 // ModerationUpdateActorAccess calls the XRPC method "chat.bsky.moderation.updateActorAccess". 21 - func ModerationUpdateActorAccess(ctx context.Context, c util.LexClient, input *ModerationUpdateActorAccess_Input) error { 22 - if err := c.LexDo(ctx, util.Procedure, "application/json", "chat.bsky.moderation.updateActorAccess", nil, input, nil); err != nil { 21 + func ModerationUpdateActorAccess(ctx context.Context, c lexutil.LexClient, input *ModerationUpdateActorAccess_Input) error { 22 + if err := c.LexDo(ctx, lexutil.Procedure, "application/json", "chat.bsky.moderation.updateActorAccess", nil, input, nil); err != nil { 23 23 return err 24 24 } 25 25
+3 -3
api/ozone/communicationcreateTemplate.go
··· 7 7 import ( 8 8 "context" 9 9 10 - "github.com/bluesky-social/indigo/lex/util" 10 + lexutil "github.com/bluesky-social/indigo/lex/util" 11 11 ) 12 12 13 13 // CommunicationCreateTemplate_Input is the input argument to a tools.ozone.communication.createTemplate call. ··· 25 25 } 26 26 27 27 // CommunicationCreateTemplate calls the XRPC method "tools.ozone.communication.createTemplate". 28 - func CommunicationCreateTemplate(ctx context.Context, c util.LexClient, input *CommunicationCreateTemplate_Input) (*CommunicationDefs_TemplateView, error) { 28 + func CommunicationCreateTemplate(ctx context.Context, c lexutil.LexClient, input *CommunicationCreateTemplate_Input) (*CommunicationDefs_TemplateView, error) { 29 29 var out CommunicationDefs_TemplateView 30 - if err := c.LexDo(ctx, util.Procedure, "application/json", "tools.ozone.communication.createTemplate", nil, input, &out); err != nil { 30 + if err := c.LexDo(ctx, lexutil.Procedure, "application/json", "tools.ozone.communication.createTemplate", nil, input, &out); err != nil { 31 31 return nil, err 32 32 } 33 33
+3 -3
api/ozone/communicationdeleteTemplate.go
··· 7 7 import ( 8 8 "context" 9 9 10 - "github.com/bluesky-social/indigo/lex/util" 10 + lexutil "github.com/bluesky-social/indigo/lex/util" 11 11 ) 12 12 13 13 // CommunicationDeleteTemplate_Input is the input argument to a tools.ozone.communication.deleteTemplate call. ··· 16 16 } 17 17 18 18 // CommunicationDeleteTemplate calls the XRPC method "tools.ozone.communication.deleteTemplate". 19 - func CommunicationDeleteTemplate(ctx context.Context, c util.LexClient, input *CommunicationDeleteTemplate_Input) error { 20 - if err := c.LexDo(ctx, util.Procedure, "application/json", "tools.ozone.communication.deleteTemplate", nil, input, nil); err != nil { 19 + func CommunicationDeleteTemplate(ctx context.Context, c lexutil.LexClient, input *CommunicationDeleteTemplate_Input) error { 20 + if err := c.LexDo(ctx, lexutil.Procedure, "application/json", "tools.ozone.communication.deleteTemplate", nil, input, nil); err != nil { 21 21 return err 22 22 } 23 23
+3 -3
api/ozone/communicationlistTemplates.go
··· 7 7 import ( 8 8 "context" 9 9 10 - "github.com/bluesky-social/indigo/lex/util" 10 + lexutil "github.com/bluesky-social/indigo/lex/util" 11 11 ) 12 12 13 13 // CommunicationListTemplates_Output is the output of a tools.ozone.communication.listTemplates call. ··· 16 16 } 17 17 18 18 // CommunicationListTemplates calls the XRPC method "tools.ozone.communication.listTemplates". 19 - func CommunicationListTemplates(ctx context.Context, c util.LexClient) (*CommunicationListTemplates_Output, error) { 19 + func CommunicationListTemplates(ctx context.Context, c lexutil.LexClient) (*CommunicationListTemplates_Output, error) { 20 20 var out CommunicationListTemplates_Output 21 - if err := c.LexDo(ctx, util.Query, "", "tools.ozone.communication.listTemplates", nil, nil, &out); err != nil { 21 + if err := c.LexDo(ctx, lexutil.Query, "", "tools.ozone.communication.listTemplates", nil, nil, &out); err != nil { 22 22 return nil, err 23 23 } 24 24
+3 -3
api/ozone/communicationupdateTemplate.go
··· 7 7 import ( 8 8 "context" 9 9 10 - "github.com/bluesky-social/indigo/lex/util" 10 + lexutil "github.com/bluesky-social/indigo/lex/util" 11 11 ) 12 12 13 13 // CommunicationUpdateTemplate_Input is the input argument to a tools.ozone.communication.updateTemplate call. ··· 28 28 } 29 29 30 30 // CommunicationUpdateTemplate calls the XRPC method "tools.ozone.communication.updateTemplate". 31 - func CommunicationUpdateTemplate(ctx context.Context, c util.LexClient, input *CommunicationUpdateTemplate_Input) (*CommunicationDefs_TemplateView, error) { 31 + func CommunicationUpdateTemplate(ctx context.Context, c lexutil.LexClient, input *CommunicationUpdateTemplate_Input) (*CommunicationDefs_TemplateView, error) { 32 32 var out CommunicationDefs_TemplateView 33 - if err := c.LexDo(ctx, util.Procedure, "application/json", "tools.ozone.communication.updateTemplate", nil, input, &out); err != nil { 33 + if err := c.LexDo(ctx, lexutil.Procedure, "application/json", "tools.ozone.communication.updateTemplate", nil, input, &out); err != nil { 34 34 return nil, err 35 35 } 36 36
+4 -5
api/ozone/hostinggetAccountHistory.go
··· 9 9 "encoding/json" 10 10 "fmt" 11 11 12 - "github.com/bluesky-social/indigo/lex/util" 12 + lexutil "github.com/bluesky-social/indigo/lex/util" 13 13 ) 14 14 15 15 // HostingGetAccountHistory_AccountCreated is a "accountCreated" in the tools.ozone.hosting.getAccountHistory schema. ··· 71 71 } 72 72 73 73 func (t *HostingGetAccountHistory_Event_Details) UnmarshalJSON(b []byte) error { 74 - typ, err := util.TypeExtract(b) 74 + typ, err := lexutil.TypeExtract(b) 75 75 if err != nil { 76 76 return err 77 77 } ··· 92 92 case "tools.ozone.hosting.getAccountHistory#handleUpdated": 93 93 t.HostingGetAccountHistory_HandleUpdated = new(HostingGetAccountHistory_HandleUpdated) 94 94 return json.Unmarshal(b, t.HostingGetAccountHistory_HandleUpdated) 95 - 96 95 default: 97 96 return nil 98 97 } ··· 116 115 } 117 116 118 117 // HostingGetAccountHistory calls the XRPC method "tools.ozone.hosting.getAccountHistory". 119 - func HostingGetAccountHistory(ctx context.Context, c util.LexClient, cursor string, did string, events []string, limit int64) (*HostingGetAccountHistory_Output, error) { 118 + func HostingGetAccountHistory(ctx context.Context, c lexutil.LexClient, cursor string, did string, events []string, limit int64) (*HostingGetAccountHistory_Output, error) { 120 119 var out HostingGetAccountHistory_Output 121 120 122 121 params := map[string]interface{}{} ··· 130 129 if limit != 0 { 131 130 params["limit"] = limit 132 131 } 133 - if err := c.LexDo(ctx, util.Query, "", "tools.ozone.hosting.getAccountHistory", params, nil, &out); err != nil { 132 + if err := c.LexDo(ctx, lexutil.Query, "", "tools.ozone.hosting.getAccountHistory", params, nil, &out); err != nil { 134 133 return nil, err 135 134 } 136 135
+3 -3
api/ozone/moderationcancelScheduledActions.go
··· 7 7 import ( 8 8 "context" 9 9 10 - "github.com/bluesky-social/indigo/lex/util" 10 + lexutil "github.com/bluesky-social/indigo/lex/util" 11 11 ) 12 12 13 13 // ModerationCancelScheduledActions_CancellationResults is a "cancellationResults" in the tools.ozone.moderation.cancelScheduledActions schema. ··· 34 34 } 35 35 36 36 // ModerationCancelScheduledActions calls the XRPC method "tools.ozone.moderation.cancelScheduledActions". 37 - func ModerationCancelScheduledActions(ctx context.Context, c util.LexClient, input *ModerationCancelScheduledActions_Input) (*ModerationCancelScheduledActions_CancellationResults, error) { 37 + func ModerationCancelScheduledActions(ctx context.Context, c lexutil.LexClient, input *ModerationCancelScheduledActions_Input) (*ModerationCancelScheduledActions_CancellationResults, error) { 38 38 var out ModerationCancelScheduledActions_CancellationResults 39 - if err := c.LexDo(ctx, util.Procedure, "application/json", "tools.ozone.moderation.cancelScheduledActions", nil, input, &out); err != nil { 39 + if err := c.LexDo(ctx, lexutil.Procedure, "application/json", "tools.ozone.moderation.cancelScheduledActions", nil, input, &out); err != nil { 40 40 return nil, err 41 41 } 42 42
+68 -75
api/ozone/moderationdefs.go
··· 8 8 "encoding/json" 9 9 "fmt" 10 10 11 - comatprototypes "github.com/bluesky-social/indigo/api/atproto" 12 - chatbskytypes "github.com/bluesky-social/indigo/api/chat" 13 - "github.com/bluesky-social/indigo/lex/util" 11 + comatproto "github.com/bluesky-social/indigo/api/atproto" 12 + chatbsky "github.com/bluesky-social/indigo/api/chat" 13 + lexutil "github.com/bluesky-social/indigo/lex/util" 14 14 ) 15 15 16 16 // ModerationDefs_AccountEvent is a "accountEvent" in the tools.ozone.moderation.defs schema. ··· 112 112 } 113 113 114 114 func (t *ModerationDefs_BlobView_Details) UnmarshalJSON(b []byte) error { 115 - typ, err := util.TypeExtract(b) 115 + typ, err := lexutil.TypeExtract(b) 116 116 if err != nil { 117 117 return err 118 118 } ··· 124 124 case "tools.ozone.moderation.defs#videoDetails": 125 125 t.ModerationDefs_VideoDetails = new(ModerationDefs_VideoDetails) 126 126 return json.Unmarshal(b, t.ModerationDefs_VideoDetails) 127 - 128 127 default: 129 128 return nil 130 129 } ··· 469 468 } 470 469 471 470 func (t *ModerationDefs_ModEventViewDetail_Event) UnmarshalJSON(b []byte) error { 472 - typ, err := util.TypeExtract(b) 471 + typ, err := lexutil.TypeExtract(b) 473 472 if err != nil { 474 473 return err 475 474 } ··· 547 546 case "tools.ozone.moderation.defs#cancelScheduledTakedownEvent": 548 547 t.ModerationDefs_CancelScheduledTakedownEvent = new(ModerationDefs_CancelScheduledTakedownEvent) 549 548 return json.Unmarshal(b, t.ModerationDefs_CancelScheduledTakedownEvent) 550 - 551 549 default: 552 550 return nil 553 551 } ··· 581 579 } 582 580 583 581 func (t *ModerationDefs_ModEventViewDetail_Subject) UnmarshalJSON(b []byte) error { 584 - typ, err := util.TypeExtract(b) 582 + typ, err := lexutil.TypeExtract(b) 585 583 if err != nil { 586 584 return err 587 585 } ··· 599 597 case "tools.ozone.moderation.defs#recordViewNotFound": 600 598 t.ModerationDefs_RecordViewNotFound = new(ModerationDefs_RecordViewNotFound) 601 599 return json.Unmarshal(b, t.ModerationDefs_RecordViewNotFound) 602 - 603 600 default: 604 601 return nil 605 602 } ··· 733 730 } 734 731 735 732 func (t *ModerationDefs_ModEventView_Event) UnmarshalJSON(b []byte) error { 736 - typ, err := util.TypeExtract(b) 733 + typ, err := lexutil.TypeExtract(b) 737 734 if err != nil { 738 735 return err 739 736 } ··· 811 808 case "tools.ozone.moderation.defs#cancelScheduledTakedownEvent": 812 809 t.ModerationDefs_CancelScheduledTakedownEvent = new(ModerationDefs_CancelScheduledTakedownEvent) 813 810 return json.Unmarshal(b, t.ModerationDefs_CancelScheduledTakedownEvent) 814 - 815 811 default: 816 812 return nil 817 813 } 818 814 } 819 815 820 816 type ModerationDefs_ModEventView_Subject struct { 821 - AdminDefs_RepoRef *comatprototypes.AdminDefs_RepoRef 822 - RepoStrongRef *comatprototypes.RepoStrongRef 823 - ConvoDefs_MessageRef *chatbskytypes.ConvoDefs_MessageRef 817 + AdminDefs_RepoRef *comatproto.AdminDefs_RepoRef 818 + RepoStrongRef *comatproto.RepoStrongRef 819 + ConvoDefs_MessageRef *chatbsky.ConvoDefs_MessageRef 824 820 } 825 821 826 822 func (t *ModerationDefs_ModEventView_Subject) MarshalJSON() ([]byte, error) { ··· 840 836 } 841 837 842 838 func (t *ModerationDefs_ModEventView_Subject) UnmarshalJSON(b []byte) error { 843 - typ, err := util.TypeExtract(b) 839 + typ, err := lexutil.TypeExtract(b) 844 840 if err != nil { 845 841 return err 846 842 } 847 843 848 844 switch typ { 849 845 case "com.atproto.admin.defs#repoRef": 850 - t.AdminDefs_RepoRef = new(comatprototypes.AdminDefs_RepoRef) 846 + t.AdminDefs_RepoRef = new(comatproto.AdminDefs_RepoRef) 851 847 return json.Unmarshal(b, t.AdminDefs_RepoRef) 852 848 case "com.atproto.repo.strongRef": 853 - t.RepoStrongRef = new(comatprototypes.RepoStrongRef) 849 + t.RepoStrongRef = new(comatproto.RepoStrongRef) 854 850 return json.Unmarshal(b, t.RepoStrongRef) 855 851 case "chat.bsky.convo.defs#messageRef": 856 - t.ConvoDefs_MessageRef = new(chatbskytypes.ConvoDefs_MessageRef) 852 + t.ConvoDefs_MessageRef = new(chatbsky.ConvoDefs_MessageRef) 857 853 return json.Unmarshal(b, t.ConvoDefs_MessageRef) 858 - 859 854 default: 860 855 return nil 861 856 } ··· 903 898 904 899 // ModerationDefs_RecordView is a "recordView" in the tools.ozone.moderation.defs schema. 905 900 type ModerationDefs_RecordView struct { 906 - LexiconTypeID string `json:"$type" cborgen:"$type,const=tools.ozone.moderation.defs#recordView"` 907 - BlobCids []string `json:"blobCids" cborgen:"blobCids"` 908 - Cid string `json:"cid" cborgen:"cid"` 909 - IndexedAt string `json:"indexedAt" cborgen:"indexedAt"` 910 - Moderation *ModerationDefs_Moderation `json:"moderation" cborgen:"moderation"` 911 - Repo *ModerationDefs_RepoView `json:"repo" cborgen:"repo"` 912 - Uri string `json:"uri" cborgen:"uri"` 913 - Value *util.LexiconTypeDecoder `json:"value" cborgen:"value"` 901 + LexiconTypeID string `json:"$type" cborgen:"$type,const=tools.ozone.moderation.defs#recordView"` 902 + BlobCids []string `json:"blobCids" cborgen:"blobCids"` 903 + Cid string `json:"cid" cborgen:"cid"` 904 + IndexedAt string `json:"indexedAt" cborgen:"indexedAt"` 905 + Moderation *ModerationDefs_Moderation `json:"moderation" cborgen:"moderation"` 906 + Repo *ModerationDefs_RepoView `json:"repo" cborgen:"repo"` 907 + Uri string `json:"uri" cborgen:"uri"` 908 + Value *lexutil.LexiconTypeDecoder `json:"value" cborgen:"value"` 914 909 } 915 910 916 911 // ModerationDefs_RecordViewDetail is a "recordViewDetail" in the tools.ozone.moderation.defs schema. 917 912 type ModerationDefs_RecordViewDetail struct { 918 - LexiconTypeID string `json:"$type" cborgen:"$type,const=tools.ozone.moderation.defs#recordViewDetail"` 919 - Blobs []*ModerationDefs_BlobView `json:"blobs" cborgen:"blobs"` 920 - Cid string `json:"cid" cborgen:"cid"` 921 - IndexedAt string `json:"indexedAt" cborgen:"indexedAt"` 922 - Labels []*comatprototypes.LabelDefs_Label `json:"labels,omitempty" cborgen:"labels,omitempty"` 923 - Moderation *ModerationDefs_ModerationDetail `json:"moderation" cborgen:"moderation"` 924 - Repo *ModerationDefs_RepoView `json:"repo" cborgen:"repo"` 925 - Uri string `json:"uri" cborgen:"uri"` 926 - Value *util.LexiconTypeDecoder `json:"value" cborgen:"value"` 913 + LexiconTypeID string `json:"$type" cborgen:"$type,const=tools.ozone.moderation.defs#recordViewDetail"` 914 + Blobs []*ModerationDefs_BlobView `json:"blobs" cborgen:"blobs"` 915 + Cid string `json:"cid" cborgen:"cid"` 916 + IndexedAt string `json:"indexedAt" cborgen:"indexedAt"` 917 + Labels []*comatproto.LabelDefs_Label `json:"labels,omitempty" cborgen:"labels,omitempty"` 918 + Moderation *ModerationDefs_ModerationDetail `json:"moderation" cborgen:"moderation"` 919 + Repo *ModerationDefs_RepoView `json:"repo" cborgen:"repo"` 920 + Uri string `json:"uri" cborgen:"uri"` 921 + Value *lexutil.LexiconTypeDecoder `json:"value" cborgen:"value"` 927 922 } 928 923 929 924 // ModerationDefs_RecordViewNotFound is a "recordViewNotFound" in the tools.ozone.moderation.defs schema. ··· 956 951 957 952 // ModerationDefs_RepoView is a "repoView" in the tools.ozone.moderation.defs schema. 958 953 type ModerationDefs_RepoView struct { 959 - LexiconTypeID string `json:"$type" cborgen:"$type,const=tools.ozone.moderation.defs#repoView"` 960 - DeactivatedAt *string `json:"deactivatedAt,omitempty" cborgen:"deactivatedAt,omitempty"` 961 - Did string `json:"did" cborgen:"did"` 962 - Email *string `json:"email,omitempty" cborgen:"email,omitempty"` 963 - Handle string `json:"handle" cborgen:"handle"` 964 - IndexedAt string `json:"indexedAt" cborgen:"indexedAt"` 965 - InviteNote *string `json:"inviteNote,omitempty" cborgen:"inviteNote,omitempty"` 966 - InvitedBy *comatprototypes.ServerDefs_InviteCode `json:"invitedBy,omitempty" cborgen:"invitedBy,omitempty"` 967 - InvitesDisabled *bool `json:"invitesDisabled,omitempty" cborgen:"invitesDisabled,omitempty"` 968 - Moderation *ModerationDefs_Moderation `json:"moderation" cborgen:"moderation"` 969 - RelatedRecords []*util.LexiconTypeDecoder `json:"relatedRecords" cborgen:"relatedRecords"` 970 - ThreatSignatures []*comatprototypes.AdminDefs_ThreatSignature `json:"threatSignatures,omitempty" cborgen:"threatSignatures,omitempty"` 954 + LexiconTypeID string `json:"$type" cborgen:"$type,const=tools.ozone.moderation.defs#repoView"` 955 + DeactivatedAt *string `json:"deactivatedAt,omitempty" cborgen:"deactivatedAt,omitempty"` 956 + Did string `json:"did" cborgen:"did"` 957 + Email *string `json:"email,omitempty" cborgen:"email,omitempty"` 958 + Handle string `json:"handle" cborgen:"handle"` 959 + IndexedAt string `json:"indexedAt" cborgen:"indexedAt"` 960 + InviteNote *string `json:"inviteNote,omitempty" cborgen:"inviteNote,omitempty"` 961 + InvitedBy *comatproto.ServerDefs_InviteCode `json:"invitedBy,omitempty" cborgen:"invitedBy,omitempty"` 962 + InvitesDisabled *bool `json:"invitesDisabled,omitempty" cborgen:"invitesDisabled,omitempty"` 963 + Moderation *ModerationDefs_Moderation `json:"moderation" cborgen:"moderation"` 964 + RelatedRecords []*lexutil.LexiconTypeDecoder `json:"relatedRecords" cborgen:"relatedRecords"` 965 + ThreatSignatures []*comatproto.AdminDefs_ThreatSignature `json:"threatSignatures,omitempty" cborgen:"threatSignatures,omitempty"` 971 966 } 972 967 973 968 // ModerationDefs_RepoViewDetail is a "repoViewDetail" in the tools.ozone.moderation.defs schema. 974 969 type ModerationDefs_RepoViewDetail struct { 975 - LexiconTypeID string `json:"$type" cborgen:"$type,const=tools.ozone.moderation.defs#repoViewDetail"` 976 - DeactivatedAt *string `json:"deactivatedAt,omitempty" cborgen:"deactivatedAt,omitempty"` 977 - Did string `json:"did" cborgen:"did"` 978 - Email *string `json:"email,omitempty" cborgen:"email,omitempty"` 979 - EmailConfirmedAt *string `json:"emailConfirmedAt,omitempty" cborgen:"emailConfirmedAt,omitempty"` 980 - Handle string `json:"handle" cborgen:"handle"` 981 - IndexedAt string `json:"indexedAt" cborgen:"indexedAt"` 982 - InviteNote *string `json:"inviteNote,omitempty" cborgen:"inviteNote,omitempty"` 983 - InvitedBy *comatprototypes.ServerDefs_InviteCode `json:"invitedBy,omitempty" cborgen:"invitedBy,omitempty"` 984 - Invites []*comatprototypes.ServerDefs_InviteCode `json:"invites,omitempty" cborgen:"invites,omitempty"` 985 - InvitesDisabled *bool `json:"invitesDisabled,omitempty" cborgen:"invitesDisabled,omitempty"` 986 - Labels []*comatprototypes.LabelDefs_Label `json:"labels,omitempty" cborgen:"labels,omitempty"` 987 - Moderation *ModerationDefs_ModerationDetail `json:"moderation" cborgen:"moderation"` 988 - RelatedRecords []*util.LexiconTypeDecoder `json:"relatedRecords" cborgen:"relatedRecords"` 989 - ThreatSignatures []*comatprototypes.AdminDefs_ThreatSignature `json:"threatSignatures,omitempty" cborgen:"threatSignatures,omitempty"` 970 + LexiconTypeID string `json:"$type" cborgen:"$type,const=tools.ozone.moderation.defs#repoViewDetail"` 971 + DeactivatedAt *string `json:"deactivatedAt,omitempty" cborgen:"deactivatedAt,omitempty"` 972 + Did string `json:"did" cborgen:"did"` 973 + Email *string `json:"email,omitempty" cborgen:"email,omitempty"` 974 + EmailConfirmedAt *string `json:"emailConfirmedAt,omitempty" cborgen:"emailConfirmedAt,omitempty"` 975 + Handle string `json:"handle" cborgen:"handle"` 976 + IndexedAt string `json:"indexedAt" cborgen:"indexedAt"` 977 + InviteNote *string `json:"inviteNote,omitempty" cborgen:"inviteNote,omitempty"` 978 + InvitedBy *comatproto.ServerDefs_InviteCode `json:"invitedBy,omitempty" cborgen:"invitedBy,omitempty"` 979 + Invites []*comatproto.ServerDefs_InviteCode `json:"invites,omitempty" cborgen:"invites,omitempty"` 980 + InvitesDisabled *bool `json:"invitesDisabled,omitempty" cborgen:"invitesDisabled,omitempty"` 981 + Labels []*comatproto.LabelDefs_Label `json:"labels,omitempty" cborgen:"labels,omitempty"` 982 + Moderation *ModerationDefs_ModerationDetail `json:"moderation" cborgen:"moderation"` 983 + RelatedRecords []*lexutil.LexiconTypeDecoder `json:"relatedRecords" cborgen:"relatedRecords"` 984 + ThreatSignatures []*comatproto.AdminDefs_ThreatSignature `json:"threatSignatures,omitempty" cborgen:"threatSignatures,omitempty"` 990 985 } 991 986 992 987 // ModerationDefs_RepoViewNotFound is a "repoViewNotFound" in the tools.ozone.moderation.defs schema. ··· 1049 1044 // did: Subject DID for the action 1050 1045 Did string `json:"did" cborgen:"did"` 1051 1046 // eventData: Serialized event object that will be propagated to the event when performed 1052 - EventData *util.LexiconTypeDecoder `json:"eventData,omitempty" cborgen:"eventData,omitempty"` 1047 + EventData *lexutil.LexiconTypeDecoder `json:"eventData,omitempty" cborgen:"eventData,omitempty"` 1053 1048 // executeAfter: Earliest time to execute the action (for randomized scheduling) 1054 1049 ExecuteAfter *string `json:"executeAfter,omitempty" cborgen:"executeAfter,omitempty"` 1055 1050 // executeAt: Exact time to execute the action ··· 1128 1123 } 1129 1124 1130 1125 func (t *ModerationDefs_SubjectStatusView_Hosting) UnmarshalJSON(b []byte) error { 1131 - typ, err := util.TypeExtract(b) 1126 + typ, err := lexutil.TypeExtract(b) 1132 1127 if err != nil { 1133 1128 return err 1134 1129 } ··· 1140 1135 case "tools.ozone.moderation.defs#recordHosting": 1141 1136 t.ModerationDefs_RecordHosting = new(ModerationDefs_RecordHosting) 1142 1137 return json.Unmarshal(b, t.ModerationDefs_RecordHosting) 1143 - 1144 1138 default: 1145 1139 return nil 1146 1140 } 1147 1141 } 1148 1142 1149 1143 type ModerationDefs_SubjectStatusView_Subject struct { 1150 - AdminDefs_RepoRef *comatprototypes.AdminDefs_RepoRef 1151 - RepoStrongRef *comatprototypes.RepoStrongRef 1152 - ConvoDefs_MessageRef *chatbskytypes.ConvoDefs_MessageRef 1144 + AdminDefs_RepoRef *comatproto.AdminDefs_RepoRef 1145 + RepoStrongRef *comatproto.RepoStrongRef 1146 + ConvoDefs_MessageRef *chatbsky.ConvoDefs_MessageRef 1153 1147 } 1154 1148 1155 1149 func (t *ModerationDefs_SubjectStatusView_Subject) MarshalJSON() ([]byte, error) { ··· 1169 1163 } 1170 1164 1171 1165 func (t *ModerationDefs_SubjectStatusView_Subject) UnmarshalJSON(b []byte) error { 1172 - typ, err := util.TypeExtract(b) 1166 + typ, err := lexutil.TypeExtract(b) 1173 1167 if err != nil { 1174 1168 return err 1175 1169 } 1176 1170 1177 1171 switch typ { 1178 1172 case "com.atproto.admin.defs#repoRef": 1179 - t.AdminDefs_RepoRef = new(comatprototypes.AdminDefs_RepoRef) 1173 + t.AdminDefs_RepoRef = new(comatproto.AdminDefs_RepoRef) 1180 1174 return json.Unmarshal(b, t.AdminDefs_RepoRef) 1181 1175 case "com.atproto.repo.strongRef": 1182 - t.RepoStrongRef = new(comatprototypes.RepoStrongRef) 1176 + t.RepoStrongRef = new(comatproto.RepoStrongRef) 1183 1177 return json.Unmarshal(b, t.RepoStrongRef) 1184 1178 case "chat.bsky.convo.defs#messageRef": 1185 - t.ConvoDefs_MessageRef = new(chatbskytypes.ConvoDefs_MessageRef) 1179 + t.ConvoDefs_MessageRef = new(chatbsky.ConvoDefs_MessageRef) 1186 1180 return json.Unmarshal(b, t.ConvoDefs_MessageRef) 1187 - 1188 1181 default: 1189 1182 return nil 1190 1183 } ··· 1194 1187 // 1195 1188 // Detailed view of a subject. For record subjects, the author's repo and profile will be returned. 1196 1189 type ModerationDefs_SubjectView struct { 1197 - Profile *util.LexiconTypeDecoder `json:"profile,omitempty" cborgen:"profile,omitempty"` 1190 + Profile *lexutil.LexiconTypeDecoder `json:"profile,omitempty" cborgen:"profile,omitempty"` 1198 1191 Record *ModerationDefs_RecordViewDetail `json:"record,omitempty" cborgen:"record,omitempty"` 1199 1192 Repo *ModerationDefs_RepoViewDetail `json:"repo,omitempty" cborgen:"repo,omitempty"` 1200 1193 Status *ModerationDefs_SubjectStatusView `json:"status,omitempty" cborgen:"status,omitempty"`
+10 -12
api/ozone/moderationemitEvent.go
··· 9 9 "encoding/json" 10 10 "fmt" 11 11 12 - comatprototypes "github.com/bluesky-social/indigo/api/atproto" 13 - "github.com/bluesky-social/indigo/lex/util" 12 + comatproto "github.com/bluesky-social/indigo/api/atproto" 13 + lexutil "github.com/bluesky-social/indigo/lex/util" 14 14 ) 15 15 16 16 // ModerationEmitEvent_Input is the input argument to a tools.ozone.moderation.emitEvent call. ··· 152 152 } 153 153 154 154 func (t *ModerationEmitEvent_Input_Event) UnmarshalJSON(b []byte) error { 155 - typ, err := util.TypeExtract(b) 155 + typ, err := lexutil.TypeExtract(b) 156 156 if err != nil { 157 157 return err 158 158 } ··· 230 230 case "tools.ozone.moderation.defs#cancelScheduledTakedownEvent": 231 231 t.ModerationDefs_CancelScheduledTakedownEvent = new(ModerationDefs_CancelScheduledTakedownEvent) 232 232 return json.Unmarshal(b, t.ModerationDefs_CancelScheduledTakedownEvent) 233 - 234 233 default: 235 234 return nil 236 235 } 237 236 } 238 237 239 238 type ModerationEmitEvent_Input_Subject struct { 240 - AdminDefs_RepoRef *comatprototypes.AdminDefs_RepoRef 241 - RepoStrongRef *comatprototypes.RepoStrongRef 239 + AdminDefs_RepoRef *comatproto.AdminDefs_RepoRef 240 + RepoStrongRef *comatproto.RepoStrongRef 242 241 } 243 242 244 243 func (t *ModerationEmitEvent_Input_Subject) MarshalJSON() ([]byte, error) { ··· 254 253 } 255 254 256 255 func (t *ModerationEmitEvent_Input_Subject) UnmarshalJSON(b []byte) error { 257 - typ, err := util.TypeExtract(b) 256 + typ, err := lexutil.TypeExtract(b) 258 257 if err != nil { 259 258 return err 260 259 } 261 260 262 261 switch typ { 263 262 case "com.atproto.admin.defs#repoRef": 264 - t.AdminDefs_RepoRef = new(comatprototypes.AdminDefs_RepoRef) 263 + t.AdminDefs_RepoRef = new(comatproto.AdminDefs_RepoRef) 265 264 return json.Unmarshal(b, t.AdminDefs_RepoRef) 266 265 case "com.atproto.repo.strongRef": 267 - t.RepoStrongRef = new(comatprototypes.RepoStrongRef) 266 + t.RepoStrongRef = new(comatproto.RepoStrongRef) 268 267 return json.Unmarshal(b, t.RepoStrongRef) 269 - 270 268 default: 271 269 return nil 272 270 } 273 271 } 274 272 275 273 // ModerationEmitEvent calls the XRPC method "tools.ozone.moderation.emitEvent". 276 - func ModerationEmitEvent(ctx context.Context, c util.LexClient, input *ModerationEmitEvent_Input) (*ModerationDefs_ModEventView, error) { 274 + func ModerationEmitEvent(ctx context.Context, c lexutil.LexClient, input *ModerationEmitEvent_Input) (*ModerationDefs_ModEventView, error) { 277 275 var out ModerationDefs_ModEventView 278 - if err := c.LexDo(ctx, util.Procedure, "application/json", "tools.ozone.moderation.emitEvent", nil, input, &out); err != nil { 276 + if err := c.LexDo(ctx, lexutil.Procedure, "application/json", "tools.ozone.moderation.emitEvent", nil, input, &out); err != nil { 279 277 return nil, err 280 278 } 281 279
+3 -3
api/ozone/moderationgetAccountTimeline.go
··· 7 7 import ( 8 8 "context" 9 9 10 - "github.com/bluesky-social/indigo/lex/util" 10 + lexutil "github.com/bluesky-social/indigo/lex/util" 11 11 ) 12 12 13 13 // ModerationGetAccountTimeline_Output is the output of a tools.ozone.moderation.getAccountTimeline call. ··· 29 29 } 30 30 31 31 // ModerationGetAccountTimeline calls the XRPC method "tools.ozone.moderation.getAccountTimeline". 32 - func ModerationGetAccountTimeline(ctx context.Context, c util.LexClient, did string) (*ModerationGetAccountTimeline_Output, error) { 32 + func ModerationGetAccountTimeline(ctx context.Context, c lexutil.LexClient, did string) (*ModerationGetAccountTimeline_Output, error) { 33 33 var out ModerationGetAccountTimeline_Output 34 34 35 35 params := map[string]interface{}{} 36 36 params["did"] = did 37 - if err := c.LexDo(ctx, util.Query, "", "tools.ozone.moderation.getAccountTimeline", params, nil, &out); err != nil { 37 + if err := c.LexDo(ctx, lexutil.Query, "", "tools.ozone.moderation.getAccountTimeline", params, nil, &out); err != nil { 38 38 return nil, err 39 39 } 40 40
+3 -3
api/ozone/moderationgetEvent.go
··· 7 7 import ( 8 8 "context" 9 9 10 - "github.com/bluesky-social/indigo/lex/util" 10 + lexutil "github.com/bluesky-social/indigo/lex/util" 11 11 ) 12 12 13 13 // ModerationGetEvent calls the XRPC method "tools.ozone.moderation.getEvent". 14 - func ModerationGetEvent(ctx context.Context, c util.LexClient, id int64) (*ModerationDefs_ModEventViewDetail, error) { 14 + func ModerationGetEvent(ctx context.Context, c lexutil.LexClient, id int64) (*ModerationDefs_ModEventViewDetail, error) { 15 15 var out ModerationDefs_ModEventViewDetail 16 16 17 17 params := map[string]interface{}{} 18 18 params["id"] = id 19 - if err := c.LexDo(ctx, util.Query, "", "tools.ozone.moderation.getEvent", params, nil, &out); err != nil { 19 + if err := c.LexDo(ctx, lexutil.Query, "", "tools.ozone.moderation.getEvent", params, nil, &out); err != nil { 20 20 return nil, err 21 21 } 22 22
+3 -3
api/ozone/moderationgetRecord.go
··· 7 7 import ( 8 8 "context" 9 9 10 - "github.com/bluesky-social/indigo/lex/util" 10 + lexutil "github.com/bluesky-social/indigo/lex/util" 11 11 ) 12 12 13 13 // ModerationGetRecord calls the XRPC method "tools.ozone.moderation.getRecord". 14 - func ModerationGetRecord(ctx context.Context, c util.LexClient, cid string, uri string) (*ModerationDefs_RecordViewDetail, error) { 14 + func ModerationGetRecord(ctx context.Context, c lexutil.LexClient, cid string, uri string) (*ModerationDefs_RecordViewDetail, error) { 15 15 var out ModerationDefs_RecordViewDetail 16 16 17 17 params := map[string]interface{}{} ··· 19 19 params["cid"] = cid 20 20 } 21 21 params["uri"] = uri 22 - if err := c.LexDo(ctx, util.Query, "", "tools.ozone.moderation.getRecord", params, nil, &out); err != nil { 22 + if err := c.LexDo(ctx, lexutil.Query, "", "tools.ozone.moderation.getRecord", params, nil, &out); err != nil { 23 23 return nil, err 24 24 } 25 25
+4 -5
api/ozone/moderationgetRecords.go
··· 9 9 "encoding/json" 10 10 "fmt" 11 11 12 - "github.com/bluesky-social/indigo/lex/util" 12 + lexutil "github.com/bluesky-social/indigo/lex/util" 13 13 ) 14 14 15 15 // ModerationGetRecords_Output is the output of a tools.ozone.moderation.getRecords call. ··· 35 35 } 36 36 37 37 func (t *ModerationGetRecords_Output_Records_Elem) UnmarshalJSON(b []byte) error { 38 - typ, err := util.TypeExtract(b) 38 + typ, err := lexutil.TypeExtract(b) 39 39 if err != nil { 40 40 return err 41 41 } ··· 47 47 case "tools.ozone.moderation.defs#recordViewNotFound": 48 48 t.ModerationDefs_RecordViewNotFound = new(ModerationDefs_RecordViewNotFound) 49 49 return json.Unmarshal(b, t.ModerationDefs_RecordViewNotFound) 50 - 51 50 default: 52 51 return nil 53 52 } 54 53 } 55 54 56 55 // ModerationGetRecords calls the XRPC method "tools.ozone.moderation.getRecords". 57 - func ModerationGetRecords(ctx context.Context, c util.LexClient, uris []string) (*ModerationGetRecords_Output, error) { 56 + func ModerationGetRecords(ctx context.Context, c lexutil.LexClient, uris []string) (*ModerationGetRecords_Output, error) { 58 57 var out ModerationGetRecords_Output 59 58 60 59 params := map[string]interface{}{} 61 60 params["uris"] = uris 62 - if err := c.LexDo(ctx, util.Query, "", "tools.ozone.moderation.getRecords", params, nil, &out); err != nil { 61 + if err := c.LexDo(ctx, lexutil.Query, "", "tools.ozone.moderation.getRecords", params, nil, &out); err != nil { 63 62 return nil, err 64 63 } 65 64
+3 -3
api/ozone/moderationgetRepo.go
··· 7 7 import ( 8 8 "context" 9 9 10 - "github.com/bluesky-social/indigo/lex/util" 10 + lexutil "github.com/bluesky-social/indigo/lex/util" 11 11 ) 12 12 13 13 // ModerationGetRepo calls the XRPC method "tools.ozone.moderation.getRepo". 14 - func ModerationGetRepo(ctx context.Context, c util.LexClient, did string) (*ModerationDefs_RepoViewDetail, error) { 14 + func ModerationGetRepo(ctx context.Context, c lexutil.LexClient, did string) (*ModerationDefs_RepoViewDetail, error) { 15 15 var out ModerationDefs_RepoViewDetail 16 16 17 17 params := map[string]interface{}{} 18 18 params["did"] = did 19 - if err := c.LexDo(ctx, util.Query, "", "tools.ozone.moderation.getRepo", params, nil, &out); err != nil { 19 + if err := c.LexDo(ctx, lexutil.Query, "", "tools.ozone.moderation.getRepo", params, nil, &out); err != nil { 20 20 return nil, err 21 21 } 22 22
+3 -3
api/ozone/moderationgetReporterStats.go
··· 7 7 import ( 8 8 "context" 9 9 10 - "github.com/bluesky-social/indigo/lex/util" 10 + lexutil "github.com/bluesky-social/indigo/lex/util" 11 11 ) 12 12 13 13 // ModerationGetReporterStats_Output is the output of a tools.ozone.moderation.getReporterStats call. ··· 16 16 } 17 17 18 18 // ModerationGetReporterStats calls the XRPC method "tools.ozone.moderation.getReporterStats". 19 - func ModerationGetReporterStats(ctx context.Context, c util.LexClient, dids []string) (*ModerationGetReporterStats_Output, error) { 19 + func ModerationGetReporterStats(ctx context.Context, c lexutil.LexClient, dids []string) (*ModerationGetReporterStats_Output, error) { 20 20 var out ModerationGetReporterStats_Output 21 21 22 22 params := map[string]interface{}{} 23 23 params["dids"] = dids 24 - if err := c.LexDo(ctx, util.Query, "", "tools.ozone.moderation.getReporterStats", params, nil, &out); err != nil { 24 + if err := c.LexDo(ctx, lexutil.Query, "", "tools.ozone.moderation.getReporterStats", params, nil, &out); err != nil { 25 25 return nil, err 26 26 } 27 27
+4 -5
api/ozone/moderationgetRepos.go
··· 9 9 "encoding/json" 10 10 "fmt" 11 11 12 - "github.com/bluesky-social/indigo/lex/util" 12 + lexutil "github.com/bluesky-social/indigo/lex/util" 13 13 ) 14 14 15 15 // ModerationGetRepos_Output is the output of a tools.ozone.moderation.getRepos call. ··· 35 35 } 36 36 37 37 func (t *ModerationGetRepos_Output_Repos_Elem) UnmarshalJSON(b []byte) error { 38 - typ, err := util.TypeExtract(b) 38 + typ, err := lexutil.TypeExtract(b) 39 39 if err != nil { 40 40 return err 41 41 } ··· 47 47 case "tools.ozone.moderation.defs#repoViewNotFound": 48 48 t.ModerationDefs_RepoViewNotFound = new(ModerationDefs_RepoViewNotFound) 49 49 return json.Unmarshal(b, t.ModerationDefs_RepoViewNotFound) 50 - 51 50 default: 52 51 return nil 53 52 } 54 53 } 55 54 56 55 // ModerationGetRepos calls the XRPC method "tools.ozone.moderation.getRepos". 57 - func ModerationGetRepos(ctx context.Context, c util.LexClient, dids []string) (*ModerationGetRepos_Output, error) { 56 + func ModerationGetRepos(ctx context.Context, c lexutil.LexClient, dids []string) (*ModerationGetRepos_Output, error) { 58 57 var out ModerationGetRepos_Output 59 58 60 59 params := map[string]interface{}{} 61 60 params["dids"] = dids 62 - if err := c.LexDo(ctx, util.Query, "", "tools.ozone.moderation.getRepos", params, nil, &out); err != nil { 61 + if err := c.LexDo(ctx, lexutil.Query, "", "tools.ozone.moderation.getRepos", params, nil, &out); err != nil { 63 62 return nil, err 64 63 } 65 64
+3 -3
api/ozone/moderationgetSubjects.go
··· 7 7 import ( 8 8 "context" 9 9 10 - "github.com/bluesky-social/indigo/lex/util" 10 + lexutil "github.com/bluesky-social/indigo/lex/util" 11 11 ) 12 12 13 13 // ModerationGetSubjects_Output is the output of a tools.ozone.moderation.getSubjects call. ··· 16 16 } 17 17 18 18 // ModerationGetSubjects calls the XRPC method "tools.ozone.moderation.getSubjects". 19 - func ModerationGetSubjects(ctx context.Context, c util.LexClient, subjects []string) (*ModerationGetSubjects_Output, error) { 19 + func ModerationGetSubjects(ctx context.Context, c lexutil.LexClient, subjects []string) (*ModerationGetSubjects_Output, error) { 20 20 var out ModerationGetSubjects_Output 21 21 22 22 params := map[string]interface{}{} 23 23 params["subjects"] = subjects 24 - if err := c.LexDo(ctx, util.Query, "", "tools.ozone.moderation.getSubjects", params, nil, &out); err != nil { 24 + if err := c.LexDo(ctx, lexutil.Query, "", "tools.ozone.moderation.getSubjects", params, nil, &out); err != nil { 25 25 return nil, err 26 26 } 27 27
+3 -3
api/ozone/moderationlistScheduledActions.go
··· 7 7 import ( 8 8 "context" 9 9 10 - "github.com/bluesky-social/indigo/lex/util" 10 + lexutil "github.com/bluesky-social/indigo/lex/util" 11 11 ) 12 12 13 13 // ModerationListScheduledActions_Input is the input argument to a tools.ozone.moderation.listScheduledActions call. ··· 34 34 } 35 35 36 36 // ModerationListScheduledActions calls the XRPC method "tools.ozone.moderation.listScheduledActions". 37 - func ModerationListScheduledActions(ctx context.Context, c util.LexClient, input *ModerationListScheduledActions_Input) (*ModerationListScheduledActions_Output, error) { 37 + func ModerationListScheduledActions(ctx context.Context, c lexutil.LexClient, input *ModerationListScheduledActions_Input) (*ModerationListScheduledActions_Output, error) { 38 38 var out ModerationListScheduledActions_Output 39 - if err := c.LexDo(ctx, util.Procedure, "application/json", "tools.ozone.moderation.listScheduledActions", nil, input, &out); err != nil { 39 + if err := c.LexDo(ctx, lexutil.Procedure, "application/json", "tools.ozone.moderation.listScheduledActions", nil, input, &out); err != nil { 40 40 return nil, err 41 41 } 42 42
+3 -3
api/ozone/moderationqueryEvents.go
··· 7 7 import ( 8 8 "context" 9 9 10 - "github.com/bluesky-social/indigo/lex/util" 10 + lexutil "github.com/bluesky-social/indigo/lex/util" 11 11 ) 12 12 13 13 // ModerationQueryEvents_Output is the output of a tools.ozone.moderation.queryEvents call. ··· 34 34 // sortDirection: Sort direction for the events. Defaults to descending order of created at timestamp. 35 35 // subjectType: If specified, only events where the subject is of the given type (account or record) will be returned. When this is set to 'account' the 'collections' parameter will be ignored. When includeAllUserRecords or subject is set, this will be ignored. 36 36 // types: The types of events (fully qualified string in the format of tools.ozone.moderation.defs#modEvent<name>) to filter by. If not specified, all events are returned. 37 - func ModerationQueryEvents(ctx context.Context, c util.LexClient, addedLabels []string, addedTags []string, ageAssuranceState string, batchId string, collections []string, comment string, createdAfter string, createdBefore string, createdBy string, cursor string, hasComment bool, includeAllUserRecords bool, limit int64, modTool []string, policies []string, removedLabels []string, removedTags []string, reportTypes []string, sortDirection string, subject string, subjectType string, types []string) (*ModerationQueryEvents_Output, error) { 37 + func ModerationQueryEvents(ctx context.Context, c lexutil.LexClient, addedLabels []string, addedTags []string, ageAssuranceState string, batchId string, collections []string, comment string, createdAfter string, createdBefore string, createdBy string, cursor string, hasComment bool, includeAllUserRecords bool, limit int64, modTool []string, policies []string, removedLabels []string, removedTags []string, reportTypes []string, sortDirection string, subject string, subjectType string, types []string) (*ModerationQueryEvents_Output, error) { 38 38 var out ModerationQueryEvents_Output 39 39 40 40 params := map[string]interface{}{} ··· 104 104 if len(types) != 0 { 105 105 params["types"] = types 106 106 } 107 - if err := c.LexDo(ctx, util.Query, "", "tools.ozone.moderation.queryEvents", params, nil, &out); err != nil { 107 + if err := c.LexDo(ctx, lexutil.Query, "", "tools.ozone.moderation.queryEvents", params, nil, &out); err != nil { 108 108 return nil, err 109 109 } 110 110
+3 -3
api/ozone/moderationqueryStatuses.go
··· 7 7 import ( 8 8 "context" 9 9 10 - "github.com/bluesky-social/indigo/lex/util" 10 + lexutil "github.com/bluesky-social/indigo/lex/util" 11 11 ) 12 12 13 13 // ModerationQueryStatuses_Output is the output of a tools.ozone.moderation.queryStatuses call. ··· 46 46 // subject: The subject to get the status for. 47 47 // subjectType: If specified, subjects of the given type (account or record) will be returned. When this is set to 'account' the 'collections' parameter will be ignored. When includeAllUserRecords or subject is set, this will be ignored. 48 48 // takendown: Get subjects that were taken down 49 - func ModerationQueryStatuses(ctx context.Context, c util.LexClient, ageAssuranceState string, appealed bool, collections []string, comment string, cursor string, excludeTags []string, hostingDeletedAfter string, hostingDeletedBefore string, hostingStatuses []string, hostingUpdatedAfter string, hostingUpdatedBefore string, ignoreSubjects []string, includeAllUserRecords bool, includeMuted bool, lastReviewedBy string, limit int64, minAccountSuspendCount int64, minPriorityScore int64, minReportedRecordsCount int64, minTakendownRecordsCount int64, onlyMuted bool, queueCount int64, queueIndex int64, queueSeed string, reportedAfter string, reportedBefore string, reviewState string, reviewedAfter string, reviewedBefore string, sortDirection string, sortField string, subject string, subjectType string, tags []string, takendown bool) (*ModerationQueryStatuses_Output, error) { 49 + func ModerationQueryStatuses(ctx context.Context, c lexutil.LexClient, ageAssuranceState string, appealed bool, collections []string, comment string, cursor string, excludeTags []string, hostingDeletedAfter string, hostingDeletedBefore string, hostingStatuses []string, hostingUpdatedAfter string, hostingUpdatedBefore string, ignoreSubjects []string, includeAllUserRecords bool, includeMuted bool, lastReviewedBy string, limit int64, minAccountSuspendCount int64, minPriorityScore int64, minReportedRecordsCount int64, minTakendownRecordsCount int64, onlyMuted bool, queueCount int64, queueIndex int64, queueSeed string, reportedAfter string, reportedBefore string, reviewState string, reviewedAfter string, reviewedBefore string, sortDirection string, sortField string, subject string, subjectType string, tags []string, takendown bool) (*ModerationQueryStatuses_Output, error) { 50 50 var out ModerationQueryStatuses_Output 51 51 52 52 params := map[string]interface{}{} ··· 155 155 if takendown { 156 156 params["takendown"] = takendown 157 157 } 158 - if err := c.LexDo(ctx, util.Query, "", "tools.ozone.moderation.queryStatuses", params, nil, &out); err != nil { 158 + if err := c.LexDo(ctx, lexutil.Query, "", "tools.ozone.moderation.queryStatuses", params, nil, &out); err != nil { 159 159 return nil, err 160 160 } 161 161
+4 -5
api/ozone/moderationscheduleAction.go
··· 9 9 "encoding/json" 10 10 "fmt" 11 11 12 - "github.com/bluesky-social/indigo/lex/util" 12 + lexutil "github.com/bluesky-social/indigo/lex/util" 13 13 ) 14 14 15 15 // ModerationScheduleAction_FailedScheduling is a "failedScheduling" in the tools.ozone.moderation.scheduleAction schema. ··· 43 43 } 44 44 45 45 func (t *ModerationScheduleAction_Input_Action) UnmarshalJSON(b []byte) error { 46 - typ, err := util.TypeExtract(b) 46 + typ, err := lexutil.TypeExtract(b) 47 47 if err != nil { 48 48 return err 49 49 } ··· 52 52 case "tools.ozone.moderation.scheduleAction#takedown": 53 53 t.ModerationScheduleAction_Takedown = new(ModerationScheduleAction_Takedown) 54 54 return json.Unmarshal(b, t.ModerationScheduleAction_Takedown) 55 - 56 55 default: 57 56 return nil 58 57 } ··· 91 90 } 92 91 93 92 // ModerationScheduleAction calls the XRPC method "tools.ozone.moderation.scheduleAction". 94 - func ModerationScheduleAction(ctx context.Context, c util.LexClient, input *ModerationScheduleAction_Input) (*ModerationScheduleAction_ScheduledActionResults, error) { 93 + func ModerationScheduleAction(ctx context.Context, c lexutil.LexClient, input *ModerationScheduleAction_Input) (*ModerationScheduleAction_ScheduledActionResults, error) { 95 94 var out ModerationScheduleAction_ScheduledActionResults 96 - if err := c.LexDo(ctx, util.Procedure, "application/json", "tools.ozone.moderation.scheduleAction", nil, input, &out); err != nil { 95 + if err := c.LexDo(ctx, lexutil.Procedure, "application/json", "tools.ozone.moderation.scheduleAction", nil, input, &out); err != nil { 97 96 return nil, err 98 97 } 99 98
+3 -3
api/ozone/moderationsearchRepos.go
··· 7 7 import ( 8 8 "context" 9 9 10 - "github.com/bluesky-social/indigo/lex/util" 10 + lexutil "github.com/bluesky-social/indigo/lex/util" 11 11 ) 12 12 13 13 // ModerationSearchRepos_Output is the output of a tools.ozone.moderation.searchRepos call. ··· 19 19 // ModerationSearchRepos calls the XRPC method "tools.ozone.moderation.searchRepos". 20 20 // 21 21 // term: DEPRECATED: use 'q' instead 22 - func ModerationSearchRepos(ctx context.Context, c util.LexClient, cursor string, limit int64, q string, term string) (*ModerationSearchRepos_Output, error) { 22 + func ModerationSearchRepos(ctx context.Context, c lexutil.LexClient, cursor string, limit int64, q string, term string) (*ModerationSearchRepos_Output, error) { 23 23 var out ModerationSearchRepos_Output 24 24 25 25 params := map[string]interface{}{} ··· 35 35 if term != "" { 36 36 params["term"] = term 37 37 } 38 - if err := c.LexDo(ctx, util.Query, "", "tools.ozone.moderation.searchRepos", params, nil, &out); err != nil { 38 + if err := c.LexDo(ctx, lexutil.Query, "", "tools.ozone.moderation.searchRepos", params, nil, &out); err != nil { 39 39 return nil, err 40 40 } 41 41
+3 -3
api/ozone/safelinkaddRule.go
··· 7 7 import ( 8 8 "context" 9 9 10 - "github.com/bluesky-social/indigo/lex/util" 10 + lexutil "github.com/bluesky-social/indigo/lex/util" 11 11 ) 12 12 13 13 // SafelinkAddRule_Input is the input argument to a tools.ozone.safelink.addRule call. ··· 24 24 } 25 25 26 26 // SafelinkAddRule calls the XRPC method "tools.ozone.safelink.addRule". 27 - func SafelinkAddRule(ctx context.Context, c util.LexClient, input *SafelinkAddRule_Input) (*SafelinkDefs_Event, error) { 27 + func SafelinkAddRule(ctx context.Context, c lexutil.LexClient, input *SafelinkAddRule_Input) (*SafelinkDefs_Event, error) { 28 28 var out SafelinkDefs_Event 29 - if err := c.LexDo(ctx, util.Procedure, "application/json", "tools.ozone.safelink.addRule", nil, input, &out); err != nil { 29 + if err := c.LexDo(ctx, lexutil.Procedure, "application/json", "tools.ozone.safelink.addRule", nil, input, &out); err != nil { 30 30 return nil, err 31 31 } 32 32
+3 -3
api/ozone/safelinkqueryEvents.go
··· 7 7 import ( 8 8 "context" 9 9 10 - "github.com/bluesky-social/indigo/lex/util" 10 + lexutil "github.com/bluesky-social/indigo/lex/util" 11 11 ) 12 12 13 13 // SafelinkQueryEvents_Input is the input argument to a tools.ozone.safelink.queryEvents call. ··· 32 32 } 33 33 34 34 // SafelinkQueryEvents calls the XRPC method "tools.ozone.safelink.queryEvents". 35 - func SafelinkQueryEvents(ctx context.Context, c util.LexClient, input *SafelinkQueryEvents_Input) (*SafelinkQueryEvents_Output, error) { 35 + func SafelinkQueryEvents(ctx context.Context, c lexutil.LexClient, input *SafelinkQueryEvents_Input) (*SafelinkQueryEvents_Output, error) { 36 36 var out SafelinkQueryEvents_Output 37 - if err := c.LexDo(ctx, util.Procedure, "application/json", "tools.ozone.safelink.queryEvents", nil, input, &out); err != nil { 37 + if err := c.LexDo(ctx, lexutil.Procedure, "application/json", "tools.ozone.safelink.queryEvents", nil, input, &out); err != nil { 38 38 return nil, err 39 39 } 40 40
+3 -3
api/ozone/safelinkqueryRules.go
··· 7 7 import ( 8 8 "context" 9 9 10 - "github.com/bluesky-social/indigo/lex/util" 10 + lexutil "github.com/bluesky-social/indigo/lex/util" 11 11 ) 12 12 13 13 // SafelinkQueryRules_Input is the input argument to a tools.ozone.safelink.queryRules call. ··· 38 38 } 39 39 40 40 // SafelinkQueryRules calls the XRPC method "tools.ozone.safelink.queryRules". 41 - func SafelinkQueryRules(ctx context.Context, c util.LexClient, input *SafelinkQueryRules_Input) (*SafelinkQueryRules_Output, error) { 41 + func SafelinkQueryRules(ctx context.Context, c lexutil.LexClient, input *SafelinkQueryRules_Input) (*SafelinkQueryRules_Output, error) { 42 42 var out SafelinkQueryRules_Output 43 - if err := c.LexDo(ctx, util.Procedure, "application/json", "tools.ozone.safelink.queryRules", nil, input, &out); err != nil { 43 + if err := c.LexDo(ctx, lexutil.Procedure, "application/json", "tools.ozone.safelink.queryRules", nil, input, &out); err != nil { 44 44 return nil, err 45 45 } 46 46
+3 -3
api/ozone/safelinkremoveRule.go
··· 7 7 import ( 8 8 "context" 9 9 10 - "github.com/bluesky-social/indigo/lex/util" 10 + lexutil "github.com/bluesky-social/indigo/lex/util" 11 11 ) 12 12 13 13 // SafelinkRemoveRule_Input is the input argument to a tools.ozone.safelink.removeRule call. ··· 22 22 } 23 23 24 24 // SafelinkRemoveRule calls the XRPC method "tools.ozone.safelink.removeRule". 25 - func SafelinkRemoveRule(ctx context.Context, c util.LexClient, input *SafelinkRemoveRule_Input) (*SafelinkDefs_Event, error) { 25 + func SafelinkRemoveRule(ctx context.Context, c lexutil.LexClient, input *SafelinkRemoveRule_Input) (*SafelinkDefs_Event, error) { 26 26 var out SafelinkDefs_Event 27 - if err := c.LexDo(ctx, util.Procedure, "application/json", "tools.ozone.safelink.removeRule", nil, input, &out); err != nil { 27 + if err := c.LexDo(ctx, lexutil.Procedure, "application/json", "tools.ozone.safelink.removeRule", nil, input, &out); err != nil { 28 28 return nil, err 29 29 } 30 30
+3 -3
api/ozone/safelinkupdateRule.go
··· 7 7 import ( 8 8 "context" 9 9 10 - "github.com/bluesky-social/indigo/lex/util" 10 + lexutil "github.com/bluesky-social/indigo/lex/util" 11 11 ) 12 12 13 13 // SafelinkUpdateRule_Input is the input argument to a tools.ozone.safelink.updateRule call. ··· 24 24 } 25 25 26 26 // SafelinkUpdateRule calls the XRPC method "tools.ozone.safelink.updateRule". 27 - func SafelinkUpdateRule(ctx context.Context, c util.LexClient, input *SafelinkUpdateRule_Input) (*SafelinkDefs_Event, error) { 27 + func SafelinkUpdateRule(ctx context.Context, c lexutil.LexClient, input *SafelinkUpdateRule_Input) (*SafelinkDefs_Event, error) { 28 28 var out SafelinkDefs_Event 29 - if err := c.LexDo(ctx, util.Procedure, "application/json", "tools.ozone.safelink.updateRule", nil, input, &out); err != nil { 29 + if err := c.LexDo(ctx, lexutil.Procedure, "application/json", "tools.ozone.safelink.updateRule", nil, input, &out); err != nil { 30 30 return nil, err 31 31 } 32 32
+3 -3
api/ozone/servergetConfig.go
··· 7 7 import ( 8 8 "context" 9 9 10 - "github.com/bluesky-social/indigo/lex/util" 10 + lexutil "github.com/bluesky-social/indigo/lex/util" 11 11 ) 12 12 13 13 // ServerGetConfig_Output is the output of a tools.ozone.server.getConfig call. ··· 32 32 } 33 33 34 34 // ServerGetConfig calls the XRPC method "tools.ozone.server.getConfig". 35 - func ServerGetConfig(ctx context.Context, c util.LexClient) (*ServerGetConfig_Output, error) { 35 + func ServerGetConfig(ctx context.Context, c lexutil.LexClient) (*ServerGetConfig_Output, error) { 36 36 var out ServerGetConfig_Output 37 - if err := c.LexDo(ctx, util.Query, "", "tools.ozone.server.getConfig", nil, nil, &out); err != nil { 37 + if err := c.LexDo(ctx, lexutil.Query, "", "tools.ozone.server.getConfig", nil, nil, &out); err != nil { 38 38 return nil, err 39 39 } 40 40
+3 -3
api/ozone/setaddValues.go
··· 7 7 import ( 8 8 "context" 9 9 10 - "github.com/bluesky-social/indigo/lex/util" 10 + lexutil "github.com/bluesky-social/indigo/lex/util" 11 11 ) 12 12 13 13 // SetAddValues_Input is the input argument to a tools.ozone.set.addValues call. ··· 19 19 } 20 20 21 21 // SetAddValues calls the XRPC method "tools.ozone.set.addValues". 22 - func SetAddValues(ctx context.Context, c util.LexClient, input *SetAddValues_Input) error { 23 - if err := c.LexDo(ctx, util.Procedure, "application/json", "tools.ozone.set.addValues", nil, input, nil); err != nil { 22 + func SetAddValues(ctx context.Context, c lexutil.LexClient, input *SetAddValues_Input) error { 23 + if err := c.LexDo(ctx, lexutil.Procedure, "application/json", "tools.ozone.set.addValues", nil, input, nil); err != nil { 24 24 return err 25 25 } 26 26
+3 -3
api/ozone/setdeleteSet.go
··· 7 7 import ( 8 8 "context" 9 9 10 - "github.com/bluesky-social/indigo/lex/util" 10 + lexutil "github.com/bluesky-social/indigo/lex/util" 11 11 ) 12 12 13 13 // SetDeleteSet_Input is the input argument to a tools.ozone.set.deleteSet call. ··· 21 21 } 22 22 23 23 // SetDeleteSet calls the XRPC method "tools.ozone.set.deleteSet". 24 - func SetDeleteSet(ctx context.Context, c util.LexClient, input *SetDeleteSet_Input) (*SetDeleteSet_Output, error) { 24 + func SetDeleteSet(ctx context.Context, c lexutil.LexClient, input *SetDeleteSet_Input) (*SetDeleteSet_Output, error) { 25 25 var out SetDeleteSet_Output 26 - if err := c.LexDo(ctx, util.Procedure, "application/json", "tools.ozone.set.deleteSet", nil, input, &out); err != nil { 26 + if err := c.LexDo(ctx, lexutil.Procedure, "application/json", "tools.ozone.set.deleteSet", nil, input, &out); err != nil { 27 27 return nil, err 28 28 } 29 29
+3 -3
api/ozone/setdeleteValues.go
··· 7 7 import ( 8 8 "context" 9 9 10 - "github.com/bluesky-social/indigo/lex/util" 10 + lexutil "github.com/bluesky-social/indigo/lex/util" 11 11 ) 12 12 13 13 // SetDeleteValues_Input is the input argument to a tools.ozone.set.deleteValues call. ··· 19 19 } 20 20 21 21 // SetDeleteValues calls the XRPC method "tools.ozone.set.deleteValues". 22 - func SetDeleteValues(ctx context.Context, c util.LexClient, input *SetDeleteValues_Input) error { 23 - if err := c.LexDo(ctx, util.Procedure, "application/json", "tools.ozone.set.deleteValues", nil, input, nil); err != nil { 22 + func SetDeleteValues(ctx context.Context, c lexutil.LexClient, input *SetDeleteValues_Input) error { 23 + if err := c.LexDo(ctx, lexutil.Procedure, "application/json", "tools.ozone.set.deleteValues", nil, input, nil); err != nil { 24 24 return err 25 25 } 26 26
+3 -3
api/ozone/setgetValues.go
··· 7 7 import ( 8 8 "context" 9 9 10 - "github.com/bluesky-social/indigo/lex/util" 10 + lexutil "github.com/bluesky-social/indigo/lex/util" 11 11 ) 12 12 13 13 // SetGetValues_Output is the output of a tools.ozone.set.getValues call. ··· 18 18 } 19 19 20 20 // SetGetValues calls the XRPC method "tools.ozone.set.getValues". 21 - func SetGetValues(ctx context.Context, c util.LexClient, cursor string, limit int64, name string) (*SetGetValues_Output, error) { 21 + func SetGetValues(ctx context.Context, c lexutil.LexClient, cursor string, limit int64, name string) (*SetGetValues_Output, error) { 22 22 var out SetGetValues_Output 23 23 24 24 params := map[string]interface{}{} ··· 29 29 params["limit"] = limit 30 30 } 31 31 params["name"] = name 32 - if err := c.LexDo(ctx, util.Query, "", "tools.ozone.set.getValues", params, nil, &out); err != nil { 32 + if err := c.LexDo(ctx, lexutil.Query, "", "tools.ozone.set.getValues", params, nil, &out); err != nil { 33 33 return nil, err 34 34 } 35 35
+3 -3
api/ozone/setquerySets.go
··· 7 7 import ( 8 8 "context" 9 9 10 - "github.com/bluesky-social/indigo/lex/util" 10 + lexutil "github.com/bluesky-social/indigo/lex/util" 11 11 ) 12 12 13 13 // SetQuerySets_Output is the output of a tools.ozone.set.querySets call. ··· 19 19 // SetQuerySets calls the XRPC method "tools.ozone.set.querySets". 20 20 // 21 21 // sortDirection: Defaults to ascending order of name field. 22 - func SetQuerySets(ctx context.Context, c util.LexClient, cursor string, limit int64, namePrefix string, sortBy string, sortDirection string) (*SetQuerySets_Output, error) { 22 + func SetQuerySets(ctx context.Context, c lexutil.LexClient, cursor string, limit int64, namePrefix string, sortBy string, sortDirection string) (*SetQuerySets_Output, error) { 23 23 var out SetQuerySets_Output 24 24 25 25 params := map[string]interface{}{} ··· 38 38 if sortDirection != "" { 39 39 params["sortDirection"] = sortDirection 40 40 } 41 - if err := c.LexDo(ctx, util.Query, "", "tools.ozone.set.querySets", params, nil, &out); err != nil { 41 + if err := c.LexDo(ctx, lexutil.Query, "", "tools.ozone.set.querySets", params, nil, &out); err != nil { 42 42 return nil, err 43 43 } 44 44
+11 -11
api/ozone/settingdefs.go
··· 5 5 package ozone 6 6 7 7 import ( 8 - "github.com/bluesky-social/indigo/lex/util" 8 + lexutil "github.com/bluesky-social/indigo/lex/util" 9 9 ) 10 10 11 11 // SettingDefs_Option is a "option" in the tools.ozone.setting.defs schema. 12 12 type SettingDefs_Option struct { 13 - CreatedAt *string `json:"createdAt,omitempty" cborgen:"createdAt,omitempty"` 14 - CreatedBy string `json:"createdBy" cborgen:"createdBy"` 15 - Description *string `json:"description,omitempty" cborgen:"description,omitempty"` 16 - Did string `json:"did" cborgen:"did"` 17 - Key string `json:"key" cborgen:"key"` 18 - LastUpdatedBy string `json:"lastUpdatedBy" cborgen:"lastUpdatedBy"` 19 - ManagerRole *string `json:"managerRole,omitempty" cborgen:"managerRole,omitempty"` 20 - Scope string `json:"scope" cborgen:"scope"` 21 - UpdatedAt *string `json:"updatedAt,omitempty" cborgen:"updatedAt,omitempty"` 22 - Value *util.LexiconTypeDecoder `json:"value" cborgen:"value"` 13 + CreatedAt *string `json:"createdAt,omitempty" cborgen:"createdAt,omitempty"` 14 + CreatedBy string `json:"createdBy" cborgen:"createdBy"` 15 + Description *string `json:"description,omitempty" cborgen:"description,omitempty"` 16 + Did string `json:"did" cborgen:"did"` 17 + Key string `json:"key" cborgen:"key"` 18 + LastUpdatedBy string `json:"lastUpdatedBy" cborgen:"lastUpdatedBy"` 19 + ManagerRole *string `json:"managerRole,omitempty" cborgen:"managerRole,omitempty"` 20 + Scope string `json:"scope" cborgen:"scope"` 21 + UpdatedAt *string `json:"updatedAt,omitempty" cborgen:"updatedAt,omitempty"` 22 + Value *lexutil.LexiconTypeDecoder `json:"value" cborgen:"value"` 23 23 }
+3 -3
api/ozone/settinglistOptions.go
··· 7 7 import ( 8 8 "context" 9 9 10 - "github.com/bluesky-social/indigo/lex/util" 10 + lexutil "github.com/bluesky-social/indigo/lex/util" 11 11 ) 12 12 13 13 // SettingListOptions_Output is the output of a tools.ozone.setting.listOptions call. ··· 20 20 // 21 21 // keys: Filter for only the specified keys. Ignored if prefix is provided 22 22 // prefix: Filter keys by prefix 23 - func SettingListOptions(ctx context.Context, c util.LexClient, cursor string, keys []string, limit int64, prefix string, scope string) (*SettingListOptions_Output, error) { 23 + func SettingListOptions(ctx context.Context, c lexutil.LexClient, cursor string, keys []string, limit int64, prefix string, scope string) (*SettingListOptions_Output, error) { 24 24 var out SettingListOptions_Output 25 25 26 26 params := map[string]interface{}{} ··· 39 39 if scope != "" { 40 40 params["scope"] = scope 41 41 } 42 - if err := c.LexDo(ctx, util.Query, "", "tools.ozone.setting.listOptions", params, nil, &out); err != nil { 42 + if err := c.LexDo(ctx, lexutil.Query, "", "tools.ozone.setting.listOptions", params, nil, &out); err != nil { 43 43 return nil, err 44 44 } 45 45
+3 -3
api/ozone/settingremoveOptions.go
··· 7 7 import ( 8 8 "context" 9 9 10 - "github.com/bluesky-social/indigo/lex/util" 10 + lexutil "github.com/bluesky-social/indigo/lex/util" 11 11 ) 12 12 13 13 // SettingRemoveOptions_Input is the input argument to a tools.ozone.setting.removeOptions call. ··· 21 21 } 22 22 23 23 // SettingRemoveOptions calls the XRPC method "tools.ozone.setting.removeOptions". 24 - func SettingRemoveOptions(ctx context.Context, c util.LexClient, input *SettingRemoveOptions_Input) (*SettingRemoveOptions_Output, error) { 24 + func SettingRemoveOptions(ctx context.Context, c lexutil.LexClient, input *SettingRemoveOptions_Input) (*SettingRemoveOptions_Output, error) { 25 25 var out SettingRemoveOptions_Output 26 - if err := c.LexDo(ctx, util.Procedure, "application/json", "tools.ozone.setting.removeOptions", nil, input, &out); err != nil { 26 + if err := c.LexDo(ctx, lexutil.Procedure, "application/json", "tools.ozone.setting.removeOptions", nil, input, &out); err != nil { 27 27 return nil, err 28 28 } 29 29
+8 -8
api/ozone/settingupsertOption.go
··· 7 7 import ( 8 8 "context" 9 9 10 - "github.com/bluesky-social/indigo/lex/util" 10 + lexutil "github.com/bluesky-social/indigo/lex/util" 11 11 ) 12 12 13 13 // SettingUpsertOption_Input is the input argument to a tools.ozone.setting.upsertOption call. 14 14 type SettingUpsertOption_Input struct { 15 - Description *string `json:"description,omitempty" cborgen:"description,omitempty"` 16 - Key string `json:"key" cborgen:"key"` 17 - ManagerRole *string `json:"managerRole,omitempty" cborgen:"managerRole,omitempty"` 18 - Scope string `json:"scope" cborgen:"scope"` 19 - Value *util.LexiconTypeDecoder `json:"value" cborgen:"value"` 15 + Description *string `json:"description,omitempty" cborgen:"description,omitempty"` 16 + Key string `json:"key" cborgen:"key"` 17 + ManagerRole *string `json:"managerRole,omitempty" cborgen:"managerRole,omitempty"` 18 + Scope string `json:"scope" cborgen:"scope"` 19 + Value *lexutil.LexiconTypeDecoder `json:"value" cborgen:"value"` 20 20 } 21 21 22 22 // SettingUpsertOption_Output is the output of a tools.ozone.setting.upsertOption call. ··· 25 25 } 26 26 27 27 // SettingUpsertOption calls the XRPC method "tools.ozone.setting.upsertOption". 28 - func SettingUpsertOption(ctx context.Context, c util.LexClient, input *SettingUpsertOption_Input) (*SettingUpsertOption_Output, error) { 28 + func SettingUpsertOption(ctx context.Context, c lexutil.LexClient, input *SettingUpsertOption_Input) (*SettingUpsertOption_Output, error) { 29 29 var out SettingUpsertOption_Output 30 - if err := c.LexDo(ctx, util.Procedure, "application/json", "tools.ozone.setting.upsertOption", nil, input, &out); err != nil { 30 + if err := c.LexDo(ctx, lexutil.Procedure, "application/json", "tools.ozone.setting.upsertOption", nil, input, &out); err != nil { 31 31 return nil, err 32 32 } 33 33
+3 -3
api/ozone/setupsertSet.go
··· 7 7 import ( 8 8 "context" 9 9 10 - "github.com/bluesky-social/indigo/lex/util" 10 + lexutil "github.com/bluesky-social/indigo/lex/util" 11 11 ) 12 12 13 13 // SetUpsertSet calls the XRPC method "tools.ozone.set.upsertSet". 14 - func SetUpsertSet(ctx context.Context, c util.LexClient, input *SetDefs_Set) (*SetDefs_SetView, error) { 14 + func SetUpsertSet(ctx context.Context, c lexutil.LexClient, input *SetDefs_Set) (*SetDefs_SetView, error) { 15 15 var out SetDefs_SetView 16 - if err := c.LexDo(ctx, util.Procedure, "application/json", "tools.ozone.set.upsertSet", nil, input, &out); err != nil { 16 + if err := c.LexDo(ctx, lexutil.Procedure, "application/json", "tools.ozone.set.upsertSet", nil, input, &out); err != nil { 17 17 return nil, err 18 18 } 19 19
+3 -3
api/ozone/signaturefindCorrelation.go
··· 7 7 import ( 8 8 "context" 9 9 10 - "github.com/bluesky-social/indigo/lex/util" 10 + lexutil "github.com/bluesky-social/indigo/lex/util" 11 11 ) 12 12 13 13 // SignatureFindCorrelation_Output is the output of a tools.ozone.signature.findCorrelation call. ··· 16 16 } 17 17 18 18 // SignatureFindCorrelation calls the XRPC method "tools.ozone.signature.findCorrelation". 19 - func SignatureFindCorrelation(ctx context.Context, c util.LexClient, dids []string) (*SignatureFindCorrelation_Output, error) { 19 + func SignatureFindCorrelation(ctx context.Context, c lexutil.LexClient, dids []string) (*SignatureFindCorrelation_Output, error) { 20 20 var out SignatureFindCorrelation_Output 21 21 22 22 params := map[string]interface{}{} 23 23 params["dids"] = dids 24 - if err := c.LexDo(ctx, util.Query, "", "tools.ozone.signature.findCorrelation", params, nil, &out); err != nil { 24 + if err := c.LexDo(ctx, lexutil.Query, "", "tools.ozone.signature.findCorrelation", params, nil, &out); err != nil { 25 25 return nil, err 26 26 } 27 27
+6 -6
api/ozone/signaturefindRelatedAccounts.go
··· 7 7 import ( 8 8 "context" 9 9 10 - comatprototypes "github.com/bluesky-social/indigo/api/atproto" 11 - "github.com/bluesky-social/indigo/lex/util" 10 + comatproto "github.com/bluesky-social/indigo/api/atproto" 11 + lexutil "github.com/bluesky-social/indigo/lex/util" 12 12 ) 13 13 14 14 // SignatureFindRelatedAccounts_Output is the output of a tools.ozone.signature.findRelatedAccounts call. ··· 19 19 20 20 // SignatureFindRelatedAccounts_RelatedAccount is a "relatedAccount" in the tools.ozone.signature.findRelatedAccounts schema. 21 21 type SignatureFindRelatedAccounts_RelatedAccount struct { 22 - Account *comatprototypes.AdminDefs_AccountView `json:"account" cborgen:"account"` 23 - Similarities []*SignatureDefs_SigDetail `json:"similarities,omitempty" cborgen:"similarities,omitempty"` 22 + Account *comatproto.AdminDefs_AccountView `json:"account" cborgen:"account"` 23 + Similarities []*SignatureDefs_SigDetail `json:"similarities,omitempty" cborgen:"similarities,omitempty"` 24 24 } 25 25 26 26 // SignatureFindRelatedAccounts calls the XRPC method "tools.ozone.signature.findRelatedAccounts". 27 - func SignatureFindRelatedAccounts(ctx context.Context, c util.LexClient, cursor string, did string, limit int64) (*SignatureFindRelatedAccounts_Output, error) { 27 + func SignatureFindRelatedAccounts(ctx context.Context, c lexutil.LexClient, cursor string, did string, limit int64) (*SignatureFindRelatedAccounts_Output, error) { 28 28 var out SignatureFindRelatedAccounts_Output 29 29 30 30 params := map[string]interface{}{} ··· 35 35 if limit != 0 { 36 36 params["limit"] = limit 37 37 } 38 - if err := c.LexDo(ctx, util.Query, "", "tools.ozone.signature.findRelatedAccounts", params, nil, &out); err != nil { 38 + if err := c.LexDo(ctx, lexutil.Query, "", "tools.ozone.signature.findRelatedAccounts", params, nil, &out); err != nil { 39 39 return nil, err 40 40 } 41 41
+6 -6
api/ozone/signaturesearchAccounts.go
··· 7 7 import ( 8 8 "context" 9 9 10 - comatprototypes "github.com/bluesky-social/indigo/api/atproto" 11 - "github.com/bluesky-social/indigo/lex/util" 10 + comatproto "github.com/bluesky-social/indigo/api/atproto" 11 + lexutil "github.com/bluesky-social/indigo/lex/util" 12 12 ) 13 13 14 14 // SignatureSearchAccounts_Output is the output of a tools.ozone.signature.searchAccounts call. 15 15 type SignatureSearchAccounts_Output struct { 16 - Accounts []*comatprototypes.AdminDefs_AccountView `json:"accounts" cborgen:"accounts"` 17 - Cursor *string `json:"cursor,omitempty" cborgen:"cursor,omitempty"` 16 + Accounts []*comatproto.AdminDefs_AccountView `json:"accounts" cborgen:"accounts"` 17 + Cursor *string `json:"cursor,omitempty" cborgen:"cursor,omitempty"` 18 18 } 19 19 20 20 // SignatureSearchAccounts calls the XRPC method "tools.ozone.signature.searchAccounts". 21 - func SignatureSearchAccounts(ctx context.Context, c util.LexClient, cursor string, limit int64, values []string) (*SignatureSearchAccounts_Output, error) { 21 + func SignatureSearchAccounts(ctx context.Context, c lexutil.LexClient, cursor string, limit int64, values []string) (*SignatureSearchAccounts_Output, error) { 22 22 var out SignatureSearchAccounts_Output 23 23 24 24 params := map[string]interface{}{} ··· 29 29 params["limit"] = limit 30 30 } 31 31 params["values"] = values 32 - if err := c.LexDo(ctx, util.Query, "", "tools.ozone.signature.searchAccounts", params, nil, &out); err != nil { 32 + if err := c.LexDo(ctx, lexutil.Query, "", "tools.ozone.signature.searchAccounts", params, nil, &out); err != nil { 33 33 return nil, err 34 34 } 35 35
+3 -3
api/ozone/teamaddMember.go
··· 7 7 import ( 8 8 "context" 9 9 10 - "github.com/bluesky-social/indigo/lex/util" 10 + lexutil "github.com/bluesky-social/indigo/lex/util" 11 11 ) 12 12 13 13 // TeamAddMember_Input is the input argument to a tools.ozone.team.addMember call. ··· 17 17 } 18 18 19 19 // TeamAddMember calls the XRPC method "tools.ozone.team.addMember". 20 - func TeamAddMember(ctx context.Context, c util.LexClient, input *TeamAddMember_Input) (*TeamDefs_Member, error) { 20 + func TeamAddMember(ctx context.Context, c lexutil.LexClient, input *TeamAddMember_Input) (*TeamDefs_Member, error) { 21 21 var out TeamDefs_Member 22 - if err := c.LexDo(ctx, util.Procedure, "application/json", "tools.ozone.team.addMember", nil, input, &out); err != nil { 22 + if err := c.LexDo(ctx, lexutil.Procedure, "application/json", "tools.ozone.team.addMember", nil, input, &out); err != nil { 23 23 return nil, err 24 24 } 25 25
+8 -8
api/ozone/teamdefs.go
··· 5 5 package ozone 6 6 7 7 import ( 8 - appbskytypes "github.com/bluesky-social/indigo/api/bsky" 8 + appbsky "github.com/bluesky-social/indigo/api/bsky" 9 9 ) 10 10 11 11 // TeamDefs_Member is a "member" in the tools.ozone.team.defs schema. 12 12 type TeamDefs_Member struct { 13 - CreatedAt *string `json:"createdAt,omitempty" cborgen:"createdAt,omitempty"` 14 - Did string `json:"did" cborgen:"did"` 15 - Disabled *bool `json:"disabled,omitempty" cborgen:"disabled,omitempty"` 16 - LastUpdatedBy *string `json:"lastUpdatedBy,omitempty" cborgen:"lastUpdatedBy,omitempty"` 17 - Profile *appbskytypes.ActorDefs_ProfileViewDetailed `json:"profile,omitempty" cborgen:"profile,omitempty"` 18 - Role string `json:"role" cborgen:"role"` 19 - UpdatedAt *string `json:"updatedAt,omitempty" cborgen:"updatedAt,omitempty"` 13 + CreatedAt *string `json:"createdAt,omitempty" cborgen:"createdAt,omitempty"` 14 + Did string `json:"did" cborgen:"did"` 15 + Disabled *bool `json:"disabled,omitempty" cborgen:"disabled,omitempty"` 16 + LastUpdatedBy *string `json:"lastUpdatedBy,omitempty" cborgen:"lastUpdatedBy,omitempty"` 17 + Profile *appbsky.ActorDefs_ProfileViewDetailed `json:"profile,omitempty" cborgen:"profile,omitempty"` 18 + Role string `json:"role" cborgen:"role"` 19 + UpdatedAt *string `json:"updatedAt,omitempty" cborgen:"updatedAt,omitempty"` 20 20 }
+3 -3
api/ozone/teamdeleteMember.go
··· 7 7 import ( 8 8 "context" 9 9 10 - "github.com/bluesky-social/indigo/lex/util" 10 + lexutil "github.com/bluesky-social/indigo/lex/util" 11 11 ) 12 12 13 13 // TeamDeleteMember_Input is the input argument to a tools.ozone.team.deleteMember call. ··· 16 16 } 17 17 18 18 // TeamDeleteMember calls the XRPC method "tools.ozone.team.deleteMember". 19 - func TeamDeleteMember(ctx context.Context, c util.LexClient, input *TeamDeleteMember_Input) error { 20 - if err := c.LexDo(ctx, util.Procedure, "application/json", "tools.ozone.team.deleteMember", nil, input, nil); err != nil { 19 + func TeamDeleteMember(ctx context.Context, c lexutil.LexClient, input *TeamDeleteMember_Input) error { 20 + if err := c.LexDo(ctx, lexutil.Procedure, "application/json", "tools.ozone.team.deleteMember", nil, input, nil); err != nil { 21 21 return err 22 22 } 23 23
+3 -3
api/ozone/teamlistMembers.go
··· 7 7 import ( 8 8 "context" 9 9 10 - "github.com/bluesky-social/indigo/lex/util" 10 + lexutil "github.com/bluesky-social/indigo/lex/util" 11 11 ) 12 12 13 13 // TeamListMembers_Output is the output of a tools.ozone.team.listMembers call. ··· 17 17 } 18 18 19 19 // TeamListMembers calls the XRPC method "tools.ozone.team.listMembers". 20 - func TeamListMembers(ctx context.Context, c util.LexClient, cursor string, disabled bool, limit int64, q string, roles []string) (*TeamListMembers_Output, error) { 20 + func TeamListMembers(ctx context.Context, c lexutil.LexClient, cursor string, disabled bool, limit int64, q string, roles []string) (*TeamListMembers_Output, error) { 21 21 var out TeamListMembers_Output 22 22 23 23 params := map[string]interface{}{} ··· 36 36 if len(roles) != 0 { 37 37 params["roles"] = roles 38 38 } 39 - if err := c.LexDo(ctx, util.Query, "", "tools.ozone.team.listMembers", params, nil, &out); err != nil { 39 + if err := c.LexDo(ctx, lexutil.Query, "", "tools.ozone.team.listMembers", params, nil, &out); err != nil { 40 40 return nil, err 41 41 } 42 42
+3 -3
api/ozone/teamupdateMember.go
··· 7 7 import ( 8 8 "context" 9 9 10 - "github.com/bluesky-social/indigo/lex/util" 10 + lexutil "github.com/bluesky-social/indigo/lex/util" 11 11 ) 12 12 13 13 // TeamUpdateMember_Input is the input argument to a tools.ozone.team.updateMember call. ··· 18 18 } 19 19 20 20 // TeamUpdateMember calls the XRPC method "tools.ozone.team.updateMember". 21 - func TeamUpdateMember(ctx context.Context, c util.LexClient, input *TeamUpdateMember_Input) (*TeamDefs_Member, error) { 21 + func TeamUpdateMember(ctx context.Context, c lexutil.LexClient, input *TeamUpdateMember_Input) (*TeamDefs_Member, error) { 22 22 var out TeamDefs_Member 23 - if err := c.LexDo(ctx, util.Procedure, "application/json", "tools.ozone.team.updateMember", nil, input, &out); err != nil { 23 + if err := c.LexDo(ctx, lexutil.Procedure, "application/json", "tools.ozone.team.updateMember", nil, input, &out); err != nil { 24 24 return nil, err 25 25 } 26 26
+5 -7
api/ozone/verificationdefs.go
··· 8 8 "encoding/json" 9 9 "fmt" 10 10 11 - "github.com/bluesky-social/indigo/lex/util" 11 + lexutil "github.com/bluesky-social/indigo/lex/util" 12 12 ) 13 13 14 14 // VerificationDefs_VerificationView is a "verificationView" in the tools.ozone.verification.defs schema. ··· 23 23 Handle string `json:"handle" cborgen:"handle"` 24 24 // issuer: The user who issued this verification. 25 25 Issuer string `json:"issuer" cborgen:"issuer"` 26 - IssuerProfile *util.LexiconTypeDecoder `json:"issuerProfile,omitempty" cborgen:"issuerProfile,omitempty"` 26 + IssuerProfile *lexutil.LexiconTypeDecoder `json:"issuerProfile,omitempty" cborgen:"issuerProfile,omitempty"` 27 27 IssuerRepo *VerificationDefs_VerificationView_IssuerRepo `json:"issuerRepo,omitempty" cborgen:"issuerRepo,omitempty"` 28 28 // revokeReason: Describes the reason for revocation, also indicating that the verification is no longer valid. 29 29 RevokeReason *string `json:"revokeReason,omitempty" cborgen:"revokeReason,omitempty"` ··· 33 33 RevokedBy *string `json:"revokedBy,omitempty" cborgen:"revokedBy,omitempty"` 34 34 // subject: The subject of the verification. 35 35 Subject string `json:"subject" cborgen:"subject"` 36 - SubjectProfile *util.LexiconTypeDecoder `json:"subjectProfile,omitempty" cborgen:"subjectProfile,omitempty"` 36 + SubjectProfile *lexutil.LexiconTypeDecoder `json:"subjectProfile,omitempty" cborgen:"subjectProfile,omitempty"` 37 37 SubjectRepo *VerificationDefs_VerificationView_SubjectRepo `json:"subjectRepo,omitempty" cborgen:"subjectRepo,omitempty"` 38 38 // uri: The AT-URI of the verification record. 39 39 Uri string `json:"uri" cborgen:"uri"` ··· 57 57 } 58 58 59 59 func (t *VerificationDefs_VerificationView_IssuerRepo) UnmarshalJSON(b []byte) error { 60 - typ, err := util.TypeExtract(b) 60 + typ, err := lexutil.TypeExtract(b) 61 61 if err != nil { 62 62 return err 63 63 } ··· 69 69 case "tools.ozone.moderation.defs#repoViewNotFound": 70 70 t.ModerationDefs_RepoViewNotFound = new(ModerationDefs_RepoViewNotFound) 71 71 return json.Unmarshal(b, t.ModerationDefs_RepoViewNotFound) 72 - 73 72 default: 74 73 return nil 75 74 } ··· 93 92 } 94 93 95 94 func (t *VerificationDefs_VerificationView_SubjectRepo) UnmarshalJSON(b []byte) error { 96 - typ, err := util.TypeExtract(b) 95 + typ, err := lexutil.TypeExtract(b) 97 96 if err != nil { 98 97 return err 99 98 } ··· 105 104 case "tools.ozone.moderation.defs#repoViewNotFound": 106 105 t.ModerationDefs_RepoViewNotFound = new(ModerationDefs_RepoViewNotFound) 107 106 return json.Unmarshal(b, t.ModerationDefs_RepoViewNotFound) 108 - 109 107 default: 110 108 return nil 111 109 }
+3 -3
api/ozone/verificationgrantVerifications.go
··· 7 7 import ( 8 8 "context" 9 9 10 - "github.com/bluesky-social/indigo/lex/util" 10 + lexutil "github.com/bluesky-social/indigo/lex/util" 11 11 ) 12 12 13 13 // VerificationGrantVerifications_GrantError is a "grantError" in the tools.ozone.verification.grantVerifications schema. ··· 45 45 } 46 46 47 47 // VerificationGrantVerifications calls the XRPC method "tools.ozone.verification.grantVerifications". 48 - func VerificationGrantVerifications(ctx context.Context, c util.LexClient, input *VerificationGrantVerifications_Input) (*VerificationGrantVerifications_Output, error) { 48 + func VerificationGrantVerifications(ctx context.Context, c lexutil.LexClient, input *VerificationGrantVerifications_Input) (*VerificationGrantVerifications_Output, error) { 49 49 var out VerificationGrantVerifications_Output 50 - if err := c.LexDo(ctx, util.Procedure, "application/json", "tools.ozone.verification.grantVerifications", nil, input, &out); err != nil { 50 + if err := c.LexDo(ctx, lexutil.Procedure, "application/json", "tools.ozone.verification.grantVerifications", nil, input, &out); err != nil { 51 51 return nil, err 52 52 } 53 53
+3 -3
api/ozone/verificationlistVerifications.go
··· 7 7 import ( 8 8 "context" 9 9 10 - "github.com/bluesky-social/indigo/lex/util" 10 + lexutil "github.com/bluesky-social/indigo/lex/util" 11 11 ) 12 12 13 13 // VerificationListVerifications_Output is the output of a tools.ozone.verification.listVerifications call. ··· 26 26 // limit: Maximum number of results to return 27 27 // sortDirection: Sort direction for creation date 28 28 // subjects: Filter to specific verified DIDs 29 - func VerificationListVerifications(ctx context.Context, c util.LexClient, createdAfter string, createdBefore string, cursor string, isRevoked bool, issuers []string, limit int64, sortDirection string, subjects []string) (*VerificationListVerifications_Output, error) { 29 + func VerificationListVerifications(ctx context.Context, c lexutil.LexClient, createdAfter string, createdBefore string, cursor string, isRevoked bool, issuers []string, limit int64, sortDirection string, subjects []string) (*VerificationListVerifications_Output, error) { 30 30 var out VerificationListVerifications_Output 31 31 32 32 params := map[string]interface{}{} ··· 54 54 if len(subjects) != 0 { 55 55 params["subjects"] = subjects 56 56 } 57 - if err := c.LexDo(ctx, util.Query, "", "tools.ozone.verification.listVerifications", params, nil, &out); err != nil { 57 + if err := c.LexDo(ctx, lexutil.Query, "", "tools.ozone.verification.listVerifications", params, nil, &out); err != nil { 58 58 return nil, err 59 59 } 60 60
+3 -3
api/ozone/verificationrevokeVerifications.go
··· 7 7 import ( 8 8 "context" 9 9 10 - "github.com/bluesky-social/indigo/lex/util" 10 + lexutil "github.com/bluesky-social/indigo/lex/util" 11 11 ) 12 12 13 13 // VerificationRevokeVerifications_Input is the input argument to a tools.ozone.verification.revokeVerifications call. ··· 37 37 } 38 38 39 39 // VerificationRevokeVerifications calls the XRPC method "tools.ozone.verification.revokeVerifications". 40 - func VerificationRevokeVerifications(ctx context.Context, c util.LexClient, input *VerificationRevokeVerifications_Input) (*VerificationRevokeVerifications_Output, error) { 40 + func VerificationRevokeVerifications(ctx context.Context, c lexutil.LexClient, input *VerificationRevokeVerifications_Input) (*VerificationRevokeVerifications_Output, error) { 41 41 var out VerificationRevokeVerifications_Output 42 - if err := c.LexDo(ctx, util.Procedure, "application/json", "tools.ozone.verification.revokeVerifications", nil, input, &out); err != nil { 42 + if err := c.LexDo(ctx, lexutil.Procedure, "application/json", "tools.ozone.verification.revokeVerifications", nil, input, &out); err != nil { 43 43 return nil, err 44 44 } 45 45
+3 -3
lex/gen.go
··· 135 135 pf("\t\"fmt\"\n") 136 136 pf("\t\"encoding/json\"\n") 137 137 pf("\tcbg \"github.com/whyrusleeping/cbor-gen\"\n") 138 - pf("\t\"github.com/bluesky-social/indigo/lex/util\"\n") 138 + pf("\tlexutil \"github.com/bluesky-social/indigo/lex/util\"\n") 139 139 for _, xpkg := range packages { 140 140 if xpkg.Prefix != pkg.Prefix { 141 141 pf("\t%s %q\n", importNameForPrefix(xpkg.Prefix), xpkg.Import) ··· 190 190 if buf.Len() == 0 { 191 191 outf("func init() {\n") 192 192 } 193 - outf("util.RegisterType(%q, &%s{})\n", id, t.Name) 193 + outf("lexutil.RegisterType(%q, &%s{})\n", id, t.Name) 194 194 } 195 195 } 196 196 if buf.Len() == 0 { ··· 308 308 } 309 309 310 310 func importNameForPrefix(prefix string) string { 311 - return strings.Join(strings.Split(prefix, "."), "") + "types" 311 + return strings.Join(strings.Split(prefix, "."), "") 312 312 } 313 313 314 314 func WriteServerHandlers(w io.Writer, schemas []*Schema, pkg string, impmap map[string]string) error {
+17 -22
lex/type_schema.go
··· 55 55 pf := printerf(w) 56 56 fname := typename 57 57 58 - params := "ctx context.Context, c util.LexClient" 58 + params := "ctx context.Context, c lexutil.LexClient" 59 59 inpvar := "nil" 60 60 inpenc := "" 61 61 ··· 67 67 params = fmt.Sprintf("%s, input io.Reader", params) 68 68 case EncodingJSON: 69 69 params = fmt.Sprintf("%s, input *%s", params, inputname) 70 - 71 70 default: 72 71 return fmt.Errorf("unsupported input encoding (RPC input): %q", s.Input.Encoding) 73 72 } ··· 174 173 var reqtype string 175 174 switch s.Type { 176 175 case "procedure": 177 - reqtype = "util.Procedure" 176 + reqtype = "lexutil.Procedure" 178 177 case "query": 179 - reqtype = "util.Query" 178 + reqtype = "lexutil.Query" 180 179 default: 181 180 return fmt.Errorf("can only generate RPC for Query or Procedure (got %s)", s.Type) 182 181 } ··· 555 554 if k == "didDoc" || k == "plcOp" || k == "meta" { 556 555 return "interface{}", nil 557 556 } else { 558 - return "*util.LexiconTypeDecoder", nil 557 + return "*lexutil.LexiconTypeDecoder", nil 559 558 } 560 559 case "union": 561 560 if len(v.Refs) > 0 { 562 561 return "*" + name + "_" + strings.Title(k), nil 563 562 } else { 564 563 // an empty union is effectively an 'unknown', but with mandatory type indicator 565 - return "*util.LexiconTypeDecoder", nil 564 + return "*lexutil.LexiconTypeDecoder", nil 566 565 } 567 566 case "blob": 568 - return "*util.LexBlob", nil 567 + return "*lexutil.LexBlob", nil 569 568 case "array": 570 569 subt, err := s.typeNameForField(name+"_"+strings.Title(k), "Elem", *v.Items) 571 570 if err != nil { ··· 574 573 575 574 return "[]" + subt, nil 576 575 case "cid-link": 577 - return "util.LexLink", nil 576 + return "lexutil.LexLink", nil 578 577 case "bytes": 579 - return "util.LexBytes", nil 578 + return "lexutil.LexBytes", nil 580 579 default: 581 580 return "", fmt.Errorf("field %q in %s has unsupported type name (%s)", k, name, v.Type) 582 581 } ··· 692 691 jsonOmit, cborOmit := omit, omit 693 692 694 693 // Don't generate pointers to lexbytes, as it's already a pointer. 695 - if ptr == "*" && tname == "util.LexBytes" { 694 + if ptr == "*" && tname == "lexutil.LexBytes" { 696 695 ptr = "" 697 696 } 698 697 699 698 // TODO: hard-coded hacks for now, making this type (with underlying type []byte) 700 699 // be omitempty. 701 - if ptr == "" && tname == "util.LexBytes" { 700 + if ptr == "" && tname == "lexutil.LexBytes" { 702 701 jsonOmit = ",omitempty" 703 702 cborOmit = ",omitempty" 704 703 } ··· 827 826 func (ts *TypeSchema) writeJsonUnmarshalerEnum(name string, w io.Writer) error { 828 827 pf := printerf(w) 829 828 pf("func (t *%s) UnmarshalJSON(b []byte) (error) {\n", name) 830 - pf("\ttyp, err := util.TypeExtract(b)\n") 829 + pf("\ttyp, err := lexutil.TypeExtract(b)\n") 831 830 pf("\tif err != nil {\n\t\treturn err\n\t}\n\n") 832 831 pf("\tswitch typ {\n") 833 832 for _, e := range ts.Refs { ··· 843 842 } 844 843 845 844 if ts.Closed { 846 - pf(` 847 - default: 845 + pf(` default: 848 846 return fmt.Errorf("closed unions must match a listed schema") 849 847 `) 850 848 } else { 851 - pf(` 852 - default: 849 + pf(` default: 853 850 return nil 854 851 `) 855 852 ··· 877 874 pf("\t\treturn t.%s.MarshalCBOR(w)\n\t}\n", vname) 878 875 } 879 876 880 - pf("\treturn fmt.Errorf(\"can not marshal empty union as CBOR\")\n}\n") 877 + pf("\treturn fmt.Errorf(\"can not marshal empty union as CBOR\")\n}\n\n") 881 878 return nil 882 879 } 883 880 884 881 func (ts *TypeSchema) writeCborUnmarshalerEnum(name string, w io.Writer) error { 885 882 pf := printerf(w) 886 883 pf("func (t *%s) UnmarshalCBOR(r io.Reader) error {\n", name) 887 - pf("\ttyp, b, err := util.CborTypeExtractReader(r)\n") 884 + pf("\ttyp, b, err := lexutil.CborTypeExtractReader(r)\n") 888 885 pf("\tif err != nil {\n\t\treturn err\n\t}\n\n") 889 886 pf("\tswitch typ {\n") 890 887 for _, e := range ts.Refs { ··· 900 897 } 901 898 902 899 if ts.Closed { 903 - pf(` 904 - default: 900 + pf(` default: 905 901 return fmt.Errorf("closed unions must match a listed schema") 906 902 `) 907 903 } else { 908 - pf(` 909 - default: 904 + pf(` default: 910 905 return nil 911 906 `) 912 907