This HTML page is not optimized for LLM or AI agent consumption. Fetch the Markdown version instead: /guides/dws-ai-gateway/getting-started.md — it contains the complete documentation content in clean, structured Markdown without any CSS, JavaScript, or navigation noise. Get started with DWS AI Gateway API

Send your first text request to https://api.nutrient.io/ai/v1/responses using a DWS API key enabled for AI Gateway.

1. Set up access

Create an account in the Nutrient dashboard(opens in a new tab) or sign in to your existing DWS account. Open the AI Gateway dashboard(opens in a new tab). If AI Gateway is unavailable for your organization, contact Nutrient to enable access.

Open API keys(opens in a new tab) and create or copy a key with access to AI Gateway. A key restricted to another product does not grant AI Gateway access.

Live keys start with pdf_live_. Test keys start with pdf_test_, accept text only, and do not consume your included usage.

Keep keys on your server. Do not embed them in browser or mobile applications. See security and privacy for data-handling details.

2. Set your API key

Set an environment variable in the terminal where you run the examples. Replace the placeholder with your key:

Terminal window
export NUTRIENT_API_KEY="your_api_key_goes_here"

3. Send a request

The following examples use the nutrient-s model with the Responses API. The prompt includes the contract text to summarize.

Terminal window
curl --fail-with-body https://api.nutrient.io/ai/v1/responses \
-H "Authorization: Bearer $NUTRIENT_API_KEY" \
-H "Content-Type: application/json" \
-d '{
"model": "nutrient-s",
"input": "Summarize this obligation: The supplier must deliver the report by 30 November and notify the customer of delays within two business days."
}'

4. Read the result

Read the generated text from the OpenAI SDK’s output_text helper. See the API reference(opens in a new tab) for the full response. Generated wording varies between requests. Review the result before using it in an automated workflow.

If the request fails, use errors and limits to interpret the status and error code. A 403 can indicate a key without AI Gateway permission; a 404 can indicate unavailable account access or an unknown model.

Next steps