> ## Documentation Index
> Fetch the complete documentation index at: https://docs.memmachine.ai/llms.txt
> Use this file to discover all available pages before exploring further.

# Add Embedder Endpoint

> Add a new embedder configuration at runtime.

    Creates a new embedder with the specified configuration and attempts to
    initialize it immediately. This allows adding embedders without restarting
    the server. The configuration is persisted to the configuration file.

    **Security Warning**: API keys and credentials are stored in plain text in
    the configuration file. Only use this API in protected environments. To
    avoid storing secrets in plain text, use environment variable references
    (e.g., `"api_key": "$OPENAI_API_KEY"`) which will be resolved at runtime.

    Supported providers:
    - `openai`: OpenAI embedding models (requires api_key, model)
    - `amazon-bedrock`: AWS Bedrock embedding models (requires region, model_id)
    - `sentence-transformer`: Local sentence transformer models (requires model)

    The response indicates whether the embedder was successfully initialized:
    - `success: true, status: ready`: Embedder is available for use
    - `success: false, status: failed`: Initialization failed (check error field)

    If initialization fails, the embedder configuration is still stored and can
    be retried later using the retry endpoint when the underlying service
    becomes available.

    Returns 422 if the provider type or configuration is invalid.



## OpenAPI

````yaml /openapi.json post /api/v2/config/resources/embedders
openapi: 3.1.0
info:
  title: MemMachine API
  version: 0.3.10
  description: >-
    Architectural Memory Systems for AI Agents. Specialized in episodic and
    semantic memory management with strict namespace isolation.
servers:
  - url: http://localhost:8080
security: []
tags:
  - name: Configuration
    description: System overview and memory subsystem configuration.
  - name: Episodic Configuration
    description: Per-project episodic memory subsystem configuration.
  - name: Memories
    description: Core operations for episodic and semantic memory ingestion and retrieval.
  - name: Projects
    description: Lifecycle management for isolated memory namespaces.
  - name: Resources
    description: Embedder, language model, and reranker lifecycle management.
  - name: 'Semantic Memory: Categories'
    description: Category, template, and tag management for semantic sets.
  - name: 'Semantic Memory: Features'
    description: Add, retrieve, and update individual semantic features.
  - name: 'Semantic Memory: Sets'
    description: Set type and set ID lifecycle, listing, and configuration.
  - name: System
    description: Infrastructure, health, and observability.
paths:
  /api/v2/config/resources/embedders:
    post:
      tags:
        - Resources
      summary: Add Embedder Endpoint
      description: |-
        Add a new embedder configuration at runtime.

            Creates a new embedder with the specified configuration and attempts to
            initialize it immediately. This allows adding embedders without restarting
            the server. The configuration is persisted to the configuration file.

            **Security Warning**: API keys and credentials are stored in plain text in
            the configuration file. Only use this API in protected environments. To
            avoid storing secrets in plain text, use environment variable references
            (e.g., `"api_key": "$OPENAI_API_KEY"`) which will be resolved at runtime.

            Supported providers:
            - `openai`: OpenAI embedding models (requires api_key, model)
            - `amazon-bedrock`: AWS Bedrock embedding models (requires region, model_id)
            - `sentence-transformer`: Local sentence transformer models (requires model)

            The response indicates whether the embedder was successfully initialized:
            - `success: true, status: ready`: Embedder is available for use
            - `success: false, status: failed`: Initialization failed (check error field)

            If initialization fails, the embedder configuration is still stored and can
            be retried later using the retry endpoint when the underlying service
            becomes available.

            Returns 422 if the provider type or configuration is invalid.
      operationId: add_embedder
      requestBody:
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/AddEmbedderSpec'
        required: true
      responses:
        '201':
          description: Successful Response
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/UpdateResourceResponse'
        '422':
          description: Validation Error
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/HTTPValidationError'
components:
  schemas:
    AddEmbedderSpec:
      properties:
        name:
          type: string
          title: Name
          description: |2-

                Unique name/identifier for the embedder.
        provider:
          type: string
          enum:
            - openai
            - amazon-bedrock
            - sentence-transformer
          title: Provider
          description: |2-

                The embedder provider type (e.g., 'openai', 'amazon-bedrock', 'sentence-transformer').
        config:
          additionalProperties: true
          type: object
          title: Config
          description: |2-

                Provider-specific configuration settings.
      type: object
      required:
        - name
        - provider
        - config
      title: AddEmbedderSpec
      description: Specification for adding a new embedder.
    UpdateResourceResponse:
      properties:
        success:
          type: boolean
          title: Success
          description: |2-

                Whether the operation succeeded.
        status:
          $ref: '#/components/schemas/ResourceStatus'
          description: |2-

                Current status of the resource after the operation.
        error:
          anyOf:
            - type: string
            - type: 'null'
          title: Error
          description: |2-

                Error message if the operation failed.
      type: object
      required:
        - success
        - status
      title: UpdateResourceResponse
      description: Response model for resource update operations.
    HTTPValidationError:
      properties:
        detail:
          items:
            $ref: '#/components/schemas/ValidationError'
          type: array
          title: Detail
      type: object
      title: HTTPValidationError
    ResourceStatus:
      type: string
      enum:
        - ready
        - failed
        - pending
      title: ResourceStatus
      description: Status of a resource.
    ValidationError:
      properties:
        loc:
          items:
            anyOf:
              - type: string
              - type: integer
          type: array
          title: Location
        msg:
          type: string
          title: Message
        type:
          type: string
          title: Error Type
      type: object
      required:
        - loc
        - msg
        - type
      title: ValidationError

````