credential

package
v0.0.0-...-3a21ec0 Latest Latest
Warning

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

Go to latest
Published: Oct 7, 2020 License: Apache-2.0 Imports: 11 Imported by: 0

Documentation

Index

Constants

View Source
const CreateCredentialBadRequestCode int = 400

CreateCredentialBadRequestCode is the HTTP code returned for type CreateCredentialBadRequest

View Source
const CreateCredentialInternalServerErrorCode int = 500

CreateCredentialInternalServerErrorCode is the HTTP code returned for type CreateCredentialInternalServerError

View Source
const CreateCredentialNotFoundCode int = 404

CreateCredentialNotFoundCode is the HTTP code returned for type CreateCredentialNotFound

View Source
const CreateCredentialOKCode int = 200

CreateCredentialOKCode is the HTTP code returned for type CreateCredentialOK

View Source
const GetCredentialByIDBadRequestCode int = 400

GetCredentialByIDBadRequestCode is the HTTP code returned for type GetCredentialByIDBadRequest

View Source
const GetCredentialByIDInternalServerErrorCode int = 500

GetCredentialByIDInternalServerErrorCode is the HTTP code returned for type GetCredentialByIDInternalServerError

View Source
const GetCredentialByIDNotFoundCode int = 404

GetCredentialByIDNotFoundCode is the HTTP code returned for type GetCredentialByIDNotFound

View Source
const GetCredentialByIDOKCode int = 200

GetCredentialByIDOKCode is the HTTP code returned for type GetCredentialByIDOK

View Source
const RenewalCredentialBadRequestCode int = 400

RenewalCredentialBadRequestCode is the HTTP code returned for type RenewalCredentialBadRequest

View Source
const RenewalCredentialInternalServerErrorCode int = 500

RenewalCredentialInternalServerErrorCode is the HTTP code returned for type RenewalCredentialInternalServerError

View Source
const RenewalCredentialNotFoundCode int = 404

RenewalCredentialNotFoundCode is the HTTP code returned for type RenewalCredentialNotFound

View Source
const RenewalCredentialOKCode int = 200

RenewalCredentialOKCode is the HTTP code returned for type RenewalCredentialOK

View Source
const RevokeCredentialBadRequestCode int = 400

RevokeCredentialBadRequestCode is the HTTP code returned for type RevokeCredentialBadRequest

View Source
const RevokeCredentialInternalServerErrorCode int = 500

RevokeCredentialInternalServerErrorCode is the HTTP code returned for type RevokeCredentialInternalServerError

View Source
const RevokeCredentialNotFoundCode int = 404

RevokeCredentialNotFoundCode is the HTTP code returned for type RevokeCredentialNotFound

View Source
const RevokeCredentialOKCode int = 200

RevokeCredentialOKCode is the HTTP code returned for type RevokeCredentialOK

View Source
const SendCredentialBadRequestCode int = 400

SendCredentialBadRequestCode is the HTTP code returned for type SendCredentialBadRequest

View Source
const SendCredentialInternalServerErrorCode int = 500

SendCredentialInternalServerErrorCode is the HTTP code returned for type SendCredentialInternalServerError

View Source
const SendCredentialNotFoundCode int = 404

SendCredentialNotFoundCode is the HTTP code returned for type SendCredentialNotFound

View Source
const SendCredentialOKCode int = 200

SendCredentialOKCode is the HTTP code returned for type SendCredentialOK

View Source
const VerifyCredentialBadRequestCode int = 400

VerifyCredentialBadRequestCode is the HTTP code returned for type VerifyCredentialBadRequest

View Source
const VerifyCredentialInternalServerErrorCode int = 500

VerifyCredentialInternalServerErrorCode is the HTTP code returned for type VerifyCredentialInternalServerError

View Source
const VerifyCredentialNotFoundCode int = 404

VerifyCredentialNotFoundCode is the HTTP code returned for type VerifyCredentialNotFound

View Source
const VerifyCredentialOKCode int = 200

VerifyCredentialOKCode is the HTTP code returned for type VerifyCredentialOK

Variables

This section is empty.

Functions

This section is empty.

Types

type CreateCredential

type CreateCredential struct {
	Context *middleware.Context
	Handler CreateCredentialHandler
}

CreateCredential swagger:route POST /credential credential createCredential

Create Credential

This service is responsible for generating verifiable credentials, storing the credential hash in the blockchain. You send the credential data with type of credential, range of valid dates and evidence generated about credential as optional

func NewCreateCredential

func NewCreateCredential(ctx *middleware.Context, handler CreateCredentialHandler) *CreateCredential

NewCreateCredential creates a new http.Handler for the create credential operation

func (*CreateCredential) ServeHTTP

func (o *CreateCredential) ServeHTTP(rw http.ResponseWriter, r *http.Request)

type CreateCredentialBadRequest

type CreateCredentialBadRequest struct {

	/*
	  In: Body
	*/
	Payload []*models.CredentialSubject `json:"body,omitempty"`
}

CreateCredentialBadRequest Invalid credential supplied

swagger:response createCredentialBadRequest

func NewCreateCredentialBadRequest

func NewCreateCredentialBadRequest() *CreateCredentialBadRequest

NewCreateCredentialBadRequest creates CreateCredentialBadRequest with default headers values

