Documentation
¶
Overview ¶
Class to interact with the underlying blockchain to operate on the highway
Index ¶
- func CheckAlias(alias string) (bool, error)
- func GetControllerAccount(address string) (*identitytypes.ControllerAccount, error)
- func GetDID(alias string) (*identitytypes.DIDDocument, error)
- func GetEmailRecordCreator(email string) (string, error)
- func GetServiceRecord(origin string) (*servicetypes.ServiceRecord, error)
- func IsAuthenticated(c *gin.Context) bool
- func IssueCredentialAssertionOptions(email string, record *servicetypes.ServiceRecord) (string, protocol.URLEncodedBase64, error)
- func IssueCredentialAttestationOptions(alias string, record *servicetypes.ServiceRecord) (string, protocol.URLEncodedBase64, error)
- func IssueEmailAssertionOptions(email string, ucwDid string) (string, error)
- func PublishControllerAccount(alias string, cred *servicetypes.WebauthnCredential, origin string) (*controller.SonrController, *types.TxResponse, error)
- func StoreAuthCookies(c *gin.Context, res *types.AuthenticationResult, origin string) gin.H
- func UseControllerAccount(token string) (*controller.SonrController, error)
- type ClaimsAPI
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func CheckAlias ¶
CheckAlias checks if an alias is already registered
func GetControllerAccount ¶ added in v0.7.1
func GetControllerAccount(address string) (*identitytypes.ControllerAccount, error)
GetDID returns the DIDDocument of a given DID or Alias
func GetDID ¶
func GetDID(alias string) (*identitytypes.DIDDocument, error)
GetDID returns the DIDDocument of a given DID or Alias
func GetEmailRecordCreator ¶ added in v0.7.1
GetEmailRecordCreator returns the creator of a given email
func GetServiceRecord ¶
func GetServiceRecord(origin string) (*servicetypes.ServiceRecord, error)
GetServiceRecord returns the ServiceRecord of a given origin
func IsAuthenticated ¶ added in v0.7.1
The function checks if a user is authenticated.
func IssueCredentialAssertionOptions ¶ added in v0.7.1
func IssueCredentialAssertionOptions(email string, record *servicetypes.ServiceRecord) (string, protocol.URLEncodedBase64, error)
IssueCredentialAssertionOptions takes a didDocument and serviceRecord in order to create a credential options.
func IssueCredentialAttestationOptions ¶ added in v0.7.1
func IssueCredentialAttestationOptions(alias string, record *servicetypes.ServiceRecord) (string, protocol.URLEncodedBase64, error)
IssueCredentialAttestationOptions takes a ucwId alias, and random unclaimed address and returns a token with the credential options.
func IssueEmailAssertionOptions ¶ added in v0.7.1
IssueEmailAssertionOptions takes a didDocument and serviceRecord in order to create a credential options.
func PublishControllerAccount ¶ added in v0.7.1
func PublishControllerAccount(alias string, cred *servicetypes.WebauthnCredential, origin string) (*controller.SonrController, *types.TxResponse, error)
func StoreAuthCookies ¶ added in v0.7.1
The function stores authentication cookies in the context.
func UseControllerAccount ¶ added in v0.7.1
func UseControllerAccount(token string) (*controller.SonrController, error)