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 ¶
- type DeliveryMethod
- type Dosage
- type DosageHistory
- type DosageHistoryCSV
- type DosageParams
- type Dose
- type EditDoseJSONBody
- type EditDoseJSONRequestBody
- type ExportDosesParams
- type ExportDosesParamsAccept
- type ForgetDosesParams
- type ImportDosesJSONRequestBody
- type ImportDosesParams
- type ImportDosesParamsContentType
- type RecordDoseJSONBody
- type RecordDoseJSONRequestBody
- type SetDosageJSONRequestBody
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 meta.Days `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"`
// ReminderRecurrence A list of reminder recurrences for the reminder notification.
// Each recurrence is a number that represents the number of days after the time of the first notification to send the reminder notification.
ReminderRecurrence []meta.Days `json:"reminderRecurrence,omitempty"`
}
Dosage defines model for Dosage.
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 ¶
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 RecordDoseJSONBody ¶
type RecordDoseJSONBody struct {
// TakenAt The time the dosage was taken. If not provided, the current time is used.
TakenAt *time.Time `json:"takenAt,omitempty"`
}
RecordDoseJSONBody defines parameters for RecordDose.
type RecordDoseJSONRequestBody ¶
type RecordDoseJSONRequestBody RecordDoseJSONBody
RecordDoseJSONRequestBody defines body for RecordDose for application/json ContentType.
type SetDosageJSONRequestBody ¶
type SetDosageJSONRequestBody = Dosage
SetDosageJSONRequestBody defines body for SetDosage for application/json ContentType.