From 39ae9f98db435a06d6f8b786b72b40a2e2b7c6de Mon Sep 17 00:00:00 2001 From: Jens Langhammer Date: Fri, 18 Oct 2024 01:19:50 +0200 Subject: [PATCH] tag version v0.9.3 --- Makefile | 2 +- api/.openapi-generator/FILES | 2 + api/README.md | 7 +- api/api/openapi.yaml | 149 ++++++------ api/api_cluster_instances.go | 2 +- api/api_roles_api.go | 218 +----------------- api/api_roles_backup.go | 2 +- api/api_roles_dhcp.go | 2 +- api/api_roles_discovery.go | 2 +- api/api_roles_dns.go | 110 +-------- api/api_roles_etcd.go | 2 +- api/api_roles_monitoring.go | 2 +- api/api_roles_tsdb.go | 149 +++++++++++- api/client.go | 4 +- api/configuration.go | 2 +- api/docs/RolesApiApi.md | 120 ---------- api/docs/RolesDnsApi.md | 60 ----- api/docs/RolesTsdbApi.md | 72 ++++++ api/docs/TypesAPIMetricsRecord.md | 40 ++-- api/docs/TypesAPIMetricsRole.md | 13 ++ api/model_api_api_export_input.go | 2 +- api/model_api_api_export_output.go | 2 +- api/model_api_api_import_input.go | 2 +- api/model_api_api_log_message.go | 2 +- api/model_api_api_log_messages.go | 2 +- api/model_api_api_member.go | 2 +- api/model_api_api_member_join_input.go | 2 +- api/model_api_api_member_join_output.go | 2 +- api/model_api_api_members_output.go | 2 +- api/model_api_api_role_config_input.go | 2 +- api/model_api_api_role_config_output.go | 2 +- api/model_api_api_tool_ping_input.go | 2 +- api/model_api_api_tool_ping_output.go | 2 +- api/model_api_api_tool_portmap_input.go | 2 +- api/model_api_api_tool_portmap_output.go | 2 +- api/model_api_api_tool_portmap_output_port.go | 2 +- api/model_api_api_tool_traceroute_input.go | 2 +- api/model_api_api_tool_traceroute_output.go | 2 +- ...odel_api_api_tool_traceroute_output_hop.go | 2 +- api/model_api_api_transport_entry.go | 2 +- api/model_api_role_config.go | 2 +- api/model_auth_api_config_output.go | 2 +- api/model_auth_api_login_input.go | 2 +- api/model_auth_api_login_output.go | 2 +- api/model_auth_api_token.go | 2 +- api/model_auth_api_tokens_get_output.go | 2 +- api/model_auth_api_tokens_put_output.go | 2 +- api/model_auth_api_user.go | 2 +- api/model_auth_api_users_get_output.go | 2 +- api/model_auth_api_users_put_input.go | 2 +- api/model_auth_apime_output.go | 2 +- api/model_backup_api_backup_status.go | 2 +- api/model_backup_api_backup_status_output.go | 2 +- api/model_backup_api_role_config_input.go | 2 +- api/model_backup_api_role_config_output.go | 2 +- api/model_backup_backup_status.go | 2 +- api/model_backup_role_config.go | 2 +- api/model_dhcp_api_lease.go | 2 +- api/model_dhcp_api_lease_info.go | 2 +- api/model_dhcp_api_leases_get_output.go | 2 +- api/model_dhcp_api_leases_put_input.go | 2 +- api/model_dhcp_api_role_config_input.go | 2 +- api/model_dhcp_api_role_config_output.go | 2 +- api/model_dhcp_api_scope.go | 2 +- api/model_dhcp_api_scopes_get_output.go | 2 +- api/model_dhcp_api_scopes_put_input.go | 2 +- api/model_dhcp_role_config.go | 2 +- api/model_dhcp_scope_dns.go | 2 +- api/model_discovery_api_device.go | 2 +- ...model_discovery_api_devices_apply_input.go | 2 +- api/model_discovery_api_devices_get_output.go | 2 +- api/model_discovery_api_role_config_input.go | 2 +- api/model_discovery_api_role_config_output.go | 2 +- api/model_discovery_api_subnet.go | 2 +- api/model_discovery_api_subnets_get_output.go | 2 +- api/model_discovery_api_subnets_put_input.go | 2 +- api/model_discovery_role_config.go | 2 +- api/model_dns_api_record.go | 2 +- api/model_dns_api_records_get_output.go | 2 +- api/model_dns_api_records_put_input.go | 2 +- api/model_dns_api_role_config_input.go | 2 +- api/model_dns_api_role_config_output.go | 2 +- api/model_dns_api_zone.go | 2 +- api/model_dns_api_zones_get_output.go | 2 +- api/model_dns_api_zones_put_input.go | 2 +- api/model_dns_role_config.go | 2 +- api/model_extconfig_ext_config_dirs.go | 2 +- api/model_instance_api_instance_info.go | 2 +- api/model_instance_api_instances_output.go | 2 +- api/model_instance_api_role_restart_input.go | 2 +- api/model_instance_instance_info.go | 2 +- api/model_monitoring_api_role_config_input.go | 2 +- ...model_monitoring_api_role_config_output.go | 2 +- api/model_monitoring_role_config.go | 2 +- api/model_rest_err_response.go | 2 +- api/model_tsdb_api_role_config_input.go | 2 +- api/model_tsdb_api_role_config_output.go | 2 +- api/model_tsdb_role_config.go | 2 +- api/model_types_api_metrics_get_output.go | 2 +- api/model_types_api_metrics_record.go | 51 ++-- api/model_types_api_metrics_role.go | 110 +++++++++ api/model_types_dhcp_option.go | 2 +- api/model_types_oidc_config.go | 2 +- api/response.go | 2 +- api/utils.go | 2 +- schema.yml | 2 +- web/package-lock.json | 12 +- web/package.json | 4 +- 108 files changed, 585 insertions(+), 720 deletions(-) create mode 100644 api/docs/TypesAPIMetricsRole.md create mode 100644 api/model_types_api_metrics_role.go diff --git a/Makefile b/Makefile index e81c9b8f1..1e3ed5a92 100644 --- a/Makefile +++ b/Makefile @@ -3,7 +3,7 @@ PWD = $(shell pwd) UID = $(shell id -u) GID = $(shell id -g) -VERSION = "0.9.2" +VERSION = "0.9.3" LD_FLAGS = -X beryju.io/gravity/pkg/extconfig.Version=${VERSION} GO_FLAGS = -ldflags "${LD_FLAGS}" -v SCHEMA_FILE = schema.yml diff --git a/api/.openapi-generator/FILES b/api/.openapi-generator/FILES index 6f15899eb..cf91a43e1 100755 --- a/api/.openapi-generator/FILES +++ b/api/.openapi-generator/FILES @@ -102,6 +102,7 @@ docs/TsdbAPIRoleConfigOutput.md docs/TsdbRoleConfig.md docs/TypesAPIMetricsGetOutput.md docs/TypesAPIMetricsRecord.md +docs/TypesAPIMetricsRole.md docs/TypesDHCPOption.md docs/TypesOIDCConfig.md git_push.sh @@ -187,6 +188,7 @@ model_tsdb_api_role_config_output.go model_tsdb_role_config.go model_types_api_metrics_get_output.go model_types_api_metrics_record.go +model_types_api_metrics_role.go model_types_dhcp_option.go model_types_oidc_config.go response.go diff --git a/api/README.md b/api/README.md index 0a77f7ad0..4054ae4cf 100755 --- a/api/README.md +++ b/api/README.md @@ -5,7 +5,7 @@ No description provided (generated by Openapi Generator https://github.com/opena ## Overview This API client was generated by the [OpenAPI Generator](https://openapi-generator.tech) project. By using the [OpenAPI-spec](https://www.openapis.org/) from a remote server, you can easily generate an API client. -- API version: 0.9.2 +- API version: 0.9.3 - Package version: 1.0.0 - Build package: org.openapitools.codegen.languages.GoClientCodegen @@ -86,8 +86,6 @@ Class | Method | HTTP request | Description *RolesApiApi* | [**ApiExport**](docs/RolesApiApi.md#apiexport) | **Post** /api/v1/cluster/export | Export Cluster *RolesApiApi* | [**ApiGetLogMessages**](docs/RolesApiApi.md#apigetlogmessages) | **Get** /api/v1/cluster/node/logs | Log messages *RolesApiApi* | [**ApiGetMembers**](docs/RolesApiApi.md#apigetmembers) | **Get** /api/v1/etcd/members | Etcd members -*RolesApiApi* | [**ApiGetMetricsCpu**](docs/RolesApiApi.md#apigetmetricscpu) | **Get** /api/v1/system/metrics/cpu | System Metrics -*RolesApiApi* | [**ApiGetMetricsMemory**](docs/RolesApiApi.md#apigetmetricsmemory) | **Get** /api/v1/system/metrics/memory | System Metrics *RolesApiApi* | [**ApiGetRoleConfig**](docs/RolesApiApi.md#apigetroleconfig) | **Get** /api/v1/roles/api | API role config *RolesApiApi* | [**ApiGetTokens**](docs/RolesApiApi.md#apigettokens) | **Get** /api/v1/auth/tokens | Tokens *RolesApiApi* | [**ApiGetUsers**](docs/RolesApiApi.md#apigetusers) | **Get** /api/v1/auth/users | API Users @@ -124,7 +122,6 @@ Class | Method | HTTP request | Description *RolesDiscoveryApi* | [**DiscoverySubnetStart**](docs/RolesDiscoveryApi.md#discoverysubnetstart) | **Post** /api/v1/discovery/subnets/start | Discovery Subnets *RolesDnsApi* | [**DnsDeleteRecords**](docs/RolesDnsApi.md#dnsdeleterecords) | **Delete** /api/v1/dns/zones/records | DNS Records *RolesDnsApi* | [**DnsDeleteZones**](docs/RolesDnsApi.md#dnsdeletezones) | **Delete** /api/v1/dns/zones | DNS Zones -*RolesDnsApi* | [**DnsGetMetrics**](docs/RolesDnsApi.md#dnsgetmetrics) | **Get** /api/v1/dns/metrics | DNS Metrics *RolesDnsApi* | [**DnsGetRecords**](docs/RolesDnsApi.md#dnsgetrecords) | **Get** /api/v1/dns/zones/records | DNS Records *RolesDnsApi* | [**DnsGetRoleConfig**](docs/RolesDnsApi.md#dnsgetroleconfig) | **Get** /api/v1/roles/dns | DNS role config *RolesDnsApi* | [**DnsGetZones**](docs/RolesDnsApi.md#dnsgetzones) | **Get** /api/v1/dns/zones | DNS Zones @@ -134,6 +131,7 @@ Class | Method | HTTP request | Description *RolesEtcdApi* | [**EtcdJoinMember**](docs/RolesEtcdApi.md#etcdjoinmember) | **Post** /api/v1/etcd/join | Etcd join *RolesMonitoringApi* | [**MonitoringGetRoleConfig**](docs/RolesMonitoringApi.md#monitoringgetroleconfig) | **Get** /api/v1/roles/monitoring | Monitoring role config *RolesMonitoringApi* | [**MonitoringPutRoleConfig**](docs/RolesMonitoringApi.md#monitoringputroleconfig) | **Post** /api/v1/roles/monitoring | Monitoring role config +*RolesTsdbApi* | [**TsdbGetMetrics**](docs/RolesTsdbApi.md#tsdbgetmetrics) | **Get** /api/v1/tsdb/metrics | Retrieve Metrics *RolesTsdbApi* | [**TsdbGetRoleConfig**](docs/RolesTsdbApi.md#tsdbgetroleconfig) | **Get** /api/v1/roles/tsdb | TSDB role config *RolesTsdbApi* | [**TsdbPutRoleConfig**](docs/RolesTsdbApi.md#tsdbputroleconfig) | **Post** /api/v1/roles/tsdb | TSDB role config @@ -220,6 +218,7 @@ Class | Method | HTTP request | Description - [TsdbRoleConfig](docs/TsdbRoleConfig.md) - [TypesAPIMetricsGetOutput](docs/TypesAPIMetricsGetOutput.md) - [TypesAPIMetricsRecord](docs/TypesAPIMetricsRecord.md) + - [TypesAPIMetricsRole](docs/TypesAPIMetricsRole.md) - [TypesDHCPOption](docs/TypesDHCPOption.md) - [TypesOIDCConfig](docs/TypesOIDCConfig.md) diff --git a/api/api/openapi.yaml b/api/api/openapi.yaml index f95ad63d5..91f0c036a 100755 --- a/api/api/openapi.yaml +++ b/api/api/openapi.yaml @@ -1,7 +1,7 @@ openapi: 3.0.3 info: title: gravity - version: 0.9.2 + version: 0.9.3 servers: - url: / paths: @@ -837,25 +837,6 @@ paths: summary: Discovery Subnets tags: - roles/discovery - /api/v1/dns/metrics: - get: - operationId: dns.get_metrics - responses: - "200": - content: - application/json: - schema: - $ref: '#/components/schemas/TypesAPIMetricsGetOutput' - description: OK - "500": - content: - application/json: - schema: - $ref: '#/components/schemas/RestErrResponse' - description: Internal Server Error - summary: DNS Metrics - tags: - - roles/dns /api/v1/dns/zones: delete: operationId: dns.delete_zones @@ -1415,44 +1396,6 @@ paths: summary: TSDB role config tags: - roles/tsdb - /api/v1/system/metrics/cpu: - get: - operationId: api.get_metrics_cpu - responses: - "200": - content: - application/json: - schema: - $ref: '#/components/schemas/TypesAPIMetricsGetOutput' - description: OK - "500": - content: - application/json: - schema: - $ref: '#/components/schemas/RestErrResponse' - description: Internal Server Error - summary: System Metrics - tags: - - roles/api - /api/v1/system/metrics/memory: - get: - operationId: api.get_metrics_memory - responses: - "200": - content: - application/json: - schema: - $ref: '#/components/schemas/TypesAPIMetricsGetOutput' - description: OK - "500": - content: - application/json: - schema: - $ref: '#/components/schemas/RestErrResponse' - description: Internal Server Error - summary: System Metrics - tags: - - roles/api /api/v1/tools/ping: post: operationId: tools.ping @@ -1525,6 +1468,59 @@ paths: summary: Traceroute tool tags: - roles/api + /api/v1/tsdb/metrics: + get: + operationId: tsdb.get_metrics + parameters: + - explode: true + in: query + name: role + required: true + schema: + $ref: '#/components/schemas/TypesAPIMetricsRole' + style: form + - explode: true + in: query + name: category + required: false + schema: + type: string + style: form + - explode: true + in: query + name: node + required: false + schema: + type: string + style: form + - description: Optionally set a start time for which to return datapoints after + explode: true + in: query + name: since + required: false + schema: + description: Optionally set a start time for which to return datapoints + after + format: date-time + nullable: true + type: string + style: form + responses: + "200": + content: + application/json: + schema: + $ref: '#/components/schemas/TypesAPIMetricsGetOutput' + description: OK + "500": + content: + application/json: + schema: + $ref: '#/components/schemas/RestErrResponse' + description: Internal Server Error + summary: Retrieve Metrics + tags: + - roles/tsdb components: schemas: ApiAPIExportInput: @@ -2936,13 +2932,17 @@ components: TypesAPIMetricsGetOutput: example: records: - - handler: handler - node: node - time: time + - node: node + keys: + - keys + - keys + time: 2000-01-23T04:56:07.000+00:00 value: 0 - - handler: handler - node: node - time: time + - node: node + keys: + - keys + - keys + time: 2000-01-23T04:56:07.000+00:00 value: 0 properties: records: @@ -2955,25 +2955,36 @@ components: type: object TypesAPIMetricsRecord: example: - handler: handler node: node - time: time + keys: + - keys + - keys + time: 2000-01-23T04:56:07.000+00:00 value: 0 properties: - handler: - type: string + keys: + items: + type: string + nullable: true + type: array node: type: string time: + format: date-time type: string value: type: integer required: - - handler + - keys - node - time - value type: object + TypesAPIMetricsRole: + enum: + - system + - dns + type: string TypesDHCPOption: example: value64: diff --git a/api/api_cluster_instances.go b/api/api_cluster_instances.go index 4fcd591a5..bbc385c9b 100644 --- a/api/api_cluster_instances.go +++ b/api/api_cluster_instances.go @@ -3,7 +3,7 @@ gravity No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) -API version: 0.9.2 +API version: 0.9.3 */ // Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. diff --git a/api/api_roles_api.go b/api/api_roles_api.go index 1ddab1f97..2ec9c16d6 100644 --- a/api/api_roles_api.go +++ b/api/api_roles_api.go @@ -3,7 +3,7 @@ gravity No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) -API version: 0.9.2 +API version: 0.9.3 */ // Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. @@ -673,222 +673,6 @@ func (a *RolesApiApiService) ApiGetMembersExecute(r ApiApiGetMembersRequest) (*A return localVarReturnValue, localVarHTTPResponse, nil } -type ApiApiGetMetricsCpuRequest struct { - ctx context.Context - ApiService *RolesApiApiService -} - -func (r ApiApiGetMetricsCpuRequest) Execute() (*TypesAPIMetricsGetOutput, *http.Response, error) { - return r.ApiService.ApiGetMetricsCpuExecute(r) -} - -/* -ApiGetMetricsCpu System Metrics - - @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - @return ApiApiGetMetricsCpuRequest -*/ -func (a *RolesApiApiService) ApiGetMetricsCpu(ctx context.Context) ApiApiGetMetricsCpuRequest { - return ApiApiGetMetricsCpuRequest{ - ApiService: a, - ctx: ctx, - } -} - -// Execute executes the request -// -// @return TypesAPIMetricsGetOutput -func (a *RolesApiApiService) ApiGetMetricsCpuExecute(r ApiApiGetMetricsCpuRequest) (*TypesAPIMetricsGetOutput, *http.Response, error) { - var ( - localVarHTTPMethod = http.MethodGet - localVarPostBody interface{} - formFiles []formFile - localVarReturnValue *TypesAPIMetricsGetOutput - ) - - localBasePath, err := a.client.cfg.ServerURLWithContext(r.ctx, "RolesApiApiService.ApiGetMetricsCpu") - if err != nil { - return localVarReturnValue, nil, &GenericOpenAPIError{error: err.Error()} - } - - localVarPath := localBasePath + "/api/v1/system/metrics/cpu" - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := url.Values{} - localVarFormParams := url.Values{} - - // to determine the Content-Type header - localVarHTTPContentTypes := []string{} - - // set Content-Type header - localVarHTTPContentType := selectHeaderContentType(localVarHTTPContentTypes) - if localVarHTTPContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHTTPContentType - } - - // to determine the Accept header - localVarHTTPHeaderAccepts := []string{"application/json"} - - // set Accept header - localVarHTTPHeaderAccept := selectHeaderAccept(localVarHTTPHeaderAccepts) - if localVarHTTPHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHTTPHeaderAccept - } - req, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, formFiles) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHTTPResponse, err := a.client.callAPI(req) - if err != nil || localVarHTTPResponse == nil { - return localVarReturnValue, localVarHTTPResponse, err - } - - localVarBody, err := io.ReadAll(localVarHTTPResponse.Body) - localVarHTTPResponse.Body.Close() - localVarHTTPResponse.Body = io.NopCloser(bytes.NewBuffer(localVarBody)) - if err != nil { - return localVarReturnValue, localVarHTTPResponse, err - } - - if localVarHTTPResponse.StatusCode >= 300 { - newErr := &GenericOpenAPIError{ - body: localVarBody, - error: localVarHTTPResponse.Status, - } - if localVarHTTPResponse.StatusCode == 500 { - var v RestErrResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.error = formatErrorMessage(localVarHTTPResponse.Status, &v) - newErr.model = v - } - return localVarReturnValue, localVarHTTPResponse, newErr - } - - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr := &GenericOpenAPIError{ - body: localVarBody, - error: err.Error(), - } - return localVarReturnValue, localVarHTTPResponse, newErr - } - - return localVarReturnValue, localVarHTTPResponse, nil -} - -type ApiApiGetMetricsMemoryRequest struct { - ctx context.Context - ApiService *RolesApiApiService -} - -func (r ApiApiGetMetricsMemoryRequest) Execute() (*TypesAPIMetricsGetOutput, *http.Response, error) { - return r.ApiService.ApiGetMetricsMemoryExecute(r) -} - -/* -ApiGetMetricsMemory System Metrics - - @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - @return ApiApiGetMetricsMemoryRequest -*/ -func (a *RolesApiApiService) ApiGetMetricsMemory(ctx context.Context) ApiApiGetMetricsMemoryRequest { - return ApiApiGetMetricsMemoryRequest{ - ApiService: a, - ctx: ctx, - } -} - -// Execute executes the request -// -// @return TypesAPIMetricsGetOutput -func (a *RolesApiApiService) ApiGetMetricsMemoryExecute(r ApiApiGetMetricsMemoryRequest) (*TypesAPIMetricsGetOutput, *http.Response, error) { - var ( - localVarHTTPMethod = http.MethodGet - localVarPostBody interface{} - formFiles []formFile - localVarReturnValue *TypesAPIMetricsGetOutput - ) - - localBasePath, err := a.client.cfg.ServerURLWithContext(r.ctx, "RolesApiApiService.ApiGetMetricsMemory") - if err != nil { - return localVarReturnValue, nil, &GenericOpenAPIError{error: err.Error()} - } - - localVarPath := localBasePath + "/api/v1/system/metrics/memory" - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := url.Values{} - localVarFormParams := url.Values{} - - // to determine the Content-Type header - localVarHTTPContentTypes := []string{} - - // set Content-Type header - localVarHTTPContentType := selectHeaderContentType(localVarHTTPContentTypes) - if localVarHTTPContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHTTPContentType - } - - // to determine the Accept header - localVarHTTPHeaderAccepts := []string{"application/json"} - - // set Accept header - localVarHTTPHeaderAccept := selectHeaderAccept(localVarHTTPHeaderAccepts) - if localVarHTTPHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHTTPHeaderAccept - } - req, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, formFiles) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHTTPResponse, err := a.client.callAPI(req) - if err != nil || localVarHTTPResponse == nil { - return localVarReturnValue, localVarHTTPResponse, err - } - - localVarBody, err := io.ReadAll(localVarHTTPResponse.Body) - localVarHTTPResponse.Body.Close() - localVarHTTPResponse.Body = io.NopCloser(bytes.NewBuffer(localVarBody)) - if err != nil { - return localVarReturnValue, localVarHTTPResponse, err - } - - if localVarHTTPResponse.StatusCode >= 300 { - newErr := &GenericOpenAPIError{ - body: localVarBody, - error: localVarHTTPResponse.Status, - } - if localVarHTTPResponse.StatusCode == 500 { - var v RestErrResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.error = formatErrorMessage(localVarHTTPResponse.Status, &v) - newErr.model = v - } - return localVarReturnValue, localVarHTTPResponse, newErr - } - - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr := &GenericOpenAPIError{ - body: localVarBody, - error: err.Error(), - } - return localVarReturnValue, localVarHTTPResponse, newErr - } - - return localVarReturnValue, localVarHTTPResponse, nil -} - type ApiApiGetRoleConfigRequest struct { ctx context.Context ApiService *RolesApiApiService diff --git a/api/api_roles_backup.go b/api/api_roles_backup.go index fc0ff280b..09ea4858d 100644 --- a/api/api_roles_backup.go +++ b/api/api_roles_backup.go @@ -3,7 +3,7 @@ gravity No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) -API version: 0.9.2 +API version: 0.9.3 */ // Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. diff --git a/api/api_roles_dhcp.go b/api/api_roles_dhcp.go index ef19a05f0..111d9f65e 100644 --- a/api/api_roles_dhcp.go +++ b/api/api_roles_dhcp.go @@ -3,7 +3,7 @@ gravity No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) -API version: 0.9.2 +API version: 0.9.3 */ // Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. diff --git a/api/api_roles_discovery.go b/api/api_roles_discovery.go index 1feda0f8a..48f90fcf3 100644 --- a/api/api_roles_discovery.go +++ b/api/api_roles_discovery.go @@ -3,7 +3,7 @@ gravity No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) -API version: 0.9.2 +API version: 0.9.3 */ // Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. diff --git a/api/api_roles_dns.go b/api/api_roles_dns.go index 30777858d..7fbe9af1c 100644 --- a/api/api_roles_dns.go +++ b/api/api_roles_dns.go @@ -3,7 +3,7 @@ gravity No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) -API version: 0.9.2 +API version: 0.9.3 */ // Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. @@ -295,114 +295,6 @@ func (a *RolesDnsApiService) DnsDeleteZonesExecute(r ApiDnsDeleteZonesRequest) ( return localVarHTTPResponse, nil } -type ApiDnsGetMetricsRequest struct { - ctx context.Context - ApiService *RolesDnsApiService -} - -func (r ApiDnsGetMetricsRequest) Execute() (*TypesAPIMetricsGetOutput, *http.Response, error) { - return r.ApiService.DnsGetMetricsExecute(r) -} - -/* -DnsGetMetrics DNS Metrics - - @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - @return ApiDnsGetMetricsRequest -*/ -func (a *RolesDnsApiService) DnsGetMetrics(ctx context.Context) ApiDnsGetMetricsRequest { - return ApiDnsGetMetricsRequest{ - ApiService: a, - ctx: ctx, - } -} - -// Execute executes the request -// -// @return TypesAPIMetricsGetOutput -func (a *RolesDnsApiService) DnsGetMetricsExecute(r ApiDnsGetMetricsRequest) (*TypesAPIMetricsGetOutput, *http.Response, error) { - var ( - localVarHTTPMethod = http.MethodGet - localVarPostBody interface{} - formFiles []formFile - localVarReturnValue *TypesAPIMetricsGetOutput - ) - - localBasePath, err := a.client.cfg.ServerURLWithContext(r.ctx, "RolesDnsApiService.DnsGetMetrics") - if err != nil { - return localVarReturnValue, nil, &GenericOpenAPIError{error: err.Error()} - } - - localVarPath := localBasePath + "/api/v1/dns/metrics" - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := url.Values{} - localVarFormParams := url.Values{} - - // to determine the Content-Type header - localVarHTTPContentTypes := []string{} - - // set Content-Type header - localVarHTTPContentType := selectHeaderContentType(localVarHTTPContentTypes) - if localVarHTTPContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHTTPContentType - } - - // to determine the Accept header - localVarHTTPHeaderAccepts := []string{"application/json"} - - // set Accept header - localVarHTTPHeaderAccept := selectHeaderAccept(localVarHTTPHeaderAccepts) - if localVarHTTPHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHTTPHeaderAccept - } - req, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, formFiles) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHTTPResponse, err := a.client.callAPI(req) - if err != nil || localVarHTTPResponse == nil { - return localVarReturnValue, localVarHTTPResponse, err - } - - localVarBody, err := io.ReadAll(localVarHTTPResponse.Body) - localVarHTTPResponse.Body.Close() - localVarHTTPResponse.Body = io.NopCloser(bytes.NewBuffer(localVarBody)) - if err != nil { - return localVarReturnValue, localVarHTTPResponse, err - } - - if localVarHTTPResponse.StatusCode >= 300 { - newErr := &GenericOpenAPIError{ - body: localVarBody, - error: localVarHTTPResponse.Status, - } - if localVarHTTPResponse.StatusCode == 500 { - var v RestErrResponse - err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHTTPResponse, newErr - } - newErr.error = formatErrorMessage(localVarHTTPResponse.Status, &v) - newErr.model = v - } - return localVarReturnValue, localVarHTTPResponse, newErr - } - - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) - if err != nil { - newErr := &GenericOpenAPIError{ - body: localVarBody, - error: err.Error(), - } - return localVarReturnValue, localVarHTTPResponse, newErr - } - - return localVarReturnValue, localVarHTTPResponse, nil -} - type ApiDnsGetRecordsRequest struct { ctx context.Context ApiService *RolesDnsApiService diff --git a/api/api_roles_etcd.go b/api/api_roles_etcd.go index d08f1842e..c3bbaefab 100644 --- a/api/api_roles_etcd.go +++ b/api/api_roles_etcd.go @@ -3,7 +3,7 @@ gravity No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) -API version: 0.9.2 +API version: 0.9.3 */ // Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. diff --git a/api/api_roles_monitoring.go b/api/api_roles_monitoring.go index 1007f1418..7fea94c76 100644 --- a/api/api_roles_monitoring.go +++ b/api/api_roles_monitoring.go @@ -3,7 +3,7 @@ gravity No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) -API version: 0.9.2 +API version: 0.9.3 */ // Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. diff --git a/api/api_roles_tsdb.go b/api/api_roles_tsdb.go index d0b19b862..f540d63bd 100644 --- a/api/api_roles_tsdb.go +++ b/api/api_roles_tsdb.go @@ -3,7 +3,7 @@ gravity No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) -API version: 0.9.2 +API version: 0.9.3 */ // Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. @@ -16,11 +16,158 @@ import ( "io" "net/http" "net/url" + "time" ) // RolesTsdbApiService RolesTsdbApi service type RolesTsdbApiService service +type ApiTsdbGetMetricsRequest struct { + ctx context.Context + ApiService *RolesTsdbApiService + role *TypesAPIMetricsRole + category *string + node *string + since *time.Time +} + +func (r ApiTsdbGetMetricsRequest) Role(role TypesAPIMetricsRole) ApiTsdbGetMetricsRequest { + r.role = &role + return r +} + +func (r ApiTsdbGetMetricsRequest) Category(category string) ApiTsdbGetMetricsRequest { + r.category = &category + return r +} + +func (r ApiTsdbGetMetricsRequest) Node(node string) ApiTsdbGetMetricsRequest { + r.node = &node + return r +} + +// Optionally set a start time for which to return datapoints after +func (r ApiTsdbGetMetricsRequest) Since(since time.Time) ApiTsdbGetMetricsRequest { + r.since = &since + return r +} + +func (r ApiTsdbGetMetricsRequest) Execute() (*TypesAPIMetricsGetOutput, *http.Response, error) { + return r.ApiService.TsdbGetMetricsExecute(r) +} + +/* +TsdbGetMetrics Retrieve Metrics + + @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). + @return ApiTsdbGetMetricsRequest +*/ +func (a *RolesTsdbApiService) TsdbGetMetrics(ctx context.Context) ApiTsdbGetMetricsRequest { + return ApiTsdbGetMetricsRequest{ + ApiService: a, + ctx: ctx, + } +} + +// Execute executes the request +// +// @return TypesAPIMetricsGetOutput +func (a *RolesTsdbApiService) TsdbGetMetricsExecute(r ApiTsdbGetMetricsRequest) (*TypesAPIMetricsGetOutput, *http.Response, error) { + var ( + localVarHTTPMethod = http.MethodGet + localVarPostBody interface{} + formFiles []formFile + localVarReturnValue *TypesAPIMetricsGetOutput + ) + + localBasePath, err := a.client.cfg.ServerURLWithContext(r.ctx, "RolesTsdbApiService.TsdbGetMetrics") + if err != nil { + return localVarReturnValue, nil, &GenericOpenAPIError{error: err.Error()} + } + + localVarPath := localBasePath + "/api/v1/tsdb/metrics" + + localVarHeaderParams := make(map[string]string) + localVarQueryParams := url.Values{} + localVarFormParams := url.Values{} + if r.role == nil { + return localVarReturnValue, nil, reportError("role is required and must be specified") + } + + parameterAddToHeaderOrQuery(localVarQueryParams, "role", r.role, "") + if r.category != nil { + parameterAddToHeaderOrQuery(localVarQueryParams, "category", r.category, "") + } + if r.node != nil { + parameterAddToHeaderOrQuery(localVarQueryParams, "node", r.node, "") + } + if r.since != nil { + parameterAddToHeaderOrQuery(localVarQueryParams, "since", r.since, "") + } + // to determine the Content-Type header + localVarHTTPContentTypes := []string{} + + // set Content-Type header + localVarHTTPContentType := selectHeaderContentType(localVarHTTPContentTypes) + if localVarHTTPContentType != "" { + localVarHeaderParams["Content-Type"] = localVarHTTPContentType + } + + // to determine the Accept header + localVarHTTPHeaderAccepts := []string{"application/json"} + + // set Accept header + localVarHTTPHeaderAccept := selectHeaderAccept(localVarHTTPHeaderAccepts) + if localVarHTTPHeaderAccept != "" { + localVarHeaderParams["Accept"] = localVarHTTPHeaderAccept + } + req, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, formFiles) + if err != nil { + return localVarReturnValue, nil, err + } + + localVarHTTPResponse, err := a.client.callAPI(req) + if err != nil || localVarHTTPResponse == nil { + return localVarReturnValue, localVarHTTPResponse, err + } + + localVarBody, err := io.ReadAll(localVarHTTPResponse.Body) + localVarHTTPResponse.Body.Close() + localVarHTTPResponse.Body = io.NopCloser(bytes.NewBuffer(localVarBody)) + if err != nil { + return localVarReturnValue, localVarHTTPResponse, err + } + + if localVarHTTPResponse.StatusCode >= 300 { + newErr := &GenericOpenAPIError{ + body: localVarBody, + error: localVarHTTPResponse.Status, + } + if localVarHTTPResponse.StatusCode == 500 { + var v RestErrResponse + err = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHTTPResponse, newErr + } + newErr.error = formatErrorMessage(localVarHTTPResponse.Status, &v) + newErr.model = v + } + return localVarReturnValue, localVarHTTPResponse, newErr + } + + err = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get("Content-Type")) + if err != nil { + newErr := &GenericOpenAPIError{ + body: localVarBody, + error: err.Error(), + } + return localVarReturnValue, localVarHTTPResponse, newErr + } + + return localVarReturnValue, localVarHTTPResponse, nil +} + type ApiTsdbGetRoleConfigRequest struct { ctx context.Context ApiService *RolesTsdbApiService diff --git a/api/client.go b/api/client.go index 808a1e1d8..1cd4cecda 100644 --- a/api/client.go +++ b/api/client.go @@ -3,7 +3,7 @@ gravity No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) -API version: 0.9.2 +API version: 0.9.3 */ // Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. @@ -40,7 +40,7 @@ var ( queryDescape = strings.NewReplacer("%5B", "[", "%5D", "]") ) -// APIClient manages communication with the gravity API v0.9.2 +// APIClient manages communication with the gravity API v0.9.3 // In most cases there should be only one, shared, APIClient. type APIClient struct { cfg *Configuration diff --git a/api/configuration.go b/api/configuration.go index be6f03286..8cdc4fa64 100644 --- a/api/configuration.go +++ b/api/configuration.go @@ -3,7 +3,7 @@ gravity No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) -API version: 0.9.2 +API version: 0.9.3 */ // Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. diff --git a/api/docs/RolesApiApi.md b/api/docs/RolesApiApi.md index a5b057c50..772256fb2 100755 --- a/api/docs/RolesApiApi.md +++ b/api/docs/RolesApiApi.md @@ -10,8 +10,6 @@ Method | HTTP request | Description [**ApiExport**](RolesApiApi.md#ApiExport) | **Post** /api/v1/cluster/export | Export Cluster [**ApiGetLogMessages**](RolesApiApi.md#ApiGetLogMessages) | **Get** /api/v1/cluster/node/logs | Log messages [**ApiGetMembers**](RolesApiApi.md#ApiGetMembers) | **Get** /api/v1/etcd/members | Etcd members -[**ApiGetMetricsCpu**](RolesApiApi.md#ApiGetMetricsCpu) | **Get** /api/v1/system/metrics/cpu | System Metrics -[**ApiGetMetricsMemory**](RolesApiApi.md#ApiGetMetricsMemory) | **Get** /api/v1/system/metrics/memory | System Metrics [**ApiGetRoleConfig**](RolesApiApi.md#ApiGetRoleConfig) | **Get** /api/v1/roles/api | API role config [**ApiGetTokens**](RolesApiApi.md#ApiGetTokens) | **Get** /api/v1/auth/tokens | Tokens [**ApiGetUsers**](RolesApiApi.md#ApiGetUsers) | **Get** /api/v1/auth/users | API Users @@ -392,124 +390,6 @@ No authorization required [[Back to README]](../README.md) -## ApiGetMetricsCpu - -> TypesAPIMetricsGetOutput ApiGetMetricsCpu(ctx).Execute() - -System Metrics - -### Example - -```go -package main - -import ( - "context" - "fmt" - "os" - openapiclient "beryju.io/gravity/api" -) - -func main() { - - configuration := openapiclient.NewConfiguration() - apiClient := openapiclient.NewAPIClient(configuration) - resp, r, err := apiClient.RolesApiApi.ApiGetMetricsCpu(context.Background()).Execute() - if err != nil { - fmt.Fprintf(os.Stderr, "Error when calling `RolesApiApi.ApiGetMetricsCpu``: %v\n", err) - fmt.Fprintf(os.Stderr, "Full HTTP response: %v\n", r) - } - // response from `ApiGetMetricsCpu`: TypesAPIMetricsGetOutput - fmt.Fprintf(os.Stdout, "Response from `RolesApiApi.ApiGetMetricsCpu`: %v\n", resp) -} -``` - -### Path Parameters - -This endpoint does not need any parameter. - -### Other Parameters - -Other parameters are passed through a pointer to a apiApiGetMetricsCpuRequest struct via the builder pattern - - -### Return type - -[**TypesAPIMetricsGetOutput**](TypesAPIMetricsGetOutput.md) - -### Authorization - -No authorization required - -### HTTP request headers - -- **Content-Type**: Not defined -- **Accept**: application/json - -[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) -[[Back to Model list]](../README.md#documentation-for-models) -[[Back to README]](../README.md) - - -## ApiGetMetricsMemory - -> TypesAPIMetricsGetOutput ApiGetMetricsMemory(ctx).Execute() - -System Metrics - -### Example - -```go -package main - -import ( - "context" - "fmt" - "os" - openapiclient "beryju.io/gravity/api" -) - -func main() { - - configuration := openapiclient.NewConfiguration() - apiClient := openapiclient.NewAPIClient(configuration) - resp, r, err := apiClient.RolesApiApi.ApiGetMetricsMemory(context.Background()).Execute() - if err != nil { - fmt.Fprintf(os.Stderr, "Error when calling `RolesApiApi.ApiGetMetricsMemory``: %v\n", err) - fmt.Fprintf(os.Stderr, "Full HTTP response: %v\n", r) - } - // response from `ApiGetMetricsMemory`: TypesAPIMetricsGetOutput - fmt.Fprintf(os.Stdout, "Response from `RolesApiApi.ApiGetMetricsMemory`: %v\n", resp) -} -``` - -### Path Parameters - -This endpoint does not need any parameter. - -### Other Parameters - -Other parameters are passed through a pointer to a apiApiGetMetricsMemoryRequest struct via the builder pattern - - -### Return type - -[**TypesAPIMetricsGetOutput**](TypesAPIMetricsGetOutput.md) - -### Authorization - -No authorization required - -### HTTP request headers - -- **Content-Type**: Not defined -- **Accept**: application/json - -[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) -[[Back to Model list]](../README.md#documentation-for-models) -[[Back to README]](../README.md) - - ## ApiGetRoleConfig > ApiAPIRoleConfigOutput ApiGetRoleConfig(ctx).Execute() diff --git a/api/docs/RolesDnsApi.md b/api/docs/RolesDnsApi.md index 4a226cd75..ce27b809f 100755 --- a/api/docs/RolesDnsApi.md +++ b/api/docs/RolesDnsApi.md @@ -6,7 +6,6 @@ Method | HTTP request | Description ------------- | ------------- | ------------- [**DnsDeleteRecords**](RolesDnsApi.md#DnsDeleteRecords) | **Delete** /api/v1/dns/zones/records | DNS Records [**DnsDeleteZones**](RolesDnsApi.md#DnsDeleteZones) | **Delete** /api/v1/dns/zones | DNS Zones -[**DnsGetMetrics**](RolesDnsApi.md#DnsGetMetrics) | **Get** /api/v1/dns/metrics | DNS Metrics [**DnsGetRecords**](RolesDnsApi.md#DnsGetRecords) | **Get** /api/v1/dns/zones/records | DNS Records [**DnsGetRoleConfig**](RolesDnsApi.md#DnsGetRoleConfig) | **Get** /api/v1/roles/dns | DNS role config [**DnsGetZones**](RolesDnsApi.md#DnsGetZones) | **Get** /api/v1/dns/zones | DNS Zones @@ -146,65 +145,6 @@ No authorization required [[Back to README]](../README.md) -## DnsGetMetrics - -> TypesAPIMetricsGetOutput DnsGetMetrics(ctx).Execute() - -DNS Metrics - -### Example - -```go -package main - -import ( - "context" - "fmt" - "os" - openapiclient "beryju.io/gravity/api" -) - -func main() { - - configuration := openapiclient.NewConfiguration() - apiClient := openapiclient.NewAPIClient(configuration) - resp, r, err := apiClient.RolesDnsApi.DnsGetMetrics(context.Background()).Execute() - if err != nil { - fmt.Fprintf(os.Stderr, "Error when calling `RolesDnsApi.DnsGetMetrics``: %v\n", err) - fmt.Fprintf(os.Stderr, "Full HTTP response: %v\n", r) - } - // response from `DnsGetMetrics`: TypesAPIMetricsGetOutput - fmt.Fprintf(os.Stdout, "Response from `RolesDnsApi.DnsGetMetrics`: %v\n", resp) -} -``` - -### Path Parameters - -This endpoint does not need any parameter. - -### Other Parameters - -Other parameters are passed through a pointer to a apiDnsGetMetricsRequest struct via the builder pattern - - -### Return type - -[**TypesAPIMetricsGetOutput**](TypesAPIMetricsGetOutput.md) - -### Authorization - -No authorization required - -### HTTP request headers - -- **Content-Type**: Not defined -- **Accept**: application/json - -[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) -[[Back to Model list]](../README.md#documentation-for-models) -[[Back to README]](../README.md) - - ## DnsGetRecords > DnsAPIRecordsGetOutput DnsGetRecords(ctx).Zone(zone).Hostname(hostname).Execute() diff --git a/api/docs/RolesTsdbApi.md b/api/docs/RolesTsdbApi.md index 15a4163c1..c6a58d14e 100755 --- a/api/docs/RolesTsdbApi.md +++ b/api/docs/RolesTsdbApi.md @@ -4,11 +4,83 @@ All URIs are relative to *http://localhost* Method | HTTP request | Description ------------- | ------------- | ------------- +[**TsdbGetMetrics**](RolesTsdbApi.md#TsdbGetMetrics) | **Get** /api/v1/tsdb/metrics | Retrieve Metrics [**TsdbGetRoleConfig**](RolesTsdbApi.md#TsdbGetRoleConfig) | **Get** /api/v1/roles/tsdb | TSDB role config [**TsdbPutRoleConfig**](RolesTsdbApi.md#TsdbPutRoleConfig) | **Post** /api/v1/roles/tsdb | TSDB role config +## TsdbGetMetrics + +> TypesAPIMetricsGetOutput TsdbGetMetrics(ctx).Role(role).Category(category).Node(node).Since(since).Execute() + +Retrieve Metrics + +### Example + +```go +package main + +import ( + "context" + "fmt" + "os" + "time" + openapiclient "beryju.io/gravity/api" +) + +func main() { + role := openapiclient.TypesAPIMetricsRole("system") // TypesAPIMetricsRole | + category := "category_example" // string | (optional) + node := "node_example" // string | (optional) + since := time.Now() // time.Time | Optionally set a start time for which to return datapoints after (optional) + + configuration := openapiclient.NewConfiguration() + apiClient := openapiclient.NewAPIClient(configuration) + resp, r, err := apiClient.RolesTsdbApi.TsdbGetMetrics(context.Background()).Role(role).Category(category).Node(node).Since(since).Execute() + if err != nil { + fmt.Fprintf(os.Stderr, "Error when calling `RolesTsdbApi.TsdbGetMetrics``: %v\n", err) + fmt.Fprintf(os.Stderr, "Full HTTP response: %v\n", r) + } + // response from `TsdbGetMetrics`: TypesAPIMetricsGetOutput + fmt.Fprintf(os.Stdout, "Response from `RolesTsdbApi.TsdbGetMetrics`: %v\n", resp) +} +``` + +### Path Parameters + + + +### Other Parameters + +Other parameters are passed through a pointer to a apiTsdbGetMetricsRequest struct via the builder pattern + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **role** | [**TypesAPIMetricsRole**](TypesAPIMetricsRole.md) | | + **category** | **string** | | + **node** | **string** | | + **since** | **time.Time** | Optionally set a start time for which to return datapoints after | + +### Return type + +[**TypesAPIMetricsGetOutput**](TypesAPIMetricsGetOutput.md) + +### Authorization + +No authorization required + +### HTTP request headers + +- **Content-Type**: Not defined +- **Accept**: application/json + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) +[[Back to Model list]](../README.md#documentation-for-models) +[[Back to README]](../README.md) + + ## TsdbGetRoleConfig > TsdbAPIRoleConfigOutput TsdbGetRoleConfig(ctx).Execute() diff --git a/api/docs/TypesAPIMetricsRecord.md b/api/docs/TypesAPIMetricsRecord.md index d06cd56b0..1c96898b5 100755 --- a/api/docs/TypesAPIMetricsRecord.md +++ b/api/docs/TypesAPIMetricsRecord.md @@ -4,16 +4,16 @@ Name | Type | Description | Notes ------------ | ------------- | ------------- | ------------- -**Handler** | **string** | | +**Keys** | **[]string** | | **Node** | **string** | | -**Time** | **string** | | +**Time** | **time.Time** | | **Value** | **int32** | | ## Methods ### NewTypesAPIMetricsRecord -`func NewTypesAPIMetricsRecord(handler string, node string, time string, value int32, ) *TypesAPIMetricsRecord` +`func NewTypesAPIMetricsRecord(keys []string, node string, time time.Time, value int32, ) *TypesAPIMetricsRecord` NewTypesAPIMetricsRecord instantiates a new TypesAPIMetricsRecord object This constructor will assign default values to properties that have it defined, @@ -28,26 +28,36 @@ NewTypesAPIMetricsRecordWithDefaults instantiates a new TypesAPIMetricsRecord ob This constructor will only assign default values to properties that have it defined, but it doesn't guarantee that properties required by API are set -### GetHandler +### GetKeys -`func (o *TypesAPIMetricsRecord) GetHandler() string` +`func (o *TypesAPIMetricsRecord) GetKeys() []string` -GetHandler returns the Handler field if non-nil, zero value otherwise. +GetKeys returns the Keys field if non-nil, zero value otherwise. -### GetHandlerOk +### GetKeysOk -`func (o *TypesAPIMetricsRecord) GetHandlerOk() (*string, bool)` +`func (o *TypesAPIMetricsRecord) GetKeysOk() (*[]string, bool)` -GetHandlerOk returns a tuple with the Handler field if it's non-nil, zero value otherwise +GetKeysOk returns a tuple with the Keys field if it's non-nil, zero value otherwise and a boolean to check if the value has been set. -### SetHandler +### SetKeys -`func (o *TypesAPIMetricsRecord) SetHandler(v string)` +`func (o *TypesAPIMetricsRecord) SetKeys(v []string)` -SetHandler sets Handler field to given value. +SetKeys sets Keys field to given value. +### SetKeysNil + +`func (o *TypesAPIMetricsRecord) SetKeysNil(b bool)` + + SetKeysNil sets the value for Keys to be an explicit nil + +### UnsetKeys +`func (o *TypesAPIMetricsRecord) UnsetKeys()` + +UnsetKeys ensures that no value is present for Keys, not even an explicit nil ### GetNode `func (o *TypesAPIMetricsRecord) GetNode() string` @@ -70,20 +80,20 @@ SetNode sets Node field to given value. ### GetTime -`func (o *TypesAPIMetricsRecord) GetTime() string` +`func (o *TypesAPIMetricsRecord) GetTime() time.Time` GetTime returns the Time field if non-nil, zero value otherwise. ### GetTimeOk -`func (o *TypesAPIMetricsRecord) GetTimeOk() (*string, bool)` +`func (o *TypesAPIMetricsRecord) GetTimeOk() (*time.Time, bool)` GetTimeOk returns a tuple with the Time field if it's non-nil, zero value otherwise and a boolean to check if the value has been set. ### SetTime -`func (o *TypesAPIMetricsRecord) SetTime(v string)` +`func (o *TypesAPIMetricsRecord) SetTime(v time.Time)` SetTime sets Time field to given value. diff --git a/api/docs/TypesAPIMetricsRole.md b/api/docs/TypesAPIMetricsRole.md new file mode 100644 index 000000000..430da4202 --- /dev/null +++ b/api/docs/TypesAPIMetricsRole.md @@ -0,0 +1,13 @@ +# TypesAPIMetricsRole + +## Enum + + +* `SYSTEM` (value: `"system"`) + +* `DNS` (value: `"dns"`) + + +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/api/model_api_api_export_input.go b/api/model_api_api_export_input.go index 745bc8669..60ddc3a7c 100644 --- a/api/model_api_api_export_input.go +++ b/api/model_api_api_export_input.go @@ -3,7 +3,7 @@ gravity No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) -API version: 0.9.2 +API version: 0.9.3 */ // Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. diff --git a/api/model_api_api_export_output.go b/api/model_api_api_export_output.go index 61251b69e..76ab07c15 100644 --- a/api/model_api_api_export_output.go +++ b/api/model_api_api_export_output.go @@ -3,7 +3,7 @@ gravity No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) -API version: 0.9.2 +API version: 0.9.3 */ // Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. diff --git a/api/model_api_api_import_input.go b/api/model_api_api_import_input.go index f4ddd5baf..72c0d8da4 100644 --- a/api/model_api_api_import_input.go +++ b/api/model_api_api_import_input.go @@ -3,7 +3,7 @@ gravity No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) -API version: 0.9.2 +API version: 0.9.3 */ // Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. diff --git a/api/model_api_api_log_message.go b/api/model_api_api_log_message.go index ac63afc3b..1acc22bac 100644 --- a/api/model_api_api_log_message.go +++ b/api/model_api_api_log_message.go @@ -3,7 +3,7 @@ gravity No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) -API version: 0.9.2 +API version: 0.9.3 */ // Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. diff --git a/api/model_api_api_log_messages.go b/api/model_api_api_log_messages.go index e8b4138e8..fcbadddb4 100644 --- a/api/model_api_api_log_messages.go +++ b/api/model_api_api_log_messages.go @@ -3,7 +3,7 @@ gravity No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) -API version: 0.9.2 +API version: 0.9.3 */ // Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. diff --git a/api/model_api_api_member.go b/api/model_api_api_member.go index e29fb5f7c..7690cd46b 100644 --- a/api/model_api_api_member.go +++ b/api/model_api_api_member.go @@ -3,7 +3,7 @@ gravity No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) -API version: 0.9.2 +API version: 0.9.3 */ // Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. diff --git a/api/model_api_api_member_join_input.go b/api/model_api_api_member_join_input.go index 96cc88ead..3c48d4cee 100644 --- a/api/model_api_api_member_join_input.go +++ b/api/model_api_api_member_join_input.go @@ -3,7 +3,7 @@ gravity No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) -API version: 0.9.2 +API version: 0.9.3 */ // Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. diff --git a/api/model_api_api_member_join_output.go b/api/model_api_api_member_join_output.go index 3f307ae17..17cc94cef 100644 --- a/api/model_api_api_member_join_output.go +++ b/api/model_api_api_member_join_output.go @@ -3,7 +3,7 @@ gravity No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) -API version: 0.9.2 +API version: 0.9.3 */ // Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. diff --git a/api/model_api_api_members_output.go b/api/model_api_api_members_output.go index 359f400e3..ee710fa7d 100644 --- a/api/model_api_api_members_output.go +++ b/api/model_api_api_members_output.go @@ -3,7 +3,7 @@ gravity No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) -API version: 0.9.2 +API version: 0.9.3 */ // Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. diff --git a/api/model_api_api_role_config_input.go b/api/model_api_api_role_config_input.go index aa7288d6a..c967de833 100644 --- a/api/model_api_api_role_config_input.go +++ b/api/model_api_api_role_config_input.go @@ -3,7 +3,7 @@ gravity No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) -API version: 0.9.2 +API version: 0.9.3 */ // Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. diff --git a/api/model_api_api_role_config_output.go b/api/model_api_api_role_config_output.go index 0540bebf5..cdc157804 100644 --- a/api/model_api_api_role_config_output.go +++ b/api/model_api_api_role_config_output.go @@ -3,7 +3,7 @@ gravity No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) -API version: 0.9.2 +API version: 0.9.3 */ // Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. diff --git a/api/model_api_api_tool_ping_input.go b/api/model_api_api_tool_ping_input.go index 4889dcbad..0c6a777cd 100644 --- a/api/model_api_api_tool_ping_input.go +++ b/api/model_api_api_tool_ping_input.go @@ -3,7 +3,7 @@ gravity No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) -API version: 0.9.2 +API version: 0.9.3 */ // Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. diff --git a/api/model_api_api_tool_ping_output.go b/api/model_api_api_tool_ping_output.go index c9e74d5c7..5aec5525a 100644 --- a/api/model_api_api_tool_ping_output.go +++ b/api/model_api_api_tool_ping_output.go @@ -3,7 +3,7 @@ gravity No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) -API version: 0.9.2 +API version: 0.9.3 */ // Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. diff --git a/api/model_api_api_tool_portmap_input.go b/api/model_api_api_tool_portmap_input.go index 9ed3de6b1..662260547 100644 --- a/api/model_api_api_tool_portmap_input.go +++ b/api/model_api_api_tool_portmap_input.go @@ -3,7 +3,7 @@ gravity No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) -API version: 0.9.2 +API version: 0.9.3 */ // Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. diff --git a/api/model_api_api_tool_portmap_output.go b/api/model_api_api_tool_portmap_output.go index 44fead091..70f100d0e 100644 --- a/api/model_api_api_tool_portmap_output.go +++ b/api/model_api_api_tool_portmap_output.go @@ -3,7 +3,7 @@ gravity No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) -API version: 0.9.2 +API version: 0.9.3 */ // Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. diff --git a/api/model_api_api_tool_portmap_output_port.go b/api/model_api_api_tool_portmap_output_port.go index 40ca878f6..9c8f2b57b 100644 --- a/api/model_api_api_tool_portmap_output_port.go +++ b/api/model_api_api_tool_portmap_output_port.go @@ -3,7 +3,7 @@ gravity No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) -API version: 0.9.2 +API version: 0.9.3 */ // Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. diff --git a/api/model_api_api_tool_traceroute_input.go b/api/model_api_api_tool_traceroute_input.go index 48d3c27b3..01d6cacdc 100644 --- a/api/model_api_api_tool_traceroute_input.go +++ b/api/model_api_api_tool_traceroute_input.go @@ -3,7 +3,7 @@ gravity No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) -API version: 0.9.2 +API version: 0.9.3 */ // Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. diff --git a/api/model_api_api_tool_traceroute_output.go b/api/model_api_api_tool_traceroute_output.go index 006d1cff1..cad21cd0d 100644 --- a/api/model_api_api_tool_traceroute_output.go +++ b/api/model_api_api_tool_traceroute_output.go @@ -3,7 +3,7 @@ gravity No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) -API version: 0.9.2 +API version: 0.9.3 */ // Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. diff --git a/api/model_api_api_tool_traceroute_output_hop.go b/api/model_api_api_tool_traceroute_output_hop.go index abc9984c3..1273624c0 100644 --- a/api/model_api_api_tool_traceroute_output_hop.go +++ b/api/model_api_api_tool_traceroute_output_hop.go @@ -3,7 +3,7 @@ gravity No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) -API version: 0.9.2 +API version: 0.9.3 */ // Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. diff --git a/api/model_api_api_transport_entry.go b/api/model_api_api_transport_entry.go index 3fb488f94..ea39e9df3 100644 --- a/api/model_api_api_transport_entry.go +++ b/api/model_api_api_transport_entry.go @@ -3,7 +3,7 @@ gravity No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) -API version: 0.9.2 +API version: 0.9.3 */ // Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. diff --git a/api/model_api_role_config.go b/api/model_api_role_config.go index 67cd33f18..21c28f004 100644 --- a/api/model_api_role_config.go +++ b/api/model_api_role_config.go @@ -3,7 +3,7 @@ gravity No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) -API version: 0.9.2 +API version: 0.9.3 */ // Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. diff --git a/api/model_auth_api_config_output.go b/api/model_auth_api_config_output.go index 5609e1207..c423a7b22 100644 --- a/api/model_auth_api_config_output.go +++ b/api/model_auth_api_config_output.go @@ -3,7 +3,7 @@ gravity No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) -API version: 0.9.2 +API version: 0.9.3 */ // Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. diff --git a/api/model_auth_api_login_input.go b/api/model_auth_api_login_input.go index e1b450017..1c5240fe9 100644 --- a/api/model_auth_api_login_input.go +++ b/api/model_auth_api_login_input.go @@ -3,7 +3,7 @@ gravity No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) -API version: 0.9.2 +API version: 0.9.3 */ // Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. diff --git a/api/model_auth_api_login_output.go b/api/model_auth_api_login_output.go index a0a0d674f..8331eee69 100644 --- a/api/model_auth_api_login_output.go +++ b/api/model_auth_api_login_output.go @@ -3,7 +3,7 @@ gravity No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) -API version: 0.9.2 +API version: 0.9.3 */ // Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. diff --git a/api/model_auth_api_token.go b/api/model_auth_api_token.go index 935a1b00c..eea6ca402 100644 --- a/api/model_auth_api_token.go +++ b/api/model_auth_api_token.go @@ -3,7 +3,7 @@ gravity No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) -API version: 0.9.2 +API version: 0.9.3 */ // Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. diff --git a/api/model_auth_api_tokens_get_output.go b/api/model_auth_api_tokens_get_output.go index 0c2c5dd17..c741e338b 100644 --- a/api/model_auth_api_tokens_get_output.go +++ b/api/model_auth_api_tokens_get_output.go @@ -3,7 +3,7 @@ gravity No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) -API version: 0.9.2 +API version: 0.9.3 */ // Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. diff --git a/api/model_auth_api_tokens_put_output.go b/api/model_auth_api_tokens_put_output.go index 87576075f..a48efe40d 100644 --- a/api/model_auth_api_tokens_put_output.go +++ b/api/model_auth_api_tokens_put_output.go @@ -3,7 +3,7 @@ gravity No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) -API version: 0.9.2 +API version: 0.9.3 */ // Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. diff --git a/api/model_auth_api_user.go b/api/model_auth_api_user.go index 9ce85045d..983fa55d1 100644 --- a/api/model_auth_api_user.go +++ b/api/model_auth_api_user.go @@ -3,7 +3,7 @@ gravity No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) -API version: 0.9.2 +API version: 0.9.3 */ // Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. diff --git a/api/model_auth_api_users_get_output.go b/api/model_auth_api_users_get_output.go index bdabd95b3..0fbb91ac5 100644 --- a/api/model_auth_api_users_get_output.go +++ b/api/model_auth_api_users_get_output.go @@ -3,7 +3,7 @@ gravity No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) -API version: 0.9.2 +API version: 0.9.3 */ // Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. diff --git a/api/model_auth_api_users_put_input.go b/api/model_auth_api_users_put_input.go index 064866d38..7873e225c 100644 --- a/api/model_auth_api_users_put_input.go +++ b/api/model_auth_api_users_put_input.go @@ -3,7 +3,7 @@ gravity No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) -API version: 0.9.2 +API version: 0.9.3 */ // Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. diff --git a/api/model_auth_apime_output.go b/api/model_auth_apime_output.go index 896aa1ef2..2b1a4d6b7 100644 --- a/api/model_auth_apime_output.go +++ b/api/model_auth_apime_output.go @@ -3,7 +3,7 @@ gravity No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) -API version: 0.9.2 +API version: 0.9.3 */ // Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. diff --git a/api/model_backup_api_backup_status.go b/api/model_backup_api_backup_status.go index 94fb2a448..dda3fe3cc 100644 --- a/api/model_backup_api_backup_status.go +++ b/api/model_backup_api_backup_status.go @@ -3,7 +3,7 @@ gravity No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) -API version: 0.9.2 +API version: 0.9.3 */ // Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. diff --git a/api/model_backup_api_backup_status_output.go b/api/model_backup_api_backup_status_output.go index 22d03889b..47f24f08e 100644 --- a/api/model_backup_api_backup_status_output.go +++ b/api/model_backup_api_backup_status_output.go @@ -3,7 +3,7 @@ gravity No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) -API version: 0.9.2 +API version: 0.9.3 */ // Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. diff --git a/api/model_backup_api_role_config_input.go b/api/model_backup_api_role_config_input.go index bf9889dcd..2311f3463 100644 --- a/api/model_backup_api_role_config_input.go +++ b/api/model_backup_api_role_config_input.go @@ -3,7 +3,7 @@ gravity No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) -API version: 0.9.2 +API version: 0.9.3 */ // Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. diff --git a/api/model_backup_api_role_config_output.go b/api/model_backup_api_role_config_output.go index e77629d51..2bd07dc5a 100644 --- a/api/model_backup_api_role_config_output.go +++ b/api/model_backup_api_role_config_output.go @@ -3,7 +3,7 @@ gravity No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) -API version: 0.9.2 +API version: 0.9.3 */ // Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. diff --git a/api/model_backup_backup_status.go b/api/model_backup_backup_status.go index cd52d30af..be9e8b5d2 100644 --- a/api/model_backup_backup_status.go +++ b/api/model_backup_backup_status.go @@ -3,7 +3,7 @@ gravity No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) -API version: 0.9.2 +API version: 0.9.3 */ // Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. diff --git a/api/model_backup_role_config.go b/api/model_backup_role_config.go index 6da77e1db..d7467b98a 100644 --- a/api/model_backup_role_config.go +++ b/api/model_backup_role_config.go @@ -3,7 +3,7 @@ gravity No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) -API version: 0.9.2 +API version: 0.9.3 */ // Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. diff --git a/api/model_dhcp_api_lease.go b/api/model_dhcp_api_lease.go index 2d8ed702b..815b5b5b9 100644 --- a/api/model_dhcp_api_lease.go +++ b/api/model_dhcp_api_lease.go @@ -3,7 +3,7 @@ gravity No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) -API version: 0.9.2 +API version: 0.9.3 */ // Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. diff --git a/api/model_dhcp_api_lease_info.go b/api/model_dhcp_api_lease_info.go index 544118433..9c121b7fc 100644 --- a/api/model_dhcp_api_lease_info.go +++ b/api/model_dhcp_api_lease_info.go @@ -3,7 +3,7 @@ gravity No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) -API version: 0.9.2 +API version: 0.9.3 */ // Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. diff --git a/api/model_dhcp_api_leases_get_output.go b/api/model_dhcp_api_leases_get_output.go index e726e116a..a34b27041 100644 --- a/api/model_dhcp_api_leases_get_output.go +++ b/api/model_dhcp_api_leases_get_output.go @@ -3,7 +3,7 @@ gravity No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) -API version: 0.9.2 +API version: 0.9.3 */ // Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. diff --git a/api/model_dhcp_api_leases_put_input.go b/api/model_dhcp_api_leases_put_input.go index b0d3335a3..cffd6b6b8 100644 --- a/api/model_dhcp_api_leases_put_input.go +++ b/api/model_dhcp_api_leases_put_input.go @@ -3,7 +3,7 @@ gravity No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) -API version: 0.9.2 +API version: 0.9.3 */ // Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. diff --git a/api/model_dhcp_api_role_config_input.go b/api/model_dhcp_api_role_config_input.go index e61a91e1a..f9ac50356 100644 --- a/api/model_dhcp_api_role_config_input.go +++ b/api/model_dhcp_api_role_config_input.go @@ -3,7 +3,7 @@ gravity No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) -API version: 0.9.2 +API version: 0.9.3 */ // Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. diff --git a/api/model_dhcp_api_role_config_output.go b/api/model_dhcp_api_role_config_output.go index 607d88026..6e56a899e 100644 --- a/api/model_dhcp_api_role_config_output.go +++ b/api/model_dhcp_api_role_config_output.go @@ -3,7 +3,7 @@ gravity No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) -API version: 0.9.2 +API version: 0.9.3 */ // Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. diff --git a/api/model_dhcp_api_scope.go b/api/model_dhcp_api_scope.go index 235624042..f831769e7 100644 --- a/api/model_dhcp_api_scope.go +++ b/api/model_dhcp_api_scope.go @@ -3,7 +3,7 @@ gravity No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) -API version: 0.9.2 +API version: 0.9.3 */ // Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. diff --git a/api/model_dhcp_api_scopes_get_output.go b/api/model_dhcp_api_scopes_get_output.go index 44ef3e1f3..f7a338195 100644 --- a/api/model_dhcp_api_scopes_get_output.go +++ b/api/model_dhcp_api_scopes_get_output.go @@ -3,7 +3,7 @@ gravity No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) -API version: 0.9.2 +API version: 0.9.3 */ // Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. diff --git a/api/model_dhcp_api_scopes_put_input.go b/api/model_dhcp_api_scopes_put_input.go index b321fef5d..76ed3700b 100644 --- a/api/model_dhcp_api_scopes_put_input.go +++ b/api/model_dhcp_api_scopes_put_input.go @@ -3,7 +3,7 @@ gravity No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) -API version: 0.9.2 +API version: 0.9.3 */ // Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. diff --git a/api/model_dhcp_role_config.go b/api/model_dhcp_role_config.go index 38c23544b..e5558b745 100644 --- a/api/model_dhcp_role_config.go +++ b/api/model_dhcp_role_config.go @@ -3,7 +3,7 @@ gravity No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) -API version: 0.9.2 +API version: 0.9.3 */ // Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. diff --git a/api/model_dhcp_scope_dns.go b/api/model_dhcp_scope_dns.go index d8b99127f..5f101c881 100644 --- a/api/model_dhcp_scope_dns.go +++ b/api/model_dhcp_scope_dns.go @@ -3,7 +3,7 @@ gravity No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) -API version: 0.9.2 +API version: 0.9.3 */ // Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. diff --git a/api/model_discovery_api_device.go b/api/model_discovery_api_device.go index a4e56af9f..7af43b31a 100644 --- a/api/model_discovery_api_device.go +++ b/api/model_discovery_api_device.go @@ -3,7 +3,7 @@ gravity No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) -API version: 0.9.2 +API version: 0.9.3 */ // Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. diff --git a/api/model_discovery_api_devices_apply_input.go b/api/model_discovery_api_devices_apply_input.go index 5de95994f..089c2717d 100644 --- a/api/model_discovery_api_devices_apply_input.go +++ b/api/model_discovery_api_devices_apply_input.go @@ -3,7 +3,7 @@ gravity No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) -API version: 0.9.2 +API version: 0.9.3 */ // Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. diff --git a/api/model_discovery_api_devices_get_output.go b/api/model_discovery_api_devices_get_output.go index 2108c33ff..3b6f42132 100644 --- a/api/model_discovery_api_devices_get_output.go +++ b/api/model_discovery_api_devices_get_output.go @@ -3,7 +3,7 @@ gravity No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) -API version: 0.9.2 +API version: 0.9.3 */ // Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. diff --git a/api/model_discovery_api_role_config_input.go b/api/model_discovery_api_role_config_input.go index 4509f8a53..3ee66f7c2 100644 --- a/api/model_discovery_api_role_config_input.go +++ b/api/model_discovery_api_role_config_input.go @@ -3,7 +3,7 @@ gravity No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) -API version: 0.9.2 +API version: 0.9.3 */ // Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. diff --git a/api/model_discovery_api_role_config_output.go b/api/model_discovery_api_role_config_output.go index ff82b4696..f65bbd0a8 100644 --- a/api/model_discovery_api_role_config_output.go +++ b/api/model_discovery_api_role_config_output.go @@ -3,7 +3,7 @@ gravity No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) -API version: 0.9.2 +API version: 0.9.3 */ // Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. diff --git a/api/model_discovery_api_subnet.go b/api/model_discovery_api_subnet.go index 965c81f18..e6f3934d4 100644 --- a/api/model_discovery_api_subnet.go +++ b/api/model_discovery_api_subnet.go @@ -3,7 +3,7 @@ gravity No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) -API version: 0.9.2 +API version: 0.9.3 */ // Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. diff --git a/api/model_discovery_api_subnets_get_output.go b/api/model_discovery_api_subnets_get_output.go index f596f27b5..da218cbe9 100644 --- a/api/model_discovery_api_subnets_get_output.go +++ b/api/model_discovery_api_subnets_get_output.go @@ -3,7 +3,7 @@ gravity No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) -API version: 0.9.2 +API version: 0.9.3 */ // Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. diff --git a/api/model_discovery_api_subnets_put_input.go b/api/model_discovery_api_subnets_put_input.go index c61ec0747..43e2ea215 100644 --- a/api/model_discovery_api_subnets_put_input.go +++ b/api/model_discovery_api_subnets_put_input.go @@ -3,7 +3,7 @@ gravity No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) -API version: 0.9.2 +API version: 0.9.3 */ // Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. diff --git a/api/model_discovery_role_config.go b/api/model_discovery_role_config.go index ff0a94283..75dc8a103 100644 --- a/api/model_discovery_role_config.go +++ b/api/model_discovery_role_config.go @@ -3,7 +3,7 @@ gravity No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) -API version: 0.9.2 +API version: 0.9.3 */ // Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. diff --git a/api/model_dns_api_record.go b/api/model_dns_api_record.go index 2779e37b5..1f6c03bad 100644 --- a/api/model_dns_api_record.go +++ b/api/model_dns_api_record.go @@ -3,7 +3,7 @@ gravity No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) -API version: 0.9.2 +API version: 0.9.3 */ // Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. diff --git a/api/model_dns_api_records_get_output.go b/api/model_dns_api_records_get_output.go index 2b96096b3..42f7316a0 100644 --- a/api/model_dns_api_records_get_output.go +++ b/api/model_dns_api_records_get_output.go @@ -3,7 +3,7 @@ gravity No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) -API version: 0.9.2 +API version: 0.9.3 */ // Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. diff --git a/api/model_dns_api_records_put_input.go b/api/model_dns_api_records_put_input.go index e81332aff..ee87c8c57 100644 --- a/api/model_dns_api_records_put_input.go +++ b/api/model_dns_api_records_put_input.go @@ -3,7 +3,7 @@ gravity No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) -API version: 0.9.2 +API version: 0.9.3 */ // Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. diff --git a/api/model_dns_api_role_config_input.go b/api/model_dns_api_role_config_input.go index a24ec313b..b575b86a5 100644 --- a/api/model_dns_api_role_config_input.go +++ b/api/model_dns_api_role_config_input.go @@ -3,7 +3,7 @@ gravity No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) -API version: 0.9.2 +API version: 0.9.3 */ // Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. diff --git a/api/model_dns_api_role_config_output.go b/api/model_dns_api_role_config_output.go index f7746b8ca..29c1102e4 100644 --- a/api/model_dns_api_role_config_output.go +++ b/api/model_dns_api_role_config_output.go @@ -3,7 +3,7 @@ gravity No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) -API version: 0.9.2 +API version: 0.9.3 */ // Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. diff --git a/api/model_dns_api_zone.go b/api/model_dns_api_zone.go index 68fd346ad..860d98d9a 100644 --- a/api/model_dns_api_zone.go +++ b/api/model_dns_api_zone.go @@ -3,7 +3,7 @@ gravity No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) -API version: 0.9.2 +API version: 0.9.3 */ // Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. diff --git a/api/model_dns_api_zones_get_output.go b/api/model_dns_api_zones_get_output.go index daf0e1f26..6a18ca3b0 100644 --- a/api/model_dns_api_zones_get_output.go +++ b/api/model_dns_api_zones_get_output.go @@ -3,7 +3,7 @@ gravity No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) -API version: 0.9.2 +API version: 0.9.3 */ // Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. diff --git a/api/model_dns_api_zones_put_input.go b/api/model_dns_api_zones_put_input.go index da6e92f7c..9900e1c70 100644 --- a/api/model_dns_api_zones_put_input.go +++ b/api/model_dns_api_zones_put_input.go @@ -3,7 +3,7 @@ gravity No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) -API version: 0.9.2 +API version: 0.9.3 */ // Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. diff --git a/api/model_dns_role_config.go b/api/model_dns_role_config.go index 729ced7d4..fd3bd2832 100644 --- a/api/model_dns_role_config.go +++ b/api/model_dns_role_config.go @@ -3,7 +3,7 @@ gravity No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) -API version: 0.9.2 +API version: 0.9.3 */ // Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. diff --git a/api/model_extconfig_ext_config_dirs.go b/api/model_extconfig_ext_config_dirs.go index f5f4ec231..cc593c3a6 100644 --- a/api/model_extconfig_ext_config_dirs.go +++ b/api/model_extconfig_ext_config_dirs.go @@ -3,7 +3,7 @@ gravity No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) -API version: 0.9.2 +API version: 0.9.3 */ // Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. diff --git a/api/model_instance_api_instance_info.go b/api/model_instance_api_instance_info.go index 12d7c454d..d10d1f44c 100644 --- a/api/model_instance_api_instance_info.go +++ b/api/model_instance_api_instance_info.go @@ -3,7 +3,7 @@ gravity No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) -API version: 0.9.2 +API version: 0.9.3 */ // Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. diff --git a/api/model_instance_api_instances_output.go b/api/model_instance_api_instances_output.go index 8ab71fb78..05c56ae16 100644 --- a/api/model_instance_api_instances_output.go +++ b/api/model_instance_api_instances_output.go @@ -3,7 +3,7 @@ gravity No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) -API version: 0.9.2 +API version: 0.9.3 */ // Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. diff --git a/api/model_instance_api_role_restart_input.go b/api/model_instance_api_role_restart_input.go index f69934ea0..b4828b65e 100644 --- a/api/model_instance_api_role_restart_input.go +++ b/api/model_instance_api_role_restart_input.go @@ -3,7 +3,7 @@ gravity No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) -API version: 0.9.2 +API version: 0.9.3 */ // Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. diff --git a/api/model_instance_instance_info.go b/api/model_instance_instance_info.go index 75345837a..d82fc6f13 100644 --- a/api/model_instance_instance_info.go +++ b/api/model_instance_instance_info.go @@ -3,7 +3,7 @@ gravity No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) -API version: 0.9.2 +API version: 0.9.3 */ // Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. diff --git a/api/model_monitoring_api_role_config_input.go b/api/model_monitoring_api_role_config_input.go index 28fbde530..47a22cc06 100644 --- a/api/model_monitoring_api_role_config_input.go +++ b/api/model_monitoring_api_role_config_input.go @@ -3,7 +3,7 @@ gravity No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) -API version: 0.9.2 +API version: 0.9.3 */ // Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. diff --git a/api/model_monitoring_api_role_config_output.go b/api/model_monitoring_api_role_config_output.go index 808fe7f49..4c98dfde3 100644 --- a/api/model_monitoring_api_role_config_output.go +++ b/api/model_monitoring_api_role_config_output.go @@ -3,7 +3,7 @@ gravity No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) -API version: 0.9.2 +API version: 0.9.3 */ // Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. diff --git a/api/model_monitoring_role_config.go b/api/model_monitoring_role_config.go index c907f31f2..80e513527 100644 --- a/api/model_monitoring_role_config.go +++ b/api/model_monitoring_role_config.go @@ -3,7 +3,7 @@ gravity No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) -API version: 0.9.2 +API version: 0.9.3 */ // Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. diff --git a/api/model_rest_err_response.go b/api/model_rest_err_response.go index f58d2e198..731715140 100644 --- a/api/model_rest_err_response.go +++ b/api/model_rest_err_response.go @@ -3,7 +3,7 @@ gravity No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) -API version: 0.9.2 +API version: 0.9.3 */ // Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. diff --git a/api/model_tsdb_api_role_config_input.go b/api/model_tsdb_api_role_config_input.go index c273c4c84..4a524472e 100644 --- a/api/model_tsdb_api_role_config_input.go +++ b/api/model_tsdb_api_role_config_input.go @@ -3,7 +3,7 @@ gravity No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) -API version: 0.9.2 +API version: 0.9.3 */ // Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. diff --git a/api/model_tsdb_api_role_config_output.go b/api/model_tsdb_api_role_config_output.go index fa86adf10..db7911b69 100644 --- a/api/model_tsdb_api_role_config_output.go +++ b/api/model_tsdb_api_role_config_output.go @@ -3,7 +3,7 @@ gravity No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) -API version: 0.9.2 +API version: 0.9.3 */ // Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. diff --git a/api/model_tsdb_role_config.go b/api/model_tsdb_role_config.go index 7822cec7c..bf390fd2f 100644 --- a/api/model_tsdb_role_config.go +++ b/api/model_tsdb_role_config.go @@ -3,7 +3,7 @@ gravity No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) -API version: 0.9.2 +API version: 0.9.3 */ // Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. diff --git a/api/model_types_api_metrics_get_output.go b/api/model_types_api_metrics_get_output.go index cd62290f3..d71599d0a 100644 --- a/api/model_types_api_metrics_get_output.go +++ b/api/model_types_api_metrics_get_output.go @@ -3,7 +3,7 @@ gravity No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) -API version: 0.9.2 +API version: 0.9.3 */ // Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. diff --git a/api/model_types_api_metrics_record.go b/api/model_types_api_metrics_record.go index a9411b5ce..b99613fec 100644 --- a/api/model_types_api_metrics_record.go +++ b/api/model_types_api_metrics_record.go @@ -3,7 +3,7 @@ gravity No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) -API version: 0.9.2 +API version: 0.9.3 */ // Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. @@ -12,6 +12,7 @@ package api import ( "encoding/json" + "time" ) // checks if the TypesAPIMetricsRecord type satisfies the MappedNullable interface at compile time @@ -19,19 +20,19 @@ var _ MappedNullable = &TypesAPIMetricsRecord{} // TypesAPIMetricsRecord struct for TypesAPIMetricsRecord type TypesAPIMetricsRecord struct { - Handler string `json:"handler"` - Node string `json:"node"` - Time string `json:"time"` - Value int32 `json:"value"` + Keys []string `json:"keys"` + Node string `json:"node"` + Time time.Time `json:"time"` + Value int32 `json:"value"` } // NewTypesAPIMetricsRecord instantiates a new TypesAPIMetricsRecord object // This constructor will assign default values to properties that have it defined, // and makes sure properties required by API are set, but the set of arguments // will change when the set of required properties is changed -func NewTypesAPIMetricsRecord(handler string, node string, time string, value int32) *TypesAPIMetricsRecord { +func NewTypesAPIMetricsRecord(keys []string, node string, time time.Time, value int32) *TypesAPIMetricsRecord { this := TypesAPIMetricsRecord{} - this.Handler = handler + this.Keys = keys this.Node = node this.Time = time this.Value = value @@ -46,28 +47,30 @@ func NewTypesAPIMetricsRecordWithDefaults() *TypesAPIMetricsRecord { return &this } -// GetHandler returns the Handler field value -func (o *TypesAPIMetricsRecord) GetHandler() string { +// GetKeys returns the Keys field value +// If the value is explicit nil, the zero value for []string will be returned +func (o *TypesAPIMetricsRecord) GetKeys() []string { if o == nil { - var ret string + var ret []string return ret } - return o.Handler + return o.Keys } -// GetHandlerOk returns a tuple with the Handler field value +// GetKeysOk returns a tuple with the Keys field value // and a boolean to check if the value has been set. -func (o *TypesAPIMetricsRecord) GetHandlerOk() (*string, bool) { - if o == nil { +// NOTE: If the value is an explicit nil, `nil, true` will be returned +func (o *TypesAPIMetricsRecord) GetKeysOk() ([]string, bool) { + if o == nil || IsNil(o.Keys) { return nil, false } - return &o.Handler, true + return o.Keys, true } -// SetHandler sets field value -func (o *TypesAPIMetricsRecord) SetHandler(v string) { - o.Handler = v +// SetKeys sets field value +func (o *TypesAPIMetricsRecord) SetKeys(v []string) { + o.Keys = v } // GetNode returns the Node field value @@ -95,9 +98,9 @@ func (o *TypesAPIMetricsRecord) SetNode(v string) { } // GetTime returns the Time field value -func (o *TypesAPIMetricsRecord) GetTime() string { +func (o *TypesAPIMetricsRecord) GetTime() time.Time { if o == nil { - var ret string + var ret time.Time return ret } @@ -106,7 +109,7 @@ func (o *TypesAPIMetricsRecord) GetTime() string { // GetTimeOk returns a tuple with the Time field value // and a boolean to check if the value has been set. -func (o *TypesAPIMetricsRecord) GetTimeOk() (*string, bool) { +func (o *TypesAPIMetricsRecord) GetTimeOk() (*time.Time, bool) { if o == nil { return nil, false } @@ -114,7 +117,7 @@ func (o *TypesAPIMetricsRecord) GetTimeOk() (*string, bool) { } // SetTime sets field value -func (o *TypesAPIMetricsRecord) SetTime(v string) { +func (o *TypesAPIMetricsRecord) SetTime(v time.Time) { o.Time = v } @@ -152,7 +155,9 @@ func (o TypesAPIMetricsRecord) MarshalJSON() ([]byte, error) { func (o TypesAPIMetricsRecord) ToMap() (map[string]interface{}, error) { toSerialize := map[string]interface{}{} - toSerialize["handler"] = o.Handler + if o.Keys != nil { + toSerialize["keys"] = o.Keys + } toSerialize["node"] = o.Node toSerialize["time"] = o.Time toSerialize["value"] = o.Value diff --git a/api/model_types_api_metrics_role.go b/api/model_types_api_metrics_role.go new file mode 100644 index 000000000..6ee45261f --- /dev/null +++ b/api/model_types_api_metrics_role.go @@ -0,0 +1,110 @@ +/* +gravity + +No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) + +API version: 0.9.3 +*/ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package api + +import ( + "encoding/json" + "fmt" +) + +// TypesAPIMetricsRole the model 'TypesAPIMetricsRole' +type TypesAPIMetricsRole string + +// List of TypesAPIMetricsRole +const ( + TYPESAPIMETRICSROLE_SYSTEM TypesAPIMetricsRole = "system" + TYPESAPIMETRICSROLE_DNS TypesAPIMetricsRole = "dns" +) + +// All allowed values of TypesAPIMetricsRole enum +var AllowedTypesAPIMetricsRoleEnumValues = []TypesAPIMetricsRole{ + "system", + "dns", +} + +func (v *TypesAPIMetricsRole) UnmarshalJSON(src []byte) error { + var value string + err := json.Unmarshal(src, &value) + if err != nil { + return err + } + enumTypeValue := TypesAPIMetricsRole(value) + for _, existing := range AllowedTypesAPIMetricsRoleEnumValues { + if existing == enumTypeValue { + *v = enumTypeValue + return nil + } + } + + return fmt.Errorf("%+v is not a valid TypesAPIMetricsRole", value) +} + +// NewTypesAPIMetricsRoleFromValue returns a pointer to a valid TypesAPIMetricsRole +// for the value passed as argument, or an error if the value passed is not allowed by the enum +func NewTypesAPIMetricsRoleFromValue(v string) (*TypesAPIMetricsRole, error) { + ev := TypesAPIMetricsRole(v) + if ev.IsValid() { + return &ev, nil + } else { + return nil, fmt.Errorf("invalid value '%v' for TypesAPIMetricsRole: valid values are %v", v, AllowedTypesAPIMetricsRoleEnumValues) + } +} + +// IsValid return true if the value is valid for the enum, false otherwise +func (v TypesAPIMetricsRole) IsValid() bool { + for _, existing := range AllowedTypesAPIMetricsRoleEnumValues { + if existing == v { + return true + } + } + return false +} + +// Ptr returns reference to TypesAPIMetricsRole value +func (v TypesAPIMetricsRole) Ptr() *TypesAPIMetricsRole { + return &v +} + +type NullableTypesAPIMetricsRole struct { + value *TypesAPIMetricsRole + isSet bool +} + +func (v NullableTypesAPIMetricsRole) Get() *TypesAPIMetricsRole { + return v.value +} + +func (v *NullableTypesAPIMetricsRole) Set(val *TypesAPIMetricsRole) { + v.value = val + v.isSet = true +} + +func (v NullableTypesAPIMetricsRole) IsSet() bool { + return v.isSet +} + +func (v *NullableTypesAPIMetricsRole) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableTypesAPIMetricsRole(val *TypesAPIMetricsRole) *NullableTypesAPIMetricsRole { + return &NullableTypesAPIMetricsRole{value: val, isSet: true} +} + +func (v NullableTypesAPIMetricsRole) MarshalJSON() ([]byte, error) { + return json.Marshal(v.value) +} + +func (v *NullableTypesAPIMetricsRole) UnmarshalJSON(src []byte) error { + v.isSet = true + return json.Unmarshal(src, &v.value) +} diff --git a/api/model_types_dhcp_option.go b/api/model_types_dhcp_option.go index f8fd17114..f11f564f9 100644 --- a/api/model_types_dhcp_option.go +++ b/api/model_types_dhcp_option.go @@ -3,7 +3,7 @@ gravity No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) -API version: 0.9.2 +API version: 0.9.3 */ // Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. diff --git a/api/model_types_oidc_config.go b/api/model_types_oidc_config.go index 7feccbf04..d36335039 100644 --- a/api/model_types_oidc_config.go +++ b/api/model_types_oidc_config.go @@ -3,7 +3,7 @@ gravity No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) -API version: 0.9.2 +API version: 0.9.3 */ // Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. diff --git a/api/response.go b/api/response.go index aecbf9f87..8a569eb38 100644 --- a/api/response.go +++ b/api/response.go @@ -3,7 +3,7 @@ gravity No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) -API version: 0.9.2 +API version: 0.9.3 */ // Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. diff --git a/api/utils.go b/api/utils.go index 12013904a..468127c3b 100644 --- a/api/utils.go +++ b/api/utils.go @@ -3,7 +3,7 @@ gravity No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) -API version: 0.9.2 +API version: 0.9.3 */ // Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. diff --git a/schema.yml b/schema.yml index 72d0b0b34..b069d6365 100644 --- a/schema.yml +++ b/schema.yml @@ -1,7 +1,7 @@ openapi: 3.0.3 info: title: gravity - version: 0.9.2 + version: 0.9.3 paths: /api/v1/auth/config: get: diff --git a/web/package-lock.json b/web/package-lock.json index d95a407a2..8da936217 100644 --- a/web/package-lock.json +++ b/web/package-lock.json @@ -1,12 +1,12 @@ { "name": "@beryju/gravity-web", - "version": "0.9.2", + "version": "0.9.3", "lockfileVersion": 3, "requires": true, "packages": { "": { "name": "@beryju/gravity-web", - "version": "0.9.2", + "version": "0.9.3", "dependencies": { "@codemirror/lang-javascript": "^6.2.2", "@codemirror/legacy-modes": "^6.4.1", @@ -35,7 +35,7 @@ "eslint-plugin-lit": "^1.15.0", "eslint-plugin-wc": "^2.2.0", "globals": "^15.11.0", - "gravity-api": "^0.9.2", + "gravity-api": "^0.9.3", "lit": "^3.2.1", "moment": "^2.30.1", "prettier": "^3.3.3", @@ -3666,9 +3666,9 @@ "license": "MIT" }, "node_modules/gravity-api": { - "version": "0.9.2", - "resolved": "https://registry.npmjs.org/gravity-api/-/gravity-api-0.9.2.tgz", - "integrity": "sha512-VCKlIT4e9D7y1tfNiHX1ZJEAOkSBxIBK3yzPs9/RFi77PEYCvRdQbPAqdCIseN9Ow4YWXSPSnHei6SskFdZpdw==" + "version": "0.9.3", + "resolved": "https://registry.npmjs.org/gravity-api/-/gravity-api-0.9.3.tgz", + "integrity": "sha512-yaXhalxvScKcAJ1ZQNkT20nfwbRVzOXuHuZ0RHD/VO+WoTGcVkV+k4OXS/ixaaM+/10Jk4tHF1VstKV829fy9w==" }, "node_modules/has-flag": { "version": "3.0.0", diff --git a/web/package.json b/web/package.json index c0a50fa80..2f22316c8 100644 --- a/web/package.json +++ b/web/package.json @@ -1,6 +1,6 @@ { "name": "@beryju/gravity-web", - "version": "0.9.2", + "version": "0.9.3", "description": "", "scripts": { "build": "rm -rf dist/ && rollup -c", @@ -38,7 +38,7 @@ "eslint-plugin-lit": "^1.15.0", "eslint-plugin-wc": "^2.2.0", "globals": "^15.11.0", - "gravity-api": "^0.9.2", + "gravity-api": "^0.9.3", "lit": "^3.2.1", "moment": "^2.30.1", "prettier": "^3.3.3",