Skip to content

Latest commit

 

History

History
564 lines (364 loc) · 16.4 KB

EnvironmentMainCallsAPI.md

File metadata and controls

564 lines (364 loc) · 16.4 KB

\EnvironmentMainCallsAPI

All URIs are relative to https://api.qovery.com

Method HTTP request Description
DeleteEnvironment Delete /environment/{environmentId} Delete an environment
EditEnvironment Put /environment/{environmentId} Edit an environment
GetEnvironment Get /environment/{environmentId} Get environment by ID
GetEnvironmentStatus Get /environment/{environmentId}/status Get environment status
GetEnvironmentStatuses Get /environment/{environmentId}/statuses Get environment statuses with services status
GetEnvironmentStatusesWithStages Get /environment/{environmentId}/statusesWithStages Get environment statuses with stages
ListDeploymentRequestByEnvironmentId Get /environment/{environmentId}/deploymentQueue List Deployment Request By EnvironmentId
ListServicesByEnvironmentId Get /environment/{environmentId}/services List Services By EnvironmentId

DeleteEnvironment

DeleteEnvironment(ctx, environmentId).Execute()

Delete an environment

Example

package main

import (
	"context"
	"fmt"
	"os"
	openapiclient "github.com/qovery/qovery-client-go"
)

func main() {
	environmentId := "38400000-8cf0-11bd-b23e-10b96e4ef00d" // string | Environment ID

	configuration := openapiclient.NewConfiguration()
	apiClient := openapiclient.NewAPIClient(configuration)
	r, err := apiClient.EnvironmentMainCallsAPI.DeleteEnvironment(context.Background(), environmentId).Execute()
	if err != nil {
		fmt.Fprintf(os.Stderr, "Error when calling `EnvironmentMainCallsAPI.DeleteEnvironment``: %v\n", err)
		fmt.Fprintf(os.Stderr, "Full HTTP response: %v\n", r)
	}
}

Path Parameters

Name Type Description Notes
ctx context.Context context for authentication, logging, cancellation, deadlines, tracing, etc.
environmentId string Environment ID

Other Parameters

Other parameters are passed through a pointer to a apiDeleteEnvironmentRequest struct via the builder pattern

Name Type Description Notes

Return type

(empty response body)

Authorization

ApiKeyAuth, bearerAuth

HTTP request headers

  • Content-Type: Not defined
  • Accept: Not defined

[Back to top] [Back to API list] [Back to Model list] [Back to README]

EditEnvironment

Environment EditEnvironment(ctx, environmentId).EnvironmentEditRequest(environmentEditRequest).Execute()

Edit an environment

Example

package main

import (
	"context"
	"fmt"
	"os"
	openapiclient "github.com/qovery/qovery-client-go"
)

func main() {
	environmentId := "38400000-8cf0-11bd-b23e-10b96e4ef00d" // string | Environment ID
	environmentEditRequest := *openapiclient.NewEnvironmentEditRequest() // EnvironmentEditRequest |  (optional)

	configuration := openapiclient.NewConfiguration()
	apiClient := openapiclient.NewAPIClient(configuration)
	resp, r, err := apiClient.EnvironmentMainCallsAPI.EditEnvironment(context.Background(), environmentId).EnvironmentEditRequest(environmentEditRequest).Execute()
	if err != nil {
		fmt.Fprintf(os.Stderr, "Error when calling `EnvironmentMainCallsAPI.EditEnvironment``: %v\n", err)
		fmt.Fprintf(os.Stderr, "Full HTTP response: %v\n", r)
	}
	// response from `EditEnvironment`: Environment
	fmt.Fprintf(os.Stdout, "Response from `EnvironmentMainCallsAPI.EditEnvironment`: %v\n", resp)
}

Path Parameters

Name Type Description Notes
ctx context.Context context for authentication, logging, cancellation, deadlines, tracing, etc.
environmentId string Environment ID

Other Parameters

Other parameters are passed through a pointer to a apiEditEnvironmentRequest struct via the builder pattern

Name Type Description Notes

environmentEditRequest | EnvironmentEditRequest | |

Return type

Environment

Authorization

ApiKeyAuth, bearerAuth

HTTP request headers

  • Content-Type: application/json
  • Accept: application/json

[Back to top] [Back to API list] [Back to Model list] [Back to README]

GetEnvironment

Environment GetEnvironment(ctx, environmentId).Execute()

Get environment by ID

Example

package main

import (
	"context"
	"fmt"
	"os"
	openapiclient "github.com/qovery/qovery-client-go"
)

