Block a User

Block a particular User

Parameter

Accessible via URL https://api.channel.io/open/v3/users/{userId}/block and HTTP POST

Parameter

Example

Required

Description

Parameter type

userId

12345

Required

ID of User

Path

Example

POST http://api.channel.io/open/v3/users/12345/block

Response

Returns changed User object along with related information.

{
  "user": {
    "id": "String",
    "channelId": "String",
    "memberId": "String",
    "veilId": "String",
    "name": "String",
    "alert": Integer,
    "unread": Integer,
    "blocked": Boolean,
    "unsubscribed": Boolean,
    "hasChat": Boolean,
    "hasPushToken": Boolean,
    "language": "String",
    "country": "String",
    "city": "String",
    "latitude": Long,
    "longitude": Long,
    "web": {
      "device": "String",
      "os": "String",
      "osName": "String",
      "browser": "Chrome 80.0.3987.132",
      "browserName": "Chrome",
      "sessionsCount": 5,
      "lastSeenAt": 1584673657636
    },
    "sessionsCount": Integer,
    "lastSeenAt": 1584673657636,
    "createdAt": 1584145649408,
    "updatedAt": 1584934318716,
    "version": Integer,
    "member": Boolean,
    "contact": Boolean,
    "avatarUrl": "String",
    "systemLanguage": "String"
  }
}