API v1
v1
View as Markdown

List the life event types of a category

GET /api/v1/life-event-categories/{lifeEventCategory}/types

List the natures filed under one category, in the order you arranged them.

This is the grouped reading the settings screen shows, one category at a time. Retired natures are listed with the rest, and so are the natures of a retired category, because the list says what is filed where rather than what is currently offered.

The natures are described exactly as the life event types endpoints describe them, so anything you read here can be changed there without asking for it again.

This endpoint also answers QUERY, with the same parameters sent in the request body. How QUERY works.

Parameters

Sent as JSON. Anything not listed here is ignored.

lifeEventCategory uuid Required

The id of the category. A path that is not a uuid answers 404 without a query being run.

page integer Optional default: 1

Which page to answer with.

per_page integer Optional default: 25

How many categories one page holds, between 1 and 100. A number outside the range is brought back into it rather than refused.

Returns

A page of life event type objects, and how many there are in all. A category belonging to somebody else answers 404 rather than an empty list.

data array

The natures on this page. An empty list rather than an error when there are none.

data[] object

One nature.

data[].type string

Always life_event_type. It names the kind of record, so a caller holding several kinds can tell them apart without looking at where they came from.

data[].id string

The id of this record, as a string even when it reads as a number. It is what every endpoint naming this record takes.

data[].attributes object

Everything the record holds.

data[].attributes.life_event_category_id uuid

The category the nature is filed under, which is the category you asked about.

data[].attributes.name string

What the nature is called, in the language you ask for while the product still supplies the wording.

data[].attributes.description string

A sentence saying what the nature covers, or null when nobody wrote one.

data[].attributes.icon string

The glyph drawn beside the nature, or null.

data[].attributes.colour string

The tint the nature is drawn in, or null.

data[].attributes.position integer

Where the nature sits inside this category, counting from 1.

data[].attributes.is_system boolean

Whether the product supplied the nature, which governs deletion and nothing else.

data[].attributes.is_active boolean

Whether the nature is offered when a life event is recorded.

data[].attributes.updates_last_in_touch boolean

Whether a life event of this nature sets the Last in touch date of the contacts it is recorded with.

data[].attributes.created_at timestamp

When the nature was added, as a count of seconds since 1970.

data[].attributes.updated_at timestamp

When it last changed, as a count of seconds, or null.

data[].links object

Where to find this record.

data[].links.self string

The absolute address this record is read from.

meta object

Where you are in the collection.

meta.page integer

The page this is, counting from 1.

meta.per_page integer

How many one page holds, which is the size that was asked for once it has been brought into the allowed range.

meta.total integer

How many natures there are in all, not how many are on this page.

Rate limit

Sixty requests per minute, per user, shared by every key and device. Every answer carries the budget left in X-RateLimit-Remaining.

GET
curl https://my.monicahq.com/api/v1/life-event-categories/5f8b3c21-9d07-4a64-8e12-7b0a4d6c3e95/types \
-H "Authorization: Bearer $MONICA_TOKEN"
const response = await fetch('https://my.monicahq.com/api/v1/life-event-categories/5f8b3c21-9d07-4a64-8e12-7b0a4d6c3e95/types', {
headers: { Authorization: `Bearer ${token}` },
})
const data = await response.json()
$response = Http::withToken($token)->get('https://my.monicahq.com/api/v1/life-event-categories/5f8b3c21-9d07-4a64-8e12-7b0a4d6c3e95/types');
Response 200
{
"data": [
{
"type": "life_event_type",
"id": "c3f9a8d1-4e62-4b07-9a35-6d180b2fc74e",
"attributes": {
"life_event_category_id": "5f8b3c21-9d07-4a64-8e12-7b0a4d6c3e95",
"name": "Call",
"description": null,
"icon": "activity",
"colour": null,
"position": 1,
"is_system": true,
"is_active": true,
"updates_last_in_touch": true,
"created_at": 1756252800,
"updated_at": 1756252800
},
"links": {
"self": "https://my.monicahq.com/api/v1/life-event-types/c3f9a8d1-4e62-4b07-9a35-6d180b2fc74e"
}
}
],
"meta": {
"page": 1,
"per_page": 25,
"total": 1
}
}

Keys act as you, with exactly the access you have. Make one per integration so you can revoke it alone.