Yammer Export Data - yammer

I am hoping you can help me with a problem regarding Yammer Export Data.
I have followed the steps in https://developer.yammer.com/docs/oauth-2. received a token code and copied the example
https://www.yammer.com/api/v1/export?since=2012-02-09T00:00:00+00:00&access_token=WOI87382HDL replacing the access_token with my token. But I get the error "This sight can't be reached". I know I am doing something stupid but don't know what. Any help would be much appreciated.
Cheers
Paul

https://www.yammer.com/api/v1/export?since=2016-04-09T00:00:00&model=Message&include=csv with a bearer token for a verified admin works for me. Note that I only added the params of &model=Message&include=csv to ensure I didn't grab all the files in my network which could take awhile depending on the size of your data.
Is the user you are using a verified admin of the network?

Related

python google-api quickstart examples are poorly documented

They say its a quickstart but idk lol
Any way I have attempted to connect to the google api with Ruby for an entire week and eventually said I am going to see if its easier with python, turns out it is not.
I have added my redirect URI in the Oauth Credential. I have tried using a web applications type, a desktop app, and a tv or limited input device.
All of them return errors.
Error 400: redirect uri mismatch
Error 400: Invalid Request
Couldnt Log you in, The browser you are using doesnt support javascript, please try signing in in a browser with javascript enabled.
It keeps trying to use a localhost uri even when its set to my authorized one in the json credentials....
Is there anyone who can help me just get a basic example connection to the API working I am starting to lose hope that it is even realistic to try and build on an API as chaotic as this has been in my research so far. Everywhere you go you see devs wasting 5 days on something that should take an hour.
Edits BELOW !!!!
This has been so confusing I had to just go to trying to make a basic api call and eliminate all of the chaos brought in by these deprecated dependencies.
I have moved to just trying to get data back using post man and this tutorial >> https://medium.com/kinandcartacreated/google-authentication-with-postman-12943b63e76a
I have successfully been able to generate an Auth token using ONLY an OAuth2.0 Credential that is of TYPE 'Web Application'
However when trying to hit this endpoint....
GET https://admin.googleapis.com/admin/directory/v1/customer/MY-CUSTOMER-ID/devices/mobile?projection=FULL
I get the following error...
I know that in the end I will need to have a service account for this application configured properly, however given the wild goose chase that this has been I have been putting it off to keep the experiment controlled.
I will be working hard on trying to demystify this service account authorization for the next 4 hours atleast...
I had some difficulty getting the "quickstart" going as well.
There are a few things that should be taken into account that, in fact, aren't clearly documented.
After setting up the credentials in the respective page in Google Console as indicated in the documentation, you should download the json file and save it to the same directory as the script.
Take note that the quickstart has its own local server that it starts up when you run it. You can set the port in this line in the script. For example:
creds = flow.run_local_server(port=3000)
Then when you configure your credentials in the project, you would set the redirect URI to http://localhost:3000/
It does require some patience, because as noted, it does sometimes take several hours until the credentials settings in the Console take effect!
https://developers.google.com/sheets/api/quickstart/python
Same as CptCook, in my case the port defined in the quickstart is set to '0', which causes the redirect_uri error.
Removing and using the default resolved the issue.

Is it possible to access Google Drive folders just by API key

Trying to get my head around the Google Drive API and being stuck on if I can get folders just via API key bypassing the OAuth2 authorization.
Particularly referring to this thread , which states it is simply possible by doing:
https://www.googleapis.com/drive/v2/files?q='FOLDERID'+in+parents&key=APIKEY
I'm getting an authorisation issue although the API key is correct. Also I find the ' ' really weird so I tried without and it gives me a 404. Any help is much appreciated.
For whomever it may be helpful but the issue is solved by URL encoding the ':
https://www.googleapis.com/drive/v2/files?q=%27FOLDER_ID%27+in+parents&key=KEY_ID
and it works just fine.

Getting error from Parse while debugging Google login

