---
title: "Create Playground Prompt"
method: POST
path: "/projects/{project_id}/playgrounds/{playground_id}/prompts"
tags: ["playground_prompts"]
---

# Create Playground Prompt

`POST /projects/{project_id}/playgrounds/{playground_id}/prompts`

## Request

- Base URL: `https://api.galileo.ai`
- URL: `https://api.galileo.ai/projects/{project_id}/playgrounds/{playground_id}/prompts`
- Auth: one of:
  - API key in header `Splunk-AO-API-Key`
  - API key in header `Galileo-API-Key`
  - OAuth 2
    - Password
    - Token URL: `https://api.galileo.ai/login`
  - HTTP basic

Add a prompt to a playground.

Args:
    ctx: Async request context supplying the read session and current user.
    principal: Caller the base template's permissions are resolved for.
    playground: Playground resolved from the URL, verified to belong to the URL project.
    create_request: Optional prompt to copy the template, settings and raw flag from.

Returns:
    The created prompt.

## Path parameters

- `project_id` string, uuid4, required
- `playground_id` string, uuid4, required

## Request body

- CreatePlaygroundPromptRequest
  - `playground_prompt_id` string, uuid4, nullable: If provided, the new prompt will be a copy of the existing one.

## Response `200`

Successful Response

- PlaygroundPromptResponse
  - `id` string, uuid4, required
  - `base_prompt` BasePrompt, required
    - `id` string, uuid4, required
    - `permissions` Permission[]
      - `action` union, required
        - 'update' | 'delete' | 'read_api_keys' | 'change_role_to_admin' | 'change_role_to_manager' | 'change_role_to_user' | 'change_role_to_read_only' | 'change_role_to_capability_based'
        - 'update' | 'list_members' | 'join' | 'request_to_join'
        - 'update_role' | 'delete'
        - 'read_all_logs' | 'read_filtered_logs' | 'delete' | 'rename' | 'share' | 'create_run' | 'delete_run' | 'rename_run' | 'move_run' | 'export_data' | 'configure_human_feedback' | 'record_human_feedback' | 'log_data' | 'toggle_metric' | 'edit_alert' | 'create_stage' | 'edit_stage' | 'configure_crown_logic' | 'configure_rate_limit' | 'delete_data' | 'set_metric' | 'edit_run_tags' | 'dismiss_alert' | 'edit_slice' | 'edit_edit' | 'update_control_bindings' | 'use_control_runtime'
        - 'create_shared' | 'create_global' | 'update' | 'delete' | 'share' | 'export' | 'autotune_apply'
        - 'update' | 'delete'
        - 'update' | 'delete'
        - 'update' | 'delete'
        - 'update' | 'delete'
        - 'update' | 'delete' | 'share' | 'export' | 'rename'
        - 'update' | 'delete' | 'share' | 'read_secrets'
        - 'rename' | 'delete' | 'delete_log_data' | 'read_settings' | 'update_settings' | 'read_cost_settings' | 'read_ai_usage' | 'read_ai_usage_organization' | 'read_unredacted_data'
        - 'update' | 'delete' | 'share' | 'record_annotation'
        - 'create' | 'read' | 'update' | 'delete': Actions on Agent Control's org-scoped ``control`` resource.
      - `allowed` boolean, required
      - `message` string, nullable
    - `version` integer, required
    - `version_id` string, uuid4, required
    - `name` string, required
    - `template` string, required
    - `settings` PromptRunSettingsOutput: Prompt run settings.
      - `logprobs` boolean
      - `top_logprobs` integer
      - `echo` boolean
      - `n` integer
      - `reasoning_effort` string
      - `verbosity` string
      - `deployment_name` string, nullable
      - `model_alias` string
      - `temperature` number, nullable
      - `max_tokens` integer
      - `stop_sequences` string[], nullable
      - `top_p` number
      - `top_k` integer
      - `frequency_penalty` number
      - `presence_penalty` number
      - `tools` string
      - `tool_choice` union
        - string
        - OpenAIToolChoice
          - `type` string
          - `function` OpenAIFunction, required
            - `name` string, required
      - `response_format` object, nullable
    - `raw` boolean
  - `template` string, nullable: Overrides the base prompt template if set.
  - `settings` PromptRunSettingsOutput: Prompt run settings.
    - `logprobs` boolean
    - `top_logprobs` integer
    - `echo` boolean
    - `n` integer
    - `reasoning_effort` string
    - `verbosity` string
    - `deployment_name` string, nullable
    - `model_alias` string
    - `temperature` number, nullable
    - `max_tokens` integer
    - `stop_sequences` string[], nullable
    - `top_p` number
    - `top_k` integer
    - `frequency_penalty` number
    - `presence_penalty` number
    - `tools` string
    - `tool_choice` union
      - string
      - OpenAIToolChoice
        - `type` string
        - `function` OpenAIFunction, required
          - `name` string, required
    - `response_format` object, nullable
  - `raw` boolean, required
  - `position` integer, required
  - `run_id` string, uuid4, nullable

## Other responses

- `422`: Validation Error

## Changes

> 34 revisions in range; 2 not diffed.

- **2026-10-19** `0b20eade6391`: 2 warning
  - added the new `read_all_logs` enum value to the `base_prompt/anyOf[subschema #1: BasePrompt]/permissions/items/action/anyOf[subschema #4: ProjectAction]/` response property for the response status `200`
  - added the new `read_filtered_logs` enum value to the `base_prompt/anyOf[subschema #1: BasePrompt]/permissions/items/action/anyOf[subschema #4: ProjectAction]/` response property for the response status `200`
- **2026-09-24** `2bc86a55558e`: 1 warning
  - added the new `configure_rate_limit` enum value to the `base_prompt/anyOf[subschema #1: BasePrompt]/permissions/items/action/anyOf[subschema #4: ProjectAction]/` response property for the response status `200`
- **2026-09-02** `4bc031507246`: 3 warning
  - added the new `change_role_to_capability_based` enum value to the `base_prompt/anyOf[subschema #1: BasePrompt]/permissions/items/action/anyOf[subschema #1: UserAction]/` response property for the response status `200`
  - added the new `create_global` enum value to the `base_prompt/anyOf[subschema #1: BasePrompt]/permissions/items/action/anyOf[subschema #5: ScorerAction]/` response property for the response status `200`
  - added the new `create_shared` enum value to the `base_prompt/anyOf[subschema #1: BasePrompt]/permissions/items/action/anyOf[subschema #5: ScorerAction]/` response property for the response status `200`
- …earlier changes not shown

[Operation history](https://skmtc.dev/galileo/apis/galileo-api-server/changes/projects/:project_id/playgrounds/:playground_id/prompts/post.md)

---

[API](https://skmtc.dev/galileo/apis/galileo-api-server.md) - [All operations](https://skmtc.dev/galileo/apis/galileo-api-server/llms.txt) - [OpenAPI document](https://skmtc.dev/galileo/apis/galileo-api-server/revisions/a289cea1b504?raw)
