The Codeberg Documentation website is licensed under a Creative Commons Attribution-ShareAlike 4.0 International License.
It bundles third-party font software licensed under a different license. Please look at the LICENSE file for details.
Changes to the original versions of the article as well as its individual authors can be looked up in this article's commit history
Codeberg and the Codeberg Logo are trademarks of Codeberg e.V.
This article will guide you through integrating Codeberg with Matrix, allowing repo updates to be automatically broadcast to your project's Matrix room.
To set up the Matrix integration, it is recommended that you create a new account dedicated to broadcasting your repo updates. This will act as a bot account. You can create an account on your preferred Matrix server.
You will need an access token to give Codeberg access to send updates from your dedicated Matrix account. Here's how to do it on the Element web client.
All Settings
in the dropdown.Help & About
tab on the left.Access Token
dropdown in the advanced section.Alternatively, you can get an access token directly from the Matrix API. Read more at Matrix's documentation.
Now we will connect the Matrix bot to your Codeberg repository. You will need admin permissions for the repo.
In a web browser, go to your repo and click on the Settings
button on the top right.
Navigate to the Webhooks
settings tab.
Click on the Add Webhook
button and select Matrix
.
Here are explanations for some key fields:
https://matrix.org
!VTjWrzxSWgLJnHgDUd:matrix.org
. You can find this on Element in the Advanced
tab for the room settings.Bearer <your_access_token>
. The access token is the one you got earlier.m.text
is the most basic type of plaintext message, whereas m.notice
is intended for bots and behaves slightly differently.Add your webhook, then click on the webhook URL. At the bottom now, there will be a Test Delivery
button. Click this, and you will receive a message on your Matrix room!
Hey there! 👋 Thank you for reading this article!
Is there something missing, or do you have an idea on how to improve the documentation? Do you want to write your own article?
You're invited to contribute to the Codeberg Documentation at its source code repository, for example, by adding a pull request or joining in on the discussion in the issue tracker.
For an introduction on contributing to Codeberg Documentation, please have a look at the Contributor FAQ.
© Codeberg Docs Contributors. See LICENSE