Commit Graph

351 Commits

Author SHA1 Message Date
Niloth P
ad122af6f8 integrations: Use dir_name instead of name for default view fn.
Use the directory name as the template literal in the default view
function path.
2025-10-14 12:17:05 -07:00
Niloth P
23740c97a4 integrations: Remove redundant arguments. 2025-10-14 12:17:05 -07:00
Niloth P
f33ef8f206 integrations: Rename IFTTT view function to match conventions. 2025-10-14 12:17:05 -07:00
Niloth P
1f4267f3e0 integrations: Add screenshot configs for monitoring integrations.
that do not have fixtures.
2025-10-03 15:38:03 -07:00
Niloth P
d70b099644 integrations: Add screenshot configs for productivity integrations.
that do not have fixtures.
2025-10-03 15:38:03 -07:00
Niloth P
433f43a9b4 integrations: Add screenshot configs for communication integrations.
that do not have fixtures.
2025-10-03 15:38:03 -07:00
Niloth P
f5e925b26b integrations: Add screenshot configs for the project management type.
of integrations that do not have fixtures.
2025-10-03 15:38:03 -07:00
Niloth P
24eab61ab0 integrations: Add screenshot configs for deployment integrations.
that do not have fixtures.
2025-10-03 15:38:03 -07:00
Niloth P
7f2161bffa integrations: Add screenshot configs for fixtureless CI integrations. 2025-10-03 15:38:03 -07:00
Niloth P
65d01b553b integrations: Add screenshot configs for fixtureless VCS integrations.
Co-authored-by: Lauryn Menard <lauryn@zulip.com>
2025-10-03 15:38:03 -07:00
Niloth P
23a8e26741 integrations: Load optional fields for fixtureless screenshot configs.
The hardcoded content (topic and message) for the screenshot configs are
loaded from `fixtureless_integrations.py`. Add a new
FIXTURELESS_SCREENSHOT_CONFIG_OPTIONAL_FIELDS dict to maintain the
optional fields of fixtureless screenshot configs, and load both into
FIXTURELESS_SCREENSHOT_CONFIG.

This commit does not set any screenshot configs, but only adds the
framework.
2025-10-03 15:38:03 -07:00
Niloth P
c7a6fcaf88 integrations: Add new file for fixtureless screenshot configs registry.
This does not include any screenshot configs, just defining the format,
and loading FIXTURELESS_SCREENSHOT_CONFIG from the file.

Co-authored-by: Lauryn Menard <lauryn@zulip.com>
2025-10-03 15:38:03 -07:00
PieterCK
3863f4d6a5 integrations: Add IGNORE_PRIVATE_REPOSITORIES preset WebhookUrlOption.
This refactors the `ignore_private_repositories` URL option to be a
preset because it can be used by other "version-control" integrations.
2025-08-07 17:19:03 -07:00
PieterCK
57ff908af9 webhook_common: Add a method to build preset WebhookUrlOption.
This adds `WebhookUrlOption.build_preset_config` method which builds
pre-configured WebhookUrlOptions objects. It can be used to abstract
commonly used WebhookUrlOption settings or to construct special
settings that have additional logic and UI in the web-app modal for
generating an incoming webhook URL.

Currently, one such setting is the "branches" url option. This setting
is meant to be used by "versioncontrol" integrations such as GitHub,
Gitea, etc. It adds UI that lets the user to choose which branches of
their repository can trigger notifications. So, we refactor those
integrations to use `build_preset_config` for the "branches" option.

Co-authored-by: Lauryn Menard <lauryn@zulip.com>
2025-08-07 17:19:03 -07:00
Niloth P
c75a48b63b integrations: Remove Phabricator integration.
Phabricator has not been actively maintained since June 2021.
2025-07-14 12:03:48 -07:00
PieterCK
feb25b0e6b integrations: Move configs in config_options to url_options.
Currently we have 2 implementations of `config_options`:

- It's used for generating optional webhook URL parameters. These
settings also come with custom UI in the "Generate integration URL"
modal.

- In `/bots` API, it's used as schema for the bots `BotConfigData`. Each
type of bots have different ways of defining their `BotConfigData`
fields. Currently, only embedded bots use `BotConfigData`, and only the
incoming webhooks use `config_options` to configure a bot's
`BotConfigData`; thus, the `config_options` remain unused.

To avoid confusion as to which implementation of `config_options` is
used by an integration, this separates the first use case -- to generate
optional webhook URL -- to a new field called `url_options`. Thus, the
`config_options` field is reserved only for the second use case.
2025-07-09 10:12:33 -07:00
Niloth P
fb74cd3ddf webhooks/opsgenie: Support linking to EU instances.
Adds a URL parameter to the webhook to track the region of the Opsgenie
instance (US/EU), and uses that to construct the alert URL in the
message.

