/
githubmirror
/
client
Обзор
Документация
Войти
/
githubmirror
/
client
Код
Запросы
0
Пакеты
0
Релизы
0
Аналитика
Безопасность
master
go/protocol/gregor1/auth_update.go
52 строки
1 KB
chrisnojima-zoom
Version 670 - clean2 (#29122)
08 июн 2026, 19:31
Не верифицирован
08 июн 2026, 19:31
1943197
Код
Авторство
О чём код?
// Code generated to Go types and interfaces using avdl-compiler v1.4.10 (https://github.com/keybase/node-avdl-compiler). DO NOT EDIT. // Input file: avdl/gregor1/auth_update.avdl package gregor1 import ( "context" "time" "github.com/keybase/go-framed-msgpack-rpc/rpc" ) type RevokeSessionIDsArg struct { SessionIDs []SessionID `codec:"sessionIDs" json:"sessionIDs"` } type AuthUpdateInterface interface { RevokeSessionIDs(context.Context, []SessionID) error } func AuthUpdateProtocol(i AuthUpdateInterface) rpc.Protocol { return rpc.Protocol{ Name: "gregor.1.authUpdate", Methods: map[string]rpc.ServeHandlerDescription{ "revokeSessionIDs": { MakeArg: func() any { var ret [1]RevokeSessionIDsArg return &ret }, Handler: func(ctx context.Context, args any) (ret any, err error) { typedArgs, ok := args.(*[1]RevokeSessionIDsArg) if !ok { err = rpc.NewTypeError((*[1]RevokeSessionIDsArg)(nil), args) return } err = i.RevokeSessionIDs(ctx, typedArgs[0].SessionIDs) return }, }, }, } } type AuthUpdateClient struct { Cli rpc.GenericClient } func (c AuthUpdateClient) RevokeSessionIDs(ctx context.Context, sessionIDs []SessionID) (err error) { __arg := RevokeSessionIDsArg{SessionIDs: sessionIDs} err = c.Cli.Call(ctx, "gregor.1.authUpdate.revokeSessionIDs", []any{__arg}, nil, 0*time.Millisecond) return }