openapi: 3.1.0 info: title: Salesforce Analytics (CRM Analytics) REST Actions Query API description: REST API for accessing and managing CRM Analytics (formerly Tableau CRM / Einstein Analytics) resources including datasets, lenses, dashboards, and dataflows. Enables programmatic access to analytics metadata, query execution, and dashboard management. Uses the Wave API resource at /services/data/vXX.0/wave. version: '63.0' contact: name: Salesforce Developer Support url: https://developer.salesforce.com/support email: developer@salesforce.com license: name: Salesforce API Terms of Use url: https://www.salesforce.com/company/legal/agreements/ servers: - url: https://{instance}.salesforce.com/services/data/v63.0/wave description: Salesforce production or developer instance variables: instance: default: yourInstance description: Your Salesforce instance identifier security: - oauth2: [] - bearerAuth: [] tags: - name: Query description: SAQL query execution paths: /query: post: operationId: executeQuery summary: Execute a SAQL query description: Executes a SAQL (Salesforce Analytics Query Language) query against CRM Analytics datasets. SAQL provides a SQL-like syntax for querying, aggregating, and transforming analytics data. tags: - Query requestBody: required: true content: application/json: schema: type: object required: - query properties: query: type: string description: The SAQL query string timezone: type: string description: The timezone for date operations (e.g., America/Los_Angeles) responses: '200': description: Query results content: application/json: schema: $ref: '#/components/schemas/QueryResult' get: operationId: toolingQuery summary: Execute a Tooling API SOQL query description: Executes a SOQL query against Tooling API objects. Supports querying ApexClass, ApexTrigger, Flow, FlowDefinition, CustomField, ValidationRule, WorkflowRule, and other metadata types. tags: - Query parameters: - name: q in: query required: true description: The SOQL query string targeting Tooling API objects (e.g., SELECT Id, FullName, Metadata FROM Flow WHERE Status = 'Active') schema: type: string responses: '200': description: Query results content: application/json: schema: $ref: '#/components/schemas/QueryResult_2' components: schemas: QueryResult_2: type: object properties: totalSize: type: integer done: type: boolean records: type: array items: type: object additionalProperties: true nextRecordsUrl: type: string QueryResult: type: object properties: action: type: string responseId: type: string results: type: object properties: metadata: type: array items: type: object additionalProperties: true records: type: array items: type: object additionalProperties: true query: type: string responseTime: type: number securitySchemes: oauth2: type: oauth2 flows: authorizationCode: authorizationUrl: https://login.salesforce.com/services/oauth2/authorize tokenUrl: https://login.salesforce.com/services/oauth2/token scopes: api: Access and manage your Salesforce data wave_api: Access CRM Analytics REST API resources bearerAuth: type: http scheme: bearer