-
Notifications
You must be signed in to change notification settings - Fork 0
Open
Labels
Description
Description
Implement a bulk IP processing API to handle multiple IP addresses in a single request, enabling efficient processing of large IP datasets.
Requirements
- Batch IP lookup endpoint:
/api/ip/bulk- Process multiple IPs in a single request - Multiple input formats: Support JSON array, CSV, and plain text formats
- File upload support: Accept file uploads for bulk processing (CSV/JSON/TXT)
- Async processing: Handle large batches asynchronously with job tracking
- Result aggregation: Return consolidated results in structured format
- Rate limiting: Implement different rate limits for bulk vs single requests
- Progress tracking: Provide status updates for long-running batch jobs
- Error handling: Handle individual IP failures gracefully without stopping the entire batch
API Endpoints
POST /api/ip/bulk- Submit bulk IP processing jobGET /api/ip/bulk/{jobId}- Check processing statusGET /api/ip/bulk/{jobId}/results- Download results
Example Request
{
"ips": [
"203.0.113.1",
"2001:db8::1",
"192.168.1.1"
],
"includeGeolocation": true,
"includeSecurity": false,
"format": "json"
}Example Response
{
"jobId": "bulk-12345",
"status": "completed",
"totalIps": 3,
"processedIps": 3,
"failedIps": 0,
"results": [
{
"ip": "203.0.113.1",
"ipv4": "203.0.113.1",
"geolocation": { ... }
}
]
}Implementation Notes
- Support processing up to 10,000 IPs per batch
- Implement job queuing with Redis or similar
- Add webhook notifications for job completion
- Include comprehensive error reporting
- Ensure high performance for large datasets
Reactions are currently unavailable