Step 1: Sign up for a CoConstruct developer account
Get access to CoConstruct’s APIs by signing up for a developer account. Our API Team will reach out to learn more about the integrated solution you’re planning to build and discuss how you can best make use of the CoConstruct API to achieve your goal.
We’ll also set you up with the Client ID and Client Secret you’ll need to access our APIs as well as the credentials for a developer sandbox environment for testing and experimentation.
In the meantime, you can start exploring our API documentation.
Step 2: Get an access token
CoConstruct uses the OAuth 2.0 Authorization Code grant type to issue an access token for our APIs. Any resources we can link to that provide info on OAuth framework?
Visit www.oauth.com to read about the basis of oAuth 2.0.
To request a token, you’ll need to provide the following info:
Use the callback URL that you provided to CoConstruct when registering your application.
Access Token URL
32 character value, e.g., 05703afd9a20093851fee3b7a72cf5f6
64 character value, e.g., 9c0ea20ed5092b4608c29eabb6d135ba706acb88c46031c5d1768c40f38e8151
Include the scopes relevant to the API calls you’ll be making, which are noted in our API documentation.
You may also include the offline_access scope to obtain a refresh token along with the access token.
Step 3: Complete the authorization workflow
Upon successful validation of the info in the previous step, you will be presented with the authorization workflow as shown below.
Completing the workflow requires logging in as a CoConstruct user with admin privileges.
During development and testing, you may use the test credentials provided by Coconstruct, which will have the necessary admin privileges.
After logging in with valid CoConstruct credentials, you will need to give consent to the connecting app as shown in the screen on the right.
The scopes you requested in Step 2 will inform what the end user sees here, detailing which areas of the CoConstruct account you have requested to access.
After you click Allow, the token will be issued.
Step 4: Make your first API call
Now that you have your access token, you can make a call to any of CoConstruct’s APIs. We recommend starting with the Get Contractor List request, which provides basic information about CoConstruct accounts and serves as the basis for the workflows you’ll build out with our API.
The base URL for all API requests will be as follows:
Using Postman, the Get Contractor List request will appear as follows:
A successful Get Contractor List request will return a JSON response in the following format.