Skip to main content

Testing a proxy

Compare two runs​

Run once against Discord, once against the proxy, and compare:

bucketmap run -guild GUILD_ID -users USER1,USER2,USER3,USER4 -report direct.json
bucketmap run -api http://localhost:8080/api/v10 -guild GUILD_ID -users USER1,USER2,USER3,USER4 -report proxied.json
bucketmap compare direct.json proxied.json

The proxy conforms when every step answered the same and nothing through it hit a 429. The same works for anything that stands in for Discord, such as a simulator.

This is how we check our fork of Nirn Proxy.

In CI​

Call the reusable conformance workflow from your repository. It runs the engine and uploads the report:

.github/workflows/bucketmap.yml
jobs:
bucketmap:
uses: FCAgreatgoals/bucketmap/.github/workflows/conformance.yml@main
with:
api: https://discord.com/api/v10 # or your proxy
secrets:
token: ${{ secrets.BUCKETMAP_TOKEN }}
guild: ${{ secrets.BUCKETMAP_GUILD }}
users: ${{ secrets.BUCKETMAP_USERS }} # four IDs, comma separated