func (*CreateCredentialBadRequest) SetPayload

func (o *CreateCredentialBadRequest) SetPayload(payload []*models.CredentialSubject)

SetPayload sets the payload to the create credential bad request response

func (*CreateCredentialBadRequest) WithPayload

WithPayload adds the payload to the create credential bad request response

func (*CreateCredentialBadRequest) WriteResponse

func (o *CreateCredentialBadRequest) WriteResponse(rw http.ResponseWriter, producer runtime.Producer)

WriteResponse to the client

type CreateCredentialHandler

type CreateCredentialHandler interface {
	Handle(CreateCredentialParams) middleware.Responder
}

CreateCredentialHandler interface for that can handle valid create credential params

type CreateCredentialHandlerFunc

type CreateCredentialHandlerFunc func(CreateCredentialParams) middleware.Responder

CreateCredentialHandlerFunc turns a function with the right signature into a create credential handler

func (CreateCredentialHandlerFunc) Handle

Handle executing the request and returning a response

type CreateCredentialInternalServerError

type CreateCredentialInternalServerError struct {
}

CreateCredentialInternalServerError Error Internal Server

swagger:response createCredentialInternalServerError

func NewCreateCredentialInternalServerError

func NewCreateCredentialInternalServerError() *CreateCredentialInternalServerError

NewCreateCredentialInternalServerError creates CreateCredentialInternalServerError with default headers values

func (*CreateCredentialInternalServerError) WriteResponse

WriteResponse to the client

type CreateCredentialNotFound

type CreateCredentialNotFound struct {
}

CreateCredentialNotFound DID not found

swagger:response createCredentialNotFound

func NewCreateCredentialNotFound

func NewCreateCredentialNotFound() *CreateCredentialNotFound

NewCreateCredentialNotFound creates CreateCredentialNotFound with default headers values

func (*CreateCredentialNotFound) WriteResponse

func (o *CreateCredentialNotFound) WriteResponse(rw http.ResponseWriter, producer runtime.Producer)

WriteResponse to the client

type CreateCredentialOK

type CreateCredentialOK struct {

	/*
	  In: Body
	*/
	Payload []*models.Credential `json:"body,omitempty"`
}

CreateCredentialOK successful operation

swagger:response createCredentialOK

func NewCreateCredentialOK

func NewCreateCredentialOK() *CreateCredentialOK

NewCreateCredentialOK creates CreateCredentialOK with default headers values

func (*CreateCredentialOK) SetPayload

func (o *CreateCredentialOK) SetPayload(payload []*models.Credential)

SetPayload sets the payload to the create credential o k response

func (*CreateCredentialOK) WithPayload

func (o *CreateCredentialOK) WithPayload(payload []*models.Credential) *CreateCredentialOK

WithPayload adds the payload to the create credential o k response

func (*CreateCredentialOK) WriteResponse

func (o *CreateCredentialOK) WriteResponse(rw http.ResponseWriter, producer runtime.Producer)

WriteResponse to the client

type CreateCredentialParams

type CreateCredentialParams struct {

	// HTTP Request Object
	HTTPRequest *http.Request `json:"-"`

	/*Created credential object
	  Required: true
	  In: body
	*/
	Body []*models.CredentialSubject
}

CreateCredentialParams contains all the bound params for the create credential operation typically these are obtained from a http.Request

swagger:parameters createCredential

func NewCreateCredentialParams

func NewCreateCredentialParams() CreateCredentialParams

NewCreateCredentialParams creates a new CreateCredentialParams object no default values defined in spec.

func (*CreateCredentialParams) BindRequest

func (o *CreateCredentialParams) BindRequest(r *http.Request, route *middleware.MatchedRoute) error

BindRequest both binds and validates a request, it assumes that complex things implement a Validatable(strfmt.Registry) error interface for simple values it will use straight method calls.

To ensure default values, the struct must have been initialized with NewCreateCredentialParams() beforehand.

type CreateCredentialURL

type CreateCredentialURL struct {
	// contains filtered or unexported fields
}

CreateCredentialURL generates an URL for the create credential operation

func (*CreateCredentialURL) Build

func (o *CreateCredentialURL) Build() (*url.URL, error)

Build a url path and query string

func (*CreateCredentialURL) BuildFull

func (o *CreateCredentialURL) BuildFull(scheme, host string) (*url.URL, error)

BuildFull builds a full url with scheme, host, path and query string

func (*CreateCredentialURL) Must

func (o *CreateCredentialURL) Must(u *url.URL, err error) *url.URL

Must is a helper function to panic when the url builder returns an error

func (*CreateCredentialURL) SetBasePath

func (o *CreateCredentialURL) SetBasePath(bp string)

SetBasePath sets the base path for this url builder, only required when it's different from the base path specified in the swagger spec. When the value of the base path is an empty string

func (*CreateCredentialURL) String

func (o *CreateCredentialURL) String() string

String returns the string representation of the path with query string

func (*CreateCredentialURL) StringFull

func (o *CreateCredentialURL) StringFull(scheme, host string) string

StringFull returns the string representation of a complete url

func (*CreateCredentialURL) WithBasePath

func (o *CreateCredentialURL) WithBasePath(bp string) *CreateCredentialURL

WithBasePath sets the base path for this url builder, only required when it's different from the base path specified in the swagger spec. When the value of the base path is an empty string

type GetCredentialByID

type GetCredentialByID struct {
	Context *middleware.Context
	Handler GetCredentialByIDHandler
}

GetCredentialByID swagger:route GET /credential/{credentialId} credential getCredentialById

Get a Credential by ID

This service returns a credential verifiable

func NewGetCredentialByID

func NewGetCredentialByID(ctx *middleware.Context, handler GetCredentialByIDHandler) *GetCredentialByID

NewGetCredentialByID creates a new http.Handler for the get credential by Id operation

func (*GetCredentialByID) ServeHTTP

func (o *GetCredentialByID) ServeHTTP(rw http.ResponseWriter, r *http.Request)

type GetCredentialByIDBadRequest

type GetCredentialByIDBadRequest struct {
}

GetCredentialByIDBadRequest Invalid credential Id supplied

swagger:response getCredentialByIdBadRequest

func NewGetCredentialByIDBadRequest

func NewGetCredentialByIDBadRequest() *GetCredentialByIDBadRequest

NewGetCredentialByIDBadRequest creates GetCredentialByIDBadRequest with default headers values

func (*GetCredentialByIDBadRequest) WriteResponse

func (o *GetCredentialByIDBadRequest) WriteResponse(rw http.ResponseWriter, producer runtime.Producer)

WriteResponse to the client

type GetCredentialByIDHandler

type GetCredentialByIDHandler interface {
	Handle(GetCredentialByIDParams) middleware.Responder
}

GetCredentialByIDHandler interface for that can handle valid get credential by Id params

type GetCredentialByIDHandlerFunc

type GetCredentialByIDHandlerFunc func(GetCredentialByIDParams) middleware.Responder

GetCredentialByIDHandlerFunc turns a function with the right signature into a get credential by Id handler

func (GetCredentialByIDHandlerFunc) Handle

Handle executing the request and returning a response

type GetCredentialByIDInternalServerError

type GetCredentialByIDInternalServerError struct {
}

GetCredentialByIDInternalServerError Error Internal Server

swagger:response getCredentialByIdInternalServerError

func NewGetCredentialByIDInternalServerError

func NewGetCredentialByIDInternalServerError() *GetCredentialByIDInternalServerError

NewGetCredentialByIDInternalServerError creates GetCredentialByIDInternalServerError with default headers values

func (*GetCredentialByIDInternalServerError) WriteResponse

WriteResponse to the client

type GetCredentialByIDNotFound

type GetCredentialByIDNotFound struct {
}

GetCredentialByIDNotFound ID not found

swagger:response getCredentialByIdNotFound

func NewGetCredentialByIDNotFound

func NewGetCredentialByIDNotFound() *GetCredentialByIDNotFound

NewGetCredentialByIDNotFound creates GetCredentialByIDNotFound with default headers values

func (*GetCredentialByIDNotFound) WriteResponse

func (o *GetCredentialByIDNotFound) WriteResponse(rw http.ResponseWriter, producer runtime.Producer)

WriteResponse to the client

type GetCredentialByIDOK

type GetCredentialByIDOK struct {

	/*
	  In: Body
	*/
	Payload *models.Credential `json:"body,omitempty"`
}

GetCredentialByIDOK successful operation

swagger:response getCredentialByIdOK

func NewGetCredentialByIDOK

func NewGetCredentialByIDOK() *GetCredentialByIDOK

NewGetCredentialByIDOK creates GetCredentialByIDOK with default headers values

func (*GetCredentialByIDOK) SetPayload

func (o *GetCredentialByIDOK) SetPayload(payload *models.Credential)

SetPayload sets the payload to the get credential by Id o k response

func (*GetCredentialByIDOK) WithPayload

func (o *GetCredentialByIDOK) WithPayload(payload *models.Credential) *GetCredentialByIDOK

WithPayload adds the payload to the get credential by Id o k response

func (*GetCredentialByIDOK) WriteResponse

func (o *GetCredentialByIDOK) WriteResponse(rw http.ResponseWriter, producer runtime.Producer)

WriteResponse to the client

type GetCredentialByIDParams

type GetCredentialByIDParams struct {

	// HTTP Request Object
	HTTPRequest *http.Request `json:"-"`

	/*the credential id that needs be returned.
	  Required: true
	  In: path
	*/
	CredentialID string
}

GetCredentialByIDParams contains all the bound params for the get credential by Id operation typically these are obtained from a http.Request

swagger:parameters getCredentialById

func NewGetCredentialByIDParams

func NewGetCredentialByIDParams() GetCredentialByIDParams

NewGetCredentialByIDParams creates a new GetCredentialByIDParams object no default values defined in spec.

func (*GetCredentialByIDParams) BindRequest

func (o *GetCredentialByIDParams) BindRequest(r *http.Request, route *middleware.MatchedRoute) error

BindRequest both binds and validates a request, it assumes that complex things implement a Validatable(strfmt.Registry) error interface for simple values it will use straight method calls.

To ensure default values, the struct must have been initialized with NewGetCredentialByIDParams() beforehand.

type GetCredentialByIDURL

