openapi

package
v0.0.0-...-29719d2 Latest Latest
Warning

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

Go to latest
Published: Feb 4, 2025 License: GPL-3.0 Imports: 1 Imported by: 0

Documentation

Overview

Package openapi provides primitives to interact with the openapi HTTP API.

Code generated by github.com/oapi-codegen/oapi-codegen/v2 version (devel) DO NOT EDIT.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type DeliveryMethod

type DeliveryMethod struct {
	// ID A short string representing the delivery method. This is what goes into the DeliveryMethod fields.
	ID string `json:"id"`

	// Units The units of the delivery method.
	Units string `json:"units"`

	// Name The full name of the delivery method.
	Name string `json:"name"`

	// Description A description of the delivery method.
	Description string `json:"description,omitempty"`
}

DeliveryMethod defines model for DeliveryMethod.

type Dosage

type Dosage struct {
	// DeliveryMethod The delivery method to use.
	DeliveryMethod string `json:"deliveryMethod"`

	// Dose The dosage amount.
	Dose float32 `json:"dose"`

	// Interval The interval between doses in days.
	Interval float64 `json:"interval"`

	// Concurrence The number of estrogen patches on the body at once. Only relevant if delivery method is patch.
	Concurrence *int `json:"concurrence,omitempty"`
}

Dosage defines model for Dosage.

type DosageHistory

type DosageHistory = []Dose

DosageHistory defines model for DosageHistory.

type DosageHistoryCSV

type DosageHistoryCSV = string

DosageHistoryCSV The CSV format of the user's dosage history.

type DosageParams

type DosageParams struct {
	Start *time.Time `form:"start,omitempty" json:"start,omitempty"`
	End   *time.Time `form:"end,omitempty" json:"end,omitempty"`
}

DosageParams defines parameters for Dosage.

type Dose

type Dose struct {
	// DeliveryMethod The delivery method used.
	DeliveryMethod string `json:"deliveryMethod"`

	// Dose The dosage amount.
	Dose float32 `json:"dose"`

	// TakenAt The time the dosage was taken.
	TakenAt time.Time `json:"takenAt"`

	// TakenOffAt The time the dosage was taken off. This is only relevant for patch delivery methods.
	TakenOffAt *time.Time `json:"takenOffAt,omitempty"`

	// Comment A comment about the dosage, if any.
	Comment *string `json:"comment,omitempty"`
}

Dose A dose of medication in time.

type EditDoseJSONBody

type EditDoseJSONBody = Dose

EditDoseJSONBody defines parameters for EditDose.

type EditDoseJSONRequestBody

type EditDoseJSONRequestBody = EditDoseJSONBody

EditDoseJSONRequestBody defines body for EditDose for application/json ContentType.

type ExportDosesParams

type ExportDosesParams struct {
	Start *time.Time `form:"start,omitempty" json:"start,omitempty"`
	End   *time.Time `form:"end,omitempty" json:"end,omitempty"`

	// Accept The format to export the dosage history in.
	Accept ExportDosesParamsAccept `json:"Accept"`
}

ExportDosesParams defines parameters for ExportDoses.

type ExportDosesParamsAccept

type ExportDosesParamsAccept string

ExportDosesParamsAccept defines parameters for ExportDoses.

const (
	ExportDosesParamsAcceptApplicationJSON ExportDosesParamsAccept = "application/json"
	ExportDosesParamsAcceptTextCsv         ExportDosesParamsAccept = "text/csv"
)

Defines values for ExportDosesParamsAccept.

type ForgetDosesParams

type ForgetDosesParams struct {
	DoseTimes []time.Time `form:"doseTimes" json:"doseTimes"`
}

ForgetDosesParams defines parameters for ForgetDoses.

type ImportDosesJSONRequestBody

type ImportDosesJSONRequestBody = DosageHistory

ImportDosesJSONRequestBody defines body for ImportDoses for application/json ContentType.

type ImportDosesParams

type ImportDosesParams struct {
	// ContentType The format to import the dosage history as.
	ContentType ImportDosesParamsContentType `json:"Content-Type"`
}

ImportDosesParams defines parameters for ImportDoses.

type ImportDosesParamsContentType

type ImportDosesParamsContentType string

ImportDosesParamsContentType defines parameters for ImportDoses.

const (
	ImportDosesParamsContentTypeApplicationJSON ImportDosesParamsContentType = "application/json"
	ImportDosesParamsContentTypeTextCsv         ImportDosesParamsContentType = "text/csv"
)

Defines values for ImportDosesParamsContentType.

type SetDosageJSONRequestBody

type SetDosageJSONRequestBody = Dosage

SetDosageJSONRequestBody defines body for SetDosage for application/json ContentType.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL
JackTT - Gopher 🇻🇳