logo
enes

List blocked users

Last update: 6 hours ago by Irais Aguirre

Integration summary

  • Base URL: https://{{url}}/whatsapp-bsp-admin-ext-endpoint-ws/services
  • Token: admin token, in the Authorization: Bearer {{admin-token}} header (how to generate it)
  • Endpoints on this page:
    • GET /v1/block_users/{{waba_id}}: List blocked users by WABA
    • GET /v1/block_users/{{waba_id}}/{{phone_number_id}}: List blocked users by phone number

List the blocked users of your whole WABA or of one phone number. If the request succeeds, the service returns HTTP 200 and a list of users.

List blocked users by WABA

Request

List blocked users by WABA request:

URLhttps://{{url}}/whatsapp-bsp-admin-ext-endpoint-ws/services/v1/block_users/{{waba_id}}
MethodGET

Headers

List blocked users by WABA headers:

NameDescriptionTypeRequirements
AuthorizationAdmin token. See Generate authentication token.StringRequired

Parameters

List blocked users by WABA parameters:

NameDescriptionTypeRequirements
waba_idWhatsApp Business Account ID.StringRequired
blockedFilters by status: true returns only blocked users, false returns only unblocked users. Send it as a query parameter.Boolean
  • Optional.
  • If omitted, both blocked and unblocked users are returned.

Example

Complete List blocked users by WABA example:

curl --location 'https://{{url}}/whatsapp-bsp-admin-ext-endpoint-ws/services/v1/block_users/{{waba_id}}?blocked=true' \
--header 'Authorization: Bearer {{admin-token}}'

Response

List blocked users by WABA response:

Applies to both the WABA and the phone number queries. The service returns HTTP 200 and a list of users.

NameDescriptionType
phone_number_idID of the phone number that blocked the user. Only included in the WABA query.String
inputIdentifier used in the block request.String
statusThe user's current status. Possible values:
  • BLOCKED
  • UNLOCKED
  • FAILED (only appears when the blocked parameter is omitted)
String
[
{
"phone_number_id": "1234567890",
"input": "521550123456",
"status": "BLOCKED"
},
{
"phone_number_id": "1234567890",
"input": "US.13491208655302741918",
"status": "BLOCKED"
}
]


List blocked users by phone number

Request

List blocked users by phone number request:

URLhttps://{{url}}/whatsapp-bsp-admin-ext-endpoint-ws/services/v1/block_users/{{waba_id}}/{{phone_number_id}}
MethodGET

Headers

List blocked users by phone number headers:

NameDescriptionTypeRequirements
AuthorizationAdmin token. See Generate authentication token.StringRequired

Parameters

List blocked users by phone number parameters:

NameDescriptionTypeRequirements
waba_idWhatsApp Business Account ID.StringRequired
phone_number_idID of the phone number to query.StringRequired
blockedFilters by status: true returns only blocked users, false returns only unblocked users. Send it as a query parameter.Boolean
  • Optional.
  • If omitted, both blocked and unblocked users are returned.

Example

Complete List blocked users by phone number example:

curl --location 'https://{{url}}/whatsapp-bsp-admin-ext-endpoint-ws/services/v1/block_users/{{waba_id}}/{{phone_number_id}}?blocked=true' \
--header 'Authorization: Bearer {{admin-token}}'

Response

List blocked users by phone number response:

Applies to both the WABA and the phone number queries. The service returns HTTP 200 and a list of users.

NameDescriptionType
phone_number_idID of the phone number that blocked the user. Only included in the WABA query.String
inputIdentifier used in the block request.String
statusThe user's current status. Possible values:
  • BLOCKED
  • UNLOCKED
  • FAILED (only appears when the blocked parameter is omitted)
String
[
{
"input": "521550123456",
"status": "BLOCKED"
},
{
"input": "US.13491208655302741918",
"status": "BLOCKED"
}
]

Previous
Block and unblock users
Next
Error codes