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

Added missing createdAt prop from Interaction's docs #1500

Open
wants to merge 1 commit into
base: dev
Choose a base branch
from

Conversation

dmkng
Copy link

@dmkng dmkng commented Apr 30, 2024

I noticed that the createdAt property is missing from the Interaction's documentation page, so I added it like it's added in e.g. the Channel's docs.

@iiFDCT
Copy link
Contributor

iiFDCT commented May 7, 2024

Afaik Discord don't send a timestamp with interactions? It's not on Discords documentation atm and even when I look at the raw interaction payload that Discord sends, no timestamp appears

@dmkng
Copy link
Author

dmkng commented May 7, 2024

Afaik Discord don't send a timestamp with interactions? It's not on Discords documentation atm and even when I look at the raw interaction payload that Discord sends, no timestamp appears

createdAt property is inherited from Base, it extracts timestamp from id property. I tested it and it works like a charm.

@iiFDCT
Copy link
Contributor

iiFDCT commented May 7, 2024

Afaik Discord don't send a timestamp with interactions? It's not on Discords documentation atm and even when I look at the raw interaction payload that Discord sends, no timestamp appears

createdAt property is inherited from Base, it extracts timestamp from id property. I tested it and it works like a charm.

Right ik that, I just couldn't get it to work for me lol so if it works for you then clearly I'm doing something wrong. If it works in your testing then TS docs for the Interaction class will need to include createdAt too. Looks like TS docs only documents createdAt in UnknownInteraction atm

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

Successfully merging this pull request may close these issues.

None yet

2 participants