v1

package
v1.0.8 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Sep 25, 2023 License: Apache-2.0 Imports: 22 Imported by: 1

Documentation

Overview

Package v1 is a reverse proxy.

It translates gRPC into RESTful JSON APIs.

Index

Constants

This section is empty.

Variables

View Source
var File_coinbase_cloud_mpc_wallets_v1_mpc_wallets_proto protoreflect.FileDescriptor
View Source
var MPCWalletService_ServiceDesc = grpc.ServiceDesc{
	ServiceName: "coinbase.cloud.mpc_wallets.v1.MPCWalletService",
	HandlerType: (*MPCWalletServiceServer)(nil),
	Methods: []grpc.MethodDesc{
		{
			MethodName: "CreateMPCWallet",
			Handler:    _MPCWalletService_CreateMPCWallet_Handler,
		},
		{
			MethodName: "GetMPCWallet",
			Handler:    _MPCWalletService_GetMPCWallet_Handler,
		},
		{
			MethodName: "ListMPCWallets",
			Handler:    _MPCWalletService_ListMPCWallets_Handler,
		},
		{
			MethodName: "GenerateAddress",
			Handler:    _MPCWalletService_GenerateAddress_Handler,
		},
		{
			MethodName: "GetAddress",
			Handler:    _MPCWalletService_GetAddress_Handler,
		},
		{
			MethodName: "ListAddresses",
			Handler:    _MPCWalletService_ListAddresses_Handler,
		},
		{
			MethodName: "ListBalances",
			Handler:    _MPCWalletService_ListBalances_Handler,
		},
		{
			MethodName: "ListBalanceDetails",
			Handler:    _MPCWalletService_ListBalanceDetails_Handler,
		},
	},
	Streams:  []grpc.StreamDesc{},
	Metadata: "coinbase/cloud/mpc_wallets/v1/mpc_wallets.proto",
}

MPCWalletService_ServiceDesc is the grpc.ServiceDesc for MPCWalletService service. It's only intended for direct use with grpc.RegisterService, and not to be introspected or modified (even as a copy)

Functions

func RegisterMPCWalletServiceHandler

func RegisterMPCWalletServiceHandler(ctx context.Context, mux *runtime.ServeMux, conn *grpc.ClientConn) error

RegisterMPCWalletServiceHandler registers the http handlers for service MPCWalletService to "mux". The handlers forward requests to the grpc endpoint over "conn".

func RegisterMPCWalletServiceHandlerClient

func RegisterMPCWalletServiceHandlerClient(ctx context.Context, mux *runtime.ServeMux, client MPCWalletServiceClient) error

RegisterMPCWalletServiceHandlerClient registers the http handlers for service MPCWalletService to "mux". The handlers forward requests to the grpc endpoint over the given implementation of "MPCWalletServiceClient". Note: the gRPC framework executes interceptors within the gRPC handler. If the passed in "MPCWalletServiceClient" doesn't go through the normal gRPC flow (creating a gRPC client etc.) then it will be up to the passed in "MPCWalletServiceClient" to call the correct interceptors.

func RegisterMPCWalletServiceHandlerFromEndpoint

func RegisterMPCWalletServiceHandlerFromEndpoint(ctx context.Context, mux *runtime.ServeMux, endpoint string, opts []grpc.DialOption) (err error)

RegisterMPCWalletServiceHandlerFromEndpoint is same as RegisterMPCWalletServiceHandler but automatically dials to "endpoint" and closes the connection when "ctx" gets done.

func RegisterMPCWalletServiceHandlerServer

func RegisterMPCWalletServiceHandlerServer(ctx context.Context, mux *runtime.ServeMux, server MPCWalletServiceServer) error

RegisterMPCWalletServiceHandlerServer registers the http handlers for service MPCWalletService to "mux". UnaryRPC :call MPCWalletServiceServer directly. StreamingRPC :currently unsupported pending https://github.com/grpc/grpc-go/issues/906. Note that using this registration option will cause many gRPC library features to stop working. Consider using RegisterMPCWalletServiceHandlerFromEndpoint instead.

func RegisterMPCWalletServiceServer

func RegisterMPCWalletServiceServer(s grpc.ServiceRegistrar, srv MPCWalletServiceServer)

Types

type Address

type Address struct {

	// The resource name of the Address. The resource ID of the Address is
	// equal to the address field.
	// Format: networks/{network_id}/addresses/{address_id}
	Name string `protobuf:"bytes,1,opt,name=name,proto3" json:"name,omitempty"`
	// The address value - for example, a 0x-prefixed checksummed hexadecimal string.
	// This is equal to the resource ID of the Address.
	Address string `protobuf:"bytes,2,opt,name=address,proto3" json:"address,omitempty"`
	// The resource names of the MPCKeys that back this Address.
	// For EVM networks, there will be only one MPCKey.
	// Format: pools/{pool_id}/deviceGroups/{device_group_id}/mpcKeys/{mpc_key_id}
	MpcKeys []string `protobuf:"bytes,3,rep,name=mpc_keys,json=mpcKeys,proto3" json:"mpc_keys,omitempty"`
	// The resource name of the MPCWallet to which this Address belongs.
	// Format: pools/{pool}/mpcWallets/{mpcWallet}
	MpcWallet string `protobuf:"bytes,4,opt,name=mpc_wallet,json=mpcWallet,proto3" json:"mpc_wallet,omitempty"`
	// contains filtered or unexported fields
}

