Skip to content

Connections

A connection holds the credentials needed to talk to OpenAI. A connection on its own can’t do anything — you also need at least one model configuration: a specific model registered against that connection, with its own pricing and parameter overrides. Throughout the admin, picking the connection-plus-model combination is labelled AI connection.

  • Connection name — admin label.
  • Provider — OpenAI (the only provider currently supported).
  • API key — your OpenAI secret key. Stored encrypted in the database.
  • Base URL (optional) — leave empty to use OpenAI’s default endpoint. Override only if you proxy OpenAI through your own gateway.
  • Status — automatically updated after each test call: connected / unknown / error.
  • Last tested at — timestamp of the last successful or failed test.
  • Kindchat for text generation, image_gen for image edit.
  • Model — the model identifier (e.g. gpt-4o-mini, gpt-image-1). Picked from the list returned by /v1/models.
  • Parameters — temperature, top P, max tokens. Defaults to OpenAI’s recommended values; override per use case.
  • Pricing:
    • Input per million tokens (USD)
    • Output per million tokens (USD)
    • Image edit cost (flat USD per /images/edits call)
  • Default for task types — multi-select. This model becomes the default in the AI connection dropdown for the picked task types.

The pricing fields drive the cost estimator. Keep them in sync with OpenAI’s pricing page so your statistics stay accurate.

The Add connection button on the Connections settings page opens a 3-step wizard:

  1. Credentials — connection name, provider, API key, optional base URL.
  2. Model configurations — after the credentials check, the plugin lists available models. Add one or more model configurations, each pinned to a kind (chat / image generation), a model identifier, pricing and parameters. You can also bind each model to its default task types here.
  3. Review — summary of what you’ve set up, with Test buttons per model configuration to verify credentials work end-to-end.

When editing an existing connection, the same wizard reopens pre-filled.

The connection list page supports the standard Shopware actions:

  • Add connection — open the wizard.
  • Test connection — pings OpenAI and updates the status badge.
  • Edit credentials & models — opens the wizard pre-filled.
  • Delete — only allowed if no model configuration is in use by any prompt as a default.
  • Test (per model configuration) — runs a small completion to confirm parameters and pricing work end-to-end.

You can have any number of connections — useful for separating staging from production, or for A/B comparing model behaviour without rotating keys. The AI connection dropdown across the admin shows every chat / image_gen model from every connection.