Cadencz brain conversations API

The brain conversations API from Cadencz — 4 operation(s) for brain conversations.

Operations 5

GET /api/v1/brains/{brain_id}/conversations List a Brain's conversations #
POST /api/v1/brains/{brain_id}/conversations Start a Brain conversation #
GET /api/v1/brains/{brain_id}/conversations/{conversation_id} Get a Brain conversation #
GET /api/v1/brains/{brain_id}/conversations/{conversation_id}/handoff/{message_id} Load one Brain draft for Compose #
POST /api/v1/brains/{brain_id}/conversations/{conversation_id}/messages Send a message to a Brain #

Work with this as data

Every API here is available over the APIs.io API and to AI agents over MCP.

MCP server

One button, every client — Claude, Cursor, VS Code and the rest.

https://apis.io/mcp

Tools for apis

7 MCP tools reach this
  • find_apisBrowse and filter every API in the catalog.
  • get_api_artifactsOne API's artifacts, grouped by type.
  • get_openapiThe primary OpenAPI for this API.
  • find_similar_apisAPIs that look like this one.
  • apis_io_searchSTART HERE — APIs, providers and tags for one query, each with its total.
  • resolveTurn a domain, URL or GitHub org into the provider it belongs to.
  • find_cohortsEvery scored population of providers in the catalog.
All 92 tools →

Call it yourself

curl for this page
This API
curl "https://apis.io/api/v1/apis/cadencz-com:cadencz-com-brain-conversations-api"
All apis
curl "https://apis.io/api/v1/apis?limit=25"

Calls without X-API-Key need no key. Calls with it need a paid plan — get a key.

Get an API key

Free tier, no form to fill in. Signing in shares your email address with us — we store it to create your key and to recognise you if you sign in with another provider. See our Privacy Policy and Terms.

A second provider on the same verified email joins the account you already have.

OpenAPI Specification

cadencz-com-brain-conversations-api-openapi.yml Raw ↑
openapi: 3.2.0
info:
  title: Cadencz brain conversations API
  description: Cadencz Phase 0 API. Frontend developers can use this Swagger page as the live request/response contract. Click `Authorize` and paste a Supabase access token for user-scoped endpoints.
  version: 0.1.0
