Assets
An asset is an optional record of the thing a checklist is about — a property, a vehicle, a tool. A run can reference one with asset_id, and its name and fields are shown with the run and included in webhook payloads. See Concepts for how assets fit in.
Every asset endpoint accepts your organization API key (Authorization: Bearer rdk_live_…). A key can only reach its own organization's assets.
Fields are strings
fields is a map of names to string values — the names are yours to choose.
{ "name": "Beach House 3BR", "fields": { "address": "123 Ocean Drive", "bedrooms": "3", "wifi": "beach24" } }
Send "3", not 3. If you send a number or boolean the API stores it as a string (3 → "3", true → "true"), and a null becomes an empty string; objects and arrays are rejected with 400.
POST /v1/assets
curl -X POST https://api.rundun.app/v1/assets \
-H "Authorization: Bearer rdk_live_..." \
-H "Content-Type: application/json" \
-d '{ "name": "Beach House 3BR", "fields": { "bedrooms": "3" } }'
org_id is optional with an API key (it defaults to the key's organization). Returns 201 and the asset, including its _id (a-…).
GET /v1/assets
List your organization's assets, paginated with limit (1–100, default 20) and cursor. The response is { "items": [...], "next_cursor": "a-…" | null }; pass next_cursor back as cursor for the next page.
GET /v1/assets/:id
Retrieve one asset.
PATCH /v1/assets/:id
Update name and/or fields. fields are merged into the existing fields, not replaced — to change a value, send the same name again.
curl -X PATCH https://api.rundun.app/v1/assets/a-550e8400-... \
-H "Authorization: Bearer rdk_live_..." \
-H "Content-Type: application/json" \
-d '{ "fields": { "bedrooms": "4" } }'
DELETE /v1/assets/:id
Delete an asset. Returns 204. Fails with 409 asset_has_active_runs while the asset has pending or in-progress runs — cancel those first.
Errors
| Status | Error | Meaning |
|---|---|---|
| 400 | org_id_required |
Dashboard sessions must name the organization |
| 401 | invalid_api_key |
Missing or wrong key |
| 403 | forbidden |
The asset (or org_id) belongs to a different organization |
| 404 | asset_not_found |
No such asset |
| 409 | asset_has_active_runs |
Cancel the asset's active runs before deleting |