This is an automated email from the ASF dual-hosted git repository. davsclaus pushed a commit to branch api in repository https://gitbox.apache.org/repos/asf/camel.git
commit ff78e70856846fefb6020aac5f9fba9b8aca278e Author: Claus Ibsen <claus.ib...@gmail.com> AuthorDate: Thu Sep 17 19:39:03 2020 +0200 CAMEL-15478: Polished docs --- .../src/main/docs/as2-component.adoc | 223 --------------------- .../src/main/docs/google-calendar-component.adoc | 92 +-------- .../docs/google-calendar-stream-component.adoc | 41 ++-- .../src/main/docs/google-drive-component.adoc | 95 ++------- .../src/main/docs/google-mail-component.adoc | 76 +------ .../main/docs/google-mail-stream-component.adoc | 29 +-- .../src/main/docs/google-sheets-component.adoc | 79 ++------ .../main/docs/google-sheets-stream-component.adoc | 44 ++-- .../src/main/docs/olingo2-component.adoc | 105 +--------- .../src/main/docs/olingo4-component.adoc | 119 ++--------- .../src/main/docs/twilio-component.adoc | 28 --- .../src/main/docs/zendesk-component.adoc | 47 +---- 12 files changed, 112 insertions(+), 866 deletions(-) diff --git a/components/camel-as2/camel-as2-component/src/main/docs/as2-component.adoc b/components/camel-as2/camel-as2-component/src/main/docs/as2-component.adoc index 310363a..3aaa145 100644 --- a/components/camel-as2/camel-as2-component/src/main/docs/as2-component.adoc +++ b/components/camel-as2/camel-as2-component/src/main/docs/as2-component.adoc @@ -156,229 +156,6 @@ as2:apiName/methodName The following lists each API name and method and its additional parameters. -==== client - - -The client API has 1 method(s) which is represented by the following method signatures -(an API method may have multiple signatures due to overloading): - -[source,java] ----- - -org.apache.http.protocol.HttpCoreContext send(String ediMessage, String requestUri, String subject, String from, String as2From, String as2To, org.apache.camel.component.as2.api.AS2MessageStructure as2MessageStructure, org.apache.http.entity.ContentType ediMessageContentType, String ediMessageTransferEncoding, org.apache.camel.component.as2.api.AS2SignatureAlgorithm signingAlgorithm, java.security.cert.Certificate[] signingCertificateChain, java.security.PrivateKey signingPrivateKey, org [...] - ----- - -The client API is defined in the syntax as follows: - ----- -as2:client/methodName?[parameters] ----- - -The 1 method(s) is listed in the table below. -(API methods can have a shorthand alias name which can be used in the syntax instead of the name) - -[width="100%",cols="2,2,6",options="header"] -|=== -| Method | Alias | Description -| *send* | | Send ediMessage to trading partner -|=== - -The client API method(s) has the following set of parameters listed in the table below: -[width="100%",cols="2,2,4,2",options="header"] -|=== -| Method | Parameter | Description | Type -| send | *as2From* | AS2 name of sender | String -| send | *as2MessageStructure* | The structure of AS2 to send; see AS2MessageStructure | AS2MessageStructure -| send | *as2To* | AS2 name of recipient | String -| send | *compressionAlgorithm* | *Optional* The algorithm used to compress the message or null if sending EDI message uncompressed | AS2CompressionAlgorithm -| send | *dispositionNotificationTo* | *Optional* An RFC2822 address to request a receipt or null if no receipt requested | String -| send | *ediMessage* | EDI message to transport | String -| send | *ediMessageContentType* | The content typw of EDI message | ContentType -| send | *ediMessageTransferEncoding* | *Optional* The transfer encoding used to transport EDI message | String -| send | *encryptingAlgorithm* | *Optional* The algorithm used to encrypt the message or null if sending EDI message unencrypted | AS2EncryptionAlgorithm -| send | *encryptingCertificateChain* | *Optional* The chain of certificates used to encrypt the message or null if sending EDI message unencrypted | Certificate[] -| send | *from* | RFC2822 address of sender | String -| send | *requestUri* | Resource location to deliver message | String -| send | *signedReceiptMicAlgorithms* | *Optional* The senders list of signing algorithms for signing receipt, in preferred order, or null if requesting an unsigned receipt. | String[] -| send | *signingAlgorithm* | *Optional* The algorithm used to sign the message or null if sending EDI message unsigned | AS2SignatureAlgorithm -| send | *signingCertificateChain* | *Optional* The chain of certificates used to sign the message or null if sending EDI message unsigned | Certificate[] -| send | *signingPrivateKey* | *Optional* The private key used to sign EDI message | PrivateKey -| send | *subject* | Message subject | String -|=== - -In addition to the parameters above, the client API can also use from the 49 endpoint query option -which is listed in the _Query Parameters_ section. - -Any of the parameters can be provided in either the endpoint URI, or dynamically in a message header. -The message header name must be of the format `CamelAs2.parameter`. -The `inBody` parameter overrides message header, i.e. the endpoint parameter `inBody=myParameterNameHere` -would override a `CamelAs2.myParameterNameHere` header. - - - -==== server - - -The server API has 1 method(s) which is represented by the following method signatures -(an API method may have multiple signatures due to overloading): - -[source,java] ----- - -void listen(String requestUriPattern, org.apache.http.protocol.HttpRequestHandler handler); - ----- - -The server API is defined in the syntax as follows: - ----- -as2:server/methodName?[parameters] ----- - -The 1 method(s) is listed in the table below. -(API methods can have a shorthand alias name which can be used in the syntax instead of the name) - -[width="100%",cols="2,2,6",options="header"] -|=== -| Method | Alias | Description -| *listen* | | -|=== - -The server API method(s) has the following set of parameters listed in the table below: -[width="100%",cols="2,2,4,2",options="header"] -|=== -| Method | Parameter | Description | Type -| listen | *requestUriPattern* | | String -|=== - -In addition to the parameters above, the server API can also use from the 49 endpoint query option -which is listed in the _Query Parameters_ section. - -Any of the parameters can be provided in either the endpoint URI, or dynamically in a message header. -The message header name must be of the format `CamelAs2.parameter`. -The `inBody` parameter overrides message header, i.e. the endpoint parameter `inBody=myParameterNameHere` -would override a `CamelAs2.myParameterNameHere` header. // endpoint options: END - -== Client Endpoints: - -Client endpoints use the endpoint prefix *`client`* followed by the name of a method -and associated options described next. The endpoint URI MUST contain the prefix *`client`*. - -[source] ----- -as2://client/method?[options] ----- - -Endpoint options that are not mandatory are denoted by *[]*. When there -are no mandatory options for an endpoint, one of the set of *[]* options -MUST be provided. Producer endpoints can also use a special -option *`inBody`* that in turn should contain the name of the endpoint -option whose value will be contained in the Camel Exchange In message. - -Any of the endpoint options can be provided in either the endpoint URI, -or dynamically in a message header. The message header name must be of -the format *`CamelAS2.<option>`*. Note that the *`inBody`* option -overrides message header, i.e. the endpoint -option *`inBody=option`* would override a *`CamelAS2.option`* header. - -If a value is not provided for the option *defaultRequest* either in the -endpoint URI or in a message header, it will be assumed to be `null`. -Note that the `null` value will only be used if other options do not -satisfy matching endpoints. - -In case of AS2 API errors the endpoint will throw a -RuntimeCamelException with a -*org.apache.http.HttpException* derived exception -cause. - -[width="100%",cols="10%,10%,70%",options="header"] -|=== -|Method |Options |Result Body Type - -|send |ediMessage, requestUri, subject, from, as2From, as2To, as2MessageStructure, ediMessageContentType, ediMessageTransferEncoding, dispositionNotificationTo, signedReceiptMicAlgorithms |org.apache.http.protocol.HttpCoreContext -|=== - -URI Options for _client_ - - -[width="100%",cols="10%,90%",options="header"] -|=== -|Name |Type - -|ediMessage |String - -|requestUri |String - -|subject |String - -|from |String - -|as2From |String - -|as2To |String - -|as2MessageStructure |org.apache.camel.component.as2.api.AS2MessageStructure - -|ediMessageContentType |String - -|ediMessageTransferEncoding |String - -|dispositionNotificationTo |String - -|signedReceiptMicAlgorithms |String[] -|=== - - -== Server Endpoints: - -Server endpoints use the endpoint prefix *`server`* followed by the name of a method -and associated options described next. The endpoint URI MUST contain the prefix *`server`*. - -[source] ----- -as2://server/method?[options] ----- - -Endpoint options that are not mandatory are denoted by *[]*. When there -are no mandatory options for an endpoint, one of the set of *[]* options -MUST be provided. Producer endpoints can also use a special -option *`inBody`* that in turn should contain the name of the endpoint -option whose value will be contained in the Camel Exchange In message. - -Any of the endpoint options can be provided in either the endpoint URI, -or dynamically in a message header. The message header name must be of -the format *`CamelAS2.<option>`*. Note that the *`inBody`* option -overrides message header, i.e. the endpoint -option *`inBody=option`* would override a *`CamelAS2.option`* header. - -If a value is not provided for the option *defaultRequest* either in the -endpoint URI or in a message header, it will be assumed to be `null`. -Note that the `null` value will only be used if other options do not -satisfy matching endpoints. - -In case of AS2 API errors the endpoint will throw a -RuntimeCamelException with a -*org.apache.http.HttpException* derived exception -cause. - -[width="100%",cols="10%,10%,70%",options="header"] -|=== -|Method |Options |Result Body Type - -|listen |requestUriPattern |org.apache.http.protocol.HttpCoreContext -|=== - -URI Options for _server_ - - -[width="100%",cols="10%,90%",options="header"] -|=== -|Name |Type - -|requestUriPattern |String -|=== - include::camel-spring-boot::page$as2-starter.adoc[] diff --git a/components/camel-google-calendar/src/main/docs/google-calendar-component.adoc b/components/camel-google-calendar/src/main/docs/google-calendar-component.adoc index 6f1c71f..f49fa0d 100644 --- a/components/camel-google-calendar/src/main/docs/google-calendar-component.adoc +++ b/components/camel-google-calendar/src/main/docs/google-calendar-component.adoc @@ -31,20 +31,17 @@ the https://developers.google.com/oauthplayground[OAuth playground]. Maven users will need to add the following dependency to their pom.xml for this component: ----------------------------------------------------------- - <dependency> - <groupId>org.apache.camel</groupId> - <artifactId>camel-google-calendar</artifactId> - <!-- use the same version as your Camel core version --> - <version>x.x.x</version> - </dependency> - ----------------------------------------------------------- - -== 1. Google Calendar Options - - +[source,xml] +---- +<dependency> + <groupId>org.apache.camel</groupId> + <artifactId>camel-google-calendar</artifactId> + <!-- use the same version as your Camel core version --> + <version>x.x.x</version> +</dependency> +---- +=== Component options // component options: START The Google Calendar component supports 14 options, which are listed below. @@ -72,12 +69,6 @@ The Google Calendar component supports 14 options, which are listed below. // component options: END - - - - - - // endpoint options: START The Google Calendar endpoint is configured using URI syntax: @@ -601,67 +592,4 @@ would override a `CamelGoogleCalendar.myParameterNameHere` header. // endpoint options: END - -== URI Format - -The GoogleCalendar Component uses the following URI format: - ------------------------------------------------------------- - google-calendar://endpoint-prefix/endpoint?[options] - ------------------------------------------------------------- - -Endpoint prefix can be one of: - -* acl -* calendars -* channels -* colors -* events -* freebusy -* list -* settings - -== Producer Endpoints - -Producer endpoints can use endpoint prefixes followed by endpoint names -and associated options described next. A shorthand alias can be used for -some endpoints. The endpoint URI MUST contain a prefix. - -Endpoint options that are not mandatory are denoted by []. When there -are no mandatory options for an endpoint, one of the set of [] options -MUST be provided. Producer endpoints can also use a special option -*`inBody`* that in turn should contain the name of the endpoint option -whose value will be contained in the Camel Exchange In message. - -Any of the endpoint options can be provided in either the endpoint URI, -or dynamically in a message header. The message header name must be of -the format `CamelGoogleCalendar.<option>`. Note that the `inBody` option -overrides message header, i.e. the endpoint option `inBody=option` would -override a `CamelGoogleCalendar.option` header. - - -== Consumer Endpoints - -Any of the producer endpoints can be used as a consumer endpoint. -Consumer endpoints can use -http://camel.apache.org/polling-consumer.html#PollingConsumer-ScheduledPollConsumerOptions[Scheduled -Poll Consumer Options] with a `consumer.` prefix to schedule endpoint -invocation. Consumer endpoints that return an array or collection will -generate one exchange per element, and their routes will be executed -once for each exchange. - -== Message Headers - -Any URI option can be provided in a message header for producer -endpoints with a `CamelGoogleCalendar.` prefix. - -== Message Body - -All result message bodies utilize objects provided by the underlying -APIs used by the GoogleCalendarComponent. Producer endpoints can specify -the option name for incoming message body in the `inBody` endpoint URI -parameter. For endpoints that return an array or collection, a consumer -endpoint will map every element to distinct messages. - include::camel-spring-boot::page$google-calendar-starter.adoc[] diff --git a/components/camel-google-calendar/src/main/docs/google-calendar-stream-component.adoc b/components/camel-google-calendar/src/main/docs/google-calendar-stream-component.adoc index 96aa54b..add9240 100644 --- a/components/camel-google-calendar/src/main/docs/google-calendar-stream-component.adoc +++ b/components/camel-google-calendar/src/main/docs/google-calendar-stream-component.adoc @@ -31,26 +31,25 @@ the https://developers.google.com/oauthplayground[OAuth playground]. Maven users will need to add the following dependency to their pom.xml for this component: ------------------------------------------------------- - <dependency> - <groupId>org.apache.camel</groupId> - <artifactId>camel-google-calendar</artifactId> - <!-- use the same version as your Camel core version --> - <version>x.x.x</version> - </dependency> - ------------------------------------------------------- +[source,xml] +---- +<dependency> + <groupId>org.apache.camel</groupId> + <artifactId>camel-google-calendar</artifactId> + <!-- use the same version as your Camel core version --> + <version>x.x.x</version> +</dependency> +---- == URI Format The Google Calendar Component uses the following URI format: --------------------------------------------------------- - google-calendar-stream://index?[options] - --------------------------------------------------------- +---- +google-calendar-stream://index?[options] +---- -== Google Calendar stream component options +== Component options // component options: START @@ -604,19 +603,5 @@ would override a `CamelGoogleCalendarStream.myParameterNameHere` header. // endpoint options: END -== Consumer - -The consumer will poll by default with maxResults equals to 5. - -For example - -[source,java] ---------------------------------------------------------- -from("google-calendar-stream://test?markAsRead=true&delay=5000&maxResults=5").to("mock:result"); ---------------------------------------------------------- - -This route will consume the next five events starting from the date of polling. - - include::camel-spring-boot::page$google-calendar-starter.adoc[] diff --git a/components/camel-google-drive/src/main/docs/google-drive-component.adoc b/components/camel-google-drive/src/main/docs/google-drive-component.adoc index cfe274c..f313362 100644 --- a/components/camel-google-drive/src/main/docs/google-drive-component.adoc +++ b/components/camel-google-drive/src/main/docs/google-drive-component.adoc @@ -30,48 +30,26 @@ https://developers.google.com/oauthplayground[OAuth playground]. Maven users will need to add the following dependency to their pom.xml for this component: -------------------------------------------------------- - <dependency> - <groupId>org.apache.camel</groupId> - <artifactId>camel-google-drive</artifactId> - <!-- use the same version as your Camel core version --> - <version>x.x.x</version> - </dependency> - -------------------------------------------------------- +[source,xml] +---- +<dependency> + <groupId>org.apache.camel</groupId> + <artifactId>camel-google-drive</artifactId> + <!-- use the same version as your Camel core version --> + <version>x.x.x</version> +</dependency> +---- == URI Format -''''' - The GoogleDrive Component uses the following URI format: ---------------------------------------------------------- - google-drive://endpoint-prefix/endpoint?[options] - ---------------------------------------------------------- - -Endpoint prefix can be one of: - -* drive-about -* drive-apps -* drive-changes -* drive-channels -* drive-children -* drive-comments -* drive-files -* drive-parents -* drive-permissions -* drive-properties -* drive-realtime -* drive-replies -* drive-revisions - -== GoogleDriveComponent - - +---- +google-drive://endpoint-prefix/endpoint?[options] +---- +== Component options // component options: START The Google Drive component supports 11 options, which are listed below. @@ -97,11 +75,6 @@ The Google Drive component supports 11 options, which are listed below. - - - - - // endpoint options: START The Google Drive endpoint is configured using URI syntax: @@ -947,50 +920,10 @@ would override a `CamelGoogleDrive.myParameterNameHere` header. // endpoint options: END - - -== Producer Endpoints - -Producer endpoints can use endpoint prefixes followed by endpoint names -and associated options described next. A shorthand alias can be used for -some endpoints. The endpoint URI MUST contain a prefix. - -Endpoint options that are not mandatory are denoted by []. When there -are no mandatory options for an endpoint, one of the set of [] options -MUST be provided. Producer endpoints can also use a special option -*`inBody`* that in turn should contain the name of the endpoint option -whose value will be contained in the Camel Exchange In message. - -Any of the endpoint options can be provided in either the endpoint URI, -or dynamically in a message header. The message header name must be of -the format `CamelGoogleDrive.<option>`. Note that the `inBody` option -overrides message header, i.e. the endpoint option `inBody=option` would -override a `CamelGoogleDrive.option` header. +== More Information For more information on the endpoints and options see API documentation at: https://developers.google.com/drive/v2/reference/[https://developers.google.com/drive/v2/reference/] -== Consumer Endpoints - -Any of the producer endpoints can be used as a consumer endpoint. -Consumer endpoints can use -http://camel.apache.org/polling-consumer.html#PollingConsumer-ScheduledPollConsumerOptions[Scheduled -Poll Consumer Options] to schedule endpoint invocation. -Consumer endpoints that return an array or collection will -generate one exchange per element, and their routes will be executed -once for each exchange. - -== Message Headers - -Any URI option can be provided in a message header for producer -endpoints with a `CamelGoogleDrive.` prefix. - -== Message Body - -All result message bodies utilize objects provided by the underlying -APIs used by the GoogleDriveComponent. Producer endpoints can specify -the option name for incoming message body in the `inBody` endpoint URI -parameter. For endpoints that return an array or collection, a consumer -endpoint will map every element to distinct messages. include::camel-spring-boot::page$google-drive-starter.adoc[] diff --git a/components/camel-google-mail/src/main/docs/google-mail-component.adoc b/components/camel-google-mail/src/main/docs/google-mail-component.adoc index f2c980b..80feb72 100644 --- a/components/camel-google-mail/src/main/docs/google-mail-component.adoc +++ b/components/camel-google-mail/src/main/docs/google-mail-component.adoc @@ -31,39 +31,25 @@ the https://developers.google.com/oauthplayground[OAuth playground]. Maven users will need to add the following dependency to their pom.xml for this component: ------------------------------------------------------- +[source,xml] +---- <dependency> <groupId>org.apache.camel</groupId> <artifactId>camel-google-mail</artifactId> <!-- use the same version as your Camel core version --> <version>x.y.z</version> </dependency> ------------------------------------------------------- +---- == URI Format The GoogleMail Component uses the following URI format: --------------------------------------------------------- - google-mail://endpoint-prefix/endpoint?[options] - --------------------------------------------------------- - -Endpoint prefix can be one of: - -* attachments -* drafts -* history -* labels -* messages -* threads -* users - -== GoogleMailComponent - - - +---- +google-mail://endpoint-prefix/endpoint?[options] +---- +== Component options // component options: START The Google Mail component supports 10 options, which are listed below. @@ -87,11 +73,6 @@ The Google Mail component supports 10 options, which are listed below. // component options: END - - - - - // endpoint options: START The Google Mail endpoint is configured using URI syntax: @@ -636,51 +617,10 @@ The `inBody` parameter overrides message header, i.e. the endpoint parameter `in would override a `CamelGoogleMail.myParameterNameHere` header. // endpoint options: END - - - -== Producer Endpoints - -Producer endpoints can use endpoint prefixes followed by endpoint names -and associated options described next. A shorthand alias can be used for -some endpoints. The endpoint URI MUST contain a prefix. - -Endpoint options that are not mandatory are denoted by []. When there -are no mandatory options for an endpoint, one of the set of [] options -MUST be provided. Producer endpoints can also use a special option -*`inBody`* that in turn should contain the name of the endpoint option -whose value will be contained in the Camel Exchange In message. - -Any of the endpoint options can be provided in either the endpoint URI, -or dynamically in a message header. The message header name must be of -the format `CamelGoogleMail.<option>`. Note that the `inBody` option -overrides message header, i.e. the endpoint option `inBody=option` would -override a `CamelGoogleMail.option` header. +== More Information For more information on the endpoints and options see API documentation at: https://developers.google.com/gmail/api/v1/reference/[https://developers.google.com/gmail/api/v1/reference/] -== Consumer Endpoints - -Any of the producer endpoints can be used as a consumer endpoint. -Consumer endpoints can use -http://camel.apache.org/polling-consumer.html#PollingConsumer-ScheduledPollConsumerOptions[Scheduled -Poll Consumer Options] to schedule endpoint invocation. -Consumer endpoints that return an array or collection will -generate one exchange per element, and their routes will be executed -once for each exchange. - -== Message Headers - -Any URI option can be provided in a message header for producer -endpoints with a `CamelGoogleMail.` prefix. - -== Message Body - -All result message bodies utilize objects provided by the underlying -APIs used by the GoogleMailComponent. Producer endpoints can specify the -option name for incoming message body in the `inBody` endpoint URI -parameter. For endpoints that return an array or collection, a consumer -endpoint will map every element to distinct messages. include::camel-spring-boot::page$google-mail-starter.adoc[] diff --git a/components/camel-google-mail/src/main/docs/google-mail-stream-component.adoc b/components/camel-google-mail/src/main/docs/google-mail-stream-component.adoc index 28e4ec8..92350b4 100644 --- a/components/camel-google-mail/src/main/docs/google-mail-stream-component.adoc +++ b/components/camel-google-mail/src/main/docs/google-mail-stream-component.adoc @@ -31,24 +31,25 @@ the https://developers.google.com/oauthplayground[OAuth playground]. Maven users will need to add the following dependency to their pom.xml for this component: ------------------------------------------------------- +[source,xml] +---- <dependency> <groupId>org.apache.camel</groupId> <artifactId>camel-google-mail</artifactId> <!-- use the same version as your Camel core version --> <version>x.y.z</version> </dependency> ------------------------------------------------------- +---- == URI Format The GoogleMail Component uses the following URI format: --------------------------------------------------------- - google-mail-stream://index?[options] --------------------------------------------------------- +---- +google-mail-stream://index?[options] +---- -== GoogleMailStreamComponent +== Component options // component options: START @@ -623,20 +624,10 @@ The `inBody` parameter overrides message header, i.e. the endpoint parameter `in would override a `CamelGoogleMailStream.myParameterNameHere` header. // endpoint options: END +== More Information -== Consumer - -The consumer will poll by default with the query "is:unread" and maxResults equals to 10. - -For example - -[source,java] ---------------------------------------------------------- -from("google-mail-stream://test?markAsRead=true&delay=5000&maxResults=5&labels=GitHub,Apache").to("mock:result"); ---------------------------------------------------------- - -This route will consume unread messages with labels Github and Apache and it will mark the messages as read. +For more information on the endpoints and options see API documentation +at: https://developers.google.com/gmail/api/v1/reference/[https://developers.google.com/gmail/api/v1/reference/] - include::camel-spring-boot::page$google-mail-starter.adoc[] diff --git a/components/camel-google-sheets/src/main/docs/google-sheets-component.adoc b/components/camel-google-sheets/src/main/docs/google-sheets-component.adoc index d18c7fe..616149c 100644 --- a/components/camel-google-sheets/src/main/docs/google-sheets-component.adoc +++ b/components/camel-google-sheets/src/main/docs/google-sheets-component.adoc @@ -31,35 +31,30 @@ the https://developers.google.com/oauthplayground[OAuth playground]. Maven users will need to add the following dependency to their pom.xml for this component: ----------------------------------------------------------- - <dependency> - <groupId>org.apache.camel</groupId> - <artifactId>camel-google-sheets</artifactId> - <!-- use the same version as your Camel core version --> - <version>x.x.x</version> - </dependency> - ----------------------------------------------------------- +[source,xml] +---- +<dependency> + <groupId>org.apache.camel</groupId> + <artifactId>camel-google-sheets</artifactId> + <!-- use the same version as your Camel core version --> + <version>x.x.x</version> +</dependency> +---- == URI Format The GoogleSheets Component uses the following URI format: ------------------------------------------------------------- - google-sheets://endpoint-prefix/endpoint?[options] - ------------------------------------------------------------- +---- +google-sheets://endpoint-prefix/endpoint?[options] +---- Endpoint prefix can be one of: * spreadsheets * data -== GoogleSheetsComponent - - - - +=== Component options // component options: START The Google Sheets component supports 10 options, which are listed below. @@ -83,11 +78,6 @@ The Google Sheets component supports 10 options, which are listed below. // component options: END - - - - - // endpoint options: START The Google Sheets endpoint is configured using URI syntax: @@ -311,50 +301,9 @@ would override a `CamelGoogleSheets.myParameterNameHere` header. // endpoint options: END - - -== Producer Endpoints - -Producer endpoints can use endpoint prefixes followed by endpoint names -and associated options described next. A shorthand alias can be used for -some endpoints. The endpoint URI MUST contain a prefix. - -Endpoint options that are not mandatory are denoted by []. When there -are no mandatory options for an endpoint, one of the set of [] options -MUST be provided. Producer endpoints can also use a special option -*`inBody`* that in turn should contain the name of the endpoint option -whose value will be contained in the Camel Exchange In message. - -Any of the endpoint options can be provided in either the endpoint URI, -or dynamically in a message header. The message header name must be of -the format `CamelGoogleSheets.<option>`. Note that the `inBody` option -overrides message header, i.e. the endpoint option `inBody=option` would -override a `CamelGoogleSheets.option` header. +== More information For more information on the endpoints and options see API documentation at: https://developers.google.com/sheets/api/reference/rest/[https://developers.google.com/sheets/api/reference/rest/] -== Consumer Endpoints - -Any of the producer endpoints can be used as a consumer endpoint. -Consumer endpoints can use -http://camel.apache.org/polling-consumer.html#PollingConsumer-ScheduledPollConsumerOptions[Scheduled -Poll Consumer Options] to schedule endpoint invocation. -Consumer endpoints that return an array or collection will -generate one exchange per element, and their routes will be executed -once for each exchange. - -== Message Headers - -Any URI option can be provided in a message header for producer -endpoints with a `CamelGoogleSheets.` prefix. - -== Message Body - -All result message bodies utilize objects provided by the underlying -APIs used by the GoogleSheetsComponent. Producer endpoints can specify -the option name for incoming message body in the `inBody` endpoint URI -parameter. For endpoints that return an array or collection, a consumer -endpoint will map every element to distinct messages. - include::camel-spring-boot::page$google-sheets-starter.adoc[] diff --git a/components/camel-google-sheets/src/main/docs/google-sheets-stream-component.adoc b/components/camel-google-sheets/src/main/docs/google-sheets-stream-component.adoc index f0fe6d7..7bb07c8 100644 --- a/components/camel-google-sheets/src/main/docs/google-sheets-stream-component.adoc +++ b/components/camel-google-sheets/src/main/docs/google-sheets-stream-component.adoc @@ -31,27 +31,25 @@ the https://developers.google.com/oauthplayground[OAuth playground]. Maven users will need to add the following dependency to their pom.xml for this component: ------------------------------------------------------- - <dependency> - <groupId>org.apache.camel</groupId> - <artifactId>camel-google-sheets</artifactId> - <!-- use the same version as your Camel core version --> - <version>x.x.x</version> - </dependency> - ------------------------------------------------------- +[source,xml] +---- +<dependency> + <groupId>org.apache.camel</groupId> + <artifactId>camel-google-sheets</artifactId> + <!-- use the same version as your Camel core version --> + <version>x.x.x</version> +</dependency> +---- == URI Format The Google Sheets Component uses the following URI format: --------------------------------------------------------- - google-sheets-stream://apiName?[options] - --------------------------------------------------------- - -== GoogleSheetsStreamComponent +---- +google-sheets-stream://apiName?[options] +---- +=== Component options // component options: START The Google Sheets Stream component supports 17 options, which are listed below. @@ -311,20 +309,10 @@ The `inBody` parameter overrides message header, i.e. the endpoint parameter `in would override a `CamelGoogleSheetsStream.myParameterNameHere` header. // endpoint options: END +== More information -== Consumer - -The consumer will poll by default with maxResults equals to 5. - -For example - -[source,java] ---------------------------------------------------------- -from("google-sheets-stream://data?range=A:B&delay=5000&maxResults=5").to("mock:result"); ---------------------------------------------------------- - -This route will consume the next ten events starting from the date of polling. +For more information on the endpoints and options see API documentation +at: https://developers.google.com/sheets/api/reference/rest/[https://developers.google.com/sheets/api/reference/rest/] - include::camel-spring-boot::page$google-sheets-starter.adoc[] diff --git a/components/camel-olingo2/camel-olingo2-component/src/main/docs/olingo2-component.adoc b/components/camel-olingo2/camel-olingo2-component/src/main/docs/olingo2-component.adoc index 0032798..9758b4b 100644 --- a/components/camel-olingo2/camel-olingo2-component/src/main/docs/olingo2-component.adoc +++ b/components/camel-olingo2/camel-olingo2-component/src/main/docs/olingo2-component.adoc @@ -265,67 +265,9 @@ The `inBody` parameter overrides message header, i.e. the endpoint parameter `in would override a `CamelOlingo2.myParameterNameHere` header. // endpoint options: END -== Producer Endpoints - -Producer endpoints can use endpoint names and options listed -next. Producer endpoints can also use a special option *`inBody`* that -in turn should contain the name of the endpoint option whose value will -be contained in the Camel Exchange In message. The *inBody* option -defaults to *data* for endpoints that take that option. - -== Endpoint Options - -Any of the endpoint options can be provided in either the endpoint URI, -or dynamically in a message header. The message header name must be of -the format *`CamelOlingo2.<option>`*. Note that the *`inBody`* option -overrides message header, i.e. the endpoint -option *`inBody=option`* would override -a *`CamelOlingo2.option`* header. In addition, query parameters can be -specified. - -[width="100%",cols="10%,20%,70%",options="header",] -|======================================================================= -|Name |Type |Description -|data |Object |Data with appropriate type used to create or modify the OData resource -|keyPredicate |String |Key predicate to create a parameterized OData resource endpoint. Useful for -create/update operations where the key predicate value is dynamically provided in a header -|queryParams |java.util.Map<String,String> |OData system options and custom query options. For more -information see http://www.odata.org/documentation/odata-version-2-0/uri-conventions/[OData 2.0 URI Conventions] -|resourcePath |String |OData resource path, may or may not contain key predicate -|endpointHttpHeaders |java.util.Map<String, String> |Dynamic HTTP Headers to be sent to the endpoint -|responseHttpHeaders |java.util.Map<String, String> |Dynamic HTTP Response Headers from the endpoint -|======================================================================= - -Note that the resourcePath option can either in specified in the URI as -a part of the URI path, as an endpoint option -?resourcePath=<resource-path> or as a header value -CamelOlingo2.resourcePath. The OData entity key predicate can either be -a part of the resource path, e.g. _Manufacturers('1')_, where _'__1'_ is -the key predicate, or be specified separately with resource path -_Manufacturers_ and keyPredicate option _'1'_. - -[width="100%",cols="10%,10%,10%,70%",options="header",] -|======================================================================= -|Endpoint |Options |HTTP Method |Result Body Type - -|batch |data, endpointHttpHeaders |POST with multipart/mixed batch request |java.util.List<org.apache.camel.component.olingo2.api.batch.Olingo2BatchResponse> - -|create |data, resourcePath, endpointHttpHeaders |POST |org.apache.olingo.odata2.api.ep.entry.ODataEntry for new entries -org.apache.olingo.odata2.api.commons.HttpStatusCodes for other OData resources - -|delete |resourcePath, endpointHttpHeaders |DELETE |org.apache.olingo.odata2.api.commons.HttpStatusCodes - -|merge |data, resourcePath, endpointHttpHeaders |MERGE |org.apache.olingo.odata2.api.commons.HttpStatusCodes - -|patch |data, resourcePath, endpointHttpHeaders |PATCH |org.apache.olingo.odata2.api.commons.HttpStatusCodes - -|read |queryParams, resourcePath, endpointHttpHeaders |GET |Depends on OData resource being queried as described next - -|update |data, resourcePath, endpointHttpHeaders |PUT |org.apache.olingo.odata2.api.commons.HttpStatusCodes -|======================================================================= - == Endpoint HTTP Headers -The component level configuration property **httpHeaders** supplies static HTTP header information. + +The component level configuration property **httpHeaders** supplies static HTTP header information. However, some systems requires dynamic header information to be passed to and received from the endpoint. A sample use case would be systems that require dynamic security tokens. The **endpointHttpHeaders** and **responseHttpHeaders** endpoint properties provides this capability. Set headers that need to @@ -336,7 +278,7 @@ Both properties are of the type *`java.util.Map<String, String>`*. == OData Resource Type Mapping The result of *read* endpoint and data type of *data* option depends on -the OData resource being queried, created or modified. +the OData resource being queried, created or modified. [width="100%",cols="10%,10%,80%",options="header",] |======================================================================= @@ -366,39 +308,11 @@ java.util.List<java.util.Map<String, Object>> containing list of key property na |Count |<resource-uri>/$count |java.lang.Long |======================================================================= -== Consumer Endpoints - -Only the *read* endpoint can be used as a consumer endpoint. Consumer -endpoints can -use http://camel.apache.org/polling-consumer.html#PollingConsumer-ScheduledPollConsumerOptions[Scheduled -Poll Consumer Options] to schedule endpoint -invocation. By default consumer endpoints that return an array or -collection will generate one exchange per element, and their routes will -be executed once for each exchange. This behavior can be disabled by -setting the endpoint property *splitResult=false*. - -== Message Headers - -Any URI option can be provided in a message header for producer -endpoints with a *`CamelOlingo2.`* prefix. - -== Message Body - -All result message bodies utilize objects provided by the underlying -http://olingo.apache.org/javadoc/odata2/index.html[Apache Olingo 2.0 -API] used by the Olingo2Component. Producer endpoints can specify the -option name for incoming message body in the *`inBody`* endpoint URI -parameter. For endpoints that return an array or collection, a consumer -endpoint will map every element to distinct messages, unless -*splitResult* is set to *false*. - -== Use cases +== Samples The following route reads top 5 entries from the Manufacturer feed ordered by ascending Name property. - - [source,java] ------------------------------------------------------------ from("direct:...") @@ -406,13 +320,9 @@ from("direct:...") .to("olingo2://read/Manufacturers?orderBy=Name%20asc"); ------------------------------------------------------------ - - The following route reads Manufacturer entry using the key property value in incoming *id* header. - - [source,java] ------------------------------------------------------------ from("direct:...") @@ -420,21 +330,15 @@ from("direct:...") .to("olingo2://read/Manufacturers"); ------------------------------------------------------------ - - The following route creates Manufacturer entry using the *java.util.Map<String, Object>* in body message. - - [source,java] ------------------------------------------------------------ from("direct:...") .to("olingo2://create/Manufacturers"); ------------------------------------------------------------ - - The following route polls Manufacturer http://olingo.apache.org/doc/tutorials/deltaClient.html[delta feed] every 30 seconds. The bean *blah* updates the bean *paramsBean* to @@ -443,7 +347,6 @@ add an updated *!deltatoken* property with the value returned in the consumer endpoint will produce an *ODataFeed* value the first time, and *ODataDeltaFeed* on subsequent polls. - [source,java] --------------------------------------------------------------------------------------------------------- diff --git a/components/camel-olingo4/camel-olingo4-component/src/main/docs/olingo4-component.adoc b/components/camel-olingo4/camel-olingo4-component/src/main/docs/olingo4-component.adoc index 5aa6f43..140e9ac 100644 --- a/components/camel-olingo4/camel-olingo4-component/src/main/docs/olingo4-component.adoc +++ b/components/camel-olingo4/camel-olingo4-component/src/main/docs/olingo4-component.adoc @@ -30,28 +30,25 @@ SSL, OAuth2.0, etc. as required by the target OData service. Maven users will need to add the following dependency to their pom.xml for this component: -[source,java] ----------------------------------------------- - <dependency> - <groupId>org.apache.camel</groupId> - <artifactId>camel-olingo4</artifactId> - <version>x.x.x</version> - <!-- use the same version as your Camel core version --> - </dependency> ----------------------------------------------- +[source,xml] +---- +<dependency> + <groupId>org.apache.camel</groupId> + <artifactId>camel-olingo4</artifactId> + <version>x.x.x</version> + <!-- use the same version as your Camel core version --> +</dependency> +---- == URI format -[source,java] ------------------------------------------------- - olingo4://endpoint/<resource-path>?[options] ------------------------------------------------- +---- +olingo4://endpoint/<resource-path>?[options] +---- == Olingo4 Options - - // component options: START The Olingo4 component supports 16 options, which are listed below. @@ -270,55 +267,9 @@ The `inBody` parameter overrides message header, i.e. the endpoint parameter `in would override a `CamelOlingo4.myParameterNameHere` header. // endpoint options: END -== Producer Endpoints - -Producer endpoints can use endpoint names and options listed -next. Producer endpoints can also use a special option *`inBody`* that -in turn should contain the name of the endpoint option whose value will -be contained in the Camel Exchange In message. The *inBody* option -defaults to *data* for endpoints that take that option. - -Any of the endpoint options can be provided in either the endpoint URI, -or dynamically in a message header. The message header name must be of -the format *`CamelOlingo4.<option>`*. Note that the *`inBody`* option -overrides message header, i.e. the endpoint -option *`inBody=option`* would override -a *`CamelOlingo4.option`* header. In addition, query parameters can be -specified - -Note that the resourcePath option can either in specified in the URI as -a part of the URI path, as an endpoint option -?resourcePath=<resource-path> or as a header value -CamelOlingo4.resourcePath. The OData entity key predicate can either be -a part of the resource path, e.g. _Manufacturers('1')_, where _'__1'_ is -the key predicate, or be specified separately with resource path -_Manufacturers_ and keyPredicate option _'1'_. - -[width="100%",cols="10%,10%,10%,70%",options="header",] -|======================================================================= -|Endpoint |Options |HTTP Method |Result Body Type - -|batch |data, endpointHttpHeaders |POST with multipart/mixed batch request |java.util.List<org.apache.camel.component.olingo4.api.batch.Olingo4BatchResponse> - -|create |data, resourcePath, endpointHttpHeaders |POST |org.apache.olingo.client.api.domain.ClientEntity for new entries -org.apache.olingo.commons.api.http.HttpStatusCode for other OData resources - -|delete |resourcePath, endpointHttpHeaders |DELETE |org.apache.olingo.commons.api.http.HttpStatusCode - -|merge |data, resourcePath, endpointHttpHeaders |MERGE |org.apache.olingo.commons.api.http.HttpStatusCode - -|patch |data, resourcePath, endpointHttpHeaders |PATCH |org.apache.olingo.commons.api.http.HttpStatusCode - -|read |queryParams, resourcePath, endpointHttpHeaders |GET |Depends on OData resource being queried as described next - -|update |data, resourcePath, endpointHttpHeaders |PUT |org.apache.olingo.commons.api.http.HttpStatusCode - -|action |data, resourcePath, endpointHttpHeaders |POST |org.apache.olingo.client.api.domain.ClientEntity for action's -that have a "ReturnType" defined org.apache.olingo.commons.api.http.HttpStatusCode otherwise -|======================================================================= - == Endpoint HTTP Headers -The component level configuration property **httpHeaders** supplies static HTTP header information. + +The component level configuration property **httpHeaders** supplies static HTTP header information. However, some systems requires dynamic header information to be passed to and received from the endpoint. A sample use case would be systems that require dynamic security tokens. The **endpointHttpHeaders** and **responseHttpHeaders** endpoint properties provides this capability. Set headers that need to @@ -353,39 +304,11 @@ java.util.Map<String, Object> for In body (request) |Count |<resource-uri>/$count |java.lang.Long |======================================================================= -== Consumer Endpoints - -Only the *read* endpoint can be used as a consumer endpoint. Consumer -endpoints can -use http://camel.apache.org/polling-consumer.html#PollingConsumer-ScheduledPollConsumerOptions[Scheduled -Poll Consumer Options] to schedule endpoint -invocation. By default consumer endpoints that return an array or -collection will generate one exchange per element, and their routes will -be executed once for each exchange. This behavior can be disabled by -setting the endpoint property *splitResult=false*. - -== Message Headers - -Any URI option can be provided in a message header for producer -endpoints with a *`CamelOlingo4.`* prefix. - -== Message Body - -All result message bodies utilize objects provided by the underlying -http://olingo.apache.org/javadoc/odata4/index.html[Apache Olingo 4.0 -API] used by the Olingo4Component. Producer endpoints can specify the -option name for incoming message body in the *`inBody`* endpoint URI -parameter. For endpoints that return an array or collection, a consumer -endpoint will map every element to distinct messages, unless -*splitResult* is set to *false*. - -== Use cases +== Samples The following route reads top 5 entries from the People entity ordered by ascending FirstName property. - - [source,java] ------------------------------------------------------------ from("direct:...") @@ -393,13 +316,9 @@ from("direct:...") .to("olingo4://read/People?orderBy=FirstName%20asc"); ------------------------------------------------------------ - - The following route reads Airports entity using the key property value in incoming *id* header. - - [source,java] ------------------------------------------------------------ from("direct:...") @@ -407,26 +326,18 @@ from("direct:...") .to("olingo4://read/Airports"); ------------------------------------------------------------ - - The following route creates People entity using the *ClientEntity* in body message. - - [source,java] ------------------------------------------------------------ from("direct:...") .to("olingo4://create/People"); ------------------------------------------------------------ - - The following route calls an odata action using the *ClientEntity* in the body message. The body message may be null for actions that don't expect an input. - - [source,java] ------------------------------------------------------------ from("direct:...") diff --git a/components/camel-twilio/src/main/docs/twilio-component.adoc b/components/camel-twilio/src/main/docs/twilio-component.adoc index 56d1a76..976775d 100644 --- a/components/camel-twilio/src/main/docs/twilio-component.adoc +++ b/components/camel-twilio/src/main/docs/twilio-component.adoc @@ -3600,32 +3600,4 @@ For more information on the endpoints and options see API documentation at: https://www.twilio.com/docs/libraries/reference/twilio-java/index.html -== Consumer Endpoints: - -Any of the producer endpoints can be used as a consumer endpoint. -Consumer endpoints can use -http://camel.apache.org/polling-consumer.html#PollingConsumer-ScheduledPollConsumerOptions[Scheduled -Poll Consumer Options] to schedule endpoint invocation. -Consumer endpoints that return an array or collection will -generate one exchange per element, and their routes will be executed -once for each exchange. - -If you want to receive calls or messages from Twilio and respond to them -using a Camel consumer endpoint, you can use other HTTP-based components -such as *camel-servlet*, *camel-undertow*, *camel-jetty*, and *camel-netty-http* -to respond with https://www.twilio.com/docs/api/twiml[TwiML]. - - -== Message header - -Any of the options can be provided in a message header for producer -endpoints with *CamelTwilio.* prefix. - - -== Message body - -All result message bodies utilize objects provided by the Twilio Java SDK. -Producer endpoints can specify the option name for incoming message body -in the *inBody* endpoint parameter. - include::camel-spring-boot::page$twilio-starter.adoc[] diff --git a/components/camel-zendesk/src/main/docs/zendesk-component.adoc b/components/camel-zendesk/src/main/docs/zendesk-component.adoc index 908e9bc..d4d1679 100644 --- a/components/camel-zendesk/src/main/docs/zendesk-component.adoc +++ b/components/camel-zendesk/src/main/docs/zendesk-component.adoc @@ -18,14 +18,14 @@ allows producing messages to manage Zendesk ticket, user, organization, etc. Maven users will need to add the following dependency to their pom.xml for this component: -[source,java] -------------------------------------------- - <dependency> - <groupId>org.apache.camel</groupId> - <artifactId>camel-zendesk</artifactId> - <version>${camel-version}</version> - </dependency> -------------------------------------------- +[source,xml] +---- +<dependency> + <groupId>org.apache.camel</groupId> + <artifactId>camel-zendesk</artifactId> + <version>${camel-version}</version> +</dependency> +---- == Zendesk Options @@ -1369,35 +1369,4 @@ would override a `CamelZendesk.myParameterNameHere` header. -== Producer Endpoints: - -Producer endpoints can use endpoint names and associated options described next. - - -== Consumer Endpoints: - -Any of the producer endpoints can be used as a consumer endpoint. -Consumer endpoints can use -http://camel.apache.org/polling-consumer.html#PollingConsumer-ScheduledPollConsumerOptions[Scheduled -Poll Consumer Options] to schedule endpoint invocation. -Consumer endpoints that return an array or collection will -generate one exchange per element, and their routes will be executed -once for each exchange. - - -== Message header - -Any of the options can be provided in a message header for producer -endpoints with *CamelZendesk.* prefix. In principal, parameter names are same as -the arugument name of each API methods on the original `org.zendesk.client.v2.Zendesk` - class. However some of them are renamed to the other name to avoid confliction in the - camel API component framework. To see actual parameter name, please check `org.apache.camel.component.zendesk.internal.ZendeskApiMethod`. - - -== Message body - -All result message bodies utilize objects provided by the Zendesk Java Client. -Producer endpoints can specify the option name for incoming message body -in the *inBody* endpoint parameter. - include::camel-spring-boot::page$zendesk-starter.adoc[]