The Address resource, which represents an on-chain Address backed by an MPCKey in an MPCWallet.

func (*Address) Descriptor deprecated

func (*Address) Descriptor() ([]byte, []int)

Deprecated: Use Address.ProtoReflect.Descriptor instead.

func (*Address) GetAddress

func (x *Address) GetAddress() string

func (*Address) GetMpcKeys

func (x *Address) GetMpcKeys() []string

func (*Address) GetMpcWallet

func (x *Address) GetMpcWallet() string

func (*Address) GetName

func (x *Address) GetName() string

func (*Address) ProtoMessage

func (*Address) ProtoMessage()

func (*Address) ProtoReflect

func (x *Address) ProtoReflect() protoreflect.Message

func (*Address) Reset

func (x *Address) Reset()

func (*Address) String

func (x *Address) String() string

type AddressResourceName

type AddressResourceName struct {
	NetworkId string
	AddressId string
}

func (AddressResourceName) BalanceDetailResourceName

func (n AddressResourceName) BalanceDetailResourceName(
	balanceId string,
	balanceDetailId string,
) BalanceDetailResourceName

func (AddressResourceName) BalanceResourceName

func (n AddressResourceName) BalanceResourceName(
	balanceId string,
) BalanceResourceName

func (AddressResourceName) ContainsWildcard

func (n AddressResourceName) ContainsWildcard() bool

func (AddressResourceName) MarshalString

func (n AddressResourceName) MarshalString() (string, error)

func (AddressResourceName) String

func (n AddressResourceName) String() string

func (*AddressResourceName) UnmarshalString

func (n *AddressResourceName) UnmarshalString(name string) error

func (AddressResourceName) Validate

func (n AddressResourceName) Validate() error

type Balance

type Balance struct {

	// The resource name of the Balance.
	// Format: networks/{network_id}/addresses/{address_id}/balances/{balance_id}
	Name string `protobuf:"bytes,1,opt,name=name,proto3" json:"name,omitempty"`
	// The resource name of the Asset to which this Balance corresponds.
	// Format: networks/{network}/assets/{asset}
	Asset string `protobuf:"bytes,2,opt,name=asset,proto3" json:"asset,omitempty"`
	// The amount of the asset. For native assets or ERC-20 contracts, this is presented in terms of
	// atomic units (e.g., Wei for Ether) as a base-10 number. For ERC-721 and ERC-1155 contracts, it
	// is the count of distinct token IDs held by address.
	Amount string `protobuf:"bytes,3,opt,name=amount,proto3" json:"amount,omitempty"`
	// The resource name of the MPCWallet to which this Balance belongs.
	// Format: pools/{pool}/mpcWallets/{mpcWallet}
	MpcWallet string `protobuf:"bytes,4,opt,name=mpc_wallet,json=mpcWallet,proto3" json:"mpc_wallet,omitempty"`
	// contains filtered or unexported fields
}

The Balance resource, which represents an amount of an Asset held on-chain by an Address.

func (*Balance) Descriptor deprecated

func (*Balance) Descriptor() ([]byte, []int)

Deprecated: Use Balance.ProtoReflect.Descriptor instead.

func (*Balance) GetAmount

func (x *Balance) GetAmount() string

func (*Balance) GetAsset

func (x *Balance) GetAsset() string

func (*Balance) GetMpcWallet

func (x *Balance) GetMpcWallet() string

func (*Balance) GetName

func (x *Balance) GetName() string

func (*Balance) ProtoMessage

func (*Balance) ProtoMessage()

func (*Balance) ProtoReflect

func (x *Balance) ProtoReflect() protoreflect.Message

func (*Balance) Reset

func (x *Balance) Reset()

func (*Balance) String

func (x *Balance) String() string

type BalanceDetail

type BalanceDetail struct {

	// The resource name of the BalanceDetail.
	// Format: networks/{network_id}/addresses/{address_id}/balances/{balance_id}/balanceDetails/{balance_detail_id}
	Name string `protobuf:"bytes,1,opt,name=name,proto3" json:"name,omitempty"`
	// The resource name of the Asset to which the parent Balance corresponds.
	// Format: networks/{network}/assets/{asset}
	Asset string `protobuf:"bytes,2,opt,name=asset,proto3" json:"asset,omitempty"`
	// The amount of the BalanceDetail as a base-10 number.
	// For a BalanceDetail for a native Balance or ERC-20 Balance, this is denominated in atomic units of the asset.
	Amount string `protobuf:"bytes,3,opt,name=amount,proto3" json:"amount,omitempty"`
	// The asset definition which can be used to identify what token the amount corresponds to.
	//
	// A BalanceDetail for a native Balance will only have the asset_type field set ("native").
	// A BalanceDetail for an ERC-20 Balance will only have the asset_type ("erc20") and asset_group_id (contract address) fields set.
	// A BalanceDetail for an ERC-721 Balance or ERC-1155 Balance will have the asset_type ("erc721" or "erc1155"),
	// asset_group_id (contract address), and sub_group_id (token ID) fields set.
	AssetDefinition *v1.Asset_Definition `protobuf:"bytes,4,opt,name=asset_definition,json=assetDefinition,proto3" json:"asset_definition,omitempty"`
	// The resource name of the MPCWallet to which the parent Balance belongs.
	// Format: pools/{pool}/mpcWallets/{mpcWallet}
	MpcWallet string `protobuf:"bytes,5,opt,name=mpc_wallet,json=mpcWallet,proto3" json:"mpc_wallet,omitempty"`
	// contains filtered or unexported fields
}

