launchdarkly_api 7.0.0 → 7.1.0

Sign up to get free protection for your applications and to get access to all the features.
Files changed (92) hide show
  1. checksums.yaml +4 -4
  2. data/README.md +31 -4
  3. data/docs/AccountMembersApi.md +75 -1
  4. data/docs/CodeReferencesApi.md +5 -1
  5. data/docs/CustomRolesRep.md +24 -0
  6. data/docs/ExpandedTeamRep.md +44 -0
  7. data/docs/FeatureFlagsApi.md +1 -3
  8. data/docs/FlagTriggerInput.md +20 -0
  9. data/docs/FlagTriggersApi.md +396 -0
  10. data/docs/Integration.md +40 -0
  11. data/docs/IntegrationAuditLogSubscriptionsApi.md +376 -0
  12. data/docs/IntegrationStatusRep.md +22 -0
  13. data/docs/IntegrationSubscriptionStatusRep.md +26 -0
  14. data/docs/Integrations.md +22 -0
  15. data/docs/MemberImportItemRep.md +22 -0
  16. data/docs/MemberTeamsFormPost.md +18 -0
  17. data/docs/MetricListingRep.md +1 -1
  18. data/docs/MetricPost.md +1 -1
  19. data/docs/MetricRep.md +1 -1
  20. data/docs/MetricSeen.md +2 -2
  21. data/docs/PutBranch.md +3 -1
  22. data/docs/RecentTriggerBody.md +20 -0
  23. data/docs/Rule.md +3 -1
  24. data/docs/ScheduledChangesApi.md +1 -1
  25. data/docs/SegmentsApi.md +2 -2
  26. data/docs/SubscriptionPost.md +30 -0
  27. data/docs/TeamImportsRep.md +18 -0
  28. data/docs/TeamsBetaApi.md +84 -8
  29. data/docs/TriggerPost.md +22 -0
  30. data/docs/TriggerWorkflowCollectionRep.md +20 -0
  31. data/docs/TriggerWorkflowRep.md +42 -0
  32. data/lib/launchdarkly_api/api/account_members_api.rb +76 -2
  33. data/lib/launchdarkly_api/api/code_references_api.rb +6 -0
  34. data/lib/launchdarkly_api/api/feature_flags_api.rb +2 -5
  35. data/lib/launchdarkly_api/api/flag_triggers_api.rb +437 -0
  36. data/lib/launchdarkly_api/api/integration_audit_log_subscriptions_api.rb +377 -0
  37. data/lib/launchdarkly_api/api/scheduled_changes_api.rb +2 -2
  38. data/lib/launchdarkly_api/api/segments_api.rb +4 -4
  39. data/lib/launchdarkly_api/api/teams_beta_api.rb +77 -6
  40. data/lib/launchdarkly_api/models/custom_roles_rep.rb +247 -0
  41. data/lib/launchdarkly_api/models/expanded_team_rep.rb +349 -0
  42. data/lib/launchdarkly_api/models/flag_trigger_input.rb +230 -0
  43. data/lib/launchdarkly_api/models/integration.rb +325 -0
  44. data/lib/launchdarkly_api/models/integration_status_rep.rb +236 -0
  45. data/lib/launchdarkly_api/models/integration_subscription_status_rep.rb +256 -0
  46. data/lib/launchdarkly_api/models/integrations.rb +240 -0
  47. data/lib/launchdarkly_api/models/member_import_item_rep.rb +246 -0
  48. data/lib/launchdarkly_api/models/member_teams_form_post.rb +226 -0
  49. data/lib/launchdarkly_api/models/metric_listing_rep.rb +13 -1
  50. data/lib/launchdarkly_api/models/metric_post.rb +13 -1
  51. data/lib/launchdarkly_api/models/metric_rep.rb +13 -1
  52. data/lib/launchdarkly_api/models/metric_seen.rb +7 -7
  53. data/lib/launchdarkly_api/models/put_branch.rb +13 -4
  54. data/lib/launchdarkly_api/models/recent_trigger_body.rb +229 -0
  55. data/lib/launchdarkly_api/models/rule.rb +13 -4
  56. data/lib/launchdarkly_api/models/subscription_post.rb +293 -0
  57. data/lib/launchdarkly_api/models/team_imports_rep.rb +220 -0
  58. data/lib/launchdarkly_api/models/trigger_post.rb +245 -0
  59. data/lib/launchdarkly_api/models/trigger_workflow_collection_rep.rb +231 -0
  60. data/lib/launchdarkly_api/models/trigger_workflow_rep.rb +332 -0
  61. data/lib/launchdarkly_api/version.rb +1 -1
  62. data/lib/launchdarkly_api.rb +17 -0
  63. data/spec/api/account_members_api_spec.rb +14 -1
  64. data/spec/api/code_references_api_spec.rb +2 -0
  65. data/spec/api/feature_flags_api_spec.rb +1 -2
  66. data/spec/api/flag_triggers_api_spec.rb +110 -0
  67. data/spec/api/integration_audit_log_subscriptions_api_spec.rb +100 -0
  68. data/spec/api/scheduled_changes_api_spec.rb +1 -1
  69. data/spec/api/segments_api_spec.rb +2 -2
  70. data/spec/api/teams_beta_api_spec.rb +15 -2
  71. data/spec/models/custom_roles_rep_spec.rb +52 -0
  72. data/spec/models/expanded_team_rep_spec.rb +112 -0
  73. data/spec/models/flag_trigger_input_spec.rb +40 -0
  74. data/spec/models/integration_spec.rb +100 -0
  75. data/spec/models/integration_status_rep_spec.rb +46 -0
  76. data/spec/models/integration_subscription_status_rep_spec.rb +58 -0
  77. data/spec/models/integrations_spec.rb +46 -0
  78. data/spec/models/member_import_item_rep_spec.rb +46 -0
  79. data/spec/models/member_teams_form_post_spec.rb +34 -0
  80. data/spec/models/metric_listing_rep_spec.rb +4 -0
  81. data/spec/models/metric_post_spec.rb +4 -0
  82. data/spec/models/metric_rep_spec.rb +4 -0
  83. data/spec/models/metric_seen_spec.rb +1 -1
  84. data/spec/models/put_branch_spec.rb +6 -0
  85. data/spec/models/recent_trigger_body_spec.rb +40 -0
  86. data/spec/models/rule_spec.rb +6 -0
  87. data/spec/models/subscription_post_spec.rb +70 -0
  88. data/spec/models/team_imports_rep_spec.rb +34 -0
  89. data/spec/models/trigger_post_spec.rb +46 -0
  90. data/spec/models/trigger_workflow_collection_rep_spec.rb +40 -0
  91. data/spec/models/trigger_workflow_rep_spec.rb +106 -0
  92. metadata +70 -2
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: b5fa18c753f96439219f4acb093faa22cf901bd17b80274a0fe7ca79e829a7c7
4
- data.tar.gz: 50fa53606668e891cfdd098e8885b10021c56f411990b18bf258bd23657b323a
3
+ metadata.gz: 20e053ea43acedddc221ffeb6a9548db7b3a86b2d68539a4ce275f045e7110a5
4
+ data.tar.gz: 46e5ae30e0914e49807f4c9c57610bbb617b43aba36cdcbbf80e0632fe35f334
5
5
  SHA512:
