Skip to content

Latest commit

 

History

History
288 lines (186 loc) · 7.92 KB

ApplicationActionsAPI.md

File metadata and controls

288 lines (186 loc) · 7.92 KB

\ApplicationActionsAPI

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

Method HTTP request Description
DeployApplication Post /application/{applicationId}/deploy Deploy application
RebootApplication Post /application/{applicationId}/restart-service Reboot application
RedeployApplication Post /application/{applicationId}/redeploy Redeploy application
StopApplication Post /application/{applicationId}/stop Stop application

DeployApplication

Status DeployApplication(ctx, applicationId).DeployRequest(deployRequest).Execute()

Deploy application

Example

package main

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

func main() {
	applicationId := "38400000-8cf0-11bd-b23e-10b96e4ef00d" // string | Application ID
	deployRequest := *openapiclient.NewDeployRequest("GitCommitId_example") // DeployRequest |  (optional)

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

Path Parameters

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

Other Parameters

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

Name Type Description Notes

deployRequest | DeployRequest | |

Return type

Status

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]

RebootApplication

Status RebootApplication(ctx, applicationId).Execute()

Reboot application

Example

package main

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

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

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

Path Parameters

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

Other Parameters

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

Name Type Description Notes

Return type

Status

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]

RedeployApplication

Status RedeployApplication(ctx, applicationId).Execute()

Redeploy application

Example

package main

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

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

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

Path Parameters

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

Other Parameters

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

Name Type Description Notes

Return type

Status

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]

StopApplication

Status StopApplication(ctx, applicationId).Execute()

Stop application

Example

package main

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

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

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

Path Parameters

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

Other Parameters

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

Name Type Description Notes

Return type

Status

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]