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

# Restore archived agent



## OpenAPI

````yaml /openapi.json post /api/agents/{id}/restore
openapi: 3.0.0
info:
  title: GoMobile Backend API
  description: >-
    API documentation for GoMobile telephony platform - automated calling
    campaigns, interactive voice flows, and call management
  version: '1.0'
  contact: {}
servers:
  - url: http://localhost:3000
    description: Local Development
security: []
tags:
  - name: Organizations
    description: Multi-tenant organization management
  - name: Teams
    description: Team structure and hierarchy
  - name: Contacts
    description: Customer contact management (CRM)
  - name: Entities
    description: Business entities management
  - name: Audiences
    description: Contact segmentation and groups
  - name: Programs
    description: Call campaign configuration
  - name: Call Flows
    description: Interactive call flow builder
paths:
  /api/agents/{id}/restore:
    post:
      tags:
        - Agent Studio
      summary: Restore archived agent
      operationId: AgentStudioController_restore
      parameters:
        - name: id
          required: true
          in: path
          description: Agent ID
          schema:
            type: string
      responses:
        '200':
          description: Agent restored successfully
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/AgentResponseDto'
        '404':
          description: Agent not found
        '409':
          description: Invalid status transition
      security:
        - bearer: []
components:
  schemas:
    AgentResponseDto:
      type: object
      properties:
        id:
          type: string
          description: Agent ID
        organizationId:
          type: string
          description: Organization ID
        name:
          type: string
          description: Agent name
          example: Customer Support Agent
        description:
          type: string
          description: Agent description
          nullable: true
        instructions:
          type: string
          description: Agent instructions
        policy:
          type: string
          description: Agent policy (business rules)
          nullable: true
        status:
          type: string
          description: Agent status
          enum:
            - draft
            - active
            - archived
        version:
          type: number
          description: Agent version
        modelConfig:
          description: Model configuration
          allOf:
            - $ref: '#/components/schemas/AgentModelConfigDto'
        voiceConfig:
          description: Voice configuration
          allOf:
            - $ref: '#/components/schemas/AgentVoiceConfigDto'
        memoryConfig:
          description: Memory configuration
          allOf:
            - $ref: '#/components/schemas/AgentMemoryConfigDto'
        metadata:
          type: object
          description: Additional metadata
          nullable: true
          additionalProperties: true
        knowledgeBaseConfig:
          type: object
          description: Knowledge base configuration for RAG
          nullable: true
          additionalProperties: true
        createdAt:
          format: date-time
          type: string
          description: Created at timestamp
        updatedAt:
          format: date-time
          type: string
          description: Updated at timestamp
        createdBy:
          type: string
          description: Created by user ID
          nullable: true
      required:
        - id
        - organizationId
        - name
        - instructions
        - status
        - version
        - modelConfig
        - createdAt
        - updatedAt
    AgentModelConfigDto:
      type: object
      properties:
        model:
          type: string
          example: openai/gpt-4o
        modelSettings:
          type: object
          nullable: true
          additionalProperties: true
        providerOptions:
          type: object
          nullable: true
          additionalProperties: true
      required:
        - model
    AgentVoiceConfigDto:
      type: object
      properties:
        pipelineMode:
          type: string
          example: batch
          enum:
            - batch
            - streaming
            - sts
        voiceId:
          type: string
          example: EXAVITQdyfvLewQXW32eyLI
        stsProvider:
          type: string
          example: openai
          enum:
            - openai
            - gemini
      required:
        - pipelineMode
    AgentMemoryConfigDto:
      type: object
      properties:
        enabled:
          type: boolean
          example: true
        lastMessages:
          type: number
          example: 20
        semanticRecall:
          type: boolean
          example: false
      required:
        - enabled
  securitySchemes:
    bearer:
      scheme: bearer
      bearerFormat: JWT
      type: http

````