{ "info": { "_postman_id": "caltrans-payment-tracking-api", "name": "Caltrans Payment Tracking API", "description": "API for retrieving contract payment history and detailed monthly estimates from the California Department of Transportation (Caltrans) Payment Estimation Tracking System (PETS)", "schema": "https://schema.getpostman.com/json/collection/v2.1.0/collection.json", "_exporter_id": "caltrans-payment-tracking-api" }, "item": [ { "name": "Root Endpoint", "request": { "method": "GET", "header": [], "url": { "raw": "{{base_url}}/", "host": [ "{{base_url}}" ], "path": [ "" ] }, "description": "Root endpoint that provides API information, available endpoints, and workflow descriptions." }, "response": [] }, { "name": "Health Check", "request": { "method": "GET", "header": [], "url": { "raw": "{{base_url}}/health", "host": [ "{{base_url}}" ], "path": [ "health" ] }, "description": "Health check endpoint to verify API status and get current timestamp." }, "response": [] }, { "name": "Get Contract Payments", "request": { "method": "GET", "header": [], "url": { "raw": "{{base_url}}/contracts/{{contract_number}}/payments", "host": [ "{{base_url}}" ], "path": [ "contracts", "{{contract_number}}", "payments" ] }, "description": "Retrieve complete payment history for a contract (basic PETS data only). This endpoint scrapes the PETS system for payment history and returns contract details, payment records, contact information, and summary statistics." }, "response": [] }, { "name": "Get Monthly Payments with Details", "request": { "method": "GET", "header": [], "url": { "raw": "{{base_url}}/contracts/{{contract_number}}/payments/monthly/{{month}}", "host": [ "{{base_url}}" ], "path": [ "contracts", "{{contract_number}}", "payments", "monthly", "{{month}}" ] }, "description": "Retrieve detailed payment information for a specific month. This endpoint:\n1. Scrapes PETS system to get payment history\n2. Filters payments for the specified month\n3. For each payment in that month, follows the detail_link\n4. Parses the detailed CAS145 estimate information\n\nNote: Month must be in YYYY-MM format (e.g., '2024-12' for December 2024)" }, "response": [] } ], "event": [ { "listen": "prerequest", "script": { "type": "text/javascript", "exec": [ "// Pre-request script to set default values if not already set", "if (!pm.environment.get('base_url')) {", " pm.environment.set('base_url', 'http://localhost:8000');", "}", "if (!pm.environment.get('contract_number')) {", " pm.environment.set('contract_number', '03-3F0704');", "}", "if (!pm.environment.get('month')) {", " pm.environment.set('month', '2025-05');", "}" ] } } ], "variable": [ { "key": "base_url", "value": "http://localhost:8000", "type": "string", "description": "Base URL for the Caltrans Payment Tracking API" }, { "key": "contract_number", "value": "03-3F0704", "type": "string", "description": "Example contract number for testing" }, { "key": "month", "value": "2025-05", "type": "string", "description": "Example month in YYYY-MM format for testing" } ] }