So I'm trying to integrate Google login with Parse using the "Bring your own login" system. I was able to get the basic authorization functionality to work using the code snippets at https://groups.google.com/forum/#!topic/parse-developers/UUvTreGYOrI.
Now, to do some testing, I went ahead and manually deleted the user object via the Parse dashboard. However, I am now getting the following error when trying to access go through the signup workflow:
com.parse.ParseRequest$ParseRequestException: {"code":101,"message":"object not found for get"}
I tried clearing the cache and uninstalling the app, but the issue persists. Can anyone help me how to get around this and start the registration process afresh?
On a more fundamental note, this is my first time implementing code OAuth, logins, and ACLs. As such, any resource/tutorial that can give me code examples of this integration with Parse on both the CloudCode and the client (app) side would be highly appreciated (I believe the current official Parse tutorial uses Git and only has samples of the server side CloudCode).
Nevermind - I figured it out.
I had to delete the entry in the TokenStorage class on the Parse dashboard. I guess that's storing the token that links the login with the User object.
Anyway - I'm keeping this open to see if someone can point me to a good sample code for this workflow.

Connecting Oracle Fusion Application with DocuSign API

I am looking for some help setting up a connection between Oracle Fusion and DocuSign API. We want to use DocuSign to electronically sign procurement contracts we have in Oracle Fusion Procurement application and to set this up you need to provide the following details onto a form in Oracle Fusion:
Username
Password
Account ID
EndPoint URL
Once this is entered, you can click 'Validate' and the form will validate the connection for you.
I got most of this information from the API section of my demo account so have been able to provide everything except the EndPoint URL. To fibnd this out, I used the API explorer tool http://iodocs.docusign.com/, entered my account details at the top of the form and ran the GET v2/login_information REST message. The response I retrieved contained a 'baseURL' which I assumed was the same as the EndPoint URL and input this into the Oracle Fusion form, hit validate but unfortunately I was still unable to validate the connection.
I spoke with Oracle support and they advised that from their side they simply need the information in the form to validate the connection (assuming that information is correct and a DocuSign account exists) there doesn't appear to be anything else required to make a connection. So I can only assume that something isn't configured correctly within my DocuSign demo account and need some advice on how to check this. If anyone has had to do this in the past and came up against the same issue I'd love to know how you managed to get it working.
Any help and suggestions would be greatly appreciated :-)
Thanks,
Jamie
Based on that information, my guess is that the "EndPoint URL" would actually be something like https://demo.docusign.net. The application can then append whatever it needs after that. You could also try these:
demo.docusign.net
https://demo.docusign.net/restapi/v2
https://demo.docusign.net/API/3.0/api.asmx
https://demo.docusign.net/API/3.0/dsapi.asmx
(Note: The last two are for the SOAP API.)

How to keep user authenticated long term using google api client library

Background
I'm working on an app that will run on a device which does not contain a browser, but I want to get the users google tasks through the google api.
Because of the lack of browser, they can't authenticate on the device, so I have it set up in such a way that they visit a website and authenticate there, then the device makes http requests to the website to get the data it needs.
Problem
Once I got everything working this system works out OK, the problem is it only works for a day or so before the user has to visit the website again to refresh their access token.
It would be great if the user could be authenticated for very long periods of time, or even forever (not sure if that's possible or secure). Can I get some suggestions on what people think is the best way to accomplish this kind of long term athentication?
Refresh tokens?
I've heard there is a way to store the user's refresh token in a database and somehow use that to refresh their access token. If this sounds like a good way, can anyone point me in the direction of an example to get this to work?
I've been using the google api client library for ruby
Thanks a lot!
You're on the right track with the refresh tokens. I can't help too much with the Ruby API, and honestly I just did this calling the REST api directly, but this doc should help you understand the actual calls you need to make.
https://developers.google.com/accounts/docs/OAuth2WebServer#offline
Note that for a lot of their examples you need to remove the newlines for them to work.
Basically like you said, you need to send the user to https://accounts.google.com/o/oauth2/auth with the access-type=offline parameter for them to give consent. This comes back with an authorization code, which you send to /o/oauth2/token. This comes back with an access token and a refresh token. You can use the access token immediately, and you store the refresh token, which never expires. When the access token expires you send the refresh token to /o/oauth2/token (note that the grant_type changes to refresh_token) to get a new access token.

Resources