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

# Add Prompt

> Create a new prompt for an entity.



## OpenAPI

````yaml post /entities/addprompt
openapi: 3.1.0
info:
  title: Geogen API
  description: >-
    API for accessing LLM visibility data, managing entities, and tracking AI
    mentions.
  version: 1.0.0
servers:
  - url: https://api.geogen.io/v1
    description: Production server
security:
  - bearerAuth: []
paths:
  /entities/addprompt:
    post:
      tags:
        - Entities
      summary: Add Prompt(s)
      description: >-
        Create one or more prompts for an entity. Supports both single prompt
        and bulk upload modes.


        **Single prompt mode:** Use `prompt` field with a string value.


        **Bulk upload mode:** Use `prompts` field with an array of prompt
        objects. Each object can have its own language/geolocation, or inherit
        from the top-level defaults.
      operationId: addPrompt
      requestBody:
        required: true
        content:
          application/json:
            schema:
              type: object
              required:
                - entityId
              properties:
                entityId:
                  type: string
                  description: Entity ID
                prompt:
                  type: string
                  description: Prompt text (for single prompt mode)
                prompts:
                  type: array
                  description: Array of prompts (for bulk upload mode)
                  items:
                    type: object
                    required:
                      - prompt
                    properties:
                      prompt:
                        type: string
                        description: Prompt text
                      language:
                        type: string
                        description: Language code (overrides default)
                      geolocation:
                        type: string
                        description: Geolocation code (overrides default)
                language:
                  type: string
                  description: Default language code for prompts
                geolocation:
                  type: string
                  description: Default geolocation code for prompts
            examples:
              single:
                summary: Single prompt
                value:
                  entityId: abc123def456...
                  prompt: What are the best tools for SEO?
                  language: en
                  geolocation: us
              bulk:
                summary: Bulk upload
                value:
                  entityId: abc123def456...
                  prompts:
                    - prompt: What are the best SEO tools?
                    - prompt: Quelles sont les meilleures outils SEO?
                      language: fr
                    - prompt: What is the best marketing software in UK?
                      geolocation: gb
                  language: en
                  geolocation: global
      responses:
        '201':
          description: Prompt(s) created successfully
          content:
            application/json:
              schema:
                oneOf:
                  - type: object
                    description: Single prompt response
                    properties:
                      success:
                        type: boolean
                      promptId:
                        type: string
                        description: Created prompt ID
                  - type: object
                    description: Bulk upload response
                    properties:
                      success:
                        type: boolean
                      promptIds:
                        type: array
                        items:
                          type: string
                        description: Array of created prompt IDs
                      count:
                        type: number
                        description: Number of prompts created
        '400':
          description: Bad request - invalid input
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Error'
        '401':
          description: Unauthorized
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Error'
        '403':
          description: Prompt limit exceeded
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Error'
        '404':
          description: Entity not found
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Error'
components:
  schemas:
    Error:
      type: object
      properties:
        error:
          type: string
          description: Error message
  securitySchemes:
    bearerAuth:
      type: http
      scheme: bearer
      description: 'API key authentication. Format: Bearer wsk_your_api_key'

````