Add connection
Creates the new connection in the xpipe vault from raw json data. This can also perform an optional validation first to make sure that the connection can be established. If an equivalent connection already exists, no new one will be added.
Authorization
bearerAuth The bearer token used is the session token that you receive from the handshake exchange.
In: header
Request Body
application/json
The connection name
The raw connection store data. Schemas for connection types are not documented, but you can find the connection data of your existing connections in the xpipe vault.
Whether to perform a connection validation before adding it, i.e., probe the connection first. If validation is enabled and fails, the connection will not be added
The category uuid to put the connection in. If not specified, the default category will be used
Response Body
application/json
application/json
application/json
curl -X POST "http://localhost:21721/connection/add" \ -H "Content-Type: application/json" \ -d '{ "name": "my connection", "validate": true, "category": "97458c07-75c0-4f9d-a06e-92d8cdf67c40", "data": { "type": "shellEnvironment", "commands": null, "host": "f0ec68aa-63f5-405c-b178-9a4454556d6b", "shell": "pwsh", "elevated": false } }'{
"connection": "36ad9716-a209-4f7f-9814-078d3349280c"
}{
"message": "string"
}{
"error": {
"cause": {},
"stackTrace": [],
"suppressed": [],
"localizedMessage": "string",
"message": "string"
}
}