tags:
- name: brain conversations
paths:
  /api/v1/brains/{brain_id}/conversations:
    get:
      tags:
      - brain conversations
      summary: List a Brain's conversations
      operationId: list_conversations_api_v1_brains__brain_id__conversations_get
      parameters:
      - name: brain_id
        in: path
        required: true
        schema:
          type: string
          title: Brain Id
      responses:
        '200':
          description: Successful Response
          content:
            application/json:
              schema:
                type: array
                items:
                  $ref: '#/components/schemas/BrainConversationRead'
                title: Response List Conversations Api V1 Brains  Brain Id  Conversations Get
        '401':
          description: Missing or invalid Supabase bearer token.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ErrorResponse'
        '404':
          description: The requested resource was not found.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ErrorResponse'
        '422':
          description: Validation Error
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/HTTPValidationError'
      security:
      - SupabaseBearerAuth: []
    post:
      tags:
      - brain conversations
      summary: Start a Brain conversation
      operationId: start_conversation_api_v1_brains__brain_id__conversations_post
      parameters:
      - name: brain_id
        in: path
        required: true
        schema:
          type: string
          title: Brain Id
      requestBody:
        required: true
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/BrainConversationCreate'
      responses:
        '201':
          description: Successful Response
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/BrainConversationRead'
        '401':
          description: Missing or invalid Supabase bearer token.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ErrorResponse'
        '404':
          description: The requested resource was not found.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ErrorResponse'
        '422':
          description: Validation Error
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/HTTPValidationError'
      security:
      - SupabaseBearerAuth: []
  /api/v1/brains/{brain_id}/conversations/{conversation_id}:
    get:
      tags:
      - brain conversations
      summary: Get a Brain conversation
      operationId: get_conversation_api_v1_brains__brain_id__conversations__conversation_id__get
      parameters:
      - name: brain_id
        in: path
        required: true
        schema:
          type: string
          title: Brain Id
      - name: conversation_id
        in: path
        required: true
        schema:
          type: string
          title: Conversation Id
      responses:
        '200':
          description: Successful Response
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/BrainConversationDetail'
        '401':
          description: Missing or invalid Supabase bearer token.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ErrorResponse'
        '404':
          description: The requested resource was not found.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ErrorResponse'
        '422':
          description: Validation Error
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/HTTPValidationError'
      security:
      - SupabaseBearerAuth: []
  /api/v1/brains/{brain_id}/conversations/{conversation_id}/handoff/{message_id}:
    get:
      tags:
      - brain conversations
      summary: Load one Brain draft for Compose
      operationId: get_conversation_handoff_api_v1_brains__brain_id__conversations__conversation_id__handoff__message_id__get
      parameters:
      - name: brain_id
        in: path
        required: true
        schema:
          type: string
          title: Brain Id
      - name: conversation_id
        in: path
        required: true
        schema:
          type: string
          title: Conversation Id
      - name: message_id
        in: path
        required: true
        schema:
          type: string
          title: Message Id
      responses:
        '200':
          description: Successful Response
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/BrainConversationHandoff'
        '401':
          description: Missing or invalid Supabase bearer token.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ErrorResponse'
        '404':
          description: The requested resource was not found.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ErrorResponse'
        '400':
          description: The request payload is invalid.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ErrorResponse'
        '422':
          description: Validation Error
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/HTTPValidationError'
      security:
      - SupabaseBearerAuth: []
  /api/v1/brains/{brain_id}/conversations/{conversation_id}/messages:
    post:
      tags:
      - brain conversations
      summary: Send a message to a Brain
      operationId: send_message_api_v1_brains__brain_id__conversations__conversation_id__messages_post
      parameters:
      - name: brain_id
        in: path
        required: true
        schema:
          type: string
          title: Brain Id
      - name: conversation_id
        in: path
        required: true
        schema:
          type: string
          title: Conversation Id
      requestBody:
        required: true
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/BrainChatRequest'
      responses:
        '200':
          description: Successful Response
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/BrainChatResponse'
        '401':
          description: Missing or invalid Supabase bearer token.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ErrorResponse'
        '404':
          description: The requested resource was not found.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ErrorResponse'
        '502':
          description: The upstream provider rejected the request.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ErrorResponse'
        '503':
          description: Required infrastructure or provider config is unavailable.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ErrorResponse'
        '422':
          description: Validation Error
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/HTTPValidationError'
      security:
      - SupabaseBearerAuth: []