6
- metadata.gz: bb1bdb01197f78c6d3f209ea4f66a3a6bb34d017fede894a3d35b5de09d7e1a53bab143768d79f277340628f71a54f3d04618b343eddfd7942d7ab7afd6cd9ab
7
- data.tar.gz: 84168897cb889a04f00d230568c2107f052b3c0c1fd02ecc3e86809e2632e4f8d37b89f15e7dbf4464868988817e5142b0cedba104932c0b4dde67267ca6503e
6
+ metadata.gz: cb3fca84a41808bcb33c2d114ed7639cbf69922723334437eeaa5d8583e6f8e8e646de337a22c52765bb57307f55ec9c38dd91f3ced336efa892f6bffdb9b01c
7
+ data.tar.gz: 224c81d09610ce01a53327409e227f4575f9a19df353e47d8196447a9608d39c3ecae5da034d342f382bc55f4aeb2536cbb23bef2773e7a6c4373788f9c6aee2
data/README.md CHANGED
@@ -442,7 +442,7 @@ If you would like to upgrade your integration to use a new API version, you can
442
442
  This SDK is automatically generated by the [OpenAPI Generator](https://openapi-generator.tech) project:
443
443
 
444
444
  - API version: 2.0
445
- - Package version: 7.0.0
445
+ - Package version: 7.1.0
446
446
  - Build package: org.openapitools.codegen.languages.RubyClientCodegen
447
447
  For more information, please visit [https://support.launchdarkly.com](https://support.launchdarkly.com)
448
448
 
@@ -459,16 +459,16 @@ gem build launchdarkly_api.gemspec
459
459
  Then either install the gem locally:
460
460
 
461
461
  ```shell
462
- gem install ./launchdarkly_api-7.0.0.gem
462
+ gem install ./launchdarkly_api-7.1.0.gem
463
463
  ```
464
464
 
465
- (for development, run `gem install --dev ./launchdarkly_api-7.0.0.gem` to install the development dependencies)
465
+ (for development, run `gem install --dev ./launchdarkly_api-7.1.0.gem` to install the development dependencies)
466
466
 
467
467
  or publish the gem to a gem hosting service, e.g. [RubyGems](https://rubygems.org/).
468
468
 
469
469
  Finally add this to the Gemfile:
470
470
 
471
- gem 'launchdarkly_api', '~> 7.0.0'
471
+ gem 'launchdarkly_api', '~> 7.1.0'
472
472
 
473
473
  ### Install from Git
474
474
 
@@ -528,6 +528,7 @@ Class | Method | HTTP request | Description
528
528
  *LaunchDarklyApi::AccountMembersApi* | [**get_member**](docs/AccountMembersApi.md#get_member) | **GET** /api/v2/members/{id} | Get account member
529
529
  *LaunchDarklyApi::AccountMembersApi* | [**get_members**](docs/AccountMembersApi.md#get_members) | **GET** /api/v2/members | List account members
530
530
  *LaunchDarklyApi::AccountMembersApi* | [**patch_member**](docs/AccountMembersApi.md#patch_member) | **PATCH** /api/v2/members/{id} | Modify an account member
531
+ *LaunchDarklyApi::AccountMembersApi* | [**post_member_teams**](docs/AccountMembersApi.md#post_member_teams) | **POST** /api/v2/members/{id}/teams | Add member to teams
531
532
  *LaunchDarklyApi::AccountMembersApi* | [**post_members**](docs/AccountMembersApi.md#post_members) | **POST** /api/v2/members | Invite new members
532
533
  *LaunchDarklyApi::AccountUsageBetaApi* | [**get_evaluations_usage**](docs/AccountUsageBetaApi.md#get_evaluations_usage) | **GET** /api/v2/usage/evaluations/{projKey}/{envKey}/{flagKey} | Get evaluations usage
533
534
  *LaunchDarklyApi::AccountUsageBetaApi* | [**get_events_usage**](docs/AccountUsageBetaApi.md#get_events_usage) | **GET** /api/v2/usage/events/{type} | Get events usage
@@ -590,6 +591,16 @@ Class | Method | HTTP request | Description
590
591
  *LaunchDarklyApi::FeatureFlagsApi* | [**post_feature_flag**](docs/FeatureFlagsApi.md#post_feature_flag) | **POST** /api/v2/flags/{projKey} | Create a feature flag
591
592
  *LaunchDarklyApi::FeatureFlagsBetaApi* | [**get_dependent_flags**](docs/FeatureFlagsBetaApi.md#get_dependent_flags) | **GET** /api/v2/flags/{projKey}/{flagKey}/dependent-flags | List dependent feature flags
592
593
  *LaunchDarklyApi::FeatureFlagsBetaApi* | [**get_dependent_flags_by_env**](docs/FeatureFlagsBetaApi.md#get_dependent_flags_by_env) | **GET** /api/v2/flags/{projKey}/{envKey}/{flagKey}/dependent-flags | List dependent feature flags by environment
594
+ *LaunchDarklyApi::FlagTriggersApi* | [**create_trigger_workflow**](docs/FlagTriggersApi.md#create_trigger_workflow) | **POST** /api/v2/flags/{projKey}/{flagKey}/triggers/{envKey} | Create flag trigger
595
+ *LaunchDarklyApi::FlagTriggersApi* | [**delete_trigger_workflow**](docs/FlagTriggersApi.md#delete_trigger_workflow) | **DELETE** /api/v2/flags/{projKey}/{flagKey}/triggers/{envKey}/{id} | Delete flag trigger
596
+ *LaunchDarklyApi::FlagTriggersApi* | [**get_trigger_workflow_by_id**](docs/FlagTriggersApi.md#get_trigger_workflow_by_id) | **GET** /api/v2/flags/{projKey}/{flagKey}/triggers/{envKey}/{id} | Get flag trigger by ID
597
+ *LaunchDarklyApi::FlagTriggersApi* | [**get_trigger_workflows**](docs/FlagTriggersApi.md#get_trigger_workflows) | **GET** /api/v2/flags/{projKey}/{flagKey}/triggers/{envKey} | List flag triggers
598
+ *LaunchDarklyApi::FlagTriggersApi* | [**patch_trigger_workflow**](docs/FlagTriggersApi.md#patch_trigger_workflow) | **PATCH** /api/v2/flags/{projKey}/{flagKey}/triggers/{envKey}/{id} | Update flag trigger
599
+ *LaunchDarklyApi::IntegrationAuditLogSubscriptionsApi* | [**create_subscription**](docs/IntegrationAuditLogSubscriptionsApi.md#create_subscription) | **POST** /api/v2/integrations/{integrationKey} | Create audit log subscription
600
+ *LaunchDarklyApi::IntegrationAuditLogSubscriptionsApi* | [**delete_subscription**](docs/IntegrationAuditLogSubscriptionsApi.md#delete_subscription) | **DELETE** /api/v2/integrations/{integrationKey}/{id} | Delete audit log subscription
601
+ *LaunchDarklyApi::IntegrationAuditLogSubscriptionsApi* | [**get_subscription_by_id**](docs/IntegrationAuditLogSubscriptionsApi.md#get_subscription_by_id) | **GET** /api/v2/integrations/{integrationKey}/{id} | Get audit log subscription by ID
602
+ *LaunchDarklyApi::IntegrationAuditLogSubscriptionsApi* | [**get_subscriptions**](docs/IntegrationAuditLogSubscriptionsApi.md#get_subscriptions) | **GET** /api/v2/integrations/{integrationKey} | Get audit log subscriptions by integration
603
+ *LaunchDarklyApi::IntegrationAuditLogSubscriptionsApi* | [**update_subscription**](docs/IntegrationAuditLogSubscriptionsApi.md#update_subscription) | **PATCH** /api/v2/integrations/{integrationKey}/{id} | Update audit log subscription
593
604
  *LaunchDarklyApi::MetricsApi* | [**delete_metric**](docs/MetricsApi.md#delete_metric) | **DELETE** /api/v2/metrics/{projectKey}/{key} | Delete metric
594
605
  *LaunchDarklyApi::MetricsApi* | [**get_metric**](docs/MetricsApi.md#get_metric) | **GET** /api/v2/metrics/{projectKey}/{key} | Get metric
595
606
  *LaunchDarklyApi::MetricsApi* | [**get_metrics**](docs/MetricsApi.md#get_metrics) | **GET** /api/v2/metrics/{projectKey} | List metrics
@@ -629,6 +640,7 @@ Class | Method | HTTP request | Description
629
640
  *LaunchDarklyApi::TeamsBetaApi* | [**get_teams**](docs/TeamsBetaApi.md#get_teams) | **GET** /api/v2/teams | List teams
630
641
  *LaunchDarklyApi::TeamsBetaApi* | [**patch_team**](docs/TeamsBetaApi.md#patch_team) | **PATCH** /api/v2/teams/{key} | Update team
631
642
  *LaunchDarklyApi::TeamsBetaApi* | [**post_team**](docs/TeamsBetaApi.md#post_team) | **POST** /api/v2/teams | Create team
643
+ *LaunchDarklyApi::TeamsBetaApi* | [**post_team_members**](docs/TeamsBetaApi.md#post_team_members) | **POST** /api/v2/teams/{key}/members | Add members to team
632
644
  *LaunchDarklyApi::UserSettingsApi* | [**get_expiring_flags_for_user**](docs/UserSettingsApi.md#get_expiring_flags_for_user) | **GET** /api/v2/users/{projKey}/{userKey}/expiring-user-targets/{envKey} | Get expiring dates on flags for user
633
645
  *LaunchDarklyApi::UserSettingsApi* | [**get_user_flag_setting**](docs/UserSettingsApi.md#get_user_flag_setting) | **GET** /api/v2/users/{projKey}/{envKey}/{key}/flags/{featureKey} | Get flag setting for user
634
646
  *LaunchDarklyApi::UserSettingsApi* | [**get_user_flag_settings**](docs/UserSettingsApi.md#get_user_flag_settings) | **GET** /api/v2/users/{projKey}/{envKey}/{key}/flags | List flag settings for user
@@ -685,6 +697,7 @@ Class | Method | HTTP request | Description
685
697
  - [LaunchDarklyApi::CustomRolePost](docs/CustomRolePost.md)
686
698
  - [LaunchDarklyApi::CustomRolePostData](docs/CustomRolePostData.md)
687
699
  - [LaunchDarklyApi::CustomRoles](docs/CustomRoles.md)
700
+ - [LaunchDarklyApi::CustomRolesRep](docs/CustomRolesRep.md)
688
701
  - [LaunchDarklyApi::CustomWorkflowInputRep](docs/CustomWorkflowInputRep.md)
689
702
  - [LaunchDarklyApi::CustomWorkflowMeta](docs/CustomWorkflowMeta.md)
690
703
  - [LaunchDarklyApi::CustomWorkflowOutputRep](docs/CustomWorkflowOutputRep.md)
@@ -702,6 +715,7 @@ Class | Method | HTTP request | Description
702
715
  - [LaunchDarklyApi::Environment](docs/Environment.md)
703
716
  - [LaunchDarklyApi::EnvironmentPost](docs/EnvironmentPost.md)
704
717
  - [LaunchDarklyApi::ExecutionOutputRep](docs/ExecutionOutputRep.md)
718
+ - [LaunchDarklyApi::ExpandedTeamRep](docs/ExpandedTeamRep.md)
705
719
  - [LaunchDarklyApi::ExperimentAllocationRep](docs/ExperimentAllocationRep.md)
706
720
  - [LaunchDarklyApi::ExperimentEnabledPeriodRep](docs/ExperimentEnabledPeriodRep.md)
707
721
  - [LaunchDarklyApi::ExperimentEnvironmentSettingRep](docs/ExperimentEnvironmentSettingRep.md)
@@ -737,19 +751,26 @@ Class | Method | HTTP request | Description
737
751
  - [LaunchDarklyApi::FlagScheduledChangesInput](docs/FlagScheduledChangesInput.md)
738
752
  - [LaunchDarklyApi::FlagStatusRep](docs/FlagStatusRep.md)
739
753
  - [LaunchDarklyApi::FlagSummary](docs/FlagSummary.md)
754
+ - [LaunchDarklyApi::FlagTriggerInput](docs/FlagTriggerInput.md)
740
755
  - [LaunchDarklyApi::ForbiddenErrorRep](docs/ForbiddenErrorRep.md)
741
756
  - [LaunchDarklyApi::HunkRep](docs/HunkRep.md)
757
+ - [LaunchDarklyApi::Integration](docs/Integration.md)
742
758
  - [LaunchDarklyApi::IntegrationMetadata](docs/IntegrationMetadata.md)
743
759
  - [LaunchDarklyApi::IntegrationStatus](docs/IntegrationStatus.md)
760
+ - [LaunchDarklyApi::IntegrationStatusRep](docs/IntegrationStatusRep.md)
761
+ - [LaunchDarklyApi::IntegrationSubscriptionStatusRep](docs/IntegrationSubscriptionStatusRep.md)
762
+ - [LaunchDarklyApi::Integrations](docs/Integrations.md)
744
763
  - [LaunchDarklyApi::InvalidRequestErrorRep](docs/InvalidRequestErrorRep.md)
745
764
  - [LaunchDarklyApi::IpList](docs/IpList.md)
746
765
  - [LaunchDarklyApi::LastSeenMetadata](docs/LastSeenMetadata.md)
747
766
  - [LaunchDarklyApi::Link](docs/Link.md)
748
767
  - [LaunchDarklyApi::Member](docs/Member.md)
749
768
  - [LaunchDarklyApi::MemberDataRep](docs/MemberDataRep.md)
769
+ - [LaunchDarklyApi::MemberImportItemRep](docs/MemberImportItemRep.md)
750
770
  - [LaunchDarklyApi::MemberPermissionGrantSummaryRep](docs/MemberPermissionGrantSummaryRep.md)
751
771
  - [LaunchDarklyApi::MemberSummaryRep](docs/MemberSummaryRep.md)
752
772
  - [LaunchDarklyApi::MemberTeamSummaryRep](docs/MemberTeamSummaryRep.md)
773
+ - [LaunchDarklyApi::MemberTeamsFormPost](docs/MemberTeamsFormPost.md)
753
774
  - [LaunchDarklyApi::Members](docs/Members.md)
754
775
  - [LaunchDarklyApi::MethodNotAllowedErrorRep](docs/MethodNotAllowedErrorRep.md)
755
776
  - [LaunchDarklyApi::MetricCollectionRep](docs/MetricCollectionRep.md)
@@ -781,6 +802,7 @@ Class | Method | HTTP request | Description
781
802
  - [LaunchDarklyApi::PubNubDetailRep](docs/PubNubDetailRep.md)
782
803
  - [LaunchDarklyApi::PutBranch](docs/PutBranch.md)
783
804
  - [LaunchDarklyApi::RateLimitedErrorRep](docs/RateLimitedErrorRep.md)
805
+ - [LaunchDarklyApi::RecentTriggerBody](docs/RecentTriggerBody.md)
784
806
  - [LaunchDarklyApi::ReferenceRep](docs/ReferenceRep.md)
785
807
  - [LaunchDarklyApi::RelayAutoConfigCollectionRep](docs/RelayAutoConfigCollectionRep.md)
786
808
  - [LaunchDarklyApi::RelayAutoConfigPost](docs/RelayAutoConfigPost.md)
@@ -816,9 +838,11 @@ Class | Method | HTTP request | Description
816
838
  - [LaunchDarklyApi::StatisticsRoot](docs/StatisticsRoot.md)
817
839
  - [LaunchDarklyApi::StatusConflictErrorRep](docs/StatusConflictErrorRep.md)
818
840
  - [LaunchDarklyApi::SubjectDataRep](docs/SubjectDataRep.md)
841
+ - [LaunchDarklyApi::SubscriptionPost](docs/SubscriptionPost.md)
819
842
  - [LaunchDarklyApi::Target](docs/Target.md)
820
843
  - [LaunchDarklyApi::TargetResourceRep](docs/TargetResourceRep.md)
821
844
  - [LaunchDarklyApi::TeamCollectionRep](docs/TeamCollectionRep.md)
845
+ - [LaunchDarklyApi::TeamImportsRep](docs/TeamImportsRep.md)
822
846
  - [LaunchDarklyApi::TeamPatchInput](docs/TeamPatchInput.md)
823
847
  - [LaunchDarklyApi::TeamPostInput](docs/TeamPostInput.md)
824
848
  - [LaunchDarklyApi::TeamRep](docs/TeamRep.md)
@@ -826,6 +850,9 @@ Class | Method | HTTP request | Description
826
850
  - [LaunchDarklyApi::Token](docs/Token.md)
827
851
  - [LaunchDarklyApi::TokenDataRep](docs/TokenDataRep.md)
828
852
  - [LaunchDarklyApi::Tokens](docs/Tokens.md)
853
+ - [LaunchDarklyApi::TriggerPost](docs/TriggerPost.md)
854
+ - [LaunchDarklyApi::TriggerWorkflowCollectionRep](docs/TriggerWorkflowCollectionRep.md)
855
+ - [LaunchDarklyApi::TriggerWorkflowRep](docs/TriggerWorkflowRep.md)
829
856
  - [LaunchDarklyApi::UnauthorizedErrorRep](docs/UnauthorizedErrorRep.md)
830
857
  - [LaunchDarklyApi::UrlPost](docs/UrlPost.md)
831
858
  - [LaunchDarklyApi::User](docs/User.md)
@@ -8,6 +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
12
  | [**post_members**](AccountMembersApi.md#post_members) | **POST** /api/v2/members | Invite new members |
12
13
 
13
14
 
@@ -237,7 +238,7 @@ end
237
238
 
238
239
  Modify an account member
239
240
 
240
- Update a single account member. The request should be a valid JSON Patch document describing the changes to be made to the member. Requests to update account members will not work if SCIM is enabled for the account.
241
+ Update a single account member. The request should be a valid JSON Patch document describing the changes to be made to the member. To update fields in the account member 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. For example, to add a new custom role to a member, use the following request body: ``` [ { \"op\": \"add\", \"path\": \"/customRoles/0\", \"value\": \"some-role-id\" } ] ``` Requests to update account members will not work if SCIM is enabled for the account.
241
242
 
242
243
  ### Examples
243
244
 
@@ -304,6 +305,79 @@ end
304
305
  - **Accept**: application/json
305
306
 
306
307
 
308
+ ## post_member_teams
309
+
310
+ > <Member> post_member_teams(id, member_teams_form_post)
311
+
312
+ Add member to teams
313
+
314
+ Add member to team(s)
315
+
316
+ ### Examples
317
+
318
+ ```ruby
319
+ require 'time'
320
+ require 'launchdarkly_api'
321
+ # setup authorization
322
+ LaunchDarklyApi.configure do |config|
323
+ # Configure API key authorization: ApiKey
324
+ config.api_key['ApiKey'] = 'YOUR API KEY'
325
+ # Uncomment the following line to set a prefix for the API key, e.g. 'Bearer' (defaults to nil)
326
+ # config.api_key_prefix['ApiKey'] = 'Bearer'
327
+ end
328
+
329
+ api_instance = LaunchDarklyApi::AccountMembersApi.new
330
+ id = 'id_example' # String | The member ID
331
+ member_teams_form_post = LaunchDarklyApi::MemberTeamsFormPost.new({team_keys: ['team_keys_example']}) # MemberTeamsFormPost |
332
+
333
+ begin
334
+ # Add member to teams
335
+ result = api_instance.post_member_teams(id, member_teams_form_post)
336
+ p result
337
+ rescue LaunchDarklyApi::ApiError => e
338
+ puts "Error when calling AccountMembersApi->post_member_teams: #{e}"
339
+ end
340
+ ```
341
+
342
+ #### Using the post_member_teams_with_http_info variant
343
+
344
+ This returns an Array which contains the response data, status code and headers.
345
+
346
+ > <Array(<Member>, Integer, Hash)> post_member_teams_with_http_info(id, member_teams_form_post)
347
+
348
+ ```ruby
349
+ begin
350
+ # Add member to teams
351
+ data, status_code, headers = api_instance.post_member_teams_with_http_info(id, member_teams_form_post)
352
+ p status_code # => 2xx
353
+ p headers # => { ... }
354
+ p data # => <Member>
355
+ rescue LaunchDarklyApi::ApiError => e
356
+ puts "Error when calling AccountMembersApi->post_member_teams_with_http_info: #{e}"
357
+ end
358
+ ```
359
+
360
+ ### Parameters
361
+
362
+ | Name | Type | Description | Notes |
363
+ | ---- | ---- | ----------- | ----- |
364
+ | **id** | **String** | The member ID | |
365
+ | **member_teams_form_post** | [**MemberTeamsFormPost**](MemberTeamsFormPost.md) | | |
366
+
367
+ ### Return type
368
+
369
+ [**Member**](Member.md)
370
+
371
+ ### Authorization
372
+
373
+ [ApiKey](../README.md#ApiKey)
374
+
375
+ ### HTTP request headers
376
+
377
+ - **Content-Type**: application/json
378
+ - **Accept**: application/json
379
+
380
+
307
381
  ## post_members
308
382
 
309
383
  > <Members> post_members(new_member_form)
@@ -337,7 +337,9 @@ opts = {
337
337
  repo_name: 'repo_name_example', # String | Filter results to a specific repository
338
338
  branch_name: 'branch_name_example', # String | Filter results to a specific branch. By default, only the default branch will be queried for extinctions.
339
339
  proj_key: 'proj_key_example', # String | Filter results to a specific project
340
- flag_key: 'flag_key_example' # String | Filter results to a specific flag key
340
+ flag_key: 'flag_key_example', # String | Filter results to a specific flag key
341
+ from: 789, # Integer | Filter results to a specific timeframe based on commit time, expressed as a Unix epoch time in milliseconds. Must be used with `to`.
342
+ to: 789 # Integer | Filter results to a specific timeframe based on commit time, expressed as a Unix epoch time in milliseconds. Must be used with `from`.
341
343
  }
342
344
 
343
345
  begin
@@ -375,6 +377,8 @@ end
375
377
  | **branch_name** | **String** | Filter results to a specific branch. By default, only the default branch will be queried for extinctions. | [optional] |
376
378
  | **proj_key** | **String** | Filter results to a specific project | [optional] |
377
379
  | **flag_key** | **String** | Filter results to a specific flag key | [optional] |
380
+ | **from** | **Integer** | Filter results to a specific timeframe based on commit time, expressed as a Unix epoch time in milliseconds. Must be used with &#x60;to&#x60;. | [optional] |
381
+ | **to** | **Integer** | Filter results to a specific timeframe based on commit time, expressed as a Unix epoch time in milliseconds. Must be used with &#x60;from&#x60;. | [optional] |
378
382
 
379
383
  ### Return type
380
384
 
@@ -0,0 +1,24 @@
1
+ # LaunchDarklyApi::CustomRolesRep
2
+
3
+ ## Properties
4
+
5
+ | Name | Type | Description | Notes |
6
+ | ---- | ---- | ----------- | ----- |
7
+ | **key** | **String** | | [optional] |
8
+ | **name** | **String** | | [optional] |
9
+ | **projects** | **Array&lt;String&gt;** | | [optional] |
10
+ | **applied_on** | **Integer** | | [optional] |
11
+
12
+ ## Example
13
+
14
+ ```ruby
15
+ require 'launchdarkly_api'
16
+
17
+ instance = LaunchDarklyApi::CustomRolesRep.new(
18
+ key: null,
19
+ name: null,
20
+ projects: null,
21
+ applied_on: null
22
+ )
23
+ ```
24
+
@@ -0,0 +1,44 @@
1
+ # LaunchDarklyApi::ExpandedTeamRep
2
+
3
+ ## Properties
4
+
5
+ | Name | Type | Description | Notes |
6
+ | ---- | ---- | ----------- | ----- |
7
+ | **custom_roles** | [**Array&lt;CustomRolesRep&gt;**](CustomRolesRep.md) | | [optional] |
8
+ | **team_maintainers** | [**Array&lt;MemberSummaryRep&gt;**](MemberSummaryRep.md) | | [optional] |
9
+ | **custom_role_keys** | **Array&lt;String&gt;** | | [optional] |
10
+ | **description** | **String** | | [optional] |
11
+ | **key** | **String** | | [optional] |
12
+ | **member_ids** | **Array&lt;String&gt;** | | [optional] |
13
+ | **name** | **String** | | [optional] |
14
+ | **permission_grants** | [**Array&lt;PermissionGrantRep&gt;**](PermissionGrantRep.md) | | [optional] |
15
+ | **project_keys** | **Array&lt;String&gt;** | | [optional] |
16
+ | **_access** | [**AccessRep**](AccessRep.md) | | [optional] |
17
+ | **_created_at** | **Integer** | | [optional] |
18
+ | **_links** | [**Hash&lt;String, Link&gt;**](Link.md) | | [optional] |
19
+ | **_updated_at** | **Integer** | | [optional] |
20
+ | **_version** | **Integer** | | [optional] |
21
+
22
+ ## Example
23
+
24
+ ```ruby
25
+ require 'launchdarkly_api'
26
+
27
+ instance = LaunchDarklyApi::ExpandedTeamRep.new(
28
+ custom_roles: null,
29
+ team_maintainers: null,
30
+ custom_role_keys: null,
31
+ description: null,
32
+ key: null,
33
+ member_ids: null,
34
+ name: null,
35
+ permission_grants: null,
36
+ project_keys: null,
37
+ _access: null,
38
+ _created_at: null,
39
+ _links: null,
40
+ _updated_at: null,
41
+ _version: null
42
+ )
43
+ ```
44
+
@@ -569,7 +569,6 @@ opts = {
569
569
  tag: 'tag_example', # String | Filter feature flags by tag
570
570
  limit: 789, # Integer | The number of feature flags to return. Defaults to -1, which returns all flags
571
571
  offset: 789, # Integer | Where to start in the list. Use this with pagination. For example, an offset of 10 skips the first ten items and then returns the next limit items
572
- query: 'query_example', # String | A string that matches against the flags' keys and names. It is not case sensitive
573
572
  archived: true, # Boolean | A boolean to filter the list to archived flags. When this is absent, only unarchived flags will be returned
574
573
  summary: true, # Boolean | By default in API version >= 1, flags will _not_ include their list of prerequisites, targets or rules. Set summary=0 to include these fields for each flag returned
575
574
  filter: 'filter_example', # String | A comma-separated list of filters. Each filter is of the form field:value
@@ -612,7 +611,6 @@ end
612
611
  | **tag** | **String** | Filter feature flags by tag | [optional] |
613
612
  | **limit** | **Integer** | The number of feature flags to return. Defaults to -1, which returns all flags | [optional] |
614
613
  | **offset** | **Integer** | Where to start in the list. Use this with pagination. For example, an offset of 10 skips the first ten items and then returns the next limit items | [optional] |
615
- | **query** | **String** | A string that matches against the flags&#39; keys and names. It is not case sensitive | [optional] |
616
614
  | **archived** | **Boolean** | A boolean to filter the list to archived flags. When this is absent, only unarchived flags will be returned | [optional] |
617
615
  | **summary** | **Boolean** | By default in API version &gt;&#x3D; 1, flags will _not_ include their list of prerequisites, targets or rules. Set summary&#x3D;0 to include these fields for each flag returned | [optional] |
618
616
  | **filter** | **String** | A comma-separated list of filters. Each filter is of the form field:value | [optional] |
@@ -715,7 +713,7 @@ end
715
713
 
716
714
  Update feature flag
717
715
 
718
- Perform a partial update to a feature flag. ## Using JSON Patches on a feature flag 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\"] } } ] ``` ## Using semantic patches on a feature flag To use a [semantic patch](/#section/Updates/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 receive a `400` response as 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 action or list of actions to be performed by the update. Each update action in the list must be an object/hash table with a `kind` property, although depending on the action, other properties may be necessary. 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. #### `turnFlagOff` Sets the flag's targeting state to off. #### `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](/#section/Updates/Updates-via-JSON-Patch).
716
+ Perform a partial update to a feature flag. ## Using JSON Patches on a feature flag 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\"] } } ] ``` ## 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 action or list of actions to be performed by the update. Each update action in the list must be an object/hash table with a `kind` property, although depending on the action, other properties may be necessary. 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. #### `turnFlagOff` Sets the flag's targeting state to off. #### `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).
719
717
 
720
718
  ### Examples
721
719
 
@@ -0,0 +1,20 @@
1
+ # LaunchDarklyApi::FlagTriggerInput
2
+
3
+ ## Properties
4
+
5
+ | Name | Type | Description | Notes |
6
+ | ---- | ---- | ----------- | ----- |
7
+ | **comment** | **String** | | [optional] |
8
+ | **instructions** | **Array&lt;Hash&gt;** | The action to perform when triggering. It should pass an array with a single {\&quot;kind\&quot;: &lt;flag_action&gt;} object. Currently supported flag actions are \&quot;turnFlagOn\&quot; and \&quot;turnFlagOff\&quot;. | [optional] |
9
+
10
+ ## Example
11
+
12
+ ```ruby
13
+ require 'launchdarkly_api'
14
+
15
+ instance = LaunchDarklyApi::FlagTriggerInput.new(
16
+ comment: null,
17
+ instructions: null
18
+ )
19
+ ```
20
+