ai
POST /v1/ai/credentials/{credentialId}/test
Test a stored AI provider key now.
Uwierzytelnianie
Wyślij klucz API jako token bearer. Klucz musi posiadać uprawnienie billing.payment.manage; klucz bez niego jest odrzucany z kodem 403, a nie 404.
Ten punkt końcowy nie wymaga identyfikatora organizacji. Twój klucz już identyfikuje organizację, do której należy, a odpowiedź jest do niej ograniczona.
Wypróbuj
Zastąp wszystko w nawiasach ostrych własnymi wartościami, a zastępczy znacznik klucza kluczem ze swojego pulpitu nawigacyjnego.
curl -X POST https://api.zinndigital.com/v1/ai/credentials/{credentialId}/test \
-H "Authorization: Bearer zdk_live_…"Zalogowany? Konsola API w Twoim panelu uzupełnia rzeczywiste identyfikator organizacji oraz Twój własny klucz i wykonuje żądanie względem aktywnego API, dzięki czemu możesz zobaczyć rzeczywistą odpowiedź. Otwórz ten punkt końcowy w konsoli API
Szczegóły
Runs a **real, tiny completion with our own prompts and tool format** on the key — not the free authentication probe. ⚖️ The owner's requirement, verbatim: *"it must test it works with our system and prompts."* Authenticating and *working with our prompts* are different claims, and a screen showing only the first as a green tick is a control that cannot see the failure it exists to catch. Costs a fraction of a cent on the customer's own key, which is why it is only ever run on save, weekly, or when a person presses the button. Requires `billing.payment.manage`.
Parametry
| Nazwa | Typ | Wymagane | Co to jest |
|---|---|---|---|
credentialId (path) | Uuid | Tak | — |
Odpowiedź
| Nazwa | Typ | Wymagane | Co to jest |
|---|---|---|---|
ok | boolean | Tak | — |
exercised_prompt | boolean | Tak | ⭐ Whether a **real call with our own prompts** was made. `false` means we proved only that the key authenticates — a narrower claim a screen showing just "working" would erase,… |
detail | string | Nie | — |
model | string | Nie | — |
latency_ms | integer | Nie | — |
state | string<untested, working, broken> | Tak | — |
Błędy, które ten punkt końcowy może zwrócić
401 · 403 · 404 · 429