Documentation ¶
Index ¶
- type Correlation
- type CreateIndicatorRequest
- type CreateOrUpdateObservationRequest
- type CreateUserRequest
- type Dataset
- type ErrorResponse
- type FindUserCorrelationsRequest
- type GetCorrelationMatrixRequest
- type GetCorrelationMatrixResponse
- type GetCorrelationMatrixResponseBodyItem
- type GetCorrelationMatrixResponseHeaderItem
- type GetCorrelationRequest
- type GetCorrelationResponse
- type GetIndicatorsRequest
- type GetIndicatorsRequestFilter
- type GetIndicatorsResponse
- type GetIndicatorsResponseItem
- type GetTokenRequest
- type GetTokenResponse
- type GetUserRequest
- type GetUserResponse
- type Indicator
- type OKResponse
- type Observation
- type ServiceStatsResponse
- type UpdateAggregationsRequest
- type UpdateIndicatorRequest
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Correlation ¶
type Correlation struct { ID int `json:"correlationID"` Coef float64 `json:"coef"` P float64 `json:"p"` R2 float64 `json:"r2"` Type string `json:"type"` Granularity string `json:"granularity"` UpdateTime time.Time `json:"updateTime"` Left *Dataset `json:"left,omitempty"` Right *Dataset `json:"right,omitempty"` }
Correlation is a common model to use in various methods
type CreateIndicatorRequest ¶
type CreateUserRequest ¶
type Dataset ¶
type Dataset struct { ID int `json:"id,omitempty"` Source string `json:"source,omitempty"` Granularity string `json:"granularity"` Style domain.DatasetStyle `json:"style,omitempty"` Aggregation domain.DatasetAggregation `json:"aggregation,omitempty"` Observations []Observation `json:"observations,omitempty"` }
Dataset is a common model to use in various methods
type ErrorResponse ¶
type ErrorResponse struct { Error string `json:"error,omitempty"` Message string `json:"message,omitempty"` }
ErrorResponse is default error response schema
type FindUserCorrelationsRequest ¶
type FindUserCorrelationsRequest struct { UserID int `json:"userID"` }
FindUserCorrelationsRequest is just for testing
type GetCorrelationMatrixRequest ¶
type GetCorrelationMatrixRequest struct { Granularity string `json:"granularity"` }
type GetCorrelationMatrixResponse ¶
type GetCorrelationMatrixResponse struct { Granularity string `json:"granularity"` Header []GetCorrelationMatrixResponseHeaderItem `json:"header"` Body [][]GetCorrelationMatrixResponseBodyItem `json:"body"` }
type GetCorrelationRequest ¶
type GetCorrelationRequest struct {
ID int `json:"id"`
}
type GetCorrelationResponse ¶
type GetCorrelationResponse struct {
Correlation
}
type GetIndicatorsRequest ¶
type GetIndicatorsRequest struct { WithDataset bool `json:"withDataset"` ObservationsLimit int `json:"observationsLimit"` Granularity string `json:"granularity"` Filter GetIndicatorsRequestFilter `json:"filter"` }
type GetIndicatorsResponse ¶
type GetIndicatorsResponse []GetIndicatorsResponseItem
type GetIndicatorsResponseItem ¶
type GetIndicatorsResponseItem struct {
Indicator
}
type GetTokenRequest ¶
type GetTokenResponse ¶
type GetTokenResponse struct {
Token string `json:"token"`
}
type GetUserRequest ¶
type GetUserRequest struct{}
type GetUserResponse ¶
type Indicator ¶
type Indicator struct { ID int `json:"id"` Code string `json:"code"` Title string `json:"title"` Description string `json:"description"` Active bool `json:"active"` BuiltIn bool `json:"builtIn"` External bool `json:"external"` ScaleID int `json:"scaleID"` AuthorID int `json:"authorID,omitempty"` CreateTime time.Time `json:"createTime"` UpdateTime time.Time `json:"updateTime"` ValueMapping map[string]string `json:"valueMapping,omitempty"` ValueParams *domain.IndicatorValueParams `json:"valueParams,omitempty"` Dataset *Dataset `json:"dataset,omitempty"` }
Indicator is a common model to use in various methods
type OKResponse ¶
type OKResponse struct { Status string `json:"status,omitempty"` Message string `json:"message,omitempty"` }
OKResponse is default ok response schema
type Observation ¶
type Observation struct { ID int `json:"id"` Value float64 `json:"value"` Date *time.Time `json:"date"` }
Observation is a common model to use in various methods
type ServiceStatsResponse ¶ added in v0.0.5
type UpdateAggregationsRequest ¶
type UpdateAggregationsRequest struct {
DatasetID int `json:"datasetID"`
}
UpdateAggregationsRequest is just for testing
type UpdateIndicatorRequest ¶ added in v0.0.8
Click to show internal directories.
Click to hide internal directories.