Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

serialized_source_guild in Guild Template returns the incorrect type for the system_channel_id field #6609

Closed
kagadar opened this issue Jan 8, 2024 · 2 comments
Labels
bug synced Synced to internal tracker

Comments

@kagadar
Copy link

kagadar commented Jan 8, 2024

Description

Using https://discord.com/developers/docs/resources/guild-template#get-guild-template the guild template object, https://discord.com/developers/docs/resources/guild-template#guild-template-resource, has a field serialized_source_guild, which is a guild object: https://discord.com/developers/docs/resources/guild#guild-object

This object has a field system_channel_id of type snowflake

According to https://discord.com/developers/docs/reference#snowflakes, the API should return these as a string, however the value returned by the API is a number.

Steps to Reproduce

New template that exhibits this behaviour: https://discord.com/api/v9/guilds/templates/5TA7DUe7aAEy

Expected Behavior

The system_channel_id should be a string.

Current Behavior

The system_channel_id is a number.

Screenshots/Videos

No response

Client and System Information

Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/120.0.0.0 Safari/537.36

@kagadar
Copy link
Author

kagadar commented Jan 10, 2024

Just to add to this, the initial report only specifies one snowflake field in the serialized_source_guild as impacted, but it seems like most, if not all, snowflake fields are returning numbers instead of strings.

@kagadar kagadar closed this as completed Jan 10, 2024
@kagadar kagadar reopened this Jan 10, 2024
@appellation
Copy link
Contributor

This behavior is intentional, but it's true that the docs are incorrect here.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug synced Synced to internal tracker
Projects
None yet
Development

No branches or pull requests

3 participants