type GetCredentialByIDURL struct {
	CredentialID string
	// contains filtered or unexported fields
}

GetCredentialByIDURL generates an URL for the get credential by Id operation

func (*GetCredentialByIDURL) Build

func (o *GetCredentialByIDURL) Build() (*url.URL, error)

Build a url path and query string

func (*GetCredentialByIDURL) BuildFull

func (o *GetCredentialByIDURL) BuildFull(scheme, host string) (*url.URL, error)

BuildFull builds a full url with scheme, host, path and query string

func (*GetCredentialByIDURL) Must

func (o *GetCredentialByIDURL) Must(u *url.URL, err error) *url.URL

Must is a helper function to panic when the url builder returns an error

func (*GetCredentialByIDURL) SetBasePath

func (o *GetCredentialByIDURL) SetBasePath(bp string)

SetBasePath sets the base path for this url builder, only required when it's different from the base path specified in the swagger spec. When the value of the base path is an empty string

func (*GetCredentialByIDURL) String

func (o *GetCredentialByIDURL) String() string

String returns the string representation of the path with query string

func (*GetCredentialByIDURL) StringFull

func (o *GetCredentialByIDURL) StringFull(scheme, host string) string

StringFull returns the string representation of a complete url

func (*GetCredentialByIDURL) WithBasePath

func (o *GetCredentialByIDURL) WithBasePath(bp string) *GetCredentialByIDURL

WithBasePath sets the base path for this url builder, only required when it's different from the base path specified in the swagger spec. When the value of the base path is an empty string

type RenewalCredential

type RenewalCredential struct {
	Context *middleware.Context
	Handler RenewalCredentialHandler
}

RenewalCredential swagger:route PUT /credential/{credentialId} credential renewalCredential

Renewal a credential

This service updates a verifiable credential. First revoke the old credential with credential id, after generates a new credential with updated data from credential subject

func NewRenewalCredential

func NewRenewalCredential(ctx *middleware.Context, handler RenewalCredentialHandler) *RenewalCredential

NewRenewalCredential creates a new http.Handler for the renewal credential operation

func (*RenewalCredential) ServeHTTP

func (o *RenewalCredential) ServeHTTP(rw http.ResponseWriter, r *http.Request)

type RenewalCredentialBadRequest

type RenewalCredentialBadRequest struct {
}

RenewalCredentialBadRequest Invalid credential supplied

swagger:response renewalCredentialBadRequest

func NewRenewalCredentialBadRequest

func NewRenewalCredentialBadRequest() *RenewalCredentialBadRequest

NewRenewalCredentialBadRequest creates RenewalCredentialBadRequest with default headers values

func (*RenewalCredentialBadRequest) WriteResponse

func (o *RenewalCredentialBadRequest) WriteResponse(rw http.ResponseWriter, producer runtime.Producer)

WriteResponse to the client

type RenewalCredentialHandler

type RenewalCredentialHandler interface {
	Handle(RenewalCredentialParams) middleware.Responder
}

RenewalCredentialHandler interface for that can handle valid renewal credential params

type RenewalCredentialHandlerFunc

type RenewalCredentialHandlerFunc func(RenewalCredentialParams) middleware.Responder

RenewalCredentialHandlerFunc turns a function with the right signature into a renewal credential handler

func (RenewalCredentialHandlerFunc) Handle

Handle executing the request and returning a response

type RenewalCredentialInternalServerError

type RenewalCredentialInternalServerError struct {
}

RenewalCredentialInternalServerError Error Internal Server

swagger:response renewalCredentialInternalServerError

func NewRenewalCredentialInternalServerError

func NewRenewalCredentialInternalServerError() *RenewalCredentialInternalServerError

NewRenewalCredentialInternalServerError creates RenewalCredentialInternalServerError with default headers values

func (*RenewalCredentialInternalServerError) WriteResponse

WriteResponse to the client

type RenewalCredentialNotFound

type RenewalCredentialNotFound struct {
}

RenewalCredentialNotFound Credential ID not found

swagger:response renewalCredentialNotFound

func NewRenewalCredentialNotFound

func NewRenewalCredentialNotFound() *RenewalCredentialNotFound

NewRenewalCredentialNotFound creates RenewalCredentialNotFound with default headers values

func (*RenewalCredentialNotFound) WriteResponse

func (o *RenewalCredentialNotFound) WriteResponse(rw http.ResponseWriter, producer runtime.Producer)

WriteResponse to the client

type RenewalCredentialOK

type RenewalCredentialOK struct {

	/*
	  In: Body
	*/
	Payload *models.Credential `json:"body,omitempty"`
}

RenewalCredentialOK successful operation

swagger:response renewalCredentialOK

func NewRenewalCredentialOK

func NewRenewalCredentialOK() *RenewalCredentialOK

NewRenewalCredentialOK creates RenewalCredentialOK with default headers values

func (*RenewalCredentialOK) SetPayload

func (o *RenewalCredentialOK) SetPayload(payload *models.Credential)

SetPayload sets the payload to the renewal credential o k response

func (*RenewalCredentialOK) WithPayload

func (o *RenewalCredentialOK) WithPayload(payload *models.Credential) *RenewalCredentialOK

WithPayload adds the payload to the renewal credential o k response

