I am attempting to work with Google Checkout on Google App Engine. Currently, I am writing everything in Python and have the checkout process working. I am having some difficulty getting the notifications of processed orders functioning. I've been searching for Python examples, but thus far have been unsuccessful. Programming directly off of the documentation provided by Google, I have not been able to get my notifications working either. Would anyone happen to have a framework/demo Google Checkout Notification example in Python?
The chippyshop source has a nice example of a python Google Checkout implementation that should get you moving in the right direction.
UPDATE: I actually ended up needing to do this myself so I extended the example linked above and turned it into a reusable RequestHandler for use on GAE.
You can find the source and examples on github which should serve as a good starting point for any others following this path.
Related
I'm building a kivy app and almost got firebase cloud messaging working using the pyfcm
package from pypi.
What i'm stuck on is how to get the "registration token" that the firebase SDK creates on app install so that i have a registration token to send push notifications to.
There seems to be lots of info scattered around the net in regards to doing it using some other language other than "python", but python is all i know so i'm trying to work it out for that language.Any one have tips on how i go about that please ?
I can't find a python package that has the FirebaseMessaging.getToken() in it which is what the firebase documentation keeps referring to, so i'm lost and my brain is going mushy now due to researching this for hours and hours so far :)
any help appreciated
To answer my own question.
For those wondering the same question as i had. I came across this package https://github.com/Fox520/pushyy
In that package the guy has incorporated the ability to get the device token and also update the token when it changes. It takes a little manipulating to get the package to work properly with the latest gradle version but it is do able.
There doesnt seem to be a direct "python" method as such to get the token so using this package makes use of the required java and python code to achieve the task. Using this and using pyfcm from pypi to send messages, i'm now able to send firebase push notifications from my kivy app :)
I'm not a newbie when it comes to python (nor a professional), but this is the first time I'm trying something like this.
I would like to upload files to OneDrive using an python script. Sounds simple right? Well apparently it's more then I can handle.
From what I've seen so far the onedrive-sdk-python I was using apparently doesn't work anymore (source: https://github.com/OneDrive/onedrive-sdk-python/issues/119) because it's being decommissioned.
The new SDK to use is the one for Microsoft Graph I guess? But the github (https://github.com/MicrosoftArchive/msgraph-sdk-python) doesn't really mention how to set up the new Oauth2 authentication, get a token and use the client in python. The links mentioned in the authentication section don't work for me, I get error messages like: "AADSTS900144: The request body must contain the following parameter: 'client_id'."
I looked on stackoverflow for similar questions but most of them are about the old onedrive-sdk and the most recent one I could find was almost 3 months old. The response there was that it was still under development.
I guess the problems I've been having are all related to the Microsoft Graph still being in development, but I was wondering if someone managed to get it to work and if they could point me in the right direction to get the authentication setup and getting me started on uploading files to OneDrive.
Some details in case it matters:
Rasbian 9 Stretch
Python 2.7.13 & Python 3.5.3 (tried both)
OneDrive business account
Many thanks to anyone who can point me in the right direction :)
I'm afraid the SDK you're using is no longer being actively maintained. From the ReadMe:
This library is no longer actively supported. To integrate Microsoft Graph into your Python solution, we recommend using REST and taking a look at our new Python samples and documentation.
To answer your question on tokens, these are not technically issued by Microsoft Graph. They're issued by Azure Active Directory (or Outlook.com for personal accounts). You obtain a token using OAuth 2.0.
You are, however, on the right track. Before you can do anything with Microsoft Graph, you're going to need to obtain an OAuth token. The good news here is there's a sample Python project that walks you through how this process works: Python authentication samples for Microsoft Graph.
I am trying to create a script that get the data from a google keep list I was thinking Google Takeout might do part of what I want but I cannot find a API to automate the downloads. Does anyone know a way to grab this data via script (python/bash) so that I can easily extract what I need?
I am not sure if it is allowed or not, but you could login via a BeautifulSoup session and navigate to the site you wish to parse.
I've written a quite similar script for Python, you can find it at github, i thinkt it's pretty self-explanatory but if you should require any more help feel free to ask.
You could use selenium library for that.
Used the framework to scrape the keep.google.com webpage for all the notes and export them to a csv file
This Might be helpful, i made the script to backup my notes to my computer
https://github.com/darshkpatel/GoogleKeep_Backup
There is no API for Google Keep at this time. I don't think your going to be able automate Google Takeout either the best you will be able to do would be run it manually then create your own application to import it were ever it is you want to import it to.
Here is an automated solution for this question: a link!
Or just execute these commands in the terminal:
git clone https://github.com/Dmitry9/exportKeep.git;
cd exportKeep;
npm install;
npm run scrape;
After all dependencies installed (could take a minute or so) chrome instance will navigate to the sign-in page. After posting credentials it will scroll to the bottom of the window to force the browser to load all of the notes inside DOM. Inspecting the output of the terminal you will find a path to the saved JSON file.
In the meanwhile there is an API, see here: https://developers.google.com/keep/api/reference/rest
Also, there is a python library that implements this API (I'm not the author of the library): https://github.com/kiwiz/gkeepapi
I've got a python script that I want to build a locally-hosted web gui app for, so I can use the modern styling and tools available to web apps.
The scripts I'm running take a while to process, and I want to update the web app with visual updates, or at least something akin to what the console sees when using print() in python.
My initial hosting efforts have been based on this tutorial, and I tried out the methods in this answer to try and get data to update in a streamed fashion, but the pages only showed once the entire script was finished.
I'm wondering whether web.py could help me?
Any guidance, or even the right terms to google would be appreciated. Thanks.
--
Update: I've been reading up on node.js (something I've failed to do for years..) and, please correct me if I'm wrong, but it seems like it could be the answer. I'm even considering re-writing my original functions into node.js given the existence of this serial comms library
I created a simple web app using django and was wondering if there is any python library out there that could help me integrate my app with facebook.
Thanks!
A simple search for "facebook" on PyPI
http://pypi.python.org/pypi?%3Aaction=search&term=facebook&submit=search
gives two django related modules with the first two hits.
http://pypi.python.org/pypi/django-facebook/2.0.16
http://pypi.python.org/pypi/django-la-facebook/0.1.0
Apart from that there is always the official Facebook SDK (on PyPI) that you will find on Github (also carrying several forks of the SDK):
google "facebook sdk python"
Please some more research next time....