Test a connection
const url = 'https://example.com/api/v1/connections/example/test';const options = { method: 'POST', headers: {cookie: 'bl_%3Cslug%3E_session=%3Cbl_%3Cslug%3E_session%3E'}};
try { const response = await fetch(url, options); const data = await response.json(); console.log(data);} catch (error) { console.error(error);}curl --request POST \ --url https://example.com/api/v1/connections/example/test \ --cookie bl_%3Cslug%3E_session=%3Cbl_%3Cslug%3E_session%3ETests the whole chain with one small read, as an application would: our gateway, the provider’s data plane (or its supplier’s), and the system behind it. It is a real request within the agreement, recorded like any other (decisions #78).
Authorizations
Section titled “Authorizations”Parameters
Section titled “Parameters”Path Parameters
Section titled “Path Parameters”The alias of the connection: the name in its gateway address.
Responses
Section titled “Responses”The outcome, also when the test failed (ok: false).
The outcome of a connection test, as the UI shows it.
object
Where it stopped: connection (not active), own (our data plane),
counterparty (theirs), agreement, backend or other.
Milliseconds.
How many points the discovery listed.
The request as an application makes it, without the key: method, url.
What came back: status, content_type, body (at most 64 KiB), bytes, truncated.
Example generated
{ "ok": true, "stage": "example", "status": 1, "ms": 1, "message": "example", "points": 1, "request": "example", "response": "example"}No valid session, DPoP-bound token or API key.
The body of every failed call to a management API.
object
object
Stable, machine-readable: invalid_request, unauthenticated,
forbidden, not_found, conflict, upstream_unavailable,
unavailable, internal, or a more specific code of the operation.
For people; may change between versions.
Example
{ "error": { "code": "not_found", "message": "unknown negotiation" }}The caller lacks the role this operation needs; or a change with the session cookie came from a page of another site (cross_site_request, decisions #83).
The body of every failed call to a management API.
object
object
Stable, machine-readable: invalid_request, unauthenticated,
forbidden, not_found, conflict, upstream_unavailable,
unavailable, internal, or a more specific code of the operation.
For people; may change between versions.
Example
{ "error": { "code": "not_found", "message": "unknown negotiation" }}Not found.
The body of every failed call to a management API.
object
object
Stable, machine-readable: invalid_request, unauthenticated,
forbidden, not_found, conflict, upstream_unavailable,
unavailable, internal, or a more specific code of the operation.
For people; may change between versions.
Example
{ "error": { "code": "not_found", "message": "unknown negotiation" }}