diff --git a/reference.md b/reference.md index eaa0149e..ee55df7f 100644 --- a/reference.md +++ b/reference.md @@ -3266,7 +3266,7 @@ client.connections().list( OptionalNullable.of(true) ) .strategy( - Arrays.asList(Optional.of(ConnectionStrategyEnum.AD)) + Arrays.asList(ConnectionStrategyEnum.AD) ) .build() ); @@ -5566,9 +5566,7 @@ client.events().subscribe( OptionalNullable.of("from_timestamp") ) .eventType( - OptionalNullable.of( - EventStreamSubscribeEventsEventTypeParam.of(EventStreamSubscribeEventsEventTypeEnum.GROUP_CREATED) - ) + Arrays.asList(EventStreamSubscribeEventsEventTypeEnum.GROUP_CREATED) ) .build() ); @@ -5602,7 +5600,7 @@ client.events().subscribe(
-**eventType:** `Optional` — Event type(s) to listen for. Specify multiple times for multiple types (e.g., ?event_type=user.created&event_type=user.updated). If not provided, all event types will be streamed. +**eventType:** `Optional` — Event type(s) to listen for. Specify multiple times for multiple types (e.g., ?event_type=user.created&event_type=user.updated). If not provided, all event types will be streamed.
@@ -5644,7 +5642,7 @@ client.flows().list( OptionalNullable.of(true) ) .hydrate( - Arrays.asList(Optional.of(ListFlowsRequestParametersHydrateEnum.FORM_COUNT)) + Arrays.asList(ListFlowsRequestParametersHydrateEnum.FORM_COUNT) ) .build() ); @@ -5777,7 +5775,7 @@ client.flows().get( GetFlowRequestParameters .builder() .hydrate( - Arrays.asList(Optional.of(GetFlowRequestParametersHydrateEnum.FORM_COUNT)) + Arrays.asList(GetFlowRequestParametersHydrateEnum.FORM_COUNT) ) .build() ); @@ -5943,7 +5941,7 @@ client.forms().list( OptionalNullable.of(true) ) .hydrate( - Arrays.asList(Optional.of(FormsRequestParametersHydrateEnum.FLOW_COUNT)) + Arrays.asList(FormsRequestParametersHydrateEnum.FLOW_COUNT) ) .build() ); @@ -6116,7 +6114,7 @@ client.forms().get( GetFormRequestParameters .builder() .hydrate( - Arrays.asList(Optional.of(FormsRequestParametersHydrateEnum.FLOW_COUNT)) + Arrays.asList(FormsRequestParametersHydrateEnum.FLOW_COUNT) ) .build() ); @@ -9754,7 +9752,7 @@ client.resourceServers().list( OptionalNullable.of(true) ) .identifiers( - Arrays.asList(Optional.of("identifiers")) + Arrays.asList("identifiers") ) .build() ); @@ -18365,7 +18363,7 @@ client.clients().connections().get( OptionalNullable.of(true) ) .strategy( - Arrays.asList(Optional.of(ConnectionStrategyEnum.AD)) + Arrays.asList(ConnectionStrategyEnum.AD) ) .build() ); @@ -20735,7 +20733,7 @@ client.flows().executions().get( GetFlowExecutionRequestParameters .builder() .hydrate( - Arrays.asList(Optional.of(GetFlowExecutionRequestParametersHydrateEnum.DEBUG)) + Arrays.asList(GetFlowExecutionRequestParametersHydrateEnum.DEBUG) ) .build() ); @@ -24597,7 +24595,7 @@ client.organizations().clientGrants().list( OptionalNullable.of(true) ) .grantIds( - Arrays.asList(Optional.of("grant_ids")) + Arrays.asList("grant_ids") ) .build() ); diff --git a/src/main/java/com/auth0/client/mgmt/AsyncRawEventsClient.java b/src/main/java/com/auth0/client/mgmt/AsyncRawEventsClient.java index 72355b02..261c6a66 100644 --- a/src/main/java/com/auth0/client/mgmt/AsyncRawEventsClient.java +++ b/src/main/java/com/auth0/client/mgmt/AsyncRawEventsClient.java @@ -81,9 +81,9 @@ public CompletableFuture { diff --git a/src/main/java/com/auth0/client/mgmt/RawEventsClient.java b/src/main/java/com/auth0/client/mgmt/RawEventsClient.java index ddfee8cf..63ec6d1d 100644 --- a/src/main/java/com/auth0/client/mgmt/RawEventsClient.java +++ b/src/main/java/com/auth0/client/mgmt/RawEventsClient.java @@ -76,9 +76,9 @@ public ManagementApiHttpResponse { diff --git a/src/main/java/com/auth0/client/mgmt/types/ConnectionAssertionDecryptionAlgorithmProfileEnum.java b/src/main/java/com/auth0/client/mgmt/types/ConnectionAssertionDecryptionAlgorithmProfileEnum.java new file mode 100644 index 00000000..ae1a1ff0 --- /dev/null +++ b/src/main/java/com/auth0/client/mgmt/types/ConnectionAssertionDecryptionAlgorithmProfileEnum.java @@ -0,0 +1,75 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ +package com.auth0.client.mgmt.types; + +import com.fasterxml.jackson.annotation.JsonCreator; +import com.fasterxml.jackson.annotation.JsonValue; + +public final class ConnectionAssertionDecryptionAlgorithmProfileEnum { + public static final ConnectionAssertionDecryptionAlgorithmProfileEnum V20261 = + new ConnectionAssertionDecryptionAlgorithmProfileEnum(Value.V20261, "v2026-1"); + + private final Value value; + + private final String string; + + ConnectionAssertionDecryptionAlgorithmProfileEnum(Value value, String string) { + this.value = value; + this.string = string; + } + + public Value getEnumValue() { + return value; + } + + @java.lang.Override + @JsonValue + public String toString() { + return this.string; + } + + @java.lang.Override + public boolean equals(Object other) { + return (this == other) + || (other instanceof ConnectionAssertionDecryptionAlgorithmProfileEnum + && this.string.equals(((ConnectionAssertionDecryptionAlgorithmProfileEnum) other).string)); + } + + @java.lang.Override + public int hashCode() { + return this.string.hashCode(); + } + + public T visit(Visitor visitor) { + switch (value) { + case V20261: + return visitor.visitV20261(); + case UNKNOWN: + default: + return visitor.visitUnknown(string); + } + } + + @JsonCreator(mode = JsonCreator.Mode.DELEGATING) + public static ConnectionAssertionDecryptionAlgorithmProfileEnum valueOf(String value) { + switch (value) { + case "v2026-1": + return V20261; + default: + return new ConnectionAssertionDecryptionAlgorithmProfileEnum(Value.UNKNOWN, value); + } + } + + public enum Value { + V20261, + + UNKNOWN + } + + public interface Visitor { + T visitV20261(); + + T visitUnknown(String unknownType); + } +} diff --git a/src/main/java/com/auth0/client/mgmt/types/ConnectionAssertionDecryptionSettings.java b/src/main/java/com/auth0/client/mgmt/types/ConnectionAssertionDecryptionSettings.java new file mode 100644 index 00000000..fae616e9 --- /dev/null +++ b/src/main/java/com/auth0/client/mgmt/types/ConnectionAssertionDecryptionSettings.java @@ -0,0 +1,168 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ +package com.auth0.client.mgmt.types; + +import com.auth0.client.mgmt.core.ObjectMappers; +import com.fasterxml.jackson.annotation.JsonAnyGetter; +import com.fasterxml.jackson.annotation.JsonAnySetter; +import com.fasterxml.jackson.annotation.JsonIgnoreProperties; +import com.fasterxml.jackson.annotation.JsonInclude; +import com.fasterxml.jackson.annotation.JsonProperty; +import com.fasterxml.jackson.annotation.JsonSetter; +import com.fasterxml.jackson.annotation.Nulls; +import com.fasterxml.jackson.databind.annotation.JsonDeserialize; +import java.util.HashMap; +import java.util.List; +import java.util.Map; +import java.util.Objects; +import java.util.Optional; +import org.jetbrains.annotations.NotNull; + +@JsonInclude(JsonInclude.Include.NON_ABSENT) +@JsonDeserialize(builder = ConnectionAssertionDecryptionSettings.Builder.class) +public final class ConnectionAssertionDecryptionSettings { + private final ConnectionAssertionDecryptionAlgorithmProfileEnum algorithmProfile; + + private final Optional> algorithmExceptions; + + private final Map additionalProperties; + + private ConnectionAssertionDecryptionSettings( + ConnectionAssertionDecryptionAlgorithmProfileEnum algorithmProfile, + Optional> algorithmExceptions, + Map additionalProperties) { + this.algorithmProfile = algorithmProfile; + this.algorithmExceptions = algorithmExceptions; + this.additionalProperties = additionalProperties; + } + + @JsonProperty("algorithm_profile") + public ConnectionAssertionDecryptionAlgorithmProfileEnum getAlgorithmProfile() { + return algorithmProfile; + } + + /** + * @return A list of insecure algorithms to allow for SAML assertion decryption. + */ + @JsonProperty("algorithm_exceptions") + public Optional> getAlgorithmExceptions() { + return algorithmExceptions; + } + + @java.lang.Override + public boolean equals(Object other) { + if (this == other) return true; + return other instanceof ConnectionAssertionDecryptionSettings + && equalTo((ConnectionAssertionDecryptionSettings) other); + } + + @JsonAnyGetter + public Map getAdditionalProperties() { + return this.additionalProperties; + } + + private boolean equalTo(ConnectionAssertionDecryptionSettings other) { + return algorithmProfile.equals(other.algorithmProfile) && algorithmExceptions.equals(other.algorithmExceptions); + } + + @java.lang.Override + public int hashCode() { + return Objects.hash(this.algorithmProfile, this.algorithmExceptions); + } + + @java.lang.Override + public String toString() { + return ObjectMappers.stringify(this); + } + + public static AlgorithmProfileStage builder() { + return new Builder(); + } + + public interface AlgorithmProfileStage { + _FinalStage algorithmProfile(@NotNull ConnectionAssertionDecryptionAlgorithmProfileEnum algorithmProfile); + + Builder from(ConnectionAssertionDecryptionSettings other); + } + + public interface _FinalStage { + ConnectionAssertionDecryptionSettings build(); + + _FinalStage additionalProperty(String key, Object value); + + _FinalStage additionalProperties(Map additionalProperties); + + /** + *

A list of insecure algorithms to allow for SAML assertion decryption.

+ */ + _FinalStage algorithmExceptions(Optional> algorithmExceptions); + + _FinalStage algorithmExceptions(List algorithmExceptions); + } + + @JsonIgnoreProperties(ignoreUnknown = true) + public static final class Builder implements AlgorithmProfileStage, _FinalStage { + private ConnectionAssertionDecryptionAlgorithmProfileEnum algorithmProfile; + + private Optional> algorithmExceptions = Optional.empty(); + + @JsonAnySetter + private Map additionalProperties = new HashMap<>(); + + private Builder() {} + + @java.lang.Override + public Builder from(ConnectionAssertionDecryptionSettings other) { + algorithmProfile(other.getAlgorithmProfile()); + algorithmExceptions(other.getAlgorithmExceptions()); + return this; + } + + @java.lang.Override + @JsonSetter("algorithm_profile") + public _FinalStage algorithmProfile( + @NotNull ConnectionAssertionDecryptionAlgorithmProfileEnum algorithmProfile) { + this.algorithmProfile = Objects.requireNonNull(algorithmProfile, "algorithmProfile must not be null"); + return this; + } + + /** + *

A list of insecure algorithms to allow for SAML assertion decryption.

+ * @return Reference to {@code this} so that method calls can be chained together. + */ + @java.lang.Override + public _FinalStage algorithmExceptions(List algorithmExceptions) { + this.algorithmExceptions = Optional.ofNullable(algorithmExceptions); + return this; + } + + /** + *

A list of insecure algorithms to allow for SAML assertion decryption.

+ */ + @java.lang.Override + @JsonSetter(value = "algorithm_exceptions", nulls = Nulls.SKIP) + public _FinalStage algorithmExceptions(Optional> algorithmExceptions) { + this.algorithmExceptions = algorithmExceptions; + return this; + } + + @java.lang.Override + public ConnectionAssertionDecryptionSettings build() { + return new ConnectionAssertionDecryptionSettings( + algorithmProfile, algorithmExceptions, additionalProperties); + } + + @java.lang.Override + public Builder additionalProperty(String key, Object value) { + this.additionalProperties.put(key, value); + return this; + } + + @java.lang.Override + public Builder additionalProperties(Map additionalProperties) { + this.additionalProperties.putAll(additionalProperties); + return this; + } + } +} diff --git a/src/main/java/com/auth0/client/mgmt/types/ConnectionOptionsCommonSaml.java b/src/main/java/com/auth0/client/mgmt/types/ConnectionOptionsCommonSaml.java index 850b831e..1efb4b8c 100644 --- a/src/main/java/com/auth0/client/mgmt/types/ConnectionOptionsCommonSaml.java +++ b/src/main/java/com/auth0/client/mgmt/types/ConnectionOptionsCommonSaml.java @@ -24,6 +24,8 @@ @JsonInclude(JsonInclude.Include.NON_ABSENT) @JsonDeserialize(builder = ConnectionOptionsCommonSaml.Builder.class) public final class ConnectionOptionsCommonSaml implements IConnectionOptionsCommonSaml { + private final Optional assertionDecryptionSettings; + private final Optional cert; private final Optional decryptionKey; @@ -58,6 +60,7 @@ public final class ConnectionOptionsCommonSaml implements IConnectionOptionsComm private final Map additionalProperties; private ConnectionOptionsCommonSaml( + Optional assertionDecryptionSettings, Optional cert, Optional decryptionKey, Optional digestAlgorithm, @@ -74,6 +77,7 @@ private ConnectionOptionsCommonSaml( Optional> thumbprints, OptionalNullable>> upstreamParams, Map additionalProperties) { + this.assertionDecryptionSettings = assertionDecryptionSettings; this.cert = cert; this.decryptionKey = decryptionKey; this.digestAlgorithm = digestAlgorithm; @@ -92,6 +96,12 @@ private ConnectionOptionsCommonSaml( this.additionalProperties = additionalProperties; } + @JsonProperty("assertion_decryption_settings") + @java.lang.Override + public Optional getAssertionDecryptionSettings() { + return assertionDecryptionSettings; + } + @JsonProperty("cert") @java.lang.Override public Optional getCert() { @@ -205,7 +215,8 @@ public Map getAdditionalProperties() { } private boolean equalTo(ConnectionOptionsCommonSaml other) { - return cert.equals(other.cert) + return assertionDecryptionSettings.equals(other.assertionDecryptionSettings) + && cert.equals(other.cert) && decryptionKey.equals(other.decryptionKey) && digestAlgorithm.equals(other.digestAlgorithm) && domainAliases.equals(other.domainAliases) @@ -225,6 +236,7 @@ private boolean equalTo(ConnectionOptionsCommonSaml other) { @java.lang.Override public int hashCode() { return Objects.hash( + this.assertionDecryptionSettings, this.cert, this.decryptionKey, this.digestAlgorithm, @@ -253,6 +265,8 @@ public static Builder builder() { @JsonIgnoreProperties(ignoreUnknown = true) public static final class Builder { + private Optional assertionDecryptionSettings = Optional.empty(); + private Optional cert = Optional.empty(); private Optional decryptionKey = Optional.empty(); @@ -290,6 +304,7 @@ public static final class Builder { private Builder() {} public Builder from(ConnectionOptionsCommonSaml other) { + assertionDecryptionSettings(other.getAssertionDecryptionSettings()); cert(other.getCert()); decryptionKey(other.getDecryptionKey()); digestAlgorithm(other.getDigestAlgorithm()); @@ -308,6 +323,18 @@ public Builder from(ConnectionOptionsCommonSaml other) { return this; } + @JsonSetter(value = "assertion_decryption_settings", nulls = Nulls.SKIP) + public Builder assertionDecryptionSettings( + Optional assertionDecryptionSettings) { + this.assertionDecryptionSettings = assertionDecryptionSettings; + return this; + } + + public Builder assertionDecryptionSettings(ConnectionAssertionDecryptionSettings assertionDecryptionSettings) { + this.assertionDecryptionSettings = Optional.ofNullable(assertionDecryptionSettings); + return this; + } + @JsonSetter(value = "cert", nulls = Nulls.SKIP) public Builder cert(Optional cert) { this.cert = cert; @@ -503,6 +530,7 @@ public Builder upstreamParams( public ConnectionOptionsCommonSaml build() { return new ConnectionOptionsCommonSaml( + assertionDecryptionSettings, cert, decryptionKey, digestAlgorithm, diff --git a/src/main/java/com/auth0/client/mgmt/types/ConnectionOptionsPingFederate.java b/src/main/java/com/auth0/client/mgmt/types/ConnectionOptionsPingFederate.java index d23ca387..8f9d002d 100644 --- a/src/main/java/com/auth0/client/mgmt/types/ConnectionOptionsPingFederate.java +++ b/src/main/java/com/auth0/client/mgmt/types/ConnectionOptionsPingFederate.java @@ -25,6 +25,8 @@ @JsonInclude(JsonInclude.Include.NON_ABSENT) @JsonDeserialize(builder = ConnectionOptionsPingFederate.Builder.class) public final class ConnectionOptionsPingFederate implements IConnectionOptionsCommonSaml, IConnectionOptionsCommon { + private final Optional assertionDecryptionSettings; + private final Optional cert; private final Optional decryptionKey; @@ -65,6 +67,7 @@ public final class ConnectionOptionsPingFederate implements IConnectionOptionsCo private final Map additionalProperties; private ConnectionOptionsPingFederate( + Optional assertionDecryptionSettings, Optional cert, Optional decryptionKey, Optional digestAlgorithm, @@ -84,6 +87,7 @@ private ConnectionOptionsPingFederate( String pingFederateBaseUrl, Optional signingCert, Map additionalProperties) { + this.assertionDecryptionSettings = assertionDecryptionSettings; this.cert = cert; this.decryptionKey = decryptionKey; this.digestAlgorithm = digestAlgorithm; @@ -105,6 +109,12 @@ private ConnectionOptionsPingFederate( this.additionalProperties = additionalProperties; } + @JsonProperty("assertion_decryption_settings") + @java.lang.Override + public Optional getAssertionDecryptionSettings() { + return assertionDecryptionSettings; + } + @JsonProperty("cert") @java.lang.Override public Optional getCert() { @@ -234,7 +244,8 @@ public Map getAdditionalProperties() { } private boolean equalTo(ConnectionOptionsPingFederate other) { - return cert.equals(other.cert) + return assertionDecryptionSettings.equals(other.assertionDecryptionSettings) + && cert.equals(other.cert) && decryptionKey.equals(other.decryptionKey) && digestAlgorithm.equals(other.digestAlgorithm) && domainAliases.equals(other.domainAliases) @@ -257,6 +268,7 @@ private boolean equalTo(ConnectionOptionsPingFederate other) { @java.lang.Override public int hashCode() { return Objects.hash( + this.assertionDecryptionSettings, this.cert, this.decryptionKey, this.digestAlgorithm, @@ -299,6 +311,11 @@ public interface _FinalStage { _FinalStage additionalProperties(Map additionalProperties); + _FinalStage assertionDecryptionSettings( + Optional assertionDecryptionSettings); + + _FinalStage assertionDecryptionSettings(ConnectionAssertionDecryptionSettings assertionDecryptionSettings); + _FinalStage cert(Optional cert); _FinalStage cert(String cert); @@ -419,6 +436,8 @@ public static final class Builder implements PingFederateBaseUrlStage, _FinalSta private Optional cert = Optional.empty(); + private Optional assertionDecryptionSettings = Optional.empty(); + @JsonAnySetter private Map additionalProperties = new HashMap<>(); @@ -426,6 +445,7 @@ private Builder() {} @java.lang.Override public Builder from(ConnectionOptionsPingFederate other) { + assertionDecryptionSettings(other.getAssertionDecryptionSettings()); cert(other.getCert()); decryptionKey(other.getDecryptionKey()); digestAlgorithm(other.getDigestAlgorithm()); @@ -706,9 +726,25 @@ public _FinalStage cert(Optional cert) { return this; } + @java.lang.Override + public _FinalStage assertionDecryptionSettings( + ConnectionAssertionDecryptionSettings assertionDecryptionSettings) { + this.assertionDecryptionSettings = Optional.ofNullable(assertionDecryptionSettings); + return this; + } + + @java.lang.Override + @JsonSetter(value = "assertion_decryption_settings", nulls = Nulls.SKIP) + public _FinalStage assertionDecryptionSettings( + Optional assertionDecryptionSettings) { + this.assertionDecryptionSettings = assertionDecryptionSettings; + return this; + } + @java.lang.Override public ConnectionOptionsPingFederate build() { return new ConnectionOptionsPingFederate( + assertionDecryptionSettings, cert, decryptionKey, digestAlgorithm, diff --git a/src/main/java/com/auth0/client/mgmt/types/ConnectionOptionsSaml.java b/src/main/java/com/auth0/client/mgmt/types/ConnectionOptionsSaml.java index 25de7198..3f01f6d6 100644 --- a/src/main/java/com/auth0/client/mgmt/types/ConnectionOptionsSaml.java +++ b/src/main/java/com/auth0/client/mgmt/types/ConnectionOptionsSaml.java @@ -24,6 +24,8 @@ @JsonInclude(JsonInclude.Include.NON_ABSENT) @JsonDeserialize(builder = ConnectionOptionsSaml.Builder.class) public final class ConnectionOptionsSaml implements IConnectionOptionsCommonSaml, IConnectionOptionsCommon { + private final Optional assertionDecryptionSettings; + private final Optional cert; private final Optional decryptionKey; @@ -90,6 +92,7 @@ public final class ConnectionOptionsSaml implements IConnectionOptionsCommonSaml private final Map additionalProperties; private ConnectionOptionsSaml( + Optional assertionDecryptionSettings, Optional cert, Optional decryptionKey, Optional digestAlgorithm, @@ -122,6 +125,7 @@ private ConnectionOptionsSaml( Optional signOutEndpoint, Optional userIdAttribute, Map additionalProperties) { + this.assertionDecryptionSettings = assertionDecryptionSettings; this.cert = cert; this.decryptionKey = decryptionKey; this.digestAlgorithm = digestAlgorithm; @@ -156,6 +160,12 @@ private ConnectionOptionsSaml( this.additionalProperties = additionalProperties; } + @JsonProperty("assertion_decryption_settings") + @java.lang.Override + public Optional getAssertionDecryptionSettings() { + return assertionDecryptionSettings; + } + @JsonProperty("cert") @java.lang.Override public Optional getCert() { @@ -353,7 +363,8 @@ public Map getAdditionalProperties() { } private boolean equalTo(ConnectionOptionsSaml other) { - return cert.equals(other.cert) + return assertionDecryptionSettings.equals(other.assertionDecryptionSettings) + && cert.equals(other.cert) && decryptionKey.equals(other.decryptionKey) && digestAlgorithm.equals(other.digestAlgorithm) && domainAliases.equals(other.domainAliases) @@ -389,6 +400,7 @@ private boolean equalTo(ConnectionOptionsSaml other) { @java.lang.Override public int hashCode() { return Objects.hash( + this.assertionDecryptionSettings, this.cert, this.decryptionKey, this.digestAlgorithm, @@ -433,6 +445,8 @@ public static Builder builder() { @JsonIgnoreProperties(ignoreUnknown = true) public static final class Builder { + private Optional assertionDecryptionSettings = Optional.empty(); + private Optional cert = Optional.empty(); private Optional decryptionKey = Optional.empty(); @@ -502,6 +516,7 @@ public static final class Builder { private Builder() {} public Builder from(ConnectionOptionsSaml other) { + assertionDecryptionSettings(other.getAssertionDecryptionSettings()); cert(other.getCert()); decryptionKey(other.getDecryptionKey()); digestAlgorithm(other.getDigestAlgorithm()); @@ -536,6 +551,18 @@ public Builder from(ConnectionOptionsSaml other) { return this; } + @JsonSetter(value = "assertion_decryption_settings", nulls = Nulls.SKIP) + public Builder assertionDecryptionSettings( + Optional assertionDecryptionSettings) { + this.assertionDecryptionSettings = assertionDecryptionSettings; + return this; + } + + public Builder assertionDecryptionSettings(ConnectionAssertionDecryptionSettings assertionDecryptionSettings) { + this.assertionDecryptionSettings = Optional.ofNullable(assertionDecryptionSettings); + return this; + } + @JsonSetter(value = "cert", nulls = Nulls.SKIP) public Builder cert(Optional cert) { this.cert = cert; @@ -910,6 +937,7 @@ public Builder userIdAttribute(String userIdAttribute) { public ConnectionOptionsSaml build() { return new ConnectionOptionsSaml( + assertionDecryptionSettings, cert, decryptionKey, digestAlgorithm, diff --git a/src/main/java/com/auth0/client/mgmt/types/ConnectionPropertiesOptions.java b/src/main/java/com/auth0/client/mgmt/types/ConnectionPropertiesOptions.java index cd07c3e5..53f76bf1 100644 --- a/src/main/java/com/auth0/client/mgmt/types/ConnectionPropertiesOptions.java +++ b/src/main/java/com/auth0/client/mgmt/types/ConnectionPropertiesOptions.java @@ -87,6 +87,8 @@ public final class ConnectionPropertiesOptions { private final Optional passwordOptions; + private final Optional assertionDecryptionSettings; + private final OptionalNullable> idTokenSignedResponseAlgs; private final OptionalNullable tokenEndpointAuthMethod; @@ -129,6 +131,7 @@ private ConnectionPropertiesOptions( OptionalNullable gatewayAuthentication, OptionalNullable federatedConnectionsAccessTokens, Optional passwordOptions, + Optional assertionDecryptionSettings, OptionalNullable> idTokenSignedResponseAlgs, OptionalNullable tokenEndpointAuthMethod, OptionalNullable tokenEndpointAuthSigningAlg, @@ -165,6 +168,7 @@ private ConnectionPropertiesOptions( this.gatewayAuthentication = gatewayAuthentication; this.federatedConnectionsAccessTokens = federatedConnectionsAccessTokens; this.passwordOptions = passwordOptions; + this.assertionDecryptionSettings = assertionDecryptionSettings; this.idTokenSignedResponseAlgs = idTokenSignedResponseAlgs; this.tokenEndpointAuthMethod = tokenEndpointAuthMethod; this.tokenEndpointAuthSigningAlg = tokenEndpointAuthSigningAlg; @@ -397,6 +401,11 @@ public Optional getPasswordOptions() { return passwordOptions; } + @JsonProperty("assertion_decryption_settings") + public Optional getAssertionDecryptionSettings() { + return assertionDecryptionSettings; + } + @JsonInclude(value = JsonInclude.Include.CUSTOM, valueFilter = NullableNonemptyFilter.class) @JsonProperty("id_token_signed_response_algs") public OptionalNullable> getIdTokenSignedResponseAlgs() { @@ -569,6 +578,7 @@ private boolean equalTo(ConnectionPropertiesOptions other) { && gatewayAuthentication.equals(other.gatewayAuthentication) && federatedConnectionsAccessTokens.equals(other.federatedConnectionsAccessTokens) && passwordOptions.equals(other.passwordOptions) + && assertionDecryptionSettings.equals(other.assertionDecryptionSettings) && idTokenSignedResponseAlgs.equals(other.idTokenSignedResponseAlgs) && tokenEndpointAuthMethod.equals(other.tokenEndpointAuthMethod) && tokenEndpointAuthSigningAlg.equals(other.tokenEndpointAuthSigningAlg) @@ -609,6 +619,7 @@ public int hashCode() { this.gatewayAuthentication, this.federatedConnectionsAccessTokens, this.passwordOptions, + this.assertionDecryptionSettings, this.idTokenSignedResponseAlgs, this.tokenEndpointAuthMethod, this.tokenEndpointAuthSigningAlg, @@ -692,6 +703,8 @@ public static final class Builder { private Optional passwordOptions = Optional.empty(); + private Optional assertionDecryptionSettings = Optional.empty(); + private OptionalNullable> idTokenSignedResponseAlgs = OptionalNullable.absent(); @@ -740,6 +753,7 @@ public Builder from(ConnectionPropertiesOptions other) { gatewayAuthentication(other.getGatewayAuthentication()); federatedConnectionsAccessTokens(other.getFederatedConnectionsAccessTokens()); passwordOptions(other.getPasswordOptions()); + assertionDecryptionSettings(other.getAssertionDecryptionSettings()); idTokenSignedResponseAlgs(other.getIdTokenSignedResponseAlgs()); tokenEndpointAuthMethod(other.getTokenEndpointAuthMethod()); tokenEndpointAuthSigningAlg(other.getTokenEndpointAuthSigningAlg()); @@ -1395,6 +1409,18 @@ public Builder passwordOptions(ConnectionPasswordOptions passwordOptions) { return this; } + @JsonSetter(value = "assertion_decryption_settings", nulls = Nulls.SKIP) + public Builder assertionDecryptionSettings( + Optional assertionDecryptionSettings) { + this.assertionDecryptionSettings = assertionDecryptionSettings; + return this; + } + + public Builder assertionDecryptionSettings(ConnectionAssertionDecryptionSettings assertionDecryptionSettings) { + this.assertionDecryptionSettings = Optional.ofNullable(assertionDecryptionSettings); + return this; + } + @JsonSetter(value = "id_token_signed_response_algs", nulls = Nulls.SKIP) public Builder idTokenSignedResponseAlgs( @Nullable OptionalNullable> idTokenSignedResponseAlgs) { @@ -1547,6 +1573,7 @@ public ConnectionPropertiesOptions build() { gatewayAuthentication, federatedConnectionsAccessTokens, passwordOptions, + assertionDecryptionSettings, idTokenSignedResponseAlgs, tokenEndpointAuthMethod, tokenEndpointAuthSigningAlg, diff --git a/src/main/java/com/auth0/client/mgmt/types/EventStreamSubscribeEventsEventTypeParam.java b/src/main/java/com/auth0/client/mgmt/types/EventStreamSubscribeEventsEventTypeParam.java deleted file mode 100644 index d9f6b71a..00000000 --- a/src/main/java/com/auth0/client/mgmt/types/EventStreamSubscribeEventsEventTypeParam.java +++ /dev/null @@ -1,100 +0,0 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ -package com.auth0.client.mgmt.types; - -import com.auth0.client.mgmt.core.ObjectMappers; -import com.fasterxml.jackson.annotation.JsonValue; -import com.fasterxml.jackson.core.JsonParseException; -import com.fasterxml.jackson.core.JsonParser; -import com.fasterxml.jackson.core.type.TypeReference; -import com.fasterxml.jackson.databind.DeserializationContext; -import com.fasterxml.jackson.databind.annotation.JsonDeserialize; -import com.fasterxml.jackson.databind.deser.std.StdDeserializer; -import java.io.IOException; -import java.util.List; -import java.util.Objects; - -@JsonDeserialize(using = EventStreamSubscribeEventsEventTypeParam.Deserializer.class) -public final class EventStreamSubscribeEventsEventTypeParam { - private final Object value; - - private final int type; - - private EventStreamSubscribeEventsEventTypeParam(Object value, int type) { - this.value = value; - this.type = type; - } - - @JsonValue - public Object get() { - return this.value; - } - - @SuppressWarnings("unchecked") - public T visit(Visitor visitor) { - if (this.type == 0) { - return visitor.visit((EventStreamSubscribeEventsEventTypeEnum) this.value); - } else if (this.type == 1) { - return visitor.visit((List) this.value); - } - throw new IllegalStateException("Failed to visit value. This should never happen."); - } - - @java.lang.Override - public boolean equals(Object other) { - if (this == other) return true; - return other instanceof EventStreamSubscribeEventsEventTypeParam - && equalTo((EventStreamSubscribeEventsEventTypeParam) other); - } - - private boolean equalTo(EventStreamSubscribeEventsEventTypeParam other) { - return value.equals(other.value); - } - - @java.lang.Override - public int hashCode() { - return Objects.hash(this.value); - } - - @java.lang.Override - public String toString() { - return this.value.toString(); - } - - public static EventStreamSubscribeEventsEventTypeParam of(EventStreamSubscribeEventsEventTypeEnum value) { - return new EventStreamSubscribeEventsEventTypeParam(value, 0); - } - - public static EventStreamSubscribeEventsEventTypeParam of(List value) { - return new EventStreamSubscribeEventsEventTypeParam(value, 1); - } - - public interface Visitor { - T visit(EventStreamSubscribeEventsEventTypeEnum value); - - T visit(List value); - } - - static final class Deserializer extends StdDeserializer { - Deserializer() { - super(EventStreamSubscribeEventsEventTypeParam.class); - } - - @java.lang.Override - public EventStreamSubscribeEventsEventTypeParam deserialize(JsonParser p, DeserializationContext context) - throws IOException { - Object value = p.readValueAs(Object.class); - try { - return of(ObjectMappers.JSON_MAPPER.convertValue(value, EventStreamSubscribeEventsEventTypeEnum.class)); - } catch (RuntimeException e) { - } - try { - return of(ObjectMappers.JSON_MAPPER.convertValue( - value, new TypeReference>() {})); - } catch (RuntimeException e) { - } - throw new JsonParseException(p, "Failed to deserialize"); - } - } -} diff --git a/src/main/java/com/auth0/client/mgmt/types/IConnectionOptionsCommonSaml.java b/src/main/java/com/auth0/client/mgmt/types/IConnectionOptionsCommonSaml.java index 7283adea..6550f1e0 100644 --- a/src/main/java/com/auth0/client/mgmt/types/IConnectionOptionsCommonSaml.java +++ b/src/main/java/com/auth0/client/mgmt/types/IConnectionOptionsCommonSaml.java @@ -9,6 +9,8 @@ import java.util.Optional; public interface IConnectionOptionsCommonSaml { + Optional getAssertionDecryptionSettings(); + Optional getCert(); Optional getDecryptionKey(); diff --git a/src/main/java/com/auth0/client/mgmt/types/SubscribeEventsRequestParameters.java b/src/main/java/com/auth0/client/mgmt/types/SubscribeEventsRequestParameters.java index 0b83c82f..b4c4a38d 100644 --- a/src/main/java/com/auth0/client/mgmt/types/SubscribeEventsRequestParameters.java +++ b/src/main/java/com/auth0/client/mgmt/types/SubscribeEventsRequestParameters.java @@ -13,7 +13,9 @@ import com.fasterxml.jackson.annotation.JsonSetter; import com.fasterxml.jackson.annotation.Nulls; import com.fasterxml.jackson.databind.annotation.JsonDeserialize; +import java.util.Collections; import java.util.HashMap; +import java.util.List; import java.util.Map; import java.util.Objects; import java.util.Optional; @@ -22,25 +24,36 @@ @JsonInclude(JsonInclude.Include.NON_ABSENT) @JsonDeserialize(builder = SubscribeEventsRequestParameters.Builder.class) public final class SubscribeEventsRequestParameters { + private final Optional> eventType; + private final OptionalNullable from; private final OptionalNullable fromTimestamp; - private final OptionalNullable eventType; - private final Map additionalProperties; private SubscribeEventsRequestParameters( + Optional> eventType, OptionalNullable from, OptionalNullable fromTimestamp, - OptionalNullable eventType, Map additionalProperties) { + this.eventType = eventType; this.from = from; this.fromTimestamp = fromTimestamp; - this.eventType = eventType; this.additionalProperties = additionalProperties; } + /** + * @return Event type(s) to listen for. Specify multiple times for multiple types (e.g., ?event_type=user.created&event_type=user.updated). If not provided, all event types will be streamed. + */ + @JsonIgnore + public Optional> getEventType() { + if (eventType == null) { + return Optional.empty(); + } + return eventType; + } + /** * @return Opaque token representing position in the stream. If not provided, stream will start from the latest events. */ @@ -63,17 +76,6 @@ public OptionalNullable getFromTimestamp() { return fromTimestamp; } - /** - * @return Event type(s) to listen for. Specify multiple times for multiple types (e.g., ?event_type=user.created&event_type=user.updated). If not provided, all event types will be streamed. - */ - @JsonIgnore - public OptionalNullable getEventType() { - if (eventType == null) { - return OptionalNullable.absent(); - } - return eventType; - } - @java.lang.Override public boolean equals(Object other) { if (this == other) return true; @@ -86,14 +88,14 @@ public Map getAdditionalProperties() { } private boolean equalTo(SubscribeEventsRequestParameters other) { - return from.equals(other.from) - && fromTimestamp.equals(other.fromTimestamp) - && eventType.equals(other.eventType); + return eventType.equals(other.eventType) + && from.equals(other.from) + && fromTimestamp.equals(other.fromTimestamp); } @java.lang.Override public int hashCode() { - return Objects.hash(this.from, this.fromTimestamp, this.eventType); + return Objects.hash(this.eventType, this.from, this.fromTimestamp); } @java.lang.Override @@ -107,21 +109,52 @@ public static Builder builder() { @JsonIgnoreProperties(ignoreUnknown = true) public static final class Builder { + private Optional> eventType = Optional.empty(); + private OptionalNullable from = OptionalNullable.absent(); private OptionalNullable fromTimestamp = OptionalNullable.absent(); - private OptionalNullable eventType = OptionalNullable.absent(); - @JsonAnySetter private Map additionalProperties = new HashMap<>(); private Builder() {} public Builder from(SubscribeEventsRequestParameters other) { + eventType(other.getEventType()); from(other.getFrom()); fromTimestamp(other.getFromTimestamp()); - eventType(other.getEventType()); + return this; + } + + /** + *

Event type(s) to listen for. Specify multiple times for multiple types (e.g., ?event_type=user.created&event_type=user.updated). If not provided, all event types will be streamed.

+ */ + @JsonSetter(value = "event_type", nulls = Nulls.SKIP) + public Builder eventType(@Nullable Optional> eventType) { + this.eventType = eventType; + return this; + } + + public Builder eventType(List eventType) { + this.eventType = Optional.ofNullable(eventType); + return this; + } + + public Builder eventType( + com.auth0.client.mgmt.core.Nullable> eventType) { + if (eventType.isNull()) { + this.eventType = null; + } else if (eventType.isEmpty()) { + this.eventType = Optional.empty(); + } else { + this.eventType = Optional.of(eventType.get()); + } + return this; + } + + public Builder eventType(EventStreamSubscribeEventsEventTypeEnum eventType) { + this.eventType = Optional.of(Collections.singletonList(eventType)); return this; } @@ -193,43 +226,8 @@ public Builder fromTimestamp(com.auth0.client.mgmt.core.Nullable fromTim return this; } - /** - *

Event type(s) to listen for. Specify multiple times for multiple types (e.g., ?event_type=user.created&event_type=user.updated). If not provided, all event types will be streamed.

- */ - @JsonSetter(value = "event_type", nulls = Nulls.SKIP) - public Builder eventType(@Nullable OptionalNullable eventType) { - this.eventType = eventType; - return this; - } - - public Builder eventType(EventStreamSubscribeEventsEventTypeParam eventType) { - this.eventType = OptionalNullable.of(eventType); - return this; - } - - public Builder eventType(Optional eventType) { - if (eventType.isPresent()) { - this.eventType = OptionalNullable.of(eventType.get()); - } else { - this.eventType = OptionalNullable.absent(); - } - return this; - } - - public Builder eventType( - com.auth0.client.mgmt.core.Nullable eventType) { - if (eventType.isNull()) { - this.eventType = OptionalNullable.ofNull(); - } else if (eventType.isEmpty()) { - this.eventType = OptionalNullable.absent(); - } else { - this.eventType = OptionalNullable.of(eventType.get()); - } - return this; - } - public SubscribeEventsRequestParameters build() { - return new SubscribeEventsRequestParameters(from, fromTimestamp, eventType, additionalProperties); + return new SubscribeEventsRequestParameters(eventType, from, fromTimestamp, additionalProperties); } public Builder additionalProperty(String key, Object value) { diff --git a/src/main/java/com/auth0/client/mgmt/types/UpdateConnectionOptions.java b/src/main/java/com/auth0/client/mgmt/types/UpdateConnectionOptions.java index 016ba440..e7599dfc 100644 --- a/src/main/java/com/auth0/client/mgmt/types/UpdateConnectionOptions.java +++ b/src/main/java/com/auth0/client/mgmt/types/UpdateConnectionOptions.java @@ -87,6 +87,8 @@ public final class UpdateConnectionOptions { private final Optional passwordOptions; + private final Optional assertionDecryptionSettings; + private final OptionalNullable> idTokenSignedResponseAlgs; private final OptionalNullable tokenEndpointAuthMethod; @@ -129,6 +131,7 @@ private UpdateConnectionOptions( OptionalNullable gatewayAuthentication, OptionalNullable federatedConnectionsAccessTokens, Optional passwordOptions, + Optional assertionDecryptionSettings, OptionalNullable> idTokenSignedResponseAlgs, OptionalNullable tokenEndpointAuthMethod, OptionalNullable tokenEndpointAuthSigningAlg, @@ -165,6 +168,7 @@ private UpdateConnectionOptions( this.gatewayAuthentication = gatewayAuthentication; this.federatedConnectionsAccessTokens = federatedConnectionsAccessTokens; this.passwordOptions = passwordOptions; + this.assertionDecryptionSettings = assertionDecryptionSettings; this.idTokenSignedResponseAlgs = idTokenSignedResponseAlgs; this.tokenEndpointAuthMethod = tokenEndpointAuthMethod; this.tokenEndpointAuthSigningAlg = tokenEndpointAuthSigningAlg; @@ -397,6 +401,11 @@ public Optional getPasswordOptions() { return passwordOptions; } + @JsonProperty("assertion_decryption_settings") + public Optional getAssertionDecryptionSettings() { + return assertionDecryptionSettings; + } + @JsonInclude(value = JsonInclude.Include.CUSTOM, valueFilter = NullableNonemptyFilter.class) @JsonProperty("id_token_signed_response_algs") public OptionalNullable> getIdTokenSignedResponseAlgs() { @@ -569,6 +578,7 @@ private boolean equalTo(UpdateConnectionOptions other) { && gatewayAuthentication.equals(other.gatewayAuthentication) && federatedConnectionsAccessTokens.equals(other.federatedConnectionsAccessTokens) && passwordOptions.equals(other.passwordOptions) + && assertionDecryptionSettings.equals(other.assertionDecryptionSettings) && idTokenSignedResponseAlgs.equals(other.idTokenSignedResponseAlgs) && tokenEndpointAuthMethod.equals(other.tokenEndpointAuthMethod) && tokenEndpointAuthSigningAlg.equals(other.tokenEndpointAuthSigningAlg) @@ -609,6 +619,7 @@ public int hashCode() { this.gatewayAuthentication, this.federatedConnectionsAccessTokens, this.passwordOptions, + this.assertionDecryptionSettings, this.idTokenSignedResponseAlgs, this.tokenEndpointAuthMethod, this.tokenEndpointAuthSigningAlg, @@ -692,6 +703,8 @@ public static final class Builder { private Optional passwordOptions = Optional.empty(); + private Optional assertionDecryptionSettings = Optional.empty(); + private OptionalNullable> idTokenSignedResponseAlgs = OptionalNullable.absent(); @@ -740,6 +753,7 @@ public Builder from(UpdateConnectionOptions other) { gatewayAuthentication(other.getGatewayAuthentication()); federatedConnectionsAccessTokens(other.getFederatedConnectionsAccessTokens()); passwordOptions(other.getPasswordOptions()); + assertionDecryptionSettings(other.getAssertionDecryptionSettings()); idTokenSignedResponseAlgs(other.getIdTokenSignedResponseAlgs()); tokenEndpointAuthMethod(other.getTokenEndpointAuthMethod()); tokenEndpointAuthSigningAlg(other.getTokenEndpointAuthSigningAlg()); @@ -1395,6 +1409,18 @@ public Builder passwordOptions(ConnectionPasswordOptions passwordOptions) { return this; } + @JsonSetter(value = "assertion_decryption_settings", nulls = Nulls.SKIP) + public Builder assertionDecryptionSettings( + Optional assertionDecryptionSettings) { + this.assertionDecryptionSettings = assertionDecryptionSettings; + return this; + } + + public Builder assertionDecryptionSettings(ConnectionAssertionDecryptionSettings assertionDecryptionSettings) { + this.assertionDecryptionSettings = Optional.ofNullable(assertionDecryptionSettings); + return this; + } + @JsonSetter(value = "id_token_signed_response_algs", nulls = Nulls.SKIP) public Builder idTokenSignedResponseAlgs( @Nullable OptionalNullable> idTokenSignedResponseAlgs) { @@ -1547,6 +1573,7 @@ public UpdateConnectionOptions build() { gatewayAuthentication, federatedConnectionsAccessTokens, passwordOptions, + assertionDecryptionSettings, idTokenSignedResponseAlgs, tokenEndpointAuthMethod, tokenEndpointAuthSigningAlg, diff --git a/src/test/java/com/auth0/client/mgmt/ClientsConnectionsWireTest.java b/src/test/java/com/auth0/client/mgmt/ClientsConnectionsWireTest.java index 9e4fa755..3dcee800 100644 --- a/src/test/java/com/auth0/client/mgmt/ClientsConnectionsWireTest.java +++ b/src/test/java/com/auth0/client/mgmt/ClientsConnectionsWireTest.java @@ -9,7 +9,6 @@ import com.fasterxml.jackson.databind.JsonNode; import com.fasterxml.jackson.databind.ObjectMapper; import java.util.Arrays; -import java.util.Optional; import okhttp3.mockwebserver.MockResponse; import okhttp3.mockwebserver.MockWebServer; import okhttp3.mockwebserver.RecordedRequest; @@ -54,7 +53,7 @@ public void testGet() throws Exception { .take(OptionalNullable.of(1)) .fields(OptionalNullable.of("fields")) .includeFields(OptionalNullable.of(true)) - .strategy(Arrays.asList(Optional.of(ConnectionStrategyEnum.AD))) + .strategy(Arrays.asList(ConnectionStrategyEnum.AD)) .build()); RecordedRequest request = server.takeRequest(); Assertions.assertNotNull(request); diff --git a/src/test/java/com/auth0/client/mgmt/ConnectionsWireTest.java b/src/test/java/com/auth0/client/mgmt/ConnectionsWireTest.java index d94c4962..dbeecfa0 100644 --- a/src/test/java/com/auth0/client/mgmt/ConnectionsWireTest.java +++ b/src/test/java/com/auth0/client/mgmt/ConnectionsWireTest.java @@ -16,7 +16,6 @@ import com.fasterxml.jackson.databind.JsonNode; import com.fasterxml.jackson.databind.ObjectMapper; import java.util.Arrays; -import java.util.Optional; import okhttp3.mockwebserver.MockResponse; import okhttp3.mockwebserver.MockWebServer; import okhttp3.mockwebserver.RecordedRequest; @@ -59,7 +58,7 @@ public void testList() throws Exception { .name(OptionalNullable.of("name")) .fields(OptionalNullable.of("fields")) .includeFields(OptionalNullable.of(true)) - .strategy(Arrays.asList(Optional.of(ConnectionStrategyEnum.AD))) + .strategy(Arrays.asList(ConnectionStrategyEnum.AD)) .build()); RecordedRequest request = server.takeRequest(); Assertions.assertNotNull(request); diff --git a/src/test/java/com/auth0/client/mgmt/EventsWireTest.java b/src/test/java/com/auth0/client/mgmt/EventsWireTest.java index d9cd523e..67b9037a 100644 --- a/src/test/java/com/auth0/client/mgmt/EventsWireTest.java +++ b/src/test/java/com/auth0/client/mgmt/EventsWireTest.java @@ -3,11 +3,11 @@ import com.auth0.client.mgmt.core.ObjectMappers; import com.auth0.client.mgmt.core.OptionalNullable; import com.auth0.client.mgmt.types.EventStreamSubscribeEventsEventTypeEnum; -import com.auth0.client.mgmt.types.EventStreamSubscribeEventsEventTypeParam; import com.auth0.client.mgmt.types.EventStreamSubscribeEventsResponseContent; import com.auth0.client.mgmt.types.SubscribeEventsRequestParameters; import com.fasterxml.jackson.databind.JsonNode; import com.fasterxml.jackson.databind.ObjectMapper; +import java.util.Arrays; import okhttp3.mockwebserver.MockResponse; import okhttp3.mockwebserver.MockWebServer; import okhttp3.mockwebserver.RecordedRequest; @@ -43,8 +43,7 @@ public void testSubscribe() throws Exception { .subscribe(SubscribeEventsRequestParameters.builder() .from(OptionalNullable.of("from")) .fromTimestamp(OptionalNullable.of("from_timestamp")) - .eventType(OptionalNullable.of(EventStreamSubscribeEventsEventTypeParam.of( - EventStreamSubscribeEventsEventTypeEnum.GROUP_CREATED))) + .eventType(Arrays.asList(EventStreamSubscribeEventsEventTypeEnum.GROUP_CREATED)) .build()); RecordedRequest request = server.takeRequest(); Assertions.assertNotNull(request); diff --git a/src/test/java/com/auth0/client/mgmt/FlowsExecutionsWireTest.java b/src/test/java/com/auth0/client/mgmt/FlowsExecutionsWireTest.java index 624ea329..d61853f1 100644 --- a/src/test/java/com/auth0/client/mgmt/FlowsExecutionsWireTest.java +++ b/src/test/java/com/auth0/client/mgmt/FlowsExecutionsWireTest.java @@ -11,7 +11,6 @@ import com.fasterxml.jackson.databind.JsonNode; import com.fasterxml.jackson.databind.ObjectMapper; import java.util.Arrays; -import java.util.Optional; import okhttp3.mockwebserver.MockResponse; import okhttp3.mockwebserver.MockWebServer; import okhttp3.mockwebserver.RecordedRequest; @@ -78,7 +77,7 @@ public void testGet() throws Exception { "flow_id", "execution_id", GetFlowExecutionRequestParameters.builder() - .hydrate(Arrays.asList(Optional.of(GetFlowExecutionRequestParametersHydrateEnum.DEBUG))) + .hydrate(Arrays.asList(GetFlowExecutionRequestParametersHydrateEnum.DEBUG)) .build()); RecordedRequest request = server.takeRequest(); Assertions.assertNotNull(request); diff --git a/src/test/java/com/auth0/client/mgmt/FlowsWireTest.java b/src/test/java/com/auth0/client/mgmt/FlowsWireTest.java index c00fcad4..7eb3fc2a 100644 --- a/src/test/java/com/auth0/client/mgmt/FlowsWireTest.java +++ b/src/test/java/com/auth0/client/mgmt/FlowsWireTest.java @@ -16,7 +16,6 @@ import com.fasterxml.jackson.databind.JsonNode; import com.fasterxml.jackson.databind.ObjectMapper; import java.util.Arrays; -import java.util.Optional; import okhttp3.mockwebserver.MockResponse; import okhttp3.mockwebserver.MockWebServer; import okhttp3.mockwebserver.RecordedRequest; @@ -58,7 +57,7 @@ public void testList() throws Exception { .perPage(OptionalNullable.of(1)) .includeTotals(OptionalNullable.of(true)) .synchronous(OptionalNullable.of(true)) - .hydrate(Arrays.asList(Optional.of(ListFlowsRequestParametersHydrateEnum.FORM_COUNT))) + .hydrate(Arrays.asList(ListFlowsRequestParametersHydrateEnum.FORM_COUNT)) .build()); RecordedRequest request = server.takeRequest(); Assertions.assertNotNull(request); @@ -179,7 +178,7 @@ public void testGet() throws Exception { .get( "id", GetFlowRequestParameters.builder() - .hydrate(Arrays.asList(Optional.of(GetFlowRequestParametersHydrateEnum.FORM_COUNT))) + .hydrate(Arrays.asList(GetFlowRequestParametersHydrateEnum.FORM_COUNT)) .build()); RecordedRequest request = server.takeRequest(); Assertions.assertNotNull(request); diff --git a/src/test/java/com/auth0/client/mgmt/FormsWireTest.java b/src/test/java/com/auth0/client/mgmt/FormsWireTest.java index 9703882b..afbbcc10 100644 --- a/src/test/java/com/auth0/client/mgmt/FormsWireTest.java +++ b/src/test/java/com/auth0/client/mgmt/FormsWireTest.java @@ -15,7 +15,6 @@ import com.fasterxml.jackson.databind.JsonNode; import com.fasterxml.jackson.databind.ObjectMapper; import java.util.Arrays; -import java.util.Optional; import okhttp3.mockwebserver.MockResponse; import okhttp3.mockwebserver.MockWebServer; import okhttp3.mockwebserver.RecordedRequest; @@ -56,7 +55,7 @@ public void testList() throws Exception { .page(OptionalNullable.of(1)) .perPage(OptionalNullable.of(1)) .includeTotals(OptionalNullable.of(true)) - .hydrate(Arrays.asList(Optional.of(FormsRequestParametersHydrateEnum.FLOW_COUNT))) + .hydrate(Arrays.asList(FormsRequestParametersHydrateEnum.FLOW_COUNT)) .build()); RecordedRequest request = server.takeRequest(); Assertions.assertNotNull(request); @@ -152,7 +151,7 @@ public void testGet() throws Exception { .get( "id", GetFormRequestParameters.builder() - .hydrate(Arrays.asList(Optional.of(FormsRequestParametersHydrateEnum.FLOW_COUNT))) + .hydrate(Arrays.asList(FormsRequestParametersHydrateEnum.FLOW_COUNT)) .build()); RecordedRequest request = server.takeRequest(); Assertions.assertNotNull(request); diff --git a/src/test/java/com/auth0/client/mgmt/OrganizationsClientGrantsWireTest.java b/src/test/java/com/auth0/client/mgmt/OrganizationsClientGrantsWireTest.java index b49d47cb..cc1eddc7 100644 --- a/src/test/java/com/auth0/client/mgmt/OrganizationsClientGrantsWireTest.java +++ b/src/test/java/com/auth0/client/mgmt/OrganizationsClientGrantsWireTest.java @@ -10,7 +10,6 @@ import com.fasterxml.jackson.databind.JsonNode; import com.fasterxml.jackson.databind.ObjectMapper; import java.util.Arrays; -import java.util.Optional; import okhttp3.mockwebserver.MockResponse; import okhttp3.mockwebserver.MockWebServer; import okhttp3.mockwebserver.RecordedRequest; @@ -56,7 +55,7 @@ public void testList() throws Exception { .page(OptionalNullable.of(1)) .perPage(OptionalNullable.of(1)) .includeTotals(OptionalNullable.of(true)) - .grantIds(Arrays.asList(Optional.of("grant_ids"))) + .grantIds(Arrays.asList("grant_ids")) .build()); RecordedRequest request = server.takeRequest(); Assertions.assertNotNull(request); diff --git a/src/test/java/com/auth0/client/mgmt/ResourceServersWireTest.java b/src/test/java/com/auth0/client/mgmt/ResourceServersWireTest.java index 45b4b859..c95223bc 100644 --- a/src/test/java/com/auth0/client/mgmt/ResourceServersWireTest.java +++ b/src/test/java/com/auth0/client/mgmt/ResourceServersWireTest.java @@ -14,7 +14,6 @@ import com.fasterxml.jackson.databind.JsonNode; import com.fasterxml.jackson.databind.ObjectMapper; import java.util.Arrays; -import java.util.Optional; import okhttp3.mockwebserver.MockResponse; import okhttp3.mockwebserver.MockWebServer; import okhttp3.mockwebserver.RecordedRequest; @@ -56,7 +55,7 @@ public void testList() throws Exception { .perPage(OptionalNullable.of(1)) .includeTotals(OptionalNullable.of(true)) .includeFields(OptionalNullable.of(true)) - .identifiers(Arrays.asList(Optional.of("identifiers"))) + .identifiers(Arrays.asList("identifiers")) .build()); RecordedRequest request = server.takeRequest(); Assertions.assertNotNull(request);