> ## Documentation Index
> Fetch the complete documentation index at: https://deepline.com/docs/llms.txt
> Use this file to discover all available pages before exploring further.

# Reo.dev Write API: Reo Write Add Telemetry Event

> Send one product telemetry or call-home event, by IP or domain, to Reo.dev for a metric key configured in Reo. Includes SDK V2 examples, schemas, and cost.

Send one product telemetry or call-home event, by IP or domain, to Reo.dev for a metric key configured in Reo.

> [!NOTE]
>
> Tool ID: `reo_write_add_telemetry_event`

## Run this action

Use the TypeScript SDK for one call. Use `ctx.tools.execute(...)` inside a Play for durable calls, scheduled calls, or CSV processing.

```ts theme={"languages":{"custom":["/languages/deepline-prompt.json"]}}
import { Deepline } from 'deepline';

const deepline = await Deepline.connect();
const result = await deepline.tools.execute(
  'reo_write_add_telemetry_event',
  {
    "payload": {
      "activity_type": "example",
      "source": "TELEMETRY",
      "event_id": "event_123",
      "event_at": 123,
      "product_id": "product_123"
    }
  },
);

console.log(result.toolResponse.raw);
```

### CLI

```bash theme={"languages":{"custom":["/languages/deepline-prompt.json"]}}
deepline run reo_write_add_telemetry_event --input '{
  "payload": {
    "activity_type": "example",
    "source": "TELEMETRY",
    "event_id": "event_123",
    "event_at": 123,
    "product_id": "product_123"
  }
}'
```

## Example response

The SDK returns this shape at `result.toolResponse.raw`. The example values illustrate the response.

```json theme={"languages":{"custom":["/languages/deepline-prompt.json"]}}
{
  "data": {
    "response_code": "example",
    "response": "example",
    "status": "example"
  }
}
```

Use `deepline describe reo_write_add_telemetry_event --json` for the latest machine-readable contract.

## Input reference

### Overview Sends one product usage or call-home event to Reo. Reo resolves the IP or domain to a company and, if a user ID is sent, rolls usage up at the developer level before mapping it to their account. Events sent here show up in **Get Account Activities** and **Get Developer Activities** under the `PRODUCT_API` source. Use your Write API key (Settings → Configurations → API Keys → Product Usage API). Only Admins can see API keys. ### Path Parameters None. ### Errors | Code | When it happens | Response body | |---|---|---| | 400 | API key wrong or missing | `&#123;"response_code":400,"response":"Authentication Failure","status":"failure"&#125;` | | 500 | Body not wrapped in a `payload` object | `&#123;"timestamp":"...","status":500,"error":"Internal Server Error","path":"/api/product/usage"&#125;` | ### ENUMs | Field | Value | Meaning | |---|---|---| | source | `TELEMETRY` | Telemetry or call-home See the live schema below for the complete notes.

| Name | Type | Required | Default | Details |
| - | - | - | - | - |
| `payload.payload` | `object` | Yes | — | Wrapper object. Every field sits inside it. |

