Skip to content

Latest commit

 

History

History
219 lines (139 loc) · 5.59 KB

ProjectMainCallsAPI.md

File metadata and controls

219 lines (139 loc) · 5.59 KB

\ProjectMainCallsAPI

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

Method HTTP request Description
DeleteProject Delete /project/{projectId} Delete a project
EditProject Put /project/{projectId} Edit a project
GetProject Get /project/{projectId} Get project by ID

DeleteProject

DeleteProject(ctx, projectId).Execute()

Delete a project

Example

package main

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

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

	configuration := openapiclient.NewConfiguration()
	apiClient := openapiclient.NewAPIClient(configuration)
	r, err := apiClient.ProjectMainCallsAPI.DeleteProject(context.Background(), projectId).Execute()
	if err != nil {
		fmt.Fprintf(os.Stderr, "Error when calling `ProjectMainCallsAPI.DeleteProject``: %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.
projectId string Project ID

Other Parameters

Other parameters are passed through a pointer to a apiDeleteProjectRequest 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]

EditProject

Project EditProject(ctx, projectId).ProjectRequest(projectRequest).Execute()

Edit a project

Example

package main

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

func main() {
	projectId := "38400000-8cf0-11bd-b23e-10b96e4ef00d" // string | Project ID
	projectRequest := *openapiclient.NewProjectRequest("Name_example") // ProjectRequest |  (optional)

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

Path Parameters

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

Other Parameters

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

Name Type Description Notes

projectRequest | ProjectRequest | |

Return type

Project

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]

GetProject

Project GetProject(ctx, projectId).Execute()

Get project by ID

Example

package main

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

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

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

Path Parameters

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

Other Parameters

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

Name Type Description Notes

Return type

Project

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]