Performance

Update late performance metrics

post/_temps/speed/update

Request

  • Base URL: /api (relative, and the document was published on a file host, not at the API’s origin)
  • URL: /api/_temps/speed/update
  • Auth: none declared

Query parameters

temps_keystring

Query-string fallback for the analytics ingest key, for clients that cannot set custom headers. This endpoint is called via navigator.sendBeacon on page unload, so the query form is the only one available there. Consulted only when the x-temps-analytics-key header is absent; identical precedence and error semantics.

Headers

x-temps-analytics-keystring nullable

Analytics ingest key (ADR-040), pa_ followed by 64 hex characters. An alternative to Host-based project resolution, for apps Temps does not deploy and which therefore have no route-table entry. When present it takes precedence and the Host header is not consulted for resolution; a key that does not resolve to an active row is a 401, never a fallback to Host. The value is public by design — it ships in client JS — and is write-only: it grants analytics ingest for one project (optionally one environment) and nothing else.

Request body

clsnumber float nullable

Cumulative Layout Shift (score)

inpnumber float nullable

Interaction to Next Paint (milliseconds)

sessionIdstring nullable

Client-generated session id fallback (see [SpeedMetricsPayload::visitor_id]).

visitorIdstring nullable

Client-generated visitor id fallback (see [SpeedMetricsPayload::visitor_id]). Required to identify the right row on the keyed path, where there is no Temps-issued cookie to fall back on.

Response

Metrics updated successfully

Changes

No recorded changes to this operation across all 53 revisions of this API.