Skip to content

Extend media Type with variants property - #44

Merged
daneden merged 1 commit into
daneden:mainfrom
emin-grbo:add-variants-media-field
Aug 11, 2022
Merged

Extend media Type with variants property#44
daneden merged 1 commit into
daneden:mainfrom
emin-grbo:add-variants-media-field

Conversation

@emin-grbo

Copy link
Copy Markdown
Contributor

To be able to fetch the videos direct URL, we need the variants field and a Variant model.

Right now, you can only get a twitter URL of the media, but not of the video resource as well. Crucial part to be able to play the video in your app.

More details on this link
https://developer.twitter.com/en/docs/twitter-api/data-dictionary/object-model/media

That page is not fully up to date tho.
I joined a Twitter Chirp slack where I asked about fetching video/gif URL and got info that this is now possible (on the link it still says "Note that video URLs are not currently available, only static images.") 馃槄

Tested this in a playground here:
playground

@daneden , I hope this makes sense 馃檶

@daneden
daneden merged commit 04866fa into daneden:main Aug 11, 2022
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.

2 participants