func (*RenewalCredentialOK) WriteResponse

func (o *RenewalCredentialOK) WriteResponse(rw http.ResponseWriter, producer runtime.Producer)

WriteResponse to the client

type RenewalCredentialParams

type RenewalCredentialParams struct {

	// HTTP Request Object
	HTTPRequest *http.Request `json:"-"`

	/*The data credential that needs be updated.
	  Required: true
	  In: body
	*/
	Body *models.CredentialSubject
	/*Credential ID to update credential
	  Required: true
	  In: path
	*/
	CredentialID string
}

RenewalCredentialParams contains all the bound params for the renewal credential operation typically these are obtained from a http.Request

swagger:parameters renewalCredential

func NewRenewalCredentialParams

func NewRenewalCredentialParams() RenewalCredentialParams

NewRenewalCredentialParams creates a new RenewalCredentialParams object no default values defined in spec.

func (*RenewalCredentialParams) BindRequest

func (o *RenewalCredentialParams) BindRequest(r *http.Request, route *middleware.MatchedRoute) error

BindRequest both binds and validates a request, it assumes that complex things implement a Validatable(strfmt.Registry) error interface for simple values it will use straight method calls.

To ensure default values, the struct must have been initialized with NewRenewalCredentialParams() beforehand.

type RenewalCredentialURL

type RenewalCredentialURL struct {
	CredentialID string
	// contains filtered or unexported fields
}

RenewalCredentialURL generates an URL for the renewal credential operation

func (*RenewalCredentialURL) Build

func (o *RenewalCredentialURL) Build() (*url.URL, error)

Build a url path and query string

func (*RenewalCredentialURL) BuildFull

func (o *RenewalCredentialURL) BuildFull(scheme, host string) (*url.URL, error)

BuildFull builds a full url with scheme, host, path and query string

func (*RenewalCredentialURL) Must

func (o *RenewalCredentialURL) Must(u *url.URL, err error) *url.URL

Must is a helper function to panic when the url builder returns an error

func (*RenewalCredentialURL) SetBasePath

func (o *RenewalCredentialURL) SetBasePath(bp string)

SetBasePath sets the base path for this url builder, only required when it's different from the base path specified in the swagger spec. When the value of the base path is an empty string

func (*RenewalCredentialURL) String

func (o *RenewalCredentialURL) String() string

String returns the string representation of the path with query string

func (*RenewalCredentialURL) StringFull

func (o *RenewalCredentialURL) StringFull(scheme, host string) string

StringFull returns the string representation of a complete url

func (*RenewalCredentialURL) WithBasePath

func (o *RenewalCredentialURL) WithBasePath(bp string) *RenewalCredentialURL

WithBasePath sets the base path for this url builder, only required when it's different from the base path specified in the swagger spec. When the value of the base path is an empty string

type RevokeCredential

type RevokeCredential struct {
	Context *middleware.Context
	Handler RevokeCredentialHandler
}

RevokeCredential swagger:route DELETE /credential/{credentialId} credential revokeCredential

Revoke a credential

This service revokes a credential in the credential revocation list(Blockchain) providing a credential Id

func NewRevokeCredential

func NewRevokeCredential(ctx *middleware.Context, handler RevokeCredentialHandler) *RevokeCredential

NewRevokeCredential creates a new http.Handler for the revoke credential operation

func (*RevokeCredential) ServeHTTP

func (o *RevokeCredential) ServeHTTP(rw http.ResponseWriter, r *http.Request)

type RevokeCredentialBadRequest

type RevokeCredentialBadRequest struct {
}

RevokeCredentialBadRequest Invalid ID credential supplied

swagger:response revokeCredentialBadRequest

func NewRevokeCredentialBadRequest

func NewRevokeCredentialBadRequest() *RevokeCredentialBadRequest

NewRevokeCredentialBadRequest creates RevokeCredentialBadRequest with default headers values

func (*RevokeCredentialBadRequest) WriteResponse

func (o *RevokeCredentialBadRequest) WriteResponse(rw http.ResponseWriter, producer runtime.Producer)

WriteResponse to the client

type RevokeCredentialHandler

type RevokeCredentialHandler interface {
	Handle(RevokeCredentialParams) middleware.Responder
}

RevokeCredentialHandler interface for that can handle valid revoke credential params

type RevokeCredentialHandlerFunc

type RevokeCredentialHandlerFunc func(RevokeCredentialParams) middleware.Responder

RevokeCredentialHandlerFunc turns a function with the right signature into a revoke credential handler

func (RevokeCredentialHandlerFunc) Handle

Handle executing the request and returning a response

type RevokeCredentialInternalServerError

type RevokeCredentialInternalServerError struct {
}

RevokeCredentialInternalServerError Error Internal Server

swagger:response revokeCredentialInternalServerError

func NewRevokeCredentialInternalServerError

func NewRevokeCredentialInternalServerError() *RevokeCredentialInternalServerError

NewRevokeCredentialInternalServerError creates RevokeCredentialInternalServerError with default headers values

func (*RevokeCredentialInternalServerError) WriteResponse

WriteResponse to the client

type RevokeCredentialNotFound

type RevokeCredentialNotFound struct {
}

RevokeCredentialNotFound credential not found

swagger:response revokeCredentialNotFound

