Start a PageSpeed test
Queues a mobile and a desktop test of the site's home page; read the history again for the results, which are in once the tests have left in_flight. A site can start two tests an hour, only while it is live, and Corefinity keeps a daily budget of tests for everyone.
Path parameters
The id of a site row. A website's production site and each of its environments has its own id. Digits only. At least 1.
Returns
202 Both tests are queued. Poll the operation until it finishes.
Fields of the 202 answer
The mobile test, then the desktop test, both queued. Up to 2 items.
Fields of each item
Format: date-time.
What the page loaded. Null when Google reports none of it.
Fields
The number of elements on the page.
The requests and bytes of each kind of file.
Fields of each item
Google's name for the kind, such as script, image or font.
The bytes loaded from other sites.
Why a failed test failed. Null otherwise.
When Google analysed the page. Null until the test succeeds. Format: date-time.
Google's figures from real visits over the last 28 days. Null when it has none for the page or the site.
Fields
Google's verdict in its own word, such as FAST, AVERAGE or SLOW.
page when the figures are the tested page's; origin when any of them is for the whole site.
pageoriginFormat: date-time.
At least 1.
Fields
Cumulative Layout Shift.
Fields
goodneeds_improvementpoornullFirst Contentful Paint.
Fields
goodneeds_improvementpoornullInteraction to Next Paint.
Fields
goodneeds_improvementpoornullfield when the figure comes from real visits. Null when there is none.
Largest Contentful Paint.
Fields
goodneeds_improvementpoornullSpeed Index.
Fields
goodneeds_improvementpoornullTotal Blocking Time.
Fields
goodneeds_improvementpoornullTime to first byte.
Fields
goodneeds_improvementpoornullGoogle's suggestions with a saving, the largest saving first, ten at most. Up to 10 items.
Fields of each item
The saving in Google's words, when it gives one.
Google's name for the check, such as unused-javascript.
The time the suggestion could save, in milliseconds.
Who asked for the test. Null for a scheduled test.
The performance score, 0 to 100.
Fields
goodneeds_improvementpoornullFormat: date-time.
queuedrunningsucceededfailedThe status as the Control Panel shows it, such as Queued or Done.
mobiledesktopThe address tested.
If it is refused
| Status | Reason | What to do |
|---|---|---|
401 | none | Send a valid token as Authorization: Bearer <token>. |
403 | company_unavailable | Your company is unavailable. |
403 | scope_required | Use a token with the scope named in scope. |
403 | two_factor_required | Turn on two-factor on your account, then send again. |
404 | feature_off | This feature is not on for your organisation yet. |
409 | busy | Another operation is running on the site. Wait for it to finish. |
409 | deleted | The site, environment or copy has been deleted, or is being deleted. Nothing can be changed on it. Restore a deleted site first if it can still be restored. |
409 | preview_only | The environment has no domain attached yet. Attach one first. |
409 | provisioning | The site is still being created. Try again in a few minutes. |
409 | removed | The site or environment is being removed, or has been. Nothing can be changed on it. |
422 | maintenance | The site is in maintenance mode, which blocks this. Switch maintenance mode off first. |
429 | rate_limited | Wait for the seconds in Retry-After. |
503 | switched_off | Corefinity has switched this action off for the moment. Try again later. |
Reasons are listed by name in Errors and refusals.
The same task elsewhere
curl -X POST https://manage.corefinity.com/api/corestack/sites/1042/pagespeed/runs \
-H "Authorization: Bearer $COREFINITY_TOKEN" \
-H "Accept: application/json"use Illuminate\Support\Facades\Http;
$response = Http::withToken(env('COREFINITY_TOKEN'))
->acceptJson()
->post('https://manage.corefinity.com/api/corestack/sites/1042/pagespeed/runs');
$data = $response->json();const res = await fetch('https://manage.corefinity.com/api/corestack/sites/1042/pagespeed/runs', {
method: 'POST',
headers: {
Authorization: `Bearer ${process.env.COREFINITY_TOKEN}`,
Accept: 'application/json',
},
});
// An answer with no body (204) has nothing to parse.
const text = await res.text();
const data = text && JSON.parse(text);import os
import requests
res = requests.post(
"https://manage.corefinity.com/api/corestack/sites/1042/pagespeed/runs",
headers={
"Authorization": f"Bearer {os.environ['COREFINITY_TOKEN']}",
"Accept": "application/json",
},
)
data = res.json() if res.content else None{
"runs": [
{
"created_at": "2026-11-10T13:00:00Z",
"diagnostics": null,
"error": null,
"fetched_at": null,
"field": null,
"finished_at": null,
"id": 6207,
"lighthouse_version": null,
"metrics": {
"cls": {
"band": null,
"value": null
},
"fcp": {
"band": null,
"value_ms": null
},
"inp": {
"band": null,
"source": null,
"value_ms": null
},
"lcp": {
"band": null,
"value_ms": null
},
"speed_index": {
"band": null,
"value_ms": null
},
"tbt": {
"band": null,
"value_ms": null
},
"ttfb": {
"band": null,
"value_ms": null
}
},
"opportunities": [],
"requested_by": {
"id": 2042,
"name": "Tom Harbour"
},
"score": {
"band": null,
"value": null
},
"started_at": null,
"status": "queued",
"status_label": "Queued",
"strategy": "mobile",
"url": "https://harbourandfinch.example.com/"
},
{
"created_at": "2026-11-10T13:00:00Z",
"diagnostics": null,
"error": null,
"fetched_at": null,
"field": null,
"finished_at": null,
"id": 6208,
"lighthouse_version": null,
"metrics": {
"cls": {
"band": null,
"value": null
},
"fcp": {
"band": null,
"value_ms": null
},
"inp": {
"band": null,
"source": null,
"value_ms": null
},
"lcp": {
"band": null,
"value_ms": null
},
"speed_index": {
"band": null,
"value_ms": null
},
"tbt": {
"band": null,
"value_ms": null
},
"ttfb": {
"band": null,
"value_ms": null
}
},
"opportunities": [],
"requested_by": {
"id": 2042,
"name": "Tom Harbour"
},
"score": {
"band": null,
"value": null
},
"started_at": null,
"status": "queued",
"status_label": "Queued",
"strategy": "desktop",
"url": "https://harbourandfinch.example.com/"
}
]
}{
"message": "Unauthenticated."
}{
"code": "company_unavailable",
"message": "Your company is unavailable.",
"reason": "company_unavailable"
}{
"code": "feature_off",
"message": "Not found.",
"reason": "feature_off"
}{
"code": "busy",
"message": "A PageSpeed test is already running for this site.",
"reason": "busy"
}{
"code": "maintenance",
"message": "In maintenance mode; tests resume when it is switched off.",
"reason": "maintenance"
}{
"code": "rate_limited",
"message": "Today's PageSpeed budget is used up. Try again tomorrow.",
"next_at": "2026-11-11T00:00:00Z",
"reason": "rate_limited"
}{
"code": "switched_off",
"message": "PageSpeed Insights is switched off",
"reason": "switched_off"
}Try it is off for this endpointIt has not been cleared for the console. Copy the request and run it yourself when you are sure.