Unblock an IP address
POST
/api/users/[user_id]/blocked_ips/unblock
Removes the block on a specified IP address associated with the user, restoring the ability for the IP address to authenticate the user. If 'all' is passed in the IP address field, all blocked IP addresses associated with the user will be unblocked.
Path Parameters
user_id
string
Required
The ID of the user whose IP address should be unblocked.
Body Parameters
ip_address
string
Required
The IP address to be unblocked. Use 'all' to unblock all IP addresses associated with the user.
Authentication
X-API-KEY
header
Required
The API key is essential for accessing MonoCloud's APIs. You can find it in the Tenant Settings section of your MonoCloud dashboard. To authenticate your requests, include this key in the request header using the following format: X-API-Key: <Your_API_Key>.
Headers
content-type
string
- application/json
accept
string
- application/json
- application/problem+json
Responses
200
Successfully unblocked an IP address
400
Bad Request
422
Client Error
404
Not Found
401
Unauthorized
403
Forbidden
Request Example
Request
curl -X POST "https://<your-domain>/api/users/{user_id}/blocked_ips/unblock" \
-H "X-API-KEY: <your-api-key>" \
-H "Accept: application/json" \
-H "Content-Type: application/json" \
--data-raw '{
"ip_address" : "127.0.0.1"
}'
Response Example
Response
200 OK
{
"creation_time": 1640975400,
"passkeys": [
{
"public_key": "MIICYzCCAcygAwIBAgIBADAMQwwCgYDVQBgQD2bZEoZXIgZm9yIE9TLzM5MCAoUkFDRikwDgYDVR0PAQH/BAQDAgAGMA8GA1UdEwEB/wQFMAMB6Vf1nYi/rO+ryMO",
"backup_state": true,
"user_present": true,
"backup_eligibility": true,
"aa_guid": "204a871f-f7c4-465c-a81f-83d7ad4d04ee",
"name": "IPhone 15 Pro Max",
"passkey_id": "sM5X24vn_R3YqFvk8o5Hf7l3E1fMeyKnssiAgCYxouA",
"user_agent": "Mozilla/5.0 (Macintosh; Intel Mac OS X 10.15; rv:127.0) Gecko/20100101 Firefox/127.0",
"user_verified": true
}
],
"last_updated": 1640975400,
"private_data": {
"transaction_ids": [
"5GRZ4X7XUItpRGOwkHhONqTtG",
"9Fw7Jx9Zja5lWlmRkYJf1WMV9"
],
"subscription_plan": "premium",
"last_renewed": 1672511400
},
"idps": [
{
"provider_user_id": "79a500f9-aba6-4f03-baec-c18f4b7136ad",
"claims": {
"email": "user@example.com",
"email_verified": "true",
"name": "John Doe"
},
"authenticator": "google"
}
],
"emails": [
{
"authenticators": [
"password",
"email"
],
"verified": true,
"id": "6cec8047-6149-4d9b-8d99-91c83c22a9dc",
"email": "user@example.com",
"primary": false,
"idps": [
"monocloud",
"google"
]
}
],
"phone_numbers": [
{
"phone": "+441514960453",
"authenticators": [
"password",
"phone"
],
"verified": true,
"id": "ab66b6a2-df6b-4f9d-9eb2-5a7142984e70",
"primary": false,
"idps": [
"monocloud",
"google"
]
}
],
"password_updated_at": 1640975400,
"user_id": "UOtBaOybB6dTpIJNrnkRw",
"claims": {
"name": "John Doe",
"given_name": "John",
"family_name": "Doe"
},
"public_data": {
"color_preference": {
"dashboard": "monochrome"
},
"send_emails": true,
"days_to_retain": 1
},
"disabled": true,
"username": {
"authenticators": [
"password"
],
"id": "9082b772-dbf6-4610-a71e-05fb93c0ab73",
"idps": [
"monocloud",
"google"
],
"username": "username"
},
"has_password": true
}