Skip to content

Cross-repo audit: bugs, typos, and broken links across Discord open-source repos #8203

@Akenove

Description

@Akenove

Summary

Ran an audit across Discord's public repos and found several issues. Consolidating everything into one issue instead of opening multiple PRs.

Bugs

discord/linked-roles-sample

  • Metadata key mismatch: register.js registers key as bakingsince but server.js pushes metadata as firstcookiebaked — linked roles silently fail to display
  • Missing express.json() middleware: /update-metadata endpoint reads req.body.userId but no body parser is configured — always undefined
  • Null token crash: updateMetadata() crashes with TypeError if user has no stored tokens

discord/access

  • Broken notification URLs: Both notifications.py and notifications_slack/notifications.py generate /requests/{id} links for role requests, but the frontend routes them to /role-requests/:id — every notification link 404s (fixes Document channel-icons/ CDN endpoint #383)
  • Typo: occuredoccurred in modify_group_users.py:197 and modify_role_groups.py:197

discord/getting-started-activity

  • No error handling on token exchange: server.js returns {access_token: undefined} when Discord API returns an error
  • Package name typo: getting-starter-activity-servergetting-started-activity-server

discord/discord-interactions-js

  • 4 missing component types: FileUpload (19), RadioGroup (21), CheckboxGroup (22), Checkbox (23) are in the API docs but not in the npm package
  • No MODAL_SUBMIT test coverage: InteractionType 5 is the only type without a test case

Typos (discord-api-docs)

Already fixed via merged PRs #8198 and #8202:

  • attacheattach
  • Guilt TemplateGuild Template
  • preferedpreferred
  • have havehave
  • the thethe
  • to toto
  • Missing space before inline code in gateway-events.mdx

Old Docs URLs

Multiple repos still reference discord.com/developers/docs/ instead of the new docs.discord.com/developers/ format. The old URLs 301 redirect so nothing is broken, but for consistency:

Repo Count
discord-api-docs 187
discord-interactions-js 43
embedded-app-sdk-examples 20
discord-example-app 16
user-install-example 9
embedded-app-sdk 7
heroku-sample-app 5
linked-roles-sample 5
cloudflare-sample-app 4
avatar-remix-bot 3
getting-started-activity 2
social-sdk-unity-sample 2

Happy to submit PRs for any of these if helpful — just wanted to consolidate everything in one place first.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions