Remove Peer
POST
/cluster/remove-node
const url = 'https://sylve.lan:8181/api/cluster/remove-node';const options = { method: 'POST', headers: {Authorization: '<Authorization>', 'Content-Type': 'application/json'}, body: '{"nodeId":"example"}'};
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://sylve.lan:8181/api/cluster/remove-node \ --header 'Authorization: <Authorization>' \ --header 'Content-Type: application/json' \ --data '{ "nodeId": "example" }'Ask an online peer to fence local work, leave Raft, and clear its cluster state
Authorizations
Section titled “Authorizations”Request Body
Section titled “Request Body”Remove Peer Request
Media typeapplication/json
object
nodeId
required
string
Examplegenerated
{ "nodeId": "example"}Responses
Section titled “Responses”Success
Media typeapplication/json
object
data
object
cleanupAcknowledged
boolean
membershipRemoved
boolean
status
object
attempts
integer
enabled
boolean
lastError
string
leaderIp
string
leaveId
string
localNodeId
string
phase
string
error
string
message
string
status
string
Examplegenerated
{ "data": { "cleanupAcknowledged": true, "membershipRemoved": true, "status": { "attempts": 1, "enabled": true, "lastError": "example", "leaderIp": "example", "leaveId": "example", "localNodeId": "example", "phase": "example" } }, "error": "example", "message": "example", "status": "example"}Bad Request
Media typeapplication/json
object
data
error
string
message
string
status
string
Examplegenerated
{ "data": "example", "error": "example", "message": "example", "status": "example"}Unauthorized
Media typeapplication/json
object
data
error
string
message
string
status
string
Examplegenerated
{ "data": "example", "error": "example", "message": "example", "status": "example"}Forbidden
Media typeapplication/json
object
data
error
string
message
string
status
string
Examplegenerated
{ "data": "example", "error": "example", "message": "example", "status": "example"}Peer owns cluster resources
Media typeapplication/json
object
data
object
dependencies
Array<object>
object
id
string
kind
string
name
string
role
string
state
string
nodeId
string
error
string
message
string
status
string
Examplegenerated
{ "data": { "dependencies": [ { "id": "example", "kind": "example", "name": "example", "role": "example", "state": "example" } ], "nodeId": "example" }, "error": "example", "message": "example", "status": "example"}Internal Server Error
Media typeapplication/json
object
data
error
string
message
string
status
string
Examplegenerated
{ "data": "example", "error": "example", "message": "example", "status": "example"}Service Unavailable
Media typeapplication/json
object
data
error
string
message
string
status
string
Examplegenerated
{ "data": "example", "error": "example", "message": "example", "status": "example"}