Ban a user from a group
POST
/api/v1/groups/{groupId}/ban
const url = 'http://localhost:3001/api/v1/groups/example/ban';const options = { method: 'POST', headers: {Authorization: '<Authorization>', 'Content-Type': 'application/json'}, body: '{"reason":"example","user_address":"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 http://localhost:3001/api/v1/groups/example/ban \ --header 'Authorization: <Authorization>' \ --header 'Content-Type: application/json' \ --data '{ "reason": "example", "user_address": "example" }'Add a user to a group’s ban list. Distinct from the global RBAC ban — only affects rejoin/add for this group.
Authorizations
Section titled “Authorizations”Parameters
Section titled “Parameters”Path Parameters
Section titled “Path Parameters”groupId
required
string
Group ID
Request Bodyrequired
Section titled “Request Bodyrequired”User to ban
Media typeapplication/json
object
reason
string
user_address
string
Examplegenerated
{ "reason": "example", "user_address": "example"}Responses
Section titled “Responses”Banned
Media typeapplication/json
object
key
additional properties
any
Examplegenerated
{}Unauthorized
Media typeapplication/json
object
error
string
success
boolean
Examplegenerated
{ "error": "example", "success": true}Forbidden
Media typeapplication/json
object
error
string
success
boolean
Examplegenerated
{ "error": "example", "success": true}Internal Server Error
Media typeapplication/json
object
error
string
success
boolean
Examplegenerated
{ "error": "example", "success": true}