func NewRevokeCredentialNotFound

func NewRevokeCredentialNotFound() *RevokeCredentialNotFound

NewRevokeCredentialNotFound creates RevokeCredentialNotFound with default headers values

func (*RevokeCredentialNotFound) WriteResponse

func (o *RevokeCredentialNotFound) WriteResponse(rw http.ResponseWriter, producer runtime.Producer)

WriteResponse to the client

type RevokeCredentialOK

type RevokeCredentialOK struct {
}

RevokeCredentialOK successful operation

swagger:response revokeCredentialOK

func NewRevokeCredentialOK

func NewRevokeCredentialOK() *RevokeCredentialOK

NewRevokeCredentialOK creates RevokeCredentialOK with default headers values

func (*RevokeCredentialOK) WriteResponse

func (o *RevokeCredentialOK) WriteResponse(rw http.ResponseWriter, producer runtime.Producer)

WriteResponse to the client

type RevokeCredentialParams

type RevokeCredentialParams struct {

	// HTTP Request Object
	HTTPRequest *http.Request `json:"-"`

	/*Credential ID to revoke
	  Required: true
	  In: path
	*/
	CredentialID string
}

RevokeCredentialParams contains all the bound params for the revoke credential operation typically these are obtained from a http.Request

swagger:parameters revokeCredential

func NewRevokeCredentialParams

func NewRevokeCredentialParams() RevokeCredentialParams

NewRevokeCredentialParams creates a new RevokeCredentialParams object no default values defined in spec.

func (*RevokeCredentialParams) BindRequest

func (o *RevokeCredentialParams) BindRequest(r *http.Request, route *middleware.MatchedRoute) error

BindRequest both binds and validates a request, it assumes that complex things implement a Validatable(strfmt.Registry) error interface for simple values it will use straight method calls.

To ensure default values, the struct must have been initialized with NewRevokeCredentialParams() beforehand.

type RevokeCredentialURL

type RevokeCredentialURL struct {
	CredentialID string
	// contains filtered or unexported fields
}

RevokeCredentialURL generates an URL for the revoke credential operation

func (*RevokeCredentialURL) Build

func (o *RevokeCredentialURL) Build() (*url.URL, error)

Build a url path and query string

func (*RevokeCredentialURL) BuildFull

func (o *RevokeCredentialURL) BuildFull(scheme, host string) (*url.URL, error)

BuildFull builds a full url with scheme, host, path and query string

func (*RevokeCredentialURL) Must

func (o *RevokeCredentialURL) Must(u *url.URL, err error) *url.URL

Must is a helper function to panic when the url builder returns an error

func (*RevokeCredentialURL) SetBasePath

func (o *RevokeCredentialURL) SetBasePath(bp string)

SetBasePath sets the base path for this url builder, only required when it's different from the base path specified in the swagger spec. When the value of the base path is an empty string

func (*RevokeCredentialURL) String

func (o *RevokeCredentialURL) String() string

String returns the string representation of the path with query string

func (*RevokeCredentialURL) StringFull

func (o *RevokeCredentialURL) StringFull(scheme, host string) string

StringFull returns the string representation of a complete url

func (*RevokeCredentialURL) WithBasePath

func (o *RevokeCredentialURL) WithBasePath(bp string) *RevokeCredentialURL

WithBasePath sets the base path for this url builder, only required when it's different from the base path specified in the swagger spec. When the value of the base path is an empty string

type SendCredential

type SendCredential struct {
	Context *middleware.Context
	Handler SendCredentialHandler
}

SendCredential swagger:route POST /credential/send credential sendCredential

send a credential

This service verify the credential exist into blockchain and send the credential by email

func NewSendCredential

func NewSendCredential(ctx *middleware.Context, handler SendCredentialHandler) *SendCredential

NewSendCredential creates a new http.Handler for the send credential operation

func (*SendCredential) ServeHTTP

func (o *SendCredential) ServeHTTP(rw http.ResponseWriter, r *http.Request)

type SendCredentialBadRequest

type SendCredentialBadRequest struct {
}

SendCredentialBadRequest Invalid credential supplied

swagger:response sendCredentialBadRequest

func NewSendCredentialBadRequest

func NewSendCredentialBadRequest() *SendCredentialBadRequest

NewSendCredentialBadRequest creates SendCredentialBadRequest with default headers values

func (*SendCredentialBadRequest) WriteResponse

func (o *SendCredentialBadRequest) WriteResponse(rw http.ResponseWriter, producer runtime.Producer)

WriteResponse to the client

type SendCredentialHandler

type SendCredentialHandler interface {
	Handle(SendCredentialParams) middleware.Responder
}

SendCredentialHandler interface for that can handle valid send credential params

type SendCredentialHandlerFunc

type SendCredentialHandlerFunc func(SendCredentialParams) middleware.Responder

SendCredentialHandlerFunc turns a function with the right signature into a send credential handler

func (SendCredentialHandlerFunc) Handle

Handle executing the request and returning a response

type SendCredentialInternalServerError

type SendCredentialInternalServerError struct {
}

SendCredentialInternalServerError Error Internal Server

swagger:response sendCredentialInternalServerError

func NewSendCredentialInternalServerError

