openapi: 3.1.1 info: title: Alpic analytics API version: 1.0.0 servers: - url: https://api.alpic.ai security: - bearerAuth: [] tags: - name: analytics paths: /v1/analytics/{projectId}: get: operationId: analytics.get.v1 summary: Get project analytics description: Get analytics data for a project over a time range tags: - analytics parameters: - name: projectId in: path required: true schema: type: string description: The ID of the project - name: startTimestamp in: query required: true schema: type: number description: Start timestamp in milliseconds allowEmptyValue: true allowReserved: true - name: endTimestamp in: query required: true schema: type: number description: End timestamp in milliseconds allowEmptyValue: true allowReserved: true - name: timeZone in: query required: true schema: type: string description: IANA timezone (e.g. Europe/Paris) allowEmptyValue: true allowReserved: true responses: '200': description: The project analytics data content: application/json: schema: type: object properties: metadata: type: object properties: startTimestamp: type: number endTimestamp: type: number timeZone: type: string startDate: type: string format: date-time x-native-type: date interval: type: string required: - startTimestamp - endTimestamp - timeZone - startDate - interval timeSeries: type: object properties: sessions_count: type: array items: type: object properties: timestamp: type: number categories: type: object propertyNames: type: string additionalProperties: {} required: - timestamp - categories requests_count: type: array items: type: object properties: timestamp: type: number categories: type: object propertyNames: type: string additionalProperties: {} required: - timestamp - categories requests_latency_mean: type: array items: type: object properties: timestamp: type: number categories: type: object propertyNames: type: string additionalProperties: {} required: - timestamp - categories tool_errors: type: array items: type: object properties: timestamp: type: number categories: type: object propertyNames: type: string additionalProperties: {} required: - timestamp - categories mcp_errors: type: array items: type: object properties: timestamp: type: number categories: type: object propertyNames: type: string additionalProperties: {} required: - timestamp - categories output_token_mean: type: array items: type: object properties: timestamp: type: number categories: type: object propertyNames: type: string additionalProperties: {} required: - timestamp - categories task_count: type: array items: type: object properties: timestamp: type: number categories: type: object propertyNames: type: string additionalProperties: {} required: - timestamp - categories required: - sessions_count - requests_count - requests_latency_mean - tool_errors - mcp_errors - output_token_mean - task_count required: - metadata - timeSeries '400': description: '400' content: application/json: schema: oneOf: - type: object properties: defined: const: true code: const: BAD_REQUEST status: const: 400 message: type: string default: Bad Request data: {} required: - defined - code - status - message - type: object properties: defined: const: false code: type: string status: type: number message: type: string data: {} required: - defined - code - status - message '404': description: '404' content: application/json: schema: oneOf: - type: object properties: defined: const: true code: const: NOT_FOUND status: const: 404 message: type: string default: Not Found data: {} required: - defined - code - status - message - type: object properties: defined: const: false code: type: string status: type: number message: type: string data: {} required: - defined - code - status - message components: securitySchemes: bearerAuth: type: http description: Bearer token for authentication. Use an API key from the API Keys page in team settings, or an OAuth access token. scheme: bearer