func main() {
	environmentId := "38400000-8cf0-11bd-b23e-10b96e4ef00d" // string | Environment ID

	configuration := openapiclient.NewConfiguration()
	apiClient := openapiclient.NewAPIClient(configuration)
	resp, r, err := apiClient.EnvironmentMainCallsAPI.GetEnvironment(context.Background(), environmentId).Execute()
	if err != nil {
		fmt.Fprintf(os.Stderr, "Error when calling `EnvironmentMainCallsAPI.GetEnvironment``: %v\n", err)
		fmt.Fprintf(os.Stderr, "Full HTTP response: %v\n", r)
	}
	// response from `GetEnvironment`: Environment
	fmt.Fprintf(os.Stdout, "Response from `EnvironmentMainCallsAPI.GetEnvironment`: %v\n", resp)
}

Path Parameters

Name Type Description Notes
ctx context.Context context for authentication, logging, cancellation, deadlines, tracing, etc.
environmentId string Environment ID

Other Parameters

Other parameters are passed through a pointer to a apiGetEnvironmentRequest struct via the builder pattern

Name Type Description Notes

Return type

Environment

Authorization

ApiKeyAuth, bearerAuth

HTTP request headers

  • Content-Type: Not defined
  • Accept: application/json

[Back to top] [Back to API list] [Back to Model list] [Back to README]

GetEnvironmentStatus

EnvironmentStatus GetEnvironmentStatus(ctx, environmentId).Execute()

Get environment status

Example

package main

import (
	"context"
	"fmt"
	"os"
	openapiclient "github.com/qovery/qovery-client-go"
)

func main() {
	environmentId := "38400000-8cf0-11bd-b23e-10b96e4ef00d" // string | Environment ID

	configuration := openapiclient.NewConfiguration()
	apiClient := openapiclient.NewAPIClient(configuration)
	resp, r, err := apiClient.EnvironmentMainCallsAPI.GetEnvironmentStatus(context.Background(), environmentId).Execute()
	if err != nil {
		fmt.Fprintf(os.Stderr, "Error when calling `EnvironmentMainCallsAPI.GetEnvironmentStatus``: %v\n", err)
		fmt.Fprintf(os.Stderr, "Full HTTP response: %v\n", r)
	}
	// response from `GetEnvironmentStatus`: EnvironmentStatus
	fmt.Fprintf(os.Stdout, "Response from `EnvironmentMainCallsAPI.GetEnvironmentStatus`: %v\n", resp)
}

Path Parameters

Name Type Description Notes
ctx context.Context context for authentication, logging, cancellation, deadlines, tracing, etc.
environmentId string Environment ID

Other Parameters

Other parameters are passed through a pointer to a apiGetEnvironmentStatusRequest struct via the builder pattern

Name Type Description Notes

Return type

EnvironmentStatus

Authorization

ApiKeyAuth, bearerAuth

HTTP request headers

  • Content-Type: Not defined
  • Accept: application/json

[Back to top] [Back to API list] [Back to Model list] [Back to README]

GetEnvironmentStatuses

EnvironmentStatuses GetEnvironmentStatuses(ctx, environmentId).Execute()

Get environment statuses with services status

Example

package main

import (
	"context"
	"fmt"
	"os"
	openapiclient "github.com/qovery/qovery-client-go"
)

func main() {
	environmentId := "38400000-8cf0-11bd-b23e-10b96e4ef00d" // string | Environment ID

	configuration := openapiclient.NewConfiguration()
	apiClient := openapiclient.NewAPIClient(configuration)
	resp, r, err := apiClient.EnvironmentMainCallsAPI.GetEnvironmentStatuses(context.Background(), environmentId).Execute()
	if err != nil {
		fmt.Fprintf(os.Stderr, "Error when calling `EnvironmentMainCallsAPI.GetEnvironmentStatuses``: %v\n", err)
		fmt.Fprintf(os.Stderr, "Full HTTP response: %v\n", r)
	}
	// response from `GetEnvironmentStatuses`: EnvironmentStatuses
	fmt.Fprintf(os.Stdout, "Response from `EnvironmentMainCallsAPI.GetEnvironmentStatuses`: %v\n", resp)
}

Path Parameters

Name Type Description Notes
ctx context.Context context for authentication, logging, cancellation, deadlines, tracing, etc.
environmentId string Environment ID

Other Parameters

Other parameters are passed through a pointer to a apiGetEnvironmentStatusesRequest struct via the builder pattern

Name Type Description Notes

Return type

EnvironmentStatuses

Authorization

ApiKeyAuth, bearerAuth

HTTP request headers

  • Content-Type: Not defined
  • Accept: application/json

[Back to top] [Back to API list] [Back to Model list] [Back to README]

GetEnvironmentStatusesWithStages

EnvironmentStatusesWithStages GetEnvironmentStatusesWithStages(ctx, environmentId).Execute()

Get environment statuses with stages

Example

package main

import (
	"context"
	"fmt"
	"os"
	openapiclient "github.com/qovery/qovery-client-go"
)

