openapi: 3.0.3 info: title: Stellar Cyber Open XDR Alerts Queries API description: The Stellar Cyber REST API provides programmatic access to the Open XDR platform, enabling automation of security operations including case management, tenant administration, connector management, alert handling, query operations, user management, watchlists, sensors, and security event management. version: '6.3' contact: name: Stellar Cyber Support url: https://stellarcyber.zendesk.com license: name: Proprietary url: https://stellarcyber.ai/terms/ servers: - url: https://{platformHostname}/connect/api/v1 description: Stellar Cyber Platform API variables: platformHostname: description: Your Stellar Cyber platform hostname default: your-platform.stellarcyber.ai security: - bearerAuth: [] tags: - name: Queries description: Saved query management paths: /queries: get: operationId: listQueries summary: List Queries description: Retrieve all saved queries. tags: - Queries responses: '200': description: List of saved queries content: application/json: schema: $ref: '#/components/schemas/QueriesListResponse' '401': $ref: '#/components/responses/Unauthorized' post: operationId: createQuery summary: Create Query description: Create a new saved query. tags: - Queries requestBody: required: true content: application/json: schema: $ref: '#/components/schemas/CreateQueryRequest' responses: '201': description: Query created successfully content: application/json: schema: $ref: '#/components/schemas/Query' '401': $ref: '#/components/responses/Unauthorized' /queries/{queryId}: put: operationId: updateQuery summary: Update Query description: Update an existing saved query. tags: - Queries parameters: - $ref: '#/components/parameters/QueryId' requestBody: required: true content: application/json: schema: $ref: '#/components/schemas/UpdateQueryRequest' responses: '200': description: Query updated successfully content: application/json: schema: $ref: '#/components/schemas/Query' '401': $ref: '#/components/responses/Unauthorized' delete: operationId: deleteQuery summary: Delete Query description: Delete a saved query. tags: - Queries parameters: - $ref: '#/components/parameters/QueryId' responses: '204': description: Query deleted successfully '401': $ref: '#/components/responses/Unauthorized' components: schemas: UpdateQueryRequest: type: object properties: name: type: string description: type: string query: type: string QueriesListResponse: type: object properties: data: type: array items: $ref: '#/components/schemas/Query' total: type: integer CreateQueryRequest: type: object required: - name - query properties: name: type: string description: type: string query: type: string Error: type: object properties: error: type: string message: type: string code: type: integer Query: type: object properties: id: type: string name: type: string description: type: string query: type: string created_at: type: string format: date-time responses: Unauthorized: description: Authentication required or token expired content: application/json: schema: $ref: '#/components/schemas/Error' parameters: QueryId: name: queryId in: path required: true description: Unique identifier for the query schema: type: string securitySchemes: bearerAuth: type: http scheme: bearer bearerFormat: JWT description: JWT token obtained from /access_token endpoint. Tokens expire after 10 minutes. API keys can also be used as Bearer tokens for the /access_token call.