Project Commitments API
This endpoint allows you to retrieve project commitments from Procore.
Endpoint
GET /api/external/project-commitments
Authentication
All API requests require an API key to be included in the request headers.
x-api-key: your-api-key
Required Headers
The following headers are required for all requests:
organization-id: your-organization-id
company-id: your-company-id
Request Parameters
Parameter | Type | Required | Description |
---|---|---|---|
project_id | string | Yes | The ID of the project to retrieve commitments for |
Example Request
curl -X GET "https://your-domain.com/api/external/project-commitments?project_id=123456" \
-H "x-api-key: your-api-key" \
-H "organization-id: your-organization-id" \
-H "company-id: your-company-id"
Response Format
A successful response will return a JSON object containing the project commitments data.
Success Response (200 OK)
{
"id": 12345,
"number": "PO-001",
"status": "active",
"title": "Example Commitment",
"description": "Example commitment description",
"vendor": {
"id": 67890,
"name": "Example Vendor"
},
"original_amount": "10000.00",
"revised_amount": "12000.00",
"total_amount": "12000.00",
"line_items": [
{
"id": 11111,
"description": "Example line item",
"amount": "5000.00",
"cost_code": {
"id": 22222,
"full_code": "01-001",
"name": "Example Cost Code"
}
}
],
"change_order_packages": [
{
"id": 33333,
"title": "Example Change Order",
"number": "CO-001",
"status": "approved",
"grand_total": "2000.00"
}
]
}
Error Response (400 Bad Request)
{
"error": "Missing required parameter: project_id"
}
Error Response (401 Unauthorized)
{
"error": "Invalid API key"
}
Error Response (500 Internal Server Error)
{
"error": "Failed to fetch project commitments"
}