func main() {
	environmentId := "38400000-8cf0-11bd-b23e-10b96e4ef00d" // string | Environment ID

	configuration := openapiclient.NewConfiguration()
	apiClient := openapiclient.NewAPIClient(configuration)
	resp, r, err := apiClient.EnvironmentMainCallsAPI.GetEnvironmentStatusesWithStages(context.Background(), environmentId).Execute()
	if err != nil {
		fmt.Fprintf(os.Stderr, "Error when calling `EnvironmentMainCallsAPI.GetEnvironmentStatusesWithStages``: %v\n", err)
		fmt.Fprintf(os.Stderr, "Full HTTP response: %v\n", r)
	}
	// response from `GetEnvironmentStatusesWithStages`: EnvironmentStatusesWithStages
	fmt.Fprintf(os.Stdout, "Response from `EnvironmentMainCallsAPI.GetEnvironmentStatusesWithStages`: %v\n", resp)
}

Path Parameters

Name Type Description Notes
ctx context.Context context for authentication, logging, cancellation, deadlines, tracing, etc.
environmentId string Environment ID

Other Parameters

Other parameters are passed through a pointer to a apiGetEnvironmentStatusesWithStagesRequest struct via the builder pattern

Name Type Description Notes

Return type

EnvironmentStatusesWithStages

Authorization

ApiKeyAuth, bearerAuth

HTTP request headers

  • Content-Type: Not defined
  • Accept: application/json

[Back to top] [Back to API list] [Back to Model list] [Back to README]

ListDeploymentRequestByEnvironmentId

ListDeploymentRequestByEnvironmentId200Response ListDeploymentRequestByEnvironmentId(ctx, environmentId).Execute()

List Deployment Request By EnvironmentId

Example

package main

import (
	"context"
	"fmt"
	"os"
	openapiclient "github.com/qovery/qovery-client-go"
)

func main() {
	environmentId := "38400000-8cf0-11bd-b23e-10b96e4ef00d" // string | 

	configuration := openapiclient.NewConfiguration()
	apiClient := openapiclient.NewAPIClient(configuration)
	resp, r, err := apiClient.EnvironmentMainCallsAPI.ListDeploymentRequestByEnvironmentId(context.Background(), environmentId).Execute()
	if err != nil {
		fmt.Fprintf(os.Stderr, "Error when calling `EnvironmentMainCallsAPI.ListDeploymentRequestByEnvironmentId``: %v\n", err)
		fmt.Fprintf(os.Stderr, "Full HTTP response: %v\n", r)
	}
	// response from `ListDeploymentRequestByEnvironmentId`: ListDeploymentRequestByEnvironmentId200Response
	fmt.Fprintf(os.Stdout, "Response from `EnvironmentMainCallsAPI.ListDeploymentRequestByEnvironmentId`: %v\n", resp)
}

Path Parameters

Name Type Description Notes
ctx context.Context context for authentication, logging, cancellation, deadlines, tracing, etc.
environmentId string

Other Parameters

Other parameters are passed through a pointer to a apiListDeploymentRequestByEnvironmentIdRequest struct via the builder pattern

Name Type Description Notes

Return type

ListDeploymentRequestByEnvironmentId200Response

Authorization

ApiKeyAuth, bearerAuth

HTTP request headers

  • Content-Type: Not defined
  • Accept: application/json

[Back to top] [Back to API list] [Back to Model list] [Back to README]

ListServicesByEnvironmentId

ListServicesByEnvironmentId200Response ListServicesByEnvironmentId(ctx, environmentId).Execute()

List Services By EnvironmentId

Example

package main

import (
	"context"
	"fmt"
	"os"
	openapiclient "github.com/qovery/qovery-client-go"
)

func main() {
	environmentId := "environmentId_example" // string | 

	configuration := openapiclient.NewConfiguration()
	apiClient := openapiclient.NewAPIClient(configuration)
	resp, r, err := apiClient.EnvironmentMainCallsAPI.ListServicesByEnvironmentId(context.Background(), environmentId).Execute()
	if err != nil {
		fmt.Fprintf(os.Stderr, "Error when calling `EnvironmentMainCallsAPI.ListServicesByEnvironmentId``: %v\n", err)
		fmt.Fprintf(os.Stderr, "Full HTTP response: %v\n", r)
	}
	// response from `ListServicesByEnvironmentId`: ListServicesByEnvironmentId200Response
	fmt.Fprintf(os.Stdout, "Response from `EnvironmentMainCallsAPI.ListServicesByEnvironmentId`: %v\n", resp)
}

Path Parameters

Name Type Description Notes
ctx context.Context context for authentication, logging, cancellation, deadlines, tracing, etc.
environmentId string

Other Parameters

Other parameters are passed through a pointer to a apiListServicesByEnvironmentIdRequest struct via the builder pattern

Name Type Description Notes

Return type

ListServicesByEnvironmentId200Response

Authorization

ApiKeyAuth, bearerAuth

HTTP request headers

  • Content-Type: Not defined
  • Accept: application/json

[Back to top] [Back to API list] [Back to Model list] [Back to README]