openapi: 3.0.3 info: title: Agave Unified Construction Budgets Cost Codes API description: The Agave Unified Construction API provides a single REST API to read and write data from 100+ construction and accounting software systems. It normalizes data across platforms including projects, budgets, contracts, commitments, purchase orders, invoices, cost codes, vendors, timesheets, and employees. version: '1.0' contact: name: Agave API Support url: https://docs.agaveapi.com x-generated-from: documentation servers: - url: https://api.agaveapi.com/v1 description: Production Server - url: https://sandbox.agaveapi.com/v1 description: Sandbox Server security: - apiKey: [] tags: - name: Cost Codes description: Job cost codes and cost types. paths: /cost-codes: get: operationId: listCostCodes summary: Agave List Cost Codes description: Retrieve job cost codes from the linked source system. tags: - Cost Codes parameters: - name: source_system_id in: header required: true description: The linked account source system identifier. schema: type: string example: linked-account-abc123 - name: project_id in: query description: Filter cost codes by project ID. schema: type: string example: proj-500123 responses: '200': description: A list of cost codes. content: application/json: schema: $ref: '#/components/schemas/CostCodeList' examples: listCostCodes200Example: summary: Default listCostCodes 200 response x-microcks-default: true value: data: - {} next_cursor: example_value count: 1 '401': description: Unauthorized. content: application/json: schema: $ref: '#/components/schemas/Error' examples: listCostCodes401Example: summary: Default listCostCodes 401 response x-microcks-default: true value: error: example_value message: example_value request_id: '500123' x-microcks-operation: delay: 0 dispatcher: FALLBACK components: schemas: CostCode: type: object description: A job cost code for categorizing construction costs. properties: id: type: string description: Cost code identifier. example: cc-445566 project_id: type: string description: Associated project identifier. example: proj-500123 code: type: string description: Cost code value. example: 03-1000 description: type: string description: Cost code description. example: Concrete cost_type: type: string description: Cost type classification. enum: - labor - material - equipment - subcontract - other example: material Error: type: object description: API error response. properties: error: type: string description: Error code. example: not_found message: type: string description: Human-readable error description. example: The requested resource was not found. request_id: type: string description: Unique request ID for support. example: req-a1b2c3d4e5 CostCodeList: type: object description: Paginated list of cost codes. properties: data: type: array items: $ref: '#/components/schemas/CostCode' example: - example_value next_cursor: type: string example: eyJpZCI6MTIzfQ== count: type: integer example: 200 securitySchemes: apiKey: type: apiKey in: header name: API-Key description: Agave API key for authentication.