{
  "openapi": "3.0.1",
  "info": {
    "title": "Unity Ai Assistant",
    "description": "AI-powered Unity development assistant running as an mcp Actor. Generate C# scripts, create shaders, query LLMs (GPT-4, Claude, Gemini), analyze code, and manage Unity Cloud Services - all through a simple API.",
    "version": "1.0",
    "x-build-id": "ANbZLYJvX6BYpFdUJ"
  },
  "servers": [
    {
      "url": "https://api.apify.com/v2"
    }
  ],
  "paths": {
    "/acts/syntellect_ai~unity-ai-assistant/run-sync-get-dataset-items": {
      "post": {
        "operationId": "run-sync-get-dataset-items-syntellect_ai-unity-ai-assistant",
        "x-openai-isConsequential": false,
        "summary": "Executes an Actor, waits for its completion, and returns Actor's dataset items in response.",
        "tags": [
          "Run Actor"
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/inputSchema"
              }
            }
          }
        },
        "parameters": [
          {
            "name": "token",
            "in": "query",
            "required": true,
            "schema": {
              "type": "string"
            },
            "description": "Enter your Apify token here"
          }
        ],
        "responses": {
          "200": {
            "description": "OK"
          }
        }
      }
    },
    "/acts/syntellect_ai~unity-ai-assistant/runs": {
      "post": {
        "operationId": "runs-sync-syntellect_ai-unity-ai-assistant",
        "x-openai-isConsequential": false,
        "summary": "Executes an Actor and returns information about the initiated run in response.",
        "tags": [
          "Run Actor"
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/inputSchema"
              }
            }
          }
        },
        "parameters": [
          {
            "name": "token",
            "in": "query",
            "required": true,
            "schema": {
              "type": "string"
            },
            "description": "Enter your Apify token here"
          }
        ],
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/runsResponseSchema"
                }
              }
            }
          }
        }
      }
    },
    "/acts/syntellect_ai~unity-ai-assistant/run-sync": {
      "post": {
        "operationId": "run-sync-syntellect_ai-unity-ai-assistant",
        "x-openai-isConsequential": false,
        "summary": "Executes an Actor, waits for completion, and returns the OUTPUT from Key-value store in response.",
        "tags": [
          "Run Actor"
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/inputSchema"
              }
            }
          }
        },
        "parameters": [
          {
            "name": "token",
            "in": "query",
            "required": true,
            "schema": {
              "type": "string"
            },
            "description": "Enter your Apify token here"
          }
        ],
        "responses": {
          "200": {
            "description": "OK"
          }
        }
      }
    }
  },
  "components": {
    "schemas": {
      "inputSchema": {
        "type": "object",
        "required": [
          "operation"
        ],
        "properties": {
          "operation": {
            "title": "Operation",
            "enum": [
              "generate_script",
              "create_shader",
              "analyze_gameobject",
              "optimize_prefab",
              "query_llm",
              "code_completion",
              "analyze_code",
              "text_to_speech",
              "npc_dialogue",
              "translate_ui",
              "vision_analysis",
              "deploy_cloud_code",
              "manage_remote_config",
              "query_analytics"
            ],
            "type": "string",
            "description": "The AI operation to perform",
            "default": "generate_script"
          },
          "scriptDescription": {
            "title": "Script Description",
            "type": "string",
            "description": "What the script should do (for generate_script)"
          },
          "scriptName": {
            "title": "Script Name",
            "type": "string",
            "description": "Name of the script class"
          },
          "shaderName": {
            "title": "Shader Name",
            "type": "string",
            "description": "Name of the shader (for create_shader)"
          },
          "shaderType": {
            "title": "Shader Type",
            "enum": [
              "Surface",
              "Unlit",
              "Lit"
            ],
            "type": "string",
            "description": "Type of shader",
            "default": "Lit"
          },
          "renderPipeline": {
            "title": "Render Pipeline",
            "enum": [
              "Built-in",
              "URP",
              "HDRP"
            ],
            "type": "string",
            "description": "Unity render pipeline",
            "default": "URP"
          },
          "gameObjectName": {
            "title": "GameObject Name",
            "type": "string",
            "description": "Name of GameObject to analyze"
          },
          "prefabName": {
            "title": "Prefab Name",
            "type": "string",
            "description": "Name of prefab to optimize"
          },
          "targetPlatform": {
            "title": "Target Platform",
            "enum": [
              "Windows",
              "macOS",
              "Linux",
              "Android",
              "iOS",
              "WebGL"
            ],
            "type": "string",
            "description": "Unity target platform",
            "default": "Windows"
          },
          "llmModel": {
            "title": "LLM Model",
            "enum": [
              "gpt-4",
              "gpt-3.5-turbo",
              "claude-3-opus",
              "claude-3-sonnet",
              "gemini-pro"
            ],
            "type": "string",
            "description": "Language model to use (for query_llm)",
            "default": "gpt-4"
          },
          "llmPrompt": {
            "title": "LLM Prompt",
            "type": "string",
            "description": "Question or prompt for the LLM"
          },
          "codeToAnalyze": {
            "title": "Code to Analyze",
            "type": "string",
            "description": "C# code to analyze or complete"
          },
          "textToSpeak": {
            "title": "Text to Speak",
            "type": "string",
            "description": "Text to convert to speech"
          },
          "textsToTranslate": {
            "title": "Texts to Translate",
            "type": "array",
            "description": "UI texts to translate"
          },
          "targetLanguages": {
            "title": "Target Languages",
            "type": "array",
            "description": "Language codes to translate to",
            "items": {
              "type": "string"
            }
          },
          "unityProjectId": {
            "title": "Unity Project ID",
            "type": "string",
            "description": "Unity Cloud Project ID (for cloud operations)"
          },
          "openaiApiKey": {
            "title": "OpenAI API Key",
            "type": "string",
            "description": "OpenAI API key (optional, for LLM operations)"
          },
          "anthropicApiKey": {
            "title": "Anthropic API Key",
            "type": "string",
            "description": "Anthropic API key (optional, for Claude)"
          },
          "googleApiKey": {
            "title": "Google API Key",
            "type": "string",
            "description": "Google API key (optional, for Gemini)"
          }
        }
      },
      "runsResponseSchema": {
        "type": "object",
        "properties": {
          "data": {
            "type": "object",
            "properties": {
              "id": {
                "type": "string"
              },
              "actId": {
                "type": "string"
              },
              "userId": {
                "type": "string"
              },
              "startedAt": {
                "type": "string",
                "format": "date-time",
                "example": "2025-01-08T00:00:00.000Z"
              },
              "finishedAt": {
                "type": "string",
                "format": "date-time",
                "example": "2025-01-08T00:00:00.000Z"
              },
              "status": {
                "type": "string",
                "example": "READY"
              },
              "meta": {
                "type": "object",
                "properties": {
                  "origin": {
                    "type": "string",
                    "example": "API"
                  },
                  "userAgent": {
                    "type": "string"
                  }
                }
              },
              "stats": {
                "type": "object",
                "properties": {
                  "inputBodyLen": {
                    "type": "integer",
                    "example": 2000
                  },
                  "rebootCount": {
                    "type": "integer",
                    "example": 0
                  },
                  "restartCount": {
                    "type": "integer",
                    "example": 0
                  },
                  "resurrectCount": {
                    "type": "integer",
                    "example": 0
                  },
                  "computeUnits": {
                    "type": "integer",
                    "example": 0
                  }
                }
              },
              "options": {
                "type": "object",
                "properties": {
                  "build": {
                    "type": "string",
                    "example": "latest"
                  },
                  "timeoutSecs": {
                    "type": "integer",
                    "example": 300
                  },
                  "memoryMbytes": {
                    "type": "integer",
                    "example": 1024
                  },
                  "diskMbytes": {
                    "type": "integer",
                    "example": 2048
                  }
                }
              },
              "buildId": {
                "type": "string"
              },
              "defaultKeyValueStoreId": {
                "type": "string"
              },
              "defaultDatasetId": {
                "type": "string"
              },
              "defaultRequestQueueId": {
                "type": "string"
              },
              "buildNumber": {
                "type": "string",
                "example": "1.0.0"
              },
              "containerUrl": {
                "type": "string"
              },
              "usage": {
                "type": "object",
                "properties": {
                  "ACTOR_COMPUTE_UNITS": {
                    "type": "integer",
                    "example": 0
                  },
                  "DATASET_READS": {
                    "type": "integer",
                    "example": 0
                  },
                  "DATASET_WRITES": {
                    "type": "integer",
                    "example": 0
                  },
                  "KEY_VALUE_STORE_READS": {
                    "type": "integer",
                    "example": 0
                  },
                  "KEY_VALUE_STORE_WRITES": {
                    "type": "integer",
                    "example": 1
                  },
                  "KEY_VALUE_STORE_LISTS": {
                    "type": "integer",
                    "example": 0
                  },
                  "REQUEST_QUEUE_READS": {
                    "type": "integer",
                    "example": 0
                  },
                  "REQUEST_QUEUE_WRITES": {
                    "type": "integer",
                    "example": 0
                  },
                  "DATA_TRANSFER_INTERNAL_GBYTES": {
                    "type": "integer",
                    "example": 0
                  },
                  "DATA_TRANSFER_EXTERNAL_GBYTES": {
                    "type": "integer",
                    "example": 0
                  },
                  "PROXY_RESIDENTIAL_TRANSFER_GBYTES": {
                    "type": "integer",
                    "example": 0
                  },
                  "PROXY_SERPS": {
                    "type": "integer",
                    "example": 0
                  }
                }
              },
              "usageTotalUsd": {
                "type": "number",
                "example": 0.00005
              },
              "usageUsd": {
                "type": "object",
                "properties": {
                  "ACTOR_COMPUTE_UNITS": {
                    "type": "integer",
                    "example": 0
                  },
                  "DATASET_READS": {
                    "type": "integer",
                    "example": 0
                  },
                  "DATASET_WRITES": {
                    "type": "integer",
                    "example": 0
                  },
                  "KEY_VALUE_STORE_READS": {
                    "type": "integer",
                    "example": 0
                  },
                  "KEY_VALUE_STORE_WRITES": {
                    "type": "number",
                    "example": 0.00005
                  },
                  "KEY_VALUE_STORE_LISTS": {
                    "type": "integer",
                    "example": 0
                  },
                  "REQUEST_QUEUE_READS": {
                    "type": "integer",
                    "example": 0
                  },
                  "REQUEST_QUEUE_WRITES": {
                    "type": "integer",
                    "example": 0
                  },
                  "DATA_TRANSFER_INTERNAL_GBYTES": {
                    "type": "integer",
                    "example": 0
                  },
                  "DATA_TRANSFER_EXTERNAL_GBYTES": {
                    "type": "integer",
                    "example": 0
                  },
                  "PROXY_RESIDENTIAL_TRANSFER_GBYTES": {
                    "type": "integer",
                    "example": 0
                  },
                  "PROXY_SERPS": {
                    "type": "integer",
                    "example": 0
                  }
                }
              }
            }
          }
        }
      }
    }
  }
}