components:
  schemas:
    BrainConversationRead:
      properties:
        id:
          type: string
          title: Id
        brain_id:
          type: string
          title: Brain Id
        title:
          type: string
          title: Title
        status:
          type: string
          title: Status
        message_count:
          type: integer
          title: Message Count
        user_message_count:
          type: integer
          title: User Message Count
        current_draft:
          type: string
          title: Current Draft
        current_platform:
          anyOf:
          - type: string
          - type: 'null'
          title: Current Platform
        last_message_at:
          anyOf:
          - type: string
            format: date-time
          - type: 'null'
          title: Last Message At
        summary_through_sequence:
          type: integer
          title: Summary Through Sequence
        created_at:
          type: string
          format: date-time
          title: Created At
        updated_at:
          type: string
          format: date-time
          title: Updated At
      type: object
      required:
      - id
      - brain_id
      - title
      - status
      - message_count
      - user_message_count
      - current_draft
      - current_platform
      - last_message_at
      - summary_through_sequence
      - created_at
      - updated_at
      title: BrainConversationRead
    BrainChatResponse:
      properties:
        conversation:
          $ref: '#/components/schemas/BrainConversationRead'
        user_message:
          $ref: '#/components/schemas/BrainMessageRead'
        assistant_message:
          $ref: '#/components/schemas/BrainMessageRead'
        intent:
          type: string
          enum:
          - chat
          - create
          - refine
          title: Intent
        draft:
          anyOf:
          - type: string
          - type: 'null'
          title: Draft
      type: object
      required:
      - conversation
      - user_message
      - assistant_message
      - intent
      - draft
      title: BrainChatResponse
    BrainConversationDetail:
      properties:
        id:
          type: string
          title: Id
        brain_id:
          type: string
          title: Brain Id
        title:
          type: string
          title: Title
        status:
          type: string
          title: Status
        message_count:
          type: integer
          title: Message Count
        user_message_count:
          type: integer
          title: User Message Count
        current_draft:
          type: string
          title: Current Draft
        current_platform:
          anyOf:
          - type: string
          - type: 'null'
          title: Current Platform
        last_message_at:
          anyOf:
          - type: string
            format: date-time
          - type: 'null'
          title: Last Message At
        summary_through_sequence:
          type: integer
          title: Summary Through Sequence
        created_at:
          type: string
          format: date-time
          title: Created At
        updated_at:
          type: string
          format: date-time
          title: Updated At
        summary:
          additionalProperties: true
          type: object
          title: Summary
        messages:
          items:
            $ref: '#/components/schemas/BrainMessageRead'
          type: array
          title: Messages
      type: object
      required:
      - id
      - brain_id
      - title
      - status
      - message_count
      - user_message_count
      - current_draft
      - current_platform
      - last_message_at
      - summary_through_sequence
      - created_at
      - updated_at
      - summary
      title: BrainConversationDetail
    BrainChatRequest:
      properties:
        message:
          type: string
          maxLength: 8000
          minLength: 1
          title: Message
        mode:
          type: string
          enum:
          - auto
          - chat
          - create
          - refine
          title: Mode
          default: auto
        platform:
          anyOf:
          - type: string
            maxLength: 40
            minLength: 1
          - type: 'null'
          title: Platform
      type: object
      required:
      - message
      title: BrainChatRequest
    BrainMessageRead:
      properties:
        id:
          type: string
          title: Id
        conversation_id:
          type: string
          title: Conversation Id
        role:
          type: string
          enum:
          - user
          - assistant
          title: Role
        sequence:
          type: integer
          title: Sequence
        content:
          type: string
          title: Content
        intent:
          anyOf:
          - type: string
          - type: 'null'
          title: Intent
        provider:
          anyOf:
          - type: string
          - type: 'null'
          title: Provider
        model:
          anyOf:
          - type: string
          - type: 'null'
          title: Model
        agent_run_id:
          anyOf:
          - type: string
          - type: 'null'
          title: Agent Run Id
        metadata:
          additionalProperties: true
          type: object
          title: Metadata
        created_at:
          type: string
          format: date-time
          title: Created At
      type: object
      required:
      - id
      - conversation_id
      - role
      - sequence
      - content
      - intent
      - provider
      - model
      - agent_run_id
      - metadata
      - created_at
      title: BrainMessageRead
    BrainConversationCreate:
      properties:
        title:
          anyOf:
          - type: string
            maxLength: 160
          - type: 'null'
          title: Title
      type: object
      title: BrainConversationCreate
    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
    BrainConversationHandoff:
      properties:
        kind:
          type: string
          const: brain_conversation
          title: Kind
          default: brain_conversation
        brain_id:
          type: string
          title: Brain Id
        conversation_id:
          type: string
          title: Conversation Id
        conversation_title:
          type: string
          title: Conversation Title
        message_id:
          type: string
          title: Message Id
        idea:
          type: string
          title: Idea
        platform:
          type: string
          title: Platform
        body:
          type: string
          title: Body
        agent_run_id:
          anyOf:
          - type: string
          - type: 'null'
          title: Agent Run Id
        source_ids:
          items:
            type: string
          type: array
          title: Source Ids
      type: object
      required:
      - brain_id
      - conversation_id
      - conversation_title
      - message_id
      - idea
      - platform
      - body
      - agent_run_id
      title: BrainConversationHandoff
    ErrorResponse:
      properties:
        detail:
          anyOf:
          - type: string
          - additionalProperties: true
            type: object
          - items: {}
            type: array
          title: Detail
      type: object
      required:
      - detail
      title: ErrorResponse
      example:
        detail: Authorization header is required.
    HTTPValidationError:
      properties:
        detail:
          items:
            $ref: '#/components/schemas/ValidationError'
          type: array
          title: Detail
      type: object
      title: HTTPValidationError
  securitySchemes:
    SupabaseBearerAuth:
      type: http
      scheme: bearer
      bearerFormat: Supabase access token
      description: 'Send the Supabase access token as `Authorization: Bearer <token>`.'
    DodoWebhookSignature:
      type: apiKey
      in: header
      name: webhook-signature
      description: Dodo Payments webhook signature header.