matrix-org / matrix-org/matrix-hookshot

Add ability to handle image URLs from generic webhooks

Open
#470 1 comment 0 reactions 0 assignees View on GitHub
T-Enhancement
Dominant language
TypeScript
Stars
450
Forks
95
Avg merge
1d 2h
Merged PRs (30d)
23

Description

**Is your feature request related to a problem? Please describe.**
If the JSON payload from a generic webhook includes a URL for an image, there currently is no simple way to include that image within a message.

**Describe the solution you'd like**
Matrix-hookshot could convert the URL to MXC, perhaps via some transformation JavaScript function. Then a user could include that MXC address within the HTML or Markdown for their message.

**Describe alternatives you've considered**
It's possible to simply include the URL in the message and if URL previews are turned on, the image will display at the bottom of the message. This isn't ideal though since not all homeservers or rooms have URL previews on. Also, the preview image is often cropped in odd ways, and the image can't be displayed within the body of the message.

Contributor guide

Open the contributing guide

Research direction

The issue names no files or tests. Start by tracing generic webhook payload handling and the existing Matrix message transformation path, then investigate how image URLs could become MXC addresses. Done means a webhook image URL can be embedded in the message body without relying on URL previews, including the requested HTML or Markdown use cases.

Written by the indexing model from the issue text.

Assessment

Tech stack
typescript
Domain
api, backend
Issue type
Feature
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Needs clarification
Newbie friendliness
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.