The BalanceDetail resource, which enumerates the specific tokens held which compose a Balance.

func (*BalanceDetail) Descriptor deprecated

func (*BalanceDetail) Descriptor() ([]byte, []int)

Deprecated: Use BalanceDetail.ProtoReflect.Descriptor instead.

func (*BalanceDetail) GetAmount

func (x *BalanceDetail) GetAmount() string

func (*BalanceDetail) GetAsset

func (x *BalanceDetail) GetAsset() string

func (*BalanceDetail) GetAssetDefinition

func (x *BalanceDetail) GetAssetDefinition() *v1.Asset_Definition

func (*BalanceDetail) GetMpcWallet

func (x *BalanceDetail) GetMpcWallet() string

func (*BalanceDetail) GetName

func (x *BalanceDetail) GetName() string

func (*BalanceDetail) ProtoMessage

func (*BalanceDetail) ProtoMessage()

func (*BalanceDetail) ProtoReflect

func (x *BalanceDetail) ProtoReflect() protoreflect.Message

func (*BalanceDetail) Reset

func (x *BalanceDetail) Reset()

func (*BalanceDetail) String

func (x *BalanceDetail) String() string

type BalanceDetailResourceName

type BalanceDetailResourceName struct {
	NetworkId       string
	AddressId       string
	BalanceId       string
	BalanceDetailId string
}

func (BalanceDetailResourceName) AddressResourceName

func (n BalanceDetailResourceName) AddressResourceName() AddressResourceName

func (BalanceDetailResourceName) BalanceResourceName

func (n BalanceDetailResourceName) BalanceResourceName() BalanceResourceName

func (BalanceDetailResourceName) ContainsWildcard

func (n BalanceDetailResourceName) ContainsWildcard() bool

func (BalanceDetailResourceName) MarshalString

func (n BalanceDetailResourceName) MarshalString() (string, error)

func (BalanceDetailResourceName) String

func (n BalanceDetailResourceName) String() string

func (*BalanceDetailResourceName) UnmarshalString

func (n *BalanceDetailResourceName) UnmarshalString(name string) error

func (BalanceDetailResourceName) Validate

func (n BalanceDetailResourceName) Validate() error

type BalanceResourceName

type BalanceResourceName struct {
	NetworkId string
	AddressId string
	BalanceId string
}

func (BalanceResourceName) AddressResourceName

func (n BalanceResourceName) AddressResourceName() AddressResourceName

func (BalanceResourceName) BalanceDetailResourceName

func (n BalanceResourceName) BalanceDetailResourceName(
	balanceDetailId string,
) BalanceDetailResourceName

func (BalanceResourceName) ContainsWildcard

func (n BalanceResourceName) ContainsWildcard() bool

func (BalanceResourceName) MarshalString

func (n BalanceResourceName) MarshalString() (string, error)

func (BalanceResourceName) String

func (n BalanceResourceName) String() string

func (*BalanceResourceName) UnmarshalString

func (n *BalanceResourceName) UnmarshalString(name string) error

func (BalanceResourceName) Validate

func (n BalanceResourceName) Validate() error

type CreateMPCWalletMetadata

type CreateMPCWalletMetadata struct {

	// The resource name of the DeviceGroup to poll for using ListMPCOperations.
	// Format: pools/{pool_id}/deviceGroups/{device_group_id}
	DeviceGroup string `protobuf:"bytes,1,opt,name=device_group,json=deviceGroup,proto3" json:"device_group,omitempty"`
	// contains filtered or unexported fields
}

Metadata associated with the CreateMPCWallet long-running operation.

func (*CreateMPCWalletMetadata) Descriptor deprecated

func (*CreateMPCWalletMetadata) Descriptor() ([]byte, []int)

Deprecated: Use CreateMPCWalletMetadata.ProtoReflect.Descriptor instead.

func (*CreateMPCWalletMetadata) GetDeviceGroup

func (x *CreateMPCWalletMetadata) GetDeviceGroup() string

func (*CreateMPCWalletMetadata) ProtoMessage

func (*CreateMPCWalletMetadata) ProtoMessage()

func (*CreateMPCWalletMetadata) ProtoReflect

func (x *CreateMPCWalletMetadata) ProtoReflect() protoreflect.Message

func (*CreateMPCWalletMetadata) Reset

func (x *CreateMPCWalletMetadata) Reset()

func (*CreateMPCWalletMetadata) String

func (x *CreateMPCWalletMetadata) String() string

type CreateMPCWalletRequest

type CreateMPCWalletRequest struct {

	// The resource name of the parent Pool.
	// Format: pools/{pool_id}
	Parent string `protobuf:"bytes,1,opt,name=parent,proto3" json:"parent,omitempty"`
	// The MPCWallet to be created. This should be blank.
	MpcWallet *MPCWallet `protobuf:"bytes,2,opt,name=mpc_wallet,json=mpcWallet,proto3" json:"mpc_wallet,omitempty"`
	// The resource name of the Device that will initially be the sole member of the underlying
	// DeviceGroup. This Device should have already been registered using MPCKeyService's
	// RegisterDevice.
	// Format: devices/{device_id}
	Device string `protobuf:"bytes,3,opt,name=device,proto3" json:"device,omitempty"`
	// A user-provided request ID to allow for idempotency. This should be a UUID.
	RequestId string `protobuf:"bytes,4,opt,name=request_id,json=requestId,proto3" json:"request_id,omitempty"`
	// contains filtered or unexported fields
}

