From e0c992562c9e4c22a0ca4cbe7f89b9bdd4453004 Mon Sep 17 00:00:00 2001 From: "fern-api[bot]" <115122769+fern-api[bot]@users.noreply.github.com> Date: Tue, 29 Sep 2026 05:48:37 +0000 Subject: [PATCH 1/3] [fern-generated] Update SDK Generated by Fern CLI Version: unknown Generators: - fernapi/fern-python-sdk: 5.26.0 --- UPGRADING.md | 157 - reference.md | 9220 ++++++++++------- src/auth0/management/__init__.py | 189 +- src/auth0/management/clients/client.py | 9 + src/auth0/management/clients/raw_client.py | 13 + src/auth0/management/core/client_wrapper.py | 16 - .../management/experimentation/__init__.py | 10 +- .../management/experimentation/client.py | 38 + .../experimentation/experiments/client.py | 763 ++ .../experimentation/experiments/raw_client.py | 1705 ++- .../experimentation/feature_flags/__init__.py | 34 + .../experimentation/feature_flags/client.py | 626 ++ .../feature_flags/raw_client.py | 1313 +++ .../feature_flags/variations}/__init__.py | 0 .../feature_flags/variations/client.py | 508 + .../feature_flags/variations/raw_client.py | 1138 ++ .../experimentation/segments/__init__.py | 4 + .../experimentation/segments/client.py | 509 + .../experimentation/segments/raw_client.py | 1131 ++ .../management/organizations/__init__.py | 3 - src/auth0/management/organizations/client.py | 19 - .../organization_template/client.py | 274 - .../organization_template/raw_client.py | 531 - .../management/resource_servers/client.py | 20 + .../management/resource_servers/raw_client.py | 20 + src/auth0/management/types/__init__.py | 189 +- src/auth0/management/types/allocation_item.py | 28 + .../types/allocation_request_item.py | 47 + .../types/allocation_strategy_enum.py | 5 + ...nc_approval_notifications_channels_enum.py | 4 +- .../types/authentication_flow_enum.py | 8 + ...ations_channels_api_patch_configuration.py | 2 +- ...cations_channels_api_post_configuration.py | 2 +- ...oidc_backchannel_logout_initiators_enum.py | 1 + ...client_oidc_support_allowed_scopes_enum.py | 5 + .../types/client_oidc_support_post.py | 26 + .../connection_deletion_behavior_enum.py | 5 - .../management/types/connection_options_ad.py | 6 + .../types/connection_options_adfs.py | 6 + .../types/connection_options_azure_ad.py | 6 + .../types/connection_options_common_saml.py | 6 + .../types/connection_properties_options.py | 8 + .../types/connection_thumbprints.py | 2 +- .../types/connection_thumbprints_sha_384.py | 8 + .../connection_thumbprints_sha_384_ad.py | 8 + .../connection_thumbprints_sha_384_saml.py | 8 + .../create_experiment_response_content.py | 54 + .../types/create_feature_flag_parameters.py | 10 + .../create_feature_flag_response_content.py | 30 + ...create_resource_server_response_content.py | 5 + .../types/create_segment_response_content.py | 28 + .../create_variation_response_content.py | 27 + .../management/types/default_config_enum.py | 5 + .../management/types/experiment_list_item.py | 54 + .../types/experiment_status_enum.py | 5 + .../experiment_transition_status_enum.py | 5 + ...ride.py => experiment_validation_error.py} | 12 +- src/auth0/management/types/feature_flag.py | 30 + .../types/feature_flag_config_param.py | 25 + .../feature_flag_config_param_type_enum.py | 7 + .../types/feature_flag_config_params.py | 10 + .../types/feature_flag_status_enum.py | 5 + .../types/feature_flag_type_enum.py | 5 + .../types/get_experiment_response_content.py | 54 + .../get_feature_flag_response_content.py | 30 + .../get_resource_server_response_content.py | 5 + .../types/get_segment_response_content.py | 28 + .../types/get_variation_response_content.py | 27 + .../list_experiments_response_content.py | 24 + .../list_feature_flags_response_content.py | 24 + .../types/list_segments_response_content.py | 24 + .../types/list_variations_response_content.py | 20 + src/auth0/management/types/oauth_scope.py | 4 +- .../organization_deletion_behavior_enum.py | 5 - .../management/types/organization_template.py | 89 - ...nization_template_allowed_strategy_enum.py | 7 - ...anization_template_role_visibility_enum.py | 5 - ...ization_template_role_visibility_policy.py | 29 - src/auth0/management/types/resource_server.py | 5 + .../types/resource_server_search_response.py | 5 + src/auth0/management/types/segment.py | 28 + .../types/segment_contains_expression.py | 19 + .../types/segment_ends_with_expression.py | 19 + .../types/segment_exists_expression.py | 19 + .../types/segment_match_conditions.py | 34 + .../types/segment_match_expression.py | 16 + .../types/segment_not_match_conditions.py | 34 + src/auth0/management/types/segment_rule.py | 22 + .../types/segment_starts_with_expression.py | 19 + .../management/types/segment_type_enum.py | 5 + .../types/segment_type_filter_enum.py | 5 + .../types/update_connection_options.py | 8 + .../update_experiment_response_content.py | 54 + ...date_experiment_status_response_content.py | 54 + .../types/update_feature_flag_parameters.py | 10 + .../update_feature_flag_response_content.py | 30 + ...te_feature_flag_status_response_content.py | 30 + ...update_resource_server_response_content.py | 5 + .../types/update_segment_response_content.py | 28 + .../types/update_variation_overrides_map.py | 8 + .../update_variation_response_content.py | 27 + ...> validate_experiment_response_content.py} | 15 +- src/auth0/management/types/variation.py | 27 + .../types/variation_overrides_map.py | 8 + src/auth0/management/user_blocks/client.py | 16 +- .../management/user_blocks/raw_client.py | 16 +- src/auth0/management/users/client.py | 36 +- src/auth0/management/users/raw_client.py | 36 +- .../wire/test_experimentation_experiments.py | 89 + .../wire/test_experimentation_featureFlags.py | 72 + ...experimentation_featureFlags_variations.py | 56 + tests/wire/test_experimentation_segments.py | 56 + ...test_organizations_organizationTemplate.py | 33 - wiremock/wiremock-mappings.json | 984 +- 114 files changed, 16115 insertions(+), 5135 deletions(-) delete mode 100644 UPGRADING.md create mode 100644 src/auth0/management/experimentation/feature_flags/__init__.py create mode 100644 src/auth0/management/experimentation/feature_flags/client.py create mode 100644 src/auth0/management/experimentation/feature_flags/raw_client.py rename src/auth0/management/{organizations/organization_template => experimentation/feature_flags/variations}/__init__.py (100%) create mode 100644 src/auth0/management/experimentation/feature_flags/variations/client.py create mode 100644 src/auth0/management/experimentation/feature_flags/variations/raw_client.py create mode 100644 src/auth0/management/experimentation/segments/__init__.py create mode 100644 src/auth0/management/experimentation/segments/client.py create mode 100644 src/auth0/management/experimentation/segments/raw_client.py delete mode 100644 src/auth0/management/organizations/organization_template/client.py delete mode 100644 src/auth0/management/organizations/organization_template/raw_client.py create mode 100644 src/auth0/management/types/allocation_item.py create mode 100644 src/auth0/management/types/allocation_request_item.py create mode 100644 src/auth0/management/types/allocation_strategy_enum.py create mode 100644 src/auth0/management/types/authentication_flow_enum.py create mode 100644 src/auth0/management/types/client_oidc_support_allowed_scopes_enum.py create mode 100644 src/auth0/management/types/client_oidc_support_post.py delete mode 100644 src/auth0/management/types/connection_deletion_behavior_enum.py create mode 100644 src/auth0/management/types/connection_thumbprints_sha_384.py create mode 100644 src/auth0/management/types/connection_thumbprints_sha_384_ad.py create mode 100644 src/auth0/management/types/connection_thumbprints_sha_384_saml.py create mode 100644 src/auth0/management/types/create_experiment_response_content.py create mode 100644 src/auth0/management/types/create_feature_flag_parameters.py create mode 100644 src/auth0/management/types/create_feature_flag_response_content.py create mode 100644 src/auth0/management/types/create_segment_response_content.py create mode 100644 src/auth0/management/types/create_variation_response_content.py create mode 100644 src/auth0/management/types/default_config_enum.py create mode 100644 src/auth0/management/types/experiment_list_item.py create mode 100644 src/auth0/management/types/experiment_status_enum.py create mode 100644 src/auth0/management/types/experiment_transition_status_enum.py rename src/auth0/management/types/{organization_template_role_visibility_override.py => experiment_validation_error.py} (61%) create mode 100644 src/auth0/management/types/feature_flag.py create mode 100644 src/auth0/management/types/feature_flag_config_param.py create mode 100644 src/auth0/management/types/feature_flag_config_param_type_enum.py create mode 100644 src/auth0/management/types/feature_flag_config_params.py create mode 100644 src/auth0/management/types/feature_flag_status_enum.py create mode 100644 src/auth0/management/types/feature_flag_type_enum.py create mode 100644 src/auth0/management/types/get_experiment_response_content.py create mode 100644 src/auth0/management/types/get_feature_flag_response_content.py create mode 100644 src/auth0/management/types/get_segment_response_content.py create mode 100644 src/auth0/management/types/get_variation_response_content.py create mode 100644 src/auth0/management/types/list_experiments_response_content.py create mode 100644 src/auth0/management/types/list_feature_flags_response_content.py create mode 100644 src/auth0/management/types/list_segments_response_content.py create mode 100644 src/auth0/management/types/list_variations_response_content.py delete mode 100644 src/auth0/management/types/organization_deletion_behavior_enum.py delete mode 100644 src/auth0/management/types/organization_template.py delete mode 100644 src/auth0/management/types/organization_template_allowed_strategy_enum.py delete mode 100644 src/auth0/management/types/organization_template_role_visibility_enum.py delete mode 100644 src/auth0/management/types/organization_template_role_visibility_policy.py create mode 100644 src/auth0/management/types/segment.py create mode 100644 src/auth0/management/types/segment_contains_expression.py create mode 100644 src/auth0/management/types/segment_ends_with_expression.py create mode 100644 src/auth0/management/types/segment_exists_expression.py create mode 100644 src/auth0/management/types/segment_match_conditions.py create mode 100644 src/auth0/management/types/segment_match_expression.py create mode 100644 src/auth0/management/types/segment_not_match_conditions.py create mode 100644 src/auth0/management/types/segment_rule.py create mode 100644 src/auth0/management/types/segment_starts_with_expression.py create mode 100644 src/auth0/management/types/segment_type_enum.py create mode 100644 src/auth0/management/types/segment_type_filter_enum.py create mode 100644 src/auth0/management/types/update_experiment_response_content.py create mode 100644 src/auth0/management/types/update_experiment_status_response_content.py create mode 100644 src/auth0/management/types/update_feature_flag_parameters.py create mode 100644 src/auth0/management/types/update_feature_flag_response_content.py create mode 100644 src/auth0/management/types/update_feature_flag_status_response_content.py create mode 100644 src/auth0/management/types/update_segment_response_content.py create mode 100644 src/auth0/management/types/update_variation_overrides_map.py create mode 100644 src/auth0/management/types/update_variation_response_content.py rename src/auth0/management/types/{organization_template_use_for_organization_discovery.py => validate_experiment_response_content.py} (54%) create mode 100644 src/auth0/management/types/variation.py create mode 100644 src/auth0/management/types/variation_overrides_map.py create mode 100644 tests/wire/test_experimentation_featureFlags.py create mode 100644 tests/wire/test_experimentation_featureFlags_variations.py create mode 100644 tests/wire/test_experimentation_segments.py delete mode 100644 tests/wire/test_organizations_organizationTemplate.py diff --git a/UPGRADING.md b/UPGRADING.md deleted file mode 100644 index ed653dbf..00000000 --- a/UPGRADING.md +++ /dev/null @@ -1,157 +0,0 @@ -# v6 Migration Guide - -A guide to migrating the Auth0 Python SDK from v5 to v6. - -- [Overall changes](#overall-changes) -- [Breaking changes](#breaking-changes) - - [Federated connections tokensets removed](#federated-connections-tokensets-removed) - - [`federated_connections_access_tokens` field removed](#federated_connections_access_tokens-field-removed) - - [`read:federated_connections_tokens` / `delete:federated_connections_tokens` scopes removed](#readfederated_connections_tokens--deletefederated_connections_tokens-scopes-removed) - - [`ClientSessionTransferDelegationDeviceBindingEnum` narrowed](#clientsessiontransferdelegationdevicebindingenum-narrowed) - - [`ConnectionAttributeIdentifier` split into three types](#connectionattributeidentifier-split-into-three-types) - - [`PhoneProviderProtectionBackoffStrategyEnum` value renamed](#phoneproviderprotectionbackoffstrategyenum-value-renamed) - - [`ListRolesOffsetPaginatedResponseContent` pagination fields now required](#listrolesoffsetpaginatedresponsecontent-pagination-fields-now-required) - -## Overall changes - -v6 removes one deprecated Management API surface (federated connections -tokensets) and tightens a handful of generated types to match the current -Auth0 Management API contract. Most applications will only be affected if -they use the specific types or endpoints listed below. - -The Authentication API is not affected by this release. - -## Breaking changes - -### Federated connections tokensets removed - -The `users.federated_connections_tokensets` sub-client and its `list`/`delete` -methods have been removed, along with the `FederatedConnectionTokenSet` and -`ConnectionFederatedConnectionsAccessTokens` types. This endpoint is no longer -part of the Auth0 Management API. - -```python -# v5 -client.users.federated_connections_tokensets.list(id="user_id") -client.users.federated_connections_tokensets.delete(id="user_id", tokenset_id="tokenset_id") -``` - -```python -# v6 -# No replacement — the endpoint has been removed from the Management API. -``` - -If you depend on this functionality, do not upgrade until you have confirmed -an alternative with Auth0 support. - -### `federated_connections_access_tokens` field removed - -The optional `federated_connections_access_tokens` field has been removed -from: - -- `ConnectionOptionsAzureAd` -- `ConnectionOptionsCommonOidc` -- `ConnectionOptionsGoogleApps` -- `ConnectionPropertiesOptions` -- `UpdateConnectionOptions` - -Any code reading or setting this field on the above types will need to -remove that usage. Note that these models are configured with -`extra="allow"`, so passing `federated_connections_access_tokens` is **not** -silently dropped — it is retained on the model and still serialized into the -outbound request. Remove the field explicitly rather than relying on the SDK -to strip it. - -### `read:federated_connections_tokens` / `delete:federated_connections_tokens` scopes removed - -These two values are no longer valid members of `OauthScope`. Remove any -references to them when requesting or checking scopes. - -### `ClientSessionTransferDelegationDeviceBindingEnum` narrowed - -The `"asn"` literal value has been removed. The enum now only accepts `"ip"`: - -```python -# v5 -ClientSessionTransferDelegationDeviceBindingEnum = typing.Union[typing.Literal["ip", "asn"], typing.Any] -``` - -```python -# v6 -ClientSessionTransferDelegationDeviceBindingEnum = typing.Union[typing.Literal["ip"], typing.Any] -``` - -If you were setting this value to `"asn"`, update it to `"ip"` — this matches -the current Management API's accepted values. - -### `ConnectionAttributeIdentifier` split into three types - -`ConnectionAttributeIdentifier` has been removed with no compatibility alias. -It is replaced by three narrower types, one per attribute: - -| Attribute field | v5 type | v6 type | Shape | -| --- | --- | --- | --- | -| `EmailAttribute.identifier` | `ConnectionAttributeIdentifier` | `EmailAttributeIdentifier` | `{active?, default_method?: DefaultMethodEmailIdentifierEnum}` | -| `PhoneAttribute.identifier` | `ConnectionAttributeIdentifier` | `PhoneAttributeIdentifier` | `{active?, default_method?: DefaultMethodPhoneNumberIdentifierEnum}` | -| `UsernameAttribute.identifier` | `ConnectionAttributeIdentifier` | `UsernameAttributeIdentifier` | `{active?}` (no `default_method`) | - -```python -# v5 -from auth0.management.types import ConnectionAttributeIdentifier - -identifier = ConnectionAttributeIdentifier(active=True, default_method="email_otp") -``` - -```python -# v6 -from auth0.management.types import EmailAttributeIdentifier - -identifier = EmailAttributeIdentifier(active=True, default_method="email_otp") -``` - -`EmailAttributeIdentifier` has the same shape as the old -`ConnectionAttributeIdentifier` and is a drop-in replacement for code that -was only ever used with `EmailAttribute`. Code using -`ConnectionAttributeIdentifier` with `PhoneAttribute` or `UsernameAttribute` -must switch to `PhoneAttributeIdentifier` or `UsernameAttributeIdentifier` -respectively; `UsernameAttributeIdentifier` does not support -`default_method`. - -### `PhoneProviderProtectionBackoffStrategyEnum` value renamed - -The `"none"` literal has been replaced with `"default"`: - -```python -# v5 -PhoneProviderProtectionBackoffStrategyEnum = typing.Union[typing.Literal["exponential", "none"], typing.Any] -``` - -```python -# v6 -PhoneProviderProtectionBackoffStrategyEnum = typing.Union[typing.Literal["exponential", "default"], typing.Any] -``` - -Replace any use of `"none"` with `"default"`. - -### `ListRolesOffsetPaginatedResponseContent` pagination fields now required - -`start`, `limit`, and `total` are no longer optional: - -```python -# v5 -start: typing.Optional[float] = None -limit: typing.Optional[float] = None -total: typing.Optional[float] = None -``` - -```python -# v6 -start: float -limit: float -total: float -``` - -Deserializing a role-list response that is missing any of these fields now -raises `pydantic.ValidationError` instead of silently defaulting to `None`. -This matches the Management API, which always returns these fields for this -endpoint. diff --git a/reference.md b/reference.md index 4697293c..cd3c9dcb 100644 --- a/reference.md +++ b/reference.md @@ -2514,6 +2514,14 @@ See https://auth0.com/docs/secure/security-guidance/measures-against-app-imperso
+**oidc_support:** `typing.Optional[ClientOidcSupportPost]` + +
+
+ +
+
+ **request_options:** `typing.Optional[RequestOptions]` — Request-specific configuration.
@@ -12772,509 +12780,7 @@ client.resource_servers.create(
-**authorization_details:** `typing.Optional[typing.List[typing.Any]]` - -
-
- -
-
- -**proof_of_possession:** `typing.Optional[ResourceServerProofOfPossession]` - -
-
- -
-
- -**subject_type_authorization:** `typing.Optional[ResourceServerSubjectTypeAuthorization]` - -
-
- -
-
- -**authorization_policy:** `typing.Optional[ResourceServerAuthorizationPolicy]` - -
-
- -
-
- -**request_options:** `typing.Optional[RequestOptions]` — Request-specific configuration. - -
-
- -
- - - - - - -
client.resource_servers.search(...) -> SearchResourceServersResponseContent -
-
- -#### 📝 Description - -
-
- -
-
- -Search resource servers using SCIM or Lucene filter syntax with low-latency, eventually consistent results. Use the parser parameter to specify "scim" or "lucene" syntax (default: "lucene"). This endpoint provides an alternative to the standard GET /resource-servers endpoint with better performance for complex queries. -Results may not reflect recent updates immediately. - -The `signing_secret` field is not supported by this endpoint. -
-
-
-
- -#### 🔌 Usage - -
-
- -
-
- -```python -from auth0.management import Auth0 -from auth0.management.environment import Auth0Environment - -client = Auth0( - token="", - environment=Auth0Environment.DEFAULT, -) - -client.resource_servers.search( - q="q", - parser="scim", - fields="fields", - include_fields=True, - take=1, - from_="from", - sort="identifier", -) - -``` -
-
-
-
- -#### ⚙️ Parameters - -
-
- -
-
- -**q:** `typing.Optional[str]` — Filter expression in SCIM or Lucene syntax (depending on parser parameter). SCIM examples: `name eq "My API"`, `identifier sw "https://"`. SCIM operators: eq, ne, sw, ew, co, pr, gt, ge, lt, le, and, or.

Supported Fields:
  • id - Filter by resource server ID
  • identifier - Filter by resource server identifier
  • name - Filter by resource server name
  • updated_at - Filter by last update date
Maximum 5 filter operations per query. Results are eventually consistent and may not reflect recent updates. - -
-
- -
-
- -**parser:** `typing.Optional[SearchParserEnum]` — Query parser to use for the filter expression. Use "scim" for SCIM filter syntax or "lucene" for Lucene query syntax (default). - -
-
- -
-
- -**fields:** `typing.Optional[str]` — Comma-separated list of fields to include or exclude in the response. Works with the include_fields parameter to control projection mode. - -
-
- -
-
- -**include_fields:** `typing.Optional[bool]` — Controls field projection mode. Set to true to include only fields specified in the fields parameter. Set to false to exclude fields specified in the fields parameter. Defaults to true if not specified. - -
-
- -
-
- -**take:** `typing.Optional[int]` — Maximum number of results to return per page (1-100). Defaults to 50. - -
-
- -
-
- -**from:** `typing.Optional[str]` — Cursor for the next page of results. Use the value from the next field in the previous response. - -
-
- -
-
- -**sort:** `typing.Optional[ResourceServerSortFieldEnum]` — Field name to sort results by in ascending order only. Defaults to insertion order (oldest first) if not provided. - -
-
- -
-
- -**request_options:** `typing.Optional[RequestOptions]` — Request-specific configuration. - -
-
-
-
- - -
-
-
- -
client.resource_servers.get(...) -> GetResourceServerResponseContent -
-
- -#### 📝 Description - -
-
- -
-
- -Retrieve API details with the given ID. -
-
-
-
- -#### 🔌 Usage - -
-
- -
-
- -```python -from auth0.management import Auth0 -from auth0.management.environment import Auth0Environment - -client = Auth0( - token="", - environment=Auth0Environment.DEFAULT, -) - -client.resource_servers.get( - id="id", - include_fields=True, -) - -``` -
-
-
-
- -#### ⚙️ Parameters - -
-
- -
-
- -**id:** `str` — ID or audience of the resource server to retrieve. - -
-
- -
-
- -**include_fields:** `typing.Optional[bool]` — Whether specified fields are to be included (true) or excluded (false). - -
-
- -
-
- -**request_options:** `typing.Optional[RequestOptions]` — Request-specific configuration. - -
-
-
-
- - -
-
-
- -
client.resource_servers.delete(...) -
-
- -#### 📝 Description - -
-
- -
-
- -Delete an existing API by ID. For more information, read API Settings. -
-
-
-
- -#### 🔌 Usage - -
-
- -
-
- -```python -from auth0.management import Auth0 -from auth0.management.environment import Auth0Environment - -client = Auth0( - token="", - environment=Auth0Environment.DEFAULT, -) - -client.resource_servers.delete( - id="id", -) - -``` -
-
-
-
- -#### ⚙️ Parameters - -
-
- -
-
- -**id:** `str` — ID or the audience of the resource server to delete. - -
-
- -
-
- -**request_options:** `typing.Optional[RequestOptions]` — Request-specific configuration. - -
-
-
-
- - -
-
-
- -
client.resource_servers.update(...) -> UpdateResourceServerResponseContent -
-
- -#### 📝 Description - -
-
- -
-
- -Change an existing API setting by resource server ID. For more information, read API Settings. -
-
-
-
- -#### 🔌 Usage - -
-
- -
-
- -```python -from auth0.management import Auth0 -from auth0.management.environment import Auth0Environment - -client = Auth0( - token="", - environment=Auth0Environment.DEFAULT, -) - -client.resource_servers.update( - id="id", -) - -``` -
-
-
-
- -#### ⚙️ Parameters - -
-
- -
-
- -**id:** `str` — ID or audience of the resource server to update. - -
-
- -
-
- -**name:** `typing.Optional[str]` — Friendly name for this resource server. Can not contain `<` or `>` characters. - -
-
- -
-
- -**scopes:** `typing.Optional[typing.List[ResourceServerScope]]` — List of permissions (scopes) that this API uses. - -
-
- -
-
- -**signing_alg:** `typing.Optional[SigningAlgorithmEnum]` - -
-
- -
-
- -**signing_secret:** `typing.Optional[str]` — Secret used to sign tokens when using symmetric algorithms (HS256). - -
-
- -
-
- -**skip_consent_for_verifiable_first_party_clients:** `typing.Optional[bool]` — Whether to skip user consent for applications flagged as first party (true) or not (false). - -
-
- -
-
- -**allow_offline_access:** `typing.Optional[bool]` — Whether refresh tokens can be issued for this API (true) or not (false). - -
-
- -
-
- -**allow_online_access:** `typing.Optional[bool]` — Whether Online Refresh Tokens can be issued for this API (true) or not (false). - -
-
- -
-
- -**allow_online_access_with_ephemeral_sessions:** `typing.Optional[bool]` — Whether Online Refresh Tokens can be issued even when sessions are configured as ephemeral (true) or not (false). - -
-
- -
-
- -**token_lifetime:** `typing.Optional[int]` — Expiration value (in seconds) for access tokens issued for this API from the token endpoint. - -
-
- -
-
- -**token_lifetime_for_anonymous_access_tokens:** `typing.Optional[int]` — Expiration value (in seconds) for anonymous-session access tokens issued for this API. - -
-
- -
-
- -**token_dialect:** `typing.Optional[ResourceServerTokenDialectSchemaEnum]` - -
-
- -
-
- -**enforce_policies:** `typing.Optional[bool]` — Whether authorization policies are enforced (true) or not enforced (false). - -
-
- -
-
- -**access_token:** `typing.Optional[ResourceServerAccessToken]` - -
-
- -
-
- -**token_encryption:** `typing.Optional[ResourceServerTokenEncryption]` - -
-
- -
-
- -**consent_policy:** `typing.Optional[ResourceServerConsentPolicyEnum]` +**require_consent_non_repudiation:** `typing.Optional[bool]` — When true, the resource server requires every consent approval to be digitally signed, so the approver cannot later deny a consent they granted. When false, consent decisions do not need a signature. Defaults to false. A configured value is still returned even after the related entitlement is disabled.
@@ -13326,8 +12832,7 @@ client.resource_servers.update(
-## Roles -
client.roles.list(...) -> ListRolesOffsetPaginatedResponseContent +
client.resource_servers.search(...) -> SearchResourceServersResponseContent
@@ -13339,9 +12844,10 @@ client.resource_servers.update(
-Retrieve detailed list of user roles created in your tenant. +Search resource servers using SCIM or Lucene filter syntax with low-latency, eventually consistent results. Use the parser parameter to specify "scim" or "lucene" syntax (default: "lucene"). This endpoint provides an alternative to the standard GET /resource-servers endpoint with better performance for complex queries. +Results may not reflect recent updates immediately. -**Note**: The returned list does not include standard roles available for tenant members, such as Admin or Support Access. +The `signing_secret` field is not supported by this endpoint.
@@ -13364,13 +12870,14 @@ client = Auth0( environment=Auth0Environment.DEFAULT, ) -client.roles.list( - per_page=1, - page=1, - include_totals=True, - name_filter="name_filter", - type="tenant", - owner_id="owner_id", +client.resource_servers.search( + q="q", + parser="scim", + fields="fields", + include_fields=True, + take=1, + from_="from", + sort="identifier", ) ``` @@ -13387,7 +12894,7 @@ client.roles.list(
-**per_page:** `typing.Optional[int]` — Number of results per page. Defaults to 50. +**q:** `typing.Optional[str]` — Filter expression in SCIM or Lucene syntax (depending on parser parameter). SCIM examples: `name eq "My API"`, `identifier sw "https://"`. SCIM operators: eq, ne, sw, ew, co, pr, gt, ge, lt, le, and, or.

Supported Fields:
  • id - Filter by resource server ID
  • identifier - Filter by resource server identifier
  • name - Filter by resource server name
  • updated_at - Filter by last update date
Maximum 5 filter operations per query. Results are eventually consistent and may not reflect recent updates.
@@ -13395,7 +12902,7 @@ client.roles.list(
-**page:** `typing.Optional[int]` — Page index of the results to return. First page is 0. +**parser:** `typing.Optional[SearchParserEnum]` — Query parser to use for the filter expression. Use "scim" for SCIM filter syntax or "lucene" for Lucene query syntax (default).
@@ -13403,7 +12910,7 @@ client.roles.list(
-**include_totals:** `typing.Optional[bool]` — Return results inside an object that contains the total result count (true) or as a direct array of results (false, default). +**fields:** `typing.Optional[str]` — Comma-separated list of fields to include or exclude in the response. Works with the include_fields parameter to control projection mode.
@@ -13411,7 +12918,7 @@ client.roles.list(
-**name_filter:** `typing.Optional[str]` — Optional filter on name (case-insensitive). +**include_fields:** `typing.Optional[bool]` — Controls field projection mode. Set to true to include only fields specified in the fields parameter. Set to false to exclude fields specified in the fields parameter. Defaults to true if not specified.
@@ -13419,7 +12926,7 @@ client.roles.list(
-**type:** `typing.Optional[RoleTypeEnum]` — Optional filter on the type of the role +**take:** `typing.Optional[int]` — Maximum number of results to return per page (1-100). Defaults to 50.
@@ -13427,7 +12934,15 @@ client.roles.list(
-**owner_id:** `typing.Optional[str]` — Filter organization-level roles by owner ID. Required when type is "organization". +**from:** `typing.Optional[str]` — Cursor for the next page of results. Use the value from the next field in the previous response. + +
+
+ +
+
+ +**sort:** `typing.Optional[ResourceServerSortFieldEnum]` — Field name to sort results by in ascending order only. Defaults to insertion order (oldest first) if not provided.
@@ -13447,7 +12962,7 @@ client.roles.list(
-
client.roles.create(...) -> CreateRoleResponseContent +
client.resource_servers.get(...) -> GetResourceServerResponseContent
@@ -13459,9 +12974,7 @@ client.roles.list(
-Create a user role for [Role-Based Access Control](https://auth0.com/docs/manage-users/access-control/rbac). - -**Note**: New roles are not associated with any permissions by default. To assign existing permissions to your role, review Associate Permissions with a Role. To create new permissions, review Add API Permissions. +Retrieve API details with the given ID.
@@ -13484,8 +12997,9 @@ client = Auth0( environment=Auth0Environment.DEFAULT, ) -client.roles.create( - name="name", +client.resource_servers.get( + id="id", + include_fields=True, ) ``` @@ -13502,23 +13016,7 @@ client.roles.create(
-**name:** `str` — Name of the role. - -
-
- -
-
- -**description:** `typing.Optional[str]` — Description of the role. - -
-
- -
-
- -**type:** `typing.Optional[RoleTypeEnum]` — The type of the role. Defaults to tenant. +**id:** `str` — ID or audience of the resource server to retrieve.
@@ -13526,7 +13024,7 @@ client.roles.create(
-**owner_id:** `typing.Optional[str]` — The ID of the organization that owns this role. Required when type is "organization". +**include_fields:** `typing.Optional[bool]` — Whether specified fields are to be included (true) or excluded (false).
@@ -13546,7 +13044,7 @@ client.roles.create(
-
client.roles.get(...) -> GetRoleResponseContent +
client.resource_servers.delete(...)
@@ -13558,7 +13056,7 @@ client.roles.create(
-Retrieve details about a specific [user role](https://auth0.com/docs/manage-users/access-control/rbac) specified by ID. +Delete an existing API by ID. For more information, read API Settings.
@@ -13581,7 +13079,7 @@ client = Auth0( environment=Auth0Environment.DEFAULT, ) -client.roles.get( +client.resource_servers.delete( id="id", ) @@ -13599,7 +13097,7 @@ client.roles.get(
-**id:** `str` — ID of the role to retrieve. +**id:** `str` — ID or the audience of the resource server to delete.
@@ -13619,7 +13117,7 @@ client.roles.get(
-
client.roles.delete(...) +
client.resource_servers.update(...) -> UpdateResourceServerResponseContent
@@ -13631,7 +13129,7 @@ client.roles.get(
-Delete a specific [user role](https://auth0.com/docs/manage-users/access-control/rbac) from your tenant. Once deleted, it is removed from any user who was previously assigned that role. This action cannot be undone. +Change an existing API setting by resource server ID. For more information, read API Settings.
@@ -13654,7 +13152,7 @@ client = Auth0( environment=Auth0Environment.DEFAULT, ) -client.roles.delete( +client.resource_servers.update( id="id", ) @@ -13672,7 +13170,7 @@ client.roles.delete(
-**id:** `str` — ID of the role to delete. +**id:** `str` — ID or audience of the resource server to update.
@@ -13680,72 +13178,47 @@ client.roles.delete(
-**request_options:** `typing.Optional[RequestOptions]` — Request-specific configuration. +**name:** `typing.Optional[str]` — Friendly name for this resource server. Can not contain `<` or `>` characters.
- -
+
+
+**scopes:** `typing.Optional[typing.List[ResourceServerScope]]` — List of permissions (scopes) that this API uses. +
-
-
client.roles.update(...) -> UpdateRoleResponseContent
-#### 📝 Description - -
-
+**signing_alg:** `typing.Optional[SigningAlgorithmEnum]` + +
+
-Modify the details of a specific [user role](https://auth0.com/docs/manage-users/access-control/rbac) specified by ID. -
-
+**signing_secret:** `typing.Optional[str]` — Secret used to sign tokens when using symmetric algorithms (HS256). +
-#### 🔌 Usage -
-
-
- -```python -from auth0.management import Auth0 -from auth0.management.environment import Auth0Environment - -client = Auth0( - token="", - environment=Auth0Environment.DEFAULT, -) - -client.roles.update( - id="id", -) - -``` -
-
+**skip_consent_for_verifiable_first_party_clients:** `typing.Optional[bool]` — Whether to skip user consent for applications flagged as first party (true) or not (false). +
-#### ⚙️ Parameters - -
-
-
-**id:** `str` — ID of the role to update. +**allow_offline_access:** `typing.Optional[bool]` — Whether refresh tokens can be issued for this API (true) or not (false).
@@ -13753,7 +13226,7 @@ client.roles.update(
-**name:** `typing.Optional[str]` — Name of this role. +**allow_online_access:** `typing.Optional[bool]` — Whether Online Refresh Tokens can be issued for this API (true) or not (false).
@@ -13761,7 +13234,7 @@ client.roles.update(
-**description:** `typing.Optional[str]` — Description of this role. +**allow_online_access_with_ephemeral_sessions:** `typing.Optional[bool]` — Whether Online Refresh Tokens can be issued even when sessions are configured as ephemeral (true) or not (false).
@@ -13769,78 +13242,55 @@ client.roles.update(
-**request_options:** `typing.Optional[RequestOptions]` — Request-specific configuration. +**token_lifetime:** `typing.Optional[int]` — Expiration value (in seconds) for access tokens issued for this API from the token endpoint.
-
-
+
+
+**token_lifetime_for_anonymous_access_tokens:** `typing.Optional[int]` — Expiration value (in seconds) for anonymous-session access tokens issued for this API. +
-
-## Rules -
client.rules.list(...) -> ListRulesOffsetPaginatedResponseContent
-#### 📝 Description - -
-
+**token_dialect:** `typing.Optional[ResourceServerTokenDialectSchemaEnum]` + +
+
-Retrieve a filtered list of [rules](https://auth0.com/docs/rules). Accepts a list of fields to include or exclude. -
-
+**enforce_policies:** `typing.Optional[bool]` — Whether authorization policies are enforced (true) or not enforced (false). +
-#### 🔌 Usage -
-
-
- -```python -from auth0.management import Auth0 -from auth0.management.environment import Auth0Environment - -client = Auth0( - token="", - environment=Auth0Environment.DEFAULT, -) - -client.rules.list( - page=1, - per_page=1, - include_totals=True, - enabled=True, - fields="fields", - include_fields=True, -) - -``` -
-
+**access_token:** `typing.Optional[ResourceServerAccessToken]` +
-#### ⚙️ Parameters -
+**token_encryption:** `typing.Optional[ResourceServerTokenEncryption]` + +
+
+
-**page:** `typing.Optional[int]` — Page index of the results to return. First page is 0. +**consent_policy:** `typing.Optional[ResourceServerConsentPolicyEnum]`
@@ -13848,7 +13298,7 @@ client.rules.list(
-**per_page:** `typing.Optional[int]` — Number of results per page. +**require_consent_non_repudiation:** `typing.Optional[bool]` — When true, the resource server requires every consent approval to be digitally signed, so the approver cannot later deny a consent they granted. When false, consent decisions do not need a signature. Defaults to false. A configured value is still returned even after the related entitlement is disabled.
@@ -13856,7 +13306,7 @@ client.rules.list(
-**include_totals:** `typing.Optional[bool]` — Return results inside an object that contains the total result count (true) or as a direct array of results (false, default). +**authorization_details:** `typing.Optional[typing.List[typing.Any]]`
@@ -13864,7 +13314,7 @@ client.rules.list(
-**enabled:** `typing.Optional[bool]` — Optional filter on whether a rule is enabled (true) or disabled (false). +**proof_of_possession:** `typing.Optional[ResourceServerProofOfPossession]`
@@ -13872,7 +13322,7 @@ client.rules.list(
-**fields:** `typing.Optional[str]` — Comma-separated list of fields to include or exclude (based on value provided for include_fields) in the result. Leave empty to retrieve all fields. +**subject_type_authorization:** `typing.Optional[ResourceServerSubjectTypeAuthorization]`
@@ -13880,7 +13330,7 @@ client.rules.list(
-**include_fields:** `typing.Optional[bool]` — Whether specified fields are to be included (true) or excluded (false). +**authorization_policy:** `typing.Optional[ResourceServerAuthorizationPolicy]`
@@ -13900,7 +13350,8 @@ client.rules.list(
-
client.rules.create(...) -> CreateRuleResponseContent +## Roles +
client.roles.list(...) -> ListRolesOffsetPaginatedResponseContent
@@ -13912,9 +13363,9 @@ client.rules.list(
-Create a [new rule](https://auth0.com/docs/rules#create-a-new-rule-using-the-management-api). +Retrieve detailed list of user roles created in your tenant. -Note: Changing a rule's stage of execution from the default `login_success` can change the rule's function signature to have user omitted. +**Note**: The returned list does not include standard roles available for tenant members, such as Admin or Support Access.
@@ -13937,9 +13388,13 @@ client = Auth0( environment=Auth0Environment.DEFAULT, ) -client.rules.create( - name="name", - script="script", +client.roles.list( + per_page=1, + page=1, + include_totals=True, + name_filter="name_filter", + type="tenant", + owner_id="owner_id", ) ``` @@ -13956,7 +13411,7 @@ client.rules.create(
-**name:** `str` — Name of this rule. +**per_page:** `typing.Optional[int]` — Number of results per page. Defaults to 50.
@@ -13964,7 +13419,7 @@ client.rules.create(
-**script:** `str` — Code to be executed when this rule runs. +**page:** `typing.Optional[int]` — Page index of the results to return. First page is 0.
@@ -13972,7 +13427,7 @@ client.rules.create(
-**order:** `typing.Optional[float]` — Order that this rule should execute in relative to other rules. Lower-valued rules execute first. +**include_totals:** `typing.Optional[bool]` — Return results inside an object that contains the total result count (true) or as a direct array of results (false, default).
@@ -13980,7 +13435,23 @@ client.rules.create(
-**enabled:** `typing.Optional[bool]` — Whether the rule is enabled (true), or disabled (false). +**name_filter:** `typing.Optional[str]` — Optional filter on name (case-insensitive). + +
+
+ +
+
+ +**type:** `typing.Optional[RoleTypeEnum]` — Optional filter on the type of the role + +
+
+ +
+
+ +**owner_id:** `typing.Optional[str]` — Filter organization-level roles by owner ID. Required when type is "organization".
@@ -14000,7 +13471,7 @@ client.rules.create(
-
client.rules.get(...) -> GetRuleResponseContent +
client.roles.create(...) -> CreateRoleResponseContent
@@ -14012,7 +13483,9 @@ client.rules.create(
-Retrieve [rule](https://auth0.com/docs/rules) details. Accepts a list of fields to include or exclude in the result. +Create a user role for [Role-Based Access Control](https://auth0.com/docs/manage-users/access-control/rbac). + +**Note**: New roles are not associated with any permissions by default. To assign existing permissions to your role, review Associate Permissions with a Role. To create new permissions, review Add API Permissions.
@@ -14035,10 +13508,8 @@ client = Auth0( environment=Auth0Environment.DEFAULT, ) -client.rules.get( - id="id", - fields="fields", - include_fields=True, +client.roles.create( + name="name", ) ``` @@ -14055,7 +13526,7 @@ client.rules.get(
-**id:** `str` — ID of the rule to retrieve. +**name:** `str` — Name of the role.
@@ -14063,7 +13534,7 @@ client.rules.get(
-**fields:** `typing.Optional[str]` — Comma-separated list of fields to include or exclude (based on value provided for include_fields) in the result. Leave empty to retrieve all fields. +**description:** `typing.Optional[str]` — Description of the role.
@@ -14071,7 +13542,15 @@ client.rules.get(
-**include_fields:** `typing.Optional[bool]` — Whether specified fields are to be included (true) or excluded (false). +**type:** `typing.Optional[RoleTypeEnum]` — The type of the role. Defaults to tenant. + +
+
+ +
+
+ +**owner_id:** `typing.Optional[str]` — The ID of the organization that owns this role. Required when type is "organization".
@@ -14091,7 +13570,7 @@ client.rules.get(
-
client.rules.delete(...) +
client.roles.get(...) -> GetRoleResponseContent
@@ -14103,7 +13582,7 @@ client.rules.get(
-Delete a rule. +Retrieve details about a specific [user role](https://auth0.com/docs/manage-users/access-control/rbac) specified by ID.
@@ -14126,7 +13605,7 @@ client = Auth0( environment=Auth0Environment.DEFAULT, ) -client.rules.delete( +client.roles.get( id="id", ) @@ -14144,7 +13623,7 @@ client.rules.delete(
-**id:** `str` — ID of the rule to delete. +**id:** `str` — ID of the role to retrieve.
@@ -14164,7 +13643,7 @@ client.rules.delete(
-
client.rules.update(...) -> UpdateRuleResponseContent +
client.roles.delete(...)
@@ -14176,7 +13655,7 @@ client.rules.delete(
-Update an existing rule. +Delete a specific [user role](https://auth0.com/docs/manage-users/access-control/rbac) from your tenant. Once deleted, it is removed from any user who was previously assigned that role. This action cannot be undone.
@@ -14199,7 +13678,7 @@ client = Auth0( environment=Auth0Environment.DEFAULT, ) -client.rules.update( +client.roles.delete( id="id", ) @@ -14217,7 +13696,7 @@ client.rules.update(
-**id:** `str` — ID of the rule to retrieve. +**id:** `str` — ID of the role to delete.
@@ -14225,15 +13704,72 @@ client.rules.update(
-**script:** `typing.Optional[str]` — Code to be executed when this rule runs. +**request_options:** `typing.Optional[RequestOptions]` — Request-specific configuration.
+ +
+ + + + +
+
client.roles.update(...) -> UpdateRoleResponseContent
-**name:** `typing.Optional[str]` — Name of this rule. +#### 📝 Description + +
+
+ +
+
+ +Modify the details of a specific [user role](https://auth0.com/docs/manage-users/access-control/rbac) specified by ID. +
+
+
+
+ +#### 🔌 Usage + +
+
+ +
+
+ +```python +from auth0.management import Auth0 +from auth0.management.environment import Auth0Environment + +client = Auth0( + token="", + environment=Auth0Environment.DEFAULT, +) + +client.roles.update( + id="id", +) + +``` +
+
+
+
+ +#### ⚙️ Parameters + +
+
+ +
+
+ +**id:** `str` — ID of the role to update.
@@ -14241,7 +13777,7 @@ client.rules.update(
-**order:** `typing.Optional[float]` — Order that this rule should execute in relative to other rules. Lower-valued rules execute first. +**name:** `typing.Optional[str]` — Name of this role.
@@ -14249,7 +13785,7 @@ client.rules.update(
-**enabled:** `typing.Optional[bool]` — Whether the rule is enabled (true), or disabled (false). +**description:** `typing.Optional[str]` — Description of this role.
@@ -14269,8 +13805,8 @@ client.rules.update(
-## RulesConfigs -
client.rules_configs.list() -> typing.List[RulesConfig] +## Rules +
client.rules.list(...) -> ListRulesOffsetPaginatedResponseContent
@@ -14282,9 +13818,7 @@ client.rules.update(
-Retrieve rules config variable keys. - - Note: For security, config variable values cannot be retrieved outside rule execution. +Retrieve a filtered list of [rules](https://auth0.com/docs/rules). Accepts a list of fields to include or exclude.
@@ -14307,7 +13841,14 @@ client = Auth0( environment=Auth0Environment.DEFAULT, ) -client.rules_configs.list() +client.rules.list( + page=1, + per_page=1, + include_totals=True, + enabled=True, + fields="fields", + include_fields=True, +) ``` @@ -14323,6 +13864,54 @@ client.rules_configs.list()
+**page:** `typing.Optional[int]` — Page index of the results to return. First page is 0. + +
+
+ +
+
+ +**per_page:** `typing.Optional[int]` — Number of results per page. + +
+
+ +
+
+ +**include_totals:** `typing.Optional[bool]` — Return results inside an object that contains the total result count (true) or as a direct array of results (false, default). + +
+
+ +
+
+ +**enabled:** `typing.Optional[bool]` — Optional filter on whether a rule is enabled (true) or disabled (false). + +
+
+ +
+
+ +**fields:** `typing.Optional[str]` — Comma-separated list of fields to include or exclude (based on value provided for include_fields) in the result. Leave empty to retrieve all fields. + +
+
+ +
+
+ +**include_fields:** `typing.Optional[bool]` — Whether specified fields are to be included (true) or excluded (false). + +
+
+ +
+
+ **request_options:** `typing.Optional[RequestOptions]` — Request-specific configuration.
@@ -14335,7 +13924,7 @@ client.rules_configs.list()
-
client.rules_configs.set(...) -> SetRulesConfigResponseContent +
client.rules.create(...) -> CreateRuleResponseContent
@@ -14347,7 +13936,9 @@ client.rules_configs.list()
-Sets a rules config variable. +Create a [new rule](https://auth0.com/docs/rules#create-a-new-rule-using-the-management-api). + +Note: Changing a rule's stage of execution from the default `login_success` can change the rule's function signature to have user omitted.
@@ -14370,9 +13961,9 @@ client = Auth0( environment=Auth0Environment.DEFAULT, ) -client.rules_configs.set( - key="key", - value="value", +client.rules.create( + name="name", + script="script", ) ``` @@ -14389,7 +13980,7 @@ client.rules_configs.set(
-**key:** `str` — Key of the rules config variable to set (max length: 127 characters). +**name:** `str` — Name of this rule.
@@ -14397,7 +13988,23 @@ client.rules_configs.set(
-**value:** `str` — Value for a rules config variable. +**script:** `str` — Code to be executed when this rule runs. + +
+
+ +
+
+ +**order:** `typing.Optional[float]` — Order that this rule should execute in relative to other rules. Lower-valued rules execute first. + +
+
+ +
+
+ +**enabled:** `typing.Optional[bool]` — Whether the rule is enabled (true), or disabled (false).
@@ -14417,7 +14024,7 @@ client.rules_configs.set(
-
client.rules_configs.delete(...) +
client.rules.get(...) -> GetRuleResponseContent
@@ -14429,7 +14036,7 @@ client.rules_configs.set(
-Delete a rules config variable identified by its key. +Retrieve [rule](https://auth0.com/docs/rules) details. Accepts a list of fields to include or exclude in the result.
@@ -14452,8 +14059,10 @@ client = Auth0( environment=Auth0Environment.DEFAULT, ) -client.rules_configs.delete( - key="key", +client.rules.get( + id="id", + fields="fields", + include_fields=True, ) ``` @@ -14470,7 +14079,23 @@ client.rules_configs.delete(
-**key:** `str` — Key of the rules config variable to delete. +**id:** `str` — ID of the rule to retrieve. + +
+
+ +
+
+ +**fields:** `typing.Optional[str]` — Comma-separated list of fields to include or exclude (based on value provided for include_fields) in the result. Leave empty to retrieve all fields. + +
+
+ +
+
+ +**include_fields:** `typing.Optional[bool]` — Whether specified fields are to be included (true) or excluded (false).
@@ -14490,8 +14115,7 @@ client.rules_configs.delete(
-## SelfServiceProfiles -
client.self_service_profiles.list(...) -> ListSelfServiceProfilesPaginatedResponseContent +
client.rules.delete(...)
@@ -14503,7 +14127,7 @@ client.rules_configs.delete(
-Retrieves self-service profiles. +Delete a rule.
@@ -14526,10 +14150,8 @@ client = Auth0( environment=Auth0Environment.DEFAULT, ) -client.self_service_profiles.list( - page=1, - per_page=1, - include_totals=True, +client.rules.delete( + id="id", ) ``` @@ -14546,23 +14168,7 @@ client.self_service_profiles.list(
-**page:** `typing.Optional[int]` — Page index of the results to return. First page is 0. - -
-
- -
-
- -**per_page:** `typing.Optional[int]` — Number of results per page. Defaults to 50. - -
-
- -
-
- -**include_totals:** `typing.Optional[bool]` — Return results inside an object that contains the total result count (true) or as a direct array of results (false, default). +**id:** `str` — ID of the rule to delete.
@@ -14582,7 +14188,7 @@ client.self_service_profiles.list(
-
client.self_service_profiles.create(...) -> CreateSelfServiceProfileResponseContent +
client.rules.update(...) -> UpdateRuleResponseContent
@@ -14594,7 +14200,7 @@ client.self_service_profiles.list(
-Creates a self-service profile. +Update an existing rule.
@@ -14617,8 +14223,8 @@ client = Auth0( environment=Auth0Environment.DEFAULT, ) -client.self_service_profiles.create( - name="name", +client.rules.update( + id="id", ) ``` @@ -14635,15 +14241,7 @@ client.self_service_profiles.create(
-**name:** `str` — The name of the self-service Profile. - -
-
- -
-
- -**description:** `typing.Optional[str]` — The description of the self-service Profile. +**id:** `str` — ID of the rule to retrieve.
@@ -14651,7 +14249,7 @@ client.self_service_profiles.create(
-**branding:** `typing.Optional[SelfServiceProfileBrandingProperties]` +**script:** `typing.Optional[str]` — Code to be executed when this rule runs.
@@ -14659,7 +14257,7 @@ client.self_service_profiles.create(
-**allowed_strategies:** `typing.Optional[typing.List[SelfServiceProfileAllowedStrategyEnum]]` — List of IdP strategies that will be shown to users during the Self-Service Enterprise Configuration flow. Possible values: [`oidc`, `samlp`, `waad`, `google-apps`, `adfs`, `okta`, `auth0-samlp`, `okta-samlp`, `keycloak-samlp`, `pingfederate`] +**name:** `typing.Optional[str]` — Name of this rule.
@@ -14667,7 +14265,7 @@ client.self_service_profiles.create(
-**user_attributes:** `typing.Optional[typing.List[SelfServiceProfileUserAttribute]]` — List of attributes to be mapped that will be shown to the user during the Self-Service Enterprise Configuration flow. +**order:** `typing.Optional[float]` — Order that this rule should execute in relative to other rules. Lower-valued rules execute first.
@@ -14675,7 +14273,7 @@ client.self_service_profiles.create(
-**user_attribute_profile_id:** `typing.Optional[str]` — ID of the user-attribute-profile to associate with this self-service profile. +**enabled:** `typing.Optional[bool]` — Whether the rule is enabled (true), or disabled (false).
@@ -14695,7 +14293,8 @@ client.self_service_profiles.create(
-
client.self_service_profiles.get(...) -> GetSelfServiceProfileResponseContent +## RulesConfigs +
client.rules_configs.list() -> typing.List[RulesConfig]
@@ -14707,7 +14306,9 @@ client.self_service_profiles.create(
-Retrieves a self-service profile by Id. +Retrieve rules config variable keys. + + Note: For security, config variable values cannot be retrieved outside rule execution.
@@ -14730,9 +14331,7 @@ client = Auth0( environment=Auth0Environment.DEFAULT, ) -client.self_service_profiles.get( - id="id", -) +client.rules_configs.list() ``` @@ -14748,14 +14347,6 @@ client.self_service_profiles.get(
-**id:** `str` — The id of the self-service profile to retrieve - -
-
- -
-
- **request_options:** `typing.Optional[RequestOptions]` — Request-specific configuration.
@@ -14768,7 +14359,7 @@ client.self_service_profiles.get(
-
client.self_service_profiles.delete(...) +
client.rules_configs.set(...) -> SetRulesConfigResponseContent
@@ -14780,7 +14371,7 @@ client.self_service_profiles.get(
-Deletes a self-service profile by Id. +Sets a rules config variable.
@@ -14803,8 +14394,9 @@ client = Auth0( environment=Auth0Environment.DEFAULT, ) -client.self_service_profiles.delete( - id="id", +client.rules_configs.set( + key="key", + value="value", ) ``` @@ -14821,7 +14413,15 @@ client.self_service_profiles.delete(
-**id:** `str` — The id of the self-service profile to delete +**key:** `str` — Key of the rules config variable to set (max length: 127 characters). + +
+
+ +
+
+ +**value:** `str` — Value for a rules config variable.
@@ -14841,7 +14441,7 @@ client.self_service_profiles.delete(
-
client.self_service_profiles.update(...) -> UpdateSelfServiceProfileResponseContent +
client.rules_configs.delete(...)
@@ -14853,7 +14453,7 @@ client.self_service_profiles.delete(
-Updates a self-service profile. +Delete a rules config variable identified by its key.
@@ -14876,8 +14476,8 @@ client = Auth0( environment=Auth0Environment.DEFAULT, ) -client.self_service_profiles.update( - id="id", +client.rules_configs.delete( + key="key", ) ``` @@ -14894,55 +14494,7 @@ client.self_service_profiles.update(
-**id:** `str` — The id of the self-service profile to update - -
-
- -
-
- -**name:** `typing.Optional[str]` — The name of the self-service Profile. - -
-
- -
-
- -**description:** `typing.Optional[SelfServiceProfileDescription]` - -
-
- -
-
- -**branding:** `typing.Optional[SelfServiceProfileBranding]` - -
-
- -
-
- -**allowed_strategies:** `typing.Optional[typing.List[SelfServiceProfileAllowedStrategyEnum]]` — List of IdP strategies that will be shown to users during the Self-Service Enterprise Configuration flow. Possible values: [`oidc`, `samlp`, `waad`, `google-apps`, `adfs`, `okta`, `auth0-samlp`, `okta-samlp`, `keycloak-samlp`, `pingfederate`] - -
-
- -
-
- -**user_attributes:** `typing.Optional[SelfServiceProfileUserAttributes]` - -
-
- -
-
- -**user_attribute_profile_id:** `typing.Optional[str]` — ID of the user-attribute-profile to associate with this self-service profile. +**key:** `str` — Key of the rules config variable to delete.
@@ -14962,8 +14514,8 @@ client.self_service_profiles.update(
-## Sessions -
client.sessions.get(...) -> GetSessionResponseContent +## SelfServiceProfiles +
client.self_service_profiles.list(...) -> ListSelfServiceProfilesPaginatedResponseContent
@@ -14975,7 +14527,7 @@ client.self_service_profiles.update(
-Retrieve session information. +Retrieves self-service profiles.
@@ -14998,8 +14550,10 @@ client = Auth0( environment=Auth0Environment.DEFAULT, ) -client.sessions.get( - id="id", +client.self_service_profiles.list( + page=1, + per_page=1, + include_totals=True, ) ``` @@ -15016,7 +14570,7 @@ client.sessions.get(
-**id:** `str` — ID of session to retrieve +**page:** `typing.Optional[int]` — Page index of the results to return. First page is 0.
@@ -15024,72 +14578,15 @@ client.sessions.get(
-**request_options:** `typing.Optional[RequestOptions]` — Request-specific configuration. +**per_page:** `typing.Optional[int]` — Number of results per page. Defaults to 50.
- -
- - - - -
- -
client.sessions.delete(...) -
-
- -#### 📝 Description - -
-
- -
-
- -Delete a session by ID. -
-
-
-
- -#### 🔌 Usage - -
-
- -
-
- -```python -from auth0.management import Auth0 -from auth0.management.environment import Auth0Environment - -client = Auth0( - token="", - environment=Auth0Environment.DEFAULT, -) - -client.sessions.delete( - id="id", -) - -``` -
-
-
-
- -#### ⚙️ Parameters - -
-
-**id:** `str` — ID of the session to delete. +**include_totals:** `typing.Optional[bool]` — Return results inside an object that contains the total result count (true) or as a direct array of results (false, default).
@@ -15109,7 +14606,7 @@ client.sessions.delete(
-
client.sessions.update(...) -> UpdateSessionResponseContent +
client.self_service_profiles.create(...) -> CreateSelfServiceProfileResponseContent
@@ -15121,7 +14618,7 @@ client.sessions.delete(
-Update session information. +Creates a self-service profile.
@@ -15144,8 +14641,8 @@ client = Auth0( environment=Auth0Environment.DEFAULT, ) -client.sessions.update( - id="id", +client.self_service_profiles.create( + name="name", ) ``` @@ -15162,7 +14659,7 @@ client.sessions.update(
-**id:** `str` — ID of the session to update. +**name:** `str` — The name of the self-service Profile.
@@ -15170,7 +14667,7 @@ client.sessions.update(
-**session_metadata:** `typing.Optional[SessionMetadata]` — Metadata associated with the session. Pass null or {} to remove all session_metadata. +**description:** `typing.Optional[str]` — The description of the self-service Profile.
@@ -15178,72 +14675,31 @@ client.sessions.update(
-**request_options:** `typing.Optional[RequestOptions]` — Request-specific configuration. +**branding:** `typing.Optional[SelfServiceProfileBrandingProperties]`
- -
- - - - -
-
client.sessions.revoke(...)
-#### 📝 Description - -
-
- -
-
- -Revokes a session by ID and all associated refresh tokens. -
-
+**allowed_strategies:** `typing.Optional[typing.List[SelfServiceProfileAllowedStrategyEnum]]` — List of IdP strategies that will be shown to users during the Self-Service Enterprise Configuration flow. Possible values: [`oidc`, `samlp`, `waad`, `google-apps`, `adfs`, `okta`, `auth0-samlp`, `okta-samlp`, `keycloak-samlp`, `pingfederate`] +
-#### 🔌 Usage -
-
-
- -```python -from auth0.management import Auth0 -from auth0.management.environment import Auth0Environment - -client = Auth0( - token="", - environment=Auth0Environment.DEFAULT, -) - -client.sessions.revoke( - id="id", -) - -``` -
-
+**user_attributes:** `typing.Optional[typing.List[SelfServiceProfileUserAttribute]]` — List of attributes to be mapped that will be shown to the user during the Self-Service Enterprise Configuration flow. +
-#### ⚙️ Parameters - -
-
-
-**id:** `str` — ID of the session to revoke. +**user_attribute_profile_id:** `typing.Optional[str]` — ID of the user-attribute-profile to associate with this self-service profile.
@@ -15263,8 +14719,7 @@ client.sessions.revoke(
-## Stats -
client.stats.get_active_users_count() -> GetActiveUsersCountStatsResponseContent +
client.self_service_profiles.get(...) -> GetSelfServiceProfileResponseContent
@@ -15276,7 +14731,7 @@ client.sessions.revoke(
-Retrieve the number of active users that logged in during the last 30 days. +Retrieves a self-service profile by Id.
@@ -15299,7 +14754,9 @@ client = Auth0( environment=Auth0Environment.DEFAULT, ) -client.stats.get_active_users_count() +client.self_service_profiles.get( + id="id", +) ``` @@ -15315,6 +14772,14 @@ client.stats.get_active_users_count()
+**id:** `str` — The id of the self-service profile to retrieve + +
+
+ +
+
+ **request_options:** `typing.Optional[RequestOptions]` — Request-specific configuration.
@@ -15327,7 +14792,7 @@ client.stats.get_active_users_count()
-
client.stats.get_daily(...) -> typing.List[DailyStats] +
client.self_service_profiles.delete(...)
@@ -15339,7 +14804,7 @@ client.stats.get_active_users_count()
-Retrieve the number of logins, signups and breached-password detections (subscription required) that occurred each day within a specified date range. +Deletes a self-service profile by Id.
@@ -15362,9 +14827,8 @@ client = Auth0( environment=Auth0Environment.DEFAULT, ) -client.stats.get_daily( - from_="from", - to="to", +client.self_service_profiles.delete( + id="id", ) ``` @@ -15381,15 +14845,7 @@ client.stats.get_daily(
-**from:** `typing.Optional[str]` — Optional first day of the date range (inclusive) in YYYYMMDD format. - -
-
- -
-
- -**to:** `typing.Optional[str]` — Optional last day of the date range (inclusive) in YYYYMMDD format. +**id:** `str` — The id of the self-service profile to delete
@@ -15409,8 +14865,7 @@ client.stats.get_daily(
-## SupplementalSignals -
client.supplemental_signals.get() -> GetSupplementalSignalsResponseContent +
client.self_service_profiles.update(...) -> UpdateSelfServiceProfileResponseContent
@@ -15422,7 +14877,7 @@ client.stats.get_daily(
-Get the supplemental signals configuration for a tenant. +Updates a self-service profile.
@@ -15445,7 +14900,9 @@ client = Auth0( environment=Auth0Environment.DEFAULT, ) -client.supplemental_signals.get() +client.self_service_profiles.update( + id="id", +) ``` @@ -15461,6 +14918,62 @@ client.supplemental_signals.get()
+**id:** `str` — The id of the self-service profile to update + +
+
+ +
+
+ +**name:** `typing.Optional[str]` — The name of the self-service Profile. + +
+
+ +
+
+ +**description:** `typing.Optional[SelfServiceProfileDescription]` + +
+
+ +
+
+ +**branding:** `typing.Optional[SelfServiceProfileBranding]` + +
+
+ +
+
+ +**allowed_strategies:** `typing.Optional[typing.List[SelfServiceProfileAllowedStrategyEnum]]` — List of IdP strategies that will be shown to users during the Self-Service Enterprise Configuration flow. Possible values: [`oidc`, `samlp`, `waad`, `google-apps`, `adfs`, `okta`, `auth0-samlp`, `okta-samlp`, `keycloak-samlp`, `pingfederate`] + +
+
+ +
+
+ +**user_attributes:** `typing.Optional[SelfServiceProfileUserAttributes]` + +
+
+ +
+
+ +**user_attribute_profile_id:** `typing.Optional[str]` — ID of the user-attribute-profile to associate with this self-service profile. + +
+
+ +
+
+ **request_options:** `typing.Optional[RequestOptions]` — Request-specific configuration.
@@ -15473,7 +14986,8 @@ client.supplemental_signals.get()
-
client.supplemental_signals.patch(...) -> PatchSupplementalSignalsResponseContent +## Sessions +
client.sessions.get(...) -> GetSessionResponseContent
@@ -15485,7 +14999,7 @@ client.supplemental_signals.get()
-Update the supplemental signals configuration for a tenant. +Retrieve session information.
@@ -15508,8 +15022,8 @@ client = Auth0( environment=Auth0Environment.DEFAULT, ) -client.supplemental_signals.patch( - akamai_enabled=True, +client.sessions.get( + id="id", ) ``` @@ -15526,7 +15040,7 @@ client.supplemental_signals.patch(
-**akamai_enabled:** `bool` — Indicates if incoming Akamai Headers should be processed +**id:** `str` — ID of session to retrieve
@@ -15546,8 +15060,7 @@ client.supplemental_signals.patch(
-## Tickets -
client.tickets.verify_email(...) -> VerifyEmailTicketResponseContent +
client.sessions.delete(...)
@@ -15559,7 +15072,7 @@ client.supplemental_signals.patch(
-Create an email verification ticket for a given user. An email verification ticket is a generated URL that the user can consume to verify their email address. +Delete a session by ID.
@@ -15582,8 +15095,8 @@ client = Auth0( environment=Auth0Environment.DEFAULT, ) -client.tickets.verify_email( - user_id="user_id", +client.sessions.delete( + id="id", ) ``` @@ -15600,7 +15113,7 @@ client.tickets.verify_email(
-**user_id:** `str` — user_id of for whom the ticket should be created. +**id:** `str` — ID of the session to delete.
@@ -15608,39 +15121,72 @@ client.tickets.verify_email(
-**result_url:** `typing.Optional[str]` — URL the user will be redirected to in the classic Universal Login experience once the ticket is used. Cannot be specified when using client_id or organization_id. +**request_options:** `typing.Optional[RequestOptions]` — Request-specific configuration.
+ +
-
-
-**client_id:** `typing.Optional[str]` — ID of the client (application). If provided for tenants using the New Universal Login experience, the email template and UI displays application details, and the user is prompted to redirect to the application's default login route after the ticket is used. client_id is required to use the Password Reset Post Challenge trigger. -
+
+
client.sessions.update(...) -> UpdateSessionResponseContent
-**organization_id:** `typing.Optional[str]` — (Optional) Organization ID – the ID of the Organization. If provided, organization parameters will be made available to the email template and organization branding will be applied to the prompt. In addition, the redirect link in the prompt will include organization_id and organization_name query string parameters. - +#### 📝 Description + +
+
+ +
+
+ +Update session information.
+
+
+ +#### 🔌 Usage
-**ttl_sec:** `typing.Optional[int]` — Number of seconds for which the ticket is valid before expiration. If unspecified or set to 0, this value defaults to 432000 seconds (5 days). - +
+
+ +```python +from auth0.management import Auth0 +from auth0.management.environment import Auth0Environment + +client = Auth0( + token="", + environment=Auth0Environment.DEFAULT, +) + +client.sessions.update( + id="id", +) + +```
+
+
+ +#### ⚙️ Parameters
-**include_email_in_redirect:** `typing.Optional[bool]` — Whether to include the email address as part of the returnUrl in the reset_email (true), or not (false). +
+
+ +**id:** `str` — ID of the session to update.
@@ -15648,7 +15194,7 @@ client.tickets.verify_email(
-**identity:** `typing.Optional[Identity]` +**session_metadata:** `typing.Optional[SessionMetadata]` — Metadata associated with the session. Pass null or {} to remove all session_metadata.
@@ -15668,7 +15214,7 @@ client.tickets.verify_email(
-
client.tickets.change_password(...) -> ChangePasswordTicketResponseContent +
client.sessions.revoke(...)
@@ -15680,9 +15226,7 @@ client.tickets.verify_email(
-Create a password change ticket for a given user. A password change ticket is a generated URL that the user can consume to start a reset password flow. - -Note: This endpoint does not verify the given user’s identity. If you call this endpoint within your application, you must design your application to verify the user’s identity. +Revokes a session by ID and all associated refresh tokens.
@@ -15705,7 +15249,9 @@ client = Auth0( environment=Auth0Environment.DEFAULT, ) -client.tickets.change_password() +client.sessions.revoke( + id="id", +) ``` @@ -15721,7 +15267,7 @@ client.tickets.change_password()
-**result_url:** `typing.Optional[str]` — URL the user will be redirected to in the classic Universal Login experience once the ticket is used. Cannot be specified when using organization_id. May be specified together with client_id when the tenant has a custom password reset page enabled and a password-reset-post-challenge Action bound. +**id:** `str` — ID of the session to revoke.
@@ -15729,75 +15275,67 @@ client.tickets.change_password()
-**user_id:** `typing.Optional[str]` — user_id of for whom the ticket should be created. +**request_options:** `typing.Optional[RequestOptions]` — Request-specific configuration.
- -
-
- -**client_id:** `typing.Optional[str]` — ID of the client (application). If provided for tenants using the New Universal Login experience, the email template and UI displays application details, and the user is prompted to redirect to the application's default login route after the ticket is used. client_id is required to use the Password Reset Post Challenge trigger. -
-
-
-**organization_id:** `typing.Optional[str]` — (Optional) Organization ID – the ID of the Organization. If provided, organization parameters will be made available to the email template and organization branding will be applied to the prompt. In addition, the redirect link in the prompt will include organization_id and organization_name query string parameters. -
+
+## Stats +
client.stats.get_active_users_count() -> GetActiveUsersCountStatsResponseContent
-**connection_id:** `typing.Optional[str]` — ID of the connection. If provided, allows the user to be specified using email instead of user_id. If you set this value, you must also send the email parameter. You cannot send user_id when specifying a connection_id. - -
-
+#### 📝 Description
-**email:** `typing.Optional[str]` — Email address of the user for whom the tickets should be created. Requires the connection_id parameter. Cannot be specified when using user_id. - -
-
-
-**ttl_sec:** `typing.Optional[int]` — Number of seconds for which the ticket is valid before expiration. If unspecified or set to 0, this value defaults to 432000 seconds (5 days). - +Retrieve the number of active users that logged in during the last 30 days. +
+
+#### 🔌 Usage +
-**mark_email_as_verified:** `typing.Optional[bool]` — Whether to set the email_verified attribute to true (true) or whether it should not be updated (false). - -
-
-
-**include_email_in_redirect:** `typing.Optional[bool]` — Whether to include the email address as part of the returnUrl in the reset_email (true), or not (false). - +```python +from auth0.management import Auth0 +from auth0.management.environment import Auth0Environment + +client = Auth0( + token="", + environment=Auth0Environment.DEFAULT, +) + +client.stats.get_active_users_count() + +``` +
+
+#### ⚙️ Parameters +
-**identity:** `typing.Optional[ChangePasswordTicketIdentity]` - -
-
-
@@ -15813,8 +15351,7 @@ client.tickets.change_password()
-## TokenExchangeProfiles -
client.token_exchange_profiles.list(...) -> ListTokenExchangeProfileResponseContent +
client.stats.get_daily(...) -> typing.List[DailyStats]
@@ -15826,16 +15363,7 @@ client.tickets.change_password()
-Retrieve a list of all Token Exchange Profiles available in your tenant. - -By using this feature, you agree to the applicable Free Trial terms in [Okta’s Master Subscription Agreement](https://www.okta.com/legal/). It is your responsibility to securely validate the user’s subject_token. See [User Guide](https://auth0.com/docs/authenticate/custom-token-exchange) for more details. - -This endpoint supports Checkpoint pagination. To search by checkpoint, use the following parameters: - -- `from`: Optional id from which to start selection. -- `take`: The total amount of entries to retrieve when using the from parameter. Defaults to 50. - -**Note**: The first time you call this endpoint using checkpoint pagination, omit the `from` parameter. If there are more results, a `next` value is included in the response. You can use this for subsequent API calls. When `next` is no longer included in the response, no pages are remaining. +Retrieve the number of logins, signups and breached-password detections (subscription required) that occurred each day within a specified date range.
@@ -15858,9 +15386,9 @@ client = Auth0( environment=Auth0Environment.DEFAULT, ) -client.token_exchange_profiles.list( +client.stats.get_daily( from_="from", - take=1, + to="to", ) ``` @@ -15877,7 +15405,7 @@ client.token_exchange_profiles.list(
-**from:** `typing.Optional[str]` — Optional Id from which to start selection. +**from:** `typing.Optional[str]` — Optional first day of the date range (inclusive) in YYYYMMDD format.
@@ -15885,7 +15413,7 @@ client.token_exchange_profiles.list(
-**take:** `typing.Optional[int]` — Number of results per page. Defaults to 50. +**to:** `typing.Optional[str]` — Optional last day of the date range (inclusive) in YYYYMMDD format.
@@ -15905,7 +15433,8 @@ client.token_exchange_profiles.list(
-
client.token_exchange_profiles.create(...) -> CreateTokenExchangeProfileResponseContent +## SupplementalSignals +
client.supplemental_signals.get() -> GetSupplementalSignalsResponseContent
@@ -15917,9 +15446,7 @@ client.token_exchange_profiles.list(
-Create a new Token Exchange Profile within your tenant. - -By using this feature, you agree to the applicable Free Trial terms in [Okta’s Master Subscription Agreement](https://www.okta.com/legal/). It is your responsibility to securely validate the user’s subject_token. See [User Guide](https://auth0.com/docs/authenticate/custom-token-exchange) for more details. +Get the supplemental signals configuration for a tenant.
@@ -15942,12 +15469,7 @@ client = Auth0( environment=Auth0Environment.DEFAULT, ) -client.token_exchange_profiles.create( - name="name", - subject_token_type="subject_token_type", - action_id="action_id", - type="custom_authentication", -) +client.supplemental_signals.get() ``` @@ -15963,38 +15485,6 @@ client.token_exchange_profiles.create(
-**name:** `str` — Friendly name of this profile. - -
-
- -
-
- -**subject_token_type:** `str` — Subject token type for this profile. When receiving a token exchange request on the Authentication API, the corresponding token exchange profile with a matching subject_token_type will be executed. This must be a URI. - -
-
- -
-
- -**action_id:** `str` — The ID of the Custom Token Exchange action to execute for this profile, in order to validate the subject_token. The action must use the custom-token-exchange trigger. - -
-
- -
-
- -**type:** `TokenExchangeProfileTypeEnum` - -
-
- -
-
- **request_options:** `typing.Optional[RequestOptions]` — Request-specific configuration.
@@ -16007,7 +15497,7 @@ client.token_exchange_profiles.create(
-
client.token_exchange_profiles.get(...) -> GetTokenExchangeProfileResponseContent +
client.supplemental_signals.patch(...) -> PatchSupplementalSignalsResponseContent
@@ -16019,9 +15509,7 @@ client.token_exchange_profiles.create(
-Retrieve details about a single Token Exchange Profile specified by ID. - -By using this feature, you agree to the applicable Free Trial terms in [Okta’s Master Subscription Agreement](https://www.okta.com/legal/). It is your responsibility to securely validate the user’s subject_token. See [User Guide](https://auth0.com/docs/authenticate/custom-token-exchange) for more details. +Update the supplemental signals configuration for a tenant.
@@ -16044,8 +15532,8 @@ client = Auth0( environment=Auth0Environment.DEFAULT, ) -client.token_exchange_profiles.get( - id="id", +client.supplemental_signals.patch( + akamai_enabled=True, ) ``` @@ -16062,7 +15550,7 @@ client.token_exchange_profiles.get(
-**id:** `str` — ID of the Token Exchange Profile to retrieve. +**akamai_enabled:** `bool` — Indicates if incoming Akamai Headers should be processed
@@ -16082,7 +15570,8 @@ client.token_exchange_profiles.get(
-
client.token_exchange_profiles.delete(...) +## Tickets +
client.tickets.verify_email(...) -> VerifyEmailTicketResponseContent
@@ -16094,9 +15583,7 @@ client.token_exchange_profiles.get(
-Delete a Token Exchange Profile within your tenant. - -By using this feature, you agree to the applicable Free Trial terms in [Okta's Master Subscription Agreement](https://www.okta.com/legal/). It is your responsibility to securely validate the user's subject_token. See [User Guide](https://auth0.com/docs/authenticate/custom-token-exchange) for more details. +Create an email verification ticket for a given user. An email verification ticket is a generated URL that the user can consume to verify their email address.
@@ -16119,8 +15606,8 @@ client = Auth0( environment=Auth0Environment.DEFAULT, ) -client.token_exchange_profiles.delete( - id="id", +client.tickets.verify_email( + user_id="user_id", ) ``` @@ -16137,7 +15624,55 @@ client.token_exchange_profiles.delete(
-**id:** `str` — ID of the Token Exchange Profile to delete. +**user_id:** `str` — user_id of for whom the ticket should be created. + +
+
+ +
+
+ +**result_url:** `typing.Optional[str]` — URL the user will be redirected to in the classic Universal Login experience once the ticket is used. Cannot be specified when using client_id or organization_id. + +
+
+ +
+
+ +**client_id:** `typing.Optional[str]` — ID of the client (application). If provided for tenants using the New Universal Login experience, the email template and UI displays application details, and the user is prompted to redirect to the application's default login route after the ticket is used. client_id is required to use the Password Reset Post Challenge trigger. + +
+
+ +
+
+ +**organization_id:** `typing.Optional[str]` — (Optional) Organization ID – the ID of the Organization. If provided, organization parameters will be made available to the email template and organization branding will be applied to the prompt. In addition, the redirect link in the prompt will include organization_id and organization_name query string parameters. + +
+
+ +
+
+ +**ttl_sec:** `typing.Optional[int]` — Number of seconds for which the ticket is valid before expiration. If unspecified or set to 0, this value defaults to 432000 seconds (5 days). + +
+
+ +
+
+ +**include_email_in_redirect:** `typing.Optional[bool]` — Whether to include the email address as part of the returnUrl in the reset_email (true), or not (false). + +
+
+ +
+
+ +**identity:** `typing.Optional[Identity]`
@@ -16157,7 +15692,7 @@ client.token_exchange_profiles.delete(
-
client.token_exchange_profiles.update(...) +
client.tickets.change_password(...) -> ChangePasswordTicketResponseContent
@@ -16169,9 +15704,9 @@ client.token_exchange_profiles.delete(
-Update a Token Exchange Profile within your tenant. +Create a password change ticket for a given user. A password change ticket is a generated URL that the user can consume to start a reset password flow. -By using this feature, you agree to the applicable Free Trial terms in [Okta's Master Subscription Agreement](https://www.okta.com/legal/). It is your responsibility to securely validate the user's subject_token. See [User Guide](https://auth0.com/docs/authenticate/custom-token-exchange) for more details. +Note: This endpoint does not verify the given user’s identity. If you call this endpoint within your application, you must design your application to verify the user’s identity.
@@ -16194,9 +15729,7 @@ client = Auth0( environment=Auth0Environment.DEFAULT, ) -client.token_exchange_profiles.update( - id="id", -) +client.tickets.change_password() ``` @@ -16212,7 +15745,7 @@ client.token_exchange_profiles.update(
-**id:** `str` — ID of the Token Exchange Profile to update. +**result_url:** `typing.Optional[str]` — URL the user will be redirected to in the classic Universal Login experience once the ticket is used. Cannot be specified when using organization_id. May be specified together with client_id when the tenant has a custom password reset page enabled and a password-reset-post-challenge Action bound.
@@ -16220,7 +15753,7 @@ client.token_exchange_profiles.update(
-**name:** `typing.Optional[str]` — Friendly name of this profile. +**user_id:** `typing.Optional[str]` — user_id of for whom the ticket should be created.
@@ -16228,7 +15761,63 @@ client.token_exchange_profiles.update(
-**subject_token_type:** `typing.Optional[str]` — Subject token type for this profile. When receiving a token exchange request on the Authentication API, the corresponding token exchange profile with a matching subject_token_type will be executed. This must be a URI. +**client_id:** `typing.Optional[str]` — ID of the client (application). If provided for tenants using the New Universal Login experience, the email template and UI displays application details, and the user is prompted to redirect to the application's default login route after the ticket is used. client_id is required to use the Password Reset Post Challenge trigger. + +
+
+ +
+
+ +**organization_id:** `typing.Optional[str]` — (Optional) Organization ID – the ID of the Organization. If provided, organization parameters will be made available to the email template and organization branding will be applied to the prompt. In addition, the redirect link in the prompt will include organization_id and organization_name query string parameters. + +
+
+ +
+
+ +**connection_id:** `typing.Optional[str]` — ID of the connection. If provided, allows the user to be specified using email instead of user_id. If you set this value, you must also send the email parameter. You cannot send user_id when specifying a connection_id. + +
+
+ +
+
+ +**email:** `typing.Optional[str]` — Email address of the user for whom the tickets should be created. Requires the connection_id parameter. Cannot be specified when using user_id. + +
+
+ +
+
+ +**ttl_sec:** `typing.Optional[int]` — Number of seconds for which the ticket is valid before expiration. If unspecified or set to 0, this value defaults to 432000 seconds (5 days). + +
+
+ +
+
+ +**mark_email_as_verified:** `typing.Optional[bool]` — Whether to set the email_verified attribute to true (true) or whether it should not be updated (false). + +
+
+ +
+
+ +**include_email_in_redirect:** `typing.Optional[bool]` — Whether to include the email address as part of the returnUrl in the reset_email (true), or not (false). + +
+
+ +
+
+ +**identity:** `typing.Optional[ChangePasswordTicketIdentity]`
@@ -16248,8 +15837,8 @@ client.token_exchange_profiles.update(
-## UserAttributeProfiles -
client.user_attribute_profiles.list(...) -> ListUserAttributeProfilesPaginatedResponseContent +## TokenExchangeProfiles +
client.token_exchange_profiles.list(...) -> ListTokenExchangeProfileResponseContent
@@ -16261,7 +15850,16 @@ client.token_exchange_profiles.update(
-Retrieve a list of User Attribute Profiles. This endpoint supports Checkpoint pagination. +Retrieve a list of all Token Exchange Profiles available in your tenant. + +By using this feature, you agree to the applicable Free Trial terms in [Okta’s Master Subscription Agreement](https://www.okta.com/legal/). It is your responsibility to securely validate the user’s subject_token. See [User Guide](https://auth0.com/docs/authenticate/custom-token-exchange) for more details. + +This endpoint supports Checkpoint pagination. To search by checkpoint, use the following parameters: + +- `from`: Optional id from which to start selection. +- `take`: The total amount of entries to retrieve when using the from parameter. Defaults to 50. + +**Note**: The first time you call this endpoint using checkpoint pagination, omit the `from` parameter. If there are more results, a `next` value is included in the response. You can use this for subsequent API calls. When `next` is no longer included in the response, no pages are remaining.
@@ -16284,7 +15882,7 @@ client = Auth0( environment=Auth0Environment.DEFAULT, ) -client.user_attribute_profiles.list( +client.token_exchange_profiles.list( from_="from", take=1, ) @@ -16311,7 +15909,7 @@ client.user_attribute_profiles.list(
-**take:** `typing.Optional[int]` — Number of results per page. Defaults to 5. +**take:** `typing.Optional[int]` — Number of results per page. Defaults to 50.
@@ -16331,7 +15929,7 @@ client.user_attribute_profiles.list(
-
client.user_attribute_profiles.create(...) -> CreateUserAttributeProfileResponseContent +
client.token_exchange_profiles.create(...) -> CreateTokenExchangeProfileResponseContent
@@ -16343,7 +15941,9 @@ client.user_attribute_profiles.list(
-Create a User Attribute Profile. +Create a new Token Exchange Profile within your tenant. + +By using this feature, you agree to the applicable Free Trial terms in [Okta’s Master Subscription Agreement](https://www.okta.com/legal/). It is your responsibility to securely validate the user’s subject_token. See [User Guide](https://auth0.com/docs/authenticate/custom-token-exchange) for more details.
@@ -16358,7 +15958,7 @@ Create a User Attribute Profile.
```python -from auth0.management import Auth0, UserAttributeProfileUserAttributeAdditionalProperties +from auth0.management import Auth0 from auth0.management.environment import Auth0Environment client = Auth0( @@ -16366,16 +15966,11 @@ client = Auth0( environment=Auth0Environment.DEFAULT, ) -client.user_attribute_profiles.create( +client.token_exchange_profiles.create( name="name", - user_attributes={ - "key": UserAttributeProfileUserAttributeAdditionalProperties( - description="description", - label="label", - profile_required=True, - auth_0_mapping="auth0_mapping", - ) - }, + subject_token_type="subject_token_type", + action_id="action_id", + type="custom_authentication", ) ``` @@ -16392,7 +15987,7 @@ client.user_attribute_profiles.create(
-**name:** `UserAttributeProfileName` +**name:** `str` — Friendly name of this profile.
@@ -16400,7 +15995,7 @@ client.user_attribute_profiles.create(
-**user_attributes:** `UserAttributeProfileUserAttributes` +**subject_token_type:** `str` — Subject token type for this profile. When receiving a token exchange request on the Authentication API, the corresponding token exchange profile with a matching subject_token_type will be executed. This must be a URI.
@@ -16408,7 +16003,15 @@ client.user_attribute_profiles.create(
-**user_id:** `typing.Optional[UserAttributeProfileUserId]` +**action_id:** `str` — The ID of the Custom Token Exchange action to execute for this profile, in order to validate the subject_token. The action must use the custom-token-exchange trigger. + +
+
+ +
+
+ +**type:** `TokenExchangeProfileTypeEnum`
@@ -16428,7 +16031,7 @@ client.user_attribute_profiles.create(
-
client.user_attribute_profiles.list_templates() -> ListUserAttributeProfileTemplateResponseContent +
client.token_exchange_profiles.get(...) -> GetTokenExchangeProfileResponseContent
@@ -16440,7 +16043,9 @@ client.user_attribute_profiles.create(
-Retrieve a list of User Attribute Profile Templates. +Retrieve details about a single Token Exchange Profile specified by ID. + +By using this feature, you agree to the applicable Free Trial terms in [Okta’s Master Subscription Agreement](https://www.okta.com/legal/). It is your responsibility to securely validate the user’s subject_token. See [User Guide](https://auth0.com/docs/authenticate/custom-token-exchange) for more details.
@@ -16463,7 +16068,9 @@ client = Auth0( environment=Auth0Environment.DEFAULT, ) -client.user_attribute_profiles.list_templates() +client.token_exchange_profiles.get( + id="id", +) ``` @@ -16479,6 +16086,14 @@ client.user_attribute_profiles.list_templates()
+**id:** `str` — ID of the Token Exchange Profile to retrieve. + +
+
+ +
+
+ **request_options:** `typing.Optional[RequestOptions]` — Request-specific configuration.
@@ -16491,7 +16106,7 @@ client.user_attribute_profiles.list_templates()
-
client.user_attribute_profiles.get_template(...) -> GetUserAttributeProfileTemplateResponseContent +
client.token_exchange_profiles.delete(...)
@@ -16503,7 +16118,9 @@ client.user_attribute_profiles.list_templates()
-Retrieve a User Attribute Profile Template. +Delete a Token Exchange Profile within your tenant. + +By using this feature, you agree to the applicable Free Trial terms in [Okta's Master Subscription Agreement](https://www.okta.com/legal/). It is your responsibility to securely validate the user's subject_token. See [User Guide](https://auth0.com/docs/authenticate/custom-token-exchange) for more details.
@@ -16526,7 +16143,7 @@ client = Auth0( environment=Auth0Environment.DEFAULT, ) -client.user_attribute_profiles.get_template( +client.token_exchange_profiles.delete( id="id", ) @@ -16544,7 +16161,7 @@ client.user_attribute_profiles.get_template(
-**id:** `str` — ID of the user-attribute-profile-template to retrieve. +**id:** `str` — ID of the Token Exchange Profile to delete.
@@ -16564,7 +16181,7 @@ client.user_attribute_profiles.get_template(
-
client.user_attribute_profiles.get(...) -> GetUserAttributeProfileResponseContent +
client.token_exchange_profiles.update(...)
@@ -16576,7 +16193,9 @@ client.user_attribute_profiles.get_template(
-Retrieve details about a single User Attribute Profile specified by ID. +Update a Token Exchange Profile within your tenant. + +By using this feature, you agree to the applicable Free Trial terms in [Okta's Master Subscription Agreement](https://www.okta.com/legal/). It is your responsibility to securely validate the user's subject_token. See [User Guide](https://auth0.com/docs/authenticate/custom-token-exchange) for more details.
@@ -16599,7 +16218,7 @@ client = Auth0( environment=Auth0Environment.DEFAULT, ) -client.user_attribute_profiles.get( +client.token_exchange_profiles.update( id="id", ) @@ -16617,7 +16236,23 @@ client.user_attribute_profiles.get(
-**id:** `str` — ID of the user-attribute-profile to retrieve. +**id:** `str` — ID of the Token Exchange Profile to update. + +
+
+ +
+
+ +**name:** `typing.Optional[str]` — Friendly name of this profile. + +
+
+ +
+
+ +**subject_token_type:** `typing.Optional[str]` — Subject token type for this profile. When receiving a token exchange request on the Authentication API, the corresponding token exchange profile with a matching subject_token_type will be executed. This must be a URI.
@@ -16637,7 +16272,8 @@ client.user_attribute_profiles.get(
-
client.user_attribute_profiles.delete(...) +## UserAttributeProfiles +
client.user_attribute_profiles.list(...) -> ListUserAttributeProfilesPaginatedResponseContent
@@ -16649,7 +16285,7 @@ client.user_attribute_profiles.get(
-Delete a single User Attribute Profile specified by ID. +Retrieve a list of User Attribute Profiles. This endpoint supports Checkpoint pagination.
@@ -16672,8 +16308,9 @@ client = Auth0( environment=Auth0Environment.DEFAULT, ) -client.user_attribute_profiles.delete( - id="id", +client.user_attribute_profiles.list( + from_="from", + take=1, ) ``` @@ -16690,7 +16327,15 @@ client.user_attribute_profiles.delete(
-**id:** `str` — ID of the user-attribute-profile to delete. +**from:** `typing.Optional[str]` — Optional Id from which to start selection. + +
+
+ +
+
+ +**take:** `typing.Optional[int]` — Number of results per page. Defaults to 5.
@@ -16710,7 +16355,7 @@ client.user_attribute_profiles.delete(
-
client.user_attribute_profiles.update(...) -> UpdateUserAttributeProfileResponseContent +
client.user_attribute_profiles.create(...) -> CreateUserAttributeProfileResponseContent
@@ -16722,7 +16367,7 @@ client.user_attribute_profiles.delete(
-Update the details of a specific User attribute profile, such as name, user_id and user_attributes. +Create a User Attribute Profile.
@@ -16737,7 +16382,7 @@ Update the details of a specific User attribute profile, such as name, user_id a
```python -from auth0.management import Auth0 +from auth0.management import Auth0, UserAttributeProfileUserAttributeAdditionalProperties from auth0.management.environment import Auth0Environment client = Auth0( @@ -16745,8 +16390,16 @@ client = Auth0( environment=Auth0Environment.DEFAULT, ) -client.user_attribute_profiles.update( - id="id", +client.user_attribute_profiles.create( + name="name", + user_attributes={ + "key": UserAttributeProfileUserAttributeAdditionalProperties( + description="description", + label="label", + profile_required=True, + auth_0_mapping="auth0_mapping", + ) + }, ) ``` @@ -16763,15 +16416,7 @@ client.user_attribute_profiles.update(
-**id:** `str` — ID of the user attribute profile to update. - -
-
- -
-
- -**name:** `typing.Optional[UserAttributeProfileName]` +**name:** `UserAttributeProfileName`
@@ -16779,7 +16424,7 @@ client.user_attribute_profiles.update(
-**user_id:** `typing.Optional[UserAttributeProfilePatchUserId]` +**user_attributes:** `UserAttributeProfileUserAttributes`
@@ -16787,7 +16432,7 @@ client.user_attribute_profiles.update(
-**user_attributes:** `typing.Optional[UserAttributeProfileUserAttributes]` +**user_id:** `typing.Optional[UserAttributeProfileUserId]`
@@ -16807,8 +16452,7 @@ client.user_attribute_profiles.update(
-## UserBlocks -
client.user_blocks.list_by_identifier(...) -> ListUserBlocksByIdentifierResponseContent +
client.user_attribute_profiles.list_templates() -> ListUserAttributeProfileTemplateResponseContent
@@ -16820,7 +16464,7 @@ client.user_attribute_profiles.update(
-Retrieve details of all [Brute-force Protection](https://auth0.com/docs/secure/attack-protection/brute-force-protection) blocks for a user with the given identifier (username, phone number, or email). +Retrieve a list of User Attribute Profile Templates.
@@ -16843,10 +16487,7 @@ client = Auth0( environment=Auth0Environment.DEFAULT, ) -client.user_blocks.list_by_identifier( - identifier="identifier", - consider_brute_force_enablement=True, -) +client.user_attribute_profiles.list_templates() ``` @@ -16862,27 +16503,6 @@ client.user_blocks.list_by_identifier(
-**identifier:** `str` — Should be any of a username, phone number, or email. - -
-
- -
-
- -**consider_brute_force_enablement:** `typing.Optional[bool]` - - - If true and Brute Force Protection is enabled and configured to block logins, will return a list of blocked IP addresses. - If true and Brute Force Protection is disabled, will return an empty list. - - -
-
- -
-
- **request_options:** `typing.Optional[RequestOptions]` — Request-specific configuration.
@@ -16895,7 +16515,7 @@ client.user_blocks.list_by_identifier(
-
client.user_blocks.delete_by_identifier(...) +
client.user_attribute_profiles.get_template(...) -> GetUserAttributeProfileTemplateResponseContent
@@ -16907,9 +16527,7 @@ client.user_blocks.list_by_identifier(
-Remove all [Brute-force Protection](https://auth0.com/docs/secure/attack-protection/brute-force-protection) blocks for the user with the given identifier (username, phone number, or email). - -Note: This endpoint does not unblock users that were [blocked by a tenant administrator](https://auth0.com/docs/user-profile#block-and-unblock-a-user). +Retrieve a User Attribute Profile Template.
@@ -16932,8 +16550,8 @@ client = Auth0( environment=Auth0Environment.DEFAULT, ) -client.user_blocks.delete_by_identifier( - identifier="identifier", +client.user_attribute_profiles.get_template( + id="id", ) ``` @@ -16950,7 +16568,7 @@ client.user_blocks.delete_by_identifier(
-**identifier:** `str` — Should be any of a username, phone number, or email. +**id:** `str` — ID of the user-attribute-profile-template to retrieve.
@@ -16970,7 +16588,7 @@ client.user_blocks.delete_by_identifier(
-
client.user_blocks.list(...) -> ListUserBlocksResponseContent +
client.user_attribute_profiles.get(...) -> GetUserAttributeProfileResponseContent
@@ -16982,7 +16600,7 @@ client.user_blocks.delete_by_identifier(
-Retrieve details of all [Brute-force Protection](https://auth0.com/docs/secure/attack-protection/brute-force-protection) blocks for the user with the given ID. +Retrieve details about a single User Attribute Profile specified by ID.
@@ -17005,9 +16623,8 @@ client = Auth0( environment=Auth0Environment.DEFAULT, ) -client.user_blocks.list( +client.user_attribute_profiles.get( id="id", - consider_brute_force_enablement=True, ) ``` @@ -17024,20 +16641,7 @@ client.user_blocks.list(
-**id:** `str` — user_id of the user blocks to retrieve. - -
-
- -
-
- -**consider_brute_force_enablement:** `typing.Optional[bool]` - - - If true and Brute Force Protection is enabled and configured to block logins, will return a list of blocked IP addresses. - If true and Brute Force Protection is disabled, will return an empty list. - +**id:** `str` — ID of the user-attribute-profile to retrieve.
@@ -17057,7 +16661,7 @@ client.user_blocks.list(
-
client.user_blocks.delete(...) +
client.user_attribute_profiles.delete(...)
@@ -17069,9 +16673,7 @@ client.user_blocks.list(
-Remove all [Brute-force Protection](https://auth0.com/docs/secure/attack-protection/brute-force-protection) blocks for the user with the given ID. - -Note: This endpoint does not unblock users that were [blocked by a tenant administrator](https://auth0.com/docs/user-profile#block-and-unblock-a-user). +Delete a single User Attribute Profile specified by ID.
@@ -17094,7 +16696,7 @@ client = Auth0( environment=Auth0Environment.DEFAULT, ) -client.user_blocks.delete( +client.user_attribute_profiles.delete( id="id", ) @@ -17112,7 +16714,7 @@ client.user_blocks.delete(
-**id:** `str` — The user_id of the user to update. +**id:** `str` — ID of the user-attribute-profile to delete.
@@ -17132,8 +16734,7 @@ client.user_blocks.delete(
-## Users -
client.users.list(...) -> ListUsersOffsetPaginatedResponseContent +
client.user_attribute_profiles.update(...) -> UpdateUserAttributeProfileResponseContent
@@ -17145,24 +16746,7 @@ client.user_blocks.delete(
-Retrieve details of users. It is possible to: - -- Specify a search criteria for users -- Sort the users to be returned -- Select the fields to be returned -- Specify the number of users to retrieve per page and the page index - - - -The `q` query parameter can be used to get users that match the specified criteria [using query string syntax.](https://auth0.com/docs/users/search/v3/query-syntax) - -[Learn more about searching for users.](https://auth0.com/docs/users/search/v3) - -Read about [best practices](https://auth0.com/docs/users/search/best-practices) when working with the API endpoints for retrieving users. - - - -Auth0 limits the number of users you can return. If you exceed this threshold, please redefine your search, use the [export job](https://auth0.com/docs/api/management/v2#!/Jobs/post_users_exports), or the [User Import / Export](https://auth0.com/docs/extensions/user-import-export) extension. +Update the details of a specific User attribute profile, such as name, user_id and user_attributes.
@@ -17185,17 +16769,8 @@ client = Auth0( environment=Auth0Environment.DEFAULT, ) -client.users.list( - page=1, - per_page=1, - include_totals=True, - sort="sort", - connection="connection", - fields="fields", - include_fields=True, - q="q", - search_engine="v1", - primary_order=True, +client.user_attribute_profiles.update( + id="id", ) ``` @@ -17212,55 +16787,7 @@ client.users.list(
-**page:** `typing.Optional[int]` — Page index of the results to return. First page is 0. - -
-
- -
-
- -**per_page:** `typing.Optional[int]` — Number of results per page. - -
-
- -
-
- -**include_totals:** `typing.Optional[bool]` — Return results inside an object that contains the total result count (true) or as a direct array of results (false, default). - -
-
- -
-
- -**sort:** `typing.Optional[str]` — Field to sort by. Use field:order where order is 1 for ascending and -1 for descending. e.g. created_at:1 - -
-
- -
-
- -**connection:** `typing.Optional[str]` — Connection filter. Only applies when using search_engine=v1. To filter by connection with search_engine=v2|v3, use q=identities.connection:"connection_name" - -
-
- -
-
- -**fields:** `typing.Optional[str]` — Comma-separated list of fields to include or exclude (based on value provided for include_fields) in the result. Leave empty to retrieve all fields. - -
-
- -
-
- -**include_fields:** `typing.Optional[bool]` — Whether specified fields are to be included (true) or excluded (false). +**id:** `str` — ID of the user attribute profile to update.
@@ -17268,7 +16795,7 @@ client.users.list(
-**q:** `typing.Optional[str]` — Query in Lucene query string syntax. Some query types cannot be used on metadata fields, for details see Searchable Fields. +**name:** `typing.Optional[UserAttributeProfileName]`
@@ -17276,7 +16803,7 @@ client.users.list(
-**search_engine:** `typing.Optional[SearchEngineVersionsEnum]` — The version of the search engine +**user_id:** `typing.Optional[UserAttributeProfilePatchUserId]`
@@ -17284,7 +16811,7 @@ client.users.list(
-**primary_order:** `typing.Optional[bool]` — If true (default), results are returned in a deterministic order. If false, results may be returned in a non-deterministic order, which can enhance performance for complex queries targeting a small number of users. Set to false only when consistent ordering and pagination is not required. +**user_attributes:** `typing.Optional[UserAttributeProfileUserAttributes]`
@@ -17304,7 +16831,8 @@ client.users.list(
-
client.users.create(...) -> CreateUserResponseContent +## UserBlocks +
client.user_blocks.list_by_identifier(...) -> ListUserBlocksByIdentifierResponseContent
@@ -17316,9 +16844,7 @@ client.users.list(
-Create a new user for a given [database](https://auth0.com/docs/connections/database) or [passwordless](https://auth0.com/docs/connections/passwordless) connection. - -Note: `connection` is required but other parameters such as `email` and `password` are dependent upon the type of connection. +Retrieve details of all [Brute-force Protection](https://auth0.com/docs/secure/attack-protection/brute-force-protection) blocks for a user with the given identifier (username, phone number, or email).
@@ -17341,8 +16867,9 @@ client = Auth0( environment=Auth0Environment.DEFAULT, ) -client.users.create( - connection="connection", +client.user_blocks.list_by_identifier( + identifier="identifier", + consider_brute_force_enablement=True, ) ``` @@ -17359,7 +16886,7 @@ client.users.create(
-**connection:** `str` — Name of the connection this user should be created in. +**identifier:** `str` — Should be any of a username, phone number, or email.
@@ -17367,15 +16894,12 @@ client.users.create(
-**email:** `typing.Optional[str]` — The user's email. - -
-
+**consider_brute_force_enablement:** `typing.Optional[bool]` -
-
-**phone_number:** `typing.Optional[str]` — The user's phone number (following the E.164 recommendation). + If true, returns only blocks that are currently enforced (e.g. subject to protection status, IP allowlist, etc.). + If false or omitted, returns all blocks regardless of enforcement state. +
@@ -17383,111 +16907,74 @@ client.users.create(
-**user_metadata:** `typing.Optional[UserMetadata]` +**request_options:** `typing.Optional[RequestOptions]` — Request-specific configuration.
- -
-
- -**blocked:** `typing.Optional[bool]` — Whether this user was blocked by an administrator (true) or not (false). -
-
-
-**email_verified:** `typing.Optional[bool]` — Whether this email address is verified (true) or unverified (false). User will receive a verification email after creation if `email_verified` is false or not specified -
+
+
client.user_blocks.delete_by_identifier(...)
-**phone_verified:** `typing.Optional[bool]` — Whether this phone number has been verified (true) or not (false). - -
-
+#### 📝 Description
-**app_metadata:** `typing.Optional[AppMetadata]` - -
-
-
-**given_name:** `typing.Optional[str]` — The user's given name(s). - -
-
- -
-
+Remove all [Brute-force Protection](https://auth0.com/docs/secure/attack-protection/brute-force-protection) blocks for the user with the given identifier (username, phone number, or email). -**family_name:** `typing.Optional[str]` — The user's family name(s). - +Note: This endpoint does not unblock users that were [blocked by a tenant administrator](https://auth0.com/docs/user-profile#block-and-unblock-a-user).
- -
-
- -**name:** `typing.Optional[str]` — The user's full name. -
+#### 🔌 Usage +
-**nickname:** `typing.Optional[str]` — The user's nickname. - -
-
-
-**picture:** `typing.Optional[str]` — A URI pointing to the user's picture. - -
-
+```python +from auth0.management import Auth0 +from auth0.management.environment import Auth0Environment -
-
+client = Auth0( + token="", + environment=Auth0Environment.DEFAULT, +) -**user_id:** `typing.Optional[str]` — The external user's id provided by the identity provider. - +client.user_blocks.delete_by_identifier( + identifier="identifier", +) + +```
- -
-
- -**password:** `typing.Optional[str]` — Initial password for this user. Only valid for auth0 connection strategy. -
+#### ⚙️ Parameters +
-**verify_email:** `typing.Optional[bool]` — Whether the user will receive a verification email after creation (true) or no email (false). Overrides behavior of `email_verified` parameter. - -
-
-
-**username:** `typing.Optional[str]` — The user's username. Only valid if the connection requires a username. +**identifier:** `str` — Should be any of a username, phone number, or email.
@@ -17507,7 +16994,7 @@ client.users.create(
-
client.users.list_users_by_email(...) -> typing.List[UserResponseSchema] +
client.user_blocks.list(...) -> ListUserBlocksResponseContent
@@ -17519,11 +17006,7 @@ client.users.create(
-Find users by email. If Auth0 is the identity provider (idP), the email address associated with a user is saved in lower case, regardless of how you initially provided it. - -For example, if you register a user as JohnSmith@example.com, Auth0 saves the user's email as johnsmith@example.com. - -Therefore, when using this endpoint, make sure that you are searching for users via email addresses using the correct case. +Retrieve details of all [Brute-force Protection](https://auth0.com/docs/secure/attack-protection/brute-force-protection) blocks for the user with the given ID.
@@ -17546,10 +17029,9 @@ client = Auth0( environment=Auth0Environment.DEFAULT, ) -client.users.list_users_by_email( - fields="fields", - include_fields=True, - email="email", +client.user_blocks.list( + id="id", + consider_brute_force_enablement=True, ) ``` @@ -17566,7 +17048,7 @@ client.users.list_users_by_email(
-**email:** `str` — Email address to search for (case-sensitive). +**id:** `str` — user_id of the user blocks to retrieve.
@@ -17574,15 +17056,12 @@ client.users.list_users_by_email(
-**fields:** `typing.Optional[str]` — Comma-separated list of fields to include or exclude (based on value provided for include_fields) in the result. Leave empty to retrieve all fields. - -
-
+**consider_brute_force_enablement:** `typing.Optional[bool]` -
-
-**include_fields:** `typing.Optional[bool]` — Whether specified fields are to be included (true) or excluded (false). Defaults to true. + If true, returns only blocks that are currently enforced (e.g. subject to protection status, IP allowlist, etc.). + If false or omitted, returns all blocks regardless of enforcement state. +
@@ -17602,7 +17081,7 @@ client.users.list_users_by_email(
-
client.users.get(...) -> GetUserResponseContent +
client.user_blocks.delete(...)
@@ -17614,7 +17093,9 @@ client.users.list_users_by_email(
-Retrieve user details. A list of fields to include or exclude may also be specified. For more information, see [Retrieve Users with the Get Users Endpoint](https://auth0.com/docs/manage-users/user-search/retrieve-users-with-get-users-endpoint). +Remove all [Brute-force Protection](https://auth0.com/docs/secure/attack-protection/brute-force-protection) blocks for the user with the given ID. + +Note: This endpoint does not unblock users that were [blocked by a tenant administrator](https://auth0.com/docs/user-profile#block-and-unblock-a-user).
@@ -17637,10 +17118,8 @@ client = Auth0( environment=Auth0Environment.DEFAULT, ) -client.users.get( +client.user_blocks.delete( id="id", - fields="fields", - include_fields=True, ) ``` @@ -17657,23 +17136,7 @@ client.users.get(
-**id:** `str` — ID of the user to retrieve. - -
-
- -
-
- -**fields:** `typing.Optional[str]` — Comma-separated list of fields to include or exclude (based on value provided for include_fields) in the result. Leave empty to retrieve all fields. - -
-
- -
-
- -**include_fields:** `typing.Optional[bool]` — Whether specified fields are to be included (true) or excluded (false). +**id:** `str` — The user_id of the user to update.
@@ -17693,7 +17156,8 @@ client.users.get(
-
client.users.delete(...) +## Users +
client.users.list(...) -> ListUsersOffsetPaginatedResponseContent
@@ -17705,7 +17169,22 @@ client.users.get(
-Delete a user by user ID. This action cannot be undone. For Auth0 Dashboard instructions, see [Delete Users](https://auth0.com/docs/manage-users/user-accounts/delete-users). +This endpoint retrieves details of users. It's best suited to interactive, best-effort search and lookups where slightly stale results are acceptable. With it, you can: + +- Specify search criteria for users +- Sort the users to be returned +- Select the fields to be returned +- Specify the number of users to retrieve per page and the page index + +This endpoint is **not suited for use in critical paths**. It is eventually consistent and runs under a short (~2 second) query time limit, so results can be stale and heavy queries can return a 503. + +- Do not use this endpoint for authentication, account linking, or logic inside login-flow Actions. Instead, [look users up directly by ID or email](https://auth0.com/docs/manage-users/user-search/get-users-by-id-or-email#management-api) to get their current state. +- Do not use this endpoint to keep an external system in sync with user data. Instead, subscribe to [Event Streams](https://auth0.com/docs/customize/events/sync-data-across-systems) to receive every change as it happens. +- Do not use this endpoint to enumerate or export your entire user base. Instead, run a [bulk user export](https://auth0.com/docs/manage-users/user-migration/bulk-user-exports) to retrieve the full set. + +Use the `q` query parameter to match users with [query string syntax](https://auth0.com/docs/manage-users/user-search/user-search-query-syntax). For full instructions and guidance, see [How to List and Search Users](https://auth0.com/docs/manage-users/user-search/list-and-search-users). + +For efficient queries, prefer indexed top-level fields and exact matches. Certain kinds of queries can be slow and may time out, such as filtering on freeform or multi-value fields (like user-defined attributes in `app_metadata` or `user_metadata`) or using leading wildcards.
@@ -17728,8 +17207,17 @@ client = Auth0( environment=Auth0Environment.DEFAULT, ) -client.users.delete( - id="id", +client.users.list( + page=1, + per_page=1, + include_totals=True, + sort="sort", + connection="connection", + fields="fields", + include_fields=True, + q="q", + search_engine="v1", + primary_order=True, ) ``` @@ -17746,7 +17234,7 @@ client.users.delete(
-**id:** `str` — ID of the user to delete. +**page:** `typing.Optional[int]` — Page index of the results to return. First page is 0.
@@ -17754,121 +17242,105 @@ client.users.delete(
-**request_options:** `typing.Optional[RequestOptions]` — Request-specific configuration. +**per_page:** `typing.Optional[int]` — Number of results per page.
- -
+
+
+**include_totals:** `typing.Optional[bool]` — Return results inside an object that contains the total result count (true) or as a direct array of results (false, default). +
-
-
client.users.update(...) -> UpdateUserResponseContent
-#### 📝 Description +**sort:** `typing.Optional[str]` — Field to sort by. Use field:order where order is 1 for ascending and -1 for descending. e.g. created_at:1 + +
+
+**connection:** `typing.Optional[str]` — Connection filter. Only applies when using search_engine=v1. To filter by connection with search_engine=v2|v3, use q=identities.connection:"connection_name" + +
+
+
-Update a user. - -These are the attributes that can be updated at the root level: +**fields:** `typing.Optional[str]` — Comma-separated list of fields to include or exclude (based on value provided for include_fields) in the result. Leave empty to retrieve all fields. + +
+
-- app_metadata -- blocked -- email -- email_verified -- family_name -- given_name -- name -- nickname -- password -- phone_number -- phone_verified -- picture -- username -- user_metadata -- verify_email +
+
-Some considerations: +**include_fields:** `typing.Optional[bool]` — Whether specified fields are to be included (true) or excluded (false). + +
+
-- The properties of the new object will replace the old ones. -- The metadata fields are an exception to this rule (`user_metadata` and `app_metadata`). These properties are merged instead of being replaced but be careful, the merge only occurs on the first level. -- If you are updating `email`, `email_verified`, `phone_number`, `phone_verified`, `username` or `password` of a secondary identity, you need to specify the `connection` property too. -- If you are updating `email` or `phone_number` you can specify, optionally, the `client_id` property. -- Updating `email_verified` is not supported for enterprise and passwordless sms connections. -- Updating the `blocked` to `false` does not affect the user's blocked state from an excessive amount of incorrectly provided credentials. Use the "Unblock a user" endpoint from the "User Blocks" API to change the user's state. -- Supported attributes can be unset by supplying `null` as the value. +
+
-**Updating a field (non-metadata property)** +**q:** `typing.Optional[str]` — Query in Lucene query string syntax. Some query types cannot be used on metadata fields, for details see Searchable Fields. + +
+
-To mark the email address of a user as verified, the body to send should be: +
+
-```json -{ "email_verified": true } -``` +**search_engine:** `typing.Optional[SearchEngineVersionsEnum]` — The version of the search engine + +
+
-**Updating a user metadata root property** +
+
-Let's assume that our test user has the following `user_metadata`: +**primary_order:** `typing.Optional[bool]` — If true (default), results are returned in a deterministic order. If false, results may be returned in a non-deterministic order, which can enhance performance for complex queries targeting a small number of users. Set to false only when consistent ordering and pagination is not required. + +
+
-```json -{ "user_metadata" : { "profileCode": 1479 } } -``` +
+
-To add the field `addresses` the body to send should be: +**request_options:** `typing.Optional[RequestOptions]` — Request-specific configuration. + +
+
+ + -```json -{ "user_metadata" : { "addresses": {"work_address": "100 Industrial Way"} }} -``` -The modified object ends up with the following `user_metadata` property: + + +
-```json -{ - "user_metadata": { - "profileCode": 1479, - "addresses": { "work_address": "100 Industrial Way" } - } -} -``` +
client.users.create(...) -> CreateUserResponseContent +
+
-**Updating an inner user metadata property** +#### 📝 Description -If there's existing user metadata to which we want to add `"home_address": "742 Evergreen Terrace"` (using the `addresses` property) we should send the whole `addresses` object. Since this is a first-level object, the object will be merged in, but its own properties will not be. The body to send should be: +
+
-```json -{ - "user_metadata": { - "addresses": { - "work_address": "100 Industrial Way", - "home_address": "742 Evergreen Terrace" - } - } -} -``` +
+
-The modified object ends up with the following `user_metadata` property: +Create a new user for a given [database](https://auth0.com/docs/connections/database) or [passwordless](https://auth0.com/docs/connections/passwordless) connection. -```json -{ - "user_metadata": { - "profileCode": 1479, - "addresses": { - "work_address": "100 Industrial Way", - "home_address": "742 Evergreen Terrace" - } - } -} -``` +Note: `connection` is required but other parameters such as `email` and `password` are dependent upon the type of connection.
@@ -17891,8 +17363,8 @@ client = Auth0( environment=Auth0Environment.DEFAULT, ) -client.users.update( - id="id", +client.users.create( + connection="connection", ) ``` @@ -17909,23 +17381,7 @@ client.users.update(
-**id:** `str` — ID of the user to update. - -
-
- -
-
- -**blocked:** `typing.Optional[bool]` — Whether this user was blocked by an administrator (true) or not (false). - -
-
- -
-
- -**email_verified:** `typing.Optional[bool]` — Whether this email address is verified (true) or unverified (false). If set to false the user will not receive a verification email unless `verify_email` is set to true. +**connection:** `str` — Name of the connection this user should be created in.
@@ -17933,7 +17389,7 @@ client.users.update(
-**email:** `typing.Optional[str]` — Email address of this user. +**email:** `typing.Optional[str]` — The user's email.
@@ -17949,7 +17405,7 @@ client.users.update(
-**phone_verified:** `typing.Optional[bool]` — Whether this phone number has been verified (true) or not (false). +**user_metadata:** `typing.Optional[UserMetadata]`
@@ -17957,7 +17413,7 @@ client.users.update(
-**user_metadata:** `typing.Optional[UserMetadata]` — User metadata to which this user has read/write access. +**blocked:** `typing.Optional[bool]` — Whether this user was blocked by an administrator (true) or not (false).
@@ -17965,7 +17421,7 @@ client.users.update(
-**app_metadata:** `typing.Optional[AppMetadata]` — User metadata to which this user has read-only access. +**email_verified:** `typing.Optional[bool]` — Whether this email address is verified (true) or unverified (false). User will receive a verification email after creation if `email_verified` is false or not specified
@@ -17973,7 +17429,7 @@ client.users.update(
-**given_name:** `typing.Optional[str]` — Given name/first name/forename of this user. +**phone_verified:** `typing.Optional[bool]` — Whether this phone number has been verified (true) or not (false).
@@ -17981,7 +17437,7 @@ client.users.update(
-**family_name:** `typing.Optional[str]` — Family name/last name/surname of this user. +**app_metadata:** `typing.Optional[AppMetadata]`
@@ -17989,7 +17445,7 @@ client.users.update(
-**name:** `typing.Optional[str]` — Name of this user. +**given_name:** `typing.Optional[str]` — The user's given name(s).
@@ -17997,7 +17453,7 @@ client.users.update(
-**nickname:** `typing.Optional[str]` — Preferred nickname or alias of this user. +**family_name:** `typing.Optional[str]` — The user's family name(s).
@@ -18005,7 +17461,7 @@ client.users.update(
-**picture:** `typing.Optional[str]` — URL to picture, photo, or avatar of this user. +**name:** `typing.Optional[str]` — The user's full name.
@@ -18013,7 +17469,7 @@ client.users.update(
-**verify_email:** `typing.Optional[bool]` — Whether this user will receive a verification email after creation (true) or no email (false). Overrides behavior of `email_verified` parameter. +**nickname:** `typing.Optional[str]` — The user's nickname.
@@ -18021,7 +17477,7 @@ client.users.update(
-**verify_phone_number:** `typing.Optional[bool]` — Whether this user will receive a text after changing the phone number (true) or no text (false). Only valid when changing phone number for SMS connections. +**picture:** `typing.Optional[str]` — A URI pointing to the user's picture.
@@ -18029,7 +17485,7 @@ client.users.update(
-**password:** `typing.Optional[str]` — New password for this user. Only valid for database connections. +**user_id:** `typing.Optional[str]` — The external user's id provided by the identity provider.
@@ -18037,7 +17493,7 @@ client.users.update(
-**connection:** `typing.Optional[str]` — Name of the connection to target for this user update. +**password:** `typing.Optional[str]` — Initial password for this user. Only valid for auth0 connection strategy.
@@ -18045,7 +17501,7 @@ client.users.update(
-**client_id:** `typing.Optional[str]` — Auth0 client ID. Only valid when updating email address. +**verify_email:** `typing.Optional[bool]` — Whether the user will receive a verification email after creation (true) or no email (false). Overrides behavior of `email_verified` parameter.
@@ -18073,7 +17529,7 @@ client.users.update(
-
client.users.regenerate_recovery_code(...) -> RegenerateUsersRecoveryCodeResponseContent +
client.users.list_users_by_email(...) -> typing.List[UserResponseSchema]
@@ -18085,7 +17541,11 @@ client.users.update(
-Remove an existing multi-factor authentication (MFA) [recovery code](https://auth0.com/docs/secure/multi-factor-authentication/reset-user-mfa) and generate a new one. If a user cannot access the original device or account used for MFA enrollment, they can use a recovery code to authenticate. +Find users by email. If Auth0 is the identity provider (idP), the email address associated with a user is saved in lower case, regardless of how you initially provided it. + +For example, if you register a user as JohnSmith@example.com, Auth0 saves the user's email as johnsmith@example.com. + +Therefore, when using this endpoint, make sure that you are searching for users via email addresses using the correct case.
@@ -18108,8 +17568,10 @@ client = Auth0( environment=Auth0Environment.DEFAULT, ) -client.users.regenerate_recovery_code( - id="id", +client.users.list_users_by_email( + fields="fields", + include_fields=True, + email="email", ) ``` @@ -18126,7 +17588,23 @@ client.users.regenerate_recovery_code(
-**id:** `str` — ID of the user to regenerate a multi-factor authentication recovery code for. +**email:** `str` — Email address to search for (case-sensitive). + +
+
+ +
+
+ +**fields:** `typing.Optional[str]` — Comma-separated list of fields to include or exclude (based on value provided for include_fields) in the result. Leave empty to retrieve all fields. + +
+
+ +
+
+ +**include_fields:** `typing.Optional[bool]` — Whether specified fields are to be included (true) or excluded (false). Defaults to true.
@@ -18146,7 +17624,7 @@ client.users.regenerate_recovery_code(
-
client.users.revoke_access(...) +
client.users.get(...) -> GetUserResponseContent
@@ -18158,7 +17636,7 @@ client.users.regenerate_recovery_code(
-Revokes selected resources related to a user (sessions, refresh tokens, ...). +Retrieve user details. A list of fields to include or exclude may also be specified. For more information, see [Retrieve Users with the Get Users Endpoint](https://auth0.com/docs/manage-users/user-search/retrieve-users-with-get-users-endpoint).
@@ -18181,8 +17659,10 @@ client = Auth0( environment=Auth0Environment.DEFAULT, ) -client.users.revoke_access( +client.users.get( id="id", + fields="fields", + include_fields=True, ) ``` @@ -18199,7 +17679,7 @@ client.users.revoke_access(
-**id:** `str` — ID of the user. +**id:** `str` — ID of the user to retrieve.
@@ -18207,7 +17687,7 @@ client.users.revoke_access(
-**session_id:** `typing.Optional[str]` — ID of the session to revoke. +**fields:** `typing.Optional[str]` — Comma-separated list of fields to include or exclude (based on value provided for include_fields) in the result. Leave empty to retrieve all fields.
@@ -18215,7 +17695,7 @@ client.users.revoke_access(
-**preserve_refresh_tokens:** `typing.Optional[bool]` — Whether to preserve the refresh tokens associated with the session. +**include_fields:** `typing.Optional[bool]` — Whether specified fields are to be included (true) or excluded (false).
@@ -18235,8 +17715,7 @@ client.users.revoke_access(
-## Actions Versions -
client.actions.versions.list(...) -> ListActionVersionsPaginatedResponseContent +
client.users.delete(...)
@@ -18248,7 +17727,7 @@ client.users.revoke_access(
-Retrieve all of an action's versions. An action version is created whenever an action is deployed. An action version is immutable, once created. +Delete a user by user ID. This action cannot be undone. For Auth0 Dashboard instructions, see [Delete Users](https://auth0.com/docs/manage-users/user-accounts/delete-users).
@@ -18271,10 +17750,8 @@ client = Auth0( environment=Auth0Environment.DEFAULT, ) -client.actions.versions.list( - action_id="actionId", - page=1, - per_page=1, +client.users.delete( + id="id", ) ``` @@ -18291,23 +17768,7 @@ client.actions.versions.list(
-**action_id:** `str` — The ID of the action. - -
-
- -
-
- -**page:** `typing.Optional[int]` — Use this field to request a specific page of the list results. - -
-
- -
-
- -**per_page:** `typing.Optional[int]` — This field specify the maximum number of results to be returned by the server. 20 by default +**id:** `str` — ID of the user to delete.
@@ -18327,7 +17788,7 @@ client.actions.versions.list(
-
client.actions.versions.get(...) -> GetActionVersionResponseContent +
client.users.update(...) -> UpdateUserResponseContent
@@ -18339,7 +17800,97 @@ client.actions.versions.list(
-Retrieve a specific version of an action. An action version is created whenever an action is deployed. An action version is immutable, once created. +Update a user. + +These are the attributes that can be updated at the root level: + +- app_metadata +- blocked +- email +- email_verified +- family_name +- given_name +- name +- nickname +- password +- phone_number +- phone_verified +- picture +- username +- user_metadata +- verify_email + +Some considerations: + +- The properties of the new object will replace the old ones. +- The metadata fields are an exception to this rule (`user_metadata` and `app_metadata`). These properties are merged instead of being replaced but be careful, the merge only occurs on the first level. +- If you are updating `email`, `email_verified`, `phone_number`, `phone_verified`, `username` or `password` of a secondary identity, you need to specify the `connection` property too. +- If you are updating `email` or `phone_number` you can specify, optionally, the `client_id` property. +- Updating `email_verified` is not supported for enterprise and passwordless sms connections. +- Updating the `blocked` to `false` does not affect the user's blocked state from an excessive amount of incorrectly provided credentials. Use the "Unblock a user" endpoint from the "User Blocks" API to change the user's state. +- Supported attributes can be unset by supplying `null` as the value. + +**Updating a field (non-metadata property)** + +To mark the email address of a user as verified, the body to send should be: + +```json +{ "email_verified": true } +``` + +**Updating a user metadata root property** + +Let's assume that our test user has the following `user_metadata`: + +```json +{ "user_metadata" : { "profileCode": 1479 } } +``` + +To add the field `addresses` the body to send should be: + +```json +{ "user_metadata" : { "addresses": {"work_address": "100 Industrial Way"} }} +``` + +The modified object ends up with the following `user_metadata` property: + +```json +{ + "user_metadata": { + "profileCode": 1479, + "addresses": { "work_address": "100 Industrial Way" } + } +} +``` + +**Updating an inner user metadata property** + +If there's existing user metadata to which we want to add `"home_address": "742 Evergreen Terrace"` (using the `addresses` property) we should send the whole `addresses` object. Since this is a first-level object, the object will be merged in, but its own properties will not be. The body to send should be: + +```json +{ + "user_metadata": { + "addresses": { + "work_address": "100 Industrial Way", + "home_address": "742 Evergreen Terrace" + } + } +} +``` + +The modified object ends up with the following `user_metadata` property: + +```json +{ + "user_metadata": { + "profileCode": 1479, + "addresses": { + "work_address": "100 Industrial Way", + "home_address": "742 Evergreen Terrace" + } + } +} +```
@@ -18362,8 +17913,7 @@ client = Auth0( environment=Auth0Environment.DEFAULT, ) -client.actions.versions.get( - action_id="actionId", +client.users.update( id="id", ) @@ -18381,7 +17931,7 @@ client.actions.versions.get(
-**action_id:** `str` — The ID of the action. +**id:** `str` — ID of the user to update.
@@ -18389,7 +17939,7 @@ client.actions.versions.get(
-**id:** `str` — The ID of the action version. +**blocked:** `typing.Optional[bool]` — Whether this user was blocked by an administrator (true) or not (false).
@@ -18397,74 +17947,119 @@ client.actions.versions.get(
-**request_options:** `typing.Optional[RequestOptions]` — Request-specific configuration. +**email_verified:** `typing.Optional[bool]` — Whether this email address is verified (true) or unverified (false). If set to false the user will not receive a verification email unless `verify_email` is set to true.
+ +
+
+ +**email:** `typing.Optional[str]` — Email address of this user. +
+
+
+**phone_number:** `typing.Optional[str]` — The user's phone number (following the E.164 recommendation). +
-
-
client.actions.versions.deploy(...) -> DeployActionVersionResponseContent
-#### 📝 Description +**phone_verified:** `typing.Optional[bool]` — Whether this phone number has been verified (true) or not (false). + +
+
+**user_metadata:** `typing.Optional[UserMetadata]` — User metadata to which this user has read/write access. + +
+
+
-Performs the equivalent of a roll-back of an action to an earlier, specified version. Creates a new, deployed action version that is identical to the specified version. If this action is currently bound to a trigger, the system will begin executing the newly-created version immediately. +**app_metadata:** `typing.Optional[AppMetadata]` — User metadata to which this user has read-only access. +
+ +
+
+ +**given_name:** `typing.Optional[str]` — Given name/first name/forename of this user. +
-#### 🔌 Usage -
+**family_name:** `typing.Optional[str]` — Family name/last name/surname of this user. + +
+
+
-```python -from auth0.management import Auth0, DeployActionVersionRequestContent -from auth0.management.environment import Auth0Environment +**name:** `typing.Optional[str]` — Name of this user. + +
+
-client = Auth0( - token="", - environment=Auth0Environment.DEFAULT, -) +
+
-client.actions.versions.deploy( - action_id="actionId", - id="id", - request=DeployActionVersionRequestContent(), -) +**nickname:** `typing.Optional[str]` — Preferred nickname or alias of this user. + +
+
-``` +
+
+ +**picture:** `typing.Optional[str]` — URL to picture, photo, or avatar of this user. +
+ +
+
+ +**verify_email:** `typing.Optional[bool]` — Whether this user will receive a verification email after creation (true) or no email (false). Overrides behavior of `email_verified` parameter. +
-#### ⚙️ Parameters +
+
+ +**verify_phone_number:** `typing.Optional[bool]` — Whether this user will receive a text after changing the phone number (true) or no text (false). Only valid when changing phone number for SMS connections. + +
+
+**password:** `typing.Optional[str]` — New password for this user. Only valid for database connections. + +
+
+
-**action_id:** `str` — The ID of an action. +**connection:** `typing.Optional[str]` — Name of the connection to target for this user update.
@@ -18472,7 +18067,7 @@ client.actions.versions.deploy(
-**id:** `str` — The ID of an action version. +**client_id:** `typing.Optional[str]` — Auth0 client ID. Only valid when updating email address.
@@ -18480,7 +18075,7 @@ client.actions.versions.deploy(
-**request:** `typing.Optional[DeployActionVersionRequestContent]` +**username:** `typing.Optional[str]` — The user's username. Only valid if the connection requires a username.
@@ -18500,8 +18095,7 @@ client.actions.versions.deploy(
-## Actions Executions -
client.actions.executions.get(...) -> GetActionExecutionResponseContent +
client.users.regenerate_recovery_code(...) -> RegenerateUsersRecoveryCodeResponseContent
@@ -18513,7 +18107,7 @@ client.actions.versions.deploy(
-Retrieve information about a specific execution of a trigger. Relevant execution IDs will be included in tenant logs generated as part of that authentication flow. Executions will only be stored for 10 days after their creation. +Remove an existing multi-factor authentication (MFA) [recovery code](https://auth0.com/docs/secure/multi-factor-authentication/reset-user-mfa) and generate a new one. If a user cannot access the original device or account used for MFA enrollment, they can use a recovery code to authenticate.
@@ -18536,7 +18130,7 @@ client = Auth0( environment=Auth0Environment.DEFAULT, ) -client.actions.executions.get( +client.users.regenerate_recovery_code( id="id", ) @@ -18554,7 +18148,7 @@ client.actions.executions.get(
-**id:** `str` — The ID of the execution to retrieve. +**id:** `str` — ID of the user to regenerate a multi-factor authentication recovery code for.
@@ -18574,8 +18168,7 @@ client.actions.executions.get(
-## Actions Modules -
client.actions.modules.list(...) -> GetActionModulesResponseContent +
client.users.revoke_access(...)
@@ -18587,7 +18180,7 @@ client.actions.executions.get(
-Retrieve a paginated list of all Actions Modules with optional filtering and totals. +Revokes selected resources related to a user (sessions, refresh tokens, ...).
@@ -18610,9 +18203,8 @@ client = Auth0( environment=Auth0Environment.DEFAULT, ) -client.actions.modules.list( - page=1, - per_page=1, +client.users.revoke_access( + id="id", ) ``` @@ -18629,7 +18221,7 @@ client.actions.modules.list(
-**page:** `typing.Optional[int]` — Page index of the results to return. First page is 0. +**id:** `str` — ID of the user.
@@ -18637,7 +18229,15 @@ client.actions.modules.list(
-**per_page:** `typing.Optional[int]` — Number of results per page. Paging is disabled if parameter not sent. +**session_id:** `typing.Optional[str]` — ID of the session to revoke. + +
+
+ +
+
+ +**preserve_refresh_tokens:** `typing.Optional[bool]` — Whether to preserve the refresh tokens associated with the session.
@@ -18657,7 +18257,8 @@ client.actions.modules.list(
-
client.actions.modules.create(...) -> CreateActionModuleResponseContent +## Actions Versions +
client.actions.versions.list(...) -> ListActionVersionsPaginatedResponseContent
@@ -18669,7 +18270,7 @@ client.actions.modules.list(
-Create a new Actions Module for reusable code across actions. +Retrieve all of an action's versions. An action version is created whenever an action is deployed. An action version is immutable, once created.
@@ -18692,9 +18293,10 @@ client = Auth0( environment=Auth0Environment.DEFAULT, ) -client.actions.modules.create( - name="name", - code="code", +client.actions.versions.list( + action_id="actionId", + page=1, + per_page=1, ) ``` @@ -18711,31 +18313,7 @@ client.actions.modules.create(
-**name:** `str` — The name of the action module. - -
-
- -
-
- -**code:** `str` — The source code of the action module. - -
-
- -
-
- -**secrets:** `typing.Optional[typing.List[ActionModuleSecretRequest]]` — The secrets to associate with the action module. - -
-
- -
-
- -**dependencies:** `typing.Optional[typing.List[ActionModuleDependencyRequest]]` — The npm dependencies of the action module. +**action_id:** `str` — The ID of the action.
@@ -18743,7 +18321,7 @@ client.actions.modules.create(
-**api_version:** `typing.Optional[str]` — The API version of the module. +**page:** `typing.Optional[int]` — Use this field to request a specific page of the list results.
@@ -18751,7 +18329,7 @@ client.actions.modules.create(
-**publish:** `typing.Optional[bool]` — Whether to publish the module immediately after creation. +**per_page:** `typing.Optional[int]` — This field specify the maximum number of results to be returned by the server. 20 by default
@@ -18771,7 +18349,7 @@ client.actions.modules.create(
-
client.actions.modules.get(...) -> GetActionModuleResponseContent +
client.actions.versions.get(...) -> GetActionVersionResponseContent
@@ -18783,7 +18361,7 @@ client.actions.modules.create(
-Retrieve details of a specific Actions Module by its unique identifier. +Retrieve a specific version of an action. An action version is created whenever an action is deployed. An action version is immutable, once created.
@@ -18806,7 +18384,8 @@ client = Auth0( environment=Auth0Environment.DEFAULT, ) -client.actions.modules.get( +client.actions.versions.get( + action_id="actionId", id="id", ) @@ -18824,7 +18403,15 @@ client.actions.modules.get(
-**id:** `str` — The ID of the action module to retrieve. +**action_id:** `str` — The ID of the action. + +
+
+ +
+
+ +**id:** `str` — The ID of the action version.
@@ -18844,7 +18431,7 @@ client.actions.modules.get(
-
client.actions.modules.delete(...) +
client.actions.versions.deploy(...) -> DeployActionVersionResponseContent
@@ -18856,7 +18443,7 @@ client.actions.modules.get(
-Permanently delete an Actions Module. This will fail if the module is still in use by any actions. +Performs the equivalent of a roll-back of an action to an earlier, specified version. Creates a new, deployed action version that is identical to the specified version. If this action is currently bound to a trigger, the system will begin executing the newly-created version immediately.
@@ -18871,7 +18458,7 @@ Permanently delete an Actions Module. This will fail if the module is still in u
```python -from auth0.management import Auth0 +from auth0.management import Auth0, DeployActionVersionRequestContent from auth0.management.environment import Auth0Environment client = Auth0( @@ -18879,8 +18466,10 @@ client = Auth0( environment=Auth0Environment.DEFAULT, ) -client.actions.modules.delete( +client.actions.versions.deploy( + action_id="actionId", id="id", + request=DeployActionVersionRequestContent(), ) ``` @@ -18897,7 +18486,23 @@ client.actions.modules.delete(
-**id:** `str` — The ID of the Actions Module to delete. +**action_id:** `str` — The ID of an action. + +
+
+ +
+
+ +**id:** `str` — The ID of an action version. + +
+
+ +
+
+ +**request:** `typing.Optional[DeployActionVersionRequestContent]`
@@ -18917,7 +18522,8 @@ client.actions.modules.delete(
-
client.actions.modules.update(...) -> UpdateActionModuleResponseContent +## Actions Executions +
client.actions.executions.get(...) -> GetActionExecutionResponseContent
@@ -18929,7 +18535,7 @@ client.actions.modules.delete(
-Update properties of an existing Actions Module, such as code, dependencies, or secrets. +Retrieve information about a specific execution of a trigger. Relevant execution IDs will be included in tenant logs generated as part of that authentication flow. Executions will only be stored for 10 days after their creation.
@@ -18952,7 +18558,7 @@ client = Auth0( environment=Auth0Environment.DEFAULT, ) -client.actions.modules.update( +client.actions.executions.get( id="id", ) @@ -18970,31 +18576,7 @@ client.actions.modules.update(
-**id:** `str` — The ID of the action module to update. - -
-
- -
-
- -**code:** `typing.Optional[str]` — The source code of the action module. - -
-
- -
-
- -**secrets:** `typing.Optional[typing.List[ActionModuleSecretRequest]]` — The secrets to associate with the action module. - -
-
- -
-
- -**dependencies:** `typing.Optional[typing.List[ActionModuleDependencyRequest]]` — The npm dependencies of the action module. +**id:** `str` — The ID of the execution to retrieve.
@@ -19014,7 +18596,8 @@ client.actions.modules.update(
-
client.actions.modules.list_actions(...) -> GetActionModuleActionsResponseContent +## Actions Modules +
client.actions.modules.list(...) -> GetActionModulesResponseContent
@@ -19026,7 +18609,7 @@ client.actions.modules.update(
-Lists all actions that are using a specific Actions Module, showing which deployed action versions reference this Actions Module. +Retrieve a paginated list of all Actions Modules with optional filtering and totals.
@@ -19049,8 +18632,7 @@ client = Auth0( environment=Auth0Environment.DEFAULT, ) -client.actions.modules.list_actions( - id="id", +client.actions.modules.list( page=1, per_page=1, ) @@ -19069,14 +18651,6 @@ client.actions.modules.list_actions(
-**id:** `str` — The unique ID of the module. - -
-
- -
-
- **page:** `typing.Optional[int]` — Page index of the results to return. First page is 0.
@@ -19085,7 +18659,7 @@ client.actions.modules.list_actions(
-**per_page:** `typing.Optional[int]` — Number of results per page. +**per_page:** `typing.Optional[int]` — Number of results per page. Paging is disabled if parameter not sent.
@@ -19105,7 +18679,7 @@ client.actions.modules.list_actions(
-
client.actions.modules.rollback(...) -> RollbackActionModuleResponseContent +
client.actions.modules.create(...) -> CreateActionModuleResponseContent
@@ -19117,7 +18691,7 @@ client.actions.modules.list_actions(
-Rolls back an Actions Module's draft to a previously created version. This action copies the code, dependencies, and secrets from the specified version into the current draft. +Create a new Actions Module for reusable code across actions.
@@ -19140,9 +18714,9 @@ client = Auth0( environment=Auth0Environment.DEFAULT, ) -client.actions.modules.rollback( - id="id", - module_version_id="module_version_id", +client.actions.modules.create( + name="name", + code="code", ) ``` @@ -19159,7 +18733,7 @@ client.actions.modules.rollback(
-**id:** `str` — The unique ID of the module to roll back. +**name:** `str` — The name of the action module.
@@ -19167,7 +18741,39 @@ client.actions.modules.rollback(
-**module_version_id:** `str` — The unique ID of the module version to roll back to. +**code:** `str` — The source code of the action module. + +
+
+ +
+
+ +**secrets:** `typing.Optional[typing.List[ActionModuleSecretRequest]]` — The secrets to associate with the action module. + +
+
+ +
+
+ +**dependencies:** `typing.Optional[typing.List[ActionModuleDependencyRequest]]` — The npm dependencies of the action module. + +
+
+ +
+
+ +**api_version:** `typing.Optional[str]` — The API version of the module. + +
+
+ +
+
+ +**publish:** `typing.Optional[bool]` — Whether to publish the module immediately after creation.
@@ -19187,8 +18793,7 @@ client.actions.modules.rollback(
-## Actions Triggers -
client.actions.triggers.list() -> ListActionTriggersResponseContent +
client.actions.modules.get(...) -> GetActionModuleResponseContent
@@ -19200,7 +18805,7 @@ client.actions.modules.rollback(
-Retrieve the set of triggers currently available within actions. A trigger is an extensibility point to which actions can be bound. +Retrieve details of a specific Actions Module by its unique identifier.
@@ -19223,7 +18828,9 @@ client = Auth0( environment=Auth0Environment.DEFAULT, ) -client.actions.triggers.list() +client.actions.modules.get( + id="id", +) ``` @@ -19239,6 +18846,14 @@ client.actions.triggers.list()
+**id:** `str` — The ID of the action module to retrieve. + +
+
+ +
+
+ **request_options:** `typing.Optional[RequestOptions]` — Request-specific configuration.
@@ -19251,8 +18866,7 @@ client.actions.triggers.list()
-## Actions Modules Versions -
client.actions.modules.versions.list(...) -> GetActionModuleVersionsResponseContent +
client.actions.modules.delete(...)
@@ -19264,7 +18878,7 @@ client.actions.triggers.list()
-List all published versions of a specific Actions Module. +Permanently delete an Actions Module. This will fail if the module is still in use by any actions.
@@ -19287,10 +18901,8 @@ client = Auth0( environment=Auth0Environment.DEFAULT, ) -client.actions.modules.versions.list( +client.actions.modules.delete( id="id", - page=1, - per_page=1, ) ``` @@ -19307,23 +18919,7 @@ client.actions.modules.versions.list(
-**id:** `str` — The unique ID of the module. - -
-
- -
-
- -**page:** `typing.Optional[int]` — Use this field to request a specific page of the list results. - -
-
- -
-
- -**per_page:** `typing.Optional[int]` — The maximum number of results to be returned by the server in a single response. 20 by default. +**id:** `str` — The ID of the Actions Module to delete.
@@ -19343,7 +18939,7 @@ client.actions.modules.versions.list(
-
client.actions.modules.versions.create(...) -> CreateActionModuleVersionResponseContent +
client.actions.modules.update(...) -> UpdateActionModuleResponseContent
@@ -19355,7 +18951,7 @@ client.actions.modules.versions.list(
-Creates a new immutable version of an Actions Module from the current draft version. This publishes the draft as a new version that can be referenced by actions, while maintaining the existing draft for continued development. +Update properties of an existing Actions Module, such as code, dependencies, or secrets.
@@ -19378,7 +18974,7 @@ client = Auth0( environment=Auth0Environment.DEFAULT, ) -client.actions.modules.versions.create( +client.actions.modules.update( id="id", ) @@ -19396,7 +18992,31 @@ client.actions.modules.versions.create(
-**id:** `str` — The ID of the action module to create a version for. +**id:** `str` — The ID of the action module to update. + +
+
+ +
+
+ +**code:** `typing.Optional[str]` — The source code of the action module. + +
+
+ +
+
+ +**secrets:** `typing.Optional[typing.List[ActionModuleSecretRequest]]` — The secrets to associate with the action module. + +
+
+ +
+
+ +**dependencies:** `typing.Optional[typing.List[ActionModuleDependencyRequest]]` — The npm dependencies of the action module.
@@ -19416,7 +19036,7 @@ client.actions.modules.versions.create(
-
client.actions.modules.versions.get(...) -> GetActionModuleVersionResponseContent +
client.actions.modules.list_actions(...) -> GetActionModuleActionsResponseContent
@@ -19428,7 +19048,7 @@ client.actions.modules.versions.create(
-Retrieve the details of a specific, immutable version of an Actions Module. +Lists all actions that are using a specific Actions Module, showing which deployed action versions reference this Actions Module.
@@ -19451,9 +19071,10 @@ client = Auth0( environment=Auth0Environment.DEFAULT, ) -client.actions.modules.versions.get( +client.actions.modules.list_actions( id="id", - version_id="versionId", + page=1, + per_page=1, ) ``` @@ -19478,7 +19099,15 @@ client.actions.modules.versions.get(
-**version_id:** `str` — The unique ID of the module version to retrieve. +**page:** `typing.Optional[int]` — Page index of the results to return. First page is 0. + +
+
+ +
+
+ +**per_page:** `typing.Optional[int]` — Number of results per page.
@@ -19498,8 +19127,7 @@ client.actions.modules.versions.get(
-## Actions Triggers Bindings -
client.actions.triggers.bindings.list(...) -> ListActionBindingsPaginatedResponseContent +
client.actions.modules.rollback(...) -> RollbackActionModuleResponseContent
@@ -19511,7 +19139,7 @@ client.actions.modules.versions.get(
-Retrieve the actions that are bound to a trigger. Once an action is created and deployed, it must be attached (i.e. bound) to a trigger so that it will be executed as part of a flow. The list of actions returned reflects the order in which they will be executed during the appropriate flow. +Rolls back an Actions Module's draft to a previously created version. This action copies the code, dependencies, and secrets from the specified version into the current draft.
@@ -19534,10 +19162,9 @@ client = Auth0( environment=Auth0Environment.DEFAULT, ) -client.actions.triggers.bindings.list( - trigger_id="post-login", - page=1, - per_page=1, +client.actions.modules.rollback( + id="id", + module_version_id="module_version_id", ) ``` @@ -19554,7 +19181,7 @@ client.actions.triggers.bindings.list(
-**trigger_id:** `ActionTriggerTypeEnum` — An actions extensibility point. +**id:** `str` — The unique ID of the module to roll back.
@@ -19562,7 +19189,7 @@ client.actions.triggers.bindings.list(
-**page:** `typing.Optional[int]` — Use this field to request a specific page of the list results. +**module_version_id:** `str` — The unique ID of the module version to roll back to.
@@ -19570,11 +19197,67 @@ client.actions.triggers.bindings.list(
-**per_page:** `typing.Optional[int]` — The maximum number of results to be returned in a single request. 20 by default +**request_options:** `typing.Optional[RequestOptions]` — Request-specific configuration. +
+
+ +
+ + + + +
+ +## Actions Triggers +
client.actions.triggers.list() -> ListActionTriggersResponseContent +
+
+ +#### 📝 Description + +
+
+ +
+
+ +Retrieve the set of triggers currently available within actions. A trigger is an extensibility point to which actions can be bound. +
+
+#### 🔌 Usage + +
+
+ +
+
+ +```python +from auth0.management import Auth0 +from auth0.management.environment import Auth0Environment + +client = Auth0( + token="", + environment=Auth0Environment.DEFAULT, +) + +client.actions.triggers.list() + +``` +
+
+
+
+ +#### ⚙️ Parameters + +
+
+
@@ -19590,7 +19273,8 @@ client.actions.triggers.bindings.list(
-
client.actions.triggers.bindings.update_many(...) -> UpdateActionBindingsResponseContent +## Actions Modules Versions +
client.actions.modules.versions.list(...) -> GetActionModuleVersionsResponseContent
@@ -19602,7 +19286,7 @@ client.actions.triggers.bindings.list(
-Update the actions that are bound (i.e. attached) to a trigger. Once an action is created and deployed, it must be attached (i.e. bound) to a trigger so that it will be executed as part of a flow. The order in which the actions are provided will determine the order in which they are executed. +List all published versions of a specific Actions Module.
@@ -19625,8 +19309,10 @@ client = Auth0( environment=Auth0Environment.DEFAULT, ) -client.actions.triggers.bindings.update_many( - trigger_id="post-login", +client.actions.modules.versions.list( + id="id", + page=1, + per_page=1, ) ``` @@ -19643,7 +19329,7 @@ client.actions.triggers.bindings.update_many(
-**trigger_id:** `ActionTriggerTypeEnum` — An actions extensibility point. +**id:** `str` — The unique ID of the module.
@@ -19651,7 +19337,15 @@ client.actions.triggers.bindings.update_many(
-**bindings:** `typing.Optional[typing.List[ActionBindingWithRef]]` — The actions that will be bound to this trigger. The order in which they are included will be the order in which they are executed. +**page:** `typing.Optional[int]` — Use this field to request a specific page of the list results. + +
+
+ +
+
+ +**per_page:** `typing.Optional[int]` — The maximum number of results to be returned by the server in a single response. 20 by default.
@@ -19671,8 +19365,7 @@ client.actions.triggers.bindings.update_many(
-## Anomaly Blocks -
client.anomaly.blocks.check_ip(...) +
client.actions.modules.versions.create(...) -> CreateActionModuleVersionResponseContent
@@ -19684,7 +19377,7 @@ client.actions.triggers.bindings.update_many(
-Check if the given IP address is blocked via the Suspicious IP Throttling due to multiple suspicious attempts. +Creates a new immutable version of an Actions Module from the current draft version. This publishes the draft as a new version that can be referenced by actions, while maintaining the existing draft for continued development.
@@ -19707,7 +19400,7 @@ client = Auth0( environment=Auth0Environment.DEFAULT, ) -client.anomaly.blocks.check_ip( +client.actions.modules.versions.create( id="id", ) @@ -19725,7 +19418,7 @@ client.anomaly.blocks.check_ip(
-**id:** `AnomalyIpFormat` — IP address to check. +**id:** `str` — The ID of the action module to create a version for.
@@ -19745,7 +19438,7 @@ client.anomaly.blocks.check_ip(
-
client.anomaly.blocks.unblock_ip(...) +
client.actions.modules.versions.get(...) -> GetActionModuleVersionResponseContent
@@ -19757,7 +19450,7 @@ client.anomaly.blocks.check_ip(
-Remove a block imposed by Suspicious IP Throttling for the given IP address. +Retrieve the details of a specific, immutable version of an Actions Module.
@@ -19780,8 +19473,9 @@ client = Auth0( environment=Auth0Environment.DEFAULT, ) -client.anomaly.blocks.unblock_ip( +client.actions.modules.versions.get( id="id", + version_id="versionId", ) ``` @@ -19798,7 +19492,15 @@ client.anomaly.blocks.unblock_ip(
-**id:** `AnomalyIpFormat` — IP address to unblock. +**id:** `str` — The unique ID of the module. + +
+
+ +
+
+ +**version_id:** `str` — The unique ID of the module version to retrieve.
@@ -19818,8 +19520,8 @@ client.anomaly.blocks.unblock_ip(
-## AttackProtection BotDetection -
client.attack_protection.bot_detection.get() -> GetBotDetectionSettingsResponseContent +## Actions Triggers Bindings +
client.actions.triggers.bindings.list(...) -> ListActionBindingsPaginatedResponseContent
@@ -19831,7 +19533,7 @@ client.anomaly.blocks.unblock_ip(
-Get the Bot Detection configuration of your tenant. +Retrieve the actions that are bound to a trigger. Once an action is created and deployed, it must be attached (i.e. bound) to a trigger so that it will be executed as part of a flow. The list of actions returned reflects the order in which they will be executed during the appropriate flow.
@@ -19854,7 +19556,11 @@ client = Auth0( environment=Auth0Environment.DEFAULT, ) -client.attack_protection.bot_detection.get() +client.actions.triggers.bindings.list( + trigger_id="post-login", + page=1, + per_page=1, +) ``` @@ -19870,6 +19576,30 @@ client.attack_protection.bot_detection.get()
+**trigger_id:** `ActionTriggerTypeEnum` — An actions extensibility point. + +
+
+ +
+
+ +**page:** `typing.Optional[int]` — Use this field to request a specific page of the list results. + +
+
+ +
+
+ +**per_page:** `typing.Optional[int]` — The maximum number of results to be returned in a single request. 20 by default + +
+
+ +
+
+ **request_options:** `typing.Optional[RequestOptions]` — Request-specific configuration.
@@ -19882,7 +19612,7 @@ client.attack_protection.bot_detection.get()
-
client.attack_protection.bot_detection.update(...) -> UpdateBotDetectionSettingsResponseContent +
client.actions.triggers.bindings.update_many(...) -> UpdateActionBindingsResponseContent
@@ -19894,7 +19624,7 @@ client.attack_protection.bot_detection.get()
-Update the Bot Detection configuration of your tenant. +Update the actions that are bound (i.e. attached) to a trigger. Once an action is created and deployed, it must be attached (i.e. bound) to a trigger so that it will be executed as part of a flow. The order in which the actions are provided will determine the order in which they are executed.
@@ -19917,7 +19647,9 @@ client = Auth0( environment=Auth0Environment.DEFAULT, ) -client.attack_protection.bot_detection.update() +client.actions.triggers.bindings.update_many( + trigger_id="post-login", +) ``` @@ -19933,7 +19665,7 @@ client.attack_protection.bot_detection.update()
-**bot_detection_level:** `typing.Optional[BotDetectionLevelEnum]` +**trigger_id:** `ActionTriggerTypeEnum` — An actions extensibility point.
@@ -19941,7 +19673,7 @@ client.attack_protection.bot_detection.update()
-**challenge_password_policy:** `typing.Optional[BotDetectionChallengePolicyPasswordFlowEnum]` +**bindings:** `typing.Optional[typing.List[ActionBindingWithRef]]` — The actions that will be bound to this trigger. The order in which they are included will be the order in which they are executed.
@@ -19949,15 +19681,73 @@ client.attack_protection.bot_detection.update()
-**challenge_passwordless_policy:** `typing.Optional[BotDetectionChallengePolicyPasswordlessFlowEnum]` +**request_options:** `typing.Optional[RequestOptions]` — Request-specific configuration.
+ +
+ + + +
+ +## Anomaly Blocks +
client.anomaly.blocks.check_ip(...)
-**challenge_password_reset_policy:** `typing.Optional[BotDetectionChallengePolicyPasswordResetFlowEnum]` +#### 📝 Description + +
+
+ +
+
+ +Check if the given IP address is blocked via the Suspicious IP Throttling due to multiple suspicious attempts. +
+
+
+
+ +#### 🔌 Usage + +
+
+ +
+
+ +```python +from auth0.management import Auth0 +from auth0.management.environment import Auth0Environment + +client = Auth0( + token="", + environment=Auth0Environment.DEFAULT, +) + +client.anomaly.blocks.check_ip( + id="id", +) + +``` +
+
+
+
+ +#### ⚙️ Parameters + +
+
+ +
+
+ +**id:** `AnomalyIpFormat` — IP address to check.
@@ -19965,15 +19755,72 @@ client.attack_protection.bot_detection.update()
-**allowlist:** `typing.Optional[BotDetectionAllowlist]` +**request_options:** `typing.Optional[RequestOptions]` — Request-specific configuration.
+
+
+ +
+
+
+ +
client.anomaly.blocks.unblock_ip(...)
-**monitoring_mode_enabled:** `typing.Optional[BotDetectionMonitoringModeEnabled]` +#### 📝 Description + +
+
+ +
+
+ +Remove a block imposed by Suspicious IP Throttling for the given IP address. +
+
+
+
+ +#### 🔌 Usage + +
+
+ +
+
+ +```python +from auth0.management import Auth0 +from auth0.management.environment import Auth0Environment + +client = Auth0( + token="", + environment=Auth0Environment.DEFAULT, +) + +client.anomaly.blocks.unblock_ip( + id="id", +) + +``` +
+
+
+
+ +#### ⚙️ Parameters + +
+
+ +
+
+ +**id:** `AnomalyIpFormat` — IP address to unblock.
@@ -19993,8 +19840,8 @@ client.attack_protection.bot_detection.update()
-## AttackProtection BreachedPasswordDetection -
client.attack_protection.breached_password_detection.get() -> GetBreachedPasswordDetectionSettingsResponseContent +## AttackProtection BotDetection +
client.attack_protection.bot_detection.get() -> GetBotDetectionSettingsResponseContent
@@ -20006,7 +19853,7 @@ client.attack_protection.bot_detection.update()
-Retrieve details of the Breached Password Detection configuration of your tenant. +Get the Bot Detection configuration of your tenant.
@@ -20029,7 +19876,7 @@ client = Auth0( environment=Auth0Environment.DEFAULT, ) -client.attack_protection.breached_password_detection.get() +client.attack_protection.bot_detection.get() ``` @@ -20057,7 +19904,7 @@ client.attack_protection.breached_password_detection.get()
-
client.attack_protection.breached_password_detection.update(...) -> UpdateBreachedPasswordDetectionSettingsResponseContent +
client.attack_protection.bot_detection.update(...) -> UpdateBotDetectionSettingsResponseContent
@@ -20069,7 +19916,7 @@ client.attack_protection.breached_password_detection.get()
-Update details of the Breached Password Detection configuration of your tenant. +Update the Bot Detection configuration of your tenant.
@@ -20092,7 +19939,7 @@ client = Auth0( environment=Auth0Environment.DEFAULT, ) -client.attack_protection.breached_password_detection.update() +client.attack_protection.bot_detection.update() ``` @@ -20108,7 +19955,7 @@ client.attack_protection.breached_password_detection.update()
-**enabled:** `typing.Optional[bool]` — Whether or not breached password detection is active. +**bot_detection_level:** `typing.Optional[BotDetectionLevelEnum]`
@@ -20116,10 +19963,7 @@ client.attack_protection.breached_password_detection.update()
-**shields:** `typing.Optional[typing.List[BreachedPasswordDetectionShieldsEnum]]` - -Action to take when a breached password is detected during a login. - Possible values: block, user_notification, admin_notification. +**challenge_password_policy:** `typing.Optional[BotDetectionChallengePolicyPasswordFlowEnum]`
@@ -20127,10 +19971,15 @@ Action to take when a breached password is detected during a login.
-**admin_notification_frequency:** `typing.Optional[typing.List[BreachedPasswordDetectionAdminNotificationFrequencyEnum]]` +**challenge_passwordless_policy:** `typing.Optional[BotDetectionChallengePolicyPasswordlessFlowEnum]` + +
+
-When "admin_notification" is enabled, determines how often email notifications are sent. - Possible values: immediately, daily, weekly, monthly. +
+
+ +**challenge_password_reset_policy:** `typing.Optional[BotDetectionChallengePolicyPasswordResetFlowEnum]`
@@ -20138,7 +19987,7 @@ When "admin_notification" is enabled, determines how often email notifications a
-**method:** `typing.Optional[BreachedPasswordDetectionMethodEnum]` +**allowlist:** `typing.Optional[BotDetectionAllowlist]`
@@ -20146,7 +19995,7 @@ When "admin_notification" is enabled, determines how often email notifications a
-**stage:** `typing.Optional[BreachedPasswordDetectionStage]` +**monitoring_mode_enabled:** `typing.Optional[BotDetectionMonitoringModeEnabled]`
@@ -20166,8 +20015,8 @@ When "admin_notification" is enabled, determines how often email notifications a
-## AttackProtection BruteForceProtection -
client.attack_protection.brute_force_protection.get() -> GetBruteForceSettingsResponseContent +## AttackProtection BreachedPasswordDetection +
client.attack_protection.breached_password_detection.get() -> GetBreachedPasswordDetectionSettingsResponseContent
@@ -20179,7 +20028,7 @@ When "admin_notification" is enabled, determines how often email notifications a
-Retrieve details of the Brute-force Protection configuration of your tenant. +Retrieve details of the Breached Password Detection configuration of your tenant.
@@ -20202,7 +20051,7 @@ client = Auth0( environment=Auth0Environment.DEFAULT, ) -client.attack_protection.brute_force_protection.get() +client.attack_protection.breached_password_detection.get() ``` @@ -20230,7 +20079,7 @@ client.attack_protection.brute_force_protection.get()
-
client.attack_protection.brute_force_protection.update(...) -> UpdateBruteForceSettingsResponseContent +
client.attack_protection.breached_password_detection.update(...) -> UpdateBreachedPasswordDetectionSettingsResponseContent
@@ -20242,7 +20091,7 @@ client.attack_protection.brute_force_protection.get()
-Update the Brute-force Protection configuration of your tenant. +Update details of the Breached Password Detection configuration of your tenant.
@@ -20265,7 +20114,7 @@ client = Auth0( environment=Auth0Environment.DEFAULT, ) -client.attack_protection.brute_force_protection.update() +client.attack_protection.breached_password_detection.update() ``` @@ -20281,7 +20130,7 @@ client.attack_protection.brute_force_protection.update()
-**enabled:** `typing.Optional[bool]` — Whether or not brute force attack protections are active. +**enabled:** `typing.Optional[bool]` — Whether or not breached password detection is active.
@@ -20289,10 +20138,10 @@ client.attack_protection.brute_force_protection.update()
-**shields:** `typing.Optional[typing.List[BruteForceProtectionShieldsEnum]]` +**shields:** `typing.Optional[typing.List[BreachedPasswordDetectionShieldsEnum]]` -Action to take when a brute force protection threshold is violated. - Possible values: block, user_notification. +Action to take when a breached password is detected during a login. + Possible values: block, user_notification, admin_notification.
@@ -20300,7 +20149,10 @@ Action to take when a brute force protection threshold is violated.
-**allowlist:** `typing.Optional[typing.List[str]]` — List of trusted IP addresses that will not have attack protection enforced against them. +**admin_notification_frequency:** `typing.Optional[typing.List[BreachedPasswordDetectionAdminNotificationFrequencyEnum]]` + +When "admin_notification" is enabled, determines how often email notifications are sent. + Possible values: immediately, daily, weekly, monthly.
@@ -20308,7 +20160,7 @@ Action to take when a brute force protection threshold is violated.
-**mode:** `typing.Optional[BruteForceProtectionModeEnum]` +**method:** `typing.Optional[BreachedPasswordDetectionMethodEnum]`
@@ -20316,7 +20168,7 @@ Action to take when a brute force protection threshold is violated.
-**max_attempts:** `typing.Optional[int]` — Maximum number of unsuccessful attempts. +**stage:** `typing.Optional[BreachedPasswordDetectionStage]`
@@ -20336,8 +20188,8 @@ Action to take when a brute force protection threshold is violated.
-## AttackProtection Captcha -
client.attack_protection.captcha.get() -> GetAttackProtectionCaptchaResponseContent +## AttackProtection BruteForceProtection +
client.attack_protection.brute_force_protection.get() -> GetBruteForceSettingsResponseContent
@@ -20349,7 +20201,7 @@ Action to take when a brute force protection threshold is violated.
-Get the CAPTCHA configuration for your client. +Retrieve details of the Brute-force Protection configuration of your tenant.
@@ -20372,7 +20224,7 @@ client = Auth0( environment=Auth0Environment.DEFAULT, ) -client.attack_protection.captcha.get() +client.attack_protection.brute_force_protection.get() ``` @@ -20400,7 +20252,7 @@ client.attack_protection.captcha.get()
-
client.attack_protection.captcha.update(...) -> UpdateAttackProtectionCaptchaResponseContent +
client.attack_protection.brute_force_protection.update(...) -> UpdateBruteForceSettingsResponseContent
@@ -20412,7 +20264,7 @@ client.attack_protection.captcha.get()
-Update existing CAPTCHA configuration for your client. +Update the Brute-force Protection configuration of your tenant.
@@ -20435,7 +20287,7 @@ client = Auth0( environment=Auth0Environment.DEFAULT, ) -client.attack_protection.captcha.update() +client.attack_protection.brute_force_protection.update() ``` @@ -20451,23 +20303,7 @@ client.attack_protection.captcha.update()
-**active_provider_id:** `typing.Optional[AttackProtectionCaptchaProviderId]` - -
-
- -
-
- -**arkose:** `typing.Optional[AttackProtectionUpdateCaptchaArkose]` - -
-
- -
-
- -**auth_challenge:** `typing.Optional[AttackProtectionCaptchaAuthChallengeRequest]` +**enabled:** `typing.Optional[bool]` — Whether or not brute force attack protections are active.
@@ -20475,15 +20311,10 @@ client.attack_protection.captcha.update()
-**hcaptcha:** `typing.Optional[AttackProtectionUpdateCaptchaHcaptcha]` - -
-
- -
-
+**shields:** `typing.Optional[typing.List[BruteForceProtectionShieldsEnum]]` -**friendly_captcha:** `typing.Optional[AttackProtectionUpdateCaptchaFriendlyCaptcha]` +Action to take when a brute force protection threshold is violated. + Possible values: block, user_notification.
@@ -20491,7 +20322,7 @@ client.attack_protection.captcha.update()
-**recaptcha_enterprise:** `typing.Optional[AttackProtectionUpdateCaptchaRecaptchaEnterprise]` +**allowlist:** `typing.Optional[typing.List[str]]` — List of trusted IP addresses that will not have attack protection enforced against them.
@@ -20499,7 +20330,7 @@ client.attack_protection.captcha.update()
-**recaptcha_v_2:** `typing.Optional[AttackProtectionUpdateCaptchaRecaptchaV2]` +**mode:** `typing.Optional[BruteForceProtectionModeEnum]`
@@ -20507,7 +20338,7 @@ client.attack_protection.captcha.update()
-**simple_captcha:** `typing.Optional[AttackProtectionCaptchaSimpleCaptchaResponseContent]` +**max_attempts:** `typing.Optional[int]` — Maximum number of unsuccessful attempts.
@@ -20527,8 +20358,8 @@ client.attack_protection.captcha.update()
-## AttackProtection PhoneProviderProtection -
client.attack_protection.phone_provider_protection.get() -> GetPhoneProviderProtectionResponseContent +## AttackProtection Captcha +
client.attack_protection.captcha.get() -> GetAttackProtectionCaptchaResponseContent
@@ -20540,7 +20371,7 @@ client.attack_protection.captcha.update()
-Get the phone provider protection configuration for a tenant. +Get the CAPTCHA configuration for your client.
@@ -20563,7 +20394,7 @@ client = Auth0( environment=Auth0Environment.DEFAULT, ) -client.attack_protection.phone_provider_protection.get() +client.attack_protection.captcha.get() ``` @@ -20591,7 +20422,7 @@ client.attack_protection.phone_provider_protection.get()
-
client.attack_protection.phone_provider_protection.patch(...) -> PatchPhoneProviderProtectionResponseContent +
client.attack_protection.captcha.update(...) -> UpdateAttackProtectionCaptchaResponseContent
@@ -20603,7 +20434,7 @@ client.attack_protection.phone_provider_protection.get()
-Update the phone provider protection configuration for a tenant. +Update existing CAPTCHA configuration for your client.
@@ -20626,9 +20457,7 @@ client = Auth0( environment=Auth0Environment.DEFAULT, ) -client.attack_protection.phone_provider_protection.patch( - type="exponential", -) +client.attack_protection.captcha.update() ``` @@ -20644,7 +20473,63 @@ client.attack_protection.phone_provider_protection.patch(
-**type:** `PhoneProviderProtectionBackoffStrategyEnum` +**active_provider_id:** `typing.Optional[AttackProtectionCaptchaProviderId]` + +
+
+ +
+
+ +**arkose:** `typing.Optional[AttackProtectionUpdateCaptchaArkose]` + +
+
+ +
+
+ +**auth_challenge:** `typing.Optional[AttackProtectionCaptchaAuthChallengeRequest]` + +
+
+ +
+
+ +**hcaptcha:** `typing.Optional[AttackProtectionUpdateCaptchaHcaptcha]` + +
+
+ +
+
+ +**friendly_captcha:** `typing.Optional[AttackProtectionUpdateCaptchaFriendlyCaptcha]` + +
+
+ +
+
+ +**recaptcha_enterprise:** `typing.Optional[AttackProtectionUpdateCaptchaRecaptchaEnterprise]` + +
+
+ +
+
+ +**recaptcha_v_2:** `typing.Optional[AttackProtectionUpdateCaptchaRecaptchaV2]` + +
+
+ +
+
+ +**simple_captcha:** `typing.Optional[AttackProtectionCaptchaSimpleCaptchaResponseContent]`
@@ -20664,8 +20549,8 @@ client.attack_protection.phone_provider_protection.patch(
-## AttackProtection SuspiciousIpThrottling -
client.attack_protection.suspicious_ip_throttling.get() -> GetSuspiciousIpThrottlingSettingsResponseContent +## AttackProtection PhoneProviderProtection +
client.attack_protection.phone_provider_protection.get() -> GetPhoneProviderProtectionResponseContent
@@ -20677,7 +20562,7 @@ client.attack_protection.phone_provider_protection.patch(
-Retrieve details of the Suspicious IP Throttling configuration of your tenant. +Get the phone provider protection configuration for a tenant.
@@ -20700,7 +20585,7 @@ client = Auth0( environment=Auth0Environment.DEFAULT, ) -client.attack_protection.suspicious_ip_throttling.get() +client.attack_protection.phone_provider_protection.get() ``` @@ -20728,7 +20613,7 @@ client.attack_protection.suspicious_ip_throttling.get()
-
client.attack_protection.suspicious_ip_throttling.update(...) -> UpdateSuspiciousIpThrottlingSettingsResponseContent +
client.attack_protection.phone_provider_protection.patch(...) -> PatchPhoneProviderProtectionResponseContent
@@ -20740,7 +20625,7 @@ client.attack_protection.suspicious_ip_throttling.get()
-Update the details of the Suspicious IP Throttling configuration of your tenant. +Update the phone provider protection configuration for a tenant.
@@ -20763,7 +20648,9 @@ client = Auth0( environment=Auth0Environment.DEFAULT, ) -client.attack_protection.suspicious_ip_throttling.update() +client.attack_protection.phone_provider_protection.patch( + type="exponential", +) ``` @@ -20779,7 +20666,7 @@ client.attack_protection.suspicious_ip_throttling.update()
-**enabled:** `typing.Optional[bool]` — Whether or not suspicious IP throttling attack protections are active. +**type:** `PhoneProviderProtectionBackoffStrategyEnum`
@@ -20787,49 +20674,36 @@ client.attack_protection.suspicious_ip_throttling.update()
-**shields:** `typing.Optional[typing.List[SuspiciousIpThrottlingShieldsEnum]]` - -Action to take when a suspicious IP throttling threshold is violated. - Possible values: block, admin_notification. +**request_options:** `typing.Optional[RequestOptions]` — Request-specific configuration.
+ +
-
-
-**allowlist:** `typing.Optional[SuspiciousIpThrottlingAllowlist]` -
+
+## AttackProtection SuspiciousIpThrottling +
client.attack_protection.suspicious_ip_throttling.get() -> GetSuspiciousIpThrottlingSettingsResponseContent
-**stage:** `typing.Optional[SuspiciousIpThrottlingStage]` - -
-
+#### 📝 Description
-**request_options:** `typing.Optional[RequestOptions]` — Request-specific configuration. - -
-
+
+
+ +Retrieve details of the Suspicious IP Throttling configuration of your tenant.
- - -
- -## Branding Templates -
client.branding.templates.get_universal_login() -> GetUniversalLoginTemplateResponseContent -
-
#### 🔌 Usage @@ -20848,7 +20722,7 @@ client = Auth0( environment=Auth0Environment.DEFAULT, ) -client.branding.templates.get_universal_login() +client.attack_protection.suspicious_ip_throttling.get() ```
@@ -20876,7 +20750,7 @@ client.branding.templates.get_universal_login()
-
client.branding.templates.update_universal_login(...) +
client.attack_protection.suspicious_ip_throttling.update(...) -> UpdateSuspiciousIpThrottlingSettingsResponseContent
@@ -20888,30 +20762,7 @@ client.branding.templates.get_universal_login()
-Update the Universal Login branding template. - -When `content-type` header is set to `application/json`: - -```json -{ - "template": "{% assign resolved_dir = dir | default: \"auto\" %}{%- auth0:head -%}{%- auth0:widget -%}" -} -``` - -When `content-type` header is set to `text/html`: - -```html - -{% assign resolved_dir = dir | default: "auto" %} - - - {%- auth0:head -%} - - - {%- auth0:widget -%} - - -``` +Update the details of the Suspicious IP Throttling configuration of your tenant.
@@ -20934,9 +20785,7 @@ client = Auth0( environment=Auth0Environment.DEFAULT, ) -client.branding.templates.update_universal_login( - request="string", -) +client.attack_protection.suspicious_ip_throttling.update() ``` @@ -20952,7 +20801,34 @@ client.branding.templates.update_universal_login(
-**request:** `UpdateUniversalLoginTemplateRequestContent` +**enabled:** `typing.Optional[bool]` — Whether or not suspicious IP throttling attack protections are active. + +
+
+ +
+
+ +**shields:** `typing.Optional[typing.List[SuspiciousIpThrottlingShieldsEnum]]` + +Action to take when a suspicious IP throttling threshold is violated. + Possible values: block, admin_notification. + +
+
+ +
+
+ +**allowlist:** `typing.Optional[SuspiciousIpThrottlingAllowlist]` + +
+
+ +
+
+ +**stage:** `typing.Optional[SuspiciousIpThrottlingStage]`
@@ -20972,7 +20848,8 @@ client.branding.templates.update_universal_login(
-
client.branding.templates.delete_universal_login() +## Branding Templates +
client.branding.templates.get_universal_login() -> GetUniversalLoginTemplateResponseContent
@@ -20993,7 +20870,7 @@ client = Auth0( environment=Auth0Environment.DEFAULT, ) -client.branding.templates.delete_universal_login() +client.branding.templates.get_universal_login() ```
@@ -21021,8 +20898,7 @@ client.branding.templates.delete_universal_login()
-## Branding Themes -
client.branding.themes.create(...) -> CreateBrandingThemeResponseContent +
client.branding.templates.update_universal_login(...)
@@ -21034,7 +20910,30 @@ client.branding.templates.delete_universal_login()
-Create branding theme. +Update the Universal Login branding template. + +When `content-type` header is set to `application/json`: + +```json +{ + "template": "{% assign resolved_dir = dir | default: \"auto\" %}{%- auth0:head -%}{%- auth0:widget -%}" +} +``` + +When `content-type` header is set to `text/html`: + +```html + +{% assign resolved_dir = dir | default: "auto" %} + + + {%- auth0:head -%} + + + {%- auth0:widget -%} + + +```
@@ -21049,7 +20948,7 @@ Create branding theme.
```python -from auth0.management import Auth0, BrandingThemeBorders, BrandingThemeColors, BrandingThemeFonts, BrandingThemeFontBodyText, BrandingThemeFontButtonsText, BrandingThemeFontInputLabels, BrandingThemeFontLinks, BrandingThemeFontSubtitle, BrandingThemeFontTitle, BrandingThemePageBackground, BrandingThemeWidget +from auth0.management import Auth0 from auth0.management.environment import Auth0Environment client = Auth0( @@ -21057,77 +20956,8 @@ client = Auth0( environment=Auth0Environment.DEFAULT, ) -client.branding.themes.create( - borders=BrandingThemeBorders( - button_border_radius=1.1, - button_border_weight=1.1, - buttons_style="pill", - input_border_radius=1.1, - input_border_weight=1.1, - inputs_style="pill", - show_widget_shadow=True, - widget_border_weight=1.1, - widget_corner_radius=1.1, - ), - colors=BrandingThemeColors( - body_text="body_text", - error="error", - header="header", - icons="icons", - input_background="input_background", - input_border="input_border", - input_filled_text="input_filled_text", - input_labels_placeholders="input_labels_placeholders", - links_focused_components="links_focused_components", - primary_button="primary_button", - primary_button_label="primary_button_label", - secondary_button_border="secondary_button_border", - secondary_button_label="secondary_button_label", - success="success", - widget_background="widget_background", - widget_border="widget_border", - ), - fonts=BrandingThemeFonts( - body_text=BrandingThemeFontBodyText( - bold=True, - size=1.1, - ), - buttons_text=BrandingThemeFontButtonsText( - bold=True, - size=1.1, - ), - font_url="font_url", - input_labels=BrandingThemeFontInputLabels( - bold=True, - size=1.1, - ), - links=BrandingThemeFontLinks( - bold=True, - size=1.1, - ), - links_style="normal", - reference_text_size=1.1, - subtitle=BrandingThemeFontSubtitle( - bold=True, - size=1.1, - ), - title=BrandingThemeFontTitle( - bold=True, - size=1.1, - ), - ), - page_background=BrandingThemePageBackground( - background_color="background_color", - background_image_url="background_image_url", - page_layout="center", - ), - widget=BrandingThemeWidget( - header_text_alignment="center", - logo_height=1.1, - logo_position="center", - logo_url="logo_url", - social_buttons_layout="bottom", - ), +client.branding.templates.update_universal_login( + request="string", ) ``` @@ -21144,55 +20974,7 @@ client.branding.themes.create(
-**borders:** `BrandingThemeBorders` - -
-
- -
-
- -**colors:** `BrandingThemeColors` - -
-
- -
-
- -**fonts:** `BrandingThemeFonts` - -
-
- -
-
- -**page_background:** `BrandingThemePageBackground` - -
-
- -
-
- -**widget:** `BrandingThemeWidget` - -
-
- -
-
- -**display_name:** `typing.Optional[str]` — Display Name - -
-
- -
-
- -**identifiers:** `typing.Optional[BrandingThemeIdentifiers]` +**request:** `UpdateUniversalLoginTemplateRequestContent`
@@ -21212,24 +20994,10 @@ client.branding.themes.create(
-
client.branding.themes.get_default() -> GetBrandingDefaultThemeResponseContent -
-
- -#### 📝 Description - -
-
- +
client.branding.templates.delete_universal_login()
-Retrieve default branding theme. -
-
-
-
- #### 🔌 Usage
@@ -21247,7 +21015,261 @@ client = Auth0( environment=Auth0Environment.DEFAULT, ) -client.branding.themes.get_default() +client.branding.templates.delete_universal_login() + +``` +
+
+ + + +#### ⚙️ Parameters + +
+
+ +
+
+ +**request_options:** `typing.Optional[RequestOptions]` — Request-specific configuration. + +
+
+
+
+ + + + +
+ +## Branding Themes +
client.branding.themes.create(...) -> CreateBrandingThemeResponseContent +
+
+ +#### 📝 Description + +
+
+ +
+
+ +Create branding theme. +
+
+
+
+ +#### 🔌 Usage + +
+
+ +
+
+ +```python +from auth0.management import Auth0, BrandingThemeBorders, BrandingThemeColors, BrandingThemeFonts, BrandingThemeFontBodyText, BrandingThemeFontButtonsText, BrandingThemeFontInputLabels, BrandingThemeFontLinks, BrandingThemeFontSubtitle, BrandingThemeFontTitle, BrandingThemePageBackground, BrandingThemeWidget +from auth0.management.environment import Auth0Environment + +client = Auth0( + token="", + environment=Auth0Environment.DEFAULT, +) + +client.branding.themes.create( + borders=BrandingThemeBorders( + button_border_radius=1.1, + button_border_weight=1.1, + buttons_style="pill", + input_border_radius=1.1, + input_border_weight=1.1, + inputs_style="pill", + show_widget_shadow=True, + widget_border_weight=1.1, + widget_corner_radius=1.1, + ), + colors=BrandingThemeColors( + body_text="body_text", + error="error", + header="header", + icons="icons", + input_background="input_background", + input_border="input_border", + input_filled_text="input_filled_text", + input_labels_placeholders="input_labels_placeholders", + links_focused_components="links_focused_components", + primary_button="primary_button", + primary_button_label="primary_button_label", + secondary_button_border="secondary_button_border", + secondary_button_label="secondary_button_label", + success="success", + widget_background="widget_background", + widget_border="widget_border", + ), + fonts=BrandingThemeFonts( + body_text=BrandingThemeFontBodyText( + bold=True, + size=1.1, + ), + buttons_text=BrandingThemeFontButtonsText( + bold=True, + size=1.1, + ), + font_url="font_url", + input_labels=BrandingThemeFontInputLabels( + bold=True, + size=1.1, + ), + links=BrandingThemeFontLinks( + bold=True, + size=1.1, + ), + links_style="normal", + reference_text_size=1.1, + subtitle=BrandingThemeFontSubtitle( + bold=True, + size=1.1, + ), + title=BrandingThemeFontTitle( + bold=True, + size=1.1, + ), + ), + page_background=BrandingThemePageBackground( + background_color="background_color", + background_image_url="background_image_url", + page_layout="center", + ), + widget=BrandingThemeWidget( + header_text_alignment="center", + logo_height=1.1, + logo_position="center", + logo_url="logo_url", + social_buttons_layout="bottom", + ), +) + +``` +
+
+
+
+ +#### ⚙️ Parameters + +
+
+ +
+
+ +**borders:** `BrandingThemeBorders` + +
+
+ +
+
+ +**colors:** `BrandingThemeColors` + +
+
+ +
+
+ +**fonts:** `BrandingThemeFonts` + +
+
+ +
+
+ +**page_background:** `BrandingThemePageBackground` + +
+
+ +
+
+ +**widget:** `BrandingThemeWidget` + +
+
+ +
+
+ +**display_name:** `typing.Optional[str]` — Display Name + +
+
+ +
+
+ +**identifiers:** `typing.Optional[BrandingThemeIdentifiers]` + +
+
+ +
+
+ +**request_options:** `typing.Optional[RequestOptions]` — Request-specific configuration. + +
+
+
+
+ + +
+
+
+ +
client.branding.themes.get_default() -> GetBrandingDefaultThemeResponseContent +
+
+ +#### 📝 Description + +
+
+ +
+
+ +Retrieve default branding theme. +
+
+
+
+ +#### 🔌 Usage + +
+
+ +
+
+ +```python +from auth0.management import Auth0 +from auth0.management.environment import Auth0Environment + +client = Auth0( + token="", + environment=Auth0Environment.DEFAULT, +) + +client.branding.themes.get_default() ```
@@ -23151,10 +23173,2544 @@ client = Auth0( environment=Auth0Environment.DEFAULT, ) -client.clients.credentials.update( - client_id="client_id", - credential_id="credential_id", -) +client.clients.credentials.update( + client_id="client_id", + credential_id="credential_id", +) + +``` +
+
+
+
+ +#### ⚙️ Parameters + +
+
+ +
+
+ +**client_id:** `str` — ID of the client. + +
+
+ +
+
+ +**credential_id:** `str` — ID of the credential. + +
+
+ +
+
+ +**expires_at:** `typing.Optional[datetime.datetime]` — The ISO 8601 formatted date representing the expiration of the credential. + +
+
+ +
+
+ +**request_options:** `typing.Optional[RequestOptions]` — Request-specific configuration. + +
+
+
+
+ + + + +
+ +## Clients Connections +
client.clients.connections.get(...) -> ListClientConnectionsResponseContent +
+
+ +#### 📝 Description + +
+
+ +
+
+ +Retrieve all connections that are enabled for the specified [Application](https://www.auth0.com/docs/get-started/applications), using checkpoint pagination. A list of fields to include or exclude for each connection may also be specified. + +- This endpoint requires the `read:connections` scope and any one of `read:clients` or `read:client_summary`. +- **Note**: The first time you call this endpoint, omit the `from` parameter. If there are more results, a `next` value is included in the response. You can use this for subsequent API calls. When `next` is no longer included in the response, no further results are remaining. +
+
+
+
+ +#### 🔌 Usage + +
+
+ +
+
+ +```python +from auth0.management import Auth0 +from auth0.management.environment import Auth0Environment + +client = Auth0( + token="", + environment=Auth0Environment.DEFAULT, +) + +client.clients.connections.get( + id="id", + strategy=[ + "ad" + ], + from_="from", + take=1, + fields="fields", + include_fields=True, +) + +``` +
+
+
+
+ +#### ⚙️ Parameters + +
+
+ +
+
+ +**id:** `str` — ID of the client for which to retrieve enabled connections. + +
+
+ +
+
+ +**strategy:** `typing.Optional[typing.Union[typing.Optional[ConnectionStrategyEnum], typing.Sequence[typing.Optional[ConnectionStrategyEnum]]]]` — Provide strategies to only retrieve connections with such strategies + +
+
+ +
+
+ +**from:** `typing.Optional[str]` — Optional Id from which to start selection. + +
+
+ +
+
+ +**take:** `typing.Optional[int]` — Number of results per page. Defaults to 50. + +
+
+ +
+
+ +**fields:** `typing.Optional[str]` — A comma separated list of fields to include or exclude (depending on include_fields) from the result, empty to retrieve all fields + +
+
+ +
+
+ +**include_fields:** `typing.Optional[bool]` — true if the fields specified are to be included in the result, false otherwise (defaults to true) + +
+
+ +
+
+ +**request_options:** `typing.Optional[RequestOptions]` — Request-specific configuration. + +
+
+
+
+ + +
+
+
+ +## Connections DirectoryProvisioning +
client.connections.directory_provisioning.list(...) -> ListDirectoryProvisioningsResponseContent +
+
+ +#### 📝 Description + +
+
+ +
+
+ +Retrieve a list of directory provisioning configurations of a tenant. +
+
+
+
+ +#### 🔌 Usage + +
+
+ +
+
+ +```python +from auth0.management import Auth0 +from auth0.management.environment import Auth0Environment + +client = Auth0( + token="", + environment=Auth0Environment.DEFAULT, +) + +client.connections.directory_provisioning.list( + from_="from", + take=1, +) + +``` +
+
+
+
+ +#### ⚙️ Parameters + +
+
+ +
+
+ +**from:** `typing.Optional[str]` — Optional Id from which to start selection. + +
+
+ +
+
+ +**take:** `typing.Optional[int]` — Number of results per page. Defaults to 50. + +
+
+ +
+
+ +**request_options:** `typing.Optional[RequestOptions]` — Request-specific configuration. + +
+
+
+
+ + +
+
+
+ +
client.connections.directory_provisioning.get(...) -> GetDirectoryProvisioningResponseContent +
+
+ +#### 📝 Description + +
+
+ +
+
+ +Retrieve the directory provisioning configuration of a connection. +
+
+
+
+ +#### 🔌 Usage + +
+
+ +
+
+ +```python +from auth0.management import Auth0 +from auth0.management.environment import Auth0Environment + +client = Auth0( + token="", + environment=Auth0Environment.DEFAULT, +) + +client.connections.directory_provisioning.get( + id="id", +) + +``` +
+
+
+
+ +#### ⚙️ Parameters + +
+
+ +
+
+ +**id:** `str` — The id of the connection to retrieve its directory provisioning configuration + +
+
+ +
+
+ +**request_options:** `typing.Optional[RequestOptions]` — Request-specific configuration. + +
+
+
+
+ + +
+
+
+ +
client.connections.directory_provisioning.create(...) -> CreateDirectoryProvisioningResponseContent +
+
+ +#### 📝 Description + +
+
+ +
+
+ +Create a directory provisioning configuration for a connection. +
+
+
+
+ +#### 🔌 Usage + +
+
+ +
+
+ +```python +from auth0.management import Auth0, CreateDirectoryProvisioningRequestContent +from auth0.management.environment import Auth0Environment + +client = Auth0( + token="", + environment=Auth0Environment.DEFAULT, +) + +client.connections.directory_provisioning.create( + id="id", + request=CreateDirectoryProvisioningRequestContent(), +) + +``` +
+
+
+
+ +#### ⚙️ Parameters + +
+
+ +
+
+ +**id:** `str` — The id of the connection to create its directory provisioning configuration + +
+
+ +
+
+ +**request:** `typing.Optional[CreateDirectoryProvisioningRequestContent]` + +
+
+ +
+
+ +**request_options:** `typing.Optional[RequestOptions]` — Request-specific configuration. + +
+
+
+
+ + +
+
+
+ +
client.connections.directory_provisioning.delete(...) +
+
+ +#### 📝 Description + +
+
+ +
+
+ +Delete the directory provisioning configuration of a connection. +
+
+
+
+ +#### 🔌 Usage + +
+
+ +
+
+ +```python +from auth0.management import Auth0 +from auth0.management.environment import Auth0Environment + +client = Auth0( + token="", + environment=Auth0Environment.DEFAULT, +) + +client.connections.directory_provisioning.delete( + id="id", +) + +``` +
+
+
+
+ +#### ⚙️ Parameters + +
+
+ +
+
+ +**id:** `str` — The id of the connection to delete its directory provisioning configuration + +
+
+ +
+
+ +**request_options:** `typing.Optional[RequestOptions]` — Request-specific configuration. + +
+
+
+
+ + +
+
+
+ +
client.connections.directory_provisioning.update(...) -> UpdateDirectoryProvisioningResponseContent +
+
+ +#### 📝 Description + +
+
+ +
+
+ +Update the directory provisioning configuration of a connection. +
+
+
+
+ +#### 🔌 Usage + +
+
+ +
+
+ +```python +from auth0.management import Auth0, UpdateDirectoryProvisioningRequestContent +from auth0.management.environment import Auth0Environment + +client = Auth0( + token="", + environment=Auth0Environment.DEFAULT, +) + +client.connections.directory_provisioning.update( + id="id", + request=UpdateDirectoryProvisioningRequestContent(), +) + +``` +
+
+
+
+ +#### ⚙️ Parameters + +
+
+ +
+
+ +**id:** `str` — The id of the connection to create its directory provisioning configuration + +
+
+ +
+
+ +**request:** `typing.Optional[UpdateDirectoryProvisioningRequestContent]` + +
+
+ +
+
+ +**request_options:** `typing.Optional[RequestOptions]` — Request-specific configuration. + +
+
+
+
+ + +
+
+
+ +
client.connections.directory_provisioning.get_default_mapping(...) -> GetDirectoryProvisioningDefaultMappingResponseContent +
+
+ +#### 📝 Description + +
+
+ +
+
+ +Retrieve the directory provisioning default attribute mapping of a connection. +
+
+
+
+ +#### 🔌 Usage + +
+
+ +
+
+ +```python +from auth0.management import Auth0 +from auth0.management.environment import Auth0Environment + +client = Auth0( + token="", + environment=Auth0Environment.DEFAULT, +) + +client.connections.directory_provisioning.get_default_mapping( + id="id", +) + +``` +
+
+
+
+ +#### ⚙️ Parameters + +
+
+ +
+
+ +**id:** `str` — The id of the connection to retrieve its directory provisioning configuration + +
+
+ +
+
+ +**request_options:** `typing.Optional[RequestOptions]` — Request-specific configuration. + +
+
+
+
+ + +
+
+
+ +
client.connections.directory_provisioning.list_synchronized_groups(...) -> ListSynchronizedGroupsResponseContent +
+
+ +#### 📝 Description + +
+
+ +
+
+ +Retrieve the configured synchronized groups for a connection directory provisioning configuration. +
+
+
+
+ +#### 🔌 Usage + +
+
+ +
+
+ +```python +from auth0.management import Auth0 +from auth0.management.environment import Auth0Environment + +client = Auth0( + token="", + environment=Auth0Environment.DEFAULT, +) + +client.connections.directory_provisioning.list_synchronized_groups( + id="id", + from_="from", + take=1, + q="q", +) + +``` +
+
+
+
+ +#### ⚙️ Parameters + +
+
+ +
+
+ +**id:** `str` — The id of the connection to list synchronized groups for. + +
+
+ +
+
+ +**from:** `typing.Optional[str]` — Optional Id from which to start selection. + +
+
+ +
+
+ +**take:** `typing.Optional[int]` — Number of results per page. Defaults to 50. + +
+
+ +
+
+ +**q:** `typing.Optional[str]` — Query in Lucene query string syntax. Only prefix search on "name" or "email" fields are allowed, with a single wildcard suffix. Operators, modifiers, and groupings are not allowed. Terms are treated as case-insensitive. Example query: "name:engineering*". + +
+
+ +
+
+ +**request_options:** `typing.Optional[RequestOptions]` — Request-specific configuration. + +
+
+
+
+ + +
+
+
+ +
client.connections.directory_provisioning.add_synchronized_group_selections(...) +
+
+ +#### 📝 Description + +
+
+ +
+
+ +Add synchronized group selections to a directory provisioning configuration. +
+
+
+
+ +#### 🔌 Usage + +
+
+ +
+
+ +```python +from auth0.management import Auth0, SynchronizedGroupPayload +from auth0.management.environment import Auth0Environment + +client = Auth0( + token="", + environment=Auth0Environment.DEFAULT, +) + +client.connections.directory_provisioning.add_synchronized_group_selections( + id="id", + groups=[ + SynchronizedGroupPayload( + id="id", + ) + ], +) + +``` +
+
+
+
+ +#### ⚙️ Parameters + +
+
+ +
+
+ +**id:** `str` — The id of the connection to add synchronized groups to + +
+
+ +
+
+ +**groups:** `typing.List[SynchronizedGroupPayload]` — Array of Google Workspace Directory group objects to synchronize. + +
+
+ +
+
+ +**request_options:** `typing.Optional[RequestOptions]` — Request-specific configuration. + +
+
+
+
+ + +
+
+
+ +
client.connections.directory_provisioning.set(...) +
+
+ +#### 📝 Description + +
+
+ +
+
+ +Create or replace the selected groups for a connection directory provisioning configuration. +
+
+
+
+ +#### 🔌 Usage + +
+
+ +
+
+ +```python +from auth0.management import Auth0, SynchronizedGroupPayload +from auth0.management.environment import Auth0Environment + +client = Auth0( + token="", + environment=Auth0Environment.DEFAULT, +) + +client.connections.directory_provisioning.set( + id="id", + groups=[ + SynchronizedGroupPayload( + id="id", + ) + ], +) + +``` +
+
+
+
+ +#### ⚙️ Parameters + +
+
+ +
+
+ +**id:** `str` — The id of the connection to create or replace synchronized groups for + +
+
+ +
+
+ +**groups:** `typing.List[SynchronizedGroupPayload]` — Array of Google Workspace Directory group objects to synchronize. + +
+
+ +
+
+ +**request_options:** `typing.Optional[RequestOptions]` — Request-specific configuration. + +
+
+
+
+ + +
+
+
+ +
client.connections.directory_provisioning.delete_synchronized_group_selections(...) +
+
+ +#### 📝 Description + +
+
+ +
+
+ +Delete synchronized group selections for a directory provisioning configuration +
+
+
+
+ +#### 🔌 Usage + +
+
+ +
+
+ +```python +from auth0.management import Auth0, SynchronizedGroupSelectionId +from auth0.management.environment import Auth0Environment + +client = Auth0( + token="", + environment=Auth0Environment.DEFAULT, +) + +client.connections.directory_provisioning.delete_synchronized_group_selections( + id="id", + groups=[ + SynchronizedGroupSelectionId( + id="id", + ) + ], +) + +``` +
+
+
+
+ +#### ⚙️ Parameters + +
+
+ +
+
+ +**id:** `str` — The id of the connection to delete synchronized group selections for + +
+
+ +
+
+ +**groups:** `typing.List[SynchronizedGroupSelectionId]` — Array of groups to remove from the selection set. + +
+
+ +
+
+ +**request_options:** `typing.Optional[RequestOptions]` — Request-specific configuration. + +
+
+
+
+ + +
+
+
+ +## Connections ScimConfiguration +
client.connections.scim_configuration.list(...) -> ListScimConfigurationsResponseContent +
+
+ +#### 📝 Description + +
+
+ +
+
+ +Retrieve a list of SCIM configurations of a tenant. +
+
+
+
+ +#### 🔌 Usage + +
+
+ +
+
+ +```python +from auth0.management import Auth0 +from auth0.management.environment import Auth0Environment + +client = Auth0( + token="", + environment=Auth0Environment.DEFAULT, +) + +client.connections.scim_configuration.list( + from_="from", + take=1, +) + +``` +
+
+
+
+ +#### ⚙️ Parameters + +
+
+ +
+
+ +**from:** `typing.Optional[str]` — Optional Id from which to start selection. + +
+
+ +
+
+ +**take:** `typing.Optional[int]` — Number of results per page. Defaults to 50. + +
+
+ +
+
+ +**request_options:** `typing.Optional[RequestOptions]` — Request-specific configuration. + +
+
+
+
+ + +
+
+
+ +
client.connections.scim_configuration.get(...) -> GetScimConfigurationResponseContent +
+
+ +#### 📝 Description + +
+
+ +
+
+ +Retrieves a scim configuration by its `connectionId`. +
+
+
+
+ +#### 🔌 Usage + +
+
+ +
+
+ +```python +from auth0.management import Auth0 +from auth0.management.environment import Auth0Environment + +client = Auth0( + token="", + environment=Auth0Environment.DEFAULT, +) + +client.connections.scim_configuration.get( + id="id", +) + +``` +
+
+
+
+ +#### ⚙️ Parameters + +
+
+ +
+
+ +**id:** `str` — The id of the connection to retrieve its SCIM configuration + +
+
+ +
+
+ +**request_options:** `typing.Optional[RequestOptions]` — Request-specific configuration. + +
+
+
+
+ + +
+
+
+ +
client.connections.scim_configuration.create(...) -> CreateScimConfigurationResponseContent +
+
+ +#### 📝 Description + +
+
+ +
+
+ +Create a scim configuration for a connection. +
+
+
+
+ +#### 🔌 Usage + +
+
+ +
+
+ +```python +from auth0.management import Auth0, CreateScimConfigurationRequestContent +from auth0.management.environment import Auth0Environment + +client = Auth0( + token="", + environment=Auth0Environment.DEFAULT, +) + +client.connections.scim_configuration.create( + id="id", + request=CreateScimConfigurationRequestContent(), +) + +``` +
+
+
+
+ +#### ⚙️ Parameters + +
+
+ +
+
+ +**id:** `str` — The id of the connection to create its SCIM configuration + +
+
+ +
+
+ +**request:** `typing.Optional[CreateScimConfigurationRequestContent]` + +
+
+ +
+
+ +**request_options:** `typing.Optional[RequestOptions]` — Request-specific configuration. + +
+
+
+
+ + +
+
+
+ +
client.connections.scim_configuration.delete(...) +
+
+ +#### 📝 Description + +
+
+ +
+
+ +Deletes a scim configuration by its `connectionId`. +
+
+
+
+ +#### 🔌 Usage + +
+
+ +
+
+ +```python +from auth0.management import Auth0 +from auth0.management.environment import Auth0Environment + +client = Auth0( + token="", + environment=Auth0Environment.DEFAULT, +) + +client.connections.scim_configuration.delete( + id="id", +) + +``` +
+
+
+
+ +#### ⚙️ Parameters + +
+
+ +
+
+ +**id:** `str` — The id of the connection to delete its SCIM configuration + +
+
+ +
+
+ +**request_options:** `typing.Optional[RequestOptions]` — Request-specific configuration. + +
+
+
+
+ + +
+
+
+ +
client.connections.scim_configuration.update(...) -> UpdateScimConfigurationResponseContent +
+
+ +#### 📝 Description + +
+
+ +
+
+ +Update a scim configuration by its `connectionId`. +
+
+
+
+ +#### 🔌 Usage + +
+
+ +
+
+ +```python +from auth0.management import Auth0, ScimMappingItem +from auth0.management.environment import Auth0Environment + +client = Auth0( + token="", + environment=Auth0Environment.DEFAULT, +) + +client.connections.scim_configuration.update( + id="id", + user_id_attribute="user_id_attribute", + mapping=[ + ScimMappingItem() + ], +) + +``` +
+
+
+
+ +#### ⚙️ Parameters + +
+
+ +
+
+ +**id:** `str` — The id of the connection to update its SCIM configuration + +
+
+ +
+
+ +**user_id_attribute:** `str` — User ID attribute for generating unique user ids + +
+
+ +
+
+ +**mapping:** `typing.List[ScimMappingItem]` — The mapping between auth0 and SCIM + +
+
+ +
+
+ +**request_options:** `typing.Optional[RequestOptions]` — Request-specific configuration. + +
+
+
+
+ + +
+
+
+ +
client.connections.scim_configuration.get_default_mapping(...) -> GetScimConfigurationDefaultMappingResponseContent +
+
+ +#### 📝 Description + +
+
+ +
+
+ +Retrieves a scim configuration's default mapping by its `connectionId`. +
+
+
+
+ +#### 🔌 Usage + +
+
+ +
+
+ +```python +from auth0.management import Auth0 +from auth0.management.environment import Auth0Environment + +client = Auth0( + token="", + environment=Auth0Environment.DEFAULT, +) + +client.connections.scim_configuration.get_default_mapping( + id="id", +) + +``` +
+
+
+
+ +#### ⚙️ Parameters + +
+
+ +
+
+ +**id:** `str` — The id of the connection to retrieve its default SCIM mapping + +
+
+ +
+
+ +**request_options:** `typing.Optional[RequestOptions]` — Request-specific configuration. + +
+
+
+
+ + +
+
+
+ +## Connections Clients +
client.connections.clients.get(...) -> GetConnectionEnabledClientsResponseContent +
+
+ +#### 📝 Description + +
+
+ +
+
+ +Retrieve all clients that have the specified [connection](https://auth0.com/docs/authenticate/identity-providers) enabled. + +**Note**: The first time you call this endpoint, omit the `from` parameter. If there are more results, a `next` value is included in the response. You can use this for subsequent API calls. When `next` is no longer included in the response, no further results are remaining. +
+
+
+
+ +#### 🔌 Usage + +
+
+ +
+
+ +```python +from auth0.management import Auth0 +from auth0.management.environment import Auth0Environment + +client = Auth0( + token="", + environment=Auth0Environment.DEFAULT, +) + +client.connections.clients.get( + id="id", + take=1, + from_="from", +) + +``` +
+
+
+
+ +#### ⚙️ Parameters + +
+
+ +
+
+ +**id:** `str` — The id of the connection for which enabled clients are to be retrieved + +
+
+ +
+
+ +**take:** `typing.Optional[int]` — Number of results per page. Defaults to 50. + +
+
+ +
+
+ +**from:** `typing.Optional[str]` — Optional Id from which to start selection. + +
+
+ +
+
+ +**request_options:** `typing.Optional[RequestOptions]` — Request-specific configuration. + +
+
+
+
+ + +
+
+
+ +
client.connections.clients.update(...) +
+
+ +#### 🔌 Usage + +
+
+ +
+
+ +```python +from auth0.management import Auth0, UpdateEnabledClientConnectionsRequestContentItem +from auth0.management.environment import Auth0Environment + +client = Auth0( + token="", + environment=Auth0Environment.DEFAULT, +) + +client.connections.clients.update( + id="id", + request=[ + UpdateEnabledClientConnectionsRequestContentItem( + client_id="client_id", + status=True, + ) + ], +) + +``` +
+
+
+
+ +#### ⚙️ Parameters + +
+
+ +
+
+ +**id:** `str` — The id of the connection to modify + +
+
+ +
+
+ +**request:** `UpdateEnabledClientConnectionsRequestContent` + +
+
+ +
+
+ +**request_options:** `typing.Optional[RequestOptions]` — Request-specific configuration. + +
+
+
+
+ + +
+
+
+ +## Connections Keys +
client.connections.keys.get(...) -> typing.List[ConnectionKey] +
+
+ +#### 📝 Description + +
+
+ +
+
+ +Gets the connection keys for the Okta or OIDC connection strategy. +
+
+
+
+ +#### 🔌 Usage + +
+
+ +
+
+ +```python +from auth0.management import Auth0 +from auth0.management.environment import Auth0Environment + +client = Auth0( + token="", + environment=Auth0Environment.DEFAULT, +) + +client.connections.keys.get( + id="id", +) + +``` +
+
+
+
+ +#### ⚙️ Parameters + +
+
+ +
+
+ +**id:** `str` — ID of the connection + +
+
+ +
+
+ +**request_options:** `typing.Optional[RequestOptions]` — Request-specific configuration. + +
+
+
+
+ + +
+
+
+ +
client.connections.keys.create(...) -> PostConnectionsKeysResponseContent +
+
+ +#### 📝 Description + +
+
+ +
+
+ +Provision initial connection keys for Okta or OIDC connection strategies. This endpoint allows you to create keys before configuring the connection to use Private Key JWT authentication, enabling zero-downtime transitions. +
+
+
+
+ +#### 🔌 Usage + +
+
+ +
+
+ +```python +from auth0.management import Auth0, PostConnectionKeysRequestContent +from auth0.management.environment import Auth0Environment + +client = Auth0( + token="", + environment=Auth0Environment.DEFAULT, +) + +client.connections.keys.create( + id="id", + request=PostConnectionKeysRequestContent(), +) + +``` +
+
+
+
+ +#### ⚙️ Parameters + +
+
+ +
+
+ +**id:** `str` — ID of the connection + +
+
+ +
+
+ +**request:** `typing.Optional[PostConnectionKeysRequestContent]` + +
+
+ +
+
+ +**request_options:** `typing.Optional[RequestOptions]` — Request-specific configuration. + +
+
+
+
+ + +
+
+
+ +
client.connections.keys.rotate(...) -> RotateConnectionsKeysResponseContent +
+
+ +#### 📝 Description + +
+
+ +
+
+ +Rotates the connection keys for the Okta or OIDC connection strategies. +
+
+
+
+ +#### 🔌 Usage + +
+
+ +
+
+ +```python +from auth0.management import Auth0, RotateConnectionKeysRequestContent +from auth0.management.environment import Auth0Environment + +client = Auth0( + token="", + environment=Auth0Environment.DEFAULT, +) + +client.connections.keys.rotate( + id="id", + request=RotateConnectionKeysRequestContent(), +) + +``` +
+
+
+
+ +#### ⚙️ Parameters + +
+
+ +
+
+ +**id:** `str` — ID of the connection + +
+
+ +
+
+ +**request:** `typing.Optional[RotateConnectionKeysRequestContent]` + +
+
+ +
+
+ +**request_options:** `typing.Optional[RequestOptions]` — Request-specific configuration. + +
+
+
+
+ + +
+
+
+ +## Connections Users +
client.connections.users.delete_by_email(...) +
+
+ +#### 📝 Description + +
+
+ +
+
+ +Deletes a specified connection user by its email (you cannot delete all users from specific connection). Currently, only Database Connections are supported. +
+
+
+
+ +#### 🔌 Usage + +
+
+ +
+
+ +```python +from auth0.management import Auth0 +from auth0.management.environment import Auth0Environment + +client = Auth0( + token="", + environment=Auth0Environment.DEFAULT, +) + +client.connections.users.delete_by_email( + id="id", + email="email", +) + +``` +
+
+
+
+ +#### ⚙️ Parameters + +
+
+ +
+
+ +**id:** `str` — The id of the connection (currently only database connections are supported) + +
+
+ +
+
+ +**email:** `str` — The email of the user to delete + +
+
+ +
+
+ +**request_options:** `typing.Optional[RequestOptions]` — Request-specific configuration. + +
+
+
+
+ + +
+
+
+ +## Connections DirectoryProvisioning Synchronizations +
client.connections.directory_provisioning.synchronizations.create(...) -> CreateDirectorySynchronizationResponseContent +
+
+ +#### 📝 Description + +
+
+ +
+
+ +Request an on-demand synchronization of the directory. +
+
+
+
+ +#### 🔌 Usage + +
+
+ +
+
+ +```python +from auth0.management import Auth0 +from auth0.management.environment import Auth0Environment + +client = Auth0( + token="", + environment=Auth0Environment.DEFAULT, +) + +client.connections.directory_provisioning.synchronizations.create( + id="id", +) + +``` +
+
+
+
+ +#### ⚙️ Parameters + +
+
+ +
+
+ +**id:** `str` — The id of the connection to trigger synchronization for + +
+
+ +
+
+ +**request_options:** `typing.Optional[RequestOptions]` — Request-specific configuration. + +
+
+
+
+ + +
+
+
+ +## Connections ScimConfiguration Tokens +
client.connections.scim_configuration.tokens.get(...) -> GetScimTokensResponseContent +
+
+ +#### 📝 Description + +
+
+ +
+
+ +Retrieves all scim tokens by its connection `id`. +
+
+
+
+ +#### 🔌 Usage + +
+
+ +
+
+ +```python +from auth0.management import Auth0 +from auth0.management.environment import Auth0Environment + +client = Auth0( + token="", + environment=Auth0Environment.DEFAULT, +) + +client.connections.scim_configuration.tokens.get( + id="id", +) + +``` +
+
+
+
+ +#### ⚙️ Parameters + +
+
+ +
+
+ +**id:** `str` — The id of the connection to retrieve its SCIM configuration + +
+
+ +
+
+ +**request_options:** `typing.Optional[RequestOptions]` — Request-specific configuration. + +
+
+
+
+ + +
+
+
+ +
client.connections.scim_configuration.tokens.create(...) -> CreateScimTokenResponseContent +
+
+ +#### 📝 Description + +
+
+ +
+
+ +Create a scim token for a scim client. +
+
+
+
+ +#### 🔌 Usage + +
+
+ +
+
+ +```python +from auth0.management import Auth0 +from auth0.management.environment import Auth0Environment + +client = Auth0( + token="", + environment=Auth0Environment.DEFAULT, +) + +client.connections.scim_configuration.tokens.create( + id="id", +) + +``` +
+
+
+
+ +#### ⚙️ Parameters + +
+
+ +
+
+ +**id:** `str` — The id of the connection to create its SCIM token + +
+
+ +
+
+ +**scopes:** `typing.Optional[typing.List[str]]` — The scopes of the scim token + +
+
+ +
+
+ +**token_lifetime:** `typing.Optional[int]` — Lifetime of the token in seconds. Must be greater than 900 + +
+
+ +
+
+ +**request_options:** `typing.Optional[RequestOptions]` — Request-specific configuration. + +
+
+
+
+ + +
+
+
+ +
client.connections.scim_configuration.tokens.delete(...) +
+
+ +#### 📝 Description + +
+
+ +
+
+ +Deletes a scim token by its connection `id` and `tokenId`. +
+
+
+
+ +#### 🔌 Usage + +
+
+ +
+
+ +```python +from auth0.management import Auth0 +from auth0.management.environment import Auth0Environment + +client = Auth0( + token="", + environment=Auth0Environment.DEFAULT, +) + +client.connections.scim_configuration.tokens.delete( + id="id", + token_id="tokenId", +) + +``` +
+
+
+
+ +#### ⚙️ Parameters + +
+
+ +
+
+ +**id:** `str` — The connection id that owns the SCIM token to delete + +
+
+ +
+
+ +**token_id:** `str` — The id of the scim token to delete + +
+
+ +
+
+ +**request_options:** `typing.Optional[RequestOptions]` — Request-specific configuration. + +
+
+
+
+ + +
+
+
+ +## Emails Provider +
client.emails.provider.get(...) -> GetEmailProviderResponseContent +
+
+ +#### 📝 Description + +
+
+ +
+
+ +Retrieve details of the [email provider configuration](https://auth0.com/docs/customize/email/smtp-email-providers) in your tenant. A list of fields to include or exclude may also be specified. +
+
+
+
+ +#### 🔌 Usage + +
+
+ +
+
+ +```python +from auth0.management import Auth0 +from auth0.management.environment import Auth0Environment + +client = Auth0( + token="", + environment=Auth0Environment.DEFAULT, +) + +client.emails.provider.get( + fields="fields", + include_fields=True, +) + +``` +
+
+
+
+ +#### ⚙️ Parameters + +
+
+ +
+
+ +**fields:** `typing.Optional[str]` — Comma-separated list of fields to include or exclude (dependent upon include_fields) from the result. Leave empty to retrieve `name` and `enabled`. Additional fields available include `credentials`, `default_from_address`, and `settings`. + +
+
+ +
+
+ +**include_fields:** `typing.Optional[bool]` — Whether specified fields are to be included (true) or excluded (false). + +
+
+ +
+
+ +**request_options:** `typing.Optional[RequestOptions]` — Request-specific configuration. + +
+
+
+
+ + +
+
+
+ +
client.emails.provider.create(...) -> CreateEmailProviderResponseContent +
+
+ +#### 📝 Description + +
+
+ +
+
+ +Create an [email provider](https://auth0.com/docs/email/providers). The `credentials` object +requires different properties depending on the email provider (which is specified using the `name` property): + +- `mandrill` requires `api_key` +- `sendgrid` requires `api_key` +- `sparkpost` requires `api_key`. Optionally, set `region` to `eu` to use + the SparkPost service hosted in Western Europe; set to `null` to use the SparkPost service hosted in + North America. `eu` or `null` are the only valid values for `region`. +- `mailgun` requires `api_key` and `domain`. Optionally, set `region` to + `eu` to use the Mailgun service hosted in Europe; set to `null` otherwise. `eu` or + `null` are the only valid values for `region`. +- `ses` requires `accessKeyId`, `secretAccessKey`, and `region` +- `smtp` requires `smtp_host`, `smtp_port`, `smtp_user`, and + `smtp_pass` + +Depending on the type of provider it is possible to specify `settings` object with different configuration +options, which will be used when sending an email: + +- `smtp` provider, `settings` may contain `headers` object. + - When using AWS SES SMTP host, you may provide a name of configuration set in + `X-SES-Configuration-Set` header. Value must be a string. + - When using Sparkpost host, you may provide value for + `X-MSYS_API` header. Value must be an object. +- For `ses` provider, `settings` may contain `message` object, where you can provide + a name of configuration set in `configuration_set_name` property. Value must be a string. +
+
+
+
+ +#### 🔌 Usage + +
+
+ +
+
+ +```python +from auth0.management import Auth0, EmailProviderCredentialsSchemaZero +from auth0.management.environment import Auth0Environment + +client = Auth0( + token="", + environment=Auth0Environment.DEFAULT, +) + +client.emails.provider.create( + name="mailgun", + credentials=EmailProviderCredentialsSchemaZero( + api_key="api_key", + ), +) + +``` +
+
+
+
+ +#### ⚙️ Parameters + +
+
+ +
+
+ +**name:** `EmailProviderNameEnum` + +
+
+ +
+
+ +**credentials:** `EmailProviderCredentialsSchema` + +
+
+ +
+
+ +**enabled:** `typing.Optional[bool]` — Whether the provider is enabled (true) or disabled (false). + +
+
+ +
+
+ +**default_from_address:** `typing.Optional[str]` — Email address to use as "from" when no other address specified. + +
+
+ +
+
+ +**settings:** `typing.Optional[EmailSpecificProviderSettingsWithAdditionalProperties]` + +
+
+ +
+
+ +**request_options:** `typing.Optional[RequestOptions]` — Request-specific configuration. + +
+
+
+
+ + +
+
+
+ +
client.emails.provider.delete() +
+
+ +#### 📝 Description + +
+
+ +
+
+ +Delete the email provider. +
+
+
+
+ +#### 🔌 Usage + +
+
+ +
+
+ +```python +from auth0.management import Auth0 +from auth0.management.environment import Auth0Environment + +client = Auth0( + token="", + environment=Auth0Environment.DEFAULT, +) + +client.emails.provider.delete() ```
@@ -23170,30 +25726,6 @@ client.clients.credentials.update(
-**client_id:** `str` — ID of the client. - -
-
- -
-
- -**credential_id:** `str` — ID of the credential. - -
-
- -
-
- -**expires_at:** `typing.Optional[datetime.datetime]` — The ISO 8601 formatted date representing the expiration of the credential. - -
-
- -
-
- **request_options:** `typing.Optional[RequestOptions]` — Request-specific configuration.
@@ -23206,8 +25738,7 @@ client.clients.credentials.update(
-## Clients Connections -
client.clients.connections.get(...) -> ListClientConnectionsResponseContent +
client.emails.provider.update(...) -> UpdateEmailProviderResponseContent
@@ -23219,10 +25750,32 @@ client.clients.credentials.update(
-Retrieve all connections that are enabled for the specified [Application](https://www.auth0.com/docs/get-started/applications), using checkpoint pagination. A list of fields to include or exclude for each connection may also be specified. +Update an [email provider](https://auth0.com/docs/email/providers). The `credentials` object +requires different properties depending on the email provider (which is specified using the `name` property): -- This endpoint requires the `read:connections` scope and any one of `read:clients` or `read:client_summary`. -- **Note**: The first time you call this endpoint, omit the `from` parameter. If there are more results, a `next` value is included in the response. You can use this for subsequent API calls. When `next` is no longer included in the response, no further results are remaining. +- `mandrill` requires `api_key` +- `sendgrid` requires `api_key` +- `sparkpost` requires `api_key`. Optionally, set `region` to `eu` to use + the SparkPost service hosted in Western Europe; set to `null` to use the SparkPost service hosted in + North America. `eu` or `null` are the only valid values for `region`. +- `mailgun` requires `api_key` and `domain`. Optionally, set `region` to + `eu` to use the Mailgun service hosted in Europe; set to `null` otherwise. `eu` or + `null` are the only valid values for `region`. +- `ses` requires `accessKeyId`, `secretAccessKey`, and `region` +- `smtp` requires `smtp_host`, `smtp_port`, `smtp_user`, and + `smtp_pass` + +Depending on the type of provider it is possible to specify `settings` object with different configuration +options, which will be used when sending an email: + +- `smtp` provider, `settings` may contain `headers` object. + - When using AWS SES SMTP host, you may provide a name of configuration set in + `X-SES-Configuration-Set` header. Value must be a string. + - When using Sparkpost host, you may provide value for + `X-MSYS_API` header. Value must be an object. + + For `ses` provider, `settings` may contain `message` object, where you can provide + a name of configuration set in `configuration_set_name` property. Value must be a string.
@@ -23245,16 +25798,7 @@ client = Auth0( environment=Auth0Environment.DEFAULT, ) -client.clients.connections.get( - id="id", - strategy=[ - "ad" - ], - from_="from", - take=1, - fields="fields", - include_fields=True, -) +client.emails.provider.update() ``` @@ -23270,15 +25814,7 @@ client.clients.connections.get(
-**id:** `str` — ID of the client for which to retrieve enabled connections. - -
-
- -
-
- -**strategy:** `typing.Optional[typing.Union[typing.Optional[ConnectionStrategyEnum], typing.Sequence[typing.Optional[ConnectionStrategyEnum]]]]` — Provide strategies to only retrieve connections with such strategies +**name:** `typing.Optional[EmailProviderNameEnum]`
@@ -23286,7 +25822,7 @@ client.clients.connections.get(
-**from:** `typing.Optional[str]` — Optional Id from which to start selection. +**enabled:** `typing.Optional[bool]` — Whether the provider is enabled (true) or disabled (false).
@@ -23294,7 +25830,7 @@ client.clients.connections.get(
-**take:** `typing.Optional[int]` — Number of results per page. Defaults to 50. +**default_from_address:** `typing.Optional[str]` — Email address to use as "from" when no other address specified.
@@ -23302,7 +25838,7 @@ client.clients.connections.get(
-**fields:** `typing.Optional[str]` — A comma separated list of fields to include or exclude (depending on include_fields) from the result, empty to retrieve all fields +**credentials:** `typing.Optional[EmailProviderCredentialsSchema]`
@@ -23310,7 +25846,7 @@ client.clients.connections.get(
-**include_fields:** `typing.Optional[bool]` — true if the fields specified are to be included in the result, false otherwise (defaults to true) +**settings:** `typing.Optional[EmailSpecificProviderSettingsWithAdditionalProperties]`
@@ -23330,25 +25866,11 @@ client.clients.connections.get(
-## Connections DirectoryProvisioning -
client.connections.directory_provisioning.list(...) -> ListDirectoryProvisioningsResponseContent -
-
- -#### 📝 Description - -
-
- +## EventStreams Deliveries +
client.event_streams.deliveries.list(...) -> ListEventStreamDeliveriesResponseContent
-Retrieve a list of directory provisioning configurations of a tenant. -
-
-
-
- #### 🔌 Usage
@@ -23366,7 +25888,12 @@ client = Auth0( environment=Auth0Environment.DEFAULT, ) -client.connections.directory_provisioning.list( +client.event_streams.deliveries.list( + id="id", + statuses="statuses", + event_types="event_types", + date_from="date_from", + date_to="date_to", from_="from", take=1, ) @@ -23385,7 +25912,7 @@ client.connections.directory_provisioning.list(
-**from:** `typing.Optional[str]` — Optional Id from which to start selection. +**id:** `str` — Unique identifier for the event stream.
@@ -23393,7 +25920,7 @@ client.connections.directory_provisioning.list(
-**take:** `typing.Optional[int]` — Number of results per page. Defaults to 50. +**statuses:** `typing.Optional[str]` — Comma-separated list of statuses by which to filter
@@ -23401,72 +25928,39 @@ client.connections.directory_provisioning.list(
-**request_options:** `typing.Optional[RequestOptions]` — Request-specific configuration. +**event_types:** `typing.Optional[str]` — Comma-separated list of event types by which to filter
-
-
- - - - -
-
client.connections.directory_provisioning.get(...) -> GetDirectoryProvisioningResponseContent
-#### 📝 Description - -
-
+**date_from:** `typing.Optional[str]` — An RFC-3339 date-time for redelivery start, inclusive. Does not allow sub-second precision. + +
+
-Retrieve the directory provisioning configuration of a connection. -
-
+**date_to:** `typing.Optional[str]` — An RFC-3339 date-time for redelivery end, exclusive. Does not allow sub-second precision. +
-#### 🔌 Usage - -
-
-
-```python -from auth0.management import Auth0 -from auth0.management.environment import Auth0Environment - -client = Auth0( - token="", - environment=Auth0Environment.DEFAULT, -) - -client.connections.directory_provisioning.get( - id="id", -) - -``` -
-
+**from:** `typing.Optional[str]` — Optional Id from which to start selection. +
-#### ⚙️ Parameters -
-
-
- -**id:** `str` — The id of the connection to retrieve its directory provisioning configuration +**take:** `typing.Optional[int]` — Number of results per page. Defaults to 50.
@@ -23486,24 +25980,10 @@ client.connections.directory_provisioning.get(
-
client.connections.directory_provisioning.create(...) -> CreateDirectoryProvisioningResponseContent -
-
- -#### 📝 Description - -
-
- +
client.event_streams.deliveries.get_history(...) -> GetEventStreamDeliveryHistoryResponseContent
-Create a directory provisioning configuration for a connection. -
-
-
-
- #### 🔌 Usage
@@ -23513,7 +25993,7 @@ Create a directory provisioning configuration for a connection.
```python -from auth0.management import Auth0, CreateDirectoryProvisioningRequestContent +from auth0.management import Auth0 from auth0.management.environment import Auth0Environment client = Auth0( @@ -23521,9 +26001,9 @@ client = Auth0( environment=Auth0Environment.DEFAULT, ) -client.connections.directory_provisioning.create( +client.event_streams.deliveries.get_history( id="id", - request=CreateDirectoryProvisioningRequestContent(), + event_id="event_id", ) ``` @@ -23540,7 +26020,7 @@ client.connections.directory_provisioning.create(
-**id:** `str` — The id of the connection to create its directory provisioning configuration +**id:** `str` — Unique identifier for the event stream.
@@ -23548,7 +26028,7 @@ client.connections.directory_provisioning.create(
-**request:** `typing.Optional[CreateDirectoryProvisioningRequestContent]` +**event_id:** `str` — Unique identifier for the event
@@ -23568,24 +26048,11 @@ client.connections.directory_provisioning.create(
-
client.connections.directory_provisioning.delete(...) -
-
- -#### 📝 Description - -
-
- +## EventStreams Redeliveries +
client.event_streams.redeliveries.create(...) -> CreateEventStreamRedeliveryResponseContent
-Delete the directory provisioning configuration of a connection. -
-
-
-
- #### 🔌 Usage
@@ -23603,7 +26070,7 @@ client = Auth0( environment=Auth0Environment.DEFAULT, ) -client.connections.directory_provisioning.delete( +client.event_streams.redeliveries.create( id="id", ) @@ -23621,7 +26088,7 @@ client.connections.directory_provisioning.delete(
-**id:** `str` — The id of the connection to delete its directory provisioning configuration +**id:** `str` — Unique identifier for the event stream.
@@ -23629,35 +26096,53 @@ client.connections.directory_provisioning.delete(
-**request_options:** `typing.Optional[RequestOptions]` — Request-specific configuration. +**date_from:** `typing.Optional[datetime.datetime]` — An RFC-3339 date-time for redelivery start, inclusive. Does not allow sub-second precision.
-
-
+
+
+**date_to:** `typing.Optional[datetime.datetime]` — An RFC-3339 date-time for redelivery end, exclusive. Does not allow sub-second precision. +
-
-
client.connections.directory_provisioning.update(...) -> UpdateDirectoryProvisioningResponseContent
-#### 📝 Description +**statuses:** `typing.Optional[typing.List[EventStreamDeliveryStatusEnum]]` — Filter by status + +
+
+**event_types:** `typing.Optional[typing.List[EventStreamEventTypeEnum]]` — Filter by event type + +
+
+
-Update the directory provisioning configuration of a connection. +**request_options:** `typing.Optional[RequestOptions]` — Request-specific configuration. + +
+
+ + +
+ +
client.event_streams.redeliveries.create_by_id(...) +
+
#### 🔌 Usage @@ -23668,7 +26153,7 @@ Update the directory provisioning configuration of a connection.
```python -from auth0.management import Auth0, UpdateDirectoryProvisioningRequestContent +from auth0.management import Auth0 from auth0.management.environment import Auth0Environment client = Auth0( @@ -23676,9 +26161,9 @@ client = Auth0( environment=Auth0Environment.DEFAULT, ) -client.connections.directory_provisioning.update( +client.event_streams.redeliveries.create_by_id( id="id", - request=UpdateDirectoryProvisioningRequestContent(), + event_id="event_id", ) ``` @@ -23695,7 +26180,7 @@ client.connections.directory_provisioning.update(
-**id:** `str` — The id of the connection to create its directory provisioning configuration +**id:** `str` — Unique identifier for the event stream.
@@ -23703,7 +26188,7 @@ client.connections.directory_provisioning.update(
-**request:** `typing.Optional[UpdateDirectoryProvisioningRequestContent]` +**event_id:** `str` — Unique identifier for the event
@@ -23723,7 +26208,8 @@ client.connections.directory_provisioning.update(
-
client.connections.directory_provisioning.get_default_mapping(...) -> GetDirectoryProvisioningDefaultMappingResponseContent +## Experimentation Experiments +
client.experimentation.experiments.list(...) -> ListExperimentsResponseContent
@@ -23735,7 +26221,7 @@ client.connections.directory_provisioning.update(
-Retrieve the directory provisioning default attribute mapping of a connection. +Retrieve a paginated list of experiments for the tenant, with optional filters.
@@ -23758,8 +26244,12 @@ client = Auth0( environment=Auth0Environment.DEFAULT, ) -client.connections.directory_provisioning.get_default_mapping( - id="id", +client.experimentation.experiments.list( + from_="from", + take=1, + status="draft", + authentication_flow="authentication_flow", + feature_flag_id="feature_flag_id", ) ``` @@ -23776,7 +26266,7 @@ client.connections.directory_provisioning.get_default_mapping(
-**id:** `str` — The id of the connection to retrieve its directory provisioning configuration +**from:** `typing.Optional[str]` — Optional Id from which to start selection.
@@ -23784,75 +26274,15 @@ client.connections.directory_provisioning.get_default_mapping(
-**request_options:** `typing.Optional[RequestOptions]` — Request-specific configuration. +**take:** `typing.Optional[int]` — Number of experiments to return per page. Defaults to 25, maximum 50.
- -
- - - -
- -
client.connections.directory_provisioning.list_synchronized_groups(...) -> ListSynchronizedGroupsResponseContent
-#### 📝 Description - -
-
- -
-
- -Retrieve the configured synchronized groups for a connection directory provisioning configuration. -
-
-
-
- -#### 🔌 Usage - -
-
- -
-
- -```python -from auth0.management import Auth0 -from auth0.management.environment import Auth0Environment - -client = Auth0( - token="", - environment=Auth0Environment.DEFAULT, -) - -client.connections.directory_provisioning.list_synchronized_groups( - id="id", - from_="from", - take=1, - q="q", -) - -``` -
-
-
-
- -#### ⚙️ Parameters - -
-
- -
-
- -**id:** `str` — The id of the connection to list synchronized groups for. +**status:** `typing.Optional[ExperimentStatusEnum]` — Filter by status. Exact match.
@@ -23860,7 +26290,7 @@ client.connections.directory_provisioning.list_synchronized_groups(
-**from:** `typing.Optional[str]` — Optional Id from which to start selection. +**authentication_flow:** `typing.Optional[str]` — Filter by authentication flow. Exact match.
@@ -23868,15 +26298,7 @@ client.connections.directory_provisioning.list_synchronized_groups(
-**take:** `typing.Optional[int]` — Number of results per page. Defaults to 50. - -
-
- -
-
- -**q:** `typing.Optional[str]` — Query in Lucene query string syntax. Only prefix search on "name" or "email" fields are allowed, with a single wildcard suffix. Operators, modifiers, and groupings are not allowed. Terms are treated as case-insensitive. Example query: "name:engineering*". +**feature_flag_id:** `typing.Optional[str]` — Filter by feature flag ID. Exact match.
@@ -23896,7 +26318,7 @@ client.connections.directory_provisioning.list_synchronized_groups(
-
client.connections.directory_provisioning.add_synchronized_group_selections(...) +
client.experimentation.experiments.create(...) -> CreateExperimentResponseContent
@@ -23908,7 +26330,7 @@ client.connections.directory_provisioning.list_synchronized_groups(
-Add synchronized group selections to a directory provisioning configuration. +Create a new experiment for A/B testing.
@@ -23923,7 +26345,7 @@ Add synchronized group selections to a directory provisioning configuration.
```python -from auth0.management import Auth0, SynchronizedGroupPayload +from auth0.management import Auth0 from auth0.management.environment import Auth0Environment client = Auth0( @@ -23931,13 +26353,10 @@ client = Auth0( environment=Auth0Environment.DEFAULT, ) -client.connections.directory_provisioning.add_synchronized_group_selections( - id="id", - groups=[ - SynchronizedGroupPayload( - id="id", - ) - ], +client.experimentation.experiments.create( + name="name", + feature_flag_id="feature_flag_id", + authentication_flow="authentication", ) ``` @@ -23954,7 +26373,7 @@ client.connections.directory_provisioning.add_synchronized_group_selections(
-**id:** `str` — The id of the connection to add synchronized groups to +**name:** `str` — A human-readable name for the experiment
@@ -23962,7 +26381,7 @@ client.connections.directory_provisioning.add_synchronized_group_selections(
-**groups:** `typing.List[SynchronizedGroupPayload]` — Array of Google Workspace Directory group objects to synchronize. +**feature_flag_id:** `str` — The ID of the feature flag this experiment is based on
@@ -23970,77 +26389,39 @@ client.connections.directory_provisioning.add_synchronized_group_selections(
-**request_options:** `typing.Optional[RequestOptions]` — Request-specific configuration. +**authentication_flow:** `AuthenticationFlowEnum`
-
-
- - - -
- -
client.connections.directory_provisioning.set(...)
-#### 📝 Description - -
-
+**description:** `typing.Optional[str]` — A description of the experiment + +
+
-Create or replace the selected groups for a connection directory provisioning configuration. -
-
+**default_config:** `typing.Optional[DefaultConfigEnum]` — Applies only to Auth0-managed flags. Controls where non-overridden config keys resolve from: 'tenant' inherits the tenant's live config so the experiment overlays only its changes, 'flag' uses the flag's frozen defaults for a complete config. Optional; defaults to 'tenant' when omitted. Rejected for customer-defined flags. +
-#### 🔌 Usage - -
-
-
-```python -from auth0.management import Auth0, SynchronizedGroupPayload -from auth0.management.environment import Auth0Environment - -client = Auth0( - token="", - environment=Auth0Environment.DEFAULT, -) - -client.connections.directory_provisioning.set( - id="id", - groups=[ - SynchronizedGroupPayload( - id="id", - ) - ], -) - -``` -
-
+**allocation_strategy:** `typing.Optional[AllocationStrategyEnum]` — The traffic allocation strategy for this experiment +
-#### ⚙️ Parameters -
-
-
- -**id:** `str` — The id of the connection to create or replace synchronized groups for +**allocations:** `typing.Optional[typing.List[AllocationRequestItem]]` — Traffic allocations mapping variations to weights or segments
@@ -24048,7 +26429,7 @@ client.connections.directory_provisioning.set(
-**groups:** `typing.List[SynchronizedGroupPayload]` — Array of Google Workspace Directory group objects to synchronize. +**levels:** `typing.Optional[typing.List[int]]` — Ramp experiment levels configuration. A strictly-increasing sequence of exposure percentages, each an integer in [0, 100].
@@ -24068,7 +26449,7 @@ client.connections.directory_provisioning.set(
-
client.connections.directory_provisioning.delete_synchronized_group_selections(...) +
client.experimentation.experiments.get(...) -> GetExperimentResponseContent
@@ -24080,7 +26461,7 @@ client.connections.directory_provisioning.set(
-Delete synchronized group selections for a directory provisioning configuration +Retrieve a single experiment with its allocations by ID.
@@ -24095,7 +26476,7 @@ Delete synchronized group selections for a directory provisioning configuration
```python -from auth0.management import Auth0, SynchronizedGroupSelectionId +from auth0.management import Auth0 from auth0.management.environment import Auth0Environment client = Auth0( @@ -24103,13 +26484,8 @@ client = Auth0( environment=Auth0Environment.DEFAULT, ) -client.connections.directory_provisioning.delete_synchronized_group_selections( +client.experimentation.experiments.get( id="id", - groups=[ - SynchronizedGroupSelectionId( - id="id", - ) - ], ) ``` @@ -24126,15 +26502,7 @@ client.connections.directory_provisioning.delete_synchronized_group_selections(
-**id:** `str` — The id of the connection to delete synchronized group selections for - -
-
- -
-
- -**groups:** `typing.List[SynchronizedGroupSelectionId]` — Array of groups to remove from the selection set. +**id:** `str` — The ID of the experiment to retrieve.
@@ -24154,8 +26522,7 @@ client.connections.directory_provisioning.delete_synchronized_group_selections(
-## Connections ScimConfiguration -
client.connections.scim_configuration.list(...) -> ListScimConfigurationsResponseContent +
client.experimentation.experiments.delete(...)
@@ -24167,7 +26534,7 @@ client.connections.directory_provisioning.delete_synchronized_group_selections(
-Retrieve a list of SCIM configurations of a tenant. +Permanently delete an experiment and its allocations by ID. Active experiments cannot be deleted; pause or complete first. Idempotent: returns 204 even if the experiment does not exist.
@@ -24190,9 +26557,8 @@ client = Auth0( environment=Auth0Environment.DEFAULT, ) -client.connections.scim_configuration.list( - from_="from", - take=1, +client.experimentation.experiments.delete( + id="id", ) ``` @@ -24209,15 +26575,7 @@ client.connections.scim_configuration.list(
-**from:** `typing.Optional[str]` — Optional Id from which to start selection. - -
-
- -
-
- -**take:** `typing.Optional[int]` — Number of results per page. Defaults to 50. +**id:** `str` — The ID of the experiment to delete.
@@ -24237,7 +26595,7 @@ client.connections.scim_configuration.list(
-
client.connections.scim_configuration.get(...) -> GetScimConfigurationResponseContent +
client.experimentation.experiments.update(...) -> UpdateExperimentResponseContent
@@ -24249,7 +26607,7 @@ client.connections.scim_configuration.list(
-Retrieves a scim configuration by its `connectionId`. +Partially update an experiment by ID. Only provided fields are updated. Providing allocations replaces the entire allocations set.
@@ -24272,7 +26630,7 @@ client = Auth0( environment=Auth0Environment.DEFAULT, ) -client.connections.scim_configuration.get( +client.experimentation.experiments.update( id="id", ) @@ -24290,7 +26648,7 @@ client.connections.scim_configuration.get(
-**id:** `str` — The id of the connection to retrieve its SCIM configuration +**id:** `str` — The ID of the experiment to update.
@@ -24298,73 +26656,39 @@ client.connections.scim_configuration.get(
-**request_options:** `typing.Optional[RequestOptions]` — Request-specific configuration. +**name:** `typing.Optional[str]` — A human-readable name for the experiment
- -
- - - -
- -
client.connections.scim_configuration.create(...) -> CreateScimConfigurationResponseContent
-#### 📝 Description - -
-
+**description:** `typing.Optional[str]` — A description of the experiment + +
+
-Create a scim configuration for a connection. -
-
+**authentication_flow:** `typing.Optional[AuthenticationFlowEnum]` — Specifies the target authentication flow for this experiment. This field can only be modified on draft experiments. Must be one of: authentication, mfa_enrollment, mfa_challenge, password_reset, passkey_enrollment, or all. Note that the all value targets every flow at once, but requires that this is the only active experiment. +
-#### 🔌 Usage - -
-
-
-```python -from auth0.management import Auth0, CreateScimConfigurationRequestContent -from auth0.management.environment import Auth0Environment - -client = Auth0( - token="", - environment=Auth0Environment.DEFAULT, -) - -client.connections.scim_configuration.create( - id="id", - request=CreateScimConfigurationRequestContent(), -) - -``` -
-
+**allocations:** `typing.Optional[typing.List[AllocationRequestItem]]` — Replaces all traffic allocations. Cannot be modified while the experiment is active. +
-#### ⚙️ Parameters -
-
-
- -**id:** `str` — The id of the connection to create its SCIM configuration +**default_config:** `typing.Optional[DefaultConfigEnum]` — Applies only to Auth0-managed flags. Controls where non-overridden config keys resolve from: 'tenant' inherits the tenant's live config, 'flag' uses the flag's frozen defaults. Can only be modified on draft experiments. Rejected for customer-defined flags.
@@ -24372,7 +26696,7 @@ client.connections.scim_configuration.create(
-**request:** `typing.Optional[CreateScimConfigurationRequestContent]` +**levels:** `typing.Optional[typing.List[int]]` — Ramp experiment levels configuration. A strictly-increasing sequence of exposure percentages, each an integer in [0, 100]. Can only be modified on draft experiments.
@@ -24392,7 +26716,7 @@ client.connections.scim_configuration.create(
-
client.connections.scim_configuration.delete(...) +
client.experimentation.experiments.advance_ramp(...) -> AdvanceRampResponseContent
@@ -24404,7 +26728,7 @@ client.connections.scim_configuration.create(
-Deletes a scim configuration by its `connectionId`. +Increments the current ramp index to the requested target level. Up-only: the target must be the immediate next level in the schedule. Idempotent: calling with the current level returns success without writing anything.
@@ -24427,8 +26751,9 @@ client = Auth0( environment=Auth0Environment.DEFAULT, ) -client.connections.scim_configuration.delete( +client.experimentation.experiments.advance_ramp( id="id", + target_level=1, ) ``` @@ -24445,7 +26770,15 @@ client.connections.scim_configuration.delete(
-**id:** `str` — The id of the connection to delete its SCIM configuration +**id:** `str` — The ID of the experiment to advance. + +
+
+ +
+
+ +**target_level:** `int` — The target percentage level from the experiment schedule. Must be the immediate next level.
@@ -24465,7 +26798,7 @@ client.connections.scim_configuration.delete(
-
client.connections.scim_configuration.update(...) -> UpdateScimConfigurationResponseContent +
client.experimentation.experiments.update_status(...) -> UpdateExperimentStatusResponseContent
@@ -24477,7 +26810,7 @@ client.connections.scim_configuration.delete(
-Update a scim configuration by its `connectionId`. +Transitions an experiment through its lifecycle: draft → active, active → paused, paused → active, active/paused → completed. Activation runs full readiness validation.
@@ -24492,7 +26825,7 @@ Update a scim configuration by its `connectionId`.
```python -from auth0.management import Auth0, ScimMappingItem +from auth0.management import Auth0 from auth0.management.environment import Auth0Environment client = Auth0( @@ -24500,12 +26833,9 @@ client = Auth0( environment=Auth0Environment.DEFAULT, ) -client.connections.scim_configuration.update( +client.experimentation.experiments.update_status( id="id", - user_id_attribute="user_id_attribute", - mapping=[ - ScimMappingItem() - ], + status="active", ) ``` @@ -24522,7 +26852,7 @@ client.connections.scim_configuration.update(
-**id:** `str` — The id of the connection to update its SCIM configuration +**id:** `str` — The ID of the experiment to transition.
@@ -24530,15 +26860,7 @@ client.connections.scim_configuration.update(
-**user_id_attribute:** `str` — User ID attribute for generating unique user ids - -
-
- -
-
- -**mapping:** `typing.List[ScimMappingItem]` — The mapping between auth0 and SCIM +**status:** `ExperimentTransitionStatusEnum`
@@ -24558,7 +26880,7 @@ client.connections.scim_configuration.update(
-
client.connections.scim_configuration.get_default_mapping(...) -> GetScimConfigurationDefaultMappingResponseContent +
client.experimentation.experiments.validate(...) -> ValidateExperimentResponseContent
@@ -24570,7 +26892,7 @@ client.connections.scim_configuration.update(
-Retrieves a scim configuration's default mapping by its `connectionId`. +Checks whether an experiment is ready to be activated. Returns is_valid boolean and an errors array describing any blockers. Read-only; no state is modified.
@@ -24593,7 +26915,7 @@ client = Auth0( environment=Auth0Environment.DEFAULT, ) -client.connections.scim_configuration.get_default_mapping( +client.experimentation.experiments.validate( id="id", ) @@ -24611,7 +26933,7 @@ client.connections.scim_configuration.get_default_mapping(
-**id:** `str` — The id of the connection to retrieve its default SCIM mapping +**id:** `str` — The ID of the experiment to validate.
@@ -24631,8 +26953,8 @@ client.connections.scim_configuration.get_default_mapping(
-## Connections Clients -
client.connections.clients.get(...) -> GetConnectionEnabledClientsResponseContent +## Experimentation FeatureFlags +
client.experimentation.feature_flags.list(...) -> ListFeatureFlagsResponseContent
@@ -24644,9 +26966,7 @@ client.connections.scim_configuration.get_default_mapping(
-Retrieve all clients that have the specified [connection](https://auth0.com/docs/authenticate/identity-providers) enabled. - -**Note**: The first time you call this endpoint, omit the `from` parameter. If there are more results, a `next` value is included in the response. You can use this for subsequent API calls. When `next` is no longer included in the response, no further results are remaining. +Retrieve a paginated list of feature flags for the tenant.
@@ -24669,10 +26989,11 @@ client = Auth0( environment=Auth0Environment.DEFAULT, ) -client.connections.clients.get( - id="id", - take=1, +client.experimentation.feature_flags.list( from_="from", + take=1, + type="auth0", + status="draft", ) ``` @@ -24689,22 +27010,6 @@ client.connections.clients.get(
-**id:** `str` — The id of the connection for which enabled clients are to be retrieved - -
-
- -
-
- -**take:** `typing.Optional[int]` — Number of results per page. Defaults to 50. - -
-
- -
-
- **from:** `typing.Optional[str]` — Optional Id from which to start selection.
@@ -24713,64 +27018,15 @@ client.connections.clients.get(
-**request_options:** `typing.Optional[RequestOptions]` — Request-specific configuration. +**take:** `typing.Optional[int]` — Number of feature flags to return per page. Defaults to 25, maximum 50.
- -
- - - -
-
- -
client.connections.clients.update(...) -
-
- -#### 🔌 Usage
-
-
- -```python -from auth0.management import Auth0, UpdateEnabledClientConnectionsRequestContentItem -from auth0.management.environment import Auth0Environment - -client = Auth0( - token="", - environment=Auth0Environment.DEFAULT, -) - -client.connections.clients.update( - id="id", - request=[ - UpdateEnabledClientConnectionsRequestContentItem( - client_id="client_id", - status=True, - ) - ], -) - -``` -
-
-
-
- -#### ⚙️ Parameters - -
-
- -
-
- -**id:** `str` — The id of the connection to modify +**type:** `typing.Optional[FeatureFlagTypeEnum]` — Filter by type. Exact match.
@@ -24778,7 +27034,7 @@ client.connections.clients.update(
-**request:** `UpdateEnabledClientConnectionsRequestContent` +**status:** `typing.Optional[FeatureFlagStatusEnum]` — Filter by status. Exact match.
@@ -24798,8 +27054,7 @@ client.connections.clients.update(
-## Connections Keys -
client.connections.keys.get(...) -> typing.List[ConnectionKey] +
client.experimentation.feature_flags.create(...) -> CreateFeatureFlagResponseContent
@@ -24811,7 +27066,7 @@ client.connections.clients.update(
-Gets the connection keys for the Okta or OIDC connection strategy. +Create a new feature flag with parameters for use in experiments.
@@ -24834,8 +27089,9 @@ client = Auth0( environment=Auth0Environment.DEFAULT, ) -client.connections.keys.get( - id="id", +client.experimentation.feature_flags.create( + name="name", + parameters={}, ) ``` @@ -24852,81 +27108,15 @@ client.connections.keys.get(
-**id:** `str` — ID of the connection - -
-
- -
-
- -**request_options:** `typing.Optional[RequestOptions]` — Request-specific configuration. +**name:** `str` — A human-readable name for the feature flag
- -
- - - - -
- -
client.connections.keys.create(...) -> PostConnectionsKeysResponseContent -
-
- -#### 📝 Description - -
-
- -
-
- -Provision initial connection keys for Okta or OIDC connection strategies. This endpoint allows you to create keys before configuring the connection to use Private Key JWT authentication, enabling zero-downtime transitions. -
-
-
-
- -#### 🔌 Usage - -
-
- -
-
- -```python -from auth0.management import Auth0, PostConnectionKeysRequestContent -from auth0.management.environment import Auth0Environment - -client = Auth0( - token="", - environment=Auth0Environment.DEFAULT, -) - -client.connections.keys.create( - id="id", - request=PostConnectionKeysRequestContent(), -) - -``` -
-
-
-
- -#### ⚙️ Parameters - -
-
-**id:** `str` — ID of the connection +**parameters:** `CreateFeatureFlagParameters`
@@ -24934,7 +27124,7 @@ client.connections.keys.create(
-**request:** `typing.Optional[PostConnectionKeysRequestContent]` +**description:** `typing.Optional[str]` — A description of what this feature flag controls
@@ -24954,7 +27144,7 @@ client.connections.keys.create(
-
client.connections.keys.rotate(...) -> RotateConnectionsKeysResponseContent +
client.experimentation.feature_flags.get(...) -> GetFeatureFlagResponseContent
@@ -24966,7 +27156,7 @@ client.connections.keys.create(
-Rotates the connection keys for the Okta or OIDC connection strategies. +Retrieve a single feature flag by its ID.
@@ -24981,7 +27171,7 @@ Rotates the connection keys for the Okta or OIDC connection strategies.
```python -from auth0.management import Auth0, RotateConnectionKeysRequestContent +from auth0.management import Auth0 from auth0.management.environment import Auth0Environment client = Auth0( @@ -24989,9 +27179,8 @@ client = Auth0( environment=Auth0Environment.DEFAULT, ) -client.connections.keys.rotate( +client.experimentation.feature_flags.get( id="id", - request=RotateConnectionKeysRequestContent(), ) ``` @@ -25008,15 +27197,7 @@ client.connections.keys.rotate(
-**id:** `str` — ID of the connection - -
-
- -
-
- -**request:** `typing.Optional[RotateConnectionKeysRequestContent]` +**id:** `str` — The ID of the feature flag to retrieve.
@@ -25036,8 +27217,7 @@ client.connections.keys.rotate(
-## Connections Users -
client.connections.users.delete_by_email(...) +
client.experimentation.feature_flags.delete(...)
@@ -25049,7 +27229,7 @@ client.connections.keys.rotate(
-Deletes a specified connection user by its email (you cannot delete all users from specific connection). Currently, only Database Connections are supported. +Delete a feature flag by ID. Idempotent: returns 204 even if flag does not exist.
@@ -25072,9 +27252,8 @@ client = Auth0( environment=Auth0Environment.DEFAULT, ) -client.connections.users.delete_by_email( +client.experimentation.feature_flags.delete( id="id", - email="email", ) ``` @@ -25091,15 +27270,7 @@ client.connections.users.delete_by_email(
-**id:** `str` — The id of the connection (currently only database connections are supported) - -
-
- -
-
- -**email:** `str` — The email of the user to delete +**id:** `str` — The ID of the feature flag to delete.
@@ -25119,8 +27290,7 @@ client.connections.users.delete_by_email(
-## Connections DirectoryProvisioning Synchronizations -
client.connections.directory_provisioning.synchronizations.create(...) -> CreateDirectorySynchronizationResponseContent +
client.experimentation.feature_flags.update(...) -> UpdateFeatureFlagResponseContent
@@ -25132,7 +27302,7 @@ client.connections.users.delete_by_email(
-Request an on-demand synchronization of the directory. +Partially update a feature flag by ID. Only provided fields are updated.
@@ -25155,7 +27325,7 @@ client = Auth0( environment=Auth0Environment.DEFAULT, ) -client.connections.directory_provisioning.synchronizations.create( +client.experimentation.feature_flags.update( id="id", ) @@ -25173,7 +27343,7 @@ client.connections.directory_provisioning.synchronizations.create(
-**id:** `str` — The id of the connection to trigger synchronization for +**id:** `str` — The ID of the feature flag to update.
@@ -25181,73 +27351,23 @@ client.connections.directory_provisioning.synchronizations.create(
-**request_options:** `typing.Optional[RequestOptions]` — Request-specific configuration. +**name:** `typing.Optional[str]` — A human-readable name for the feature flag
- -
- - - - -
- -## Connections ScimConfiguration Tokens -
client.connections.scim_configuration.tokens.get(...) -> GetScimTokensResponseContent -
-
- -#### 📝 Description - -
-
- -
-
- -Retrieves all scim tokens by its connection `id`. -
-
-
-
- -#### 🔌 Usage - -
-
-```python -from auth0.management import Auth0 -from auth0.management.environment import Auth0Environment - -client = Auth0( - token="", - environment=Auth0Environment.DEFAULT, -) - -client.connections.scim_configuration.tokens.get( - id="id", -) - -``` -
-
+**description:** `typing.Optional[str]` — A description of what this feature flag controls +
-#### ⚙️ Parameters - -
-
-
-**id:** `str` — The id of the connection to retrieve its SCIM configuration +**parameters:** `typing.Optional[UpdateFeatureFlagParameters]`
@@ -25267,7 +27387,7 @@ client.connections.scim_configuration.tokens.get(
-
client.connections.scim_configuration.tokens.create(...) -> CreateScimTokenResponseContent +
client.experimentation.feature_flags.update_status(...) -> UpdateFeatureFlagStatusResponseContent
@@ -25279,7 +27399,7 @@ client.connections.scim_configuration.tokens.get(
-Create a scim token for a scim client. +Transitions a feature flag through its lifecycle states: draft → active, draft → archived, active → archived.
@@ -25302,8 +27422,9 @@ client = Auth0( environment=Auth0Environment.DEFAULT, ) -client.connections.scim_configuration.tokens.create( +client.experimentation.feature_flags.update_status( id="id", + status="draft", ) ``` @@ -25320,15 +27441,7 @@ client.connections.scim_configuration.tokens.create(
-**id:** `str` — The id of the connection to create its SCIM token - -
-
- -
-
- -**scopes:** `typing.Optional[typing.List[str]]` — The scopes of the scim token +**id:** `str` — The ID of the feature flag to transition.
@@ -25336,7 +27449,7 @@ client.connections.scim_configuration.tokens.create(
-**token_lifetime:** `typing.Optional[int]` — Lifetime of the token in seconds. Must be greater than 900 +**status:** `FeatureFlagStatusEnum` — The target status to transition the feature flag to.
@@ -25356,7 +27469,8 @@ client.connections.scim_configuration.tokens.create(
-
client.connections.scim_configuration.tokens.delete(...) +## Experimentation Segments +
client.experimentation.segments.list(...) -> ListSegmentsResponseContent
@@ -25368,7 +27482,7 @@ client.connections.scim_configuration.tokens.create(
-Deletes a scim token by its connection `id` and `tokenId`. +Retrieve a paginated list of segments for the tenant.
@@ -25391,9 +27505,10 @@ client = Auth0( environment=Auth0Environment.DEFAULT, ) -client.connections.scim_configuration.tokens.delete( - id="id", - token_id="tokenId", +client.experimentation.segments.list( + from_="from", + take=1, + type="auth0", ) ``` @@ -25410,7 +27525,7 @@ client.connections.scim_configuration.tokens.delete(
-**id:** `str` — The connection id that owns the SCIM token to delete +**from:** `typing.Optional[str]` — Optional Id from which to start selection.
@@ -25418,7 +27533,15 @@ client.connections.scim_configuration.tokens.delete(
-**token_id:** `str` — The id of the scim token to delete +**take:** `typing.Optional[int]` — Number of segments to return per page. Defaults to 25, maximum 50. + +
+
+ +
+
+ +**type:** `typing.Optional[SegmentTypeFilterEnum]` — Filter by type. Exact match.
@@ -25438,8 +27561,7 @@ client.connections.scim_configuration.tokens.delete(
-## Emails Provider -
client.emails.provider.get(...) -> GetEmailProviderResponseContent +
client.experimentation.segments.create(...) -> CreateSegmentResponseContent
@@ -25451,7 +27573,7 @@ client.connections.scim_configuration.tokens.delete(
-Retrieve details of the [email provider configuration](https://auth0.com/docs/customize/email/smtp-email-providers) in your tenant. A list of fields to include or exclude may also be specified. +Create a new segment with rule-based membership criteria for use in experiments.
@@ -25466,7 +27588,7 @@ Retrieve details of the [email provider configuration](https://auth0.com/docs/cu
```python -from auth0.management import Auth0 +from auth0.management import Auth0, SegmentRule from auth0.management.environment import Auth0Environment client = Auth0( @@ -25474,9 +27596,11 @@ client = Auth0( environment=Auth0Environment.DEFAULT, ) -client.emails.provider.get( - fields="fields", - include_fields=True, +client.experimentation.segments.create( + name="name", + rules=[ + SegmentRule() + ], ) ``` @@ -25493,7 +27617,7 @@ client.emails.provider.get(
-**fields:** `typing.Optional[str]` — Comma-separated list of fields to include or exclude (dependent upon include_fields) from the result. Leave empty to retrieve `name` and `enabled`. Additional fields available include `credentials`, `default_from_address`, and `settings`. +**name:** `str` — A human-readable name for the segment
@@ -25501,7 +27625,15 @@ client.emails.provider.get(
-**include_fields:** `typing.Optional[bool]` — Whether specified fields are to be included (true) or excluded (false). +**rules:** `typing.List[SegmentRule]` — An ordered list of rules. A segment matches if any rule matches. Each rule is limited to 4KB and the whole segment to 10KB (serialized). + +
+
+ +
+
+ +**description:** `typing.Optional[str]` — A description of the segment
@@ -25521,7 +27653,7 @@ client.emails.provider.get(
-
client.emails.provider.create(...) -> CreateEmailProviderResponseContent +
client.experimentation.segments.get(...) -> GetSegmentResponseContent
@@ -25533,31 +27665,7 @@ client.emails.provider.get(
-Create an [email provider](https://auth0.com/docs/email/providers). The `credentials` object -requires different properties depending on the email provider (which is specified using the `name` property): - -- `mandrill` requires `api_key` -- `sendgrid` requires `api_key` -- `sparkpost` requires `api_key`. Optionally, set `region` to `eu` to use - the SparkPost service hosted in Western Europe; set to `null` to use the SparkPost service hosted in - North America. `eu` or `null` are the only valid values for `region`. -- `mailgun` requires `api_key` and `domain`. Optionally, set `region` to - `eu` to use the Mailgun service hosted in Europe; set to `null` otherwise. `eu` or - `null` are the only valid values for `region`. -- `ses` requires `accessKeyId`, `secretAccessKey`, and `region` -- `smtp` requires `smtp_host`, `smtp_port`, `smtp_user`, and - `smtp_pass` - -Depending on the type of provider it is possible to specify `settings` object with different configuration -options, which will be used when sending an email: - -- `smtp` provider, `settings` may contain `headers` object. - - When using AWS SES SMTP host, you may provide a name of configuration set in - `X-SES-Configuration-Set` header. Value must be a string. - - When using Sparkpost host, you may provide value for - `X-MSYS_API` header. Value must be an object. -- For `ses` provider, `settings` may contain `message` object, where you can provide - a name of configuration set in `configuration_set_name` property. Value must be a string. +Retrieve a single segment by its ID.
@@ -25572,7 +27680,7 @@ options, which will be used when sending an email:
```python -from auth0.management import Auth0, EmailProviderCredentialsSchemaZero +from auth0.management import Auth0 from auth0.management.environment import Auth0Environment client = Auth0( @@ -25580,11 +27688,8 @@ client = Auth0( environment=Auth0Environment.DEFAULT, ) -client.emails.provider.create( - name="mailgun", - credentials=EmailProviderCredentialsSchemaZero( - api_key="api_key", - ), +client.experimentation.segments.get( + id="id", ) ``` @@ -25601,39 +27706,7 @@ client.emails.provider.create(
-**name:** `EmailProviderNameEnum` - -
-
- -
-
- -**credentials:** `EmailProviderCredentialsSchema` - -
-
- -
-
- -**enabled:** `typing.Optional[bool]` — Whether the provider is enabled (true) or disabled (false). - -
-
- -
-
- -**default_from_address:** `typing.Optional[str]` — Email address to use as "from" when no other address specified. - -
-
- -
-
- -**settings:** `typing.Optional[EmailSpecificProviderSettingsWithAdditionalProperties]` +**id:** `str` — The ID of the segment to retrieve.
@@ -25653,7 +27726,7 @@ client.emails.provider.create(
-
client.emails.provider.delete() +
client.experimentation.segments.delete(...)
@@ -25665,7 +27738,7 @@ client.emails.provider.create(
-Delete the email provider. +Delete a segment by ID. Idempotent: returns 204 even if segment does not exist.
@@ -25688,7 +27761,9 @@ client = Auth0( environment=Auth0Environment.DEFAULT, ) -client.emails.provider.delete() +client.experimentation.segments.delete( + id="id", +) ``` @@ -25704,6 +27779,14 @@ client.emails.provider.delete()
+**id:** `str` — The ID of the segment to delete. + +
+
+ +
+
+ **request_options:** `typing.Optional[RequestOptions]` — Request-specific configuration.
@@ -25716,7 +27799,7 @@ client.emails.provider.delete()
-
client.emails.provider.update(...) -> UpdateEmailProviderResponseContent +
client.experimentation.segments.update(...) -> UpdateSegmentResponseContent
@@ -25728,32 +27811,7 @@ client.emails.provider.delete()
-Update an [email provider](https://auth0.com/docs/email/providers). The `credentials` object -requires different properties depending on the email provider (which is specified using the `name` property): - -- `mandrill` requires `api_key` -- `sendgrid` requires `api_key` -- `sparkpost` requires `api_key`. Optionally, set `region` to `eu` to use - the SparkPost service hosted in Western Europe; set to `null` to use the SparkPost service hosted in - North America. `eu` or `null` are the only valid values for `region`. -- `mailgun` requires `api_key` and `domain`. Optionally, set `region` to - `eu` to use the Mailgun service hosted in Europe; set to `null` otherwise. `eu` or - `null` are the only valid values for `region`. -- `ses` requires `accessKeyId`, `secretAccessKey`, and `region` -- `smtp` requires `smtp_host`, `smtp_port`, `smtp_user`, and - `smtp_pass` - -Depending on the type of provider it is possible to specify `settings` object with different configuration -options, which will be used when sending an email: - -- `smtp` provider, `settings` may contain `headers` object. - - When using AWS SES SMTP host, you may provide a name of configuration set in - `X-SES-Configuration-Set` header. Value must be a string. - - When using Sparkpost host, you may provide value for - `X-MSYS_API` header. Value must be an object. - - For `ses` provider, `settings` may contain `message` object, where you can provide - a name of configuration set in `configuration_set_name` property. Value must be a string. +Partially update a segment by ID. Only provided fields are updated. Sending rules replaces the entire rules array.
@@ -25776,7 +27834,9 @@ client = Auth0( environment=Auth0Environment.DEFAULT, ) -client.emails.provider.update() +client.experimentation.segments.update( + id="id", +) ``` @@ -25792,7 +27852,7 @@ client.emails.provider.update()
-**name:** `typing.Optional[EmailProviderNameEnum]` +**id:** `str` — The ID of the segment to update.
@@ -25800,7 +27860,7 @@ client.emails.provider.update()
-**enabled:** `typing.Optional[bool]` — Whether the provider is enabled (true) or disabled (false). +**name:** `typing.Optional[str]` — A human-readable name for the segment
@@ -25808,7 +27868,7 @@ client.emails.provider.update()
-**default_from_address:** `typing.Optional[str]` — Email address to use as "from" when no other address specified. +**description:** `typing.Optional[str]` — A description of the segment
@@ -25816,15 +27876,7 @@ client.emails.provider.update()
-**credentials:** `typing.Optional[EmailProviderCredentialsSchema]` - -
-
- -
-
- -**settings:** `typing.Optional[EmailSpecificProviderSettingsWithAdditionalProperties]` +**rules:** `typing.Optional[typing.List[SegmentRule]]` — Replaces the entire rules array. Each rule is limited to 4KB and the whole segment to 10KB (serialized).
@@ -25844,11 +27896,25 @@ client.emails.provider.update()
-## EventStreams Deliveries -
client.event_streams.deliveries.list(...) -> ListEventStreamDeliveriesResponseContent +## Experimentation FeatureFlags Variations +
client.experimentation.feature_flags.variations.list(...) -> ListVariationsResponseContent +
+
+ +#### 📝 Description + +
+
+
+Retrieve all variations defined for a specific feature flag. +
+
+
+
+ #### 🔌 Usage
@@ -25866,14 +27932,8 @@ client = Auth0( environment=Auth0Environment.DEFAULT, ) -client.event_streams.deliveries.list( +client.experimentation.feature_flags.variations.list( id="id", - statuses="statuses", - event_types="event_types", - date_from="date_from", - date_to="date_to", - from_="from", - take=1, ) ``` @@ -25890,15 +27950,7 @@ client.event_streams.deliveries.list(
-**id:** `str` — Unique identifier for the event stream. - -
-
- -
-
- -**statuses:** `typing.Optional[str]` — Comma-separated list of statuses by which to filter +**id:** `str` — The ID of the parent feature flag.
@@ -25906,61 +27958,35 @@ client.event_streams.deliveries.list(
-**event_types:** `typing.Optional[str]` — Comma-separated list of event types by which to filter +**request_options:** `typing.Optional[RequestOptions]` — Request-specific configuration.
- -
-
- -**date_from:** `typing.Optional[str]` — An RFC-3339 date-time for redelivery start, inclusive. Does not allow sub-second precision. -
-
-
-**date_to:** `typing.Optional[str]` — An RFC-3339 date-time for redelivery end, exclusive. Does not allow sub-second precision. -
+
+
client.experimentation.feature_flags.variations.create(...) -> CreateVariationResponseContent
-**from:** `typing.Optional[str]` — Optional Id from which to start selection. - -
-
+#### 📝 Description
-**take:** `typing.Optional[int]` — Number of results per page. Defaults to 50. - -
-
-
-**request_options:** `typing.Optional[RequestOptions]` — Request-specific configuration. - -
-
+Create a new variation with parameter overrides for a specific feature flag. - - -
- -
client.event_streams.deliveries.get_history(...) -> GetEventStreamDeliveryHistoryResponseContent -
-
#### 🔌 Usage @@ -25979,9 +28005,12 @@ client = Auth0( environment=Auth0Environment.DEFAULT, ) -client.event_streams.deliveries.get_history( +client.experimentation.feature_flags.variations.create( id="id", - event_id="event_id", + name="name", + overrides={ + "key": "value" + }, ) ``` @@ -25998,7 +28027,7 @@ client.event_streams.deliveries.get_history(
-**id:** `str` — Unique identifier for the event stream. +**id:** `str` — The ID of the parent feature flag.
@@ -26006,7 +28035,23 @@ client.event_streams.deliveries.get_history(
-**event_id:** `str` — Unique identifier for the event +**name:** `str` — A human-readable name for the variation + +
+
+ +
+
+ +**overrides:** `VariationOverridesMap` — Configuration overrides for this variation; keys must exist in the parent flag parameters. Empty {} is the baseline (control) variation that overrides nothing. + +
+
+ +
+
+ +**description:** `typing.Optional[str]` — A description of what this variation controls
@@ -26026,11 +28071,24 @@ client.event_streams.deliveries.get_history(
-## EventStreams Redeliveries -
client.event_streams.redeliveries.create(...) -> CreateEventStreamRedeliveryResponseContent +
client.experimentation.feature_flags.variations.get(...) -> GetVariationResponseContent +
+
+ +#### 📝 Description + +
+
+
+Retrieve a single variation by its ID. +
+
+
+
+ #### 🔌 Usage
@@ -26048,8 +28106,9 @@ client = Auth0( environment=Auth0Environment.DEFAULT, ) -client.event_streams.redeliveries.create( +client.experimentation.feature_flags.variations.get( id="id", + vid="vid", ) ``` @@ -26066,7 +28125,7 @@ client.event_streams.redeliveries.create(
-**id:** `str` — Unique identifier for the event stream. +**id:** `str` — The ID of the parent feature flag.
@@ -26074,7 +28133,7 @@ client.event_streams.redeliveries.create(
-**date_from:** `typing.Optional[datetime.datetime]` — An RFC-3339 date-time for redelivery start, inclusive. Does not allow sub-second precision. +**vid:** `str` — The ID of the variation to retrieve.
@@ -26082,46 +28141,36 @@ client.event_streams.redeliveries.create(
-**date_to:** `typing.Optional[datetime.datetime]` — An RFC-3339 date-time for redelivery end, exclusive. Does not allow sub-second precision. +**request_options:** `typing.Optional[RequestOptions]` — Request-specific configuration.
+
+
-
-
-**statuses:** `typing.Optional[typing.List[EventStreamDeliveryStatusEnum]]` — Filter by status -
+
+
client.experimentation.feature_flags.variations.delete(...)
-**event_types:** `typing.Optional[typing.List[EventStreamEventTypeEnum]]` — Filter by event type - -
-
+#### 📝 Description
-**request_options:** `typing.Optional[RequestOptions]` — Request-specific configuration. - +
+
+ +Delete a variation by ID. Returns 204 if the variation does not exist. Returns 404 if the parent feature flag does not exist.
- - - -
- -
client.event_streams.redeliveries.create_by_id(...) -
-
- #### 🔌 Usage
@@ -26139,9 +28188,9 @@ client = Auth0( environment=Auth0Environment.DEFAULT, ) -client.event_streams.redeliveries.create_by_id( +client.experimentation.feature_flags.variations.delete( id="id", - event_id="event_id", + vid="vid", ) ``` @@ -26158,7 +28207,7 @@ client.event_streams.redeliveries.create_by_id(
-**id:** `str` — Unique identifier for the event stream. +**id:** `str` — The ID of the parent feature flag.
@@ -26166,7 +28215,7 @@ client.event_streams.redeliveries.create_by_id(
-**event_id:** `str` — Unique identifier for the event +**vid:** `str` — The ID of the variation to delete.
@@ -26186,8 +28235,7 @@ client.event_streams.redeliveries.create_by_id(
-## Experimentation Experiments -
client.experimentation.experiments.advance_ramp(...) -> AdvanceRampResponseContent +
client.experimentation.feature_flags.variations.update(...) -> UpdateVariationResponseContent
@@ -26199,7 +28247,7 @@ client.event_streams.redeliveries.create_by_id(
-Increments the current ramp index to the requested target level. Up-only: the target must be the immediate next level in the schedule. Idempotent: calling with the current level returns success without writing anything. +Partially update a variation by ID. Only provided fields are updated.
@@ -26222,9 +28270,9 @@ client = Auth0( environment=Auth0Environment.DEFAULT, ) -client.experimentation.experiments.advance_ramp( +client.experimentation.feature_flags.variations.update( id="id", - target_level=1, + vid="vid", ) ``` @@ -26241,7 +28289,7 @@ client.experimentation.experiments.advance_ramp(
-**id:** `str` — The ID of the experiment to advance. +**id:** `str` — The ID of the parent feature flag.
@@ -26249,7 +28297,31 @@ client.experimentation.experiments.advance_ramp(
-**target_level:** `int` — The target percentage level from the experiment schedule. Must be the immediate next level. +**vid:** `str` — The ID of the variation to update. + +
+
+ +
+
+ +**name:** `typing.Optional[str]` — A human-readable name for the variation + +
+
+ +
+
+ +**description:** `typing.Optional[str]` — A description of what this variation controls + +
+
+ +
+
+ +**overrides:** `typing.Optional[UpdateVariationOverridesMap]`
@@ -32531,271 +34603,10 @@ client = Auth0( environment=Auth0Environment.DEFAULT, ) -client.organizations.clients.list( - id="id", - from_="from", - take=1, -) - -``` - -
- - - -#### ⚙️ Parameters - -
-
- -
-
- -**id:** `str` — ID of the organization. - -
-
- -
-
- -**from:** `typing.Optional[str]` — Optional Id from which to start selection. - -
-
- -
-
- -**take:** `typing.Optional[int]` — Number of results per page. Defaults to 50. Values greater than the maximum of 100 are capped at 100. - -
-
- -
-
- -**request_options:** `typing.Optional[RequestOptions]` — Request-specific configuration. - -
-
-
-
- - - - -
- -
client.organizations.clients.create(...) -> CreateOrganizationClientsResponseContent -
-
- -#### 📝 Description - -
-
- -
-
- -Associate one or more clients with an organization. -
-
-
-
- -#### 🔌 Usage - -
-
- -
-
- -```python -from auth0.management import Auth0, CreateOrganizationClientRequestItem -from auth0.management.environment import Auth0Environment - -client = Auth0( - token="", - environment=Auth0Environment.DEFAULT, -) - -client.organizations.clients.create( - id="id", - clients=[ - CreateOrganizationClientRequestItem( - client_id="client_id", - use_for_member_access=True, - ) - ], -) - -``` -
-
-
-
- -#### ⚙️ Parameters - -
-
- -
-
- -**id:** `str` — ID of the organization. - -
-
- -
-
- -**clients:** `typing.List[CreateOrganizationClientRequestItem]` — List of clients to associate with the organization. - -
-
- -
-
- -**request_options:** `typing.Optional[RequestOptions]` — Request-specific configuration. - -
-
-
-
- - -
-
-
- -
client.organizations.clients.delete(...) -
-
- -#### 📝 Description - -
-
- -
-
- -Remove one or more client associations from an organization. -
-
-
-
- -#### 🔌 Usage - -
-
- -
-
- -```python -from auth0.management import Auth0 -from auth0.management.environment import Auth0Environment - -client = Auth0( - token="", - environment=Auth0Environment.DEFAULT, -) - -client.organizations.clients.delete( - id="id", - clients=[ - "clients" - ], -) - -``` -
-
-
-
- -#### ⚙️ Parameters - -
-
- -
-
- -**id:** `str` — ID of the organization. - -
-
- -
-
- -**clients:** `typing.List[str]` — List of client IDs to disassociate from the organization. - -
-
- -
-
- -**request_options:** `typing.Optional[RequestOptions]` — Request-specific configuration. - -
-
-
-
- - -
-
-
- -
client.organizations.clients.get(...) -> GetOrganizationClientResponseContent -
-
- -#### 📝 Description - -
-
- -
-
- -Get a specific client association for an organization. -
-
-
-
- -#### 🔌 Usage - -
-
- -
-
- -```python -from auth0.management import Auth0 -from auth0.management.environment import Auth0Environment - -client = Auth0( - token="", - environment=Auth0Environment.DEFAULT, -) - -client.organizations.clients.get( +client.organizations.clients.list( id="id", - client_id="client_id", + from_="from", + take=1, ) ``` @@ -32820,7 +34631,15 @@ client.organizations.clients.get(
-**client_id:** `str` — ID of the client association to retrieve. +**from:** `typing.Optional[str]` — Optional Id from which to start selection. + +
+
+ +
+
+ +**take:** `typing.Optional[int]` — Number of results per page. Defaults to 50. Values greater than the maximum of 100 are capped at 100.
@@ -32840,7 +34659,7 @@ client.organizations.clients.get(
-
client.organizations.clients.update(...) -> UpdateOrganizationClientResponseContent +
client.organizations.clients.create(...) -> CreateOrganizationClientsResponseContent
@@ -32852,7 +34671,7 @@ client.organizations.clients.get(
-Update an organization client association. +Associate one or more clients with an organization.
@@ -32867,7 +34686,7 @@ Update an organization client association.
```python -from auth0.management import Auth0 +from auth0.management import Auth0, CreateOrganizationClientRequestItem from auth0.management.environment import Auth0Environment client = Auth0( @@ -32875,9 +34694,14 @@ client = Auth0( environment=Auth0Environment.DEFAULT, ) -client.organizations.clients.update( +client.organizations.clients.create( id="id", - client_id="client_id", + clients=[ + CreateOrganizationClientRequestItem( + client_id="client_id", + use_for_member_access=True, + ) + ], ) ``` @@ -32902,15 +34726,7 @@ client.organizations.clients.update(
-**client_id:** `str` — ID of the client association to update. - -
-
- -
-
- -**use_for_member_access:** `typing.Optional[bool]` — Whether this client is used for member access to the organization. +**clients:** `typing.List[CreateOrganizationClientRequestItem]` — List of clients to associate with the organization.
@@ -32930,11 +34746,24 @@ client.organizations.clients.update(
-## Organizations Connections -
client.organizations.connections.list(...) -> ListOrganizationAllConnectionsOffsetPaginatedResponseContent +
client.organizations.clients.delete(...) +
+
+ +#### 📝 Description + +
+
+
+Remove one or more client associations from an organization. +
+
+
+
+ #### 🔌 Usage
@@ -32952,12 +34781,11 @@ client = Auth0( environment=Auth0Environment.DEFAULT, ) -client.organizations.connections.list( +client.organizations.clients.delete( id="id", - page=1, - per_page=1, - include_totals=True, - is_enabled=True, + clients=[ + "clients" + ], ) ``` @@ -32974,7 +34802,7 @@ client.organizations.connections.list(
-**id:** `str` — Organization identifier. +**id:** `str` — ID of the organization.
@@ -32982,7 +34810,7 @@ client.organizations.connections.list(
-**page:** `typing.Optional[int]` — Page index of the results to return. First page is 0. +**clients:** `typing.List[str]` — List of client IDs to disassociate from the organization.
@@ -32990,45 +34818,35 @@ client.organizations.connections.list(
-**per_page:** `typing.Optional[int]` — Number of results per page. Defaults to 50. +**request_options:** `typing.Optional[RequestOptions]` — Request-specific configuration.
+
+
-
-
-**include_totals:** `typing.Optional[bool]` — Return results inside an object that contains the total result count (true) or as a direct array of results (false, default). -
+
+
client.organizations.clients.get(...) -> GetOrganizationClientResponseContent
-**is_enabled:** `typing.Optional[bool]` — Filter connections by enabled status. - -
-
+#### 📝 Description
-**request_options:** `typing.Optional[RequestOptions]` — Request-specific configuration. - -
-
+
+
+ +Get a specific client association for an organization.
- - -
- -
client.organizations.connections.create(...) -> CreateOrganizationAllConnectionResponseContent -
-
#### 🔌 Usage @@ -33047,9 +34865,9 @@ client = Auth0( environment=Auth0Environment.DEFAULT, ) -client.organizations.connections.create( +client.organizations.clients.get( id="id", - connection_id="connection_id", + client_id="client_id", ) ``` @@ -33066,7 +34884,7 @@ client.organizations.connections.create(
-**id:** `str` — Organization identifier. +**id:** `str` — ID of the organization.
@@ -33074,7 +34892,7 @@ client.organizations.connections.create(
-**connection_id:** `str` — Connection identifier. +**client_id:** `str` — ID of the client association to retrieve.
@@ -33082,39 +34900,73 @@ client.organizations.connections.create(
-**organization_connection_name:** `typing.Optional[str]` — Name of the connection in the scope of this organization. +**request_options:** `typing.Optional[RequestOptions]` — Request-specific configuration.
+
+
-
-
-**assign_membership_on_login:** `typing.Optional[bool]` — When true, all users that log in with this connection will be automatically granted membership in the organization. When false, users must be granted membership in the organization before logging in with this connection. -
+
+
client.organizations.clients.update(...) -> UpdateOrganizationClientResponseContent
-**show_as_button:** `typing.Optional[bool]` — Determines whether a connection should be displayed on this organization’s login prompt. Only applicable for enterprise connections. Default: true. - +#### 📝 Description + +
+
+ +
+
+ +Update an organization client association.
+
+
+ +#### 🔌 Usage
-**is_signup_enabled:** `typing.Optional[bool]` — Determines whether organization signup should be enabled for this organization connection. Only applicable for database connections. Default: false. - +
+
+ +```python +from auth0.management import Auth0 +from auth0.management.environment import Auth0Environment + +client = Auth0( + token="", + environment=Auth0Environment.DEFAULT, +) + +client.organizations.clients.update( + id="id", + client_id="client_id", +) + +``` +
+
+#### ⚙️ Parameters +
-**organization_access_level:** `typing.Optional[OrganizationAccessLevelEnum]` +
+
+ +**id:** `str` — ID of the organization.
@@ -33122,7 +34974,7 @@ client.organizations.connections.create(
-**organization_member_access_level:** `typing.Optional[OrganizationMemberAccessLevelEnum]` +**client_id:** `str` — ID of the client association to update.
@@ -33130,7 +34982,7 @@ client.organizations.connections.create(
-**is_enabled:** `typing.Optional[bool]` — Whether the connection is enabled for the organization. +**use_for_member_access:** `typing.Optional[bool]` — Whether this client is used for member access to the organization.
@@ -33150,7 +35002,8 @@ client.organizations.connections.create(
-
client.organizations.connections.get(...) -> GetOrganizationAllConnectionResponseContent +## Organizations Connections +
client.organizations.connections.list(...) -> ListOrganizationAllConnectionsOffsetPaginatedResponseContent
@@ -33171,9 +35024,12 @@ client = Auth0( environment=Auth0Environment.DEFAULT, ) -client.organizations.connections.get( +client.organizations.connections.list( id="id", - connection_id="connection_id", + page=1, + per_page=1, + include_totals=True, + is_enabled=True, ) ``` @@ -33198,7 +35054,31 @@ client.organizations.connections.get(
-**connection_id:** `str` — Connection identifier. +**page:** `typing.Optional[int]` — Page index of the results to return. First page is 0. + +
+
+ +
+
+ +**per_page:** `typing.Optional[int]` — Number of results per page. Defaults to 50. + +
+
+ +
+
+ +**include_totals:** `typing.Optional[bool]` — Return results inside an object that contains the total result count (true) or as a direct array of results (false, default). + +
+
+ +
+
+ +**is_enabled:** `typing.Optional[bool]` — Filter connections by enabled status.
@@ -33218,7 +35098,7 @@ client.organizations.connections.get(
-
client.organizations.connections.delete(...) +
client.organizations.connections.create(...) -> CreateOrganizationAllConnectionResponseContent
@@ -33239,7 +35119,7 @@ client = Auth0( environment=Auth0Environment.DEFAULT, ) -client.organizations.connections.delete( +client.organizations.connections.create( id="id", connection_id="connection_id", ) @@ -33274,6 +35154,62 @@ client.organizations.connections.delete(
+**organization_connection_name:** `typing.Optional[str]` — Name of the connection in the scope of this organization. + +
+
+ +
+
+ +**assign_membership_on_login:** `typing.Optional[bool]` — When true, all users that log in with this connection will be automatically granted membership in the organization. When false, users must be granted membership in the organization before logging in with this connection. + +
+
+ +
+
+ +**show_as_button:** `typing.Optional[bool]` — Determines whether a connection should be displayed on this organization’s login prompt. Only applicable for enterprise connections. Default: true. + +
+
+ +
+
+ +**is_signup_enabled:** `typing.Optional[bool]` — Determines whether organization signup should be enabled for this organization connection. Only applicable for database connections. Default: false. + +
+
+ +
+
+ +**organization_access_level:** `typing.Optional[OrganizationAccessLevelEnum]` + +
+
+ +
+
+ +**organization_member_access_level:** `typing.Optional[OrganizationMemberAccessLevelEnum]` + +
+
+ +
+
+ +**is_enabled:** `typing.Optional[bool]` — Whether the connection is enabled for the organization. + +
+
+ +
+
+ **request_options:** `typing.Optional[RequestOptions]` — Request-specific configuration.
@@ -33286,7 +35222,7 @@ client.organizations.connections.delete(
-
client.organizations.connections.update(...) -> UpdateOrganizationAllConnectionResponseContent +
client.organizations.connections.get(...) -> GetOrganizationAllConnectionResponseContent
@@ -33307,7 +35243,7 @@ client = Auth0( environment=Auth0Environment.DEFAULT, ) -client.organizations.connections.update( +client.organizations.connections.get( id="id", connection_id="connection_id", ) @@ -33342,47 +35278,59 @@ client.organizations.connections.update(
-**organization_connection_name:** `typing.Optional[str]` — Name of the connection in the scope of this organization. +**request_options:** `typing.Optional[RequestOptions]` — Request-specific configuration.
+
+
-
-
-**assign_membership_on_login:** `typing.Optional[bool]` — When true, all users that log in with this connection will be automatically granted membership in the organization. When false, users must be granted membership in the organization before logging in with this connection. -
+
+
client.organizations.connections.delete(...)
-**show_as_button:** `typing.Optional[bool]` — Determines whether a connection should be displayed on this organization’s login prompt. Only applicable for enterprise connections. Default: true. - -
-
+#### 🔌 Usage
-**is_signup_enabled:** `typing.Optional[bool]` — Determines whether organization signup should be enabled for this organization connection. Only applicable for database connections. Default: false. - -
-
-
-**organization_access_level:** `typing.Optional[OrganizationAccessLevelEnumWithNull]` - +```python +from auth0.management import Auth0 +from auth0.management.environment import Auth0Environment + +client = Auth0( + token="", + environment=Auth0Environment.DEFAULT, +) + +client.organizations.connections.delete( + id="id", + connection_id="connection_id", +) + +```
+ + + +#### ⚙️ Parameters
-**organization_member_access_level:** `typing.Optional[OrganizationMemberAccessLevelEnumWithNull]` +
+
+ +**id:** `str` — Organization identifier.
@@ -33390,7 +35338,7 @@ client.organizations.connections.update(
-**is_enabled:** `typing.Optional[bool]` — Whether the connection is enabled for the organization. +**connection_id:** `str` — Connection identifier.
@@ -33410,26 +35358,10 @@ client.organizations.connections.update(
-## Organizations DiscoveryDomains -
client.organizations.discovery_domains.list(...) -> ListOrganizationDiscoveryDomainsResponseContent -
-
- -#### 📝 Description - -
-
- +
client.organizations.connections.update(...) -> UpdateOrganizationAllConnectionResponseContent
-Retrieve list of all organization discovery domains associated with the specified organization. -This endpoint is subject to eventual consistency; newly created, updated, or deleted discovery domains may not immediately appear in the response. -
-
-
-
- #### 🔌 Usage
@@ -33447,10 +35379,9 @@ client = Auth0( environment=Auth0Environment.DEFAULT, ) -client.organizations.discovery_domains.list( +client.organizations.connections.update( id="id", - from_="from", - take=1, + connection_id="connection_id", ) ``` @@ -33467,7 +35398,7 @@ client.organizations.discovery_domains.list(
-**id:** `str` — ID of the organization. +**id:** `str` — Organization identifier.
@@ -33475,7 +35406,7 @@ client.organizations.discovery_domains.list(
-**from:** `typing.Optional[str]` — Optional Id from which to start selection. +**connection_id:** `str` — Connection identifier.
@@ -33483,7 +35414,7 @@ client.organizations.discovery_domains.list(
-**take:** `typing.Optional[int]` — Number of results per page. Defaults to 50. +**organization_connection_name:** `typing.Optional[str]` — Name of the connection in the scope of this organization.
@@ -33491,73 +35422,23 @@ client.organizations.discovery_domains.list(
-**request_options:** `typing.Optional[RequestOptions]` — Request-specific configuration. +**assign_membership_on_login:** `typing.Optional[bool]` — When true, all users that log in with this connection will be automatically granted membership in the organization. When false, users must be granted membership in the organization before logging in with this connection.
-
-
- - - - -
- -
client.organizations.discovery_domains.create(...) -> CreateOrganizationDiscoveryDomainResponseContent -
-
- -#### 📝 Description - -
-
-Create a new discovery domain for an organization. -
-
-
-
- -#### 🔌 Usage - -
-
- -
-
- -```python -from auth0.management import Auth0 -from auth0.management.environment import Auth0Environment - -client = Auth0( - token="", - environment=Auth0Environment.DEFAULT, -) - -client.organizations.discovery_domains.create( - id="id", - domain="domain", -) - -``` -
-
+**show_as_button:** `typing.Optional[bool]` — Determines whether a connection should be displayed on this organization’s login prompt. Only applicable for enterprise connections. Default: true. +
-#### ⚙️ Parameters -
-
-
- -**id:** `str` — ID of the organization. +**is_signup_enabled:** `typing.Optional[bool]` — Determines whether organization signup should be enabled for this organization connection. Only applicable for database connections. Default: false.
@@ -33565,7 +35446,7 @@ client.organizations.discovery_domains.create(
-**domain:** `str` — The domain name to associate with the organization e.g. acme.com. +**organization_access_level:** `typing.Optional[OrganizationAccessLevelEnumWithNull]`
@@ -33573,7 +35454,7 @@ client.organizations.discovery_domains.create(
-**status:** `typing.Optional[OrganizationDiscoveryDomainStatus]` +**organization_member_access_level:** `typing.Optional[OrganizationMemberAccessLevelEnumWithNull]`
@@ -33581,7 +35462,7 @@ client.organizations.discovery_domains.create(
-**use_for_organization_discovery:** `typing.Optional[bool]` — Indicates whether this domain should be used for organization discovery. +**is_enabled:** `typing.Optional[bool]` — Whether the connection is enabled for the organization.
@@ -33601,7 +35482,8 @@ client.organizations.discovery_domains.create(
-
client.organizations.discovery_domains.get_by_name(...) -> GetOrganizationDiscoveryDomainByNameResponseContent +## Organizations DiscoveryDomains +
client.organizations.discovery_domains.list(...) -> ListOrganizationDiscoveryDomainsResponseContent
@@ -33613,7 +35495,7 @@ client.organizations.discovery_domains.create(
-Retrieve details about a single organization discovery domain specified by domain name. +Retrieve list of all organization discovery domains associated with the specified organization. This endpoint is subject to eventual consistency; newly created, updated, or deleted discovery domains may not immediately appear in the response.
@@ -33637,9 +35519,10 @@ client = Auth0( environment=Auth0Environment.DEFAULT, ) -client.organizations.discovery_domains.get_by_name( +client.organizations.discovery_domains.list( id="id", - discovery_domain="discovery_domain", + from_="from", + take=1, ) ``` @@ -33664,7 +35547,15 @@ client.organizations.discovery_domains.get_by_name(
-**discovery_domain:** `str` — Domain name of the discovery domain. +**from:** `typing.Optional[str]` — Optional Id from which to start selection. + +
+
+ +
+
+ +**take:** `typing.Optional[int]` — Number of results per page. Defaults to 50.
@@ -33684,7 +35575,7 @@ client.organizations.discovery_domains.get_by_name(
-
client.organizations.discovery_domains.get(...) -> GetOrganizationDiscoveryDomainResponseContent +
client.organizations.discovery_domains.create(...) -> CreateOrganizationDiscoveryDomainResponseContent
@@ -33696,8 +35587,7 @@ client.organizations.discovery_domains.get_by_name(
-Retrieve details about a single organization discovery domain specified by ID. -This endpoint is subject to eventual consistency; newly created, updated, or deleted discovery domains may not immediately appear in the response. +Create a new discovery domain for an organization.
@@ -33720,9 +35610,9 @@ client = Auth0( environment=Auth0Environment.DEFAULT, ) -client.organizations.discovery_domains.get( +client.organizations.discovery_domains.create( id="id", - discovery_domain_id="discovery_domain_id", + domain="domain", ) ``` @@ -33747,7 +35637,23 @@ client.organizations.discovery_domains.get(
-**discovery_domain_id:** `str` — ID of the discovery domain. +**domain:** `str` — The domain name to associate with the organization e.g. acme.com. + +
+
+ +
+
+ +**status:** `typing.Optional[OrganizationDiscoveryDomainStatus]` + +
+
+ +
+
+ +**use_for_organization_discovery:** `typing.Optional[bool]` — Indicates whether this domain should be used for organization discovery.
@@ -33767,7 +35673,7 @@ client.organizations.discovery_domains.get(
-
client.organizations.discovery_domains.delete(...) +
client.organizations.discovery_domains.get_by_name(...) -> GetOrganizationDiscoveryDomainByNameResponseContent
@@ -33779,7 +35685,8 @@ client.organizations.discovery_domains.get(
-Remove a discovery domain from an organization. This action cannot be undone. +Retrieve details about a single organization discovery domain specified by domain name. +This endpoint is subject to eventual consistency; newly created, updated, or deleted discovery domains may not immediately appear in the response.
@@ -33802,9 +35709,9 @@ client = Auth0( environment=Auth0Environment.DEFAULT, ) -client.organizations.discovery_domains.delete( +client.organizations.discovery_domains.get_by_name( id="id", - discovery_domain_id="discovery_domain_id", + discovery_domain="discovery_domain", ) ``` @@ -33829,7 +35736,7 @@ client.organizations.discovery_domains.delete(
-**discovery_domain_id:** `str` — ID of the discovery domain. +**discovery_domain:** `str` — Domain name of the discovery domain.
@@ -33849,7 +35756,7 @@ client.organizations.discovery_domains.delete(
-
client.organizations.discovery_domains.update(...) -> UpdateOrganizationDiscoveryDomainResponseContent +
client.organizations.discovery_domains.get(...) -> GetOrganizationDiscoveryDomainResponseContent
@@ -33861,7 +35768,8 @@ client.organizations.discovery_domains.delete(
-Update the verification status and/or use_for_organization_discovery for an organization discovery domain. The `status` field must be either `pending` or `verified`. The `use_for_organization_discovery` field can be `true` or `false` (default: `true`). +Retrieve details about a single organization discovery domain specified by ID. +This endpoint is subject to eventual consistency; newly created, updated, or deleted discovery domains may not immediately appear in the response.
@@ -33884,7 +35792,7 @@ client = Auth0( environment=Auth0Environment.DEFAULT, ) -client.organizations.discovery_domains.update( +client.organizations.discovery_domains.get( id="id", discovery_domain_id="discovery_domain_id", ) @@ -33911,23 +35819,7 @@ client.organizations.discovery_domains.update(
-**discovery_domain_id:** `str` — ID of the discovery domain to update. - -
-
- -
-
- -**status:** `typing.Optional[OrganizationDiscoveryDomainStatus]` - -
-
- -
-
- -**use_for_organization_discovery:** `typing.Optional[bool]` — Indicates whether this domain should be used for organization discovery. +**discovery_domain_id:** `str` — ID of the discovery domain.
@@ -33947,8 +35839,7 @@ client.organizations.discovery_domains.update(
-## Organizations EnabledConnections -
client.organizations.enabled_connections.list(...) -> ListOrganizationConnectionsOffsetPaginatedResponseContent +
client.organizations.discovery_domains.delete(...)
@@ -33960,7 +35851,7 @@ client.organizations.discovery_domains.update(
-Retrieve details about a specific connection currently enabled for an Organization. Information returned includes details such as connection ID, name, strategy, and whether the connection automatically grants membership upon login. +Remove a discovery domain from an organization. This action cannot be undone.
@@ -33983,11 +35874,9 @@ client = Auth0( environment=Auth0Environment.DEFAULT, ) -client.organizations.enabled_connections.list( +client.organizations.discovery_domains.delete( id="id", - page=1, - per_page=1, - include_totals=True, + discovery_domain_id="discovery_domain_id", ) ``` @@ -34004,23 +35893,7 @@ client.organizations.enabled_connections.list(
-**id:** `str` — Organization identifier. - -
-
- -
-
- -**page:** `typing.Optional[int]` — Page index of the results to return. First page is 0. - -
-
- -
-
- -**per_page:** `typing.Optional[int]` — Number of results per page. Defaults to 50. +**id:** `str` — ID of the organization.
@@ -34028,7 +35901,7 @@ client.organizations.enabled_connections.list(
-**include_totals:** `typing.Optional[bool]` — Return results inside an object that contains the total result count (true) or as a direct array of results (false, default). +**discovery_domain_id:** `str` — ID of the discovery domain.
@@ -34048,7 +35921,7 @@ client.organizations.enabled_connections.list(
-
client.organizations.enabled_connections.add(...) -> AddOrganizationConnectionResponseContent +
client.organizations.discovery_domains.update(...) -> UpdateOrganizationDiscoveryDomainResponseContent
@@ -34060,9 +35933,7 @@ client.organizations.enabled_connections.list(
-Enable a specific connection for a given Organization. To enable a connection, it must already exist within your tenant; connections cannot be created through this action. - -[Connections](https://auth0.com/docs/authenticate/identity-providers) represent the relationship between Auth0 and a source of users. Available types of connections include database, enterprise, and social. +Update the verification status and/or use_for_organization_discovery for an organization discovery domain. The `status` field must be either `pending` or `verified`. The `use_for_organization_discovery` field can be `true` or `false` (default: `true`).
@@ -34085,9 +35956,9 @@ client = Auth0( environment=Auth0Environment.DEFAULT, ) -client.organizations.enabled_connections.add( +client.organizations.discovery_domains.update( id="id", - connection_id="connection_id", + discovery_domain_id="discovery_domain_id", ) ``` @@ -34104,15 +35975,7 @@ client.organizations.enabled_connections.add(
-**id:** `str` — Organization identifier. - -
-
- -
-
- -**connection_id:** `str` — Single connection ID to add to the organization. +**id:** `str` — ID of the organization.
@@ -34120,7 +35983,7 @@ client.organizations.enabled_connections.add(
-**assign_membership_on_login:** `typing.Optional[bool]` — When true, all users that log in with this connection will be automatically granted membership in the organization. When false, users must be granted membership in the organization before logging in with this connection. +**discovery_domain_id:** `str` — ID of the discovery domain to update.
@@ -34128,7 +35991,7 @@ client.organizations.enabled_connections.add(
-**is_signup_enabled:** `typing.Optional[bool]` — Determines whether organization signup should be enabled for this organization connection. Only applicable for database connections. Default: false. +**status:** `typing.Optional[OrganizationDiscoveryDomainStatus]`
@@ -34136,7 +35999,7 @@ client.organizations.enabled_connections.add(
-**show_as_button:** `typing.Optional[bool]` — Determines whether a connection should be displayed on this organization’s login prompt. Only applicable for enterprise connections. Default: true. +**use_for_organization_discovery:** `typing.Optional[bool]` — Indicates whether this domain should be used for organization discovery.
@@ -34156,7 +36019,8 @@ client.organizations.enabled_connections.add(
-
client.organizations.enabled_connections.get(...) -> GetOrganizationConnectionResponseContent +## Organizations EnabledConnections +
client.organizations.enabled_connections.list(...) -> ListOrganizationConnectionsOffsetPaginatedResponseContent
@@ -34191,9 +36055,11 @@ client = Auth0( environment=Auth0Environment.DEFAULT, ) -client.organizations.enabled_connections.get( +client.organizations.enabled_connections.list( id="id", - connection_id="connectionId", + page=1, + per_page=1, + include_totals=True, ) ``` @@ -34218,7 +36084,23 @@ client.organizations.enabled_connections.get(
-**connection_id:** `str` — Connection identifier. +**page:** `typing.Optional[int]` — Page index of the results to return. First page is 0. + +
+
+ +
+
+ +**per_page:** `typing.Optional[int]` — Number of results per page. Defaults to 50. + +
+
+ +
+
+ +**include_totals:** `typing.Optional[bool]` — Return results inside an object that contains the total result count (true) or as a direct array of results (false, default).
@@ -34238,7 +36120,7 @@ client.organizations.enabled_connections.get(
-
client.organizations.enabled_connections.delete(...) +
client.organizations.enabled_connections.add(...) -> AddOrganizationConnectionResponseContent
@@ -34250,9 +36132,9 @@ client.organizations.enabled_connections.get(
-Disable a specific connection for an Organization. Once disabled, Organization members can no longer use that connection to authenticate. +Enable a specific connection for a given Organization. To enable a connection, it must already exist within your tenant; connections cannot be created through this action. -**Note**: This action does not remove the connection from your tenant. +[Connections](https://auth0.com/docs/authenticate/identity-providers) represent the relationship between Auth0 and a source of users. Available types of connections include database, enterprise, and social.
@@ -34275,9 +36157,9 @@ client = Auth0( environment=Auth0Environment.DEFAULT, ) -client.organizations.enabled_connections.delete( +client.organizations.enabled_connections.add( id="id", - connection_id="connectionId", + connection_id="connection_id", ) ``` @@ -34302,7 +36184,31 @@ client.organizations.enabled_connections.delete(
-**connection_id:** `str` — Connection identifier. +**connection_id:** `str` — Single connection ID to add to the organization. + +
+
+ +
+
+ +**assign_membership_on_login:** `typing.Optional[bool]` — When true, all users that log in with this connection will be automatically granted membership in the organization. When false, users must be granted membership in the organization before logging in with this connection. + +
+
+ +
+
+ +**is_signup_enabled:** `typing.Optional[bool]` — Determines whether organization signup should be enabled for this organization connection. Only applicable for database connections. Default: false. + +
+
+ +
+
+ +**show_as_button:** `typing.Optional[bool]` — Determines whether a connection should be displayed on this organization’s login prompt. Only applicable for enterprise connections. Default: true.
@@ -34322,7 +36228,7 @@ client.organizations.enabled_connections.delete(
-
client.organizations.enabled_connections.update(...) -> UpdateOrganizationConnectionResponseContent +
client.organizations.enabled_connections.get(...) -> GetOrganizationConnectionResponseContent
@@ -34334,7 +36240,7 @@ client.organizations.enabled_connections.delete(
-Modify the details of a specific connection currently enabled for an Organization. +Retrieve details about a specific connection currently enabled for an Organization. Information returned includes details such as connection ID, name, strategy, and whether the connection automatically grants membership upon login.
@@ -34357,7 +36263,7 @@ client = Auth0( environment=Auth0Environment.DEFAULT, ) -client.organizations.enabled_connections.update( +client.organizations.enabled_connections.get( id="id", connection_id="connectionId", ) @@ -34392,15 +36298,75 @@ client.organizations.enabled_connections.update(
-**assign_membership_on_login:** `typing.Optional[bool]` — When true, all users that log in with this connection will be automatically granted membership in the organization. When false, users must be granted membership in the organization before logging in with this connection. +**request_options:** `typing.Optional[RequestOptions]` — Request-specific configuration.
+ +
+ + + +
+ +
client.organizations.enabled_connections.delete(...)
-**is_signup_enabled:** `typing.Optional[bool]` — Determines whether organization signup should be enabled for this organization connection. Only applicable for database connections. Default: false. +#### 📝 Description + +
+
+ +
+
+ +Disable a specific connection for an Organization. Once disabled, Organization members can no longer use that connection to authenticate. + +**Note**: This action does not remove the connection from your tenant. +
+
+
+
+ +#### 🔌 Usage + +
+
+ +
+
+ +```python +from auth0.management import Auth0 +from auth0.management.environment import Auth0Environment + +client = Auth0( + token="", + environment=Auth0Environment.DEFAULT, +) + +client.organizations.enabled_connections.delete( + id="id", + connection_id="connectionId", +) + +``` +
+
+
+
+ +#### ⚙️ Parameters + +
+
+ +
+
+ +**id:** `str` — Organization identifier.
@@ -34408,7 +36374,7 @@ client.organizations.enabled_connections.update(
-**show_as_button:** `typing.Optional[bool]` — Determines whether a connection should be displayed on this organization’s login prompt. Only applicable for enterprise connections. Default: true. +**connection_id:** `str` — Connection identifier.
@@ -34428,8 +36394,7 @@ client.organizations.enabled_connections.update(
-## Organizations Invitations -
client.organizations.invitations.list(...) -> ListOrganizationInvitationsOffsetPaginatedResponseContent +
client.organizations.enabled_connections.update(...) -> UpdateOrganizationConnectionResponseContent
@@ -34441,7 +36406,7 @@ client.organizations.enabled_connections.update(
-Retrieve a detailed list of invitations sent to users for a specific Organization. The list includes details such as inviter and invitee information, invitation URLs, and dates of creation and expiration. To learn more about Organization invitations, review [Invite Organization Members](https://auth0.com/docs/manage-users/organizations/configure-organizations/invite-members). +Modify the details of a specific connection currently enabled for an Organization.
@@ -34464,14 +36429,9 @@ client = Auth0( environment=Auth0Environment.DEFAULT, ) -client.organizations.invitations.list( +client.organizations.enabled_connections.update( id="id", - page=1, - per_page=1, - include_totals=True, - fields="fields", - include_fields=True, - sort="sort", + connection_id="connectionId", ) ``` @@ -34496,23 +36456,7 @@ client.organizations.invitations.list(
-**page:** `typing.Optional[int]` — Page index of the results to return. First page is 0. - -
-
- -
-
- -**per_page:** `typing.Optional[int]` — Number of results per page. Defaults to 50. - -
-
- -
-
- -**include_totals:** `typing.Optional[bool]` — When true, return results inside an object that also contains the start and limit. When false (default), a direct array of results is returned. We do not yet support returning the total invitations count. +**connection_id:** `str` — Connection identifier.
@@ -34520,7 +36464,7 @@ client.organizations.invitations.list(
-**fields:** `typing.Optional[str]` — Comma-separated list of fields to include or exclude (based on value provided for include_fields) in the result. Leave empty to retrieve all fields. +**assign_membership_on_login:** `typing.Optional[bool]` — When true, all users that log in with this connection will be automatically granted membership in the organization. When false, users must be granted membership in the organization before logging in with this connection.
@@ -34528,7 +36472,7 @@ client.organizations.invitations.list(
-**include_fields:** `typing.Optional[bool]` — Whether specified fields are to be included (true) or excluded (false). Defaults to true. +**is_signup_enabled:** `typing.Optional[bool]` — Determines whether organization signup should be enabled for this organization connection. Only applicable for database connections. Default: false.
@@ -34536,7 +36480,7 @@ client.organizations.invitations.list(
-**sort:** `typing.Optional[str]` — Field to sort by. Use field:order where order is 1 for ascending and -1 for descending Defaults to created_at:-1. +**show_as_button:** `typing.Optional[bool]` — Determines whether a connection should be displayed on this organization’s login prompt. Only applicable for enterprise connections. Default: true.
@@ -34556,7 +36500,8 @@ client.organizations.invitations.list(
-
client.organizations.invitations.create(...) -> CreateOrganizationInvitationResponseContent +## Organizations Invitations +
client.organizations.invitations.list(...) -> ListOrganizationInvitationsOffsetPaginatedResponseContent
@@ -34568,7 +36513,7 @@ client.organizations.invitations.list(
-Create a user invitation for a specific Organization. Upon creation, the listed user receives an email inviting them to join the Organization. To learn more about Organization invitations, review [Invite Organization Members](https://auth0.com/docs/manage-users/organizations/configure-organizations/invite-members). +Retrieve a detailed list of invitations sent to users for a specific Organization. The list includes details such as inviter and invitee information, invitation URLs, and dates of creation and expiration. To learn more about Organization invitations, review [Invite Organization Members](https://auth0.com/docs/manage-users/organizations/configure-organizations/invite-members).
@@ -34583,7 +36528,7 @@ Create a user invitation for a specific Organization. Upon creation, the listed
```python -from auth0.management import Auth0, OrganizationInvitationInviter, OrganizationInvitationInvitee +from auth0.management import Auth0 from auth0.management.environment import Auth0Environment client = Auth0( @@ -34591,15 +36536,14 @@ client = Auth0( environment=Auth0Environment.DEFAULT, ) -client.organizations.invitations.create( +client.organizations.invitations.list( id="id", - inviter=OrganizationInvitationInviter( - name="name", - ), - invitee=OrganizationInvitationInvitee( - email="email", - ), - client_id="client_id", + page=1, + per_page=1, + include_totals=True, + fields="fields", + include_fields=True, + sort="sort", ) ``` @@ -34624,7 +36568,7 @@ client.organizations.invitations.create(
-**inviter:** `OrganizationInvitationInviter` +**page:** `typing.Optional[int]` — Page index of the results to return. First page is 0.
@@ -34632,7 +36576,7 @@ client.organizations.invitations.create(
-**invitee:** `OrganizationInvitationInvitee` +**per_page:** `typing.Optional[int]` — Number of results per page. Defaults to 50.
@@ -34640,7 +36584,7 @@ client.organizations.invitations.create(
-**client_id:** `str` — Auth0 client ID. Used to resolve the application's login initiation endpoint. +**include_totals:** `typing.Optional[bool]` — When true, return results inside an object that also contains the start and limit. When false (default), a direct array of results is returned. We do not yet support returning the total invitations count.
@@ -34648,7 +36592,7 @@ client.organizations.invitations.create(
-**connection_id:** `typing.Optional[str]` — The id of the connection to force invitee to authenticate with. +**fields:** `typing.Optional[str]` — Comma-separated list of fields to include or exclude (based on value provided for include_fields) in the result. Leave empty to retrieve all fields.
@@ -34656,7 +36600,7 @@ client.organizations.invitations.create(
-**app_metadata:** `typing.Optional[AppMetadata]` +**include_fields:** `typing.Optional[bool]` — Whether specified fields are to be included (true) or excluded (false). Defaults to true.
@@ -34664,7 +36608,7 @@ client.organizations.invitations.create(
-**user_metadata:** `typing.Optional[UserMetadata]` +**sort:** `typing.Optional[str]` — Field to sort by. Use field:order where order is 1 for ascending and -1 for descending Defaults to created_at:-1.
@@ -34672,45 +36616,35 @@ client.organizations.invitations.create(
-**ttl_sec:** `typing.Optional[int]` — Number of seconds for which the invitation is valid before expiration. If unspecified or set to 0, this value defaults to 604800 seconds (7 days). Max value: 2592000 seconds (30 days). +**request_options:** `typing.Optional[RequestOptions]` — Request-specific configuration.
+
+
-
-
-**roles:** `typing.Optional[typing.List[str]]` — List of roles IDs to associated with the user. -
+
+
client.organizations.invitations.create(...) -> CreateOrganizationInvitationResponseContent
-**send_invitation_email:** `typing.Optional[bool]` — Whether the user will receive an invitation email (true) or no email (false), true by default - -
-
+#### 📝 Description
-**request_options:** `typing.Optional[RequestOptions]` — Request-specific configuration. - -
-
+
+
+ +Create a user invitation for a specific Organization. Upon creation, the listed user receives an email inviting them to join the Organization. To learn more about Organization invitations, review [Invite Organization Members](https://auth0.com/docs/manage-users/organizations/configure-organizations/invite-members).
- - -
- -
client.organizations.invitations.get(...) -> GetOrganizationInvitationResponseContent -
-
#### 🔌 Usage @@ -34721,7 +36655,7 @@ client.organizations.invitations.create(
```python -from auth0.management import Auth0 +from auth0.management import Auth0, OrganizationInvitationInviter, OrganizationInvitationInvitee from auth0.management.environment import Auth0Environment client = Auth0( @@ -34729,11 +36663,15 @@ client = Auth0( environment=Auth0Environment.DEFAULT, ) -client.organizations.invitations.get( +client.organizations.invitations.create( id="id", - invitation_id="invitation_id", - fields="fields", - include_fields=True, + inviter=OrganizationInvitationInviter( + name="name", + ), + invitee=OrganizationInvitationInvitee( + email="email", + ), + client_id="client_id", ) ``` @@ -34758,7 +36696,7 @@ client.organizations.invitations.get(
-**invitation_id:** `str` — The id of the user invitation. +**inviter:** `OrganizationInvitationInviter`
@@ -34766,7 +36704,7 @@ client.organizations.invitations.get(
-**fields:** `typing.Optional[str]` — Comma-separated list of fields to include or exclude (based on value provided for include_fields) in the result. Leave empty to retrieve all fields. +**invitee:** `OrganizationInvitationInvitee`
@@ -34774,7 +36712,7 @@ client.organizations.invitations.get(
-**include_fields:** `typing.Optional[bool]` — Whether specified fields are to be included (true) or excluded (false). Defaults to true. +**client_id:** `str` — Auth0 client ID. Used to resolve the application's login initiation endpoint.
@@ -34782,59 +36720,39 @@ client.organizations.invitations.get(
-**request_options:** `typing.Optional[RequestOptions]` — Request-specific configuration. +**connection_id:** `typing.Optional[str]` — The id of the connection to force invitee to authenticate with.
-
-
+
+
+**app_metadata:** `typing.Optional[AppMetadata]` +
-
-
client.organizations.invitations.delete(...)
-#### 🔌 Usage - -
-
+**user_metadata:** `typing.Optional[UserMetadata]` + +
+
-```python -from auth0.management import Auth0 -from auth0.management.environment import Auth0Environment - -client = Auth0( - token="", - environment=Auth0Environment.DEFAULT, -) - -client.organizations.invitations.delete( - id="id", - invitation_id="invitation_id", -) - -``` -
-
+**ttl_sec:** `typing.Optional[int]` — Number of seconds for which the invitation is valid before expiration. If unspecified or set to 0, this value defaults to 604800 seconds (7 days). Max value: 2592000 seconds (30 days). +
-#### ⚙️ Parameters -
-
-
- -**id:** `str` — Organization identifier. +**roles:** `typing.Optional[typing.List[str]]` — List of roles IDs to associated with the user.
@@ -34842,7 +36760,7 @@ client.organizations.invitations.delete(
-**invitation_id:** `str` — The id of the user invitation. +**send_invitation_email:** `typing.Optional[bool]` — Whether the user will receive an invitation email (true) or no email (false), true by default
@@ -34862,40 +36780,10 @@ client.organizations.invitations.delete(
-## Organizations Members -
client.organizations.members.list(...) -> ListOrganizationMembersPaginatedResponseContent -
-
- -#### 📝 Description - -
-
- +
client.organizations.invitations.get(...) -> GetOrganizationInvitationResponseContent
-List organization members. -This endpoint is subject to eventual consistency. New users may not be immediately included in the response and deleted users may not be immediately removed from it. - -- Use the `fields` parameter to optionally define the specific member details retrieved. If `fields` is left blank, all fields (except roles) are returned. -- Member roles are not sent by default. Use `fields=roles` to retrieve the roles assigned to each listed member. To use this parameter, you must include the `read:organization_member_roles` scope in the token. Only directly assigned roles are returned. To also include group-based role assignments, use `GET /api/v2/organizations/{id}/members/{user_id}/effective-roles`. - -This endpoint supports two types of pagination: - -- Offset pagination -- Checkpoint pagination - -Checkpoint pagination must be used if you need to retrieve more than 1000 organization members. - -**Checkpoint Pagination** - -To search by checkpoint, use the following parameters: - from: Optional id from which to start selection. - take: The total amount of entries to retrieve when using the from parameter. Defaults to 50. Note: The first time you call this endpoint using Checkpoint Pagination, you should omit the `from` parameter. If there are more results, a `next` value will be included in the response. You can use this for subsequent API calls. When `next` is no longer included in the response, this indicates there are no more pages remaining. -
-
-
-
- #### 🔌 Usage
@@ -34913,11 +36801,9 @@ client = Auth0( environment=Auth0Environment.DEFAULT, ) -client.organizations.members.list( +client.organizations.invitations.get( id="id", - include_totals=True, - from_="from", - take=1, + invitation_id="invitation_id", fields="fields", include_fields=True, ) @@ -34944,23 +36830,7 @@ client.organizations.members.list(
-**include_totals:** `typing.Optional[bool]` — Return results inside an object that contains the total result count (true) or as a direct array of results (false, default). - -
-
- -
-
- -**from:** `typing.Optional[str]` — Optional Id from which to start selection. - -
-
- -
-
- -**take:** `typing.Optional[int]` — Number of results per page. Defaults to 50. +**invitation_id:** `str` — The id of the user invitation.
@@ -34976,7 +36846,7 @@ client.organizations.members.list(
-**include_fields:** `typing.Optional[bool]` — Whether specified fields are to be included (true) or excluded (false). +**include_fields:** `typing.Optional[bool]` — Whether specified fields are to be included (true) or excluded (false). Defaults to true.
@@ -34996,26 +36866,10 @@ client.organizations.members.list(
-
client.organizations.members.create(...) -
-
- -#### 📝 Description - -
-
- +
client.organizations.invitations.delete(...)
-Set one or more existing users as members of a specific [Organization](https://auth0.com/docs/manage-users/organizations). - -To add a user to an Organization through this action, the user must already exist in your tenant. If a user does not yet exist, you can [invite them to create an account](https://auth0.com/docs/manage-users/organizations/configure-organizations/invite-members), manually create them through the Auth0 Dashboard, or use the Management API. -
-
-
-
- #### 🔌 Usage
@@ -35033,11 +36887,9 @@ client = Auth0( environment=Auth0Environment.DEFAULT, ) -client.organizations.members.create( +client.organizations.invitations.delete( id="id", - members=[ - "members" - ], + invitation_id="invitation_id", ) ``` @@ -35062,7 +36914,7 @@ client.organizations.members.create(
-**members:** `typing.List[str]` — List of user IDs to add to the organization as members. +**invitation_id:** `str` — The id of the user invitation.
@@ -35082,10 +36934,40 @@ client.organizations.members.create(
-
client.organizations.members.delete(...) +## Organizations Members +
client.organizations.members.list(...) -> ListOrganizationMembersPaginatedResponseContent +
+
+ +#### 📝 Description + +
+
+
+List organization members. +This endpoint is subject to eventual consistency. New users may not be immediately included in the response and deleted users may not be immediately removed from it. + +- Use the `fields` parameter to optionally define the specific member details retrieved. If `fields` is left blank, all fields (except roles) are returned. +- Member roles are not sent by default. Use `fields=roles` to retrieve the roles assigned to each listed member. To use this parameter, you must include the `read:organization_member_roles` scope in the token. Only directly assigned roles are returned. To also include group-based role assignments, use `GET /api/v2/organizations/{id}/members/{user_id}/effective-roles`. + +This endpoint supports two types of pagination: + +- Offset pagination +- Checkpoint pagination + +Checkpoint pagination must be used if you need to retrieve more than 1000 organization members. + +**Checkpoint Pagination** + +To search by checkpoint, use the following parameters: - from: Optional id from which to start selection. - take: The total amount of entries to retrieve when using the from parameter. Defaults to 50. Note: The first time you call this endpoint using Checkpoint Pagination, you should omit the `from` parameter. If there are more results, a `next` value will be included in the response. You can use this for subsequent API calls. When `next` is no longer included in the response, this indicates there are no more pages remaining. +
+
+
+
+ #### 🔌 Usage
@@ -35103,11 +36985,13 @@ client = Auth0( environment=Auth0Environment.DEFAULT, ) -client.organizations.members.delete( +client.organizations.members.list( id="id", - members=[ - "members" - ], + include_totals=True, + from_="from", + take=1, + fields="fields", + include_fields=True, ) ``` @@ -35132,7 +37016,7 @@ client.organizations.members.delete(
-**members:** `typing.List[str]` — List of user IDs to remove from the organization. +**include_totals:** `typing.Optional[bool]` — Return results inside an object that contains the total result count (true) or as a direct array of results (false, default).
@@ -35140,73 +37024,31 @@ client.organizations.members.delete(
-**request_options:** `typing.Optional[RequestOptions]` — Request-specific configuration. +**from:** `typing.Optional[str]` — Optional Id from which to start selection.
-
-
- - - - -
- -## Organizations OrganizationTemplate -
client.organizations.organization_template.get(...) -> OrganizationTemplate -
-
- -#### 📝 Description - -
-
-Retrieve the organization template assigned to a specific organization. Returns the template object if one is explicitly assigned, or a 404 if no template is assigned. -
-
+**take:** `typing.Optional[int]` — Number of results per page. Defaults to 50. +
-#### 🔌 Usage -
-
-
- -```python -from auth0.management import Auth0 -from auth0.management.environment import Auth0Environment - -client = Auth0( - token="", - environment=Auth0Environment.DEFAULT, -) - -client.organizations.organization_template.get( - id="id", -) - -``` -
-
+**fields:** `typing.Optional[str]` — Comma-separated list of fields to include or exclude (based on value provided for include_fields) in the result. Leave empty to retrieve all fields. +
-#### ⚙️ Parameters - -
-
-
-**id:** `str` — ID of the organization. +**include_fields:** `typing.Optional[bool]` — Whether specified fields are to be included (true) or excluded (false).
@@ -35226,7 +37068,7 @@ client.organizations.organization_template.get(
-
client.organizations.organization_template.assign_organization_template(...) +
client.organizations.members.create(...)
@@ -35238,7 +37080,9 @@ client.organizations.organization_template.get(
-Assign an Organization Template to an organization. +Set one or more existing users as members of a specific [Organization](https://auth0.com/docs/manage-users/organizations). + +To add a user to an Organization through this action, the user must already exist in your tenant. If a user does not yet exist, you can [invite them to create an account](https://auth0.com/docs/manage-users/organizations/configure-organizations/invite-members), manually create them through the Auth0 Dashboard, or use the Management API.
@@ -35261,9 +37105,11 @@ client = Auth0( environment=Auth0Environment.DEFAULT, ) -client.organizations.organization_template.assign_organization_template( +client.organizations.members.create( id="id", - template_id="template_id", + members=[ + "members" + ], ) ``` @@ -35280,7 +37126,7 @@ client.organizations.organization_template.assign_organization_template(
-**id:** `str` — The ID of the organization. +**id:** `str` — Organization identifier.
@@ -35288,7 +37134,7 @@ client.organizations.organization_template.assign_organization_template(
-**template_id:** `str` — The ID of the organization template to assign. +**members:** `typing.List[str]` — List of user IDs to add to the organization as members.
@@ -35308,24 +37154,10 @@ client.organizations.organization_template.assign_organization_template(
-
client.organizations.organization_template.unassign_organization_template(...) -
-
- -#### 📝 Description - -
-
- +
client.organizations.members.delete(...)
-Remove an Organization Template assignment from an organization. -
-
-
-
- #### 🔌 Usage
@@ -35343,9 +37175,11 @@ client = Auth0( environment=Auth0Environment.DEFAULT, ) -client.organizations.organization_template.unassign_organization_template( +client.organizations.members.delete( id="id", - template_id="template_id", + members=[ + "members" + ], ) ``` @@ -35362,7 +37196,7 @@ client.organizations.organization_template.unassign_organization_template(
-**id:** `str` — The ID of the organization. +**id:** `str` — Organization identifier.
@@ -35370,7 +37204,7 @@ client.organizations.organization_template.unassign_organization_template(
-**template_id:** `str` — The ID of the organization template to unassign. +**members:** `typing.List[str]` — List of user IDs to remove from the organization.
diff --git a/src/auth0/management/__init__.py b/src/auth0/management/__init__.py index 6d53c2e2..f12b793f 100644 --- a/src/auth0/management/__init__.py +++ b/src/auth0/management/__init__.py @@ -63,6 +63,9 @@ AdvanceRampResponseContent, AgentMetadata, AgentResponseContent, + AllocationItem, + AllocationRequestItem, + AllocationStrategyEnum, AnomalyIpFormat, AnonymousSessions, AppMetadata, @@ -83,6 +86,7 @@ AttackProtectionUpdateCaptchaHcaptcha, AttackProtectionUpdateCaptchaRecaptchaEnterprise, AttackProtectionUpdateCaptchaRecaptchaV2, + AuthenticationFlowEnum, AuthenticationMethodTypeEnum, AuthenticationTypeEnum, B2BIntegrationConfiguration, @@ -230,6 +234,8 @@ ClientOidcBackchannelLogoutInitiatorsModeEnum, ClientOidcBackchannelLogoutSessionMetadata, ClientOidcBackchannelLogoutSettings, + ClientOidcSupportAllowedScopesEnum, + ClientOidcSupportPost, ClientOrganizationDiscoveryEnum, ClientOrganizationRequireBehaviorEnum, ClientOrganizationRequireBehaviorPatchEnum, @@ -343,7 +349,6 @@ ConnectionDebugSaml, ConnectionDecryptionKeySaml, ConnectionDecryptionKeySamlCert, - ConnectionDeletionBehaviorEnum, ConnectionDestinationUrlSaml, ConnectionDigestAlgorithmEnumSaml, ConnectionDigestAlgorithmSaml, @@ -754,6 +759,9 @@ ConnectionThumbprints, ConnectionThumbprintsAd, ConnectionThumbprintsSaml, + ConnectionThumbprintsSha384, + ConnectionThumbprintsSha384Ad, + ConnectionThumbprintsSha384Saml, ConnectionTokenEndpoint, ConnectionTokenEndpointAuthMethodEnum, ConnectionTokenEndpointAuthMethodsSupported, @@ -936,8 +944,11 @@ CreateEventStreamResponseContent, CreateEventStreamTestEventResponseContent, CreateEventStreamWebHookRequestContent, + CreateExperimentResponseContent, CreateExportUsersFields, CreateExportUsersResponseContent, + CreateFeatureFlagParameters, + CreateFeatureFlagResponseContent, CreateFlowResponseContent, CreateFlowsVaultConnectionActivecampaign, CreateFlowsVaultConnectionActivecampaignApiKey, @@ -1046,6 +1057,7 @@ CreateScimConfigurationRequestContent, CreateScimConfigurationResponseContent, CreateScimTokenResponseContent, + CreateSegmentResponseContent, CreateSelfServiceProfileResponseContent, CreateSelfServiceProfileSsoTicketResponseContent, CreateTokenExchangeProfileResponseContent, @@ -1053,6 +1065,7 @@ CreateUserAttributeProfileResponseContent, CreateUserAuthenticationMethodResponseContent, CreateUserResponseContent, + CreateVariationResponseContent, CreateVerifiableCredentialTemplateResponseContent, CreateVerificationEmailResponseContent, CreatedAuthenticationMethodTypeEnum, @@ -1092,6 +1105,7 @@ CustomSigningKeyTypeEnum, CustomSigningKeyUseEnum, DailyStats, + DefaultConfigEnum, DefaultMethodEmailIdentifierEnum, DefaultMethodPhoneNumberIdentifierEnum, DefaultTokenQuota, @@ -2483,9 +2497,19 @@ EventStreamWebhookDestination, EventStreamWebhookDestinationTypeEnum, EventStreamWebhookResponseContent, + ExperimentListItem, + ExperimentStatusEnum, + ExperimentTransitionStatusEnum, + ExperimentValidationError, ExpressConfiguration, ExpressConfigurationOrNull, ExtensibilityEmailProviderCredentials, + FeatureFlag, + FeatureFlagConfigParam, + FeatureFlagConfigParamTypeEnum, + FeatureFlagConfigParams, + FeatureFlagStatusEnum, + FeatureFlagTypeEnum, FedCmLogin, FedCmLoginGoogle, FedCmLoginGooglePatch, @@ -3088,6 +3112,8 @@ GetEncryptionKeyResponseContent, GetEventStreamDeliveryHistoryResponseContent, GetEventStreamResponseContent, + GetExperimentResponseContent, + GetFeatureFlagResponseContent, GetFlowExecutionRequestParametersHydrateEnum, GetFlowExecutionResponseContent, GetFlowRequestParametersHydrateEnum, @@ -3143,6 +3169,7 @@ GetScimConfigurationDefaultMappingResponseContent, GetScimConfigurationResponseContent, GetScimTokensResponseContent, + GetSegmentResponseContent, GetSelfServiceProfileResponseContent, GetSessionResponseContent, GetSettingsResponseContent, @@ -3158,6 +3185,7 @@ GetUserAuthenticationMethodResponseContent, GetUserGroupsPaginatedResponseContent, GetUserResponseContent, + GetVariationResponseContent, GetVerifiableCredentialTemplateResponseContent, Group, GroupMember, @@ -3211,6 +3239,8 @@ ListEncryptionKeyOffsetPaginatedResponseContent, ListEventStreamDeliveriesResponseContent, ListEventStreamsResponseContent, + ListExperimentsResponseContent, + ListFeatureFlagsResponseContent, ListFlowExecutionsPaginatedResponseContent, ListFlowsOffsetPaginatedResponseContent, ListFlowsRequestParametersHydrateEnum, @@ -3247,6 +3277,7 @@ ListRolesOffsetPaginatedResponseContent, ListRulesOffsetPaginatedResponseContent, ListScimConfigurationsResponseContent, + ListSegmentsResponseContent, ListSelfServiceProfileCustomTextResponseContent, ListSelfServiceProfilesPaginatedResponseContent, ListSynchronizedGroupsResponseContent, @@ -3267,6 +3298,7 @@ ListUserRolesOffsetPaginatedResponseContent, ListUserSessionsPaginatedResponseContent, ListUsersOffsetPaginatedResponseContent, + ListVariationsResponseContent, ListVerifiableCredentialTemplatesPaginatedResponseContent, Log, LogDate, @@ -3364,7 +3396,6 @@ OrganizationClientMetadataOrganizationUsageEnum, OrganizationConnection, OrganizationConnectionInformation, - OrganizationDeletionBehaviorEnum, OrganizationDiscoveryDomain, OrganizationDiscoveryDomainStatus, OrganizationEnabledConnection, @@ -3379,12 +3410,6 @@ OrganizationMemberRole, OrganizationMetadata, OrganizationSortFieldEnum, - OrganizationTemplate, - OrganizationTemplateAllowedStrategyEnum, - OrganizationTemplateRoleVisibilityEnum, - OrganizationTemplateRoleVisibilityOverride, - OrganizationTemplateRoleVisibilityPolicy, - OrganizationTemplateUseForOrganizationDiscovery, OrganizationThirdPartyClientAccessEnum, OrganizationUsageEnum, PartialGroupsEnum, @@ -3505,6 +3530,17 @@ SearchOrganizationsPaginatedResponseContent, SearchParserEnum, SearchResourceServersResponseContent, + Segment, + SegmentContainsExpression, + SegmentEndsWithExpression, + SegmentExistsExpression, + SegmentMatchConditions, + SegmentMatchExpression, + SegmentNotMatchConditions, + SegmentRule, + SegmentStartsWithExpression, + SegmentTypeEnum, + SegmentTypeFilterEnum, SelfServiceProfile, SelfServiceProfileAllowedStrategyEnum, SelfServiceProfileBranding, @@ -3716,6 +3752,11 @@ UpdateEnabledClientConnectionsRequestContent, UpdateEnabledClientConnectionsRequestContentItem, UpdateEventStreamResponseContent, + UpdateExperimentResponseContent, + UpdateExperimentStatusResponseContent, + UpdateFeatureFlagParameters, + UpdateFeatureFlagResponseContent, + UpdateFeatureFlagStatusResponseContent, UpdateFlowResponseContent, UpdateFlowsVaultConnectionResponseContent, UpdateFlowsVaultConnectionSetup, @@ -3744,6 +3785,7 @@ UpdateRoleResponseContent, UpdateRuleResponseContent, UpdateScimConfigurationResponseContent, + UpdateSegmentResponseContent, UpdateSelfServiceProfileResponseContent, UpdateSessionResponseContent, UpdateSettingsResponseContent, @@ -3755,6 +3797,8 @@ UpdateUserAttributeProfileResponseContent, UpdateUserAuthenticationMethodResponseContent, UpdateUserResponseContent, + UpdateVariationOverridesMap, + UpdateVariationResponseContent, UpdateVerifiableCredentialTemplateResponseContent, UserAppMetadataSchema, UserAttributeProfile, @@ -3805,6 +3849,9 @@ UsernameAttributeIdentifier, UsernameValidation, UsersEnrollment, + ValidateExperimentResponseContent, + Variation, + VariationOverridesMap, VerifiableCredentialTemplateResponse, VerificationMethodEnum, VerifyCustomDomainResponseContent, @@ -3943,6 +3990,9 @@ "AdvanceRampResponseContent": ".types", "AgentMetadata": ".types", "AgentResponseContent": ".types", + "AllocationItem": ".types", + "AllocationRequestItem": ".types", + "AllocationStrategyEnum": ".types", "AnomalyIpFormat": ".types", "AnonymousSessions": ".types", "AppMetadata": ".types", @@ -3968,6 +4018,7 @@ "AttackProtectionUpdateCaptchaRecaptchaV2": ".types", "Auth0": ".client", "Auth0Environment": ".environment", + "AuthenticationFlowEnum": ".types", "AuthenticationMethodTypeEnum": ".types", "AuthenticationTypeEnum": ".types", "B2BIntegrationConfiguration": ".types", @@ -4116,6 +4167,8 @@ "ClientOidcBackchannelLogoutInitiatorsModeEnum": ".types", "ClientOidcBackchannelLogoutSessionMetadata": ".types", "ClientOidcBackchannelLogoutSettings": ".types", + "ClientOidcSupportAllowedScopesEnum": ".types", + "ClientOidcSupportPost": ".types", "ClientOrganizationDiscoveryEnum": ".types", "ClientOrganizationRequireBehaviorEnum": ".types", "ClientOrganizationRequireBehaviorPatchEnum": ".types", @@ -4230,7 +4283,6 @@ "ConnectionDebugSaml": ".types", "ConnectionDecryptionKeySaml": ".types", "ConnectionDecryptionKeySamlCert": ".types", - "ConnectionDeletionBehaviorEnum": ".types", "ConnectionDestinationUrlSaml": ".types", "ConnectionDigestAlgorithmEnumSaml": ".types", "ConnectionDigestAlgorithmSaml": ".types", @@ -4641,6 +4693,9 @@ "ConnectionThumbprints": ".types", "ConnectionThumbprintsAd": ".types", "ConnectionThumbprintsSaml": ".types", + "ConnectionThumbprintsSha384": ".types", + "ConnectionThumbprintsSha384Ad": ".types", + "ConnectionThumbprintsSha384Saml": ".types", "ConnectionTokenEndpoint": ".types", "ConnectionTokenEndpointAuthMethodEnum": ".types", "ConnectionTokenEndpointAuthMethodsSupported": ".types", @@ -4824,8 +4879,11 @@ "CreateEventStreamResponseContent": ".types", "CreateEventStreamTestEventResponseContent": ".types", "CreateEventStreamWebHookRequestContent": ".types", + "CreateExperimentResponseContent": ".types", "CreateExportUsersFields": ".types", "CreateExportUsersResponseContent": ".types", + "CreateFeatureFlagParameters": ".types", + "CreateFeatureFlagResponseContent": ".types", "CreateFlowResponseContent": ".types", "CreateFlowsVaultConnectionActivecampaign": ".types", "CreateFlowsVaultConnectionActivecampaignApiKey": ".types", @@ -4934,6 +4992,7 @@ "CreateScimConfigurationRequestContent": ".types", "CreateScimConfigurationResponseContent": ".types", "CreateScimTokenResponseContent": ".types", + "CreateSegmentResponseContent": ".types", "CreateSelfServiceProfileResponseContent": ".types", "CreateSelfServiceProfileSsoTicketResponseContent": ".types", "CreateTokenExchangeProfileResponseContent": ".types", @@ -4941,6 +5000,7 @@ "CreateUserAttributeProfileResponseContent": ".types", "CreateUserAuthenticationMethodResponseContent": ".types", "CreateUserResponseContent": ".types", + "CreateVariationResponseContent": ".types", "CreateVerifiableCredentialTemplateResponseContent": ".types", "CreateVerificationEmailResponseContent": ".types", "CreatedAuthenticationMethodTypeEnum": ".types", @@ -4983,6 +5043,7 @@ "DailyStats": ".types", "DefaultAioHttpClient": "._default_clients", "DefaultAsyncHttpxClient": "._default_clients", + "DefaultConfigEnum": ".types", "DefaultMethodEmailIdentifierEnum": ".types", "DefaultMethodPhoneNumberIdentifierEnum": ".types", "DefaultTokenQuota": ".types", @@ -6375,9 +6436,19 @@ "EventStreamWebhookDestinationTypeEnum": ".types", "EventStreamWebhookResponseContent": ".types", "EventStreamsCreateRequest": ".event_streams", + "ExperimentListItem": ".types", + "ExperimentStatusEnum": ".types", + "ExperimentTransitionStatusEnum": ".types", + "ExperimentValidationError": ".types", "ExpressConfiguration": ".types", "ExpressConfigurationOrNull": ".types", "ExtensibilityEmailProviderCredentials": ".types", + "FeatureFlag": ".types", + "FeatureFlagConfigParam": ".types", + "FeatureFlagConfigParamTypeEnum": ".types", + "FeatureFlagConfigParams": ".types", + "FeatureFlagStatusEnum": ".types", + "FeatureFlagTypeEnum": ".types", "FedCmLogin": ".types", "FedCmLoginGoogle": ".types", "FedCmLoginGooglePatch": ".types", @@ -6982,6 +7053,8 @@ "GetEncryptionKeyResponseContent": ".types", "GetEventStreamDeliveryHistoryResponseContent": ".types", "GetEventStreamResponseContent": ".types", + "GetExperimentResponseContent": ".types", + "GetFeatureFlagResponseContent": ".types", "GetFlowExecutionRequestParametersHydrateEnum": ".types", "GetFlowExecutionResponseContent": ".types", "GetFlowRequestParametersHydrateEnum": ".types", @@ -7037,6 +7110,7 @@ "GetScimConfigurationDefaultMappingResponseContent": ".types", "GetScimConfigurationResponseContent": ".types", "GetScimTokensResponseContent": ".types", + "GetSegmentResponseContent": ".types", "GetSelfServiceProfileResponseContent": ".types", "GetSessionResponseContent": ".types", "GetSettingsResponseContent": ".types", @@ -7052,6 +7126,7 @@ "GetUserAuthenticationMethodResponseContent": ".types", "GetUserGroupsPaginatedResponseContent": ".types", "GetUserResponseContent": ".types", + "GetVariationResponseContent": ".types", "GetVerifiableCredentialTemplateResponseContent": ".types", "GoneError": ".errors", "Group": ".types", @@ -7107,6 +7182,8 @@ "ListEncryptionKeyOffsetPaginatedResponseContent": ".types", "ListEventStreamDeliveriesResponseContent": ".types", "ListEventStreamsResponseContent": ".types", + "ListExperimentsResponseContent": ".types", + "ListFeatureFlagsResponseContent": ".types", "ListFlowExecutionsPaginatedResponseContent": ".types", "ListFlowsOffsetPaginatedResponseContent": ".types", "ListFlowsRequestParametersHydrateEnum": ".types", @@ -7143,6 +7220,7 @@ "ListRolesOffsetPaginatedResponseContent": ".types", "ListRulesOffsetPaginatedResponseContent": ".types", "ListScimConfigurationsResponseContent": ".types", + "ListSegmentsResponseContent": ".types", "ListSelfServiceProfileCustomTextResponseContent": ".types", "ListSelfServiceProfilesPaginatedResponseContent": ".types", "ListSynchronizedGroupsResponseContent": ".types", @@ -7163,6 +7241,7 @@ "ListUserRolesOffsetPaginatedResponseContent": ".types", "ListUserSessionsPaginatedResponseContent": ".types", "ListUsersOffsetPaginatedResponseContent": ".types", + "ListVariationsResponseContent": ".types", "ListVerifiableCredentialTemplatesPaginatedResponseContent": ".types", "Log": ".types", "LogDate": ".types", @@ -7262,7 +7341,6 @@ "OrganizationClientMetadataOrganizationUsageEnum": ".types", "OrganizationConnection": ".types", "OrganizationConnectionInformation": ".types", - "OrganizationDeletionBehaviorEnum": ".types", "OrganizationDiscoveryDomain": ".types", "OrganizationDiscoveryDomainStatus": ".types", "OrganizationEnabledConnection": ".types", @@ -7277,12 +7355,6 @@ "OrganizationMemberRole": ".types", "OrganizationMetadata": ".types", "OrganizationSortFieldEnum": ".types", - "OrganizationTemplate": ".types", - "OrganizationTemplateAllowedStrategyEnum": ".types", - "OrganizationTemplateRoleVisibilityEnum": ".types", - "OrganizationTemplateRoleVisibilityOverride": ".types", - "OrganizationTemplateRoleVisibilityPolicy": ".types", - "OrganizationTemplateUseForOrganizationDiscovery": ".types", "OrganizationThirdPartyClientAccessEnum": ".types", "OrganizationUsageEnum": ".types", "PartialGroupsEnum": ".types", @@ -7405,6 +7477,17 @@ "SearchOrganizationsPaginatedResponseContent": ".types", "SearchParserEnum": ".types", "SearchResourceServersResponseContent": ".types", + "Segment": ".types", + "SegmentContainsExpression": ".types", + "SegmentEndsWithExpression": ".types", + "SegmentExistsExpression": ".types", + "SegmentMatchConditions": ".types", + "SegmentMatchExpression": ".types", + "SegmentNotMatchConditions": ".types", + "SegmentRule": ".types", + "SegmentStartsWithExpression": ".types", + "SegmentTypeEnum": ".types", + "SegmentTypeFilterEnum": ".types", "SelfServiceProfile": ".types", "SelfServiceProfileAllowedStrategyEnum": ".types", "SelfServiceProfileBranding": ".types", @@ -7621,6 +7704,11 @@ "UpdateEnabledClientConnectionsRequestContent": ".types", "UpdateEnabledClientConnectionsRequestContentItem": ".types", "UpdateEventStreamResponseContent": ".types", + "UpdateExperimentResponseContent": ".types", + "UpdateExperimentStatusResponseContent": ".types", + "UpdateFeatureFlagParameters": ".types", + "UpdateFeatureFlagResponseContent": ".types", + "UpdateFeatureFlagStatusResponseContent": ".types", "UpdateFlowResponseContent": ".types", "UpdateFlowsVaultConnectionResponseContent": ".types", "UpdateFlowsVaultConnectionSetup": ".types", @@ -7649,6 +7737,7 @@ "UpdateRoleResponseContent": ".types", "UpdateRuleResponseContent": ".types", "UpdateScimConfigurationResponseContent": ".types", + "UpdateSegmentResponseContent": ".types", "UpdateSelfServiceProfileResponseContent": ".types", "UpdateSessionResponseContent": ".types", "UpdateSettingsResponseContent": ".types", @@ -7660,6 +7749,8 @@ "UpdateUserAttributeProfileResponseContent": ".types", "UpdateUserAuthenticationMethodResponseContent": ".types", "UpdateUserResponseContent": ".types", + "UpdateVariationOverridesMap": ".types", + "UpdateVariationResponseContent": ".types", "UpdateVerifiableCredentialTemplateResponseContent": ".types", "UserAppMetadataSchema": ".types", "UserAttributeProfile": ".types", @@ -7710,6 +7801,9 @@ "UsernameAttributeIdentifier": ".types", "UsernameValidation": ".types", "UsersEnrollment": ".types", + "ValidateExperimentResponseContent": ".types", + "Variation": ".types", + "VariationOverridesMap": ".types", "VerifiableCredentialTemplateResponse": ".types", "VerificationMethodEnum": ".types", "VerifyCustomDomainResponseContent": ".types", @@ -7847,6 +7941,9 @@ def __dir__(): "AdvanceRampResponseContent", "AgentMetadata", "AgentResponseContent", + "AllocationItem", + "AllocationRequestItem", + "AllocationStrategyEnum", "AnomalyIpFormat", "AnonymousSessions", "AppMetadata", @@ -7872,6 +7969,7 @@ def __dir__(): "AttackProtectionUpdateCaptchaRecaptchaV2", "Auth0", "Auth0Environment", + "AuthenticationFlowEnum", "AuthenticationMethodTypeEnum", "AuthenticationTypeEnum", "B2BIntegrationConfiguration", @@ -8020,6 +8118,8 @@ def __dir__(): "ClientOidcBackchannelLogoutInitiatorsModeEnum", "ClientOidcBackchannelLogoutSessionMetadata", "ClientOidcBackchannelLogoutSettings", + "ClientOidcSupportAllowedScopesEnum", + "ClientOidcSupportPost", "ClientOrganizationDiscoveryEnum", "ClientOrganizationRequireBehaviorEnum", "ClientOrganizationRequireBehaviorPatchEnum", @@ -8134,7 +8234,6 @@ def __dir__(): "ConnectionDebugSaml", "ConnectionDecryptionKeySaml", "ConnectionDecryptionKeySamlCert", - "ConnectionDeletionBehaviorEnum", "ConnectionDestinationUrlSaml", "ConnectionDigestAlgorithmEnumSaml", "ConnectionDigestAlgorithmSaml", @@ -8545,6 +8644,9 @@ def __dir__(): "ConnectionThumbprints", "ConnectionThumbprintsAd", "ConnectionThumbprintsSaml", + "ConnectionThumbprintsSha384", + "ConnectionThumbprintsSha384Ad", + "ConnectionThumbprintsSha384Saml", "ConnectionTokenEndpoint", "ConnectionTokenEndpointAuthMethodEnum", "ConnectionTokenEndpointAuthMethodsSupported", @@ -8728,8 +8830,11 @@ def __dir__(): "CreateEventStreamResponseContent", "CreateEventStreamTestEventResponseContent", "CreateEventStreamWebHookRequestContent", + "CreateExperimentResponseContent", "CreateExportUsersFields", "CreateExportUsersResponseContent", + "CreateFeatureFlagParameters", + "CreateFeatureFlagResponseContent", "CreateFlowResponseContent", "CreateFlowsVaultConnectionActivecampaign", "CreateFlowsVaultConnectionActivecampaignApiKey", @@ -8838,6 +8943,7 @@ def __dir__(): "CreateScimConfigurationRequestContent", "CreateScimConfigurationResponseContent", "CreateScimTokenResponseContent", + "CreateSegmentResponseContent", "CreateSelfServiceProfileResponseContent", "CreateSelfServiceProfileSsoTicketResponseContent", "CreateTokenExchangeProfileResponseContent", @@ -8845,6 +8951,7 @@ def __dir__(): "CreateUserAttributeProfileResponseContent", "CreateUserAuthenticationMethodResponseContent", "CreateUserResponseContent", + "CreateVariationResponseContent", "CreateVerifiableCredentialTemplateResponseContent", "CreateVerificationEmailResponseContent", "CreatedAuthenticationMethodTypeEnum", @@ -8887,6 +8994,7 @@ def __dir__(): "DailyStats", "DefaultAioHttpClient", "DefaultAsyncHttpxClient", + "DefaultConfigEnum", "DefaultMethodEmailIdentifierEnum", "DefaultMethodPhoneNumberIdentifierEnum", "DefaultTokenQuota", @@ -10279,9 +10387,19 @@ def __dir__(): "EventStreamWebhookDestinationTypeEnum", "EventStreamWebhookResponseContent", "EventStreamsCreateRequest", + "ExperimentListItem", + "ExperimentStatusEnum", + "ExperimentTransitionStatusEnum", + "ExperimentValidationError", "ExpressConfiguration", "ExpressConfigurationOrNull", "ExtensibilityEmailProviderCredentials", + "FeatureFlag", + "FeatureFlagConfigParam", + "FeatureFlagConfigParamTypeEnum", + "FeatureFlagConfigParams", + "FeatureFlagStatusEnum", + "FeatureFlagTypeEnum", "FedCmLogin", "FedCmLoginGoogle", "FedCmLoginGooglePatch", @@ -10886,6 +11004,8 @@ def __dir__(): "GetEncryptionKeyResponseContent", "GetEventStreamDeliveryHistoryResponseContent", "GetEventStreamResponseContent", + "GetExperimentResponseContent", + "GetFeatureFlagResponseContent", "GetFlowExecutionRequestParametersHydrateEnum", "GetFlowExecutionResponseContent", "GetFlowRequestParametersHydrateEnum", @@ -10941,6 +11061,7 @@ def __dir__(): "GetScimConfigurationDefaultMappingResponseContent", "GetScimConfigurationResponseContent", "GetScimTokensResponseContent", + "GetSegmentResponseContent", "GetSelfServiceProfileResponseContent", "GetSessionResponseContent", "GetSettingsResponseContent", @@ -10956,6 +11077,7 @@ def __dir__(): "GetUserAuthenticationMethodResponseContent", "GetUserGroupsPaginatedResponseContent", "GetUserResponseContent", + "GetVariationResponseContent", "GetVerifiableCredentialTemplateResponseContent", "GoneError", "Group", @@ -11011,6 +11133,8 @@ def __dir__(): "ListEncryptionKeyOffsetPaginatedResponseContent", "ListEventStreamDeliveriesResponseContent", "ListEventStreamsResponseContent", + "ListExperimentsResponseContent", + "ListFeatureFlagsResponseContent", "ListFlowExecutionsPaginatedResponseContent", "ListFlowsOffsetPaginatedResponseContent", "ListFlowsRequestParametersHydrateEnum", @@ -11047,6 +11171,7 @@ def __dir__(): "ListRolesOffsetPaginatedResponseContent", "ListRulesOffsetPaginatedResponseContent", "ListScimConfigurationsResponseContent", + "ListSegmentsResponseContent", "ListSelfServiceProfileCustomTextResponseContent", "ListSelfServiceProfilesPaginatedResponseContent", "ListSynchronizedGroupsResponseContent", @@ -11067,6 +11192,7 @@ def __dir__(): "ListUserRolesOffsetPaginatedResponseContent", "ListUserSessionsPaginatedResponseContent", "ListUsersOffsetPaginatedResponseContent", + "ListVariationsResponseContent", "ListVerifiableCredentialTemplatesPaginatedResponseContent", "Log", "LogDate", @@ -11166,7 +11292,6 @@ def __dir__(): "OrganizationClientMetadataOrganizationUsageEnum", "OrganizationConnection", "OrganizationConnectionInformation", - "OrganizationDeletionBehaviorEnum", "OrganizationDiscoveryDomain", "OrganizationDiscoveryDomainStatus", "OrganizationEnabledConnection", @@ -11181,12 +11306,6 @@ def __dir__(): "OrganizationMemberRole", "OrganizationMetadata", "OrganizationSortFieldEnum", - "OrganizationTemplate", - "OrganizationTemplateAllowedStrategyEnum", - "OrganizationTemplateRoleVisibilityEnum", - "OrganizationTemplateRoleVisibilityOverride", - "OrganizationTemplateRoleVisibilityPolicy", - "OrganizationTemplateUseForOrganizationDiscovery", "OrganizationThirdPartyClientAccessEnum", "OrganizationUsageEnum", "PartialGroupsEnum", @@ -11309,6 +11428,17 @@ def __dir__(): "SearchOrganizationsPaginatedResponseContent", "SearchParserEnum", "SearchResourceServersResponseContent", + "Segment", + "SegmentContainsExpression", + "SegmentEndsWithExpression", + "SegmentExistsExpression", + "SegmentMatchConditions", + "SegmentMatchExpression", + "SegmentNotMatchConditions", + "SegmentRule", + "SegmentStartsWithExpression", + "SegmentTypeEnum", + "SegmentTypeFilterEnum", "SelfServiceProfile", "SelfServiceProfileAllowedStrategyEnum", "SelfServiceProfileBranding", @@ -11525,6 +11655,11 @@ def __dir__(): "UpdateEnabledClientConnectionsRequestContent", "UpdateEnabledClientConnectionsRequestContentItem", "UpdateEventStreamResponseContent", + "UpdateExperimentResponseContent", + "UpdateExperimentStatusResponseContent", + "UpdateFeatureFlagParameters", + "UpdateFeatureFlagResponseContent", + "UpdateFeatureFlagStatusResponseContent", "UpdateFlowResponseContent", "UpdateFlowsVaultConnectionResponseContent", "UpdateFlowsVaultConnectionSetup", @@ -11553,6 +11688,7 @@ def __dir__(): "UpdateRoleResponseContent", "UpdateRuleResponseContent", "UpdateScimConfigurationResponseContent", + "UpdateSegmentResponseContent", "UpdateSelfServiceProfileResponseContent", "UpdateSessionResponseContent", "UpdateSettingsResponseContent", @@ -11564,6 +11700,8 @@ def __dir__(): "UpdateUserAttributeProfileResponseContent", "UpdateUserAuthenticationMethodResponseContent", "UpdateUserResponseContent", + "UpdateVariationOverridesMap", + "UpdateVariationResponseContent", "UpdateVerifiableCredentialTemplateResponseContent", "UserAppMetadataSchema", "UserAttributeProfile", @@ -11614,6 +11752,9 @@ def __dir__(): "UsernameAttributeIdentifier", "UsernameValidation", "UsersEnrollment", + "ValidateExperimentResponseContent", + "Variation", + "VariationOverridesMap", "VerifiableCredentialTemplateResponse", "VerificationMethodEnum", "VerifyCustomDomainResponseContent", diff --git a/src/auth0/management/clients/client.py b/src/auth0/management/clients/client.py index 1afcf22d..881a8eec 100644 --- a/src/auth0/management/clients/client.py +++ b/src/auth0/management/clients/client.py @@ -28,6 +28,7 @@ from ..types.client_my_organization_patch_configuration import ClientMyOrganizationPatchConfiguration from ..types.client_my_organization_post_configuration import ClientMyOrganizationPostConfiguration from ..types.client_oidc_backchannel_logout_settings import ClientOidcBackchannelLogoutSettings +from ..types.client_oidc_support_post import ClientOidcSupportPost from ..types.client_organization_discovery_enum import ClientOrganizationDiscoveryEnum from ..types.client_organization_require_behavior_enum import ClientOrganizationRequireBehaviorEnum from ..types.client_organization_require_behavior_patch_enum import ClientOrganizationRequireBehaviorPatchEnum @@ -277,6 +278,7 @@ def create( async_approval_notification_channels: typing.Optional[ ClientAsyncApprovalNotificationsChannelsApiPostConfiguration ] = OMIT, + oidc_support: typing.Optional[ClientOidcSupportPost] = OMIT, request_options: typing.Optional[RequestOptions] = None, ) -> CreateClientResponseContent: """ @@ -444,6 +446,8 @@ def create( async_approval_notification_channels : typing.Optional[ClientAsyncApprovalNotificationsChannelsApiPostConfiguration] + oidc_support : typing.Optional[ClientOidcSupportPost] + request_options : typing.Optional[RequestOptions] Request-specific configuration. @@ -522,6 +526,7 @@ def create( b_2_b_integration_configuration=b_2_b_integration_configuration, my_organization_configuration=my_organization_configuration, async_approval_notification_channels=async_approval_notification_channels, + oidc_support=oidc_support, request_options=request_options, ) return _response.data @@ -1290,6 +1295,7 @@ async def create( async_approval_notification_channels: typing.Optional[ ClientAsyncApprovalNotificationsChannelsApiPostConfiguration ] = OMIT, + oidc_support: typing.Optional[ClientOidcSupportPost] = OMIT, request_options: typing.Optional[RequestOptions] = None, ) -> CreateClientResponseContent: """ @@ -1457,6 +1463,8 @@ async def create( async_approval_notification_channels : typing.Optional[ClientAsyncApprovalNotificationsChannelsApiPostConfiguration] + oidc_support : typing.Optional[ClientOidcSupportPost] + request_options : typing.Optional[RequestOptions] Request-specific configuration. @@ -1543,6 +1551,7 @@ async def main() -> None: b_2_b_integration_configuration=b_2_b_integration_configuration, my_organization_configuration=my_organization_configuration, async_approval_notification_channels=async_approval_notification_channels, + oidc_support=oidc_support, request_options=request_options, ) return _response.data diff --git a/src/auth0/management/clients/raw_client.py b/src/auth0/management/clients/raw_client.py index 26e09a59..0484a914 100644 --- a/src/auth0/management/clients/raw_client.py +++ b/src/auth0/management/clients/raw_client.py @@ -40,6 +40,7 @@ from ..types.client_my_organization_patch_configuration import ClientMyOrganizationPatchConfiguration from ..types.client_my_organization_post_configuration import ClientMyOrganizationPostConfiguration from ..types.client_oidc_backchannel_logout_settings import ClientOidcBackchannelLogoutSettings +from ..types.client_oidc_support_post import ClientOidcSupportPost from ..types.client_organization_discovery_enum import ClientOrganizationDiscoveryEnum from ..types.client_organization_require_behavior_enum import ClientOrganizationRequireBehaviorEnum from ..types.client_organization_require_behavior_patch_enum import ClientOrganizationRequireBehaviorPatchEnum @@ -330,6 +331,7 @@ def create( async_approval_notification_channels: typing.Optional[ ClientAsyncApprovalNotificationsChannelsApiPostConfiguration ] = OMIT, + oidc_support: typing.Optional[ClientOidcSupportPost] = OMIT, request_options: typing.Optional[RequestOptions] = None, ) -> HttpResponse[CreateClientResponseContent]: """ @@ -497,6 +499,8 @@ def create( async_approval_notification_channels : typing.Optional[ClientAsyncApprovalNotificationsChannelsApiPostConfiguration] + oidc_support : typing.Optional[ClientOidcSupportPost] + request_options : typing.Optional[RequestOptions] Request-specific configuration. @@ -623,6 +627,9 @@ def create( direction="write", ), "async_approval_notification_channels": async_approval_notification_channels, + "oidc_support": convert_and_respect_annotation_metadata( + object_=oidc_support, annotation=ClientOidcSupportPost, direction="write" + ), }, headers={ "content-type": "application/json", @@ -1948,6 +1955,7 @@ async def create( async_approval_notification_channels: typing.Optional[ ClientAsyncApprovalNotificationsChannelsApiPostConfiguration ] = OMIT, + oidc_support: typing.Optional[ClientOidcSupportPost] = OMIT, request_options: typing.Optional[RequestOptions] = None, ) -> AsyncHttpResponse[CreateClientResponseContent]: """ @@ -2115,6 +2123,8 @@ async def create( async_approval_notification_channels : typing.Optional[ClientAsyncApprovalNotificationsChannelsApiPostConfiguration] + oidc_support : typing.Optional[ClientOidcSupportPost] + request_options : typing.Optional[RequestOptions] Request-specific configuration. @@ -2241,6 +2251,9 @@ async def create( direction="write", ), "async_approval_notification_channels": async_approval_notification_channels, + "oidc_support": convert_and_respect_annotation_metadata( + object_=oidc_support, annotation=ClientOidcSupportPost, direction="write" + ), }, headers={ "content-type": "application/json", diff --git a/src/auth0/management/core/client_wrapper.py b/src/auth0/management/core/client_wrapper.py index fd991f52..abce2c81 100644 --- a/src/auth0/management/core/client_wrapper.py +++ b/src/auth0/management/core/client_wrapper.py @@ -1,11 +1,6 @@ # This file was auto-generated by Fern from our API Definition. -# Modified by Auth0 to use Auth0 telemetry format with dynamic versioning -import base64 -import platform -import sys import typing -from json import dumps import httpx from .http_client import AsyncHttpClient, HttpClient @@ -35,18 +30,7 @@ def __init__( self._logging = logging def get_headers(self) -> typing.Dict[str, str]: - py_version = platform.python_version() - version = sys.modules["auth0"].__version__ - - auth0_client = dumps({ - "name": "auth0-python", - "version": version, - "env": {"python": py_version} - }).encode("utf-8") - headers: typing.Dict[str, str] = { - "User-Agent": f"Python/{py_version}", - "Auth0-Client": base64.b64encode(auth0_client).decode(), **(self.get_custom_headers() or {}), } headers["Authorization"] = f"Bearer {self._get_token()}" diff --git a/src/auth0/management/experimentation/__init__.py b/src/auth0/management/experimentation/__init__.py index ae95c3f6..1e498c78 100644 --- a/src/auth0/management/experimentation/__init__.py +++ b/src/auth0/management/experimentation/__init__.py @@ -6,8 +6,12 @@ from importlib import import_module if typing.TYPE_CHECKING: - from . import experiments -_dynamic_imports: typing.Dict[str, str] = {"experiments": ".experiments"} + from . import experiments, feature_flags, segments +_dynamic_imports: typing.Dict[str, str] = { + "experiments": ".experiments", + "feature_flags": ".feature_flags", + "segments": ".segments", +} def __getattr__(attr_name: str) -> typing.Any: @@ -31,4 +35,4 @@ def __dir__(): return sorted(lazy_attrs) -__all__ = ["experiments"] +__all__ = ["experiments", "feature_flags", "segments"] diff --git a/src/auth0/management/experimentation/client.py b/src/auth0/management/experimentation/client.py index bdb6c823..48fc1407 100644 --- a/src/auth0/management/experimentation/client.py +++ b/src/auth0/management/experimentation/client.py @@ -9,6 +9,8 @@ if typing.TYPE_CHECKING: from .experiments.client import AsyncExperimentsClient, ExperimentsClient + from .feature_flags.client import AsyncFeatureFlagsClient, FeatureFlagsClient + from .segments.client import AsyncSegmentsClient, SegmentsClient class ExperimentationClient: @@ -16,6 +18,8 @@ def __init__(self, *, client_wrapper: SyncClientWrapper): self._raw_client = RawExperimentationClient(client_wrapper=client_wrapper) self._client_wrapper = client_wrapper self._experiments: typing.Optional[ExperimentsClient] = None + self._feature_flags: typing.Optional[FeatureFlagsClient] = None + self._segments: typing.Optional[SegmentsClient] = None @property def with_raw_response(self) -> RawExperimentationClient: @@ -36,12 +40,30 @@ def experiments(self): self._experiments = ExperimentsClient(client_wrapper=self._client_wrapper) return self._experiments + @property + def feature_flags(self): + if self._feature_flags is None: + from .feature_flags.client import FeatureFlagsClient # noqa: E402 + + self._feature_flags = FeatureFlagsClient(client_wrapper=self._client_wrapper) + return self._feature_flags + + @property + def segments(self): + if self._segments is None: + from .segments.client import SegmentsClient # noqa: E402 + + self._segments = SegmentsClient(client_wrapper=self._client_wrapper) + return self._segments + class AsyncExperimentationClient: def __init__(self, *, client_wrapper: AsyncClientWrapper): self._raw_client = AsyncRawExperimentationClient(client_wrapper=client_wrapper) self._client_wrapper = client_wrapper self._experiments: typing.Optional[AsyncExperimentsClient] = None + self._feature_flags: typing.Optional[AsyncFeatureFlagsClient] = None + self._segments: typing.Optional[AsyncSegmentsClient] = None @property def with_raw_response(self) -> AsyncRawExperimentationClient: @@ -61,3 +83,19 @@ def experiments(self): self._experiments = AsyncExperimentsClient(client_wrapper=self._client_wrapper) return self._experiments + + @property + def feature_flags(self): + if self._feature_flags is None: + from .feature_flags.client import AsyncFeatureFlagsClient # noqa: E402 + + self._feature_flags = AsyncFeatureFlagsClient(client_wrapper=self._client_wrapper) + return self._feature_flags + + @property + def segments(self): + if self._segments is None: + from .segments.client import AsyncSegmentsClient # noqa: E402 + + self._segments = AsyncSegmentsClient(client_wrapper=self._client_wrapper) + return self._segments diff --git a/src/auth0/management/experimentation/experiments/client.py b/src/auth0/management/experimentation/experiments/client.py index 11593bfd..45bbc1b4 100644 --- a/src/auth0/management/experimentation/experiments/client.py +++ b/src/auth0/management/experimentation/experiments/client.py @@ -3,8 +3,22 @@ import typing from ...core.client_wrapper import AsyncClientWrapper, SyncClientWrapper +from ...core.pagination import AsyncPager, SyncPager from ...core.request_options import RequestOptions from ...types.advance_ramp_response_content import AdvanceRampResponseContent +from ...types.allocation_request_item import AllocationRequestItem +from ...types.allocation_strategy_enum import AllocationStrategyEnum +from ...types.authentication_flow_enum import AuthenticationFlowEnum +from ...types.create_experiment_response_content import CreateExperimentResponseContent +from ...types.default_config_enum import DefaultConfigEnum +from ...types.experiment_list_item import ExperimentListItem +from ...types.experiment_status_enum import ExperimentStatusEnum +from ...types.experiment_transition_status_enum import ExperimentTransitionStatusEnum +from ...types.get_experiment_response_content import GetExperimentResponseContent +from ...types.list_experiments_response_content import ListExperimentsResponseContent +from ...types.update_experiment_response_content import UpdateExperimentResponseContent +from ...types.update_experiment_status_response_content import UpdateExperimentStatusResponseContent +from ...types.validate_experiment_response_content import ValidateExperimentResponseContent from .raw_client import AsyncRawExperimentsClient, RawExperimentsClient # this is used as the default value for optional parameters @@ -26,6 +40,278 @@ def with_raw_response(self) -> RawExperimentsClient: """ return self._raw_client + def list( + self, + *, + from_: typing.Optional[str] = None, + take: typing.Optional[int] = 50, + status: typing.Optional[ExperimentStatusEnum] = None, + authentication_flow: typing.Optional[str] = None, + feature_flag_id: typing.Optional[str] = None, + request_options: typing.Optional[RequestOptions] = None, + ) -> SyncPager[ExperimentListItem, ListExperimentsResponseContent]: + """ + Retrieve a paginated list of experiments for the tenant, with optional filters. + + Parameters + ---------- + from_ : typing.Optional[str] + Optional Id from which to start selection. + + take : typing.Optional[int] + Number of experiments to return per page. Defaults to 25, maximum 50. + + status : typing.Optional[ExperimentStatusEnum] + Filter by status. Exact match. + + authentication_flow : typing.Optional[str] + Filter by authentication flow. Exact match. + + feature_flag_id : typing.Optional[str] + Filter by feature flag ID. Exact match. + + request_options : typing.Optional[RequestOptions] + Request-specific configuration. + + Returns + ------- + SyncPager[ExperimentListItem, ListExperimentsResponseContent] + Experiments successfully retrieved. + + Examples + -------- + from auth0 import Auth0 + + client = Auth0( + token="YOUR_TOKEN", + ) + response = client.experimentation.experiments.list( + from_="from", + take=1, + status="draft", + authentication_flow="authentication_flow", + feature_flag_id="feature_flag_id", + ) + for item in response: + yield item + # alternatively, you can paginate page-by-page + for page in response.iter_pages(): + yield page + """ + return self._raw_client.list( + from_=from_, + take=take, + status=status, + authentication_flow=authentication_flow, + feature_flag_id=feature_flag_id, + request_options=request_options, + ) + + def create( + self, + *, + name: str, + feature_flag_id: str, + authentication_flow: AuthenticationFlowEnum, + description: typing.Optional[str] = OMIT, + default_config: typing.Optional[DefaultConfigEnum] = OMIT, + allocation_strategy: typing.Optional[AllocationStrategyEnum] = OMIT, + allocations: typing.Optional[typing.Sequence[AllocationRequestItem]] = OMIT, + levels: typing.Optional[typing.Sequence[int]] = OMIT, + request_options: typing.Optional[RequestOptions] = None, + ) -> CreateExperimentResponseContent: + """ + Create a new experiment for A/B testing. + + Parameters + ---------- + name : str + A human-readable name for the experiment + + feature_flag_id : str + The ID of the feature flag this experiment is based on + + authentication_flow : AuthenticationFlowEnum + + description : typing.Optional[str] + A description of the experiment + + default_config : typing.Optional[DefaultConfigEnum] + Applies only to Auth0-managed flags. Controls where non-overridden config keys resolve from: 'tenant' inherits the tenant's live config so the experiment overlays only its changes, 'flag' uses the flag's frozen defaults for a complete config. Optional; defaults to 'tenant' when omitted. Rejected for customer-defined flags. + + allocation_strategy : typing.Optional[AllocationStrategyEnum] + The traffic allocation strategy for this experiment + + allocations : typing.Optional[typing.Sequence[AllocationRequestItem]] + Traffic allocations mapping variations to weights or segments + + levels : typing.Optional[typing.Sequence[int]] + Ramp experiment levels configuration. A strictly-increasing sequence of exposure percentages, each an integer in [0, 100]. + + request_options : typing.Optional[RequestOptions] + Request-specific configuration. + + Returns + ------- + CreateExperimentResponseContent + Experiment successfully created. + + Examples + -------- + from auth0 import Auth0 + + client = Auth0( + token="YOUR_TOKEN", + ) + client.experimentation.experiments.create( + name="name", + feature_flag_id="feature_flag_id", + authentication_flow="authentication", + ) + """ + _response = self._raw_client.create( + name=name, + feature_flag_id=feature_flag_id, + authentication_flow=authentication_flow, + description=description, + default_config=default_config, + allocation_strategy=allocation_strategy, + allocations=allocations, + levels=levels, + request_options=request_options, + ) + return _response.data + + def get(self, id: str, *, request_options: typing.Optional[RequestOptions] = None) -> GetExperimentResponseContent: + """ + Retrieve a single experiment with its allocations by ID. + + Parameters + ---------- + id : str + The ID of the experiment to retrieve. + + request_options : typing.Optional[RequestOptions] + Request-specific configuration. + + Returns + ------- + GetExperimentResponseContent + Experiment successfully retrieved. + + Examples + -------- + from auth0 import Auth0 + + client = Auth0( + token="YOUR_TOKEN", + ) + client.experimentation.experiments.get( + id="id", + ) + """ + _response = self._raw_client.get(id, request_options=request_options) + return _response.data + + def delete(self, id: str, *, request_options: typing.Optional[RequestOptions] = None) -> None: + """ + Permanently delete an experiment and its allocations by ID. Active experiments cannot be deleted; pause or complete first. Idempotent: returns 204 even if the experiment does not exist. + + Parameters + ---------- + id : str + The ID of the experiment to delete. + + request_options : typing.Optional[RequestOptions] + Request-specific configuration. + + Returns + ------- + None + + Examples + -------- + from auth0 import Auth0 + + client = Auth0( + token="YOUR_TOKEN", + ) + client.experimentation.experiments.delete( + id="id", + ) + """ + _response = self._raw_client.delete(id, request_options=request_options) + return _response.data + + def update( + self, + id: str, + *, + name: typing.Optional[str] = OMIT, + description: typing.Optional[str] = OMIT, + authentication_flow: typing.Optional[AuthenticationFlowEnum] = OMIT, + allocations: typing.Optional[typing.Sequence[AllocationRequestItem]] = OMIT, + default_config: typing.Optional[DefaultConfigEnum] = OMIT, + levels: typing.Optional[typing.Sequence[int]] = OMIT, + request_options: typing.Optional[RequestOptions] = None, + ) -> UpdateExperimentResponseContent: + """ + Partially update an experiment by ID. Only provided fields are updated. Providing allocations replaces the entire allocations set. + + Parameters + ---------- + id : str + The ID of the experiment to update. + + name : typing.Optional[str] + A human-readable name for the experiment + + description : typing.Optional[str] + A description of the experiment + + authentication_flow : typing.Optional[AuthenticationFlowEnum] + Specifies the target authentication flow for this experiment. This field can only be modified on draft experiments. Must be one of: authentication, mfa_enrollment, mfa_challenge, password_reset, passkey_enrollment, or all. Note that the all value targets every flow at once, but requires that this is the only active experiment. + + allocations : typing.Optional[typing.Sequence[AllocationRequestItem]] + Replaces all traffic allocations. Cannot be modified while the experiment is active. + + default_config : typing.Optional[DefaultConfigEnum] + Applies only to Auth0-managed flags. Controls where non-overridden config keys resolve from: 'tenant' inherits the tenant's live config, 'flag' uses the flag's frozen defaults. Can only be modified on draft experiments. Rejected for customer-defined flags. + + levels : typing.Optional[typing.Sequence[int]] + Ramp experiment levels configuration. A strictly-increasing sequence of exposure percentages, each an integer in [0, 100]. Can only be modified on draft experiments. + + request_options : typing.Optional[RequestOptions] + Request-specific configuration. + + Returns + ------- + UpdateExperimentResponseContent + Experiment successfully updated. + + Examples + -------- + from auth0 import Auth0 + + client = Auth0( + token="YOUR_TOKEN", + ) + client.experimentation.experiments.update( + id="id", + ) + """ + _response = self._raw_client.update( + id, + name=name, + description=description, + authentication_flow=authentication_flow, + allocations=allocations, + default_config=default_config, + levels=levels, + request_options=request_options, + ) + return _response.data + def advance_ramp( self, id: str, *, target_level: int, request_options: typing.Optional[RequestOptions] = None ) -> AdvanceRampResponseContent: @@ -63,6 +349,79 @@ def advance_ramp( _response = self._raw_client.advance_ramp(id, target_level=target_level, request_options=request_options) return _response.data + def update_status( + self, + id: str, + *, + status: ExperimentTransitionStatusEnum, + request_options: typing.Optional[RequestOptions] = None, + ) -> UpdateExperimentStatusResponseContent: + """ + Transitions an experiment through its lifecycle: draft → active, active → paused, paused → active, active/paused → completed. Activation runs full readiness validation. + + Parameters + ---------- + id : str + The ID of the experiment to transition. + + status : ExperimentTransitionStatusEnum + + request_options : typing.Optional[RequestOptions] + Request-specific configuration. + + Returns + ------- + UpdateExperimentStatusResponseContent + Experiment status successfully updated. + + Examples + -------- + from auth0 import Auth0 + + client = Auth0( + token="YOUR_TOKEN", + ) + client.experimentation.experiments.update_status( + id="id", + status="active", + ) + """ + _response = self._raw_client.update_status(id, status=status, request_options=request_options) + return _response.data + + def validate( + self, id: str, *, request_options: typing.Optional[RequestOptions] = None + ) -> ValidateExperimentResponseContent: + """ + Checks whether an experiment is ready to be activated. Returns is_valid boolean and an errors array describing any blockers. Read-only; no state is modified. + + Parameters + ---------- + id : str + The ID of the experiment to validate. + + request_options : typing.Optional[RequestOptions] + Request-specific configuration. + + Returns + ------- + ValidateExperimentResponseContent + Experiment validation result returned. + + Examples + -------- + from auth0 import Auth0 + + client = Auth0( + token="YOUR_TOKEN", + ) + client.experimentation.experiments.validate( + id="id", + ) + """ + _response = self._raw_client.validate(id, request_options=request_options) + return _response.data + class AsyncExperimentsClient: def __init__(self, *, client_wrapper: AsyncClientWrapper): @@ -79,6 +438,321 @@ def with_raw_response(self) -> AsyncRawExperimentsClient: """ return self._raw_client + async def list( + self, + *, + from_: typing.Optional[str] = None, + take: typing.Optional[int] = 50, + status: typing.Optional[ExperimentStatusEnum] = None, + authentication_flow: typing.Optional[str] = None, + feature_flag_id: typing.Optional[str] = None, + request_options: typing.Optional[RequestOptions] = None, + ) -> AsyncPager[ExperimentListItem, ListExperimentsResponseContent]: + """ + Retrieve a paginated list of experiments for the tenant, with optional filters. + + Parameters + ---------- + from_ : typing.Optional[str] + Optional Id from which to start selection. + + take : typing.Optional[int] + Number of experiments to return per page. Defaults to 25, maximum 50. + + status : typing.Optional[ExperimentStatusEnum] + Filter by status. Exact match. + + authentication_flow : typing.Optional[str] + Filter by authentication flow. Exact match. + + feature_flag_id : typing.Optional[str] + Filter by feature flag ID. Exact match. + + request_options : typing.Optional[RequestOptions] + Request-specific configuration. + + Returns + ------- + AsyncPager[ExperimentListItem, ListExperimentsResponseContent] + Experiments successfully retrieved. + + Examples + -------- + import asyncio + + from auth0 import AsyncAuth0 + + client = AsyncAuth0( + token="YOUR_TOKEN", + ) + + + async def main() -> None: + response = await client.experimentation.experiments.list( + from_="from", + take=1, + status="draft", + authentication_flow="authentication_flow", + feature_flag_id="feature_flag_id", + ) + async for item in response: + yield item + + # alternatively, you can paginate page-by-page + async for page in response.iter_pages(): + yield page + + + asyncio.run(main()) + """ + return await self._raw_client.list( + from_=from_, + take=take, + status=status, + authentication_flow=authentication_flow, + feature_flag_id=feature_flag_id, + request_options=request_options, + ) + + async def create( + self, + *, + name: str, + feature_flag_id: str, + authentication_flow: AuthenticationFlowEnum, + description: typing.Optional[str] = OMIT, + default_config: typing.Optional[DefaultConfigEnum] = OMIT, + allocation_strategy: typing.Optional[AllocationStrategyEnum] = OMIT, + allocations: typing.Optional[typing.Sequence[AllocationRequestItem]] = OMIT, + levels: typing.Optional[typing.Sequence[int]] = OMIT, + request_options: typing.Optional[RequestOptions] = None, + ) -> CreateExperimentResponseContent: + """ + Create a new experiment for A/B testing. + + Parameters + ---------- + name : str + A human-readable name for the experiment + + feature_flag_id : str + The ID of the feature flag this experiment is based on + + authentication_flow : AuthenticationFlowEnum + + description : typing.Optional[str] + A description of the experiment + + default_config : typing.Optional[DefaultConfigEnum] + Applies only to Auth0-managed flags. Controls where non-overridden config keys resolve from: 'tenant' inherits the tenant's live config so the experiment overlays only its changes, 'flag' uses the flag's frozen defaults for a complete config. Optional; defaults to 'tenant' when omitted. Rejected for customer-defined flags. + + allocation_strategy : typing.Optional[AllocationStrategyEnum] + The traffic allocation strategy for this experiment + + allocations : typing.Optional[typing.Sequence[AllocationRequestItem]] + Traffic allocations mapping variations to weights or segments + + levels : typing.Optional[typing.Sequence[int]] + Ramp experiment levels configuration. A strictly-increasing sequence of exposure percentages, each an integer in [0, 100]. + + request_options : typing.Optional[RequestOptions] + Request-specific configuration. + + Returns + ------- + CreateExperimentResponseContent + Experiment successfully created. + + Examples + -------- + import asyncio + + from auth0 import AsyncAuth0 + + client = AsyncAuth0( + token="YOUR_TOKEN", + ) + + + async def main() -> None: + await client.experimentation.experiments.create( + name="name", + feature_flag_id="feature_flag_id", + authentication_flow="authentication", + ) + + + asyncio.run(main()) + """ + _response = await self._raw_client.create( + name=name, + feature_flag_id=feature_flag_id, + authentication_flow=authentication_flow, + description=description, + default_config=default_config, + allocation_strategy=allocation_strategy, + allocations=allocations, + levels=levels, + request_options=request_options, + ) + return _response.data + + async def get( + self, id: str, *, request_options: typing.Optional[RequestOptions] = None + ) -> GetExperimentResponseContent: + """ + Retrieve a single experiment with its allocations by ID. + + Parameters + ---------- + id : str + The ID of the experiment to retrieve. + + request_options : typing.Optional[RequestOptions] + Request-specific configuration. + + Returns + ------- + GetExperimentResponseContent + Experiment successfully retrieved. + + Examples + -------- + import asyncio + + from auth0 import AsyncAuth0 + + client = AsyncAuth0( + token="YOUR_TOKEN", + ) + + + async def main() -> None: + await client.experimentation.experiments.get( + id="id", + ) + + + asyncio.run(main()) + """ + _response = await self._raw_client.get(id, request_options=request_options) + return _response.data + + async def delete(self, id: str, *, request_options: typing.Optional[RequestOptions] = None) -> None: + """ + Permanently delete an experiment and its allocations by ID. Active experiments cannot be deleted; pause or complete first. Idempotent: returns 204 even if the experiment does not exist. + + Parameters + ---------- + id : str + The ID of the experiment to delete. + + request_options : typing.Optional[RequestOptions] + Request-specific configuration. + + Returns + ------- + None + + Examples + -------- + import asyncio + + from auth0 import AsyncAuth0 + + client = AsyncAuth0( + token="YOUR_TOKEN", + ) + + + async def main() -> None: + await client.experimentation.experiments.delete( + id="id", + ) + + + asyncio.run(main()) + """ + _response = await self._raw_client.delete(id, request_options=request_options) + return _response.data + + async def update( + self, + id: str, + *, + name: typing.Optional[str] = OMIT, + description: typing.Optional[str] = OMIT, + authentication_flow: typing.Optional[AuthenticationFlowEnum] = OMIT, + allocations: typing.Optional[typing.Sequence[AllocationRequestItem]] = OMIT, + default_config: typing.Optional[DefaultConfigEnum] = OMIT, + levels: typing.Optional[typing.Sequence[int]] = OMIT, + request_options: typing.Optional[RequestOptions] = None, + ) -> UpdateExperimentResponseContent: + """ + Partially update an experiment by ID. Only provided fields are updated. Providing allocations replaces the entire allocations set. + + Parameters + ---------- + id : str + The ID of the experiment to update. + + name : typing.Optional[str] + A human-readable name for the experiment + + description : typing.Optional[str] + A description of the experiment + + authentication_flow : typing.Optional[AuthenticationFlowEnum] + Specifies the target authentication flow for this experiment. This field can only be modified on draft experiments. Must be one of: authentication, mfa_enrollment, mfa_challenge, password_reset, passkey_enrollment, or all. Note that the all value targets every flow at once, but requires that this is the only active experiment. + + allocations : typing.Optional[typing.Sequence[AllocationRequestItem]] + Replaces all traffic allocations. Cannot be modified while the experiment is active. + + default_config : typing.Optional[DefaultConfigEnum] + Applies only to Auth0-managed flags. Controls where non-overridden config keys resolve from: 'tenant' inherits the tenant's live config, 'flag' uses the flag's frozen defaults. Can only be modified on draft experiments. Rejected for customer-defined flags. + + levels : typing.Optional[typing.Sequence[int]] + Ramp experiment levels configuration. A strictly-increasing sequence of exposure percentages, each an integer in [0, 100]. Can only be modified on draft experiments. + + request_options : typing.Optional[RequestOptions] + Request-specific configuration. + + Returns + ------- + UpdateExperimentResponseContent + Experiment successfully updated. + + Examples + -------- + import asyncio + + from auth0 import AsyncAuth0 + + client = AsyncAuth0( + token="YOUR_TOKEN", + ) + + + async def main() -> None: + await client.experimentation.experiments.update( + id="id", + ) + + + asyncio.run(main()) + """ + _response = await self._raw_client.update( + id, + name=name, + description=description, + authentication_flow=authentication_flow, + allocations=allocations, + default_config=default_config, + levels=levels, + request_options=request_options, + ) + return _response.data + async def advance_ramp( self, id: str, *, target_level: int, request_options: typing.Optional[RequestOptions] = None ) -> AdvanceRampResponseContent: @@ -123,3 +797,92 @@ async def main() -> None: """ _response = await self._raw_client.advance_ramp(id, target_level=target_level, request_options=request_options) return _response.data + + async def update_status( + self, + id: str, + *, + status: ExperimentTransitionStatusEnum, + request_options: typing.Optional[RequestOptions] = None, + ) -> UpdateExperimentStatusResponseContent: + """ + Transitions an experiment through its lifecycle: draft → active, active → paused, paused → active, active/paused → completed. Activation runs full readiness validation. + + Parameters + ---------- + id : str + The ID of the experiment to transition. + + status : ExperimentTransitionStatusEnum + + request_options : typing.Optional[RequestOptions] + Request-specific configuration. + + Returns + ------- + UpdateExperimentStatusResponseContent + Experiment status successfully updated. + + Examples + -------- + import asyncio + + from auth0 import AsyncAuth0 + + client = AsyncAuth0( + token="YOUR_TOKEN", + ) + + + async def main() -> None: + await client.experimentation.experiments.update_status( + id="id", + status="active", + ) + + + asyncio.run(main()) + """ + _response = await self._raw_client.update_status(id, status=status, request_options=request_options) + return _response.data + + async def validate( + self, id: str, *, request_options: typing.Optional[RequestOptions] = None + ) -> ValidateExperimentResponseContent: + """ + Checks whether an experiment is ready to be activated. Returns is_valid boolean and an errors array describing any blockers. Read-only; no state is modified. + + Parameters + ---------- + id : str + The ID of the experiment to validate. + + request_options : typing.Optional[RequestOptions] + Request-specific configuration. + + Returns + ------- + ValidateExperimentResponseContent + Experiment validation result returned. + + Examples + -------- + import asyncio + + from auth0 import AsyncAuth0 + + client = AsyncAuth0( + token="YOUR_TOKEN", + ) + + + async def main() -> None: + await client.experimentation.experiments.validate( + id="id", + ) + + + asyncio.run(main()) + """ + _response = await self._raw_client.validate(id, request_options=request_options) + return _response.data diff --git a/src/auth0/management/experimentation/experiments/raw_client.py b/src/auth0/management/experimentation/experiments/raw_client.py index 30e3b1aa..c6dad9eb 100644 --- a/src/auth0/management/experimentation/experiments/raw_client.py +++ b/src/auth0/management/experimentation/experiments/raw_client.py @@ -7,16 +7,32 @@ from ...core.client_wrapper import AsyncClientWrapper, SyncClientWrapper from ...core.http_response import AsyncHttpResponse, HttpResponse from ...core.jsonable_encoder import quote_path_param +from ...core.pagination import AsyncPager, SyncPager from ...core.parse_error import ParsingError from ...core.pydantic_utilities import parse_obj_as from ...core.request_options import RequestOptions +from ...core.serialization import convert_and_respect_annotation_metadata from ...errors.bad_request_error import BadRequestError from ...errors.conflict_error import ConflictError from ...errors.forbidden_error import ForbiddenError from ...errors.not_found_error import NotFoundError from ...errors.too_many_requests_error import TooManyRequestsError from ...errors.unauthorized_error import UnauthorizedError +from ...errors.unprocessable_entity_error import UnprocessableEntityError from ...types.advance_ramp_response_content import AdvanceRampResponseContent +from ...types.allocation_request_item import AllocationRequestItem +from ...types.allocation_strategy_enum import AllocationStrategyEnum +from ...types.authentication_flow_enum import AuthenticationFlowEnum +from ...types.create_experiment_response_content import CreateExperimentResponseContent +from ...types.default_config_enum import DefaultConfigEnum +from ...types.experiment_list_item import ExperimentListItem +from ...types.experiment_status_enum import ExperimentStatusEnum +from ...types.experiment_transition_status_enum import ExperimentTransitionStatusEnum +from ...types.get_experiment_response_content import GetExperimentResponseContent +from ...types.list_experiments_response_content import ListExperimentsResponseContent +from ...types.update_experiment_response_content import UpdateExperimentResponseContent +from ...types.update_experiment_status_response_content import UpdateExperimentStatusResponseContent +from ...types.validate_experiment_response_content import ValidateExperimentResponseContent from pydantic import ValidationError # this is used as the default value for optional parameters @@ -27,33 +43,1460 @@ class RawExperimentsClient: def __init__(self, *, client_wrapper: SyncClientWrapper): self._client_wrapper = client_wrapper + def list( + self, + *, + from_: typing.Optional[str] = None, + take: typing.Optional[int] = 50, + status: typing.Optional[ExperimentStatusEnum] = None, + authentication_flow: typing.Optional[str] = None, + feature_flag_id: typing.Optional[str] = None, + request_options: typing.Optional[RequestOptions] = None, + ) -> SyncPager[ExperimentListItem, ListExperimentsResponseContent]: + """ + Retrieve a paginated list of experiments for the tenant, with optional filters. + + Parameters + ---------- + from_ : typing.Optional[str] + Optional Id from which to start selection. + + take : typing.Optional[int] + Number of experiments to return per page. Defaults to 25, maximum 50. + + status : typing.Optional[ExperimentStatusEnum] + Filter by status. Exact match. + + authentication_flow : typing.Optional[str] + Filter by authentication flow. Exact match. + + feature_flag_id : typing.Optional[str] + Filter by feature flag ID. Exact match. + + request_options : typing.Optional[RequestOptions] + Request-specific configuration. + + Returns + ------- + SyncPager[ExperimentListItem, ListExperimentsResponseContent] + Experiments successfully retrieved. + """ + _response = self._client_wrapper.httpx_client.request( + "experimentation/experiments", + method="GET", + params={ + "from": from_, + "take": take, + "status": status, + "authentication_flow": authentication_flow, + "feature_flag_id": feature_flag_id, + }, + request_options=request_options, + ) + try: + if 200 <= _response.status_code < 300: + _parsed_response = typing.cast( + ListExperimentsResponseContent, + parse_obj_as( + type_=ListExperimentsResponseContent, # type: ignore + object_=_response.json(), + ), + ) + _items = _parsed_response.experiments + _parsed_next = _parsed_response.next + _has_next = _parsed_next is not None and _parsed_next != "" + _get_next = lambda: self.list( + from_=_parsed_next, + take=take, + status=status, + authentication_flow=authentication_flow, + feature_flag_id=feature_flag_id, + request_options=request_options, + ) + return SyncPager(has_next=_has_next, items=_items, get_next=_get_next, response=_parsed_response) + if _response.status_code == 400: + raise BadRequestError( + headers=dict(_response.headers), + body=typing.cast( + typing.Any, + parse_obj_as( + type_=typing.Any, # type: ignore + object_=_response.json(), + ), + ), + ) + if _response.status_code == 401: + raise UnauthorizedError( + headers=dict(_response.headers), + body=typing.cast( + typing.Any, + parse_obj_as( + type_=typing.Any, # type: ignore + object_=_response.json(), + ), + ), + ) + if _response.status_code == 403: + raise ForbiddenError( + headers=dict(_response.headers), + body=typing.cast( + typing.Any, + parse_obj_as( + type_=typing.Any, # type: ignore + object_=_response.json(), + ), + ), + ) + if _response.status_code == 429: + raise TooManyRequestsError( + headers=dict(_response.headers), + body=typing.cast( + typing.Any, + parse_obj_as( + type_=typing.Any, # type: ignore + object_=_response.json(), + ), + ), + ) + _response_json = _response.json() + except JSONDecodeError: + raise ApiError(status_code=_response.status_code, headers=dict(_response.headers), body=_response.text) + except ValidationError as e: + raise ParsingError( + status_code=_response.status_code, headers=dict(_response.headers), body=_response.json(), cause=e + ) + raise ApiError(status_code=_response.status_code, headers=dict(_response.headers), body=_response_json) + + def create( + self, + *, + name: str, + feature_flag_id: str, + authentication_flow: AuthenticationFlowEnum, + description: typing.Optional[str] = OMIT, + default_config: typing.Optional[DefaultConfigEnum] = OMIT, + allocation_strategy: typing.Optional[AllocationStrategyEnum] = OMIT, + allocations: typing.Optional[typing.Sequence[AllocationRequestItem]] = OMIT, + levels: typing.Optional[typing.Sequence[int]] = OMIT, + request_options: typing.Optional[RequestOptions] = None, + ) -> HttpResponse[CreateExperimentResponseContent]: + """ + Create a new experiment for A/B testing. + + Parameters + ---------- + name : str + A human-readable name for the experiment + + feature_flag_id : str + The ID of the feature flag this experiment is based on + + authentication_flow : AuthenticationFlowEnum + + description : typing.Optional[str] + A description of the experiment + + default_config : typing.Optional[DefaultConfigEnum] + Applies only to Auth0-managed flags. Controls where non-overridden config keys resolve from: 'tenant' inherits the tenant's live config so the experiment overlays only its changes, 'flag' uses the flag's frozen defaults for a complete config. Optional; defaults to 'tenant' when omitted. Rejected for customer-defined flags. + + allocation_strategy : typing.Optional[AllocationStrategyEnum] + The traffic allocation strategy for this experiment + + allocations : typing.Optional[typing.Sequence[AllocationRequestItem]] + Traffic allocations mapping variations to weights or segments + + levels : typing.Optional[typing.Sequence[int]] + Ramp experiment levels configuration. A strictly-increasing sequence of exposure percentages, each an integer in [0, 100]. + + request_options : typing.Optional[RequestOptions] + Request-specific configuration. + + Returns + ------- + HttpResponse[CreateExperimentResponseContent] + Experiment successfully created. + """ + _response = self._client_wrapper.httpx_client.request( + "experimentation/experiments", + method="POST", + json={ + "name": name, + "description": description, + "feature_flag_id": feature_flag_id, + "authentication_flow": authentication_flow, + "default_config": default_config, + "allocation_strategy": allocation_strategy, + "allocations": convert_and_respect_annotation_metadata( + object_=allocations, annotation=typing.Sequence[AllocationRequestItem], direction="write" + ), + "levels": levels, + }, + headers={ + "content-type": "application/json", + }, + request_options=request_options, + omit=OMIT, + ) + try: + if 200 <= _response.status_code < 300: + _data = typing.cast( + CreateExperimentResponseContent, + parse_obj_as( + type_=CreateExperimentResponseContent, # type: ignore + object_=_response.json(), + ), + ) + return HttpResponse(response=_response, data=_data) + if _response.status_code == 400: + raise BadRequestError( + headers=dict(_response.headers), + body=typing.cast( + typing.Any, + parse_obj_as( + type_=typing.Any, # type: ignore + object_=_response.json(), + ), + ), + ) + if _response.status_code == 401: + raise UnauthorizedError( + headers=dict(_response.headers), + body=typing.cast( + typing.Any, + parse_obj_as( + type_=typing.Any, # type: ignore + object_=_response.json(), + ), + ), + ) + if _response.status_code == 403: + raise ForbiddenError( + headers=dict(_response.headers), + body=typing.cast( + typing.Any, + parse_obj_as( + type_=typing.Any, # type: ignore + object_=_response.json(), + ), + ), + ) + if _response.status_code == 404: + raise NotFoundError( + headers=dict(_response.headers), + body=typing.cast( + typing.Any, + parse_obj_as( + type_=typing.Any, # type: ignore + object_=_response.json(), + ), + ), + ) + if _response.status_code == 409: + raise ConflictError( + headers=dict(_response.headers), + body=typing.cast( + typing.Any, + parse_obj_as( + type_=typing.Any, # type: ignore + object_=_response.json(), + ), + ), + ) + if _response.status_code == 422: + raise UnprocessableEntityError( + headers=dict(_response.headers), + body=typing.cast( + typing.Any, + parse_obj_as( + type_=typing.Any, # type: ignore + object_=_response.json(), + ), + ), + ) + if _response.status_code == 429: + raise TooManyRequestsError( + headers=dict(_response.headers), + body=typing.cast( + typing.Any, + parse_obj_as( + type_=typing.Any, # type: ignore + object_=_response.json(), + ), + ), + ) + _response_json = _response.json() + except JSONDecodeError: + raise ApiError(status_code=_response.status_code, headers=dict(_response.headers), body=_response.text) + except ValidationError as e: + raise ParsingError( + status_code=_response.status_code, headers=dict(_response.headers), body=_response.json(), cause=e + ) + raise ApiError(status_code=_response.status_code, headers=dict(_response.headers), body=_response_json) + + def get( + self, id: str, *, request_options: typing.Optional[RequestOptions] = None + ) -> HttpResponse[GetExperimentResponseContent]: + """ + Retrieve a single experiment with its allocations by ID. + + Parameters + ---------- + id : str + The ID of the experiment to retrieve. + + request_options : typing.Optional[RequestOptions] + Request-specific configuration. + + Returns + ------- + HttpResponse[GetExperimentResponseContent] + Experiment successfully retrieved. + """ + _response = self._client_wrapper.httpx_client.request( + f"experimentation/experiments/{quote_path_param(id)}", + method="GET", + request_options=request_options, + ) + try: + if 200 <= _response.status_code < 300: + _data = typing.cast( + GetExperimentResponseContent, + parse_obj_as( + type_=GetExperimentResponseContent, # type: ignore + object_=_response.json(), + ), + ) + return HttpResponse(response=_response, data=_data) + if _response.status_code == 401: + raise UnauthorizedError( + headers=dict(_response.headers), + body=typing.cast( + typing.Any, + parse_obj_as( + type_=typing.Any, # type: ignore + object_=_response.json(), + ), + ), + ) + if _response.status_code == 403: + raise ForbiddenError( + headers=dict(_response.headers), + body=typing.cast( + typing.Any, + parse_obj_as( + type_=typing.Any, # type: ignore + object_=_response.json(), + ), + ), + ) + if _response.status_code == 404: + raise NotFoundError( + headers=dict(_response.headers), + body=typing.cast( + typing.Any, + parse_obj_as( + type_=typing.Any, # type: ignore + object_=_response.json(), + ), + ), + ) + if _response.status_code == 429: + raise TooManyRequestsError( + headers=dict(_response.headers), + body=typing.cast( + typing.Any, + parse_obj_as( + type_=typing.Any, # type: ignore + object_=_response.json(), + ), + ), + ) + _response_json = _response.json() + except JSONDecodeError: + raise ApiError(status_code=_response.status_code, headers=dict(_response.headers), body=_response.text) + except ValidationError as e: + raise ParsingError( + status_code=_response.status_code, headers=dict(_response.headers), body=_response.json(), cause=e + ) + raise ApiError(status_code=_response.status_code, headers=dict(_response.headers), body=_response_json) + + def delete(self, id: str, *, request_options: typing.Optional[RequestOptions] = None) -> HttpResponse[None]: + """ + Permanently delete an experiment and its allocations by ID. Active experiments cannot be deleted; pause or complete first. Idempotent: returns 204 even if the experiment does not exist. + + Parameters + ---------- + id : str + The ID of the experiment to delete. + + request_options : typing.Optional[RequestOptions] + Request-specific configuration. + + Returns + ------- + HttpResponse[None] + """ + _response = self._client_wrapper.httpx_client.request( + f"experimentation/experiments/{quote_path_param(id)}", + method="DELETE", + request_options=request_options, + ) + try: + if 200 <= _response.status_code < 300: + return HttpResponse(response=_response, data=None) + if _response.status_code == 400: + raise BadRequestError( + headers=dict(_response.headers), + body=typing.cast( + typing.Any, + parse_obj_as( + type_=typing.Any, # type: ignore + object_=_response.json(), + ), + ), + ) + if _response.status_code == 403: + raise ForbiddenError( + headers=dict(_response.headers), + body=typing.cast( + typing.Any, + parse_obj_as( + type_=typing.Any, # type: ignore + object_=_response.json(), + ), + ), + ) + if _response.status_code == 429: + raise TooManyRequestsError( + headers=dict(_response.headers), + body=typing.cast( + typing.Any, + parse_obj_as( + type_=typing.Any, # type: ignore + object_=_response.json(), + ), + ), + ) + _response_json = _response.json() + except JSONDecodeError: + raise ApiError(status_code=_response.status_code, headers=dict(_response.headers), body=_response.text) + except ValidationError as e: + raise ParsingError( + status_code=_response.status_code, headers=dict(_response.headers), body=_response.json(), cause=e + ) + raise ApiError(status_code=_response.status_code, headers=dict(_response.headers), body=_response_json) + + def update( + self, + id: str, + *, + name: typing.Optional[str] = OMIT, + description: typing.Optional[str] = OMIT, + authentication_flow: typing.Optional[AuthenticationFlowEnum] = OMIT, + allocations: typing.Optional[typing.Sequence[AllocationRequestItem]] = OMIT, + default_config: typing.Optional[DefaultConfigEnum] = OMIT, + levels: typing.Optional[typing.Sequence[int]] = OMIT, + request_options: typing.Optional[RequestOptions] = None, + ) -> HttpResponse[UpdateExperimentResponseContent]: + """ + Partially update an experiment by ID. Only provided fields are updated. Providing allocations replaces the entire allocations set. + + Parameters + ---------- + id : str + The ID of the experiment to update. + + name : typing.Optional[str] + A human-readable name for the experiment + + description : typing.Optional[str] + A description of the experiment + + authentication_flow : typing.Optional[AuthenticationFlowEnum] + Specifies the target authentication flow for this experiment. This field can only be modified on draft experiments. Must be one of: authentication, mfa_enrollment, mfa_challenge, password_reset, passkey_enrollment, or all. Note that the all value targets every flow at once, but requires that this is the only active experiment. + + allocations : typing.Optional[typing.Sequence[AllocationRequestItem]] + Replaces all traffic allocations. Cannot be modified while the experiment is active. + + default_config : typing.Optional[DefaultConfigEnum] + Applies only to Auth0-managed flags. Controls where non-overridden config keys resolve from: 'tenant' inherits the tenant's live config, 'flag' uses the flag's frozen defaults. Can only be modified on draft experiments. Rejected for customer-defined flags. + + levels : typing.Optional[typing.Sequence[int]] + Ramp experiment levels configuration. A strictly-increasing sequence of exposure percentages, each an integer in [0, 100]. Can only be modified on draft experiments. + + request_options : typing.Optional[RequestOptions] + Request-specific configuration. + + Returns + ------- + HttpResponse[UpdateExperimentResponseContent] + Experiment successfully updated. + """ + _response = self._client_wrapper.httpx_client.request( + f"experimentation/experiments/{quote_path_param(id)}", + method="PATCH", + json={ + "name": name, + "description": description, + "authentication_flow": authentication_flow, + "allocations": convert_and_respect_annotation_metadata( + object_=allocations, annotation=typing.Sequence[AllocationRequestItem], direction="write" + ), + "default_config": default_config, + "levels": levels, + }, + headers={ + "content-type": "application/json", + }, + request_options=request_options, + omit=OMIT, + ) + try: + if 200 <= _response.status_code < 300: + _data = typing.cast( + UpdateExperimentResponseContent, + parse_obj_as( + type_=UpdateExperimentResponseContent, # type: ignore + object_=_response.json(), + ), + ) + return HttpResponse(response=_response, data=_data) + if _response.status_code == 400: + raise BadRequestError( + headers=dict(_response.headers), + body=typing.cast( + typing.Any, + parse_obj_as( + type_=typing.Any, # type: ignore + object_=_response.json(), + ), + ), + ) + if _response.status_code == 401: + raise UnauthorizedError( + headers=dict(_response.headers), + body=typing.cast( + typing.Any, + parse_obj_as( + type_=typing.Any, # type: ignore + object_=_response.json(), + ), + ), + ) + if _response.status_code == 403: + raise ForbiddenError( + headers=dict(_response.headers), + body=typing.cast( + typing.Any, + parse_obj_as( + type_=typing.Any, # type: ignore + object_=_response.json(), + ), + ), + ) + if _response.status_code == 404: + raise NotFoundError( + headers=dict(_response.headers), + body=typing.cast( + typing.Any, + parse_obj_as( + type_=typing.Any, # type: ignore + object_=_response.json(), + ), + ), + ) + if _response.status_code == 409: + raise ConflictError( + headers=dict(_response.headers), + body=typing.cast( + typing.Any, + parse_obj_as( + type_=typing.Any, # type: ignore + object_=_response.json(), + ), + ), + ) + if _response.status_code == 422: + raise UnprocessableEntityError( + headers=dict(_response.headers), + body=typing.cast( + typing.Any, + parse_obj_as( + type_=typing.Any, # type: ignore + object_=_response.json(), + ), + ), + ) + if _response.status_code == 429: + raise TooManyRequestsError( + headers=dict(_response.headers), + body=typing.cast( + typing.Any, + parse_obj_as( + type_=typing.Any, # type: ignore + object_=_response.json(), + ), + ), + ) + _response_json = _response.json() + except JSONDecodeError: + raise ApiError(status_code=_response.status_code, headers=dict(_response.headers), body=_response.text) + except ValidationError as e: + raise ParsingError( + status_code=_response.status_code, headers=dict(_response.headers), body=_response.json(), cause=e + ) + raise ApiError(status_code=_response.status_code, headers=dict(_response.headers), body=_response_json) + def advance_ramp( self, id: str, *, target_level: int, request_options: typing.Optional[RequestOptions] = None ) -> HttpResponse[AdvanceRampResponseContent]: """ - Increments the current ramp index to the requested target level. Up-only: the target must be the immediate next level in the schedule. Idempotent: calling with the current level returns success without writing anything. + Increments the current ramp index to the requested target level. Up-only: the target must be the immediate next level in the schedule. Idempotent: calling with the current level returns success without writing anything. + + Parameters + ---------- + id : str + The ID of the experiment to advance. + + target_level : int + The target percentage level from the experiment schedule. Must be the immediate next level. + + request_options : typing.Optional[RequestOptions] + Request-specific configuration. + + Returns + ------- + HttpResponse[AdvanceRampResponseContent] + Ramp advanced successfully. + """ + _response = self._client_wrapper.httpx_client.request( + f"experimentation/experiments/{quote_path_param(id)}/advance-ramp", + method="POST", + json={ + "target_level": target_level, + }, + headers={ + "content-type": "application/json", + }, + request_options=request_options, + omit=OMIT, + ) + try: + if 200 <= _response.status_code < 300: + _data = typing.cast( + AdvanceRampResponseContent, + parse_obj_as( + type_=AdvanceRampResponseContent, # type: ignore + object_=_response.json(), + ), + ) + return HttpResponse(response=_response, data=_data) + if _response.status_code == 400: + raise BadRequestError( + headers=dict(_response.headers), + body=typing.cast( + typing.Any, + parse_obj_as( + type_=typing.Any, # type: ignore + object_=_response.json(), + ), + ), + ) + if _response.status_code == 401: + raise UnauthorizedError( + headers=dict(_response.headers), + body=typing.cast( + typing.Any, + parse_obj_as( + type_=typing.Any, # type: ignore + object_=_response.json(), + ), + ), + ) + if _response.status_code == 403: + raise ForbiddenError( + headers=dict(_response.headers), + body=typing.cast( + typing.Any, + parse_obj_as( + type_=typing.Any, # type: ignore + object_=_response.json(), + ), + ), + ) + if _response.status_code == 404: + raise NotFoundError( + headers=dict(_response.headers), + body=typing.cast( + typing.Any, + parse_obj_as( + type_=typing.Any, # type: ignore + object_=_response.json(), + ), + ), + ) + if _response.status_code == 409: + raise ConflictError( + headers=dict(_response.headers), + body=typing.cast( + typing.Any, + parse_obj_as( + type_=typing.Any, # type: ignore + object_=_response.json(), + ), + ), + ) + if _response.status_code == 429: + raise TooManyRequestsError( + headers=dict(_response.headers), + body=typing.cast( + typing.Any, + parse_obj_as( + type_=typing.Any, # type: ignore + object_=_response.json(), + ), + ), + ) + _response_json = _response.json() + except JSONDecodeError: + raise ApiError(status_code=_response.status_code, headers=dict(_response.headers), body=_response.text) + except ValidationError as e: + raise ParsingError( + status_code=_response.status_code, headers=dict(_response.headers), body=_response.json(), cause=e + ) + raise ApiError(status_code=_response.status_code, headers=dict(_response.headers), body=_response_json) + + def update_status( + self, + id: str, + *, + status: ExperimentTransitionStatusEnum, + request_options: typing.Optional[RequestOptions] = None, + ) -> HttpResponse[UpdateExperimentStatusResponseContent]: + """ + Transitions an experiment through its lifecycle: draft → active, active → paused, paused → active, active/paused → completed. Activation runs full readiness validation. + + Parameters + ---------- + id : str + The ID of the experiment to transition. + + status : ExperimentTransitionStatusEnum + + request_options : typing.Optional[RequestOptions] + Request-specific configuration. + + Returns + ------- + HttpResponse[UpdateExperimentStatusResponseContent] + Experiment status successfully updated. + """ + _response = self._client_wrapper.httpx_client.request( + f"experimentation/experiments/{quote_path_param(id)}/status", + method="POST", + json={ + "status": status, + }, + headers={ + "content-type": "application/json", + }, + request_options=request_options, + omit=OMIT, + ) + try: + if 200 <= _response.status_code < 300: + _data = typing.cast( + UpdateExperimentStatusResponseContent, + parse_obj_as( + type_=UpdateExperimentStatusResponseContent, # type: ignore + object_=_response.json(), + ), + ) + return HttpResponse(response=_response, data=_data) + if _response.status_code == 400: + raise BadRequestError( + headers=dict(_response.headers), + body=typing.cast( + typing.Any, + parse_obj_as( + type_=typing.Any, # type: ignore + object_=_response.json(), + ), + ), + ) + if _response.status_code == 401: + raise UnauthorizedError( + headers=dict(_response.headers), + body=typing.cast( + typing.Any, + parse_obj_as( + type_=typing.Any, # type: ignore + object_=_response.json(), + ), + ), + ) + if _response.status_code == 403: + raise ForbiddenError( + headers=dict(_response.headers), + body=typing.cast( + typing.Any, + parse_obj_as( + type_=typing.Any, # type: ignore + object_=_response.json(), + ), + ), + ) + if _response.status_code == 404: + raise NotFoundError( + headers=dict(_response.headers), + body=typing.cast( + typing.Any, + parse_obj_as( + type_=typing.Any, # type: ignore + object_=_response.json(), + ), + ), + ) + if _response.status_code == 409: + raise ConflictError( + headers=dict(_response.headers), + body=typing.cast( + typing.Any, + parse_obj_as( + type_=typing.Any, # type: ignore + object_=_response.json(), + ), + ), + ) + if _response.status_code == 422: + raise UnprocessableEntityError( + headers=dict(_response.headers), + body=typing.cast( + typing.Any, + parse_obj_as( + type_=typing.Any, # type: ignore + object_=_response.json(), + ), + ), + ) + if _response.status_code == 429: + raise TooManyRequestsError( + headers=dict(_response.headers), + body=typing.cast( + typing.Any, + parse_obj_as( + type_=typing.Any, # type: ignore + object_=_response.json(), + ), + ), + ) + _response_json = _response.json() + except JSONDecodeError: + raise ApiError(status_code=_response.status_code, headers=dict(_response.headers), body=_response.text) + except ValidationError as e: + raise ParsingError( + status_code=_response.status_code, headers=dict(_response.headers), body=_response.json(), cause=e + ) + raise ApiError(status_code=_response.status_code, headers=dict(_response.headers), body=_response_json) + + def validate( + self, id: str, *, request_options: typing.Optional[RequestOptions] = None + ) -> HttpResponse[ValidateExperimentResponseContent]: + """ + Checks whether an experiment is ready to be activated. Returns is_valid boolean and an errors array describing any blockers. Read-only; no state is modified. + + Parameters + ---------- + id : str + The ID of the experiment to validate. + + request_options : typing.Optional[RequestOptions] + Request-specific configuration. + + Returns + ------- + HttpResponse[ValidateExperimentResponseContent] + Experiment validation result returned. + """ + _response = self._client_wrapper.httpx_client.request( + f"experimentation/experiments/{quote_path_param(id)}/validate", + method="POST", + request_options=request_options, + ) + try: + if 200 <= _response.status_code < 300: + _data = typing.cast( + ValidateExperimentResponseContent, + parse_obj_as( + type_=ValidateExperimentResponseContent, # type: ignore + object_=_response.json(), + ), + ) + return HttpResponse(response=_response, data=_data) + if _response.status_code == 401: + raise UnauthorizedError( + headers=dict(_response.headers), + body=typing.cast( + typing.Any, + parse_obj_as( + type_=typing.Any, # type: ignore + object_=_response.json(), + ), + ), + ) + if _response.status_code == 403: + raise ForbiddenError( + headers=dict(_response.headers), + body=typing.cast( + typing.Any, + parse_obj_as( + type_=typing.Any, # type: ignore + object_=_response.json(), + ), + ), + ) + if _response.status_code == 404: + raise NotFoundError( + headers=dict(_response.headers), + body=typing.cast( + typing.Any, + parse_obj_as( + type_=typing.Any, # type: ignore + object_=_response.json(), + ), + ), + ) + if _response.status_code == 429: + raise TooManyRequestsError( + headers=dict(_response.headers), + body=typing.cast( + typing.Any, + parse_obj_as( + type_=typing.Any, # type: ignore + object_=_response.json(), + ), + ), + ) + _response_json = _response.json() + except JSONDecodeError: + raise ApiError(status_code=_response.status_code, headers=dict(_response.headers), body=_response.text) + except ValidationError as e: + raise ParsingError( + status_code=_response.status_code, headers=dict(_response.headers), body=_response.json(), cause=e + ) + raise ApiError(status_code=_response.status_code, headers=dict(_response.headers), body=_response_json) + + +class AsyncRawExperimentsClient: + def __init__(self, *, client_wrapper: AsyncClientWrapper): + self._client_wrapper = client_wrapper + + async def list( + self, + *, + from_: typing.Optional[str] = None, + take: typing.Optional[int] = 50, + status: typing.Optional[ExperimentStatusEnum] = None, + authentication_flow: typing.Optional[str] = None, + feature_flag_id: typing.Optional[str] = None, + request_options: typing.Optional[RequestOptions] = None, + ) -> AsyncPager[ExperimentListItem, ListExperimentsResponseContent]: + """ + Retrieve a paginated list of experiments for the tenant, with optional filters. + + Parameters + ---------- + from_ : typing.Optional[str] + Optional Id from which to start selection. + + take : typing.Optional[int] + Number of experiments to return per page. Defaults to 25, maximum 50. + + status : typing.Optional[ExperimentStatusEnum] + Filter by status. Exact match. + + authentication_flow : typing.Optional[str] + Filter by authentication flow. Exact match. + + feature_flag_id : typing.Optional[str] + Filter by feature flag ID. Exact match. + + request_options : typing.Optional[RequestOptions] + Request-specific configuration. + + Returns + ------- + AsyncPager[ExperimentListItem, ListExperimentsResponseContent] + Experiments successfully retrieved. + """ + _response = await self._client_wrapper.httpx_client.request( + "experimentation/experiments", + method="GET", + params={ + "from": from_, + "take": take, + "status": status, + "authentication_flow": authentication_flow, + "feature_flag_id": feature_flag_id, + }, + request_options=request_options, + ) + try: + if 200 <= _response.status_code < 300: + _parsed_response = typing.cast( + ListExperimentsResponseContent, + parse_obj_as( + type_=ListExperimentsResponseContent, # type: ignore + object_=_response.json(), + ), + ) + _items = _parsed_response.experiments + _parsed_next = _parsed_response.next + _has_next = _parsed_next is not None and _parsed_next != "" + + async def _get_next(): + return await self.list( + from_=_parsed_next, + take=take, + status=status, + authentication_flow=authentication_flow, + feature_flag_id=feature_flag_id, + request_options=request_options, + ) + + return AsyncPager(has_next=_has_next, items=_items, get_next=_get_next, response=_parsed_response) + if _response.status_code == 400: + raise BadRequestError( + headers=dict(_response.headers), + body=typing.cast( + typing.Any, + parse_obj_as( + type_=typing.Any, # type: ignore + object_=_response.json(), + ), + ), + ) + if _response.status_code == 401: + raise UnauthorizedError( + headers=dict(_response.headers), + body=typing.cast( + typing.Any, + parse_obj_as( + type_=typing.Any, # type: ignore + object_=_response.json(), + ), + ), + ) + if _response.status_code == 403: + raise ForbiddenError( + headers=dict(_response.headers), + body=typing.cast( + typing.Any, + parse_obj_as( + type_=typing.Any, # type: ignore + object_=_response.json(), + ), + ), + ) + if _response.status_code == 429: + raise TooManyRequestsError( + headers=dict(_response.headers), + body=typing.cast( + typing.Any, + parse_obj_as( + type_=typing.Any, # type: ignore + object_=_response.json(), + ), + ), + ) + _response_json = _response.json() + except JSONDecodeError: + raise ApiError(status_code=_response.status_code, headers=dict(_response.headers), body=_response.text) + except ValidationError as e: + raise ParsingError( + status_code=_response.status_code, headers=dict(_response.headers), body=_response.json(), cause=e + ) + raise ApiError(status_code=_response.status_code, headers=dict(_response.headers), body=_response_json) + + async def create( + self, + *, + name: str, + feature_flag_id: str, + authentication_flow: AuthenticationFlowEnum, + description: typing.Optional[str] = OMIT, + default_config: typing.Optional[DefaultConfigEnum] = OMIT, + allocation_strategy: typing.Optional[AllocationStrategyEnum] = OMIT, + allocations: typing.Optional[typing.Sequence[AllocationRequestItem]] = OMIT, + levels: typing.Optional[typing.Sequence[int]] = OMIT, + request_options: typing.Optional[RequestOptions] = None, + ) -> AsyncHttpResponse[CreateExperimentResponseContent]: + """ + Create a new experiment for A/B testing. + + Parameters + ---------- + name : str + A human-readable name for the experiment + + feature_flag_id : str + The ID of the feature flag this experiment is based on + + authentication_flow : AuthenticationFlowEnum + + description : typing.Optional[str] + A description of the experiment + + default_config : typing.Optional[DefaultConfigEnum] + Applies only to Auth0-managed flags. Controls where non-overridden config keys resolve from: 'tenant' inherits the tenant's live config so the experiment overlays only its changes, 'flag' uses the flag's frozen defaults for a complete config. Optional; defaults to 'tenant' when omitted. Rejected for customer-defined flags. + + allocation_strategy : typing.Optional[AllocationStrategyEnum] + The traffic allocation strategy for this experiment + + allocations : typing.Optional[typing.Sequence[AllocationRequestItem]] + Traffic allocations mapping variations to weights or segments + + levels : typing.Optional[typing.Sequence[int]] + Ramp experiment levels configuration. A strictly-increasing sequence of exposure percentages, each an integer in [0, 100]. + + request_options : typing.Optional[RequestOptions] + Request-specific configuration. + + Returns + ------- + AsyncHttpResponse[CreateExperimentResponseContent] + Experiment successfully created. + """ + _response = await self._client_wrapper.httpx_client.request( + "experimentation/experiments", + method="POST", + json={ + "name": name, + "description": description, + "feature_flag_id": feature_flag_id, + "authentication_flow": authentication_flow, + "default_config": default_config, + "allocation_strategy": allocation_strategy, + "allocations": convert_and_respect_annotation_metadata( + object_=allocations, annotation=typing.Sequence[AllocationRequestItem], direction="write" + ), + "levels": levels, + }, + headers={ + "content-type": "application/json", + }, + request_options=request_options, + omit=OMIT, + ) + try: + if 200 <= _response.status_code < 300: + _data = typing.cast( + CreateExperimentResponseContent, + parse_obj_as( + type_=CreateExperimentResponseContent, # type: ignore + object_=_response.json(), + ), + ) + return AsyncHttpResponse(response=_response, data=_data) + if _response.status_code == 400: + raise BadRequestError( + headers=dict(_response.headers), + body=typing.cast( + typing.Any, + parse_obj_as( + type_=typing.Any, # type: ignore + object_=_response.json(), + ), + ), + ) + if _response.status_code == 401: + raise UnauthorizedError( + headers=dict(_response.headers), + body=typing.cast( + typing.Any, + parse_obj_as( + type_=typing.Any, # type: ignore + object_=_response.json(), + ), + ), + ) + if _response.status_code == 403: + raise ForbiddenError( + headers=dict(_response.headers), + body=typing.cast( + typing.Any, + parse_obj_as( + type_=typing.Any, # type: ignore + object_=_response.json(), + ), + ), + ) + if _response.status_code == 404: + raise NotFoundError( + headers=dict(_response.headers), + body=typing.cast( + typing.Any, + parse_obj_as( + type_=typing.Any, # type: ignore + object_=_response.json(), + ), + ), + ) + if _response.status_code == 409: + raise ConflictError( + headers=dict(_response.headers), + body=typing.cast( + typing.Any, + parse_obj_as( + type_=typing.Any, # type: ignore + object_=_response.json(), + ), + ), + ) + if _response.status_code == 422: + raise UnprocessableEntityError( + headers=dict(_response.headers), + body=typing.cast( + typing.Any, + parse_obj_as( + type_=typing.Any, # type: ignore + object_=_response.json(), + ), + ), + ) + if _response.status_code == 429: + raise TooManyRequestsError( + headers=dict(_response.headers), + body=typing.cast( + typing.Any, + parse_obj_as( + type_=typing.Any, # type: ignore + object_=_response.json(), + ), + ), + ) + _response_json = _response.json() + except JSONDecodeError: + raise ApiError(status_code=_response.status_code, headers=dict(_response.headers), body=_response.text) + except ValidationError as e: + raise ParsingError( + status_code=_response.status_code, headers=dict(_response.headers), body=_response.json(), cause=e + ) + raise ApiError(status_code=_response.status_code, headers=dict(_response.headers), body=_response_json) + + async def get( + self, id: str, *, request_options: typing.Optional[RequestOptions] = None + ) -> AsyncHttpResponse[GetExperimentResponseContent]: + """ + Retrieve a single experiment with its allocations by ID. + + Parameters + ---------- + id : str + The ID of the experiment to retrieve. + + request_options : typing.Optional[RequestOptions] + Request-specific configuration. + + Returns + ------- + AsyncHttpResponse[GetExperimentResponseContent] + Experiment successfully retrieved. + """ + _response = await self._client_wrapper.httpx_client.request( + f"experimentation/experiments/{quote_path_param(id)}", + method="GET", + request_options=request_options, + ) + try: + if 200 <= _response.status_code < 300: + _data = typing.cast( + GetExperimentResponseContent, + parse_obj_as( + type_=GetExperimentResponseContent, # type: ignore + object_=_response.json(), + ), + ) + return AsyncHttpResponse(response=_response, data=_data) + if _response.status_code == 401: + raise UnauthorizedError( + headers=dict(_response.headers), + body=typing.cast( + typing.Any, + parse_obj_as( + type_=typing.Any, # type: ignore + object_=_response.json(), + ), + ), + ) + if _response.status_code == 403: + raise ForbiddenError( + headers=dict(_response.headers), + body=typing.cast( + typing.Any, + parse_obj_as( + type_=typing.Any, # type: ignore + object_=_response.json(), + ), + ), + ) + if _response.status_code == 404: + raise NotFoundError( + headers=dict(_response.headers), + body=typing.cast( + typing.Any, + parse_obj_as( + type_=typing.Any, # type: ignore + object_=_response.json(), + ), + ), + ) + if _response.status_code == 429: + raise TooManyRequestsError( + headers=dict(_response.headers), + body=typing.cast( + typing.Any, + parse_obj_as( + type_=typing.Any, # type: ignore + object_=_response.json(), + ), + ), + ) + _response_json = _response.json() + except JSONDecodeError: + raise ApiError(status_code=_response.status_code, headers=dict(_response.headers), body=_response.text) + except ValidationError as e: + raise ParsingError( + status_code=_response.status_code, headers=dict(_response.headers), body=_response.json(), cause=e + ) + raise ApiError(status_code=_response.status_code, headers=dict(_response.headers), body=_response_json) + + async def delete( + self, id: str, *, request_options: typing.Optional[RequestOptions] = None + ) -> AsyncHttpResponse[None]: + """ + Permanently delete an experiment and its allocations by ID. Active experiments cannot be deleted; pause or complete first. Idempotent: returns 204 even if the experiment does not exist. + + Parameters + ---------- + id : str + The ID of the experiment to delete. + + request_options : typing.Optional[RequestOptions] + Request-specific configuration. + + Returns + ------- + AsyncHttpResponse[None] + """ + _response = await self._client_wrapper.httpx_client.request( + f"experimentation/experiments/{quote_path_param(id)}", + method="DELETE", + request_options=request_options, + ) + try: + if 200 <= _response.status_code < 300: + return AsyncHttpResponse(response=_response, data=None) + if _response.status_code == 400: + raise BadRequestError( + headers=dict(_response.headers), + body=typing.cast( + typing.Any, + parse_obj_as( + type_=typing.Any, # type: ignore + object_=_response.json(), + ), + ), + ) + if _response.status_code == 403: + raise ForbiddenError( + headers=dict(_response.headers), + body=typing.cast( + typing.Any, + parse_obj_as( + type_=typing.Any, # type: ignore + object_=_response.json(), + ), + ), + ) + if _response.status_code == 429: + raise TooManyRequestsError( + headers=dict(_response.headers), + body=typing.cast( + typing.Any, + parse_obj_as( + type_=typing.Any, # type: ignore + object_=_response.json(), + ), + ), + ) + _response_json = _response.json() + except JSONDecodeError: + raise ApiError(status_code=_response.status_code, headers=dict(_response.headers), body=_response.text) + except ValidationError as e: + raise ParsingError( + status_code=_response.status_code, headers=dict(_response.headers), body=_response.json(), cause=e + ) + raise ApiError(status_code=_response.status_code, headers=dict(_response.headers), body=_response_json) + + async def update( + self, + id: str, + *, + name: typing.Optional[str] = OMIT, + description: typing.Optional[str] = OMIT, + authentication_flow: typing.Optional[AuthenticationFlowEnum] = OMIT, + allocations: typing.Optional[typing.Sequence[AllocationRequestItem]] = OMIT, + default_config: typing.Optional[DefaultConfigEnum] = OMIT, + levels: typing.Optional[typing.Sequence[int]] = OMIT, + request_options: typing.Optional[RequestOptions] = None, + ) -> AsyncHttpResponse[UpdateExperimentResponseContent]: + """ + Partially update an experiment by ID. Only provided fields are updated. Providing allocations replaces the entire allocations set. Parameters ---------- id : str - The ID of the experiment to advance. + The ID of the experiment to update. - target_level : int - The target percentage level from the experiment schedule. Must be the immediate next level. + name : typing.Optional[str] + A human-readable name for the experiment + + description : typing.Optional[str] + A description of the experiment + + authentication_flow : typing.Optional[AuthenticationFlowEnum] + Specifies the target authentication flow for this experiment. This field can only be modified on draft experiments. Must be one of: authentication, mfa_enrollment, mfa_challenge, password_reset, passkey_enrollment, or all. Note that the all value targets every flow at once, but requires that this is the only active experiment. + + allocations : typing.Optional[typing.Sequence[AllocationRequestItem]] + Replaces all traffic allocations. Cannot be modified while the experiment is active. + + default_config : typing.Optional[DefaultConfigEnum] + Applies only to Auth0-managed flags. Controls where non-overridden config keys resolve from: 'tenant' inherits the tenant's live config, 'flag' uses the flag's frozen defaults. Can only be modified on draft experiments. Rejected for customer-defined flags. + + levels : typing.Optional[typing.Sequence[int]] + Ramp experiment levels configuration. A strictly-increasing sequence of exposure percentages, each an integer in [0, 100]. Can only be modified on draft experiments. request_options : typing.Optional[RequestOptions] Request-specific configuration. Returns ------- - HttpResponse[AdvanceRampResponseContent] - Ramp advanced successfully. + AsyncHttpResponse[UpdateExperimentResponseContent] + Experiment successfully updated. """ - _response = self._client_wrapper.httpx_client.request( - f"experimentation/experiments/{quote_path_param(id)}/advance-ramp", - method="POST", + _response = await self._client_wrapper.httpx_client.request( + f"experimentation/experiments/{quote_path_param(id)}", + method="PATCH", json={ - "target_level": target_level, + "name": name, + "description": description, + "authentication_flow": authentication_flow, + "allocations": convert_and_respect_annotation_metadata( + object_=allocations, annotation=typing.Sequence[AllocationRequestItem], direction="write" + ), + "default_config": default_config, + "levels": levels, }, headers={ "content-type": "application/json", @@ -64,13 +1507,13 @@ def advance_ramp( try: if 200 <= _response.status_code < 300: _data = typing.cast( - AdvanceRampResponseContent, + UpdateExperimentResponseContent, parse_obj_as( - type_=AdvanceRampResponseContent, # type: ignore + type_=UpdateExperimentResponseContent, # type: ignore object_=_response.json(), ), ) - return HttpResponse(response=_response, data=_data) + return AsyncHttpResponse(response=_response, data=_data) if _response.status_code == 400: raise BadRequestError( headers=dict(_response.headers), @@ -126,6 +1569,17 @@ def advance_ramp( ), ), ) + if _response.status_code == 422: + raise UnprocessableEntityError( + headers=dict(_response.headers), + body=typing.cast( + typing.Any, + parse_obj_as( + type_=typing.Any, # type: ignore + object_=_response.json(), + ), + ), + ) if _response.status_code == 429: raise TooManyRequestsError( headers=dict(_response.headers), @@ -146,11 +1600,6 @@ def advance_ramp( ) raise ApiError(status_code=_response.status_code, headers=dict(_response.headers), body=_response_json) - -class AsyncRawExperimentsClient: - def __init__(self, *, client_wrapper: AsyncClientWrapper): - self._client_wrapper = client_wrapper - async def advance_ramp( self, id: str, *, target_level: int, request_options: typing.Optional[RequestOptions] = None ) -> AsyncHttpResponse[AdvanceRampResponseContent]: @@ -269,3 +1718,223 @@ async def advance_ramp( status_code=_response.status_code, headers=dict(_response.headers), body=_response.json(), cause=e ) raise ApiError(status_code=_response.status_code, headers=dict(_response.headers), body=_response_json) + + async def update_status( + self, + id: str, + *, + status: ExperimentTransitionStatusEnum, + request_options: typing.Optional[RequestOptions] = None, + ) -> AsyncHttpResponse[UpdateExperimentStatusResponseContent]: + """ + Transitions an experiment through its lifecycle: draft → active, active → paused, paused → active, active/paused → completed. Activation runs full readiness validation. + + Parameters + ---------- + id : str + The ID of the experiment to transition. + + status : ExperimentTransitionStatusEnum + + request_options : typing.Optional[RequestOptions] + Request-specific configuration. + + Returns + ------- + AsyncHttpResponse[UpdateExperimentStatusResponseContent] + Experiment status successfully updated. + """ + _response = await self._client_wrapper.httpx_client.request( + f"experimentation/experiments/{quote_path_param(id)}/status", + method="POST", + json={ + "status": status, + }, + headers={ + "content-type": "application/json", + }, + request_options=request_options, + omit=OMIT, + ) + try: + if 200 <= _response.status_code < 300: + _data = typing.cast( + UpdateExperimentStatusResponseContent, + parse_obj_as( + type_=UpdateExperimentStatusResponseContent, # type: ignore + object_=_response.json(), + ), + ) + return AsyncHttpResponse(response=_response, data=_data) + if _response.status_code == 400: + raise BadRequestError( + headers=dict(_response.headers), + body=typing.cast( + typing.Any, + parse_obj_as( + type_=typing.Any, # type: ignore + object_=_response.json(), + ), + ), + ) + if _response.status_code == 401: + raise UnauthorizedError( + headers=dict(_response.headers), + body=typing.cast( + typing.Any, + parse_obj_as( + type_=typing.Any, # type: ignore + object_=_response.json(), + ), + ), + ) + if _response.status_code == 403: + raise ForbiddenError( + headers=dict(_response.headers), + body=typing.cast( + typing.Any, + parse_obj_as( + type_=typing.Any, # type: ignore + object_=_response.json(), + ), + ), + ) + if _response.status_code == 404: + raise NotFoundError( + headers=dict(_response.headers), + body=typing.cast( + typing.Any, + parse_obj_as( + type_=typing.Any, # type: ignore + object_=_response.json(), + ), + ), + ) + if _response.status_code == 409: + raise ConflictError( + headers=dict(_response.headers), + body=typing.cast( + typing.Any, + parse_obj_as( + type_=typing.Any, # type: ignore + object_=_response.json(), + ), + ), + ) + if _response.status_code == 422: + raise UnprocessableEntityError( + headers=dict(_response.headers), + body=typing.cast( + typing.Any, + parse_obj_as( + type_=typing.Any, # type: ignore + object_=_response.json(), + ), + ), + ) + if _response.status_code == 429: + raise TooManyRequestsError( + headers=dict(_response.headers), + body=typing.cast( + typing.Any, + parse_obj_as( + type_=typing.Any, # type: ignore + object_=_response.json(), + ), + ), + ) + _response_json = _response.json() + except JSONDecodeError: + raise ApiError(status_code=_response.status_code, headers=dict(_response.headers), body=_response.text) + except ValidationError as e: + raise ParsingError( + status_code=_response.status_code, headers=dict(_response.headers), body=_response.json(), cause=e + ) + raise ApiError(status_code=_response.status_code, headers=dict(_response.headers), body=_response_json) + + async def validate( + self, id: str, *, request_options: typing.Optional[RequestOptions] = None + ) -> AsyncHttpResponse[ValidateExperimentResponseContent]: + """ + Checks whether an experiment is ready to be activated. Returns is_valid boolean and an errors array describing any blockers. Read-only; no state is modified. + + Parameters + ---------- + id : str + The ID of the experiment to validate. + + request_options : typing.Optional[RequestOptions] + Request-specific configuration. + + Returns + ------- + AsyncHttpResponse[ValidateExperimentResponseContent] + Experiment validation result returned. + """ + _response = await self._client_wrapper.httpx_client.request( + f"experimentation/experiments/{quote_path_param(id)}/validate", + method="POST", + request_options=request_options, + ) + try: + if 200 <= _response.status_code < 300: + _data = typing.cast( + ValidateExperimentResponseContent, + parse_obj_as( + type_=ValidateExperimentResponseContent, # type: ignore + object_=_response.json(), + ), + ) + return AsyncHttpResponse(response=_response, data=_data) + if _response.status_code == 401: + raise UnauthorizedError( + headers=dict(_response.headers), + body=typing.cast( + typing.Any, + parse_obj_as( + type_=typing.Any, # type: ignore + object_=_response.json(), + ), + ), + ) + if _response.status_code == 403: + raise ForbiddenError( + headers=dict(_response.headers), + body=typing.cast( + typing.Any, + parse_obj_as( + type_=typing.Any, # type: ignore + object_=_response.json(), + ), + ), + ) + if _response.status_code == 404: + raise NotFoundError( + headers=dict(_response.headers), + body=typing.cast( + typing.Any, + parse_obj_as( + type_=typing.Any, # type: ignore + object_=_response.json(), + ), + ), + ) + if _response.status_code == 429: + raise TooManyRequestsError( + headers=dict(_response.headers), + body=typing.cast( + typing.Any, + parse_obj_as( + type_=typing.Any, # type: ignore + object_=_response.json(), + ), + ), + ) + _response_json = _response.json() + except JSONDecodeError: + raise ApiError(status_code=_response.status_code, headers=dict(_response.headers), body=_response.text) + except ValidationError as e: + raise ParsingError( + status_code=_response.status_code, headers=dict(_response.headers), body=_response.json(), cause=e + ) + raise ApiError(status_code=_response.status_code, headers=dict(_response.headers), body=_response_json) diff --git a/src/auth0/management/experimentation/feature_flags/__init__.py b/src/auth0/management/experimentation/feature_flags/__init__.py new file mode 100644 index 00000000..8b4c9653 --- /dev/null +++ b/src/auth0/management/experimentation/feature_flags/__init__.py @@ -0,0 +1,34 @@ +# This file was auto-generated by Fern from our API Definition. + +# isort: skip_file + +import typing +from importlib import import_module + +if typing.TYPE_CHECKING: + from . import variations +_dynamic_imports: typing.Dict[str, str] = {"variations": ".variations"} + + +def __getattr__(attr_name: str) -> typing.Any: + module_name = _dynamic_imports.get(attr_name) + if module_name is None: + raise AttributeError(f"No {attr_name} found in _dynamic_imports for module name -> {__name__}") + try: + module = import_module(module_name, __package__) + if module_name == f".{attr_name}": + return module + else: + return getattr(module, attr_name) + except ImportError as e: + raise ImportError(f"Failed to import {attr_name} from {module_name}: {e}") from e + except AttributeError as e: + raise AttributeError(f"Failed to get {attr_name} from {module_name}: {e}") from e + + +def __dir__(): + lazy_attrs = list(_dynamic_imports.keys()) + return sorted(lazy_attrs) + + +__all__ = ["variations"] diff --git a/src/auth0/management/experimentation/feature_flags/client.py b/src/auth0/management/experimentation/feature_flags/client.py new file mode 100644 index 00000000..da6ac727 --- /dev/null +++ b/src/auth0/management/experimentation/feature_flags/client.py @@ -0,0 +1,626 @@ +# This file was auto-generated by Fern from our API Definition. + +from __future__ import annotations + +import typing + +from ...core.client_wrapper import AsyncClientWrapper, SyncClientWrapper +from ...core.pagination import AsyncPager, SyncPager +from ...core.request_options import RequestOptions +from ...types.create_feature_flag_parameters import CreateFeatureFlagParameters +from ...types.create_feature_flag_response_content import CreateFeatureFlagResponseContent +from ...types.feature_flag import FeatureFlag +from ...types.feature_flag_status_enum import FeatureFlagStatusEnum +from ...types.feature_flag_type_enum import FeatureFlagTypeEnum +from ...types.get_feature_flag_response_content import GetFeatureFlagResponseContent +from ...types.list_feature_flags_response_content import ListFeatureFlagsResponseContent +from ...types.update_feature_flag_parameters import UpdateFeatureFlagParameters +from ...types.update_feature_flag_response_content import UpdateFeatureFlagResponseContent +from ...types.update_feature_flag_status_response_content import UpdateFeatureFlagStatusResponseContent +from .raw_client import AsyncRawFeatureFlagsClient, RawFeatureFlagsClient + +if typing.TYPE_CHECKING: + from .variations.client import AsyncVariationsClient, VariationsClient +# this is used as the default value for optional parameters +OMIT = typing.cast(typing.Any, ...) + + +class FeatureFlagsClient: + def __init__(self, *, client_wrapper: SyncClientWrapper): + self._raw_client = RawFeatureFlagsClient(client_wrapper=client_wrapper) + self._client_wrapper = client_wrapper + self._variations: typing.Optional[VariationsClient] = None + + @property + def with_raw_response(self) -> RawFeatureFlagsClient: + """ + Retrieves a raw implementation of this client that returns raw responses. + + Returns + ------- + RawFeatureFlagsClient + """ + return self._raw_client + + def list( + self, + *, + from_: typing.Optional[str] = None, + take: typing.Optional[int] = 50, + type: typing.Optional[FeatureFlagTypeEnum] = None, + status: typing.Optional[FeatureFlagStatusEnum] = None, + request_options: typing.Optional[RequestOptions] = None, + ) -> SyncPager[FeatureFlag, ListFeatureFlagsResponseContent]: + """ + Retrieve a paginated list of feature flags for the tenant. + + Parameters + ---------- + from_ : typing.Optional[str] + Optional Id from which to start selection. + + take : typing.Optional[int] + Number of feature flags to return per page. Defaults to 25, maximum 50. + + type : typing.Optional[FeatureFlagTypeEnum] + Filter by type. Exact match. + + status : typing.Optional[FeatureFlagStatusEnum] + Filter by status. Exact match. + + request_options : typing.Optional[RequestOptions] + Request-specific configuration. + + Returns + ------- + SyncPager[FeatureFlag, ListFeatureFlagsResponseContent] + Feature flags successfully retrieved. + + Examples + -------- + from auth0 import Auth0 + + client = Auth0( + token="YOUR_TOKEN", + ) + response = client.experimentation.feature_flags.list( + from_="from", + take=1, + type="auth0", + status="draft", + ) + for item in response: + yield item + # alternatively, you can paginate page-by-page + for page in response.iter_pages(): + yield page + """ + return self._raw_client.list(from_=from_, take=take, type=type, status=status, request_options=request_options) + + def create( + self, + *, + name: str, + parameters: CreateFeatureFlagParameters, + description: typing.Optional[str] = OMIT, + request_options: typing.Optional[RequestOptions] = None, + ) -> CreateFeatureFlagResponseContent: + """ + Create a new feature flag with parameters for use in experiments. + + Parameters + ---------- + name : str + A human-readable name for the feature flag + + parameters : CreateFeatureFlagParameters + + description : typing.Optional[str] + A description of what this feature flag controls + + request_options : typing.Optional[RequestOptions] + Request-specific configuration. + + Returns + ------- + CreateFeatureFlagResponseContent + Feature flag successfully created. + + Examples + -------- + from auth0 import Auth0 + + client = Auth0( + token="YOUR_TOKEN", + ) + client.experimentation.feature_flags.create( + name="name", + parameters={}, + ) + """ + _response = self._raw_client.create( + name=name, parameters=parameters, description=description, request_options=request_options + ) + return _response.data + + def get(self, id: str, *, request_options: typing.Optional[RequestOptions] = None) -> GetFeatureFlagResponseContent: + """ + Retrieve a single feature flag by its ID. + + Parameters + ---------- + id : str + The ID of the feature flag to retrieve. + + request_options : typing.Optional[RequestOptions] + Request-specific configuration. + + Returns + ------- + GetFeatureFlagResponseContent + Feature flag successfully retrieved. + + Examples + -------- + from auth0 import Auth0 + + client = Auth0( + token="YOUR_TOKEN", + ) + client.experimentation.feature_flags.get( + id="id", + ) + """ + _response = self._raw_client.get(id, request_options=request_options) + return _response.data + + def delete(self, id: str, *, request_options: typing.Optional[RequestOptions] = None) -> None: + """ + Delete a feature flag by ID. Idempotent: returns 204 even if flag does not exist. + + Parameters + ---------- + id : str + The ID of the feature flag to delete. + + request_options : typing.Optional[RequestOptions] + Request-specific configuration. + + Returns + ------- + None + + Examples + -------- + from auth0 import Auth0 + + client = Auth0( + token="YOUR_TOKEN", + ) + client.experimentation.feature_flags.delete( + id="id", + ) + """ + _response = self._raw_client.delete(id, request_options=request_options) + return _response.data + + def update( + self, + id: str, + *, + name: typing.Optional[str] = OMIT, + description: typing.Optional[str] = OMIT, + parameters: typing.Optional[UpdateFeatureFlagParameters] = OMIT, + request_options: typing.Optional[RequestOptions] = None, + ) -> UpdateFeatureFlagResponseContent: + """ + Partially update a feature flag by ID. Only provided fields are updated. + + Parameters + ---------- + id : str + The ID of the feature flag to update. + + name : typing.Optional[str] + A human-readable name for the feature flag + + description : typing.Optional[str] + A description of what this feature flag controls + + parameters : typing.Optional[UpdateFeatureFlagParameters] + + request_options : typing.Optional[RequestOptions] + Request-specific configuration. + + Returns + ------- + UpdateFeatureFlagResponseContent + Feature flag successfully updated. + + Examples + -------- + from auth0 import Auth0 + + client = Auth0( + token="YOUR_TOKEN", + ) + client.experimentation.feature_flags.update( + id="id", + ) + """ + _response = self._raw_client.update( + id, name=name, description=description, parameters=parameters, request_options=request_options + ) + return _response.data + + def update_status( + self, id: str, *, status: FeatureFlagStatusEnum, request_options: typing.Optional[RequestOptions] = None + ) -> UpdateFeatureFlagStatusResponseContent: + """ + Transitions a feature flag through its lifecycle states: draft → active, draft → archived, active → archived. + + Parameters + ---------- + id : str + The ID of the feature flag to transition. + + status : FeatureFlagStatusEnum + The target status to transition the feature flag to. + + request_options : typing.Optional[RequestOptions] + Request-specific configuration. + + Returns + ------- + UpdateFeatureFlagStatusResponseContent + Feature flag status successfully updated. + + Examples + -------- + from auth0 import Auth0 + + client = Auth0( + token="YOUR_TOKEN", + ) + client.experimentation.feature_flags.update_status( + id="id", + status="draft", + ) + """ + _response = self._raw_client.update_status(id, status=status, request_options=request_options) + return _response.data + + @property + def variations(self): + if self._variations is None: + from .variations.client import VariationsClient # noqa: E402 + + self._variations = VariationsClient(client_wrapper=self._client_wrapper) + return self._variations + + +class AsyncFeatureFlagsClient: + def __init__(self, *, client_wrapper: AsyncClientWrapper): + self._raw_client = AsyncRawFeatureFlagsClient(client_wrapper=client_wrapper) + self._client_wrapper = client_wrapper + self._variations: typing.Optional[AsyncVariationsClient] = None + + @property + def with_raw_response(self) -> AsyncRawFeatureFlagsClient: + """ + Retrieves a raw implementation of this client that returns raw responses. + + Returns + ------- + AsyncRawFeatureFlagsClient + """ + return self._raw_client + + async def list( + self, + *, + from_: typing.Optional[str] = None, + take: typing.Optional[int] = 50, + type: typing.Optional[FeatureFlagTypeEnum] = None, + status: typing.Optional[FeatureFlagStatusEnum] = None, + request_options: typing.Optional[RequestOptions] = None, + ) -> AsyncPager[FeatureFlag, ListFeatureFlagsResponseContent]: + """ + Retrieve a paginated list of feature flags for the tenant. + + Parameters + ---------- + from_ : typing.Optional[str] + Optional Id from which to start selection. + + take : typing.Optional[int] + Number of feature flags to return per page. Defaults to 25, maximum 50. + + type : typing.Optional[FeatureFlagTypeEnum] + Filter by type. Exact match. + + status : typing.Optional[FeatureFlagStatusEnum] + Filter by status. Exact match. + + request_options : typing.Optional[RequestOptions] + Request-specific configuration. + + Returns + ------- + AsyncPager[FeatureFlag, ListFeatureFlagsResponseContent] + Feature flags successfully retrieved. + + Examples + -------- + import asyncio + + from auth0 import AsyncAuth0 + + client = AsyncAuth0( + token="YOUR_TOKEN", + ) + + + async def main() -> None: + response = await client.experimentation.feature_flags.list( + from_="from", + take=1, + type="auth0", + status="draft", + ) + async for item in response: + yield item + + # alternatively, you can paginate page-by-page + async for page in response.iter_pages(): + yield page + + + asyncio.run(main()) + """ + return await self._raw_client.list( + from_=from_, take=take, type=type, status=status, request_options=request_options + ) + + async def create( + self, + *, + name: str, + parameters: CreateFeatureFlagParameters, + description: typing.Optional[str] = OMIT, + request_options: typing.Optional[RequestOptions] = None, + ) -> CreateFeatureFlagResponseContent: + """ + Create a new feature flag with parameters for use in experiments. + + Parameters + ---------- + name : str + A human-readable name for the feature flag + + parameters : CreateFeatureFlagParameters + + description : typing.Optional[str] + A description of what this feature flag controls + + request_options : typing.Optional[RequestOptions] + Request-specific configuration. + + Returns + ------- + CreateFeatureFlagResponseContent + Feature flag successfully created. + + Examples + -------- + import asyncio + + from auth0 import AsyncAuth0 + + client = AsyncAuth0( + token="YOUR_TOKEN", + ) + + + async def main() -> None: + await client.experimentation.feature_flags.create( + name="name", + parameters={}, + ) + + + asyncio.run(main()) + """ + _response = await self._raw_client.create( + name=name, parameters=parameters, description=description, request_options=request_options + ) + return _response.data + + async def get( + self, id: str, *, request_options: typing.Optional[RequestOptions] = None + ) -> GetFeatureFlagResponseContent: + """ + Retrieve a single feature flag by its ID. + + Parameters + ---------- + id : str + The ID of the feature flag to retrieve. + + request_options : typing.Optional[RequestOptions] + Request-specific configuration. + + Returns + ------- + GetFeatureFlagResponseContent + Feature flag successfully retrieved. + + Examples + -------- + import asyncio + + from auth0 import AsyncAuth0 + + client = AsyncAuth0( + token="YOUR_TOKEN", + ) + + + async def main() -> None: + await client.experimentation.feature_flags.get( + id="id", + ) + + + asyncio.run(main()) + """ + _response = await self._raw_client.get(id, request_options=request_options) + return _response.data + + async def delete(self, id: str, *, request_options: typing.Optional[RequestOptions] = None) -> None: + """ + Delete a feature flag by ID. Idempotent: returns 204 even if flag does not exist. + + Parameters + ---------- + id : str + The ID of the feature flag to delete. + + request_options : typing.Optional[RequestOptions] + Request-specific configuration. + + Returns + ------- + None + + Examples + -------- + import asyncio + + from auth0 import AsyncAuth0 + + client = AsyncAuth0( + token="YOUR_TOKEN", + ) + + + async def main() -> None: + await client.experimentation.feature_flags.delete( + id="id", + ) + + + asyncio.run(main()) + """ + _response = await self._raw_client.delete(id, request_options=request_options) + return _response.data + + async def update( + self, + id: str, + *, + name: typing.Optional[str] = OMIT, + description: typing.Optional[str] = OMIT, + parameters: typing.Optional[UpdateFeatureFlagParameters] = OMIT, + request_options: typing.Optional[RequestOptions] = None, + ) -> UpdateFeatureFlagResponseContent: + """ + Partially update a feature flag by ID. Only provided fields are updated. + + Parameters + ---------- + id : str + The ID of the feature flag to update. + + name : typing.Optional[str] + A human-readable name for the feature flag + + description : typing.Optional[str] + A description of what this feature flag controls + + parameters : typing.Optional[UpdateFeatureFlagParameters] + + request_options : typing.Optional[RequestOptions] + Request-specific configuration. + + Returns + ------- + UpdateFeatureFlagResponseContent + Feature flag successfully updated. + + Examples + -------- + import asyncio + + from auth0 import AsyncAuth0 + + client = AsyncAuth0( + token="YOUR_TOKEN", + ) + + + async def main() -> None: + await client.experimentation.feature_flags.update( + id="id", + ) + + + asyncio.run(main()) + """ + _response = await self._raw_client.update( + id, name=name, description=description, parameters=parameters, request_options=request_options + ) + return _response.data + + async def update_status( + self, id: str, *, status: FeatureFlagStatusEnum, request_options: typing.Optional[RequestOptions] = None + ) -> UpdateFeatureFlagStatusResponseContent: + """ + Transitions a feature flag through its lifecycle states: draft → active, draft → archived, active → archived. + + Parameters + ---------- + id : str + The ID of the feature flag to transition. + + status : FeatureFlagStatusEnum + The target status to transition the feature flag to. + + request_options : typing.Optional[RequestOptions] + Request-specific configuration. + + Returns + ------- + UpdateFeatureFlagStatusResponseContent + Feature flag status successfully updated. + + Examples + -------- + import asyncio + + from auth0 import AsyncAuth0 + + client = AsyncAuth0( + token="YOUR_TOKEN", + ) + + + async def main() -> None: + await client.experimentation.feature_flags.update_status( + id="id", + status="draft", + ) + + + asyncio.run(main()) + """ + _response = await self._raw_client.update_status(id, status=status, request_options=request_options) + return _response.data + + @property + def variations(self): + if self._variations is None: + from .variations.client import AsyncVariationsClient # noqa: E402 + + self._variations = AsyncVariationsClient(client_wrapper=self._client_wrapper) + return self._variations diff --git a/src/auth0/management/experimentation/feature_flags/raw_client.py b/src/auth0/management/experimentation/feature_flags/raw_client.py new file mode 100644 index 00000000..340ed8d2 --- /dev/null +++ b/src/auth0/management/experimentation/feature_flags/raw_client.py @@ -0,0 +1,1313 @@ +# This file was auto-generated by Fern from our API Definition. + +import typing +from json.decoder import JSONDecodeError + +from ...core.api_error import ApiError +from ...core.client_wrapper import AsyncClientWrapper, SyncClientWrapper +from ...core.http_response import AsyncHttpResponse, HttpResponse +from ...core.jsonable_encoder import quote_path_param +from ...core.pagination import AsyncPager, SyncPager +from ...core.parse_error import ParsingError +from ...core.pydantic_utilities import parse_obj_as +from ...core.request_options import RequestOptions +from ...core.serialization import convert_and_respect_annotation_metadata +from ...errors.bad_request_error import BadRequestError +from ...errors.conflict_error import ConflictError +from ...errors.forbidden_error import ForbiddenError +from ...errors.not_found_error import NotFoundError +from ...errors.too_many_requests_error import TooManyRequestsError +from ...errors.unauthorized_error import UnauthorizedError +from ...types.create_feature_flag_parameters import CreateFeatureFlagParameters +from ...types.create_feature_flag_response_content import CreateFeatureFlagResponseContent +from ...types.feature_flag import FeatureFlag +from ...types.feature_flag_status_enum import FeatureFlagStatusEnum +from ...types.feature_flag_type_enum import FeatureFlagTypeEnum +from ...types.get_feature_flag_response_content import GetFeatureFlagResponseContent +from ...types.list_feature_flags_response_content import ListFeatureFlagsResponseContent +from ...types.update_feature_flag_parameters import UpdateFeatureFlagParameters +from ...types.update_feature_flag_response_content import UpdateFeatureFlagResponseContent +from ...types.update_feature_flag_status_response_content import UpdateFeatureFlagStatusResponseContent +from pydantic import ValidationError + +# this is used as the default value for optional parameters +OMIT = typing.cast(typing.Any, ...) + + +class RawFeatureFlagsClient: + def __init__(self, *, client_wrapper: SyncClientWrapper): + self._client_wrapper = client_wrapper + + def list( + self, + *, + from_: typing.Optional[str] = None, + take: typing.Optional[int] = 50, + type: typing.Optional[FeatureFlagTypeEnum] = None, + status: typing.Optional[FeatureFlagStatusEnum] = None, + request_options: typing.Optional[RequestOptions] = None, + ) -> SyncPager[FeatureFlag, ListFeatureFlagsResponseContent]: + """ + Retrieve a paginated list of feature flags for the tenant. + + Parameters + ---------- + from_ : typing.Optional[str] + Optional Id from which to start selection. + + take : typing.Optional[int] + Number of feature flags to return per page. Defaults to 25, maximum 50. + + type : typing.Optional[FeatureFlagTypeEnum] + Filter by type. Exact match. + + status : typing.Optional[FeatureFlagStatusEnum] + Filter by status. Exact match. + + request_options : typing.Optional[RequestOptions] + Request-specific configuration. + + Returns + ------- + SyncPager[FeatureFlag, ListFeatureFlagsResponseContent] + Feature flags successfully retrieved. + """ + _response = self._client_wrapper.httpx_client.request( + "experimentation/feature-flags", + method="GET", + params={ + "from": from_, + "take": take, + "type": type, + "status": status, + }, + request_options=request_options, + ) + try: + if 200 <= _response.status_code < 300: + _parsed_response = typing.cast( + ListFeatureFlagsResponseContent, + parse_obj_as( + type_=ListFeatureFlagsResponseContent, # type: ignore + object_=_response.json(), + ), + ) + _items = _parsed_response.feature_flags + _parsed_next = _parsed_response.next + _has_next = _parsed_next is not None and _parsed_next != "" + _get_next = lambda: self.list( + from_=_parsed_next, + take=take, + type=type, + status=status, + request_options=request_options, + ) + return SyncPager(has_next=_has_next, items=_items, get_next=_get_next, response=_parsed_response) + if _response.status_code == 400: + raise BadRequestError( + headers=dict(_response.headers), + body=typing.cast( + typing.Any, + parse_obj_as( + type_=typing.Any, # type: ignore + object_=_response.json(), + ), + ), + ) + if _response.status_code == 401: + raise UnauthorizedError( + headers=dict(_response.headers), + body=typing.cast( + typing.Any, + parse_obj_as( + type_=typing.Any, # type: ignore + object_=_response.json(), + ), + ), + ) + if _response.status_code == 403: + raise ForbiddenError( + headers=dict(_response.headers), + body=typing.cast( + typing.Any, + parse_obj_as( + type_=typing.Any, # type: ignore + object_=_response.json(), + ), + ), + ) + if _response.status_code == 429: + raise TooManyRequestsError( + headers=dict(_response.headers), + body=typing.cast( + typing.Any, + parse_obj_as( + type_=typing.Any, # type: ignore + object_=_response.json(), + ), + ), + ) + _response_json = _response.json() + except JSONDecodeError: + raise ApiError(status_code=_response.status_code, headers=dict(_response.headers), body=_response.text) + except ValidationError as e: + raise ParsingError( + status_code=_response.status_code, headers=dict(_response.headers), body=_response.json(), cause=e + ) + raise ApiError(status_code=_response.status_code, headers=dict(_response.headers), body=_response_json) + + def create( + self, + *, + name: str, + parameters: CreateFeatureFlagParameters, + description: typing.Optional[str] = OMIT, + request_options: typing.Optional[RequestOptions] = None, + ) -> HttpResponse[CreateFeatureFlagResponseContent]: + """ + Create a new feature flag with parameters for use in experiments. + + Parameters + ---------- + name : str + A human-readable name for the feature flag + + parameters : CreateFeatureFlagParameters + + description : typing.Optional[str] + A description of what this feature flag controls + + request_options : typing.Optional[RequestOptions] + Request-specific configuration. + + Returns + ------- + HttpResponse[CreateFeatureFlagResponseContent] + Feature flag successfully created. + """ + _response = self._client_wrapper.httpx_client.request( + "experimentation/feature-flags", + method="POST", + json={ + "name": name, + "description": description, + "parameters": convert_and_respect_annotation_metadata( + object_=parameters, annotation=CreateFeatureFlagParameters, direction="write" + ), + }, + headers={ + "content-type": "application/json", + }, + request_options=request_options, + omit=OMIT, + ) + try: + if 200 <= _response.status_code < 300: + _data = typing.cast( + CreateFeatureFlagResponseContent, + parse_obj_as( + type_=CreateFeatureFlagResponseContent, # type: ignore + object_=_response.json(), + ), + ) + return HttpResponse(response=_response, data=_data) + if _response.status_code == 400: + raise BadRequestError( + headers=dict(_response.headers), + body=typing.cast( + typing.Any, + parse_obj_as( + type_=typing.Any, # type: ignore + object_=_response.json(), + ), + ), + ) + if _response.status_code == 401: + raise UnauthorizedError( + headers=dict(_response.headers), + body=typing.cast( + typing.Any, + parse_obj_as( + type_=typing.Any, # type: ignore + object_=_response.json(), + ), + ), + ) + if _response.status_code == 403: + raise ForbiddenError( + headers=dict(_response.headers), + body=typing.cast( + typing.Any, + parse_obj_as( + type_=typing.Any, # type: ignore + object_=_response.json(), + ), + ), + ) + if _response.status_code == 409: + raise ConflictError( + headers=dict(_response.headers), + body=typing.cast( + typing.Any, + parse_obj_as( + type_=typing.Any, # type: ignore + object_=_response.json(), + ), + ), + ) + if _response.status_code == 429: + raise TooManyRequestsError( + headers=dict(_response.headers), + body=typing.cast( + typing.Any, + parse_obj_as( + type_=typing.Any, # type: ignore + object_=_response.json(), + ), + ), + ) + _response_json = _response.json() + except JSONDecodeError: + raise ApiError(status_code=_response.status_code, headers=dict(_response.headers), body=_response.text) + except ValidationError as e: + raise ParsingError( + status_code=_response.status_code, headers=dict(_response.headers), body=_response.json(), cause=e + ) + raise ApiError(status_code=_response.status_code, headers=dict(_response.headers), body=_response_json) + + def get( + self, id: str, *, request_options: typing.Optional[RequestOptions] = None + ) -> HttpResponse[GetFeatureFlagResponseContent]: + """ + Retrieve a single feature flag by its ID. + + Parameters + ---------- + id : str + The ID of the feature flag to retrieve. + + request_options : typing.Optional[RequestOptions] + Request-specific configuration. + + Returns + ------- + HttpResponse[GetFeatureFlagResponseContent] + Feature flag successfully retrieved. + """ + _response = self._client_wrapper.httpx_client.request( + f"experimentation/feature-flags/{quote_path_param(id)}", + method="GET", + request_options=request_options, + ) + try: + if 200 <= _response.status_code < 300: + _data = typing.cast( + GetFeatureFlagResponseContent, + parse_obj_as( + type_=GetFeatureFlagResponseContent, # type: ignore + object_=_response.json(), + ), + ) + return HttpResponse(response=_response, data=_data) + if _response.status_code == 401: + raise UnauthorizedError( + headers=dict(_response.headers), + body=typing.cast( + typing.Any, + parse_obj_as( + type_=typing.Any, # type: ignore + object_=_response.json(), + ), + ), + ) + if _response.status_code == 403: + raise ForbiddenError( + headers=dict(_response.headers), + body=typing.cast( + typing.Any, + parse_obj_as( + type_=typing.Any, # type: ignore + object_=_response.json(), + ), + ), + ) + if _response.status_code == 404: + raise NotFoundError( + headers=dict(_response.headers), + body=typing.cast( + typing.Any, + parse_obj_as( + type_=typing.Any, # type: ignore + object_=_response.json(), + ), + ), + ) + if _response.status_code == 429: + raise TooManyRequestsError( + headers=dict(_response.headers), + body=typing.cast( + typing.Any, + parse_obj_as( + type_=typing.Any, # type: ignore + object_=_response.json(), + ), + ), + ) + _response_json = _response.json() + except JSONDecodeError: + raise ApiError(status_code=_response.status_code, headers=dict(_response.headers), body=_response.text) + except ValidationError as e: + raise ParsingError( + status_code=_response.status_code, headers=dict(_response.headers), body=_response.json(), cause=e + ) + raise ApiError(status_code=_response.status_code, headers=dict(_response.headers), body=_response_json) + + def delete(self, id: str, *, request_options: typing.Optional[RequestOptions] = None) -> HttpResponse[None]: + """ + Delete a feature flag by ID. Idempotent: returns 204 even if flag does not exist. + + Parameters + ---------- + id : str + The ID of the feature flag to delete. + + request_options : typing.Optional[RequestOptions] + Request-specific configuration. + + Returns + ------- + HttpResponse[None] + """ + _response = self._client_wrapper.httpx_client.request( + f"experimentation/feature-flags/{quote_path_param(id)}", + method="DELETE", + request_options=request_options, + ) + try: + if 200 <= _response.status_code < 300: + return HttpResponse(response=_response, data=None) + if _response.status_code == 403: + raise ForbiddenError( + headers=dict(_response.headers), + body=typing.cast( + typing.Any, + parse_obj_as( + type_=typing.Any, # type: ignore + object_=_response.json(), + ), + ), + ) + if _response.status_code == 409: + raise ConflictError( + headers=dict(_response.headers), + body=typing.cast( + typing.Any, + parse_obj_as( + type_=typing.Any, # type: ignore + object_=_response.json(), + ), + ), + ) + if _response.status_code == 429: + raise TooManyRequestsError( + headers=dict(_response.headers), + body=typing.cast( + typing.Any, + parse_obj_as( + type_=typing.Any, # type: ignore + object_=_response.json(), + ), + ), + ) + _response_json = _response.json() + except JSONDecodeError: + raise ApiError(status_code=_response.status_code, headers=dict(_response.headers), body=_response.text) + except ValidationError as e: + raise ParsingError( + status_code=_response.status_code, headers=dict(_response.headers), body=_response.json(), cause=e + ) + raise ApiError(status_code=_response.status_code, headers=dict(_response.headers), body=_response_json) + + def update( + self, + id: str, + *, + name: typing.Optional[str] = OMIT, + description: typing.Optional[str] = OMIT, + parameters: typing.Optional[UpdateFeatureFlagParameters] = OMIT, + request_options: typing.Optional[RequestOptions] = None, + ) -> HttpResponse[UpdateFeatureFlagResponseContent]: + """ + Partially update a feature flag by ID. Only provided fields are updated. + + Parameters + ---------- + id : str + The ID of the feature flag to update. + + name : typing.Optional[str] + A human-readable name for the feature flag + + description : typing.Optional[str] + A description of what this feature flag controls + + parameters : typing.Optional[UpdateFeatureFlagParameters] + + request_options : typing.Optional[RequestOptions] + Request-specific configuration. + + Returns + ------- + HttpResponse[UpdateFeatureFlagResponseContent] + Feature flag successfully updated. + """ + _response = self._client_wrapper.httpx_client.request( + f"experimentation/feature-flags/{quote_path_param(id)}", + method="PATCH", + json={ + "name": name, + "description": description, + "parameters": convert_and_respect_annotation_metadata( + object_=parameters, annotation=UpdateFeatureFlagParameters, direction="write" + ), + }, + headers={ + "content-type": "application/json", + }, + request_options=request_options, + omit=OMIT, + ) + try: + if 200 <= _response.status_code < 300: + _data = typing.cast( + UpdateFeatureFlagResponseContent, + parse_obj_as( + type_=UpdateFeatureFlagResponseContent, # type: ignore + object_=_response.json(), + ), + ) + return HttpResponse(response=_response, data=_data) + if _response.status_code == 400: + raise BadRequestError( + headers=dict(_response.headers), + body=typing.cast( + typing.Any, + parse_obj_as( + type_=typing.Any, # type: ignore + object_=_response.json(), + ), + ), + ) + if _response.status_code == 401: + raise UnauthorizedError( + headers=dict(_response.headers), + body=typing.cast( + typing.Any, + parse_obj_as( + type_=typing.Any, # type: ignore + object_=_response.json(), + ), + ), + ) + if _response.status_code == 403: + raise ForbiddenError( + headers=dict(_response.headers), + body=typing.cast( + typing.Any, + parse_obj_as( + type_=typing.Any, # type: ignore + object_=_response.json(), + ), + ), + ) + if _response.status_code == 404: + raise NotFoundError( + headers=dict(_response.headers), + body=typing.cast( + typing.Any, + parse_obj_as( + type_=typing.Any, # type: ignore + object_=_response.json(), + ), + ), + ) + if _response.status_code == 409: + raise ConflictError( + headers=dict(_response.headers), + body=typing.cast( + typing.Any, + parse_obj_as( + type_=typing.Any, # type: ignore + object_=_response.json(), + ), + ), + ) + if _response.status_code == 429: + raise TooManyRequestsError( + headers=dict(_response.headers), + body=typing.cast( + typing.Any, + parse_obj_as( + type_=typing.Any, # type: ignore + object_=_response.json(), + ), + ), + ) + _response_json = _response.json() + except JSONDecodeError: + raise ApiError(status_code=_response.status_code, headers=dict(_response.headers), body=_response.text) + except ValidationError as e: + raise ParsingError( + status_code=_response.status_code, headers=dict(_response.headers), body=_response.json(), cause=e + ) + raise ApiError(status_code=_response.status_code, headers=dict(_response.headers), body=_response_json) + + def update_status( + self, id: str, *, status: FeatureFlagStatusEnum, request_options: typing.Optional[RequestOptions] = None + ) -> HttpResponse[UpdateFeatureFlagStatusResponseContent]: + """ + Transitions a feature flag through its lifecycle states: draft → active, draft → archived, active → archived. + + Parameters + ---------- + id : str + The ID of the feature flag to transition. + + status : FeatureFlagStatusEnum + The target status to transition the feature flag to. + + request_options : typing.Optional[RequestOptions] + Request-specific configuration. + + Returns + ------- + HttpResponse[UpdateFeatureFlagStatusResponseContent] + Feature flag status successfully updated. + """ + _response = self._client_wrapper.httpx_client.request( + f"experimentation/feature-flags/{quote_path_param(id)}/status", + method="POST", + json={ + "status": status, + }, + headers={ + "content-type": "application/json", + }, + request_options=request_options, + omit=OMIT, + ) + try: + if 200 <= _response.status_code < 300: + _data = typing.cast( + UpdateFeatureFlagStatusResponseContent, + parse_obj_as( + type_=UpdateFeatureFlagStatusResponseContent, # type: ignore + object_=_response.json(), + ), + ) + return HttpResponse(response=_response, data=_data) + if _response.status_code == 400: + raise BadRequestError( + headers=dict(_response.headers), + body=typing.cast( + typing.Any, + parse_obj_as( + type_=typing.Any, # type: ignore + object_=_response.json(), + ), + ), + ) + if _response.status_code == 401: + raise UnauthorizedError( + headers=dict(_response.headers), + body=typing.cast( + typing.Any, + parse_obj_as( + type_=typing.Any, # type: ignore + object_=_response.json(), + ), + ), + ) + if _response.status_code == 403: + raise ForbiddenError( + headers=dict(_response.headers), + body=typing.cast( + typing.Any, + parse_obj_as( + type_=typing.Any, # type: ignore + object_=_response.json(), + ), + ), + ) + if _response.status_code == 404: + raise NotFoundError( + headers=dict(_response.headers), + body=typing.cast( + typing.Any, + parse_obj_as( + type_=typing.Any, # type: ignore + object_=_response.json(), + ), + ), + ) + if _response.status_code == 429: + raise TooManyRequestsError( + headers=dict(_response.headers), + body=typing.cast( + typing.Any, + parse_obj_as( + type_=typing.Any, # type: ignore + object_=_response.json(), + ), + ), + ) + _response_json = _response.json() + except JSONDecodeError: + raise ApiError(status_code=_response.status_code, headers=dict(_response.headers), body=_response.text) + except ValidationError as e: + raise ParsingError( + status_code=_response.status_code, headers=dict(_response.headers), body=_response.json(), cause=e + ) + raise ApiError(status_code=_response.status_code, headers=dict(_response.headers), body=_response_json) + + +class AsyncRawFeatureFlagsClient: + def __init__(self, *, client_wrapper: AsyncClientWrapper): + self._client_wrapper = client_wrapper + + async def list( + self, + *, + from_: typing.Optional[str] = None, + take: typing.Optional[int] = 50, + type: typing.Optional[FeatureFlagTypeEnum] = None, + status: typing.Optional[FeatureFlagStatusEnum] = None, + request_options: typing.Optional[RequestOptions] = None, + ) -> AsyncPager[FeatureFlag, ListFeatureFlagsResponseContent]: + """ + Retrieve a paginated list of feature flags for the tenant. + + Parameters + ---------- + from_ : typing.Optional[str] + Optional Id from which to start selection. + + take : typing.Optional[int] + Number of feature flags to return per page. Defaults to 25, maximum 50. + + type : typing.Optional[FeatureFlagTypeEnum] + Filter by type. Exact match. + + status : typing.Optional[FeatureFlagStatusEnum] + Filter by status. Exact match. + + request_options : typing.Optional[RequestOptions] + Request-specific configuration. + + Returns + ------- + AsyncPager[FeatureFlag, ListFeatureFlagsResponseContent] + Feature flags successfully retrieved. + """ + _response = await self._client_wrapper.httpx_client.request( + "experimentation/feature-flags", + method="GET", + params={ + "from": from_, + "take": take, + "type": type, + "status": status, + }, + request_options=request_options, + ) + try: + if 200 <= _response.status_code < 300: + _parsed_response = typing.cast( + ListFeatureFlagsResponseContent, + parse_obj_as( + type_=ListFeatureFlagsResponseContent, # type: ignore + object_=_response.json(), + ), + ) + _items = _parsed_response.feature_flags + _parsed_next = _parsed_response.next + _has_next = _parsed_next is not None and _parsed_next != "" + + async def _get_next(): + return await self.list( + from_=_parsed_next, + take=take, + type=type, + status=status, + request_options=request_options, + ) + + return AsyncPager(has_next=_has_next, items=_items, get_next=_get_next, response=_parsed_response) + if _response.status_code == 400: + raise BadRequestError( + headers=dict(_response.headers), + body=typing.cast( + typing.Any, + parse_obj_as( + type_=typing.Any, # type: ignore + object_=_response.json(), + ), + ), + ) + if _response.status_code == 401: + raise UnauthorizedError( + headers=dict(_response.headers), + body=typing.cast( + typing.Any, + parse_obj_as( + type_=typing.Any, # type: ignore + object_=_response.json(), + ), + ), + ) + if _response.status_code == 403: + raise ForbiddenError( + headers=dict(_response.headers), + body=typing.cast( + typing.Any, + parse_obj_as( + type_=typing.Any, # type: ignore + object_=_response.json(), + ), + ), + ) + if _response.status_code == 429: + raise TooManyRequestsError( + headers=dict(_response.headers), + body=typing.cast( + typing.Any, + parse_obj_as( + type_=typing.Any, # type: ignore + object_=_response.json(), + ), + ), + ) + _response_json = _response.json() + except JSONDecodeError: + raise ApiError(status_code=_response.status_code, headers=dict(_response.headers), body=_response.text) + except ValidationError as e: + raise ParsingError( + status_code=_response.status_code, headers=dict(_response.headers), body=_response.json(), cause=e + ) + raise ApiError(status_code=_response.status_code, headers=dict(_response.headers), body=_response_json) + + async def create( + self, + *, + name: str, + parameters: CreateFeatureFlagParameters, + description: typing.Optional[str] = OMIT, + request_options: typing.Optional[RequestOptions] = None, + ) -> AsyncHttpResponse[CreateFeatureFlagResponseContent]: + """ + Create a new feature flag with parameters for use in experiments. + + Parameters + ---------- + name : str + A human-readable name for the feature flag + + parameters : CreateFeatureFlagParameters + + description : typing.Optional[str] + A description of what this feature flag controls + + request_options : typing.Optional[RequestOptions] + Request-specific configuration. + + Returns + ------- + AsyncHttpResponse[CreateFeatureFlagResponseContent] + Feature flag successfully created. + """ + _response = await self._client_wrapper.httpx_client.request( + "experimentation/feature-flags", + method="POST", + json={ + "name": name, + "description": description, + "parameters": convert_and_respect_annotation_metadata( + object_=parameters, annotation=CreateFeatureFlagParameters, direction="write" + ), + }, + headers={ + "content-type": "application/json", + }, + request_options=request_options, + omit=OMIT, + ) + try: + if 200 <= _response.status_code < 300: + _data = typing.cast( + CreateFeatureFlagResponseContent, + parse_obj_as( + type_=CreateFeatureFlagResponseContent, # type: ignore + object_=_response.json(), + ), + ) + return AsyncHttpResponse(response=_response, data=_data) + if _response.status_code == 400: + raise BadRequestError( + headers=dict(_response.headers), + body=typing.cast( + typing.Any, + parse_obj_as( + type_=typing.Any, # type: ignore + object_=_response.json(), + ), + ), + ) + if _response.status_code == 401: + raise UnauthorizedError( + headers=dict(_response.headers), + body=typing.cast( + typing.Any, + parse_obj_as( + type_=typing.Any, # type: ignore + object_=_response.json(), + ), + ), + ) + if _response.status_code == 403: + raise ForbiddenError( + headers=dict(_response.headers), + body=typing.cast( + typing.Any, + parse_obj_as( + type_=typing.Any, # type: ignore + object_=_response.json(), + ), + ), + ) + if _response.status_code == 409: + raise ConflictError( + headers=dict(_response.headers), + body=typing.cast( + typing.Any, + parse_obj_as( + type_=typing.Any, # type: ignore + object_=_response.json(), + ), + ), + ) + if _response.status_code == 429: + raise TooManyRequestsError( + headers=dict(_response.headers), + body=typing.cast( + typing.Any, + parse_obj_as( + type_=typing.Any, # type: ignore + object_=_response.json(), + ), + ), + ) + _response_json = _response.json() + except JSONDecodeError: + raise ApiError(status_code=_response.status_code, headers=dict(_response.headers), body=_response.text) + except ValidationError as e: + raise ParsingError( + status_code=_response.status_code, headers=dict(_response.headers), body=_response.json(), cause=e + ) + raise ApiError(status_code=_response.status_code, headers=dict(_response.headers), body=_response_json) + + async def get( + self, id: str, *, request_options: typing.Optional[RequestOptions] = None + ) -> AsyncHttpResponse[GetFeatureFlagResponseContent]: + """ + Retrieve a single feature flag by its ID. + + Parameters + ---------- + id : str + The ID of the feature flag to retrieve. + + request_options : typing.Optional[RequestOptions] + Request-specific configuration. + + Returns + ------- + AsyncHttpResponse[GetFeatureFlagResponseContent] + Feature flag successfully retrieved. + """ + _response = await self._client_wrapper.httpx_client.request( + f"experimentation/feature-flags/{quote_path_param(id)}", + method="GET", + request_options=request_options, + ) + try: + if 200 <= _response.status_code < 300: + _data = typing.cast( + GetFeatureFlagResponseContent, + parse_obj_as( + type_=GetFeatureFlagResponseContent, # type: ignore + object_=_response.json(), + ), + ) + return AsyncHttpResponse(response=_response, data=_data) + if _response.status_code == 401: + raise UnauthorizedError( + headers=dict(_response.headers), + body=typing.cast( + typing.Any, + parse_obj_as( + type_=typing.Any, # type: ignore + object_=_response.json(), + ), + ), + ) + if _response.status_code == 403: + raise ForbiddenError( + headers=dict(_response.headers), + body=typing.cast( + typing.Any, + parse_obj_as( + type_=typing.Any, # type: ignore + object_=_response.json(), + ), + ), + ) + if _response.status_code == 404: + raise NotFoundError( + headers=dict(_response.headers), + body=typing.cast( + typing.Any, + parse_obj_as( + type_=typing.Any, # type: ignore + object_=_response.json(), + ), + ), + ) + if _response.status_code == 429: + raise TooManyRequestsError( + headers=dict(_response.headers), + body=typing.cast( + typing.Any, + parse_obj_as( + type_=typing.Any, # type: ignore + object_=_response.json(), + ), + ), + ) + _response_json = _response.json() + except JSONDecodeError: + raise ApiError(status_code=_response.status_code, headers=dict(_response.headers), body=_response.text) + except ValidationError as e: + raise ParsingError( + status_code=_response.status_code, headers=dict(_response.headers), body=_response.json(), cause=e + ) + raise ApiError(status_code=_response.status_code, headers=dict(_response.headers), body=_response_json) + + async def delete( + self, id: str, *, request_options: typing.Optional[RequestOptions] = None + ) -> AsyncHttpResponse[None]: + """ + Delete a feature flag by ID. Idempotent: returns 204 even if flag does not exist. + + Parameters + ---------- + id : str + The ID of the feature flag to delete. + + request_options : typing.Optional[RequestOptions] + Request-specific configuration. + + Returns + ------- + AsyncHttpResponse[None] + """ + _response = await self._client_wrapper.httpx_client.request( + f"experimentation/feature-flags/{quote_path_param(id)}", + method="DELETE", + request_options=request_options, + ) + try: + if 200 <= _response.status_code < 300: + return AsyncHttpResponse(response=_response, data=None) + if _response.status_code == 403: + raise ForbiddenError( + headers=dict(_response.headers), + body=typing.cast( + typing.Any, + parse_obj_as( + type_=typing.Any, # type: ignore + object_=_response.json(), + ), + ), + ) + if _response.status_code == 409: + raise ConflictError( + headers=dict(_response.headers), + body=typing.cast( + typing.Any, + parse_obj_as( + type_=typing.Any, # type: ignore + object_=_response.json(), + ), + ), + ) + if _response.status_code == 429: + raise TooManyRequestsError( + headers=dict(_response.headers), + body=typing.cast( + typing.Any, + parse_obj_as( + type_=typing.Any, # type: ignore + object_=_response.json(), + ), + ), + ) + _response_json = _response.json() + except JSONDecodeError: + raise ApiError(status_code=_response.status_code, headers=dict(_response.headers), body=_response.text) + except ValidationError as e: + raise ParsingError( + status_code=_response.status_code, headers=dict(_response.headers), body=_response.json(), cause=e + ) + raise ApiError(status_code=_response.status_code, headers=dict(_response.headers), body=_response_json) + + async def update( + self, + id: str, + *, + name: typing.Optional[str] = OMIT, + description: typing.Optional[str] = OMIT, + parameters: typing.Optional[UpdateFeatureFlagParameters] = OMIT, + request_options: typing.Optional[RequestOptions] = None, + ) -> AsyncHttpResponse[UpdateFeatureFlagResponseContent]: + """ + Partially update a feature flag by ID. Only provided fields are updated. + + Parameters + ---------- + id : str + The ID of the feature flag to update. + + name : typing.Optional[str] + A human-readable name for the feature flag + + description : typing.Optional[str] + A description of what this feature flag controls + + parameters : typing.Optional[UpdateFeatureFlagParameters] + + request_options : typing.Optional[RequestOptions] + Request-specific configuration. + + Returns + ------- + AsyncHttpResponse[UpdateFeatureFlagResponseContent] + Feature flag successfully updated. + """ + _response = await self._client_wrapper.httpx_client.request( + f"experimentation/feature-flags/{quote_path_param(id)}", + method="PATCH", + json={ + "name": name, + "description": description, + "parameters": convert_and_respect_annotation_metadata( + object_=parameters, annotation=UpdateFeatureFlagParameters, direction="write" + ), + }, + headers={ + "content-type": "application/json", + }, + request_options=request_options, + omit=OMIT, + ) + try: + if 200 <= _response.status_code < 300: + _data = typing.cast( + UpdateFeatureFlagResponseContent, + parse_obj_as( + type_=UpdateFeatureFlagResponseContent, # type: ignore + object_=_response.json(), + ), + ) + return AsyncHttpResponse(response=_response, data=_data) + if _response.status_code == 400: + raise BadRequestError( + headers=dict(_response.headers), + body=typing.cast( + typing.Any, + parse_obj_as( + type_=typing.Any, # type: ignore + object_=_response.json(), + ), + ), + ) + if _response.status_code == 401: + raise UnauthorizedError( + headers=dict(_response.headers), + body=typing.cast( + typing.Any, + parse_obj_as( + type_=typing.Any, # type: ignore + object_=_response.json(), + ), + ), + ) + if _response.status_code == 403: + raise ForbiddenError( + headers=dict(_response.headers), + body=typing.cast( + typing.Any, + parse_obj_as( + type_=typing.Any, # type: ignore + object_=_response.json(), + ), + ), + ) + if _response.status_code == 404: + raise NotFoundError( + headers=dict(_response.headers), + body=typing.cast( + typing.Any, + parse_obj_as( + type_=typing.Any, # type: ignore + object_=_response.json(), + ), + ), + ) + if _response.status_code == 409: + raise ConflictError( + headers=dict(_response.headers), + body=typing.cast( + typing.Any, + parse_obj_as( + type_=typing.Any, # type: ignore + object_=_response.json(), + ), + ), + ) + if _response.status_code == 429: + raise TooManyRequestsError( + headers=dict(_response.headers), + body=typing.cast( + typing.Any, + parse_obj_as( + type_=typing.Any, # type: ignore + object_=_response.json(), + ), + ), + ) + _response_json = _response.json() + except JSONDecodeError: + raise ApiError(status_code=_response.status_code, headers=dict(_response.headers), body=_response.text) + except ValidationError as e: + raise ParsingError( + status_code=_response.status_code, headers=dict(_response.headers), body=_response.json(), cause=e + ) + raise ApiError(status_code=_response.status_code, headers=dict(_response.headers), body=_response_json) + + async def update_status( + self, id: str, *, status: FeatureFlagStatusEnum, request_options: typing.Optional[RequestOptions] = None + ) -> AsyncHttpResponse[UpdateFeatureFlagStatusResponseContent]: + """ + Transitions a feature flag through its lifecycle states: draft → active, draft → archived, active → archived. + + Parameters + ---------- + id : str + The ID of the feature flag to transition. + + status : FeatureFlagStatusEnum + The target status to transition the feature flag to. + + request_options : typing.Optional[RequestOptions] + Request-specific configuration. + + Returns + ------- + AsyncHttpResponse[UpdateFeatureFlagStatusResponseContent] + Feature flag status successfully updated. + """ + _response = await self._client_wrapper.httpx_client.request( + f"experimentation/feature-flags/{quote_path_param(id)}/status", + method="POST", + json={ + "status": status, + }, + headers={ + "content-type": "application/json", + }, + request_options=request_options, + omit=OMIT, + ) + try: + if 200 <= _response.status_code < 300: + _data = typing.cast( + UpdateFeatureFlagStatusResponseContent, + parse_obj_as( + type_=UpdateFeatureFlagStatusResponseContent, # type: ignore + object_=_response.json(), + ), + ) + return AsyncHttpResponse(response=_response, data=_data) + if _response.status_code == 400: + raise BadRequestError( + headers=dict(_response.headers), + body=typing.cast( + typing.Any, + parse_obj_as( + type_=typing.Any, # type: ignore + object_=_response.json(), + ), + ), + ) + if _response.status_code == 401: + raise UnauthorizedError( + headers=dict(_response.headers), + body=typing.cast( + typing.Any, + parse_obj_as( + type_=typing.Any, # type: ignore + object_=_response.json(), + ), + ), + ) + if _response.status_code == 403: + raise ForbiddenError( + headers=dict(_response.headers), + body=typing.cast( + typing.Any, + parse_obj_as( + type_=typing.Any, # type: ignore + object_=_response.json(), + ), + ), + ) + if _response.status_code == 404: + raise NotFoundError( + headers=dict(_response.headers), + body=typing.cast( + typing.Any, + parse_obj_as( + type_=typing.Any, # type: ignore + object_=_response.json(), + ), + ), + ) + if _response.status_code == 429: + raise TooManyRequestsError( + headers=dict(_response.headers), + body=typing.cast( + typing.Any, + parse_obj_as( + type_=typing.Any, # type: ignore + object_=_response.json(), + ), + ), + ) + _response_json = _response.json() + except JSONDecodeError: + raise ApiError(status_code=_response.status_code, headers=dict(_response.headers), body=_response.text) + except ValidationError as e: + raise ParsingError( + status_code=_response.status_code, headers=dict(_response.headers), body=_response.json(), cause=e + ) + raise ApiError(status_code=_response.status_code, headers=dict(_response.headers), body=_response_json) diff --git a/src/auth0/management/organizations/organization_template/__init__.py b/src/auth0/management/experimentation/feature_flags/variations/__init__.py similarity index 100% rename from src/auth0/management/organizations/organization_template/__init__.py rename to src/auth0/management/experimentation/feature_flags/variations/__init__.py diff --git a/src/auth0/management/experimentation/feature_flags/variations/client.py b/src/auth0/management/experimentation/feature_flags/variations/client.py new file mode 100644 index 00000000..3ca63b80 --- /dev/null +++ b/src/auth0/management/experimentation/feature_flags/variations/client.py @@ -0,0 +1,508 @@ +# This file was auto-generated by Fern from our API Definition. + +import typing + +from ....core.client_wrapper import AsyncClientWrapper, SyncClientWrapper +from ....core.request_options import RequestOptions +from ....types.create_variation_response_content import CreateVariationResponseContent +from ....types.get_variation_response_content import GetVariationResponseContent +from ....types.list_variations_response_content import ListVariationsResponseContent +from ....types.update_variation_overrides_map import UpdateVariationOverridesMap +from ....types.update_variation_response_content import UpdateVariationResponseContent +from ....types.variation_overrides_map import VariationOverridesMap +from .raw_client import AsyncRawVariationsClient, RawVariationsClient + +# this is used as the default value for optional parameters +OMIT = typing.cast(typing.Any, ...) + + +class VariationsClient: + def __init__(self, *, client_wrapper: SyncClientWrapper): + self._raw_client = RawVariationsClient(client_wrapper=client_wrapper) + + @property + def with_raw_response(self) -> RawVariationsClient: + """ + Retrieves a raw implementation of this client that returns raw responses. + + Returns + ------- + RawVariationsClient + """ + return self._raw_client + + def list( + self, id: str, *, request_options: typing.Optional[RequestOptions] = None + ) -> ListVariationsResponseContent: + """ + Retrieve all variations defined for a specific feature flag. + + Parameters + ---------- + id : str + The ID of the parent feature flag. + + request_options : typing.Optional[RequestOptions] + Request-specific configuration. + + Returns + ------- + ListVariationsResponseContent + Variations successfully retrieved. + + Examples + -------- + from auth0 import Auth0 + + client = Auth0( + token="YOUR_TOKEN", + ) + client.experimentation.feature_flags.variations.list( + id="id", + ) + """ + _response = self._raw_client.list(id, request_options=request_options) + return _response.data + + def create( + self, + id: str, + *, + name: str, + overrides: VariationOverridesMap, + description: typing.Optional[str] = OMIT, + request_options: typing.Optional[RequestOptions] = None, + ) -> CreateVariationResponseContent: + """ + Create a new variation with parameter overrides for a specific feature flag. + + Parameters + ---------- + id : str + The ID of the parent feature flag. + + name : str + A human-readable name for the variation + + overrides : VariationOverridesMap + Configuration overrides for this variation; keys must exist in the parent flag parameters. Empty {} is the baseline (control) variation that overrides nothing. + + description : typing.Optional[str] + A description of what this variation controls + + request_options : typing.Optional[RequestOptions] + Request-specific configuration. + + Returns + ------- + CreateVariationResponseContent + Variation successfully created. + + Examples + -------- + from auth0 import Auth0 + + client = Auth0( + token="YOUR_TOKEN", + ) + client.experimentation.feature_flags.variations.create( + id="id", + name="name", + overrides={"key": "value"}, + ) + """ + _response = self._raw_client.create( + id, name=name, overrides=overrides, description=description, request_options=request_options + ) + return _response.data + + def get( + self, id: str, vid: str, *, request_options: typing.Optional[RequestOptions] = None + ) -> GetVariationResponseContent: + """ + Retrieve a single variation by its ID. + + Parameters + ---------- + id : str + The ID of the parent feature flag. + + vid : str + The ID of the variation to retrieve. + + request_options : typing.Optional[RequestOptions] + Request-specific configuration. + + Returns + ------- + GetVariationResponseContent + Variation successfully retrieved. + + Examples + -------- + from auth0 import Auth0 + + client = Auth0( + token="YOUR_TOKEN", + ) + client.experimentation.feature_flags.variations.get( + id="id", + vid="vid", + ) + """ + _response = self._raw_client.get(id, vid, request_options=request_options) + return _response.data + + def delete(self, id: str, vid: str, *, request_options: typing.Optional[RequestOptions] = None) -> None: + """ + Delete a variation by ID. Returns 204 if the variation does not exist. Returns 404 if the parent feature flag does not exist. + + Parameters + ---------- + id : str + The ID of the parent feature flag. + + vid : str + The ID of the variation to delete. + + request_options : typing.Optional[RequestOptions] + Request-specific configuration. + + Returns + ------- + None + + Examples + -------- + from auth0 import Auth0 + + client = Auth0( + token="YOUR_TOKEN", + ) + client.experimentation.feature_flags.variations.delete( + id="id", + vid="vid", + ) + """ + _response = self._raw_client.delete(id, vid, request_options=request_options) + return _response.data + + def update( + self, + id: str, + vid: str, + *, + name: typing.Optional[str] = OMIT, + description: typing.Optional[str] = OMIT, + overrides: typing.Optional[UpdateVariationOverridesMap] = OMIT, + request_options: typing.Optional[RequestOptions] = None, + ) -> UpdateVariationResponseContent: + """ + Partially update a variation by ID. Only provided fields are updated. + + Parameters + ---------- + id : str + The ID of the parent feature flag. + + vid : str + The ID of the variation to update. + + name : typing.Optional[str] + A human-readable name for the variation + + description : typing.Optional[str] + A description of what this variation controls + + overrides : typing.Optional[UpdateVariationOverridesMap] + + request_options : typing.Optional[RequestOptions] + Request-specific configuration. + + Returns + ------- + UpdateVariationResponseContent + Variation successfully updated. + + Examples + -------- + from auth0 import Auth0 + + client = Auth0( + token="YOUR_TOKEN", + ) + client.experimentation.feature_flags.variations.update( + id="id", + vid="vid", + ) + """ + _response = self._raw_client.update( + id, vid, name=name, description=description, overrides=overrides, request_options=request_options + ) + return _response.data + + +class AsyncVariationsClient: + def __init__(self, *, client_wrapper: AsyncClientWrapper): + self._raw_client = AsyncRawVariationsClient(client_wrapper=client_wrapper) + + @property + def with_raw_response(self) -> AsyncRawVariationsClient: + """ + Retrieves a raw implementation of this client that returns raw responses. + + Returns + ------- + AsyncRawVariationsClient + """ + return self._raw_client + + async def list( + self, id: str, *, request_options: typing.Optional[RequestOptions] = None + ) -> ListVariationsResponseContent: + """ + Retrieve all variations defined for a specific feature flag. + + Parameters + ---------- + id : str + The ID of the parent feature flag. + + request_options : typing.Optional[RequestOptions] + Request-specific configuration. + + Returns + ------- + ListVariationsResponseContent + Variations successfully retrieved. + + Examples + -------- + import asyncio + + from auth0 import AsyncAuth0 + + client = AsyncAuth0( + token="YOUR_TOKEN", + ) + + + async def main() -> None: + await client.experimentation.feature_flags.variations.list( + id="id", + ) + + + asyncio.run(main()) + """ + _response = await self._raw_client.list(id, request_options=request_options) + return _response.data + + async def create( + self, + id: str, + *, + name: str, + overrides: VariationOverridesMap, + description: typing.Optional[str] = OMIT, + request_options: typing.Optional[RequestOptions] = None, + ) -> CreateVariationResponseContent: + """ + Create a new variation with parameter overrides for a specific feature flag. + + Parameters + ---------- + id : str + The ID of the parent feature flag. + + name : str + A human-readable name for the variation + + overrides : VariationOverridesMap + Configuration overrides for this variation; keys must exist in the parent flag parameters. Empty {} is the baseline (control) variation that overrides nothing. + + description : typing.Optional[str] + A description of what this variation controls + + request_options : typing.Optional[RequestOptions] + Request-specific configuration. + + Returns + ------- + CreateVariationResponseContent + Variation successfully created. + + Examples + -------- + import asyncio + + from auth0 import AsyncAuth0 + + client = AsyncAuth0( + token="YOUR_TOKEN", + ) + + + async def main() -> None: + await client.experimentation.feature_flags.variations.create( + id="id", + name="name", + overrides={"key": "value"}, + ) + + + asyncio.run(main()) + """ + _response = await self._raw_client.create( + id, name=name, overrides=overrides, description=description, request_options=request_options + ) + return _response.data + + async def get( + self, id: str, vid: str, *, request_options: typing.Optional[RequestOptions] = None + ) -> GetVariationResponseContent: + """ + Retrieve a single variation by its ID. + + Parameters + ---------- + id : str + The ID of the parent feature flag. + + vid : str + The ID of the variation to retrieve. + + request_options : typing.Optional[RequestOptions] + Request-specific configuration. + + Returns + ------- + GetVariationResponseContent + Variation successfully retrieved. + + Examples + -------- + import asyncio + + from auth0 import AsyncAuth0 + + client = AsyncAuth0( + token="YOUR_TOKEN", + ) + + + async def main() -> None: + await client.experimentation.feature_flags.variations.get( + id="id", + vid="vid", + ) + + + asyncio.run(main()) + """ + _response = await self._raw_client.get(id, vid, request_options=request_options) + return _response.data + + async def delete(self, id: str, vid: str, *, request_options: typing.Optional[RequestOptions] = None) -> None: + """ + Delete a variation by ID. Returns 204 if the variation does not exist. Returns 404 if the parent feature flag does not exist. + + Parameters + ---------- + id : str + The ID of the parent feature flag. + + vid : str + The ID of the variation to delete. + + request_options : typing.Optional[RequestOptions] + Request-specific configuration. + + Returns + ------- + None + + Examples + -------- + import asyncio + + from auth0 import AsyncAuth0 + + client = AsyncAuth0( + token="YOUR_TOKEN", + ) + + + async def main() -> None: + await client.experimentation.feature_flags.variations.delete( + id="id", + vid="vid", + ) + + + asyncio.run(main()) + """ + _response = await self._raw_client.delete(id, vid, request_options=request_options) + return _response.data + + async def update( + self, + id: str, + vid: str, + *, + name: typing.Optional[str] = OMIT, + description: typing.Optional[str] = OMIT, + overrides: typing.Optional[UpdateVariationOverridesMap] = OMIT, + request_options: typing.Optional[RequestOptions] = None, + ) -> UpdateVariationResponseContent: + """ + Partially update a variation by ID. Only provided fields are updated. + + Parameters + ---------- + id : str + The ID of the parent feature flag. + + vid : str + The ID of the variation to update. + + name : typing.Optional[str] + A human-readable name for the variation + + description : typing.Optional[str] + A description of what this variation controls + + overrides : typing.Optional[UpdateVariationOverridesMap] + + request_options : typing.Optional[RequestOptions] + Request-specific configuration. + + Returns + ------- + UpdateVariationResponseContent + Variation successfully updated. + + Examples + -------- + import asyncio + + from auth0 import AsyncAuth0 + + client = AsyncAuth0( + token="YOUR_TOKEN", + ) + + + async def main() -> None: + await client.experimentation.feature_flags.variations.update( + id="id", + vid="vid", + ) + + + asyncio.run(main()) + """ + _response = await self._raw_client.update( + id, vid, name=name, description=description, overrides=overrides, request_options=request_options + ) + return _response.data diff --git a/src/auth0/management/experimentation/feature_flags/variations/raw_client.py b/src/auth0/management/experimentation/feature_flags/variations/raw_client.py new file mode 100644 index 00000000..9b33461f --- /dev/null +++ b/src/auth0/management/experimentation/feature_flags/variations/raw_client.py @@ -0,0 +1,1138 @@ +# This file was auto-generated by Fern from our API Definition. + +import typing +from json.decoder import JSONDecodeError + +from ....core.api_error import ApiError +from ....core.client_wrapper import AsyncClientWrapper, SyncClientWrapper +from ....core.http_response import AsyncHttpResponse, HttpResponse +from ....core.jsonable_encoder import quote_path_param +from ....core.parse_error import ParsingError +from ....core.pydantic_utilities import parse_obj_as +from ....core.request_options import RequestOptions +from ....errors.bad_request_error import BadRequestError +from ....errors.conflict_error import ConflictError +from ....errors.forbidden_error import ForbiddenError +from ....errors.not_found_error import NotFoundError +from ....errors.too_many_requests_error import TooManyRequestsError +from ....errors.unauthorized_error import UnauthorizedError +from ....types.create_variation_response_content import CreateVariationResponseContent +from ....types.get_variation_response_content import GetVariationResponseContent +from ....types.list_variations_response_content import ListVariationsResponseContent +from ....types.update_variation_overrides_map import UpdateVariationOverridesMap +from ....types.update_variation_response_content import UpdateVariationResponseContent +from ....types.variation_overrides_map import VariationOverridesMap +from pydantic import ValidationError + +# this is used as the default value for optional parameters +OMIT = typing.cast(typing.Any, ...) + + +class RawVariationsClient: + def __init__(self, *, client_wrapper: SyncClientWrapper): + self._client_wrapper = client_wrapper + + def list( + self, id: str, *, request_options: typing.Optional[RequestOptions] = None + ) -> HttpResponse[ListVariationsResponseContent]: + """ + Retrieve all variations defined for a specific feature flag. + + Parameters + ---------- + id : str + The ID of the parent feature flag. + + request_options : typing.Optional[RequestOptions] + Request-specific configuration. + + Returns + ------- + HttpResponse[ListVariationsResponseContent] + Variations successfully retrieved. + """ + _response = self._client_wrapper.httpx_client.request( + f"experimentation/feature-flags/{quote_path_param(id)}/variations", + method="GET", + request_options=request_options, + ) + try: + if 200 <= _response.status_code < 300: + _data = typing.cast( + ListVariationsResponseContent, + parse_obj_as( + type_=ListVariationsResponseContent, # type: ignore + object_=_response.json(), + ), + ) + return HttpResponse(response=_response, data=_data) + if _response.status_code == 400: + raise BadRequestError( + headers=dict(_response.headers), + body=typing.cast( + typing.Any, + parse_obj_as( + type_=typing.Any, # type: ignore + object_=_response.json(), + ), + ), + ) + if _response.status_code == 401: + raise UnauthorizedError( + headers=dict(_response.headers), + body=typing.cast( + typing.Any, + parse_obj_as( + type_=typing.Any, # type: ignore + object_=_response.json(), + ), + ), + ) + if _response.status_code == 403: + raise ForbiddenError( + headers=dict(_response.headers), + body=typing.cast( + typing.Any, + parse_obj_as( + type_=typing.Any, # type: ignore + object_=_response.json(), + ), + ), + ) + if _response.status_code == 404: + raise NotFoundError( + headers=dict(_response.headers), + body=typing.cast( + typing.Any, + parse_obj_as( + type_=typing.Any, # type: ignore + object_=_response.json(), + ), + ), + ) + if _response.status_code == 429: + raise TooManyRequestsError( + headers=dict(_response.headers), + body=typing.cast( + typing.Any, + parse_obj_as( + type_=typing.Any, # type: ignore + object_=_response.json(), + ), + ), + ) + _response_json = _response.json() + except JSONDecodeError: + raise ApiError(status_code=_response.status_code, headers=dict(_response.headers), body=_response.text) + except ValidationError as e: + raise ParsingError( + status_code=_response.status_code, headers=dict(_response.headers), body=_response.json(), cause=e + ) + raise ApiError(status_code=_response.status_code, headers=dict(_response.headers), body=_response_json) + + def create( + self, + id: str, + *, + name: str, + overrides: VariationOverridesMap, + description: typing.Optional[str] = OMIT, + request_options: typing.Optional[RequestOptions] = None, + ) -> HttpResponse[CreateVariationResponseContent]: + """ + Create a new variation with parameter overrides for a specific feature flag. + + Parameters + ---------- + id : str + The ID of the parent feature flag. + + name : str + A human-readable name for the variation + + overrides : VariationOverridesMap + Configuration overrides for this variation; keys must exist in the parent flag parameters. Empty {} is the baseline (control) variation that overrides nothing. + + description : typing.Optional[str] + A description of what this variation controls + + request_options : typing.Optional[RequestOptions] + Request-specific configuration. + + Returns + ------- + HttpResponse[CreateVariationResponseContent] + Variation successfully created. + """ + _response = self._client_wrapper.httpx_client.request( + f"experimentation/feature-flags/{quote_path_param(id)}/variations", + method="POST", + json={ + "name": name, + "description": description, + "overrides": overrides, + }, + headers={ + "content-type": "application/json", + }, + request_options=request_options, + omit=OMIT, + ) + try: + if 200 <= _response.status_code < 300: + _data = typing.cast( + CreateVariationResponseContent, + parse_obj_as( + type_=CreateVariationResponseContent, # type: ignore + object_=_response.json(), + ), + ) + return HttpResponse(response=_response, data=_data) + if _response.status_code == 400: + raise BadRequestError( + headers=dict(_response.headers), + body=typing.cast( + typing.Any, + parse_obj_as( + type_=typing.Any, # type: ignore + object_=_response.json(), + ), + ), + ) + if _response.status_code == 401: + raise UnauthorizedError( + headers=dict(_response.headers), + body=typing.cast( + typing.Any, + parse_obj_as( + type_=typing.Any, # type: ignore + object_=_response.json(), + ), + ), + ) + if _response.status_code == 403: + raise ForbiddenError( + headers=dict(_response.headers), + body=typing.cast( + typing.Any, + parse_obj_as( + type_=typing.Any, # type: ignore + object_=_response.json(), + ), + ), + ) + if _response.status_code == 404: + raise NotFoundError( + headers=dict(_response.headers), + body=typing.cast( + typing.Any, + parse_obj_as( + type_=typing.Any, # type: ignore + object_=_response.json(), + ), + ), + ) + if _response.status_code == 409: + raise ConflictError( + headers=dict(_response.headers), + body=typing.cast( + typing.Any, + parse_obj_as( + type_=typing.Any, # type: ignore + object_=_response.json(), + ), + ), + ) + if _response.status_code == 429: + raise TooManyRequestsError( + headers=dict(_response.headers), + body=typing.cast( + typing.Any, + parse_obj_as( + type_=typing.Any, # type: ignore + object_=_response.json(), + ), + ), + ) + _response_json = _response.json() + except JSONDecodeError: + raise ApiError(status_code=_response.status_code, headers=dict(_response.headers), body=_response.text) + except ValidationError as e: + raise ParsingError( + status_code=_response.status_code, headers=dict(_response.headers), body=_response.json(), cause=e + ) + raise ApiError(status_code=_response.status_code, headers=dict(_response.headers), body=_response_json) + + def get( + self, id: str, vid: str, *, request_options: typing.Optional[RequestOptions] = None + ) -> HttpResponse[GetVariationResponseContent]: + """ + Retrieve a single variation by its ID. + + Parameters + ---------- + id : str + The ID of the parent feature flag. + + vid : str + The ID of the variation to retrieve. + + request_options : typing.Optional[RequestOptions] + Request-specific configuration. + + Returns + ------- + HttpResponse[GetVariationResponseContent] + Variation successfully retrieved. + """ + _response = self._client_wrapper.httpx_client.request( + f"experimentation/feature-flags/{quote_path_param(id)}/variations/{quote_path_param(vid)}", + method="GET", + request_options=request_options, + ) + try: + if 200 <= _response.status_code < 300: + _data = typing.cast( + GetVariationResponseContent, + parse_obj_as( + type_=GetVariationResponseContent, # type: ignore + object_=_response.json(), + ), + ) + return HttpResponse(response=_response, data=_data) + if _response.status_code == 401: + raise UnauthorizedError( + headers=dict(_response.headers), + body=typing.cast( + typing.Any, + parse_obj_as( + type_=typing.Any, # type: ignore + object_=_response.json(), + ), + ), + ) + if _response.status_code == 403: + raise ForbiddenError( + headers=dict(_response.headers), + body=typing.cast( + typing.Any, + parse_obj_as( + type_=typing.Any, # type: ignore + object_=_response.json(), + ), + ), + ) + if _response.status_code == 404: + raise NotFoundError( + headers=dict(_response.headers), + body=typing.cast( + typing.Any, + parse_obj_as( + type_=typing.Any, # type: ignore + object_=_response.json(), + ), + ), + ) + if _response.status_code == 429: + raise TooManyRequestsError( + headers=dict(_response.headers), + body=typing.cast( + typing.Any, + parse_obj_as( + type_=typing.Any, # type: ignore + object_=_response.json(), + ), + ), + ) + _response_json = _response.json() + except JSONDecodeError: + raise ApiError(status_code=_response.status_code, headers=dict(_response.headers), body=_response.text) + except ValidationError as e: + raise ParsingError( + status_code=_response.status_code, headers=dict(_response.headers), body=_response.json(), cause=e + ) + raise ApiError(status_code=_response.status_code, headers=dict(_response.headers), body=_response_json) + + def delete( + self, id: str, vid: str, *, request_options: typing.Optional[RequestOptions] = None + ) -> HttpResponse[None]: + """ + Delete a variation by ID. Returns 204 if the variation does not exist. Returns 404 if the parent feature flag does not exist. + + Parameters + ---------- + id : str + The ID of the parent feature flag. + + vid : str + The ID of the variation to delete. + + request_options : typing.Optional[RequestOptions] + Request-specific configuration. + + Returns + ------- + HttpResponse[None] + """ + _response = self._client_wrapper.httpx_client.request( + f"experimentation/feature-flags/{quote_path_param(id)}/variations/{quote_path_param(vid)}", + method="DELETE", + request_options=request_options, + ) + try: + if 200 <= _response.status_code < 300: + return HttpResponse(response=_response, data=None) + if _response.status_code == 400: + raise BadRequestError( + headers=dict(_response.headers), + body=typing.cast( + typing.Any, + parse_obj_as( + type_=typing.Any, # type: ignore + object_=_response.json(), + ), + ), + ) + if _response.status_code == 403: + raise ForbiddenError( + headers=dict(_response.headers), + body=typing.cast( + typing.Any, + parse_obj_as( + type_=typing.Any, # type: ignore + object_=_response.json(), + ), + ), + ) + if _response.status_code == 404: + raise NotFoundError( + headers=dict(_response.headers), + body=typing.cast( + typing.Any, + parse_obj_as( + type_=typing.Any, # type: ignore + object_=_response.json(), + ), + ), + ) + if _response.status_code == 409: + raise ConflictError( + headers=dict(_response.headers), + body=typing.cast( + typing.Any, + parse_obj_as( + type_=typing.Any, # type: ignore + object_=_response.json(), + ), + ), + ) + if _response.status_code == 429: + raise TooManyRequestsError( + headers=dict(_response.headers), + body=typing.cast( + typing.Any, + parse_obj_as( + type_=typing.Any, # type: ignore + object_=_response.json(), + ), + ), + ) + _response_json = _response.json() + except JSONDecodeError: + raise ApiError(status_code=_response.status_code, headers=dict(_response.headers), body=_response.text) + except ValidationError as e: + raise ParsingError( + status_code=_response.status_code, headers=dict(_response.headers), body=_response.json(), cause=e + ) + raise ApiError(status_code=_response.status_code, headers=dict(_response.headers), body=_response_json) + + def update( + self, + id: str, + vid: str, + *, + name: typing.Optional[str] = OMIT, + description: typing.Optional[str] = OMIT, + overrides: typing.Optional[UpdateVariationOverridesMap] = OMIT, + request_options: typing.Optional[RequestOptions] = None, + ) -> HttpResponse[UpdateVariationResponseContent]: + """ + Partially update a variation by ID. Only provided fields are updated. + + Parameters + ---------- + id : str + The ID of the parent feature flag. + + vid : str + The ID of the variation to update. + + name : typing.Optional[str] + A human-readable name for the variation + + description : typing.Optional[str] + A description of what this variation controls + + overrides : typing.Optional[UpdateVariationOverridesMap] + + request_options : typing.Optional[RequestOptions] + Request-specific configuration. + + Returns + ------- + HttpResponse[UpdateVariationResponseContent] + Variation successfully updated. + """ + _response = self._client_wrapper.httpx_client.request( + f"experimentation/feature-flags/{quote_path_param(id)}/variations/{quote_path_param(vid)}", + method="PATCH", + json={ + "name": name, + "description": description, + "overrides": overrides, + }, + headers={ + "content-type": "application/json", + }, + request_options=request_options, + omit=OMIT, + ) + try: + if 200 <= _response.status_code < 300: + _data = typing.cast( + UpdateVariationResponseContent, + parse_obj_as( + type_=UpdateVariationResponseContent, # type: ignore + object_=_response.json(), + ), + ) + return HttpResponse(response=_response, data=_data) + if _response.status_code == 400: + raise BadRequestError( + headers=dict(_response.headers), + body=typing.cast( + typing.Any, + parse_obj_as( + type_=typing.Any, # type: ignore + object_=_response.json(), + ), + ), + ) + if _response.status_code == 401: + raise UnauthorizedError( + headers=dict(_response.headers), + body=typing.cast( + typing.Any, + parse_obj_as( + type_=typing.Any, # type: ignore + object_=_response.json(), + ), + ), + ) + if _response.status_code == 403: + raise ForbiddenError( + headers=dict(_response.headers), + body=typing.cast( + typing.Any, + parse_obj_as( + type_=typing.Any, # type: ignore + object_=_response.json(), + ), + ), + ) + if _response.status_code == 404: + raise NotFoundError( + headers=dict(_response.headers), + body=typing.cast( + typing.Any, + parse_obj_as( + type_=typing.Any, # type: ignore + object_=_response.json(), + ), + ), + ) + if _response.status_code == 409: + raise ConflictError( + headers=dict(_response.headers), + body=typing.cast( + typing.Any, + parse_obj_as( + type_=typing.Any, # type: ignore + object_=_response.json(), + ), + ), + ) + if _response.status_code == 429: + raise TooManyRequestsError( + headers=dict(_response.headers), + body=typing.cast( + typing.Any, + parse_obj_as( + type_=typing.Any, # type: ignore + object_=_response.json(), + ), + ), + ) + _response_json = _response.json() + except JSONDecodeError: + raise ApiError(status_code=_response.status_code, headers=dict(_response.headers), body=_response.text) + except ValidationError as e: + raise ParsingError( + status_code=_response.status_code, headers=dict(_response.headers), body=_response.json(), cause=e + ) + raise ApiError(status_code=_response.status_code, headers=dict(_response.headers), body=_response_json) + + +class AsyncRawVariationsClient: + def __init__(self, *, client_wrapper: AsyncClientWrapper): + self._client_wrapper = client_wrapper + + async def list( + self, id: str, *, request_options: typing.Optional[RequestOptions] = None + ) -> AsyncHttpResponse[ListVariationsResponseContent]: + """ + Retrieve all variations defined for a specific feature flag. + + Parameters + ---------- + id : str + The ID of the parent feature flag. + + request_options : typing.Optional[RequestOptions] + Request-specific configuration. + + Returns + ------- + AsyncHttpResponse[ListVariationsResponseContent] + Variations successfully retrieved. + """ + _response = await self._client_wrapper.httpx_client.request( + f"experimentation/feature-flags/{quote_path_param(id)}/variations", + method="GET", + request_options=request_options, + ) + try: + if 200 <= _response.status_code < 300: + _data = typing.cast( + ListVariationsResponseContent, + parse_obj_as( + type_=ListVariationsResponseContent, # type: ignore + object_=_response.json(), + ), + ) + return AsyncHttpResponse(response=_response, data=_data) + if _response.status_code == 400: + raise BadRequestError( + headers=dict(_response.headers), + body=typing.cast( + typing.Any, + parse_obj_as( + type_=typing.Any, # type: ignore + object_=_response.json(), + ), + ), + ) + if _response.status_code == 401: + raise UnauthorizedError( + headers=dict(_response.headers), + body=typing.cast( + typing.Any, + parse_obj_as( + type_=typing.Any, # type: ignore + object_=_response.json(), + ), + ), + ) + if _response.status_code == 403: + raise ForbiddenError( + headers=dict(_response.headers), + body=typing.cast( + typing.Any, + parse_obj_as( + type_=typing.Any, # type: ignore + object_=_response.json(), + ), + ), + ) + if _response.status_code == 404: + raise NotFoundError( + headers=dict(_response.headers), + body=typing.cast( + typing.Any, + parse_obj_as( + type_=typing.Any, # type: ignore + object_=_response.json(), + ), + ), + ) + if _response.status_code == 429: + raise TooManyRequestsError( + headers=dict(_response.headers), + body=typing.cast( + typing.Any, + parse_obj_as( + type_=typing.Any, # type: ignore + object_=_response.json(), + ), + ), + ) + _response_json = _response.json() + except JSONDecodeError: + raise ApiError(status_code=_response.status_code, headers=dict(_response.headers), body=_response.text) + except ValidationError as e: + raise ParsingError( + status_code=_response.status_code, headers=dict(_response.headers), body=_response.json(), cause=e + ) + raise ApiError(status_code=_response.status_code, headers=dict(_response.headers), body=_response_json) + + async def create( + self, + id: str, + *, + name: str, + overrides: VariationOverridesMap, + description: typing.Optional[str] = OMIT, + request_options: typing.Optional[RequestOptions] = None, + ) -> AsyncHttpResponse[CreateVariationResponseContent]: + """ + Create a new variation with parameter overrides for a specific feature flag. + + Parameters + ---------- + id : str + The ID of the parent feature flag. + + name : str + A human-readable name for the variation + + overrides : VariationOverridesMap + Configuration overrides for this variation; keys must exist in the parent flag parameters. Empty {} is the baseline (control) variation that overrides nothing. + + description : typing.Optional[str] + A description of what this variation controls + + request_options : typing.Optional[RequestOptions] + Request-specific configuration. + + Returns + ------- + AsyncHttpResponse[CreateVariationResponseContent] + Variation successfully created. + """ + _response = await self._client_wrapper.httpx_client.request( + f"experimentation/feature-flags/{quote_path_param(id)}/variations", + method="POST", + json={ + "name": name, + "description": description, + "overrides": overrides, + }, + headers={ + "content-type": "application/json", + }, + request_options=request_options, + omit=OMIT, + ) + try: + if 200 <= _response.status_code < 300: + _data = typing.cast( + CreateVariationResponseContent, + parse_obj_as( + type_=CreateVariationResponseContent, # type: ignore + object_=_response.json(), + ), + ) + return AsyncHttpResponse(response=_response, data=_data) + if _response.status_code == 400: + raise BadRequestError( + headers=dict(_response.headers), + body=typing.cast( + typing.Any, + parse_obj_as( + type_=typing.Any, # type: ignore + object_=_response.json(), + ), + ), + ) + if _response.status_code == 401: + raise UnauthorizedError( + headers=dict(_response.headers), + body=typing.cast( + typing.Any, + parse_obj_as( + type_=typing.Any, # type: ignore + object_=_response.json(), + ), + ), + ) + if _response.status_code == 403: + raise ForbiddenError( + headers=dict(_response.headers), + body=typing.cast( + typing.Any, + parse_obj_as( + type_=typing.Any, # type: ignore + object_=_response.json(), + ), + ), + ) + if _response.status_code == 404: + raise NotFoundError( + headers=dict(_response.headers), + body=typing.cast( + typing.Any, + parse_obj_as( + type_=typing.Any, # type: ignore + object_=_response.json(), + ), + ), + ) + if _response.status_code == 409: + raise ConflictError( + headers=dict(_response.headers), + body=typing.cast( + typing.Any, + parse_obj_as( + type_=typing.Any, # type: ignore + object_=_response.json(), + ), + ), + ) + if _response.status_code == 429: + raise TooManyRequestsError( + headers=dict(_response.headers), + body=typing.cast( + typing.Any, + parse_obj_as( + type_=typing.Any, # type: ignore + object_=_response.json(), + ), + ), + ) + _response_json = _response.json() + except JSONDecodeError: + raise ApiError(status_code=_response.status_code, headers=dict(_response.headers), body=_response.text) + except ValidationError as e: + raise ParsingError( + status_code=_response.status_code, headers=dict(_response.headers), body=_response.json(), cause=e + ) + raise ApiError(status_code=_response.status_code, headers=dict(_response.headers), body=_response_json) + + async def get( + self, id: str, vid: str, *, request_options: typing.Optional[RequestOptions] = None + ) -> AsyncHttpResponse[GetVariationResponseContent]: + """ + Retrieve a single variation by its ID. + + Parameters + ---------- + id : str + The ID of the parent feature flag. + + vid : str + The ID of the variation to retrieve. + + request_options : typing.Optional[RequestOptions] + Request-specific configuration. + + Returns + ------- + AsyncHttpResponse[GetVariationResponseContent] + Variation successfully retrieved. + """ + _response = await self._client_wrapper.httpx_client.request( + f"experimentation/feature-flags/{quote_path_param(id)}/variations/{quote_path_param(vid)}", + method="GET", + request_options=request_options, + ) + try: + if 200 <= _response.status_code < 300: + _data = typing.cast( + GetVariationResponseContent, + parse_obj_as( + type_=GetVariationResponseContent, # type: ignore + object_=_response.json(), + ), + ) + return AsyncHttpResponse(response=_response, data=_data) + if _response.status_code == 401: + raise UnauthorizedError( + headers=dict(_response.headers), + body=typing.cast( + typing.Any, + parse_obj_as( + type_=typing.Any, # type: ignore + object_=_response.json(), + ), + ), + ) + if _response.status_code == 403: + raise ForbiddenError( + headers=dict(_response.headers), + body=typing.cast( + typing.Any, + parse_obj_as( + type_=typing.Any, # type: ignore + object_=_response.json(), + ), + ), + ) + if _response.status_code == 404: + raise NotFoundError( + headers=dict(_response.headers), + body=typing.cast( + typing.Any, + parse_obj_as( + type_=typing.Any, # type: ignore + object_=_response.json(), + ), + ), + ) + if _response.status_code == 429: + raise TooManyRequestsError( + headers=dict(_response.headers), + body=typing.cast( + typing.Any, + parse_obj_as( + type_=typing.Any, # type: ignore + object_=_response.json(), + ), + ), + ) + _response_json = _response.json() + except JSONDecodeError: + raise ApiError(status_code=_response.status_code, headers=dict(_response.headers), body=_response.text) + except ValidationError as e: + raise ParsingError( + status_code=_response.status_code, headers=dict(_response.headers), body=_response.json(), cause=e + ) + raise ApiError(status_code=_response.status_code, headers=dict(_response.headers), body=_response_json) + + async def delete( + self, id: str, vid: str, *, request_options: typing.Optional[RequestOptions] = None + ) -> AsyncHttpResponse[None]: + """ + Delete a variation by ID. Returns 204 if the variation does not exist. Returns 404 if the parent feature flag does not exist. + + Parameters + ---------- + id : str + The ID of the parent feature flag. + + vid : str + The ID of the variation to delete. + + request_options : typing.Optional[RequestOptions] + Request-specific configuration. + + Returns + ------- + AsyncHttpResponse[None] + """ + _response = await self._client_wrapper.httpx_client.request( + f"experimentation/feature-flags/{quote_path_param(id)}/variations/{quote_path_param(vid)}", + method="DELETE", + request_options=request_options, + ) + try: + if 200 <= _response.status_code < 300: + return AsyncHttpResponse(response=_response, data=None) + if _response.status_code == 400: + raise BadRequestError( + headers=dict(_response.headers), + body=typing.cast( + typing.Any, + parse_obj_as( + type_=typing.Any, # type: ignore + object_=_response.json(), + ), + ), + ) + if _response.status_code == 403: + raise ForbiddenError( + headers=dict(_response.headers), + body=typing.cast( + typing.Any, + parse_obj_as( + type_=typing.Any, # type: ignore + object_=_response.json(), + ), + ), + ) + if _response.status_code == 404: + raise NotFoundError( + headers=dict(_response.headers), + body=typing.cast( + typing.Any, + parse_obj_as( + type_=typing.Any, # type: ignore + object_=_response.json(), + ), + ), + ) + if _response.status_code == 409: + raise ConflictError( + headers=dict(_response.headers), + body=typing.cast( + typing.Any, + parse_obj_as( + type_=typing.Any, # type: ignore + object_=_response.json(), + ), + ), + ) + if _response.status_code == 429: + raise TooManyRequestsError( + headers=dict(_response.headers), + body=typing.cast( + typing.Any, + parse_obj_as( + type_=typing.Any, # type: ignore + object_=_response.json(), + ), + ), + ) + _response_json = _response.json() + except JSONDecodeError: + raise ApiError(status_code=_response.status_code, headers=dict(_response.headers), body=_response.text) + except ValidationError as e: + raise ParsingError( + status_code=_response.status_code, headers=dict(_response.headers), body=_response.json(), cause=e + ) + raise ApiError(status_code=_response.status_code, headers=dict(_response.headers), body=_response_json) + + async def update( + self, + id: str, + vid: str, + *, + name: typing.Optional[str] = OMIT, + description: typing.Optional[str] = OMIT, + overrides: typing.Optional[UpdateVariationOverridesMap] = OMIT, + request_options: typing.Optional[RequestOptions] = None, + ) -> AsyncHttpResponse[UpdateVariationResponseContent]: + """ + Partially update a variation by ID. Only provided fields are updated. + + Parameters + ---------- + id : str + The ID of the parent feature flag. + + vid : str + The ID of the variation to update. + + name : typing.Optional[str] + A human-readable name for the variation + + description : typing.Optional[str] + A description of what this variation controls + + overrides : typing.Optional[UpdateVariationOverridesMap] + + request_options : typing.Optional[RequestOptions] + Request-specific configuration. + + Returns + ------- + AsyncHttpResponse[UpdateVariationResponseContent] + Variation successfully updated. + """ + _response = await self._client_wrapper.httpx_client.request( + f"experimentation/feature-flags/{quote_path_param(id)}/variations/{quote_path_param(vid)}", + method="PATCH", + json={ + "name": name, + "description": description, + "overrides": overrides, + }, + headers={ + "content-type": "application/json", + }, + request_options=request_options, + omit=OMIT, + ) + try: + if 200 <= _response.status_code < 300: + _data = typing.cast( + UpdateVariationResponseContent, + parse_obj_as( + type_=UpdateVariationResponseContent, # type: ignore + object_=_response.json(), + ), + ) + return AsyncHttpResponse(response=_response, data=_data) + if _response.status_code == 400: + raise BadRequestError( + headers=dict(_response.headers), + body=typing.cast( + typing.Any, + parse_obj_as( + type_=typing.Any, # type: ignore + object_=_response.json(), + ), + ), + ) + if _response.status_code == 401: + raise UnauthorizedError( + headers=dict(_response.headers), + body=typing.cast( + typing.Any, + parse_obj_as( + type_=typing.Any, # type: ignore + object_=_response.json(), + ), + ), + ) + if _response.status_code == 403: + raise ForbiddenError( + headers=dict(_response.headers), + body=typing.cast( + typing.Any, + parse_obj_as( + type_=typing.Any, # type: ignore + object_=_response.json(), + ), + ), + ) + if _response.status_code == 404: + raise NotFoundError( + headers=dict(_response.headers), + body=typing.cast( + typing.Any, + parse_obj_as( + type_=typing.Any, # type: ignore + object_=_response.json(), + ), + ), + ) + if _response.status_code == 409: + raise ConflictError( + headers=dict(_response.headers), + body=typing.cast( + typing.Any, + parse_obj_as( + type_=typing.Any, # type: ignore + object_=_response.json(), + ), + ), + ) + if _response.status_code == 429: + raise TooManyRequestsError( + headers=dict(_response.headers), + body=typing.cast( + typing.Any, + parse_obj_as( + type_=typing.Any, # type: ignore + object_=_response.json(), + ), + ), + ) + _response_json = _response.json() + except JSONDecodeError: + raise ApiError(status_code=_response.status_code, headers=dict(_response.headers), body=_response.text) + except ValidationError as e: + raise ParsingError( + status_code=_response.status_code, headers=dict(_response.headers), body=_response.json(), cause=e + ) + raise ApiError(status_code=_response.status_code, headers=dict(_response.headers), body=_response_json) diff --git a/src/auth0/management/experimentation/segments/__init__.py b/src/auth0/management/experimentation/segments/__init__.py new file mode 100644 index 00000000..5cde0202 --- /dev/null +++ b/src/auth0/management/experimentation/segments/__init__.py @@ -0,0 +1,4 @@ +# This file was auto-generated by Fern from our API Definition. + +# isort: skip_file + diff --git a/src/auth0/management/experimentation/segments/client.py b/src/auth0/management/experimentation/segments/client.py new file mode 100644 index 00000000..bea2f1da --- /dev/null +++ b/src/auth0/management/experimentation/segments/client.py @@ -0,0 +1,509 @@ +# This file was auto-generated by Fern from our API Definition. + +import typing + +from ...core.client_wrapper import AsyncClientWrapper, SyncClientWrapper +from ...core.pagination import AsyncPager, SyncPager +from ...core.request_options import RequestOptions +from ...types.create_segment_response_content import CreateSegmentResponseContent +from ...types.get_segment_response_content import GetSegmentResponseContent +from ...types.list_segments_response_content import ListSegmentsResponseContent +from ...types.segment import Segment +from ...types.segment_rule import SegmentRule +from ...types.segment_type_filter_enum import SegmentTypeFilterEnum +from ...types.update_segment_response_content import UpdateSegmentResponseContent +from .raw_client import AsyncRawSegmentsClient, RawSegmentsClient + +# this is used as the default value for optional parameters +OMIT = typing.cast(typing.Any, ...) + + +class SegmentsClient: + def __init__(self, *, client_wrapper: SyncClientWrapper): + self._raw_client = RawSegmentsClient(client_wrapper=client_wrapper) + + @property + def with_raw_response(self) -> RawSegmentsClient: + """ + Retrieves a raw implementation of this client that returns raw responses. + + Returns + ------- + RawSegmentsClient + """ + return self._raw_client + + def list( + self, + *, + from_: typing.Optional[str] = None, + take: typing.Optional[int] = 50, + type: typing.Optional[SegmentTypeFilterEnum] = None, + request_options: typing.Optional[RequestOptions] = None, + ) -> SyncPager[Segment, ListSegmentsResponseContent]: + """ + Retrieve a paginated list of segments for the tenant. + + Parameters + ---------- + from_ : typing.Optional[str] + Optional Id from which to start selection. + + take : typing.Optional[int] + Number of segments to return per page. Defaults to 25, maximum 50. + + type : typing.Optional[SegmentTypeFilterEnum] + Filter by type. Exact match. + + request_options : typing.Optional[RequestOptions] + Request-specific configuration. + + Returns + ------- + SyncPager[Segment, ListSegmentsResponseContent] + Segments successfully retrieved. + + Examples + -------- + from auth0 import Auth0 + + client = Auth0( + token="YOUR_TOKEN", + ) + response = client.experimentation.segments.list( + from_="from", + take=1, + type="auth0", + ) + for item in response: + yield item + # alternatively, you can paginate page-by-page + for page in response.iter_pages(): + yield page + """ + return self._raw_client.list(from_=from_, take=take, type=type, request_options=request_options) + + def create( + self, + *, + name: str, + rules: typing.Sequence[SegmentRule], + description: typing.Optional[str] = OMIT, + request_options: typing.Optional[RequestOptions] = None, + ) -> CreateSegmentResponseContent: + """ + Create a new segment with rule-based membership criteria for use in experiments. + + Parameters + ---------- + name : str + A human-readable name for the segment + + rules : typing.Sequence[SegmentRule] + An ordered list of rules. A segment matches if any rule matches. Each rule is limited to 4KB and the whole segment to 10KB (serialized). + + description : typing.Optional[str] + A description of the segment + + request_options : typing.Optional[RequestOptions] + Request-specific configuration. + + Returns + ------- + CreateSegmentResponseContent + Segment successfully created. + + Examples + -------- + from auth0 import Auth0, SegmentRule + + client = Auth0( + token="YOUR_TOKEN", + ) + client.experimentation.segments.create( + name="name", + rules=[SegmentRule()], + ) + """ + _response = self._raw_client.create( + name=name, rules=rules, description=description, request_options=request_options + ) + return _response.data + + def get(self, id: str, *, request_options: typing.Optional[RequestOptions] = None) -> GetSegmentResponseContent: + """ + Retrieve a single segment by its ID. + + Parameters + ---------- + id : str + The ID of the segment to retrieve. + + request_options : typing.Optional[RequestOptions] + Request-specific configuration. + + Returns + ------- + GetSegmentResponseContent + Segment successfully retrieved. + + Examples + -------- + from auth0 import Auth0 + + client = Auth0( + token="YOUR_TOKEN", + ) + client.experimentation.segments.get( + id="id", + ) + """ + _response = self._raw_client.get(id, request_options=request_options) + return _response.data + + def delete(self, id: str, *, request_options: typing.Optional[RequestOptions] = None) -> None: + """ + Delete a segment by ID. Idempotent: returns 204 even if segment does not exist. + + Parameters + ---------- + id : str + The ID of the segment to delete. + + request_options : typing.Optional[RequestOptions] + Request-specific configuration. + + Returns + ------- + None + + Examples + -------- + from auth0 import Auth0 + + client = Auth0( + token="YOUR_TOKEN", + ) + client.experimentation.segments.delete( + id="id", + ) + """ + _response = self._raw_client.delete(id, request_options=request_options) + return _response.data + + def update( + self, + id: str, + *, + name: typing.Optional[str] = OMIT, + description: typing.Optional[str] = OMIT, + rules: typing.Optional[typing.Sequence[SegmentRule]] = OMIT, + request_options: typing.Optional[RequestOptions] = None, + ) -> UpdateSegmentResponseContent: + """ + Partially update a segment by ID. Only provided fields are updated. Sending rules replaces the entire rules array. + + Parameters + ---------- + id : str + The ID of the segment to update. + + name : typing.Optional[str] + A human-readable name for the segment + + description : typing.Optional[str] + A description of the segment + + rules : typing.Optional[typing.Sequence[SegmentRule]] + Replaces the entire rules array. Each rule is limited to 4KB and the whole segment to 10KB (serialized). + + request_options : typing.Optional[RequestOptions] + Request-specific configuration. + + Returns + ------- + UpdateSegmentResponseContent + Segment successfully updated. + + Examples + -------- + from auth0 import Auth0 + + client = Auth0( + token="YOUR_TOKEN", + ) + client.experimentation.segments.update( + id="id", + ) + """ + _response = self._raw_client.update( + id, name=name, description=description, rules=rules, request_options=request_options + ) + return _response.data + + +class AsyncSegmentsClient: + def __init__(self, *, client_wrapper: AsyncClientWrapper): + self._raw_client = AsyncRawSegmentsClient(client_wrapper=client_wrapper) + + @property + def with_raw_response(self) -> AsyncRawSegmentsClient: + """ + Retrieves a raw implementation of this client that returns raw responses. + + Returns + ------- + AsyncRawSegmentsClient + """ + return self._raw_client + + async def list( + self, + *, + from_: typing.Optional[str] = None, + take: typing.Optional[int] = 50, + type: typing.Optional[SegmentTypeFilterEnum] = None, + request_options: typing.Optional[RequestOptions] = None, + ) -> AsyncPager[Segment, ListSegmentsResponseContent]: + """ + Retrieve a paginated list of segments for the tenant. + + Parameters + ---------- + from_ : typing.Optional[str] + Optional Id from which to start selection. + + take : typing.Optional[int] + Number of segments to return per page. Defaults to 25, maximum 50. + + type : typing.Optional[SegmentTypeFilterEnum] + Filter by type. Exact match. + + request_options : typing.Optional[RequestOptions] + Request-specific configuration. + + Returns + ------- + AsyncPager[Segment, ListSegmentsResponseContent] + Segments successfully retrieved. + + Examples + -------- + import asyncio + + from auth0 import AsyncAuth0 + + client = AsyncAuth0( + token="YOUR_TOKEN", + ) + + + async def main() -> None: + response = await client.experimentation.segments.list( + from_="from", + take=1, + type="auth0", + ) + async for item in response: + yield item + + # alternatively, you can paginate page-by-page + async for page in response.iter_pages(): + yield page + + + asyncio.run(main()) + """ + return await self._raw_client.list(from_=from_, take=take, type=type, request_options=request_options) + + async def create( + self, + *, + name: str, + rules: typing.Sequence[SegmentRule], + description: typing.Optional[str] = OMIT, + request_options: typing.Optional[RequestOptions] = None, + ) -> CreateSegmentResponseContent: + """ + Create a new segment with rule-based membership criteria for use in experiments. + + Parameters + ---------- + name : str + A human-readable name for the segment + + rules : typing.Sequence[SegmentRule] + An ordered list of rules. A segment matches if any rule matches. Each rule is limited to 4KB and the whole segment to 10KB (serialized). + + description : typing.Optional[str] + A description of the segment + + request_options : typing.Optional[RequestOptions] + Request-specific configuration. + + Returns + ------- + CreateSegmentResponseContent + Segment successfully created. + + Examples + -------- + import asyncio + + from auth0 import AsyncAuth0, SegmentRule + + client = AsyncAuth0( + token="YOUR_TOKEN", + ) + + + async def main() -> None: + await client.experimentation.segments.create( + name="name", + rules=[SegmentRule()], + ) + + + asyncio.run(main()) + """ + _response = await self._raw_client.create( + name=name, rules=rules, description=description, request_options=request_options + ) + return _response.data + + async def get( + self, id: str, *, request_options: typing.Optional[RequestOptions] = None + ) -> GetSegmentResponseContent: + """ + Retrieve a single segment by its ID. + + Parameters + ---------- + id : str + The ID of the segment to retrieve. + + request_options : typing.Optional[RequestOptions] + Request-specific configuration. + + Returns + ------- + GetSegmentResponseContent + Segment successfully retrieved. + + Examples + -------- + import asyncio + + from auth0 import AsyncAuth0 + + client = AsyncAuth0( + token="YOUR_TOKEN", + ) + + + async def main() -> None: + await client.experimentation.segments.get( + id="id", + ) + + + asyncio.run(main()) + """ + _response = await self._raw_client.get(id, request_options=request_options) + return _response.data + + async def delete(self, id: str, *, request_options: typing.Optional[RequestOptions] = None) -> None: + """ + Delete a segment by ID. Idempotent: returns 204 even if segment does not exist. + + Parameters + ---------- + id : str + The ID of the segment to delete. + + request_options : typing.Optional[RequestOptions] + Request-specific configuration. + + Returns + ------- + None + + Examples + -------- + import asyncio + + from auth0 import AsyncAuth0 + + client = AsyncAuth0( + token="YOUR_TOKEN", + ) + + + async def main() -> None: + await client.experimentation.segments.delete( + id="id", + ) + + + asyncio.run(main()) + """ + _response = await self._raw_client.delete(id, request_options=request_options) + return _response.data + + async def update( + self, + id: str, + *, + name: typing.Optional[str] = OMIT, + description: typing.Optional[str] = OMIT, + rules: typing.Optional[typing.Sequence[SegmentRule]] = OMIT, + request_options: typing.Optional[RequestOptions] = None, + ) -> UpdateSegmentResponseContent: + """ + Partially update a segment by ID. Only provided fields are updated. Sending rules replaces the entire rules array. + + Parameters + ---------- + id : str + The ID of the segment to update. + + name : typing.Optional[str] + A human-readable name for the segment + + description : typing.Optional[str] + A description of the segment + + rules : typing.Optional[typing.Sequence[SegmentRule]] + Replaces the entire rules array. Each rule is limited to 4KB and the whole segment to 10KB (serialized). + + request_options : typing.Optional[RequestOptions] + Request-specific configuration. + + Returns + ------- + UpdateSegmentResponseContent + Segment successfully updated. + + Examples + -------- + import asyncio + + from auth0 import AsyncAuth0 + + client = AsyncAuth0( + token="YOUR_TOKEN", + ) + + + async def main() -> None: + await client.experimentation.segments.update( + id="id", + ) + + + asyncio.run(main()) + """ + _response = await self._raw_client.update( + id, name=name, description=description, rules=rules, request_options=request_options + ) + return _response.data diff --git a/src/auth0/management/experimentation/segments/raw_client.py b/src/auth0/management/experimentation/segments/raw_client.py new file mode 100644 index 00000000..998cfba2 --- /dev/null +++ b/src/auth0/management/experimentation/segments/raw_client.py @@ -0,0 +1,1131 @@ +# This file was auto-generated by Fern from our API Definition. + +import typing +from json.decoder import JSONDecodeError + +from ...core.api_error import ApiError +from ...core.client_wrapper import AsyncClientWrapper, SyncClientWrapper +from ...core.http_response import AsyncHttpResponse, HttpResponse +from ...core.jsonable_encoder import quote_path_param +from ...core.pagination import AsyncPager, SyncPager +from ...core.parse_error import ParsingError +from ...core.pydantic_utilities import parse_obj_as +from ...core.request_options import RequestOptions +from ...core.serialization import convert_and_respect_annotation_metadata +from ...errors.bad_request_error import BadRequestError +from ...errors.conflict_error import ConflictError +from ...errors.forbidden_error import ForbiddenError +from ...errors.not_found_error import NotFoundError +from ...errors.too_many_requests_error import TooManyRequestsError +from ...errors.unauthorized_error import UnauthorizedError +from ...errors.unprocessable_entity_error import UnprocessableEntityError +from ...types.create_segment_response_content import CreateSegmentResponseContent +from ...types.get_segment_response_content import GetSegmentResponseContent +from ...types.list_segments_response_content import ListSegmentsResponseContent +from ...types.segment import Segment +from ...types.segment_rule import SegmentRule +from ...types.segment_type_filter_enum import SegmentTypeFilterEnum +from ...types.update_segment_response_content import UpdateSegmentResponseContent +from pydantic import ValidationError + +# this is used as the default value for optional parameters +OMIT = typing.cast(typing.Any, ...) + + +class RawSegmentsClient: + def __init__(self, *, client_wrapper: SyncClientWrapper): + self._client_wrapper = client_wrapper + + def list( + self, + *, + from_: typing.Optional[str] = None, + take: typing.Optional[int] = 50, + type: typing.Optional[SegmentTypeFilterEnum] = None, + request_options: typing.Optional[RequestOptions] = None, + ) -> SyncPager[Segment, ListSegmentsResponseContent]: + """ + Retrieve a paginated list of segments for the tenant. + + Parameters + ---------- + from_ : typing.Optional[str] + Optional Id from which to start selection. + + take : typing.Optional[int] + Number of segments to return per page. Defaults to 25, maximum 50. + + type : typing.Optional[SegmentTypeFilterEnum] + Filter by type. Exact match. + + request_options : typing.Optional[RequestOptions] + Request-specific configuration. + + Returns + ------- + SyncPager[Segment, ListSegmentsResponseContent] + Segments successfully retrieved. + """ + _response = self._client_wrapper.httpx_client.request( + "experimentation/segments", + method="GET", + params={ + "from": from_, + "take": take, + "type": type, + }, + request_options=request_options, + ) + try: + if 200 <= _response.status_code < 300: + _parsed_response = typing.cast( + ListSegmentsResponseContent, + parse_obj_as( + type_=ListSegmentsResponseContent, # type: ignore + object_=_response.json(), + ), + ) + _items = _parsed_response.segments + _parsed_next = _parsed_response.next + _has_next = _parsed_next is not None and _parsed_next != "" + _get_next = lambda: self.list( + from_=_parsed_next, + take=take, + type=type, + request_options=request_options, + ) + return SyncPager(has_next=_has_next, items=_items, get_next=_get_next, response=_parsed_response) + if _response.status_code == 400: + raise BadRequestError( + headers=dict(_response.headers), + body=typing.cast( + typing.Any, + parse_obj_as( + type_=typing.Any, # type: ignore + object_=_response.json(), + ), + ), + ) + if _response.status_code == 401: + raise UnauthorizedError( + headers=dict(_response.headers), + body=typing.cast( + typing.Any, + parse_obj_as( + type_=typing.Any, # type: ignore + object_=_response.json(), + ), + ), + ) + if _response.status_code == 403: + raise ForbiddenError( + headers=dict(_response.headers), + body=typing.cast( + typing.Any, + parse_obj_as( + type_=typing.Any, # type: ignore + object_=_response.json(), + ), + ), + ) + if _response.status_code == 429: + raise TooManyRequestsError( + headers=dict(_response.headers), + body=typing.cast( + typing.Any, + parse_obj_as( + type_=typing.Any, # type: ignore + object_=_response.json(), + ), + ), + ) + _response_json = _response.json() + except JSONDecodeError: + raise ApiError(status_code=_response.status_code, headers=dict(_response.headers), body=_response.text) + except ValidationError as e: + raise ParsingError( + status_code=_response.status_code, headers=dict(_response.headers), body=_response.json(), cause=e + ) + raise ApiError(status_code=_response.status_code, headers=dict(_response.headers), body=_response_json) + + def create( + self, + *, + name: str, + rules: typing.Sequence[SegmentRule], + description: typing.Optional[str] = OMIT, + request_options: typing.Optional[RequestOptions] = None, + ) -> HttpResponse[CreateSegmentResponseContent]: + """ + Create a new segment with rule-based membership criteria for use in experiments. + + Parameters + ---------- + name : str + A human-readable name for the segment + + rules : typing.Sequence[SegmentRule] + An ordered list of rules. A segment matches if any rule matches. Each rule is limited to 4KB and the whole segment to 10KB (serialized). + + description : typing.Optional[str] + A description of the segment + + request_options : typing.Optional[RequestOptions] + Request-specific configuration. + + Returns + ------- + HttpResponse[CreateSegmentResponseContent] + Segment successfully created. + """ + _response = self._client_wrapper.httpx_client.request( + "experimentation/segments", + method="POST", + json={ + "name": name, + "description": description, + "rules": convert_and_respect_annotation_metadata( + object_=rules, annotation=typing.Sequence[SegmentRule], direction="write" + ), + }, + headers={ + "content-type": "application/json", + }, + request_options=request_options, + omit=OMIT, + ) + try: + if 200 <= _response.status_code < 300: + _data = typing.cast( + CreateSegmentResponseContent, + parse_obj_as( + type_=CreateSegmentResponseContent, # type: ignore + object_=_response.json(), + ), + ) + return HttpResponse(response=_response, data=_data) + if _response.status_code == 400: + raise BadRequestError( + headers=dict(_response.headers), + body=typing.cast( + typing.Any, + parse_obj_as( + type_=typing.Any, # type: ignore + object_=_response.json(), + ), + ), + ) + if _response.status_code == 401: + raise UnauthorizedError( + headers=dict(_response.headers), + body=typing.cast( + typing.Any, + parse_obj_as( + type_=typing.Any, # type: ignore + object_=_response.json(), + ), + ), + ) + if _response.status_code == 403: + raise ForbiddenError( + headers=dict(_response.headers), + body=typing.cast( + typing.Any, + parse_obj_as( + type_=typing.Any, # type: ignore + object_=_response.json(), + ), + ), + ) + if _response.status_code == 409: + raise ConflictError( + headers=dict(_response.headers), + body=typing.cast( + typing.Any, + parse_obj_as( + type_=typing.Any, # type: ignore + object_=_response.json(), + ), + ), + ) + if _response.status_code == 422: + raise UnprocessableEntityError( + headers=dict(_response.headers), + body=typing.cast( + typing.Any, + parse_obj_as( + type_=typing.Any, # type: ignore + object_=_response.json(), + ), + ), + ) + if _response.status_code == 429: + raise TooManyRequestsError( + headers=dict(_response.headers), + body=typing.cast( + typing.Any, + parse_obj_as( + type_=typing.Any, # type: ignore + object_=_response.json(), + ), + ), + ) + _response_json = _response.json() + except JSONDecodeError: + raise ApiError(status_code=_response.status_code, headers=dict(_response.headers), body=_response.text) + except ValidationError as e: + raise ParsingError( + status_code=_response.status_code, headers=dict(_response.headers), body=_response.json(), cause=e + ) + raise ApiError(status_code=_response.status_code, headers=dict(_response.headers), body=_response_json) + + def get( + self, id: str, *, request_options: typing.Optional[RequestOptions] = None + ) -> HttpResponse[GetSegmentResponseContent]: + """ + Retrieve a single segment by its ID. + + Parameters + ---------- + id : str + The ID of the segment to retrieve. + + request_options : typing.Optional[RequestOptions] + Request-specific configuration. + + Returns + ------- + HttpResponse[GetSegmentResponseContent] + Segment successfully retrieved. + """ + _response = self._client_wrapper.httpx_client.request( + f"experimentation/segments/{quote_path_param(id)}", + method="GET", + request_options=request_options, + ) + try: + if 200 <= _response.status_code < 300: + _data = typing.cast( + GetSegmentResponseContent, + parse_obj_as( + type_=GetSegmentResponseContent, # type: ignore + object_=_response.json(), + ), + ) + return HttpResponse(response=_response, data=_data) + if _response.status_code == 401: + raise UnauthorizedError( + headers=dict(_response.headers), + body=typing.cast( + typing.Any, + parse_obj_as( + type_=typing.Any, # type: ignore + object_=_response.json(), + ), + ), + ) + if _response.status_code == 403: + raise ForbiddenError( + headers=dict(_response.headers), + body=typing.cast( + typing.Any, + parse_obj_as( + type_=typing.Any, # type: ignore + object_=_response.json(), + ), + ), + ) + if _response.status_code == 404: + raise NotFoundError( + headers=dict(_response.headers), + body=typing.cast( + typing.Any, + parse_obj_as( + type_=typing.Any, # type: ignore + object_=_response.json(), + ), + ), + ) + if _response.status_code == 429: + raise TooManyRequestsError( + headers=dict(_response.headers), + body=typing.cast( + typing.Any, + parse_obj_as( + type_=typing.Any, # type: ignore + object_=_response.json(), + ), + ), + ) + _response_json = _response.json() + except JSONDecodeError: + raise ApiError(status_code=_response.status_code, headers=dict(_response.headers), body=_response.text) + except ValidationError as e: + raise ParsingError( + status_code=_response.status_code, headers=dict(_response.headers), body=_response.json(), cause=e + ) + raise ApiError(status_code=_response.status_code, headers=dict(_response.headers), body=_response_json) + + def delete(self, id: str, *, request_options: typing.Optional[RequestOptions] = None) -> HttpResponse[None]: + """ + Delete a segment by ID. Idempotent: returns 204 even if segment does not exist. + + Parameters + ---------- + id : str + The ID of the segment to delete. + + request_options : typing.Optional[RequestOptions] + Request-specific configuration. + + Returns + ------- + HttpResponse[None] + """ + _response = self._client_wrapper.httpx_client.request( + f"experimentation/segments/{quote_path_param(id)}", + method="DELETE", + request_options=request_options, + ) + try: + if 200 <= _response.status_code < 300: + return HttpResponse(response=_response, data=None) + if _response.status_code == 403: + raise ForbiddenError( + headers=dict(_response.headers), + body=typing.cast( + typing.Any, + parse_obj_as( + type_=typing.Any, # type: ignore + object_=_response.json(), + ), + ), + ) + if _response.status_code == 409: + raise ConflictError( + headers=dict(_response.headers), + body=typing.cast( + typing.Any, + parse_obj_as( + type_=typing.Any, # type: ignore + object_=_response.json(), + ), + ), + ) + if _response.status_code == 429: + raise TooManyRequestsError( + headers=dict(_response.headers), + body=typing.cast( + typing.Any, + parse_obj_as( + type_=typing.Any, # type: ignore + object_=_response.json(), + ), + ), + ) + _response_json = _response.json() + except JSONDecodeError: + raise ApiError(status_code=_response.status_code, headers=dict(_response.headers), body=_response.text) + except ValidationError as e: + raise ParsingError( + status_code=_response.status_code, headers=dict(_response.headers), body=_response.json(), cause=e + ) + raise ApiError(status_code=_response.status_code, headers=dict(_response.headers), body=_response_json) + + def update( + self, + id: str, + *, + name: typing.Optional[str] = OMIT, + description: typing.Optional[str] = OMIT, + rules: typing.Optional[typing.Sequence[SegmentRule]] = OMIT, + request_options: typing.Optional[RequestOptions] = None, + ) -> HttpResponse[UpdateSegmentResponseContent]: + """ + Partially update a segment by ID. Only provided fields are updated. Sending rules replaces the entire rules array. + + Parameters + ---------- + id : str + The ID of the segment to update. + + name : typing.Optional[str] + A human-readable name for the segment + + description : typing.Optional[str] + A description of the segment + + rules : typing.Optional[typing.Sequence[SegmentRule]] + Replaces the entire rules array. Each rule is limited to 4KB and the whole segment to 10KB (serialized). + + request_options : typing.Optional[RequestOptions] + Request-specific configuration. + + Returns + ------- + HttpResponse[UpdateSegmentResponseContent] + Segment successfully updated. + """ + _response = self._client_wrapper.httpx_client.request( + f"experimentation/segments/{quote_path_param(id)}", + method="PATCH", + json={ + "name": name, + "description": description, + "rules": convert_and_respect_annotation_metadata( + object_=rules, annotation=typing.Sequence[SegmentRule], direction="write" + ), + }, + headers={ + "content-type": "application/json", + }, + request_options=request_options, + omit=OMIT, + ) + try: + if 200 <= _response.status_code < 300: + _data = typing.cast( + UpdateSegmentResponseContent, + parse_obj_as( + type_=UpdateSegmentResponseContent, # type: ignore + object_=_response.json(), + ), + ) + return HttpResponse(response=_response, data=_data) + if _response.status_code == 400: + raise BadRequestError( + headers=dict(_response.headers), + body=typing.cast( + typing.Any, + parse_obj_as( + type_=typing.Any, # type: ignore + object_=_response.json(), + ), + ), + ) + if _response.status_code == 401: + raise UnauthorizedError( + headers=dict(_response.headers), + body=typing.cast( + typing.Any, + parse_obj_as( + type_=typing.Any, # type: ignore + object_=_response.json(), + ), + ), + ) + if _response.status_code == 403: + raise ForbiddenError( + headers=dict(_response.headers), + body=typing.cast( + typing.Any, + parse_obj_as( + type_=typing.Any, # type: ignore + object_=_response.json(), + ), + ), + ) + if _response.status_code == 404: + raise NotFoundError( + headers=dict(_response.headers), + body=typing.cast( + typing.Any, + parse_obj_as( + type_=typing.Any, # type: ignore + object_=_response.json(), + ), + ), + ) + if _response.status_code == 409: + raise ConflictError( + headers=dict(_response.headers), + body=typing.cast( + typing.Any, + parse_obj_as( + type_=typing.Any, # type: ignore + object_=_response.json(), + ), + ), + ) + if _response.status_code == 422: + raise UnprocessableEntityError( + headers=dict(_response.headers), + body=typing.cast( + typing.Any, + parse_obj_as( + type_=typing.Any, # type: ignore + object_=_response.json(), + ), + ), + ) + if _response.status_code == 429: + raise TooManyRequestsError( + headers=dict(_response.headers), + body=typing.cast( + typing.Any, + parse_obj_as( + type_=typing.Any, # type: ignore + object_=_response.json(), + ), + ), + ) + _response_json = _response.json() + except JSONDecodeError: + raise ApiError(status_code=_response.status_code, headers=dict(_response.headers), body=_response.text) + except ValidationError as e: + raise ParsingError( + status_code=_response.status_code, headers=dict(_response.headers), body=_response.json(), cause=e + ) + raise ApiError(status_code=_response.status_code, headers=dict(_response.headers), body=_response_json) + + +class AsyncRawSegmentsClient: + def __init__(self, *, client_wrapper: AsyncClientWrapper): + self._client_wrapper = client_wrapper + + async def list( + self, + *, + from_: typing.Optional[str] = None, + take: typing.Optional[int] = 50, + type: typing.Optional[SegmentTypeFilterEnum] = None, + request_options: typing.Optional[RequestOptions] = None, + ) -> AsyncPager[Segment, ListSegmentsResponseContent]: + """ + Retrieve a paginated list of segments for the tenant. + + Parameters + ---------- + from_ : typing.Optional[str] + Optional Id from which to start selection. + + take : typing.Optional[int] + Number of segments to return per page. Defaults to 25, maximum 50. + + type : typing.Optional[SegmentTypeFilterEnum] + Filter by type. Exact match. + + request_options : typing.Optional[RequestOptions] + Request-specific configuration. + + Returns + ------- + AsyncPager[Segment, ListSegmentsResponseContent] + Segments successfully retrieved. + """ + _response = await self._client_wrapper.httpx_client.request( + "experimentation/segments", + method="GET", + params={ + "from": from_, + "take": take, + "type": type, + }, + request_options=request_options, + ) + try: + if 200 <= _response.status_code < 300: + _parsed_response = typing.cast( + ListSegmentsResponseContent, + parse_obj_as( + type_=ListSegmentsResponseContent, # type: ignore + object_=_response.json(), + ), + ) + _items = _parsed_response.segments + _parsed_next = _parsed_response.next + _has_next = _parsed_next is not None and _parsed_next != "" + + async def _get_next(): + return await self.list( + from_=_parsed_next, + take=take, + type=type, + request_options=request_options, + ) + + return AsyncPager(has_next=_has_next, items=_items, get_next=_get_next, response=_parsed_response) + if _response.status_code == 400: + raise BadRequestError( + headers=dict(_response.headers), + body=typing.cast( + typing.Any, + parse_obj_as( + type_=typing.Any, # type: ignore + object_=_response.json(), + ), + ), + ) + if _response.status_code == 401: + raise UnauthorizedError( + headers=dict(_response.headers), + body=typing.cast( + typing.Any, + parse_obj_as( + type_=typing.Any, # type: ignore + object_=_response.json(), + ), + ), + ) + if _response.status_code == 403: + raise ForbiddenError( + headers=dict(_response.headers), + body=typing.cast( + typing.Any, + parse_obj_as( + type_=typing.Any, # type: ignore + object_=_response.json(), + ), + ), + ) + if _response.status_code == 429: + raise TooManyRequestsError( + headers=dict(_response.headers), + body=typing.cast( + typing.Any, + parse_obj_as( + type_=typing.Any, # type: ignore + object_=_response.json(), + ), + ), + ) + _response_json = _response.json() + except JSONDecodeError: + raise ApiError(status_code=_response.status_code, headers=dict(_response.headers), body=_response.text) + except ValidationError as e: + raise ParsingError( + status_code=_response.status_code, headers=dict(_response.headers), body=_response.json(), cause=e + ) + raise ApiError(status_code=_response.status_code, headers=dict(_response.headers), body=_response_json) + + async def create( + self, + *, + name: str, + rules: typing.Sequence[SegmentRule], + description: typing.Optional[str] = OMIT, + request_options: typing.Optional[RequestOptions] = None, + ) -> AsyncHttpResponse[CreateSegmentResponseContent]: + """ + Create a new segment with rule-based membership criteria for use in experiments. + + Parameters + ---------- + name : str + A human-readable name for the segment + + rules : typing.Sequence[SegmentRule] + An ordered list of rules. A segment matches if any rule matches. Each rule is limited to 4KB and the whole segment to 10KB (serialized). + + description : typing.Optional[str] + A description of the segment + + request_options : typing.Optional[RequestOptions] + Request-specific configuration. + + Returns + ------- + AsyncHttpResponse[CreateSegmentResponseContent] + Segment successfully created. + """ + _response = await self._client_wrapper.httpx_client.request( + "experimentation/segments", + method="POST", + json={ + "name": name, + "description": description, + "rules": convert_and_respect_annotation_metadata( + object_=rules, annotation=typing.Sequence[SegmentRule], direction="write" + ), + }, + headers={ + "content-type": "application/json", + }, + request_options=request_options, + omit=OMIT, + ) + try: + if 200 <= _response.status_code < 300: + _data = typing.cast( + CreateSegmentResponseContent, + parse_obj_as( + type_=CreateSegmentResponseContent, # type: ignore + object_=_response.json(), + ), + ) + return AsyncHttpResponse(response=_response, data=_data) + if _response.status_code == 400: + raise BadRequestError( + headers=dict(_response.headers), + body=typing.cast( + typing.Any, + parse_obj_as( + type_=typing.Any, # type: ignore + object_=_response.json(), + ), + ), + ) + if _response.status_code == 401: + raise UnauthorizedError( + headers=dict(_response.headers), + body=typing.cast( + typing.Any, + parse_obj_as( + type_=typing.Any, # type: ignore + object_=_response.json(), + ), + ), + ) + if _response.status_code == 403: + raise ForbiddenError( + headers=dict(_response.headers), + body=typing.cast( + typing.Any, + parse_obj_as( + type_=typing.Any, # type: ignore + object_=_response.json(), + ), + ), + ) + if _response.status_code == 409: + raise ConflictError( + headers=dict(_response.headers), + body=typing.cast( + typing.Any, + parse_obj_as( + type_=typing.Any, # type: ignore + object_=_response.json(), + ), + ), + ) + if _response.status_code == 422: + raise UnprocessableEntityError( + headers=dict(_response.headers), + body=typing.cast( + typing.Any, + parse_obj_as( + type_=typing.Any, # type: ignore + object_=_response.json(), + ), + ), + ) + if _response.status_code == 429: + raise TooManyRequestsError( + headers=dict(_response.headers), + body=typing.cast( + typing.Any, + parse_obj_as( + type_=typing.Any, # type: ignore + object_=_response.json(), + ), + ), + ) + _response_json = _response.json() + except JSONDecodeError: + raise ApiError(status_code=_response.status_code, headers=dict(_response.headers), body=_response.text) + except ValidationError as e: + raise ParsingError( + status_code=_response.status_code, headers=dict(_response.headers), body=_response.json(), cause=e + ) + raise ApiError(status_code=_response.status_code, headers=dict(_response.headers), body=_response_json) + + async def get( + self, id: str, *, request_options: typing.Optional[RequestOptions] = None + ) -> AsyncHttpResponse[GetSegmentResponseContent]: + """ + Retrieve a single segment by its ID. + + Parameters + ---------- + id : str + The ID of the segment to retrieve. + + request_options : typing.Optional[RequestOptions] + Request-specific configuration. + + Returns + ------- + AsyncHttpResponse[GetSegmentResponseContent] + Segment successfully retrieved. + """ + _response = await self._client_wrapper.httpx_client.request( + f"experimentation/segments/{quote_path_param(id)}", + method="GET", + request_options=request_options, + ) + try: + if 200 <= _response.status_code < 300: + _data = typing.cast( + GetSegmentResponseContent, + parse_obj_as( + type_=GetSegmentResponseContent, # type: ignore + object_=_response.json(), + ), + ) + return AsyncHttpResponse(response=_response, data=_data) + if _response.status_code == 401: + raise UnauthorizedError( + headers=dict(_response.headers), + body=typing.cast( + typing.Any, + parse_obj_as( + type_=typing.Any, # type: ignore + object_=_response.json(), + ), + ), + ) + if _response.status_code == 403: + raise ForbiddenError( + headers=dict(_response.headers), + body=typing.cast( + typing.Any, + parse_obj_as( + type_=typing.Any, # type: ignore + object_=_response.json(), + ), + ), + ) + if _response.status_code == 404: + raise NotFoundError( + headers=dict(_response.headers), + body=typing.cast( + typing.Any, + parse_obj_as( + type_=typing.Any, # type: ignore + object_=_response.json(), + ), + ), + ) + if _response.status_code == 429: + raise TooManyRequestsError( + headers=dict(_response.headers), + body=typing.cast( + typing.Any, + parse_obj_as( + type_=typing.Any, # type: ignore + object_=_response.json(), + ), + ), + ) + _response_json = _response.json() + except JSONDecodeError: + raise ApiError(status_code=_response.status_code, headers=dict(_response.headers), body=_response.text) + except ValidationError as e: + raise ParsingError( + status_code=_response.status_code, headers=dict(_response.headers), body=_response.json(), cause=e + ) + raise ApiError(status_code=_response.status_code, headers=dict(_response.headers), body=_response_json) + + async def delete( + self, id: str, *, request_options: typing.Optional[RequestOptions] = None + ) -> AsyncHttpResponse[None]: + """ + Delete a segment by ID. Idempotent: returns 204 even if segment does not exist. + + Parameters + ---------- + id : str + The ID of the segment to delete. + + request_options : typing.Optional[RequestOptions] + Request-specific configuration. + + Returns + ------- + AsyncHttpResponse[None] + """ + _response = await self._client_wrapper.httpx_client.request( + f"experimentation/segments/{quote_path_param(id)}", + method="DELETE", + request_options=request_options, + ) + try: + if 200 <= _response.status_code < 300: + return AsyncHttpResponse(response=_response, data=None) + if _response.status_code == 403: + raise ForbiddenError( + headers=dict(_response.headers), + body=typing.cast( + typing.Any, + parse_obj_as( + type_=typing.Any, # type: ignore + object_=_response.json(), + ), + ), + ) + if _response.status_code == 409: + raise ConflictError( + headers=dict(_response.headers), + body=typing.cast( + typing.Any, + parse_obj_as( + type_=typing.Any, # type: ignore + object_=_response.json(), + ), + ), + ) + if _response.status_code == 429: + raise TooManyRequestsError( + headers=dict(_response.headers), + body=typing.cast( + typing.Any, + parse_obj_as( + type_=typing.Any, # type: ignore + object_=_response.json(), + ), + ), + ) + _response_json = _response.json() + except JSONDecodeError: + raise ApiError(status_code=_response.status_code, headers=dict(_response.headers), body=_response.text) + except ValidationError as e: + raise ParsingError( + status_code=_response.status_code, headers=dict(_response.headers), body=_response.json(), cause=e + ) + raise ApiError(status_code=_response.status_code, headers=dict(_response.headers), body=_response_json) + + async def update( + self, + id: str, + *, + name: typing.Optional[str] = OMIT, + description: typing.Optional[str] = OMIT, + rules: typing.Optional[typing.Sequence[SegmentRule]] = OMIT, + request_options: typing.Optional[RequestOptions] = None, + ) -> AsyncHttpResponse[UpdateSegmentResponseContent]: + """ + Partially update a segment by ID. Only provided fields are updated. Sending rules replaces the entire rules array. + + Parameters + ---------- + id : str + The ID of the segment to update. + + name : typing.Optional[str] + A human-readable name for the segment + + description : typing.Optional[str] + A description of the segment + + rules : typing.Optional[typing.Sequence[SegmentRule]] + Replaces the entire rules array. Each rule is limited to 4KB and the whole segment to 10KB (serialized). + + request_options : typing.Optional[RequestOptions] + Request-specific configuration. + + Returns + ------- + AsyncHttpResponse[UpdateSegmentResponseContent] + Segment successfully updated. + """ + _response = await self._client_wrapper.httpx_client.request( + f"experimentation/segments/{quote_path_param(id)}", + method="PATCH", + json={ + "name": name, + "description": description, + "rules": convert_and_respect_annotation_metadata( + object_=rules, annotation=typing.Sequence[SegmentRule], direction="write" + ), + }, + headers={ + "content-type": "application/json", + }, + request_options=request_options, + omit=OMIT, + ) + try: + if 200 <= _response.status_code < 300: + _data = typing.cast( + UpdateSegmentResponseContent, + parse_obj_as( + type_=UpdateSegmentResponseContent, # type: ignore + object_=_response.json(), + ), + ) + return AsyncHttpResponse(response=_response, data=_data) + if _response.status_code == 400: + raise BadRequestError( + headers=dict(_response.headers), + body=typing.cast( + typing.Any, + parse_obj_as( + type_=typing.Any, # type: ignore + object_=_response.json(), + ), + ), + ) + if _response.status_code == 401: + raise UnauthorizedError( + headers=dict(_response.headers), + body=typing.cast( + typing.Any, + parse_obj_as( + type_=typing.Any, # type: ignore + object_=_response.json(), + ), + ), + ) + if _response.status_code == 403: + raise ForbiddenError( + headers=dict(_response.headers), + body=typing.cast( + typing.Any, + parse_obj_as( + type_=typing.Any, # type: ignore + object_=_response.json(), + ), + ), + ) + if _response.status_code == 404: + raise NotFoundError( + headers=dict(_response.headers), + body=typing.cast( + typing.Any, + parse_obj_as( + type_=typing.Any, # type: ignore + object_=_response.json(), + ), + ), + ) + if _response.status_code == 409: + raise ConflictError( + headers=dict(_response.headers), + body=typing.cast( + typing.Any, + parse_obj_as( + type_=typing.Any, # type: ignore + object_=_response.json(), + ), + ), + ) + if _response.status_code == 422: + raise UnprocessableEntityError( + headers=dict(_response.headers), + body=typing.cast( + typing.Any, + parse_obj_as( + type_=typing.Any, # type: ignore + object_=_response.json(), + ), + ), + ) + if _response.status_code == 429: + raise TooManyRequestsError( + headers=dict(_response.headers), + body=typing.cast( + typing.Any, + parse_obj_as( + type_=typing.Any, # type: ignore + object_=_response.json(), + ), + ), + ) + _response_json = _response.json() + except JSONDecodeError: + raise ApiError(status_code=_response.status_code, headers=dict(_response.headers), body=_response.text) + except ValidationError as e: + raise ParsingError( + status_code=_response.status_code, headers=dict(_response.headers), body=_response.json(), cause=e + ) + raise ApiError(status_code=_response.status_code, headers=dict(_response.headers), body=_response_json) diff --git a/src/auth0/management/organizations/__init__.py b/src/auth0/management/organizations/__init__.py index bc43123f..079f5c6d 100644 --- a/src/auth0/management/organizations/__init__.py +++ b/src/auth0/management/organizations/__init__.py @@ -15,7 +15,6 @@ groups, invitations, members, - organization_template, roles, ) _dynamic_imports: typing.Dict[str, str] = { @@ -27,7 +26,6 @@ "groups": ".groups", "invitations": ".invitations", "members": ".members", - "organization_template": ".organization_template", "roles": ".roles", } @@ -62,6 +60,5 @@ def __dir__(): "groups", "invitations", "members", - "organization_template", "roles", ] diff --git a/src/auth0/management/organizations/client.py b/src/auth0/management/organizations/client.py index 0299632d..ea655744 100644 --- a/src/auth0/management/organizations/client.py +++ b/src/auth0/management/organizations/client.py @@ -34,7 +34,6 @@ from .groups.client import AsyncGroupsClient, GroupsClient from .invitations.client import AsyncInvitationsClient, InvitationsClient from .members.client import AsyncMembersClient, MembersClient - from .organization_template.client import AsyncOrganizationTemplateClient, OrganizationTemplateClient from .roles.client import AsyncRolesClient, RolesClient # this is used as the default value for optional parameters OMIT = typing.cast(typing.Any, ...) @@ -51,7 +50,6 @@ def __init__(self, *, client_wrapper: SyncClientWrapper): self._enabled_connections: typing.Optional[EnabledConnectionsClient] = None self._invitations: typing.Optional[InvitationsClient] = None self._members: typing.Optional[MembersClient] = None - self._organization_template: typing.Optional[OrganizationTemplateClient] = None self._groups: typing.Optional[GroupsClient] = None self._roles: typing.Optional[RolesClient] = None @@ -519,14 +517,6 @@ def members(self): self._members = MembersClient(client_wrapper=self._client_wrapper) return self._members - @property - def organization_template(self): - if self._organization_template is None: - from .organization_template.client import OrganizationTemplateClient # noqa: E402 - - self._organization_template = OrganizationTemplateClient(client_wrapper=self._client_wrapper) - return self._organization_template - @property def groups(self): if self._groups is None: @@ -555,7 +545,6 @@ def __init__(self, *, client_wrapper: AsyncClientWrapper): self._enabled_connections: typing.Optional[AsyncEnabledConnectionsClient] = None self._invitations: typing.Optional[AsyncInvitationsClient] = None self._members: typing.Optional[AsyncMembersClient] = None - self._organization_template: typing.Optional[AsyncOrganizationTemplateClient] = None self._groups: typing.Optional[AsyncGroupsClient] = None self._roles: typing.Optional[AsyncRolesClient] = None @@ -1081,14 +1070,6 @@ def members(self): self._members = AsyncMembersClient(client_wrapper=self._client_wrapper) return self._members - @property - def organization_template(self): - if self._organization_template is None: - from .organization_template.client import AsyncOrganizationTemplateClient # noqa: E402 - - self._organization_template = AsyncOrganizationTemplateClient(client_wrapper=self._client_wrapper) - return self._organization_template - @property def groups(self): if self._groups is None: diff --git a/src/auth0/management/organizations/organization_template/client.py b/src/auth0/management/organizations/organization_template/client.py deleted file mode 100644 index e4beedfb..00000000 --- a/src/auth0/management/organizations/organization_template/client.py +++ /dev/null @@ -1,274 +0,0 @@ -# This file was auto-generated by Fern from our API Definition. - -import typing - -from ...core.client_wrapper import AsyncClientWrapper, SyncClientWrapper -from ...core.request_options import RequestOptions -from ...types.organization_template import OrganizationTemplate -from .raw_client import AsyncRawOrganizationTemplateClient, RawOrganizationTemplateClient - - -class OrganizationTemplateClient: - def __init__(self, *, client_wrapper: SyncClientWrapper): - self._raw_client = RawOrganizationTemplateClient(client_wrapper=client_wrapper) - - @property - def with_raw_response(self) -> RawOrganizationTemplateClient: - """ - Retrieves a raw implementation of this client that returns raw responses. - - Returns - ------- - RawOrganizationTemplateClient - """ - return self._raw_client - - def get(self, id: str, *, request_options: typing.Optional[RequestOptions] = None) -> OrganizationTemplate: - """ - Retrieve the organization template assigned to a specific organization. Returns the template object if one is explicitly assigned, or a 404 if no template is assigned. - - Parameters - ---------- - id : str - ID of the organization. - - request_options : typing.Optional[RequestOptions] - Request-specific configuration. - - Returns - ------- - OrganizationTemplate - Organization template successfully retrieved. - - Examples - -------- - from auth0 import Auth0 - - client = Auth0( - token="YOUR_TOKEN", - ) - client.organizations.organization_template.get( - id="id", - ) - """ - _response = self._raw_client.get(id, request_options=request_options) - return _response.data - - def assign_organization_template( - self, id: str, template_id: str, *, request_options: typing.Optional[RequestOptions] = None - ) -> None: - """ - Assign an Organization Template to an organization. - - Parameters - ---------- - id : str - The ID of the organization. - - template_id : str - The ID of the organization template to assign. - - request_options : typing.Optional[RequestOptions] - Request-specific configuration. - - Returns - ------- - None - - Examples - -------- - from auth0 import Auth0 - - client = Auth0( - token="YOUR_TOKEN", - ) - client.organizations.organization_template.assign_organization_template( - id="id", - template_id="template_id", - ) - """ - _response = self._raw_client.assign_organization_template(id, template_id, request_options=request_options) - return _response.data - - def unassign_organization_template( - self, id: str, template_id: str, *, request_options: typing.Optional[RequestOptions] = None - ) -> None: - """ - Remove an Organization Template assignment from an organization. - - Parameters - ---------- - id : str - The ID of the organization. - - template_id : str - The ID of the organization template to unassign. - - request_options : typing.Optional[RequestOptions] - Request-specific configuration. - - Returns - ------- - None - - Examples - -------- - from auth0 import Auth0 - - client = Auth0( - token="YOUR_TOKEN", - ) - client.organizations.organization_template.unassign_organization_template( - id="id", - template_id="template_id", - ) - """ - _response = self._raw_client.unassign_organization_template(id, template_id, request_options=request_options) - return _response.data - - -class AsyncOrganizationTemplateClient: - def __init__(self, *, client_wrapper: AsyncClientWrapper): - self._raw_client = AsyncRawOrganizationTemplateClient(client_wrapper=client_wrapper) - - @property - def with_raw_response(self) -> AsyncRawOrganizationTemplateClient: - """ - Retrieves a raw implementation of this client that returns raw responses. - - Returns - ------- - AsyncRawOrganizationTemplateClient - """ - return self._raw_client - - async def get(self, id: str, *, request_options: typing.Optional[RequestOptions] = None) -> OrganizationTemplate: - """ - Retrieve the organization template assigned to a specific organization. Returns the template object if one is explicitly assigned, or a 404 if no template is assigned. - - Parameters - ---------- - id : str - ID of the organization. - - request_options : typing.Optional[RequestOptions] - Request-specific configuration. - - Returns - ------- - OrganizationTemplate - Organization template successfully retrieved. - - Examples - -------- - import asyncio - - from auth0 import AsyncAuth0 - - client = AsyncAuth0( - token="YOUR_TOKEN", - ) - - - async def main() -> None: - await client.organizations.organization_template.get( - id="id", - ) - - - asyncio.run(main()) - """ - _response = await self._raw_client.get(id, request_options=request_options) - return _response.data - - async def assign_organization_template( - self, id: str, template_id: str, *, request_options: typing.Optional[RequestOptions] = None - ) -> None: - """ - Assign an Organization Template to an organization. - - Parameters - ---------- - id : str - The ID of the organization. - - template_id : str - The ID of the organization template to assign. - - request_options : typing.Optional[RequestOptions] - Request-specific configuration. - - Returns - ------- - None - - Examples - -------- - import asyncio - - from auth0 import AsyncAuth0 - - client = AsyncAuth0( - token="YOUR_TOKEN", - ) - - - async def main() -> None: - await client.organizations.organization_template.assign_organization_template( - id="id", - template_id="template_id", - ) - - - asyncio.run(main()) - """ - _response = await self._raw_client.assign_organization_template( - id, template_id, request_options=request_options - ) - return _response.data - - async def unassign_organization_template( - self, id: str, template_id: str, *, request_options: typing.Optional[RequestOptions] = None - ) -> None: - """ - Remove an Organization Template assignment from an organization. - - Parameters - ---------- - id : str - The ID of the organization. - - template_id : str - The ID of the organization template to unassign. - - request_options : typing.Optional[RequestOptions] - Request-specific configuration. - - Returns - ------- - None - - Examples - -------- - import asyncio - - from auth0 import AsyncAuth0 - - client = AsyncAuth0( - token="YOUR_TOKEN", - ) - - - async def main() -> None: - await client.organizations.organization_template.unassign_organization_template( - id="id", - template_id="template_id", - ) - - - asyncio.run(main()) - """ - _response = await self._raw_client.unassign_organization_template( - id, template_id, request_options=request_options - ) - return _response.data diff --git a/src/auth0/management/organizations/organization_template/raw_client.py b/src/auth0/management/organizations/organization_template/raw_client.py deleted file mode 100644 index 2df4e6ee..00000000 --- a/src/auth0/management/organizations/organization_template/raw_client.py +++ /dev/null @@ -1,531 +0,0 @@ -# This file was auto-generated by Fern from our API Definition. - -import typing -from json.decoder import JSONDecodeError - -from ...core.api_error import ApiError -from ...core.client_wrapper import AsyncClientWrapper, SyncClientWrapper -from ...core.http_response import AsyncHttpResponse, HttpResponse -from ...core.jsonable_encoder import quote_path_param -from ...core.parse_error import ParsingError -from ...core.pydantic_utilities import parse_obj_as -from ...core.request_options import RequestOptions -from ...errors.bad_request_error import BadRequestError -from ...errors.forbidden_error import ForbiddenError -from ...errors.not_found_error import NotFoundError -from ...errors.too_many_requests_error import TooManyRequestsError -from ...errors.unauthorized_error import UnauthorizedError -from ...types.organization_template import OrganizationTemplate -from pydantic import ValidationError - - -class RawOrganizationTemplateClient: - def __init__(self, *, client_wrapper: SyncClientWrapper): - self._client_wrapper = client_wrapper - - def get( - self, id: str, *, request_options: typing.Optional[RequestOptions] = None - ) -> HttpResponse[OrganizationTemplate]: - """ - Retrieve the organization template assigned to a specific organization. Returns the template object if one is explicitly assigned, or a 404 if no template is assigned. - - Parameters - ---------- - id : str - ID of the organization. - - request_options : typing.Optional[RequestOptions] - Request-specific configuration. - - Returns - ------- - HttpResponse[OrganizationTemplate] - Organization template successfully retrieved. - """ - _response = self._client_wrapper.httpx_client.request( - f"organizations/{quote_path_param(id)}/organization-templates", - method="GET", - request_options=request_options, - ) - try: - if 200 <= _response.status_code < 300: - _data = typing.cast( - OrganizationTemplate, - parse_obj_as( - type_=OrganizationTemplate, # type: ignore - object_=_response.json(), - ), - ) - return HttpResponse(response=_response, data=_data) - if _response.status_code == 401: - raise UnauthorizedError( - headers=dict(_response.headers), - body=typing.cast( - typing.Any, - parse_obj_as( - type_=typing.Any, # type: ignore - object_=_response.json(), - ), - ), - ) - if _response.status_code == 403: - raise ForbiddenError( - headers=dict(_response.headers), - body=typing.cast( - typing.Any, - parse_obj_as( - type_=typing.Any, # type: ignore - object_=_response.json(), - ), - ), - ) - if _response.status_code == 404: - raise NotFoundError( - headers=dict(_response.headers), - body=typing.cast( - typing.Any, - parse_obj_as( - type_=typing.Any, # type: ignore - object_=_response.json(), - ), - ), - ) - if _response.status_code == 429: - raise TooManyRequestsError( - headers=dict(_response.headers), - body=typing.cast( - typing.Any, - parse_obj_as( - type_=typing.Any, # type: ignore - object_=_response.json(), - ), - ), - ) - _response_json = _response.json() - except JSONDecodeError: - raise ApiError(status_code=_response.status_code, headers=dict(_response.headers), body=_response.text) - except ValidationError as e: - raise ParsingError( - status_code=_response.status_code, headers=dict(_response.headers), body=_response.json(), cause=e - ) - raise ApiError(status_code=_response.status_code, headers=dict(_response.headers), body=_response_json) - - def assign_organization_template( - self, id: str, template_id: str, *, request_options: typing.Optional[RequestOptions] = None - ) -> HttpResponse[None]: - """ - Assign an Organization Template to an organization. - - Parameters - ---------- - id : str - The ID of the organization. - - template_id : str - The ID of the organization template to assign. - - request_options : typing.Optional[RequestOptions] - Request-specific configuration. - - Returns - ------- - HttpResponse[None] - """ - _response = self._client_wrapper.httpx_client.request( - f"organizations/{quote_path_param(id)}/organization-templates/{quote_path_param(template_id)}", - method="PUT", - request_options=request_options, - ) - try: - if 200 <= _response.status_code < 300: - return HttpResponse(response=_response, data=None) - if _response.status_code == 400: - raise BadRequestError( - headers=dict(_response.headers), - body=typing.cast( - typing.Any, - parse_obj_as( - type_=typing.Any, # type: ignore - object_=_response.json(), - ), - ), - ) - if _response.status_code == 401: - raise UnauthorizedError( - headers=dict(_response.headers), - body=typing.cast( - typing.Any, - parse_obj_as( - type_=typing.Any, # type: ignore - object_=_response.json(), - ), - ), - ) - if _response.status_code == 403: - raise ForbiddenError( - headers=dict(_response.headers), - body=typing.cast( - typing.Any, - parse_obj_as( - type_=typing.Any, # type: ignore - object_=_response.json(), - ), - ), - ) - if _response.status_code == 429: - raise TooManyRequestsError( - headers=dict(_response.headers), - body=typing.cast( - typing.Any, - parse_obj_as( - type_=typing.Any, # type: ignore - object_=_response.json(), - ), - ), - ) - _response_json = _response.json() - except JSONDecodeError: - raise ApiError(status_code=_response.status_code, headers=dict(_response.headers), body=_response.text) - except ValidationError as e: - raise ParsingError( - status_code=_response.status_code, headers=dict(_response.headers), body=_response.json(), cause=e - ) - raise ApiError(status_code=_response.status_code, headers=dict(_response.headers), body=_response_json) - - def unassign_organization_template( - self, id: str, template_id: str, *, request_options: typing.Optional[RequestOptions] = None - ) -> HttpResponse[None]: - """ - Remove an Organization Template assignment from an organization. - - Parameters - ---------- - id : str - The ID of the organization. - - template_id : str - The ID of the organization template to unassign. - - request_options : typing.Optional[RequestOptions] - Request-specific configuration. - - Returns - ------- - HttpResponse[None] - """ - _response = self._client_wrapper.httpx_client.request( - f"organizations/{quote_path_param(id)}/organization-templates/{quote_path_param(template_id)}", - method="DELETE", - request_options=request_options, - ) - try: - if 200 <= _response.status_code < 300: - return HttpResponse(response=_response, data=None) - if _response.status_code == 400: - raise BadRequestError( - headers=dict(_response.headers), - body=typing.cast( - typing.Any, - parse_obj_as( - type_=typing.Any, # type: ignore - object_=_response.json(), - ), - ), - ) - if _response.status_code == 401: - raise UnauthorizedError( - headers=dict(_response.headers), - body=typing.cast( - typing.Any, - parse_obj_as( - type_=typing.Any, # type: ignore - object_=_response.json(), - ), - ), - ) - if _response.status_code == 403: - raise ForbiddenError( - headers=dict(_response.headers), - body=typing.cast( - typing.Any, - parse_obj_as( - type_=typing.Any, # type: ignore - object_=_response.json(), - ), - ), - ) - if _response.status_code == 429: - raise TooManyRequestsError( - headers=dict(_response.headers), - body=typing.cast( - typing.Any, - parse_obj_as( - type_=typing.Any, # type: ignore - object_=_response.json(), - ), - ), - ) - _response_json = _response.json() - except JSONDecodeError: - raise ApiError(status_code=_response.status_code, headers=dict(_response.headers), body=_response.text) - except ValidationError as e: - raise ParsingError( - status_code=_response.status_code, headers=dict(_response.headers), body=_response.json(), cause=e - ) - raise ApiError(status_code=_response.status_code, headers=dict(_response.headers), body=_response_json) - - -class AsyncRawOrganizationTemplateClient: - def __init__(self, *, client_wrapper: AsyncClientWrapper): - self._client_wrapper = client_wrapper - - async def get( - self, id: str, *, request_options: typing.Optional[RequestOptions] = None - ) -> AsyncHttpResponse[OrganizationTemplate]: - """ - Retrieve the organization template assigned to a specific organization. Returns the template object if one is explicitly assigned, or a 404 if no template is assigned. - - Parameters - ---------- - id : str - ID of the organization. - - request_options : typing.Optional[RequestOptions] - Request-specific configuration. - - Returns - ------- - AsyncHttpResponse[OrganizationTemplate] - Organization template successfully retrieved. - """ - _response = await self._client_wrapper.httpx_client.request( - f"organizations/{quote_path_param(id)}/organization-templates", - method="GET", - request_options=request_options, - ) - try: - if 200 <= _response.status_code < 300: - _data = typing.cast( - OrganizationTemplate, - parse_obj_as( - type_=OrganizationTemplate, # type: ignore - object_=_response.json(), - ), - ) - return AsyncHttpResponse(response=_response, data=_data) - if _response.status_code == 401: - raise UnauthorizedError( - headers=dict(_response.headers), - body=typing.cast( - typing.Any, - parse_obj_as( - type_=typing.Any, # type: ignore - object_=_response.json(), - ), - ), - ) - if _response.status_code == 403: - raise ForbiddenError( - headers=dict(_response.headers), - body=typing.cast( - typing.Any, - parse_obj_as( - type_=typing.Any, # type: ignore - object_=_response.json(), - ), - ), - ) - if _response.status_code == 404: - raise NotFoundError( - headers=dict(_response.headers), - body=typing.cast( - typing.Any, - parse_obj_as( - type_=typing.Any, # type: ignore - object_=_response.json(), - ), - ), - ) - if _response.status_code == 429: - raise TooManyRequestsError( - headers=dict(_response.headers), - body=typing.cast( - typing.Any, - parse_obj_as( - type_=typing.Any, # type: ignore - object_=_response.json(), - ), - ), - ) - _response_json = _response.json() - except JSONDecodeError: - raise ApiError(status_code=_response.status_code, headers=dict(_response.headers), body=_response.text) - except ValidationError as e: - raise ParsingError( - status_code=_response.status_code, headers=dict(_response.headers), body=_response.json(), cause=e - ) - raise ApiError(status_code=_response.status_code, headers=dict(_response.headers), body=_response_json) - - async def assign_organization_template( - self, id: str, template_id: str, *, request_options: typing.Optional[RequestOptions] = None - ) -> AsyncHttpResponse[None]: - """ - Assign an Organization Template to an organization. - - Parameters - ---------- - id : str - The ID of the organization. - - template_id : str - The ID of the organization template to assign. - - request_options : typing.Optional[RequestOptions] - Request-specific configuration. - - Returns - ------- - AsyncHttpResponse[None] - """ - _response = await self._client_wrapper.httpx_client.request( - f"organizations/{quote_path_param(id)}/organization-templates/{quote_path_param(template_id)}", - method="PUT", - request_options=request_options, - ) - try: - if 200 <= _response.status_code < 300: - return AsyncHttpResponse(response=_response, data=None) - if _response.status_code == 400: - raise BadRequestError( - headers=dict(_response.headers), - body=typing.cast( - typing.Any, - parse_obj_as( - type_=typing.Any, # type: ignore - object_=_response.json(), - ), - ), - ) - if _response.status_code == 401: - raise UnauthorizedError( - headers=dict(_response.headers), - body=typing.cast( - typing.Any, - parse_obj_as( - type_=typing.Any, # type: ignore - object_=_response.json(), - ), - ), - ) - if _response.status_code == 403: - raise ForbiddenError( - headers=dict(_response.headers), - body=typing.cast( - typing.Any, - parse_obj_as( - type_=typing.Any, # type: ignore - object_=_response.json(), - ), - ), - ) - if _response.status_code == 429: - raise TooManyRequestsError( - headers=dict(_response.headers), - body=typing.cast( - typing.Any, - parse_obj_as( - type_=typing.Any, # type: ignore - object_=_response.json(), - ), - ), - ) - _response_json = _response.json() - except JSONDecodeError: - raise ApiError(status_code=_response.status_code, headers=dict(_response.headers), body=_response.text) - except ValidationError as e: - raise ParsingError( - status_code=_response.status_code, headers=dict(_response.headers), body=_response.json(), cause=e - ) - raise ApiError(status_code=_response.status_code, headers=dict(_response.headers), body=_response_json) - - async def unassign_organization_template( - self, id: str, template_id: str, *, request_options: typing.Optional[RequestOptions] = None - ) -> AsyncHttpResponse[None]: - """ - Remove an Organization Template assignment from an organization. - - Parameters - ---------- - id : str - The ID of the organization. - - template_id : str - The ID of the organization template to unassign. - - request_options : typing.Optional[RequestOptions] - Request-specific configuration. - - Returns - ------- - AsyncHttpResponse[None] - """ - _response = await self._client_wrapper.httpx_client.request( - f"organizations/{quote_path_param(id)}/organization-templates/{quote_path_param(template_id)}", - method="DELETE", - request_options=request_options, - ) - try: - if 200 <= _response.status_code < 300: - return AsyncHttpResponse(response=_response, data=None) - if _response.status_code == 400: - raise BadRequestError( - headers=dict(_response.headers), - body=typing.cast( - typing.Any, - parse_obj_as( - type_=typing.Any, # type: ignore - object_=_response.json(), - ), - ), - ) - if _response.status_code == 401: - raise UnauthorizedError( - headers=dict(_response.headers), - body=typing.cast( - typing.Any, - parse_obj_as( - type_=typing.Any, # type: ignore - object_=_response.json(), - ), - ), - ) - if _response.status_code == 403: - raise ForbiddenError( - headers=dict(_response.headers), - body=typing.cast( - typing.Any, - parse_obj_as( - type_=typing.Any, # type: ignore - object_=_response.json(), - ), - ), - ) - if _response.status_code == 429: - raise TooManyRequestsError( - headers=dict(_response.headers), - body=typing.cast( - typing.Any, - parse_obj_as( - type_=typing.Any, # type: ignore - object_=_response.json(), - ), - ), - ) - _response_json = _response.json() - except JSONDecodeError: - raise ApiError(status_code=_response.status_code, headers=dict(_response.headers), body=_response.text) - except ValidationError as e: - raise ParsingError( - status_code=_response.status_code, headers=dict(_response.headers), body=_response.json(), cause=e - ) - raise ApiError(status_code=_response.status_code, headers=dict(_response.headers), body=_response_json) diff --git a/src/auth0/management/resource_servers/client.py b/src/auth0/management/resource_servers/client.py index 6592d378..9eecbf68 100644 --- a/src/auth0/management/resource_servers/client.py +++ b/src/auth0/management/resource_servers/client.py @@ -132,6 +132,7 @@ def create( access_token: typing.Optional[ResourceServerAccessToken] = OMIT, token_encryption: typing.Optional[ResourceServerTokenEncryption] = OMIT, consent_policy: typing.Optional[ResourceServerConsentPolicyEnum] = OMIT, + require_consent_non_repudiation: typing.Optional[bool] = OMIT, authorization_details: typing.Optional[typing.Sequence[typing.Any]] = OMIT, proof_of_possession: typing.Optional[ResourceServerProofOfPossession] = OMIT, subject_type_authorization: typing.Optional[ResourceServerSubjectTypeAuthorization] = OMIT, @@ -186,6 +187,9 @@ def create( consent_policy : typing.Optional[ResourceServerConsentPolicyEnum] + require_consent_non_repudiation : typing.Optional[bool] + When true, the resource server requires every consent approval to be digitally signed, so the approver cannot later deny a consent they granted. When false, consent decisions do not need a signature. Defaults to false. A configured value is still returned even after the related entitlement is disabled. + authorization_details : typing.Optional[typing.Sequence[typing.Any]] proof_of_possession : typing.Optional[ResourceServerProofOfPossession] @@ -230,6 +234,7 @@ def create( access_token=access_token, token_encryption=token_encryption, consent_policy=consent_policy, + require_consent_non_repudiation=require_consent_non_repudiation, authorization_details=authorization_details, proof_of_possession=proof_of_possession, subject_type_authorization=subject_type_authorization, @@ -410,6 +415,7 @@ def update( access_token: typing.Optional[ResourceServerAccessToken] = OMIT, token_encryption: typing.Optional[ResourceServerTokenEncryption] = OMIT, consent_policy: typing.Optional[ResourceServerConsentPolicyEnum] = OMIT, + require_consent_non_repudiation: typing.Optional[bool] = OMIT, authorization_details: typing.Optional[typing.Sequence[typing.Any]] = OMIT, proof_of_possession: typing.Optional[ResourceServerProofOfPossession] = OMIT, subject_type_authorization: typing.Optional[ResourceServerSubjectTypeAuthorization] = OMIT, @@ -464,6 +470,9 @@ def update( consent_policy : typing.Optional[ResourceServerConsentPolicyEnum] + require_consent_non_repudiation : typing.Optional[bool] + When true, the resource server requires every consent approval to be digitally signed, so the approver cannot later deny a consent they granted. When false, consent decisions do not need a signature. Defaults to false. A configured value is still returned even after the related entitlement is disabled. + authorization_details : typing.Optional[typing.Sequence[typing.Any]] proof_of_possession : typing.Optional[ResourceServerProofOfPossession] @@ -508,6 +517,7 @@ def update( access_token=access_token, token_encryption=token_encryption, consent_policy=consent_policy, + require_consent_non_repudiation=require_consent_non_repudiation, authorization_details=authorization_details, proof_of_possession=proof_of_possession, subject_type_authorization=subject_type_authorization, @@ -627,6 +637,7 @@ async def create( access_token: typing.Optional[ResourceServerAccessToken] = OMIT, token_encryption: typing.Optional[ResourceServerTokenEncryption] = OMIT, consent_policy: typing.Optional[ResourceServerConsentPolicyEnum] = OMIT, + require_consent_non_repudiation: typing.Optional[bool] = OMIT, authorization_details: typing.Optional[typing.Sequence[typing.Any]] = OMIT, proof_of_possession: typing.Optional[ResourceServerProofOfPossession] = OMIT, subject_type_authorization: typing.Optional[ResourceServerSubjectTypeAuthorization] = OMIT, @@ -681,6 +692,9 @@ async def create( consent_policy : typing.Optional[ResourceServerConsentPolicyEnum] + require_consent_non_repudiation : typing.Optional[bool] + When true, the resource server requires every consent approval to be digitally signed, so the approver cannot later deny a consent they granted. When false, consent decisions do not need a signature. Defaults to false. A configured value is still returned even after the related entitlement is disabled. + authorization_details : typing.Optional[typing.Sequence[typing.Any]] proof_of_possession : typing.Optional[ResourceServerProofOfPossession] @@ -733,6 +747,7 @@ async def main() -> None: access_token=access_token, token_encryption=token_encryption, consent_policy=consent_policy, + require_consent_non_repudiation=require_consent_non_repudiation, authorization_details=authorization_details, proof_of_possession=proof_of_possession, subject_type_authorization=subject_type_authorization, @@ -938,6 +953,7 @@ async def update( access_token: typing.Optional[ResourceServerAccessToken] = OMIT, token_encryption: typing.Optional[ResourceServerTokenEncryption] = OMIT, consent_policy: typing.Optional[ResourceServerConsentPolicyEnum] = OMIT, + require_consent_non_repudiation: typing.Optional[bool] = OMIT, authorization_details: typing.Optional[typing.Sequence[typing.Any]] = OMIT, proof_of_possession: typing.Optional[ResourceServerProofOfPossession] = OMIT, subject_type_authorization: typing.Optional[ResourceServerSubjectTypeAuthorization] = OMIT, @@ -992,6 +1008,9 @@ async def update( consent_policy : typing.Optional[ResourceServerConsentPolicyEnum] + require_consent_non_repudiation : typing.Optional[bool] + When true, the resource server requires every consent approval to be digitally signed, so the approver cannot later deny a consent they granted. When false, consent decisions do not need a signature. Defaults to false. A configured value is still returned even after the related entitlement is disabled. + authorization_details : typing.Optional[typing.Sequence[typing.Any]] proof_of_possession : typing.Optional[ResourceServerProofOfPossession] @@ -1044,6 +1063,7 @@ async def main() -> None: access_token=access_token, token_encryption=token_encryption, consent_policy=consent_policy, + require_consent_non_repudiation=require_consent_non_repudiation, authorization_details=authorization_details, proof_of_possession=proof_of_possession, subject_type_authorization=subject_type_authorization, diff --git a/src/auth0/management/resource_servers/raw_client.py b/src/auth0/management/resource_servers/raw_client.py index 0648de47..8efc5715 100644 --- a/src/auth0/management/resource_servers/raw_client.py +++ b/src/auth0/management/resource_servers/raw_client.py @@ -194,6 +194,7 @@ def create( access_token: typing.Optional[ResourceServerAccessToken] = OMIT, token_encryption: typing.Optional[ResourceServerTokenEncryption] = OMIT, consent_policy: typing.Optional[ResourceServerConsentPolicyEnum] = OMIT, + require_consent_non_repudiation: typing.Optional[bool] = OMIT, authorization_details: typing.Optional[typing.Sequence[typing.Any]] = OMIT, proof_of_possession: typing.Optional[ResourceServerProofOfPossession] = OMIT, subject_type_authorization: typing.Optional[ResourceServerSubjectTypeAuthorization] = OMIT, @@ -248,6 +249,9 @@ def create( consent_policy : typing.Optional[ResourceServerConsentPolicyEnum] + require_consent_non_repudiation : typing.Optional[bool] + When true, the resource server requires every consent approval to be digitally signed, so the approver cannot later deny a consent they granted. When false, consent decisions do not need a signature. Defaults to false. A configured value is still returned even after the related entitlement is disabled. + authorization_details : typing.Optional[typing.Sequence[typing.Any]] proof_of_possession : typing.Optional[ResourceServerProofOfPossession] @@ -292,6 +296,7 @@ def create( direction="write", ), "consent_policy": consent_policy, + "require_consent_non_repudiation": require_consent_non_repudiation, "authorization_details": authorization_details, "proof_of_possession": convert_and_respect_annotation_metadata( object_=proof_of_possession, @@ -765,6 +770,7 @@ def update( access_token: typing.Optional[ResourceServerAccessToken] = OMIT, token_encryption: typing.Optional[ResourceServerTokenEncryption] = OMIT, consent_policy: typing.Optional[ResourceServerConsentPolicyEnum] = OMIT, + require_consent_non_repudiation: typing.Optional[bool] = OMIT, authorization_details: typing.Optional[typing.Sequence[typing.Any]] = OMIT, proof_of_possession: typing.Optional[ResourceServerProofOfPossession] = OMIT, subject_type_authorization: typing.Optional[ResourceServerSubjectTypeAuthorization] = OMIT, @@ -819,6 +825,9 @@ def update( consent_policy : typing.Optional[ResourceServerConsentPolicyEnum] + require_consent_non_repudiation : typing.Optional[bool] + When true, the resource server requires every consent approval to be digitally signed, so the approver cannot later deny a consent they granted. When false, consent decisions do not need a signature. Defaults to false. A configured value is still returned even after the related entitlement is disabled. + authorization_details : typing.Optional[typing.Sequence[typing.Any]] proof_of_possession : typing.Optional[ResourceServerProofOfPossession] @@ -862,6 +871,7 @@ def update( direction="write", ), "consent_policy": consent_policy, + "require_consent_non_repudiation": require_consent_non_repudiation, "authorization_details": authorization_details, "proof_of_possession": convert_and_respect_annotation_metadata( object_=proof_of_possession, @@ -1111,6 +1121,7 @@ async def create( access_token: typing.Optional[ResourceServerAccessToken] = OMIT, token_encryption: typing.Optional[ResourceServerTokenEncryption] = OMIT, consent_policy: typing.Optional[ResourceServerConsentPolicyEnum] = OMIT, + require_consent_non_repudiation: typing.Optional[bool] = OMIT, authorization_details: typing.Optional[typing.Sequence[typing.Any]] = OMIT, proof_of_possession: typing.Optional[ResourceServerProofOfPossession] = OMIT, subject_type_authorization: typing.Optional[ResourceServerSubjectTypeAuthorization] = OMIT, @@ -1165,6 +1176,9 @@ async def create( consent_policy : typing.Optional[ResourceServerConsentPolicyEnum] + require_consent_non_repudiation : typing.Optional[bool] + When true, the resource server requires every consent approval to be digitally signed, so the approver cannot later deny a consent they granted. When false, consent decisions do not need a signature. Defaults to false. A configured value is still returned even after the related entitlement is disabled. + authorization_details : typing.Optional[typing.Sequence[typing.Any]] proof_of_possession : typing.Optional[ResourceServerProofOfPossession] @@ -1209,6 +1223,7 @@ async def create( direction="write", ), "consent_policy": consent_policy, + "require_consent_non_repudiation": require_consent_non_repudiation, "authorization_details": authorization_details, "proof_of_possession": convert_and_respect_annotation_metadata( object_=proof_of_possession, @@ -1687,6 +1702,7 @@ async def update( access_token: typing.Optional[ResourceServerAccessToken] = OMIT, token_encryption: typing.Optional[ResourceServerTokenEncryption] = OMIT, consent_policy: typing.Optional[ResourceServerConsentPolicyEnum] = OMIT, + require_consent_non_repudiation: typing.Optional[bool] = OMIT, authorization_details: typing.Optional[typing.Sequence[typing.Any]] = OMIT, proof_of_possession: typing.Optional[ResourceServerProofOfPossession] = OMIT, subject_type_authorization: typing.Optional[ResourceServerSubjectTypeAuthorization] = OMIT, @@ -1741,6 +1757,9 @@ async def update( consent_policy : typing.Optional[ResourceServerConsentPolicyEnum] + require_consent_non_repudiation : typing.Optional[bool] + When true, the resource server requires every consent approval to be digitally signed, so the approver cannot later deny a consent they granted. When false, consent decisions do not need a signature. Defaults to false. A configured value is still returned even after the related entitlement is disabled. + authorization_details : typing.Optional[typing.Sequence[typing.Any]] proof_of_possession : typing.Optional[ResourceServerProofOfPossession] @@ -1784,6 +1803,7 @@ async def update( direction="write", ), "consent_policy": consent_policy, + "require_consent_non_repudiation": require_consent_non_repudiation, "authorization_details": authorization_details, "proof_of_possession": convert_and_respect_annotation_metadata( object_=proof_of_possession, diff --git a/src/auth0/management/types/__init__.py b/src/auth0/management/types/__init__.py index ada24e66..1a548259 100644 --- a/src/auth0/management/types/__init__.py +++ b/src/auth0/management/types/__init__.py @@ -62,6 +62,9 @@ from .advance_ramp_response_content import AdvanceRampResponseContent from .agent_metadata import AgentMetadata from .agent_response_content import AgentResponseContent + from .allocation_item import AllocationItem + from .allocation_request_item import AllocationRequestItem + from .allocation_strategy_enum import AllocationStrategyEnum from .anomaly_ip_format import AnomalyIpFormat from .anonymous_sessions import AnonymousSessions from .app_metadata import AppMetadata @@ -92,6 +95,7 @@ from .attack_protection_update_captcha_hcaptcha import AttackProtectionUpdateCaptchaHcaptcha from .attack_protection_update_captcha_recaptcha_enterprise import AttackProtectionUpdateCaptchaRecaptchaEnterprise from .attack_protection_update_captcha_recaptcha_v_2 import AttackProtectionUpdateCaptchaRecaptchaV2 + from .authentication_flow_enum import AuthenticationFlowEnum from .authentication_method_type_enum import AuthenticationMethodTypeEnum from .authentication_type_enum import AuthenticationTypeEnum from .b_2_b_integration_configuration import B2BIntegrationConfiguration @@ -277,6 +281,8 @@ from .client_oidc_backchannel_logout_initiators_mode_enum import ClientOidcBackchannelLogoutInitiatorsModeEnum from .client_oidc_backchannel_logout_session_metadata import ClientOidcBackchannelLogoutSessionMetadata from .client_oidc_backchannel_logout_settings import ClientOidcBackchannelLogoutSettings + from .client_oidc_support_allowed_scopes_enum import ClientOidcSupportAllowedScopesEnum + from .client_oidc_support_post import ClientOidcSupportPost from .client_organization_discovery_enum import ClientOrganizationDiscoveryEnum from .client_organization_require_behavior_enum import ClientOrganizationRequireBehaviorEnum from .client_organization_require_behavior_patch_enum import ClientOrganizationRequireBehaviorPatchEnum @@ -396,7 +402,6 @@ from .connection_debug_saml import ConnectionDebugSaml from .connection_decryption_key_saml import ConnectionDecryptionKeySaml from .connection_decryption_key_saml_cert import ConnectionDecryptionKeySamlCert - from .connection_deletion_behavior_enum import ConnectionDeletionBehaviorEnum from .connection_destination_url_saml import ConnectionDestinationUrlSaml from .connection_digest_algorithm_enum_saml import ConnectionDigestAlgorithmEnumSaml from .connection_digest_algorithm_saml import ConnectionDigestAlgorithmSaml @@ -837,6 +842,9 @@ from .connection_thumbprints import ConnectionThumbprints from .connection_thumbprints_ad import ConnectionThumbprintsAd from .connection_thumbprints_saml import ConnectionThumbprintsSaml + from .connection_thumbprints_sha_384 import ConnectionThumbprintsSha384 + from .connection_thumbprints_sha_384_ad import ConnectionThumbprintsSha384Ad + from .connection_thumbprints_sha_384_saml import ConnectionThumbprintsSha384Saml from .connection_token_endpoint import ConnectionTokenEndpoint from .connection_token_endpoint_auth_method_enum import ConnectionTokenEndpointAuthMethodEnum from .connection_token_endpoint_auth_methods_supported import ConnectionTokenEndpointAuthMethodsSupported @@ -1045,8 +1053,11 @@ from .create_event_stream_response_content import CreateEventStreamResponseContent from .create_event_stream_test_event_response_content import CreateEventStreamTestEventResponseContent from .create_event_stream_web_hook_request_content import CreateEventStreamWebHookRequestContent + from .create_experiment_response_content import CreateExperimentResponseContent from .create_export_users_fields import CreateExportUsersFields from .create_export_users_response_content import CreateExportUsersResponseContent + from .create_feature_flag_parameters import CreateFeatureFlagParameters + from .create_feature_flag_response_content import CreateFeatureFlagResponseContent from .create_flow_response_content import CreateFlowResponseContent from .create_flows_vault_connection_activecampaign import CreateFlowsVaultConnectionActivecampaign from .create_flows_vault_connection_activecampaign_api_key import CreateFlowsVaultConnectionActivecampaignApiKey @@ -1165,6 +1176,7 @@ from .create_scim_configuration_request_content import CreateScimConfigurationRequestContent from .create_scim_configuration_response_content import CreateScimConfigurationResponseContent from .create_scim_token_response_content import CreateScimTokenResponseContent + from .create_segment_response_content import CreateSegmentResponseContent from .create_self_service_profile_response_content import CreateSelfServiceProfileResponseContent from .create_self_service_profile_sso_ticket_response_content import ( CreateSelfServiceProfileSsoTicketResponseContent, @@ -1174,6 +1186,7 @@ from .create_user_attribute_profile_response_content import CreateUserAttributeProfileResponseContent from .create_user_authentication_method_response_content import CreateUserAuthenticationMethodResponseContent from .create_user_response_content import CreateUserResponseContent + from .create_variation_response_content import CreateVariationResponseContent from .create_verifiable_credential_template_response_content import ( CreateVerifiableCredentialTemplateResponseContent, ) @@ -1215,6 +1228,7 @@ from .custom_signing_key_type_enum import CustomSigningKeyTypeEnum from .custom_signing_key_use_enum import CustomSigningKeyUseEnum from .daily_stats import DailyStats + from .default_config_enum import DefaultConfigEnum from .default_method_email_identifier_enum import DefaultMethodEmailIdentifierEnum from .default_method_phone_number_identifier_enum import DefaultMethodPhoneNumberIdentifierEnum from .default_token_quota import DefaultTokenQuota @@ -4836,9 +4850,19 @@ from .event_stream_webhook_destination import EventStreamWebhookDestination from .event_stream_webhook_destination_type_enum import EventStreamWebhookDestinationTypeEnum from .event_stream_webhook_response_content import EventStreamWebhookResponseContent + from .experiment_list_item import ExperimentListItem + from .experiment_status_enum import ExperimentStatusEnum + from .experiment_transition_status_enum import ExperimentTransitionStatusEnum + from .experiment_validation_error import ExperimentValidationError from .express_configuration import ExpressConfiguration from .express_configuration_or_null import ExpressConfigurationOrNull from .extensibility_email_provider_credentials import ExtensibilityEmailProviderCredentials + from .feature_flag import FeatureFlag + from .feature_flag_config_param import FeatureFlagConfigParam + from .feature_flag_config_param_type_enum import FeatureFlagConfigParamTypeEnum + from .feature_flag_config_params import FeatureFlagConfigParams + from .feature_flag_status_enum import FeatureFlagStatusEnum + from .feature_flag_type_enum import FeatureFlagTypeEnum from .fed_cm_login import FedCmLogin from .fed_cm_login_google import FedCmLoginGoogle from .fed_cm_login_google_patch import FedCmLoginGooglePatch @@ -5463,6 +5487,8 @@ from .get_encryption_key_response_content import GetEncryptionKeyResponseContent from .get_event_stream_delivery_history_response_content import GetEventStreamDeliveryHistoryResponseContent from .get_event_stream_response_content import GetEventStreamResponseContent + from .get_experiment_response_content import GetExperimentResponseContent + from .get_feature_flag_response_content import GetFeatureFlagResponseContent from .get_flow_execution_request_parameters_hydrate_enum import GetFlowExecutionRequestParametersHydrateEnum from .get_flow_execution_response_content import GetFlowExecutionResponseContent from .get_flow_request_parameters_hydrate_enum import GetFlowRequestParametersHydrateEnum @@ -5532,6 +5558,7 @@ ) from .get_scim_configuration_response_content import GetScimConfigurationResponseContent from .get_scim_tokens_response_content import GetScimTokensResponseContent + from .get_segment_response_content import GetSegmentResponseContent from .get_self_service_profile_response_content import GetSelfServiceProfileResponseContent from .get_session_response_content import GetSessionResponseContent from .get_settings_response_content import GetSettingsResponseContent @@ -5547,6 +5574,7 @@ from .get_user_authentication_method_response_content import GetUserAuthenticationMethodResponseContent from .get_user_groups_paginated_response_content import GetUserGroupsPaginatedResponseContent from .get_user_response_content import GetUserResponseContent + from .get_variation_response_content import GetVariationResponseContent from .get_verifiable_credential_template_response_content import GetVerifiableCredentialTemplateResponseContent from .group import Group from .group_member import GroupMember @@ -5608,6 +5636,8 @@ from .list_encryption_key_offset_paginated_response_content import ListEncryptionKeyOffsetPaginatedResponseContent from .list_event_stream_deliveries_response_content import ListEventStreamDeliveriesResponseContent from .list_event_streams_response_content import ListEventStreamsResponseContent + from .list_experiments_response_content import ListExperimentsResponseContent + from .list_feature_flags_response_content import ListFeatureFlagsResponseContent from .list_flow_executions_paginated_response_content import ListFlowExecutionsPaginatedResponseContent from .list_flows_offset_paginated_response_content import ListFlowsOffsetPaginatedResponseContent from .list_flows_request_parameters_hydrate_enum import ListFlowsRequestParametersHydrateEnum @@ -5662,6 +5692,7 @@ from .list_roles_offset_paginated_response_content import ListRolesOffsetPaginatedResponseContent from .list_rules_offset_paginated_response_content import ListRulesOffsetPaginatedResponseContent from .list_scim_configurations_response_content import ListScimConfigurationsResponseContent + from .list_segments_response_content import ListSegmentsResponseContent from .list_self_service_profile_custom_text_response_content import ListSelfServiceProfileCustomTextResponseContent from .list_self_service_profiles_paginated_response_content import ListSelfServiceProfilesPaginatedResponseContent from .list_synchronized_groups_response_content import ListSynchronizedGroupsResponseContent @@ -5692,6 +5723,7 @@ from .list_user_roles_offset_paginated_response_content import ListUserRolesOffsetPaginatedResponseContent from .list_user_sessions_paginated_response_content import ListUserSessionsPaginatedResponseContent from .list_users_offset_paginated_response_content import ListUsersOffsetPaginatedResponseContent + from .list_variations_response_content import ListVariationsResponseContent from .list_verifiable_credential_templates_paginated_response_content import ( ListVerifiableCredentialTemplatesPaginatedResponseContent, ) @@ -5791,7 +5823,6 @@ from .organization_client_metadata_organization_usage_enum import OrganizationClientMetadataOrganizationUsageEnum from .organization_connection import OrganizationConnection from .organization_connection_information import OrganizationConnectionInformation - from .organization_deletion_behavior_enum import OrganizationDeletionBehaviorEnum from .organization_discovery_domain import OrganizationDiscoveryDomain from .organization_discovery_domain_status import OrganizationDiscoveryDomainStatus from .organization_enabled_connection import OrganizationEnabledConnection @@ -5806,12 +5837,6 @@ from .organization_member_role import OrganizationMemberRole from .organization_metadata import OrganizationMetadata from .organization_sort_field_enum import OrganizationSortFieldEnum - from .organization_template import OrganizationTemplate - from .organization_template_allowed_strategy_enum import OrganizationTemplateAllowedStrategyEnum - from .organization_template_role_visibility_enum import OrganizationTemplateRoleVisibilityEnum - from .organization_template_role_visibility_override import OrganizationTemplateRoleVisibilityOverride - from .organization_template_role_visibility_policy import OrganizationTemplateRoleVisibilityPolicy - from .organization_template_use_for_organization_discovery import OrganizationTemplateUseForOrganizationDiscovery from .organization_third_party_client_access_enum import OrganizationThirdPartyClientAccessEnum from .organization_usage_enum import OrganizationUsageEnum from .partial_groups_enum import PartialGroupsEnum @@ -5954,6 +5979,17 @@ from .search_organizations_paginated_response_content import SearchOrganizationsPaginatedResponseContent from .search_parser_enum import SearchParserEnum from .search_resource_servers_response_content import SearchResourceServersResponseContent + from .segment import Segment + from .segment_contains_expression import SegmentContainsExpression + from .segment_ends_with_expression import SegmentEndsWithExpression + from .segment_exists_expression import SegmentExistsExpression + from .segment_match_conditions import SegmentMatchConditions + from .segment_match_expression import SegmentMatchExpression + from .segment_not_match_conditions import SegmentNotMatchConditions + from .segment_rule import SegmentRule + from .segment_starts_with_expression import SegmentStartsWithExpression + from .segment_type_enum import SegmentTypeEnum + from .segment_type_filter_enum import SegmentTypeFilterEnum from .self_service_profile import SelfServiceProfile from .self_service_profile_allowed_strategy_enum import SelfServiceProfileAllowedStrategyEnum from .self_service_profile_branding import SelfServiceProfileBranding @@ -6197,6 +6233,11 @@ from .update_enabled_client_connections_request_content import UpdateEnabledClientConnectionsRequestContent from .update_enabled_client_connections_request_content_item import UpdateEnabledClientConnectionsRequestContentItem from .update_event_stream_response_content import UpdateEventStreamResponseContent + from .update_experiment_response_content import UpdateExperimentResponseContent + from .update_experiment_status_response_content import UpdateExperimentStatusResponseContent + from .update_feature_flag_parameters import UpdateFeatureFlagParameters + from .update_feature_flag_response_content import UpdateFeatureFlagResponseContent + from .update_feature_flag_status_response_content import UpdateFeatureFlagStatusResponseContent from .update_flow_response_content import UpdateFlowResponseContent from .update_flows_vault_connection_response_content import UpdateFlowsVaultConnectionResponseContent from .update_flows_vault_connection_setup import UpdateFlowsVaultConnectionSetup @@ -6235,6 +6276,7 @@ from .update_role_response_content import UpdateRoleResponseContent from .update_rule_response_content import UpdateRuleResponseContent from .update_scim_configuration_response_content import UpdateScimConfigurationResponseContent + from .update_segment_response_content import UpdateSegmentResponseContent from .update_self_service_profile_response_content import UpdateSelfServiceProfileResponseContent from .update_session_response_content import UpdateSessionResponseContent from .update_settings_response_content import UpdateSettingsResponseContent @@ -6250,6 +6292,8 @@ from .update_user_attribute_profile_response_content import UpdateUserAttributeProfileResponseContent from .update_user_authentication_method_response_content import UpdateUserAuthenticationMethodResponseContent from .update_user_response_content import UpdateUserResponseContent + from .update_variation_overrides_map import UpdateVariationOverridesMap + from .update_variation_response_content import UpdateVariationResponseContent from .update_verifiable_credential_template_response_content import ( UpdateVerifiableCredentialTemplateResponseContent, ) @@ -6308,6 +6352,9 @@ from .username_attribute_identifier import UsernameAttributeIdentifier from .username_validation import UsernameValidation from .users_enrollment import UsersEnrollment + from .validate_experiment_response_content import ValidateExperimentResponseContent + from .variation import Variation + from .variation_overrides_map import VariationOverridesMap from .verifiable_credential_template_response import VerifiableCredentialTemplateResponse from .verification_method_enum import VerificationMethodEnum from .verify_custom_domain_response_content import VerifyCustomDomainResponseContent @@ -6373,6 +6420,9 @@ "AdvanceRampResponseContent": ".advance_ramp_response_content", "AgentMetadata": ".agent_metadata", "AgentResponseContent": ".agent_response_content", + "AllocationItem": ".allocation_item", + "AllocationRequestItem": ".allocation_request_item", + "AllocationStrategyEnum": ".allocation_strategy_enum", "AnomalyIpFormat": ".anomaly_ip_format", "AnonymousSessions": ".anonymous_sessions", "AppMetadata": ".app_metadata", @@ -6393,6 +6443,7 @@ "AttackProtectionUpdateCaptchaHcaptcha": ".attack_protection_update_captcha_hcaptcha", "AttackProtectionUpdateCaptchaRecaptchaEnterprise": ".attack_protection_update_captcha_recaptcha_enterprise", "AttackProtectionUpdateCaptchaRecaptchaV2": ".attack_protection_update_captcha_recaptcha_v_2", + "AuthenticationFlowEnum": ".authentication_flow_enum", "AuthenticationMethodTypeEnum": ".authentication_method_type_enum", "AuthenticationTypeEnum": ".authentication_type_enum", "B2BIntegrationConfiguration": ".b_2_b_integration_configuration", @@ -6540,6 +6591,8 @@ "ClientOidcBackchannelLogoutInitiatorsModeEnum": ".client_oidc_backchannel_logout_initiators_mode_enum", "ClientOidcBackchannelLogoutSessionMetadata": ".client_oidc_backchannel_logout_session_metadata", "ClientOidcBackchannelLogoutSettings": ".client_oidc_backchannel_logout_settings", + "ClientOidcSupportAllowedScopesEnum": ".client_oidc_support_allowed_scopes_enum", + "ClientOidcSupportPost": ".client_oidc_support_post", "ClientOrganizationDiscoveryEnum": ".client_organization_discovery_enum", "ClientOrganizationRequireBehaviorEnum": ".client_organization_require_behavior_enum", "ClientOrganizationRequireBehaviorPatchEnum": ".client_organization_require_behavior_patch_enum", @@ -6653,7 +6706,6 @@ "ConnectionDebugSaml": ".connection_debug_saml", "ConnectionDecryptionKeySaml": ".connection_decryption_key_saml", "ConnectionDecryptionKeySamlCert": ".connection_decryption_key_saml_cert", - "ConnectionDeletionBehaviorEnum": ".connection_deletion_behavior_enum", "ConnectionDestinationUrlSaml": ".connection_destination_url_saml", "ConnectionDigestAlgorithmEnumSaml": ".connection_digest_algorithm_enum_saml", "ConnectionDigestAlgorithmSaml": ".connection_digest_algorithm_saml", @@ -7064,6 +7116,9 @@ "ConnectionThumbprints": ".connection_thumbprints", "ConnectionThumbprintsAd": ".connection_thumbprints_ad", "ConnectionThumbprintsSaml": ".connection_thumbprints_saml", + "ConnectionThumbprintsSha384": ".connection_thumbprints_sha_384", + "ConnectionThumbprintsSha384Ad": ".connection_thumbprints_sha_384_ad", + "ConnectionThumbprintsSha384Saml": ".connection_thumbprints_sha_384_saml", "ConnectionTokenEndpoint": ".connection_token_endpoint", "ConnectionTokenEndpointAuthMethodEnum": ".connection_token_endpoint_auth_method_enum", "ConnectionTokenEndpointAuthMethodsSupported": ".connection_token_endpoint_auth_methods_supported", @@ -7246,8 +7301,11 @@ "CreateEventStreamResponseContent": ".create_event_stream_response_content", "CreateEventStreamTestEventResponseContent": ".create_event_stream_test_event_response_content", "CreateEventStreamWebHookRequestContent": ".create_event_stream_web_hook_request_content", + "CreateExperimentResponseContent": ".create_experiment_response_content", "CreateExportUsersFields": ".create_export_users_fields", "CreateExportUsersResponseContent": ".create_export_users_response_content", + "CreateFeatureFlagParameters": ".create_feature_flag_parameters", + "CreateFeatureFlagResponseContent": ".create_feature_flag_response_content", "CreateFlowResponseContent": ".create_flow_response_content", "CreateFlowsVaultConnectionActivecampaign": ".create_flows_vault_connection_activecampaign", "CreateFlowsVaultConnectionActivecampaignApiKey": ".create_flows_vault_connection_activecampaign_api_key", @@ -7356,6 +7414,7 @@ "CreateScimConfigurationRequestContent": ".create_scim_configuration_request_content", "CreateScimConfigurationResponseContent": ".create_scim_configuration_response_content", "CreateScimTokenResponseContent": ".create_scim_token_response_content", + "CreateSegmentResponseContent": ".create_segment_response_content", "CreateSelfServiceProfileResponseContent": ".create_self_service_profile_response_content", "CreateSelfServiceProfileSsoTicketResponseContent": ".create_self_service_profile_sso_ticket_response_content", "CreateTokenExchangeProfileResponseContent": ".create_token_exchange_profile_response_content", @@ -7363,6 +7422,7 @@ "CreateUserAttributeProfileResponseContent": ".create_user_attribute_profile_response_content", "CreateUserAuthenticationMethodResponseContent": ".create_user_authentication_method_response_content", "CreateUserResponseContent": ".create_user_response_content", + "CreateVariationResponseContent": ".create_variation_response_content", "CreateVerifiableCredentialTemplateResponseContent": ".create_verifiable_credential_template_response_content", "CreateVerificationEmailResponseContent": ".create_verification_email_response_content", "CreatedAuthenticationMethodTypeEnum": ".created_authentication_method_type_enum", @@ -7402,6 +7462,7 @@ "CustomSigningKeyTypeEnum": ".custom_signing_key_type_enum", "CustomSigningKeyUseEnum": ".custom_signing_key_use_enum", "DailyStats": ".daily_stats", + "DefaultConfigEnum": ".default_config_enum", "DefaultMethodEmailIdentifierEnum": ".default_method_email_identifier_enum", "DefaultMethodPhoneNumberIdentifierEnum": ".default_method_phone_number_identifier_enum", "DefaultTokenQuota": ".default_token_quota", @@ -8793,9 +8854,19 @@ "EventStreamWebhookDestination": ".event_stream_webhook_destination", "EventStreamWebhookDestinationTypeEnum": ".event_stream_webhook_destination_type_enum", "EventStreamWebhookResponseContent": ".event_stream_webhook_response_content", + "ExperimentListItem": ".experiment_list_item", + "ExperimentStatusEnum": ".experiment_status_enum", + "ExperimentTransitionStatusEnum": ".experiment_transition_status_enum", + "ExperimentValidationError": ".experiment_validation_error", "ExpressConfiguration": ".express_configuration", "ExpressConfigurationOrNull": ".express_configuration_or_null", "ExtensibilityEmailProviderCredentials": ".extensibility_email_provider_credentials", + "FeatureFlag": ".feature_flag", + "FeatureFlagConfigParam": ".feature_flag_config_param", + "FeatureFlagConfigParamTypeEnum": ".feature_flag_config_param_type_enum", + "FeatureFlagConfigParams": ".feature_flag_config_params", + "FeatureFlagStatusEnum": ".feature_flag_status_enum", + "FeatureFlagTypeEnum": ".feature_flag_type_enum", "FedCmLogin": ".fed_cm_login", "FedCmLoginGoogle": ".fed_cm_login_google", "FedCmLoginGooglePatch": ".fed_cm_login_google_patch", @@ -9398,6 +9469,8 @@ "GetEncryptionKeyResponseContent": ".get_encryption_key_response_content", "GetEventStreamDeliveryHistoryResponseContent": ".get_event_stream_delivery_history_response_content", "GetEventStreamResponseContent": ".get_event_stream_response_content", + "GetExperimentResponseContent": ".get_experiment_response_content", + "GetFeatureFlagResponseContent": ".get_feature_flag_response_content", "GetFlowExecutionRequestParametersHydrateEnum": ".get_flow_execution_request_parameters_hydrate_enum", "GetFlowExecutionResponseContent": ".get_flow_execution_response_content", "GetFlowRequestParametersHydrateEnum": ".get_flow_request_parameters_hydrate_enum", @@ -9453,6 +9526,7 @@ "GetScimConfigurationDefaultMappingResponseContent": ".get_scim_configuration_default_mapping_response_content", "GetScimConfigurationResponseContent": ".get_scim_configuration_response_content", "GetScimTokensResponseContent": ".get_scim_tokens_response_content", + "GetSegmentResponseContent": ".get_segment_response_content", "GetSelfServiceProfileResponseContent": ".get_self_service_profile_response_content", "GetSessionResponseContent": ".get_session_response_content", "GetSettingsResponseContent": ".get_settings_response_content", @@ -9468,6 +9542,7 @@ "GetUserAuthenticationMethodResponseContent": ".get_user_authentication_method_response_content", "GetUserGroupsPaginatedResponseContent": ".get_user_groups_paginated_response_content", "GetUserResponseContent": ".get_user_response_content", + "GetVariationResponseContent": ".get_variation_response_content", "GetVerifiableCredentialTemplateResponseContent": ".get_verifiable_credential_template_response_content", "Group": ".group", "GroupMember": ".group_member", @@ -9521,6 +9596,8 @@ "ListEncryptionKeyOffsetPaginatedResponseContent": ".list_encryption_key_offset_paginated_response_content", "ListEventStreamDeliveriesResponseContent": ".list_event_stream_deliveries_response_content", "ListEventStreamsResponseContent": ".list_event_streams_response_content", + "ListExperimentsResponseContent": ".list_experiments_response_content", + "ListFeatureFlagsResponseContent": ".list_feature_flags_response_content", "ListFlowExecutionsPaginatedResponseContent": ".list_flow_executions_paginated_response_content", "ListFlowsOffsetPaginatedResponseContent": ".list_flows_offset_paginated_response_content", "ListFlowsRequestParametersHydrateEnum": ".list_flows_request_parameters_hydrate_enum", @@ -9557,6 +9634,7 @@ "ListRolesOffsetPaginatedResponseContent": ".list_roles_offset_paginated_response_content", "ListRulesOffsetPaginatedResponseContent": ".list_rules_offset_paginated_response_content", "ListScimConfigurationsResponseContent": ".list_scim_configurations_response_content", + "ListSegmentsResponseContent": ".list_segments_response_content", "ListSelfServiceProfileCustomTextResponseContent": ".list_self_service_profile_custom_text_response_content", "ListSelfServiceProfilesPaginatedResponseContent": ".list_self_service_profiles_paginated_response_content", "ListSynchronizedGroupsResponseContent": ".list_synchronized_groups_response_content", @@ -9577,6 +9655,7 @@ "ListUserRolesOffsetPaginatedResponseContent": ".list_user_roles_offset_paginated_response_content", "ListUserSessionsPaginatedResponseContent": ".list_user_sessions_paginated_response_content", "ListUsersOffsetPaginatedResponseContent": ".list_users_offset_paginated_response_content", + "ListVariationsResponseContent": ".list_variations_response_content", "ListVerifiableCredentialTemplatesPaginatedResponseContent": ".list_verifiable_credential_templates_paginated_response_content", "Log": ".log", "LogDate": ".log_date", @@ -9674,7 +9753,6 @@ "OrganizationClientMetadataOrganizationUsageEnum": ".organization_client_metadata_organization_usage_enum", "OrganizationConnection": ".organization_connection", "OrganizationConnectionInformation": ".organization_connection_information", - "OrganizationDeletionBehaviorEnum": ".organization_deletion_behavior_enum", "OrganizationDiscoveryDomain": ".organization_discovery_domain", "OrganizationDiscoveryDomainStatus": ".organization_discovery_domain_status", "OrganizationEnabledConnection": ".organization_enabled_connection", @@ -9689,12 +9767,6 @@ "OrganizationMemberRole": ".organization_member_role", "OrganizationMetadata": ".organization_metadata", "OrganizationSortFieldEnum": ".organization_sort_field_enum", - "OrganizationTemplate": ".organization_template", - "OrganizationTemplateAllowedStrategyEnum": ".organization_template_allowed_strategy_enum", - "OrganizationTemplateRoleVisibilityEnum": ".organization_template_role_visibility_enum", - "OrganizationTemplateRoleVisibilityOverride": ".organization_template_role_visibility_override", - "OrganizationTemplateRoleVisibilityPolicy": ".organization_template_role_visibility_policy", - "OrganizationTemplateUseForOrganizationDiscovery": ".organization_template_use_for_organization_discovery", "OrganizationThirdPartyClientAccessEnum": ".organization_third_party_client_access_enum", "OrganizationUsageEnum": ".organization_usage_enum", "PartialGroupsEnum": ".partial_groups_enum", @@ -9815,6 +9887,17 @@ "SearchOrganizationsPaginatedResponseContent": ".search_organizations_paginated_response_content", "SearchParserEnum": ".search_parser_enum", "SearchResourceServersResponseContent": ".search_resource_servers_response_content", + "Segment": ".segment", + "SegmentContainsExpression": ".segment_contains_expression", + "SegmentEndsWithExpression": ".segment_ends_with_expression", + "SegmentExistsExpression": ".segment_exists_expression", + "SegmentMatchConditions": ".segment_match_conditions", + "SegmentMatchExpression": ".segment_match_expression", + "SegmentNotMatchConditions": ".segment_not_match_conditions", + "SegmentRule": ".segment_rule", + "SegmentStartsWithExpression": ".segment_starts_with_expression", + "SegmentTypeEnum": ".segment_type_enum", + "SegmentTypeFilterEnum": ".segment_type_filter_enum", "SelfServiceProfile": ".self_service_profile", "SelfServiceProfileAllowedStrategyEnum": ".self_service_profile_allowed_strategy_enum", "SelfServiceProfileBranding": ".self_service_profile_branding", @@ -10026,6 +10109,11 @@ "UpdateEnabledClientConnectionsRequestContent": ".update_enabled_client_connections_request_content", "UpdateEnabledClientConnectionsRequestContentItem": ".update_enabled_client_connections_request_content_item", "UpdateEventStreamResponseContent": ".update_event_stream_response_content", + "UpdateExperimentResponseContent": ".update_experiment_response_content", + "UpdateExperimentStatusResponseContent": ".update_experiment_status_response_content", + "UpdateFeatureFlagParameters": ".update_feature_flag_parameters", + "UpdateFeatureFlagResponseContent": ".update_feature_flag_response_content", + "UpdateFeatureFlagStatusResponseContent": ".update_feature_flag_status_response_content", "UpdateFlowResponseContent": ".update_flow_response_content", "UpdateFlowsVaultConnectionResponseContent": ".update_flows_vault_connection_response_content", "UpdateFlowsVaultConnectionSetup": ".update_flows_vault_connection_setup", @@ -10054,6 +10142,7 @@ "UpdateRoleResponseContent": ".update_role_response_content", "UpdateRuleResponseContent": ".update_rule_response_content", "UpdateScimConfigurationResponseContent": ".update_scim_configuration_response_content", + "UpdateSegmentResponseContent": ".update_segment_response_content", "UpdateSelfServiceProfileResponseContent": ".update_self_service_profile_response_content", "UpdateSessionResponseContent": ".update_session_response_content", "UpdateSettingsResponseContent": ".update_settings_response_content", @@ -10065,6 +10154,8 @@ "UpdateUserAttributeProfileResponseContent": ".update_user_attribute_profile_response_content", "UpdateUserAuthenticationMethodResponseContent": ".update_user_authentication_method_response_content", "UpdateUserResponseContent": ".update_user_response_content", + "UpdateVariationOverridesMap": ".update_variation_overrides_map", + "UpdateVariationResponseContent": ".update_variation_response_content", "UpdateVerifiableCredentialTemplateResponseContent": ".update_verifiable_credential_template_response_content", "UserAppMetadataSchema": ".user_app_metadata_schema", "UserAttributeProfile": ".user_attribute_profile", @@ -10115,6 +10206,9 @@ "UsernameAttributeIdentifier": ".username_attribute_identifier", "UsernameValidation": ".username_validation", "UsersEnrollment": ".users_enrollment", + "ValidateExperimentResponseContent": ".validate_experiment_response_content", + "Variation": ".variation", + "VariationOverridesMap": ".variation_overrides_map", "VerifiableCredentialTemplateResponse": ".verifiable_credential_template_response", "VerificationMethodEnum": ".verification_method_enum", "VerifyCustomDomainResponseContent": ".verify_custom_domain_response_content", @@ -10204,6 +10298,9 @@ def __dir__(): "AdvanceRampResponseContent", "AgentMetadata", "AgentResponseContent", + "AllocationItem", + "AllocationRequestItem", + "AllocationStrategyEnum", "AnomalyIpFormat", "AnonymousSessions", "AppMetadata", @@ -10224,6 +10321,7 @@ def __dir__(): "AttackProtectionUpdateCaptchaHcaptcha", "AttackProtectionUpdateCaptchaRecaptchaEnterprise", "AttackProtectionUpdateCaptchaRecaptchaV2", + "AuthenticationFlowEnum", "AuthenticationMethodTypeEnum", "AuthenticationTypeEnum", "B2BIntegrationConfiguration", @@ -10371,6 +10469,8 @@ def __dir__(): "ClientOidcBackchannelLogoutInitiatorsModeEnum", "ClientOidcBackchannelLogoutSessionMetadata", "ClientOidcBackchannelLogoutSettings", + "ClientOidcSupportAllowedScopesEnum", + "ClientOidcSupportPost", "ClientOrganizationDiscoveryEnum", "ClientOrganizationRequireBehaviorEnum", "ClientOrganizationRequireBehaviorPatchEnum", @@ -10484,7 +10584,6 @@ def __dir__(): "ConnectionDebugSaml", "ConnectionDecryptionKeySaml", "ConnectionDecryptionKeySamlCert", - "ConnectionDeletionBehaviorEnum", "ConnectionDestinationUrlSaml", "ConnectionDigestAlgorithmEnumSaml", "ConnectionDigestAlgorithmSaml", @@ -10895,6 +10994,9 @@ def __dir__(): "ConnectionThumbprints", "ConnectionThumbprintsAd", "ConnectionThumbprintsSaml", + "ConnectionThumbprintsSha384", + "ConnectionThumbprintsSha384Ad", + "ConnectionThumbprintsSha384Saml", "ConnectionTokenEndpoint", "ConnectionTokenEndpointAuthMethodEnum", "ConnectionTokenEndpointAuthMethodsSupported", @@ -11077,8 +11179,11 @@ def __dir__(): "CreateEventStreamResponseContent", "CreateEventStreamTestEventResponseContent", "CreateEventStreamWebHookRequestContent", + "CreateExperimentResponseContent", "CreateExportUsersFields", "CreateExportUsersResponseContent", + "CreateFeatureFlagParameters", + "CreateFeatureFlagResponseContent", "CreateFlowResponseContent", "CreateFlowsVaultConnectionActivecampaign", "CreateFlowsVaultConnectionActivecampaignApiKey", @@ -11187,6 +11292,7 @@ def __dir__(): "CreateScimConfigurationRequestContent", "CreateScimConfigurationResponseContent", "CreateScimTokenResponseContent", + "CreateSegmentResponseContent", "CreateSelfServiceProfileResponseContent", "CreateSelfServiceProfileSsoTicketResponseContent", "CreateTokenExchangeProfileResponseContent", @@ -11194,6 +11300,7 @@ def __dir__(): "CreateUserAttributeProfileResponseContent", "CreateUserAuthenticationMethodResponseContent", "CreateUserResponseContent", + "CreateVariationResponseContent", "CreateVerifiableCredentialTemplateResponseContent", "CreateVerificationEmailResponseContent", "CreatedAuthenticationMethodTypeEnum", @@ -11233,6 +11340,7 @@ def __dir__(): "CustomSigningKeyTypeEnum", "CustomSigningKeyUseEnum", "DailyStats", + "DefaultConfigEnum", "DefaultMethodEmailIdentifierEnum", "DefaultMethodPhoneNumberIdentifierEnum", "DefaultTokenQuota", @@ -12624,9 +12732,19 @@ def __dir__(): "EventStreamWebhookDestination", "EventStreamWebhookDestinationTypeEnum", "EventStreamWebhookResponseContent", + "ExperimentListItem", + "ExperimentStatusEnum", + "ExperimentTransitionStatusEnum", + "ExperimentValidationError", "ExpressConfiguration", "ExpressConfigurationOrNull", "ExtensibilityEmailProviderCredentials", + "FeatureFlag", + "FeatureFlagConfigParam", + "FeatureFlagConfigParamTypeEnum", + "FeatureFlagConfigParams", + "FeatureFlagStatusEnum", + "FeatureFlagTypeEnum", "FedCmLogin", "FedCmLoginGoogle", "FedCmLoginGooglePatch", @@ -13229,6 +13347,8 @@ def __dir__(): "GetEncryptionKeyResponseContent", "GetEventStreamDeliveryHistoryResponseContent", "GetEventStreamResponseContent", + "GetExperimentResponseContent", + "GetFeatureFlagResponseContent", "GetFlowExecutionRequestParametersHydrateEnum", "GetFlowExecutionResponseContent", "GetFlowRequestParametersHydrateEnum", @@ -13284,6 +13404,7 @@ def __dir__(): "GetScimConfigurationDefaultMappingResponseContent", "GetScimConfigurationResponseContent", "GetScimTokensResponseContent", + "GetSegmentResponseContent", "GetSelfServiceProfileResponseContent", "GetSessionResponseContent", "GetSettingsResponseContent", @@ -13299,6 +13420,7 @@ def __dir__(): "GetUserAuthenticationMethodResponseContent", "GetUserGroupsPaginatedResponseContent", "GetUserResponseContent", + "GetVariationResponseContent", "GetVerifiableCredentialTemplateResponseContent", "Group", "GroupMember", @@ -13352,6 +13474,8 @@ def __dir__(): "ListEncryptionKeyOffsetPaginatedResponseContent", "ListEventStreamDeliveriesResponseContent", "ListEventStreamsResponseContent", + "ListExperimentsResponseContent", + "ListFeatureFlagsResponseContent", "ListFlowExecutionsPaginatedResponseContent", "ListFlowsOffsetPaginatedResponseContent", "ListFlowsRequestParametersHydrateEnum", @@ -13388,6 +13512,7 @@ def __dir__(): "ListRolesOffsetPaginatedResponseContent", "ListRulesOffsetPaginatedResponseContent", "ListScimConfigurationsResponseContent", + "ListSegmentsResponseContent", "ListSelfServiceProfileCustomTextResponseContent", "ListSelfServiceProfilesPaginatedResponseContent", "ListSynchronizedGroupsResponseContent", @@ -13408,6 +13533,7 @@ def __dir__(): "ListUserRolesOffsetPaginatedResponseContent", "ListUserSessionsPaginatedResponseContent", "ListUsersOffsetPaginatedResponseContent", + "ListVariationsResponseContent", "ListVerifiableCredentialTemplatesPaginatedResponseContent", "Log", "LogDate", @@ -13505,7 +13631,6 @@ def __dir__(): "OrganizationClientMetadataOrganizationUsageEnum", "OrganizationConnection", "OrganizationConnectionInformation", - "OrganizationDeletionBehaviorEnum", "OrganizationDiscoveryDomain", "OrganizationDiscoveryDomainStatus", "OrganizationEnabledConnection", @@ -13520,12 +13645,6 @@ def __dir__(): "OrganizationMemberRole", "OrganizationMetadata", "OrganizationSortFieldEnum", - "OrganizationTemplate", - "OrganizationTemplateAllowedStrategyEnum", - "OrganizationTemplateRoleVisibilityEnum", - "OrganizationTemplateRoleVisibilityOverride", - "OrganizationTemplateRoleVisibilityPolicy", - "OrganizationTemplateUseForOrganizationDiscovery", "OrganizationThirdPartyClientAccessEnum", "OrganizationUsageEnum", "PartialGroupsEnum", @@ -13646,6 +13765,17 @@ def __dir__(): "SearchOrganizationsPaginatedResponseContent", "SearchParserEnum", "SearchResourceServersResponseContent", + "Segment", + "SegmentContainsExpression", + "SegmentEndsWithExpression", + "SegmentExistsExpression", + "SegmentMatchConditions", + "SegmentMatchExpression", + "SegmentNotMatchConditions", + "SegmentRule", + "SegmentStartsWithExpression", + "SegmentTypeEnum", + "SegmentTypeFilterEnum", "SelfServiceProfile", "SelfServiceProfileAllowedStrategyEnum", "SelfServiceProfileBranding", @@ -13857,6 +13987,11 @@ def __dir__(): "UpdateEnabledClientConnectionsRequestContent", "UpdateEnabledClientConnectionsRequestContentItem", "UpdateEventStreamResponseContent", + "UpdateExperimentResponseContent", + "UpdateExperimentStatusResponseContent", + "UpdateFeatureFlagParameters", + "UpdateFeatureFlagResponseContent", + "UpdateFeatureFlagStatusResponseContent", "UpdateFlowResponseContent", "UpdateFlowsVaultConnectionResponseContent", "UpdateFlowsVaultConnectionSetup", @@ -13885,6 +14020,7 @@ def __dir__(): "UpdateRoleResponseContent", "UpdateRuleResponseContent", "UpdateScimConfigurationResponseContent", + "UpdateSegmentResponseContent", "UpdateSelfServiceProfileResponseContent", "UpdateSessionResponseContent", "UpdateSettingsResponseContent", @@ -13896,6 +14032,8 @@ def __dir__(): "UpdateUserAttributeProfileResponseContent", "UpdateUserAuthenticationMethodResponseContent", "UpdateUserResponseContent", + "UpdateVariationOverridesMap", + "UpdateVariationResponseContent", "UpdateVerifiableCredentialTemplateResponseContent", "UserAppMetadataSchema", "UserAttributeProfile", @@ -13946,6 +14084,9 @@ def __dir__(): "UsernameAttributeIdentifier", "UsernameValidation", "UsersEnrollment", + "ValidateExperimentResponseContent", + "Variation", + "VariationOverridesMap", "VerifiableCredentialTemplateResponse", "VerificationMethodEnum", "VerifyCustomDomainResponseContent", diff --git a/src/auth0/management/types/allocation_item.py b/src/auth0/management/types/allocation_item.py new file mode 100644 index 00000000..08202bf7 --- /dev/null +++ b/src/auth0/management/types/allocation_item.py @@ -0,0 +1,28 @@ +# This file was auto-generated by Fern from our API Definition. + +import typing + +import pydantic +from ..core.pydantic_utilities import IS_PYDANTIC_V2, UniversalBaseModel + + +class AllocationItem(UniversalBaseModel): + variation_id: typing.Optional[str] = None + variation_name: typing.Optional[str] = None + segment_id: typing.Optional[str] = None + segment_name: typing.Optional[str] = None + weight: typing.Optional[int] = None + priority: typing.Optional[int] = None + is_control: typing.Optional[bool] = None + is_fallback: typing.Optional[bool] = None + variation_snapshot: typing.Optional[typing.Dict[str, typing.Any]] = None + segment_snapshot: typing.Optional[typing.Dict[str, typing.Any]] = None + + if IS_PYDANTIC_V2: + model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2 + else: + + class Config: + frozen = True + smart_union = True + extra = pydantic.Extra.allow diff --git a/src/auth0/management/types/allocation_request_item.py b/src/auth0/management/types/allocation_request_item.py new file mode 100644 index 00000000..760fc1f6 --- /dev/null +++ b/src/auth0/management/types/allocation_request_item.py @@ -0,0 +1,47 @@ +# This file was auto-generated by Fern from our API Definition. + +import typing + +import pydantic +from ..core.pydantic_utilities import IS_PYDANTIC_V2, UniversalBaseModel + + +class AllocationRequestItem(UniversalBaseModel): + variation_id: str = pydantic.Field() + """ + The ID of the variation to allocate + """ + + weight: typing.Optional[int] = pydantic.Field(default=None) + """ + Percentage weight for this allocation (percentage strategy only) + """ + + segment_id: typing.Optional[str] = pydantic.Field(default=None) + """ + The segment this allocation targets (segment strategy only) + """ + + priority: typing.Optional[int] = pydantic.Field(default=None) + """ + Evaluation order; 1 = highest priority (segment strategy only) + """ + + is_control: bool = pydantic.Field() + """ + Whether this allocation is the control group + """ + + is_fallback: typing.Optional[bool] = pydantic.Field(default=None) + """ + Whether this allocation is the default fallback (segment strategy only) + """ + + if IS_PYDANTIC_V2: + model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2 + else: + + class Config: + frozen = True + smart_union = True + extra = pydantic.Extra.allow diff --git a/src/auth0/management/types/allocation_strategy_enum.py b/src/auth0/management/types/allocation_strategy_enum.py new file mode 100644 index 00000000..e2ec53e8 --- /dev/null +++ b/src/auth0/management/types/allocation_strategy_enum.py @@ -0,0 +1,5 @@ +# This file was auto-generated by Fern from our API Definition. + +import typing + +AllocationStrategyEnum = typing.Union[typing.Literal["percentage", "segment"], typing.Any] diff --git a/src/auth0/management/types/async_approval_notifications_channels_enum.py b/src/auth0/management/types/async_approval_notifications_channels_enum.py index f012147e..b2571a94 100644 --- a/src/auth0/management/types/async_approval_notifications_channels_enum.py +++ b/src/auth0/management/types/async_approval_notifications_channels_enum.py @@ -2,4 +2,6 @@ import typing -AsyncApprovalNotificationsChannelsEnum = typing.Union[typing.Literal["guardian-push", "email"], typing.Any] +AsyncApprovalNotificationsChannelsEnum = typing.Union[ + typing.Literal["guardian-push", "email", "my-account"], typing.Any +] diff --git a/src/auth0/management/types/authentication_flow_enum.py b/src/auth0/management/types/authentication_flow_enum.py new file mode 100644 index 00000000..1facfb0d --- /dev/null +++ b/src/auth0/management/types/authentication_flow_enum.py @@ -0,0 +1,8 @@ +# This file was auto-generated by Fern from our API Definition. + +import typing + +AuthenticationFlowEnum = typing.Union[ + typing.Literal["authentication", "mfa_enrollment", "mfa_challenge", "password_reset", "passkey_enrollment", "all"], + typing.Any, +] diff --git a/src/auth0/management/types/client_async_approval_notifications_channels_api_patch_configuration.py b/src/auth0/management/types/client_async_approval_notifications_channels_api_patch_configuration.py index b7e62188..9fa2c4e3 100644 --- a/src/auth0/management/types/client_async_approval_notifications_channels_api_patch_configuration.py +++ b/src/auth0/management/types/client_async_approval_notifications_channels_api_patch_configuration.py @@ -8,5 +8,5 @@ typing.List[AsyncApprovalNotificationsChannelsEnum] ] """ -Array of notification channels for contacting the user when their approval is required. Valid values are `guardian-push`, `email`. +Array of notification channels for contacting the user when their approval is required. Valid values are `guardian-push`, `email`, `my-account`. """ diff --git a/src/auth0/management/types/client_async_approval_notifications_channels_api_post_configuration.py b/src/auth0/management/types/client_async_approval_notifications_channels_api_post_configuration.py index 6b723600..ef7fa6f3 100644 --- a/src/auth0/management/types/client_async_approval_notifications_channels_api_post_configuration.py +++ b/src/auth0/management/types/client_async_approval_notifications_channels_api_post_configuration.py @@ -6,5 +6,5 @@ ClientAsyncApprovalNotificationsChannelsApiPostConfiguration = typing.List[AsyncApprovalNotificationsChannelsEnum] """ -Array of notification channels for contacting the user when their approval is required. Valid values are `guardian-push`, `email`. +Array of notification channels for contacting the user when their approval is required. Valid values are `guardian-push`, `email`, `my-account`. """ diff --git a/src/auth0/management/types/client_oidc_backchannel_logout_initiators_enum.py b/src/auth0/management/types/client_oidc_backchannel_logout_initiators_enum.py index 9ed1eb90..88526b6f 100644 --- a/src/auth0/management/types/client_oidc_backchannel_logout_initiators_enum.py +++ b/src/auth0/management/types/client_oidc_backchannel_logout_initiators_enum.py @@ -13,6 +13,7 @@ "email-identifier-changed", "mfa-phone-unenrolled", "account-deactivated", + "profile-changed", ], typing.Any, ] diff --git a/src/auth0/management/types/client_oidc_support_allowed_scopes_enum.py b/src/auth0/management/types/client_oidc_support_allowed_scopes_enum.py new file mode 100644 index 00000000..b11e3c4a --- /dev/null +++ b/src/auth0/management/types/client_oidc_support_allowed_scopes_enum.py @@ -0,0 +1,5 @@ +# This file was auto-generated by Fern from our API Definition. + +import typing + +ClientOidcSupportAllowedScopesEnum = typing.Union[typing.Literal["profile", "email", "address", "phone"], typing.Any] diff --git a/src/auth0/management/types/client_oidc_support_post.py b/src/auth0/management/types/client_oidc_support_post.py new file mode 100644 index 00000000..9ae15738 --- /dev/null +++ b/src/auth0/management/types/client_oidc_support_post.py @@ -0,0 +1,26 @@ +# This file was auto-generated by Fern from our API Definition. + +import typing + +import pydantic +from ..core.pydantic_utilities import IS_PYDANTIC_V2, UniversalBaseModel +from .client_oidc_support_allowed_scopes_enum import ClientOidcSupportAllowedScopesEnum + + +class ClientOidcSupportPost(UniversalBaseModel): + """ + OIDC support configuration for a client. Controls whether OIDC flows are allowed and which scopes the client may request. + """ + + is_allowed: bool + allow_all_scopes: typing.Optional[bool] = None + allowed_scopes: typing.Optional[typing.List[ClientOidcSupportAllowedScopesEnum]] = None + + if IS_PYDANTIC_V2: + model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2 + else: + + class Config: + frozen = True + smart_union = True + extra = pydantic.Extra.allow diff --git a/src/auth0/management/types/connection_deletion_behavior_enum.py b/src/auth0/management/types/connection_deletion_behavior_enum.py deleted file mode 100644 index 1bb4c2e0..00000000 --- a/src/auth0/management/types/connection_deletion_behavior_enum.py +++ /dev/null @@ -1,5 +0,0 @@ -# This file was auto-generated by Fern from our API Definition. - -import typing - -ConnectionDeletionBehaviorEnum = typing.Union[typing.Literal["allow", "allow_if_empty"], typing.Any] diff --git a/src/auth0/management/types/connection_options_ad.py b/src/auth0/management/types/connection_options_ad.py index 630624b2..aa516f30 100644 --- a/src/auth0/management/types/connection_options_ad.py +++ b/src/auth0/management/types/connection_options_ad.py @@ -19,6 +19,7 @@ from .connection_sign_in_endpoint_ad import ConnectionSignInEndpointAd from .connection_tenant_domain_ad import ConnectionTenantDomainAd from .connection_thumbprints_ad import ConnectionThumbprintsAd +from .connection_thumbprints_sha_384_ad import ConnectionThumbprintsSha384Ad from .connection_upstream_params import ConnectionUpstreamParams @@ -78,6 +79,11 @@ class ConnectionOptionsAd(ConnectionOptionsCommon): ] = None tenant_domain: typing.Optional[ConnectionTenantDomainAd] = None thumbprints: typing.Optional[ConnectionThumbprintsAd] = None + thumbprints_sha_384: typing_extensions.Annotated[ + typing.Optional[ConnectionThumbprintsSha384Ad], + FieldMetadata(alias="thumbprints_sha384"), + pydantic.Field(alias="thumbprints_sha384"), + ] = None upstream_params: typing.Optional[ConnectionUpstreamParams] = None if IS_PYDANTIC_V2: diff --git a/src/auth0/management/types/connection_options_adfs.py b/src/auth0/management/types/connection_options_adfs.py index c265f66a..05e35434 100644 --- a/src/auth0/management/types/connection_options_adfs.py +++ b/src/auth0/management/types/connection_options_adfs.py @@ -15,6 +15,7 @@ from .connection_sign_in_endpoint_adfs import ConnectionSignInEndpointAdfs from .connection_tenant_domain import ConnectionTenantDomain from .connection_thumbprints import ConnectionThumbprints +from .connection_thumbprints_sha_384 import ConnectionThumbprintsSha384 from .connection_upstream_params import ConnectionUpstreamParams @@ -57,6 +58,11 @@ class ConnectionOptionsAdfs(ConnectionOptionsCommon): ] = None tenant_domain: typing.Optional[ConnectionTenantDomain] = None thumbprints: typing.Optional[ConnectionThumbprints] = None + thumbprints_sha_384: typing_extensions.Annotated[ + typing.Optional[ConnectionThumbprintsSha384], + FieldMetadata(alias="thumbprints_sha384"), + pydantic.Field(alias="thumbprints_sha384"), + ] = None upstream_params: typing.Optional[ConnectionUpstreamParams] = None user_id_attribute: typing.Optional[str] = pydantic.Field(default=None) """ diff --git a/src/auth0/management/types/connection_options_azure_ad.py b/src/auth0/management/types/connection_options_azure_ad.py index a7d04c26..31416423 100644 --- a/src/auth0/management/types/connection_options_azure_ad.py +++ b/src/auth0/management/types/connection_options_azure_ad.py @@ -26,6 +26,7 @@ from .connection_tenant_domain_azure_ad_one import ConnectionTenantDomainAzureAdOne from .connection_tenant_id_azure_ad import ConnectionTenantIdAzureAd from .connection_thumbprints import ConnectionThumbprints +from .connection_thumbprints_sha_384 import ConnectionThumbprintsSha384 from .connection_upstream_params import ConnectionUpstreamParams from .connection_use_common_endpoint_azure_ad import ConnectionUseCommonEndpointAzureAd from .connection_userid_attribute_azure_ad import ConnectionUseridAttributeAzureAd @@ -275,6 +276,11 @@ class ConnectionOptionsAzureAd(ConnectionOptionsCommon): typing.Optional[ConnectionTenantIdAzureAd], FieldMetadata(alias="tenantId"), pydantic.Field(alias="tenantId") ] = None thumbprints: typing.Optional[ConnectionThumbprints] = None + thumbprints_sha_384: typing_extensions.Annotated[ + typing.Optional[ConnectionThumbprintsSha384], + FieldMetadata(alias="thumbprints_sha384"), + pydantic.Field(alias="thumbprints_sha384"), + ] = None upstream_params: typing.Optional[ConnectionUpstreamParams] = None use_wsfed: typing.Optional[bool] = pydantic.Field(default=None) """ diff --git a/src/auth0/management/types/connection_options_common_saml.py b/src/auth0/management/types/connection_options_common_saml.py index 49071575..10597544 100644 --- a/src/auth0/management/types/connection_options_common_saml.py +++ b/src/auth0/management/types/connection_options_common_saml.py @@ -21,6 +21,7 @@ from .connection_signing_certificate_der_saml import ConnectionSigningCertificateDerSaml from .connection_tenant_domain_saml import ConnectionTenantDomainSaml from .connection_thumbprints_saml import ConnectionThumbprintsSaml +from .connection_thumbprints_sha_384_saml import ConnectionThumbprintsSha384Saml from .connection_upstream_params import ConnectionUpstreamParams @@ -70,6 +71,11 @@ class ConnectionOptionsCommonSaml(UniversalBaseModel): ] = None tenant_domain: typing.Optional[ConnectionTenantDomainSaml] = None thumbprints: typing.Optional[ConnectionThumbprintsSaml] = None + thumbprints_sha_384: typing_extensions.Annotated[ + typing.Optional[ConnectionThumbprintsSha384Saml], + FieldMetadata(alias="thumbprints_sha384"), + pydantic.Field(alias="thumbprints_sha384"), + ] = None upstream_params: typing.Optional[ConnectionUpstreamParams] = None if IS_PYDANTIC_V2: diff --git a/src/auth0/management/types/connection_properties_options.py b/src/auth0/management/types/connection_properties_options.py index d106c402..12bf209d 100644 --- a/src/auth0/management/types/connection_properties_options.py +++ b/src/auth0/management/types/connection_properties_options.py @@ -25,6 +25,8 @@ from .connection_password_policy_enum import ConnectionPasswordPolicyEnum from .connection_pushed_authorization_request_endpoint import ConnectionPushedAuthorizationRequestEndpoint from .connection_set_user_root_attributes_enum import ConnectionSetUserRootAttributesEnum +from .connection_thumbprints import ConnectionThumbprints +from .connection_thumbprints_sha_384 import ConnectionThumbprintsSha384 from .connection_token_endpoint_auth_method_enum import ConnectionTokenEndpointAuthMethodEnum from .connection_token_endpoint_auth_signing_alg_enum import ConnectionTokenEndpointAuthSigningAlgEnum from .connection_token_endpoint_jwtca_aud_format_enum_oidc import ConnectionTokenEndpointJwtcaAudFormatEnumOidc @@ -122,6 +124,12 @@ class ConnectionPropertiesOptions(UniversalBaseModel): ] = None discovery_url: typing.Optional[ConnectionsDiscoveryUrl] = None oidc_metadata: typing.Optional[ConnectionsOidcMetadata] = None + thumbprints: typing.Optional[ConnectionThumbprints] = None + thumbprints_sha_384: typing_extensions.Annotated[ + typing.Optional[ConnectionThumbprintsSha384], + FieldMetadata(alias="thumbprints_sha384"), + pydantic.Field(alias="thumbprints_sha384"), + ] = None if IS_PYDANTIC_V2: model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2 diff --git a/src/auth0/management/types/connection_thumbprints.py b/src/auth0/management/types/connection_thumbprints.py index fff89341..8764f29a 100644 --- a/src/auth0/management/types/connection_thumbprints.py +++ b/src/auth0/management/types/connection_thumbprints.py @@ -4,5 +4,5 @@ ConnectionThumbprints = typing.List[str] """ -Array of certificate thumbprints (SHA-128/SHA-256/SHA-512 hex hashes) for validating SAML signatures. Used with WS-Federation protocol. Maximum 20 thumbprints. Each thumbprint must be a hexadecimal string. +Array of certificate thumbprints (SHA-128 hex hashes) for validating SAML signatures. Used with WS-Federation protocol. Maximum 20 thumbprints. Each thumbprint must be a hexadecimal string. """ diff --git a/src/auth0/management/types/connection_thumbprints_sha_384.py b/src/auth0/management/types/connection_thumbprints_sha_384.py new file mode 100644 index 00000000..cce1b26f --- /dev/null +++ b/src/auth0/management/types/connection_thumbprints_sha_384.py @@ -0,0 +1,8 @@ +# This file was auto-generated by Fern from our API Definition. + +import typing + +ConnectionThumbprintsSha384 = typing.List[str] +""" +Array of certificate thumbprints (SHA-384 hex hashes) for validating SAML signatures. Used with WS-Federation protocol. Maximum 20 thumbprints. Each thumbprint must be a 96-character hexadecimal string. +""" diff --git a/src/auth0/management/types/connection_thumbprints_sha_384_ad.py b/src/auth0/management/types/connection_thumbprints_sha_384_ad.py new file mode 100644 index 00000000..2e4f4800 --- /dev/null +++ b/src/auth0/management/types/connection_thumbprints_sha_384_ad.py @@ -0,0 +1,8 @@ +# This file was auto-generated by Fern from our API Definition. + +import typing + +ConnectionThumbprintsSha384Ad = typing.List[str] +""" +Array of certificate SHA-384 thumbprints for validating signatures. Managed by Auth0 when using the AD Connector agent. +""" diff --git a/src/auth0/management/types/connection_thumbprints_sha_384_saml.py b/src/auth0/management/types/connection_thumbprints_sha_384_saml.py new file mode 100644 index 00000000..fb1a7be5 --- /dev/null +++ b/src/auth0/management/types/connection_thumbprints_sha_384_saml.py @@ -0,0 +1,8 @@ +# This file was auto-generated by Fern from our API Definition. + +import typing + +ConnectionThumbprintsSha384Saml = typing.List[str] +""" +SHA-384 thumbprints (fingerprints) of the identity provider's signing certificates. Automatically computed from signingCert during connection creation. Each thumbprint must be a 96-character hexadecimal string. +""" diff --git a/src/auth0/management/types/create_experiment_response_content.py b/src/auth0/management/types/create_experiment_response_content.py new file mode 100644 index 00000000..200f2ee9 --- /dev/null +++ b/src/auth0/management/types/create_experiment_response_content.py @@ -0,0 +1,54 @@ +# This file was auto-generated by Fern from our API Definition. + +import datetime as dt +import typing + +import pydantic +from ..core.pydantic_utilities import IS_PYDANTIC_V2, UniversalBaseModel +from .allocation_item import AllocationItem +from .allocation_strategy_enum import AllocationStrategyEnum +from .default_config_enum import DefaultConfigEnum +from .experiment_status_enum import ExperimentStatusEnum + + +class CreateExperimentResponseContent(UniversalBaseModel): + id: str + name: str + description: typing.Optional[str] = None + feature_flag_id: str + feature_flag_name: typing.Optional[str] = None + authentication_flow: str + allocation_strategy: AllocationStrategyEnum + status: ExperimentStatusEnum + is_valid: bool + default_config: typing.Optional[DefaultConfigEnum] = None + feature_flag_snapshot: typing.Optional[typing.Dict[str, typing.Any]] = None + allocations: typing.List[AllocationItem] + editable_fields: typing.List[str] = pydantic.Field() + """ + Fields that may be mutated given the experiment's current status. Computed at response time; always current with the API's enforcement logic. + """ + + levels: typing.Optional[typing.List[int]] = pydantic.Field(default=None) + """ + Ramp experiment levels configuration. + """ + + current_level: typing.Optional[int] = pydantic.Field(default=None) + """ + Read-only. The active exposure percentage for the current ramp step. Null when no ramp schedule is active. + """ + + started_at: typing.Optional[dt.datetime] = None + ended_at: typing.Optional[dt.datetime] = None + created_at: dt.datetime + updated_at: dt.datetime + + if IS_PYDANTIC_V2: + model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2 + else: + + class Config: + frozen = True + smart_union = True + extra = pydantic.Extra.allow diff --git a/src/auth0/management/types/create_feature_flag_parameters.py b/src/auth0/management/types/create_feature_flag_parameters.py new file mode 100644 index 00000000..4b6ba458 --- /dev/null +++ b/src/auth0/management/types/create_feature_flag_parameters.py @@ -0,0 +1,10 @@ +# This file was auto-generated by Fern from our API Definition. + +import typing + +from .feature_flag_config_param import FeatureFlagConfigParam + +CreateFeatureFlagParameters = typing.Dict[str, FeatureFlagConfigParam] +""" +Configuration parameters for this feature flag +""" diff --git a/src/auth0/management/types/create_feature_flag_response_content.py b/src/auth0/management/types/create_feature_flag_response_content.py new file mode 100644 index 00000000..938d278f --- /dev/null +++ b/src/auth0/management/types/create_feature_flag_response_content.py @@ -0,0 +1,30 @@ +# This file was auto-generated by Fern from our API Definition. + +import datetime as dt +import typing + +import pydantic +from ..core.pydantic_utilities import IS_PYDANTIC_V2, UniversalBaseModel +from .feature_flag_config_params import FeatureFlagConfigParams +from .feature_flag_status_enum import FeatureFlagStatusEnum +from .feature_flag_type_enum import FeatureFlagTypeEnum + + +class CreateFeatureFlagResponseContent(UniversalBaseModel): + id: str + name: str + description: typing.Optional[str] = None + type: FeatureFlagTypeEnum + status: FeatureFlagStatusEnum + parameters: typing.Optional[FeatureFlagConfigParams] = None + created_at: dt.datetime + updated_at: dt.datetime + + if IS_PYDANTIC_V2: + model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2 + else: + + class Config: + frozen = True + smart_union = True + extra = pydantic.Extra.allow diff --git a/src/auth0/management/types/create_resource_server_response_content.py b/src/auth0/management/types/create_resource_server_response_content.py index b3214093..447c41c3 100644 --- a/src/auth0/management/types/create_resource_server_response_content.py +++ b/src/auth0/management/types/create_resource_server_response_content.py @@ -91,6 +91,11 @@ class CreateResourceServerResponseContent(UniversalBaseModel): access_token: typing.Optional[ResourceServerAccessToken] = None token_encryption: typing.Optional[ResourceServerTokenEncryption] = None consent_policy: typing.Optional[ResourceServerConsentPolicyEnum] = None + require_consent_non_repudiation: typing.Optional[bool] = pydantic.Field(default=None) + """ + When true, the resource server requires every consent approval to be digitally signed, so the approver cannot later deny a consent they granted. When false, consent decisions do not need a signature. Defaults to false. A configured value is still returned even after the related entitlement is disabled. + """ + authorization_details: typing.Optional[typing.List[typing.Any]] = None proof_of_possession: typing.Optional[ResourceServerProofOfPossession] = None subject_type_authorization: typing.Optional[ResourceServerSubjectTypeAuthorization] = None diff --git a/src/auth0/management/types/create_segment_response_content.py b/src/auth0/management/types/create_segment_response_content.py new file mode 100644 index 00000000..5d97af4b --- /dev/null +++ b/src/auth0/management/types/create_segment_response_content.py @@ -0,0 +1,28 @@ +# This file was auto-generated by Fern from our API Definition. + +import datetime as dt +import typing + +import pydantic +from ..core.pydantic_utilities import IS_PYDANTIC_V2, UniversalBaseModel +from .segment_rule import SegmentRule +from .segment_type_enum import SegmentTypeEnum + + +class CreateSegmentResponseContent(UniversalBaseModel): + id: str + name: str + description: typing.Optional[str] = None + type: SegmentTypeEnum + rules: typing.List[SegmentRule] + created_at: dt.datetime + updated_at: dt.datetime + + if IS_PYDANTIC_V2: + model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2 + else: + + class Config: + frozen = True + smart_union = True + extra = pydantic.Extra.allow diff --git a/src/auth0/management/types/create_variation_response_content.py b/src/auth0/management/types/create_variation_response_content.py new file mode 100644 index 00000000..e7da6aeb --- /dev/null +++ b/src/auth0/management/types/create_variation_response_content.py @@ -0,0 +1,27 @@ +# This file was auto-generated by Fern from our API Definition. + +import datetime as dt +import typing + +import pydantic +from ..core.pydantic_utilities import IS_PYDANTIC_V2, UniversalBaseModel +from .variation_overrides_map import VariationOverridesMap + + +class CreateVariationResponseContent(UniversalBaseModel): + id: str + feature_flag_id: str + name: str + description: typing.Optional[str] = None + overrides: VariationOverridesMap + created_at: dt.datetime + updated_at: dt.datetime + + if IS_PYDANTIC_V2: + model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2 + else: + + class Config: + frozen = True + smart_union = True + extra = pydantic.Extra.allow diff --git a/src/auth0/management/types/default_config_enum.py b/src/auth0/management/types/default_config_enum.py new file mode 100644 index 00000000..0916c304 --- /dev/null +++ b/src/auth0/management/types/default_config_enum.py @@ -0,0 +1,5 @@ +# This file was auto-generated by Fern from our API Definition. + +import typing + +DefaultConfigEnum = typing.Union[typing.Literal["tenant", "flag"], typing.Any] diff --git a/src/auth0/management/types/experiment_list_item.py b/src/auth0/management/types/experiment_list_item.py new file mode 100644 index 00000000..1c4ba5fe --- /dev/null +++ b/src/auth0/management/types/experiment_list_item.py @@ -0,0 +1,54 @@ +# This file was auto-generated by Fern from our API Definition. + +import datetime as dt +import typing + +import pydantic +from ..core.pydantic_utilities import IS_PYDANTIC_V2, UniversalBaseModel +from .allocation_item import AllocationItem +from .allocation_strategy_enum import AllocationStrategyEnum +from .default_config_enum import DefaultConfigEnum +from .experiment_status_enum import ExperimentStatusEnum + + +class ExperimentListItem(UniversalBaseModel): + id: str + name: str + description: typing.Optional[str] = None + feature_flag_id: str + feature_flag_name: typing.Optional[str] = None + authentication_flow: str + allocation_strategy: AllocationStrategyEnum + status: ExperimentStatusEnum + is_valid: bool + default_config: typing.Optional[DefaultConfigEnum] = None + feature_flag_snapshot: typing.Optional[typing.Dict[str, typing.Any]] = None + allocations: typing.List[AllocationItem] + editable_fields: typing.List[str] = pydantic.Field() + """ + Fields that may be mutated given the experiment's current status. Computed at response time; always current with the API's enforcement logic. + """ + + levels: typing.Optional[typing.List[int]] = pydantic.Field(default=None) + """ + Ramp experiment levels configuration. + """ + + current_level: typing.Optional[int] = pydantic.Field(default=None) + """ + Read-only. The active exposure percentage for the current ramp step. Null when no ramp schedule is active. + """ + + started_at: typing.Optional[dt.datetime] = None + ended_at: typing.Optional[dt.datetime] = None + created_at: dt.datetime + updated_at: dt.datetime + + if IS_PYDANTIC_V2: + model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2 + else: + + class Config: + frozen = True + smart_union = True + extra = pydantic.Extra.allow diff --git a/src/auth0/management/types/experiment_status_enum.py b/src/auth0/management/types/experiment_status_enum.py new file mode 100644 index 00000000..e0d8f152 --- /dev/null +++ b/src/auth0/management/types/experiment_status_enum.py @@ -0,0 +1,5 @@ +# This file was auto-generated by Fern from our API Definition. + +import typing + +ExperimentStatusEnum = typing.Union[typing.Literal["draft", "active", "paused", "completed", "archived"], typing.Any] diff --git a/src/auth0/management/types/experiment_transition_status_enum.py b/src/auth0/management/types/experiment_transition_status_enum.py new file mode 100644 index 00000000..264d2ab8 --- /dev/null +++ b/src/auth0/management/types/experiment_transition_status_enum.py @@ -0,0 +1,5 @@ +# This file was auto-generated by Fern from our API Definition. + +import typing + +ExperimentTransitionStatusEnum = typing.Union[typing.Literal["active", "paused", "completed", "archived"], typing.Any] diff --git a/src/auth0/management/types/organization_template_role_visibility_override.py b/src/auth0/management/types/experiment_validation_error.py similarity index 61% rename from src/auth0/management/types/organization_template_role_visibility_override.py rename to src/auth0/management/types/experiment_validation_error.py index 8c4a7411..01b7a291 100644 --- a/src/auth0/management/types/organization_template_role_visibility_override.py +++ b/src/auth0/management/types/experiment_validation_error.py @@ -4,21 +4,19 @@ import pydantic from ..core.pydantic_utilities import IS_PYDANTIC_V2, UniversalBaseModel -from .organization_template_role_visibility_enum import OrganizationTemplateRoleVisibilityEnum -class OrganizationTemplateRoleVisibilityOverride(UniversalBaseModel): +class ExperimentValidationError(UniversalBaseModel): + code: str = pydantic.Field() """ - A role visibility override. + Machine-readable error code identifying the validation failure. """ - role_id: str = pydantic.Field() + message: str = pydantic.Field() """ - The role identifier. + Human-readable description of the validation failure. """ - access: OrganizationTemplateRoleVisibilityEnum - if IS_PYDANTIC_V2: model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2 else: diff --git a/src/auth0/management/types/feature_flag.py b/src/auth0/management/types/feature_flag.py new file mode 100644 index 00000000..8366ff79 --- /dev/null +++ b/src/auth0/management/types/feature_flag.py @@ -0,0 +1,30 @@ +# This file was auto-generated by Fern from our API Definition. + +import datetime as dt +import typing + +import pydantic +from ..core.pydantic_utilities import IS_PYDANTIC_V2, UniversalBaseModel +from .feature_flag_config_params import FeatureFlagConfigParams +from .feature_flag_status_enum import FeatureFlagStatusEnum +from .feature_flag_type_enum import FeatureFlagTypeEnum + + +class FeatureFlag(UniversalBaseModel): + id: str + name: str + description: typing.Optional[str] = None + type: FeatureFlagTypeEnum + status: FeatureFlagStatusEnum + parameters: typing.Optional[FeatureFlagConfigParams] = None + created_at: dt.datetime + updated_at: dt.datetime + + if IS_PYDANTIC_V2: + model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2 + else: + + class Config: + frozen = True + smart_union = True + extra = pydantic.Extra.allow diff --git a/src/auth0/management/types/feature_flag_config_param.py b/src/auth0/management/types/feature_flag_config_param.py new file mode 100644 index 00000000..eef7477f --- /dev/null +++ b/src/auth0/management/types/feature_flag_config_param.py @@ -0,0 +1,25 @@ +# This file was auto-generated by Fern from our API Definition. + +import typing + +import pydantic +from ..core.pydantic_utilities import IS_PYDANTIC_V2, UniversalBaseModel +from .feature_flag_config_param_type_enum import FeatureFlagConfigParamTypeEnum + + +class FeatureFlagConfigParam(UniversalBaseModel): + type: FeatureFlagConfigParamTypeEnum + value: typing.Any + description: typing.Optional[str] = pydantic.Field(default=None) + """ + A human-readable description of the parameter + """ + + if IS_PYDANTIC_V2: + model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2 + else: + + class Config: + frozen = True + smart_union = True + extra = pydantic.Extra.allow diff --git a/src/auth0/management/types/feature_flag_config_param_type_enum.py b/src/auth0/management/types/feature_flag_config_param_type_enum.py new file mode 100644 index 00000000..928f82a6 --- /dev/null +++ b/src/auth0/management/types/feature_flag_config_param_type_enum.py @@ -0,0 +1,7 @@ +# This file was auto-generated by Fern from our API Definition. + +import typing + +FeatureFlagConfigParamTypeEnum = typing.Union[ + typing.Literal["string", "boolean", "number", "array", "object"], typing.Any +] diff --git a/src/auth0/management/types/feature_flag_config_params.py b/src/auth0/management/types/feature_flag_config_params.py new file mode 100644 index 00000000..b68b0798 --- /dev/null +++ b/src/auth0/management/types/feature_flag_config_params.py @@ -0,0 +1,10 @@ +# This file was auto-generated by Fern from our API Definition. + +import typing + +from .feature_flag_config_param import FeatureFlagConfigParam + +FeatureFlagConfigParams = typing.Dict[str, FeatureFlagConfigParam] +""" +Configuration parameters for this feature flag +""" diff --git a/src/auth0/management/types/feature_flag_status_enum.py b/src/auth0/management/types/feature_flag_status_enum.py new file mode 100644 index 00000000..3a379401 --- /dev/null +++ b/src/auth0/management/types/feature_flag_status_enum.py @@ -0,0 +1,5 @@ +# This file was auto-generated by Fern from our API Definition. + +import typing + +FeatureFlagStatusEnum = typing.Union[typing.Literal["draft", "active", "archived"], typing.Any] diff --git a/src/auth0/management/types/feature_flag_type_enum.py b/src/auth0/management/types/feature_flag_type_enum.py new file mode 100644 index 00000000..1852075f --- /dev/null +++ b/src/auth0/management/types/feature_flag_type_enum.py @@ -0,0 +1,5 @@ +# This file was auto-generated by Fern from our API Definition. + +import typing + +FeatureFlagTypeEnum = typing.Union[typing.Literal["auth0", "self"], typing.Any] diff --git a/src/auth0/management/types/get_experiment_response_content.py b/src/auth0/management/types/get_experiment_response_content.py new file mode 100644 index 00000000..5ea178c1 --- /dev/null +++ b/src/auth0/management/types/get_experiment_response_content.py @@ -0,0 +1,54 @@ +# This file was auto-generated by Fern from our API Definition. + +import datetime as dt +import typing + +import pydantic +from ..core.pydantic_utilities import IS_PYDANTIC_V2, UniversalBaseModel +from .allocation_item import AllocationItem +from .allocation_strategy_enum import AllocationStrategyEnum +from .default_config_enum import DefaultConfigEnum +from .experiment_status_enum import ExperimentStatusEnum + + +class GetExperimentResponseContent(UniversalBaseModel): + id: str + name: str + description: typing.Optional[str] = None + feature_flag_id: str + feature_flag_name: typing.Optional[str] = None + authentication_flow: str + allocation_strategy: AllocationStrategyEnum + status: ExperimentStatusEnum + is_valid: bool + default_config: typing.Optional[DefaultConfigEnum] = None + feature_flag_snapshot: typing.Optional[typing.Dict[str, typing.Any]] = None + allocations: typing.List[AllocationItem] + editable_fields: typing.List[str] = pydantic.Field() + """ + Fields that may be mutated given the experiment's current status. Computed at response time; always current with the API's enforcement logic. + """ + + levels: typing.Optional[typing.List[int]] = pydantic.Field(default=None) + """ + Ramp experiment levels configuration. + """ + + current_level: typing.Optional[int] = pydantic.Field(default=None) + """ + Read-only. The active exposure percentage for the current ramp step. Null when no ramp schedule is active. + """ + + started_at: typing.Optional[dt.datetime] = None + ended_at: typing.Optional[dt.datetime] = None + created_at: dt.datetime + updated_at: dt.datetime + + if IS_PYDANTIC_V2: + model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2 + else: + + class Config: + frozen = True + smart_union = True + extra = pydantic.Extra.allow diff --git a/src/auth0/management/types/get_feature_flag_response_content.py b/src/auth0/management/types/get_feature_flag_response_content.py new file mode 100644 index 00000000..cbf3985c --- /dev/null +++ b/src/auth0/management/types/get_feature_flag_response_content.py @@ -0,0 +1,30 @@ +# This file was auto-generated by Fern from our API Definition. + +import datetime as dt +import typing + +import pydantic +from ..core.pydantic_utilities import IS_PYDANTIC_V2, UniversalBaseModel +from .feature_flag_config_params import FeatureFlagConfigParams +from .feature_flag_status_enum import FeatureFlagStatusEnum +from .feature_flag_type_enum import FeatureFlagTypeEnum + + +class GetFeatureFlagResponseContent(UniversalBaseModel): + id: str + name: str + description: typing.Optional[str] = None + type: FeatureFlagTypeEnum + status: FeatureFlagStatusEnum + parameters: typing.Optional[FeatureFlagConfigParams] = None + created_at: dt.datetime + updated_at: dt.datetime + + if IS_PYDANTIC_V2: + model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2 + else: + + class Config: + frozen = True + smart_union = True + extra = pydantic.Extra.allow diff --git a/src/auth0/management/types/get_resource_server_response_content.py b/src/auth0/management/types/get_resource_server_response_content.py index a99c4bdd..0b60b730 100644 --- a/src/auth0/management/types/get_resource_server_response_content.py +++ b/src/auth0/management/types/get_resource_server_response_content.py @@ -91,6 +91,11 @@ class GetResourceServerResponseContent(UniversalBaseModel): access_token: typing.Optional[ResourceServerAccessToken] = None token_encryption: typing.Optional[ResourceServerTokenEncryption] = None consent_policy: typing.Optional[ResourceServerConsentPolicyEnum] = None + require_consent_non_repudiation: typing.Optional[bool] = pydantic.Field(default=None) + """ + When true, the resource server requires every consent approval to be digitally signed, so the approver cannot later deny a consent they granted. When false, consent decisions do not need a signature. Defaults to false. A configured value is still returned even after the related entitlement is disabled. + """ + authorization_details: typing.Optional[typing.List[typing.Any]] = None proof_of_possession: typing.Optional[ResourceServerProofOfPossession] = None subject_type_authorization: typing.Optional[ResourceServerSubjectTypeAuthorization] = None diff --git a/src/auth0/management/types/get_segment_response_content.py b/src/auth0/management/types/get_segment_response_content.py new file mode 100644 index 00000000..7e808477 --- /dev/null +++ b/src/auth0/management/types/get_segment_response_content.py @@ -0,0 +1,28 @@ +# This file was auto-generated by Fern from our API Definition. + +import datetime as dt +import typing + +import pydantic +from ..core.pydantic_utilities import IS_PYDANTIC_V2, UniversalBaseModel +from .segment_rule import SegmentRule +from .segment_type_enum import SegmentTypeEnum + + +class GetSegmentResponseContent(UniversalBaseModel): + id: str + name: str + description: typing.Optional[str] = None + type: SegmentTypeEnum + rules: typing.List[SegmentRule] + created_at: dt.datetime + updated_at: dt.datetime + + if IS_PYDANTIC_V2: + model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2 + else: + + class Config: + frozen = True + smart_union = True + extra = pydantic.Extra.allow diff --git a/src/auth0/management/types/get_variation_response_content.py b/src/auth0/management/types/get_variation_response_content.py new file mode 100644 index 00000000..747c9566 --- /dev/null +++ b/src/auth0/management/types/get_variation_response_content.py @@ -0,0 +1,27 @@ +# This file was auto-generated by Fern from our API Definition. + +import datetime as dt +import typing + +import pydantic +from ..core.pydantic_utilities import IS_PYDANTIC_V2, UniversalBaseModel +from .variation_overrides_map import VariationOverridesMap + + +class GetVariationResponseContent(UniversalBaseModel): + id: str + feature_flag_id: str + name: str + description: typing.Optional[str] = None + overrides: VariationOverridesMap + created_at: dt.datetime + updated_at: dt.datetime + + if IS_PYDANTIC_V2: + model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2 + else: + + class Config: + frozen = True + smart_union = True + extra = pydantic.Extra.allow diff --git a/src/auth0/management/types/list_experiments_response_content.py b/src/auth0/management/types/list_experiments_response_content.py new file mode 100644 index 00000000..e4d965b9 --- /dev/null +++ b/src/auth0/management/types/list_experiments_response_content.py @@ -0,0 +1,24 @@ +# This file was auto-generated by Fern from our API Definition. + +import typing + +import pydantic +from ..core.pydantic_utilities import IS_PYDANTIC_V2, UniversalBaseModel +from .experiment_list_item import ExperimentListItem + + +class ListExperimentsResponseContent(UniversalBaseModel): + experiments: typing.List[ExperimentListItem] + next: typing.Optional[str] = pydantic.Field(default=None) + """ + Checkpoint token for the next page. Omitted when there are no further results. + """ + + if IS_PYDANTIC_V2: + model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2 + else: + + class Config: + frozen = True + smart_union = True + extra = pydantic.Extra.allow diff --git a/src/auth0/management/types/list_feature_flags_response_content.py b/src/auth0/management/types/list_feature_flags_response_content.py new file mode 100644 index 00000000..19ea3893 --- /dev/null +++ b/src/auth0/management/types/list_feature_flags_response_content.py @@ -0,0 +1,24 @@ +# This file was auto-generated by Fern from our API Definition. + +import typing + +import pydantic +from ..core.pydantic_utilities import IS_PYDANTIC_V2, UniversalBaseModel +from .feature_flag import FeatureFlag + + +class ListFeatureFlagsResponseContent(UniversalBaseModel): + feature_flags: typing.List[FeatureFlag] + next: typing.Optional[str] = pydantic.Field(default=None) + """ + Checkpoint token for the next page. Omitted when there are no further results. + """ + + if IS_PYDANTIC_V2: + model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2 + else: + + class Config: + frozen = True + smart_union = True + extra = pydantic.Extra.allow diff --git a/src/auth0/management/types/list_segments_response_content.py b/src/auth0/management/types/list_segments_response_content.py new file mode 100644 index 00000000..0147aaa0 --- /dev/null +++ b/src/auth0/management/types/list_segments_response_content.py @@ -0,0 +1,24 @@ +# This file was auto-generated by Fern from our API Definition. + +import typing + +import pydantic +from ..core.pydantic_utilities import IS_PYDANTIC_V2, UniversalBaseModel +from .segment import Segment + + +class ListSegmentsResponseContent(UniversalBaseModel): + segments: typing.List[Segment] + next: typing.Optional[str] = pydantic.Field(default=None) + """ + Checkpoint token for the next page. Omitted when there are no further results. + """ + + if IS_PYDANTIC_V2: + model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2 + else: + + class Config: + frozen = True + smart_union = True + extra = pydantic.Extra.allow diff --git a/src/auth0/management/types/list_variations_response_content.py b/src/auth0/management/types/list_variations_response_content.py new file mode 100644 index 00000000..a4d76655 --- /dev/null +++ b/src/auth0/management/types/list_variations_response_content.py @@ -0,0 +1,20 @@ +# This file was auto-generated by Fern from our API Definition. + +import typing + +import pydantic +from ..core.pydantic_utilities import IS_PYDANTIC_V2, UniversalBaseModel +from .variation import Variation + + +class ListVariationsResponseContent(UniversalBaseModel): + variations: typing.List[Variation] + + if IS_PYDANTIC_V2: + model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2 + else: + + class Config: + frozen = True + smart_union = True + extra = pydantic.Extra.allow diff --git a/src/auth0/management/types/oauth_scope.py b/src/auth0/management/types/oauth_scope.py index 92c1eb8c..78347dc7 100644 --- a/src/auth0/management/types/oauth_scope.py +++ b/src/auth0/management/types/oauth_scope.py @@ -88,7 +88,10 @@ "update:event_streams", "delete:event_streams", "read:events", + "create:experimentation", + "read:experimentation", "update:experimentation", + "delete:experimentation", "create:flows", "read:flows", "update:flows", @@ -249,7 +252,6 @@ "read:organization_clients", "update:organization_clients", "delete:organization_clients", - "read:organization_templates", "create:network_acl_keys", "read:network_acl_keys", "delete:network_acl_keys", diff --git a/src/auth0/management/types/organization_deletion_behavior_enum.py b/src/auth0/management/types/organization_deletion_behavior_enum.py deleted file mode 100644 index 094b7b2d..00000000 --- a/src/auth0/management/types/organization_deletion_behavior_enum.py +++ /dev/null @@ -1,5 +0,0 @@ -# This file was auto-generated by Fern from our API Definition. - -import typing - -OrganizationDeletionBehaviorEnum = typing.Union[typing.Literal["allow", "allow_if_empty"], typing.Any] diff --git a/src/auth0/management/types/organization_template.py b/src/auth0/management/types/organization_template.py deleted file mode 100644 index d5c653ca..00000000 --- a/src/auth0/management/types/organization_template.py +++ /dev/null @@ -1,89 +0,0 @@ -# This file was auto-generated by Fern from our API Definition. - -import datetime as dt -import typing - -import pydantic -from ..core.pydantic_utilities import IS_PYDANTIC_V2, UniversalBaseModel -from .connection_deletion_behavior_enum import ConnectionDeletionBehaviorEnum -from .organization_deletion_behavior_enum import OrganizationDeletionBehaviorEnum -from .organization_template_allowed_strategy_enum import OrganizationTemplateAllowedStrategyEnum -from .organization_template_role_visibility_policy import OrganizationTemplateRoleVisibilityPolicy -from .organization_template_use_for_organization_discovery import OrganizationTemplateUseForOrganizationDiscovery - - -class OrganizationTemplate(UniversalBaseModel): - id: typing.Optional[str] = pydantic.Field(default=None) - """ - Organization Template identifier. - """ - - name: typing.Optional[str] = pydantic.Field(default=None) - """ - The name of the organization template. - """ - - is_default: typing.Optional[bool] = pydantic.Field(default=None) - """ - Whether this is the default template applied to new organizations. - """ - - organization_deletion_behavior: typing.Optional[OrganizationDeletionBehaviorEnum] = None - connection_deletion_behavior: typing.Optional[ConnectionDeletionBehaviorEnum] = None - enforce_permission_ceiling: typing.Optional[bool] = pydantic.Field(default=None) - """ - Whether to enforce permission ceiling for organizations using this template. - """ - - enforce_self_assignment_restriction: typing.Optional[bool] = pydantic.Field(default=None) - """ - Whether to enforce self-assignment restrictions for organizations using this template. - """ - - connection_profile_id: typing.Optional[str] = pydantic.Field(default=None) - """ - The connection profile to apply to new connections. - """ - - user_attribute_profile_id: typing.Optional[str] = pydantic.Field(default=None) - """ - The user attribute profile to apply to organizations. - """ - - allowed_strategies: typing.Optional[typing.List[OrganizationTemplateAllowedStrategyEnum]] = pydantic.Field( - default=None - ) - """ - List of allowed connection strategies for this template. - """ - - invitation_landing_client_id: typing.Optional[str] = pydantic.Field(default=None) - """ - The client ID for the invitation landing page. - """ - - admin_roles_assignment: typing.Optional[typing.List[str]] = pydantic.Field(default=None) - """ - Default admin roles to assign to organization creators. - """ - - use_for_organization_discovery: typing.Optional[OrganizationTemplateUseForOrganizationDiscovery] = None - role_visibility_policy: typing.Optional[OrganizationTemplateRoleVisibilityPolicy] = None - created_at: typing.Optional[dt.datetime] = pydantic.Field(default=None) - """ - The ISO 8601 formatted timestamp representing when the template was created. - """ - - updated_at: typing.Optional[dt.datetime] = pydantic.Field(default=None) - """ - The ISO 8601 formatted timestamp representing when the template was last updated. - """ - - if IS_PYDANTIC_V2: - model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2 - else: - - class Config: - frozen = True - smart_union = True - extra = pydantic.Extra.allow diff --git a/src/auth0/management/types/organization_template_allowed_strategy_enum.py b/src/auth0/management/types/organization_template_allowed_strategy_enum.py deleted file mode 100644 index 7b5d2364..00000000 --- a/src/auth0/management/types/organization_template_allowed_strategy_enum.py +++ /dev/null @@ -1,7 +0,0 @@ -# This file was auto-generated by Fern from our API Definition. - -import typing - -OrganizationTemplateAllowedStrategyEnum = typing.Union[ - typing.Literal["adfs", "google-apps", "oidc", "okta", "pingfederate", "samlp", "waad"], typing.Any -] diff --git a/src/auth0/management/types/organization_template_role_visibility_enum.py b/src/auth0/management/types/organization_template_role_visibility_enum.py deleted file mode 100644 index 0448c321..00000000 --- a/src/auth0/management/types/organization_template_role_visibility_enum.py +++ /dev/null @@ -1,5 +0,0 @@ -# This file was auto-generated by Fern from our API Definition. - -import typing - -OrganizationTemplateRoleVisibilityEnum = typing.Union[typing.Literal["write", "read_only", "hidden"], typing.Any] diff --git a/src/auth0/management/types/organization_template_role_visibility_policy.py b/src/auth0/management/types/organization_template_role_visibility_policy.py deleted file mode 100644 index 52242742..00000000 --- a/src/auth0/management/types/organization_template_role_visibility_policy.py +++ /dev/null @@ -1,29 +0,0 @@ -# This file was auto-generated by Fern from our API Definition. - -import typing - -import pydantic -from ..core.pydantic_utilities import IS_PYDANTIC_V2, UniversalBaseModel -from .organization_template_role_visibility_enum import OrganizationTemplateRoleVisibilityEnum -from .organization_template_role_visibility_override import OrganizationTemplateRoleVisibilityOverride - - -class OrganizationTemplateRoleVisibilityPolicy(UniversalBaseModel): - """ - Controls role visibility for organization administrators. - """ - - default_value: OrganizationTemplateRoleVisibilityEnum - overrides: typing.Optional[typing.List[OrganizationTemplateRoleVisibilityOverride]] = pydantic.Field(default=None) - """ - Role-specific visibility overrides. - """ - - if IS_PYDANTIC_V2: - model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2 - else: - - class Config: - frozen = True - smart_union = True - extra = pydantic.Extra.allow diff --git a/src/auth0/management/types/resource_server.py b/src/auth0/management/types/resource_server.py index 027b110c..b2b161aa 100644 --- a/src/auth0/management/types/resource_server.py +++ b/src/auth0/management/types/resource_server.py @@ -91,6 +91,11 @@ class ResourceServer(UniversalBaseModel): access_token: typing.Optional[ResourceServerAccessToken] = None token_encryption: typing.Optional[ResourceServerTokenEncryption] = None consent_policy: typing.Optional[ResourceServerConsentPolicyEnum] = None + require_consent_non_repudiation: typing.Optional[bool] = pydantic.Field(default=None) + """ + When true, the resource server requires every consent approval to be digitally signed, so the approver cannot later deny a consent they granted. When false, consent decisions do not need a signature. Defaults to false. A configured value is still returned even after the related entitlement is disabled. + """ + authorization_details: typing.Optional[typing.List[typing.Any]] = None proof_of_possession: typing.Optional[ResourceServerProofOfPossession] = None subject_type_authorization: typing.Optional[ResourceServerSubjectTypeAuthorization] = None diff --git a/src/auth0/management/types/resource_server_search_response.py b/src/auth0/management/types/resource_server_search_response.py index a14256a5..2c9438fb 100644 --- a/src/auth0/management/types/resource_server_search_response.py +++ b/src/auth0/management/types/resource_server_search_response.py @@ -86,6 +86,11 @@ class ResourceServerSearchResponse(UniversalBaseModel): access_token: typing.Optional[ResourceServerAccessToken] = None token_encryption: typing.Optional[ResourceServerTokenEncryption] = None consent_policy: typing.Optional[ResourceServerConsentPolicyEnum] = None + require_consent_non_repudiation: typing.Optional[bool] = pydantic.Field(default=None) + """ + When true, the resource server requires every consent approval to be digitally signed, so the approver cannot later deny a consent they granted. When false, consent decisions do not need a signature. Defaults to false. A configured value is still returned even after the related entitlement is disabled. + """ + authorization_details: typing.Optional[typing.List[typing.Any]] = None proof_of_possession: typing.Optional[ResourceServerProofOfPossession] = None subject_type_authorization: typing.Optional[ResourceServerSubjectTypeAuthorization] = None diff --git a/src/auth0/management/types/segment.py b/src/auth0/management/types/segment.py new file mode 100644 index 00000000..c208be50 --- /dev/null +++ b/src/auth0/management/types/segment.py @@ -0,0 +1,28 @@ +# This file was auto-generated by Fern from our API Definition. + +import datetime as dt +import typing + +import pydantic +from ..core.pydantic_utilities import IS_PYDANTIC_V2, UniversalBaseModel +from .segment_rule import SegmentRule +from .segment_type_enum import SegmentTypeEnum + + +class Segment(UniversalBaseModel): + id: str + name: str + description: typing.Optional[str] = None + type: SegmentTypeEnum + rules: typing.List[SegmentRule] + created_at: dt.datetime + updated_at: dt.datetime + + if IS_PYDANTIC_V2: + model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2 + else: + + class Config: + frozen = True + smart_union = True + extra = pydantic.Extra.allow diff --git a/src/auth0/management/types/segment_contains_expression.py b/src/auth0/management/types/segment_contains_expression.py new file mode 100644 index 00000000..d1c084a7 --- /dev/null +++ b/src/auth0/management/types/segment_contains_expression.py @@ -0,0 +1,19 @@ +# This file was auto-generated by Fern from our API Definition. + +import typing + +import pydantic +from ..core.pydantic_utilities import IS_PYDANTIC_V2, UniversalBaseModel + + +class SegmentContainsExpression(UniversalBaseModel): + contains: typing.List[str] + + if IS_PYDANTIC_V2: + model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2 + else: + + class Config: + frozen = True + smart_union = True + extra = pydantic.Extra.allow diff --git a/src/auth0/management/types/segment_ends_with_expression.py b/src/auth0/management/types/segment_ends_with_expression.py new file mode 100644 index 00000000..ba5c8aee --- /dev/null +++ b/src/auth0/management/types/segment_ends_with_expression.py @@ -0,0 +1,19 @@ +# This file was auto-generated by Fern from our API Definition. + +import typing + +import pydantic +from ..core.pydantic_utilities import IS_PYDANTIC_V2, UniversalBaseModel + + +class SegmentEndsWithExpression(UniversalBaseModel): + ends_with: typing.List[str] + + if IS_PYDANTIC_V2: + model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2 + else: + + class Config: + frozen = True + smart_union = True + extra = pydantic.Extra.allow diff --git a/src/auth0/management/types/segment_exists_expression.py b/src/auth0/management/types/segment_exists_expression.py new file mode 100644 index 00000000..727d9d21 --- /dev/null +++ b/src/auth0/management/types/segment_exists_expression.py @@ -0,0 +1,19 @@ +# This file was auto-generated by Fern from our API Definition. + +import typing + +import pydantic +from ..core.pydantic_utilities import IS_PYDANTIC_V2, UniversalBaseModel + + +class SegmentExistsExpression(UniversalBaseModel): + exists: bool + + if IS_PYDANTIC_V2: + model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2 + else: + + class Config: + frozen = True + smart_union = True + extra = pydantic.Extra.allow diff --git a/src/auth0/management/types/segment_match_conditions.py b/src/auth0/management/types/segment_match_conditions.py new file mode 100644 index 00000000..ef905a7e --- /dev/null +++ b/src/auth0/management/types/segment_match_conditions.py @@ -0,0 +1,34 @@ +# This file was auto-generated by Fern from our API Definition. + +import typing + +import pydantic +from ..core.pydantic_utilities import IS_PYDANTIC_V2, UniversalBaseModel +from .segment_match_expression import SegmentMatchExpression + + +class SegmentMatchConditions(UniversalBaseModel): + """ + Attribute conditions that must match. + """ + + client_id: typing.Optional[SegmentMatchExpression] = None + connection: typing.Optional[SegmentMatchExpression] = None + connection_type: typing.Optional[SegmentMatchExpression] = None + organization_id: typing.Optional[SegmentMatchExpression] = None + domain: typing.Optional[SegmentMatchExpression] = None + device_type: typing.Optional[SegmentMatchExpression] = None + browser: typing.Optional[SegmentMatchExpression] = None + platform: typing.Optional[SegmentMatchExpression] = None + user_agent: typing.Optional[SegmentMatchExpression] = None + country: typing.Optional[SegmentMatchExpression] = None + region: typing.Optional[SegmentMatchExpression] = None + + if IS_PYDANTIC_V2: + model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2 + else: + + class Config: + frozen = True + smart_union = True + extra = pydantic.Extra.allow diff --git a/src/auth0/management/types/segment_match_expression.py b/src/auth0/management/types/segment_match_expression.py new file mode 100644 index 00000000..b440d326 --- /dev/null +++ b/src/auth0/management/types/segment_match_expression.py @@ -0,0 +1,16 @@ +# This file was auto-generated by Fern from our API Definition. + +import typing + +from .segment_contains_expression import SegmentContainsExpression +from .segment_ends_with_expression import SegmentEndsWithExpression +from .segment_exists_expression import SegmentExistsExpression +from .segment_starts_with_expression import SegmentStartsWithExpression + +SegmentMatchExpression = typing.Union[ + typing.List[str], + SegmentContainsExpression, + SegmentStartsWithExpression, + SegmentEndsWithExpression, + SegmentExistsExpression, +] diff --git a/src/auth0/management/types/segment_not_match_conditions.py b/src/auth0/management/types/segment_not_match_conditions.py new file mode 100644 index 00000000..f3810d46 --- /dev/null +++ b/src/auth0/management/types/segment_not_match_conditions.py @@ -0,0 +1,34 @@ +# This file was auto-generated by Fern from our API Definition. + +import typing + +import pydantic +from ..core.pydantic_utilities import IS_PYDANTIC_V2, UniversalBaseModel +from .segment_match_expression import SegmentMatchExpression + + +class SegmentNotMatchConditions(UniversalBaseModel): + """ + Attribute conditions that must not match. + """ + + client_id: typing.Optional[SegmentMatchExpression] = None + connection: typing.Optional[SegmentMatchExpression] = None + connection_type: typing.Optional[SegmentMatchExpression] = None + organization_id: typing.Optional[SegmentMatchExpression] = None + domain: typing.Optional[SegmentMatchExpression] = None + device_type: typing.Optional[SegmentMatchExpression] = None + browser: typing.Optional[SegmentMatchExpression] = None + platform: typing.Optional[SegmentMatchExpression] = None + user_agent: typing.Optional[SegmentMatchExpression] = None + country: typing.Optional[SegmentMatchExpression] = None + region: typing.Optional[SegmentMatchExpression] = None + + if IS_PYDANTIC_V2: + model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2 + else: + + class Config: + frozen = True + smart_union = True + extra = pydantic.Extra.allow diff --git a/src/auth0/management/types/segment_rule.py b/src/auth0/management/types/segment_rule.py new file mode 100644 index 00000000..239f86ec --- /dev/null +++ b/src/auth0/management/types/segment_rule.py @@ -0,0 +1,22 @@ +# This file was auto-generated by Fern from our API Definition. + +import typing + +import pydantic +from ..core.pydantic_utilities import IS_PYDANTIC_V2, UniversalBaseModel +from .segment_match_conditions import SegmentMatchConditions +from .segment_not_match_conditions import SegmentNotMatchConditions + + +class SegmentRule(UniversalBaseModel): + match: typing.Optional[SegmentMatchConditions] = None + not_match: typing.Optional[SegmentNotMatchConditions] = None + + if IS_PYDANTIC_V2: + model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2 + else: + + class Config: + frozen = True + smart_union = True + extra = pydantic.Extra.allow diff --git a/src/auth0/management/types/segment_starts_with_expression.py b/src/auth0/management/types/segment_starts_with_expression.py new file mode 100644 index 00000000..05af74f6 --- /dev/null +++ b/src/auth0/management/types/segment_starts_with_expression.py @@ -0,0 +1,19 @@ +# This file was auto-generated by Fern from our API Definition. + +import typing + +import pydantic +from ..core.pydantic_utilities import IS_PYDANTIC_V2, UniversalBaseModel + + +class SegmentStartsWithExpression(UniversalBaseModel): + starts_with: typing.List[str] + + if IS_PYDANTIC_V2: + model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2 + else: + + class Config: + frozen = True + smart_union = True + extra = pydantic.Extra.allow diff --git a/src/auth0/management/types/segment_type_enum.py b/src/auth0/management/types/segment_type_enum.py new file mode 100644 index 00000000..b7abaed2 --- /dev/null +++ b/src/auth0/management/types/segment_type_enum.py @@ -0,0 +1,5 @@ +# This file was auto-generated by Fern from our API Definition. + +import typing + +SegmentTypeEnum = typing.Union[typing.Literal["self", "auth0"], typing.Any] diff --git a/src/auth0/management/types/segment_type_filter_enum.py b/src/auth0/management/types/segment_type_filter_enum.py new file mode 100644 index 00000000..558de32e --- /dev/null +++ b/src/auth0/management/types/segment_type_filter_enum.py @@ -0,0 +1,5 @@ +# This file was auto-generated by Fern from our API Definition. + +import typing + +SegmentTypeFilterEnum = typing.Union[typing.Literal["auth0", "self"], typing.Any] diff --git a/src/auth0/management/types/update_connection_options.py b/src/auth0/management/types/update_connection_options.py index e8df3f96..e5c4af5c 100644 --- a/src/auth0/management/types/update_connection_options.py +++ b/src/auth0/management/types/update_connection_options.py @@ -25,6 +25,8 @@ from .connection_password_policy_enum import ConnectionPasswordPolicyEnum from .connection_pushed_authorization_request_endpoint import ConnectionPushedAuthorizationRequestEndpoint from .connection_set_user_root_attributes_enum import ConnectionSetUserRootAttributesEnum +from .connection_thumbprints import ConnectionThumbprints +from .connection_thumbprints_sha_384 import ConnectionThumbprintsSha384 from .connection_token_endpoint_auth_method_enum import ConnectionTokenEndpointAuthMethodEnum from .connection_token_endpoint_auth_signing_alg_enum import ConnectionTokenEndpointAuthSigningAlgEnum from .connection_token_endpoint_jwtca_aud_format_enum_oidc import ConnectionTokenEndpointJwtcaAudFormatEnumOidc @@ -122,6 +124,12 @@ class UpdateConnectionOptions(UniversalBaseModel): ] = None discovery_url: typing.Optional[ConnectionsDiscoveryUrl] = None oidc_metadata: typing.Optional[ConnectionsOidcMetadata] = None + thumbprints: typing.Optional[ConnectionThumbprints] = None + thumbprints_sha_384: typing_extensions.Annotated[ + typing.Optional[ConnectionThumbprintsSha384], + FieldMetadata(alias="thumbprints_sha384"), + pydantic.Field(alias="thumbprints_sha384"), + ] = None if IS_PYDANTIC_V2: model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2 diff --git a/src/auth0/management/types/update_experiment_response_content.py b/src/auth0/management/types/update_experiment_response_content.py new file mode 100644 index 00000000..367e0fdf --- /dev/null +++ b/src/auth0/management/types/update_experiment_response_content.py @@ -0,0 +1,54 @@ +# This file was auto-generated by Fern from our API Definition. + +import datetime as dt +import typing + +import pydantic +from ..core.pydantic_utilities import IS_PYDANTIC_V2, UniversalBaseModel +from .allocation_item import AllocationItem +from .allocation_strategy_enum import AllocationStrategyEnum +from .default_config_enum import DefaultConfigEnum +from .experiment_status_enum import ExperimentStatusEnum + + +class UpdateExperimentResponseContent(UniversalBaseModel): + id: str + name: str + description: typing.Optional[str] = None + feature_flag_id: str + feature_flag_name: typing.Optional[str] = None + authentication_flow: str + allocation_strategy: AllocationStrategyEnum + status: ExperimentStatusEnum + is_valid: bool + default_config: typing.Optional[DefaultConfigEnum] = None + feature_flag_snapshot: typing.Optional[typing.Dict[str, typing.Any]] = None + allocations: typing.List[AllocationItem] + editable_fields: typing.List[str] = pydantic.Field() + """ + Fields that may be mutated given the experiment's current status. Computed at response time; always current with the API's enforcement logic. + """ + + levels: typing.Optional[typing.List[int]] = pydantic.Field(default=None) + """ + Ramp experiment levels configuration. + """ + + current_level: typing.Optional[int] = pydantic.Field(default=None) + """ + Read-only. The active exposure percentage for the current ramp step. Null when no ramp schedule is active. + """ + + started_at: typing.Optional[dt.datetime] = None + ended_at: typing.Optional[dt.datetime] = None + created_at: dt.datetime + updated_at: dt.datetime + + if IS_PYDANTIC_V2: + model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2 + else: + + class Config: + frozen = True + smart_union = True + extra = pydantic.Extra.allow diff --git a/src/auth0/management/types/update_experiment_status_response_content.py b/src/auth0/management/types/update_experiment_status_response_content.py new file mode 100644 index 00000000..44887508 --- /dev/null +++ b/src/auth0/management/types/update_experiment_status_response_content.py @@ -0,0 +1,54 @@ +# This file was auto-generated by Fern from our API Definition. + +import datetime as dt +import typing + +import pydantic +from ..core.pydantic_utilities import IS_PYDANTIC_V2, UniversalBaseModel +from .allocation_item import AllocationItem +from .allocation_strategy_enum import AllocationStrategyEnum +from .default_config_enum import DefaultConfigEnum +from .experiment_status_enum import ExperimentStatusEnum + + +class UpdateExperimentStatusResponseContent(UniversalBaseModel): + id: str + name: str + description: typing.Optional[str] = None + feature_flag_id: str + feature_flag_name: typing.Optional[str] = None + authentication_flow: str + allocation_strategy: AllocationStrategyEnum + status: ExperimentStatusEnum + is_valid: bool + default_config: typing.Optional[DefaultConfigEnum] = None + feature_flag_snapshot: typing.Optional[typing.Dict[str, typing.Any]] = None + allocations: typing.List[AllocationItem] + editable_fields: typing.List[str] = pydantic.Field() + """ + Fields that may be mutated given the experiment's current status. Computed at response time; always current with the API's enforcement logic. + """ + + levels: typing.Optional[typing.List[int]] = pydantic.Field(default=None) + """ + Ramp experiment levels configuration. + """ + + current_level: typing.Optional[int] = pydantic.Field(default=None) + """ + Read-only. The active exposure percentage for the current ramp step. Null when no ramp schedule is active. + """ + + started_at: typing.Optional[dt.datetime] = None + ended_at: typing.Optional[dt.datetime] = None + created_at: dt.datetime + updated_at: dt.datetime + + if IS_PYDANTIC_V2: + model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2 + else: + + class Config: + frozen = True + smart_union = True + extra = pydantic.Extra.allow diff --git a/src/auth0/management/types/update_feature_flag_parameters.py b/src/auth0/management/types/update_feature_flag_parameters.py new file mode 100644 index 00000000..73c8d175 --- /dev/null +++ b/src/auth0/management/types/update_feature_flag_parameters.py @@ -0,0 +1,10 @@ +# This file was auto-generated by Fern from our API Definition. + +import typing + +from .feature_flag_config_param import FeatureFlagConfigParam + +UpdateFeatureFlagParameters = typing.Dict[str, FeatureFlagConfigParam] +""" +Configuration parameters for this feature flag +""" diff --git a/src/auth0/management/types/update_feature_flag_response_content.py b/src/auth0/management/types/update_feature_flag_response_content.py new file mode 100644 index 00000000..de02e56a --- /dev/null +++ b/src/auth0/management/types/update_feature_flag_response_content.py @@ -0,0 +1,30 @@ +# This file was auto-generated by Fern from our API Definition. + +import datetime as dt +import typing + +import pydantic +from ..core.pydantic_utilities import IS_PYDANTIC_V2, UniversalBaseModel +from .feature_flag_config_params import FeatureFlagConfigParams +from .feature_flag_status_enum import FeatureFlagStatusEnum +from .feature_flag_type_enum import FeatureFlagTypeEnum + + +class UpdateFeatureFlagResponseContent(UniversalBaseModel): + id: str + name: str + description: typing.Optional[str] = None + type: FeatureFlagTypeEnum + status: FeatureFlagStatusEnum + parameters: typing.Optional[FeatureFlagConfigParams] = None + created_at: dt.datetime + updated_at: dt.datetime + + if IS_PYDANTIC_V2: + model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2 + else: + + class Config: + frozen = True + smart_union = True + extra = pydantic.Extra.allow diff --git a/src/auth0/management/types/update_feature_flag_status_response_content.py b/src/auth0/management/types/update_feature_flag_status_response_content.py new file mode 100644 index 00000000..523a2715 --- /dev/null +++ b/src/auth0/management/types/update_feature_flag_status_response_content.py @@ -0,0 +1,30 @@ +# This file was auto-generated by Fern from our API Definition. + +import datetime as dt +import typing + +import pydantic +from ..core.pydantic_utilities import IS_PYDANTIC_V2, UniversalBaseModel +from .feature_flag_config_params import FeatureFlagConfigParams +from .feature_flag_status_enum import FeatureFlagStatusEnum +from .feature_flag_type_enum import FeatureFlagTypeEnum + + +class UpdateFeatureFlagStatusResponseContent(UniversalBaseModel): + id: str + name: str + description: typing.Optional[str] = None + type: FeatureFlagTypeEnum + status: FeatureFlagStatusEnum + parameters: typing.Optional[FeatureFlagConfigParams] = None + created_at: dt.datetime + updated_at: dt.datetime + + if IS_PYDANTIC_V2: + model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2 + else: + + class Config: + frozen = True + smart_union = True + extra = pydantic.Extra.allow diff --git a/src/auth0/management/types/update_resource_server_response_content.py b/src/auth0/management/types/update_resource_server_response_content.py index a24fa352..e60f14d0 100644 --- a/src/auth0/management/types/update_resource_server_response_content.py +++ b/src/auth0/management/types/update_resource_server_response_content.py @@ -91,6 +91,11 @@ class UpdateResourceServerResponseContent(UniversalBaseModel): access_token: typing.Optional[ResourceServerAccessToken] = None token_encryption: typing.Optional[ResourceServerTokenEncryption] = None consent_policy: typing.Optional[ResourceServerConsentPolicyEnum] = None + require_consent_non_repudiation: typing.Optional[bool] = pydantic.Field(default=None) + """ + When true, the resource server requires every consent approval to be digitally signed, so the approver cannot later deny a consent they granted. When false, consent decisions do not need a signature. Defaults to false. A configured value is still returned even after the related entitlement is disabled. + """ + authorization_details: typing.Optional[typing.List[typing.Any]] = None proof_of_possession: typing.Optional[ResourceServerProofOfPossession] = None subject_type_authorization: typing.Optional[ResourceServerSubjectTypeAuthorization] = None diff --git a/src/auth0/management/types/update_segment_response_content.py b/src/auth0/management/types/update_segment_response_content.py new file mode 100644 index 00000000..2036765d --- /dev/null +++ b/src/auth0/management/types/update_segment_response_content.py @@ -0,0 +1,28 @@ +# This file was auto-generated by Fern from our API Definition. + +import datetime as dt +import typing + +import pydantic +from ..core.pydantic_utilities import IS_PYDANTIC_V2, UniversalBaseModel +from .segment_rule import SegmentRule +from .segment_type_enum import SegmentTypeEnum + + +class UpdateSegmentResponseContent(UniversalBaseModel): + id: str + name: str + description: typing.Optional[str] = None + type: SegmentTypeEnum + rules: typing.List[SegmentRule] + created_at: dt.datetime + updated_at: dt.datetime + + if IS_PYDANTIC_V2: + model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2 + else: + + class Config: + frozen = True + smart_union = True + extra = pydantic.Extra.allow diff --git a/src/auth0/management/types/update_variation_overrides_map.py b/src/auth0/management/types/update_variation_overrides_map.py new file mode 100644 index 00000000..d895e780 --- /dev/null +++ b/src/auth0/management/types/update_variation_overrides_map.py @@ -0,0 +1,8 @@ +# This file was auto-generated by Fern from our API Definition. + +import typing + +UpdateVariationOverridesMap = typing.Dict[str, typing.Any] +""" +Configuration overrides for this variation; keys must exist in the parent flag parameters. Empty {} is the baseline (control) variation that overrides nothing. +""" diff --git a/src/auth0/management/types/update_variation_response_content.py b/src/auth0/management/types/update_variation_response_content.py new file mode 100644 index 00000000..08e9cb40 --- /dev/null +++ b/src/auth0/management/types/update_variation_response_content.py @@ -0,0 +1,27 @@ +# This file was auto-generated by Fern from our API Definition. + +import datetime as dt +import typing + +import pydantic +from ..core.pydantic_utilities import IS_PYDANTIC_V2, UniversalBaseModel +from .variation_overrides_map import VariationOverridesMap + + +class UpdateVariationResponseContent(UniversalBaseModel): + id: str + feature_flag_id: str + name: str + description: typing.Optional[str] = None + overrides: VariationOverridesMap + created_at: dt.datetime + updated_at: dt.datetime + + if IS_PYDANTIC_V2: + model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2 + else: + + class Config: + frozen = True + smart_union = True + extra = pydantic.Extra.allow diff --git a/src/auth0/management/types/organization_template_use_for_organization_discovery.py b/src/auth0/management/types/validate_experiment_response_content.py similarity index 54% rename from src/auth0/management/types/organization_template_use_for_organization_discovery.py rename to src/auth0/management/types/validate_experiment_response_content.py index b3682cba..a2ded55c 100644 --- a/src/auth0/management/types/organization_template_use_for_organization_discovery.py +++ b/src/auth0/management/types/validate_experiment_response_content.py @@ -4,21 +4,18 @@ import pydantic from ..core.pydantic_utilities import IS_PYDANTIC_V2, UniversalBaseModel +from .experiment_validation_error import ExperimentValidationError -class OrganizationTemplateUseForOrganizationDiscovery(UniversalBaseModel): +class ValidateExperimentResponseContent(UniversalBaseModel): + is_valid: bool = pydantic.Field() """ - Controls whether connections from this template are used for organization discovery. + Whether the experiment is ready to be activated. """ - default_value: bool = pydantic.Field() + errors: typing.List[ExperimentValidationError] = pydantic.Field() """ - The default value for organization discovery. - """ - - allowed_values: typing.Optional[typing.List[bool]] = pydantic.Field(default=None) - """ - The allowed values for organization discovery. + List of validation errors preventing activation. Empty when is_valid is true. """ if IS_PYDANTIC_V2: diff --git a/src/auth0/management/types/variation.py b/src/auth0/management/types/variation.py new file mode 100644 index 00000000..1899441d --- /dev/null +++ b/src/auth0/management/types/variation.py @@ -0,0 +1,27 @@ +# This file was auto-generated by Fern from our API Definition. + +import datetime as dt +import typing + +import pydantic +from ..core.pydantic_utilities import IS_PYDANTIC_V2, UniversalBaseModel +from .variation_overrides_map import VariationOverridesMap + + +class Variation(UniversalBaseModel): + id: str + feature_flag_id: str + name: str + description: typing.Optional[str] = None + overrides: VariationOverridesMap + created_at: dt.datetime + updated_at: dt.datetime + + if IS_PYDANTIC_V2: + model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2 + else: + + class Config: + frozen = True + smart_union = True + extra = pydantic.Extra.allow diff --git a/src/auth0/management/types/variation_overrides_map.py b/src/auth0/management/types/variation_overrides_map.py new file mode 100644 index 00000000..07816f49 --- /dev/null +++ b/src/auth0/management/types/variation_overrides_map.py @@ -0,0 +1,8 @@ +# This file was auto-generated by Fern from our API Definition. + +import typing + +VariationOverridesMap = typing.Dict[str, typing.Any] +""" +Configuration overrides for this variation +""" diff --git a/src/auth0/management/user_blocks/client.py b/src/auth0/management/user_blocks/client.py index 8c336b8e..26546e9a 100644 --- a/src/auth0/management/user_blocks/client.py +++ b/src/auth0/management/user_blocks/client.py @@ -41,8 +41,8 @@ def list_by_identifier( consider_brute_force_enablement : typing.Optional[bool] - If true and Brute Force Protection is enabled and configured to block logins, will return a list of blocked IP addresses. - If true and Brute Force Protection is disabled, will return an empty list. + If true, returns only blocks that are currently enforced (e.g. subject to protection status, IP allowlist, etc.). + If false or omitted, returns all blocks regardless of enforcement state. request_options : typing.Optional[RequestOptions] @@ -121,8 +121,8 @@ def list( consider_brute_force_enablement : typing.Optional[bool] - If true and Brute Force Protection is enabled and configured to block logins, will return a list of blocked IP addresses. - If true and Brute Force Protection is disabled, will return an empty list. + If true, returns only blocks that are currently enforced (e.g. subject to protection status, IP allowlist, etc.). + If false or omitted, returns all blocks regardless of enforcement state. request_options : typing.Optional[RequestOptions] @@ -215,8 +215,8 @@ async def list_by_identifier( consider_brute_force_enablement : typing.Optional[bool] - If true and Brute Force Protection is enabled and configured to block logins, will return a list of blocked IP addresses. - If true and Brute Force Protection is disabled, will return an empty list. + If true, returns only blocks that are currently enforced (e.g. subject to protection status, IP allowlist, etc.). + If false or omitted, returns all blocks regardless of enforcement state. request_options : typing.Optional[RequestOptions] @@ -313,8 +313,8 @@ async def list( consider_brute_force_enablement : typing.Optional[bool] - If true and Brute Force Protection is enabled and configured to block logins, will return a list of blocked IP addresses. - If true and Brute Force Protection is disabled, will return an empty list. + If true, returns only blocks that are currently enforced (e.g. subject to protection status, IP allowlist, etc.). + If false or omitted, returns all blocks regardless of enforcement state. request_options : typing.Optional[RequestOptions] diff --git a/src/auth0/management/user_blocks/raw_client.py b/src/auth0/management/user_blocks/raw_client.py index 65f1f0aa..1090aee8 100644 --- a/src/auth0/management/user_blocks/raw_client.py +++ b/src/auth0/management/user_blocks/raw_client.py @@ -41,8 +41,8 @@ def list_by_identifier( consider_brute_force_enablement : typing.Optional[bool] - If true and Brute Force Protection is enabled and configured to block logins, will return a list of blocked IP addresses. - If true and Brute Force Protection is disabled, will return an empty list. + If true, returns only blocks that are currently enforced (e.g. subject to protection status, IP allowlist, etc.). + If false or omitted, returns all blocks regardless of enforcement state. request_options : typing.Optional[RequestOptions] @@ -226,8 +226,8 @@ def list( consider_brute_force_enablement : typing.Optional[bool] - If true and Brute Force Protection is enabled and configured to block logins, will return a list of blocked IP addresses. - If true and Brute Force Protection is disabled, will return an empty list. + If true, returns only blocks that are currently enforced (e.g. subject to protection status, IP allowlist, etc.). + If false or omitted, returns all blocks regardless of enforcement state. request_options : typing.Optional[RequestOptions] @@ -432,8 +432,8 @@ async def list_by_identifier( consider_brute_force_enablement : typing.Optional[bool] - If true and Brute Force Protection is enabled and configured to block logins, will return a list of blocked IP addresses. - If true and Brute Force Protection is disabled, will return an empty list. + If true, returns only blocks that are currently enforced (e.g. subject to protection status, IP allowlist, etc.). + If false or omitted, returns all blocks regardless of enforcement state. request_options : typing.Optional[RequestOptions] @@ -617,8 +617,8 @@ async def list( consider_brute_force_enablement : typing.Optional[bool] - If true and Brute Force Protection is enabled and configured to block logins, will return a list of blocked IP addresses. - If true and Brute Force Protection is disabled, will return an empty list. + If true, returns only blocks that are currently enforced (e.g. subject to protection status, IP allowlist, etc.). + If false or omitted, returns all blocks regardless of enforcement state. request_options : typing.Optional[RequestOptions] diff --git a/src/auth0/management/users/client.py b/src/auth0/management/users/client.py index 34982838..04a8a141 100644 --- a/src/auth0/management/users/client.py +++ b/src/auth0/management/users/client.py @@ -87,24 +87,22 @@ def list( request_options: typing.Optional[RequestOptions] = None, ) -> SyncPager[UserResponseSchema, ListUsersOffsetPaginatedResponseContent]: """ - Retrieve details of users. It is possible to: + This endpoint retrieves details of users. It's best suited to interactive, best-effort search and lookups where slightly stale results are acceptable. With it, you can: - - Specify a search criteria for users + - Specify search criteria for users - Sort the users to be returned - Select the fields to be returned - Specify the number of users to retrieve per page and the page index + This endpoint is **not suited for use in critical paths**. It is eventually consistent and runs under a short (~2 second) query time limit, so results can be stale and heavy queries can return a 503. + - Do not use this endpoint for authentication, account linking, or logic inside login-flow Actions. Instead, [look users up directly by ID or email](https://auth0.com/docs/manage-users/user-search/get-users-by-id-or-email#management-api) to get their current state. + - Do not use this endpoint to keep an external system in sync with user data. Instead, subscribe to [Event Streams](https://auth0.com/docs/customize/events/sync-data-across-systems) to receive every change as it happens. + - Do not use this endpoint to enumerate or export your entire user base. Instead, run a [bulk user export](https://auth0.com/docs/manage-users/user-migration/bulk-user-exports) to retrieve the full set. - The `q` query parameter can be used to get users that match the specified criteria [using query string syntax.](https://auth0.com/docs/users/search/v3/query-syntax) + Use the `q` query parameter to match users with [query string syntax](https://auth0.com/docs/manage-users/user-search/user-search-query-syntax). For full instructions and guidance, see [How to List and Search Users](https://auth0.com/docs/manage-users/user-search/list-and-search-users). - [Learn more about searching for users.](https://auth0.com/docs/users/search/v3) - - Read about [best practices](https://auth0.com/docs/users/search/best-practices) when working with the API endpoints for retrieving users. - - - - Auth0 limits the number of users you can return. If you exceed this threshold, please redefine your search, use the [export job](https://auth0.com/docs/api/management/v2#!/Jobs/post_users_exports), or the [User Import / Export](https://auth0.com/docs/extensions/user-import-export) extension. + For efficient queries, prefer indexed top-level fields and exact matches. Certain kinds of queries can be slow and may time out, such as filtering on freeform or multi-value fields (like user-defined attributes in `app_metadata` or `user_metadata`) or using leading wildcards. Parameters ---------- @@ -908,24 +906,22 @@ async def list( request_options: typing.Optional[RequestOptions] = None, ) -> AsyncPager[UserResponseSchema, ListUsersOffsetPaginatedResponseContent]: """ - Retrieve details of users. It is possible to: + This endpoint retrieves details of users. It's best suited to interactive, best-effort search and lookups where slightly stale results are acceptable. With it, you can: - - Specify a search criteria for users + - Specify search criteria for users - Sort the users to be returned - Select the fields to be returned - Specify the number of users to retrieve per page and the page index + This endpoint is **not suited for use in critical paths**. It is eventually consistent and runs under a short (~2 second) query time limit, so results can be stale and heavy queries can return a 503. + - Do not use this endpoint for authentication, account linking, or logic inside login-flow Actions. Instead, [look users up directly by ID or email](https://auth0.com/docs/manage-users/user-search/get-users-by-id-or-email#management-api) to get their current state. + - Do not use this endpoint to keep an external system in sync with user data. Instead, subscribe to [Event Streams](https://auth0.com/docs/customize/events/sync-data-across-systems) to receive every change as it happens. + - Do not use this endpoint to enumerate or export your entire user base. Instead, run a [bulk user export](https://auth0.com/docs/manage-users/user-migration/bulk-user-exports) to retrieve the full set. - The `q` query parameter can be used to get users that match the specified criteria [using query string syntax.](https://auth0.com/docs/users/search/v3/query-syntax) - - [Learn more about searching for users.](https://auth0.com/docs/users/search/v3) - - Read about [best practices](https://auth0.com/docs/users/search/best-practices) when working with the API endpoints for retrieving users. - - + Use the `q` query parameter to match users with [query string syntax](https://auth0.com/docs/manage-users/user-search/user-search-query-syntax). For full instructions and guidance, see [How to List and Search Users](https://auth0.com/docs/manage-users/user-search/list-and-search-users). - Auth0 limits the number of users you can return. If you exceed this threshold, please redefine your search, use the [export job](https://auth0.com/docs/api/management/v2#!/Jobs/post_users_exports), or the [User Import / Export](https://auth0.com/docs/extensions/user-import-export) extension. + For efficient queries, prefer indexed top-level fields and exact matches. Certain kinds of queries can be slow and may time out, such as filtering on freeform or multi-value fields (like user-defined attributes in `app_metadata` or `user_metadata`) or using leading wildcards. Parameters ---------- diff --git a/src/auth0/management/users/raw_client.py b/src/auth0/management/users/raw_client.py index b71bbebe..972ef29f 100644 --- a/src/auth0/management/users/raw_client.py +++ b/src/auth0/management/users/raw_client.py @@ -53,24 +53,22 @@ def list( request_options: typing.Optional[RequestOptions] = None, ) -> SyncPager[UserResponseSchema, ListUsersOffsetPaginatedResponseContent]: """ - Retrieve details of users. It is possible to: + This endpoint retrieves details of users. It's best suited to interactive, best-effort search and lookups where slightly stale results are acceptable. With it, you can: - - Specify a search criteria for users + - Specify search criteria for users - Sort the users to be returned - Select the fields to be returned - Specify the number of users to retrieve per page and the page index + This endpoint is **not suited for use in critical paths**. It is eventually consistent and runs under a short (~2 second) query time limit, so results can be stale and heavy queries can return a 503. + - Do not use this endpoint for authentication, account linking, or logic inside login-flow Actions. Instead, [look users up directly by ID or email](https://auth0.com/docs/manage-users/user-search/get-users-by-id-or-email#management-api) to get their current state. + - Do not use this endpoint to keep an external system in sync with user data. Instead, subscribe to [Event Streams](https://auth0.com/docs/customize/events/sync-data-across-systems) to receive every change as it happens. + - Do not use this endpoint to enumerate or export your entire user base. Instead, run a [bulk user export](https://auth0.com/docs/manage-users/user-migration/bulk-user-exports) to retrieve the full set. - The `q` query parameter can be used to get users that match the specified criteria [using query string syntax.](https://auth0.com/docs/users/search/v3/query-syntax) + Use the `q` query parameter to match users with [query string syntax](https://auth0.com/docs/manage-users/user-search/user-search-query-syntax). For full instructions and guidance, see [How to List and Search Users](https://auth0.com/docs/manage-users/user-search/list-and-search-users). - [Learn more about searching for users.](https://auth0.com/docs/users/search/v3) - - Read about [best practices](https://auth0.com/docs/users/search/best-practices) when working with the API endpoints for retrieving users. - - - - Auth0 limits the number of users you can return. If you exceed this threshold, please redefine your search, use the [export job](https://auth0.com/docs/api/management/v2#!/Jobs/post_users_exports), or the [User Import / Export](https://auth0.com/docs/extensions/user-import-export) extension. + For efficient queries, prefer indexed top-level fields and exact matches. Certain kinds of queries can be slow and may time out, such as filtering on freeform or multi-value fields (like user-defined attributes in `app_metadata` or `user_metadata`) or using leading wildcards. Parameters ---------- @@ -1198,24 +1196,22 @@ async def list( request_options: typing.Optional[RequestOptions] = None, ) -> AsyncPager[UserResponseSchema, ListUsersOffsetPaginatedResponseContent]: """ - Retrieve details of users. It is possible to: + This endpoint retrieves details of users. It's best suited to interactive, best-effort search and lookups where slightly stale results are acceptable. With it, you can: - - Specify a search criteria for users + - Specify search criteria for users - Sort the users to be returned - Select the fields to be returned - Specify the number of users to retrieve per page and the page index + This endpoint is **not suited for use in critical paths**. It is eventually consistent and runs under a short (~2 second) query time limit, so results can be stale and heavy queries can return a 503. + - Do not use this endpoint for authentication, account linking, or logic inside login-flow Actions. Instead, [look users up directly by ID or email](https://auth0.com/docs/manage-users/user-search/get-users-by-id-or-email#management-api) to get their current state. + - Do not use this endpoint to keep an external system in sync with user data. Instead, subscribe to [Event Streams](https://auth0.com/docs/customize/events/sync-data-across-systems) to receive every change as it happens. + - Do not use this endpoint to enumerate or export your entire user base. Instead, run a [bulk user export](https://auth0.com/docs/manage-users/user-migration/bulk-user-exports) to retrieve the full set. - The `q` query parameter can be used to get users that match the specified criteria [using query string syntax.](https://auth0.com/docs/users/search/v3/query-syntax) - - [Learn more about searching for users.](https://auth0.com/docs/users/search/v3) - - Read about [best practices](https://auth0.com/docs/users/search/best-practices) when working with the API endpoints for retrieving users. - - + Use the `q` query parameter to match users with [query string syntax](https://auth0.com/docs/manage-users/user-search/user-search-query-syntax). For full instructions and guidance, see [How to List and Search Users](https://auth0.com/docs/manage-users/user-search/list-and-search-users). - Auth0 limits the number of users you can return. If you exceed this threshold, please redefine your search, use the [export job](https://auth0.com/docs/api/management/v2#!/Jobs/post_users_exports), or the [User Import / Export](https://auth0.com/docs/extensions/user-import-export) extension. + For efficient queries, prefer indexed top-level fields and exact matches. Certain kinds of queries can be slow and may time out, such as filtering on freeform or multi-value fields (like user-defined attributes in `app_metadata` or `user_metadata`) or using leading wildcards. Parameters ---------- diff --git a/tests/wire/test_experimentation_experiments.py b/tests/wire/test_experimentation_experiments.py index 8bb54c26..c16ec557 100644 --- a/tests/wire/test_experimentation_experiments.py +++ b/tests/wire/test_experimentation_experiments.py @@ -1,6 +1,74 @@ from .conftest import get_client, verify_request_count +def test_experimentation_experiments_list_() -> None: + """Test list endpoint with WireMock""" + test_id = "experimentation.experiments.list_.0" + client = get_client(test_id) + client.experimentation.experiments.list( + from_="from", + take=1, + status="draft", + authentication_flow="authentication_flow", + feature_flag_id="feature_flag_id", + ) + verify_request_count( + test_id, + "GET", + "/experimentation/experiments", + { + "from": "from", + "take": "1", + "status": "draft", + "authentication_flow": "authentication_flow", + "feature_flag_id": "feature_flag_id", + }, + 1, + ) + + +def test_experimentation_experiments_create() -> None: + """Test create endpoint with WireMock""" + test_id = "experimentation.experiments.create.0" + client = get_client(test_id) + client.experimentation.experiments.create( + name="name", + feature_flag_id="feature_flag_id", + authentication_flow="authentication", + ) + verify_request_count(test_id, "POST", "/experimentation/experiments", None, 1) + + +def test_experimentation_experiments_get() -> None: + """Test get endpoint with WireMock""" + test_id = "experimentation.experiments.get.0" + client = get_client(test_id) + client.experimentation.experiments.get( + id="id", + ) + verify_request_count(test_id, "GET", "/experimentation/experiments/id", None, 1) + + +def test_experimentation_experiments_delete() -> None: + """Test delete endpoint with WireMock""" + test_id = "experimentation.experiments.delete.0" + client = get_client(test_id) + client.experimentation.experiments.delete( + id="id", + ) + verify_request_count(test_id, "DELETE", "/experimentation/experiments/id", None, 1) + + +def test_experimentation_experiments_update() -> None: + """Test update endpoint with WireMock""" + test_id = "experimentation.experiments.update.0" + client = get_client(test_id) + client.experimentation.experiments.update( + id="id", + ) + verify_request_count(test_id, "PATCH", "/experimentation/experiments/id", None, 1) + + def test_experimentation_experiments_advance_ramp() -> None: """Test advanceRamp endpoint with WireMock""" test_id = "experimentation.experiments.advance_ramp.0" @@ -10,3 +78,24 @@ def test_experimentation_experiments_advance_ramp() -> None: target_level=1, ) verify_request_count(test_id, "POST", "/experimentation/experiments/id/advance-ramp", None, 1) + + +def test_experimentation_experiments_update_status() -> None: + """Test updateStatus endpoint with WireMock""" + test_id = "experimentation.experiments.update_status.0" + client = get_client(test_id) + client.experimentation.experiments.update_status( + id="id", + status="active", + ) + verify_request_count(test_id, "POST", "/experimentation/experiments/id/status", None, 1) + + +def test_experimentation_experiments_validate() -> None: + """Test validate endpoint with WireMock""" + test_id = "experimentation.experiments.validate.0" + client = get_client(test_id) + client.experimentation.experiments.validate( + id="id", + ) + verify_request_count(test_id, "POST", "/experimentation/experiments/id/validate", None, 1) diff --git a/tests/wire/test_experimentation_featureFlags.py b/tests/wire/test_experimentation_featureFlags.py new file mode 100644 index 00000000..b09e3f44 --- /dev/null +++ b/tests/wire/test_experimentation_featureFlags.py @@ -0,0 +1,72 @@ +from .conftest import get_client, verify_request_count + + +def test_experimentation_featureFlags_list_() -> None: + """Test list endpoint with WireMock""" + test_id = "experimentation.feature_flags.list_.0" + client = get_client(test_id) + client.experimentation.feature_flags.list( + from_="from", + take=1, + type="auth0", + status="draft", + ) + verify_request_count( + test_id, + "GET", + "/experimentation/feature-flags", + {"from": "from", "take": "1", "type": "auth0", "status": "draft"}, + 1, + ) + + +def test_experimentation_featureFlags_create() -> None: + """Test create endpoint with WireMock""" + test_id = "experimentation.feature_flags.create.0" + client = get_client(test_id) + client.experimentation.feature_flags.create( + name="name", + parameters={}, + ) + verify_request_count(test_id, "POST", "/experimentation/feature-flags", None, 1) + + +def test_experimentation_featureFlags_get() -> None: + """Test get endpoint with WireMock""" + test_id = "experimentation.feature_flags.get.0" + client = get_client(test_id) + client.experimentation.feature_flags.get( + id="id", + ) + verify_request_count(test_id, "GET", "/experimentation/feature-flags/id", None, 1) + + +def test_experimentation_featureFlags_delete() -> None: + """Test delete endpoint with WireMock""" + test_id = "experimentation.feature_flags.delete.0" + client = get_client(test_id) + client.experimentation.feature_flags.delete( + id="id", + ) + verify_request_count(test_id, "DELETE", "/experimentation/feature-flags/id", None, 1) + + +def test_experimentation_featureFlags_update() -> None: + """Test update endpoint with WireMock""" + test_id = "experimentation.feature_flags.update.0" + client = get_client(test_id) + client.experimentation.feature_flags.update( + id="id", + ) + verify_request_count(test_id, "PATCH", "/experimentation/feature-flags/id", None, 1) + + +def test_experimentation_featureFlags_update_status() -> None: + """Test updateStatus endpoint with WireMock""" + test_id = "experimentation.feature_flags.update_status.0" + client = get_client(test_id) + client.experimentation.feature_flags.update_status( + id="id", + status="draft", + ) + verify_request_count(test_id, "POST", "/experimentation/feature-flags/id/status", None, 1) diff --git a/tests/wire/test_experimentation_featureFlags_variations.py b/tests/wire/test_experimentation_featureFlags_variations.py new file mode 100644 index 00000000..a779b2d7 --- /dev/null +++ b/tests/wire/test_experimentation_featureFlags_variations.py @@ -0,0 +1,56 @@ +from .conftest import get_client, verify_request_count + + +def test_experimentation_featureFlags_variations_list_() -> None: + """Test list endpoint with WireMock""" + test_id = "experimentation.feature_flags.variations.list_.0" + client = get_client(test_id) + client.experimentation.feature_flags.variations.list( + id="id", + ) + verify_request_count(test_id, "GET", "/experimentation/feature-flags/id/variations", None, 1) + + +def test_experimentation_featureFlags_variations_create() -> None: + """Test create endpoint with WireMock""" + test_id = "experimentation.feature_flags.variations.create.0" + client = get_client(test_id) + client.experimentation.feature_flags.variations.create( + id="id", + name="name", + overrides={"key": "value"}, + ) + verify_request_count(test_id, "POST", "/experimentation/feature-flags/id/variations", None, 1) + + +def test_experimentation_featureFlags_variations_get() -> None: + """Test get endpoint with WireMock""" + test_id = "experimentation.feature_flags.variations.get.0" + client = get_client(test_id) + client.experimentation.feature_flags.variations.get( + id="id", + vid="vid", + ) + verify_request_count(test_id, "GET", "/experimentation/feature-flags/id/variations/vid", None, 1) + + +def test_experimentation_featureFlags_variations_delete() -> None: + """Test delete endpoint with WireMock""" + test_id = "experimentation.feature_flags.variations.delete.0" + client = get_client(test_id) + client.experimentation.feature_flags.variations.delete( + id="id", + vid="vid", + ) + verify_request_count(test_id, "DELETE", "/experimentation/feature-flags/id/variations/vid", None, 1) + + +def test_experimentation_featureFlags_variations_update() -> None: + """Test update endpoint with WireMock""" + test_id = "experimentation.feature_flags.variations.update.0" + client = get_client(test_id) + client.experimentation.feature_flags.variations.update( + id="id", + vid="vid", + ) + verify_request_count(test_id, "PATCH", "/experimentation/feature-flags/id/variations/vid", None, 1) diff --git a/tests/wire/test_experimentation_segments.py b/tests/wire/test_experimentation_segments.py new file mode 100644 index 00000000..4fbbdb65 --- /dev/null +++ b/tests/wire/test_experimentation_segments.py @@ -0,0 +1,56 @@ +from .conftest import get_client, verify_request_count + +from auth0.management import SegmentRule + + +def test_experimentation_segments_list_() -> None: + """Test list endpoint with WireMock""" + test_id = "experimentation.segments.list_.0" + client = get_client(test_id) + client.experimentation.segments.list( + from_="from", + take=1, + type="auth0", + ) + verify_request_count(test_id, "GET", "/experimentation/segments", {"from": "from", "take": "1", "type": "auth0"}, 1) + + +def test_experimentation_segments_create() -> None: + """Test create endpoint with WireMock""" + test_id = "experimentation.segments.create.0" + client = get_client(test_id) + client.experimentation.segments.create( + name="name", + rules=[SegmentRule()], + ) + verify_request_count(test_id, "POST", "/experimentation/segments", None, 1) + + +def test_experimentation_segments_get() -> None: + """Test get endpoint with WireMock""" + test_id = "experimentation.segments.get.0" + client = get_client(test_id) + client.experimentation.segments.get( + id="id", + ) + verify_request_count(test_id, "GET", "/experimentation/segments/id", None, 1) + + +def test_experimentation_segments_delete() -> None: + """Test delete endpoint with WireMock""" + test_id = "experimentation.segments.delete.0" + client = get_client(test_id) + client.experimentation.segments.delete( + id="id", + ) + verify_request_count(test_id, "DELETE", "/experimentation/segments/id", None, 1) + + +def test_experimentation_segments_update() -> None: + """Test update endpoint with WireMock""" + test_id = "experimentation.segments.update.0" + client = get_client(test_id) + client.experimentation.segments.update( + id="id", + ) + verify_request_count(test_id, "PATCH", "/experimentation/segments/id", None, 1) diff --git a/tests/wire/test_organizations_organizationTemplate.py b/tests/wire/test_organizations_organizationTemplate.py deleted file mode 100644 index e3d1b2a4..00000000 --- a/tests/wire/test_organizations_organizationTemplate.py +++ /dev/null @@ -1,33 +0,0 @@ -from .conftest import get_client, verify_request_count - - -def test_organizations_organizationTemplate_get() -> None: - """Test get endpoint with WireMock""" - test_id = "organizations.organization_template.get.0" - client = get_client(test_id) - client.organizations.organization_template.get( - id="id", - ) - verify_request_count(test_id, "GET", "/organizations/id/organization-templates", None, 1) - - -def test_organizations_organizationTemplate_assign_organization_template() -> None: - """Test assignOrganizationTemplate endpoint with WireMock""" - test_id = "organizations.organization_template.assign_organization_template.0" - client = get_client(test_id) - client.organizations.organization_template.assign_organization_template( - id="id", - template_id="template_id", - ) - verify_request_count(test_id, "PUT", "/organizations/id/organization-templates/template_id", None, 1) - - -def test_organizations_organizationTemplate_unassign_organization_template() -> None: - """Test unassignOrganizationTemplate endpoint with WireMock""" - test_id = "organizations.organization_template.unassign_organization_template.0" - client = get_client(test_id) - client.organizations.organization_template.unassign_organization_template( - id="id", - template_id="template_id", - ) - verify_request_count(test_id, "DELETE", "/organizations/id/organization-templates/template_id", None, 1) diff --git a/wiremock/wiremock-mappings.json b/wiremock/wiremock-mappings.json index ac40146a..8d6e75ef 100644 --- a/wiremock/wiremock-mappings.json +++ b/wiremock/wiremock-mappings.json @@ -4532,7 +4532,7 @@ }, "response": { "status": 200, - "body": "{\n \"start\": 1.1,\n \"limit\": 1.1,\n \"total\": 1.1,\n \"resource_servers\": [\n {\n \"id\": \"id\",\n \"name\": \"name\",\n \"is_system\": true,\n \"identifier\": \"identifier\",\n \"scopes\": [\n {\n \"value\": \"value\"\n }\n ],\n \"signing_alg\": \"HS256\",\n \"signing_secret\": \"signing_secret\",\n \"allow_offline_access\": true,\n \"allow_online_access\": true,\n \"allow_online_access_with_ephemeral_sessions\": true,\n \"skip_consent_for_verifiable_first_party_clients\": true,\n \"token_lifetime\": 1,\n \"token_lifetime_for_web\": 1,\n \"enforce_policies\": true,\n \"token_lifetime_for_anonymous_access_tokens\": 1,\n \"token_dialect\": \"access_token\",\n \"token_encryption\": {\n \"format\": \"compact-nested-jwe\",\n \"encryption_key\": {\n \"alg\": \"RSA-OAEP-256\",\n \"pem\": \"pem\"\n }\n },\n \"consent_policy\": \"transactional-authorization-with-mfa\",\n \"proof_of_possession\": {\n \"mechanism\": \"mtls\",\n \"required\": true\n },\n \"authorization_policy\": {\n \"policy_id\": \"policy_id\"\n },\n \"client_id\": \"client_id\"\n }\n ]\n}", + "body": "{\n \"start\": 1.1,\n \"limit\": 1.1,\n \"total\": 1.1,\n \"resource_servers\": [\n {\n \"id\": \"id\",\n \"name\": \"name\",\n \"is_system\": true,\n \"identifier\": \"identifier\",\n \"scopes\": [\n {\n \"value\": \"value\"\n }\n ],\n \"signing_alg\": \"HS256\",\n \"signing_secret\": \"signing_secret\",\n \"allow_offline_access\": true,\n \"allow_online_access\": true,\n \"allow_online_access_with_ephemeral_sessions\": true,\n \"skip_consent_for_verifiable_first_party_clients\": true,\n \"token_lifetime\": 1,\n \"token_lifetime_for_web\": 1,\n \"enforce_policies\": true,\n \"token_lifetime_for_anonymous_access_tokens\": 1,\n \"token_dialect\": \"access_token\",\n \"token_encryption\": {\n \"format\": \"compact-nested-jwe\",\n \"encryption_key\": {\n \"alg\": \"RSA-OAEP-256\",\n \"pem\": \"pem\"\n }\n },\n \"consent_policy\": \"transactional-authorization-with-mfa\",\n \"require_consent_non_repudiation\": true,\n \"proof_of_possession\": {\n \"mechanism\": \"mtls\",\n \"required\": true\n },\n \"authorization_policy\": {\n \"policy_id\": \"policy_id\"\n },\n \"client_id\": \"client_id\"\n }\n ]\n}", "headers": { "Content-Type": "application/json" } @@ -4564,7 +4564,7 @@ }, "response": { "status": 201, - "body": "{\n \"id\": \"id\",\n \"name\": \"name\",\n \"is_system\": true,\n \"identifier\": \"identifier\",\n \"scopes\": [\n {\n \"value\": \"value\",\n \"description\": \"description\"\n }\n ],\n \"signing_alg\": \"HS256\",\n \"signing_secret\": \"signing_secret\",\n \"allow_offline_access\": true,\n \"allow_online_access\": true,\n \"allow_online_access_with_ephemeral_sessions\": true,\n \"skip_consent_for_verifiable_first_party_clients\": true,\n \"token_lifetime\": 1,\n \"token_lifetime_for_web\": 1,\n \"enforce_policies\": true,\n \"token_lifetime_for_anonymous_access_tokens\": 1,\n \"token_dialect\": \"access_token\",\n \"access_token\": {\n \"claims_mapping\": {\n \"custom_claims\": [\n {\n \"name\": \"name\",\n \"expression\": \"expression\"\n }\n ]\n }\n },\n \"token_encryption\": {\n \"format\": \"compact-nested-jwe\",\n \"encryption_key\": {\n \"name\": \"name\",\n \"alg\": \"RSA-OAEP-256\",\n \"kid\": \"kid\",\n \"pem\": \"pem\"\n }\n },\n \"consent_policy\": \"transactional-authorization-with-mfa\",\n \"authorization_details\": [\n {\n \"key\": \"value\"\n }\n ],\n \"proof_of_possession\": {\n \"mechanism\": \"mtls\",\n \"required\": true,\n \"required_for\": \"public_clients\"\n },\n \"subject_type_authorization\": {\n \"user\": {\n \"policy\": \"allow_all\"\n },\n \"client\": {\n \"policy\": \"deny_all\"\n },\n \"anonymous_user\": {\n \"policy\": \"deny_all\"\n }\n },\n \"authorization_policy\": {\n \"policy_id\": \"policy_id\"\n },\n \"client_id\": \"client_id\"\n}", + "body": "{\n \"id\": \"id\",\n \"name\": \"name\",\n \"is_system\": true,\n \"identifier\": \"identifier\",\n \"scopes\": [\n {\n \"value\": \"value\",\n \"description\": \"description\"\n }\n ],\n \"signing_alg\": \"HS256\",\n \"signing_secret\": \"signing_secret\",\n \"allow_offline_access\": true,\n \"allow_online_access\": true,\n \"allow_online_access_with_ephemeral_sessions\": true,\n \"skip_consent_for_verifiable_first_party_clients\": true,\n \"token_lifetime\": 1,\n \"token_lifetime_for_web\": 1,\n \"enforce_policies\": true,\n \"token_lifetime_for_anonymous_access_tokens\": 1,\n \"token_dialect\": \"access_token\",\n \"access_token\": {\n \"claims_mapping\": {\n \"custom_claims\": [\n {\n \"name\": \"name\",\n \"expression\": \"expression\"\n }\n ]\n }\n },\n \"token_encryption\": {\n \"format\": \"compact-nested-jwe\",\n \"encryption_key\": {\n \"name\": \"name\",\n \"alg\": \"RSA-OAEP-256\",\n \"kid\": \"kid\",\n \"pem\": \"pem\"\n }\n },\n \"consent_policy\": \"transactional-authorization-with-mfa\",\n \"require_consent_non_repudiation\": true,\n \"authorization_details\": [\n {\n \"key\": \"value\"\n }\n ],\n \"proof_of_possession\": {\n \"mechanism\": \"mtls\",\n \"required\": true,\n \"required_for\": \"public_clients\"\n },\n \"subject_type_authorization\": {\n \"user\": {\n \"policy\": \"allow_all\"\n },\n \"client\": {\n \"policy\": \"deny_all\"\n },\n \"anonymous_user\": {\n \"policy\": \"deny_all\"\n }\n },\n \"authorization_policy\": {\n \"policy_id\": \"policy_id\"\n },\n \"client_id\": \"client_id\"\n}", "headers": { "Content-Type": "application/json" } @@ -4618,7 +4618,7 @@ }, "response": { "status": 200, - "body": "{\n \"resource_servers\": [\n {\n \"id\": \"id\",\n \"name\": \"name\",\n \"is_system\": true,\n \"identifier\": \"identifier\",\n \"scopes\": [\n {\n \"value\": \"value\"\n }\n ],\n \"signing_alg\": \"HS256\",\n \"allow_offline_access\": true,\n \"allow_online_access\": true,\n \"allow_online_access_with_ephemeral_sessions\": true,\n \"skip_consent_for_verifiable_first_party_clients\": true,\n \"token_lifetime\": 1,\n \"token_lifetime_for_web\": 1,\n \"enforce_policies\": true,\n \"token_lifetime_for_anonymous_access_tokens\": 1,\n \"token_dialect\": \"access_token\",\n \"token_encryption\": {\n \"format\": \"compact-nested-jwe\",\n \"encryption_key\": {\n \"alg\": \"RSA-OAEP-256\",\n \"pem\": \"pem\"\n }\n },\n \"consent_policy\": \"transactional-authorization-with-mfa\",\n \"proof_of_possession\": {\n \"mechanism\": \"mtls\",\n \"required\": true\n },\n \"authorization_policy\": {\n \"policy_id\": \"policy_id\"\n },\n \"client_id\": \"client_id\"\n }\n ],\n \"next\": \"next\"\n}", + "body": "{\n \"resource_servers\": [\n {\n \"id\": \"id\",\n \"name\": \"name\",\n \"is_system\": true,\n \"identifier\": \"identifier\",\n \"scopes\": [\n {\n \"value\": \"value\"\n }\n ],\n \"signing_alg\": \"HS256\",\n \"allow_offline_access\": true,\n \"allow_online_access\": true,\n \"allow_online_access_with_ephemeral_sessions\": true,\n \"skip_consent_for_verifiable_first_party_clients\": true,\n \"token_lifetime\": 1,\n \"token_lifetime_for_web\": 1,\n \"enforce_policies\": true,\n \"token_lifetime_for_anonymous_access_tokens\": 1,\n \"token_dialect\": \"access_token\",\n \"token_encryption\": {\n \"format\": \"compact-nested-jwe\",\n \"encryption_key\": {\n \"alg\": \"RSA-OAEP-256\",\n \"pem\": \"pem\"\n }\n },\n \"consent_policy\": \"transactional-authorization-with-mfa\",\n \"require_consent_non_repudiation\": true,\n \"proof_of_possession\": {\n \"mechanism\": \"mtls\",\n \"required\": true\n },\n \"authorization_policy\": {\n \"policy_id\": \"policy_id\"\n },\n \"client_id\": \"client_id\"\n }\n ],\n \"next\": \"next\"\n}", "headers": { "Content-Type": "application/json" } @@ -4660,7 +4660,7 @@ }, "response": { "status": 200, - "body": "{\n \"id\": \"id\",\n \"name\": \"name\",\n \"is_system\": true,\n \"identifier\": \"identifier\",\n \"scopes\": [\n {\n \"value\": \"value\",\n \"description\": \"description\"\n }\n ],\n \"signing_alg\": \"HS256\",\n \"signing_secret\": \"signing_secret\",\n \"allow_offline_access\": true,\n \"allow_online_access\": true,\n \"allow_online_access_with_ephemeral_sessions\": true,\n \"skip_consent_for_verifiable_first_party_clients\": true,\n \"token_lifetime\": 1,\n \"token_lifetime_for_web\": 1,\n \"enforce_policies\": true,\n \"token_lifetime_for_anonymous_access_tokens\": 1,\n \"token_dialect\": \"access_token\",\n \"access_token\": {\n \"claims_mapping\": {\n \"custom_claims\": [\n {\n \"name\": \"name\",\n \"expression\": \"expression\"\n }\n ]\n }\n },\n \"token_encryption\": {\n \"format\": \"compact-nested-jwe\",\n \"encryption_key\": {\n \"name\": \"name\",\n \"alg\": \"RSA-OAEP-256\",\n \"kid\": \"kid\",\n \"pem\": \"pem\"\n }\n },\n \"consent_policy\": \"transactional-authorization-with-mfa\",\n \"authorization_details\": [\n {\n \"key\": \"value\"\n }\n ],\n \"proof_of_possession\": {\n \"mechanism\": \"mtls\",\n \"required\": true,\n \"required_for\": \"public_clients\"\n },\n \"subject_type_authorization\": {\n \"user\": {\n \"policy\": \"allow_all\"\n },\n \"client\": {\n \"policy\": \"deny_all\"\n },\n \"anonymous_user\": {\n \"policy\": \"deny_all\"\n }\n },\n \"authorization_policy\": {\n \"policy_id\": \"policy_id\"\n },\n \"client_id\": \"client_id\"\n}", + "body": "{\n \"id\": \"id\",\n \"name\": \"name\",\n \"is_system\": true,\n \"identifier\": \"identifier\",\n \"scopes\": [\n {\n \"value\": \"value\",\n \"description\": \"description\"\n }\n ],\n \"signing_alg\": \"HS256\",\n \"signing_secret\": \"signing_secret\",\n \"allow_offline_access\": true,\n \"allow_online_access\": true,\n \"allow_online_access_with_ephemeral_sessions\": true,\n \"skip_consent_for_verifiable_first_party_clients\": true,\n \"token_lifetime\": 1,\n \"token_lifetime_for_web\": 1,\n \"enforce_policies\": true,\n \"token_lifetime_for_anonymous_access_tokens\": 1,\n \"token_dialect\": \"access_token\",\n \"access_token\": {\n \"claims_mapping\": {\n \"custom_claims\": [\n {\n \"name\": \"name\",\n \"expression\": \"expression\"\n }\n ]\n }\n },\n \"token_encryption\": {\n \"format\": \"compact-nested-jwe\",\n \"encryption_key\": {\n \"name\": \"name\",\n \"alg\": \"RSA-OAEP-256\",\n \"kid\": \"kid\",\n \"pem\": \"pem\"\n }\n },\n \"consent_policy\": \"transactional-authorization-with-mfa\",\n \"require_consent_non_repudiation\": true,\n \"authorization_details\": [\n {\n \"key\": \"value\"\n }\n ],\n \"proof_of_possession\": {\n \"mechanism\": \"mtls\",\n \"required\": true,\n \"required_for\": \"public_clients\"\n },\n \"subject_type_authorization\": {\n \"user\": {\n \"policy\": \"allow_all\"\n },\n \"client\": {\n \"policy\": \"deny_all\"\n },\n \"anonymous_user\": {\n \"policy\": \"deny_all\"\n }\n },\n \"authorization_policy\": {\n \"policy_id\": \"policy_id\"\n },\n \"client_id\": \"client_id\"\n}", "headers": { "Content-Type": "application/json" } @@ -4732,7 +4732,7 @@ }, "response": { "status": 201, - "body": "{\n \"id\": \"id\",\n \"name\": \"name\",\n \"is_system\": true,\n \"identifier\": \"identifier\",\n \"scopes\": [\n {\n \"value\": \"value\",\n \"description\": \"description\"\n }\n ],\n \"signing_alg\": \"HS256\",\n \"signing_secret\": \"signing_secret\",\n \"allow_offline_access\": true,\n \"allow_online_access\": true,\n \"allow_online_access_with_ephemeral_sessions\": true,\n \"skip_consent_for_verifiable_first_party_clients\": true,\n \"token_lifetime\": 1,\n \"token_lifetime_for_web\": 1,\n \"enforce_policies\": true,\n \"token_lifetime_for_anonymous_access_tokens\": 1,\n \"token_dialect\": \"access_token\",\n \"access_token\": {\n \"claims_mapping\": {\n \"custom_claims\": [\n {\n \"name\": \"name\",\n \"expression\": \"expression\"\n }\n ]\n }\n },\n \"token_encryption\": {\n \"format\": \"compact-nested-jwe\",\n \"encryption_key\": {\n \"name\": \"name\",\n \"alg\": \"RSA-OAEP-256\",\n \"kid\": \"kid\",\n \"pem\": \"pem\"\n }\n },\n \"consent_policy\": \"transactional-authorization-with-mfa\",\n \"authorization_details\": [\n {\n \"key\": \"value\"\n }\n ],\n \"proof_of_possession\": {\n \"mechanism\": \"mtls\",\n \"required\": true,\n \"required_for\": \"public_clients\"\n },\n \"subject_type_authorization\": {\n \"user\": {\n \"policy\": \"allow_all\"\n },\n \"client\": {\n \"policy\": \"deny_all\"\n },\n \"anonymous_user\": {\n \"policy\": \"deny_all\"\n }\n },\n \"authorization_policy\": {\n \"policy_id\": \"policy_id\"\n },\n \"client_id\": \"client_id\"\n}", + "body": "{\n \"id\": \"id\",\n \"name\": \"name\",\n \"is_system\": true,\n \"identifier\": \"identifier\",\n \"scopes\": [\n {\n \"value\": \"value\",\n \"description\": \"description\"\n }\n ],\n \"signing_alg\": \"HS256\",\n \"signing_secret\": \"signing_secret\",\n \"allow_offline_access\": true,\n \"allow_online_access\": true,\n \"allow_online_access_with_ephemeral_sessions\": true,\n \"skip_consent_for_verifiable_first_party_clients\": true,\n \"token_lifetime\": 1,\n \"token_lifetime_for_web\": 1,\n \"enforce_policies\": true,\n \"token_lifetime_for_anonymous_access_tokens\": 1,\n \"token_dialect\": \"access_token\",\n \"access_token\": {\n \"claims_mapping\": {\n \"custom_claims\": [\n {\n \"name\": \"name\",\n \"expression\": \"expression\"\n }\n ]\n }\n },\n \"token_encryption\": {\n \"format\": \"compact-nested-jwe\",\n \"encryption_key\": {\n \"name\": \"name\",\n \"alg\": \"RSA-OAEP-256\",\n \"kid\": \"kid\",\n \"pem\": \"pem\"\n }\n },\n \"consent_policy\": \"transactional-authorization-with-mfa\",\n \"require_consent_non_repudiation\": true,\n \"authorization_details\": [\n {\n \"key\": \"value\"\n }\n ],\n \"proof_of_possession\": {\n \"mechanism\": \"mtls\",\n \"required\": true,\n \"required_for\": \"public_clients\"\n },\n \"subject_type_authorization\": {\n \"user\": {\n \"policy\": \"allow_all\"\n },\n \"client\": {\n \"policy\": \"deny_all\"\n },\n \"anonymous_user\": {\n \"policy\": \"deny_all\"\n }\n },\n \"authorization_policy\": {\n \"policy_id\": \"policy_id\"\n },\n \"client_id\": \"client_id\"\n}", "headers": { "Content-Type": "application/json" } @@ -10061,11 +10061,746 @@ } } }, + { + "id": "bd75bcab-7889-4be2-8450-869b365b3fd6", + "name": "List experiments for the tenant. - default", + "request": { + "urlPathTemplate": "/experimentation/experiments", + "method": "GET", + "headers": { + "Authorization": { + "matches": "Bearer .+" + } + }, + "queryParameters": { + "from": { + "equalTo": "from" + }, + "take": { + "equalTo": "1" + }, + "status": { + "equalTo": "draft" + }, + "authentication_flow": { + "equalTo": "authentication_flow" + }, + "feature_flag_id": { + "equalTo": "feature_flag_id" + } + } + }, + "response": { + "status": 200, + "body": "{\n \"experiments\": [\n {\n \"id\": \"id\",\n \"name\": \"name\",\n \"description\": \"description\",\n \"feature_flag_id\": \"feature_flag_id\",\n \"feature_flag_name\": \"feature_flag_name\",\n \"authentication_flow\": \"authentication_flow\",\n \"allocation_strategy\": \"percentage\",\n \"status\": \"draft\",\n \"is_valid\": true,\n \"default_config\": \"tenant\",\n \"feature_flag_snapshot\": {\n \"key\": \"value\"\n },\n \"allocations\": [\n {}\n ],\n \"editable_fields\": [\n \"editable_fields\"\n ],\n \"levels\": [\n 1\n ],\n \"current_level\": 1,\n \"started_at\": \"2024-01-15T09:30:00Z\",\n \"ended_at\": \"2024-01-15T09:30:00Z\",\n \"created_at\": \"2024-01-15T09:30:00Z\",\n \"updated_at\": \"2024-01-15T09:30:00Z\"\n }\n ],\n \"next\": \"next\"\n}", + "headers": { + "Content-Type": "application/json" + } + }, + "uuid": "bd75bcab-7889-4be2-8450-869b365b3fd6", + "persistent": true, + "priority": 3, + "metadata": { + "mocklab": { + "created": { + "at": "2020-01-01T00:00:00.000Z", + "via": "SYSTEM" + } + } + }, + "postServeActions": [] + }, + { + "id": "8134b9b9-4d8a-4951-a430-6287adc0df07", + "name": "Create an experiment for the Experiment Center. - default", + "request": { + "urlPathTemplate": "/experimentation/experiments", + "method": "POST", + "headers": { + "Authorization": { + "matches": "Bearer .+" + } + } + }, + "response": { + "status": 201, + "body": "{\n \"id\": \"id\",\n \"name\": \"name\",\n \"description\": \"description\",\n \"feature_flag_id\": \"feature_flag_id\",\n \"feature_flag_name\": \"feature_flag_name\",\n \"authentication_flow\": \"authentication_flow\",\n \"allocation_strategy\": \"percentage\",\n \"status\": \"draft\",\n \"is_valid\": true,\n \"default_config\": \"tenant\",\n \"feature_flag_snapshot\": {\n \"key\": \"value\"\n },\n \"allocations\": [\n {\n \"variation_id\": \"variation_id\",\n \"variation_name\": \"variation_name\",\n \"segment_id\": \"segment_id\",\n \"segment_name\": \"segment_name\",\n \"weight\": 1,\n \"priority\": 1,\n \"is_control\": true,\n \"is_fallback\": true,\n \"variation_snapshot\": {\n \"key\": \"value\"\n },\n \"segment_snapshot\": {\n \"key\": \"value\"\n }\n }\n ],\n \"editable_fields\": [\n \"editable_fields\"\n ],\n \"levels\": [\n 1\n ],\n \"current_level\": 1,\n \"started_at\": \"2024-01-15T09:30:00Z\",\n \"ended_at\": \"2024-01-15T09:30:00Z\",\n \"created_at\": \"2024-01-15T09:30:00Z\",\n \"updated_at\": \"2024-01-15T09:30:00Z\"\n}", + "headers": { + "Content-Type": "application/json" + } + }, + "uuid": "8134b9b9-4d8a-4951-a430-6287adc0df07", + "persistent": true, + "priority": 3, + "metadata": { + "mocklab": { + "created": { + "at": "2020-01-01T00:00:00.000Z", + "via": "SYSTEM" + } + } + } + }, + { + "id": "274d4dba-dc33-4e37-8a85-e46845e575b9", + "name": "Get an experiment by ID. - default", + "request": { + "urlPathTemplate": "/experimentation/experiments/{id}", + "method": "GET", + "headers": { + "Authorization": { + "matches": "Bearer .+" + } + }, + "pathParameters": { + "id": { + "equalTo": "id" + } + } + }, + "response": { + "status": 200, + "body": "{\n \"id\": \"id\",\n \"name\": \"name\",\n \"description\": \"description\",\n \"feature_flag_id\": \"feature_flag_id\",\n \"feature_flag_name\": \"feature_flag_name\",\n \"authentication_flow\": \"authentication_flow\",\n \"allocation_strategy\": \"percentage\",\n \"status\": \"draft\",\n \"is_valid\": true,\n \"default_config\": \"tenant\",\n \"feature_flag_snapshot\": {\n \"key\": \"value\"\n },\n \"allocations\": [\n {\n \"variation_id\": \"variation_id\",\n \"variation_name\": \"variation_name\",\n \"segment_id\": \"segment_id\",\n \"segment_name\": \"segment_name\",\n \"weight\": 1,\n \"priority\": 1,\n \"is_control\": true,\n \"is_fallback\": true,\n \"variation_snapshot\": {\n \"key\": \"value\"\n },\n \"segment_snapshot\": {\n \"key\": \"value\"\n }\n }\n ],\n \"editable_fields\": [\n \"editable_fields\"\n ],\n \"levels\": [\n 1\n ],\n \"current_level\": 1,\n \"started_at\": \"2024-01-15T09:30:00Z\",\n \"ended_at\": \"2024-01-15T09:30:00Z\",\n \"created_at\": \"2024-01-15T09:30:00Z\",\n \"updated_at\": \"2024-01-15T09:30:00Z\"\n}", + "headers": { + "Content-Type": "application/json" + } + }, + "uuid": "274d4dba-dc33-4e37-8a85-e46845e575b9", + "persistent": true, + "priority": 3, + "metadata": { + "mocklab": { + "created": { + "at": "2020-01-01T00:00:00.000Z", + "via": "SYSTEM" + } + } + } + }, + { + "id": "0029389e-1345-4549-9a99-7244a9975ed8", + "name": "Delete an experiment. - default", + "request": { + "urlPathTemplate": "/experimentation/experiments/{id}", + "method": "DELETE", + "headers": { + "Authorization": { + "matches": "Bearer .+" + } + }, + "pathParameters": { + "id": { + "equalTo": "id" + } + } + }, + "response": { + "status": 200, + "body": "\"\"", + "headers": { + "Content-Type": "application/json" + } + }, + "uuid": "0029389e-1345-4549-9a99-7244a9975ed8", + "persistent": true, + "priority": 3, + "metadata": { + "mocklab": { + "created": { + "at": "2020-01-01T00:00:00.000Z", + "via": "SYSTEM" + } + } + } + }, + { + "id": "2f052315-dd21-4094-b6d2-095774dabfe2", + "name": "Update an experiment. - default", + "request": { + "urlPathTemplate": "/experimentation/experiments/{id}", + "method": "PATCH", + "headers": { + "Authorization": { + "matches": "Bearer .+" + } + }, + "pathParameters": { + "id": { + "equalTo": "id" + } + } + }, + "response": { + "status": 200, + "body": "{\n \"id\": \"id\",\n \"name\": \"name\",\n \"description\": \"description\",\n \"feature_flag_id\": \"feature_flag_id\",\n \"feature_flag_name\": \"feature_flag_name\",\n \"authentication_flow\": \"authentication_flow\",\n \"allocation_strategy\": \"percentage\",\n \"status\": \"draft\",\n \"is_valid\": true,\n \"default_config\": \"tenant\",\n \"feature_flag_snapshot\": {\n \"key\": \"value\"\n },\n \"allocations\": [\n {\n \"variation_id\": \"variation_id\",\n \"variation_name\": \"variation_name\",\n \"segment_id\": \"segment_id\",\n \"segment_name\": \"segment_name\",\n \"weight\": 1,\n \"priority\": 1,\n \"is_control\": true,\n \"is_fallback\": true,\n \"variation_snapshot\": {\n \"key\": \"value\"\n },\n \"segment_snapshot\": {\n \"key\": \"value\"\n }\n }\n ],\n \"editable_fields\": [\n \"editable_fields\"\n ],\n \"levels\": [\n 1\n ],\n \"current_level\": 1,\n \"started_at\": \"2024-01-15T09:30:00Z\",\n \"ended_at\": \"2024-01-15T09:30:00Z\",\n \"created_at\": \"2024-01-15T09:30:00Z\",\n \"updated_at\": \"2024-01-15T09:30:00Z\"\n}", + "headers": { + "Content-Type": "application/json" + } + }, + "uuid": "2f052315-dd21-4094-b6d2-095774dabfe2", + "persistent": true, + "priority": 3, + "metadata": { + "mocklab": { + "created": { + "at": "2020-01-01T00:00:00.000Z", + "via": "SYSTEM" + } + } + } + }, { "id": "82b4942b-e9d7-43ff-9167-27f89f0fb6e3", "name": "Advance the rollout level of a ramp experiment. - default", "request": { - "urlPathTemplate": "/experimentation/experiments/{id}/advance-ramp", + "urlPathTemplate": "/experimentation/experiments/{id}/advance-ramp", + "method": "POST", + "headers": { + "Authorization": { + "matches": "Bearer .+" + } + }, + "pathParameters": { + "id": { + "equalTo": "id" + } + } + }, + "response": { + "status": 201, + "body": "{\n \"experiment_id\": \"experiment_id\",\n \"from_level\": 1,\n \"to_level\": 1,\n \"current_level\": 1\n}", + "headers": { + "Content-Type": "application/json" + } + }, + "uuid": "82b4942b-e9d7-43ff-9167-27f89f0fb6e3", + "persistent": true, + "priority": 3, + "metadata": { + "mocklab": { + "created": { + "at": "2020-01-01T00:00:00.000Z", + "via": "SYSTEM" + } + } + } + }, + { + "id": "bad7af9d-5e89-4f47-b2d5-36b3d3560d91", + "name": "Transition an experiment to a new status. - default", + "request": { + "urlPathTemplate": "/experimentation/experiments/{id}/status", + "method": "POST", + "headers": { + "Authorization": { + "matches": "Bearer .+" + } + }, + "pathParameters": { + "id": { + "equalTo": "id" + } + } + }, + "response": { + "status": 200, + "body": "{\n \"id\": \"id\",\n \"name\": \"name\",\n \"description\": \"description\",\n \"feature_flag_id\": \"feature_flag_id\",\n \"feature_flag_name\": \"feature_flag_name\",\n \"authentication_flow\": \"authentication_flow\",\n \"allocation_strategy\": \"percentage\",\n \"status\": \"draft\",\n \"is_valid\": true,\n \"default_config\": \"tenant\",\n \"feature_flag_snapshot\": {\n \"key\": \"value\"\n },\n \"allocations\": [\n {\n \"variation_id\": \"variation_id\",\n \"variation_name\": \"variation_name\",\n \"segment_id\": \"segment_id\",\n \"segment_name\": \"segment_name\",\n \"weight\": 1,\n \"priority\": 1,\n \"is_control\": true,\n \"is_fallback\": true,\n \"variation_snapshot\": {\n \"key\": \"value\"\n },\n \"segment_snapshot\": {\n \"key\": \"value\"\n }\n }\n ],\n \"editable_fields\": [\n \"editable_fields\"\n ],\n \"levels\": [\n 1\n ],\n \"current_level\": 1,\n \"started_at\": \"2024-01-15T09:30:00Z\",\n \"ended_at\": \"2024-01-15T09:30:00Z\",\n \"created_at\": \"2024-01-15T09:30:00Z\",\n \"updated_at\": \"2024-01-15T09:30:00Z\"\n}", + "headers": { + "Content-Type": "application/json" + } + }, + "uuid": "bad7af9d-5e89-4f47-b2d5-36b3d3560d91", + "persistent": true, + "priority": 3, + "metadata": { + "mocklab": { + "created": { + "at": "2020-01-01T00:00:00.000Z", + "via": "SYSTEM" + } + } + } + }, + { + "id": "20ae6e00-fdf5-43c3-a259-bcdbc0129c9d", + "name": "Validate an experiment. - default", + "request": { + "urlPathTemplate": "/experimentation/experiments/{id}/validate", + "method": "POST", + "headers": { + "Authorization": { + "matches": "Bearer .+" + } + }, + "pathParameters": { + "id": { + "equalTo": "id" + } + } + }, + "response": { + "status": 200, + "body": "{\n \"is_valid\": true,\n \"errors\": [\n {\n \"code\": \"code\",\n \"message\": \"message\"\n }\n ]\n}", + "headers": { + "Content-Type": "application/json" + } + }, + "uuid": "20ae6e00-fdf5-43c3-a259-bcdbc0129c9d", + "persistent": true, + "priority": 3, + "metadata": { + "mocklab": { + "created": { + "at": "2020-01-01T00:00:00.000Z", + "via": "SYSTEM" + } + } + } + }, + { + "id": "c7a5a02e-7595-4d10-b58d-5a96d5a3f7c8", + "name": "List feature flags for the tenant. - default", + "request": { + "urlPathTemplate": "/experimentation/feature-flags", + "method": "GET", + "headers": { + "Authorization": { + "matches": "Bearer .+" + } + }, + "queryParameters": { + "from": { + "equalTo": "from" + }, + "take": { + "equalTo": "1" + }, + "type": { + "equalTo": "auth0" + }, + "status": { + "equalTo": "draft" + } + } + }, + "response": { + "status": 200, + "body": "{\n \"feature_flags\": [\n {\n \"id\": \"id\",\n \"name\": \"name\",\n \"description\": \"description\",\n \"type\": \"auth0\",\n \"status\": \"draft\",\n \"created_at\": \"2024-01-15T09:30:00Z\",\n \"updated_at\": \"2024-01-15T09:30:00Z\"\n }\n ],\n \"next\": \"next\"\n}", + "headers": { + "Content-Type": "application/json" + } + }, + "uuid": "c7a5a02e-7595-4d10-b58d-5a96d5a3f7c8", + "persistent": true, + "priority": 3, + "metadata": { + "mocklab": { + "created": { + "at": "2020-01-01T00:00:00.000Z", + "via": "SYSTEM" + } + } + }, + "postServeActions": [] + }, + { + "id": "5b965deb-f921-4ef0-b7db-7ba8c30d1fef", + "name": "Create a feature flag for the Experiment Center. - default", + "request": { + "urlPathTemplate": "/experimentation/feature-flags", + "method": "POST", + "headers": { + "Authorization": { + "matches": "Bearer .+" + } + } + }, + "response": { + "status": 201, + "body": "{\n \"id\": \"id\",\n \"name\": \"name\",\n \"description\": \"description\",\n \"type\": \"auth0\",\n \"status\": \"draft\",\n \"parameters\": {\n \"key\": {\n \"type\": \"string\",\n \"value\": {\n \"key\": \"value\"\n },\n \"description\": \"description\"\n }\n },\n \"created_at\": \"2024-01-15T09:30:00Z\",\n \"updated_at\": \"2024-01-15T09:30:00Z\"\n}", + "headers": { + "Content-Type": "application/json" + } + }, + "uuid": "5b965deb-f921-4ef0-b7db-7ba8c30d1fef", + "persistent": true, + "priority": 3, + "metadata": { + "mocklab": { + "created": { + "at": "2020-01-01T00:00:00.000Z", + "via": "SYSTEM" + } + } + } + }, + { + "id": "d67c44c6-dd70-4a7a-a203-566a40f7970f", + "name": "Get a feature flag by ID. - default", + "request": { + "urlPathTemplate": "/experimentation/feature-flags/{id}", + "method": "GET", + "headers": { + "Authorization": { + "matches": "Bearer .+" + } + }, + "pathParameters": { + "id": { + "equalTo": "id" + } + } + }, + "response": { + "status": 200, + "body": "{\n \"id\": \"id\",\n \"name\": \"name\",\n \"description\": \"description\",\n \"type\": \"auth0\",\n \"status\": \"draft\",\n \"parameters\": {\n \"key\": {\n \"type\": \"string\",\n \"value\": {\n \"key\": \"value\"\n },\n \"description\": \"description\"\n }\n },\n \"created_at\": \"2024-01-15T09:30:00Z\",\n \"updated_at\": \"2024-01-15T09:30:00Z\"\n}", + "headers": { + "Content-Type": "application/json" + } + }, + "uuid": "d67c44c6-dd70-4a7a-a203-566a40f7970f", + "persistent": true, + "priority": 3, + "metadata": { + "mocklab": { + "created": { + "at": "2020-01-01T00:00:00.000Z", + "via": "SYSTEM" + } + } + } + }, + { + "id": "94fc1535-b1de-4f15-a050-e0db73d2031d", + "name": "Delete a feature flag. - default", + "request": { + "urlPathTemplate": "/experimentation/feature-flags/{id}", + "method": "DELETE", + "headers": { + "Authorization": { + "matches": "Bearer .+" + } + }, + "pathParameters": { + "id": { + "equalTo": "id" + } + } + }, + "response": { + "status": 200, + "body": "\"\"", + "headers": { + "Content-Type": "application/json" + } + }, + "uuid": "94fc1535-b1de-4f15-a050-e0db73d2031d", + "persistent": true, + "priority": 3, + "metadata": { + "mocklab": { + "created": { + "at": "2020-01-01T00:00:00.000Z", + "via": "SYSTEM" + } + } + } + }, + { + "id": "fca842b6-3f36-4dfb-ae90-568e68695c8c", + "name": "Update a feature flag. - default", + "request": { + "urlPathTemplate": "/experimentation/feature-flags/{id}", + "method": "PATCH", + "headers": { + "Authorization": { + "matches": "Bearer .+" + } + }, + "pathParameters": { + "id": { + "equalTo": "id" + } + } + }, + "response": { + "status": 200, + "body": "{\n \"id\": \"id\",\n \"name\": \"name\",\n \"description\": \"description\",\n \"type\": \"auth0\",\n \"status\": \"draft\",\n \"parameters\": {\n \"key\": {\n \"type\": \"string\",\n \"value\": {\n \"key\": \"value\"\n },\n \"description\": \"description\"\n }\n },\n \"created_at\": \"2024-01-15T09:30:00Z\",\n \"updated_at\": \"2024-01-15T09:30:00Z\"\n}", + "headers": { + "Content-Type": "application/json" + } + }, + "uuid": "fca842b6-3f36-4dfb-ae90-568e68695c8c", + "persistent": true, + "priority": 3, + "metadata": { + "mocklab": { + "created": { + "at": "2020-01-01T00:00:00.000Z", + "via": "SYSTEM" + } + } + } + }, + { + "id": "e8918863-9064-44c0-a1b7-db3c423377a1", + "name": "Transition a feature flag to a new status. - default", + "request": { + "urlPathTemplate": "/experimentation/feature-flags/{id}/status", + "method": "POST", + "headers": { + "Authorization": { + "matches": "Bearer .+" + } + }, + "pathParameters": { + "id": { + "equalTo": "id" + } + } + }, + "response": { + "status": 200, + "body": "{\n \"id\": \"id\",\n \"name\": \"name\",\n \"description\": \"description\",\n \"type\": \"auth0\",\n \"status\": \"draft\",\n \"parameters\": {\n \"key\": {\n \"type\": \"string\",\n \"value\": {\n \"key\": \"value\"\n },\n \"description\": \"description\"\n }\n },\n \"created_at\": \"2024-01-15T09:30:00Z\",\n \"updated_at\": \"2024-01-15T09:30:00Z\"\n}", + "headers": { + "Content-Type": "application/json" + } + }, + "uuid": "e8918863-9064-44c0-a1b7-db3c423377a1", + "persistent": true, + "priority": 3, + "metadata": { + "mocklab": { + "created": { + "at": "2020-01-01T00:00:00.000Z", + "via": "SYSTEM" + } + } + } + }, + { + "id": "f3d101fb-cdd6-4ae1-9613-a72ab8cb6207", + "name": "List segments for the tenant. - default", + "request": { + "urlPathTemplate": "/experimentation/segments", + "method": "GET", + "headers": { + "Authorization": { + "matches": "Bearer .+" + } + }, + "queryParameters": { + "from": { + "equalTo": "from" + }, + "take": { + "equalTo": "1" + }, + "type": { + "equalTo": "auth0" + } + } + }, + "response": { + "status": 200, + "body": "{\n \"segments\": [\n {\n \"id\": \"id\",\n \"name\": \"name\",\n \"description\": \"description\",\n \"type\": \"self\",\n \"rules\": [\n {}\n ],\n \"created_at\": \"2024-01-15T09:30:00Z\",\n \"updated_at\": \"2024-01-15T09:30:00Z\"\n }\n ],\n \"next\": \"next\"\n}", + "headers": { + "Content-Type": "application/json" + } + }, + "uuid": "f3d101fb-cdd6-4ae1-9613-a72ab8cb6207", + "persistent": true, + "priority": 3, + "metadata": { + "mocklab": { + "created": { + "at": "2020-01-01T00:00:00.000Z", + "via": "SYSTEM" + } + } + }, + "postServeActions": [] + }, + { + "id": "d8d193b6-8822-4d36-8044-479bd24483e1", + "name": "Create a segment for the Experiment Center. - default", + "request": { + "urlPathTemplate": "/experimentation/segments", + "method": "POST", + "headers": { + "Authorization": { + "matches": "Bearer .+" + } + } + }, + "response": { + "status": 201, + "body": "{\n \"id\": \"id\",\n \"name\": \"name\",\n \"description\": \"description\",\n \"type\": \"self\",\n \"rules\": [\n {}\n ],\n \"created_at\": \"2024-01-15T09:30:00Z\",\n \"updated_at\": \"2024-01-15T09:30:00Z\"\n}", + "headers": { + "Content-Type": "application/json" + } + }, + "uuid": "d8d193b6-8822-4d36-8044-479bd24483e1", + "persistent": true, + "priority": 3, + "metadata": { + "mocklab": { + "created": { + "at": "2020-01-01T00:00:00.000Z", + "via": "SYSTEM" + } + } + } + }, + { + "id": "f205ed84-327b-4abc-9154-889fab0fb681", + "name": "Get a segment by ID. - default", + "request": { + "urlPathTemplate": "/experimentation/segments/{id}", + "method": "GET", + "headers": { + "Authorization": { + "matches": "Bearer .+" + } + }, + "pathParameters": { + "id": { + "equalTo": "id" + } + } + }, + "response": { + "status": 200, + "body": "{\n \"id\": \"id\",\n \"name\": \"name\",\n \"description\": \"description\",\n \"type\": \"self\",\n \"rules\": [\n {}\n ],\n \"created_at\": \"2024-01-15T09:30:00Z\",\n \"updated_at\": \"2024-01-15T09:30:00Z\"\n}", + "headers": { + "Content-Type": "application/json" + } + }, + "uuid": "f205ed84-327b-4abc-9154-889fab0fb681", + "persistent": true, + "priority": 3, + "metadata": { + "mocklab": { + "created": { + "at": "2020-01-01T00:00:00.000Z", + "via": "SYSTEM" + } + } + } + }, + { + "id": "1f1e87b3-9fdc-4b26-8ac2-537a57b6d8ae", + "name": "Delete a segment. - default", + "request": { + "urlPathTemplate": "/experimentation/segments/{id}", + "method": "DELETE", + "headers": { + "Authorization": { + "matches": "Bearer .+" + } + }, + "pathParameters": { + "id": { + "equalTo": "id" + } + } + }, + "response": { + "status": 200, + "body": "\"\"", + "headers": { + "Content-Type": "application/json" + } + }, + "uuid": "1f1e87b3-9fdc-4b26-8ac2-537a57b6d8ae", + "persistent": true, + "priority": 3, + "metadata": { + "mocklab": { + "created": { + "at": "2020-01-01T00:00:00.000Z", + "via": "SYSTEM" + } + } + } + }, + { + "id": "e2397c3e-6009-45bf-8ebd-62d6d9ccc2bd", + "name": "Update a segment. - default", + "request": { + "urlPathTemplate": "/experimentation/segments/{id}", + "method": "PATCH", + "headers": { + "Authorization": { + "matches": "Bearer .+" + } + }, + "pathParameters": { + "id": { + "equalTo": "id" + } + } + }, + "response": { + "status": 200, + "body": "{\n \"id\": \"id\",\n \"name\": \"name\",\n \"description\": \"description\",\n \"type\": \"self\",\n \"rules\": [\n {}\n ],\n \"created_at\": \"2024-01-15T09:30:00Z\",\n \"updated_at\": \"2024-01-15T09:30:00Z\"\n}", + "headers": { + "Content-Type": "application/json" + } + }, + "uuid": "e2397c3e-6009-45bf-8ebd-62d6d9ccc2bd", + "persistent": true, + "priority": 3, + "metadata": { + "mocklab": { + "created": { + "at": "2020-01-01T00:00:00.000Z", + "via": "SYSTEM" + } + } + } + }, + { + "id": "1abb2607-78fd-4896-bc90-9384a36aafdc", + "name": "List all variations for a feature flag. - default", + "request": { + "urlPathTemplate": "/experimentation/feature-flags/{id}/variations", + "method": "GET", + "headers": { + "Authorization": { + "matches": "Bearer .+" + } + }, + "pathParameters": { + "id": { + "equalTo": "id" + } + } + }, + "response": { + "status": 200, + "body": "{\n \"variations\": [\n {\n \"id\": \"id\",\n \"feature_flag_id\": \"feature_flag_id\",\n \"name\": \"name\",\n \"description\": \"description\",\n \"overrides\": {\n \"key\": \"value\"\n },\n \"created_at\": \"2024-01-15T09:30:00Z\",\n \"updated_at\": \"2024-01-15T09:30:00Z\"\n }\n ]\n}", + "headers": { + "Content-Type": "application/json" + } + }, + "uuid": "1abb2607-78fd-4896-bc90-9384a36aafdc", + "persistent": true, + "priority": 3, + "metadata": { + "mocklab": { + "created": { + "at": "2020-01-01T00:00:00.000Z", + "via": "SYSTEM" + } + } + } + }, + { + "id": "c9d939f1-99ea-420a-a6ad-0f672876141b", + "name": "Create a variation for a feature flag. - default", + "request": { + "urlPathTemplate": "/experimentation/feature-flags/{id}/variations", "method": "POST", "headers": { "Authorization": { @@ -10080,12 +10815,129 @@ }, "response": { "status": 201, - "body": "{\n \"experiment_id\": \"experiment_id\",\n \"from_level\": 1,\n \"to_level\": 1,\n \"current_level\": 1\n}", + "body": "{\n \"id\": \"id\",\n \"feature_flag_id\": \"feature_flag_id\",\n \"name\": \"name\",\n \"description\": \"description\",\n \"overrides\": {\n \"key\": \"value\"\n },\n \"created_at\": \"2024-01-15T09:30:00Z\",\n \"updated_at\": \"2024-01-15T09:30:00Z\"\n}", "headers": { "Content-Type": "application/json" } }, - "uuid": "82b4942b-e9d7-43ff-9167-27f89f0fb6e3", + "uuid": "c9d939f1-99ea-420a-a6ad-0f672876141b", + "persistent": true, + "priority": 3, + "metadata": { + "mocklab": { + "created": { + "at": "2020-01-01T00:00:00.000Z", + "via": "SYSTEM" + } + } + } + }, + { + "id": "e2d62924-fd55-44bd-a420-b2af14221ab3", + "name": "Get a variation by ID. - default", + "request": { + "urlPathTemplate": "/experimentation/feature-flags/{id}/variations/{vid}", + "method": "GET", + "headers": { + "Authorization": { + "matches": "Bearer .+" + } + }, + "pathParameters": { + "id": { + "equalTo": "id" + }, + "vid": { + "equalTo": "vid" + } + } + }, + "response": { + "status": 200, + "body": "{\n \"id\": \"id\",\n \"feature_flag_id\": \"feature_flag_id\",\n \"name\": \"name\",\n \"description\": \"description\",\n \"overrides\": {\n \"key\": \"value\"\n },\n \"created_at\": \"2024-01-15T09:30:00Z\",\n \"updated_at\": \"2024-01-15T09:30:00Z\"\n}", + "headers": { + "Content-Type": "application/json" + } + }, + "uuid": "e2d62924-fd55-44bd-a420-b2af14221ab3", + "persistent": true, + "priority": 3, + "metadata": { + "mocklab": { + "created": { + "at": "2020-01-01T00:00:00.000Z", + "via": "SYSTEM" + } + } + } + }, + { + "id": "c581e83f-a6d2-4f3f-b7c3-fd93c5d99b1b", + "name": "Delete a variation. - default", + "request": { + "urlPathTemplate": "/experimentation/feature-flags/{id}/variations/{vid}", + "method": "DELETE", + "headers": { + "Authorization": { + "matches": "Bearer .+" + } + }, + "pathParameters": { + "id": { + "equalTo": "id" + }, + "vid": { + "equalTo": "vid" + } + } + }, + "response": { + "status": 200, + "body": "\"\"", + "headers": { + "Content-Type": "application/json" + } + }, + "uuid": "c581e83f-a6d2-4f3f-b7c3-fd93c5d99b1b", + "persistent": true, + "priority": 3, + "metadata": { + "mocklab": { + "created": { + "at": "2020-01-01T00:00:00.000Z", + "via": "SYSTEM" + } + } + } + }, + { + "id": "f2b8f79d-6aa1-47c2-8894-b917b3dea8e3", + "name": "Update a variation. - default", + "request": { + "urlPathTemplate": "/experimentation/feature-flags/{id}/variations/{vid}", + "method": "PATCH", + "headers": { + "Authorization": { + "matches": "Bearer .+" + } + }, + "pathParameters": { + "id": { + "equalTo": "id" + }, + "vid": { + "equalTo": "vid" + } + } + }, + "response": { + "status": 200, + "body": "{\n \"id\": \"id\",\n \"feature_flag_id\": \"feature_flag_id\",\n \"name\": \"name\",\n \"description\": \"description\",\n \"overrides\": {\n \"key\": \"value\"\n },\n \"created_at\": \"2024-01-15T09:30:00Z\",\n \"updated_at\": \"2024-01-15T09:30:00Z\"\n}", + "headers": { + "Content-Type": "application/json" + } + }, + "uuid": "f2b8f79d-6aa1-47c2-8894-b917b3dea8e3", "persistent": true, "priority": 3, "metadata": { @@ -14006,120 +14858,6 @@ } } }, - { - "id": "c2f5ec1c-5df7-4f2c-9343-e5e3f3f637ef", - "name": "Get organization template for organization - default", - "request": { - "urlPathTemplate": "/organizations/{id}/organization-templates", - "method": "GET", - "headers": { - "Authorization": { - "matches": "Bearer .+" - } - }, - "pathParameters": { - "id": { - "equalTo": "id" - } - } - }, - "response": { - "status": 200, - "body": "{\n \"id\": \"id\",\n \"name\": \"name\",\n \"is_default\": true,\n \"organization_deletion_behavior\": \"allow\",\n \"connection_deletion_behavior\": \"allow\",\n \"enforce_permission_ceiling\": true,\n \"enforce_self_assignment_restriction\": true,\n \"connection_profile_id\": \"connection_profile_id\",\n \"user_attribute_profile_id\": \"user_attribute_profile_id\",\n \"allowed_strategies\": [\n \"adfs\"\n ],\n \"invitation_landing_client_id\": \"invitation_landing_client_id\",\n \"admin_roles_assignment\": [\n \"admin_roles_assignment\"\n ],\n \"use_for_organization_discovery\": {\n \"default_value\": true,\n \"allowed_values\": [\n true\n ]\n },\n \"role_visibility_policy\": {\n \"default_value\": \"write\",\n \"overrides\": [\n {\n \"role_id\": \"role_id\",\n \"access\": \"write\"\n }\n ]\n },\n \"created_at\": \"2024-01-15T09:30:00Z\",\n \"updated_at\": \"2024-01-15T09:30:00Z\"\n}", - "headers": { - "Content-Type": "application/json" - } - }, - "uuid": "c2f5ec1c-5df7-4f2c-9343-e5e3f3f637ef", - "persistent": true, - "priority": 3, - "metadata": { - "mocklab": { - "created": { - "at": "2020-01-01T00:00:00.000Z", - "via": "SYSTEM" - } - } - } - }, - { - "id": "50ff1eeb-7359-44c1-94f5-552cd5844704", - "name": "Assign an organization template to an organization - default", - "request": { - "urlPathTemplate": "/organizations/{id}/organization-templates/{template_id}", - "method": "PUT", - "headers": { - "Authorization": { - "matches": "Bearer .+" - } - }, - "pathParameters": { - "id": { - "equalTo": "id" - }, - "template_id": { - "equalTo": "template_id" - } - } - }, - "response": { - "status": 200, - "body": "\"\"", - "headers": { - "Content-Type": "application/json" - } - }, - "uuid": "50ff1eeb-7359-44c1-94f5-552cd5844704", - "persistent": true, - "priority": 3, - "metadata": { - "mocklab": { - "created": { - "at": "2020-01-01T00:00:00.000Z", - "via": "SYSTEM" - } - } - } - }, - { - "id": "f4cc26a9-f247-4729-96f3-d61861a61351", - "name": "Unassign an organization template from an organization - default", - "request": { - "urlPathTemplate": "/organizations/{id}/organization-templates/{template_id}", - "method": "DELETE", - "headers": { - "Authorization": { - "matches": "Bearer .+" - } - }, - "pathParameters": { - "id": { - "equalTo": "id" - }, - "template_id": { - "equalTo": "template_id" - } - } - }, - "response": { - "status": 200, - "body": "\"\"", - "headers": { - "Content-Type": "application/json" - } - }, - "uuid": "f4cc26a9-f247-4729-96f3-d61861a61351", - "persistent": true, - "priority": 3, - "metadata": { - "mocklab": { - "created": { - "at": "2020-01-01T00:00:00.000Z", - "via": "SYSTEM" - } - } - } - }, { "id": "6d9e3ba1-00dd-4040-89c3-a856e4b77da2", "name": "List the groups that are assigned to the organization. - default", @@ -17105,6 +17843,6 @@ } ], "meta": { - "total": 457 + "total": 477 } } \ No newline at end of file From 96dca58eced61da31144b94ad31356a09e210002 Mon Sep 17 00:00:00 2001 From: "fern-api[bot]" <115122769+fern-api[bot]@users.noreply.github.com> Date: Tue, 29 Sep 2026 05:48:37 +0000 Subject: [PATCH 2/3] [fern-replay] Applied customizations Patches applied (5): - patch-c04f0b4d: Fix for incorrect return type and missing __all__ type - patch-f7384913: Remove duplicate FedCmLoginGooglePatch and FedCmLoginPatch entries - patch-1e44613d: Added migration guide for v5 to v6 - patch-30b1089a: Updated UPGRADING.md doc - patch-d6d69aeb: Remove duplicate FedCmLoginGooglePatch and FedCmLoginPatch entries Patches with unresolved conflicts (3): - patch-4894603d: chore: Restore custom wiring in management/__init__.py - patch-7271f157: Revert wrapper file to preserve Auth0 telemetry customizations - patch-95211006: Restore Auth0 telemetry and custom client wiring after regeneration Run `fern-replay resolve` to apply these customizations. --- .fern/replay.lock | 639 ++++++++++++++++---- UPGRADING.md | 157 +++++ src/auth0/management/__init__.py | 10 + src/auth0/management/core/client_wrapper.py | 5 + 4 files changed, 706 insertions(+), 105 deletions(-) create mode 100644 UPGRADING.md diff --git a/.fern/replay.lock b/.fern/replay.lock index 16449706..ee9bb241 100644 --- a/.fern/replay.lock +++ b/.fern/replay.lock @@ -91,7 +91,13 @@ generations: cli_version: unknown generator_versions: fernapi/fern-python-sdk: 5.26.0 -current_generation: 193c5b32c22bbefb59df79172f03574bdc409a5c + - commit_sha: 3f88a54d1de26fef8a9a3fc8f2be152344b66b0f + tree_hash: 7ace6406973ba9a78fd52d256351ee61457572dd + timestamp: 2026-09-29T05:48:28.838Z + cli_version: unknown + generator_versions: + fernapi/fern-python-sdk: 5.26.0 +current_generation: 3f88a54d1de26fef8a9a3fc8f2be152344b66b0f patches: - id: patch-4894603d content_hash: sha256:fc35b55720e7e9e354dca29191c5832b7e242ad21ba635310c698ea2c3b70a00 @@ -8850,7 +8856,7 @@ patches: "verifiable_credentials", ] user_owned: true - status: resolving + status: unresolved - id: patch-7271f157 content_hash: sha256:cd98dd1948587cf3396a2eacf46626176784bd00996eb660374161bfef686e93 original_commit: 7271f15759cfb545c9ef82b5a4f519ffe0a89db2 @@ -9031,21 +9037,21 @@ patches: token = await self._async_token() headers["Authorization"] = f"Bearer {token}" return headers - status: resolving + status: unresolved - id: patch-c04f0b4d - content_hash: sha256:d81b346f6b8180a73e2f451377ba6365bd7086e80b1eb22b2d694648365be947 + content_hash: sha256:b56317f901bea2a9448227a5dcc0bbd6878bc3f01e31ba601803c3ab93c573ef original_commit: c04f0b4dbbe8f2300f4f1bf42f62350888a92da5 original_message: Fix for incorrect return type and missing __all__ type original_author: Sourav Basu - base_generation: 193c5b32c22bbefb59df79172f03574bdc409a5c + base_generation: 3f88a54d1de26fef8a9a3fc8f2be152344b66b0f files: - src/auth0/management/__init__.py patch_content: | diff --git a/src/auth0/management/__init__.py b/src/auth0/management/__init__.py - index 6d53c2e2..c07ffb67 100644 + index f12b793f..56930e08 100644 --- a/src/auth0/management/__init__.py +++ b/src/auth0/management/__init__.py - @@ -2490,6 +2490,8 @@ if typing.TYPE_CHECKING: + @@ -2514,6 +2514,8 @@ if typing.TYPE_CHECKING: FedCmLoginGoogle, FedCmLoginGooglePatch, FedCmLoginPatch, @@ -9054,7 +9060,7 @@ patches: FlowAction, FlowActionActivecampaign, FlowActionActivecampaignListContacts, - @@ -3886,6 +3888,8 @@ if typing.TYPE_CHECKING: + @@ -3933,6 +3935,8 @@ if typing.TYPE_CHECKING: from .management_client import AsyncManagementClient, CustomDomainHeader, ManagementClient from .token_provider import AsyncTokenProvider, TokenProvider from .version import __version__ @@ -9063,7 +9069,7 @@ patches: _dynamic_imports: typing.Dict[str, str] = { "Action": ".types", "ActionBase": ".types", - @@ -4963,6 +4967,7 @@ _dynamic_imports: typing.Dict[str, str] = { + @@ -5023,6 +5027,7 @@ _dynamic_imports: typing.Dict[str, str] = { "CspReportingEndpoints": ".types", "CspReportingInfrastructure": ".types", "CustomDomain": ".types", @@ -9071,7 +9077,7 @@ patches: "CustomDomainCustomClientIpHeader": ".types", "CustomDomainCustomClientIpHeaderEnum": ".types", "CustomDomainHeader": ".management_client", - @@ -6382,6 +6387,8 @@ _dynamic_imports: typing.Dict[str, str] = { + @@ -6453,6 +6458,8 @@ _dynamic_imports: typing.Dict[str, str] = { "FedCmLoginGoogle": ".types", "FedCmLoginGooglePatch": ".types", "FedCmLoginPatch": ".types", @@ -9080,7 +9086,7 @@ patches: "FlowAction": ".types", "FlowActionActivecampaign": ".types", "FlowActionActivecampaignListContacts": ".types", - @@ -8867,6 +8874,7 @@ __all__ = [ + @@ -8974,6 +8981,7 @@ __all__ = [ "CspReportingEndpoints", "CspReportingInfrastructure", "CustomDomain", @@ -9088,7 +9094,7 @@ patches: "CustomDomainCustomClientIpHeader", "CustomDomainCustomClientIpHeaderEnum", "CustomDomainHeader", - @@ -10286,6 +10294,8 @@ __all__ = [ + @@ -10404,6 +10412,8 @@ __all__ = [ "FedCmLoginGoogle", "FedCmLoginGooglePatch", "FedCmLoginPatch", @@ -9164,6 +9170,9 @@ patches: AdvanceRampResponseContent, AgentMetadata, AgentResponseContent, + AllocationItem, + AllocationRequestItem, + AllocationStrategyEnum, AnomalyIpFormat, AnonymousSessions, AppMetadata, @@ -9184,6 +9193,7 @@ patches: AttackProtectionUpdateCaptchaHcaptcha, AttackProtectionUpdateCaptchaRecaptchaEnterprise, AttackProtectionUpdateCaptchaRecaptchaV2, + AuthenticationFlowEnum, AuthenticationMethodTypeEnum, AuthenticationTypeEnum, B2BIntegrationConfiguration, @@ -9331,6 +9341,8 @@ patches: ClientOidcBackchannelLogoutInitiatorsModeEnum, ClientOidcBackchannelLogoutSessionMetadata, ClientOidcBackchannelLogoutSettings, + ClientOidcSupportAllowedScopesEnum, + ClientOidcSupportPost, ClientOrganizationDiscoveryEnum, ClientOrganizationRequireBehaviorEnum, ClientOrganizationRequireBehaviorPatchEnum, @@ -9444,7 +9456,6 @@ patches: ConnectionDebugSaml, ConnectionDecryptionKeySaml, ConnectionDecryptionKeySamlCert, - ConnectionDeletionBehaviorEnum, ConnectionDestinationUrlSaml, ConnectionDigestAlgorithmEnumSaml, ConnectionDigestAlgorithmSaml, @@ -9855,6 +9866,9 @@ patches: ConnectionThumbprints, ConnectionThumbprintsAd, ConnectionThumbprintsSaml, + ConnectionThumbprintsSha384, + ConnectionThumbprintsSha384Ad, + ConnectionThumbprintsSha384Saml, ConnectionTokenEndpoint, ConnectionTokenEndpointAuthMethodEnum, ConnectionTokenEndpointAuthMethodsSupported, @@ -10037,8 +10051,11 @@ patches: CreateEventStreamResponseContent, CreateEventStreamTestEventResponseContent, CreateEventStreamWebHookRequestContent, + CreateExperimentResponseContent, CreateExportUsersFields, CreateExportUsersResponseContent, + CreateFeatureFlagParameters, + CreateFeatureFlagResponseContent, CreateFlowResponseContent, CreateFlowsVaultConnectionActivecampaign, CreateFlowsVaultConnectionActivecampaignApiKey, @@ -10147,6 +10164,7 @@ patches: CreateScimConfigurationRequestContent, CreateScimConfigurationResponseContent, CreateScimTokenResponseContent, + CreateSegmentResponseContent, CreateSelfServiceProfileResponseContent, CreateSelfServiceProfileSsoTicketResponseContent, CreateTokenExchangeProfileResponseContent, @@ -10154,6 +10172,7 @@ patches: CreateUserAttributeProfileResponseContent, CreateUserAuthenticationMethodResponseContent, CreateUserResponseContent, + CreateVariationResponseContent, CreateVerifiableCredentialTemplateResponseContent, CreateVerificationEmailResponseContent, CreatedAuthenticationMethodTypeEnum, @@ -10193,6 +10212,7 @@ patches: CustomSigningKeyTypeEnum, CustomSigningKeyUseEnum, DailyStats, + DefaultConfigEnum, DefaultMethodEmailIdentifierEnum, DefaultMethodPhoneNumberIdentifierEnum, DefaultTokenQuota, @@ -11584,9 +11604,19 @@ patches: EventStreamWebhookDestination, EventStreamWebhookDestinationTypeEnum, EventStreamWebhookResponseContent, + ExperimentListItem, + ExperimentStatusEnum, + ExperimentTransitionStatusEnum, + ExperimentValidationError, ExpressConfiguration, ExpressConfigurationOrNull, ExtensibilityEmailProviderCredentials, + FeatureFlag, + FeatureFlagConfigParam, + FeatureFlagConfigParamTypeEnum, + FeatureFlagConfigParams, + FeatureFlagStatusEnum, + FeatureFlagTypeEnum, FedCmLogin, FedCmLoginGoogle, FedCmLoginGooglePatch, @@ -12191,6 +12221,8 @@ patches: GetEncryptionKeyResponseContent, GetEventStreamDeliveryHistoryResponseContent, GetEventStreamResponseContent, + GetExperimentResponseContent, + GetFeatureFlagResponseContent, GetFlowExecutionRequestParametersHydrateEnum, GetFlowExecutionResponseContent, GetFlowRequestParametersHydrateEnum, @@ -12246,6 +12278,7 @@ patches: GetScimConfigurationDefaultMappingResponseContent, GetScimConfigurationResponseContent, GetScimTokensResponseContent, + GetSegmentResponseContent, GetSelfServiceProfileResponseContent, GetSessionResponseContent, GetSettingsResponseContent, @@ -12261,6 +12294,7 @@ patches: GetUserAuthenticationMethodResponseContent, GetUserGroupsPaginatedResponseContent, GetUserResponseContent, + GetVariationResponseContent, GetVerifiableCredentialTemplateResponseContent, Group, GroupMember, @@ -12314,6 +12348,8 @@ patches: ListEncryptionKeyOffsetPaginatedResponseContent, ListEventStreamDeliveriesResponseContent, ListEventStreamsResponseContent, + ListExperimentsResponseContent, + ListFeatureFlagsResponseContent, ListFlowExecutionsPaginatedResponseContent, ListFlowsOffsetPaginatedResponseContent, ListFlowsRequestParametersHydrateEnum, @@ -12350,6 +12386,7 @@ patches: ListRolesOffsetPaginatedResponseContent, ListRulesOffsetPaginatedResponseContent, ListScimConfigurationsResponseContent, + ListSegmentsResponseContent, ListSelfServiceProfileCustomTextResponseContent, ListSelfServiceProfilesPaginatedResponseContent, ListSynchronizedGroupsResponseContent, @@ -12370,6 +12407,7 @@ patches: ListUserRolesOffsetPaginatedResponseContent, ListUserSessionsPaginatedResponseContent, ListUsersOffsetPaginatedResponseContent, + ListVariationsResponseContent, ListVerifiableCredentialTemplatesPaginatedResponseContent, Log, LogDate, @@ -12467,7 +12505,6 @@ patches: OrganizationClientMetadataOrganizationUsageEnum, OrganizationConnection, OrganizationConnectionInformation, - OrganizationDeletionBehaviorEnum, OrganizationDiscoveryDomain, OrganizationDiscoveryDomainStatus, OrganizationEnabledConnection, @@ -12482,12 +12519,6 @@ patches: OrganizationMemberRole, OrganizationMetadata, OrganizationSortFieldEnum, - OrganizationTemplate, - OrganizationTemplateAllowedStrategyEnum, - OrganizationTemplateRoleVisibilityEnum, - OrganizationTemplateRoleVisibilityOverride, - OrganizationTemplateRoleVisibilityPolicy, - OrganizationTemplateUseForOrganizationDiscovery, OrganizationThirdPartyClientAccessEnum, OrganizationUsageEnum, PartialGroupsEnum, @@ -12608,6 +12639,17 @@ patches: SearchOrganizationsPaginatedResponseContent, SearchParserEnum, SearchResourceServersResponseContent, + Segment, + SegmentContainsExpression, + SegmentEndsWithExpression, + SegmentExistsExpression, + SegmentMatchConditions, + SegmentMatchExpression, + SegmentNotMatchConditions, + SegmentRule, + SegmentStartsWithExpression, + SegmentTypeEnum, + SegmentTypeFilterEnum, SelfServiceProfile, SelfServiceProfileAllowedStrategyEnum, SelfServiceProfileBranding, @@ -12819,6 +12861,11 @@ patches: UpdateEnabledClientConnectionsRequestContent, UpdateEnabledClientConnectionsRequestContentItem, UpdateEventStreamResponseContent, + UpdateExperimentResponseContent, + UpdateExperimentStatusResponseContent, + UpdateFeatureFlagParameters, + UpdateFeatureFlagResponseContent, + UpdateFeatureFlagStatusResponseContent, UpdateFlowResponseContent, UpdateFlowsVaultConnectionResponseContent, UpdateFlowsVaultConnectionSetup, @@ -12847,6 +12894,7 @@ patches: UpdateRoleResponseContent, UpdateRuleResponseContent, UpdateScimConfigurationResponseContent, + UpdateSegmentResponseContent, UpdateSelfServiceProfileResponseContent, UpdateSessionResponseContent, UpdateSettingsResponseContent, @@ -12858,6 +12906,8 @@ patches: UpdateUserAttributeProfileResponseContent, UpdateUserAuthenticationMethodResponseContent, UpdateUserResponseContent, + UpdateVariationOverridesMap, + UpdateVariationResponseContent, UpdateVerifiableCredentialTemplateResponseContent, UserAppMetadataSchema, UserAttributeProfile, @@ -12908,6 +12958,9 @@ patches: UsernameAttributeIdentifier, UsernameValidation, UsersEnrollment, + ValidateExperimentResponseContent, + Variation, + VariationOverridesMap, VerifiableCredentialTemplateResponse, VerificationMethodEnum, VerifyCustomDomainResponseContent, @@ -13048,6 +13101,9 @@ patches: "AdvanceRampResponseContent": ".types", "AgentMetadata": ".types", "AgentResponseContent": ".types", + "AllocationItem": ".types", + "AllocationRequestItem": ".types", + "AllocationStrategyEnum": ".types", "AnomalyIpFormat": ".types", "AnonymousSessions": ".types", "AppMetadata": ".types", @@ -13073,6 +13129,7 @@ patches: "AttackProtectionUpdateCaptchaRecaptchaV2": ".types", "Auth0": ".client", "Auth0Environment": ".environment", + "AuthenticationFlowEnum": ".types", "AuthenticationMethodTypeEnum": ".types", "AuthenticationTypeEnum": ".types", "B2BIntegrationConfiguration": ".types", @@ -13221,6 +13278,8 @@ patches: "ClientOidcBackchannelLogoutInitiatorsModeEnum": ".types", "ClientOidcBackchannelLogoutSessionMetadata": ".types", "ClientOidcBackchannelLogoutSettings": ".types", + "ClientOidcSupportAllowedScopesEnum": ".types", + "ClientOidcSupportPost": ".types", "ClientOrganizationDiscoveryEnum": ".types", "ClientOrganizationRequireBehaviorEnum": ".types", "ClientOrganizationRequireBehaviorPatchEnum": ".types", @@ -13335,7 +13394,6 @@ patches: "ConnectionDebugSaml": ".types", "ConnectionDecryptionKeySaml": ".types", "ConnectionDecryptionKeySamlCert": ".types", - "ConnectionDeletionBehaviorEnum": ".types", "ConnectionDestinationUrlSaml": ".types", "ConnectionDigestAlgorithmEnumSaml": ".types", "ConnectionDigestAlgorithmSaml": ".types", @@ -13746,6 +13804,9 @@ patches: "ConnectionThumbprints": ".types", "ConnectionThumbprintsAd": ".types", "ConnectionThumbprintsSaml": ".types", + "ConnectionThumbprintsSha384": ".types", + "ConnectionThumbprintsSha384Ad": ".types", + "ConnectionThumbprintsSha384Saml": ".types", "ConnectionTokenEndpoint": ".types", "ConnectionTokenEndpointAuthMethodEnum": ".types", "ConnectionTokenEndpointAuthMethodsSupported": ".types", @@ -13929,8 +13990,11 @@ patches: "CreateEventStreamResponseContent": ".types", "CreateEventStreamTestEventResponseContent": ".types", "CreateEventStreamWebHookRequestContent": ".types", + "CreateExperimentResponseContent": ".types", "CreateExportUsersFields": ".types", "CreateExportUsersResponseContent": ".types", + "CreateFeatureFlagParameters": ".types", + "CreateFeatureFlagResponseContent": ".types", "CreateFlowResponseContent": ".types", "CreateFlowsVaultConnectionActivecampaign": ".types", "CreateFlowsVaultConnectionActivecampaignApiKey": ".types", @@ -14039,6 +14103,7 @@ patches: "CreateScimConfigurationRequestContent": ".types", "CreateScimConfigurationResponseContent": ".types", "CreateScimTokenResponseContent": ".types", + "CreateSegmentResponseContent": ".types", "CreateSelfServiceProfileResponseContent": ".types", "CreateSelfServiceProfileSsoTicketResponseContent": ".types", "CreateTokenExchangeProfileResponseContent": ".types", @@ -14046,6 +14111,7 @@ patches: "CreateUserAttributeProfileResponseContent": ".types", "CreateUserAuthenticationMethodResponseContent": ".types", "CreateUserResponseContent": ".types", + "CreateVariationResponseContent": ".types", "CreateVerifiableCredentialTemplateResponseContent": ".types", "CreateVerificationEmailResponseContent": ".types", "CreatedAuthenticationMethodTypeEnum": ".types", @@ -14089,6 +14155,7 @@ patches: "DailyStats": ".types", "DefaultAioHttpClient": "._default_clients", "DefaultAsyncHttpxClient": "._default_clients", + "DefaultConfigEnum": ".types", "DefaultMethodEmailIdentifierEnum": ".types", "DefaultMethodPhoneNumberIdentifierEnum": ".types", "DefaultTokenQuota": ".types", @@ -15481,9 +15548,19 @@ patches: "EventStreamWebhookDestinationTypeEnum": ".types", "EventStreamWebhookResponseContent": ".types", "EventStreamsCreateRequest": ".event_streams", + "ExperimentListItem": ".types", + "ExperimentStatusEnum": ".types", + "ExperimentTransitionStatusEnum": ".types", + "ExperimentValidationError": ".types", "ExpressConfiguration": ".types", "ExpressConfigurationOrNull": ".types", "ExtensibilityEmailProviderCredentials": ".types", + "FeatureFlag": ".types", + "FeatureFlagConfigParam": ".types", + "FeatureFlagConfigParamTypeEnum": ".types", + "FeatureFlagConfigParams": ".types", + "FeatureFlagStatusEnum": ".types", + "FeatureFlagTypeEnum": ".types", "FedCmLogin": ".types", "FedCmLoginGoogle": ".types", "FedCmLoginGooglePatch": ".types", @@ -16090,6 +16167,8 @@ patches: "GetEncryptionKeyResponseContent": ".types", "GetEventStreamDeliveryHistoryResponseContent": ".types", "GetEventStreamResponseContent": ".types", + "GetExperimentResponseContent": ".types", + "GetFeatureFlagResponseContent": ".types", "GetFlowExecutionRequestParametersHydrateEnum": ".types", "GetFlowExecutionResponseContent": ".types", "GetFlowRequestParametersHydrateEnum": ".types", @@ -16145,6 +16224,7 @@ patches: "GetScimConfigurationDefaultMappingResponseContent": ".types", "GetScimConfigurationResponseContent": ".types", "GetScimTokensResponseContent": ".types", + "GetSegmentResponseContent": ".types", "GetSelfServiceProfileResponseContent": ".types", "GetSessionResponseContent": ".types", "GetSettingsResponseContent": ".types", @@ -16160,6 +16240,7 @@ patches: "GetUserAuthenticationMethodResponseContent": ".types", "GetUserGroupsPaginatedResponseContent": ".types", "GetUserResponseContent": ".types", + "GetVariationResponseContent": ".types", "GetVerifiableCredentialTemplateResponseContent": ".types", "GoneError": ".errors", "Group": ".types", @@ -16215,6 +16296,8 @@ patches: "ListEncryptionKeyOffsetPaginatedResponseContent": ".types", "ListEventStreamDeliveriesResponseContent": ".types", "ListEventStreamsResponseContent": ".types", + "ListExperimentsResponseContent": ".types", + "ListFeatureFlagsResponseContent": ".types", "ListFlowExecutionsPaginatedResponseContent": ".types", "ListFlowsOffsetPaginatedResponseContent": ".types", "ListFlowsRequestParametersHydrateEnum": ".types", @@ -16251,6 +16334,7 @@ patches: "ListRolesOffsetPaginatedResponseContent": ".types", "ListRulesOffsetPaginatedResponseContent": ".types", "ListScimConfigurationsResponseContent": ".types", + "ListSegmentsResponseContent": ".types", "ListSelfServiceProfileCustomTextResponseContent": ".types", "ListSelfServiceProfilesPaginatedResponseContent": ".types", "ListSynchronizedGroupsResponseContent": ".types", @@ -16271,6 +16355,7 @@ patches: "ListUserRolesOffsetPaginatedResponseContent": ".types", "ListUserSessionsPaginatedResponseContent": ".types", "ListUsersOffsetPaginatedResponseContent": ".types", + "ListVariationsResponseContent": ".types", "ListVerifiableCredentialTemplatesPaginatedResponseContent": ".types", "Log": ".types", "LogDate": ".types", @@ -16370,7 +16455,6 @@ patches: "OrganizationClientMetadataOrganizationUsageEnum": ".types", "OrganizationConnection": ".types", "OrganizationConnectionInformation": ".types", - "OrganizationDeletionBehaviorEnum": ".types", "OrganizationDiscoveryDomain": ".types", "OrganizationDiscoveryDomainStatus": ".types", "OrganizationEnabledConnection": ".types", @@ -16385,12 +16469,6 @@ patches: "OrganizationMemberRole": ".types", "OrganizationMetadata": ".types", "OrganizationSortFieldEnum": ".types", - "OrganizationTemplate": ".types", - "OrganizationTemplateAllowedStrategyEnum": ".types", - "OrganizationTemplateRoleVisibilityEnum": ".types", - "OrganizationTemplateRoleVisibilityOverride": ".types", - "OrganizationTemplateRoleVisibilityPolicy": ".types", - "OrganizationTemplateUseForOrganizationDiscovery": ".types", "OrganizationThirdPartyClientAccessEnum": ".types", "OrganizationUsageEnum": ".types", "PartialGroupsEnum": ".types", @@ -16513,6 +16591,17 @@ patches: "SearchOrganizationsPaginatedResponseContent": ".types", "SearchParserEnum": ".types", "SearchResourceServersResponseContent": ".types", + "Segment": ".types", + "SegmentContainsExpression": ".types", + "SegmentEndsWithExpression": ".types", + "SegmentExistsExpression": ".types", + "SegmentMatchConditions": ".types", + "SegmentMatchExpression": ".types", + "SegmentNotMatchConditions": ".types", + "SegmentRule": ".types", + "SegmentStartsWithExpression": ".types", + "SegmentTypeEnum": ".types", + "SegmentTypeFilterEnum": ".types", "SelfServiceProfile": ".types", "SelfServiceProfileAllowedStrategyEnum": ".types", "SelfServiceProfileBranding": ".types", @@ -16729,6 +16818,11 @@ patches: "UpdateEnabledClientConnectionsRequestContent": ".types", "UpdateEnabledClientConnectionsRequestContentItem": ".types", "UpdateEventStreamResponseContent": ".types", + "UpdateExperimentResponseContent": ".types", + "UpdateExperimentStatusResponseContent": ".types", + "UpdateFeatureFlagParameters": ".types", + "UpdateFeatureFlagResponseContent": ".types", + "UpdateFeatureFlagStatusResponseContent": ".types", "UpdateFlowResponseContent": ".types", "UpdateFlowsVaultConnectionResponseContent": ".types", "UpdateFlowsVaultConnectionSetup": ".types", @@ -16757,6 +16851,7 @@ patches: "UpdateRoleResponseContent": ".types", "UpdateRuleResponseContent": ".types", "UpdateScimConfigurationResponseContent": ".types", + "UpdateSegmentResponseContent": ".types", "UpdateSelfServiceProfileResponseContent": ".types", "UpdateSessionResponseContent": ".types", "UpdateSettingsResponseContent": ".types", @@ -16768,6 +16863,8 @@ patches: "UpdateUserAttributeProfileResponseContent": ".types", "UpdateUserAuthenticationMethodResponseContent": ".types", "UpdateUserResponseContent": ".types", + "UpdateVariationOverridesMap": ".types", + "UpdateVariationResponseContent": ".types", "UpdateVerifiableCredentialTemplateResponseContent": ".types", "UserAppMetadataSchema": ".types", "UserAttributeProfile": ".types", @@ -16818,6 +16915,9 @@ patches: "UsernameAttributeIdentifier": ".types", "UsernameValidation": ".types", "UsersEnrollment": ".types", + "ValidateExperimentResponseContent": ".types", + "Variation": ".types", + "VariationOverridesMap": ".types", "VerifiableCredentialTemplateResponse": ".types", "VerificationMethodEnum": ".types", "VerifyCustomDomainResponseContent": ".types", @@ -16955,6 +17055,9 @@ patches: "AdvanceRampResponseContent", "AgentMetadata", "AgentResponseContent", + "AllocationItem", + "AllocationRequestItem", + "AllocationStrategyEnum", "AnomalyIpFormat", "AnonymousSessions", "AppMetadata", @@ -16980,6 +17083,7 @@ patches: "AttackProtectionUpdateCaptchaRecaptchaV2", "Auth0", "Auth0Environment", + "AuthenticationFlowEnum", "AuthenticationMethodTypeEnum", "AuthenticationTypeEnum", "B2BIntegrationConfiguration", @@ -17128,6 +17232,8 @@ patches: "ClientOidcBackchannelLogoutInitiatorsModeEnum", "ClientOidcBackchannelLogoutSessionMetadata", "ClientOidcBackchannelLogoutSettings", + "ClientOidcSupportAllowedScopesEnum", + "ClientOidcSupportPost", "ClientOrganizationDiscoveryEnum", "ClientOrganizationRequireBehaviorEnum", "ClientOrganizationRequireBehaviorPatchEnum", @@ -17242,7 +17348,6 @@ patches: "ConnectionDebugSaml", "ConnectionDecryptionKeySaml", "ConnectionDecryptionKeySamlCert", - "ConnectionDeletionBehaviorEnum", "ConnectionDestinationUrlSaml", "ConnectionDigestAlgorithmEnumSaml", "ConnectionDigestAlgorithmSaml", @@ -17653,6 +17758,9 @@ patches: "ConnectionThumbprints", "ConnectionThumbprintsAd", "ConnectionThumbprintsSaml", + "ConnectionThumbprintsSha384", + "ConnectionThumbprintsSha384Ad", + "ConnectionThumbprintsSha384Saml", "ConnectionTokenEndpoint", "ConnectionTokenEndpointAuthMethodEnum", "ConnectionTokenEndpointAuthMethodsSupported", @@ -17836,8 +17944,11 @@ patches: "CreateEventStreamResponseContent", "CreateEventStreamTestEventResponseContent", "CreateEventStreamWebHookRequestContent", + "CreateExperimentResponseContent", "CreateExportUsersFields", "CreateExportUsersResponseContent", + "CreateFeatureFlagParameters", + "CreateFeatureFlagResponseContent", "CreateFlowResponseContent", "CreateFlowsVaultConnectionActivecampaign", "CreateFlowsVaultConnectionActivecampaignApiKey", @@ -17946,6 +18057,7 @@ patches: "CreateScimConfigurationRequestContent", "CreateScimConfigurationResponseContent", "CreateScimTokenResponseContent", + "CreateSegmentResponseContent", "CreateSelfServiceProfileResponseContent", "CreateSelfServiceProfileSsoTicketResponseContent", "CreateTokenExchangeProfileResponseContent", @@ -17953,6 +18065,7 @@ patches: "CreateUserAttributeProfileResponseContent", "CreateUserAuthenticationMethodResponseContent", "CreateUserResponseContent", + "CreateVariationResponseContent", "CreateVerifiableCredentialTemplateResponseContent", "CreateVerificationEmailResponseContent", "CreatedAuthenticationMethodTypeEnum", @@ -17996,6 +18109,7 @@ patches: "DailyStats", "DefaultAioHttpClient", "DefaultAsyncHttpxClient", + "DefaultConfigEnum", "DefaultMethodEmailIdentifierEnum", "DefaultMethodPhoneNumberIdentifierEnum", "DefaultTokenQuota", @@ -19388,9 +19502,19 @@ patches: "EventStreamWebhookDestinationTypeEnum", "EventStreamWebhookResponseContent", "EventStreamsCreateRequest", + "ExperimentListItem", + "ExperimentStatusEnum", + "ExperimentTransitionStatusEnum", + "ExperimentValidationError", "ExpressConfiguration", "ExpressConfigurationOrNull", "ExtensibilityEmailProviderCredentials", + "FeatureFlag", + "FeatureFlagConfigParam", + "FeatureFlagConfigParamTypeEnum", + "FeatureFlagConfigParams", + "FeatureFlagStatusEnum", + "FeatureFlagTypeEnum", "FedCmLogin", "FedCmLoginGoogle", "FedCmLoginGooglePatch", @@ -19997,6 +20121,8 @@ patches: "GetEncryptionKeyResponseContent", "GetEventStreamDeliveryHistoryResponseContent", "GetEventStreamResponseContent", + "GetExperimentResponseContent", + "GetFeatureFlagResponseContent", "GetFlowExecutionRequestParametersHydrateEnum", "GetFlowExecutionResponseContent", "GetFlowRequestParametersHydrateEnum", @@ -20052,6 +20178,7 @@ patches: "GetScimConfigurationDefaultMappingResponseContent", "GetScimConfigurationResponseContent", "GetScimTokensResponseContent", + "GetSegmentResponseContent", "GetSelfServiceProfileResponseContent", "GetSessionResponseContent", "GetSettingsResponseContent", @@ -20067,6 +20194,7 @@ patches: "GetUserAuthenticationMethodResponseContent", "GetUserGroupsPaginatedResponseContent", "GetUserResponseContent", + "GetVariationResponseContent", "GetVerifiableCredentialTemplateResponseContent", "GoneError", "Group", @@ -20122,6 +20250,8 @@ patches: "ListEncryptionKeyOffsetPaginatedResponseContent", "ListEventStreamDeliveriesResponseContent", "ListEventStreamsResponseContent", + "ListExperimentsResponseContent", + "ListFeatureFlagsResponseContent", "ListFlowExecutionsPaginatedResponseContent", "ListFlowsOffsetPaginatedResponseContent", "ListFlowsRequestParametersHydrateEnum", @@ -20158,6 +20288,7 @@ patches: "ListRolesOffsetPaginatedResponseContent", "ListRulesOffsetPaginatedResponseContent", "ListScimConfigurationsResponseContent", + "ListSegmentsResponseContent", "ListSelfServiceProfileCustomTextResponseContent", "ListSelfServiceProfilesPaginatedResponseContent", "ListSynchronizedGroupsResponseContent", @@ -20178,6 +20309,7 @@ patches: "ListUserRolesOffsetPaginatedResponseContent", "ListUserSessionsPaginatedResponseContent", "ListUsersOffsetPaginatedResponseContent", + "ListVariationsResponseContent", "ListVerifiableCredentialTemplatesPaginatedResponseContent", "Log", "LogDate", @@ -20277,7 +20409,6 @@ patches: "OrganizationClientMetadataOrganizationUsageEnum", "OrganizationConnection", "OrganizationConnectionInformation", - "OrganizationDeletionBehaviorEnum", "OrganizationDiscoveryDomain", "OrganizationDiscoveryDomainStatus", "OrganizationEnabledConnection", @@ -20292,12 +20423,6 @@ patches: "OrganizationMemberRole", "OrganizationMetadata", "OrganizationSortFieldEnum", - "OrganizationTemplate", - "OrganizationTemplateAllowedStrategyEnum", - "OrganizationTemplateRoleVisibilityEnum", - "OrganizationTemplateRoleVisibilityOverride", - "OrganizationTemplateRoleVisibilityPolicy", - "OrganizationTemplateUseForOrganizationDiscovery", "OrganizationThirdPartyClientAccessEnum", "OrganizationUsageEnum", "PartialGroupsEnum", @@ -20420,6 +20545,17 @@ patches: "SearchOrganizationsPaginatedResponseContent", "SearchParserEnum", "SearchResourceServersResponseContent", + "Segment", + "SegmentContainsExpression", + "SegmentEndsWithExpression", + "SegmentExistsExpression", + "SegmentMatchConditions", + "SegmentMatchExpression", + "SegmentNotMatchConditions", + "SegmentRule", + "SegmentStartsWithExpression", + "SegmentTypeEnum", + "SegmentTypeFilterEnum", "SelfServiceProfile", "SelfServiceProfileAllowedStrategyEnum", "SelfServiceProfileBranding", @@ -20636,6 +20772,11 @@ patches: "UpdateEnabledClientConnectionsRequestContent", "UpdateEnabledClientConnectionsRequestContentItem", "UpdateEventStreamResponseContent", + "UpdateExperimentResponseContent", + "UpdateExperimentStatusResponseContent", + "UpdateFeatureFlagParameters", + "UpdateFeatureFlagResponseContent", + "UpdateFeatureFlagStatusResponseContent", "UpdateFlowResponseContent", "UpdateFlowsVaultConnectionResponseContent", "UpdateFlowsVaultConnectionSetup", @@ -20664,6 +20805,7 @@ patches: "UpdateRoleResponseContent", "UpdateRuleResponseContent", "UpdateScimConfigurationResponseContent", + "UpdateSegmentResponseContent", "UpdateSelfServiceProfileResponseContent", "UpdateSessionResponseContent", "UpdateSettingsResponseContent", @@ -20675,6 +20817,8 @@ patches: "UpdateUserAttributeProfileResponseContent", "UpdateUserAuthenticationMethodResponseContent", "UpdateUserResponseContent", + "UpdateVariationOverridesMap", + "UpdateVariationResponseContent", "UpdateVerifiableCredentialTemplateResponseContent", "UserAppMetadataSchema", "UserAttributeProfile", @@ -20725,6 +20869,9 @@ patches: "UsernameAttributeIdentifier", "UsernameValidation", "UsersEnrollment", + "ValidateExperimentResponseContent", + "Variation", + "VariationOverridesMap", "VerifiableCredentialTemplateResponse", "VerificationMethodEnum", "VerifyCustomDomainResponseContent", @@ -30745,21 +30892,21 @@ patches: headers["Authorization"] = f"Bearer {token}" return headers user_owned: true - status: resolving + status: unresolved - id: patch-f7384913 - content_hash: sha256:d81b346f6b8180a73e2f451377ba6365bd7086e80b1eb22b2d694648365be947 + content_hash: sha256:b56317f901bea2a9448227a5dcc0bbd6878bc3f01e31ba601803c3ab93c573ef original_commit: f7384913ab0a14df83dbc602d2b694e2cb7b7668 original_message: Remove duplicate FedCmLoginGooglePatch and FedCmLoginPatch entries original_author: Kunal Dawar - base_generation: 193c5b32c22bbefb59df79172f03574bdc409a5c + base_generation: 3f88a54d1de26fef8a9a3fc8f2be152344b66b0f files: - src/auth0/management/__init__.py patch_content: | diff --git a/src/auth0/management/__init__.py b/src/auth0/management/__init__.py - index 6d53c2e2..c07ffb67 100644 + index f12b793f..56930e08 100644 --- a/src/auth0/management/__init__.py +++ b/src/auth0/management/__init__.py - @@ -2490,6 +2490,8 @@ if typing.TYPE_CHECKING: + @@ -2514,6 +2514,8 @@ if typing.TYPE_CHECKING: FedCmLoginGoogle, FedCmLoginGooglePatch, FedCmLoginPatch, @@ -30768,7 +30915,7 @@ patches: FlowAction, FlowActionActivecampaign, FlowActionActivecampaignListContacts, - @@ -3886,6 +3888,8 @@ if typing.TYPE_CHECKING: + @@ -3933,6 +3935,8 @@ if typing.TYPE_CHECKING: from .management_client import AsyncManagementClient, CustomDomainHeader, ManagementClient from .token_provider import AsyncTokenProvider, TokenProvider from .version import __version__ @@ -30777,7 +30924,7 @@ patches: _dynamic_imports: typing.Dict[str, str] = { "Action": ".types", "ActionBase": ".types", - @@ -4963,6 +4967,7 @@ _dynamic_imports: typing.Dict[str, str] = { + @@ -5023,6 +5027,7 @@ _dynamic_imports: typing.Dict[str, str] = { "CspReportingEndpoints": ".types", "CspReportingInfrastructure": ".types", "CustomDomain": ".types", @@ -30785,7 +30932,7 @@ patches: "CustomDomainCustomClientIpHeader": ".types", "CustomDomainCustomClientIpHeaderEnum": ".types", "CustomDomainHeader": ".management_client", - @@ -6382,6 +6387,8 @@ _dynamic_imports: typing.Dict[str, str] = { + @@ -6453,6 +6458,8 @@ _dynamic_imports: typing.Dict[str, str] = { "FedCmLoginGoogle": ".types", "FedCmLoginGooglePatch": ".types", "FedCmLoginPatch": ".types", @@ -30794,7 +30941,7 @@ patches: "FlowAction": ".types", "FlowActionActivecampaign": ".types", "FlowActionActivecampaignListContacts": ".types", - @@ -8867,6 +8874,7 @@ __all__ = [ + @@ -8974,6 +8981,7 @@ __all__ = [ "CspReportingEndpoints", "CspReportingInfrastructure", "CustomDomain", @@ -30802,7 +30949,7 @@ patches: "CustomDomainCustomClientIpHeader", "CustomDomainCustomClientIpHeaderEnum", "CustomDomainHeader", - @@ -10286,6 +10294,8 @@ __all__ = [ + @@ -10404,6 +10412,8 @@ __all__ = [ "FedCmLoginGoogle", "FedCmLoginGooglePatch", "FedCmLoginPatch", @@ -30878,6 +31025,9 @@ patches: AdvanceRampResponseContent, AgentMetadata, AgentResponseContent, + AllocationItem, + AllocationRequestItem, + AllocationStrategyEnum, AnomalyIpFormat, AnonymousSessions, AppMetadata, @@ -30898,6 +31048,7 @@ patches: AttackProtectionUpdateCaptchaHcaptcha, AttackProtectionUpdateCaptchaRecaptchaEnterprise, AttackProtectionUpdateCaptchaRecaptchaV2, + AuthenticationFlowEnum, AuthenticationMethodTypeEnum, AuthenticationTypeEnum, B2BIntegrationConfiguration, @@ -31045,6 +31196,8 @@ patches: ClientOidcBackchannelLogoutInitiatorsModeEnum, ClientOidcBackchannelLogoutSessionMetadata, ClientOidcBackchannelLogoutSettings, + ClientOidcSupportAllowedScopesEnum, + ClientOidcSupportPost, ClientOrganizationDiscoveryEnum, ClientOrganizationRequireBehaviorEnum, ClientOrganizationRequireBehaviorPatchEnum, @@ -31158,7 +31311,6 @@ patches: ConnectionDebugSaml, ConnectionDecryptionKeySaml, ConnectionDecryptionKeySamlCert, - ConnectionDeletionBehaviorEnum, ConnectionDestinationUrlSaml, ConnectionDigestAlgorithmEnumSaml, ConnectionDigestAlgorithmSaml, @@ -31569,6 +31721,9 @@ patches: ConnectionThumbprints, ConnectionThumbprintsAd, ConnectionThumbprintsSaml, + ConnectionThumbprintsSha384, + ConnectionThumbprintsSha384Ad, + ConnectionThumbprintsSha384Saml, ConnectionTokenEndpoint, ConnectionTokenEndpointAuthMethodEnum, ConnectionTokenEndpointAuthMethodsSupported, @@ -31751,8 +31906,11 @@ patches: CreateEventStreamResponseContent, CreateEventStreamTestEventResponseContent, CreateEventStreamWebHookRequestContent, + CreateExperimentResponseContent, CreateExportUsersFields, CreateExportUsersResponseContent, + CreateFeatureFlagParameters, + CreateFeatureFlagResponseContent, CreateFlowResponseContent, CreateFlowsVaultConnectionActivecampaign, CreateFlowsVaultConnectionActivecampaignApiKey, @@ -31861,6 +32019,7 @@ patches: CreateScimConfigurationRequestContent, CreateScimConfigurationResponseContent, CreateScimTokenResponseContent, + CreateSegmentResponseContent, CreateSelfServiceProfileResponseContent, CreateSelfServiceProfileSsoTicketResponseContent, CreateTokenExchangeProfileResponseContent, @@ -31868,6 +32027,7 @@ patches: CreateUserAttributeProfileResponseContent, CreateUserAuthenticationMethodResponseContent, CreateUserResponseContent, + CreateVariationResponseContent, CreateVerifiableCredentialTemplateResponseContent, CreateVerificationEmailResponseContent, CreatedAuthenticationMethodTypeEnum, @@ -31907,6 +32067,7 @@ patches: CustomSigningKeyTypeEnum, CustomSigningKeyUseEnum, DailyStats, + DefaultConfigEnum, DefaultMethodEmailIdentifierEnum, DefaultMethodPhoneNumberIdentifierEnum, DefaultTokenQuota, @@ -33298,9 +33459,19 @@ patches: EventStreamWebhookDestination, EventStreamWebhookDestinationTypeEnum, EventStreamWebhookResponseContent, + ExperimentListItem, + ExperimentStatusEnum, + ExperimentTransitionStatusEnum, + ExperimentValidationError, ExpressConfiguration, ExpressConfigurationOrNull, ExtensibilityEmailProviderCredentials, + FeatureFlag, + FeatureFlagConfigParam, + FeatureFlagConfigParamTypeEnum, + FeatureFlagConfigParams, + FeatureFlagStatusEnum, + FeatureFlagTypeEnum, FedCmLogin, FedCmLoginGoogle, FedCmLoginGooglePatch, @@ -33905,6 +34076,8 @@ patches: GetEncryptionKeyResponseContent, GetEventStreamDeliveryHistoryResponseContent, GetEventStreamResponseContent, + GetExperimentResponseContent, + GetFeatureFlagResponseContent, GetFlowExecutionRequestParametersHydrateEnum, GetFlowExecutionResponseContent, GetFlowRequestParametersHydrateEnum, @@ -33960,6 +34133,7 @@ patches: GetScimConfigurationDefaultMappingResponseContent, GetScimConfigurationResponseContent, GetScimTokensResponseContent, + GetSegmentResponseContent, GetSelfServiceProfileResponseContent, GetSessionResponseContent, GetSettingsResponseContent, @@ -33975,6 +34149,7 @@ patches: GetUserAuthenticationMethodResponseContent, GetUserGroupsPaginatedResponseContent, GetUserResponseContent, + GetVariationResponseContent, GetVerifiableCredentialTemplateResponseContent, Group, GroupMember, @@ -34028,6 +34203,8 @@ patches: ListEncryptionKeyOffsetPaginatedResponseContent, ListEventStreamDeliveriesResponseContent, ListEventStreamsResponseContent, + ListExperimentsResponseContent, + ListFeatureFlagsResponseContent, ListFlowExecutionsPaginatedResponseContent, ListFlowsOffsetPaginatedResponseContent, ListFlowsRequestParametersHydrateEnum, @@ -34064,6 +34241,7 @@ patches: ListRolesOffsetPaginatedResponseContent, ListRulesOffsetPaginatedResponseContent, ListScimConfigurationsResponseContent, + ListSegmentsResponseContent, ListSelfServiceProfileCustomTextResponseContent, ListSelfServiceProfilesPaginatedResponseContent, ListSynchronizedGroupsResponseContent, @@ -34084,6 +34262,7 @@ patches: ListUserRolesOffsetPaginatedResponseContent, ListUserSessionsPaginatedResponseContent, ListUsersOffsetPaginatedResponseContent, + ListVariationsResponseContent, ListVerifiableCredentialTemplatesPaginatedResponseContent, Log, LogDate, @@ -34181,7 +34360,6 @@ patches: OrganizationClientMetadataOrganizationUsageEnum, OrganizationConnection, OrganizationConnectionInformation, - OrganizationDeletionBehaviorEnum, OrganizationDiscoveryDomain, OrganizationDiscoveryDomainStatus, OrganizationEnabledConnection, @@ -34196,12 +34374,6 @@ patches: OrganizationMemberRole, OrganizationMetadata, OrganizationSortFieldEnum, - OrganizationTemplate, - OrganizationTemplateAllowedStrategyEnum, - OrganizationTemplateRoleVisibilityEnum, - OrganizationTemplateRoleVisibilityOverride, - OrganizationTemplateRoleVisibilityPolicy, - OrganizationTemplateUseForOrganizationDiscovery, OrganizationThirdPartyClientAccessEnum, OrganizationUsageEnum, PartialGroupsEnum, @@ -34322,6 +34494,17 @@ patches: SearchOrganizationsPaginatedResponseContent, SearchParserEnum, SearchResourceServersResponseContent, + Segment, + SegmentContainsExpression, + SegmentEndsWithExpression, + SegmentExistsExpression, + SegmentMatchConditions, + SegmentMatchExpression, + SegmentNotMatchConditions, + SegmentRule, + SegmentStartsWithExpression, + SegmentTypeEnum, + SegmentTypeFilterEnum, SelfServiceProfile, SelfServiceProfileAllowedStrategyEnum, SelfServiceProfileBranding, @@ -34533,6 +34716,11 @@ patches: UpdateEnabledClientConnectionsRequestContent, UpdateEnabledClientConnectionsRequestContentItem, UpdateEventStreamResponseContent, + UpdateExperimentResponseContent, + UpdateExperimentStatusResponseContent, + UpdateFeatureFlagParameters, + UpdateFeatureFlagResponseContent, + UpdateFeatureFlagStatusResponseContent, UpdateFlowResponseContent, UpdateFlowsVaultConnectionResponseContent, UpdateFlowsVaultConnectionSetup, @@ -34561,6 +34749,7 @@ patches: UpdateRoleResponseContent, UpdateRuleResponseContent, UpdateScimConfigurationResponseContent, + UpdateSegmentResponseContent, UpdateSelfServiceProfileResponseContent, UpdateSessionResponseContent, UpdateSettingsResponseContent, @@ -34572,6 +34761,8 @@ patches: UpdateUserAttributeProfileResponseContent, UpdateUserAuthenticationMethodResponseContent, UpdateUserResponseContent, + UpdateVariationOverridesMap, + UpdateVariationResponseContent, UpdateVerifiableCredentialTemplateResponseContent, UserAppMetadataSchema, UserAttributeProfile, @@ -34622,6 +34813,9 @@ patches: UsernameAttributeIdentifier, UsernameValidation, UsersEnrollment, + ValidateExperimentResponseContent, + Variation, + VariationOverridesMap, VerifiableCredentialTemplateResponse, VerificationMethodEnum, VerifyCustomDomainResponseContent, @@ -34762,6 +34956,9 @@ patches: "AdvanceRampResponseContent": ".types", "AgentMetadata": ".types", "AgentResponseContent": ".types", + "AllocationItem": ".types", + "AllocationRequestItem": ".types", + "AllocationStrategyEnum": ".types", "AnomalyIpFormat": ".types", "AnonymousSessions": ".types", "AppMetadata": ".types", @@ -34787,6 +34984,7 @@ patches: "AttackProtectionUpdateCaptchaRecaptchaV2": ".types", "Auth0": ".client", "Auth0Environment": ".environment", + "AuthenticationFlowEnum": ".types", "AuthenticationMethodTypeEnum": ".types", "AuthenticationTypeEnum": ".types", "B2BIntegrationConfiguration": ".types", @@ -34935,6 +35133,8 @@ patches: "ClientOidcBackchannelLogoutInitiatorsModeEnum": ".types", "ClientOidcBackchannelLogoutSessionMetadata": ".types", "ClientOidcBackchannelLogoutSettings": ".types", + "ClientOidcSupportAllowedScopesEnum": ".types", + "ClientOidcSupportPost": ".types", "ClientOrganizationDiscoveryEnum": ".types", "ClientOrganizationRequireBehaviorEnum": ".types", "ClientOrganizationRequireBehaviorPatchEnum": ".types", @@ -35049,7 +35249,6 @@ patches: "ConnectionDebugSaml": ".types", "ConnectionDecryptionKeySaml": ".types", "ConnectionDecryptionKeySamlCert": ".types", - "ConnectionDeletionBehaviorEnum": ".types", "ConnectionDestinationUrlSaml": ".types", "ConnectionDigestAlgorithmEnumSaml": ".types", "ConnectionDigestAlgorithmSaml": ".types", @@ -35460,6 +35659,9 @@ patches: "ConnectionThumbprints": ".types", "ConnectionThumbprintsAd": ".types", "ConnectionThumbprintsSaml": ".types", + "ConnectionThumbprintsSha384": ".types", + "ConnectionThumbprintsSha384Ad": ".types", + "ConnectionThumbprintsSha384Saml": ".types", "ConnectionTokenEndpoint": ".types", "ConnectionTokenEndpointAuthMethodEnum": ".types", "ConnectionTokenEndpointAuthMethodsSupported": ".types", @@ -35643,8 +35845,11 @@ patches: "CreateEventStreamResponseContent": ".types", "CreateEventStreamTestEventResponseContent": ".types", "CreateEventStreamWebHookRequestContent": ".types", + "CreateExperimentResponseContent": ".types", "CreateExportUsersFields": ".types", "CreateExportUsersResponseContent": ".types", + "CreateFeatureFlagParameters": ".types", + "CreateFeatureFlagResponseContent": ".types", "CreateFlowResponseContent": ".types", "CreateFlowsVaultConnectionActivecampaign": ".types", "CreateFlowsVaultConnectionActivecampaignApiKey": ".types", @@ -35753,6 +35958,7 @@ patches: "CreateScimConfigurationRequestContent": ".types", "CreateScimConfigurationResponseContent": ".types", "CreateScimTokenResponseContent": ".types", + "CreateSegmentResponseContent": ".types", "CreateSelfServiceProfileResponseContent": ".types", "CreateSelfServiceProfileSsoTicketResponseContent": ".types", "CreateTokenExchangeProfileResponseContent": ".types", @@ -35760,6 +35966,7 @@ patches: "CreateUserAttributeProfileResponseContent": ".types", "CreateUserAuthenticationMethodResponseContent": ".types", "CreateUserResponseContent": ".types", + "CreateVariationResponseContent": ".types", "CreateVerifiableCredentialTemplateResponseContent": ".types", "CreateVerificationEmailResponseContent": ".types", "CreatedAuthenticationMethodTypeEnum": ".types", @@ -35803,6 +36010,7 @@ patches: "DailyStats": ".types", "DefaultAioHttpClient": "._default_clients", "DefaultAsyncHttpxClient": "._default_clients", + "DefaultConfigEnum": ".types", "DefaultMethodEmailIdentifierEnum": ".types", "DefaultMethodPhoneNumberIdentifierEnum": ".types", "DefaultTokenQuota": ".types", @@ -37195,9 +37403,19 @@ patches: "EventStreamWebhookDestinationTypeEnum": ".types", "EventStreamWebhookResponseContent": ".types", "EventStreamsCreateRequest": ".event_streams", + "ExperimentListItem": ".types", + "ExperimentStatusEnum": ".types", + "ExperimentTransitionStatusEnum": ".types", + "ExperimentValidationError": ".types", "ExpressConfiguration": ".types", "ExpressConfigurationOrNull": ".types", "ExtensibilityEmailProviderCredentials": ".types", + "FeatureFlag": ".types", + "FeatureFlagConfigParam": ".types", + "FeatureFlagConfigParamTypeEnum": ".types", + "FeatureFlagConfigParams": ".types", + "FeatureFlagStatusEnum": ".types", + "FeatureFlagTypeEnum": ".types", "FedCmLogin": ".types", "FedCmLoginGoogle": ".types", "FedCmLoginGooglePatch": ".types", @@ -37804,6 +38022,8 @@ patches: "GetEncryptionKeyResponseContent": ".types", "GetEventStreamDeliveryHistoryResponseContent": ".types", "GetEventStreamResponseContent": ".types", + "GetExperimentResponseContent": ".types", + "GetFeatureFlagResponseContent": ".types", "GetFlowExecutionRequestParametersHydrateEnum": ".types", "GetFlowExecutionResponseContent": ".types", "GetFlowRequestParametersHydrateEnum": ".types", @@ -37859,6 +38079,7 @@ patches: "GetScimConfigurationDefaultMappingResponseContent": ".types", "GetScimConfigurationResponseContent": ".types", "GetScimTokensResponseContent": ".types", + "GetSegmentResponseContent": ".types", "GetSelfServiceProfileResponseContent": ".types", "GetSessionResponseContent": ".types", "GetSettingsResponseContent": ".types", @@ -37874,6 +38095,7 @@ patches: "GetUserAuthenticationMethodResponseContent": ".types", "GetUserGroupsPaginatedResponseContent": ".types", "GetUserResponseContent": ".types", + "GetVariationResponseContent": ".types", "GetVerifiableCredentialTemplateResponseContent": ".types", "GoneError": ".errors", "Group": ".types", @@ -37929,6 +38151,8 @@ patches: "ListEncryptionKeyOffsetPaginatedResponseContent": ".types", "ListEventStreamDeliveriesResponseContent": ".types", "ListEventStreamsResponseContent": ".types", + "ListExperimentsResponseContent": ".types", + "ListFeatureFlagsResponseContent": ".types", "ListFlowExecutionsPaginatedResponseContent": ".types", "ListFlowsOffsetPaginatedResponseContent": ".types", "ListFlowsRequestParametersHydrateEnum": ".types", @@ -37965,6 +38189,7 @@ patches: "ListRolesOffsetPaginatedResponseContent": ".types", "ListRulesOffsetPaginatedResponseContent": ".types", "ListScimConfigurationsResponseContent": ".types", + "ListSegmentsResponseContent": ".types", "ListSelfServiceProfileCustomTextResponseContent": ".types", "ListSelfServiceProfilesPaginatedResponseContent": ".types", "ListSynchronizedGroupsResponseContent": ".types", @@ -37985,6 +38210,7 @@ patches: "ListUserRolesOffsetPaginatedResponseContent": ".types", "ListUserSessionsPaginatedResponseContent": ".types", "ListUsersOffsetPaginatedResponseContent": ".types", + "ListVariationsResponseContent": ".types", "ListVerifiableCredentialTemplatesPaginatedResponseContent": ".types", "Log": ".types", "LogDate": ".types", @@ -38084,7 +38310,6 @@ patches: "OrganizationClientMetadataOrganizationUsageEnum": ".types", "OrganizationConnection": ".types", "OrganizationConnectionInformation": ".types", - "OrganizationDeletionBehaviorEnum": ".types", "OrganizationDiscoveryDomain": ".types", "OrganizationDiscoveryDomainStatus": ".types", "OrganizationEnabledConnection": ".types", @@ -38099,12 +38324,6 @@ patches: "OrganizationMemberRole": ".types", "OrganizationMetadata": ".types", "OrganizationSortFieldEnum": ".types", - "OrganizationTemplate": ".types", - "OrganizationTemplateAllowedStrategyEnum": ".types", - "OrganizationTemplateRoleVisibilityEnum": ".types", - "OrganizationTemplateRoleVisibilityOverride": ".types", - "OrganizationTemplateRoleVisibilityPolicy": ".types", - "OrganizationTemplateUseForOrganizationDiscovery": ".types", "OrganizationThirdPartyClientAccessEnum": ".types", "OrganizationUsageEnum": ".types", "PartialGroupsEnum": ".types", @@ -38227,6 +38446,17 @@ patches: "SearchOrganizationsPaginatedResponseContent": ".types", "SearchParserEnum": ".types", "SearchResourceServersResponseContent": ".types", + "Segment": ".types", + "SegmentContainsExpression": ".types", + "SegmentEndsWithExpression": ".types", + "SegmentExistsExpression": ".types", + "SegmentMatchConditions": ".types", + "SegmentMatchExpression": ".types", + "SegmentNotMatchConditions": ".types", + "SegmentRule": ".types", + "SegmentStartsWithExpression": ".types", + "SegmentTypeEnum": ".types", + "SegmentTypeFilterEnum": ".types", "SelfServiceProfile": ".types", "SelfServiceProfileAllowedStrategyEnum": ".types", "SelfServiceProfileBranding": ".types", @@ -38443,6 +38673,11 @@ patches: "UpdateEnabledClientConnectionsRequestContent": ".types", "UpdateEnabledClientConnectionsRequestContentItem": ".types", "UpdateEventStreamResponseContent": ".types", + "UpdateExperimentResponseContent": ".types", + "UpdateExperimentStatusResponseContent": ".types", + "UpdateFeatureFlagParameters": ".types", + "UpdateFeatureFlagResponseContent": ".types", + "UpdateFeatureFlagStatusResponseContent": ".types", "UpdateFlowResponseContent": ".types", "UpdateFlowsVaultConnectionResponseContent": ".types", "UpdateFlowsVaultConnectionSetup": ".types", @@ -38471,6 +38706,7 @@ patches: "UpdateRoleResponseContent": ".types", "UpdateRuleResponseContent": ".types", "UpdateScimConfigurationResponseContent": ".types", + "UpdateSegmentResponseContent": ".types", "UpdateSelfServiceProfileResponseContent": ".types", "UpdateSessionResponseContent": ".types", "UpdateSettingsResponseContent": ".types", @@ -38482,6 +38718,8 @@ patches: "UpdateUserAttributeProfileResponseContent": ".types", "UpdateUserAuthenticationMethodResponseContent": ".types", "UpdateUserResponseContent": ".types", + "UpdateVariationOverridesMap": ".types", + "UpdateVariationResponseContent": ".types", "UpdateVerifiableCredentialTemplateResponseContent": ".types", "UserAppMetadataSchema": ".types", "UserAttributeProfile": ".types", @@ -38532,6 +38770,9 @@ patches: "UsernameAttributeIdentifier": ".types", "UsernameValidation": ".types", "UsersEnrollment": ".types", + "ValidateExperimentResponseContent": ".types", + "Variation": ".types", + "VariationOverridesMap": ".types", "VerifiableCredentialTemplateResponse": ".types", "VerificationMethodEnum": ".types", "VerifyCustomDomainResponseContent": ".types", @@ -38669,6 +38910,9 @@ patches: "AdvanceRampResponseContent", "AgentMetadata", "AgentResponseContent", + "AllocationItem", + "AllocationRequestItem", + "AllocationStrategyEnum", "AnomalyIpFormat", "AnonymousSessions", "AppMetadata", @@ -38694,6 +38938,7 @@ patches: "AttackProtectionUpdateCaptchaRecaptchaV2", "Auth0", "Auth0Environment", + "AuthenticationFlowEnum", "AuthenticationMethodTypeEnum", "AuthenticationTypeEnum", "B2BIntegrationConfiguration", @@ -38842,6 +39087,8 @@ patches: "ClientOidcBackchannelLogoutInitiatorsModeEnum", "ClientOidcBackchannelLogoutSessionMetadata", "ClientOidcBackchannelLogoutSettings", + "ClientOidcSupportAllowedScopesEnum", + "ClientOidcSupportPost", "ClientOrganizationDiscoveryEnum", "ClientOrganizationRequireBehaviorEnum", "ClientOrganizationRequireBehaviorPatchEnum", @@ -38956,7 +39203,6 @@ patches: "ConnectionDebugSaml", "ConnectionDecryptionKeySaml", "ConnectionDecryptionKeySamlCert", - "ConnectionDeletionBehaviorEnum", "ConnectionDestinationUrlSaml", "ConnectionDigestAlgorithmEnumSaml", "ConnectionDigestAlgorithmSaml", @@ -39367,6 +39613,9 @@ patches: "ConnectionThumbprints", "ConnectionThumbprintsAd", "ConnectionThumbprintsSaml", + "ConnectionThumbprintsSha384", + "ConnectionThumbprintsSha384Ad", + "ConnectionThumbprintsSha384Saml", "ConnectionTokenEndpoint", "ConnectionTokenEndpointAuthMethodEnum", "ConnectionTokenEndpointAuthMethodsSupported", @@ -39550,8 +39799,11 @@ patches: "CreateEventStreamResponseContent", "CreateEventStreamTestEventResponseContent", "CreateEventStreamWebHookRequestContent", + "CreateExperimentResponseContent", "CreateExportUsersFields", "CreateExportUsersResponseContent", + "CreateFeatureFlagParameters", + "CreateFeatureFlagResponseContent", "CreateFlowResponseContent", "CreateFlowsVaultConnectionActivecampaign", "CreateFlowsVaultConnectionActivecampaignApiKey", @@ -39660,6 +39912,7 @@ patches: "CreateScimConfigurationRequestContent", "CreateScimConfigurationResponseContent", "CreateScimTokenResponseContent", + "CreateSegmentResponseContent", "CreateSelfServiceProfileResponseContent", "CreateSelfServiceProfileSsoTicketResponseContent", "CreateTokenExchangeProfileResponseContent", @@ -39667,6 +39920,7 @@ patches: "CreateUserAttributeProfileResponseContent", "CreateUserAuthenticationMethodResponseContent", "CreateUserResponseContent", + "CreateVariationResponseContent", "CreateVerifiableCredentialTemplateResponseContent", "CreateVerificationEmailResponseContent", "CreatedAuthenticationMethodTypeEnum", @@ -39710,6 +39964,7 @@ patches: "DailyStats", "DefaultAioHttpClient", "DefaultAsyncHttpxClient", + "DefaultConfigEnum", "DefaultMethodEmailIdentifierEnum", "DefaultMethodPhoneNumberIdentifierEnum", "DefaultTokenQuota", @@ -41102,9 +41357,19 @@ patches: "EventStreamWebhookDestinationTypeEnum", "EventStreamWebhookResponseContent", "EventStreamsCreateRequest", + "ExperimentListItem", + "ExperimentStatusEnum", + "ExperimentTransitionStatusEnum", + "ExperimentValidationError", "ExpressConfiguration", "ExpressConfigurationOrNull", "ExtensibilityEmailProviderCredentials", + "FeatureFlag", + "FeatureFlagConfigParam", + "FeatureFlagConfigParamTypeEnum", + "FeatureFlagConfigParams", + "FeatureFlagStatusEnum", + "FeatureFlagTypeEnum", "FedCmLogin", "FedCmLoginGoogle", "FedCmLoginGooglePatch", @@ -41711,6 +41976,8 @@ patches: "GetEncryptionKeyResponseContent", "GetEventStreamDeliveryHistoryResponseContent", "GetEventStreamResponseContent", + "GetExperimentResponseContent", + "GetFeatureFlagResponseContent", "GetFlowExecutionRequestParametersHydrateEnum", "GetFlowExecutionResponseContent", "GetFlowRequestParametersHydrateEnum", @@ -41766,6 +42033,7 @@ patches: "GetScimConfigurationDefaultMappingResponseContent", "GetScimConfigurationResponseContent", "GetScimTokensResponseContent", + "GetSegmentResponseContent", "GetSelfServiceProfileResponseContent", "GetSessionResponseContent", "GetSettingsResponseContent", @@ -41781,6 +42049,7 @@ patches: "GetUserAuthenticationMethodResponseContent", "GetUserGroupsPaginatedResponseContent", "GetUserResponseContent", + "GetVariationResponseContent", "GetVerifiableCredentialTemplateResponseContent", "GoneError", "Group", @@ -41836,6 +42105,8 @@ patches: "ListEncryptionKeyOffsetPaginatedResponseContent", "ListEventStreamDeliveriesResponseContent", "ListEventStreamsResponseContent", + "ListExperimentsResponseContent", + "ListFeatureFlagsResponseContent", "ListFlowExecutionsPaginatedResponseContent", "ListFlowsOffsetPaginatedResponseContent", "ListFlowsRequestParametersHydrateEnum", @@ -41872,6 +42143,7 @@ patches: "ListRolesOffsetPaginatedResponseContent", "ListRulesOffsetPaginatedResponseContent", "ListScimConfigurationsResponseContent", + "ListSegmentsResponseContent", "ListSelfServiceProfileCustomTextResponseContent", "ListSelfServiceProfilesPaginatedResponseContent", "ListSynchronizedGroupsResponseContent", @@ -41892,6 +42164,7 @@ patches: "ListUserRolesOffsetPaginatedResponseContent", "ListUserSessionsPaginatedResponseContent", "ListUsersOffsetPaginatedResponseContent", + "ListVariationsResponseContent", "ListVerifiableCredentialTemplatesPaginatedResponseContent", "Log", "LogDate", @@ -41991,7 +42264,6 @@ patches: "OrganizationClientMetadataOrganizationUsageEnum", "OrganizationConnection", "OrganizationConnectionInformation", - "OrganizationDeletionBehaviorEnum", "OrganizationDiscoveryDomain", "OrganizationDiscoveryDomainStatus", "OrganizationEnabledConnection", @@ -42006,12 +42278,6 @@ patches: "OrganizationMemberRole", "OrganizationMetadata", "OrganizationSortFieldEnum", - "OrganizationTemplate", - "OrganizationTemplateAllowedStrategyEnum", - "OrganizationTemplateRoleVisibilityEnum", - "OrganizationTemplateRoleVisibilityOverride", - "OrganizationTemplateRoleVisibilityPolicy", - "OrganizationTemplateUseForOrganizationDiscovery", "OrganizationThirdPartyClientAccessEnum", "OrganizationUsageEnum", "PartialGroupsEnum", @@ -42134,6 +42400,17 @@ patches: "SearchOrganizationsPaginatedResponseContent", "SearchParserEnum", "SearchResourceServersResponseContent", + "Segment", + "SegmentContainsExpression", + "SegmentEndsWithExpression", + "SegmentExistsExpression", + "SegmentMatchConditions", + "SegmentMatchExpression", + "SegmentNotMatchConditions", + "SegmentRule", + "SegmentStartsWithExpression", + "SegmentTypeEnum", + "SegmentTypeFilterEnum", "SelfServiceProfile", "SelfServiceProfileAllowedStrategyEnum", "SelfServiceProfileBranding", @@ -42350,6 +42627,11 @@ patches: "UpdateEnabledClientConnectionsRequestContent", "UpdateEnabledClientConnectionsRequestContentItem", "UpdateEventStreamResponseContent", + "UpdateExperimentResponseContent", + "UpdateExperimentStatusResponseContent", + "UpdateFeatureFlagParameters", + "UpdateFeatureFlagResponseContent", + "UpdateFeatureFlagStatusResponseContent", "UpdateFlowResponseContent", "UpdateFlowsVaultConnectionResponseContent", "UpdateFlowsVaultConnectionSetup", @@ -42378,6 +42660,7 @@ patches: "UpdateRoleResponseContent", "UpdateRuleResponseContent", "UpdateScimConfigurationResponseContent", + "UpdateSegmentResponseContent", "UpdateSelfServiceProfileResponseContent", "UpdateSessionResponseContent", "UpdateSettingsResponseContent", @@ -42389,6 +42672,8 @@ patches: "UpdateUserAttributeProfileResponseContent", "UpdateUserAuthenticationMethodResponseContent", "UpdateUserResponseContent", + "UpdateVariationOverridesMap", + "UpdateVariationResponseContent", "UpdateVerifiableCredentialTemplateResponseContent", "UserAppMetadataSchema", "UserAttributeProfile", @@ -42439,6 +42724,9 @@ patches: "UsernameAttributeIdentifier", "UsernameValidation", "UsersEnrollment", + "ValidateExperimentResponseContent", + "Variation", + "VariationOverridesMap", "VerifiableCredentialTemplateResponse", "VerificationMethodEnum", "VerifyCustomDomainResponseContent", @@ -42502,7 +42790,7 @@ patches: original_commit: 1e44613dc017468608983dfc1363804d02ed8fc4 original_message: Added migration guide for v5 to v6 original_author: Sourav Basu - base_generation: 193c5b32c22bbefb59df79172f03574bdc409a5c + base_generation: 3f88a54d1de26fef8a9a3fc8f2be152344b66b0f files: - UPGRADING.md patch_content: | @@ -42834,7 +43122,7 @@ patches: original_commit: 30b1089ae90f33c4b431b9d868edd89a6d4697ce original_message: Updated UPGRADING.md doc original_author: Sourav Basu - base_generation: 193c5b32c22bbefb59df79172f03574bdc409a5c + base_generation: 3f88a54d1de26fef8a9a3fc8f2be152344b66b0f files: - UPGRADING.md patch_content: | @@ -43162,19 +43450,19 @@ patches: endpoint. user_owned: true - id: patch-d6d69aeb - content_hash: sha256:d81b346f6b8180a73e2f451377ba6365bd7086e80b1eb22b2d694648365be947 + content_hash: sha256:b56317f901bea2a9448227a5dcc0bbd6878bc3f01e31ba601803c3ab93c573ef original_commit: d6d69aeb98af7789afffbc697bc8fd50d7d86baa original_message: Remove duplicate FedCmLoginGooglePatch and FedCmLoginPatch entries original_author: Kunal Dawar - base_generation: 193c5b32c22bbefb59df79172f03574bdc409a5c + base_generation: 3f88a54d1de26fef8a9a3fc8f2be152344b66b0f files: - src/auth0/management/__init__.py patch_content: | diff --git a/src/auth0/management/__init__.py b/src/auth0/management/__init__.py - index 6d53c2e2..c07ffb67 100644 + index f12b793f..56930e08 100644 --- a/src/auth0/management/__init__.py +++ b/src/auth0/management/__init__.py - @@ -2490,6 +2490,8 @@ if typing.TYPE_CHECKING: + @@ -2514,6 +2514,8 @@ if typing.TYPE_CHECKING: FedCmLoginGoogle, FedCmLoginGooglePatch, FedCmLoginPatch, @@ -43183,7 +43471,7 @@ patches: FlowAction, FlowActionActivecampaign, FlowActionActivecampaignListContacts, - @@ -3886,6 +3888,8 @@ if typing.TYPE_CHECKING: + @@ -3933,6 +3935,8 @@ if typing.TYPE_CHECKING: from .management_client import AsyncManagementClient, CustomDomainHeader, ManagementClient from .token_provider import AsyncTokenProvider, TokenProvider from .version import __version__ @@ -43192,7 +43480,7 @@ patches: _dynamic_imports: typing.Dict[str, str] = { "Action": ".types", "ActionBase": ".types", - @@ -4963,6 +4967,7 @@ _dynamic_imports: typing.Dict[str, str] = { + @@ -5023,6 +5027,7 @@ _dynamic_imports: typing.Dict[str, str] = { "CspReportingEndpoints": ".types", "CspReportingInfrastructure": ".types", "CustomDomain": ".types", @@ -43200,7 +43488,7 @@ patches: "CustomDomainCustomClientIpHeader": ".types", "CustomDomainCustomClientIpHeaderEnum": ".types", "CustomDomainHeader": ".management_client", - @@ -6382,6 +6387,8 @@ _dynamic_imports: typing.Dict[str, str] = { + @@ -6453,6 +6458,8 @@ _dynamic_imports: typing.Dict[str, str] = { "FedCmLoginGoogle": ".types", "FedCmLoginGooglePatch": ".types", "FedCmLoginPatch": ".types", @@ -43209,7 +43497,7 @@ patches: "FlowAction": ".types", "FlowActionActivecampaign": ".types", "FlowActionActivecampaignListContacts": ".types", - @@ -8867,6 +8874,7 @@ __all__ = [ + @@ -8974,6 +8981,7 @@ __all__ = [ "CspReportingEndpoints", "CspReportingInfrastructure", "CustomDomain", @@ -43217,7 +43505,7 @@ patches: "CustomDomainCustomClientIpHeader", "CustomDomainCustomClientIpHeaderEnum", "CustomDomainHeader", - @@ -10286,6 +10294,8 @@ __all__ = [ + @@ -10404,6 +10412,8 @@ __all__ = [ "FedCmLoginGoogle", "FedCmLoginGooglePatch", "FedCmLoginPatch", @@ -43293,6 +43581,9 @@ patches: AdvanceRampResponseContent, AgentMetadata, AgentResponseContent, + AllocationItem, + AllocationRequestItem, + AllocationStrategyEnum, AnomalyIpFormat, AnonymousSessions, AppMetadata, @@ -43313,6 +43604,7 @@ patches: AttackProtectionUpdateCaptchaHcaptcha, AttackProtectionUpdateCaptchaRecaptchaEnterprise, AttackProtectionUpdateCaptchaRecaptchaV2, + AuthenticationFlowEnum, AuthenticationMethodTypeEnum, AuthenticationTypeEnum, B2BIntegrationConfiguration, @@ -43460,6 +43752,8 @@ patches: ClientOidcBackchannelLogoutInitiatorsModeEnum, ClientOidcBackchannelLogoutSessionMetadata, ClientOidcBackchannelLogoutSettings, + ClientOidcSupportAllowedScopesEnum, + ClientOidcSupportPost, ClientOrganizationDiscoveryEnum, ClientOrganizationRequireBehaviorEnum, ClientOrganizationRequireBehaviorPatchEnum, @@ -43573,7 +43867,6 @@ patches: ConnectionDebugSaml, ConnectionDecryptionKeySaml, ConnectionDecryptionKeySamlCert, - ConnectionDeletionBehaviorEnum, ConnectionDestinationUrlSaml, ConnectionDigestAlgorithmEnumSaml, ConnectionDigestAlgorithmSaml, @@ -43984,6 +44277,9 @@ patches: ConnectionThumbprints, ConnectionThumbprintsAd, ConnectionThumbprintsSaml, + ConnectionThumbprintsSha384, + ConnectionThumbprintsSha384Ad, + ConnectionThumbprintsSha384Saml, ConnectionTokenEndpoint, ConnectionTokenEndpointAuthMethodEnum, ConnectionTokenEndpointAuthMethodsSupported, @@ -44166,8 +44462,11 @@ patches: CreateEventStreamResponseContent, CreateEventStreamTestEventResponseContent, CreateEventStreamWebHookRequestContent, + CreateExperimentResponseContent, CreateExportUsersFields, CreateExportUsersResponseContent, + CreateFeatureFlagParameters, + CreateFeatureFlagResponseContent, CreateFlowResponseContent, CreateFlowsVaultConnectionActivecampaign, CreateFlowsVaultConnectionActivecampaignApiKey, @@ -44276,6 +44575,7 @@ patches: CreateScimConfigurationRequestContent, CreateScimConfigurationResponseContent, CreateScimTokenResponseContent, + CreateSegmentResponseContent, CreateSelfServiceProfileResponseContent, CreateSelfServiceProfileSsoTicketResponseContent, CreateTokenExchangeProfileResponseContent, @@ -44283,6 +44583,7 @@ patches: CreateUserAttributeProfileResponseContent, CreateUserAuthenticationMethodResponseContent, CreateUserResponseContent, + CreateVariationResponseContent, CreateVerifiableCredentialTemplateResponseContent, CreateVerificationEmailResponseContent, CreatedAuthenticationMethodTypeEnum, @@ -44322,6 +44623,7 @@ patches: CustomSigningKeyTypeEnum, CustomSigningKeyUseEnum, DailyStats, + DefaultConfigEnum, DefaultMethodEmailIdentifierEnum, DefaultMethodPhoneNumberIdentifierEnum, DefaultTokenQuota, @@ -45713,9 +46015,19 @@ patches: EventStreamWebhookDestination, EventStreamWebhookDestinationTypeEnum, EventStreamWebhookResponseContent, + ExperimentListItem, + ExperimentStatusEnum, + ExperimentTransitionStatusEnum, + ExperimentValidationError, ExpressConfiguration, ExpressConfigurationOrNull, ExtensibilityEmailProviderCredentials, + FeatureFlag, + FeatureFlagConfigParam, + FeatureFlagConfigParamTypeEnum, + FeatureFlagConfigParams, + FeatureFlagStatusEnum, + FeatureFlagTypeEnum, FedCmLogin, FedCmLoginGoogle, FedCmLoginGooglePatch, @@ -46320,6 +46632,8 @@ patches: GetEncryptionKeyResponseContent, GetEventStreamDeliveryHistoryResponseContent, GetEventStreamResponseContent, + GetExperimentResponseContent, + GetFeatureFlagResponseContent, GetFlowExecutionRequestParametersHydrateEnum, GetFlowExecutionResponseContent, GetFlowRequestParametersHydrateEnum, @@ -46375,6 +46689,7 @@ patches: GetScimConfigurationDefaultMappingResponseContent, GetScimConfigurationResponseContent, GetScimTokensResponseContent, + GetSegmentResponseContent, GetSelfServiceProfileResponseContent, GetSessionResponseContent, GetSettingsResponseContent, @@ -46390,6 +46705,7 @@ patches: GetUserAuthenticationMethodResponseContent, GetUserGroupsPaginatedResponseContent, GetUserResponseContent, + GetVariationResponseContent, GetVerifiableCredentialTemplateResponseContent, Group, GroupMember, @@ -46443,6 +46759,8 @@ patches: ListEncryptionKeyOffsetPaginatedResponseContent, ListEventStreamDeliveriesResponseContent, ListEventStreamsResponseContent, + ListExperimentsResponseContent, + ListFeatureFlagsResponseContent, ListFlowExecutionsPaginatedResponseContent, ListFlowsOffsetPaginatedResponseContent, ListFlowsRequestParametersHydrateEnum, @@ -46479,6 +46797,7 @@ patches: ListRolesOffsetPaginatedResponseContent, ListRulesOffsetPaginatedResponseContent, ListScimConfigurationsResponseContent, + ListSegmentsResponseContent, ListSelfServiceProfileCustomTextResponseContent, ListSelfServiceProfilesPaginatedResponseContent, ListSynchronizedGroupsResponseContent, @@ -46499,6 +46818,7 @@ patches: ListUserRolesOffsetPaginatedResponseContent, ListUserSessionsPaginatedResponseContent, ListUsersOffsetPaginatedResponseContent, + ListVariationsResponseContent, ListVerifiableCredentialTemplatesPaginatedResponseContent, Log, LogDate, @@ -46596,7 +46916,6 @@ patches: OrganizationClientMetadataOrganizationUsageEnum, OrganizationConnection, OrganizationConnectionInformation, - OrganizationDeletionBehaviorEnum, OrganizationDiscoveryDomain, OrganizationDiscoveryDomainStatus, OrganizationEnabledConnection, @@ -46611,12 +46930,6 @@ patches: OrganizationMemberRole, OrganizationMetadata, OrganizationSortFieldEnum, - OrganizationTemplate, - OrganizationTemplateAllowedStrategyEnum, - OrganizationTemplateRoleVisibilityEnum, - OrganizationTemplateRoleVisibilityOverride, - OrganizationTemplateRoleVisibilityPolicy, - OrganizationTemplateUseForOrganizationDiscovery, OrganizationThirdPartyClientAccessEnum, OrganizationUsageEnum, PartialGroupsEnum, @@ -46737,6 +47050,17 @@ patches: SearchOrganizationsPaginatedResponseContent, SearchParserEnum, SearchResourceServersResponseContent, + Segment, + SegmentContainsExpression, + SegmentEndsWithExpression, + SegmentExistsExpression, + SegmentMatchConditions, + SegmentMatchExpression, + SegmentNotMatchConditions, + SegmentRule, + SegmentStartsWithExpression, + SegmentTypeEnum, + SegmentTypeFilterEnum, SelfServiceProfile, SelfServiceProfileAllowedStrategyEnum, SelfServiceProfileBranding, @@ -46948,6 +47272,11 @@ patches: UpdateEnabledClientConnectionsRequestContent, UpdateEnabledClientConnectionsRequestContentItem, UpdateEventStreamResponseContent, + UpdateExperimentResponseContent, + UpdateExperimentStatusResponseContent, + UpdateFeatureFlagParameters, + UpdateFeatureFlagResponseContent, + UpdateFeatureFlagStatusResponseContent, UpdateFlowResponseContent, UpdateFlowsVaultConnectionResponseContent, UpdateFlowsVaultConnectionSetup, @@ -46976,6 +47305,7 @@ patches: UpdateRoleResponseContent, UpdateRuleResponseContent, UpdateScimConfigurationResponseContent, + UpdateSegmentResponseContent, UpdateSelfServiceProfileResponseContent, UpdateSessionResponseContent, UpdateSettingsResponseContent, @@ -46987,6 +47317,8 @@ patches: UpdateUserAttributeProfileResponseContent, UpdateUserAuthenticationMethodResponseContent, UpdateUserResponseContent, + UpdateVariationOverridesMap, + UpdateVariationResponseContent, UpdateVerifiableCredentialTemplateResponseContent, UserAppMetadataSchema, UserAttributeProfile, @@ -47037,6 +47369,9 @@ patches: UsernameAttributeIdentifier, UsernameValidation, UsersEnrollment, + ValidateExperimentResponseContent, + Variation, + VariationOverridesMap, VerifiableCredentialTemplateResponse, VerificationMethodEnum, VerifyCustomDomainResponseContent, @@ -47177,6 +47512,9 @@ patches: "AdvanceRampResponseContent": ".types", "AgentMetadata": ".types", "AgentResponseContent": ".types", + "AllocationItem": ".types", + "AllocationRequestItem": ".types", + "AllocationStrategyEnum": ".types", "AnomalyIpFormat": ".types", "AnonymousSessions": ".types", "AppMetadata": ".types", @@ -47202,6 +47540,7 @@ patches: "AttackProtectionUpdateCaptchaRecaptchaV2": ".types", "Auth0": ".client", "Auth0Environment": ".environment", + "AuthenticationFlowEnum": ".types", "AuthenticationMethodTypeEnum": ".types", "AuthenticationTypeEnum": ".types", "B2BIntegrationConfiguration": ".types", @@ -47350,6 +47689,8 @@ patches: "ClientOidcBackchannelLogoutInitiatorsModeEnum": ".types", "ClientOidcBackchannelLogoutSessionMetadata": ".types", "ClientOidcBackchannelLogoutSettings": ".types", + "ClientOidcSupportAllowedScopesEnum": ".types", + "ClientOidcSupportPost": ".types", "ClientOrganizationDiscoveryEnum": ".types", "ClientOrganizationRequireBehaviorEnum": ".types", "ClientOrganizationRequireBehaviorPatchEnum": ".types", @@ -47464,7 +47805,6 @@ patches: "ConnectionDebugSaml": ".types", "ConnectionDecryptionKeySaml": ".types", "ConnectionDecryptionKeySamlCert": ".types", - "ConnectionDeletionBehaviorEnum": ".types", "ConnectionDestinationUrlSaml": ".types", "ConnectionDigestAlgorithmEnumSaml": ".types", "ConnectionDigestAlgorithmSaml": ".types", @@ -47875,6 +48215,9 @@ patches: "ConnectionThumbprints": ".types", "ConnectionThumbprintsAd": ".types", "ConnectionThumbprintsSaml": ".types", + "ConnectionThumbprintsSha384": ".types", + "ConnectionThumbprintsSha384Ad": ".types", + "ConnectionThumbprintsSha384Saml": ".types", "ConnectionTokenEndpoint": ".types", "ConnectionTokenEndpointAuthMethodEnum": ".types", "ConnectionTokenEndpointAuthMethodsSupported": ".types", @@ -48058,8 +48401,11 @@ patches: "CreateEventStreamResponseContent": ".types", "CreateEventStreamTestEventResponseContent": ".types", "CreateEventStreamWebHookRequestContent": ".types", + "CreateExperimentResponseContent": ".types", "CreateExportUsersFields": ".types", "CreateExportUsersResponseContent": ".types", + "CreateFeatureFlagParameters": ".types", + "CreateFeatureFlagResponseContent": ".types", "CreateFlowResponseContent": ".types", "CreateFlowsVaultConnectionActivecampaign": ".types", "CreateFlowsVaultConnectionActivecampaignApiKey": ".types", @@ -48168,6 +48514,7 @@ patches: "CreateScimConfigurationRequestContent": ".types", "CreateScimConfigurationResponseContent": ".types", "CreateScimTokenResponseContent": ".types", + "CreateSegmentResponseContent": ".types", "CreateSelfServiceProfileResponseContent": ".types", "CreateSelfServiceProfileSsoTicketResponseContent": ".types", "CreateTokenExchangeProfileResponseContent": ".types", @@ -48175,6 +48522,7 @@ patches: "CreateUserAttributeProfileResponseContent": ".types", "CreateUserAuthenticationMethodResponseContent": ".types", "CreateUserResponseContent": ".types", + "CreateVariationResponseContent": ".types", "CreateVerifiableCredentialTemplateResponseContent": ".types", "CreateVerificationEmailResponseContent": ".types", "CreatedAuthenticationMethodTypeEnum": ".types", @@ -48218,6 +48566,7 @@ patches: "DailyStats": ".types", "DefaultAioHttpClient": "._default_clients", "DefaultAsyncHttpxClient": "._default_clients", + "DefaultConfigEnum": ".types", "DefaultMethodEmailIdentifierEnum": ".types", "DefaultMethodPhoneNumberIdentifierEnum": ".types", "DefaultTokenQuota": ".types", @@ -49610,9 +49959,19 @@ patches: "EventStreamWebhookDestinationTypeEnum": ".types", "EventStreamWebhookResponseContent": ".types", "EventStreamsCreateRequest": ".event_streams", + "ExperimentListItem": ".types", + "ExperimentStatusEnum": ".types", + "ExperimentTransitionStatusEnum": ".types", + "ExperimentValidationError": ".types", "ExpressConfiguration": ".types", "ExpressConfigurationOrNull": ".types", "ExtensibilityEmailProviderCredentials": ".types", + "FeatureFlag": ".types", + "FeatureFlagConfigParam": ".types", + "FeatureFlagConfigParamTypeEnum": ".types", + "FeatureFlagConfigParams": ".types", + "FeatureFlagStatusEnum": ".types", + "FeatureFlagTypeEnum": ".types", "FedCmLogin": ".types", "FedCmLoginGoogle": ".types", "FedCmLoginGooglePatch": ".types", @@ -50219,6 +50578,8 @@ patches: "GetEncryptionKeyResponseContent": ".types", "GetEventStreamDeliveryHistoryResponseContent": ".types", "GetEventStreamResponseContent": ".types", + "GetExperimentResponseContent": ".types", + "GetFeatureFlagResponseContent": ".types", "GetFlowExecutionRequestParametersHydrateEnum": ".types", "GetFlowExecutionResponseContent": ".types", "GetFlowRequestParametersHydrateEnum": ".types", @@ -50274,6 +50635,7 @@ patches: "GetScimConfigurationDefaultMappingResponseContent": ".types", "GetScimConfigurationResponseContent": ".types", "GetScimTokensResponseContent": ".types", + "GetSegmentResponseContent": ".types", "GetSelfServiceProfileResponseContent": ".types", "GetSessionResponseContent": ".types", "GetSettingsResponseContent": ".types", @@ -50289,6 +50651,7 @@ patches: "GetUserAuthenticationMethodResponseContent": ".types", "GetUserGroupsPaginatedResponseContent": ".types", "GetUserResponseContent": ".types", + "GetVariationResponseContent": ".types", "GetVerifiableCredentialTemplateResponseContent": ".types", "GoneError": ".errors", "Group": ".types", @@ -50344,6 +50707,8 @@ patches: "ListEncryptionKeyOffsetPaginatedResponseContent": ".types", "ListEventStreamDeliveriesResponseContent": ".types", "ListEventStreamsResponseContent": ".types", + "ListExperimentsResponseContent": ".types", + "ListFeatureFlagsResponseContent": ".types", "ListFlowExecutionsPaginatedResponseContent": ".types", "ListFlowsOffsetPaginatedResponseContent": ".types", "ListFlowsRequestParametersHydrateEnum": ".types", @@ -50380,6 +50745,7 @@ patches: "ListRolesOffsetPaginatedResponseContent": ".types", "ListRulesOffsetPaginatedResponseContent": ".types", "ListScimConfigurationsResponseContent": ".types", + "ListSegmentsResponseContent": ".types", "ListSelfServiceProfileCustomTextResponseContent": ".types", "ListSelfServiceProfilesPaginatedResponseContent": ".types", "ListSynchronizedGroupsResponseContent": ".types", @@ -50400,6 +50766,7 @@ patches: "ListUserRolesOffsetPaginatedResponseContent": ".types", "ListUserSessionsPaginatedResponseContent": ".types", "ListUsersOffsetPaginatedResponseContent": ".types", + "ListVariationsResponseContent": ".types", "ListVerifiableCredentialTemplatesPaginatedResponseContent": ".types", "Log": ".types", "LogDate": ".types", @@ -50499,7 +50866,6 @@ patches: "OrganizationClientMetadataOrganizationUsageEnum": ".types", "OrganizationConnection": ".types", "OrganizationConnectionInformation": ".types", - "OrganizationDeletionBehaviorEnum": ".types", "OrganizationDiscoveryDomain": ".types", "OrganizationDiscoveryDomainStatus": ".types", "OrganizationEnabledConnection": ".types", @@ -50514,12 +50880,6 @@ patches: "OrganizationMemberRole": ".types", "OrganizationMetadata": ".types", "OrganizationSortFieldEnum": ".types", - "OrganizationTemplate": ".types", - "OrganizationTemplateAllowedStrategyEnum": ".types", - "OrganizationTemplateRoleVisibilityEnum": ".types", - "OrganizationTemplateRoleVisibilityOverride": ".types", - "OrganizationTemplateRoleVisibilityPolicy": ".types", - "OrganizationTemplateUseForOrganizationDiscovery": ".types", "OrganizationThirdPartyClientAccessEnum": ".types", "OrganizationUsageEnum": ".types", "PartialGroupsEnum": ".types", @@ -50642,6 +51002,17 @@ patches: "SearchOrganizationsPaginatedResponseContent": ".types", "SearchParserEnum": ".types", "SearchResourceServersResponseContent": ".types", + "Segment": ".types", + "SegmentContainsExpression": ".types", + "SegmentEndsWithExpression": ".types", + "SegmentExistsExpression": ".types", + "SegmentMatchConditions": ".types", + "SegmentMatchExpression": ".types", + "SegmentNotMatchConditions": ".types", + "SegmentRule": ".types", + "SegmentStartsWithExpression": ".types", + "SegmentTypeEnum": ".types", + "SegmentTypeFilterEnum": ".types", "SelfServiceProfile": ".types", "SelfServiceProfileAllowedStrategyEnum": ".types", "SelfServiceProfileBranding": ".types", @@ -50858,6 +51229,11 @@ patches: "UpdateEnabledClientConnectionsRequestContent": ".types", "UpdateEnabledClientConnectionsRequestContentItem": ".types", "UpdateEventStreamResponseContent": ".types", + "UpdateExperimentResponseContent": ".types", + "UpdateExperimentStatusResponseContent": ".types", + "UpdateFeatureFlagParameters": ".types", + "UpdateFeatureFlagResponseContent": ".types", + "UpdateFeatureFlagStatusResponseContent": ".types", "UpdateFlowResponseContent": ".types", "UpdateFlowsVaultConnectionResponseContent": ".types", "UpdateFlowsVaultConnectionSetup": ".types", @@ -50886,6 +51262,7 @@ patches: "UpdateRoleResponseContent": ".types", "UpdateRuleResponseContent": ".types", "UpdateScimConfigurationResponseContent": ".types", + "UpdateSegmentResponseContent": ".types", "UpdateSelfServiceProfileResponseContent": ".types", "UpdateSessionResponseContent": ".types", "UpdateSettingsResponseContent": ".types", @@ -50897,6 +51274,8 @@ patches: "UpdateUserAttributeProfileResponseContent": ".types", "UpdateUserAuthenticationMethodResponseContent": ".types", "UpdateUserResponseContent": ".types", + "UpdateVariationOverridesMap": ".types", + "UpdateVariationResponseContent": ".types", "UpdateVerifiableCredentialTemplateResponseContent": ".types", "UserAppMetadataSchema": ".types", "UserAttributeProfile": ".types", @@ -50947,6 +51326,9 @@ patches: "UsernameAttributeIdentifier": ".types", "UsernameValidation": ".types", "UsersEnrollment": ".types", + "ValidateExperimentResponseContent": ".types", + "Variation": ".types", + "VariationOverridesMap": ".types", "VerifiableCredentialTemplateResponse": ".types", "VerificationMethodEnum": ".types", "VerifyCustomDomainResponseContent": ".types", @@ -51084,6 +51466,9 @@ patches: "AdvanceRampResponseContent", "AgentMetadata", "AgentResponseContent", + "AllocationItem", + "AllocationRequestItem", + "AllocationStrategyEnum", "AnomalyIpFormat", "AnonymousSessions", "AppMetadata", @@ -51109,6 +51494,7 @@ patches: "AttackProtectionUpdateCaptchaRecaptchaV2", "Auth0", "Auth0Environment", + "AuthenticationFlowEnum", "AuthenticationMethodTypeEnum", "AuthenticationTypeEnum", "B2BIntegrationConfiguration", @@ -51257,6 +51643,8 @@ patches: "ClientOidcBackchannelLogoutInitiatorsModeEnum", "ClientOidcBackchannelLogoutSessionMetadata", "ClientOidcBackchannelLogoutSettings", + "ClientOidcSupportAllowedScopesEnum", + "ClientOidcSupportPost", "ClientOrganizationDiscoveryEnum", "ClientOrganizationRequireBehaviorEnum", "ClientOrganizationRequireBehaviorPatchEnum", @@ -51371,7 +51759,6 @@ patches: "ConnectionDebugSaml", "ConnectionDecryptionKeySaml", "ConnectionDecryptionKeySamlCert", - "ConnectionDeletionBehaviorEnum", "ConnectionDestinationUrlSaml", "ConnectionDigestAlgorithmEnumSaml", "ConnectionDigestAlgorithmSaml", @@ -51782,6 +52169,9 @@ patches: "ConnectionThumbprints", "ConnectionThumbprintsAd", "ConnectionThumbprintsSaml", + "ConnectionThumbprintsSha384", + "ConnectionThumbprintsSha384Ad", + "ConnectionThumbprintsSha384Saml", "ConnectionTokenEndpoint", "ConnectionTokenEndpointAuthMethodEnum", "ConnectionTokenEndpointAuthMethodsSupported", @@ -51965,8 +52355,11 @@ patches: "CreateEventStreamResponseContent", "CreateEventStreamTestEventResponseContent", "CreateEventStreamWebHookRequestContent", + "CreateExperimentResponseContent", "CreateExportUsersFields", "CreateExportUsersResponseContent", + "CreateFeatureFlagParameters", + "CreateFeatureFlagResponseContent", "CreateFlowResponseContent", "CreateFlowsVaultConnectionActivecampaign", "CreateFlowsVaultConnectionActivecampaignApiKey", @@ -52075,6 +52468,7 @@ patches: "CreateScimConfigurationRequestContent", "CreateScimConfigurationResponseContent", "CreateScimTokenResponseContent", + "CreateSegmentResponseContent", "CreateSelfServiceProfileResponseContent", "CreateSelfServiceProfileSsoTicketResponseContent", "CreateTokenExchangeProfileResponseContent", @@ -52082,6 +52476,7 @@ patches: "CreateUserAttributeProfileResponseContent", "CreateUserAuthenticationMethodResponseContent", "CreateUserResponseContent", + "CreateVariationResponseContent", "CreateVerifiableCredentialTemplateResponseContent", "CreateVerificationEmailResponseContent", "CreatedAuthenticationMethodTypeEnum", @@ -52125,6 +52520,7 @@ patches: "DailyStats", "DefaultAioHttpClient", "DefaultAsyncHttpxClient", + "DefaultConfigEnum", "DefaultMethodEmailIdentifierEnum", "DefaultMethodPhoneNumberIdentifierEnum", "DefaultTokenQuota", @@ -53517,9 +53913,19 @@ patches: "EventStreamWebhookDestinationTypeEnum", "EventStreamWebhookResponseContent", "EventStreamsCreateRequest", + "ExperimentListItem", + "ExperimentStatusEnum", + "ExperimentTransitionStatusEnum", + "ExperimentValidationError", "ExpressConfiguration", "ExpressConfigurationOrNull", "ExtensibilityEmailProviderCredentials", + "FeatureFlag", + "FeatureFlagConfigParam", + "FeatureFlagConfigParamTypeEnum", + "FeatureFlagConfigParams", + "FeatureFlagStatusEnum", + "FeatureFlagTypeEnum", "FedCmLogin", "FedCmLoginGoogle", "FedCmLoginGooglePatch", @@ -54126,6 +54532,8 @@ patches: "GetEncryptionKeyResponseContent", "GetEventStreamDeliveryHistoryResponseContent", "GetEventStreamResponseContent", + "GetExperimentResponseContent", + "GetFeatureFlagResponseContent", "GetFlowExecutionRequestParametersHydrateEnum", "GetFlowExecutionResponseContent", "GetFlowRequestParametersHydrateEnum", @@ -54181,6 +54589,7 @@ patches: "GetScimConfigurationDefaultMappingResponseContent", "GetScimConfigurationResponseContent", "GetScimTokensResponseContent", + "GetSegmentResponseContent", "GetSelfServiceProfileResponseContent", "GetSessionResponseContent", "GetSettingsResponseContent", @@ -54196,6 +54605,7 @@ patches: "GetUserAuthenticationMethodResponseContent", "GetUserGroupsPaginatedResponseContent", "GetUserResponseContent", + "GetVariationResponseContent", "GetVerifiableCredentialTemplateResponseContent", "GoneError", "Group", @@ -54251,6 +54661,8 @@ patches: "ListEncryptionKeyOffsetPaginatedResponseContent", "ListEventStreamDeliveriesResponseContent", "ListEventStreamsResponseContent", + "ListExperimentsResponseContent", + "ListFeatureFlagsResponseContent", "ListFlowExecutionsPaginatedResponseContent", "ListFlowsOffsetPaginatedResponseContent", "ListFlowsRequestParametersHydrateEnum", @@ -54287,6 +54699,7 @@ patches: "ListRolesOffsetPaginatedResponseContent", "ListRulesOffsetPaginatedResponseContent", "ListScimConfigurationsResponseContent", + "ListSegmentsResponseContent", "ListSelfServiceProfileCustomTextResponseContent", "ListSelfServiceProfilesPaginatedResponseContent", "ListSynchronizedGroupsResponseContent", @@ -54307,6 +54720,7 @@ patches: "ListUserRolesOffsetPaginatedResponseContent", "ListUserSessionsPaginatedResponseContent", "ListUsersOffsetPaginatedResponseContent", + "ListVariationsResponseContent", "ListVerifiableCredentialTemplatesPaginatedResponseContent", "Log", "LogDate", @@ -54406,7 +54820,6 @@ patches: "OrganizationClientMetadataOrganizationUsageEnum", "OrganizationConnection", "OrganizationConnectionInformation", - "OrganizationDeletionBehaviorEnum", "OrganizationDiscoveryDomain", "OrganizationDiscoveryDomainStatus", "OrganizationEnabledConnection", @@ -54421,12 +54834,6 @@ patches: "OrganizationMemberRole", "OrganizationMetadata", "OrganizationSortFieldEnum", - "OrganizationTemplate", - "OrganizationTemplateAllowedStrategyEnum", - "OrganizationTemplateRoleVisibilityEnum", - "OrganizationTemplateRoleVisibilityOverride", - "OrganizationTemplateRoleVisibilityPolicy", - "OrganizationTemplateUseForOrganizationDiscovery", "OrganizationThirdPartyClientAccessEnum", "OrganizationUsageEnum", "PartialGroupsEnum", @@ -54549,6 +54956,17 @@ patches: "SearchOrganizationsPaginatedResponseContent", "SearchParserEnum", "SearchResourceServersResponseContent", + "Segment", + "SegmentContainsExpression", + "SegmentEndsWithExpression", + "SegmentExistsExpression", + "SegmentMatchConditions", + "SegmentMatchExpression", + "SegmentNotMatchConditions", + "SegmentRule", + "SegmentStartsWithExpression", + "SegmentTypeEnum", + "SegmentTypeFilterEnum", "SelfServiceProfile", "SelfServiceProfileAllowedStrategyEnum", "SelfServiceProfileBranding", @@ -54765,6 +55183,11 @@ patches: "UpdateEnabledClientConnectionsRequestContent", "UpdateEnabledClientConnectionsRequestContentItem", "UpdateEventStreamResponseContent", + "UpdateExperimentResponseContent", + "UpdateExperimentStatusResponseContent", + "UpdateFeatureFlagParameters", + "UpdateFeatureFlagResponseContent", + "UpdateFeatureFlagStatusResponseContent", "UpdateFlowResponseContent", "UpdateFlowsVaultConnectionResponseContent", "UpdateFlowsVaultConnectionSetup", @@ -54793,6 +55216,7 @@ patches: "UpdateRoleResponseContent", "UpdateRuleResponseContent", "UpdateScimConfigurationResponseContent", + "UpdateSegmentResponseContent", "UpdateSelfServiceProfileResponseContent", "UpdateSessionResponseContent", "UpdateSettingsResponseContent", @@ -54804,6 +55228,8 @@ patches: "UpdateUserAttributeProfileResponseContent", "UpdateUserAuthenticationMethodResponseContent", "UpdateUserResponseContent", + "UpdateVariationOverridesMap", + "UpdateVariationResponseContent", "UpdateVerifiableCredentialTemplateResponseContent", "UserAppMetadataSchema", "UserAttributeProfile", @@ -54854,6 +55280,9 @@ patches: "UsernameAttributeIdentifier", "UsernameValidation", "UsersEnrollment", + "ValidateExperimentResponseContent", + "Variation", + "VariationOverridesMap", "VerifiableCredentialTemplateResponse", "VerificationMethodEnum", "VerifyCustomDomainResponseContent", diff --git a/UPGRADING.md b/UPGRADING.md new file mode 100644 index 00000000..ed653dbf --- /dev/null +++ b/UPGRADING.md @@ -0,0 +1,157 @@ +# v6 Migration Guide + +A guide to migrating the Auth0 Python SDK from v5 to v6. + +- [Overall changes](#overall-changes) +- [Breaking changes](#breaking-changes) + - [Federated connections tokensets removed](#federated-connections-tokensets-removed) + - [`federated_connections_access_tokens` field removed](#federated_connections_access_tokens-field-removed) + - [`read:federated_connections_tokens` / `delete:federated_connections_tokens` scopes removed](#readfederated_connections_tokens--deletefederated_connections_tokens-scopes-removed) + - [`ClientSessionTransferDelegationDeviceBindingEnum` narrowed](#clientsessiontransferdelegationdevicebindingenum-narrowed) + - [`ConnectionAttributeIdentifier` split into three types](#connectionattributeidentifier-split-into-three-types) + - [`PhoneProviderProtectionBackoffStrategyEnum` value renamed](#phoneproviderprotectionbackoffstrategyenum-value-renamed) + - [`ListRolesOffsetPaginatedResponseContent` pagination fields now required](#listrolesoffsetpaginatedresponsecontent-pagination-fields-now-required) + +## Overall changes + +v6 removes one deprecated Management API surface (federated connections +tokensets) and tightens a handful of generated types to match the current +Auth0 Management API contract. Most applications will only be affected if +they use the specific types or endpoints listed below. + +The Authentication API is not affected by this release. + +## Breaking changes + +### Federated connections tokensets removed + +The `users.federated_connections_tokensets` sub-client and its `list`/`delete` +methods have been removed, along with the `FederatedConnectionTokenSet` and +`ConnectionFederatedConnectionsAccessTokens` types. This endpoint is no longer +part of the Auth0 Management API. + +```python +# v5 +client.users.federated_connections_tokensets.list(id="user_id") +client.users.federated_connections_tokensets.delete(id="user_id", tokenset_id="tokenset_id") +``` + +```python +# v6 +# No replacement — the endpoint has been removed from the Management API. +``` + +If you depend on this functionality, do not upgrade until you have confirmed +an alternative with Auth0 support. + +### `federated_connections_access_tokens` field removed + +The optional `federated_connections_access_tokens` field has been removed +from: + +- `ConnectionOptionsAzureAd` +- `ConnectionOptionsCommonOidc` +- `ConnectionOptionsGoogleApps` +- `ConnectionPropertiesOptions` +- `UpdateConnectionOptions` + +Any code reading or setting this field on the above types will need to +remove that usage. Note that these models are configured with +`extra="allow"`, so passing `federated_connections_access_tokens` is **not** +silently dropped — it is retained on the model and still serialized into the +outbound request. Remove the field explicitly rather than relying on the SDK +to strip it. + +### `read:federated_connections_tokens` / `delete:federated_connections_tokens` scopes removed + +These two values are no longer valid members of `OauthScope`. Remove any +references to them when requesting or checking scopes. + +### `ClientSessionTransferDelegationDeviceBindingEnum` narrowed + +The `"asn"` literal value has been removed. The enum now only accepts `"ip"`: + +```python +# v5 +ClientSessionTransferDelegationDeviceBindingEnum = typing.Union[typing.Literal["ip", "asn"], typing.Any] +``` + +```python +# v6 +ClientSessionTransferDelegationDeviceBindingEnum = typing.Union[typing.Literal["ip"], typing.Any] +``` + +If you were setting this value to `"asn"`, update it to `"ip"` — this matches +the current Management API's accepted values. + +### `ConnectionAttributeIdentifier` split into three types + +`ConnectionAttributeIdentifier` has been removed with no compatibility alias. +It is replaced by three narrower types, one per attribute: + +| Attribute field | v5 type | v6 type | Shape | +| --- | --- | --- | --- | +| `EmailAttribute.identifier` | `ConnectionAttributeIdentifier` | `EmailAttributeIdentifier` | `{active?, default_method?: DefaultMethodEmailIdentifierEnum}` | +| `PhoneAttribute.identifier` | `ConnectionAttributeIdentifier` | `PhoneAttributeIdentifier` | `{active?, default_method?: DefaultMethodPhoneNumberIdentifierEnum}` | +| `UsernameAttribute.identifier` | `ConnectionAttributeIdentifier` | `UsernameAttributeIdentifier` | `{active?}` (no `default_method`) | + +```python +# v5 +from auth0.management.types import ConnectionAttributeIdentifier + +identifier = ConnectionAttributeIdentifier(active=True, default_method="email_otp") +``` + +```python +# v6 +from auth0.management.types import EmailAttributeIdentifier + +identifier = EmailAttributeIdentifier(active=True, default_method="email_otp") +``` + +`EmailAttributeIdentifier` has the same shape as the old +`ConnectionAttributeIdentifier` and is a drop-in replacement for code that +was only ever used with `EmailAttribute`. Code using +`ConnectionAttributeIdentifier` with `PhoneAttribute` or `UsernameAttribute` +must switch to `PhoneAttributeIdentifier` or `UsernameAttributeIdentifier` +respectively; `UsernameAttributeIdentifier` does not support +`default_method`. + +### `PhoneProviderProtectionBackoffStrategyEnum` value renamed + +The `"none"` literal has been replaced with `"default"`: + +```python +# v5 +PhoneProviderProtectionBackoffStrategyEnum = typing.Union[typing.Literal["exponential", "none"], typing.Any] +``` + +```python +# v6 +PhoneProviderProtectionBackoffStrategyEnum = typing.Union[typing.Literal["exponential", "default"], typing.Any] +``` + +Replace any use of `"none"` with `"default"`. + +### `ListRolesOffsetPaginatedResponseContent` pagination fields now required + +`start`, `limit`, and `total` are no longer optional: + +```python +# v5 +start: typing.Optional[float] = None +limit: typing.Optional[float] = None +total: typing.Optional[float] = None +``` + +```python +# v6 +start: float +limit: float +total: float +``` + +Deserializing a role-list response that is missing any of these fields now +raises `pydantic.ValidationError` instead of silently defaulting to `None`. +This matches the Management API, which always returns these fields for this +endpoint. diff --git a/src/auth0/management/__init__.py b/src/auth0/management/__init__.py index f12b793f..56930e08 100644 --- a/src/auth0/management/__init__.py +++ b/src/auth0/management/__init__.py @@ -2514,6 +2514,8 @@ FedCmLoginGoogle, FedCmLoginGooglePatch, FedCmLoginPatch, + FedCmLoginGooglePatch, + FedCmLoginPatch, FlowAction, FlowActionActivecampaign, FlowActionActivecampaignListContacts, @@ -3933,6 +3935,8 @@ from .management_client import AsyncManagementClient, CustomDomainHeader, ManagementClient from .token_provider import AsyncTokenProvider, TokenProvider from .version import __version__ + from .management_client import AsyncManagementClient, CustomDomainHeader, ManagementClient + from .token_provider import AsyncTokenProvider, TokenProvider _dynamic_imports: typing.Dict[str, str] = { "Action": ".types", "ActionBase": ".types", @@ -5023,6 +5027,7 @@ "CspReportingEndpoints": ".types", "CspReportingInfrastructure": ".types", "CustomDomain": ".types", + "CustomDomainHeader": ".management_client", "CustomDomainCustomClientIpHeader": ".types", "CustomDomainCustomClientIpHeaderEnum": ".types", "CustomDomainHeader": ".management_client", @@ -6453,6 +6458,8 @@ "FedCmLoginGoogle": ".types", "FedCmLoginGooglePatch": ".types", "FedCmLoginPatch": ".types", + "FedCmLoginGooglePatch": ".types", + "FedCmLoginPatch": ".types", "FlowAction": ".types", "FlowActionActivecampaign": ".types", "FlowActionActivecampaignListContacts": ".types", @@ -8974,6 +8981,7 @@ def __dir__(): "CspReportingEndpoints", "CspReportingInfrastructure", "CustomDomain", + "CustomDomainHeader", "CustomDomainCustomClientIpHeader", "CustomDomainCustomClientIpHeaderEnum", "CustomDomainHeader", @@ -10404,6 +10412,8 @@ def __dir__(): "FedCmLoginGoogle", "FedCmLoginGooglePatch", "FedCmLoginPatch", + "FedCmLoginGooglePatch", + "FedCmLoginPatch", "FlowAction", "FlowActionActivecampaign", "FlowActionActivecampaignListContacts", diff --git a/src/auth0/management/core/client_wrapper.py b/src/auth0/management/core/client_wrapper.py index abce2c81..53265612 100644 --- a/src/auth0/management/core/client_wrapper.py +++ b/src/auth0/management/core/client_wrapper.py @@ -1,6 +1,11 @@ # This file was auto-generated by Fern from our API Definition. +# Modified by Auth0 to use Auth0 telemetry format with dynamic versioning +import base64 +import platform +import sys import typing +from json import dumps import httpx from .http_client import AsyncHttpClient, HttpClient From 5ffe003f46f94bed58c8daf67320933bdc228c10 Mon Sep 17 00:00:00 2001 From: Kunal Dawar Date: Wed, 30 Sep 2026 13:53:10 +0530 Subject: [PATCH 3/3] [fern-replay] Resolved conflicts Patches replayed: - patch-4894603d: chore: Restore custom wiring in management/__init__.py - patch-7271f157: Revert wrapper file to preserve Auth0 telemetry customizations - patch-c04f0b4d: Fix for incorrect return type and missing __all__ type - patch-95211006: Restore Auth0 telemetry and custom client wiring after regeneration - patch-f7384913: Remove duplicate FedCmLoginGooglePatch and FedCmLoginPatch entries - patch-1e44613d: Added migration guide for v5 to v6 - patch-30b1089a: Updated UPGRADING.md doc - patch-d6d69aeb: Remove duplicate FedCmLoginGooglePatch and FedCmLoginPatch entries --- .fern/replay.lock | 6 +++--- src/auth0/management/__init__.py | 10 ---------- src/auth0/management/core/client_wrapper.py | 11 +++++++++++ 3 files changed, 14 insertions(+), 13 deletions(-) diff --git a/.fern/replay.lock b/.fern/replay.lock index ee9bb241..07783cab 100644 --- a/.fern/replay.lock +++ b/.fern/replay.lock @@ -8856,7 +8856,7 @@ patches: "verifiable_credentials", ] user_owned: true - status: unresolved + status: resolving - id: patch-7271f157 content_hash: sha256:cd98dd1948587cf3396a2eacf46626176784bd00996eb660374161bfef686e93 original_commit: 7271f15759cfb545c9ef82b5a4f519ffe0a89db2 @@ -9037,7 +9037,7 @@ patches: token = await self._async_token() headers["Authorization"] = f"Bearer {token}" return headers - status: unresolved + status: resolving - id: patch-c04f0b4d content_hash: sha256:b56317f901bea2a9448227a5dcc0bbd6878bc3f01e31ba601803c3ab93c573ef original_commit: c04f0b4dbbe8f2300f4f1bf42f62350888a92da5 @@ -30892,7 +30892,7 @@ patches: headers["Authorization"] = f"Bearer {token}" return headers user_owned: true - status: unresolved + status: resolving - id: patch-f7384913 content_hash: sha256:b56317f901bea2a9448227a5dcc0bbd6878bc3f01e31ba601803c3ab93c573ef original_commit: f7384913ab0a14df83dbc602d2b694e2cb7b7668 diff --git a/src/auth0/management/__init__.py b/src/auth0/management/__init__.py index 56930e08..f12b793f 100644 --- a/src/auth0/management/__init__.py +++ b/src/auth0/management/__init__.py @@ -2514,8 +2514,6 @@ FedCmLoginGoogle, FedCmLoginGooglePatch, FedCmLoginPatch, - FedCmLoginGooglePatch, - FedCmLoginPatch, FlowAction, FlowActionActivecampaign, FlowActionActivecampaignListContacts, @@ -3935,8 +3933,6 @@ from .management_client import AsyncManagementClient, CustomDomainHeader, ManagementClient from .token_provider import AsyncTokenProvider, TokenProvider from .version import __version__ - from .management_client import AsyncManagementClient, CustomDomainHeader, ManagementClient - from .token_provider import AsyncTokenProvider, TokenProvider _dynamic_imports: typing.Dict[str, str] = { "Action": ".types", "ActionBase": ".types", @@ -5027,7 +5023,6 @@ "CspReportingEndpoints": ".types", "CspReportingInfrastructure": ".types", "CustomDomain": ".types", - "CustomDomainHeader": ".management_client", "CustomDomainCustomClientIpHeader": ".types", "CustomDomainCustomClientIpHeaderEnum": ".types", "CustomDomainHeader": ".management_client", @@ -6458,8 +6453,6 @@ "FedCmLoginGoogle": ".types", "FedCmLoginGooglePatch": ".types", "FedCmLoginPatch": ".types", - "FedCmLoginGooglePatch": ".types", - "FedCmLoginPatch": ".types", "FlowAction": ".types", "FlowActionActivecampaign": ".types", "FlowActionActivecampaignListContacts": ".types", @@ -8981,7 +8974,6 @@ def __dir__(): "CspReportingEndpoints", "CspReportingInfrastructure", "CustomDomain", - "CustomDomainHeader", "CustomDomainCustomClientIpHeader", "CustomDomainCustomClientIpHeaderEnum", "CustomDomainHeader", @@ -10412,8 +10404,6 @@ def __dir__(): "FedCmLoginGoogle", "FedCmLoginGooglePatch", "FedCmLoginPatch", - "FedCmLoginGooglePatch", - "FedCmLoginPatch", "FlowAction", "FlowActionActivecampaign", "FlowActionActivecampaignListContacts", diff --git a/src/auth0/management/core/client_wrapper.py b/src/auth0/management/core/client_wrapper.py index 53265612..fd991f52 100644 --- a/src/auth0/management/core/client_wrapper.py +++ b/src/auth0/management/core/client_wrapper.py @@ -35,7 +35,18 @@ def __init__( self._logging = logging def get_headers(self) -> typing.Dict[str, str]: + py_version = platform.python_version() + version = sys.modules["auth0"].__version__ + + auth0_client = dumps({ + "name": "auth0-python", + "version": version, + "env": {"python": py_version} + }).encode("utf-8") + headers: typing.Dict[str, str] = { + "User-Agent": f"Python/{py_version}", + "Auth0-Client": base64.b64encode(auth0_client).decode(), **(self.get_custom_headers() or {}), } headers["Authorization"] = f"Bearer {self._get_token()}"