Fixes #34947.
2025-06-25 11:52:02 -07:00
Niloth P
f99772b131 integrations: Add missing parameter to Transifex's screenshot config. 2025-06-09 15:59:39 -07:00
Niloth P
2a2ca01cad integrations: Add FIXTURELESS_SCREENSHOT_CONFIG.
Created a `WEBHOOK_SCREENSHOT_CONFIG` to track those separately, by
renaming the existing `DOC_SCREENSHOT_CONFIG` which contained only the
configs for webhook integrations.

Tracking the screenshot configs separately allows us to generate
the screenshots of all fixtureless integrations in a single batch, and
all webhook integrations in their own separate batch.
2025-06-01 11:38:02 -07:00
Niloth P
9ec98966e3 integrations: Add dataclass FixturelessScreenshotConfig. 2025-06-01 11:38:02 -07:00
Niloth P
0b8e042627 integrations: Split the getters for fixture_path and image_path.
This is in preparation of adding support for generating screenshots of
fixtureless integrations, which would need to get image_path, without
involving fixture_path.
2025-06-01 11:38:02 -07:00
Niloth P
94a5ced243 integrations: Rename ScreenshotConfig to WebhookScreenshotConfig.
This is in preparation to differentiate the current config dataclass
(used for webhooks) from the FixturelessScreenshotConfig that will be
added for non-webhook integrations in the following commits.
2025-06-01 11:38:02 -07:00
Niloth P
9f92ae710f integrations: Remove support for non-webhook example screenshots.
- Removed the BaseScreenshotConfig dataclass, and merge it with
ScreenshotConfig dataclass.
- Simplified get_fixture_and_image_paths.
- Simplified generate_screenshot_from_config in the screenshot script.
- Deleted send_bot_mock_message.
2025-06-01 11:38:02 -07:00
Niloth P
0b69548ded integrations: Remove Nagios fixture used for example screenshot.
Nagios is not a webhook integration, and the fixture is only used to
generate the example screenshot for the doc.

Support for generating the Nagios example screenshot will be added in a
later commit, in a different format and system. Removing this fixture
allows removing the current system logic, without raising errors.
2025-06-01 11:38:02 -07:00
nirved.mishra.eee23@itbhu.ac.in
3fc63110ac incoming-webhooks: Add OpenProject integration.
Fixes #29944.

Co-authored-by: theofficialvedantjoshi <vedant.messi101@gmail.com>
Co-authored-by: Niloth P <20315308+Niloth-p@users.noreply.github.com>
2025-05-05 12:23:04 -07:00
Varun-Kolanu
4f8263cd7f integrations: Update example screenshot for JotForm.
This commit updates the screenshot for the JotForm
integration to better demonstrate its utility
in enhancing business workflows for Zulip users.
2025-04-25 15:34:00 -07:00
Niloth P
22c80117f5 integrations: Add OpenSearch incoming webhook integration.
Co-authored-by: merlinz01 <158784988+merlinz01@users.noreply.github.com>
2025-04-16 14:05:29 -07:00
Niloth P
b2910aa05c integration-docs: Migrate PythonAPIIntegration docs.
To zulip/python-zulip-api, to keep them closer to their source code.

- Renamed the generate_zulip_bots_static_files to
generate_bots_integrations_static_files to accomodate the new function.
- Added a new function to
tools/setup/generate_bots_integrations_static_files to copy the
integration docs into static/generated/integrations.
- Updated integrations.py and computed_settings.py to use the new doc
paths.
- Deleted the affected integration docs.
- Updated the dependency URL.
2025-03-26 11:19:31 -07:00
Niloth P
e76ace28d2 integration-docs: Rename Jira doc to avoid collision with Jira plugin.
The Jira plugin integration doc will be moved in the next commit, to
"static/generated/integrations/jira/doc.md", as the directory name of
the integration is "jira" in zulip/python-zulip-api.

- Jira integration doc (previously) - "zerver/webhooks/jira/doc.md"
- Jira plugin integration doc (next commit) -
"static/generated/integrations/jira/doc.md"

Both of these will use the same path "jira/doc.md" as their
integration.doc value, and the actual file is loaded based on the order
of template directories listed in computed_settings.py.

