Detect browser, OS, device and bots from any User-Agent.
Break down traffic by device & browser without cookies.
Serve different layouts to mobile vs. desktop users.
Detect bad crawlers spoofing legit browsers.
POST https://api.yeb.to/v1/device-analyze
Parameter | Type | Req. | Description |
---|---|---|---|
api_key |
string | yes | Your API key |
ua |
string | opt | User-Agent string (defaults to caller UA) |
curl -X POST https://api.yeb.to/v1/device-analyze \
-H "Content-Type: application/json" \
-d '{
"api_key": "YOUR_KEY",
"ua" : "Mozilla/5.0 (iPhone; CPU iPhone OS 17_0 like Mac OS X)..."
}'
{
"data": {
"ua_string": "Mozilla/5.0 …",
"browser": { "name": "Mobile Safari", "version": "17.0" },
"engine": { "name": "WebKit", "version": "617" },
"os": { "name": "iOS", "version": "17.0" },
"device": { "type": "mobile", "brand": "Apple", "model": "iPhone" },
"is_mobile": true,
"is_tablet": false,
"is_bot": false,
"is_desktop": false
}
}
{"error":"Missing User-Agent string","code":422}
Code | Description |
---|---|
200 Success | Request processed OK. |
400 Bad Request | Input validation failed. |
401 Unauthorized | Missing / wrong API key. |
403 Forbidden | Key inactive or not allowed. |
429 Rate Limit | Too many requests. |
500 Server Error | Unexpected failure. |