---
title: "Update late performance metrics"
method: POST
path: "/_temps/speed/update"
tags: ["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_key` string

## Headers

- `x-temps-analytics-key` string, nullable

## Request body

- UpdateSpeedMetricsPayload: Update speed metrics payload for late-loading metrics
  - `cls` number, float, nullable: Cumulative Layout Shift (score)
  - `inp` number, float, nullable: Interaction to Next Paint (milliseconds)
  - `sessionId` string, nullable: Client-generated session id fallback (see [`SpeedMetricsPayload::visitor_id`]).
  - `visitorId` string, 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 `204`

Metrics updated successfully

## Other responses

- `400`: Bad request
- `404`: Host not found or metrics not found
- `500`: Internal server error

## Changes

- **2026-09-07** `c2a1f69745e7`: 4 info
  - added the new optional `header` request parameter `x-temps-analytics-key`
  - added the new optional `query` request parameter `temps_key`
  - added the new optional request property `sessionId`
  - added the new optional request property `visitorId`
- **2026-09-07** `7a3103561bd0`: 4 warning
  - deleted the `header` request parameter `x-temps-analytics-key`
  - deleted the `query` request parameter `temps_key`
  - removed the request property `sessionId`
  - removed the request property `visitorId`
- **2026-09-07** `7fcff272f099`: 4 info
  - added the new optional `header` request parameter `x-temps-analytics-key`
  - added the new optional `query` request parameter `temps_key`
  - added the new optional request property `sessionId`
  - added the new optional request property `visitorId`
- **2026-09-07** `c1fa498b6377`: 4 warning
  - deleted the `header` request parameter `x-temps-analytics-key`
  - deleted the `query` request parameter `temps_key`
  - removed the request property `sessionId`
  - removed the request property `visitorId`
- **2026-09-07** `c43de0e360be`: 4 info
  - added the new optional `header` request parameter `x-temps-analytics-key`
  - added the new optional `query` request parameter `temps_key`
  - added the new optional request property `sessionId`
  - added the new optional request property `visitorId`

[Operation history](https://skmtc.dev/gotempsh/apis/temps/changes/_temps/speed/update/post.md)

---

[API](https://skmtc.dev/gotempsh/apis/temps.md) - [All operations](https://skmtc.dev/gotempsh/apis/temps/llms.txt) - [OpenAPI document](https://skmtc.dev/gotempsh/apis/temps/revisions/3b040526eb43?raw)
