Documentation ¶
Index ¶
- type Claim
- type ClaimAttributes
- type ClaimListResponse
- type ClaimOffer
- type ClaimOfferAttributes
- type ClaimOfferListResponse
- type ClaimOfferResponse
- type ClaimResponse
- type ClaimSchema
- type ClaimSchemaAttributes
- type ClaimSchemaListResponse
- type ClaimSchemaResponse
- type CredentialRequest
- type Details
- type Flag
- type Flagger
- type Flags
- type GetUploadForm
- type GetUploadFormAttributes
- type GetUploadFormListRequest
- type GetUploadFormRequest
- type Group
- type GroupAttributes
- type GroupCreate
- type GroupCreateAttributes
- type GroupCreateListRequest
- type GroupCreateRequest
- type GroupListResponse
- type GroupRelationships
- type GroupResponse
- type GroupUser
- type GroupUserAttributes
- type GroupUserListResponse
- type GroupUserRelationships
- type GroupUserResponse
- type GroupUserRole
- type Included
- func (c *Included) Add(includes ...Resource)
- func (c Included) MarshalJSON() ([]byte, error)
- func (c *Included) MustClaim(key Key) *Claim
- func (c *Included) MustClaimOffer(key Key) *ClaimOffer
- func (c *Included) MustClaimSchema(key Key) *ClaimSchema
- func (c *Included) MustGetUploadForm(key Key) *GetUploadForm
- func (c *Included) MustGroup(key Key) *Group
- func (c *Included) MustGroupCreate(key Key) *GroupCreate
- func (c *Included) MustGroupUser(key Key) *GroupUser
- func (c *Included) MustInvitationAcceptEmail(key Key) *InvitationAcceptEmail
- func (c *Included) MustInvitationCreateEmail(key Key) *InvitationCreateEmail
- func (c *Included) MustInvitationEmail(key Key) *InvitationEmail
- func (c *Included) MustOrganization(key Key) *Organization
- func (c *Included) MustOrganizationCreate(key Key) *OrganizationCreate
- func (c *Included) MustRequest(key Key) *Request
- func (c *Included) MustRequestFill(key Key) *RequestFill
- func (c *Included) MustRequestVerify(key Key) *RequestVerify
- func (c *Included) MustUploadForm(key Key) *UploadForm
- func (c *Included) MustUser(key Key) *User
- func (c *Included) MustVerificationCode(key Key) *VerificationCode
- func (c *Included) UnmarshalJSON(data []byte) error
- type InvitationAcceptEmail
- type InvitationAcceptEmailAttributes
- type InvitationAcceptEmailListRequest
- type InvitationAcceptEmailRequest
- type InvitationCreateEmail
- type InvitationCreateEmailAttributes
- type InvitationCreateEmailListRequest
- type InvitationCreateEmailRequest
- type InvitationEmail
- type InvitationEmailAttributes
- type InvitationEmailListResponse
- type InvitationEmailRelationships
- type InvitationEmailResponse
- type Key
- type Links
- type Organization
- type OrganizationAttributes
- type OrganizationCreate
- type OrganizationCreateAttributes
- type OrganizationCreateListRequest
- type OrganizationCreateRequest
- type OrganizationListResponse
- type OrganizationRelationships
- type OrganizationResponse
- type OrganizationStatus
- type Relation
- type RelationCollection
- type Request
- type RequestAttributes
- type RequestFill
- type RequestFillAttributes
- type RequestFillListRequest
- type RequestFillRequest
- type RequestListResponse
- type RequestRelationships
- type RequestResponse
- type RequestStatus
- type RequestVerify
- type RequestVerifyAttributes
- type RequestVerifyListRequest
- type RequestVerifyRequest
- type Resource
- type ResourceType
- type UploadForm
- type UploadFormAttributes
- type UploadFormListResponse
- type UploadFormResponse
- type User
- type UserAttributes
- type UserListResponse
- type UserRelationships
- type UserResponse
- type UserRole
- type VerificationCode
- type VerificationCodeAttributes
- type VerificationCodeListResponse
- type VerificationCodeResponse
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Claim ¶ added in v0.3.0
type Claim struct { Key Attributes ClaimAttributes `json:"attributes"` }
type ClaimAttributes ¶ added in v0.3.0
type ClaimListResponse ¶ added in v0.3.0
type ClaimListResponse struct { Data []Claim `json:"data"` Included Included `json:"included"` Links *Links `json:"links"` Meta json.RawMessage `json:"meta,omitempty"` }
func (*ClaimListResponse) GetMeta ¶ added in v0.3.0
func (r *ClaimListResponse) GetMeta(out interface{}) error
func (*ClaimListResponse) PutMeta ¶ added in v0.3.0
func (r *ClaimListResponse) PutMeta(v interface{}) (err error)
type ClaimOffer ¶
type ClaimOffer struct { Key Attributes ClaimOfferAttributes `json:"attributes"` }
type ClaimOfferAttributes ¶ added in v0.2.0
type ClaimOfferListResponse ¶ added in v0.2.0
type ClaimOfferListResponse struct { Data []ClaimOffer `json:"data"` Included Included `json:"included"` Links *Links `json:"links"` Meta json.RawMessage `json:"meta,omitempty"` }
func (*ClaimOfferListResponse) GetMeta ¶ added in v0.2.0
func (r *ClaimOfferListResponse) GetMeta(out interface{}) error
func (*ClaimOfferListResponse) PutMeta ¶ added in v0.2.0
func (r *ClaimOfferListResponse) PutMeta(v interface{}) (err error)
type ClaimOfferResponse ¶ added in v0.2.0
type ClaimOfferResponse struct { Data ClaimOffer `json:"data"` Included Included `json:"included"` }
type ClaimResponse ¶ added in v0.3.0
type ClaimSchema ¶
type ClaimSchema struct { Key Attributes ClaimSchemaAttributes `json:"attributes"` }
type ClaimSchemaAttributes ¶
type ClaimSchemaListResponse ¶
type ClaimSchemaListResponse struct { Data []ClaimSchema `json:"data"` Included Included `json:"included"` Links *Links `json:"links"` Meta json.RawMessage `json:"meta,omitempty"` }
func (*ClaimSchemaListResponse) GetMeta ¶
func (r *ClaimSchemaListResponse) GetMeta(out interface{}) error
func (*ClaimSchemaListResponse) PutMeta ¶
func (r *ClaimSchemaListResponse) PutMeta(v interface{}) (err error)
type ClaimSchemaResponse ¶
type ClaimSchemaResponse struct { Data ClaimSchema `json:"data"` Included Included `json:"included"` }
type CredentialRequest ¶ added in v0.2.0
type CredentialRequest struct { // The ID of the organization that the group belongs to CredentialSchema string `json:"credentialSchema"` // JSON object containing the data to create a claim based on CredentialSubject json.RawMessage `json:"credentialSubject"` // The timestamp when the claim expires Expiration *int64 `json:"expiration,omitempty"` // Flag to include Merkle Tree proof or not MtProof bool `json:"mtProof"` // Flag to include Signature proof or not SignatureProof bool `json:"signatureProof"` // The type of the claim Type string `json:"type"` }
type Details ¶
type Details json.RawMessage
func (Details) MarshalJSON ¶
MarshalJSON - casts Details to []byte
func (*Details) UnmarshalJSON ¶
UnmarshalJSON - casts data to Details
type GetUploadForm ¶ added in v0.6.0
type GetUploadForm struct { Key Attributes GetUploadFormAttributes `json:"attributes"` }
type GetUploadFormAttributes ¶ added in v0.6.0
type GetUploadFormAttributes struct { // MIME type of the document ContentType string `json:"content_type"` }
type GetUploadFormListRequest ¶ added in v0.6.0
type GetUploadFormListRequest struct { Data []GetUploadForm `json:"data"` Included Included `json:"included"` Links *Links `json:"links"` Meta json.RawMessage `json:"meta,omitempty"` }
func (*GetUploadFormListRequest) GetMeta ¶ added in v0.6.0
func (r *GetUploadFormListRequest) GetMeta(out interface{}) error
func (*GetUploadFormListRequest) PutMeta ¶ added in v0.6.0
func (r *GetUploadFormListRequest) PutMeta(v interface{}) (err error)
type GetUploadFormRequest ¶ added in v0.6.0
type GetUploadFormRequest struct { Data GetUploadForm `json:"data"` Included Included `json:"included"` }
type Group ¶
type Group struct { Key Attributes GroupAttributes `json:"attributes"` Relationships *GroupRelationships `json:"relationships,omitempty"` }
type GroupAttributes ¶
type GroupAttributes struct { // The time (UTC) that the group was created in RFC3339 format CreatedAt time.Time `json:"created_at"` // JSON object containing the metadata information of the group Metadata json.RawMessage `json:"metadata"` // The ID of the organization that the group belongs to OrgId string `json:"org_id"` // JSON object containing the rules of the group, which will be used to generate claims for the group members Rules json.RawMessage `json:"rules"` }
type GroupCreate ¶
type GroupCreate struct { Key Attributes GroupCreateAttributes `json:"attributes"` }
type GroupCreateAttributes ¶
type GroupCreateAttributes struct { // JSON object containing the metadata information of the group Metadata json.RawMessage `json:"metadata"` // JSON object containing the rules of the group, which will be used to generate claims for the group members Rules json.RawMessage `json:"rules"` }
type GroupCreateListRequest ¶
type GroupCreateListRequest struct { Data []GroupCreate `json:"data"` Included Included `json:"included"` Links *Links `json:"links"` Meta json.RawMessage `json:"meta,omitempty"` }
func (*GroupCreateListRequest) GetMeta ¶
func (r *GroupCreateListRequest) GetMeta(out interface{}) error
func (*GroupCreateListRequest) PutMeta ¶
func (r *GroupCreateListRequest) PutMeta(v interface{}) (err error)
type GroupCreateRequest ¶
type GroupCreateRequest struct { Data GroupCreate `json:"data"` Included Included `json:"included"` }
type GroupListResponse ¶
type GroupListResponse struct { Data []Group `json:"data"` Included Included `json:"included"` Links *Links `json:"links"` Meta json.RawMessage `json:"meta,omitempty"` }
func (*GroupListResponse) GetMeta ¶
func (r *GroupListResponse) GetMeta(out interface{}) error
func (*GroupListResponse) PutMeta ¶
func (r *GroupListResponse) PutMeta(v interface{}) (err error)
type GroupRelationships ¶
type GroupRelationships struct {
GroupUsers RelationCollection `json:"group_users"`
}
type GroupResponse ¶
type GroupUser ¶
type GroupUser struct { Key Attributes GroupUserAttributes `json:"attributes"` }
type GroupUserAttributes ¶
type GroupUserAttributes struct { // The time (UTC) that the group user was created in RFC3339 format CreatedAt time.Time `json:"created_at"` // The ID of the group that the user belongs to GroupId string `json:"group_id"` // The role of the group user. `undefined` (code 0) – The group user that was created but hasn't been verified yet by the organization owner or group admin or superadmin. `employee` (code 1) – The group user that was verified by the organization owner or group admin or superadmin by verifying verification request. `admin` (code 2) – The group user that was verified by the organization owner or group admin or superadmin as admin and has the ability to verify other group users. `superadmin` (code 3) – The group user that was verified by the organization owner or superadmin as superadmin and has the the same permissions as organization owner. Role GroupUserRole `json:"role"` // The time (UTC) that the group user was updated in RFC3339 format UpdatedAt time.Time `json:"updated_at"` // The ID of the user that belongs to the group user UserId string `json:"user_id"` }
type GroupUserListResponse ¶
type GroupUserListResponse struct { Data []GroupUser `json:"data"` Included Included `json:"included"` Links *Links `json:"links"` Meta json.RawMessage `json:"meta,omitempty"` }
func (*GroupUserListResponse) GetMeta ¶
func (r *GroupUserListResponse) GetMeta(out interface{}) error
func (*GroupUserListResponse) PutMeta ¶
func (r *GroupUserListResponse) PutMeta(v interface{}) (err error)
type GroupUserRelationships ¶
type GroupUserRelationships struct {
User Relation `json:"user"`
}
type GroupUserResponse ¶
type GroupUserRole ¶
type GroupUserRole int32
const ( GroupUserRole_Undefined GroupUserRole = 0 GroupUserRole_Employee GroupUserRole = 1 GroupUserRole_Admin GroupUserRole = 2 GroupUserRole_Superadmin GroupUserRole = 3 )
func GroupUserRoleFromString ¶
func GroupUserRoleFromString(s string) GroupUserRole
func (GroupUserRole) Int ¶
func (r GroupUserRole) Int() int
func (GroupUserRole) Int16 ¶
func (r GroupUserRole) Int16() int16
func (GroupUserRole) MarshalJSON ¶
func (r GroupUserRole) MarshalJSON() ([]byte, error)
func (GroupUserRole) String ¶
func (r GroupUserRole) String() string
func (GroupUserRole) UInt32 ¶ added in v0.6.0
func (r GroupUserRole) UInt32() uint32
func (*GroupUserRole) UnmarshalJSON ¶
func (r *GroupUserRole) UnmarshalJSON(b []byte) error
type Included ¶
type Included struct {
// contains filtered or unexported fields
}
Included - an array of Resource objects that are related to the primary data and/or each other (“included resources”).
func (Included) MarshalJSON ¶
MarshalJSON - marshals include collection as array of json objects
func (*Included) MustClaim ¶ added in v0.3.0
MustClaim - returns Claim from include collection. if entry with specified key does not exist - returns nil if entry with specified key exists but type or ID mismatches - panics
func (*Included) MustClaimOffer ¶ added in v0.2.0
func (c *Included) MustClaimOffer(key Key) *ClaimOffer
MustClaimOffer - returns ClaimOffer from include collection. if entry with specified key does not exist - returns nil if entry with specified key exists but type or ID mismatches - panics
func (*Included) MustClaimSchema ¶
func (c *Included) MustClaimSchema(key Key) *ClaimSchema
MustClaimSchema - returns ClaimSchema from include collection. if entry with specified key does not exist - returns nil if entry with specified key exists but type or ID mismatches - panics
func (*Included) MustGetUploadForm ¶ added in v0.6.0
func (c *Included) MustGetUploadForm(key Key) *GetUploadForm
MustGetUploadForm - returns GetUploadForm from include collection. if entry with specified key does not exist - returns nil if entry with specified key exists but type or ID mismatches - panics
func (*Included) MustGroup ¶
MustGroup - returns Group from include collection. if entry with specified key does not exist - returns nil if entry with specified key exists but type or ID mismatches - panics
func (*Included) MustGroupCreate ¶
func (c *Included) MustGroupCreate(key Key) *GroupCreate
MustGroupCreate - returns GroupCreate from include collection. if entry with specified key does not exist - returns nil if entry with specified key exists but type or ID mismatches - panics
func (*Included) MustGroupUser ¶
MustGroupUser - returns GroupUser from include collection. if entry with specified key does not exist - returns nil if entry with specified key exists but type or ID mismatches - panics
func (*Included) MustInvitationAcceptEmail ¶
func (c *Included) MustInvitationAcceptEmail(key Key) *InvitationAcceptEmail
MustInvitationAcceptEmail - returns InvitationAcceptEmail from include collection. if entry with specified key does not exist - returns nil if entry with specified key exists but type or ID mismatches - panics
func (*Included) MustInvitationCreateEmail ¶
func (c *Included) MustInvitationCreateEmail(key Key) *InvitationCreateEmail
MustInvitationCreateEmail - returns InvitationCreateEmail from include collection. if entry with specified key does not exist - returns nil if entry with specified key exists but type or ID mismatches - panics
func (*Included) MustInvitationEmail ¶
func (c *Included) MustInvitationEmail(key Key) *InvitationEmail
MustInvitationEmail - returns InvitationEmail from include collection. if entry with specified key does not exist - returns nil if entry with specified key exists but type or ID mismatches - panics
func (*Included) MustOrganization ¶
func (c *Included) MustOrganization(key Key) *Organization
MustOrganization - returns Organization from include collection. if entry with specified key does not exist - returns nil if entry with specified key exists but type or ID mismatches - panics
func (*Included) MustOrganizationCreate ¶
func (c *Included) MustOrganizationCreate(key Key) *OrganizationCreate
MustOrganizationCreate - returns OrganizationCreate from include collection. if entry with specified key does not exist - returns nil if entry with specified key exists but type or ID mismatches - panics
func (*Included) MustRequest ¶
MustRequest - returns Request from include collection. if entry with specified key does not exist - returns nil if entry with specified key exists but type or ID mismatches - panics
func (*Included) MustRequestFill ¶
func (c *Included) MustRequestFill(key Key) *RequestFill
MustRequestFill - returns RequestFill from include collection. if entry with specified key does not exist - returns nil if entry with specified key exists but type or ID mismatches - panics
func (*Included) MustRequestVerify ¶
func (c *Included) MustRequestVerify(key Key) *RequestVerify
MustRequestVerify - returns RequestVerify from include collection. if entry with specified key does not exist - returns nil if entry with specified key exists but type or ID mismatches - panics
func (*Included) MustUploadForm ¶ added in v0.6.0
func (c *Included) MustUploadForm(key Key) *UploadForm
MustUploadForm - returns UploadForm from include collection. if entry with specified key does not exist - returns nil if entry with specified key exists but type or ID mismatches - panics
func (*Included) MustUser ¶
MustUser - returns User from include collection. if entry with specified key does not exist - returns nil if entry with specified key exists but type or ID mismatches - panics
func (*Included) MustVerificationCode ¶
func (c *Included) MustVerificationCode(key Key) *VerificationCode
MustVerificationCode - returns VerificationCode from include collection. if entry with specified key does not exist - returns nil if entry with specified key exists but type or ID mismatches - panics
func (*Included) UnmarshalJSON ¶
UmarshalJSON - unmarshal array of json objects into include collection
type InvitationAcceptEmail ¶
type InvitationAcceptEmail struct { Key Attributes InvitationAcceptEmailAttributes `json:"attributes"` }
type InvitationAcceptEmailListRequest ¶
type InvitationAcceptEmailListRequest struct { Data []InvitationAcceptEmail `json:"data"` Included Included `json:"included"` Links *Links `json:"links"` Meta json.RawMessage `json:"meta,omitempty"` }
func (*InvitationAcceptEmailListRequest) GetMeta ¶
func (r *InvitationAcceptEmailListRequest) GetMeta(out interface{}) error
func (*InvitationAcceptEmailListRequest) PutMeta ¶
func (r *InvitationAcceptEmailListRequest) PutMeta(v interface{}) (err error)
type InvitationAcceptEmailRequest ¶
type InvitationAcceptEmailRequest struct { Data InvitationAcceptEmail `json:"data"` Included Included `json:"included"` }
type InvitationCreateEmail ¶
type InvitationCreateEmail struct { Key Attributes InvitationCreateEmailAttributes `json:"attributes"` }
type InvitationCreateEmailAttributes ¶
type InvitationCreateEmailAttributes struct { // Credential requests to an issuer CredentialRequests *[]CredentialRequest `json:"credential_requests,omitempty"` // The email address of the user that the invitation email is sent to Email string `json:"email"` }
type InvitationCreateEmailListRequest ¶
type InvitationCreateEmailListRequest struct { Data []InvitationCreateEmail `json:"data"` Included Included `json:"included"` Links *Links `json:"links"` Meta json.RawMessage `json:"meta,omitempty"` }
func (*InvitationCreateEmailListRequest) GetMeta ¶
func (r *InvitationCreateEmailListRequest) GetMeta(out interface{}) error
func (*InvitationCreateEmailListRequest) PutMeta ¶
func (r *InvitationCreateEmailListRequest) PutMeta(v interface{}) (err error)
type InvitationCreateEmailRequest ¶
type InvitationCreateEmailRequest struct { Data InvitationCreateEmail `json:"data"` Included Included `json:"included"` }
type InvitationEmail ¶
type InvitationEmail struct { Key Attributes InvitationEmailAttributes `json:"attributes"` Relationships *InvitationEmailRelationships `json:"relationships,omitempty"` }
type InvitationEmailAttributes ¶
type InvitationEmailAttributes struct { // Claim UUID ClaimId *string `json:"claim_id,omitempty"` // The time (UTC) that the email invitation was created in RFC3339 format CreatedAt time.Time `json:"created_at"` // The email address of the user that the invitation email is sent to Email string `json:"email"` // The ID of the group GroupId string `json:"group_id"` // The ID of the organization that the group belongs to OrgId string `json:"org_id"` // The ID of the request that the invitation email is associated with ReqId string `json:"req_id"` }
type InvitationEmailListResponse ¶
type InvitationEmailListResponse struct { Data []InvitationEmail `json:"data"` Included Included `json:"included"` Links *Links `json:"links"` Meta json.RawMessage `json:"meta,omitempty"` }
func (*InvitationEmailListResponse) GetMeta ¶
func (r *InvitationEmailListResponse) GetMeta(out interface{}) error
func (*InvitationEmailListResponse) PutMeta ¶
func (r *InvitationEmailListResponse) PutMeta(v interface{}) (err error)
type InvitationEmailRelationships ¶
type InvitationEmailRelationships struct {
Request Relation `json:"request"`
}
type InvitationEmailResponse ¶
type InvitationEmailResponse struct { Data InvitationEmail `json:"data"` Included Included `json:"included"` }
type Key ¶
type Key struct { ID string `json:"id"` Type ResourceType `json:"type"` }
func NewKeyInt64 ¶
func NewKeyInt64(id int64, resourceType ResourceType) Key
func (Key) AsRelation ¶
type Organization ¶
type Organization struct { Key Attributes OrganizationAttributes `json:"attributes"` Relationships *OrganizationRelationships `json:"relationships,omitempty"` }
type OrganizationAttributes ¶
type OrganizationAttributes struct { // The time (UTC) that the organization was created in RFC3339 format CreatedAt time.Time `json:"created_at"` // The DID of the organization, can be empty for the organizations with the status `unverified` Did *string `json:"did,omitempty"` // The domain of the organization Domain string `json:"domain"` // The number of claims issued by the organization IssuedClaimsCount string `json:"issued_claims_count"` // The number of members in the organization MembersCount string `json:"members_count"` // JSON object containing the metadata information of the organization Metadata json.RawMessage `json:"metadata"` // The status of the organization. `unverified` – The organization was created by the user and hasn't been verified yet. `verified` – The owner verified the organization's domain by adding code to the DNS record, verifying by the service, and creating the organization's DID issuer. As the result of the verification – the owner of the organization receives an \"owner role claim\". Status OrganizationStatus `json:"status"` // The time (UTC) that the organization was updated in RFC3339 format UpdatedAt time.Time `json:"updated_at"` // The base64 encoded verification code that was by service to verify the domain of the organization. Can be empty for the organizations with the status `unverified` VerificationCode *string `json:"verification_code,omitempty"` }
type OrganizationCreate ¶
type OrganizationCreate struct { Key Attributes OrganizationCreateAttributes `json:"attributes"` }
type OrganizationCreateAttributes ¶
type OrganizationCreateAttributes struct { // The domain of the organization Domain string `json:"domain"` // JSON object containing the metadata information of the organization Metadata json.RawMessage `json:"metadata"` // The DID of the owner of the organization OwnerDid string `json:"owner_did"` }
type OrganizationCreateListRequest ¶
type OrganizationCreateListRequest struct { Data []OrganizationCreate `json:"data"` Included Included `json:"included"` Links *Links `json:"links"` Meta json.RawMessage `json:"meta,omitempty"` }
func (*OrganizationCreateListRequest) GetMeta ¶
func (r *OrganizationCreateListRequest) GetMeta(out interface{}) error
func (*OrganizationCreateListRequest) PutMeta ¶
func (r *OrganizationCreateListRequest) PutMeta(v interface{}) (err error)
type OrganizationCreateRequest ¶
type OrganizationCreateRequest struct { Data OrganizationCreate `json:"data"` Included Included `json:"included"` }
type OrganizationListResponse ¶
type OrganizationListResponse struct { Data []Organization `json:"data"` Included Included `json:"included"` Links *Links `json:"links"` Meta json.RawMessage `json:"meta,omitempty"` }
func (*OrganizationListResponse) GetMeta ¶
func (r *OrganizationListResponse) GetMeta(out interface{}) error
func (*OrganizationListResponse) PutMeta ¶
func (r *OrganizationListResponse) PutMeta(v interface{}) (err error)
type OrganizationRelationships ¶
type OrganizationRelationships struct {
Owner *Relation `json:"owner,omitempty"`
}
type OrganizationResponse ¶
type OrganizationResponse struct { Data Organization `json:"data"` Included Included `json:"included"` }
type OrganizationStatus ¶
type OrganizationStatus int32
const ( OrganizationStatus_Unverified OrganizationStatus = 0 OrganizationStatus_Verified OrganizationStatus = 1 )
func OrganizationStatusFromString ¶
func OrganizationStatusFromString(s string) OrganizationStatus
func (OrganizationStatus) Int ¶
func (s OrganizationStatus) Int() int
func (OrganizationStatus) Int16 ¶
func (s OrganizationStatus) Int16() int16
func (OrganizationStatus) Intp ¶
func (s OrganizationStatus) Intp() *int
func (OrganizationStatus) MarshalJSON ¶
func (s OrganizationStatus) MarshalJSON() ([]byte, error)
func (OrganizationStatus) String ¶
func (s OrganizationStatus) String() string
func (*OrganizationStatus) UnmarshalJSON ¶
func (s *OrganizationStatus) UnmarshalJSON(b []byte) error
type RelationCollection ¶
func (RelationCollection) MarshalJSON ¶
func (r RelationCollection) MarshalJSON() ([]byte, error)
type Request ¶
type Request struct { Key Attributes RequestAttributes `json:"attributes"` Relationships *RequestRelationships `json:"relationships,omitempty"` }
type RequestAttributes ¶
type RequestAttributes struct { // The time (UTC) that the group was created in RFC3339 format CreatedAt time.Time `json:"created_at"` // Credential requests to an issuer CredentialRequests []CredentialRequest `json:"credential_requests"` // The ID of the group GroupId string `json:"group_id"` // Object that represents request style and other data Metadata json.RawMessage `json:"metadata"` // The ID of the organization that the group belongs to OrgId string `json:"org_id"` // The request status. `created` – The request was created by the group admin or organization owner or superadmin and hasn't been filled yet by the user. `accepted` – The request was accepted by the user, user entity was created, request filled with `user_did` field. Email and `undefined` user role claims was issued for the user `filled` – The user filled the request but it hasn't been approved or rejected yet by the group admin or organization owner or superadmin. `approved` – The request was approved by the group admin or organization owner or superadmin. `rejected` – The request was rejected by the group admin or organization owner or superadmin. `submitted` – The request becomes submitted when claims were issues for the all fields in attributes and was submitted to the chain by the issuer service. Status RequestStatus `json:"status"` // The time (UTC) that the organization was updated in RFC3339 format UpdatedAt time.Time `json:"updated_at"` // The DID of the user that the request is associated with, can be empty if user hasn't accepted the invitation yet UserDid *string `json:"user_did,omitempty"` }
type RequestFill ¶
type RequestFill struct { Key Attributes RequestFillAttributes `json:"attributes"` }
type RequestFillAttributes ¶
type RequestFillAttributes struct { // Credential requests to an issuer CredentialRequests []CredentialRequest `json:"credential_requests"` }
type RequestFillListRequest ¶
type RequestFillListRequest struct { Data []RequestFill `json:"data"` Included Included `json:"included"` Links *Links `json:"links"` Meta json.RawMessage `json:"meta,omitempty"` }
func (*RequestFillListRequest) GetMeta ¶
func (r *RequestFillListRequest) GetMeta(out interface{}) error
func (*RequestFillListRequest) PutMeta ¶
func (r *RequestFillListRequest) PutMeta(v interface{}) (err error)
type RequestFillRequest ¶
type RequestFillRequest struct { Data RequestFill `json:"data"` Included Included `json:"included"` }
type RequestListResponse ¶
type RequestListResponse struct { Data []Request `json:"data"` Included Included `json:"included"` Links *Links `json:"links"` Meta json.RawMessage `json:"meta,omitempty"` }
func (*RequestListResponse) GetMeta ¶
func (r *RequestListResponse) GetMeta(out interface{}) error
func (*RequestListResponse) PutMeta ¶
func (r *RequestListResponse) PutMeta(v interface{}) (err error)
type RequestRelationships ¶
type RequestRelationships struct { Claims *RelationCollection `json:"claims,omitempty"` Group *Relation `json:"group,omitempty"` Organization *Relation `json:"organization,omitempty"` }
type RequestResponse ¶
type RequestStatus ¶
type RequestStatus int32
const ( RequestStatus_Created RequestStatus = 0 RequestStatus_Accepted RequestStatus = 1 RequestStatus_Filled RequestStatus = 2 RequestStatus_Approved RequestStatus = 3 RequestStatus_Rejected RequestStatus = 4 RequestStatus_Submitted RequestStatus = 5 RequestStatus_Claimed RequestStatus = 6 )
func RequestStatusFromString ¶
func RequestStatusFromString(s string) RequestStatus
func (RequestStatus) Int ¶
func (s RequestStatus) Int() int
func (RequestStatus) Int16 ¶
func (s RequestStatus) Int16() int16
func (RequestStatus) IntP ¶
func (s RequestStatus) IntP() *int
func (RequestStatus) MarshalJSON ¶
func (s RequestStatus) MarshalJSON() ([]byte, error)
func (RequestStatus) String ¶
func (s RequestStatus) String() string
func (*RequestStatus) UnmarshalJSON ¶
func (s *RequestStatus) UnmarshalJSON(b []byte) error
type RequestVerify ¶
type RequestVerify struct { Key Attributes RequestVerifyAttributes `json:"attributes"` }
type RequestVerifyAttributes ¶
type RequestVerifyAttributes struct { // The time (UTC) when claims will be issued ActivationDate time.Time `json:"activation_date"` // The approval status of the verification request. `true` – The verification request was approved. `false` – The verification request was rejected. In that case `metadata` and `role` fields could be empty. Approved bool `json:"approved"` // The time (UTC) when claims expire ExpirationDate time.Time `json:"expiration_date"` // JSON object containing the metadata (background, name, etc) information of the request Metadata json.RawMessage `json:"metadata"` // The role of the group user. 0 - `undefined` – The group user that was created but hasn't been verified yet by the organization owner or group admin or superadmin. 1 - `employee` – The group user that was verified by the organization owner or group admin or superadmin by verifying verification request. 2 - `admin` – The group user that was verified by the organization owner or group admin or superadmin as admin and has the ability to verify other group users. 3 - `superadmin` – The group user that was verified by the superadmin as superadmin and has the ability to verify other group users and has the highest permissions in the group. Role uint32 `json:"role"` }
type RequestVerifyListRequest ¶
type RequestVerifyListRequest struct { Data []RequestVerify `json:"data"` Included Included `json:"included"` Links *Links `json:"links"` Meta json.RawMessage `json:"meta,omitempty"` }
func (*RequestVerifyListRequest) GetMeta ¶
func (r *RequestVerifyListRequest) GetMeta(out interface{}) error
func (*RequestVerifyListRequest) PutMeta ¶
func (r *RequestVerifyListRequest) PutMeta(v interface{}) (err error)
type RequestVerifyRequest ¶
type RequestVerifyRequest struct { Data RequestVerify `json:"data"` Included Included `json:"included"` }
type ResourceType ¶
type ResourceType string
const ( CLAIMS ResourceType = "claims" LOGO ResourceType = "logo" GROUPS_CREATE ResourceType = "groups-create" GROUPS ResourceType = "groups" GROUP_USERS ResourceType = "group-users" INVITATIONS_ACCEPT_EMAIL ResourceType = "invitations-accept-email" INVITATIONS_CREATE_EMAIL ResourceType = "invitations-create-email" INVITATIONS_EMAIL ResourceType = "invitations-email" ORGANIZATIONS_CREATE ResourceType = "organizations-create" ORGANIZATIONS ResourceType = "organizations" REQUESTS_FILL ResourceType = "requests-fill" REQUESTS ResourceType = "requests" REQUESTS_VERIFY ResourceType = "requests-verify" UPLOAD_FORM ResourceType = "upload_form" USERS ResourceType = "users" VERIFICATION_CODES ResourceType = "verification-codes" )
List of ResourceType
type UploadForm ¶ added in v0.6.0
type UploadForm struct { Key Attributes UploadFormAttributes `json:"attributes"` }
type UploadFormAttributes ¶ added in v0.6.0
type UploadFormAttributes struct { // Name of the bucket Bucket string `json:"bucket"` // Document identifier Key string `json:"key"` // Upload policy Policy string `json:"policy"` // URL to upload an object to Url string `json:"url"` XAmzAlgorithm string `json:"x-amz-algorithm"` XAmzCredential string `json:"x-amz-credential"` XAmzDate string `json:"x-amz-date"` XAmzSignature string `json:"x-amz-signature"` }
type UploadFormListResponse ¶ added in v0.6.0
type UploadFormListResponse struct { Data []UploadForm `json:"data"` Included Included `json:"included"` Links *Links `json:"links"` Meta json.RawMessage `json:"meta,omitempty"` }
func (*UploadFormListResponse) GetMeta ¶ added in v0.6.0
func (r *UploadFormListResponse) GetMeta(out interface{}) error
func (*UploadFormListResponse) PutMeta ¶ added in v0.6.0
func (r *UploadFormListResponse) PutMeta(v interface{}) (err error)
type UploadFormResponse ¶ added in v0.6.0
type UploadFormResponse struct { Data UploadForm `json:"data"` Included Included `json:"included"` }
type User ¶
type User struct { Key Attributes UserAttributes `json:"attributes"` Relationships *UserRelationships `json:"relationships,omitempty"` }
type UserAttributes ¶
type UserAttributes struct { // The time (UTC) that the user was created in RFC3339 format CreatedAt time.Time `json:"created_at"` // The DID of the user Did *string `json:"did,omitempty"` // The ID of the organization that the user belongs to OrgId string `json:"org_id"` // The global role of the user. `undefined` (code 100) – Basic user role. Any group role that does not corresponds to superadmin will be mapped into this. `owner` (code 101) – The owner of some organization. `superadmin` (code 102) – The user with the same privileges as organization admin. Role UserRole `json:"role"` // The time (UTC) that the user was updated in RFC3339 format UpdatedAt time.Time `json:"updated_at"` }
type UserListResponse ¶
type UserListResponse struct { Data []User `json:"data"` Included Included `json:"included"` Links *Links `json:"links"` Meta json.RawMessage `json:"meta,omitempty"` }
func (*UserListResponse) GetMeta ¶
func (r *UserListResponse) GetMeta(out interface{}) error
func (*UserListResponse) PutMeta ¶
func (r *UserListResponse) PutMeta(v interface{}) (err error)
type UserRelationships ¶
type UserRelationships struct {
Organization Relation `json:"organization"`
}
type UserResponse ¶
type UserRole ¶
type UserRole int32
func UserRoleFromString ¶
func (UserRole) MarshalJSON ¶
func (*UserRole) UnmarshalJSON ¶
type VerificationCode ¶
type VerificationCode struct { Key Attributes VerificationCodeAttributes `json:"attributes"` }
type VerificationCodeAttributes ¶
type VerificationCodeAttributes struct { // Verification code for particular organization that should be added to the TXT DNS record in the “rarimo.” subdomain of provided organization domain. Code string `json:"code"` }
type VerificationCodeListResponse ¶
type VerificationCodeListResponse struct { Data []VerificationCode `json:"data"` Included Included `json:"included"` Links *Links `json:"links"` Meta json.RawMessage `json:"meta,omitempty"` }
func (*VerificationCodeListResponse) GetMeta ¶
func (r *VerificationCodeListResponse) GetMeta(out interface{}) error
func (*VerificationCodeListResponse) PutMeta ¶
func (r *VerificationCodeListResponse) PutMeta(v interface{}) (err error)
type VerificationCodeResponse ¶
type VerificationCodeResponse struct { Data VerificationCode `json:"data"` Included Included `json:"included"` }
Source Files ¶
- db.go
- flag.go
- group_user_role.go
- included.go
- links.go
- model_claim.go
- model_claim_attributes.go
- model_claim_offer.go
- model_claim_offer_attributes.go
- model_claim_schema.go
- model_claim_schema_attributes.go
- model_credential_request.go
- model_details.go
- model_get_upload_form.go
- model_get_upload_form_attributes.go
- model_group.go
- model_group_attributes.go
- model_group_create.go
- model_group_create_attributes.go
- model_group_relationships.go
- model_group_user.go
- model_group_user_attributes.go
- model_group_user_relationships.go
- model_invitation_accept_email.go
- model_invitation_accept_email_attributes.go
- model_invitation_create_email.go
- model_invitation_create_email_attributes.go
- model_invitation_email.go
- model_invitation_email_attributes.go
- model_invitation_email_relationships.go
- model_key.go
- model_organization.go
- model_organization_attributes.go
- model_organization_create.go
- model_organization_create_attributes.go
- model_organization_relationships.go
- model_relation.go
- model_relation_collection.go
- model_request.go
- model_request_attributes.go
- model_request_fill.go
- model_request_fill_attributes.go
- model_request_relationships.go
- model_request_verify.go
- model_request_verify_attributes.go
- model_resource_type.go
- model_upload_form.go
- model_upload_form_attributes.go
- model_user.go
- model_user_attributes.go
- model_user_relationships.go
- model_verification_code.go
- model_verification_code_attributes.go
- org_status.go
- req_status.go
- user_role.go