YouTube API: How can I get the date/time in which a user marked video as favorite? - api

I'm accessing the feed of a user's favorite videos through the YouTube API. How can I get the date/time in which he marked each video as favorite?
Update:
Someone pointed out that the YouTube API documentation says that the "Published" date on a user's favorite feed will have the time in which the user marked the video as favorite. But that seems to be false.
For example, check out this video entry:
http://gdata.youtube.com/feeds/api/videos/g2981r_MtHQ
It has a "published" date of 2008-03-19T21:09:09.000Z.
Now let's see the same video in the favorite feed of some user:
http://gdata.youtube.com/feeds/api/users/KeepWatchingTheSkies/favorites
It has a "published" date of 2008-03-19T21:09:09.000Z. Identical.
Here is a different way to get the favorites feed:
http://gdata.youtube.com/feeds/base/users/KeepWatchingTheSkies/favorites
And still we have a "published" date of 2008-03-19T21:09:09.000Z.
Assuming the user was not quick enough to favorite the video on the same millisecond it was published, what's written in the YouTube documentation is probably wrong, and this is not the time in which the user marked the video as favorite.
So my question is: How can I get the time at which a user marked a video as favorite?

I figured it out: The URLs must specify ?v=2 so version 2 of the API will be used.
Here's the fixed URL:
http://gdata.youtube.com/feeds/api/users/KeepWatchingTheSkies/favorites?v=2
Now it shows a correct "published" time of 2010-09-03T08:59:53.000Z.

It's easy.
The <published> tag in a favorite
videos feed entry identifies the time
that the video was marked as a
favorite and not the time that the
video was published.
from http://code.google.com/apis/youtube/2.0/developers_guide_protocol.html#Favorite_Videos

Related

Server query to YouTube API “is there any YouTube video containing this specific word?” - if so, what is the link, upload date etc

Do you think we could use the YouTube Data API to get to know which products have any YouTube review/video. Then paired with our system via, for instance, Video Name?
Your question isn't very clear. However, you want to try this.
https://developers.google.com/youtube/v3/docs/search/list#try-it
You can set type to snippet and q to the words you want to search for.

Soundcloud API: Find track like date via API

I've tried searching through Stack overflow as well as the soundcloud API reference but couldn't find any answer. I'm trying to retrieve the date a user liked a song on Soundcloud. I tried two parts of the API:
- /users/{id}/favorites: This will return all tracks liked by the user, but no date when it was liked.
- /me/activities: This returns track reposts, comments and seemingly tracks that show up on the stream. Sadly there doesn't seem to be a type track-like, but maybe I'm doing something wrong here or need to pass additional parameters.
I'm having the user log into Soundcloud before utilizing the API.
Any chance someone knows if retrieving the track like date via the API is possible?
Thanks!
With the public API available right now, this is not possible.
You have to build it on your own and track the changes in a different, your own database.
Example call from the website when you lookup your likes, i dont know what you will see with a pro account:
https://api-v2.soundcloud.com/users/soundcloud:users:1672444/stats/timeseries/likes?from=1442016000000&to=1442534400000&resolution=day&tracks=soundcloud%3Atracks%3A30984358&client_id=02gUJC0hH2ct1EGOcYXQIzRFU91c72Ea&app_version=39e9f65
Response:
[{"user_urn":"soundcloud:users:1672444","timeseries":[{"time":1442016000000,"count":1},{"time":1442534400000,"count":1}]},{"user_urn":"soundcloud:users:1672444","track_urn":"soundcloud:tracks:30984358","timeseries":[{"time":1442016000000,"count":1},{"time":1442534400000,"count":1}]}]
Here is and older, related answer about playback stats:
How to fetch playback statistics

Apple Music URL Scheme

I need to know the URL Scheme of Apple Music to open a specific song. Up to now I was using the link like this:
https://itunes.apple.com/us/album/monsieur-cousteau/id496076893?i=496076903&uo=4
That link, was working perfectly in iTunes Store, but now is not working any more. That's because the link is opened by Apple Music, and it seems to work because it opens the album, but not the specific song.
The structure of the links has changed there is now a flag in there for the open method:
iTunes:
https://geo.itunes.apple.com/au/album/monsieur-cousteau/id496076893?i=496076903&app=itunes
Apple music:
https://geo.itunes.apple.com/au/album/monsieur-cousteau/id496076893?i=496076903&mt=1&app=music
Note the app= at the end
There is a link generator here: https://tools.applemediaservices.com/ but I would imaging that you are generating these from your own log of apple ID's yes?
Also you will need to change the store, I am /au/ because I am in australia, these links don't always automatically forward the user and can give "Not available on your store" errors.
To get to a specific track you use this:
https://itunes.apple.com/au/album/monsieur-cousteau/id496076893?i=496076903&app=itunes&ign-mpt=uo%3D4#
Note the change in uo part, I am not sure how this particular part is generated as I got out of the industry a year ago but there is more information here: https://www.apple.com/itunes/affiliates/resources/documentation/tools_en.html unfortunately being I no longer work in the industry I am not classed as an affiliate any more.

instagram api search hashtags isn't reliable - so can I do this?

I'm looking to somehow tell users to upload a picture and do something, either tag or # our company so we are notified in real time, i just need to fetch the url of the photo that was uploaded and tagged or # or ANYTHING.
the hashtag search doesn't seem to work correctly, i've tried multiple hashtags and they wont retrieve them in any type of real time or at all.
the real-time subscription only notifies me that there is a new photo tagged that i subscribed to, so i have api search for a list of new media with that tag, which goes back to point 1, its not accurate or reliable.
so do i have any options at all on instagram?
If not do I have any options on facebook? any real time keyword search to grab the url of the photo they uploaded with a unique tag.
Check out https://github.com/chapmanu/hummingbird, it might be what you're looking for.
My experience with the Instagram Real-Time API is, that it is rather reliable.
When you get a real-time ping and then call the endpoint for your hashtag, the results are ordered newest first.
You can then paginate until you hit the last known result.
Maybe this tutorial helps: http://www.mtrinitaria.com/mykhel/tutorial-instagram-real-time-photo-update-api-with-php/

How to retrieve recents video's comments for a Dailymotion account

I am asking me if it's possible to retrieve recents video's comments for a given Dailymotion account.
For example, i want to get all recents video's comments for a given account every 2 minuts.
I have found severals Dailymotion API but don't found thet way to to that.
I tknow it's possible to read the list of a video‘s comments by issuing an HTTP GET to /video/{VIDEO_ID}/comments but do you know if it's possible to reteive all new comments for account's videos?
Thanks!
https://api.dailymotion.com/video/videoID/comments
will give you
{"page":1,"limit":10,"explicit":false,"has_more":false,"list":[{"id":"id","message":"wel done","owner":"id"},{"id":"id","message":"congrats","owner":"id"}]}
So, list has comments of video.Here there are 2 comments.