All URIs are relative to http://localhost
Method | HTTP request | Description |
---|---|---|
AddFavoriteFeature | Post /api/admin/projects/{projectId}/features/{featureName}/favorites | |
AddFavoriteProject | Post /api/admin/projects/{projectId}/favorites | |
AddFeatureStrategy | Post /api/admin/projects/{projectId}/features/{featureName}/environments/{environment}/strategies | |
AddTag | Post /api/admin/features/{featureName}/tags | Adds a tag to a feature. |
ArchiveFeature | Delete /api/admin/projects/{projectId}/features/{featureName} | Archive a feature. |
ArchiveFeatures | Post /api/admin/projects/{projectId}/archive | Archives a list of features |
BulkToggleFeaturesEnvironmentOff | Post /api/admin/projects/{projectId}/bulk_features/environments/{environment}/off | Bulk disabled a list of features. |
BulkToggleFeaturesEnvironmentOn | Post /api/admin/projects/{projectId}/bulk_features/environments/{environment}/on | Bulk enable a list of features. |
CloneFeature | Post /api/admin/projects/{projectId}/features/{featureName}/clone | |
CreateFeature | Post /api/admin/projects/{projectId}/features | |
DeleteFeatureStrategy | Delete /api/admin/projects/{projectId}/features/{featureName}/environments/{environment}/strategies/{strategyId} | |
GetAllFeatureTypes | Get /api/admin/feature-types | |
GetAllToggles | Get /api/admin/features | |
GetEnvironmentFeatureVariants | Get /api/admin/projects/{projectId}/features/{featureName}/environments/{environment}/variants | Get variants for a feature in an environment |
GetFeature | Get /api/admin/projects/{projectId}/features/{featureName} | Get a feature. |
GetFeatureEnvironment | Get /api/admin/projects/{projectId}/features/{featureName}/environments/{environment} | |
GetFeatureStrategies | Get /api/admin/projects/{projectId}/features/{featureName}/environments/{environment}/strategies | |
GetFeatureStrategy | Get /api/admin/projects/{projectId}/features/{featureName}/environments/{environment}/strategies/{strategyId} | |
GetFeatureVariants | Get /api/admin/projects/{projectId}/features/{featureName}/variants | Retrieve variants for a feature (deprecated) |
GetFeatures | Get /api/admin/projects/{projectId}/features | |
ListTags | Get /api/admin/features/{featureName}/tags | Get all tags for a feature. |
OverwriteEnvironmentFeatureVariants | Put /api/admin/projects/{projectId}/features/{featureName}/environments/{environment}/variants | Create (overwrite) variants for a feature in an environment |
OverwriteFeatureVariants | Put /api/admin/projects/{projectId}/features/{featureName}/variants | Create (overwrite) variants for a feature toggle in all environments |
OverwriteFeatureVariantsOnEnvironments | Put /api/admin/projects/{projectId}/features/{featureName}/variants-batch | |
PatchEnvironmentsFeatureVariants | Patch /api/admin/projects/{projectId}/features/{featureName}/environments/{environment}/variants | Patch a feature's variants in an environment |
PatchFeature | Patch /api/admin/projects/{projectId}/features/{featureName} | |
PatchFeatureStrategy | Patch /api/admin/projects/{projectId}/features/{featureName}/environments/{environment}/strategies/{strategyId} | |
PatchFeatureVariants | Patch /api/admin/projects/{projectId}/features/{featureName}/variants | Apply a patch to a feature's variants (in all environments). |
RemoveFavoriteFeature | Delete /api/admin/projects/{projectId}/features/{featureName}/favorites | |
RemoveFavoriteProject | Delete /api/admin/projects/{projectId}/favorites | |
RemoveTag | Delete /api/admin/features/{featureName}/tags/{type}/{value} | Removes a tag from a feature. |
SetStrategySortOrder | Post /api/admin/projects/{projectId}/features/{featureName}/environments/{environment}/strategies/set-sort-order | |
StaleFeatures | Post /api/admin/projects/{projectId}/stale | Stales a list of features |
ToggleFeatureEnvironmentOff | Post /api/admin/projects/{projectId}/features/{featureName}/environments/{environment}/off | |
ToggleFeatureEnvironmentOn | Post /api/admin/projects/{projectId}/features/{featureName}/environments/{environment}/on | |
UpdateFeature | Put /api/admin/projects/{projectId}/features/{featureName} | |
UpdateFeatureStrategy | Put /api/admin/projects/{projectId}/features/{featureName}/environments/{environment}/strategies/{strategyId} | |
UpdateTags | Put /api/admin/features/{featureName}/tags | Updates multiple tags for a feature. |
ValidateConstraint | Post /api/admin/constraints/validate | |
ValidateFeature | Post /api/admin/features/validate |
AddFavoriteFeature(ctx, projectId, featureName).Execute()
package main
import (
"context"
"fmt"
"os"
openapiclient "github.com/Unleash/unleash-server-api-go/client"
)
func main() {
projectId := "projectId_example" // string |
featureName := "featureName_example" // string |
configuration := openapiclient.NewConfiguration()
apiClient := openapiclient.NewAPIClient(configuration)
r, err := apiClient.FeaturesApi.AddFavoriteFeature(context.Background(), projectId, featureName).Execute()
if err != nil {
fmt.Fprintf(os.Stderr, "Error when calling `FeaturesApi.AddFavoriteFeature``: %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. | |
projectId | string | ||
featureName | string |
Other parameters are passed through a pointer to a apiAddFavoriteFeatureRequest struct via the builder pattern
Name | Type | Description | Notes |
---|
(empty response body)
- Content-Type: Not defined
- Accept: Not defined
[Back to top] [Back to API list] [Back to Model list] [Back to README]
AddFavoriteProject(ctx, projectId).Execute()
package main
import (
"context"
"fmt"
"os"
openapiclient "github.com/Unleash/unleash-server-api-go/client"
)
func main() {
projectId := "projectId_example" // string |
configuration := openapiclient.NewConfiguration()
apiClient := openapiclient.NewAPIClient(configuration)
r, err := apiClient.FeaturesApi.AddFavoriteProject(context.Background(), projectId).Execute()
if err != nil {
fmt.Fprintf(os.Stderr, "Error when calling `FeaturesApi.AddFavoriteProject``: %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. | |
projectId | string |
Other parameters are passed through a pointer to a apiAddFavoriteProjectRequest struct via the builder pattern
Name | Type | Description | Notes |
---|
(empty response body)
- Content-Type: Not defined
- Accept: Not defined
[Back to top] [Back to API list] [Back to Model list] [Back to README]
FeatureStrategySchema AddFeatureStrategy(ctx, projectId, featureName, environment).CreateFeatureStrategySchema(createFeatureStrategySchema).Execute()
package main
import (
"context"
"fmt"
"os"
openapiclient "github.com/Unleash/unleash-server-api-go/client"
)
func main() {
projectId := "projectId_example" // string |
featureName := "featureName_example" // string |
environment := "environment_example" // string |
createFeatureStrategySchema := *openapiclient.NewCreateFeatureStrategySchema("flexibleRollout") // CreateFeatureStrategySchema | createFeatureStrategySchema
configuration := openapiclient.NewConfiguration()
apiClient := openapiclient.NewAPIClient(configuration)
resp, r, err := apiClient.FeaturesApi.AddFeatureStrategy(context.Background(), projectId, featureName, environment).CreateFeatureStrategySchema(createFeatureStrategySchema).Execute()
if err != nil {
fmt.Fprintf(os.Stderr, "Error when calling `FeaturesApi.AddFeatureStrategy``: %v\n", err)
fmt.Fprintf(os.Stderr, "Full HTTP response: %v\n", r)
}
// response from `AddFeatureStrategy`: FeatureStrategySchema
fmt.Fprintf(os.Stdout, "Response from `FeaturesApi.AddFeatureStrategy`: %v\n", resp)
}
Name | Type | Description | Notes |
---|---|---|---|
ctx | context.Context | context for authentication, logging, cancellation, deadlines, tracing, etc. | |
projectId | string | ||
featureName | string | ||
environment | string |
Other parameters are passed through a pointer to a apiAddFeatureStrategyRequest struct via the builder pattern
Name | Type | Description | Notes |
---|
createFeatureStrategySchema | CreateFeatureStrategySchema | createFeatureStrategySchema |
- Content-Type: application/json
- Accept: application/json
[Back to top] [Back to API list] [Back to Model list] [Back to README]
TagSchema AddTag(ctx, featureName).TagSchema(tagSchema).Execute()
Adds a tag to a feature.
package main
import (
"context"
"fmt"
"os"
openapiclient "github.com/Unleash/unleash-server-api-go/client"
)
func main() {
featureName := "featureName_example" // string |
tagSchema := *openapiclient.NewTagSchema("a-tag-value", "simple") // TagSchema | tagSchema
configuration := openapiclient.NewConfiguration()
apiClient := openapiclient.NewAPIClient(configuration)
resp, r, err := apiClient.FeaturesApi.AddTag(context.Background(), featureName).TagSchema(tagSchema).Execute()
if err != nil {
fmt.Fprintf(os.Stderr, "Error when calling `FeaturesApi.AddTag``: %v\n", err)
fmt.Fprintf(os.Stderr, "Full HTTP response: %v\n", r)
}
// response from `AddTag`: TagSchema
fmt.Fprintf(os.Stdout, "Response from `FeaturesApi.AddTag`: %v\n", resp)
}
Name | Type | Description | Notes |
---|---|---|---|
ctx | context.Context | context for authentication, logging, cancellation, deadlines, tracing, etc. | |
featureName | string |
Other parameters are passed through a pointer to a apiAddTagRequest struct via the builder pattern
Name | Type | Description | Notes |
---|
tagSchema | TagSchema | tagSchema |
- Content-Type: application/json
- Accept: application/json
[Back to top] [Back to API list] [Back to Model list] [Back to README]
ArchiveFeature(ctx, projectId, featureName).Execute()
Archive a feature.
package main
import (
"context"
"fmt"
"os"
openapiclient "github.com/Unleash/unleash-server-api-go/client"
)
func main() {
projectId := "projectId_example" // string |
featureName := "featureName_example" // string |
configuration := openapiclient.NewConfiguration()
apiClient := openapiclient.NewAPIClient(configuration)
r, err := apiClient.FeaturesApi.ArchiveFeature(context.Background(), projectId, featureName).Execute()
if err != nil {
fmt.Fprintf(os.Stderr, "Error when calling `FeaturesApi.ArchiveFeature``: %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. | |
projectId | string | ||
featureName | string |
Other parameters are passed through a pointer to a apiArchiveFeatureRequest 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]
ArchiveFeatures(ctx, projectId).BatchFeaturesSchema(batchFeaturesSchema).Execute()
Archives a list of features
package main
import (
"context"
"fmt"
"os"
openapiclient "github.com/Unleash/unleash-server-api-go/client"
)
func main() {
projectId := "projectId_example" // string |
batchFeaturesSchema := *openapiclient.NewBatchFeaturesSchema([]string{"Features_example"}) // BatchFeaturesSchema | batchFeaturesSchema
configuration := openapiclient.NewConfiguration()
apiClient := openapiclient.NewAPIClient(configuration)
r, err := apiClient.FeaturesApi.ArchiveFeatures(context.Background(), projectId).BatchFeaturesSchema(batchFeaturesSchema).Execute()
if err != nil {
fmt.Fprintf(os.Stderr, "Error when calling `FeaturesApi.ArchiveFeatures``: %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. | |
projectId | string |
Other parameters are passed through a pointer to a apiArchiveFeaturesRequest struct via the builder pattern
Name | Type | Description | Notes |
---|
batchFeaturesSchema | BatchFeaturesSchema | batchFeaturesSchema |
(empty response body)
- Content-Type: application/json
- Accept: Not defined
[Back to top] [Back to API list] [Back to Model list] [Back to README]
BulkToggleFeaturesEnvironmentOff(ctx, projectId, environment).BulkToggleFeaturesSchema(bulkToggleFeaturesSchema).Execute()
Bulk disabled a list of features.
package main
import (
"context"
"fmt"
"os"
openapiclient "github.com/Unleash/unleash-server-api-go/client"
)
func main() {
projectId := "projectId_example" // string |
environment := "environment_example" // string |
bulkToggleFeaturesSchema := *openapiclient.NewBulkToggleFeaturesSchema([]string{"Features_example"}) // BulkToggleFeaturesSchema | bulkToggleFeaturesSchema
configuration := openapiclient.NewConfiguration()
apiClient := openapiclient.NewAPIClient(configuration)
r, err := apiClient.FeaturesApi.BulkToggleFeaturesEnvironmentOff(context.Background(), projectId, environment).BulkToggleFeaturesSchema(bulkToggleFeaturesSchema).Execute()
if err != nil {
fmt.Fprintf(os.Stderr, "Error when calling `FeaturesApi.BulkToggleFeaturesEnvironmentOff``: %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. | |
projectId | string | ||
environment | string |
Other parameters are passed through a pointer to a apiBulkToggleFeaturesEnvironmentOffRequest struct via the builder pattern
Name | Type | Description | Notes |
---|
bulkToggleFeaturesSchema | BulkToggleFeaturesSchema | bulkToggleFeaturesSchema |
(empty response body)
- Content-Type: application/json
- Accept: Not defined
[Back to top] [Back to API list] [Back to Model list] [Back to README]
BulkToggleFeaturesEnvironmentOn(ctx, projectId, environment).BulkToggleFeaturesSchema(bulkToggleFeaturesSchema).Execute()
Bulk enable a list of features.
package main
import (
"context"
"fmt"
"os"
openapiclient "github.com/Unleash/unleash-server-api-go/client"
)
func main() {
projectId := "projectId_example" // string |
environment := "environment_example" // string |
bulkToggleFeaturesSchema := *openapiclient.NewBulkToggleFeaturesSchema([]string{"Features_example"}) // BulkToggleFeaturesSchema | bulkToggleFeaturesSchema
configuration := openapiclient.NewConfiguration()
apiClient := openapiclient.NewAPIClient(configuration)
r, err := apiClient.FeaturesApi.BulkToggleFeaturesEnvironmentOn(context.Background(), projectId, environment).BulkToggleFeaturesSchema(bulkToggleFeaturesSchema).Execute()
if err != nil {
fmt.Fprintf(os.Stderr, "Error when calling `FeaturesApi.BulkToggleFeaturesEnvironmentOn``: %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. | |
projectId | string | ||
environment | string |
Other parameters are passed through a pointer to a apiBulkToggleFeaturesEnvironmentOnRequest struct via the builder pattern
Name | Type | Description | Notes |
---|
bulkToggleFeaturesSchema | BulkToggleFeaturesSchema | bulkToggleFeaturesSchema |
(empty response body)
- Content-Type: application/json
- Accept: Not defined
[Back to top] [Back to API list] [Back to Model list] [Back to README]
FeatureSchema CloneFeature(ctx, projectId, featureName).CloneFeatureSchema(cloneFeatureSchema).Execute()
package main
import (
"context"
"fmt"
"os"
openapiclient "github.com/Unleash/unleash-server-api-go/client"
)
func main() {
projectId := "projectId_example" // string |
featureName := "featureName_example" // string |
cloneFeatureSchema := *openapiclient.NewCloneFeatureSchema("Name_example") // CloneFeatureSchema | cloneFeatureSchema
configuration := openapiclient.NewConfiguration()
apiClient := openapiclient.NewAPIClient(configuration)
resp, r, err := apiClient.FeaturesApi.CloneFeature(context.Background(), projectId, featureName).CloneFeatureSchema(cloneFeatureSchema).Execute()
if err != nil {
fmt.Fprintf(os.Stderr, "Error when calling `FeaturesApi.CloneFeature``: %v\n", err)
fmt.Fprintf(os.Stderr, "Full HTTP response: %v\n", r)
}
// response from `CloneFeature`: FeatureSchema
fmt.Fprintf(os.Stdout, "Response from `FeaturesApi.CloneFeature`: %v\n", resp)
}
Name | Type | Description | Notes |
---|---|---|---|
ctx | context.Context | context for authentication, logging, cancellation, deadlines, tracing, etc. | |
projectId | string | ||
featureName | string |
Other parameters are passed through a pointer to a apiCloneFeatureRequest struct via the builder pattern
Name | Type | Description | Notes |
---|
cloneFeatureSchema | CloneFeatureSchema | cloneFeatureSchema |
- Content-Type: application/json
- Accept: application/json
[Back to top] [Back to API list] [Back to Model list] [Back to README]
FeatureSchema CreateFeature(ctx, projectId).CreateFeatureSchema(createFeatureSchema).Execute()
package main
import (
"context"
"fmt"
"os"
openapiclient "github.com/Unleash/unleash-server-api-go/client"
)
func main() {
projectId := "projectId_example" // string |
createFeatureSchema := *openapiclient.NewCreateFeatureSchema("Name_example") // CreateFeatureSchema | createFeatureSchema
configuration := openapiclient.NewConfiguration()
apiClient := openapiclient.NewAPIClient(configuration)
resp, r, err := apiClient.FeaturesApi.CreateFeature(context.Background(), projectId).CreateFeatureSchema(createFeatureSchema).Execute()
if err != nil {
fmt.Fprintf(os.Stderr, "Error when calling `FeaturesApi.CreateFeature``: %v\n", err)
fmt.Fprintf(os.Stderr, "Full HTTP response: %v\n", r)
}
// response from `CreateFeature`: FeatureSchema
fmt.Fprintf(os.Stdout, "Response from `FeaturesApi.CreateFeature`: %v\n", resp)
}
Name | Type | Description | Notes |
---|---|---|---|
ctx | context.Context | context for authentication, logging, cancellation, deadlines, tracing, etc. | |
projectId | string |
Other parameters are passed through a pointer to a apiCreateFeatureRequest struct via the builder pattern
Name | Type | Description | Notes |
---|
createFeatureSchema | CreateFeatureSchema | createFeatureSchema |
- Content-Type: application/json
- Accept: application/json
[Back to top] [Back to API list] [Back to Model list] [Back to README]
DeleteFeatureStrategy(ctx, projectId, featureName, environment, strategyId).Execute()
package main
import (
"context"
"fmt"
"os"
openapiclient "github.com/Unleash/unleash-server-api-go/client"
)
func main() {
projectId := "projectId_example" // string |
featureName := "featureName_example" // string |
environment := "environment_example" // string |
strategyId := "strategyId_example" // string |
configuration := openapiclient.NewConfiguration()
apiClient := openapiclient.NewAPIClient(configuration)
r, err := apiClient.FeaturesApi.DeleteFeatureStrategy(context.Background(), projectId, featureName, environment, strategyId).Execute()
if err != nil {
fmt.Fprintf(os.Stderr, "Error when calling `FeaturesApi.DeleteFeatureStrategy``: %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. | |
projectId | string | ||
featureName | string | ||
environment | string | ||
strategyId | string |
Other parameters are passed through a pointer to a apiDeleteFeatureStrategyRequest struct via the builder pattern
Name | Type | Description | Notes |
---|
(empty response body)
- Content-Type: Not defined
- Accept: Not defined
[Back to top] [Back to API list] [Back to Model list] [Back to README]
FeatureTypesSchema GetAllFeatureTypes(ctx).Execute()
package main
import (
"context"
"fmt"
"os"
openapiclient "github.com/Unleash/unleash-server-api-go/client"
)
func main() {
configuration := openapiclient.NewConfiguration()
apiClient := openapiclient.NewAPIClient(configuration)
resp, r, err := apiClient.FeaturesApi.GetAllFeatureTypes(context.Background()).Execute()
if err != nil {
fmt.Fprintf(os.Stderr, "Error when calling `FeaturesApi.GetAllFeatureTypes``: %v\n", err)
fmt.Fprintf(os.Stderr, "Full HTTP response: %v\n", r)
}
// response from `GetAllFeatureTypes`: FeatureTypesSchema
fmt.Fprintf(os.Stdout, "Response from `FeaturesApi.GetAllFeatureTypes`: %v\n", resp)
}
This endpoint does not need any parameter.
Other parameters are passed through a pointer to a apiGetAllFeatureTypesRequest struct via the builder pattern
- Content-Type: Not defined
- Accept: application/json
[Back to top] [Back to API list] [Back to Model list] [Back to README]
FeaturesSchema GetAllToggles(ctx).Execute()
package main
import (
"context"
"fmt"
"os"
openapiclient "github.com/Unleash/unleash-server-api-go/client"
)
func main() {
configuration := openapiclient.NewConfiguration()
apiClient := openapiclient.NewAPIClient(configuration)
resp, r, err := apiClient.FeaturesApi.GetAllToggles(context.Background()).Execute()
if err != nil {
fmt.Fprintf(os.Stderr, "Error when calling `FeaturesApi.GetAllToggles``: %v\n", err)
fmt.Fprintf(os.Stderr, "Full HTTP response: %v\n", r)
}
// response from `GetAllToggles`: FeaturesSchema
fmt.Fprintf(os.Stdout, "Response from `FeaturesApi.GetAllToggles`: %v\n", resp)
}
This endpoint does not need any parameter.
Other parameters are passed through a pointer to a apiGetAllTogglesRequest struct via the builder pattern
- Content-Type: Not defined
- Accept: application/json
[Back to top] [Back to API list] [Back to Model list] [Back to README]
FeatureVariantsSchema GetEnvironmentFeatureVariants(ctx, projectId, featureName, environment).Execute()
Get variants for a feature in an environment
package main
import (
"context"
"fmt"
"os"
openapiclient "github.com/Unleash/unleash-server-api-go/client"
)
func main() {
projectId := "projectId_example" // string |
featureName := "featureName_example" // string |
environment := "environment_example" // string |
configuration := openapiclient.NewConfiguration()
apiClient := openapiclient.NewAPIClient(configuration)
resp, r, err := apiClient.FeaturesApi.GetEnvironmentFeatureVariants(context.Background(), projectId, featureName, environment).Execute()
if err != nil {
fmt.Fprintf(os.Stderr, "Error when calling `FeaturesApi.GetEnvironmentFeatureVariants``: %v\n", err)
fmt.Fprintf(os.Stderr, "Full HTTP response: %v\n", r)
}
// response from `GetEnvironmentFeatureVariants`: FeatureVariantsSchema
fmt.Fprintf(os.Stdout, "Response from `FeaturesApi.GetEnvironmentFeatureVariants`: %v\n", resp)
}
Name | Type | Description | Notes |
---|---|---|---|
ctx | context.Context | context for authentication, logging, cancellation, deadlines, tracing, etc. | |
projectId | string | ||
featureName | string | ||
environment | string |
Other parameters are passed through a pointer to a apiGetEnvironmentFeatureVariantsRequest struct via the builder pattern
Name | Type | Description | Notes |
---|
- Content-Type: Not defined
- Accept: application/json
[Back to top] [Back to API list] [Back to Model list] [Back to README]
FeatureSchema GetFeature(ctx, projectId, featureName).Execute()
Get a feature.
package main
import (
"context"
"fmt"
"os"
openapiclient "github.com/Unleash/unleash-server-api-go/client"
)
func main() {
projectId := "projectId_example" // string |
featureName := "featureName_example" // string |
configuration := openapiclient.NewConfiguration()
apiClient := openapiclient.NewAPIClient(configuration)
resp, r, err := apiClient.FeaturesApi.GetFeature(context.Background(), projectId, featureName).Execute()
if err != nil {
fmt.Fprintf(os.Stderr, "Error when calling `FeaturesApi.GetFeature``: %v\n", err)
fmt.Fprintf(os.Stderr, "Full HTTP response: %v\n", r)
}
// response from `GetFeature`: FeatureSchema
fmt.Fprintf(os.Stdout, "Response from `FeaturesApi.GetFeature`: %v\n", resp)
}
Name | Type | Description | Notes |
---|---|---|---|
ctx | context.Context | context for authentication, logging, cancellation, deadlines, tracing, etc. | |
projectId | string | ||
featureName | string |
Other parameters are passed through a pointer to a apiGetFeatureRequest struct via the builder pattern
Name | Type | Description | Notes |
---|
- Content-Type: Not defined
- Accept: application/json
[Back to top] [Back to API list] [Back to Model list] [Back to README]
FeatureEnvironmentSchema GetFeatureEnvironment(ctx, projectId, featureName, environment).Execute()
package main
import (
"context"
"fmt"
"os"
openapiclient "github.com/Unleash/unleash-server-api-go/client"
)
func main() {
projectId := "projectId_example" // string |
featureName := "featureName_example" // string |
environment := "environment_example" // string |
configuration := openapiclient.NewConfiguration()
apiClient := openapiclient.NewAPIClient(configuration)
resp, r, err := apiClient.FeaturesApi.GetFeatureEnvironment(context.Background(), projectId, featureName, environment).Execute()
if err != nil {
fmt.Fprintf(os.Stderr, "Error when calling `FeaturesApi.GetFeatureEnvironment``: %v\n", err)
fmt.Fprintf(os.Stderr, "Full HTTP response: %v\n", r)
}
// response from `GetFeatureEnvironment`: FeatureEnvironmentSchema
fmt.Fprintf(os.Stdout, "Response from `FeaturesApi.GetFeatureEnvironment`: %v\n", resp)
}
Name | Type | Description | Notes |
---|---|---|---|
ctx | context.Context | context for authentication, logging, cancellation, deadlines, tracing, etc. | |
projectId | string | ||
featureName | string | ||
environment | string |
Other parameters are passed through a pointer to a apiGetFeatureEnvironmentRequest struct via the builder pattern
Name | Type | Description | Notes |
---|
- Content-Type: Not defined
- Accept: application/json
[Back to top] [Back to API list] [Back to Model list] [Back to README]
FeatureStrategySchema GetFeatureStrategies(ctx, projectId, featureName, environment).Execute()
package main
import (
"context"
"fmt"
"os"
openapiclient "github.com/Unleash/unleash-server-api-go/client"
)
func main() {
projectId := "projectId_example" // string |
featureName := "featureName_example" // string |
environment := "environment_example" // string |
configuration := openapiclient.NewConfiguration()
apiClient := openapiclient.NewAPIClient(configuration)
resp, r, err := apiClient.FeaturesApi.GetFeatureStrategies(context.Background(), projectId, featureName, environment).Execute()
if err != nil {
fmt.Fprintf(os.Stderr, "Error when calling `FeaturesApi.GetFeatureStrategies``: %v\n", err)
fmt.Fprintf(os.Stderr, "Full HTTP response: %v\n", r)
}
// response from `GetFeatureStrategies`: FeatureStrategySchema
fmt.Fprintf(os.Stdout, "Response from `FeaturesApi.GetFeatureStrategies`: %v\n", resp)
}
Name | Type | Description | Notes |
---|---|---|---|
ctx | context.Context | context for authentication, logging, cancellation, deadlines, tracing, etc. | |
projectId | string | ||
featureName | string | ||
environment | string |
Other parameters are passed through a pointer to a apiGetFeatureStrategiesRequest struct via the builder pattern
Name | Type | Description | Notes |
---|
- Content-Type: Not defined
- Accept: application/json
[Back to top] [Back to API list] [Back to Model list] [Back to README]
FeatureStrategySchema GetFeatureStrategy(ctx, projectId, featureName, environment, strategyId).Execute()
package main
import (
"context"
"fmt"
"os"
openapiclient "github.com/Unleash/unleash-server-api-go/client"
)
func main() {
projectId := "projectId_example" // string |
featureName := "featureName_example" // string |
environment := "environment_example" // string |
strategyId := "strategyId_example" // string |
configuration := openapiclient.NewConfiguration()
apiClient := openapiclient.NewAPIClient(configuration)
resp, r, err := apiClient.FeaturesApi.GetFeatureStrategy(context.Background(), projectId, featureName, environment, strategyId).Execute()
if err != nil {
fmt.Fprintf(os.Stderr, "Error when calling `FeaturesApi.GetFeatureStrategy``: %v\n", err)
fmt.Fprintf(os.Stderr, "Full HTTP response: %v\n", r)
}
// response from `GetFeatureStrategy`: FeatureStrategySchema
fmt.Fprintf(os.Stdout, "Response from `FeaturesApi.GetFeatureStrategy`: %v\n", resp)
}
Name | Type | Description | Notes |
---|---|---|---|
ctx | context.Context | context for authentication, logging, cancellation, deadlines, tracing, etc. | |
projectId | string | ||
featureName | string | ||
environment | string | ||
strategyId | string |
Other parameters are passed through a pointer to a apiGetFeatureStrategyRequest struct via the builder pattern
Name | Type | Description | Notes |
---|
- Content-Type: Not defined
- Accept: application/json
[Back to top] [Back to API list] [Back to Model list] [Back to README]
FeatureVariantsSchema GetFeatureVariants(ctx, projectId, featureName).Execute()
Retrieve variants for a feature (deprecated)
package main
import (
"context"
"fmt"
"os"
openapiclient "github.com/Unleash/unleash-server-api-go/client"
)
func main() {
projectId := "projectId_example" // string |
featureName := "featureName_example" // string |
configuration := openapiclient.NewConfiguration()
apiClient := openapiclient.NewAPIClient(configuration)
resp, r, err := apiClient.FeaturesApi.GetFeatureVariants(context.Background(), projectId, featureName).Execute()
if err != nil {
fmt.Fprintf(os.Stderr, "Error when calling `FeaturesApi.GetFeatureVariants``: %v\n", err)
fmt.Fprintf(os.Stderr, "Full HTTP response: %v\n", r)
}
// response from `GetFeatureVariants`: FeatureVariantsSchema
fmt.Fprintf(os.Stdout, "Response from `FeaturesApi.GetFeatureVariants`: %v\n", resp)
}
Name | Type | Description | Notes |
---|---|---|---|
ctx | context.Context | context for authentication, logging, cancellation, deadlines, tracing, etc. | |
projectId | string | ||
featureName | string |
Other parameters are passed through a pointer to a apiGetFeatureVariantsRequest struct via the builder pattern
Name | Type | Description | Notes |
---|
- Content-Type: Not defined
- Accept: application/json
[Back to top] [Back to API list] [Back to Model list] [Back to README]
FeaturesSchema GetFeatures(ctx, projectId).Execute()
package main
import (
"context"
"fmt"
"os"
openapiclient "github.com/Unleash/unleash-server-api-go/client"
)
func main() {
projectId := "projectId_example" // string |
configuration := openapiclient.NewConfiguration()
apiClient := openapiclient.NewAPIClient(configuration)
resp, r, err := apiClient.FeaturesApi.GetFeatures(context.Background(), projectId).Execute()
if err != nil {
fmt.Fprintf(os.Stderr, "Error when calling `FeaturesApi.GetFeatures``: %v\n", err)
fmt.Fprintf(os.Stderr, "Full HTTP response: %v\n", r)
}
// response from `GetFeatures`: FeaturesSchema
fmt.Fprintf(os.Stdout, "Response from `FeaturesApi.GetFeatures`: %v\n", resp)
}
Name | Type | Description | Notes |
---|---|---|---|
ctx | context.Context | context for authentication, logging, cancellation, deadlines, tracing, etc. | |
projectId | string |
Other parameters are passed through a pointer to a apiGetFeaturesRequest struct via the builder pattern
Name | Type | Description | Notes |
---|
- Content-Type: Not defined
- Accept: application/json
[Back to top] [Back to API list] [Back to Model list] [Back to README]
TagsSchema ListTags(ctx, featureName).Execute()
Get all tags for a feature.
package main
import (
"context"
"fmt"
"os"
openapiclient "github.com/Unleash/unleash-server-api-go/client"
)
func main() {
featureName := "featureName_example" // string |
configuration := openapiclient.NewConfiguration()
apiClient := openapiclient.NewAPIClient(configuration)
resp, r, err := apiClient.FeaturesApi.ListTags(context.Background(), featureName).Execute()
if err != nil {
fmt.Fprintf(os.Stderr, "Error when calling `FeaturesApi.ListTags``: %v\n", err)
fmt.Fprintf(os.Stderr, "Full HTTP response: %v\n", r)
}
// response from `ListTags`: TagsSchema
fmt.Fprintf(os.Stdout, "Response from `FeaturesApi.ListTags`: %v\n", resp)
}
Name | Type | Description | Notes |
---|---|---|---|
ctx | context.Context | context for authentication, logging, cancellation, deadlines, tracing, etc. | |
featureName | string |
Other parameters are passed through a pointer to a apiListTagsRequest struct via the builder pattern
Name | Type | Description | Notes |
---|
- Content-Type: Not defined
- Accept: application/json
[Back to top] [Back to API list] [Back to Model list] [Back to README]
FeatureVariantsSchema OverwriteEnvironmentFeatureVariants(ctx, projectId, featureName, environment).VariantSchema(variantSchema).Execute()
Create (overwrite) variants for a feature in an environment
package main
import (
"context"
"fmt"
"os"
openapiclient "github.com/Unleash/unleash-server-api-go/client"
)
func main() {
projectId := "projectId_example" // string |
featureName := "featureName_example" // string |
environment := "environment_example" // string |
variantSchema := []openapiclient.VariantSchema{*openapiclient.NewVariantSchema("blue_group", float32(123))} // []VariantSchema | variantsSchema
configuration := openapiclient.NewConfiguration()
apiClient := openapiclient.NewAPIClient(configuration)
resp, r, err := apiClient.FeaturesApi.OverwriteEnvironmentFeatureVariants(context.Background(), projectId, featureName, environment).VariantSchema(variantSchema).Execute()
if err != nil {
fmt.Fprintf(os.Stderr, "Error when calling `FeaturesApi.OverwriteEnvironmentFeatureVariants``: %v\n", err)
fmt.Fprintf(os.Stderr, "Full HTTP response: %v\n", r)
}
// response from `OverwriteEnvironmentFeatureVariants`: FeatureVariantsSchema
fmt.Fprintf(os.Stdout, "Response from `FeaturesApi.OverwriteEnvironmentFeatureVariants`: %v\n", resp)
}
Name | Type | Description | Notes |
---|---|---|---|
ctx | context.Context | context for authentication, logging, cancellation, deadlines, tracing, etc. | |
projectId | string | ||
featureName | string | ||
environment | string |
Other parameters are passed through a pointer to a apiOverwriteEnvironmentFeatureVariantsRequest struct via the builder pattern
Name | Type | Description | Notes |
---|
variantSchema | []VariantSchema | variantsSchema |
- Content-Type: application/json
- Accept: application/json
[Back to top] [Back to API list] [Back to Model list] [Back to README]
FeatureVariantsSchema OverwriteFeatureVariants(ctx, projectId, featureName).VariantSchema(variantSchema).Execute()
Create (overwrite) variants for a feature toggle in all environments
package main
import (
"context"
"fmt"
"os"
openapiclient "github.com/Unleash/unleash-server-api-go/client"
)
func main() {
projectId := "projectId_example" // string |
featureName := "featureName_example" // string |
variantSchema := []openapiclient.VariantSchema{*openapiclient.NewVariantSchema("blue_group", float32(123))} // []VariantSchema | variantsSchema
configuration := openapiclient.NewConfiguration()
apiClient := openapiclient.NewAPIClient(configuration)
resp, r, err := apiClient.FeaturesApi.OverwriteFeatureVariants(context.Background(), projectId, featureName).VariantSchema(variantSchema).Execute()
if err != nil {
fmt.Fprintf(os.Stderr, "Error when calling `FeaturesApi.OverwriteFeatureVariants``: %v\n", err)
fmt.Fprintf(os.Stderr, "Full HTTP response: %v\n", r)
}
// response from `OverwriteFeatureVariants`: FeatureVariantsSchema
fmt.Fprintf(os.Stdout, "Response from `FeaturesApi.OverwriteFeatureVariants`: %v\n", resp)
}
Name | Type | Description | Notes |
---|---|---|---|
ctx | context.Context | context for authentication, logging, cancellation, deadlines, tracing, etc. | |
projectId | string | ||
featureName | string |
Other parameters are passed through a pointer to a apiOverwriteFeatureVariantsRequest struct via the builder pattern
Name | Type | Description | Notes |
---|
variantSchema | []VariantSchema | variantsSchema |
- Content-Type: application/json
- Accept: application/json
[Back to top] [Back to API list] [Back to Model list] [Back to README]
FeatureVariantsSchema OverwriteFeatureVariantsOnEnvironments(ctx, projectId, featureName).PushVariantsSchema(pushVariantsSchema).Execute()
package main
import (
"context"
"fmt"
"os"
openapiclient "github.com/Unleash/unleash-server-api-go/client"
)
func main() {
projectId := "projectId_example" // string |
featureName := "featureName_example" // string |
pushVariantsSchema := *openapiclient.NewPushVariantsSchema() // PushVariantsSchema | pushVariantsSchema
configuration := openapiclient.NewConfiguration()
apiClient := openapiclient.NewAPIClient(configuration)
resp, r, err := apiClient.FeaturesApi.OverwriteFeatureVariantsOnEnvironments(context.Background(), projectId, featureName).PushVariantsSchema(pushVariantsSchema).Execute()
if err != nil {
fmt.Fprintf(os.Stderr, "Error when calling `FeaturesApi.OverwriteFeatureVariantsOnEnvironments``: %v\n", err)
fmt.Fprintf(os.Stderr, "Full HTTP response: %v\n", r)
}
// response from `OverwriteFeatureVariantsOnEnvironments`: FeatureVariantsSchema
fmt.Fprintf(os.Stdout, "Response from `FeaturesApi.OverwriteFeatureVariantsOnEnvironments`: %v\n", resp)
}
Name | Type | Description | Notes |
---|---|---|---|
ctx | context.Context | context for authentication, logging, cancellation, deadlines, tracing, etc. | |
projectId | string | ||
featureName | string |
Other parameters are passed through a pointer to a apiOverwriteFeatureVariantsOnEnvironmentsRequest struct via the builder pattern
Name | Type | Description | Notes |
---|
pushVariantsSchema | PushVariantsSchema | pushVariantsSchema |
- Content-Type: application/json
- Accept: application/json
[Back to top] [Back to API list] [Back to Model list] [Back to README]
FeatureVariantsSchema PatchEnvironmentsFeatureVariants(ctx, projectId, featureName, environment).PatchSchema(patchSchema).Execute()
Patch a feature's variants in an environment
package main
import (
"context"
"fmt"
"os"
openapiclient "github.com/Unleash/unleash-server-api-go/client"
)
func main() {
projectId := "projectId_example" // string |
featureName := "featureName_example" // string |
environment := "environment_example" // string |
patchSchema := []openapiclient.PatchSchema{*openapiclient.NewPatchSchema("Path_example", "Op_example")} // []PatchSchema | patchesSchema
configuration := openapiclient.NewConfiguration()
apiClient := openapiclient.NewAPIClient(configuration)
resp, r, err := apiClient.FeaturesApi.PatchEnvironmentsFeatureVariants(context.Background(), projectId, featureName, environment).PatchSchema(patchSchema).Execute()
if err != nil {
fmt.Fprintf(os.Stderr, "Error when calling `FeaturesApi.PatchEnvironmentsFeatureVariants``: %v\n", err)
fmt.Fprintf(os.Stderr, "Full HTTP response: %v\n", r)
}
// response from `PatchEnvironmentsFeatureVariants`: FeatureVariantsSchema
fmt.Fprintf(os.Stdout, "Response from `FeaturesApi.PatchEnvironmentsFeatureVariants`: %v\n", resp)
}
Name | Type | Description | Notes |
---|---|---|---|
ctx | context.Context | context for authentication, logging, cancellation, deadlines, tracing, etc. | |
projectId | string | ||
featureName | string | ||
environment | string |
Other parameters are passed through a pointer to a apiPatchEnvironmentsFeatureVariantsRequest struct via the builder pattern
Name | Type | Description | Notes |
---|
patchSchema | []PatchSchema | patchesSchema |
- Content-Type: application/json
- Accept: application/json
[Back to top] [Back to API list] [Back to Model list] [Back to README]
FeatureSchema PatchFeature(ctx, projectId, featureName).PatchSchema(patchSchema).Execute()
package main
import (
"context"
"fmt"
"os"
openapiclient "github.com/Unleash/unleash-server-api-go/client"
)
func main() {
projectId := "projectId_example" // string |
featureName := "featureName_example" // string |
patchSchema := []openapiclient.PatchSchema{*openapiclient.NewPatchSchema("Path_example", "Op_example")} // []PatchSchema | patchesSchema
configuration := openapiclient.NewConfiguration()
apiClient := openapiclient.NewAPIClient(configuration)
resp, r, err := apiClient.FeaturesApi.PatchFeature(context.Background(), projectId, featureName).PatchSchema(patchSchema).Execute()
if err != nil {
fmt.Fprintf(os.Stderr, "Error when calling `FeaturesApi.PatchFeature``: %v\n", err)
fmt.Fprintf(os.Stderr, "Full HTTP response: %v\n", r)
}
// response from `PatchFeature`: FeatureSchema
fmt.Fprintf(os.Stdout, "Response from `FeaturesApi.PatchFeature`: %v\n", resp)
}
Name | Type | Description | Notes |
---|---|---|---|
ctx | context.Context | context for authentication, logging, cancellation, deadlines, tracing, etc. | |
projectId | string | ||
featureName | string |
Other parameters are passed through a pointer to a apiPatchFeatureRequest struct via the builder pattern
Name | Type | Description | Notes |
---|
patchSchema | []PatchSchema | patchesSchema |
- Content-Type: application/json
- Accept: application/json
[Back to top] [Back to API list] [Back to Model list] [Back to README]
FeatureStrategySchema PatchFeatureStrategy(ctx, projectId, featureName, environment, strategyId).PatchSchema(patchSchema).Execute()
package main
import (
"context"
"fmt"
"os"
openapiclient "github.com/Unleash/unleash-server-api-go/client"
)
func main() {
projectId := "projectId_example" // string |
featureName := "featureName_example" // string |
environment := "environment_example" // string |
strategyId := "strategyId_example" // string |
patchSchema := []openapiclient.PatchSchema{*openapiclient.NewPatchSchema("Path_example", "Op_example")} // []PatchSchema | patchesSchema
configuration := openapiclient.NewConfiguration()
apiClient := openapiclient.NewAPIClient(configuration)
resp, r, err := apiClient.FeaturesApi.PatchFeatureStrategy(context.Background(), projectId, featureName, environment, strategyId).PatchSchema(patchSchema).Execute()
if err != nil {
fmt.Fprintf(os.Stderr, "Error when calling `FeaturesApi.PatchFeatureStrategy``: %v\n", err)
fmt.Fprintf(os.Stderr, "Full HTTP response: %v\n", r)
}
// response from `PatchFeatureStrategy`: FeatureStrategySchema
fmt.Fprintf(os.Stdout, "Response from `FeaturesApi.PatchFeatureStrategy`: %v\n", resp)
}
Name | Type | Description | Notes |
---|---|---|---|
ctx | context.Context | context for authentication, logging, cancellation, deadlines, tracing, etc. | |
projectId | string | ||
featureName | string | ||
environment | string | ||
strategyId | string |
Other parameters are passed through a pointer to a apiPatchFeatureStrategyRequest struct via the builder pattern
Name | Type | Description | Notes |
---|
patchSchema | []PatchSchema | patchesSchema |
- Content-Type: application/json
- Accept: application/json
[Back to top] [Back to API list] [Back to Model list] [Back to README]
FeatureVariantsSchema PatchFeatureVariants(ctx, projectId, featureName).PatchSchema(patchSchema).Execute()
Apply a patch to a feature's variants (in all environments).
package main
import (
"context"
"fmt"
"os"
openapiclient "github.com/Unleash/unleash-server-api-go/client"
)
func main() {
projectId := "projectId_example" // string |
featureName := "featureName_example" // string |
patchSchema := []openapiclient.PatchSchema{*openapiclient.NewPatchSchema("Path_example", "Op_example")} // []PatchSchema | patchesSchema
configuration := openapiclient.NewConfiguration()
apiClient := openapiclient.NewAPIClient(configuration)
resp, r, err := apiClient.FeaturesApi.PatchFeatureVariants(context.Background(), projectId, featureName).PatchSchema(patchSchema).Execute()
if err != nil {
fmt.Fprintf(os.Stderr, "Error when calling `FeaturesApi.PatchFeatureVariants``: %v\n", err)
fmt.Fprintf(os.Stderr, "Full HTTP response: %v\n", r)
}
// response from `PatchFeatureVariants`: FeatureVariantsSchema
fmt.Fprintf(os.Stdout, "Response from `FeaturesApi.PatchFeatureVariants`: %v\n", resp)
}
Name | Type | Description | Notes |
---|---|---|---|
ctx | context.Context | context for authentication, logging, cancellation, deadlines, tracing, etc. | |
projectId | string | ||
featureName | string |
Other parameters are passed through a pointer to a apiPatchFeatureVariantsRequest struct via the builder pattern
Name | Type | Description | Notes |
---|
patchSchema | []PatchSchema | patchesSchema |
- Content-Type: application/json
- Accept: application/json
[Back to top] [Back to API list] [Back to Model list] [Back to README]
RemoveFavoriteFeature(ctx, projectId, featureName).Execute()
package main
import (
"context"
"fmt"
"os"
openapiclient "github.com/Unleash/unleash-server-api-go/client"
)
func main() {
projectId := "projectId_example" // string |
featureName := "featureName_example" // string |
configuration := openapiclient.NewConfiguration()
apiClient := openapiclient.NewAPIClient(configuration)
r, err := apiClient.FeaturesApi.RemoveFavoriteFeature(context.Background(), projectId, featureName).Execute()
if err != nil {
fmt.Fprintf(os.Stderr, "Error when calling `FeaturesApi.RemoveFavoriteFeature``: %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. | |
projectId | string | ||
featureName | string |
Other parameters are passed through a pointer to a apiRemoveFavoriteFeatureRequest struct via the builder pattern
Name | Type | Description | Notes |
---|
(empty response body)
- Content-Type: Not defined
- Accept: Not defined
[Back to top] [Back to API list] [Back to Model list] [Back to README]
RemoveFavoriteProject(ctx, projectId).Execute()
package main
import (
"context"
"fmt"
"os"
openapiclient "github.com/Unleash/unleash-server-api-go/client"
)
func main() {
projectId := "projectId_example" // string |
configuration := openapiclient.NewConfiguration()
apiClient := openapiclient.NewAPIClient(configuration)
r, err := apiClient.FeaturesApi.RemoveFavoriteProject(context.Background(), projectId).Execute()
if err != nil {
fmt.Fprintf(os.Stderr, "Error when calling `FeaturesApi.RemoveFavoriteProject``: %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. | |
projectId | string |
Other parameters are passed through a pointer to a apiRemoveFavoriteProjectRequest struct via the builder pattern
Name | Type | Description | Notes |
---|
(empty response body)
- Content-Type: Not defined
- Accept: Not defined
[Back to top] [Back to API list] [Back to Model list] [Back to README]
RemoveTag(ctx, featureName, type_, value).Execute()
Removes a tag from a feature.
package main
import (
"context"
"fmt"
"os"
openapiclient "github.com/Unleash/unleash-server-api-go/client"
)
func main() {
featureName := "featureName_example" // string |
type_ := "type__example" // string |
value := "value_example" // string |
configuration := openapiclient.NewConfiguration()
apiClient := openapiclient.NewAPIClient(configuration)
r, err := apiClient.FeaturesApi.RemoveTag(context.Background(), featureName, type_, value).Execute()
if err != nil {
fmt.Fprintf(os.Stderr, "Error when calling `FeaturesApi.RemoveTag``: %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. | |
featureName | string | ||
type_ | string | ||
value | string |
Other parameters are passed through a pointer to a apiRemoveTagRequest 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]
SetStrategySortOrder(ctx, projectId, featureName, environment).SetStrategySortOrderSchemaInner(setStrategySortOrderSchemaInner).Execute()
package main
import (
"context"
"fmt"
"os"
openapiclient "github.com/Unleash/unleash-server-api-go/client"
)
func main() {
projectId := "projectId_example" // string |
featureName := "featureName_example" // string |
environment := "environment_example" // string |
setStrategySortOrderSchemaInner := []openapiclient.SetStrategySortOrderSchemaInner{*openapiclient.NewSetStrategySortOrderSchemaInner("Id_example", float32(123))} // []SetStrategySortOrderSchemaInner | setStrategySortOrderSchema
configuration := openapiclient.NewConfiguration()
apiClient := openapiclient.NewAPIClient(configuration)
r, err := apiClient.FeaturesApi.SetStrategySortOrder(context.Background(), projectId, featureName, environment).SetStrategySortOrderSchemaInner(setStrategySortOrderSchemaInner).Execute()
if err != nil {
fmt.Fprintf(os.Stderr, "Error when calling `FeaturesApi.SetStrategySortOrder``: %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. | |
projectId | string | ||
featureName | string | ||
environment | string |
Other parameters are passed through a pointer to a apiSetStrategySortOrderRequest struct via the builder pattern
Name | Type | Description | Notes |
---|
setStrategySortOrderSchemaInner | []SetStrategySortOrderSchemaInner | setStrategySortOrderSchema |
(empty response body)
- Content-Type: application/json
- Accept: Not defined
[Back to top] [Back to API list] [Back to Model list] [Back to README]
StaleFeatures(ctx, projectId).BatchStaleSchema(batchStaleSchema).Execute()
Stales a list of features
package main
import (
"context"
"fmt"
"os"
openapiclient "github.com/Unleash/unleash-server-api-go/client"
)
func main() {
projectId := "projectId_example" // string |
batchStaleSchema := *openapiclient.NewBatchStaleSchema([]string{"Features_example"}, false) // BatchStaleSchema | batchStaleSchema
configuration := openapiclient.NewConfiguration()
apiClient := openapiclient.NewAPIClient(configuration)
r, err := apiClient.FeaturesApi.StaleFeatures(context.Background(), projectId).BatchStaleSchema(batchStaleSchema).Execute()
if err != nil {
fmt.Fprintf(os.Stderr, "Error when calling `FeaturesApi.StaleFeatures``: %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. | |
projectId | string |
Other parameters are passed through a pointer to a apiStaleFeaturesRequest struct via the builder pattern
Name | Type | Description | Notes |
---|
batchStaleSchema | BatchStaleSchema | batchStaleSchema |
(empty response body)
- Content-Type: application/json
- Accept: Not defined
[Back to top] [Back to API list] [Back to Model list] [Back to README]
FeatureSchema ToggleFeatureEnvironmentOff(ctx, projectId, featureName, environment).Execute()
package main
import (
"context"
"fmt"
"os"
openapiclient "github.com/Unleash/unleash-server-api-go/client"
)
func main() {
projectId := "projectId_example" // string |
featureName := "featureName_example" // string |
environment := "environment_example" // string |
configuration := openapiclient.NewConfiguration()
apiClient := openapiclient.NewAPIClient(configuration)
resp, r, err := apiClient.FeaturesApi.ToggleFeatureEnvironmentOff(context.Background(), projectId, featureName, environment).Execute()
if err != nil {
fmt.Fprintf(os.Stderr, "Error when calling `FeaturesApi.ToggleFeatureEnvironmentOff``: %v\n", err)
fmt.Fprintf(os.Stderr, "Full HTTP response: %v\n", r)
}
// response from `ToggleFeatureEnvironmentOff`: FeatureSchema
fmt.Fprintf(os.Stdout, "Response from `FeaturesApi.ToggleFeatureEnvironmentOff`: %v\n", resp)
}
Name | Type | Description | Notes |
---|---|---|---|
ctx | context.Context | context for authentication, logging, cancellation, deadlines, tracing, etc. | |
projectId | string | ||
featureName | string | ||
environment | string |
Other parameters are passed through a pointer to a apiToggleFeatureEnvironmentOffRequest struct via the builder pattern
Name | Type | Description | Notes |
---|
- Content-Type: Not defined
- Accept: application/json
[Back to top] [Back to API list] [Back to Model list] [Back to README]
FeatureSchema ToggleFeatureEnvironmentOn(ctx, projectId, featureName, environment).Execute()
package main
import (
"context"
"fmt"
"os"
openapiclient "github.com/Unleash/unleash-server-api-go/client"
)
func main() {
projectId := "projectId_example" // string |
featureName := "featureName_example" // string |
environment := "environment_example" // string |
configuration := openapiclient.NewConfiguration()
apiClient := openapiclient.NewAPIClient(configuration)
resp, r, err := apiClient.FeaturesApi.ToggleFeatureEnvironmentOn(context.Background(), projectId, featureName, environment).Execute()
if err != nil {
fmt.Fprintf(os.Stderr, "Error when calling `FeaturesApi.ToggleFeatureEnvironmentOn``: %v\n", err)
fmt.Fprintf(os.Stderr, "Full HTTP response: %v\n", r)
}
// response from `ToggleFeatureEnvironmentOn`: FeatureSchema
fmt.Fprintf(os.Stdout, "Response from `FeaturesApi.ToggleFeatureEnvironmentOn`: %v\n", resp)
}
Name | Type | Description | Notes |
---|---|---|---|
ctx | context.Context | context for authentication, logging, cancellation, deadlines, tracing, etc. | |
projectId | string | ||
featureName | string | ||
environment | string |
Other parameters are passed through a pointer to a apiToggleFeatureEnvironmentOnRequest struct via the builder pattern
Name | Type | Description | Notes |
---|
- Content-Type: Not defined
- Accept: application/json
[Back to top] [Back to API list] [Back to Model list] [Back to README]
FeatureSchema UpdateFeature(ctx, projectId, featureName).UpdateFeatureSchema(updateFeatureSchema).Execute()
package main
import (
"context"
"fmt"
"os"
openapiclient "github.com/Unleash/unleash-server-api-go/client"
)
func main() {
projectId := "projectId_example" // string |
featureName := "featureName_example" // string |
updateFeatureSchema := *openapiclient.NewUpdateFeatureSchema("Name_example") // UpdateFeatureSchema | updateFeatureSchema
configuration := openapiclient.NewConfiguration()
apiClient := openapiclient.NewAPIClient(configuration)
resp, r, err := apiClient.FeaturesApi.UpdateFeature(context.Background(), projectId, featureName).UpdateFeatureSchema(updateFeatureSchema).Execute()
if err != nil {
fmt.Fprintf(os.Stderr, "Error when calling `FeaturesApi.UpdateFeature``: %v\n", err)
fmt.Fprintf(os.Stderr, "Full HTTP response: %v\n", r)
}
// response from `UpdateFeature`: FeatureSchema
fmt.Fprintf(os.Stdout, "Response from `FeaturesApi.UpdateFeature`: %v\n", resp)
}
Name | Type | Description | Notes |
---|---|---|---|
ctx | context.Context | context for authentication, logging, cancellation, deadlines, tracing, etc. | |
projectId | string | ||
featureName | string |
Other parameters are passed through a pointer to a apiUpdateFeatureRequest struct via the builder pattern
Name | Type | Description | Notes |
---|
updateFeatureSchema | UpdateFeatureSchema | updateFeatureSchema |
- Content-Type: application/json
- Accept: application/json
[Back to top] [Back to API list] [Back to Model list] [Back to README]
FeatureStrategySchema UpdateFeatureStrategy(ctx, projectId, featureName, environment, strategyId).UpdateFeatureStrategySchema(updateFeatureStrategySchema).Execute()
package main
import (
"context"
"fmt"
"os"
openapiclient "github.com/Unleash/unleash-server-api-go/client"
)
func main() {
projectId := "projectId_example" // string |
featureName := "featureName_example" // string |
environment := "environment_example" // string |
strategyId := "strategyId_example" // string |
updateFeatureStrategySchema := *openapiclient.NewUpdateFeatureStrategySchema() // UpdateFeatureStrategySchema | updateFeatureStrategySchema
configuration := openapiclient.NewConfiguration()
apiClient := openapiclient.NewAPIClient(configuration)
resp, r, err := apiClient.FeaturesApi.UpdateFeatureStrategy(context.Background(), projectId, featureName, environment, strategyId).UpdateFeatureStrategySchema(updateFeatureStrategySchema).Execute()
if err != nil {
fmt.Fprintf(os.Stderr, "Error when calling `FeaturesApi.UpdateFeatureStrategy``: %v\n", err)
fmt.Fprintf(os.Stderr, "Full HTTP response: %v\n", r)
}
// response from `UpdateFeatureStrategy`: FeatureStrategySchema
fmt.Fprintf(os.Stdout, "Response from `FeaturesApi.UpdateFeatureStrategy`: %v\n", resp)
}
Name | Type | Description | Notes |
---|---|---|---|
ctx | context.Context | context for authentication, logging, cancellation, deadlines, tracing, etc. | |
projectId | string | ||
featureName | string | ||
environment | string | ||
strategyId | string |
Other parameters are passed through a pointer to a apiUpdateFeatureStrategyRequest struct via the builder pattern
Name | Type | Description | Notes |
---|
updateFeatureStrategySchema | UpdateFeatureStrategySchema | updateFeatureStrategySchema |
- Content-Type: application/json
- Accept: application/json
[Back to top] [Back to API list] [Back to Model list] [Back to README]
TagsSchema UpdateTags(ctx, featureName).UpdateTagsSchema(updateTagsSchema).Execute()
Updates multiple tags for a feature.
package main
import (
"context"
"fmt"
"os"
openapiclient "github.com/Unleash/unleash-server-api-go/client"
)
func main() {
featureName := "featureName_example" // string |
updateTagsSchema := *openapiclient.NewUpdateTagsSchema([]openapiclient.TagSchema{*openapiclient.NewTagSchema("a-tag-value", "simple")}, []openapiclient.TagSchema{*openapiclient.NewTagSchema("a-tag-value", "simple")}) // UpdateTagsSchema | updateTagsSchema
configuration := openapiclient.NewConfiguration()
apiClient := openapiclient.NewAPIClient(configuration)
resp, r, err := apiClient.FeaturesApi.UpdateTags(context.Background(), featureName).UpdateTagsSchema(updateTagsSchema).Execute()
if err != nil {
fmt.Fprintf(os.Stderr, "Error when calling `FeaturesApi.UpdateTags``: %v\n", err)
fmt.Fprintf(os.Stderr, "Full HTTP response: %v\n", r)
}
// response from `UpdateTags`: TagsSchema
fmt.Fprintf(os.Stdout, "Response from `FeaturesApi.UpdateTags`: %v\n", resp)
}
Name | Type | Description | Notes |
---|---|---|---|
ctx | context.Context | context for authentication, logging, cancellation, deadlines, tracing, etc. | |
featureName | string |
Other parameters are passed through a pointer to a apiUpdateTagsRequest struct via the builder pattern
Name | Type | Description | Notes |
---|
updateTagsSchema | UpdateTagsSchema | updateTagsSchema |
- Content-Type: application/json
- Accept: application/json
[Back to top] [Back to API list] [Back to Model list] [Back to README]
ValidateConstraint(ctx).ConstraintSchema(constraintSchema).Execute()
package main
import (
"context"
"fmt"
"os"
openapiclient "github.com/Unleash/unleash-server-api-go/client"
)
func main() {
constraintSchema := *openapiclient.NewConstraintSchema("appName", "IN") // ConstraintSchema | constraintSchema
configuration := openapiclient.NewConfiguration()
apiClient := openapiclient.NewAPIClient(configuration)
r, err := apiClient.FeaturesApi.ValidateConstraint(context.Background()).ConstraintSchema(constraintSchema).Execute()
if err != nil {
fmt.Fprintf(os.Stderr, "Error when calling `FeaturesApi.ValidateConstraint``: %v\n", err)
fmt.Fprintf(os.Stderr, "Full HTTP response: %v\n", r)
}
}
Other parameters are passed through a pointer to a apiValidateConstraintRequest struct via the builder pattern
Name | Type | Description | Notes |
---|---|---|---|
constraintSchema | ConstraintSchema | constraintSchema |
(empty response body)
- Content-Type: application/json
- Accept: Not defined
[Back to top] [Back to API list] [Back to Model list] [Back to README]
ValidateFeature(ctx).Execute()
package main
import (
"context"
"fmt"
"os"
openapiclient "github.com/Unleash/unleash-server-api-go/client"
)
func main() {
configuration := openapiclient.NewConfiguration()
apiClient := openapiclient.NewAPIClient(configuration)
r, err := apiClient.FeaturesApi.ValidateFeature(context.Background()).Execute()
if err != nil {
fmt.Fprintf(os.Stderr, "Error when calling `FeaturesApi.ValidateFeature``: %v\n", err)
fmt.Fprintf(os.Stderr, "Full HTTP response: %v\n", r)
}
}
This endpoint does not need any parameter.
Other parameters are passed through a pointer to a apiValidateFeatureRequest struct via the builder pattern
(empty response body)
- Content-Type: Not defined
- Accept: Not defined
[Back to top] [Back to API list] [Back to Model list] [Back to README]