carto-auth
Python library to authenticate with CARTO.
Install
pip install carto-auth
To install the CARTO DW extension:
pip install carto-auth[carto-dw]
Installing from source
git clone https://github.com/cartodb/carto-auth
cd carto-auth
pip install .
Usage
from carto_auth import CartoAuth
# Authentication
carto_auth = CartoAuth.from_oauth()
# carto_auth = CartoAuth.from_m2m("./carto_credentials.json")
# Get api base url
api_base_url = carto_auth.get_api_base_url()
# Get access token
access_token = carto_auth.get_access_token()
# CARTO Data Warehouse
carto_dw_project, carto_dw_token = carto_auth.get_carto_dw_credentials()
carto_dw_client = carto_auth.get_carto_dw_client()
For more information, check the examples section.
Development
Make commands:
- init: create the environment and install dependencies
- lint: run linter (black + flake8)
- test: run tests (pytest)
- docs: build the documentation
- publish-pypi: publish package in pypi.org
- publish-test-pypi: publish package in test.pypi.org
- clean: remove the environment
Check the development documentation section.
Contributors
Metadata
Release files for carto-auth 0.2.0
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | Provenance | Actions |
|---|---|---|---|---|
| carto-auth-0.2.0.tar.gz | 8.6 kB | Without provenance | Details for carto-auth-0.2.0.tar.gz |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Actions Reset |
|---|---|---|---|---|
| carto_auth-0.2.0-py3-none-any.whl | Python 3 | none | any | Details for carto_auth-0.2.0-py3-none-any.whl |
Total release size: 18.6 kB
Release files / carto-auth-0.2.0.tar.gz
| Download URL | carto-auth-0.2.0.tar.gz |
|---|---|
| Size | 8.6 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
982d293d723e92dc334734a7be43a113dd7c8ce8c5d97b49d86c2ad81d1c63a5
|
|
BLAKE2b-256 checksum How to use checksums |
065b4570c1fa7bbe63d06465fe16ed97beadf20ba95bf9f00acf6fa6462b7fca
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/4.0.0 CPython/3.8.10
|
Release files / carto_auth-0.2.0-py3-none-any.whl
| Download URL | carto_auth-0.2.0-py3-none-any.whl |
|---|---|
| Size | 10.0 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
bcd2012b7daf90c028127f931005e779b9461a3637a2824673dd5f0a2b1485e6
|
|
BLAKE2b-256 checksum How to use checksums |
dcb2e81f8e1f8e6e925669354d3fab90a87a210bd601d0498b7aa03ecac71f0b
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/4.0.0 CPython/3.8.10
|
Security for carto-auth 0.2.0
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
No provenance found
None of the files in this release were uploaded with provenance metadata.
A note on package security
PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.
To learn more about protecting yourself from malicious actors, visit our package security documentation.