Get Blacklisted IPs API
POST /getBlacklistedIPs
Description
This endpoint retrieves a list of IP addresses that have been blacklisted.
Request
Endpoint: /getBlacklistedIPs
Method: POST
Body:
query getBlacklistedIPs {
    getBlacklistedIPs {
        id
        ipAddress
    }
}
GraphQL Variables:
{}
Example Request
cURL:
curl --location 'YOUR_API_ENDPOINT' \
--header 'Content-Type: application/json' \
--data '{"query":"query getBlacklistedIPs {\n    getBlacklistedIPs {\n        id\n        ipAddress\n    }\n}","variables":{}}'
Response
The response will include a list of blacklisted IP addresses with the following fields:
- id: Unique identifier of the blacklist record.
- ipAddress: The IP address that has been blacklisted.
Errors
- 500 Internal Server Error: Server error while processing the request.
- 403 Forbidden: User does not have permission to view blacklisted IPs.
Notes
- This endpoint returns all IP addresses that are currently blacklisted. Ensure you have appropriate permissions to access this data.
- If your application has a large number of blacklisted IPs, consider implementing pagination to manage the dataset efficiently.
- Blacklisting is usually done to prevent known malicious IPs from accessing the system. Regularly review and update the list as necessary.