<details>
  <summary>Show raw input schema</summary>

  ### Input JSON Schema

  ```json theme={"languages":{"custom":["/languages/deepline-prompt.json"]}}
  {
    "type": "object",
    "description": "### Overview Sends one product usage or call-home event to Reo. Reo resolves the IP or domain to a company and, if a user ID is sent, rolls usage up at the developer level before mapping it to their account. Events sent here show up in **Get Account Activities** and **Get Developer Activities** under the `PRODUCT_API` source. Use your Write API key (Settings → Configurations → API Keys → Product Usage API). Only Admins can see API keys. ### Path Parameters None. ### Errors | Code | When it happens | Response body | |---|---|---| | 400 | API key wrong or missing | `{\"response_code\":400,\"response\":\"Authentication Failure\",\"status\":\"failure\"}` | | 500 | Body not wrapped in a `payload` object | `{\"timestamp\":\"...\",\"status\":500,\"error\":\"Internal Server Error\",\"path\":\"/api/product/usage\"}` | ### ENUMs | Field | Value | Meaning | |---|---|---| | source | `TELEMETRY` | Telemetry or call-home event | | user_id_type | `EMAIL` | `user_id` is an email | | user_id_type | `SOCIAL` | `user_id` is a social profile ID | | user_id_type | `LINKEDIN` | `user_id` is a LinkedIn profile | | user_id_type | `GITHUB` | `user_id` is a GitHub profile | | user_id_type | `USERNAME` | `user_id` is a username | ### Things to Note - Uses the same endpoint as Add Custom Product Data. The only difference is `source: \"TELEMETRY\"`. - No `user` header is needed. - Use your Write API key, not the Read API key. - `activity_type` must match a metric configured in Product Usage Settings, or Reo won't process the event. - For telemetry, `TELEMETRY` is the only accepted `source`.",
    "properties": {
      "payload": {
        "type": "object",
        "description": "Wrapper object. Every field sits inside it.",
        "properties": {
          "activity_type": {
            "type": "string",
            "description": "Must be a metric key configured in Product Usage Settings, for example `PAGE_VISIT`. If there's no usage data (call home only), send `CALL_HOME`."
          },
          "source": {
            "type": "string",
            "description": "`TELEMETRY`. - `TELEMETRY`: Telemetry or call-home event",
            "enum": [
              "TELEMETRY"
            ]
          },
          "ip_addr": {
            "type": "string",
            "description": "IP of the system the event came from. Required: One of `ip_addr` / `domain`."
          },
          "domain": {
            "type": "string",
            "description": "Domain of the user who did the event. Required: One of `ip_addr` / `domain`."
          },
          "event_id": {
            "type": "string",
            "description": "Unique ID for the event, used for filtering."
          },
          "event_at": {
            "type": "integer",
            "description": "When the event happened, Unix timestamp in seconds."
          },
          "product_id": {
            "type": "string",
            "description": "Unique ID of your product."
          },
          "user_agent": {
            "type": "string",
            "description": "Browser or client string. Required: Yes, if `user_id` isn't sent."
          },
          "user_id": {
            "type": "string",
            "description": "Unique user ID, for example an email or GitHub URL."
          },
          "user_id_type": {
            "type": "string",
            "description": "Type of `user_id` (see ENUMs). - `EMAIL`: `user_id` is an email - `SOCIAL`: `user_id` is a social profile ID - `LINKEDIN`: `user_id` is a LinkedIn profile - `GITHUB`: `user_id` is a GitHub profile - `USERNAME`: `user_id` is a username",
            "enum": [
              "EMAIL",
              "SOCIAL",
              "LINKEDIN",
              "GITHUB",
              "USERNAME"
            ]
          },
          "environment": {
            "type": "string",
            "description": "Where the product runs, for example `PRODUCTION`."
          },
          "meta": {
            "type": "object",
            "description": "Any extra key-value data.",
            "additionalProperties": true
          }
        },
        "required": [
          "activity_type",
          "source",
          "event_id",
          "event_at",
          "product_id"
        ],
        "additionalProperties": false
      }
    },
    "required": [
      "payload"
    ],
    "additionalProperties": false
  }
  ```
</details>

## Output reference

Standard tool result payload.

| Name | Type | Required | Default | Details |
| - | - | - | - | - |
| `result.data` | `object` | Yes | — | Provider response payload. |
| `result.data.response_code` | `string` | No | — | Status code, as a string. |
| `result.data.response` | `string` | No | — | Result message. |
| `result.data.status` | `string` | No | — | `success` or `failure`. |
| `result.meta` | `object` | No | — | Additional response metadata (status, paging). |

<details>
  <summary>Show raw output schema</summary>

  ### Output JSON Schema

  ```json theme={"languages":{"custom":["/languages/deepline-prompt.json"]}}
  {
    "type": "object",
    "description": "Standard tool result payload.",
    "properties": {
      "data": {
        "type": "object",
        "description": "Provider response payload.",
        "properties": {
          "response_code": {
            "type": "string",
            "description": "Status code, as a string."
          },
          "response": {
            "type": "string",
            "description": "Result message."
          },
          "status": {
            "type": "string",
            "description": "`success` or `failure`."
          }
        },
        "additionalProperties": false
      },
      "meta": {
        "type": "object",
        "description": "Additional response metadata (status, paging).",
        "additionalProperties": true
      }
    },
    "required": [
      "data"
    ],
    "additionalProperties": false
  }
  ```
</details>

## Deepline cost

* Pricing model: `fixed` (per call).
* Estimated Deepline credits: `0` per pricing unit.
* Provider-native pricing may still exist outside Deepline credit billing.

## Related documentation

* [Connect integrations](https://deepline.com/docs/integrations.md)
* [SDK V2 quickstart](https://deepline.com/docs/sdk-v2/quickstart.md)
* [SDK reference](https://deepline.com/docs/sdk-v2/sdk-reference.md)
* [Run tools across a CSV](https://deepline.com/docs/sdk-v2/batch-csv.md)


This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.