Open RappyTV opened 1 week ago
discord.js
Discord has recently updated the way premium interactions work and it would be great to be able to use it with discord.js.
Interaction#sendPremiumRequired
This change deprecates Interaction Response Type 10
Add ButtonStyle#Premium and a new skuId field for buttons and the corresponding methods on the ButtonBuilder (e. g. #setSkuId) https://discord.com/developers/docs/interactions/message-components#button-object-button-styles
ButtonStyle#Premium
skuId
ButtonBuilder
#setSkuId
Premium buttons must contain a sku_id, and cannot have a custom_id, label, url, or emoji
sku_id
custom_id
label
url
emoji
Example premium button object:
{ "type": 2, "style": 6, "sku_id": "<SKU ID>" }
Add SKU#getUrl and ClientApplication#getStoreUrl (can also be Client#getStoreUrl) https://discord.com/developers/docs/monetization/skus#linking-to-your-skus
SKU#getUrl
ClientApplication#getStoreUrl
Client#getStoreUrl
You can link directly to a specific SKU using our Application Directory Store URL scheme: https://discord.com/application-directory/:appID/store/:skuID
https://discord.com/developers/docs/monetization/managing-your-store#linking-to-your-store
You can link directly to your Store using our Application Directory Store URL scheme: https://discord.com/application-directory/:appID/store
No response
Hi, be sure to search open issues or pull requests. It could have saved you writing all this.
oh I only looked at the issues i'm sorry 💀
Which application or package is this feature request for?
discord.js
Feature
Discord has recently updated the way premium interactions work and it would be great to be able to use it with discord.js.
Ideal solution or implementation
Interaction#sendPremiumRequired
https://discord.com/developers/docs/change-log#premium-apps-new-premium-button-style-deep-linking-url-schemesAdd![image](https://github.com/discordjs/discord.js/assets/72705182/0298074b-f2a6-472e-882b-6922ffa5c566)
ButtonStyle#Premium
and a newskuId
field for buttons and the corresponding methods on theButtonBuilder
(e. g.#setSkuId
) https://discord.com/developers/docs/interactions/message-components#button-object-button-stylesExample premium button object:
Add
SKU#getUrl
andClientApplication#getStoreUrl
(can also beClient#getStoreUrl
) https://discord.com/developers/docs/monetization/skus#linking-to-your-skushttps://discord.com/developers/docs/monetization/managing-your-store#linking-to-your-store
Alternative solutions or implementations
No response
Other context
No response