The request message for CreateMPCWallet.

func (*CreateMPCWalletRequest) Descriptor deprecated

func (*CreateMPCWalletRequest) Descriptor() ([]byte, []int)

Deprecated: Use CreateMPCWalletRequest.ProtoReflect.Descriptor instead.

func (*CreateMPCWalletRequest) GetDevice

func (x *CreateMPCWalletRequest) GetDevice() string

func (*CreateMPCWalletRequest) GetMpcWallet

func (x *CreateMPCWalletRequest) GetMpcWallet() *MPCWallet

func (*CreateMPCWalletRequest) GetParent

func (x *CreateMPCWalletRequest) GetParent() string

func (*CreateMPCWalletRequest) GetRequestId

func (x *CreateMPCWalletRequest) GetRequestId() string

func (*CreateMPCWalletRequest) ProtoMessage

func (*CreateMPCWalletRequest) ProtoMessage()

func (*CreateMPCWalletRequest) ProtoReflect

func (x *CreateMPCWalletRequest) ProtoReflect() protoreflect.Message

func (*CreateMPCWalletRequest) Reset

func (x *CreateMPCWalletRequest) Reset()

func (*CreateMPCWalletRequest) String

func (x *CreateMPCWalletRequest) String() string

type GenerateAddressRequest

type GenerateAddressRequest struct {

	// The resource name of the MPCWallet within which to generate the Address.
	// Format: pools/{pool_id}/mpcWallets/{mpc_wallet_id}
	MpcWallet string `protobuf:"bytes,1,opt,name=mpc_wallet,json=mpcWallet,proto3" json:"mpc_wallet,omitempty"`
	// The resource name of the Network for which to generate the Address.
	// Format: networks/{network_id}
	Network string `protobuf:"bytes,2,opt,name=network,proto3" json:"network,omitempty"`
	// A user-provided request ID to allow for idempotency. This should be a UUID.
	RequestId string `protobuf:"bytes,3,opt,name=request_id,json=requestId,proto3" json:"request_id,omitempty"`
	// contains filtered or unexported fields
}

The request message for GenerateAddress.

func (*GenerateAddressRequest) Descriptor deprecated

func (*GenerateAddressRequest) Descriptor() ([]byte, []int)

Deprecated: Use GenerateAddressRequest.ProtoReflect.Descriptor instead.

func (*GenerateAddressRequest) GetMpcWallet

func (x *GenerateAddressRequest) GetMpcWallet() string

func (*GenerateAddressRequest) GetNetwork

func (x *GenerateAddressRequest) GetNetwork() string

func (*GenerateAddressRequest) GetRequestId

func (x *GenerateAddressRequest) GetRequestId() string

func (*GenerateAddressRequest) ProtoMessage

func (*GenerateAddressRequest) ProtoMessage()

func (*GenerateAddressRequest) ProtoReflect

func (x *GenerateAddressRequest) ProtoReflect() protoreflect.Message

func (*GenerateAddressRequest) Reset

func (x *GenerateAddressRequest) Reset()

func (*GenerateAddressRequest) String

func (x *GenerateAddressRequest) String() string

type GetAddressRequest

type GetAddressRequest struct {

	// The resource name of the Address.
	// Format: networks/{network_id}/addresses/{address_id}
	Name string `protobuf:"bytes,1,opt,name=name,proto3" json:"name,omitempty"`
	// contains filtered or unexported fields
}

The request message for GetAddress.

func (*GetAddressRequest) Descriptor deprecated

func (*GetAddressRequest) Descriptor() ([]byte, []int)

Deprecated: Use GetAddressRequest.ProtoReflect.Descriptor instead.

func (*GetAddressRequest) GetName

func (x *GetAddressRequest) GetName() string

func (*GetAddressRequest) ProtoMessage

func (*GetAddressRequest) ProtoMessage()

func (*GetAddressRequest) ProtoReflect

func (x *GetAddressRequest) ProtoReflect() protoreflect.Message

func (*GetAddressRequest) Reset

func (x *GetAddressRequest) Reset()

func (*GetAddressRequest) String

func (x *GetAddressRequest) String() string

type GetMPCWalletRequest

type GetMPCWalletRequest struct {

	// The resource name of the MPCWallet.
	// Format: pools/{pool_id}/mpcWallets/{mpc_wallet_id}
	Name string `protobuf:"bytes,1,opt,name=name,proto3" json:"name,omitempty"`
	// contains filtered or unexported fields
}

The request message for GetMPCWallet.

func (*GetMPCWalletRequest) Descriptor deprecated

func (*GetMPCWalletRequest) Descriptor() ([]byte, []int)

Deprecated: Use GetMPCWalletRequest.ProtoReflect.Descriptor instead.

func (*GetMPCWalletRequest) GetName

func (x *GetMPCWalletRequest) GetName() string

func (*GetMPCWalletRequest) ProtoMessage

func (*GetMPCWalletRequest) ProtoMessage()

func (*GetMPCWalletRequest) ProtoReflect

func (x *GetMPCWalletRequest) ProtoReflect() protoreflect.Message

func (*GetMPCWalletRequest) Reset

func (x *GetMPCWalletRequest) Reset()

func (*GetMPCWalletRequest) String

func (x *GetMPCWalletRequest) String() string

type ListAddressesRequest

