n8n's OpenAI credential lets you set a custom base URL. Use it once and every n8n node that calls OpenAI — chat, embeddings, agents, retrievers — runs through AIgateway against any of our 1000+ models.
n8n → Credentials → New → OpenAI API. Set the base URL and paste your AIgateway key.
Set the model field to any provider/slug from the AIgateway catalog (e.g. anthropic/claude-opus-4.7).