I am trying to submit a tweet to the Twitter API (v1.1) that looks like this:
here is a tweet link http://mylinktext.com
Right now, if you submit a raw link, twitter automatically substitutes its t.co link wrapper. Can I use my own? I don't care if Twitter wraps my shortener too (two layers of redirection).
EDIT: Can I submit a URL entity via post to the Twitter API?
Links posted to and from Twitter will come out as http://t.co/ regardless.
Read this for some more clarification:
FAQs about Twitter's Link Service (http://t.co)
Because of the reasons listed above, Twitter will shorten URLs you
post on Twitter.com. You cannot opt out of link shortening.
Related
I'm trying to fetch a tweet's video url using API V2.
Using API V1.1 I can use
https://api.twitter.com/1.1/statuses/show.json?id=<ID>&include_entities=true
and get the direct mp4 urls in the response at
extended_entities.media[0].video_info.variants
But using API V2 I can't seem to find any ways to get those, I was only able to get the video thumbnail but not the actual video.
I've tried it with both the lookup and the recent search endpoints but couldn't find a way to do that.
In lookup docs twitter says:
This endpoint was recently graduated from Twitter Developer Labs, and is the replacement of v1.1 statuses/show, v1.1 statuses/lookup, and Labs Tweet lookup. If you are currently using any of these endpoints, you can use our migration materials to start working with this new endpoint.
but that doesn't seem to be the case, is that feature not included ? Also if there is any other way to be able to embed a twitter video in a web page (without the tweet text) that'd be helpful.
The videos are not currently available in the Twitter API v2 at this time. This is a known request.
For those who still looking for an answer, you can do it on the V2 by adding the following parameters :
expansions=attachments.media_keys
media.fields=variants
Your final link should give https://api.twitter.com/2/users/{{uid}}/tweets?expansions=attachments.media_keys&media.fields=variants
Source : https://developer.twitter.com/en/docs/twitter-api/data-dictionary/object-model/media
Progress on twitter-api-v2 media handling, Maybe this will allow the video URLs too in the response.
https://twittercommunity.com/t/v1-1-media-endpoints-available-for-essential-access-in-the-twitter-api-v2/171664
I want to request pins without login to Pinterest by providing a set of tags. Is this possible? I searched through current Pinterest API and couldn't find anything like some search method. I know that I can get a google custom search engine and fetch photos from pinterest.com source from google but wanted to do it natively.
Any help appreciated!
Hi, I want to get the user list in one Twitter post as picture shown. but I didn't find the API which I can get this kind of data on Twitter. Is there anyone know how can I get this data. Thanks
The official API does not include that functionality.
You will find that there are lots of actions which are available on the official website & apps which are not allowed in the API.
Sorry.
In facebook, we can specify a web page url and add comments to it, or fetch comments for it, with the Graph API.
Later we can fetch the comments for the page, using a sample code, and display them on my page, as a widget, using a javascript code.
Similarly, is it possible to setup comments for a web page virtually using google plus, and display them with a code, using the API ? I came across google plus client library for php, but not sure about how to achieve what i wanted, with it.
Currently there is no public write API for Google+ or a way to bi-directionally integrate Google+ comments with an outside web page.
You can incorporate comments from a Google+ post onto your static page. Here are a couple of resources that can illustrate how:
The full documentation for the Google+ read API is at https://developers.google.com/+/api/ and there are libraries for PHP and JavaScript at https://developers.google.com/+/downloads/
http://little418.com/2011/12/google-comments-on-your-static-html-blog.html contains some examples about how to echo comments from a Google+ post.
Any one have idea about how to post on our Google+ Stream using Google+ API? I need to post on the stream.
There is still no "public" officially supported way to post on a Google+ stream using an API. (You can post using the +1 or Share buttons, and some people have used unofficial APIs or leveraged the SMS posting methods, but this isn't what you're looking for.)
For details on what you can currently do with the limited API you can look at https://developers.google.com/+/api/
Here is an unofficial Google+ API written in js. https://github.com/mohamedmansour/google-plus-extension-jsapi