Python REST API Example
-
Hello,
Similar to this user’s request, I was hoping to find an example of your plugin using Python so a user can authenticate my software on their computer (unless there’s a safer way to do this). I’m not sure which address to get or how to find if a license is valid. I looked for docs here and here, but didn’t see any. I am using Python’s Requests library.import requests def main(): r = requests.get('https://api.github.com/user', auth=('username', 'password')) print r.status_code print r.headers['content-type'] print r.encoding print r.text print r.json() if __name__=='__main__': main()
Thank you!
Viewing 12 replies - 1 through 12 (of 12 total)
Viewing 12 replies - 1 through 12 (of 12 total)
- The topic ‘Python REST API Example’ is closed to new replies.