type ListAddressesRequest struct {

	// The resource name of the parent Network.
	// Format: networks/{network_id}
	Parent string `protobuf:"bytes,1,opt,name=parent,proto3" json:"parent,omitempty"`
	// The resource name of the MPCWallet to which the Addresses belong.
	// Format: pools/{pool_id}/mpcWallets/{mpc_wallet_id}
	MpcWallet string `protobuf:"bytes,2,opt,name=mpc_wallet,json=mpcWallet,proto3" json:"mpc_wallet,omitempty"`
	// The maximum number of Addresses to return. The default is 50.
	PageSize int32 `protobuf:"varint,3,opt,name=page_size,json=pageSize,proto3" json:"page_size,omitempty"`
	// A page token, received from a previous ListAddresses call.
	// Provide this to retrieve the subsequent page.
	PageToken string `protobuf:"bytes,4,opt,name=page_token,json=pageToken,proto3" json:"page_token,omitempty"`
	// contains filtered or unexported fields
}

The request message for ListAddresses.

func (*ListAddressesRequest) Descriptor deprecated

func (*ListAddressesRequest) Descriptor() ([]byte, []int)

Deprecated: Use ListAddressesRequest.ProtoReflect.Descriptor instead.

func (*ListAddressesRequest) GetMpcWallet

func (x *ListAddressesRequest) GetMpcWallet() string

func (*ListAddressesRequest) GetPageSize

func (x *ListAddressesRequest) GetPageSize() int32

func (*ListAddressesRequest) GetPageToken

func (x *ListAddressesRequest) GetPageToken() string

func (*ListAddressesRequest) GetParent

func (x *ListAddressesRequest) GetParent() string

func (*ListAddressesRequest) ProtoMessage

func (*ListAddressesRequest) ProtoMessage()

func (*ListAddressesRequest) ProtoReflect

func (x *ListAddressesRequest) ProtoReflect() protoreflect.Message

func (*ListAddressesRequest) Reset

func (x *ListAddressesRequest) Reset()

func (*ListAddressesRequest) String

func (x *ListAddressesRequest) String() string

type ListAddressesResponse

type ListAddressesResponse struct {

	// The list of Addresses.
	Addresses []*Address `protobuf:"bytes,1,rep,name=addresses,proto3" json:"addresses,omitempty"`
	// A token, which can be sent as page_token to retrieve the next page.
	// If this field is omitted, there are no subsequent pages.
	NextPageToken string `protobuf:"bytes,2,opt,name=next_page_token,json=nextPageToken,proto3" json:"next_page_token,omitempty"`
	// contains filtered or unexported fields
}

The response message for ListAddresses.

func (*ListAddressesResponse) Descriptor deprecated

func (*ListAddressesResponse) Descriptor() ([]byte, []int)

Deprecated: Use ListAddressesResponse.ProtoReflect.Descriptor instead.

func (*ListAddressesResponse) GetAddresses

func (x *ListAddressesResponse) GetAddresses() []*Address

func (*ListAddressesResponse) GetNextPageToken

func (x *ListAddressesResponse) GetNextPageToken() string

func (*ListAddressesResponse) ProtoMessage

func (*ListAddressesResponse) ProtoMessage()

func (*ListAddressesResponse) ProtoReflect

func (x *ListAddressesResponse) ProtoReflect() protoreflect.Message

func (*ListAddressesResponse) Reset

func (x *ListAddressesResponse) Reset()

func (*ListAddressesResponse) String

func (x *ListAddressesResponse) String() string

type ListBalanceDetailsRequest

type ListBalanceDetailsRequest struct {

	// The resource name of the parent Balance.
	// Format: networks/{network_id}/addresses/{address_id}/balances/{balance_id}
	Parent string `protobuf:"bytes,1,opt,name=parent,proto3" json:"parent,omitempty"`
	// The maximum number of BalanceDetails to return. If unspecified, at most 25 BalanceDetails
	// will be returned.
	PageSize int32 `protobuf:"varint,2,opt,name=page_size,json=pageSize,proto3" json:"page_size,omitempty"`
	// A page token, received from a previous ListBalanceDetails call.
	// Provide this to retrieve the subsequent page.
	PageToken string `protobuf:"bytes,3,opt,name=page_token,json=pageToken,proto3" json:"page_token,omitempty"`
	// contains filtered or unexported fields
}

The request message for ListBalanceDetails.

func (*ListBalanceDetailsRequest) Descriptor deprecated

func (*ListBalanceDetailsRequest) Descriptor() ([]byte, []int)

Deprecated: Use ListBalanceDetailsRequest.ProtoReflect.Descriptor instead.

func (*ListBalanceDetailsRequest) GetPageSize

func (x *ListBalanceDetailsRequest) GetPageSize() int32

func (*ListBalanceDetailsRequest) GetPageToken

func (x *ListBalanceDetailsRequest) GetPageToken() string

func (*ListBalanceDetailsRequest) GetParent

func (x *ListBalanceDetailsRequest) GetParent() string

func (*ListBalanceDetailsRequest) ProtoMessage

func (*ListBalanceDetailsRequest) ProtoMessage()

func (*ListBalanceDetailsRequest) ProtoReflect

func (*ListBalanceDetailsRequest) Reset

func (x *ListBalanceDetailsRequest) Reset()

func (*ListBalanceDetailsRequest) String

func (x *ListBalanceDetailsRequest) String() string

type ListBalanceDetailsResponse

