launchdarkly_api 9.0.0 → 9.0.1
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/README.md +12 -9
- data/docs/AccountMembersApi.md +6 -6
- data/docs/EnvironmentsApi.md +1 -1
- data/docs/Experiment.md +36 -0
- data/docs/ExperimentCollectionRep.md +1 -1
- data/docs/ExperimentExpandableProperties.md +20 -0
- data/docs/ExperimentInfoRep.md +1 -1
- data/docs/ExperimentsBetaApi.md +12 -12
- data/docs/FeatureFlagsApi.md +1 -1
- data/docs/FeatureFlagsBetaApi.md +2 -2
- data/docs/IterationExpandableProperties.md +1 -1
- data/docs/IterationRep.md +4 -2
- data/docs/{ExperimentRep.md → LegacyExperimentRep.md} +2 -2
- data/docs/MetricRep.md +43 -3
- data/docs/MetricV2Rep.md +22 -0
- data/docs/OtherApi.md +1 -1
- data/docs/StatisticsRep.md +20 -0
- data/docs/TeamsBetaApi.md +9 -9
- data/docs/TreatmentRep.md +1 -1
- data/docs/UserRecord.md +1 -1
- data/docs/Users.md +1 -1
- data/docs/UsersApi.md +4 -4
- data/docs/UsersRep.md +22 -0
- data/lib/launchdarkly_api/api/account_members_api.rb +6 -6
- data/lib/launchdarkly_api/api/environments_api.rb +2 -2
- data/lib/launchdarkly_api/api/experiments_beta_api.rb +9 -9
- data/lib/launchdarkly_api/api/feature_flags_api.rb +2 -2
- data/lib/launchdarkly_api/api/feature_flags_beta_api.rb +4 -4
- data/lib/launchdarkly_api/api/other_api.rb +2 -2
- data/lib/launchdarkly_api/api/teams_beta_api.rb +12 -12
- data/lib/launchdarkly_api/api/users_api.rb +3 -3
- data/lib/launchdarkly_api/models/experiment.rb +328 -0
- data/lib/launchdarkly_api/models/experiment_collection_rep.rb +1 -1
- data/lib/launchdarkly_api/models/{decimal.rb → experiment_expandable_properties.rb} +18 -17
- data/lib/launchdarkly_api/models/experiment_info_rep.rb +1 -1
- data/lib/launchdarkly_api/models/iteration_expandable_properties.rb +1 -1
- data/lib/launchdarkly_api/models/iteration_rep.rb +12 -3
- data/lib/launchdarkly_api/models/{experiment_rep.rb → legacy_experiment_rep.rb} +3 -3
- data/lib/launchdarkly_api/models/metric_rep.rb +256 -4
- data/lib/launchdarkly_api/models/metric_v2_rep.rb +253 -0
- data/lib/launchdarkly_api/models/{null_decimal.rb → statistics_rep.rb} +20 -16
- data/lib/launchdarkly_api/models/treatment_rep.rb +1 -1
- data/lib/launchdarkly_api/models/users_rep.rb +250 -0
- data/lib/launchdarkly_api/version.rb +1 -1
- data/lib/launchdarkly_api.rb +6 -3
- data/spec/api/account_members_api_spec.rb +3 -3
- data/spec/api/environments_api_spec.rb +1 -1
- data/spec/api/experiments_beta_api_spec.rb +3 -3
- data/spec/api/feature_flags_api_spec.rb +1 -1
- data/spec/api/feature_flags_beta_api_spec.rb +2 -2
- data/spec/api/other_api_spec.rb +1 -1
- data/spec/api/teams_beta_api_spec.rb +6 -6
- data/spec/api/users_api_spec.rb +1 -1
- data/spec/models/{decimal_spec.rb → experiment_expandable_properties_spec.rb} +8 -8
- data/spec/models/experiment_spec.rb +88 -0
- data/spec/models/iteration_rep_spec.rb +6 -0
- data/spec/models/{experiment_rep_spec.rb → legacy_experiment_rep_spec.rb} +6 -6
- data/spec/models/metric_rep_spec.rb +128 -0
- data/spec/models/metric_v2_rep_spec.rb +46 -0
- data/spec/models/{null_decimal_spec.rb → statistics_rep_spec.rb} +8 -8
- data/spec/models/users_rep_spec.rb +46 -0
- metadata +26 -14
- data/docs/Decimal.md +0 -20
- data/docs/NullDecimal.md +0 -20
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 940dae79fc5ee1c85ea9ff8317f82f84bacff73e728d867fb7779749bd24018b
|
4
|
+
data.tar.gz: 32cbe26ac5217df5a1aba6ef7cce03455a72a2e5d79f0d178cdeee69900f4288
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: bd000adb61d2ebed2116539d4a57cf430d0f95abda1e245a1c8a49367131c1af3d13d6e7174f6733796ee8c886c3eda22b08fa76a333f5e2d64211d269ab298a
|
7
|
+
data.tar.gz: 01052ebeb3cbc96c749d9820c52c131d9d5d96a7378b5ba48005d558c55187b6fc904a1fa1b6e0c9237d837fb0b9acb941374c902874e86519585da79b3f90eb
|
data/README.md
CHANGED
@@ -458,7 +458,7 @@ If you would like to upgrade your integration to use a new API version, you can
|
|
458
458
|
This SDK is automatically generated by the [OpenAPI Generator](https://openapi-generator.tech) project:
|
459
459
|
|
460
460
|
- API version: 2.0
|
461
|
-
- Package version: 9.0.
|
461
|
+
- Package version: 9.0.1
|
462
462
|
- Build package: org.openapitools.codegen.languages.RubyClientCodegen
|
463
463
|
For more information, please visit [https://support.launchdarkly.com](https://support.launchdarkly.com)
|
464
464
|
|
@@ -475,16 +475,16 @@ gem build launchdarkly_api.gemspec
|
|
475
475
|
Then either install the gem locally:
|
476
476
|
|
477
477
|
```shell
|
478
|
-
gem install ./launchdarkly_api-9.0.
|
478
|
+
gem install ./launchdarkly_api-9.0.1.gem
|
479
479
|
```
|
480
480
|
|
481
|
-
(for development, run `gem install --dev ./launchdarkly_api-9.0.
|
481
|
+
(for development, run `gem install --dev ./launchdarkly_api-9.0.1.gem` to install the development dependencies)
|
482
482
|
|
483
483
|
or publish the gem to a gem hosting service, e.g. [RubyGems](https://rubygems.org/).
|
484
484
|
|
485
485
|
Finally add this to the Gemfile:
|
486
486
|
|
487
|
-
gem 'launchdarkly_api', '~> 9.0.
|
487
|
+
gem 'launchdarkly_api', '~> 9.0.1'
|
488
488
|
|
489
489
|
### Install from Git
|
490
490
|
|
@@ -544,7 +544,7 @@ Class | Method | HTTP request | Description
|
|
544
544
|
*LaunchDarklyApi::AccountMembersApi* | [**get_member**](docs/AccountMembersApi.md#get_member) | **GET** /api/v2/members/{id} | Get account member
|
545
545
|
*LaunchDarklyApi::AccountMembersApi* | [**get_members**](docs/AccountMembersApi.md#get_members) | **GET** /api/v2/members | List account members
|
546
546
|
*LaunchDarklyApi::AccountMembersApi* | [**patch_member**](docs/AccountMembersApi.md#patch_member) | **PATCH** /api/v2/members/{id} | Modify an account member
|
547
|
-
*LaunchDarklyApi::AccountMembersApi* | [**post_member_teams**](docs/AccountMembersApi.md#post_member_teams) | **POST** /api/v2/members/{id}/teams | Add member to teams
|
547
|
+
*LaunchDarklyApi::AccountMembersApi* | [**post_member_teams**](docs/AccountMembersApi.md#post_member_teams) | **POST** /api/v2/members/{id}/teams | Add a member to teams
|
548
548
|
*LaunchDarklyApi::AccountMembersApi* | [**post_members**](docs/AccountMembersApi.md#post_members) | **POST** /api/v2/members | Invite new members
|
549
549
|
*LaunchDarklyApi::AccountUsageBetaApi* | [**get_evaluations_usage**](docs/AccountUsageBetaApi.md#get_evaluations_usage) | **GET** /api/v2/usage/evaluations/{projectKey}/{environmentKey}/{featureFlagKey} | Get evaluations usage
|
550
550
|
*LaunchDarklyApi::AccountUsageBetaApi* | [**get_events_usage**](docs/AccountUsageBetaApi.md#get_events_usage) | **GET** /api/v2/usage/events/{type} | Get events usage
|
@@ -680,7 +680,7 @@ Class | Method | HTTP request | Description
|
|
680
680
|
*LaunchDarklyApi::TeamsBetaApi* | [**get_teams**](docs/TeamsBetaApi.md#get_teams) | **GET** /api/v2/teams | List teams
|
681
681
|
*LaunchDarklyApi::TeamsBetaApi* | [**patch_team**](docs/TeamsBetaApi.md#patch_team) | **PATCH** /api/v2/teams/{teamKey} | Update team
|
682
682
|
*LaunchDarklyApi::TeamsBetaApi* | [**post_team**](docs/TeamsBetaApi.md#post_team) | **POST** /api/v2/teams | Create team
|
683
|
-
*LaunchDarklyApi::TeamsBetaApi* | [**post_team_members**](docs/TeamsBetaApi.md#post_team_members) | **POST** /api/v2/teams/{teamKey}/members | Add members to team
|
683
|
+
*LaunchDarklyApi::TeamsBetaApi* | [**post_team_members**](docs/TeamsBetaApi.md#post_team_members) | **POST** /api/v2/teams/{teamKey}/members | Add multiple members to team
|
684
684
|
*LaunchDarklyApi::UserSettingsApi* | [**get_expiring_flags_for_user**](docs/UserSettingsApi.md#get_expiring_flags_for_user) | **GET** /api/v2/users/{projectKey}/{userKey}/expiring-user-targets/{environmentKey} | Get expiring dates on flags for user
|
685
685
|
*LaunchDarklyApi::UserSettingsApi* | [**get_user_flag_setting**](docs/UserSettingsApi.md#get_user_flag_setting) | **GET** /api/v2/users/{projectKey}/{environmentKey}/{userKey}/flags/{featureFlagKey} | Get flag setting for user
|
686
686
|
*LaunchDarklyApi::UserSettingsApi* | [**get_user_flag_settings**](docs/UserSettingsApi.md#get_user_flag_settings) | **GET** /api/v2/users/{projectKey}/{environmentKey}/{userKey}/flags | List flag settings for user
|
@@ -744,7 +744,6 @@ Class | Method | HTTP request | Description
|
|
744
744
|
- [LaunchDarklyApi::CustomWorkflowOutputRep](docs/CustomWorkflowOutputRep.md)
|
745
745
|
- [LaunchDarklyApi::CustomWorkflowStageMeta](docs/CustomWorkflowStageMeta.md)
|
746
746
|
- [LaunchDarklyApi::CustomWorkflowsListingOutputRep](docs/CustomWorkflowsListingOutputRep.md)
|
747
|
-
- [LaunchDarklyApi::Decimal](docs/Decimal.md)
|
748
747
|
- [LaunchDarklyApi::DefaultClientSideAvailabilityPost](docs/DefaultClientSideAvailabilityPost.md)
|
749
748
|
- [LaunchDarklyApi::Defaults](docs/Defaults.md)
|
750
749
|
- [LaunchDarklyApi::DependentFlag](docs/DependentFlag.md)
|
@@ -757,15 +756,16 @@ Class | Method | HTTP request | Description
|
|
757
756
|
- [LaunchDarklyApi::EnvironmentPost](docs/EnvironmentPost.md)
|
758
757
|
- [LaunchDarklyApi::EvaluationReason](docs/EvaluationReason.md)
|
759
758
|
- [LaunchDarklyApi::ExecutionOutputRep](docs/ExecutionOutputRep.md)
|
759
|
+
- [LaunchDarklyApi::Experiment](docs/Experiment.md)
|
760
760
|
- [LaunchDarklyApi::ExperimentAllocationRep](docs/ExperimentAllocationRep.md)
|
761
761
|
- [LaunchDarklyApi::ExperimentCollectionRep](docs/ExperimentCollectionRep.md)
|
762
762
|
- [LaunchDarklyApi::ExperimentEnabledPeriodRep](docs/ExperimentEnabledPeriodRep.md)
|
763
763
|
- [LaunchDarklyApi::ExperimentEnvironmentSettingRep](docs/ExperimentEnvironmentSettingRep.md)
|
764
|
+
- [LaunchDarklyApi::ExperimentExpandableProperties](docs/ExperimentExpandableProperties.md)
|
764
765
|
- [LaunchDarklyApi::ExperimentInfoRep](docs/ExperimentInfoRep.md)
|
765
766
|
- [LaunchDarklyApi::ExperimentMetadataRep](docs/ExperimentMetadataRep.md)
|
766
767
|
- [LaunchDarklyApi::ExperimentPatchInput](docs/ExperimentPatchInput.md)
|
767
768
|
- [LaunchDarklyApi::ExperimentPost](docs/ExperimentPost.md)
|
768
|
-
- [LaunchDarklyApi::ExperimentRep](docs/ExperimentRep.md)
|
769
769
|
- [LaunchDarklyApi::ExperimentResults](docs/ExperimentResults.md)
|
770
770
|
- [LaunchDarklyApi::ExperimentStatsRep](docs/ExperimentStatsRep.md)
|
771
771
|
- [LaunchDarklyApi::ExperimentTimeSeriesSlice](docs/ExperimentTimeSeriesSlice.md)
|
@@ -826,6 +826,7 @@ Class | Method | HTTP request | Description
|
|
826
826
|
- [LaunchDarklyApi::IterationInput](docs/IterationInput.md)
|
827
827
|
- [LaunchDarklyApi::IterationRep](docs/IterationRep.md)
|
828
828
|
- [LaunchDarklyApi::LastSeenMetadata](docs/LastSeenMetadata.md)
|
829
|
+
- [LaunchDarklyApi::LegacyExperimentRep](docs/LegacyExperimentRep.md)
|
829
830
|
- [LaunchDarklyApi::Link](docs/Link.md)
|
830
831
|
- [LaunchDarklyApi::Member](docs/Member.md)
|
831
832
|
- [LaunchDarklyApi::MemberDataRep](docs/MemberDataRep.md)
|
@@ -842,12 +843,12 @@ Class | Method | HTTP request | Description
|
|
842
843
|
- [LaunchDarklyApi::MetricPost](docs/MetricPost.md)
|
843
844
|
- [LaunchDarklyApi::MetricRep](docs/MetricRep.md)
|
844
845
|
- [LaunchDarklyApi::MetricSeen](docs/MetricSeen.md)
|
846
|
+
- [LaunchDarklyApi::MetricV2Rep](docs/MetricV2Rep.md)
|
845
847
|
- [LaunchDarklyApi::Modification](docs/Modification.md)
|
846
848
|
- [LaunchDarklyApi::MultiEnvironmentDependentFlag](docs/MultiEnvironmentDependentFlag.md)
|
847
849
|
- [LaunchDarklyApi::MultiEnvironmentDependentFlags](docs/MultiEnvironmentDependentFlags.md)
|
848
850
|
- [LaunchDarklyApi::NewMemberForm](docs/NewMemberForm.md)
|
849
851
|
- [LaunchDarklyApi::NotFoundErrorRep](docs/NotFoundErrorRep.md)
|
850
|
-
- [LaunchDarklyApi::NullDecimal](docs/NullDecimal.md)
|
851
852
|
- [LaunchDarklyApi::ParameterRep](docs/ParameterRep.md)
|
852
853
|
- [LaunchDarklyApi::ParentResourceRep](docs/ParentResourceRep.md)
|
853
854
|
- [LaunchDarklyApi::PatchFailedErrorRep](docs/PatchFailedErrorRep.md)
|
@@ -907,6 +908,7 @@ Class | Method | HTTP request | Description
|
|
907
908
|
- [LaunchDarklyApi::StatementRep](docs/StatementRep.md)
|
908
909
|
- [LaunchDarklyApi::StatisticCollectionRep](docs/StatisticCollectionRep.md)
|
909
910
|
- [LaunchDarklyApi::StatisticRep](docs/StatisticRep.md)
|
911
|
+
- [LaunchDarklyApi::StatisticsRep](docs/StatisticsRep.md)
|
910
912
|
- [LaunchDarklyApi::StatisticsRoot](docs/StatisticsRoot.md)
|
911
913
|
- [LaunchDarklyApi::StatusConflictErrorRep](docs/StatusConflictErrorRep.md)
|
912
914
|
- [LaunchDarklyApi::SubjectDataRep](docs/SubjectDataRep.md)
|
@@ -946,6 +948,7 @@ Class | Method | HTTP request | Description
|
|
946
948
|
- [LaunchDarklyApi::UserSegmentRule](docs/UserSegmentRule.md)
|
947
949
|
- [LaunchDarklyApi::UserSegments](docs/UserSegments.md)
|
948
950
|
- [LaunchDarklyApi::Users](docs/Users.md)
|
951
|
+
- [LaunchDarklyApi::UsersRep](docs/UsersRep.md)
|
949
952
|
- [LaunchDarklyApi::ValuePut](docs/ValuePut.md)
|
950
953
|
- [LaunchDarklyApi::Variation](docs/Variation.md)
|
951
954
|
- [LaunchDarklyApi::VariationOrRolloutRep](docs/VariationOrRolloutRep.md)
|
data/docs/AccountMembersApi.md
CHANGED
@@ -8,7 +8,7 @@ All URIs are relative to *https://app.launchdarkly.com*
|
|
8
8
|
| [**get_member**](AccountMembersApi.md#get_member) | **GET** /api/v2/members/{id} | Get account member |
|
9
9
|
| [**get_members**](AccountMembersApi.md#get_members) | **GET** /api/v2/members | List account members |
|
10
10
|
| [**patch_member**](AccountMembersApi.md#patch_member) | **PATCH** /api/v2/members/{id} | Modify an account member |
|
11
|
-
| [**post_member_teams**](AccountMembersApi.md#post_member_teams) | **POST** /api/v2/members/{id}/teams | Add member to teams |
|
11
|
+
| [**post_member_teams**](AccountMembersApi.md#post_member_teams) | **POST** /api/v2/members/{id}/teams | Add a member to teams |
|
12
12
|
| [**post_members**](AccountMembersApi.md#post_members) | **POST** /api/v2/members | Invite new members |
|
13
13
|
|
14
14
|
|
@@ -88,7 +88,7 @@ nil (empty response body)
|
|
88
88
|
|
89
89
|
Get account member
|
90
90
|
|
91
|
-
Get a single account member by ID
|
91
|
+
Get a single account member by ID. `me` is a reserved value for the `id` parameter and returns the caller's member information.
|
92
92
|
|
93
93
|
### Examples
|
94
94
|
|
@@ -309,9 +309,9 @@ end
|
|
309
309
|
|
310
310
|
> <Member> post_member_teams(id, member_teams_post_input)
|
311
311
|
|
312
|
-
Add member to teams
|
312
|
+
Add a member to teams
|
313
313
|
|
314
|
-
Add member to
|
314
|
+
Add one member to one or more teams.
|
315
315
|
|
316
316
|
### Examples
|
317
317
|
|
@@ -331,7 +331,7 @@ id = 'id_example' # String | The member ID
|
|
331
331
|
member_teams_post_input = LaunchDarklyApi::MemberTeamsPostInput.new({team_keys: ['team_keys_example']}) # MemberTeamsPostInput |
|
332
332
|
|
333
333
|
begin
|
334
|
-
# Add member to teams
|
334
|
+
# Add a member to teams
|
335
335
|
result = api_instance.post_member_teams(id, member_teams_post_input)
|
336
336
|
p result
|
337
337
|
rescue LaunchDarklyApi::ApiError => e
|
@@ -347,7 +347,7 @@ This returns an Array which contains the response data, status code and headers.
|
|
347
347
|
|
348
348
|
```ruby
|
349
349
|
begin
|
350
|
-
# Add member to teams
|
350
|
+
# Add a member to teams
|
351
351
|
data, status_code, headers = api_instance.post_member_teams_with_http_info(id, member_teams_post_input)
|
352
352
|
p status_code # => 2xx
|
353
353
|
p headers # => { ... }
|
data/docs/EnvironmentsApi.md
CHANGED
@@ -163,7 +163,7 @@ end
|
|
163
163
|
|
164
164
|
Update environment
|
165
165
|
|
166
|
-
Update an environment. Requires a [JSON Patch](https://datatracker.ietf.org/doc/html/rfc6902) representation of the desired changes to the environment. To update fields in the environment object that are arrays, set the `path` to the name of the field and then append `/<array index>`. Using `/0` appends to the beginning of the array. ### Approval settings This request only returns the `approvalSettings` key if the [Flag Approvals](https://docs.launchdarkly.com/home/feature-workflows/approvals) feature is enabled. Only the `canReviewOwnRequest`, `canApplyDeclinedChanges`, `minNumApprovals`, `required` and `requiredApprovalTagsfields` are editable. If you try to patch the environment by setting both `required` and `requiredApprovalTags`, the request fails and an error appears. You can specify either required approvals for all flags in an environment or those with specific tags, but not both.
|
166
|
+
Update an environment. Requires a [JSON Patch](https://datatracker.ietf.org/doc/html/rfc6902) representation of the desired changes to the environment. To update fields in the environment object that are arrays, set the `path` to the name of the field and then append `/<array index>`. Using `/0` appends to the beginning of the array. ### Approval settings This request only returns the `approvalSettings` key if the [Flag Approvals](https://docs.launchdarkly.com/home/feature-workflows/approvals) feature is enabled. Only the `canReviewOwnRequest`, `canApplyDeclinedChanges`, `minNumApprovals`, `required` and `requiredApprovalTagsfields` are editable. If you try to patch the environment by setting both `required` and `requiredApprovalTags`, the request fails and an error appears. You can specify either required approvals for all flags in an environment or those with specific tags, but not both.
|
167
167
|
|
168
168
|
### Examples
|
169
169
|
|
data/docs/Experiment.md
ADDED
@@ -0,0 +1,36 @@
|
|
1
|
+
# LaunchDarklyApi::Experiment
|
2
|
+
|
3
|
+
## Properties
|
4
|
+
|
5
|
+
| Name | Type | Description | Notes |
|
6
|
+
| ---- | ---- | ----------- | ----- |
|
7
|
+
| **_id** | **String** | | [optional] |
|
8
|
+
| **key** | **String** | | |
|
9
|
+
| **name** | **String** | | |
|
10
|
+
| **description** | **String** | | [optional] |
|
11
|
+
| **_maintainer_id** | **String** | | |
|
12
|
+
| **_creation_date** | **Integer** | | |
|
13
|
+
| **_links** | [**Hash<String, Link>**](Link.md) | | |
|
14
|
+
| **current_iteration** | [**IterationRep**](IterationRep.md) | | [optional] |
|
15
|
+
| **draft_iteration** | [**IterationRep**](IterationRep.md) | | [optional] |
|
16
|
+
| **previous_iterations** | [**Array<IterationRep>**](IterationRep.md) | | [optional] |
|
17
|
+
|
18
|
+
## Example
|
19
|
+
|
20
|
+
```ruby
|
21
|
+
require 'launchdarkly_api'
|
22
|
+
|
23
|
+
instance = LaunchDarklyApi::Experiment.new(
|
24
|
+
_id: null,
|
25
|
+
key: null,
|
26
|
+
name: null,
|
27
|
+
description: null,
|
28
|
+
_maintainer_id: null,
|
29
|
+
_creation_date: null,
|
30
|
+
_links: {"parent":{"href":"/api/v2/projects/my-project/environments/my-environment","type":"application/json"},"self":{"href":"/api/v2/projects/my-project/environments/my-environment/experiments/my-experiment","type":"application/json"}},
|
31
|
+
current_iteration: null,
|
32
|
+
draft_iteration: null,
|
33
|
+
previous_iterations: null
|
34
|
+
)
|
35
|
+
```
|
36
|
+
|
@@ -4,7 +4,7 @@
|
|
4
4
|
|
5
5
|
| Name | Type | Description | Notes |
|
6
6
|
| ---- | ---- | ----------- | ----- |
|
7
|
-
| **items** | [**Array<
|
7
|
+
| **items** | [**Array<Experiment>**](Experiment.md) | | [optional] |
|
8
8
|
| **total_count** | **Integer** | | [optional] |
|
9
9
|
| **_links** | [**Hash<String, Link>**](Link.md) | | [optional] |
|
10
10
|
|
@@ -0,0 +1,20 @@
|
|
1
|
+
# LaunchDarklyApi::ExperimentExpandableProperties
|
2
|
+
|
3
|
+
## Properties
|
4
|
+
|
5
|
+
| Name | Type | Description | Notes |
|
6
|
+
| ---- | ---- | ----------- | ----- |
|
7
|
+
| **draft_iteration** | [**IterationRep**](IterationRep.md) | | [optional] |
|
8
|
+
| **previous_iterations** | [**Array<IterationRep>**](IterationRep.md) | | [optional] |
|
9
|
+
|
10
|
+
## Example
|
11
|
+
|
12
|
+
```ruby
|
13
|
+
require 'launchdarkly_api'
|
14
|
+
|
15
|
+
instance = LaunchDarklyApi::ExperimentExpandableProperties.new(
|
16
|
+
draft_iteration: null,
|
17
|
+
previous_iterations: null
|
18
|
+
)
|
19
|
+
```
|
20
|
+
|
data/docs/ExperimentInfoRep.md
CHANGED
@@ -5,7 +5,7 @@
|
|
5
5
|
| Name | Type | Description | Notes |
|
6
6
|
| ---- | ---- | ----------- | ----- |
|
7
7
|
| **baseline_idx** | **Integer** | | |
|
8
|
-
| **items** | [**Array<
|
8
|
+
| **items** | [**Array<LegacyExperimentRep>**](LegacyExperimentRep.md) | | |
|
9
9
|
|
10
10
|
## Example
|
11
11
|
|
data/docs/ExperimentsBetaApi.md
CHANGED
@@ -16,7 +16,7 @@ All URIs are relative to *https://app.launchdarkly.com*
|
|
16
16
|
|
17
17
|
## create_experiment
|
18
18
|
|
19
|
-
> <
|
19
|
+
> <Experiment> create_experiment(project_key, environment_key, experiment_post)
|
20
20
|
|
21
21
|
Create experiment
|
22
22
|
|
@@ -53,7 +53,7 @@ end
|
|
53
53
|
|
54
54
|
This returns an Array which contains the response data, status code and headers.
|
55
55
|
|
56
|
-
> <Array(<
|
56
|
+
> <Array(<Experiment>, Integer, Hash)> create_experiment_with_http_info(project_key, environment_key, experiment_post)
|
57
57
|
|
58
58
|
```ruby
|
59
59
|
begin
|
@@ -61,7 +61,7 @@ begin
|
|
61
61
|
data, status_code, headers = api_instance.create_experiment_with_http_info(project_key, environment_key, experiment_post)
|
62
62
|
p status_code # => 2xx
|
63
63
|
p headers # => { ... }
|
64
|
-
p data # => <
|
64
|
+
p data # => <Experiment>
|
65
65
|
rescue LaunchDarklyApi::ApiError => e
|
66
66
|
puts "Error when calling ExperimentsBetaApi->create_experiment_with_http_info: #{e}"
|
67
67
|
end
|
@@ -77,7 +77,7 @@ end
|
|
77
77
|
|
78
78
|
### Return type
|
79
79
|
|
80
|
-
[**
|
80
|
+
[**Experiment**](Experiment.md)
|
81
81
|
|
82
82
|
### Authorization
|
83
83
|
|
@@ -168,7 +168,7 @@ end
|
|
168
168
|
|
169
169
|
## get_experiment
|
170
170
|
|
171
|
-
> <
|
171
|
+
> <Experiment> get_experiment(project_key, environment_key, experiment_key)
|
172
172
|
|
173
173
|
Get experiment
|
174
174
|
|
@@ -205,7 +205,7 @@ end
|
|
205
205
|
|
206
206
|
This returns an Array which contains the response data, status code and headers.
|
207
207
|
|
208
|
-
> <Array(<
|
208
|
+
> <Array(<Experiment>, Integer, Hash)> get_experiment_with_http_info(project_key, environment_key, experiment_key)
|
209
209
|
|
210
210
|
```ruby
|
211
211
|
begin
|
@@ -213,7 +213,7 @@ begin
|
|
213
213
|
data, status_code, headers = api_instance.get_experiment_with_http_info(project_key, environment_key, experiment_key)
|
214
214
|
p status_code # => 2xx
|
215
215
|
p headers # => { ... }
|
216
|
-
p data # => <
|
216
|
+
p data # => <Experiment>
|
217
217
|
rescue LaunchDarklyApi::ApiError => e
|
218
218
|
puts "Error when calling ExperimentsBetaApi->get_experiment_with_http_info: #{e}"
|
219
219
|
end
|
@@ -229,7 +229,7 @@ end
|
|
229
229
|
|
230
230
|
### Return type
|
231
231
|
|
232
|
-
[**
|
232
|
+
[**Experiment**](Experiment.md)
|
233
233
|
|
234
234
|
### Authorization
|
235
235
|
|
@@ -476,7 +476,7 @@ end
|
|
476
476
|
|
477
477
|
## patch_experiment
|
478
478
|
|
479
|
-
> <
|
479
|
+
> <Experiment> patch_experiment(project_key, environment_key, experiment_key, experiment_patch_input)
|
480
480
|
|
481
481
|
Patch experiment
|
482
482
|
|
@@ -514,7 +514,7 @@ end
|
|
514
514
|
|
515
515
|
This returns an Array which contains the response data, status code and headers.
|
516
516
|
|
517
|
-
> <Array(<
|
517
|
+
> <Array(<Experiment>, Integer, Hash)> patch_experiment_with_http_info(project_key, environment_key, experiment_key, experiment_patch_input)
|
518
518
|
|
519
519
|
```ruby
|
520
520
|
begin
|
@@ -522,7 +522,7 @@ begin
|
|
522
522
|
data, status_code, headers = api_instance.patch_experiment_with_http_info(project_key, environment_key, experiment_key, experiment_patch_input)
|
523
523
|
p status_code # => 2xx
|
524
524
|
p headers # => { ... }
|
525
|
-
p data # => <
|
525
|
+
p data # => <Experiment>
|
526
526
|
rescue LaunchDarklyApi::ApiError => e
|
527
527
|
puts "Error when calling ExperimentsBetaApi->patch_experiment_with_http_info: #{e}"
|
528
528
|
end
|
@@ -539,7 +539,7 @@ end
|
|
539
539
|
|
540
540
|
### Return type
|
541
541
|
|
542
|
-
[**
|
542
|
+
[**Experiment**](Experiment.md)
|
543
543
|
|
544
544
|
### Authorization
|
545
545
|
|
data/docs/FeatureFlagsApi.md
CHANGED
@@ -715,7 +715,7 @@ end
|
|
715
715
|
|
716
716
|
Update feature flag
|
717
717
|
|
718
|
-
Perform a partial update to a feature flag. ## Using semantic patches on a feature flag To use a [semantic patch](/reference#updates-via-semantic-patches) on a feature flag resource, you must include a header in the request. If you call a semantic patch resource without this header, you will receive a `400` response because your semantic patch will be interpreted as a JSON patch. Use this header: ``` Content-Type: application/json; domain-model=launchdarkly.semanticpatch ``` The body of a semantic patch request takes the following three properties: 1. `comment` (string): (Optional) A description of the update. 1. `environmentKey` (string): (Required) The key of the LaunchDarkly environment. 1. `instructions` (array): (Required) The list of actions to be performed by the update. Each action in the list must be an object/hash table with a `kind` property that indicates the instruction. Depending on the `kind`, the API may require other parameters. When this is the case, add the parameters as additional fields to the instruction object. Read below for more information on the specific supported semantic patch instructions. If any instruction in the patch encounters an error, the error will be returned and the flag will not be changed. In general, instructions will silently do nothing if the flag is already in the state requested by the patch instruction. For example, `removeUserTargets` does nothing when the targets have already been removed. They will generally error if a parameter refers to something that does not exist, like a variation ID that doesn't correspond to a variation on the flag or a rule ID that doesn't belong to a rule on the flag. Other specific error conditions are noted in the instruction descriptions. ### Instructions #### `turnFlagOn` Sets the flag's targeting state to on. For example, to flip a flag on, use this request body: ```json { \"environmentKey\": \"example-environment-key\", \"instructions\": [ { \"kind\": \"turnFlagOn\" } ] } ``` #### `turnFlagOff` Sets the flag's targeting state to off. For example, to flip a flag off, use this request body: ```json { \"environmentKey\": \"example-environment-key\", \"instructions\": [ { \"kind\": \"turnFlagOff\" } ] } ``` #### `addUserTargets` Adds the user keys in `values` to the individual user targets for the variation specified by `variationId`. Returns an error if this causes the same user key to be targeted in multiple variations. ##### Parameters - `values`: list of user keys - `variationId`: ID of a variation on the flag #### `removeUserTargets` Removes the user keys in `values` to the individual user targets for the variation specified by `variationId`. Does nothing if the user keys are not targeted. ##### Parameters - `values`: list of user keys - `variationId`: ID of a variation on the flag #### `replaceUserTargets` Completely replaces the existing set of user targeting. All variations must be provided. Example: ```json { \"kind\": \"replaceUserTargets\", \"targets\": [ { \"variationId\": \"variation-1\", \"values\": [\"blah\", \"foo\", \"bar\"] }, { \"variationId\": \"variation-2\", \"values\": [\"abc\", \"def\"] } ] } ``` ##### Parameters - `targets`: a list of user targeting #### `clearUserTargets` Removes all individual user targets from the variation specified by `variationId` ##### Parameters - `variationId`: ID of a variation on the flag #### `addPrerequisite` Adds the flag indicated by `key` with variation `variationId` as a prerequisite to the flag. ##### Parameters - `key`: flag key of another flag - `variationId`: ID of a variation of the flag with key `key` #### `removePrerequisite` Removes the prerequisite indicated by `key`. Does nothing if this prerequisite does not exist. ##### Parameters - `key`: flag key of an existing prerequisite #### `updatePrerequisite` Changes the prerequisite with flag key `key` to the variation indicated by `variationId`. Returns an error if this prerequisite does not exist. ##### Parameters - `key`: flag key of an existing prerequisite - `variationId`: ID of a variation of the flag with key `key` #### `replacePrerequisites` Completely replaces the existing set of prerequisites for a given flag. Example: ```json { \"kind\": \"replacePrerequisites\", \"prerequisites\": [ { \"key\": \"flag-key\", \"variationId\": \"variation-1\" }, { \"key\": \"another-flag\", \"variationId\": \"variation-2\" } ] } ``` ##### Parameters - `prerequisites`: a list of prerequisites #### `addRule` Adds a new rule to the flag with the given `clauses` which serves the variation indicated by `variationId` or the percent rollout indicated by `rolloutWeights` and `rolloutBucketBy`. If `beforeRuleId` is set, the rule will be added in the list of rules before the indicated rule. Otherwise, the rule will be added to the end of the list. ##### Parameters - `clauses`: Array of clauses (see `addClauses`) - `beforeRuleId`: Optional ID of a rule in the flag - `variationId`: ID of a variation of the flag - `rolloutWeights`: Map of variationId to weight in thousandths of a percent (0-100000) - `rolloutBucketBy`: Optional user attribute #### `removeRule` Removes the targeting rule specified by `ruleId`. Does nothing if the rule does not exist. ##### Parameters - `ruleId`: ID of a rule in the flag #### `replaceRules` Completely replaces the existing rules for a given flag. Example: ```json { \"kind\": \"replaceRules\", \"rules\": [ { \"variationId\": \"variation-1\", \"description\": \"myRule\", \"clauses\": [ { \"attribute\": \"segmentMatch\", \"op\": \"segmentMatch\", \"values\": [\"test\"] } ], \"trackEvents\": true } ] } ``` ##### Parameters - `rules`: a list of rules #### `addClauses` Adds the given clauses to the rule indicated by `ruleId`. ##### Parameters - `ruleId`: ID of a rule in the flag - `clauses`: Array of clause objects, with `attribute` (string), `op` (string), and `values` (array of strings, numbers, or dates) properties. #### `removeClauses` Removes the clauses specified by `clauseIds` from the rule indicated by `ruleId`. #### Parameters - `ruleId`: ID of a rule in the flag - `clauseIds`: Array of IDs of clauses in the rule #### `updateClause` Replaces the clause indicated by `ruleId` and `clauseId` with `clause`. ##### Parameters - `ruleId`: ID of a rule in the flag - `clauseId`: ID of a clause in that rule - `clause`: Clause object #### `addValuesToClause` Adds `values` to the values of the clause indicated by `ruleId` and `clauseId`. ##### Parameters - `ruleId`: ID of a rule in the flag - `clauseId`: ID of a clause in that rule - `values`: Array of strings #### `removeValuesFromClause` Removes `values` from the values of the clause indicated by `ruleId` and `clauseId`. ##### Parameters `ruleId`: ID of a rule in the flag `clauseId`: ID of a clause in that rule `values`: Array of strings #### `reorderRules` Rearranges the rules to match the order given in `ruleIds`. Will return an error if `ruleIds` does not match the current set of rules on the flag. ##### Parameters - `ruleIds`: Array of IDs of all rules in the flag #### `updateRuleVariationOrRollout` Updates what the rule indicated by `ruleId` serves if its clauses evaluate to true. Can either be a fixed variation indicated by `variationId` or a percent rollout indicated by `rolloutWeights` and `rolloutBucketBy`. ##### Parameters - `ruleId`: ID of a rule in the flag - `variationId`: ID of a variation of the flag or - `rolloutWeights`: Map of variationId to weight in thousandths of a percent (0-100000) - `rolloutBucketBy`: Optional user attribute #### `updateFallthroughVariationOrRollout` Updates the flag's fallthrough, which is served if none of the targeting rules match. Can either be a fixed variation indicated by `variationId` or a percent rollout indicated by `rolloutWeights` and `rolloutBucketBy`. ##### Parameters `variationId`: ID of a variation of the flag or `rolloutWeights`: Map of variationId to weight in thousandths of a percent (0-100000) `rolloutBucketBy`: Optional user attribute #### `updateOffVariation` Updates the variation served when the flag's targeting is off to the variation indicated by `variationId`. ##### Parameters `variationId`: ID of a variation of the flag ### Example ```json { \"environmentKey\": \"production\", \"instructions\": [ { \"kind\": \"turnFlagOn\" }, { \"kind\": \"turnFlagOff\" }, { \"kind\": \"addUserTargets\", \"variationId\": \"8bfb304e-d516-47e5-8727-e7f798e8992d\", \"values\": [\"userId\", \"userId2\"] }, { \"kind\": \"removeUserTargets\", \"variationId\": \"8bfb304e-d516-47e5-8727-e7f798e8992d\", \"values\": [\"userId3\", \"userId4\"] }, { \"kind\": \"updateFallthroughVariationOrRollout\", \"rolloutWeights\": { \"variationId\": 50000, \"variationId2\": 50000 }, \"rolloutBucketBy\": null }, { \"kind\": \"addRule\", \"clauses\": [ { \"attribute\": \"segmentMatch\", \"negate\": false, \"values\": [\"test-segment\"] } ], \"variationId\": null, \"rolloutWeights\": { \"variationId\": 50000, \"variationId2\": 50000 }, \"rolloutBucketBy\": \"key\" }, { \"kind\": \"removeRule\", \"ruleId\": \"99f12464-a429-40fc-86cc-b27612188955\" }, { \"kind\": \"reorderRules\", \"ruleIds\": [\"2f72974e-de68-4243-8dd3-739582147a1f\", \"8bfb304e-d516-47e5-8727-e7f798e8992d\"] }, { \"kind\": \"addClauses\", \"ruleId\": \"1134\", \"clauses\": [ { \"attribute\": \"email\", \"op\": \"in\", \"negate\": false, \"values\": [\"test@test.com\"] } ] }, { \"kind\": \"removeClauses\", \"ruleId\": \"1242529\", \"clauseIds\": [\"8bfb304e-d516-47e5-8727-e7f798e8992d\"] }, { \"kind\": \"updateClause\", \"ruleId\": \"2f72974e-de68-4243-8dd3-739582147a1f\", \"clauseId\": \"309845\", \"clause\": { \"attribute\": \"segmentMatch\", \"negate\": false, \"values\": [\"test-segment\"] } }, { \"kind\": \"updateRuleVariationOrRollout\", \"ruleId\": \"2342\", \"rolloutWeights\": null, \"rolloutBucketBy\": null }, { \"kind\": \"updateOffVariation\", \"variationId\": \"3242453\" }, { \"kind\": \"addPrerequisite\", \"variationId\": \"234235\", \"key\": \"flagKey2\" }, { \"kind\": \"updatePrerequisite\", \"variationId\": \"234235\", \"key\": \"flagKey2\" }, { \"kind\": \"removePrerequisite\", \"key\": \"flagKey\" } ] } ``` ## Using JSON Patches on a feature flag If you do not include the header described above, you can use [JSON patch](/reference#updates-via-json-patch). When using the update feature flag endpoint to add individual users to a specific variation, there are two different patch documents, depending on whether users are already being individually targeted for the variation. If a flag variation already has users individually targeted, the path for the JSON Patch operation is: ```json { \"op\": \"add\", \"path\": \"/environments/devint/targets/0/values/-\", \"value\": \"TestClient10\" } ``` If a flag variation does not already have users individually targeted, the path for the JSON Patch operation is: ```json [ { \"op\": \"add\", \"path\": \"/environments/devint/targets/-\", \"value\": { \"variation\": 0, \"values\": [\"TestClient10\"] } } ] ``` ## Required approvals If a request attempts to alter a flag configuration in an environment where approvals are required for the flag, the request will fail with a 405. Changes to the flag configuration in that environment will required creating an [approval request](/tag/Approvals) or a [workflow](/tag/Workflows-(beta)). This behavior can be bypassed by users and access tokens that have a [custom role](https://docs.launchdarkly.com/home/members/custom-roles) with permission to perform the `bypassRequiredApproval` action on the flag. ## Conflicts If a flag configuration change made through this endpoint would cause a pending scheduled change or approval request to fail, this endpoint will return a 400. You can ignore this check by adding an `ignoreConflicts` query parameter set to `true`.
|
718
|
+
Perform a partial update to a feature flag. ## Using semantic patches on a feature flag To use a [semantic patch](/reference#updates-via-semantic-patches) on a feature flag resource, you must include a header in the request. If you call a semantic patch resource without this header, you will receive a `400` response because your semantic patch will be interpreted as a JSON patch. Use this header: ``` Content-Type: application/json; domain-model=launchdarkly.semanticpatch ``` The body of a semantic patch request takes the following three properties: 1. `comment` (string): (Optional) A description of the update. 1. `environmentKey` (string): (Required) The key of the LaunchDarkly environment. 1. `instructions` (array): (Required) The list of actions to be performed by the update. Each action in the list must be an object/hash table with a `kind` property that indicates the instruction. Depending on the `kind`, the API may require other parameters. When this is the case, add the parameters as additional fields to the instruction object. Read below for more information on the specific supported semantic patch instructions. If any instruction in the patch encounters an error, the error will be returned and the flag will not be changed. In general, instructions will silently do nothing if the flag is already in the state requested by the patch instruction. For example, `removeUserTargets` does nothing when the targets have already been removed. They will generally error if a parameter refers to something that does not exist, like a variation ID that doesn't correspond to a variation on the flag or a rule ID that doesn't belong to a rule on the flag. Other specific error conditions are noted in the instruction descriptions. ### Instructions #### `turnFlagOn` Sets the flag's targeting state to on. For example, to flip a flag on, use this request body: ```json { \"environmentKey\": \"example-environment-key\", \"instructions\": [ { \"kind\": \"turnFlagOn\" } ] } ``` #### `turnFlagOff` Sets the flag's targeting state to off. For example, to flip a flag off, use this request body: ```json { \"environmentKey\": \"example-environment-key\", \"instructions\": [ { \"kind\": \"turnFlagOff\" } ] } ``` #### `addUserTargets` Adds the user keys in `values` to the individual user targets for the variation specified by `variationId`. Returns an error if this causes the same user key to be targeted in multiple variations. ##### Parameters - `values`: list of user keys - `variationId`: ID of a variation on the flag #### `removeUserTargets` Removes the user keys in `values` to the individual user targets for the variation specified by `variationId`. Does nothing if the user keys are not targeted. ##### Parameters - `values`: list of user keys - `variationId`: ID of a variation on the flag #### `replaceUserTargets` Completely replaces the existing set of user targeting. All variations must be provided. Example: ```json { \"kind\": \"replaceUserTargets\", \"targets\": [ { \"variationId\": \"variation-1\", \"values\": [\"blah\", \"foo\", \"bar\"] }, { \"variationId\": \"variation-2\", \"values\": [\"abc\", \"def\"] } ] } ``` ##### Parameters - `targets`: a list of user targeting #### `clearUserTargets` Removes all individual user targets from the variation specified by `variationId` ##### Parameters - `variationId`: ID of a variation on the flag #### `addPrerequisite` Adds the flag indicated by `key` with variation `variationId` as a prerequisite to the flag. ##### Parameters - `key`: flag key of another flag - `variationId`: ID of a variation of the flag with key `key` #### `removePrerequisite` Removes the prerequisite indicated by `key`. Does nothing if this prerequisite does not exist. ##### Parameters - `key`: flag key of an existing prerequisite #### `updatePrerequisite` Changes the prerequisite with flag key `key` to the variation indicated by `variationId`. Returns an error if this prerequisite does not exist. ##### Parameters - `key`: flag key of an existing prerequisite - `variationId`: ID of a variation of the flag with key `key` #### `replacePrerequisites` Completely replaces the existing set of prerequisites for a given flag. Example: ```json { \"kind\": \"replacePrerequisites\", \"prerequisites\": [ { \"key\": \"flag-key\", \"variationId\": \"variation-1\" }, { \"key\": \"another-flag\", \"variationId\": \"variation-2\" } ] } ``` ##### Parameters - `prerequisites`: a list of prerequisites #### `addRule` Adds a new rule to the flag with the given `clauses` which serves the variation indicated by `variationId` or the percent rollout indicated by `rolloutWeights` and `rolloutBucketBy`. If `beforeRuleId` is set, the rule will be added in the list of rules before the indicated rule. Otherwise, the rule will be added to the end of the list. ##### Parameters - `clauses`: Array of clauses (see `addClauses`) - `beforeRuleId`: Optional ID of a rule in the flag - `variationId`: ID of a variation of the flag - `rolloutWeights`: Map of variationId to weight in thousandths of a percent (0-100000) - `rolloutBucketBy`: Optional user attribute #### `removeRule` Removes the targeting rule specified by `ruleId`. Does nothing if the rule does not exist. ##### Parameters - `ruleId`: ID of a rule in the flag #### `replaceRules` Completely replaces the existing rules for a given flag. Example: ```json { \"kind\": \"replaceRules\", \"rules\": [ { \"variationId\": \"variation-1\", \"description\": \"myRule\", \"clauses\": [ { \"attribute\": \"segmentMatch\", \"op\": \"segmentMatch\", \"values\": [\"test\"] } ], \"trackEvents\": true } ] } ``` ##### Parameters - `rules`: a list of rules #### `addClauses` Adds the given clauses to the rule indicated by `ruleId`. ##### Parameters - `ruleId`: ID of a rule in the flag - `clauses`: Array of clause objects, with `attribute` (string), `op` (string), and `values` (array of strings, numbers, or dates) properties. #### `removeClauses` Removes the clauses specified by `clauseIds` from the rule indicated by `ruleId`. #### Parameters - `ruleId`: ID of a rule in the flag - `clauseIds`: Array of IDs of clauses in the rule #### `updateClause` Replaces the clause indicated by `ruleId` and `clauseId` with `clause`. ##### Parameters - `ruleId`: ID of a rule in the flag - `clauseId`: ID of a clause in that rule - `clause`: Clause object #### `addValuesToClause` Adds `values` to the values of the clause indicated by `ruleId` and `clauseId`. ##### Parameters - `ruleId`: ID of a rule in the flag - `clauseId`: ID of a clause in that rule - `values`: Array of strings #### `removeValuesFromClause` Removes `values` from the values of the clause indicated by `ruleId` and `clauseId`. ##### Parameters `ruleId`: ID of a rule in the flag `clauseId`: ID of a clause in that rule `values`: Array of strings #### `reorderRules` Rearranges the rules to match the order given in `ruleIds`. Will return an error if `ruleIds` does not match the current set of rules on the flag. ##### Parameters - `ruleIds`: Array of IDs of all rules in the flag #### `updateRuleVariationOrRollout` Updates what the rule indicated by `ruleId` serves if its clauses evaluate to true. Can either be a fixed variation indicated by `variationId` or a percent rollout indicated by `rolloutWeights` and `rolloutBucketBy`. ##### Parameters - `ruleId`: ID of a rule in the flag - `variationId`: ID of a variation of the flag or - `rolloutWeights`: Map of variationId to weight in thousandths of a percent (0-100000) - `rolloutBucketBy`: Optional user attribute #### `updateFallthroughVariationOrRollout` Updates the flag's fallthrough, which is served if none of the targeting rules match. Can either be a fixed variation indicated by `variationId` or a percent rollout indicated by `rolloutWeights` and `rolloutBucketBy`. ##### Parameters `variationId`: ID of a variation of the flag or `rolloutWeights`: Map of variationId to weight in thousandths of a percent (0-100000) `rolloutBucketBy`: Optional user attribute #### `updateOffVariation` Updates the variation served when the flag's targeting is off to the variation indicated by `variationId`. ##### Parameters `variationId`: ID of a variation of the flag ### Example ```json { \"environmentKey\": \"production\", \"instructions\": [ { \"kind\": \"turnFlagOn\" }, { \"kind\": \"turnFlagOff\" }, { \"kind\": \"addUserTargets\", \"variationId\": \"8bfb304e-d516-47e5-8727-e7f798e8992d\", \"values\": [\"userId\", \"userId2\"] }, { \"kind\": \"removeUserTargets\", \"variationId\": \"8bfb304e-d516-47e5-8727-e7f798e8992d\", \"values\": [\"userId3\", \"userId4\"] }, { \"kind\": \"updateFallthroughVariationOrRollout\", \"rolloutWeights\": { \"variationId\": 50000, \"variationId2\": 50000 }, \"rolloutBucketBy\": null }, { \"kind\": \"addRule\", \"clauses\": [ { \"attribute\": \"segmentMatch\", \"negate\": false, \"values\": [\"test-segment\"] } ], \"variationId\": null, \"rolloutWeights\": { \"variationId\": 50000, \"variationId2\": 50000 }, \"rolloutBucketBy\": \"key\" }, { \"kind\": \"removeRule\", \"ruleId\": \"99f12464-a429-40fc-86cc-b27612188955\" }, { \"kind\": \"reorderRules\", \"ruleIds\": [\"2f72974e-de68-4243-8dd3-739582147a1f\", \"8bfb304e-d516-47e5-8727-e7f798e8992d\"] }, { \"kind\": \"addClauses\", \"ruleId\": \"1134\", \"clauses\": [ { \"attribute\": \"email\", \"op\": \"in\", \"negate\": false, \"values\": [\"test@test.com\"] } ] }, { \"kind\": \"removeClauses\", \"ruleId\": \"1242529\", \"clauseIds\": [\"8bfb304e-d516-47e5-8727-e7f798e8992d\"] }, { \"kind\": \"updateClause\", \"ruleId\": \"2f72974e-de68-4243-8dd3-739582147a1f\", \"clauseId\": \"309845\", \"clause\": { \"attribute\": \"segmentMatch\", \"negate\": false, \"values\": [\"test-segment\"] } }, { \"kind\": \"updateRuleVariationOrRollout\", \"ruleId\": \"2342\", \"rolloutWeights\": null, \"rolloutBucketBy\": null }, { \"kind\": \"updateOffVariation\", \"variationId\": \"3242453\" }, { \"kind\": \"addPrerequisite\", \"variationId\": \"234235\", \"key\": \"flagKey2\" }, { \"kind\": \"updatePrerequisite\", \"variationId\": \"234235\", \"key\": \"flagKey2\" }, { \"kind\": \"removePrerequisite\", \"key\": \"flagKey\" } ] } ``` ## Using JSON Patches on a feature flag If you do not include the header described above, you can use [JSON patch](/reference#updates-via-json-patch). When using the update feature flag endpoint to add individual users to a specific variation, there are two different patch documents, depending on whether users are already being individually targeted for the variation. If a flag variation already has users individually targeted, the path for the JSON Patch operation is: ```json { \"op\": \"add\", \"path\": \"/environments/devint/targets/0/values/-\", \"value\": \"TestClient10\" } ``` If a flag variation does not already have users individually targeted, the path for the JSON Patch operation is: ```json [ { \"op\": \"add\", \"path\": \"/environments/devint/targets/-\", \"value\": { \"variation\": 0, \"values\": [\"TestClient10\"] } } ] ``` ## Required approvals If a request attempts to alter a flag configuration in an environment where approvals are required for the flag, the request will fail with a 405. Changes to the flag configuration in that environment will required creating an [approval request](/tag/Approvals) or a [workflow](/tag/Workflows-(beta)). ## Conflicts If a flag configuration change made through this endpoint would cause a pending scheduled change or approval request to fail, this endpoint will return a 400. You can ignore this check by adding an `ignoreConflicts` query parameter set to `true`.
|
719
719
|
|
720
720
|
### Examples
|
721
721
|
|
data/docs/FeatureFlagsBetaApi.md
CHANGED
@@ -14,7 +14,7 @@ All URIs are relative to *https://app.launchdarkly.com*
|
|
14
14
|
|
15
15
|
List dependent feature flags
|
16
16
|
|
17
|
-
List dependent flags across all environments for the flag specified in the path parameters. A dependent flag is a flag that uses another flag as a prerequisite.
|
17
|
+
> ### Flag prerequisites is an Enterprise feature > > Flag prerequisites is available to customers on an Enterprise plan. To learn more, [read about our pricing](https://launchdarkly.com/pricing/). To upgrade your plan, [contact Sales](https://launchdarkly.com/contact-sales/). > ### This feature is in beta > > To use this feature, pass in a header including the `LD-API-Version` key with value set to `beta`. Use this header with each call. To learn more, read [Beta resources](/#section/Overview/Beta-resources). List dependent flags across all environments for the flag specified in the path parameters. A dependent flag is a flag that uses another flag as a prerequisite. To learn more, read [Flag prerequisites](https://docs.launchdarkly.com/home/flags/prerequisites).
|
18
18
|
|
19
19
|
### Examples
|
20
20
|
|
@@ -87,7 +87,7 @@ end
|
|
87
87
|
|
88
88
|
List dependent feature flags by environment
|
89
89
|
|
90
|
-
List dependent flags across all environments for the flag specified in the path parameters. A dependent flag is a flag that uses another flag as a prerequisite.
|
90
|
+
> ### Flag prerequisites is an Enterprise feature > > Flag prerequisites is available to customers on an Enterprise plan. To learn more, [read about our pricing](https://launchdarkly.com/pricing/). To upgrade your plan, [contact Sales](https://launchdarkly.com/contact-sales/). > ### This feature is in beta > > To use this feature, pass in a header including the `LD-API-Version` key with value set to `beta`. Use this header with each call. To learn more, read [Beta resources](/#section/Overview/Beta-resources). List dependent flags across all environments for the flag specified in the path parameters. A dependent flag is a flag that uses another flag as a prerequisite. To learn more, read [Flag prerequisites](https://docs.launchdarkly.com/home/flags/prerequisites).
|
91
91
|
|
92
92
|
### Examples
|
93
93
|
|
@@ -5,7 +5,7 @@
|
|
5
5
|
| Name | Type | Description | Notes |
|
6
6
|
| ---- | ---- | ----------- | ----- |
|
7
7
|
| **treatments** | [**Array<TreatmentRep>**](TreatmentRep.md) | | [optional] |
|
8
|
-
| **secondary_metrics** | [**Array<
|
8
|
+
| **secondary_metrics** | [**Array<MetricV2Rep>**](MetricV2Rep.md) | | [optional] |
|
9
9
|
|
10
10
|
## Example
|
11
11
|
|
data/docs/IterationRep.md
CHANGED
@@ -10,11 +10,12 @@
|
|
10
10
|
| **started_at** | **Integer** | | [optional] |
|
11
11
|
| **ended_at** | **Integer** | | [optional] |
|
12
12
|
| **winning_treatment_id** | **String** | | [optional] |
|
13
|
+
| **winning_reason** | **String** | | [optional] |
|
13
14
|
| **can_reshuffle_traffic** | **Boolean** | | [optional] |
|
14
15
|
| **flags** | [**Hash<String, FlagRep>**](FlagRep.md) | | [optional] |
|
15
|
-
| **primary_metric** | [**
|
16
|
+
| **primary_metric** | [**MetricV2Rep**](MetricV2Rep.md) | | [optional] |
|
16
17
|
| **treatments** | [**Array<TreatmentRep>**](TreatmentRep.md) | | [optional] |
|
17
|
-
| **secondary_metrics** | [**Array<
|
18
|
+
| **secondary_metrics** | [**Array<MetricV2Rep>**](MetricV2Rep.md) | | [optional] |
|
18
19
|
|
19
20
|
## Example
|
20
21
|
|
@@ -28,6 +29,7 @@ instance = LaunchDarklyApi::IterationRep.new(
|
|
28
29
|
started_at: null,
|
29
30
|
ended_at: null,
|
30
31
|
winning_treatment_id: null,
|
32
|
+
winning_reason: null,
|
31
33
|
can_reshuffle_traffic: null,
|
32
34
|
flags: null,
|
33
35
|
primary_metric: null,
|
@@ -1,4 +1,4 @@
|
|
1
|
-
# LaunchDarklyApi::
|
1
|
+
# LaunchDarklyApi::LegacyExperimentRep
|
2
2
|
|
3
3
|
## Properties
|
4
4
|
|
@@ -14,7 +14,7 @@
|
|
14
14
|
```ruby
|
15
15
|
require 'launchdarkly_api'
|
16
16
|
|
17
|
-
instance = LaunchDarklyApi::
|
17
|
+
instance = LaunchDarklyApi::LegacyExperimentRep.new(
|
18
18
|
metric_key: my-metric,
|
19
19
|
_metric: null,
|
20
20
|
environments: ["production","test","my-environment"],
|
data/docs/MetricRep.md
CHANGED
@@ -4,9 +4,29 @@
|
|
4
4
|
|
5
5
|
| Name | Type | Description | Notes |
|
6
6
|
| ---- | ---- | ----------- | ----- |
|
7
|
+
| **_id** | **String** | | |
|
7
8
|
| **key** | **String** | | |
|
8
9
|
| **name** | **String** | | |
|
10
|
+
| **kind** | **String** | | |
|
11
|
+
| **_attached_flag_count** | **Integer** | | [optional] |
|
9
12
|
| **_links** | [**Hash<String, Link>**](Link.md) | | |
|
13
|
+
| **_site** | [**Link**](Link.md) | | [optional] |
|
14
|
+
| **_access** | [**Access**](Access.md) | | [optional] |
|
15
|
+
| **tags** | **Array<String>** | | |
|
16
|
+
| **_creation_date** | **Integer** | | |
|
17
|
+
| **last_modified** | [**Modification**](Modification.md) | | [optional] |
|
18
|
+
| **maintainer_id** | **String** | | [optional] |
|
19
|
+
| **_maintainer** | [**MemberSummary**](MemberSummary.md) | | [optional] |
|
20
|
+
| **description** | **String** | | [optional] |
|
21
|
+
| **is_numeric** | **Boolean** | | [optional] |
|
22
|
+
| **success_criteria** | **String** | | [optional] |
|
23
|
+
| **unit** | **String** | | [optional] |
|
24
|
+
| **event_key** | **String** | | [optional] |
|
25
|
+
| **is_active** | **Boolean** | | [optional] |
|
26
|
+
| **_attached_features** | [**Array<FlagListingRep>**](FlagListingRep.md) | | [optional] |
|
27
|
+
| **_version** | **Integer** | | [optional] |
|
28
|
+
| **selector** | **String** | | [optional] |
|
29
|
+
| **urls** | **Array<Object>** | | [optional] |
|
10
30
|
|
11
31
|
## Example
|
12
32
|
|
@@ -14,9 +34,29 @@
|
|
14
34
|
require 'launchdarkly_api'
|
15
35
|
|
16
36
|
instance = LaunchDarklyApi::MetricRep.new(
|
17
|
-
|
18
|
-
|
19
|
-
|
37
|
+
_id: 5902deadbeef667524a01290,
|
38
|
+
key: my-metric,
|
39
|
+
name: my-metric,
|
40
|
+
kind: null,
|
41
|
+
_attached_flag_count: 0,
|
42
|
+
_links: {"parent":{"href":"/api/v2/metrics/my-project","type":"application/json"},"self":{"href":"/api/v2/metrics/my-project/my-metric","type":"application/json"}},
|
43
|
+
_site: null,
|
44
|
+
_access: null,
|
45
|
+
tags: [],
|
46
|
+
_creation_date: null,
|
47
|
+
last_modified: null,
|
48
|
+
maintainer_id: 569fdeadbeef1644facecafe,
|
49
|
+
_maintainer: null,
|
50
|
+
description: null,
|
51
|
+
is_numeric: null,
|
52
|
+
success_criteria: null,
|
53
|
+
unit: null,
|
54
|
+
event_key: null,
|
55
|
+
is_active: null,
|
56
|
+
_attached_features: null,
|
57
|
+
_version: null,
|
58
|
+
selector: null,
|
59
|
+
urls: null
|
20
60
|
)
|
21
61
|
```
|
22
62
|
|
data/docs/MetricV2Rep.md
ADDED
@@ -0,0 +1,22 @@
|
|
1
|
+
# LaunchDarklyApi::MetricV2Rep
|
2
|
+
|
3
|
+
## Properties
|
4
|
+
|
5
|
+
| Name | Type | Description | Notes |
|
6
|
+
| ---- | ---- | ----------- | ----- |
|
7
|
+
| **key** | **String** | | |
|
8
|
+
| **name** | **String** | | |
|
9
|
+
| **_links** | [**Hash<String, Link>**](Link.md) | | |
|
10
|
+
|
11
|
+
## Example
|
12
|
+
|
13
|
+
```ruby
|
14
|
+
require 'launchdarkly_api'
|
15
|
+
|
16
|
+
instance = LaunchDarklyApi::MetricV2Rep.new(
|
17
|
+
key: null,
|
18
|
+
name: null,
|
19
|
+
_links: {"self":{"href":"/api/v2/metrics/my-project/my-metric","type":"application/json"}}
|
20
|
+
)
|
21
|
+
```
|
22
|
+
|
data/docs/OtherApi.md
CHANGED
@@ -16,7 +16,7 @@ All URIs are relative to *https://app.launchdarkly.com*
|
|
16
16
|
|
17
17
|
Gets the public IP list
|
18
18
|
|
19
|
-
Get a list of IP ranges the LaunchDarkly service uses. You can use this list to allow LaunchDarkly through your firewall.<br /><br />This endpoint returns a JSON object with two attributes: `addresses` and `outboundAddresses`. The `addresses` element contains the IP addresses LaunchDarkly's service uses. The `outboundAddresses` element contains the IP addresses outgoing webhook notifications use.<br /><br />We post upcoming changes to this list in advance on our [status page](https://status.launchdarkly.com/).
|
19
|
+
Get a list of IP ranges the LaunchDarkly service uses. You can use this list to allow LaunchDarkly through your firewall.<br /><br />This endpoint returns a JSON object with two attributes: `addresses` and `outboundAddresses`. The `addresses` element contains the IP addresses LaunchDarkly's service uses. The `outboundAddresses` element contains the IP addresses outgoing webhook notifications use. To learn more, read [Public IP list](https://docs.launchdarkly.com/home/advanced/public-ip-list).<br /><br />We post upcoming changes to this list in advance on our [status page](https://status.launchdarkly.com/).
|
20
20
|
|
21
21
|
### Examples
|
22
22
|
|
@@ -0,0 +1,20 @@
|
|
1
|
+
# LaunchDarklyApi::StatisticsRep
|
2
|
+
|
3
|
+
## Properties
|
4
|
+
|
5
|
+
| Name | Type | Description | Notes |
|
6
|
+
| ---- | ---- | ----------- | ----- |
|
7
|
+
| **items** | [**Array<StatisticRep>**](StatisticRep.md) | | [optional] |
|
8
|
+
| **_links** | [**Hash<String, Link>**](Link.md) | | [optional] |
|
9
|
+
|
10
|
+
## Example
|
11
|
+
|
12
|
+
```ruby
|
13
|
+
require 'launchdarkly_api'
|
14
|
+
|
15
|
+
instance = LaunchDarklyApi::StatisticsRep.new(
|
16
|
+
items: null,
|
17
|
+
_links: null
|
18
|
+
)
|
19
|
+
```
|
20
|
+
|