davsclaus opened a new pull request, #3146:
URL: https://github.com/apache/camel-kamelets/pull/3146

   _Claude Code on behalf of Claus Ibsen_
   
   A batch of Kamelets rewritten to the documentation standard proposed in 
#3140, `docs/modules/ROOT/pages/documenting.adoc`, like #3141–#3145.
   
   This batch has 18 Kamelets and their partial pages:
   - `slack-sink` and `slack-source`;
   - `telegram-sink` and `telegram-source`;
   - the three Twitter sources;
   - `jira-add-comment-sink`, `jira-transition-issue-sink`, 
`jira-update-issue-sink`, `jira-source` and `jira-oauth-source`;
   - the six Salesforce Kamelets.
   
   ## How they were checked
   
   None of these services has a `camel infra` stand-in, and no real account was 
used. Instead, each Kamelet was run against a small local fake of the service's 
API, which showed the exact requests it sends and what it gets back. The fakes 
covered:
   - the Slack webhook and Slack API;
   - the Telegram Bot API;
   - Twitter API v1.1;
   - Jira REST;
   - the Salesforce login and REST.
   
   `jira-oauth-source` and `salesforce-pubsub-source` were checked from the 
template and the component source, up to the login step. JSON results were run 
on Camel 4.23.0 and 4.24.0-SNAPSHOT.
   
   ## Facts that were missing or wrong before
   
   - **Credentials:** every credential option now says where to get it: the 
Slack Incoming Webhooks page, BotFather, the X developer portal's Keys and 
Tokens page, a Salesforce connected app, or a Jira API token or personal access 
token.
   - **`slack-source`:**
     - `channel` is a name without `#`; the old example `#myroom` fails with 
"Channel #myroom not found";
     - on start it also sends the latest existing message.
   - **`slack-sink`:** the webhook decides the channel. The partial page 
claimed direct messages, threads and attachments, which this webhook Kamelet 
cannot do.
   - **Telegram:**
     - `telegram-sink` sends text or a photo, and the `chat-id` header chooses 
the chat;
     - the `telegram-source` partial page described a `chatId` option that does 
not exist.
   - **Twitter:** the three sources use API v1.1 and poll every 30 s. The 
direct message source reads every message of the account, sent and received, 
and sends them all again after a restart.
   - **Jira:**
     - `jira-transition-issue-sink` adds the body as a comment and needs the 
numeric transition ID;
     - `jira-update-issue-sink` replaces the description with the body;
     - `jira-source` sends only issues created after it starts, and `jql` must 
not contain `ORDER BY`;
     - the four OAuth options of `jira-oauth-source` were titled "Username" and 
"Password".
   - **Salesforce:**
     - update returns the `payload`, and delete returns an empty body;
     - composite upsert returns one result per record, and a refused record 
does not fail the message;
     - `salesforce-source` creates or updates its PushTopic in Salesforce when 
it starts;
     - the `JWT` login also needs `userName`;
     - the pubsub `AVRO` type gives an Avro record, not "binary".
   - **Partial pages:** all 18 are corrected where they described options or 
features these Kamelets do not have.
   
   ## Found on the way, not changed here
   
   - **`jira-source` and `jira-oauth-source` do not start on Camel 4.24.** 
`JodaModule` is a Jackson 2 module, and the `json` format is Jackson 3 in 4.24. 
The Jira sinks carry the same unused `jackson-datatype-joda:2.12.5` dependency.
   - **On Camel 4.23:**
     - the three Twitter sources fail on every tweet: `LocalDateTime` is not 
supported by `marshal: json`;
     - `slack-source` delivers every message, then logs it as failed.
     - Both work on 4.24.
   - **`ce-issueDescription` is never read.** `jira-update-issue-sink` (and 
`jira-add-issue-sink`) map it to `CamelJiraIssueDescription`, which no Jira 
producer reads. The description always comes from the body. The descriptions 
now say what really happens.
   - **`twitter-directmessage-source`:** the component ignores the required 
`user` option.
   - **The Salesforce Kamelets do not start on Camel JBang** (4.23 and 4.24): 
`NoClassDefFoundError: com/google/protobuf/RuntimeVersion$RuntimeDomain`. They 
do with `--dep=com.google.protobuf:protobuf-java:4.35.1`.
   - **Options the routes need but `required` does not list:** `jira-source` 
`jql` and `salesforce-create-sink` `sObjectName`. Also, `salesforce-source` 
`replayId` is typed `long`, which is not a JSON Schema type.
   
   ## Notes for review
   
   - No template, type, default or required list was changed. The `dataTypes` 
blocks are `headers` only, with no `default`.
   - `KameletsCatalogTest.testSupportedHeaders`: the catalog now returns the 
headers these Kamelets declare instead of those of their components. The 
changed counts:
     - `jira-add-comment-sink` 17 → 1
     - `salesforce-source` 22 → 4
     - `telegram-sink` 6 → 5
     - `telegram-source` 5 → 2
     - `twitter-directmessage-source` 2 → 1
     - `twitter-search-source` 7 → 1
   - This PR is based on `main`; if #3140 merges first, I will rebase it and 
regenerate the index.
   
   `./mvnw clean install` from the root passes.
   
   🤖 Generated with [Claude Code](https://claude.com/claude-code)
   


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to