Hence, use a custom path for the Jira integration doc to avoid this
collision.
2025-03-26 11:19:31 -07:00
Niloth P
4b9317cee4 integrations: Add missing directory_name for Jira plugin integration. 2025-03-26 11:19:31 -07:00
Niloth P
4975f5b0fa integrations: Remove Jenkins from the Python API integrations' dict.
Jenkins is a plugin integration, that had been mistakenly marked as a
PythonAPIIntegration.
2025-03-26 11:19:31 -07:00
Niloth P
136b852749 integrations: Use branch-filtering UI for Git-related integrations.
The integration-URL modal uses the branch-filtering UI for the
integrations that have the config option "branches".

Fixes: #33738.
2025-03-05 10:39:13 -08:00
Niloth P
f78f4b0e4b python-api-integrations: Map to directory names used in the API repo.
Added a `directory_name` field in PythonAPIIntegration objects to map
each integration to their corresponding directory in
zulip/python-zulip-api.
2025-02-24 17:04:58 -08:00
Niloth P
6475628f26 integrations: Add class PythonAPIIntegration.
For the class of integrations that exist in zulip/integrations
of the zulip/python-zulip-api repo.
2025-02-24 17:04:58 -08:00
Niloth P
c2ab2c8b73 integrations: Add a default doc path. 2025-02-24 17:04:58 -08:00
Niloth P
cdd39c9c71 integrations: Move big-blue-button logo to the default path. 2025-02-24 17:04:58 -08:00
Niloth P
3d178b0cd0 integrations: Remove unused extension variable.
Since 0904d61, we don't support HTML docs, and all docs use `.md`, so we
can remove the extension variable.
2025-02-24 17:04:58 -08:00
Niloth P
0c6bbe17e3 integrations: Remove arguments passing default logo path values. 2025-02-01 15:38:46 -08:00
Niloth P
249da6ec43 webhooks: Remove arguments passing default image_name values. 2025-02-01 15:38:46 -08:00
Niloth P
51839a72b9 HomeAssistant: Convert image instructions to code blocks.
Renamed the example screenshot to default image name as well.
2025-02-01 15:38:46 -08:00
Niloth P
fa0ea2aa2d webhooks: Remove second example screenshot from Sentry and Teamcity. 2025-02-01 15:38:46 -08:00
Niloth P
74d730f464 webhooks: Rename example screenshot images to match the default name.
The integrations - GoSquared, Greenhouse, OpsGenie and Zendesk - have
been using `000.png` as their example screenshots, renamed them to
match the default name `001.png`, to avoid passing them as arguments.
2025-02-01 15:38:46 -08:00
Niloth P
297c529b1b integrations: Move GIPHY logo to the default path.
Generated the bot avatar for GIPHY.
2025-02-01 15:38:46 -08:00
Niloth P
eb353827b2 integrations: Document Zulip Onyx integration.
The integration with Onyx is via the Zulip Connector of Onyx.
2025-01-30 11:48:11 -08:00
Niloth P
dbced00e47 hubot-integrations: Utilize a constant DOC_PATH for readability. 2025-01-21 15:07:55 -08:00
Niloth P
727fa9f32f hubot-integrations: Add secondary line text for all Hubot scripts. 2025-01-21 15:07:55 -08:00
Niloth P
e7f4d16863 hubot-integrations: Remove the unused logo_alt property.
This was used before `alt="{{ integration.display_name }} logo"` was set
in the common template `integrations/index.html` for all integration
logos. It is no longer necessary.
2025-01-21 15:07:55 -08:00
Niloth P
4b0172b282 hubot-integrations: Update link prefix to GitHub repositories.
The `hubot-scripts` account has been taken over.
While calls to the current set of URLs work as they are redirected to
the new links, this commit updates the link to refer to the right
GitHub account.
2025-01-21 15:07:55 -08:00
Niloth P
7261898d89 integrations: Remove Desk.com integration.
Desk.com has been discontinued by Salesforce in March 2020.
2024-12-31 16:31:48 -08:00
PieterCK
f29312ce03 slack-integration: Update Slack integration to handle Events API.
This updates the Slack webhook integration to handle the Slack Events
API[1], while maintaining backwards compatibility with Slack's legacy
Outgoing Webhook service.

The Events API introduces the "challenge" handshake[2] to verify and
add a new webhook URL for them to call. This commit adds a handler for
the challenge handshake.

Additionally, this commit reformats incoming payloads using the Slack
text reformatter from `slack_message_conversion.py`. There is some
duplicative code here because of the difference in Slack export data
and Slack's webhook payload.

Part of #30465

[1]: https://api.slack.com/apis/events-api#using-events-api
[2]: https://api.slack.com/apis/events-api#handshake
2024-12-11 13:06:52 -08:00