type ListBalanceDetailsResponse struct {

	// The list of balance details.
	BalanceDetails []*BalanceDetail `protobuf:"bytes,1,rep,name=balance_details,json=balanceDetails,proto3" json:"balance_details,omitempty"`
	// A token, which can be sent as page_token to retrieve the next page.
	// If this field is omitted, there are no subsequent pages.
	NextPageToken string `protobuf:"bytes,2,opt,name=next_page_token,json=nextPageToken,proto3" json:"next_page_token,omitempty"`
	// contains filtered or unexported fields
}

The response message for ListBalanceDetails.

func (*ListBalanceDetailsResponse) Descriptor deprecated

func (*ListBalanceDetailsResponse) Descriptor() ([]byte, []int)

Deprecated: Use ListBalanceDetailsResponse.ProtoReflect.Descriptor instead.

func (*ListBalanceDetailsResponse) GetBalanceDetails

func (x *ListBalanceDetailsResponse) GetBalanceDetails() []*BalanceDetail

func (*ListBalanceDetailsResponse) GetNextPageToken

func (x *ListBalanceDetailsResponse) GetNextPageToken() string

func (*ListBalanceDetailsResponse) ProtoMessage

func (*ListBalanceDetailsResponse) ProtoMessage()

func (*ListBalanceDetailsResponse) ProtoReflect

func (*ListBalanceDetailsResponse) Reset

func (x *ListBalanceDetailsResponse) Reset()

func (*ListBalanceDetailsResponse) String

func (x *ListBalanceDetailsResponse) String() string

type ListBalancesRequest

type ListBalancesRequest struct {

	// The resource name of the parent Address.
	// Format: networks/{network_id}/addresses/{address_id}
	Parent string `protobuf:"bytes,1,opt,name=parent,proto3" json:"parent,omitempty"`
	// The maximum number of Balances to return. If unspecified, at most 25 Balances
	// will be returned.
	PageSize int32 `protobuf:"varint,3,opt,name=page_size,json=pageSize,proto3" json:"page_size,omitempty"`
	// A page token, received from a previous ListBalances call.
	// Provide this to retrieve the subsequent page.
	PageToken string `protobuf:"bytes,4,opt,name=page_token,json=pageToken,proto3" json:"page_token,omitempty"`
	// contains filtered or unexported fields
}

The request message for ListBalances.

func (*ListBalancesRequest) Descriptor deprecated

func (*ListBalancesRequest) Descriptor() ([]byte, []int)

Deprecated: Use ListBalancesRequest.ProtoReflect.Descriptor instead.

func (*ListBalancesRequest) GetPageSize

func (x *ListBalancesRequest) GetPageSize() int32

func (*ListBalancesRequest) GetPageToken

func (x *ListBalancesRequest) GetPageToken() string

func (*ListBalancesRequest) GetParent

func (x *ListBalancesRequest) GetParent() string

func (*ListBalancesRequest) ProtoMessage

func (*ListBalancesRequest) ProtoMessage()

func (*ListBalancesRequest) ProtoReflect

func (x *ListBalancesRequest) ProtoReflect() protoreflect.Message

func (*ListBalancesRequest) Reset

func (x *ListBalancesRequest) Reset()

func (*ListBalancesRequest) String

func (x *ListBalancesRequest) String() string

type ListBalancesResponse

type ListBalancesResponse struct {

	// The list of Balances.
	Balances []*Balance `protobuf:"bytes,1,rep,name=balances,proto3" json:"balances,omitempty"`
	// A token, which can be sent as page_token to retrieve the next page.
	// If this field is omitted, there are no subsequent pages.
	NextPageToken string `protobuf:"bytes,2,opt,name=next_page_token,json=nextPageToken,proto3" json:"next_page_token,omitempty"`
	// contains filtered or unexported fields
}

The response message for ListBalances.

func (*ListBalancesResponse) Descriptor deprecated

func (*ListBalancesResponse) Descriptor() ([]byte, []int)

Deprecated: Use ListBalancesResponse.ProtoReflect.Descriptor instead.

func (*ListBalancesResponse) GetBalances

func (x *ListBalancesResponse) GetBalances() []*Balance

func (*ListBalancesResponse) GetNextPageToken

func (x *ListBalancesResponse) GetNextPageToken() string

func (*ListBalancesResponse) ProtoMessage

func (*ListBalancesResponse) ProtoMessage()

func (*ListBalancesResponse) ProtoReflect

func (x *ListBalancesResponse) ProtoReflect() protoreflect.Message

func (*ListBalancesResponse) Reset

func (x *ListBalancesResponse) Reset()

func (*ListBalancesResponse) String

func (x *ListBalancesResponse) String() string

type ListMPCWalletsRequest

type ListMPCWalletsRequest struct {

	// The resource name of the parent Pool.
	// Format: pools/{pool_id}
	Parent string `protobuf:"bytes,1,opt,name=parent,proto3" json:"parent,omitempty"`
	// The maximum number of MPCWallets to return. The default is 50.
	PageSize int32 `protobuf:"varint,2,opt,name=page_size,json=pageSize,proto3" json:"page_size,omitempty"`
	// A page token, received from a previous ListMPCWallets call.
	// Provide this to retrieve the subsequent page.
	PageToken string `protobuf:"bytes,3,opt,name=page_token,json=pageToken,proto3" json:"page_token,omitempty"`
	// contains filtered or unexported fields
}

The request message for ListMPCWallets.

func (*ListMPCWalletsRequest) Descriptor deprecated

func (*ListMPCWalletsRequest) Descriptor() ([]byte, []int)

