Reposted tracks by authenticated user (/me/activities)? - soundcloud

I created test account on SoundCloud and tried to use me/activities API for getting recent activities. Test account have exactly 30 activities (reposted playlists - 6; created playlists - 1; reposted tracks - 23). With limit=1 parameter I’m receiving exactly 23 activities, and 16 of them are empty like this:
{
"collection":[],
"next_href":"https://api.soundcloud.com/me/activities?cursor=9b768680-9ecc-11e3-805c-3a36c8290708\u0026limit=1”,
"future_href":"https://api.soundcloud.com/me/activities?limit=1\u0026uuid%5Bto%5D=6fdfc300-9fd6-11e3-80b5-0fd1bb49c7d8”
}
Other 7 containing info that contains reposts from users I follow, and created playlist.
So my question is, what I’m doing wrong? Is it supposed to happen? And, if so, is there any way to know all the activity?
I’m doing an iOS app, and it seems like native SoundCloud app doing that just fine. Is it using special API, that is’t available for public?
Thanks in advance.

Related

How to get live video id from YouTube channel

YouTube API eventType=live not working, does anyone have an idea why?
https://www.googleapis.com/youtube/v3/search?part=snippet&channelId=UCmyKnNRH0wH-r8I-ceP-dsg&eventType=live&type=video&key=
Without eventType was working fine (but not now):
https://www.youtube.com/embed/live_stream?channel=UCmyKnNRH0wH-r8I-ceP-dsg&autoplay=1
Looks like YouTube changed something in API, search.list really not returning live broadcast since end of last week.
If you have user's access token you can use https://www.googleapis.com/youtube/v3/liveBroadcasts?part=snippet&broadcastStatus=active&broadcastType=all
endpoint to retrieve if any broadcast is live.
If you do not have user's access token, you can try this answer
but i didn't check it if it is working
Anyway this question looks like to be a duplicate of this question
Right now the YouTube API is not working, specifically for retrieving live streams of a specific channelId. In other words if you are setting channelId in the API call, you will get 0 results.
If you're using an API key rather than OAuth (not sure if OAuth works) the only work around at the moment is to use the API to search for a specific title. Here is my query URL below.
https://www.googleapis.com/youtube/v3/search?part=id%2Csnippet&type=video&maxResults=20&order=date&q=My+Uniquely+Titled+Livestream&key=[apiKey]
The results returned by the API will be from all of YouTube. (Note: the rest is done serverside) Put the results into an array and discard any that don't match your channelId. Then check the titles in an array and only get the video ID of the one that matches your desired title. That is the basic logic and it is sort of a rigid work around that won't work for most. But at least it will get you what you need until Google fixes the API.

How to create a Facebook ad based on a post?

After many tries, I'm not getting how we can use the Facebook API to create a simple Ad based on a Post (and it's creative) like it is possible in the Business Manager.
For example, my last attempt failed due to a problem with Instagram:
Facebook API: Instagram Account Is Missing
If there is anybody that has been able to create a basic Ad (within a given or new AdSet) based on a Post, please help me. I've seen many questons like this (especially regarding the Instagram problem) and now I'd like to have a working solution.
What exact requests have to be done or isn't it possible at all?
THe Instagram placement is added by default in the targeting, so if you want to skip it you need to specify in the targeting field when creating the adSet in the publisher field:
{
"geo_locations":{"countries":["US"]},
publisher_platforms: ['facebook'],
facebook_positions: ['feed', 'right_hand_column'],
device_platforms: ['mobile', 'desktop']
}
If you want to publish on Instagram also you should also provide an instagram actor ID: The AdsCreative should contain an extra field named instagram_actor_id also remember to add Instagram in the related targeting:
{
"geo_locations":{"countries":["US"]},
publisher_platforms: ['facebook','instagram'],
facebook_positions: ['feed', 'right_hand_column'],
instagram_positions: ['stream', 'story'],
device_platforms: ['mobile', 'desktop']
}
Reference:
https://developers.facebook.com/docs/marketing-api/guides/instagramads
https://developers.facebook.com/docs/marketing-api/guides/instagramads/ads_management/
https://developers.facebook.com/docs/marketing-api/targeting-specs/#placement
Let me know if you need more info or an answer or your other question about Instragam

Is fb graph user search api not working anymore?

https://graph.facebook.com/search?q=sharma&fields=name&type=user&access_token=
I was this URL along with access token and it was giving me user name list that i was using in my project. Only names are my requirement but when today i started to use it i am not getting any data nor any error.
Its only returning this
{
"data": [
]
}
Recently a month ago it was working for me.
Can anyone tell me if they have the same issue or if something has changed?
Is there any other was of getting users name mainly first + last name from fb?
I have found answer of my question which is Fb is no more giving user results for graph search api.
https://developers.facebook.com/docs/graph-api/changelog/breaking-changes#search-4-4
Search API
You can no longer use the /search endpoint with the following object types:
event
group
page
user
I dont know whether its a permanent revoke or temporary but it has something to do with Cambridge analytica data leak issue
https://www.google.co.in/search?biw=1360&bih=662&tbm=nws&ei=-iTXWrrkCYrxvgTTy5GgCw&q=cambridge+analytica+data+leak&oq=cambridge+analytica+data+leak
I hope it will help others to find out why their API is not working anymore.

How I can Unlike Comments on the Rss Feed using Graph API.?

Hello Guys I am working on WPF app and I want to Unlike the Comments what I have been like so I am using like this.
Facebook.FacebookClient api = new FacebookClient(ExpandingNewsFeedList[0].AccessToken);
api.Delete(ID);
But it will give me error like this
.(OAuthException) (#100) Can only call this method on valid test users for your app.
so how I Can overcome this problem.?
Thank you.!!
To unlike, do an HTTP DELETE to the /objectid/likes.
Using C#, it's like this
facebookClient.Delete("/" + objectId + "/likes");
You can't delete content using an app except for some types of content which your App added (e.g. an app can delete its own posts)

Facebook old API Video upload

Our application uploads video to facebook (using the REST API video.upload method). Everything was working fine, but nearly 10 hours ago we started to receive the error "This method must run on api-video.facebook.com". We're already running it on api-video.facebook.com! The url is http://api-video.facebook.com/restserver.php?method=video.upload, it's hardcoded in the application, and never changed. What's happening? How can this be fixed?
Since Facebook doesn't seem to want to document this:
the call is to https://api-video.facebook.com/restserver.php
params:
access_token=...
method=video.upload
The rest of the params work as before.