Body
This is the lighthouse batch test body object
-
urls array[string]
For multiple-urls batch type, provide an array of urls to test. For other batch types, provide a single url in array and if multiple urls are provided, only first in the list will be used for the test. All invalid urls in the array will be ignored.
Maximum length of each is
5000
. -
devices array[string]
For multiple-devices batch type, provide an array of device ids to test or leave it empty for testing on all preset devices. For other batch types, provide a single device id in array and if multiple device ids are provided, only first in the list will be used for the test. All invalid device ids in the array will be ignored.
Values are
mobile
,desktop
,macbookAirM1
,highEndLaptop
,ipad102
,galaxyTabS7
,iphone13ProMax
,iphone11
,galaxyS10Plus
,redmiNote8Pro
,iphone7
,galaxyA50
,galaxyJ8
,motoG5
, orredmi5A
. -
locations array[string]
For multiple-locations batch type, provide an array of location ids to test or leave it empty for testing on all preset locations. For other batch types, provide just a single location id in array and if multiple location ids are provided, only first in the list will be used for the test. All invalid location ids in the array will be ignored.
Values are
us
,ca
,br
,de
,uk
,nl
,pl
,ch
,jp
,in
,sg
,au
,id
,kr
, ortw
. -
batch_type string
The type of batch test to run
Values are
multiple-urls
,multiple-devices
, ormultiple-locations
. -
config object
curl \
-X POST https://api.speedvitals.com/v1/lighthouse-batch-tests \
-H "X-API-KEY: $API_KEY" \
-H "Content-Type: application/json" \
-d '{"urls":["https://speedvitals.com","https://blog.speedvitals.com"],"devices":["macbookAirM1"],"locations":["us"],"batch_type":"multiple-urls"}'
{
"urls": [
"https://speedvitals.com",
"https://blog.speedvitals.com"
],
"devices": [
"macbookAirM1"
],
"locations": [
"us"
],
"batch_type": "multiple-urls"
}
{
"urls": [
"string"
],
"devices": [
"macbookAirM1"
],
"locations": [
"us"
],
"batch_type": "multiple-urls",
"config": {
"connection": "fiber",
"throttling_method": "simulated",
"http_version": "2",
"video": false,
"adblock": false,
"user_agent": "string",
"auth_username": "string",
"auth_password": "string",
"cookies": [
"string"
],
"whitelist": [
"string"
],
"blacklist": [
"string"
]
}
}
{
"id": "lbt_IU8rN0XQmIWEqGkP",
"urls": [
"https://speedvitals.com",
"https://blog.speedvitals.com"
],
"devices": [
"macbookAirM1"
],
"locations": [
"us"
],
"config": null,
"batch_type": "multiple-urls",
"status": "idle",
"lighthouse_version": "9.6.2",
"report_url": "https://speedvitals.com/result/afd98w0l/",
"created_at": 1657539924734,
"expires_at": 1660131924733,
"reports": null
}
{
"id": "lbt_IU8rN0XQmIWEqGkP",
"urls": [
"https://speedvitals.com",
"https://blog.speedvitals.com"
],
"config": null,
"status": "active",
"devices": [
"macbookAirM1"
],
"reports": [
{
"id": "lt_dObdG5EW4d231hto",
"url": "https://speedvitals.com",
"error": null,
"device": "macbookAirM1",
"status": "success",
"metrics": {
"speed_index": 900,
"performance_score": 100,
"time_to_interactive": 297,
"total_blocking_time": 0,
"server_response_time": 32,
"first_contentful_paint": 292,
"first_meaningful_paint": 297,
"cumulative_layout_shift": 0.0,
"largest_contentful_paint": 434
},
"location": "us",
"report_url": "https://speedvitals.com/report/speedvitals.com/IvWenx/"
},
{
"id": "lt_dmpbeQ2xk1XPh4UP",
"url": "https://blog.speedvitals.com",
"error": null,
"device": "macbookAirM1",
"status": "idle",
"metrics": {
"speed_index": 1406,
"performance_score": 99,
"time_to_interactive": 368,
"total_blocking_time": 0,
"server_response_time": 68,
"first_contentful_paint": 322,
"first_meaningful_paint": 365,
"cumulative_layout_shift": 0.0,
"largest_contentful_paint": 488
},
"location": "us",
"report_url": "https://speedvitals.com/report/blog.speedvitals.com/3t4lm7"
}
],
"locations": [
"us"
],
"batch_type": "multiple-urls",
"created_at": 1657539924734,
"expires_at": 1660131924733,
"report_url": "https://speedvitals.com/result/afd98w0l/",
"lighthouse_version": "9.6.2"
}
{
"code": "string",
"message": "string"
}
{
"code": "string",
"message": "string"
}
{
"code": "string",
"message": "string"
}
{
"code": "string",
"message": "string"
}