Deprecated: Use ListMPCWalletsRequest.ProtoReflect.Descriptor instead.

func (*ListMPCWalletsRequest) GetPageSize

func (x *ListMPCWalletsRequest) GetPageSize() int32

func (*ListMPCWalletsRequest) GetPageToken

func (x *ListMPCWalletsRequest) GetPageToken() string

func (*ListMPCWalletsRequest) GetParent

func (x *ListMPCWalletsRequest) GetParent() string

func (*ListMPCWalletsRequest) ProtoMessage

func (*ListMPCWalletsRequest) ProtoMessage()

func (*ListMPCWalletsRequest) ProtoReflect

func (x *ListMPCWalletsRequest) ProtoReflect() protoreflect.Message

func (*ListMPCWalletsRequest) Reset

func (x *ListMPCWalletsRequest) Reset()

func (*ListMPCWalletsRequest) String

func (x *ListMPCWalletsRequest) String() string

type ListMPCWalletsResponse

type ListMPCWalletsResponse struct {

	// The list of MPCWallets.
	MpcWallets []*MPCWallet `protobuf:"bytes,1,rep,name=mpc_wallets,json=mpcWallets,proto3" json:"mpc_wallets,omitempty"`
	// A token, which can be sent as page_token to retrieve the next page.
	// If this field is omitted, there are no subsequent pages.
	NextPageToken string `protobuf:"bytes,2,opt,name=next_page_token,json=nextPageToken,proto3" json:"next_page_token,omitempty"`
	// contains filtered or unexported fields
}

The response message for ListMPCWallets.

func (*ListMPCWalletsResponse) Descriptor deprecated

func (*ListMPCWalletsResponse) Descriptor() ([]byte, []int)

Deprecated: Use ListMPCWalletsResponse.ProtoReflect.Descriptor instead.

func (*ListMPCWalletsResponse) GetMpcWallets

func (x *ListMPCWalletsResponse) GetMpcWallets() []*MPCWallet

func (*ListMPCWalletsResponse) GetNextPageToken

func (x *ListMPCWalletsResponse) GetNextPageToken() string

func (*ListMPCWalletsResponse) ProtoMessage

func (*ListMPCWalletsResponse) ProtoMessage()

func (*ListMPCWalletsResponse) ProtoReflect

func (x *ListMPCWalletsResponse) ProtoReflect() protoreflect.Message

func (*ListMPCWalletsResponse) Reset

func (x *ListMPCWalletsResponse) Reset()

func (*ListMPCWalletsResponse) String

func (x *ListMPCWalletsResponse) String() string

type MPCWallet

type MPCWallet struct {

	// The resource name of the MPCWallet.
	// Format: pools/{pool_id}/mpcWallets/{mpc_wallet_id}
	Name string `protobuf:"bytes,1,opt,name=name,proto3" json:"name,omitempty"`
	// The resource name of the MPCKeyService DeviceGroup associated with this MPCWallet.
	// The DeviceGroup performs the underlying MPC operations.
	// Format: pools/{pool_id}/deviceGroups/{device_group_id}
	DeviceGroup string `protobuf:"bytes,2,opt,name=device_group,json=deviceGroup,proto3" json:"device_group,omitempty"`
	// contains filtered or unexported fields
}

The MPCWallet resource, which represents a collection of on-chain Addresses and their backing MPCKeys.

func (*MPCWallet) Descriptor deprecated

func (*MPCWallet) Descriptor() ([]byte, []int)

Deprecated: Use MPCWallet.ProtoReflect.Descriptor instead.

func (*MPCWallet) GetDeviceGroup

func (x *MPCWallet) GetDeviceGroup() string

func (*MPCWallet) GetName

func (x *MPCWallet) GetName() string

func (*MPCWallet) ProtoMessage

func (*MPCWallet) ProtoMessage()

func (*MPCWallet) ProtoReflect

func (x *MPCWallet) ProtoReflect() protoreflect.Message

func (*MPCWallet) Reset

func (x *MPCWallet) Reset()

func (*MPCWallet) String

func (x *MPCWallet) String() string

type MPCWalletResourceName

type MPCWalletResourceName struct {
	PoolId      string
	MpcWalletId string
}

func (MPCWalletResourceName) ContainsWildcard

func (n MPCWalletResourceName) ContainsWildcard() bool

func (MPCWalletResourceName) MarshalString

func (n MPCWalletResourceName) MarshalString() (string, error)

func (MPCWalletResourceName) String

func (n MPCWalletResourceName) String() string

func (*MPCWalletResourceName) UnmarshalString

func (n *MPCWalletResourceName) UnmarshalString(name string) error

func (MPCWalletResourceName) Validate

func (n MPCWalletResourceName) Validate() error

type MPCWalletServiceClient

