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

avatar_decoration field in User object is undocumented #5690

Closed
drakon64 opened this issue Nov 29, 2022 · 6 comments · Fixed by #5723
Closed

avatar_decoration field in User object is undocumented #5690

drakon64 opened this issue Nov 29, 2022 · 6 comments · Fixed by #5723
Labels

Comments

@drakon64
Copy link
Contributor

Description

A User object returned by the Discord API returns an undocumented field named avatar_decoration.

Steps to Reproduce

Invoke an endpoint that returns a User object

Expected Behavior

The Discord API returns only fields documented at https://discord.com/developers/docs/resources/user#user-object-user-structure.

Current Behavior

The Discord API returns the fields documented at https://discord.com/developers/docs/resources/user#user-object-user-structure and an additional avatar_decoration field.

Screenshots/Videos

No response

Client and System Information

Own library

@drakon64 drakon64 added the bug label Nov 29, 2022
@AlmostSuspense
Copy link
Contributor

the existence of undocumented fields is not a bug, they're just related to unreleased features. the rule of thumb is if it's not documented, ignore it

@drakon64
Copy link
Contributor Author

How is this completed? The fields are still undocumented and the PR to actually resolve this is still open.

@ooliver1
Copy link

Likely since it was reported as a bug but it is not.

@drakon64
Copy link
Contributor Author

Funny definition of 'completed'.

@yonilerner
Copy link
Member

Like AlmostSuspense said, this is not a bug. If you'd prefer I not "complete" it, I could delete it instead :)

@yonilerner yonilerner closed this as not planned Won't fix, can't repro, duplicate, stale Dec 22, 2022
@drakon64
Copy link
Contributor Author

If you want to point out where the solution is 'just ignore it', fine, I will admit that I missed it (although adding fields to a versioned API seems questionable). Otherwise, the fact that not all fields are documented should be documented for serialisation libraries that will throw an exception by default if unknown fields are attempted to be serialised (i.e KotlinX Serialization).

If you'd prefer I not "complete" it, I could delete it instead :)

Aside from being an incredibly immature response, this is also unhelpful in the event someone else runs into the same issue and wants to see the solution :)

drakon64 added a commit to TempestProject/KtDiscord that referenced this issue Dec 23, 2022
Per discord/discord-api-docs#5690 the solution appears to be to just ignore them
drakon64 added a commit to TempestProject/TempestBot that referenced this issue Dec 23, 2022
Not all fields returned by the API are actually documented, and per discord/discord-api-docs#5690 the solution seems to be to ignore them
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging a pull request may close this issue.

4 participants