Discord Activities
Activities are a way to enjoy shared experiences with friends, such as games and media, on Discord itself.
Installation
Run the following command in your project directory:
Status
Beta
Source
License
Apache 2.0
Database
No Database
Actors
0 actors
Public Scripts
No public scripts
Internal Scripts
No internal scripts
Integrate your Rivet game with Discord Activities.
1
Set up Discord SDK
Set up the Discord SDK (docs):
2
Update lobbies code
Update your Rivet matchmaking code to include tags:
3
Set up route mapping
After following the activity tutorial, access the URL mapping for your Discord app and configure it like so:
Prefix | Target |
---|---|
/gstatic | fonts.gstatic.com/ |
/ws | lobby.rivet.run/ |
/api | api.rivet.gg/ |
/ | asteroids-xxx.rivet.game/ |
The URL used for the “Root Mapping” will be printed in the console when you deploy to Rivet via rivet deploy
.
4
Run activity
Run activity (read docs here)
Example repo
A fully integrated example can be found here. (This is using a slightly dated API, but is lagely identical.)