---
title: "codespar meter-events"
description: "Meter events: record one usage event, idempotent on its event id"
---

Meter events: record one usage event, idempotent on its event id

1 command in `@codespar/cli 0.18.1`.

Each one prints what its operation answered. [What a command prints](/docs/cli/reference#what-a-command-prints) has the rule, and [Configuration](/docs/cli/config#what-a-script-gets-when-a-command-fails) has the exit codes and the shape of a failure.

### `codespar meter-events create`

Record a usage event

```bash
codespar meter-events create --input '{"event":"string","customer":"string","value":1000,"event_id":"event_0000000000000000","timestamp":"2026-01-15T12:00:00.000Z"}'
```

| option | what it does |
|---|---|
| `-q, --query <key=value>` | Query parameter (repeatable) (default: []) |
| `--timeout <ms>` | Per-request timeout in milliseconds |
| `-i, --input <json>` | Request body as a JSON string |
| `-f, --input-file <path>` | Request body from a JSON file |

`POST /v1/meter-events` · [parameters, responses and refusals](/docs/api/reference/meter-events#post-v1meter-events)
