Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type ISafeboxClient ¶
type ISafeboxClient interface { // TrusteeKeyPair is used to trutee keypair. // // API-Key must set to header. TrusteeKeyPair(http.Header, *SaveKeyPairRequetBody) (*SaveKeyPairReply, error) // QueryPrivateKey is used to query private key. // // API-Key must set to header. QueryPrivateKey(http.Header, *OperateKeyInfo) (*PrivateKeyReply, error) // QueryPublicKey is used to query public key. // // API-Key must set to header. QueryPublicKey(http.Header, *OperateKeyInfo) (*PublicKeyReply, error) // DeleteKeyPair is used to delete keypair. // // API-Key must set to header. DeleteKeyPair(http.Header, *OperateKeyInfo) error // UpdateAssistCode is used to update assist code. // // API-Key must set to header. UpdateAssistCode(http.Header, *UpdateSecurityCodeRequestBody) error // RecoverAssistCode is used to recover assist code when user has forgot. // // API-Key must set to header. RecoverAssistCode(http.Header, commdid.Identifier) (*CodeInfoReply, error) }
ISafeboxClient defines the behaviors implemented by safebox sdk
type OperateKeyInfo ¶
OperateKeyInfo ...
type PrivateKeyReply ¶
type PrivateKeyReply struct {
PrivateKey string `json:"private_key"`
}
PrivateKeyReply ...
type PublicKeyReply ¶
type PublicKeyReply struct {
PublicKey string `json:"public_key"`
}
PublicKeyReply ...
type SaveKeyPairReply ¶
type SaveKeyPairReply struct {
Code string `json:"code"`
}
SaveKeyPairReply define save KeyPair reply
type SaveKeyPairRequetBody ¶
type SaveKeyPairRequetBody struct { UserDid string `json:"user_did"` PrivateKey string `json:"private_key"` PublicKey string `json:"public_key"` }
SaveKeyPairRequetBody define save KeyPair request body
type UpdateSecurityCodeRequestBody ¶
type UpdateSecurityCodeRequestBody struct { UserDid string `json:"user_did"` OriginalCode string `json:"original_code"` NewCode string `json:"new_code"` }
UpdateSecurityCodeRequestBody ...
Click to show internal directories.
Click to hide internal directories.