uid

package
v0.1298.0-MLPAB2241sen... Latest Latest
Warning

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

Go to latest
Published: Jul 15, 2024 License: MIT Imports: 8 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Client

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

func New

func New(baseURL string, lambdaClient Doer) *Client

func (*Client) CheckHealth added in v0.892.0

func (c *Client) CheckHealth(ctx context.Context) error

func (*Client) CreateCase

func (c *Client) CreateCase(ctx context.Context, body *CreateCaseRequestBody) (string, error)

type CreateCaseRequestBody

type CreateCaseRequestBody struct {
	Type   string       `json:"type"`
	Source string       `json:"source"`
	Donor  DonorDetails `json:"donor"`
}

func (CreateCaseRequestBody) Valid

func (b CreateCaseRequestBody) Valid() bool

type CreateCaseResponse

type CreateCaseResponse struct {
	UID              string                              `json:"uid"`
	BadRequestErrors []CreateCaseResponseBadRequestError `json:"errors"`
}

func (*CreateCaseResponse) Error

func (c *CreateCaseResponse) Error() error

type CreateCaseResponseBadRequestError

type CreateCaseResponseBadRequestError struct {
	Source string `json:"source"`
	Detail string `json:"detail"`
}

type Doer

type Doer interface {
	Do(*http.Request) (*http.Response, error)
}

type DonorDetails

type DonorDetails struct {
	Name     string    `json:"name"`
	Dob      date.Date `json:"dob"`
	Postcode string    `json:"postcode"`
}

Jump to

Keyboard shortcuts

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