Skip to content

Commit

Permalink
See Qovery/qovery-openapi-spec@7b07743 from refs/heads/main
Browse files Browse the repository at this point in the history
  • Loading branch information
qovery committed Jun 5, 2024
1 parent 87ebc2e commit bd3db82
Show file tree
Hide file tree
Showing 296 changed files with 20,262 additions and 7,941 deletions.
10 changes: 2 additions & 8 deletions .openapi-generator/FILES
Original file line number Diff line number Diff line change
Expand Up @@ -122,10 +122,6 @@ docs/BackupResponseList.md
docs/BackupsAPI.md
docs/Base.md
docs/BaseJobResponse.md
docs/BaseJobResponseAllOfSource.md
docs/BaseJobResponseAllOfSourceOneOf.md
docs/BaseJobResponseAllOfSourceOneOf1.md
docs/BaseJobResponseAllOfSourceOneOf1Docker.md
docs/BillingAPI.md
docs/BillingExternalId.md
docs/BillingInfo.md
Expand Down Expand Up @@ -349,6 +345,7 @@ docs/HelmCheckRequest.md
docs/HelmConfigurationAPI.md
docs/HelmCustomDomainAPI.md
docs/HelmDefaultValuesRequest.md
docs/HelmDefaultValuesRequestAllOfSource.md
docs/HelmDeployRequest.md
docs/HelmDeploymentHistoryAPI.md
docs/HelmDeploymentRestrictionAPI.md
Expand Down Expand Up @@ -638,10 +635,6 @@ model_backup_request.go
model_backup_response_list.go
model_base.go
model_base_job_response.go
model_base_job_response_all_of_source.go
model_base_job_response_all_of_source_one_of.go
model_base_job_response_all_of_source_one_of_1.go
model_base_job_response_all_of_source_one_of_1_docker.go
model_billing_external_id.go
model_billing_info.go
model_billing_info_request.go
Expand Down Expand Up @@ -829,6 +822,7 @@ model_healthcheck.go
model_helm_advanced_settings.go
model_helm_check_request.go
model_helm_default_values_request.go
model_helm_default_values_request_all_of_source.go
model_helm_deploy_request.go
model_helm_deployment_restriction_request.go
model_helm_deployment_restriction_response.go
Expand Down
2 changes: 1 addition & 1 deletion .openapi-generator/VERSION
Original file line number Diff line number Diff line change
@@ -1 +1 @@
7.0.1
7.6.0
34 changes: 16 additions & 18 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -9,27 +9,28 @@ This API client was generated by the [OpenAPI Generator](https://openapi-generat

- API version: 1.0.3
- Package version: 1.0.3
- Generator version: 7.6.0
- Build package: org.openapitools.codegen.languages.GoClientCodegen
For more information, please visit [https://www.qovery.com](https://www.qovery.com)

## Installation

Install the following dependencies:

```shell
```sh
go get github.com/stretchr/testify/assert
go get golang.org/x/net/context
```

Put the package under your project folder and add the following in import:

```golang
```go
import qovery "github.com/qovery/qovery-client-go"
```

To use a proxy, set the environment variable `HTTP_PROXY`:

```golang
```go
os.Setenv("HTTP_PROXY", "http://proxy_name:proxy_port")
```

Expand All @@ -39,17 +40,17 @@ Default configuration comes with `Servers` field that contains server objects as

### Select Server Configuration

For using other server than the one defined on index 0 set context value `sw.ContextServerIndex` of type `int`.
For using other server than the one defined on index 0 set context value `qovery.ContextServerIndex` of type `int`.

```golang
```go
ctx := context.WithValue(context.Background(), qovery.ContextServerIndex, 1)
```

### Templated Server URL

Templated server URL is formatted using default variables from configuration or from context value `sw.ContextServerVariables` of type `map[string]string`.
Templated server URL is formatted using default variables from configuration or from context value `qovery.ContextServerVariables` of type `map[string]string`.

```golang
```go
ctx := context.WithValue(context.Background(), qovery.ContextServerVariables, map[string]string{
"basePath": "v2",
})
Expand All @@ -61,9 +62,9 @@ Note, enum values are always validated and all unused variables are silently ign

Each operation can use different server URL defined using `OperationServers` map in the `Configuration`.
An operation is uniquely identified by `"{classname}Service.{nickname}"` string.
Similar rules for overriding default operation server index and variables applies by using `sw.ContextOperationServerIndices` and `sw.ContextOperationServerVariables` context maps.
Similar rules for overriding default operation server index and variables applies by using `qovery.ContextOperationServerIndices` and `qovery.ContextOperationServerVariables` context maps.

```golang
```go
ctx := context.WithValue(context.Background(), qovery.ContextOperationServerIndices, map[string]int{
"{classname}Service.{nickname}": 2,
})
Expand Down Expand Up @@ -521,10 +522,6 @@ Class | Method | HTTP request | Description
- [BackupResponseList](docs/BackupResponseList.md)
- [Base](docs/Base.md)
- [BaseJobResponse](docs/BaseJobResponse.md)
- [BaseJobResponseAllOfSource](docs/BaseJobResponseAllOfSource.md)
- [BaseJobResponseAllOfSourceOneOf](docs/BaseJobResponseAllOfSourceOneOf.md)
- [BaseJobResponseAllOfSourceOneOf1](docs/BaseJobResponseAllOfSourceOneOf1.md)
- [BaseJobResponseAllOfSourceOneOf1Docker](docs/BaseJobResponseAllOfSourceOneOf1Docker.md)
- [BillingExternalId](docs/BillingExternalId.md)
- [BillingInfo](docs/BillingInfo.md)
- [BillingInfoRequest](docs/BillingInfoRequest.md)
Expand Down Expand Up @@ -712,6 +709,7 @@ Class | Method | HTTP request | Description
- [HelmAdvancedSettings](docs/HelmAdvancedSettings.md)
- [HelmCheckRequest](docs/HelmCheckRequest.md)
- [HelmDefaultValuesRequest](docs/HelmDefaultValuesRequest.md)
- [HelmDefaultValuesRequestAllOfSource](docs/HelmDefaultValuesRequestAllOfSource.md)
- [HelmDeployRequest](docs/HelmDeployRequest.md)
- [HelmDeploymentRestrictionRequest](docs/HelmDeploymentRestrictionRequest.md)
- [HelmDeploymentRestrictionResponse](docs/HelmDeploymentRestrictionResponse.md)
Expand Down Expand Up @@ -951,8 +949,8 @@ Authentication schemes defined for the API:

Example

```golang
auth := context.WithValue(context.Background(), sw.ContextAccessToken, "BEARER_TOKEN_STRING")
```go
auth := context.WithValue(context.Background(), qovery.ContextAccessToken, "BEARER_TOKEN_STRING")
r, err := client.Service.Operation(auth, args)
```

Expand All @@ -966,11 +964,11 @@ Note, each API key must be added to a map of `map[string]APIKey` where the key i

Example

```golang
```go
auth := context.WithValue(
context.Background(),
sw.ContextAPIKeys,
map[string]sw.APIKey{
qovery.ContextAPIKeys,
map[string]qovery.APIKey{
"Authorization": {Key: "API_KEY_STRING"},
},
)
Expand Down
Loading

0 comments on commit bd3db82

Please sign in to comment.