All URIs are relative to https://app.launchdarkly.com
Method | HTTP request | Description |
---|---|---|
CreateWorkflowTemplate | Post /api/v2/templates | Create workflow template |
DeleteWorkflowTemplate | Delete /api/v2/templates/{templateKey} | Delete workflow template |
GetWorkflowTemplates | Get /api/v2/templates | Get workflow templates |
WorkflowTemplateOutput CreateWorkflowTemplate(ctx).CreateWorkflowTemplateInput(createWorkflowTemplateInput).Execute()
Create workflow template
package main
import (
"context"
"fmt"
"os"
openapiclient "./openapi"
)
func main() {
createWorkflowTemplateInput := *openapiclient.NewCreateWorkflowTemplateInput("Key_example") // CreateWorkflowTemplateInput |
configuration := openapiclient.NewConfiguration()
apiClient := openapiclient.NewAPIClient(configuration)
resp, r, err := apiClient.WorkflowTemplatesBetaApi.CreateWorkflowTemplate(context.Background()).CreateWorkflowTemplateInput(createWorkflowTemplateInput).Execute()
if err != nil {
fmt.Fprintf(os.Stderr, "Error when calling `WorkflowTemplatesBetaApi.CreateWorkflowTemplate``: %v\n", err)
fmt.Fprintf(os.Stderr, "Full HTTP response: %v\n", r)
}
// response from `CreateWorkflowTemplate`: WorkflowTemplateOutput
fmt.Fprintf(os.Stdout, "Response from `WorkflowTemplatesBetaApi.CreateWorkflowTemplate`: %v\n", resp)
}
Other parameters are passed through a pointer to a apiCreateWorkflowTemplateRequest struct via the builder pattern
Name | Type | Description | Notes |
---|---|---|---|
createWorkflowTemplateInput | CreateWorkflowTemplateInput |
- Content-Type: application/json
- Accept: application/json
[Back to top] [Back to API list] [Back to Model list] [Back to README]
DeleteWorkflowTemplate(ctx, templateKey).Execute()
Delete workflow template
package main
import (
"context"
"fmt"
"os"
openapiclient "./openapi"
)
func main() {
templateKey := "templateKey_example" // string | The template key
configuration := openapiclient.NewConfiguration()
apiClient := openapiclient.NewAPIClient(configuration)
resp, r, err := apiClient.WorkflowTemplatesBetaApi.DeleteWorkflowTemplate(context.Background(), templateKey).Execute()
if err != nil {
fmt.Fprintf(os.Stderr, "Error when calling `WorkflowTemplatesBetaApi.DeleteWorkflowTemplate``: %v\n", err)
fmt.Fprintf(os.Stderr, "Full HTTP response: %v\n", r)
}
}
Name | Type | Description | Notes |
---|---|---|---|
ctx | context.Context | context for authentication, logging, cancellation, deadlines, tracing, etc. | |
templateKey | string | The template key |
Other parameters are passed through a pointer to a apiDeleteWorkflowTemplateRequest struct via the builder pattern
Name | Type | Description | Notes |
---|
(empty response body)
- Content-Type: Not defined
- Accept: application/json
[Back to top] [Back to API list] [Back to Model list] [Back to README]
WorkflowTemplatesListingOutputRep GetWorkflowTemplates(ctx).Summary(summary).Search(search).Execute()
Get workflow templates
package main
import (
"context"
"fmt"
"os"
openapiclient "./openapi"
)
func main() {
summary := true // bool | Whether the entire template object or just a summary should be returned (optional)
search := "search_example" // string | The substring in either the name or description of a template (optional)
configuration := openapiclient.NewConfiguration()
apiClient := openapiclient.NewAPIClient(configuration)
resp, r, err := apiClient.WorkflowTemplatesBetaApi.GetWorkflowTemplates(context.Background()).Summary(summary).Search(search).Execute()
if err != nil {
fmt.Fprintf(os.Stderr, "Error when calling `WorkflowTemplatesBetaApi.GetWorkflowTemplates``: %v\n", err)
fmt.Fprintf(os.Stderr, "Full HTTP response: %v\n", r)
}
// response from `GetWorkflowTemplates`: WorkflowTemplatesListingOutputRep
fmt.Fprintf(os.Stdout, "Response from `WorkflowTemplatesBetaApi.GetWorkflowTemplates`: %v\n", resp)
}
Other parameters are passed through a pointer to a apiGetWorkflowTemplatesRequest struct via the builder pattern
Name | Type | Description | Notes |
---|---|---|---|
summary | bool | Whether the entire template object or just a summary should be returned | |
search | string | The substring in either the name or description of a template |
WorkflowTemplatesListingOutputRep
- Content-Type: Not defined
- Accept: application/json
[Back to top] [Back to API list] [Back to Model list] [Back to README]