diff --git a/connectors/http-json/element-templates/http-json-connector.json b/connectors/http-json/element-templates/http-json-connector.json index 3634a26ae4..09b9b26bd2 100644 --- a/connectors/http-json/element-templates/http-json-connector.json +++ b/connectors/http-json/element-templates/http-json-connector.json @@ -232,6 +232,7 @@ "group": "authentication", "type": "String", "feel": "optional", + "optional": true, "binding": { "type": "zeebe:input", "name": "authentication.scopes" @@ -247,6 +248,7 @@ "group": "authentication", "type": "String", "feel": "optional", + "optional": true, "binding": { "type": "zeebe:input", "name": "authentication.audience" diff --git a/connectors/http-json/src/main/java/io/camunda/connector/http/auth/OAuthAuthentication.java b/connectors/http-json/src/main/java/io/camunda/connector/http/auth/OAuthAuthentication.java index 596c70c316..88f20a109a 100644 --- a/connectors/http-json/src/main/java/io/camunda/connector/http/auth/OAuthAuthentication.java +++ b/connectors/http-json/src/main/java/io/camunda/connector/http/auth/OAuthAuthentication.java @@ -26,7 +26,7 @@ public class OAuthAuthentication extends Authentication { @NotEmpty @Secret private String oauthTokenEndpoint; @NotEmpty @Secret private String clientId; @NotEmpty @Secret private String clientSecret; - @NotEmpty @Secret private String audience; + @Secret private String audience; @NotEmpty private String clientAuthentication; private String scopes; diff --git a/connectors/http-json/src/test/resources/requests/fail-cases-request-witout-one-requered-field.json b/connectors/http-json/src/test/resources/requests/fail-cases-request-witout-one-requered-field.json index a0931e1ba6..6b868256bf 100644 --- a/connectors/http-json/src/test/resources/requests/fail-cases-request-witout-one-requered-field.json +++ b/connectors/http-json/src/test/resources/requests/fail-cases-request-witout-one-requered-field.json @@ -222,31 +222,6 @@ } } }, - { - "descriptionOfTest": "oauth request without audience", - "method": "post", - "url": "https://abc/def", - "connectionTimeoutInSeconds": "30", - "headers": { - "X-Camunda-Cluster-ID": "abcdef", - "User-Agent": "http-connector-demo" - }, - "authentication":{ - "oauthTokenEndpoint":"https://abc.eu.auth0.com/api/v2/", - "scopes": "read:clients", - "clientId":"secrets.CLIENT_ID", - "clientSecret":"secrets.CLIENT_SECRET", - "type":"oauth-client-credentials-flow", - "clientAuthentication":"basicAuthHeader" - }, - "body": { - "customer": { - "id": 1231231, - "name": "Jane Doe", - "email": "jane.doe@exampe.com" - } - } - }, { "descriptionOfTest": "oauth request without client authentication", "method": "post",