POST Send points, states, events or a heartbeat with an explicitly authorized machine credential. Uses the existing telemetry validation, quotas, deduplication and alarm pipeline. A concrete monitor is required. Run start and completion use the existing events contract. The runtime write gate must be enabled; ingest endpoints still accept only device keys.
/api/v1/automation/telemetry/{kind}
Send points, states, events or a heartbeat with an explicitly authorized machine credential. Uses the existing telemetry validation, quotas, deduplication and alarm pipeline. A concrete monitor is required. Run start and completion use the existing events contract. The runtime write gate must be enabled; ingest endpoints still accept only device keys.
On this page
Access and permissions
Send points, states, events or a heartbeat with an explicitly authorized machine credential. Uses the existing telemetry validation, quotas, deduplication and alarm pipeline. A concrete monitor is required. Run start and completion use the existing events contract. The runtime write gate must be enabled; ingest endpoints still accept only device keys.
Machine management credentials in Authorization: Bearer. Check the permissions (scopes) required by the operation.
Parameters and headers
| Field | Location | Type and limits | Required | Meaning |
|---|---|---|---|---|
| kind | Path | string; {"enum":["points","states","events","heartbeat"]} | Yes | Telemetry kind; heartbeat has no body. |
| device_id | URL query | string; {"format":"uuid"} | No | Concrete monitor UUID, required for heartbeat; batches may supply device_id in JSON. |
Request body
| Field | Type and limits | Required | Meaning |
|---|---|---|---|
| $ | Batch | StateBatch | EventBatch | Yes | — |
| $ (oneOf 1) | Batch | No | — |
| $ (oneOf 1).batch_id | string; {"format":"uuid"} | Yes | Client-generated UUID identifying this submission. Reuse measurement IDs and the exact payload on retries. |
| $ (oneOf 1).device_id | string; {"format":"uuid"} | No | Optional monitor scope; if provided, it must belong to the write key. |
| $ (oneOf 1).points | array<Point>; {"maxItems":1000,"minItems":1} | Yes | — |
| $ (oneOf 1).points[] | Point | Yes | — |
| $ (oneOf 1).points[].id | string; {"format":"uuid"} | Yes | UUID of this resource. Keep the returned identifier for subsequent operations. |
| $ (oneOf 1).points[].measured_at | string; {"format":"date-time"} | Yes | Observation timestamp supplied by the device in UTC; follow the permitted past and future window. |
| $ (oneOf 1).points[].series_id | string; {"format":"uuid"} | Yes | UUID of the measurement series belonging to the authorized device. |
| $ (oneOf 1).points[].value | number; {"format":"double"} | Yes | — |
| $ (oneOf 2) | StateBatch | No | — |
| $ (oneOf 2).batch_id | string; {"format":"uuid"} | Yes | Client-generated UUID identifying this submission. Reuse measurement IDs and the exact payload on retries. |
| $ (oneOf 2).device_id | string; {"format":"uuid"} | No | Target device UUID. Required for shared keys, implicit for one selected device. Header and body targets must match. |
| $ (oneOf 2).points | array<StatePoint>; {"maxItems":1000,"minItems":1} | Yes | — |
| $ (oneOf 2).points[] | StatePoint | Yes | — |
| $ (oneOf 2).points[].id | string; {"format":"uuid"} | Yes | UUID of this resource. Keep the returned identifier for subsequent operations. |
| $ (oneOf 2).points[].measured_at | string; {"format":"date-time"} | Yes | Observation timestamp supplied by the device in UTC; follow the permitted past and future window. |
| $ (oneOf 2).points[].series_id | string; {"format":"uuid"} | Yes | UUID of the measurement series belonging to the authorized device. |
| $ (oneOf 2).points[].value | boolean | string; {"maxLength":128} | Yes | — |
| $ (oneOf 2).points[].value (oneOf 1) | boolean | No | — |
| $ (oneOf 2).points[].value (oneOf 2) | string; {"maxLength":128} | No | — |
| $ (oneOf 3) | EventBatch | No | — |
| $ (oneOf 3).batch_id | string; {"format":"uuid"} | Yes | Client-generated UUID identifying this submission. Reuse measurement IDs and the exact payload on retries. |
| $ (oneOf 3).device_id | string; {"format":"uuid"} | No | Target device UUID. Required for shared keys, implicit for one selected device. Header and body targets must match. |
| $ (oneOf 3).events | array<TextEvent>; {"maxItems":1000,"minItems":1} | Yes | — |
| $ (oneOf 3).events[] | TextEvent | Yes | — |
| $ (oneOf 3).events[].id | string; {"format":"uuid"} | Yes | UUID of this resource. Keep the returned identifier for subsequent operations. |
| $ (oneOf 3).events[].labels | object | No | Collector events use at most ten labels: source, type, series_id, component_id, parameter_key, change_kind, old_status, new_status, and optional JSON-encoded old_value / new_value for Boolean or Enum states. change_kind is collection_status, state_value or counter_reset. Missing values were not transmitted; collection recovery does not confirm service health. Existing event size limits apply. |
| $ (oneOf 3).events[].measured_at | string; {"format":"date-time"} | Yes | Observation timestamp supplied by the device in UTC; follow the permitted past and future window. |
| $ (oneOf 3).events[].message | string; {"maxLength":2048} | Yes | — |
| $ (oneOf 3).events[].run | RunEvent | No | — |
| $ (oneOf 3).events[].run.duration_ms | integer; {"format":"int64","maximum":604800000,"minimum":0} | No | Optional client-reported duration on completion |
| $ (oneOf 3).events[].run.exit_code | integer; {"maximum":4294967295,"minimum":-2147483648} | No | Native Unix or Windows process exit status. Unix signal exits are represented as 128 plus signal; Windows statuses retain their native value. |
| $ (oneOf 3).events[].run.id | string; {"format":"uuid"} | Yes | Unique run ID within the account |
| $ (oneOf 3).events[].run.scheduled_for | string; {"format":"date-time"} | No | Only on start; exact scheduled UTC timestamp for overlapping tolerance windows |
| $ (oneOf 3).events[].run.status | string; {"enum":["started","succeeded","failed","aborted"]} | Yes | — |
| $ (oneOf 3).events[].severity | string; {"enum":["info","warning","critical"]} | Yes | Severity value from the listed vocabulary. |
Responses
| Header | Type and limits | Meaning |
|---|---|---|
| Cache-Control | string; {"pattern":"(?:^|,\\s*)no-store(?:,|$)"} | Private API responses prohibit storage. Public OAuth metadata is cached for 300 seconds; live streams additionally prohibit transformation. |
| Content-Language | string; {"enum":["en","de"]} | Language of human-readable response text, resolved from Accept-Language or the documented browser preference. Technical codes and identifiers remain stable. |
| Referrer-Policy | JSON; {"enum":["strict-origin-when-cross-origin","no-referrer"]} | The default referrer policy is strict-origin-when-cross-origin. Provider-login responses use no-referrer to protect login parameters. |
| Vary | string | Responses vary by Accept-Language; browser-rendered responses can also vary by the preference cookie. |
| X-Content-Type-Options | JSON; {"const":"nosniff"} | The browser must use the declared content type. |
| X-Frame-Options | JSON; {"const":"DENY"} | The response must not be embedded in a frame. |
| X-Request-ID | string | Server-generated request identifier. Include this when reporting an error; inbound values are not trusted. |
application/json
| Field | Type and limits | Required | Meaning |
|---|---|---|---|
| $ | object; {"additionalProperties":true} | Yes | — |
| Stable error codes |
|---|
| invalid_credential |
| unauthorized |
| Header | Type and limits | Meaning |
|---|---|---|
| Cache-Control | string; {"pattern":"(?:^|,\\s*)no-store(?:,|$)"} | Private API responses prohibit storage. Public OAuth metadata is cached for 300 seconds; live streams additionally prohibit transformation. |
| Content-Language | string; {"enum":["en","de"]} | Language of human-readable response text, resolved from Accept-Language or the documented browser preference. Technical codes and identifiers remain stable. |
| Referrer-Policy | JSON; {"enum":["strict-origin-when-cross-origin","no-referrer"]} | The default referrer policy is strict-origin-when-cross-origin. Provider-login responses use no-referrer to protect login parameters. |
| Vary | string | Responses vary by Accept-Language; browser-rendered responses can also vary by the preference cookie. |
| X-Content-Type-Options | JSON; {"const":"nosniff"} | The browser must use the declared content type. |
| X-Frame-Options | JSON; {"const":"DENY"} | The response must not be embedded in a frame. |
| X-Request-ID | string | Server-generated request identifier. Include this when reporting an error; inbound values are not trusted. |
application/problem+json
| Field | Type and limits | Required | Meaning |
|---|---|---|---|
| $ | Problem | Yes | — |
| $.code | string | Yes | Stable machine-readable error code |
| $.detail | string | Yes | Short localized explanation without internal error details |
| $.instance | string | Yes | Unique relative identifier /api/v1/requests/{request_id}; not a retrievable resource |
| $.message | string | Yes | Temporarily identical to detail for existing clients |
| $.message_key | string | Yes | Stable translation key for changing the displayed language without another request |
| $.message_params | object; {"additionalProperties":true} | Yes | Named, safely rendered message parameters; never arbitrary HTML |
| $.request_id | string; {"pattern":"^[0-9a-f]{32}$"} | Yes | Server-generated diagnostic identifier. It contains no login token or credential. |
| $.status | integer; {"maximum":599,"minimum":400} | Yes | — |
| $.title | string | Yes | Localized HTTP status title |
| $.type | string; {"const":"about:blank"} | Yes | — |
{
"code": "demo",
"detail": "Demo error detail; inspect the documented code.",
"instance": "demo",
"message": "Demo error detail; inspect the documented code.",
"message_key": "errors.requestFailed",
"message_params": {},
"request_id": "00000000000000000000000000000000",
"status": 401,
"title": "Demo error",
"type": "about:blank"
}| Stable error codes |
|---|
| csrf |
| insufficient_scope |
| invalid_origin |
| machine_required |
| device_scope |
| Header | Type and limits | Meaning |
|---|---|---|
| Cache-Control | string; {"pattern":"(?:^|,\\s*)no-store(?:,|$)"} | Private API responses prohibit storage. Public OAuth metadata is cached for 300 seconds; live streams additionally prohibit transformation. |
| Content-Language | string; {"enum":["en","de"]} | Language of human-readable response text, resolved from Accept-Language or the documented browser preference. Technical codes and identifiers remain stable. |
| Referrer-Policy | JSON; {"enum":["strict-origin-when-cross-origin","no-referrer"]} | The default referrer policy is strict-origin-when-cross-origin. Provider-login responses use no-referrer to protect login parameters. |
| Vary | string | Responses vary by Accept-Language; browser-rendered responses can also vary by the preference cookie. |
| X-Content-Type-Options | JSON; {"const":"nosniff"} | The browser must use the declared content type. |
| X-Frame-Options | JSON; {"const":"DENY"} | The response must not be embedded in a frame. |
| X-Request-ID | string | Server-generated request identifier. Include this when reporting an error; inbound values are not trusted. |
application/problem+json
| Field | Type and limits | Required | Meaning |
|---|---|---|---|
| $ | Problem | Yes | — |
| $.code | string | Yes | Stable machine-readable error code |
| $.detail | string | Yes | Short localized explanation without internal error details |
| $.instance | string | Yes | Unique relative identifier /api/v1/requests/{request_id}; not a retrievable resource |
| $.message | string | Yes | Temporarily identical to detail for existing clients |
| $.message_key | string | Yes | Stable translation key for changing the displayed language without another request |
| $.message_params | object; {"additionalProperties":true} | Yes | Named, safely rendered message parameters; never arbitrary HTML |
| $.request_id | string; {"pattern":"^[0-9a-f]{32}$"} | Yes | Server-generated diagnostic identifier. It contains no login token or credential. |
| $.status | integer; {"maximum":599,"minimum":400} | Yes | — |
| $.title | string | Yes | Localized HTTP status title |
| $.type | string; {"const":"about:blank"} | Yes | — |
{
"code": "demo",
"detail": "Demo error detail; inspect the documented code.",
"instance": "demo",
"message": "Demo error detail; inspect the documented code.",
"message_key": "errors.requestFailed",
"message_params": {},
"request_id": "00000000000000000000000000000000",
"status": 403,
"title": "Demo error",
"type": "about:blank"
}| Stable error codes |
|---|
| feature_unavailable |
| unavailable |
| not_found |
| Header | Type and limits | Meaning |
|---|---|---|
| Cache-Control | string; {"pattern":"(?:^|,\\s*)no-store(?:,|$)"} | Private API responses prohibit storage. Public OAuth metadata is cached for 300 seconds; live streams additionally prohibit transformation. |
| Content-Language | string; {"enum":["en","de"]} | Language of human-readable response text, resolved from Accept-Language or the documented browser preference. Technical codes and identifiers remain stable. |
| Referrer-Policy | JSON; {"enum":["strict-origin-when-cross-origin","no-referrer"]} | The default referrer policy is strict-origin-when-cross-origin. Provider-login responses use no-referrer to protect login parameters. |
| Retry-After | string; {"pattern":"^[0-9]+$"} | Seconds before retry. Preserve supported idempotency identifiers and respect the operation’s mutation semantics. |
| Vary | string | Responses vary by Accept-Language; browser-rendered responses can also vary by the preference cookie. |
| X-Content-Type-Options | JSON; {"const":"nosniff"} | The browser must use the declared content type. |
| X-Frame-Options | JSON; {"const":"DENY"} | The response must not be embedded in a frame. |
| X-Request-ID | string | Server-generated request identifier. Include this when reporting an error; inbound values are not trusted. |
application/problem+json
| Field | Type and limits | Required | Meaning |
|---|---|---|---|
| $ | Problem | Yes | — |
| $.code | string | Yes | Stable machine-readable error code |
| $.detail | string | Yes | Short localized explanation without internal error details |
| $.instance | string | Yes | Unique relative identifier /api/v1/requests/{request_id}; not a retrievable resource |
| $.message | string | Yes | Temporarily identical to detail for existing clients |
| $.message_key | string | Yes | Stable translation key for changing the displayed language without another request |
| $.message_params | object; {"additionalProperties":true} | Yes | Named, safely rendered message parameters; never arbitrary HTML |
| $.request_id | string; {"pattern":"^[0-9a-f]{32}$"} | Yes | Server-generated diagnostic identifier. It contains no login token or credential. |
| $.status | integer; {"maximum":599,"minimum":400} | Yes | — |
| $.title | string | Yes | Localized HTTP status title |
| $.type | string; {"const":"about:blank"} | Yes | — |
{
"code": "demo",
"detail": "Demo error detail; inspect the documented code.",
"instance": "demo",
"message": "Demo error detail; inspect the documented code.",
"message_key": "errors.requestFailed",
"message_params": {},
"request_id": "00000000000000000000000000000000",
"status": 503,
"title": "Demo error",
"type": "about:blank"
}| Stable error codes |
|---|
| invalid_mcp_token_request |
| invalid_json |
| device_scope |
| device_required |
| Header | Type and limits | Meaning |
|---|---|---|
| Cache-Control | string; {"pattern":"(?:^|,\\s*)no-store(?:,|$)"} | Private API responses prohibit storage. Public OAuth metadata is cached for 300 seconds; live streams additionally prohibit transformation. |
| Content-Language | string; {"enum":["en","de"]} | Language of human-readable response text, resolved from Accept-Language or the documented browser preference. Technical codes and identifiers remain stable. |
| Referrer-Policy | JSON; {"enum":["strict-origin-when-cross-origin","no-referrer"]} | The default referrer policy is strict-origin-when-cross-origin. Provider-login responses use no-referrer to protect login parameters. |
| Vary | string | Responses vary by Accept-Language; browser-rendered responses can also vary by the preference cookie. |
| X-Content-Type-Options | JSON; {"const":"nosniff"} | The browser must use the declared content type. |
| X-Frame-Options | JSON; {"const":"DENY"} | The response must not be embedded in a frame. |
| X-Request-ID | string | Server-generated request identifier. Include this when reporting an error; inbound values are not trusted. |
application/problem+json
| Field | Type and limits | Required | Meaning |
|---|---|---|---|
| $ | Problem | Yes | — |
| $.code | string | Yes | Stable machine-readable error code |
| $.detail | string | Yes | Short localized explanation without internal error details |
| $.instance | string | Yes | Unique relative identifier /api/v1/requests/{request_id}; not a retrievable resource |
| $.message | string | Yes | Temporarily identical to detail for existing clients |
| $.message_key | string | Yes | Stable translation key for changing the displayed language without another request |
| $.message_params | object; {"additionalProperties":true} | Yes | Named, safely rendered message parameters; never arbitrary HTML |
| $.request_id | string; {"pattern":"^[0-9a-f]{32}$"} | Yes | Server-generated diagnostic identifier. It contains no login token or credential. |
| $.status | integer; {"maximum":599,"minimum":400} | Yes | — |
| $.title | string | Yes | Localized HTTP status title |
| $.type | string; {"const":"about:blank"} | Yes | — |
{
"code": "demo",
"detail": "Demo error detail; inspect the documented code.",
"instance": "demo",
"message": "Demo error detail; inspect the documented code.",
"message_key": "errors.requestFailed",
"message_params": {},
"request_id": "00000000000000000000000000000000",
"status": 422,
"title": "Demo error",
"type": "about:blank"
}| Stable error codes |
|---|
| mcp_token_limit |
| Header | Type and limits | Meaning |
|---|---|---|
| Cache-Control | string; {"pattern":"(?:^|,\\s*)no-store(?:,|$)"} | Private API responses prohibit storage. Public OAuth metadata is cached for 300 seconds; live streams additionally prohibit transformation. |
| Content-Language | string; {"enum":["en","de"]} | Language of human-readable response text, resolved from Accept-Language or the documented browser preference. Technical codes and identifiers remain stable. |
| Referrer-Policy | JSON; {"enum":["strict-origin-when-cross-origin","no-referrer"]} | The default referrer policy is strict-origin-when-cross-origin. Provider-login responses use no-referrer to protect login parameters. |
| Retry-After | string; {"pattern":"^[0-9]+$"} | Seconds before retry. Preserve supported idempotency identifiers and respect the operation’s mutation semantics. |
| Vary | string | Responses vary by Accept-Language; browser-rendered responses can also vary by the preference cookie. |
| X-Content-Type-Options | JSON; {"const":"nosniff"} | The browser must use the declared content type. |
| X-Frame-Options | JSON; {"const":"DENY"} | The response must not be embedded in a frame. |
| X-Request-ID | string | Server-generated request identifier. Include this when reporting an error; inbound values are not trusted. |
application/problem+json
| Field | Type and limits | Required | Meaning |
|---|---|---|---|
| $ | Problem | Yes | — |
| $.code | string | Yes | Stable machine-readable error code |
| $.detail | string | Yes | Short localized explanation without internal error details |
| $.instance | string | Yes | Unique relative identifier /api/v1/requests/{request_id}; not a retrievable resource |
| $.message | string | Yes | Temporarily identical to detail for existing clients |
| $.message_key | string | Yes | Stable translation key for changing the displayed language without another request |
| $.message_params | object; {"additionalProperties":true} | Yes | Named, safely rendered message parameters; never arbitrary HTML |
| $.request_id | string; {"pattern":"^[0-9a-f]{32}$"} | Yes | Server-generated diagnostic identifier. It contains no login token or credential. |
| $.status | integer; {"maximum":599,"minimum":400} | Yes | — |
| $.title | string | Yes | Localized HTTP status title |
| $.type | string; {"const":"about:blank"} | Yes | — |
{
"code": "demo",
"detail": "Demo error detail; inspect the documented code.",
"instance": "demo",
"message": "Demo error detail; inspect the documented code.",
"message_key": "errors.requestFailed",
"message_params": {},
"request_id": "00000000000000000000000000000000",
"status": 429,
"title": "Demo error",
"type": "about:blank"
}| Stable error codes |
|---|
| feature_unavailable |
| unavailable |
| Header | Type and limits | Meaning |
|---|---|---|
| Cache-Control | string; {"pattern":"(?:^|,\\s*)no-store(?:,|$)"} | Private API responses prohibit storage. Public OAuth metadata is cached for 300 seconds; live streams additionally prohibit transformation. |
| Content-Language | string; {"enum":["en","de"]} | Language of human-readable response text, resolved from Accept-Language or the documented browser preference. Technical codes and identifiers remain stable. |
| Referrer-Policy | JSON; {"enum":["strict-origin-when-cross-origin","no-referrer"]} | The default referrer policy is strict-origin-when-cross-origin. Provider-login responses use no-referrer to protect login parameters. |
| Retry-After | string; {"pattern":"^[0-9]+$"} | Seconds before retry. Preserve supported idempotency identifiers and respect the operation’s mutation semantics. |
| Vary | string | Responses vary by Accept-Language; browser-rendered responses can also vary by the preference cookie. |
| X-Content-Type-Options | JSON; {"const":"nosniff"} | The browser must use the declared content type. |
| X-Frame-Options | JSON; {"const":"DENY"} | The response must not be embedded in a frame. |
| X-Request-ID | string | Server-generated request identifier. Include this when reporting an error; inbound values are not trusted. |
application/problem+json
| Field | Type and limits | Required | Meaning |
|---|---|---|---|
| $ | Problem | Yes | — |
| $.code | string | Yes | Stable machine-readable error code |
| $.detail | string | Yes | Short localized explanation without internal error details |
| $.instance | string | Yes | Unique relative identifier /api/v1/requests/{request_id}; not a retrievable resource |
| $.message | string | Yes | Temporarily identical to detail for existing clients |
| $.message_key | string | Yes | Stable translation key for changing the displayed language without another request |
| $.message_params | object; {"additionalProperties":true} | Yes | Named, safely rendered message parameters; never arbitrary HTML |
| $.request_id | string; {"pattern":"^[0-9a-f]{32}$"} | Yes | Server-generated diagnostic identifier. It contains no login token or credential. |
| $.status | integer; {"maximum":599,"minimum":400} | Yes | — |
| $.title | string | Yes | Localized HTTP status title |
| $.type | string; {"const":"about:blank"} | Yes | — |
{
"code": "demo",
"detail": "Demo error detail; inspect the documented code.",
"instance": "demo",
"message": "Demo error detail; inspect the documented code.",
"message_key": "errors.requestFailed",
"message_params": {},
"request_id": "00000000000000000000000000000000",
"status": 503,
"title": "Demo error",
"type": "about:blank"
}Retries and asynchronous work
This change does not have a general retry guarantee. If the response is unclear, read the affected resource before trying again. Follow Retry-After waiting times and request new sign-in or action codes when they expire.
Request examples
Replace demo IDs, timestamps and placeholders with your own values. For a retry, keep the same IDs, time and content. These examples do not run requests on this page.
Keep login links, codes, cookies and keys private. Do not print them in logs or share them in support requests.
curl --silent --show-error --request POST --header @"$HOME/.config/metribeacon/headers.txt" --header "Content-Type: application/json" --data-binary '{"batch_id":"00000000-0000-4000-8000-000000000001","device_id":"00000000-0000-4000-8000-000000000002","points":[{"id":"00000000-0000-4000-8000-000000000003","series_id":"00000000-0000-4000-8000-000000000004","measured_at":"2026-10-02T12:00:00Z","value":42}]}' "https://metribeacon.com/api/v1/automation/telemetry/points"
import json
from pathlib import Path
import urllib.request
headers = dict(line.split(": ", 1) for line in (Path.home()/".config/metribeacon/headers.txt").read_text().splitlines())
headers["Content-Type"] = "application/json"
request = urllib.request.Request('https://metribeacon.com/api/v1/automation/telemetry/points', data='{"batch_id":"00000000-0000-4000-8000-000000000001","device_id":"00000000-0000-4000-8000-000000000002","points":[{"id":"00000000-0000-4000-8000-000000000003","series_id":"00000000-0000-4000-8000-000000000004","measured_at":"2026-10-02T12:00:00Z","value":42}]}'.encode() if '{"batch_id":"00000000-0000-4000-8000-000000000001","device_id":"00000000-0000-4000-8000-000000000002","points":[{"id":"00000000-0000-4000-8000-000000000003","series_id":"00000000-0000-4000-8000-000000000004","measured_at":"2026-10-02T12:00:00Z","value":42}]}' else None, headers=headers, method='POST')
with urllib.request.urlopen(request, timeout=20) as response:
print(response.status)
import {readFileSync} from "node:fs";
import {homedir} from "node:os";
const headers=Object.fromEntries(readFileSync(homedir()+"/.config/metribeacon/headers.txt","utf8").trim().split("\n").map(line=>{const i=line.indexOf(": ");return [line.slice(0,i),line.slice(i+2)]}));
headers["Content-Type"]="application/json";
const response=await fetch("https://metribeacon.com/api/v1/automation/telemetry/points",{method:"POST",headers,body:"{\"batch_id\":\"00000000-0000-4000-8000-000000000001\",\"device_id\":\"00000000-0000-4000-8000-000000000002\",\"points\":[{\"id\":\"00000000-0000-4000-8000-000000000003\",\"series_id\":\"00000000-0000-4000-8000-000000000004\",\"measured_at\":\"2026-10-02T12:00:00Z\",\"value\":42}]}"});
console.log(response.status);
package main
import ("fmt";"net/http";"os";"strings";"time")
func main(){
home,_:=os.UserHomeDir(); headers,_:=os.ReadFile(home+"/.config/metribeacon/headers.txt")
request,_:=http.NewRequest("POST","https://metribeacon.com/api/v1/automation/telemetry/points",strings.NewReader("{\"batch_id\":\"00000000-0000-4000-8000-000000000001\",\"device_id\":\"00000000-0000-4000-8000-000000000002\",\"points\":[{\"id\":\"00000000-0000-4000-8000-000000000003\",\"series_id\":\"00000000-0000-4000-8000-000000000004\",\"measured_at\":\"2026-10-02T12:00:00Z\",\"value\":42}]}"))
for _,line:=range strings.Split(strings.TrimSpace(string(headers)),"\n"){name,value,ok:=strings.Cut(line,": ");if ok{request.Header.Set(name,value)}}
request.Header.Set("Content-Type","application/json")
client:=&http.Client{Timeout:20*time.Second};response,err:=client.Do(request);if err!=nil{panic(err)};defer response.Body.Close();fmt.Println(response.StatusCode)
}
Related guides
- HTTP API, OAuth and MCP
Find the user API endpoints, their permissions, fields, examples and response formats.
- POST Observe accessible series for ten seconds by default, at most 15 seconds. Revalidates credential, scope, account and workspace every five seconds. Shares the two-per-account and 64-per-process machine live limits. Requires the machine live runtime gate.
Observe accessible series for ten seconds by default, at most 15 seconds. Revalidates credential, scope, account and workspace every five seconds. Shares the two-per-account and 64-per-process machine live limits. Requires the machine live runtime gate.
- POST Request a code for one sensitive action
Request a six-digit confirmation code for a sensitive account or workspace change. It lasts five minutes and allows five incorrect attempts. Use the same signed-in browser, action, target and parameters when confirming. A replacement requested after 60 seconds invalidates the previous code for that action. For your own account use link_identity, unlink_identity, add_passkey, remove_passkey or delete_self; workspace membership actions require owner permission. Do not use sign-in codes to confirm changes.
- DELETE Cancel your pending action confirmation
Only an outstanding confirmation belonging to the current account and session can be cancelled.