Documentation ¶
Overview ¶
Package common provides primitives to interact with the openapi HTTP API.
Code generated by github.com/deepmap/oapi-codegen version v1.11.0 DO NOT EDIT.
Index ¶
- func GetSwagger() (swagger *openapi3.T, err error)
- func PathToRawSpec(pathToFile string) map[string]func() ([]byte, error)
- func ValidateDIDMethod(method DIDMethod) (profileapi.Method, error)
- func ValidateKMSConfig(config *KMSConfig) (*kms.Config, error)
- func ValidateKMSType(kmsType KMSConfigType) (kms.Type, error)
- func ValidateVCFormat(format VCFormat) (vcsverifiable.Format, error)
- func ValidateVPFormat(format VPFormat) (vcsverifiable.Format, error)
- type AuthorizationDetails
- type DIDMethod
- type KMSConfig
- type KMSConfigType
- type VCFormat
- type VPFormat
- type WalletInitiatedFlowData
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func GetSwagger ¶
GetSwagger returns the Swagger specification corresponding to the generated code in this file. The external references of Swagger specification are resolved. The logic of resolving external references is tightly connected to "import-mapping" feature. Externally referenced files must be embedded in the corresponding golang packages. Urls can be supported but this task was out of the scope.
func PathToRawSpec ¶
Constructs a synthetic filesystem for resolving external references when loading openapi specifications.
func ValidateDIDMethod ¶
func ValidateDIDMethod(method DIDMethod) (profileapi.Method, error)
func ValidateKMSType ¶
func ValidateKMSType(kmsType KMSConfigType) (kms.Type, error)
func ValidateVCFormat ¶
func ValidateVCFormat(format VCFormat) (vcsverifiable.Format, error)
func ValidateVPFormat ¶
func ValidateVPFormat(format VPFormat) (vcsverifiable.Format, error)
Types ¶
type AuthorizationDetails ¶
type AuthorizationDetails struct { // String representing a format in which the Credential is requested to be issued. Valid values defined by OIDC4VC are jwt_vc_json-ld and ldp_vc. Issuer can refuse the authorization request if the given credential type and format combo is not supported. Format *string `json:"format,omitempty"` // An array of strings that allows a client to specify the location of the resource server(s) allowing the Authorization Server to mint audience restricted access tokens. Locations *[]string `json:"locations,omitempty"` // String that determines the authorization details type. MUST be set to "openid_credential" for OIDC4VC. Type string `json:"type"` // String array denoting the types of the requested Credential. Types []string `json:"types"` }
Model to convey the details about the Credentials the Client wants to obtain.
type DIDMethod ¶
type DIDMethod string
DID method of the DID to be used for signing.
const ( DIDMethodKey DIDMethod = "key" DIDMethodOrb DIDMethod = "orb" DIDMethodWeb DIDMethod = "web" )
Defines values for DIDMethod.
func MapToDIDMethod ¶
func MapToDIDMethod(method profileapi.Method) (DIDMethod, error)
type KMSConfig ¶
type KMSConfig struct { // Prefix of database used by local kms. DbPrefix *string `json:"dbPrefix,omitempty"` // Type of database used by local kms. DbType *string `json:"dbType,omitempty"` // URL to database used by local kms. DbURL *string `json:"dbURL,omitempty"` // KMS endpoint. Endpoint *string `json:"endpoint,omitempty"` // Path to secret lock used by local kms. SecretLockKeyPath *string `json:"secretLockKeyPath,omitempty"` // Type of kms used to create and store DID keys. Type KMSConfigType `json:"type"` }
Model for KMS configuration.
type KMSConfigType ¶
type KMSConfigType string
Type of kms used to create and store DID keys.
const ( KMSConfigTypeAws KMSConfigType = "aws" KMSConfigTypeLocal KMSConfigType = "local" KMSConfigTypeWeb KMSConfigType = "web" )
Defines values for KMSConfigType.
func MapToKMSConfigType ¶
func MapToKMSConfigType(kmsType kms.Type) (KMSConfigType, error)
type VPFormat ¶
type VPFormat string
Supported VP formats.
func MapToVPFormat ¶
func MapToVPFormat(format vcsverifiable.Format) (VPFormat, error)
type WalletInitiatedFlowData ¶ added in v1.2.0
type WalletInitiatedFlowData struct { ClaimEndpoint string `json:"claim_endpoint"` CredentialTemplateId string `json:"credential_template_id"` OpState string `json:"op_state"` ProfileId string `json:"profile_id"` ProfileVersion string `json:"profile_version"` Scopes *[]string `json:"scopes"` }
WalletInitiatedFlowData defines model for WalletInitiatedFlowData.