discordjs / discord-api-types

Up to date Discord API Typings, versioned by the API version
https://discord-api-types.dev
MIT License
535 stars 117 forks source link

APIRole - Missing Type - APIRole["permissions_new"] #734

Closed LKNSI closed 1 year ago

LKNSI commented 1 year ago

Issue description

Hi!

Feel free to close this if I am making a mistake, but for APIRole (And every other type that makes use of it) may be missing a new property "permissions_new".

Here's the latest response from the guild role endpoint at /guilds/x/roles

{
        "id": "x",
        "name": "x",
        "description": null,
        "permissions": 104320834,
        "position": 18,
        "color": 16732416,
        "hoist": true,
        "managed": false,
        "mentionable": true,
        "icon": "x",
        "unicode_emoji": null,
        "flags": 0,
        "permissions_new": "2171210288962"
    },

Code sample

No response

Package version

0.37.36

Runtime

Node.js

Runtime version

v18.12.1

Priority this issue should have

Medium (should be fixed soon)~~

vladfrangu commented 1 year ago

Holy heck this is an outdated API field! You might be on API v6 or v7, as v8 and onwards has permissions as strings from the get-go. You should really update!

Jiralite commented 1 year ago

Read more here: https://discord.com/developers/docs/change-log#api-and-gateway-v8

LKNSI commented 1 year ago

Completely my fault, forgot to add /v10 to the route and was misattributing it to the types. Was too used to discordjs directly using the latest version, when using the API directly over HTTP.

Appreciate your patience, seems like a dumb mistake in retrospect! :)