> ## Documentation Index
> Fetch the complete documentation index at: https://developer.jtl-software.com/llms.txt
> Use this file to discover all available pages before exploring further.

# TestShopConnection

> Runs a live connection and credentials test against a Wawi-managed webshop and reports the verdict. Mirrors the 'Verbindung testen' button of the WPF Verkaufskanalverwaltung. It contacts the shop with the stored synchronisation credentials and therefore validates reachability AND credentials in one call. Credentials are never accepted from the caller: they are read server-side from the shop record addressed by salesChannelId, so a caller can only test credentials that are already stored. Two properties are deliberate: (1) A completed test always answers HTTP 200, including when the shop is unreachable or rejects the credentials - an unreachable shop is a successful test with a negative verdict, reported through Status, not a failed request. No 502 and no 504 is therefore declared. (2) It is a POST behind saleschannels.write although its name suggests a read, because running the test updates the shop's stored connection state on every call; callers should not poll it in a loop. The test is bounded by an internal timeout well below the platform request timeout, so a slow or unreachable shop returns Status = TimedOut rather than letting the platform timeout fire; there is no SSE, so the check is synchronous by design.

If a request with this mutation's Idempotency-Key was already completed, the response's `extensions` contains an `idempotency.{responseName}` entry with `wasReplayed: true`.



**mutation** `TestShopConnection(request: TestShopConnectionCommandRequestInput!): ShopConnectionTestResult!`

## Arguments

**`request`**: `TestShopConnectionCommandRequestInput!` (required)

## Returns

`ShopConnectionTestResult!`

**`status`**: `ShopConnectionTestStatus!`

The verdict. Status == Succeeded is the equivalent of the WPF IsAuthentificationValid flag. Note that REST transports this as the raw numeric enum value (the API registers no StringEnumConverter), while GraphQL renders it as SCREAMING_SNAKE_CASE.

---

**`latencyMs`**: `Long`

Wall-clock duration of the outbound test in milliseconds, measured by this endpoint around the call to the shop. Null when no call was attempted (Status = NotConfigured). Diagnostic only - not an SLA and not comparable across networks.

---

**`shopVersion`**: `String`

The shop's own version token as reported by its synchronisation interface, verbatim and unnormalized (the shop returns e.g. '503' for version 5.03). Null unless the shop got far enough to report one, which in practice means Status = Succeeded.

---

**`errorCode`**: `String`

Stable machine-readable failure code, or null on success: shop-authentication-failed, shop-unreachable, shop-connection-timed-out, shop-incompatible-version, shop-invalid-response, shop-not-configured. Prefer this over parsing Message.

---

**`message`**: `String`

Human-readable, English, status-derived description of the failure, or null on success. Diagnostic only - not stable, not localized, and must not be parsed. Deliberately never the raw text the shop or the JTL license server returned.

