Viewrium Docs
HTTP referenceBeacon

Record a viewer event

POST/v1/beacon

Records a view, an AR entry or an AR session's end, as the embed does. Accepts a publishable key from one of your allowed domains. Always answers 204; only a malformed body is refused (422).

Request Body

application/json

TypeScript Definitions

Use the request body type in TypeScript.

One viewer event from the embed: a view, entering AR, or an AR session ending (with its duration).

Response Body

application/json

curl -X POST "https://example.com/v1/beacon" \  -H "Content-Type: application/json" \  -d '{    "model_id": "f8ff2fb8-4acc-4e48-bd83-cbdac23e1224",    "event_type": "view"  }'
Empty
{  "error": {    "code": "string",    "message": "string",    "details": null  }}