This is an automated email from the ASF dual-hosted git repository. davsclaus pushed a commit to branch main in repository https://gitbox.apache.org/repos/asf/camel.git
The following commit(s) were added to refs/heads/main by this push: new 0e3e540f81f CAMEL-15968: camel-braintree - Add more gateway APIs from never version of braintree (#10809) 0e3e540f81f is described below commit 0e3e540f81f49ed096738557adc7e183a3f11d50 Author: Claus Ibsen <claus.ib...@gmail.com> AuthorDate: Tue Jul 25 08:51:27 2023 +0200 CAMEL-15968: camel-braintree - Add more gateway APIs from never version of braintree (#10809) --- .../apache/camel/catalog/components/braintree.json | 6 +- components/camel-braintree/pom.xml | 27 ++++ .../braintree/BraintreeEndpointUriFactory.java | 4 +- .../OAuthGatewayEndpointConfiguration.java | 55 +++++++ ...AuthGatewayEndpointConfigurationConfigurer.java | 159 +++++++++++++++++++++ .../UsBankAccountGatewayEndpointConfiguration.java | 44 ++++++ ...ountGatewayEndpointConfigurationConfigurer.java | 159 +++++++++++++++++++++ .../braintree/internal/BraintreeApiCollection.java | 18 +++ .../braintree/internal/BraintreeApiName.java | 4 + .../braintree/internal/OAuthGatewayApiMethod.java | 62 ++++++++ .../internal/UsBankAccountGatewayApiMethod.java | 53 +++++++ ...ent.braintree.OAuthGatewayEndpointConfiguration | 2 + ...ntree.UsBankAccountGatewayEndpointConfiguration | 2 + .../camel/component/braintree/braintree.json | 6 +- .../builder/endpoint/StaticEndpointBuilders.java | 12 +- .../dsl/BraintreeEndpointBuilderFactory.java | 12 +- 16 files changed, 610 insertions(+), 15 deletions(-) diff --git a/catalog/camel-catalog/src/generated/resources/org/apache/camel/catalog/components/braintree.json b/catalog/camel-catalog/src/generated/resources/org/apache/camel/catalog/components/braintree.json index 14bb99f01bf..5b533d22798 100644 --- a/catalog/camel-catalog/src/generated/resources/org/apache/camel/catalog/components/braintree.json +++ b/catalog/camel-catalog/src/generated/resources/org/apache/camel/catalog/components/braintree.json @@ -28,7 +28,7 @@ "configuration": { "index": 2, "kind": "property", "displayName": "Configuration", "group": "advanced", "label": "advanced", "required": false, "type": "object", "javaType": "org.apache.camel.component.braintree.BraintreeConfiguration", "deprecated": false, "autowired": false, "secret": false, "description": "Component configuration" } }, "properties": { - "apiName": { "index": 0, "kind": "path", "displayName": "Api Name", "group": "producer", "label": "", "required": true, "type": "object", "javaType": "org.apache.camel.component.braintree.internal.BraintreeApiName", "enum": [ "ADD_ON", "ADDRESS", "CLIENT_TOKEN", "CREDIT_CARD_VERIFICATION", "CUSTOMER", "DISCOUNT", "DISPUTE", "DOCUMENT_UPLOAD", "MERCHANT_ACCOUNT", "PAYMENT_METHOD", "PAYMENT_METHOD_NONCE", "PLAN", "REPORT", "SETTLEMENT_BATCH_SUMMARY", "SUBSCRIPTION", "TRANSACTION", "WEB [...] + "apiName": { "index": 0, "kind": "path", "displayName": "Api Name", "group": "producer", "label": "", "required": true, "type": "object", "javaType": "org.apache.camel.component.braintree.internal.BraintreeApiName", "enum": [ "ADD_ON", "ADDRESS", "CLIENT_TOKEN", "CREDIT_CARD_VERIFICATION", "CUSTOMER", "DISCOUNT", "DISPUTE", "DOCUMENT_UPLOAD", "MERCHANT_ACCOUNT", "PAYMENT_METHOD", "PAYMENT_METHOD_NONCE", "OAUTH", "PLAN", "REPORT", "SETTLEMENT_BATCH_SUMMARY", "SUBSCRIPTION", "TRANSACTI [...] "methodName": { "index": 1, "kind": "path", "displayName": "Method Name", "group": "producer", "label": "", "required": true, "type": "string", "javaType": "java.lang.String", "enum": [ "accept", "addFileEvidence", "addTextEvidence", "cancel", "cancelRelease", "cloneTransaction", "create", "createForCurrency", "credit", "delete", "fetchMerchantAccounts", "finalize", "find", "generate", "grant", "holdInEscrow", "parse", "refund", "releaseFromEscrow", "removeEvidence", "retryCharge", " [...] "environment": { "index": 2, "kind": "parameter", "displayName": "Environment", "group": "producer", "label": "", "required": false, "type": "string", "javaType": "java.lang.String", "deprecated": false, "autowired": false, "secret": false, "configurationClass": "org.apache.camel.component.braintree.BraintreeConfiguration", "configurationField": "configuration", "description": "The environment Either SANDBOX or PRODUCTION" }, "inBody": { "index": 3, "kind": "parameter", "displayName": "In Body", "group": "producer", "label": "", "required": false, "type": "string", "javaType": "java.lang.String", "deprecated": false, "autowired": false, "secret": false, "description": "Sets the name of a parameter to be passed in the exchange In Body" }, @@ -52,6 +52,7 @@ "dispute": { "consumerOnly": false, "producerOnly": true, "description": "Provides methods to interact with Dispute objects", "methods": { "accept": { "description": "Accept a Dispute, given a dispute ID", "signatures": [ "com.braintreegateway.Result<com.braintreegateway.Dispute> accept(String id)" ] }, "addFileEvidence": { "description": "Add File Evidence to a Dispute, given an ID and a FileEvidenceRequest File evidence request", "signatures": [ "com.braintreegateway.Result<com.bra [...] "documentUpload": { "consumerOnly": false, "producerOnly": true, "description": "API to upload evidence documents", "methods": { "create": { "description": "", "signatures": [ "com.braintreegateway.Result<com.braintreegateway.DocumentUpload> create(com.braintreegateway.DocumentUploadRequest request)" ] } } }, "merchantAccount": { "consumerOnly": false, "producerOnly": true, "description": "Provides methods to create, find, and update MerchantAccount objects", "methods": { "create": { "description": "", "signatures": [ "com.braintreegateway.Result<com.braintreegateway.MerchantAccount> create(com.braintreegateway.MerchantAccountRequest request)" ] }, "createForCurrency": { "description": "", "signatures": [ "com.braintreegateway.Result<com.braintreegateway.MerchantAccount> createForCurrency [...] + "oauth": { "consumerOnly": false, "producerOnly": true, "description": "", "methods": { "connectUrl": { "description": "", "signatures": [ "String connectUrl(com.braintreegateway.OAuthConnectUrlRequest request)" ] }, "createTokenFromCode": { "description": "", "signatures": [ "com.braintreegateway.Result<com.braintreegateway.OAuthCredentials> createTokenFromCode(com.braintreegateway.OAuthCredentialsRequest request)" ] }, "createTokenFromRefreshToken": { "description": "", "signatures [...] "paymentMethod": { "consumerOnly": false, "producerOnly": true, "description": "Provides methods to interact with payments", "methods": { "create": { "description": "", "signatures": [ "com.braintreegateway.Result<com.braintreegateway.? extends PaymentMethod> create(com.braintreegateway.PaymentMethodRequest request)" ] }, "delete": { "description": "", "signatures": [ "com.braintreegateway.Result<com.braintreegateway.? extends PaymentMethod> delete(String token)", "com.braintreegatew [...] "paymentMethodNonce": { "consumerOnly": false, "producerOnly": true, "description": "Provides methods to interact with nonce payments", "methods": { "create": { "description": "", "signatures": [ "com.braintreegateway.Result<com.braintreegateway.PaymentMethodNonce> create(String paymentMethodToken)", "com.braintreegateway.Result<com.braintreegateway.PaymentMethodNonce> create(com.braintreegateway.PaymentMethodNonceRequest request)" ] }, "find": { "description": "", "signatures": [ "c [...] "plan": { "consumerOnly": false, "producerOnly": true, "description": "", "methods": { "create": { "description": "", "signatures": [ "com.braintreegateway.Result<com.braintreegateway.Plan> create(com.braintreegateway.PlanRequest request)" ] }, "find": { "description": "", "signatures": [ "com.braintreegateway.Plan find(String id)" ] }, "update": { "description": "", "signatures": [ "com.braintreegateway.Result<com.braintreegateway.Plan> update(String id, com.braintreegateway.PlanReq [...] @@ -59,6 +60,7 @@ "settlementBatchSummary": { "consumerOnly": false, "producerOnly": true, "description": "Provides methods to interact wit settlement summaries", "methods": { "generate": { "description": "", "signatures": [ "com.braintreegateway.Result<com.braintreegateway.SettlementBatchSummary> generate(java.util.Calendar settlementDate)", "com.braintreegateway.Result<com.braintreegateway.SettlementBatchSummary> generate(java.util.Calendar settlementDate, String groupByCustomField)" ] } } }, "subscription": { "consumerOnly": false, "producerOnly": true, "description": "Provides methods to interact with Subscriptions", "methods": { "cancel": { "description": "Cancels the Subscription with the given id", "signatures": [ "com.braintreegateway.Result<com.braintreegateway.Subscription> cancel(String id)" ] }, "create": { "description": "Creates a Subscription", "signatures": [ "com.braintreegateway.Result<com.braintreegateway.Subscription> create(com.braintreegateway.Subscrip [...] "transaction": { "consumerOnly": false, "producerOnly": true, "description": "Provides methods to interact with Transactions", "methods": { "adjustAuthorization": { "description": "Submits the transaction with the given id to be adjusted for the given amount which must be less than or equal to the authorization amount", "signatures": [ "com.braintreegateway.Result<com.braintreegateway.Transaction> adjustAuthorization(String id, com.braintreegateway.TransactionRequest request)", "com. [...] + "usBankAccount": { "consumerOnly": false, "producerOnly": true, "description": "", "methods": { "find": { "description": "", "signatures": [ "com.braintreegateway.UsBankAccount find(String token)" ] }, "sale": { "description": "", "signatures": [ "com.braintreegateway.Result<com.braintreegateway.Transaction> sale(String token, com.braintreegateway.TransactionRequest transactionRequest)" ] } } }, "webhookNotification": { "consumerOnly": false, "producerOnly": true, "description": "To retrieve notifications via webhooks", "methods": { "parse": { "description": "", "signatures": [ "com.braintreegateway.WebhookNotification parse(String signature, String payload)" ] }, "parseWithoutSignatureVerification": { "description": "", "signatures": [ "com.braintreegateway.WebhookNotification parseWithoutSignatureVerification(String payload)" ] }, "verify": { "description": "", "signatures [...] }, "apiProperties": { @@ -69,6 +71,7 @@ "dispute": { "methods": { "accept": { "properties": { "id": { "index": 0, "kind": "parameter", "displayName": "Id", "group": "producer", "label": "", "required": false, "type": "string", "javaType": "java.lang.String", "deprecated": false, "autowired": false, "secret": false, "description": "The dispute id to accept", "optional": false } } }, "addFileEvidence": { "properties": { "disputeId": { "index": 0, "kind": "parameter", "displayName": "Dispute Id", "group": "producer", "label": [...] "documentUpload": { "methods": { "create": { "properties": { "request": { "index": 0, "kind": "parameter", "displayName": "Request", "group": "producer", "label": "", "required": false, "type": "object", "javaType": "com.braintreegateway.DocumentUploadRequest", "deprecated": false, "autowired": false, "secret": false, "description": "", "optional": false } } } } }, "merchantAccount": { "methods": { "create": { "properties": { "request": { "index": 0, "kind": "parameter", "displayName": "Request", "group": "producer", "label": "", "required": false, "type": "object", "javaType": "com.braintreegateway.MerchantAccountRequest", "deprecated": false, "autowired": false, "secret": false, "description": "", "optional": false } } }, "createForCurrency": { "properties": { "currencyRequest": { "index": 0, "kind": "parameter", "displayName": "Currency Requ [...] + "oauth": { "methods": { "connectUrl": { "properties": { "connectRequest": { "index": 0, "kind": "parameter", "displayName": "Connect Request", "group": "producer", "label": "", "required": false, "type": "object", "javaType": "com.braintreegateway.OAuthConnectUrlRequest", "deprecated": false, "autowired": false, "secret": false, "description": "", "optional": false } } }, "createTokenFromCode": { "properties": { "request": { "index": 0, "kind": "parameter", "displayName": "Request", [...] "paymentMethod": { "methods": { "create": { "properties": { "request": { "index": 0, "kind": "parameter", "displayName": "Request", "group": "producer", "label": "", "required": false, "type": "object", "javaType": "com.braintreegateway.PaymentMethodRequest", "deprecated": false, "autowired": false, "secret": false, "description": "", "optional": false } } }, "delete": { "properties": { "deleteRequest": { "index": 0, "kind": "parameter", "displayName": "Delete Request", "group": "pro [...] "paymentMethodNonce": { "methods": { "create": { "properties": { "paymentMethodToken": { "index": 0, "kind": "parameter", "displayName": "Payment Method Token", "group": "producer", "label": "", "required": false, "type": "string", "javaType": "java.lang.String", "deprecated": false, "autowired": false, "secret": false, "description": "", "optional": false }, "request": { "index": 1, "kind": "parameter", "displayName": "Request", "group": "producer", "label": "", "required": false, " [...] "plan": { "methods": { "create": { "properties": { "request": { "index": 0, "kind": "parameter", "displayName": "Request", "group": "producer", "label": "", "required": false, "type": "object", "javaType": "com.braintreegateway.PlanRequest", "deprecated": false, "autowired": false, "secret": false, "description": "", "optional": false } } }, "find": { "properties": { "id": { "index": 0, "kind": "parameter", "displayName": "Id", "group": "producer", "label": "", "required": false, "ty [...] @@ -76,6 +79,7 @@ "settlementBatchSummary": { "methods": { "generate": { "properties": { "groupByCustomField": { "index": 0, "kind": "parameter", "displayName": "Group By Custom Field", "group": "producer", "label": "", "required": false, "type": "string", "javaType": "java.lang.String", "deprecated": false, "autowired": false, "secret": false, "description": "", "optional": false }, "settlementDate": { "index": 2, "kind": "parameter", "displayName": "Settlement Date", "group": "producer", "label": "" [...] "subscription": { "methods": { "cancel": { "properties": { "id": { "index": 0, "kind": "parameter", "displayName": "Id", "group": "producer", "label": "", "required": false, "type": "string", "javaType": "java.lang.String", "deprecated": false, "autowired": false, "secret": false, "description": "Of the Subscription to cancel", "optional": false } } }, "create": { "properties": { "request": { "index": 0, "kind": "parameter", "displayName": "Request", "group": "producer", "label": "", [...] "transaction": { "methods": { "adjustAuthorization": { "properties": { "amount": { "index": 0, "kind": "parameter", "displayName": "Amount", "group": "producer", "label": "", "required": false, "type": "object", "javaType": "java.math.BigDecimal", "deprecated": false, "autowired": false, "secret": false, "description": "To be adjusted", "optional": false }, "id": { "index": 1, "kind": "parameter", "displayName": "Id", "group": "producer", "label": "", "required": false, "type": "stri [...] + "usBankAccount": { "methods": { "find": { "properties": { "token": { "index": 0, "kind": "parameter", "displayName": "Token", "group": "producer", "label": "", "required": false, "type": "string", "javaType": "java.lang.String", "deprecated": false, "autowired": false, "secret": false, "description": "", "optional": false } } }, "sale": { "properties": { "token": { "index": 0, "kind": "parameter", "displayName": "Token", "group": "producer", "label": "", "required": false, "type": "s [...] "webhookNotification": { "methods": { "parse": { "properties": { "payload": { "index": 0, "kind": "parameter", "displayName": "Payload", "group": "producer", "label": "", "required": false, "type": "string", "javaType": "java.lang.String", "deprecated": false, "autowired": false, "secret": false, "description": "", "optional": false }, "signature": { "index": 1, "kind": "parameter", "displayName": "Signature", "group": "producer", "label": "", "required": false, "type": "string", "ja [...] } } diff --git a/components/camel-braintree/pom.xml b/components/camel-braintree/pom.xml index 2615dc29b6d..8725b57a58d 100644 --- a/components/camel-braintree/pom.xml +++ b/components/camel-braintree/pom.xml @@ -184,6 +184,28 @@ <excludeMethods>.*parse.*</excludeMethods> </fromJavasource> </api> + <api> + <apiName>oauth</apiName> + <proxyClass>com.braintreegateway.OAuthGateway</proxyClass> + <fromJavasource /> + <substitutions> + <substitution> + <method>^.+$</method> + <argName>^.+$</argName> + <argType>com.braintreegateway.OAuthConnectUrlRequest</argType> + <replacement>connectRequest</replacement> + <replaceWithType>false</replaceWithType> + </substitution> + <substitution> + <method>^.+$</method> + <argName>^.+$</argName> + <argType>com.braintreegateway.MerchantAccountCreateForCurrencyRequest + </argType> + <replacement>currencyRequest</replacement> + <replaceWithType>false</replaceWithType> + </substitution> + </substitutions> + </api> <api> <apiName>plan</apiName> <proxyClass>com.braintreegateway.PlanGateway</proxyClass> @@ -235,6 +257,11 @@ </substitution> </substitutions> </api> + <api> + <apiName>usBankAccount</apiName> + <proxyClass>com.braintreegateway.UsBankAccountGateway</proxyClass> + <fromJavasource /> + </api> <api> <apiName>webhookNotification</apiName> <apiDescription>To retrieve notifications via webhooks</apiDescription> diff --git a/components/camel-braintree/src/generated/java/org/apache/camel/component/braintree/BraintreeEndpointUriFactory.java b/components/camel-braintree/src/generated/java/org/apache/camel/component/braintree/BraintreeEndpointUriFactory.java index 3fbeabb0a8f..a0331fd7d79 100644 --- a/components/camel-braintree/src/generated/java/org/apache/camel/component/braintree/BraintreeEndpointUriFactory.java +++ b/components/camel-braintree/src/generated/java/org/apache/camel/component/braintree/BraintreeEndpointUriFactory.java @@ -21,13 +21,14 @@ public class BraintreeEndpointUriFactory extends org.apache.camel.support.compon private static final Set<String> SECRET_PROPERTY_NAMES; private static final Set<String> MULTI_VALUE_PREFIXES; static { - Set<String> props = new HashSet<>(44); + Set<String> props = new HashSet<>(46); props.add("accessToken"); props.add("amount"); props.add("apiName"); props.add("associationFilterId"); props.add("challenge"); props.add("cloneRequest"); + props.add("connectRequest"); props.add("content"); props.add("currencyRequest"); props.add("customerId"); @@ -66,6 +67,7 @@ public class BraintreeEndpointUriFactory extends org.apache.camel.support.compon props.add("subscriptionId"); props.add("textEvidenceRequest"); props.add("token"); + props.add("transactionRequest"); PROPERTY_NAMES = Collections.unmodifiableSet(props); Set<String> secretProps = new HashSet<>(3); secretProps.add("accessToken"); diff --git a/components/camel-braintree/src/generated/java/org/apache/camel/component/braintree/OAuthGatewayEndpointConfiguration.java b/components/camel-braintree/src/generated/java/org/apache/camel/component/braintree/OAuthGatewayEndpointConfiguration.java new file mode 100644 index 00000000000..2b9e9568cfb --- /dev/null +++ b/components/camel-braintree/src/generated/java/org/apache/camel/component/braintree/OAuthGatewayEndpointConfiguration.java @@ -0,0 +1,55 @@ +/* + * Camel EndpointConfiguration generated by camel-api-component-maven-plugin + */ +package org.apache.camel.component.braintree; + +import org.apache.camel.spi.ApiMethod; +import org.apache.camel.spi.ApiParam; +import org.apache.camel.spi.ApiParams; +import org.apache.camel.spi.Configurer; +import org.apache.camel.spi.UriParam; +import org.apache.camel.spi.UriParams; + +/** + * Camel endpoint configuration for {@link com.braintreegateway.OAuthGateway}. + */ +@ApiParams(apiName = "oauth", + description = "", + apiMethods = {@ApiMethod(methodName = "connectUrl", signatures={"String connectUrl(com.braintreegateway.OAuthConnectUrlRequest request)"}), @ApiMethod(methodName = "createTokenFromCode", signatures={"com.braintreegateway.Result<com.braintreegateway.OAuthCredentials> createTokenFromCode(com.braintreegateway.OAuthCredentialsRequest request)"}), @ApiMethod(methodName = "createTokenFromRefreshToken", signatures={"com.braintreegateway.Result<com.braintreegateway.OAuthCredentials> c [...] +@UriParams +@Configurer(extended = true) +public final class OAuthGatewayEndpointConfiguration extends BraintreeConfiguration { + @UriParam + @ApiParam(optional = false, apiMethods = {@ApiMethod(methodName = "revokeAccessToken")}) + private String accessToken; + @UriParam + @ApiParam(optional = false, apiMethods = {@ApiMethod(methodName = "connectUrl")}) + private com.braintreegateway.OAuthConnectUrlRequest connectRequest; + @UriParam + @ApiParam(optional = false, apiMethods = {@ApiMethod(methodName = "createTokenFromCode"), @ApiMethod(methodName = "createTokenFromRefreshToken")}) + private com.braintreegateway.OAuthCredentialsRequest request; + + public String getAccessToken() { + return accessToken; + } + + public void setAccessToken(String accessToken) { + this.accessToken = accessToken; + } + + public com.braintreegateway.OAuthConnectUrlRequest getConnectRequest() { + return connectRequest; + } + + public void setConnectRequest(com.braintreegateway.OAuthConnectUrlRequest connectRequest) { + this.connectRequest = connectRequest; + } + + public com.braintreegateway.OAuthCredentialsRequest getRequest() { + return request; + } + + public void setRequest(com.braintreegateway.OAuthCredentialsRequest request) { + this.request = request; + } +} diff --git a/components/camel-braintree/src/generated/java/org/apache/camel/component/braintree/OAuthGatewayEndpointConfigurationConfigurer.java b/components/camel-braintree/src/generated/java/org/apache/camel/component/braintree/OAuthGatewayEndpointConfigurationConfigurer.java new file mode 100644 index 00000000000..49d130b93e6 --- /dev/null +++ b/components/camel-braintree/src/generated/java/org/apache/camel/component/braintree/OAuthGatewayEndpointConfigurationConfigurer.java @@ -0,0 +1,159 @@ +/* Generated by camel build tools - do NOT edit this file! */ +package org.apache.camel.component.braintree; + +import java.util.Map; + +import org.apache.camel.CamelContext; +import org.apache.camel.spi.ExtendedPropertyConfigurerGetter; +import org.apache.camel.spi.PropertyConfigurerGetter; +import org.apache.camel.spi.ConfigurerStrategy; +import org.apache.camel.spi.GeneratedPropertyConfigurer; +import org.apache.camel.util.CaseInsensitiveMap; +import org.apache.camel.component.braintree.OAuthGatewayEndpointConfiguration; + +/** + * Generated by camel build tools - do NOT edit this file! + */ +@SuppressWarnings("unchecked") +public class OAuthGatewayEndpointConfigurationConfigurer extends org.apache.camel.support.component.PropertyConfigurerSupport implements GeneratedPropertyConfigurer, ExtendedPropertyConfigurerGetter { + + private static final Map<String, Object> ALL_OPTIONS; + static { + Map<String, Object> map = new CaseInsensitiveMap(); + map.put("AccessToken", java.lang.String.class); + map.put("ApiName", org.apache.camel.component.braintree.internal.BraintreeApiName.class); + map.put("ConnectRequest", com.braintreegateway.OAuthConnectUrlRequest.class); + map.put("Environment", java.lang.String.class); + map.put("HttpLogLevel", java.lang.String.class); + map.put("HttpLogName", java.lang.String.class); + map.put("HttpReadTimeout", java.lang.Integer.class); + map.put("LogHandlerEnabled", boolean.class); + map.put("MerchantId", java.lang.String.class); + map.put("MethodName", java.lang.String.class); + map.put("PrivateKey", java.lang.String.class); + map.put("ProxyHost", java.lang.String.class); + map.put("ProxyPort", java.lang.Integer.class); + map.put("PublicKey", java.lang.String.class); + map.put("Request", com.braintreegateway.OAuthCredentialsRequest.class); + ALL_OPTIONS = map; + } + + @Override + public boolean configure(CamelContext camelContext, Object obj, String name, Object value, boolean ignoreCase) { + org.apache.camel.component.braintree.OAuthGatewayEndpointConfiguration target = (org.apache.camel.component.braintree.OAuthGatewayEndpointConfiguration) obj; + switch (ignoreCase ? name.toLowerCase() : name) { + case "accesstoken": + case "AccessToken": target.setAccessToken(property(camelContext, java.lang.String.class, value)); return true; + case "apiname": + case "ApiName": target.setApiName(property(camelContext, org.apache.camel.component.braintree.internal.BraintreeApiName.class, value)); return true; + case "connectrequest": + case "ConnectRequest": target.setConnectRequest(property(camelContext, com.braintreegateway.OAuthConnectUrlRequest.class, value)); return true; + case "environment": + case "Environment": target.setEnvironment(property(camelContext, java.lang.String.class, value)); return true; + case "httploglevel": + case "HttpLogLevel": target.setHttpLogLevel(property(camelContext, java.lang.String.class, value)); return true; + case "httplogname": + case "HttpLogName": target.setHttpLogName(property(camelContext, java.lang.String.class, value)); return true; + case "httpreadtimeout": + case "HttpReadTimeout": target.setHttpReadTimeout(property(camelContext, java.lang.Integer.class, value)); return true; + case "loghandlerenabled": + case "LogHandlerEnabled": target.setLogHandlerEnabled(property(camelContext, boolean.class, value)); return true; + case "merchantid": + case "MerchantId": target.setMerchantId(property(camelContext, java.lang.String.class, value)); return true; + case "methodname": + case "MethodName": target.setMethodName(property(camelContext, java.lang.String.class, value)); return true; + case "privatekey": + case "PrivateKey": target.setPrivateKey(property(camelContext, java.lang.String.class, value)); return true; + case "proxyhost": + case "ProxyHost": target.setProxyHost(property(camelContext, java.lang.String.class, value)); return true; + case "proxyport": + case "ProxyPort": target.setProxyPort(property(camelContext, java.lang.Integer.class, value)); return true; + case "publickey": + case "PublicKey": target.setPublicKey(property(camelContext, java.lang.String.class, value)); return true; + case "request": + case "Request": target.setRequest(property(camelContext, com.braintreegateway.OAuthCredentialsRequest.class, value)); return true; + default: return false; + } + } + + @Override + public Map<String, Object> getAllOptions(Object target) { + return ALL_OPTIONS; + } + + @Override + public Class<?> getOptionType(String name, boolean ignoreCase) { + switch (ignoreCase ? name.toLowerCase() : name) { + case "accesstoken": + case "AccessToken": return java.lang.String.class; + case "apiname": + case "ApiName": return org.apache.camel.component.braintree.internal.BraintreeApiName.class; + case "connectrequest": + case "ConnectRequest": return com.braintreegateway.OAuthConnectUrlRequest.class; + case "environment": + case "Environment": return java.lang.String.class; + case "httploglevel": + case "HttpLogLevel": return java.lang.String.class; + case "httplogname": + case "HttpLogName": return java.lang.String.class; + case "httpreadtimeout": + case "HttpReadTimeout": return java.lang.Integer.class; + case "loghandlerenabled": + case "LogHandlerEnabled": return boolean.class; + case "merchantid": + case "MerchantId": return java.lang.String.class; + case "methodname": + case "MethodName": return java.lang.String.class; + case "privatekey": + case "PrivateKey": return java.lang.String.class; + case "proxyhost": + case "ProxyHost": return java.lang.String.class; + case "proxyport": + case "ProxyPort": return java.lang.Integer.class; + case "publickey": + case "PublicKey": return java.lang.String.class; + case "request": + case "Request": return com.braintreegateway.OAuthCredentialsRequest.class; + default: return null; + } + } + + @Override + public Object getOptionValue(Object obj, String name, boolean ignoreCase) { + org.apache.camel.component.braintree.OAuthGatewayEndpointConfiguration target = (org.apache.camel.component.braintree.OAuthGatewayEndpointConfiguration) obj; + switch (ignoreCase ? name.toLowerCase() : name) { + case "accesstoken": + case "AccessToken": return target.getAccessToken(); + case "apiname": + case "ApiName": return target.getApiName(); + case "connectrequest": + case "ConnectRequest": return target.getConnectRequest(); + case "environment": + case "Environment": return target.getEnvironment(); + case "httploglevel": + case "HttpLogLevel": return target.getHttpLogLevel(); + case "httplogname": + case "HttpLogName": return target.getHttpLogName(); + case "httpreadtimeout": + case "HttpReadTimeout": return target.getHttpReadTimeout(); + case "loghandlerenabled": + case "LogHandlerEnabled": return target.isLogHandlerEnabled(); + case "merchantid": + case "MerchantId": return target.getMerchantId(); + case "methodname": + case "MethodName": return target.getMethodName(); + case "privatekey": + case "PrivateKey": return target.getPrivateKey(); + case "proxyhost": + case "ProxyHost": return target.getProxyHost(); + case "proxyport": + case "ProxyPort": return target.getProxyPort(); + case "publickey": + case "PublicKey": return target.getPublicKey(); + case "request": + case "Request": return target.getRequest(); + default: return null; + } + } +} + diff --git a/components/camel-braintree/src/generated/java/org/apache/camel/component/braintree/UsBankAccountGatewayEndpointConfiguration.java b/components/camel-braintree/src/generated/java/org/apache/camel/component/braintree/UsBankAccountGatewayEndpointConfiguration.java new file mode 100644 index 00000000000..1f437849e74 --- /dev/null +++ b/components/camel-braintree/src/generated/java/org/apache/camel/component/braintree/UsBankAccountGatewayEndpointConfiguration.java @@ -0,0 +1,44 @@ +/* + * Camel EndpointConfiguration generated by camel-api-component-maven-plugin + */ +package org.apache.camel.component.braintree; + +import org.apache.camel.spi.ApiMethod; +import org.apache.camel.spi.ApiParam; +import org.apache.camel.spi.ApiParams; +import org.apache.camel.spi.Configurer; +import org.apache.camel.spi.UriParam; +import org.apache.camel.spi.UriParams; + +/** + * Camel endpoint configuration for {@link com.braintreegateway.UsBankAccountGateway}. + */ +@ApiParams(apiName = "usBankAccount", + description = "", + apiMethods = {@ApiMethod(methodName = "find", signatures={"com.braintreegateway.UsBankAccount find(String token)"}), @ApiMethod(methodName = "sale", signatures={"com.braintreegateway.Result<com.braintreegateway.Transaction> sale(String token, com.braintreegateway.TransactionRequest transactionRequest)"})}, aliases = {}) +@UriParams +@Configurer(extended = true) +public final class UsBankAccountGatewayEndpointConfiguration extends BraintreeConfiguration { + @UriParam + @ApiParam(optional = false, apiMethods = {@ApiMethod(methodName = "find"), @ApiMethod(methodName = "sale")}) + private String token; + @UriParam + @ApiParam(optional = false, apiMethods = {@ApiMethod(methodName = "sale")}) + private com.braintreegateway.TransactionRequest transactionRequest; + + public String getToken() { + return token; + } + + public void setToken(String token) { + this.token = token; + } + + public com.braintreegateway.TransactionRequest getTransactionRequest() { + return transactionRequest; + } + + public void setTransactionRequest(com.braintreegateway.TransactionRequest transactionRequest) { + this.transactionRequest = transactionRequest; + } +} diff --git a/components/camel-braintree/src/generated/java/org/apache/camel/component/braintree/UsBankAccountGatewayEndpointConfigurationConfigurer.java b/components/camel-braintree/src/generated/java/org/apache/camel/component/braintree/UsBankAccountGatewayEndpointConfigurationConfigurer.java new file mode 100644 index 00000000000..8e725ab58a2 --- /dev/null +++ b/components/camel-braintree/src/generated/java/org/apache/camel/component/braintree/UsBankAccountGatewayEndpointConfigurationConfigurer.java @@ -0,0 +1,159 @@ +/* Generated by camel build tools - do NOT edit this file! */ +package org.apache.camel.component.braintree; + +import java.util.Map; + +import org.apache.camel.CamelContext; +import org.apache.camel.spi.ExtendedPropertyConfigurerGetter; +import org.apache.camel.spi.PropertyConfigurerGetter; +import org.apache.camel.spi.ConfigurerStrategy; +import org.apache.camel.spi.GeneratedPropertyConfigurer; +import org.apache.camel.util.CaseInsensitiveMap; +import org.apache.camel.component.braintree.UsBankAccountGatewayEndpointConfiguration; + +/** + * Generated by camel build tools - do NOT edit this file! + */ +@SuppressWarnings("unchecked") +public class UsBankAccountGatewayEndpointConfigurationConfigurer extends org.apache.camel.support.component.PropertyConfigurerSupport implements GeneratedPropertyConfigurer, ExtendedPropertyConfigurerGetter { + + private static final Map<String, Object> ALL_OPTIONS; + static { + Map<String, Object> map = new CaseInsensitiveMap(); + map.put("AccessToken", java.lang.String.class); + map.put("ApiName", org.apache.camel.component.braintree.internal.BraintreeApiName.class); + map.put("Environment", java.lang.String.class); + map.put("HttpLogLevel", java.lang.String.class); + map.put("HttpLogName", java.lang.String.class); + map.put("HttpReadTimeout", java.lang.Integer.class); + map.put("LogHandlerEnabled", boolean.class); + map.put("MerchantId", java.lang.String.class); + map.put("MethodName", java.lang.String.class); + map.put("PrivateKey", java.lang.String.class); + map.put("ProxyHost", java.lang.String.class); + map.put("ProxyPort", java.lang.Integer.class); + map.put("PublicKey", java.lang.String.class); + map.put("Token", java.lang.String.class); + map.put("TransactionRequest", com.braintreegateway.TransactionRequest.class); + ALL_OPTIONS = map; + } + + @Override + public boolean configure(CamelContext camelContext, Object obj, String name, Object value, boolean ignoreCase) { + org.apache.camel.component.braintree.UsBankAccountGatewayEndpointConfiguration target = (org.apache.camel.component.braintree.UsBankAccountGatewayEndpointConfiguration) obj; + switch (ignoreCase ? name.toLowerCase() : name) { + case "accesstoken": + case "AccessToken": target.setAccessToken(property(camelContext, java.lang.String.class, value)); return true; + case "apiname": + case "ApiName": target.setApiName(property(camelContext, org.apache.camel.component.braintree.internal.BraintreeApiName.class, value)); return true; + case "environment": + case "Environment": target.setEnvironment(property(camelContext, java.lang.String.class, value)); return true; + case "httploglevel": + case "HttpLogLevel": target.setHttpLogLevel(property(camelContext, java.lang.String.class, value)); return true; + case "httplogname": + case "HttpLogName": target.setHttpLogName(property(camelContext, java.lang.String.class, value)); return true; + case "httpreadtimeout": + case "HttpReadTimeout": target.setHttpReadTimeout(property(camelContext, java.lang.Integer.class, value)); return true; + case "loghandlerenabled": + case "LogHandlerEnabled": target.setLogHandlerEnabled(property(camelContext, boolean.class, value)); return true; + case "merchantid": + case "MerchantId": target.setMerchantId(property(camelContext, java.lang.String.class, value)); return true; + case "methodname": + case "MethodName": target.setMethodName(property(camelContext, java.lang.String.class, value)); return true; + case "privatekey": + case "PrivateKey": target.setPrivateKey(property(camelContext, java.lang.String.class, value)); return true; + case "proxyhost": + case "ProxyHost": target.setProxyHost(property(camelContext, java.lang.String.class, value)); return true; + case "proxyport": + case "ProxyPort": target.setProxyPort(property(camelContext, java.lang.Integer.class, value)); return true; + case "publickey": + case "PublicKey": target.setPublicKey(property(camelContext, java.lang.String.class, value)); return true; + case "token": + case "Token": target.setToken(property(camelContext, java.lang.String.class, value)); return true; + case "transactionrequest": + case "TransactionRequest": target.setTransactionRequest(property(camelContext, com.braintreegateway.TransactionRequest.class, value)); return true; + default: return false; + } + } + + @Override + public Map<String, Object> getAllOptions(Object target) { + return ALL_OPTIONS; + } + + @Override + public Class<?> getOptionType(String name, boolean ignoreCase) { + switch (ignoreCase ? name.toLowerCase() : name) { + case "accesstoken": + case "AccessToken": return java.lang.String.class; + case "apiname": + case "ApiName": return org.apache.camel.component.braintree.internal.BraintreeApiName.class; + case "environment": + case "Environment": return java.lang.String.class; + case "httploglevel": + case "HttpLogLevel": return java.lang.String.class; + case "httplogname": + case "HttpLogName": return java.lang.String.class; + case "httpreadtimeout": + case "HttpReadTimeout": return java.lang.Integer.class; + case "loghandlerenabled": + case "LogHandlerEnabled": return boolean.class; + case "merchantid": + case "MerchantId": return java.lang.String.class; + case "methodname": + case "MethodName": return java.lang.String.class; + case "privatekey": + case "PrivateKey": return java.lang.String.class; + case "proxyhost": + case "ProxyHost": return java.lang.String.class; + case "proxyport": + case "ProxyPort": return java.lang.Integer.class; + case "publickey": + case "PublicKey": return java.lang.String.class; + case "token": + case "Token": return java.lang.String.class; + case "transactionrequest": + case "TransactionRequest": return com.braintreegateway.TransactionRequest.class; + default: return null; + } + } + + @Override + public Object getOptionValue(Object obj, String name, boolean ignoreCase) { + org.apache.camel.component.braintree.UsBankAccountGatewayEndpointConfiguration target = (org.apache.camel.component.braintree.UsBankAccountGatewayEndpointConfiguration) obj; + switch (ignoreCase ? name.toLowerCase() : name) { + case "accesstoken": + case "AccessToken": return target.getAccessToken(); + case "apiname": + case "ApiName": return target.getApiName(); + case "environment": + case "Environment": return target.getEnvironment(); + case "httploglevel": + case "HttpLogLevel": return target.getHttpLogLevel(); + case "httplogname": + case "HttpLogName": return target.getHttpLogName(); + case "httpreadtimeout": + case "HttpReadTimeout": return target.getHttpReadTimeout(); + case "loghandlerenabled": + case "LogHandlerEnabled": return target.isLogHandlerEnabled(); + case "merchantid": + case "MerchantId": return target.getMerchantId(); + case "methodname": + case "MethodName": return target.getMethodName(); + case "privatekey": + case "PrivateKey": return target.getPrivateKey(); + case "proxyhost": + case "ProxyHost": return target.getProxyHost(); + case "proxyport": + case "ProxyPort": return target.getProxyPort(); + case "publickey": + case "PublicKey": return target.getPublicKey(); + case "token": + case "Token": return target.getToken(); + case "transactionrequest": + case "TransactionRequest": return target.getTransactionRequest(); + default: return null; + } + } +} + diff --git a/components/camel-braintree/src/generated/java/org/apache/camel/component/braintree/internal/BraintreeApiCollection.java b/components/camel-braintree/src/generated/java/org/apache/camel/component/braintree/internal/BraintreeApiCollection.java index d207d029360..09af0956627 100644 --- a/components/camel-braintree/src/generated/java/org/apache/camel/component/braintree/internal/BraintreeApiCollection.java +++ b/components/camel-braintree/src/generated/java/org/apache/camel/component/braintree/internal/BraintreeApiCollection.java @@ -21,11 +21,13 @@ import org.apache.camel.component.braintree.DocumentUploadGatewayEndpointConfigu import org.apache.camel.component.braintree.MerchantAccountGatewayEndpointConfiguration; import org.apache.camel.component.braintree.PaymentMethodGatewayEndpointConfiguration; import org.apache.camel.component.braintree.PaymentMethodNonceGatewayEndpointConfiguration; +import org.apache.camel.component.braintree.OAuthGatewayEndpointConfiguration; import org.apache.camel.component.braintree.PlanGatewayEndpointConfiguration; import org.apache.camel.component.braintree.ReportGatewayEndpointConfiguration; import org.apache.camel.component.braintree.SettlementBatchSummaryGatewayEndpointConfiguration; import org.apache.camel.component.braintree.SubscriptionGatewayEndpointConfiguration; import org.apache.camel.component.braintree.TransactionGatewayEndpointConfiguration; +import org.apache.camel.component.braintree.UsBankAccountGatewayEndpointConfiguration; import org.apache.camel.component.braintree.WebhookNotificationGatewayEndpointConfiguration; import org.apache.camel.support.component.ApiCollection; @@ -101,6 +103,11 @@ public final class BraintreeApiCollection extends ApiCollection<BraintreeApiName apiHelpers.put(BraintreeApiName.PAYMENT_METHOD_NONCE, new ApiMethodHelper<>(PaymentMethodNonceGatewayApiMethod.class, aliases, nullableArgs)); apiMethods.put(PaymentMethodNonceGatewayApiMethod.class, BraintreeApiName.PAYMENT_METHOD_NONCE); + aliases.clear(); + nullableArgs = Arrays.asList(); + apiHelpers.put(BraintreeApiName.OAUTH, new ApiMethodHelper<>(OAuthGatewayApiMethod.class, aliases, nullableArgs)); + apiMethods.put(OAuthGatewayApiMethod.class, BraintreeApiName.OAUTH); + aliases.clear(); nullableArgs = Arrays.asList(); apiHelpers.put(BraintreeApiName.PLAN, new ApiMethodHelper<>(PlanGatewayApiMethod.class, aliases, nullableArgs)); @@ -126,6 +133,11 @@ public final class BraintreeApiCollection extends ApiCollection<BraintreeApiName apiHelpers.put(BraintreeApiName.TRANSACTION, new ApiMethodHelper<>(TransactionGatewayApiMethod.class, aliases, nullableArgs)); apiMethods.put(TransactionGatewayApiMethod.class, BraintreeApiName.TRANSACTION); + aliases.clear(); + nullableArgs = Arrays.asList(); + apiHelpers.put(BraintreeApiName.US_BANK_ACCOUNT, new ApiMethodHelper<>(UsBankAccountGatewayApiMethod.class, aliases, nullableArgs)); + apiMethods.put(UsBankAccountGatewayApiMethod.class, BraintreeApiName.US_BANK_ACCOUNT); + aliases.clear(); nullableArgs = Arrays.asList(); apiHelpers.put(BraintreeApiName.WEBHOOK_NOTIFICATION, new ApiMethodHelper<>(WebhookNotificationGatewayApiMethod.class, aliases, nullableArgs)); @@ -171,6 +183,9 @@ public final class BraintreeApiCollection extends ApiCollection<BraintreeApiName case PAYMENT_METHOD_NONCE: result = new PaymentMethodNonceGatewayEndpointConfiguration(); break; + case OAUTH: + result = new OAuthGatewayEndpointConfiguration(); + break; case PLAN: result = new PlanGatewayEndpointConfiguration(); break; @@ -186,6 +201,9 @@ public final class BraintreeApiCollection extends ApiCollection<BraintreeApiName case TRANSACTION: result = new TransactionGatewayEndpointConfiguration(); break; + case US_BANK_ACCOUNT: + result = new UsBankAccountGatewayEndpointConfiguration(); + break; case WEBHOOK_NOTIFICATION: result = new WebhookNotificationGatewayEndpointConfiguration(); break; diff --git a/components/camel-braintree/src/generated/java/org/apache/camel/component/braintree/internal/BraintreeApiName.java b/components/camel-braintree/src/generated/java/org/apache/camel/component/braintree/internal/BraintreeApiName.java index 8a0488df6ff..856b59f2f64 100644 --- a/components/camel-braintree/src/generated/java/org/apache/camel/component/braintree/internal/BraintreeApiName.java +++ b/components/camel-braintree/src/generated/java/org/apache/camel/component/braintree/internal/BraintreeApiName.java @@ -32,6 +32,8 @@ public enum BraintreeApiName implements ApiName { PAYMENT_METHOD_NONCE("paymentMethodNonce"), + OAUTH("oauth"), + PLAN("plan"), REPORT("report"), @@ -42,6 +44,8 @@ public enum BraintreeApiName implements ApiName { TRANSACTION("transaction"), + US_BANK_ACCOUNT("usBankAccount"), + WEBHOOK_NOTIFICATION("webhookNotification"); diff --git a/components/camel-braintree/src/generated/java/org/apache/camel/component/braintree/internal/OAuthGatewayApiMethod.java b/components/camel-braintree/src/generated/java/org/apache/camel/component/braintree/internal/OAuthGatewayApiMethod.java new file mode 100644 index 00000000000..28a21b3ae1b --- /dev/null +++ b/components/camel-braintree/src/generated/java/org/apache/camel/component/braintree/internal/OAuthGatewayApiMethod.java @@ -0,0 +1,62 @@ +/* + * Camel ApiMethod Enumeration generated by camel-api-component-maven-plugin + */ +package org.apache.camel.component.braintree.internal; + +import java.lang.reflect.Method; +import java.util.List; + +import com.braintreegateway.OAuthGateway; + +import org.apache.camel.support.component.ApiMethod; +import org.apache.camel.support.component.ApiMethodArg; +import org.apache.camel.support.component.ApiMethodImpl; + +import static org.apache.camel.support.component.ApiMethodArg.arg; + +/** + * Camel {@link ApiMethod} Enumeration for com.braintreegateway.OAuthGateway + */ +public enum OAuthGatewayApiMethod implements ApiMethod { + + CONNECT_URL( + String.class, + "connectUrl", + arg("connectRequest", com.braintreegateway.OAuthConnectUrlRequest.class)), + + CREATE_TOKEN_FROM_CODE( + com.braintreegateway.Result.class, + "createTokenFromCode", + arg("request", com.braintreegateway.OAuthCredentialsRequest.class)), + + CREATE_TOKEN_FROM_REFRESH_TOKEN( + com.braintreegateway.Result.class, + "createTokenFromRefreshToken", + arg("request", com.braintreegateway.OAuthCredentialsRequest.class)), + + REVOKE_ACCESS_TOKEN( + com.braintreegateway.Result.class, + "revokeAccessToken", + arg("accessToken", String.class)); + + private final ApiMethod apiMethod; + + private OAuthGatewayApiMethod(Class<?> resultType, String name, ApiMethodArg... args) { + this.apiMethod = new ApiMethodImpl(OAuthGateway.class, resultType, name, args); + } + + @Override + public String getName() { return apiMethod.getName(); } + + @Override + public Class<?> getResultType() { return apiMethod.getResultType(); } + + @Override + public List<String> getArgNames() { return apiMethod.getArgNames(); } + + @Override + public List<Class<?>> getArgTypes() { return apiMethod.getArgTypes(); } + + @Override + public Method getMethod() { return apiMethod.getMethod(); } +} diff --git a/components/camel-braintree/src/generated/java/org/apache/camel/component/braintree/internal/UsBankAccountGatewayApiMethod.java b/components/camel-braintree/src/generated/java/org/apache/camel/component/braintree/internal/UsBankAccountGatewayApiMethod.java new file mode 100644 index 00000000000..f763cf6a88f --- /dev/null +++ b/components/camel-braintree/src/generated/java/org/apache/camel/component/braintree/internal/UsBankAccountGatewayApiMethod.java @@ -0,0 +1,53 @@ +/* + * Camel ApiMethod Enumeration generated by camel-api-component-maven-plugin + */ +package org.apache.camel.component.braintree.internal; + +import java.lang.reflect.Method; +import java.util.List; + +import com.braintreegateway.UsBankAccountGateway; + +import org.apache.camel.support.component.ApiMethod; +import org.apache.camel.support.component.ApiMethodArg; +import org.apache.camel.support.component.ApiMethodImpl; + +import static org.apache.camel.support.component.ApiMethodArg.arg; + +/** + * Camel {@link ApiMethod} Enumeration for com.braintreegateway.UsBankAccountGateway + */ +public enum UsBankAccountGatewayApiMethod implements ApiMethod { + + FIND( + com.braintreegateway.UsBankAccount.class, + "find", + arg("token", String.class)), + + SALE( + com.braintreegateway.Result.class, + "sale", + arg("token", String.class), + arg("transactionRequest", com.braintreegateway.TransactionRequest.class)); + + private final ApiMethod apiMethod; + + private UsBankAccountGatewayApiMethod(Class<?> resultType, String name, ApiMethodArg... args) { + this.apiMethod = new ApiMethodImpl(UsBankAccountGateway.class, resultType, name, args); + } + + @Override + public String getName() { return apiMethod.getName(); } + + @Override + public Class<?> getResultType() { return apiMethod.getResultType(); } + + @Override + public List<String> getArgNames() { return apiMethod.getArgNames(); } + + @Override + public List<Class<?>> getArgTypes() { return apiMethod.getArgTypes(); } + + @Override + public Method getMethod() { return apiMethod.getMethod(); } +} diff --git a/components/camel-braintree/src/generated/resources/META-INF/services/org/apache/camel/configurer/org.apache.camel.component.braintree.OAuthGatewayEndpointConfiguration b/components/camel-braintree/src/generated/resources/META-INF/services/org/apache/camel/configurer/org.apache.camel.component.braintree.OAuthGatewayEndpointConfiguration new file mode 100644 index 00000000000..c374f9fef0b --- /dev/null +++ b/components/camel-braintree/src/generated/resources/META-INF/services/org/apache/camel/configurer/org.apache.camel.component.braintree.OAuthGatewayEndpointConfiguration @@ -0,0 +1,2 @@ +# Generated by camel build tools - do NOT edit this file! +class=org.apache.camel.component.braintree.OAuthGatewayEndpointConfigurationConfigurer diff --git a/components/camel-braintree/src/generated/resources/META-INF/services/org/apache/camel/configurer/org.apache.camel.component.braintree.UsBankAccountGatewayEndpointConfiguration b/components/camel-braintree/src/generated/resources/META-INF/services/org/apache/camel/configurer/org.apache.camel.component.braintree.UsBankAccountGatewayEndpointConfiguration new file mode 100644 index 00000000000..d92d6587884 --- /dev/null +++ b/components/camel-braintree/src/generated/resources/META-INF/services/org/apache/camel/configurer/org.apache.camel.component.braintree.UsBankAccountGatewayEndpointConfiguration @@ -0,0 +1,2 @@ +# Generated by camel build tools - do NOT edit this file! +class=org.apache.camel.component.braintree.UsBankAccountGatewayEndpointConfigurationConfigurer diff --git a/components/camel-braintree/src/generated/resources/org/apache/camel/component/braintree/braintree.json b/components/camel-braintree/src/generated/resources/org/apache/camel/component/braintree/braintree.json index 14bb99f01bf..5b533d22798 100644 --- a/components/camel-braintree/src/generated/resources/org/apache/camel/component/braintree/braintree.json +++ b/components/camel-braintree/src/generated/resources/org/apache/camel/component/braintree/braintree.json @@ -28,7 +28,7 @@ "configuration": { "index": 2, "kind": "property", "displayName": "Configuration", "group": "advanced", "label": "advanced", "required": false, "type": "object", "javaType": "org.apache.camel.component.braintree.BraintreeConfiguration", "deprecated": false, "autowired": false, "secret": false, "description": "Component configuration" } }, "properties": { - "apiName": { "index": 0, "kind": "path", "displayName": "Api Name", "group": "producer", "label": "", "required": true, "type": "object", "javaType": "org.apache.camel.component.braintree.internal.BraintreeApiName", "enum": [ "ADD_ON", "ADDRESS", "CLIENT_TOKEN", "CREDIT_CARD_VERIFICATION", "CUSTOMER", "DISCOUNT", "DISPUTE", "DOCUMENT_UPLOAD", "MERCHANT_ACCOUNT", "PAYMENT_METHOD", "PAYMENT_METHOD_NONCE", "PLAN", "REPORT", "SETTLEMENT_BATCH_SUMMARY", "SUBSCRIPTION", "TRANSACTION", "WEB [...] + "apiName": { "index": 0, "kind": "path", "displayName": "Api Name", "group": "producer", "label": "", "required": true, "type": "object", "javaType": "org.apache.camel.component.braintree.internal.BraintreeApiName", "enum": [ "ADD_ON", "ADDRESS", "CLIENT_TOKEN", "CREDIT_CARD_VERIFICATION", "CUSTOMER", "DISCOUNT", "DISPUTE", "DOCUMENT_UPLOAD", "MERCHANT_ACCOUNT", "PAYMENT_METHOD", "PAYMENT_METHOD_NONCE", "OAUTH", "PLAN", "REPORT", "SETTLEMENT_BATCH_SUMMARY", "SUBSCRIPTION", "TRANSACTI [...] "methodName": { "index": 1, "kind": "path", "displayName": "Method Name", "group": "producer", "label": "", "required": true, "type": "string", "javaType": "java.lang.String", "enum": [ "accept", "addFileEvidence", "addTextEvidence", "cancel", "cancelRelease", "cloneTransaction", "create", "createForCurrency", "credit", "delete", "fetchMerchantAccounts", "finalize", "find", "generate", "grant", "holdInEscrow", "parse", "refund", "releaseFromEscrow", "removeEvidence", "retryCharge", " [...] "environment": { "index": 2, "kind": "parameter", "displayName": "Environment", "group": "producer", "label": "", "required": false, "type": "string", "javaType": "java.lang.String", "deprecated": false, "autowired": false, "secret": false, "configurationClass": "org.apache.camel.component.braintree.BraintreeConfiguration", "configurationField": "configuration", "description": "The environment Either SANDBOX or PRODUCTION" }, "inBody": { "index": 3, "kind": "parameter", "displayName": "In Body", "group": "producer", "label": "", "required": false, "type": "string", "javaType": "java.lang.String", "deprecated": false, "autowired": false, "secret": false, "description": "Sets the name of a parameter to be passed in the exchange In Body" }, @@ -52,6 +52,7 @@ "dispute": { "consumerOnly": false, "producerOnly": true, "description": "Provides methods to interact with Dispute objects", "methods": { "accept": { "description": "Accept a Dispute, given a dispute ID", "signatures": [ "com.braintreegateway.Result<com.braintreegateway.Dispute> accept(String id)" ] }, "addFileEvidence": { "description": "Add File Evidence to a Dispute, given an ID and a FileEvidenceRequest File evidence request", "signatures": [ "com.braintreegateway.Result<com.bra [...] "documentUpload": { "consumerOnly": false, "producerOnly": true, "description": "API to upload evidence documents", "methods": { "create": { "description": "", "signatures": [ "com.braintreegateway.Result<com.braintreegateway.DocumentUpload> create(com.braintreegateway.DocumentUploadRequest request)" ] } } }, "merchantAccount": { "consumerOnly": false, "producerOnly": true, "description": "Provides methods to create, find, and update MerchantAccount objects", "methods": { "create": { "description": "", "signatures": [ "com.braintreegateway.Result<com.braintreegateway.MerchantAccount> create(com.braintreegateway.MerchantAccountRequest request)" ] }, "createForCurrency": { "description": "", "signatures": [ "com.braintreegateway.Result<com.braintreegateway.MerchantAccount> createForCurrency [...] + "oauth": { "consumerOnly": false, "producerOnly": true, "description": "", "methods": { "connectUrl": { "description": "", "signatures": [ "String connectUrl(com.braintreegateway.OAuthConnectUrlRequest request)" ] }, "createTokenFromCode": { "description": "", "signatures": [ "com.braintreegateway.Result<com.braintreegateway.OAuthCredentials> createTokenFromCode(com.braintreegateway.OAuthCredentialsRequest request)" ] }, "createTokenFromRefreshToken": { "description": "", "signatures [...] "paymentMethod": { "consumerOnly": false, "producerOnly": true, "description": "Provides methods to interact with payments", "methods": { "create": { "description": "", "signatures": [ "com.braintreegateway.Result<com.braintreegateway.? extends PaymentMethod> create(com.braintreegateway.PaymentMethodRequest request)" ] }, "delete": { "description": "", "signatures": [ "com.braintreegateway.Result<com.braintreegateway.? extends PaymentMethod> delete(String token)", "com.braintreegatew [...] "paymentMethodNonce": { "consumerOnly": false, "producerOnly": true, "description": "Provides methods to interact with nonce payments", "methods": { "create": { "description": "", "signatures": [ "com.braintreegateway.Result<com.braintreegateway.PaymentMethodNonce> create(String paymentMethodToken)", "com.braintreegateway.Result<com.braintreegateway.PaymentMethodNonce> create(com.braintreegateway.PaymentMethodNonceRequest request)" ] }, "find": { "description": "", "signatures": [ "c [...] "plan": { "consumerOnly": false, "producerOnly": true, "description": "", "methods": { "create": { "description": "", "signatures": [ "com.braintreegateway.Result<com.braintreegateway.Plan> create(com.braintreegateway.PlanRequest request)" ] }, "find": { "description": "", "signatures": [ "com.braintreegateway.Plan find(String id)" ] }, "update": { "description": "", "signatures": [ "com.braintreegateway.Result<com.braintreegateway.Plan> update(String id, com.braintreegateway.PlanReq [...] @@ -59,6 +60,7 @@ "settlementBatchSummary": { "consumerOnly": false, "producerOnly": true, "description": "Provides methods to interact wit settlement summaries", "methods": { "generate": { "description": "", "signatures": [ "com.braintreegateway.Result<com.braintreegateway.SettlementBatchSummary> generate(java.util.Calendar settlementDate)", "com.braintreegateway.Result<com.braintreegateway.SettlementBatchSummary> generate(java.util.Calendar settlementDate, String groupByCustomField)" ] } } }, "subscription": { "consumerOnly": false, "producerOnly": true, "description": "Provides methods to interact with Subscriptions", "methods": { "cancel": { "description": "Cancels the Subscription with the given id", "signatures": [ "com.braintreegateway.Result<com.braintreegateway.Subscription> cancel(String id)" ] }, "create": { "description": "Creates a Subscription", "signatures": [ "com.braintreegateway.Result<com.braintreegateway.Subscription> create(com.braintreegateway.Subscrip [...] "transaction": { "consumerOnly": false, "producerOnly": true, "description": "Provides methods to interact with Transactions", "methods": { "adjustAuthorization": { "description": "Submits the transaction with the given id to be adjusted for the given amount which must be less than or equal to the authorization amount", "signatures": [ "com.braintreegateway.Result<com.braintreegateway.Transaction> adjustAuthorization(String id, com.braintreegateway.TransactionRequest request)", "com. [...] + "usBankAccount": { "consumerOnly": false, "producerOnly": true, "description": "", "methods": { "find": { "description": "", "signatures": [ "com.braintreegateway.UsBankAccount find(String token)" ] }, "sale": { "description": "", "signatures": [ "com.braintreegateway.Result<com.braintreegateway.Transaction> sale(String token, com.braintreegateway.TransactionRequest transactionRequest)" ] } } }, "webhookNotification": { "consumerOnly": false, "producerOnly": true, "description": "To retrieve notifications via webhooks", "methods": { "parse": { "description": "", "signatures": [ "com.braintreegateway.WebhookNotification parse(String signature, String payload)" ] }, "parseWithoutSignatureVerification": { "description": "", "signatures": [ "com.braintreegateway.WebhookNotification parseWithoutSignatureVerification(String payload)" ] }, "verify": { "description": "", "signatures [...] }, "apiProperties": { @@ -69,6 +71,7 @@ "dispute": { "methods": { "accept": { "properties": { "id": { "index": 0, "kind": "parameter", "displayName": "Id", "group": "producer", "label": "", "required": false, "type": "string", "javaType": "java.lang.String", "deprecated": false, "autowired": false, "secret": false, "description": "The dispute id to accept", "optional": false } } }, "addFileEvidence": { "properties": { "disputeId": { "index": 0, "kind": "parameter", "displayName": "Dispute Id", "group": "producer", "label": [...] "documentUpload": { "methods": { "create": { "properties": { "request": { "index": 0, "kind": "parameter", "displayName": "Request", "group": "producer", "label": "", "required": false, "type": "object", "javaType": "com.braintreegateway.DocumentUploadRequest", "deprecated": false, "autowired": false, "secret": false, "description": "", "optional": false } } } } }, "merchantAccount": { "methods": { "create": { "properties": { "request": { "index": 0, "kind": "parameter", "displayName": "Request", "group": "producer", "label": "", "required": false, "type": "object", "javaType": "com.braintreegateway.MerchantAccountRequest", "deprecated": false, "autowired": false, "secret": false, "description": "", "optional": false } } }, "createForCurrency": { "properties": { "currencyRequest": { "index": 0, "kind": "parameter", "displayName": "Currency Requ [...] + "oauth": { "methods": { "connectUrl": { "properties": { "connectRequest": { "index": 0, "kind": "parameter", "displayName": "Connect Request", "group": "producer", "label": "", "required": false, "type": "object", "javaType": "com.braintreegateway.OAuthConnectUrlRequest", "deprecated": false, "autowired": false, "secret": false, "description": "", "optional": false } } }, "createTokenFromCode": { "properties": { "request": { "index": 0, "kind": "parameter", "displayName": "Request", [...] "paymentMethod": { "methods": { "create": { "properties": { "request": { "index": 0, "kind": "parameter", "displayName": "Request", "group": "producer", "label": "", "required": false, "type": "object", "javaType": "com.braintreegateway.PaymentMethodRequest", "deprecated": false, "autowired": false, "secret": false, "description": "", "optional": false } } }, "delete": { "properties": { "deleteRequest": { "index": 0, "kind": "parameter", "displayName": "Delete Request", "group": "pro [...] "paymentMethodNonce": { "methods": { "create": { "properties": { "paymentMethodToken": { "index": 0, "kind": "parameter", "displayName": "Payment Method Token", "group": "producer", "label": "", "required": false, "type": "string", "javaType": "java.lang.String", "deprecated": false, "autowired": false, "secret": false, "description": "", "optional": false }, "request": { "index": 1, "kind": "parameter", "displayName": "Request", "group": "producer", "label": "", "required": false, " [...] "plan": { "methods": { "create": { "properties": { "request": { "index": 0, "kind": "parameter", "displayName": "Request", "group": "producer", "label": "", "required": false, "type": "object", "javaType": "com.braintreegateway.PlanRequest", "deprecated": false, "autowired": false, "secret": false, "description": "", "optional": false } } }, "find": { "properties": { "id": { "index": 0, "kind": "parameter", "displayName": "Id", "group": "producer", "label": "", "required": false, "ty [...] @@ -76,6 +79,7 @@ "settlementBatchSummary": { "methods": { "generate": { "properties": { "groupByCustomField": { "index": 0, "kind": "parameter", "displayName": "Group By Custom Field", "group": "producer", "label": "", "required": false, "type": "string", "javaType": "java.lang.String", "deprecated": false, "autowired": false, "secret": false, "description": "", "optional": false }, "settlementDate": { "index": 2, "kind": "parameter", "displayName": "Settlement Date", "group": "producer", "label": "" [...] "subscription": { "methods": { "cancel": { "properties": { "id": { "index": 0, "kind": "parameter", "displayName": "Id", "group": "producer", "label": "", "required": false, "type": "string", "javaType": "java.lang.String", "deprecated": false, "autowired": false, "secret": false, "description": "Of the Subscription to cancel", "optional": false } } }, "create": { "properties": { "request": { "index": 0, "kind": "parameter", "displayName": "Request", "group": "producer", "label": "", [...] "transaction": { "methods": { "adjustAuthorization": { "properties": { "amount": { "index": 0, "kind": "parameter", "displayName": "Amount", "group": "producer", "label": "", "required": false, "type": "object", "javaType": "java.math.BigDecimal", "deprecated": false, "autowired": false, "secret": false, "description": "To be adjusted", "optional": false }, "id": { "index": 1, "kind": "parameter", "displayName": "Id", "group": "producer", "label": "", "required": false, "type": "stri [...] + "usBankAccount": { "methods": { "find": { "properties": { "token": { "index": 0, "kind": "parameter", "displayName": "Token", "group": "producer", "label": "", "required": false, "type": "string", "javaType": "java.lang.String", "deprecated": false, "autowired": false, "secret": false, "description": "", "optional": false } } }, "sale": { "properties": { "token": { "index": 0, "kind": "parameter", "displayName": "Token", "group": "producer", "label": "", "required": false, "type": "s [...] "webhookNotification": { "methods": { "parse": { "properties": { "payload": { "index": 0, "kind": "parameter", "displayName": "Payload", "group": "producer", "label": "", "required": false, "type": "string", "javaType": "java.lang.String", "deprecated": false, "autowired": false, "secret": false, "description": "", "optional": false }, "signature": { "index": 1, "kind": "parameter", "displayName": "Signature", "group": "producer", "label": "", "required": false, "type": "string", "ja [...] } } diff --git a/dsl/camel-endpointdsl/src/generated/java/org/apache/camel/builder/endpoint/StaticEndpointBuilders.java b/dsl/camel-endpointdsl/src/generated/java/org/apache/camel/builder/endpoint/StaticEndpointBuilders.java index 1efae3e343b..39d7af00342 100644 --- a/dsl/camel-endpointdsl/src/generated/java/org/apache/camel/builder/endpoint/StaticEndpointBuilders.java +++ b/dsl/camel-endpointdsl/src/generated/java/org/apache/camel/builder/endpoint/StaticEndpointBuilders.java @@ -2088,11 +2088,11 @@ public class StaticEndpointBuilders { * * Path parameter: apiName (required) * What kind of operation to perform - * There are 17 enums and the value can be one of: ADD_ON, ADDRESS, + * There are 19 enums and the value can be one of: ADD_ON, ADDRESS, * CLIENT_TOKEN, CREDIT_CARD_VERIFICATION, CUSTOMER, DISCOUNT, DISPUTE, * DOCUMENT_UPLOAD, MERCHANT_ACCOUNT, PAYMENT_METHOD, PAYMENT_METHOD_NONCE, - * PLAN, REPORT, SETTLEMENT_BATCH_SUMMARY, SUBSCRIPTION, TRANSACTION, - * WEBHOOK_NOTIFICATION + * OAUTH, PLAN, REPORT, SETTLEMENT_BATCH_SUMMARY, SUBSCRIPTION, TRANSACTION, + * US_BANK_ACCOUNT, WEBHOOK_NOTIFICATION * * Path parameter: methodName (required) * What sub operation to use for the selected operation @@ -2123,11 +2123,11 @@ public class StaticEndpointBuilders { * * Path parameter: apiName (required) * What kind of operation to perform - * There are 17 enums and the value can be one of: ADD_ON, ADDRESS, + * There are 19 enums and the value can be one of: ADD_ON, ADDRESS, * CLIENT_TOKEN, CREDIT_CARD_VERIFICATION, CUSTOMER, DISCOUNT, DISPUTE, * DOCUMENT_UPLOAD, MERCHANT_ACCOUNT, PAYMENT_METHOD, PAYMENT_METHOD_NONCE, - * PLAN, REPORT, SETTLEMENT_BATCH_SUMMARY, SUBSCRIPTION, TRANSACTION, - * WEBHOOK_NOTIFICATION + * OAUTH, PLAN, REPORT, SETTLEMENT_BATCH_SUMMARY, SUBSCRIPTION, TRANSACTION, + * US_BANK_ACCOUNT, WEBHOOK_NOTIFICATION * * Path parameter: methodName (required) * What sub operation to use for the selected operation diff --git a/dsl/camel-endpointdsl/src/generated/java/org/apache/camel/builder/endpoint/dsl/BraintreeEndpointBuilderFactory.java b/dsl/camel-endpointdsl/src/generated/java/org/apache/camel/builder/endpoint/dsl/BraintreeEndpointBuilderFactory.java index 8a54694d0d6..68101754b31 100644 --- a/dsl/camel-endpointdsl/src/generated/java/org/apache/camel/builder/endpoint/dsl/BraintreeEndpointBuilderFactory.java +++ b/dsl/camel-endpointdsl/src/generated/java/org/apache/camel/builder/endpoint/dsl/BraintreeEndpointBuilderFactory.java @@ -344,11 +344,11 @@ public interface BraintreeEndpointBuilderFactory { * * Path parameter: apiName (required) * What kind of operation to perform - * There are 17 enums and the value can be one of: ADD_ON, ADDRESS, + * There are 19 enums and the value can be one of: ADD_ON, ADDRESS, * CLIENT_TOKEN, CREDIT_CARD_VERIFICATION, CUSTOMER, DISCOUNT, DISPUTE, * DOCUMENT_UPLOAD, MERCHANT_ACCOUNT, PAYMENT_METHOD, - * PAYMENT_METHOD_NONCE, PLAN, REPORT, SETTLEMENT_BATCH_SUMMARY, - * SUBSCRIPTION, TRANSACTION, WEBHOOK_NOTIFICATION + * PAYMENT_METHOD_NONCE, OAUTH, PLAN, REPORT, SETTLEMENT_BATCH_SUMMARY, + * SUBSCRIPTION, TRANSACTION, US_BANK_ACCOUNT, WEBHOOK_NOTIFICATION * * Path parameter: methodName (required) * What sub operation to use for the selected operation @@ -379,11 +379,11 @@ public interface BraintreeEndpointBuilderFactory { * * Path parameter: apiName (required) * What kind of operation to perform - * There are 17 enums and the value can be one of: ADD_ON, ADDRESS, + * There are 19 enums and the value can be one of: ADD_ON, ADDRESS, * CLIENT_TOKEN, CREDIT_CARD_VERIFICATION, CUSTOMER, DISCOUNT, DISPUTE, * DOCUMENT_UPLOAD, MERCHANT_ACCOUNT, PAYMENT_METHOD, - * PAYMENT_METHOD_NONCE, PLAN, REPORT, SETTLEMENT_BATCH_SUMMARY, - * SUBSCRIPTION, TRANSACTION, WEBHOOK_NOTIFICATION + * PAYMENT_METHOD_NONCE, OAUTH, PLAN, REPORT, SETTLEMENT_BATCH_SUMMARY, + * SUBSCRIPTION, TRANSACTION, US_BANK_ACCOUNT, WEBHOOK_NOTIFICATION * * Path parameter: methodName (required) * What sub operation to use for the selected operation