type MPCWalletServiceClient interface {
	// Creates an MPCWallet. The Device in the request must have been registered using MPCKeyService's
	// RegisterDevice before this method is called. Under the hood, this calls MPCKeyService's
	// CreateDeviceGroup with the appropriate parameters. After calling this, use MPCKeyService's
	// ListMPCOperations to poll for the pending CreateDeviceGroup operation, and use the WaaS SDK's
	// computeMPCOperation to complete the operation.
	// Note: because the creation of MPC operations is asynchronous, ListMPCOperations may return a
	// NOT_FOUND error immediately after calling this. To complete the operation, continue polling
	// ListMPCOperations even after it returns a NOT_FOUND error.
	CreateMPCWallet(ctx context.Context, in *CreateMPCWalletRequest, opts ...grpc.CallOption) (*longrunning.Operation, error)
	// Retrieves an MPCWallet by resource name.
	GetMPCWallet(ctx context.Context, in *GetMPCWalletRequest, opts ...grpc.CallOption) (*MPCWallet, error)
	// Returns a list of MPCWallets in a Pool.
	ListMPCWallets(ctx context.Context, in *ListMPCWalletsRequest, opts ...grpc.CallOption) (*ListMPCWalletsResponse, error)
	// Generates an Address within an MPCWallet. The Address values generated are identical across
	// Networks of the same protocol family (e.g. EVM). So, for example, calling GenerateAddress twice
	// for networks/ethereum-mainnet, and then calling it twice more for networks/ethereum-goerli, will
	// result in two pairs of identical addresses on Ethereum Mainnet and Goerli.
	GenerateAddress(ctx context.Context, in *GenerateAddressRequest, opts ...grpc.CallOption) (*Address, error)
	// Retrieves an Address by resource name.
	GetAddress(ctx context.Context, in *GetAddressRequest, opts ...grpc.CallOption) (*Address, error)
	// Returns a list of Addresses in an MPCWallet.
	ListAddresses(ctx context.Context, in *ListAddressesRequest, opts ...grpc.CallOption) (*ListAddressesResponse, error)
	// Returns a list of Balances.
	ListBalances(ctx context.Context, in *ListBalancesRequest, opts ...grpc.CallOption) (*ListBalancesResponse, error)
	// Returns a list of BalanceDetails.
	ListBalanceDetails(ctx context.Context, in *ListBalanceDetailsRequest, opts ...grpc.CallOption) (*ListBalanceDetailsResponse, error)
}

MPCWalletServiceClient is the client API for MPCWalletService service.

For semantics around ctx use and closing/ending streaming RPCs, please refer to https://pkg.go.dev/google.golang.org/grpc/?tab=doc#ClientConn.NewStream.

type MPCWalletServiceServer

type MPCWalletServiceServer interface {
	// Creates an MPCWallet. The Device in the request must have been registered using MPCKeyService's
	// RegisterDevice before this method is called. Under the hood, this calls MPCKeyService's
	// CreateDeviceGroup with the appropriate parameters. After calling this, use MPCKeyService's
	// ListMPCOperations to poll for the pending CreateDeviceGroup operation, and use the WaaS SDK's
	// computeMPCOperation to complete the operation.
	// Note: because the creation of MPC operations is asynchronous, ListMPCOperations may return a
	// NOT_FOUND error immediately after calling this. To complete the operation, continue polling
	// ListMPCOperations even after it returns a NOT_FOUND error.
	CreateMPCWallet(context.Context, *CreateMPCWalletRequest) (*longrunning.Operation, error)
	// Retrieves an MPCWallet by resource name.
	GetMPCWallet(context.Context, *GetMPCWalletRequest) (*MPCWallet, error)
	// Returns a list of MPCWallets in a Pool.
	ListMPCWallets(context.Context, *ListMPCWalletsRequest) (*ListMPCWalletsResponse, error)
	// Generates an Address within an MPCWallet. The Address values generated are identical across
	// Networks of the same protocol family (e.g. EVM). So, for example, calling GenerateAddress twice
	// for networks/ethereum-mainnet, and then calling it twice more for networks/ethereum-goerli, will
	// result in two pairs of identical addresses on Ethereum Mainnet and Goerli.
	GenerateAddress(context.Context, *GenerateAddressRequest) (*Address, error)
	// Retrieves an Address by resource name.
	GetAddress(context.Context, *GetAddressRequest) (*Address, error)
	// Returns a list of Addresses in an MPCWallet.
	ListAddresses(context.Context, *ListAddressesRequest) (*ListAddressesResponse, error)
	// Returns a list of Balances.
	ListBalances(context.Context, *ListBalancesRequest) (*ListBalancesResponse, error)
	// Returns a list of BalanceDetails.
	ListBalanceDetails(context.Context, *ListBalanceDetailsRequest) (*ListBalanceDetailsResponse, error)
	// contains filtered or unexported methods
}

MPCWalletServiceServer is the server API for MPCWalletService service. All implementations must embed UnimplementedMPCWalletServiceServer for forward compatibility

type UnimplementedMPCWalletServiceServer

type UnimplementedMPCWalletServiceServer struct {
}

UnimplementedMPCWalletServiceServer must be embedded to have forward compatible implementations.

func (UnimplementedMPCWalletServiceServer) CreateMPCWallet

func (UnimplementedMPCWalletServiceServer) GenerateAddress

func (UnimplementedMPCWalletServiceServer) GetAddress

func (UnimplementedMPCWalletServiceServer) GetMPCWallet

func (UnimplementedMPCWalletServiceServer) ListAddresses

func (UnimplementedMPCWalletServiceServer) ListBalanceDetails

func (UnimplementedMPCWalletServiceServer) ListBalances

func (UnimplementedMPCWalletServiceServer) ListMPCWallets

type UnsafeMPCWalletServiceServer

type UnsafeMPCWalletServiceServer interface {
	// contains filtered or unexported methods
}

UnsafeMPCWalletServiceServer may be embedded to opt out of forward compatibility for this service. Use of this interface is not recommended, as added methods to MPCWalletServiceServer will result in compilation errors.

Directories

Path Synopsis

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL