openapi: 3.2.0 info: title: Datarails Finance OS MCP Server OAUTH API version: 3.0.0 tags: - name: Oauth paths: /oauth/callback: get: summary: Oauth Callback description: Handle Descope callback — exchange session token for JWT via POST. operationId: oauth_callback_oauth_callback_get parameters: - name: session_token in: query required: false schema: anyOf: - type: string - type: 'null' title: Session Token - name: env_url in: query required: false schema: anyOf: - type: string - type: 'null' title: Env Url - name: state in: query required: false schema: anyOf: - type: string - type: 'null' title: State - name: error in: query required: false schema: anyOf: - type: string - type: 'null' title: Error responses: '200': description: Successful Response content: application/json: schema: {} '422': description: Validation Error content: application/json: schema: $ref: '#/components/schemas/HTTPValidationError' tags: - Oauth components: schemas: HTTPValidationError: properties: detail: items: $ref: '#/components/schemas/ValidationError' type: array title: Detail type: object title: HTTPValidationError ValidationError: properties: loc: items: anyOf: - type: string - type: integer type: array title: Location msg: type: string title: Message type: type: string title: Error Type input: title: Input ctx: type: object title: Context type: object required: - loc - msg - type title: ValidationError