There are 2 ways to add your OpenRouter credentials to your requests:

Add it from the UI

1

Go to the Credentials page

2

Add your OpenRouter credentials.

Add it in code

  • Add customer_credentials parameter in your request body to use your own OpenRouter credits.
{
  // Rest of the request body
  "customer_credentials": {
    "openrouter": {
      "api_key": "YOUR_OPENROUTER_API_KEY",
    }
  }
}

Full request example