func NewSendCredentialInternalServerError() *SendCredentialInternalServerError

NewSendCredentialInternalServerError creates SendCredentialInternalServerError with default headers values

func (*SendCredentialInternalServerError) WriteResponse

func (o *SendCredentialInternalServerError) WriteResponse(rw http.ResponseWriter, producer runtime.Producer)

WriteResponse to the client

type SendCredentialNotFound

type SendCredentialNotFound struct {
}

SendCredentialNotFound DID not found

swagger:response sendCredentialNotFound

func NewSendCredentialNotFound

func NewSendCredentialNotFound() *SendCredentialNotFound

NewSendCredentialNotFound creates SendCredentialNotFound with default headers values

func (*SendCredentialNotFound) WriteResponse

func (o *SendCredentialNotFound) WriteResponse(rw http.ResponseWriter, producer runtime.Producer)

WriteResponse to the client

type SendCredentialOK

type SendCredentialOK struct {

	/*
	  In: Body
	*/
	Payload *models.VerifyResponse `json:"body,omitempty"`
}

SendCredentialOK successful operation

swagger:response sendCredentialOK

func NewSendCredentialOK

func NewSendCredentialOK() *SendCredentialOK

NewSendCredentialOK creates SendCredentialOK with default headers values

func (*SendCredentialOK) SetPayload

func (o *SendCredentialOK) SetPayload(payload *models.VerifyResponse)

SetPayload sets the payload to the send credential o k response

func (*SendCredentialOK) WithPayload

func (o *SendCredentialOK) WithPayload(payload *models.VerifyResponse) *SendCredentialOK

WithPayload adds the payload to the send credential o k response

func (*SendCredentialOK) WriteResponse

func (o *SendCredentialOK) WriteResponse(rw http.ResponseWriter, producer runtime.Producer)

WriteResponse to the client

type SendCredentialParams

type SendCredentialParams struct {

	// HTTP Request Object
	HTTPRequest *http.Request `json:"-"`

	/*the credentials that needs be sent.
	  Required: true
	  In: body
	*/
	Body []*models.Credential
}

SendCredentialParams contains all the bound params for the send credential operation typically these are obtained from a http.Request

swagger:parameters sendCredential

func NewSendCredentialParams

func NewSendCredentialParams() SendCredentialParams

NewSendCredentialParams creates a new SendCredentialParams object no default values defined in spec.

func (*SendCredentialParams) BindRequest

func (o *SendCredentialParams) BindRequest(r *http.Request, route *middleware.MatchedRoute) error

BindRequest both binds and validates a request, it assumes that complex things implement a Validatable(strfmt.Registry) error interface for simple values it will use straight method calls.

To ensure default values, the struct must have been initialized with NewSendCredentialParams() beforehand.

type SendCredentialURL

type SendCredentialURL struct {
	// contains filtered or unexported fields
}

SendCredentialURL generates an URL for the send credential operation

func (*SendCredentialURL) Build

func (o *SendCredentialURL) Build() (*url.URL, error)

Build a url path and query string

func (*SendCredentialURL) BuildFull

func (o *SendCredentialURL) BuildFull(scheme, host string) (*url.URL, error)

BuildFull builds a full url with scheme, host, path and query string

func (*SendCredentialURL) Must

func (o *SendCredentialURL) Must(u *url.URL, err error) *url.URL

Must is a helper function to panic when the url builder returns an error

func (*SendCredentialURL) SetBasePath

func (o *SendCredentialURL) SetBasePath(bp string)

SetBasePath sets the base path for this url builder, only required when it's different from the base path specified in the swagger spec. When the value of the base path is an empty string

func (*SendCredentialURL) String

func (o *SendCredentialURL) String() string

String returns the string representation of the path with query string

func (*SendCredentialURL) StringFull

func (o *SendCredentialURL) StringFull(scheme, host string) string

StringFull returns the string representation of a complete url

func (*SendCredentialURL) WithBasePath

func (o *SendCredentialURL) WithBasePath(bp string) *SendCredentialURL

WithBasePath sets the base path for this url builder, only required when it's different from the base path specified in the swagger spec. When the value of the base path is an empty string

type VerifyCredential

type VerifyCredential struct {
	Context *middleware.Context
	Handler VerifyCredentialHandler
}

VerifyCredential swagger:route POST /credential/verify credential verifyCredential

Verify a credential

This service verify into blockchain if the credentials are current and these were not revoked

func NewVerifyCredential

func NewVerifyCredential(ctx *middleware.Context, handler VerifyCredentialHandler) *VerifyCredential

NewVerifyCredential creates a new http.Handler for the verify credential operation

func (*VerifyCredential) ServeHTTP

func (o *VerifyCredential) ServeHTTP(rw http.ResponseWriter, r *http.Request)

type VerifyCredentialBadRequest

type VerifyCredentialBadRequest struct {
}

VerifyCredentialBadRequest Invalid credential supplied

swagger:response verifyCredentialBadRequest

func NewVerifyCredentialBadRequest

func NewVerifyCredentialBadRequest() *VerifyCredentialBadRequest

NewVerifyCredentialBadRequest creates VerifyCredentialBadRequest with default headers values

func (*VerifyCredentialBadRequest) WriteResponse

