Delphi Tags API

Create tags and organize your audience.

OpenAPI Specification

delphi-tags-api-openapi.yml Raw ↑
openapi: 3.1.0
info:
  title: Delphi Audience Tags API
  version: v3
  x-provenance:
    generated: '2026-07-18'
    method: generated
    source: https://docs.delphi.ai/advanced/actions/api-immortal-only.md and the per-resource reference pages (audience, conversations, clone, questions, tags, usage, voice, search). Hand-built from the published REST reference; Delphi does not publish a machine-readable OpenAPI.
  description: The Delphi API lets you integrate your Digital Mind (an AI clone trained on your content) directly into your own app, platform, or workflow. Create conversations, stream text and voice responses, manage your audience and its contextual memory, organize contacts with tags, search your clone's knowledge base for RAG, and track per-user usage. API access is available on the Immortal plan. All endpoints authenticate with an API key passed in the x-api-key header and are scoped to a single clone.
  contact:
    name: Delphi Support
    email: support@delphi.ai
    url: https://docs.delphi.ai/advanced/actions/api-immortal-only
  termsOfService: https://delphi.ai/terms
servers:
- url: https://api.delphi.ai
  description: Production
security:
- ApiKeyAuth: []
tags:
- name: Tags
  description: Create tags and organize your audience.
paths:
  /v3/tags:
    post:
      operationId: createTag
      tags:
      - Tags
      summary: Create a tag
      description: Create a new tag for organizing your audience. Returns 409 if a tag with the same name already exists.
      requestBody:
        required: true
        content:
          application/json:
            schema:
              type: object
              required:
              - name
              properties:
                name:
                  type: string
                  description: Tag name (must be unique per clone)
                color:
                  type: string
                  default: default
            example:
              name: VIP
              color: blue
      responses:
        '200':
          description: Tag created
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Tag'
        '401':
          $ref: '#/components/responses/Unauthorized'
        '409':
          $ref: '#/components/responses/Conflict'
        '429':
          $ref: '#/components/responses/RateLimited'
    get:
      operationId: listTags
      tags:
      - Tags
      summary: List all tags
      description: Retrieve all tags for your clone, sorted newest first.
      responses:
        '200':
          description: List of tags
          content:
            application/json:
              schema:
                type: object
                properties:
                  tags:
                    type: array
                    items:
                      $ref: '#/components/schemas/Tag'
                  total_count:
                    type: integer
        '401':
          $ref: '#/components/responses/Unauthorized'
        '429':
          $ref: '#/components/responses/RateLimited'
  /v3/users/{user_id}/tags/{tag_name}:
    post:
      operationId: tagUser
      tags:
      - Tags
      summary: Tag a user
      description: Apply a tag to a user in your audience. Idempotent — tagging a user who already has the tag succeeds without error.
      parameters:
      - name: user_id
        in: path
        required: true
        schema:
          type: string
      - name: tag_name
        in: path
        required: true
        schema:
          type: string
      responses:
        '200':
          description: Tag applied
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/TagMutation'
        '401':
          $ref: '#/components/responses/Unauthorized'
        '404':
          $ref: '#/components/responses/NotFound'
        '429':
          $ref: '#/components/responses/RateLimited'
    delete:
      operationId: untagUser
      tags:
      - Tags
      summary: Untag a user
      description: Remove a tag from a user. Idempotent — untagging a user who doesn't have the tag succeeds without error.
      parameters:
      - name: user_id
        in: path
        required: true
        schema:
          type: string
      - name: tag_name
        in: path
        required: true
        schema:
          type: string
      responses:
        '200':
          description: Tag removed
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/TagMutation'
        '401':
          $ref: '#/components/responses/Unauthorized'
        '404':
          $ref: '#/components/responses/NotFound'
        '429':
          $ref: '#/components/responses/RateLimited'
components:
  schemas:
    TagMutation:
      type: object
      properties:
        success:
          type: boolean
        tag_id:
          type: string
        tag_name:
          type: string
        user_id:
          type: string
        message:
          type: string
    Tag:
      type: object
      properties:
        id:
          type: string
        name:
          type: string
        color:
          type: string
        created_at:
          type: string
          format: date-time
        updated_at:
          type: string
          format: date-time
    Error:
      type: object
      properties:
        error:
          type: string
          description: Error message
  responses:
    Unauthorized:
      description: Missing or invalid API key
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/Error'
    NotFound:
      description: Resource not found
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/Error'
    RateLimited:
      description: Too many requests — 120 requests per 60 seconds per API key exceeded
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/Error'
    Conflict:
      description: Resource already exists (e.g. duplicate tag name)
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/Error'
  securitySchemes:
    ApiKeyAuth:
      type: apiKey
      in: header
      name: x-api-key
      description: API key scoped to a single clone. Available on the Immortal plan; request one from support@delphi.ai.