content: spin_manifest_version = 2
  
  # General identification information
  [application]
  name = "moonbit-ai-agent"
  version = "1.0.0"
  description = "An application that reviews GitHub PR upon request."
  
  # Secrets
  [variables]
  openapi_key = { required = true, secret = true }
  private_key = { required = true, secret = true }
  client_id = { required = true }
  app_id = { required = true }
  user_agent = { required = true }
  
  # The application's sole trigger. This application responds to HTTP requests
  # on the path "/...", and handles them using the "agent" component.
  [[trigger.http]]
  route = "/..."
  component = "agent"
  
  # The "agent" component
  [component.agent]
  description = "The MoonBit Agent"
  # The Wasm module to run for the component
  source = "target/agent.wasm"
  # Permitted outgoing HTTP requests
  allowed_outbound_hosts = ["https://api.github.com", "https://api.deepseek.com", "https://www.github.com", "https://api.siliconflow.cn"]
  # How to build the Wasm module from source
  [component.agent.build]
  command = """moon build --target wasm -g
  wasm-tools component embed --encoding utf16 wit target/wasm/debug/build/agent/agent.wasm --world http-trigger -o target/agent.core.wasm
  wasm-tools component new target/agent.core.wasm -o target/agent.wasm"""
  [component.agent.variables]
  open_api_key = "{{ openapi_key }}"
  private_key = "{{ private_key }}"
  client_id = "{{ client_id }}"
  app_id = "{{ app_id }}"
  user_agent = "{{ user_agent }}"
  