Interact with Procore through Python for data connection applications
Project description
ProPyCore
A Python-based connection with Procore that doesn't require a user authentication
This package accesses Procore's API through the Client Credentials OAuth 2.0 grant type which is meant for Data Connection Applications i.e. "userless access".
Installation
You can install this package with:
pip install ProPyCore
Examples
To get started, you need to create an instance of a Procore
object from propycore.procore
. To do so, you will need to access information from your Procore Data Connection App:
- Client ID: Accessible from your app at Procore Developers - will vary between sandbox and production modes
- Client Secret: Accessible from your app at Procore Developers - will vary between sandbox and production modes
- Redirect URI: For data connection apps, this value will be "urn:ietf:wg:oauth:2.0:oob"
- OAuth URL: Will be "https://sandbox.procore.com" for sandbox environments or "https://app.procore.com" for production
- Base URL: Will be "https://sandbox.procore.com" for sandbox environments or "https://app.procore.com" for production
Once you have these values, you will use them as parameters in the Procore
object:
connection = Procore(
client_id=os.getenv("CLIENT_ID"),
client_secret=os.getenv("CLIENT_SECRET"),
redirect_uri=os.getenv("REDIRECT_URI"),
oauth_url=os.getenv("OAUTH_URL"),
base_url=os.getenv("BASE_URL")
)
In this case, I have saved my App information as individual environment variables. For examples on how to access Procore information and create new object, see the snippets folder for a rather exhaustive list.
Resources
Procore:
- Procore Developer Dcoumentation: Various articles concerning the setup and use of Procore's API
- REST API Reference: Endpoints, response samples, and limited code snippets showcasing the use of the API.
GitHub Repositories
- Procore's Own Python Sample: Includes basic code to setup a Python Flash application but uses the other OAuth 2.0 grant type
- Python SDK for Procore: Small SDK that includes basic code to work with Procore. Uses the other OAuth 2.0 grant type.
License
This repository is licensed through the MIT License.
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
File details
Details for the file ProPyCore-0.1.3.tar.gz
.
File metadata
- Download URL: ProPyCore-0.1.3.tar.gz
- Upload date:
- Size: 23.3 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/5.1.1 CPython/3.11.9
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 812dbf8cecd0f922ec9f58d1b3e0e35366a81abe79a85ed58079ad0a332540e6 |
|
MD5 | 56cee898cc84a19ddc2e63bc60c6aef8 |
|
BLAKE2b-256 | 88ac7e0b9b6adc249e752517db02e89361a6c6f4d0e1ef66abdac1bfd16f0855 |
File details
Details for the file ProPyCore-0.1.3-py3-none-any.whl
.
File metadata
- Download URL: ProPyCore-0.1.3-py3-none-any.whl
- Upload date:
- Size: 54.3 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/5.1.1 CPython/3.11.9
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 2d07e495c0a671a9e76efa115321a8372c793fa5c2f94a4479e708afa7936bb0 |
|
MD5 | 5cbfd8f1258a9222a12f9a5f88501902 |
|
BLAKE2b-256 | 2c34d5ece88d306e7e8b6b86f6c19bee814e6826827dfcc4e43cde0305c758e1 |