Documentation ¶
Index ¶
- func ProtoDeterministicChecksum(m proto.Message) ([32]byte, error)
- type GRPCConfig
- type GRPCServer
- func (s GRPCServer) Get(ctx context.Context, msg *pb.GetRequest) (*pb.GetResponse, error)
- func (s GRPCServer) GetMetadataHistory(ctx context.Context, msg *pb.GetMetadataHistoryRequest) (*pb.GetMetadataHistoryResponse, error)
- func (s GRPCServer) GetPublicKey(ctx context.Context, msg *pb.GetPublicKeyRequest) (*pb.GetPublicKeyResponse, error)
- func (s GRPCServer) Register(ctx context.Context, msg *pb.RegisterRequest) (*pb.RegisterResponse, error)
- func (s GRPCServer) RegisterAccount(ctx context.Context, msg *pb.RegisterAccountRequest) (*pb.RegisterAccountResponse, error)
- func (s GRPCServer) SaveMetadata(ctx context.Context, msg *pb.SaveMetadataRequest) (*pb.SaveMetadataResponse, error)
- func (s GRPCServer) SaveVerificationMethods(ctx context.Context, msg *pb.MsgSaveVerificationMethods) (*pb.SaveVerificationMethodsResponse, error)
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
Types ¶
type GRPCConfig ¶
type GRPCConfig struct { Shutdown chan os.Signal Log *zap.SugaredLogger // Services DIDDocService diddoc.DIDDoc AccountService account.Account }
GRPCConfig defines the dependencies for the gRPC server
type GRPCServer ¶
type GRPCServer struct { pbdidoc.UnimplementedDIDDocServer pbacc.UnimplementedAccountServer Log *zap.SugaredLogger // Services DIDDocService diddoc.DIDDoc AccountService account.Account }
GRPCServer implements server gRPC calls for the DID registry.
func NewGRPCServer ¶
func NewGRPCServer(cfg GRPCConfig) (*grpc.Server, *GRPCServer)
NewGRPCServer creates a new grpc server
func (GRPCServer) Get ¶
func (s GRPCServer) Get(ctx context.Context, msg *pb.GetRequest) (*pb.GetResponse, error)
Get DID document from the registry
func (GRPCServer) GetMetadataHistory ¶
func (s GRPCServer) GetMetadataHistory(ctx context.Context, msg *pb.GetMetadataHistoryRequest) (*pb.GetMetadataHistoryResponse, error)
GetMetadataHistory returns historical records of metadata changes
func (GRPCServer) GetPublicKey ¶
func (s GRPCServer) GetPublicKey(ctx context.Context, msg *pb.GetPublicKeyRequest) (*pb.GetPublicKeyResponse, error)
GetPublicKey returns a public key for registry account
func (GRPCServer) Register ¶
func (s GRPCServer) Register(ctx context.Context, msg *pb.RegisterRequest) (*pb.RegisterResponse, error)
Register DID in the registry
func (GRPCServer) RegisterAccount ¶
func (s GRPCServer) RegisterAccount(ctx context.Context, msg *pb.RegisterAccountRequest) (*pb.RegisterAccountResponse, error)
RegisterAccount registers a new account in a registry
func (GRPCServer) SaveMetadata ¶
func (s GRPCServer) SaveMetadata(ctx context.Context, msg *pb.SaveMetadataRequest) (*pb.SaveMetadataResponse, error)
SaveMetadata updates metadata for DID
func (GRPCServer) SaveVerificationMethods ¶
func (s GRPCServer) SaveVerificationMethods(ctx context.Context, msg *pb.MsgSaveVerificationMethods) (*pb.SaveVerificationMethodsResponse, error)
SaveVerificationMethods saves verification methods for DID
Directories ¶
Path | Synopsis |
---|---|
pb
|
|
v1/account
Package account is a reverse proxy.
|
Package account is a reverse proxy. |
v1/diddoc
Package diddoc is a reverse proxy.
|
Package diddoc is a reverse proxy. |
Click to show internal directories.
Click to hide internal directories.