I'd like to get the impressionBasedCpm from the Api Explorer ( and later from my app).
I can log in with an youtube partner account and toggle the oauth switch. I set all scopes to checked.
Then I try to enter
ids: contentOwner==NAME_OF_CONTENT_OWNER (not the id, retrieved from the content API, https://developers.google.com/youtube/partner/docs/v1/contentOwners/list#try-it)
metrics: impressionBasedCpm
start-date: '2015-05-01'
end-date: '2015-06-01'
The output still tells me:
You do not have permission to execute this method.
Can someone help me?
My guess is that when I authorize the application I seam to still login as a channel, so the query as a content owner is not allowed. I picked the main one with the email address. But when I'm on youtube I can switch to a specific Content-Manager Channel/Account.
Even when I try to just get the 'likes' for the contentOwner it doesn't work. If I try to get the likes based on the channel_id it works. But I like to get reports for a youtube partner that uses youtube's cms.
cheers
This query won't work because it does not follow the semantics of the API. You need to provide the ID of the contentOwner in order to get a 200 OK response. Name of Content Owner cannot be unique and hence would lead to erroneous results.
Related
When querying the Graph with the PHP library for a given drive I receive 400 Unable to retrieve user's mysite URL or 429 Too many requests.
When I call for example https://graph.microsoft.com/v1.0/users/b0633c25-2655-4dfe-a2b2-078e4310deba/drive with the PHP library it gives this weird result. When I query the same url in the Graph Explorer. It works like a charm.
I've set up the permissions as described in the docs and have the E3 Developers subscription that is still valid.
What am I missing?
The error message is misleading and does not mention billing as it should.
Check your Billing > Your Products (subscription) in your Microsoft 365 Admin and then try again.
The best way to test is:
https://developer.microsoft.com/en-us/graph/graph-explorer
The current error seems like user does not have ODFB(OneDrive For Business) site created, you can check if the user have create OneDrive site(the OneDrive site will be created while the user first time to use it).
To debug that issue for now, try to use Graph Explorer https://developer.microsoft.com/en-us/graph/graph-explorer# and login with your user account.
If you can access /me then try accessing /me/drive/root and you will get details about ODFB Doc Lib for current user if it exist.
we can get results with the following link for login-in user
https://graph.microsoft.com/v1.0/me/drive/root/children
Reference for you: https://github.com/microsoftgraph/microsoft-graph-docs/issues/1354
Am trying to figure out the API. Were in the web interface can, as an administrator, find the "content owner id" of my managed accounts?
All I see is this:
"To retrieve a content owner report, call the API's reports.query method and set the ids parameter value in the API request to contentOwner==OWNER_NAME, where OWNER_NAME specifies the content owner's ID. Ask your partner manager if you are unsure of the value."
Surely I don't have to call Google to get this value?
If you want to know the content owner id of only one account, you can check the URI.
There are various ways to retrieve the id from the URI:
Log in on https://studio.youtube.com/ and switch the account to the
one you're trying to get the id of (on the top right click on the
account logo, then on "Switch account"). When you've switched to the
new account, the content owner id should be in the URL in the part
that follows https://studio.youtube.com/owner/.
Go to https://www.youtube.com/analytics and switch to the desired
account. The content owner id is what follows
https://www.youtube.com/analytics?o= and before &ar.
The second option should also work for other sections in the Youtube
creator studio.
If you want to retrieve a list of all content owner IDs linked to your admin account, it's much easier to do it via the API. If you don't want to write a script for that, you can just use the Google API explorer (on the right) here: https://developers.google.com/youtube/partner/docs/v1/contentOwners/list
Just set fetchMine to true and sign in to your account. The output below should give you a list of the content owner names, IDs and other info.
To retrieve the content owner IDs via the API, samples can also be found here:
https://developers.google.com/youtube/partner/code_samples/
(check the docs "Retrieve a content owner's managed channels (channels.list)" in your language).
You may refer with this SO answer on how to get the content owner id.
Assuming you have an OAuth 2 token with access to the https://www.googleapis.com/auth/youtubepartner scope, you can make an API call to youtubePartner.contentOwners.list(fetchMine=true) to get back a list of YouTube content owners associated with the current OAuth 2 token. (There will normally only be one item returned.) You can then get the content owner id value from the id property of each item in the items list that's returned. This is the value that you can use when making content owner YouTube Analytics API reports, or using the onBehalfOfContentOwner delegation parameter in the YouTube Data API v3.
You need to query youtubePartner.contentOwners.list(fetchMine=true) to obtain the content owner info. Also make sure that you have this API available in your console or ask your partner manager if you are eligible for this API.
I am using instagram to recieve the list of people i follow and although api returns the status code 200 I recieve absolutely no data.I tried using postman client instead of my code and even from there no data is being returned I am hitting the following service.
https://api.instagram.com/v1/users/self/follows?access_token=token
one thing to be noted is my application is in sandbox mode and this same access token is working and fetching other information about the user including media shared by the user and its basic information etc and user follows and is followed by several users.
Please suggest the solution thanks in advance.
I may have answer to this question since I was facing the same issue on my WinRT project yesterday.
You may need the relationship scope instead of 'follower_list' scope.
I am assuming that you have provided the scope as 'follower_list' in the authorization URL and logged in as yourself or through your own Instagram account(the same account with which you have created your Instagram app). And now if you are hitting the above service it will return nothing in data since you are requesting if the user is following you or not(so obviously you are not following yourself)!! So if you try logging in with someone else's Instagram account and hit the above service with follower_list scope it will return your Instagram account in data if the logged in person is following you.
EDIT
The above service will return all the users that are following you AND present in your sandbox users list. (Or at least that is my conclusion on this)
For further clarification try https://apigee.com/console/instagram for hitting this service there they are using the relationship scope.
I am trying to get all the playlist feed URLs from the YouTube channel in my iOS application.
Below is the URL to get the XML data consists of the required contents.
https://gdata.youtube.com/feeds/api/users/thenewboston/playlists?v=2
This is working fine, which results in the response of an XML with data.
But when I change this to my username nothing is retrieved. I have couple of playlists in my channel.
My Attempts:
Attempt 1:
I have googled and cross checked my channel's privacy settings which is Public in default.
Am I making any wrong? Please let me know your comments.
Attempt 2:
When I try like this in browser, http://www.youtube.com/user/myusername
getting "This channel is not available at the moment. Please try again later.".
The same url is working fine for thenewboston.
Try this
https://gdata.youtube.com/feeds/api/videos?v=2&author=USER_NAME&orderby=published
This will fetch all the user videos.
I have found the solution:
Below is the format that I have tried.
https://gdata.youtube.com/feeds/api/users/userId/playlists?v=2
But it seems there is some change in the API.
To request a feed of another user's playlists, send a GET request to the following URL. This request does not require authentication.In the URL above, you should replace the text userId with the user's YouTube user ID. For backward compatibility purposes, the API also supports having the user's YouTube username specified instead.
To find the userId in YouTube : (Follow the steps below)
Click the arrow on top right after login to your YouTube account.
Select YouTube settings.
Select the link Advanced and find the YouTube User Id there.
Reference : YouTube API v.2.0
I'm using eventbrite.com, and I'm trying use the rest API to get all the previous events for my user (organizer in eventbrite). I am expecting to get events that have occurred in the past.
I'm using the following url:
https://www.eventbrite.com/xml/event_search?organizer={MyOrganizerName}&app_key={MyAppKey}&date=past
However, I get nothing returned. ever. I am sure that have some events that happened in the past.
I am successfully getting events in the future. so there's nothing wrong with my client\app key\spelling\whatever.
With the newer Eventbrite APIv3 the endpoint changed to /users/me/owned_events The API comes with an API Explorer, which lets you see detailed debugging information for any endpoint just by going to it in a web browser.
Paste this url with your token id into your browser to get all past events:
https://www.eventbriteapi.com/v3/users/me/owned_events/?token=YOURTOKENID
The result is a paginated response of all the events your user account is organizing.
The event_search method is meant to return publicly available information about upcoming events only.
Try user_list_events instead:
https://www.eventbrite.com/xml/user_list_events?app_key={YOUR_APP_KEY}&user_key={YOUR_USER_KEY}&event_statuses=ended
You also have the option of creating an Organizer Profile Page, allowing you to group similar events together. The organizer_list_events API call may be useful for folks who are using that feature.