API wrapper for Podio written in Python
Project description
podio-python
podio-python is an API wrapper for Podio, written in Python.
This library uses Oauth2 for authentication.
Installing
pip install podio-python
Usage
# if you have an access token:
from podio.client import Client
client = Client(access_token=access_token)
# if you are using Oauth2 to get an access_token:
from podio.client import Client
client = Client(client_id=client_id, client_secret=client_secret, redirect_uri=redirect_uri)
To obtain and set an access token:
- Get authorization URL
url = client.authorization_url(state=None)
- Get access token using code
response = client.get_access_token(code)
- Set access token
client.set_token(access_token)
Check more information about Podio Oauth: https://developers.podio.com/authentication/server_side
Refresh token
If your access token expired you can use your refresh token to obtain a new one:
token = client.refresh_token(refresh_token)
# And then set your token again:
client.set_token(token["access_token"])
Get user status
user = client.get_user_status()
Organizations
List organizations
orgs = client.list_organizations()
List organization spaces
spaces = client.get_organization_spaces(org_id)
Get space
spaces = client.get_space(space_id)
List space members
members = client.get_space_members(space_id)
Applications
List applications
apps = client.list_applications()
Get application
app = client.get_application(app_id)
Get item
item = client.get_item(item_id)
Create item
body = {"fields": {"title": "Juan Assignment", "status": 1}}
item = client.create_item(app_id, body)
Get task
task = client.get_task(task_id)
Create task
body = {"text": "Text of the task", "description": "desc"}
task = client.create_task(body)
Get task labels
labels = client.get_task_labels()
Webhooks
List webhooks
hooks = client.list_webhooks(ref_type, ref_id)
Create webhook
hook = client.create_webhook(ref_type, ref_id, url, hook_type)
Validate hook verification
client.validate_hook_verification(webhook_id, code)
Delete webhook
client.delete_webhook(webhook_id)
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file podio_python-0.1.9.tar.gz.
File metadata
- Download URL: podio_python-0.1.9.tar.gz
- Upload date:
- Size: 3.7 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/4.0.2 CPython/3.10.6
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
2b2827f92ec603a9c7898d88bc86acca69e847001d4d9b8e8cb7b96c38efc4b5
|
|
| MD5 |
14b00502f3dff297b6aedf72f98df347
|
|
| BLAKE2b-256 |
2b5ef91c71f9a3f18857d9c39a90831fd7d5014aaf575a7593369b4732a0100e
|
File details
Details for the file podio_python-0.1.9-py3-none-any.whl.
File metadata
- Download URL: podio_python-0.1.9-py3-none-any.whl
- Upload date:
- Size: 4.5 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/4.0.2 CPython/3.10.6
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
45dc30aa16a85ffbac81508fe3a516b6b6d9b5ef1b7fdecee87f4b470782f4fc
|
|
| MD5 |
bf82ab272ea2a6ffe7ad60a6108590b2
|
|
| BLAKE2b-256 |
c22c01ad78d61353157a89c92c9c3765d1e1a1ddd06b6561eb3966c891187f1d
|