func (o *VerifyCredentialBadRequest) WriteResponse(rw http.ResponseWriter, producer runtime.Producer)

WriteResponse to the client

type VerifyCredentialHandler

type VerifyCredentialHandler interface {
	Handle(VerifyCredentialParams) middleware.Responder
}

VerifyCredentialHandler interface for that can handle valid verify credential params

type VerifyCredentialHandlerFunc

type VerifyCredentialHandlerFunc func(VerifyCredentialParams) middleware.Responder

VerifyCredentialHandlerFunc turns a function with the right signature into a verify credential handler

func (VerifyCredentialHandlerFunc) Handle

Handle executing the request and returning a response

type VerifyCredentialInternalServerError

type VerifyCredentialInternalServerError struct {
}

VerifyCredentialInternalServerError Error Internal Server

swagger:response verifyCredentialInternalServerError

func NewVerifyCredentialInternalServerError

func NewVerifyCredentialInternalServerError() *VerifyCredentialInternalServerError

NewVerifyCredentialInternalServerError creates VerifyCredentialInternalServerError with default headers values

func (*VerifyCredentialInternalServerError) WriteResponse

WriteResponse to the client

type VerifyCredentialNotFound

type VerifyCredentialNotFound struct {
}

VerifyCredentialNotFound DID not found

swagger:response verifyCredentialNotFound

func NewVerifyCredentialNotFound

func NewVerifyCredentialNotFound() *VerifyCredentialNotFound

NewVerifyCredentialNotFound creates VerifyCredentialNotFound with default headers values

func (*VerifyCredentialNotFound) WriteResponse

func (o *VerifyCredentialNotFound) WriteResponse(rw http.ResponseWriter, producer runtime.Producer)

WriteResponse to the client

type VerifyCredentialOK

type VerifyCredentialOK struct {

	/*
	  In: Body
	*/
	Payload *models.VerifyResponse `json:"body,omitempty"`
}

VerifyCredentialOK successful operation

swagger:response verifyCredentialOK

func NewVerifyCredentialOK

func NewVerifyCredentialOK() *VerifyCredentialOK

NewVerifyCredentialOK creates VerifyCredentialOK with default headers values

func (*VerifyCredentialOK) SetPayload

func (o *VerifyCredentialOK) SetPayload(payload *models.VerifyResponse)

SetPayload sets the payload to the verify credential o k response

func (*VerifyCredentialOK) WithPayload

func (o *VerifyCredentialOK) WithPayload(payload *models.VerifyResponse) *VerifyCredentialOK

WithPayload adds the payload to the verify credential o k response

func (*VerifyCredentialOK) WriteResponse

func (o *VerifyCredentialOK) WriteResponse(rw http.ResponseWriter, producer runtime.Producer)

WriteResponse to the client

type VerifyCredentialParams

type VerifyCredentialParams struct {

	// HTTP Request Object
	HTTPRequest *http.Request `json:"-"`

	/*the credentials that needs be validated.
	  Required: true
	  In: body
	*/
	Body []*models.CredentialData
}

VerifyCredentialParams contains all the bound params for the verify credential operation typically these are obtained from a http.Request

swagger:parameters verifyCredential

func NewVerifyCredentialParams

func NewVerifyCredentialParams() VerifyCredentialParams

NewVerifyCredentialParams creates a new VerifyCredentialParams object no default values defined in spec.

func (*VerifyCredentialParams) BindRequest

func (o *VerifyCredentialParams) BindRequest(r *http.Request, route *middleware.MatchedRoute) error

BindRequest both binds and validates a request, it assumes that complex things implement a Validatable(strfmt.Registry) error interface for simple values it will use straight method calls.

To ensure default values, the struct must have been initialized with NewVerifyCredentialParams() beforehand.

type VerifyCredentialURL

type VerifyCredentialURL struct {
	// contains filtered or unexported fields
}

VerifyCredentialURL generates an URL for the verify credential operation

func (*VerifyCredentialURL) Build

func (o *VerifyCredentialURL) Build() (*url.URL, error)

Build a url path and query string

func (*VerifyCredentialURL) BuildFull

func (o *VerifyCredentialURL) BuildFull(scheme, host string) (*url.URL, error)

BuildFull builds a full url with scheme, host, path and query string

func (*VerifyCredentialURL) Must

func (o *VerifyCredentialURL) Must(u *url.URL, err error) *url.URL

Must is a helper function to panic when the url builder returns an error

func (*VerifyCredentialURL) SetBasePath

func (o *VerifyCredentialURL) SetBasePath(bp string)

SetBasePath sets the base path for this url builder, only required when it's different from the base path specified in the swagger spec. When the value of the base path is an empty string

func (*VerifyCredentialURL) String

func (o *VerifyCredentialURL) String() string

String returns the string representation of the path with query string

func (*VerifyCredentialURL) StringFull

func (o *VerifyCredentialURL) StringFull(scheme, host string) string

StringFull returns the string representation of a complete url

func (*VerifyCredentialURL) WithBasePath

func (o *VerifyCredentialURL) WithBasePath(bp string) *VerifyCredentialURL

WithBasePath sets the base path for this url builder, only required when it's different from the base path specified in the swagger spec. When the value of the base path is an empty string

Jump to

Keyboard shortcuts

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