Rules
bearerAuthorizationBearer <token>Supabase access token (JWT) or personal API key (ga_…). A key gets 403 on a resource it has no access to, and on anything that changes data without write access.
The user's rules, in the order they run
application/json- response
rules*array<>curl -X GET 'https://example.com/v1/rules'{ "rules": [ { "id": "string", "name": "string", "description": "string", "enabled": true, "event": { "type": "bookmarkAdded", "tag": "string", "list_ids": [ "string" ] }, "condition": { "type": "alwaysTrue", "str": "string", "tag": "string", "item_type": "link", "query": "string", "conditions": [ {} ] }, "actions": [ { "type": "addTag", "tag": "string", "list_id": "string" } ], "applied_count": 0, "last_applied_at": "2019-08-24T14:15:22Z", "created_at": "2019-08-24T14:15:22Z", "updated_at": "2019-08-24T14:15:22Z" } ]}A rule has one event (its trigger), a condition tree and a list of actions, as in Karakeep. When the
event happens to an item and the condition holds for the item as it is then, the actions run, in order.
Rules run in the order they were made, and each one sees what the ones before it did. Changes made by
rules send no webhooks and trigger no other rules. Rules do not touch items that already exist. A user
can have at most 20 rules. See docs/RULES.md.
bearerAuthorizationBearer <token>Supabase access token (JWT) or personal API key (ga_…). A key gets 403 on a resource it has no access to, and on anything that changes data without write access.
application/json- body
name*stringlength <= 80description?|length <= 280enabled?booleantrueevent*What triggers a rule. tag is required for tagAdded and tagRemoved; list_ids (at least one, all
the user's own lists) for addedToList and removedFromList. Other fields are ignored.
condition*One node of a condition tree (at most 50 nodes, 10 levels). and and or hold conditions (at least
one). urlContains, urlDoesNotContain, titleContains and titleDoesNotContain take str and compare
case-sensitively; urlDoesNotContain is false for an item that is not a link. bookmarkTypeIs takes
item_type. hasTag takes tag and sees the user's tags and the AI's. search is Trova's own: query
is a search of operators only (see docs/SEARCH.md).
actions*array<>1 <= items <= 10The new rule
application/json- response
id*stringname*stringdescription*string|nullenabled*booleanevent*What triggers a rule. tag is required for tagAdded and tagRemoved; list_ids (at least one, all
the user's own lists) for addedToList and removedFromList. Other fields are ignored.
condition*One node of a condition tree (at most 50 nodes, 10 levels). and and or hold conditions (at least
one). urlContains, urlDoesNotContain, titleContains and titleDoesNotContain take str and compare
case-sensitively; urlDoesNotContain is false for an item that is not a link. bookmarkTypeIs takes
item_type. hasTag takes tag and sees the user's tags and the AI's. search is Trova's own: query
is a search of operators only (see docs/SEARCH.md).
actions*array<>applied_count*integerTimes the rule changed an item
last_applied_at*|date-timecreated_at*stringdate-timeupdated_at*stringdate-timecurl -X POST 'https://example.com/v1/rules' \ -H 'Content-Type: application/json' \ -d '{ "name": "string", "event": { "type": "bookmarkAdded" }, "condition": { "type": "alwaysTrue" }, "actions": [ { "type": "addTag" } ]}'{ "id": "string", "name": "string", "description": "string", "enabled": true, "event": { "type": "bookmarkAdded", "tag": "string", "list_ids": [ "string" ] }, "condition": { "type": "alwaysTrue", "str": "string", "tag": "string", "item_type": "link", "query": "string", "conditions": [ {} ] }, "actions": [ { "type": "addTag", "tag": "string", "list_id": "string" } ], "applied_count": 0, "last_applied_at": "2019-08-24T14:15:22Z", "created_at": "2019-08-24T14:15:22Z", "updated_at": "2019-08-24T14:15:22Z"}bearerAuthorizationBearer <token>Supabase access token (JWT) or personal API key (ga_…). A key gets 403 on a resource it has no access to, and on anything that changes data without write access.
id*stringThe rule
application/json- response
id*stringname*stringdescription*string|nullenabled*booleanevent*What triggers a rule. tag is required for tagAdded and tagRemoved; list_ids (at least one, all
the user's own lists) for addedToList and removedFromList. Other fields are ignored.
condition*One node of a condition tree (at most 50 nodes, 10 levels). and and or hold conditions (at least
one). urlContains, urlDoesNotContain, titleContains and titleDoesNotContain take str and compare
case-sensitively; urlDoesNotContain is false for an item that is not a link. bookmarkTypeIs takes
item_type. hasTag takes tag and sees the user's tags and the AI's. search is Trova's own: query
is a search of operators only (see docs/SEARCH.md).
actions*array<>applied_count*integerTimes the rule changed an item
last_applied_at*|date-timecreated_at*stringdate-timeupdated_at*stringdate-timecurl -X GET 'https://example.com/v1/rules/string'{ "id": "string", "name": "string", "description": "string", "enabled": true, "event": { "type": "bookmarkAdded", "tag": "string", "list_ids": [ "string" ] }, "condition": { "type": "alwaysTrue", "str": "string", "tag": "string", "item_type": "link", "query": "string", "conditions": [ {} ] }, "actions": [ { "type": "addTag", "tag": "string", "list_id": "string" } ], "applied_count": 0, "last_applied_at": "2019-08-24T14:15:22Z", "created_at": "2019-08-24T14:15:22Z", "updated_at": "2019-08-24T14:15:22Z"}Fields you leave out are not changed. A given event, condition or actions replaces the whole of it. An empty description clears it. The rule must still have at least one action.
bearerAuthorizationBearer <token>Supabase access token (JWT) or personal API key (ga_…). A key gets 403 on a resource it has no access to, and on anything that changes data without write access.
id*stringapplication/json- body
name?stringlength <= 80description?stringlength <= 280enabled?booleanevent?What triggers a rule. tag is required for tagAdded and tagRemoved; list_ids (at least one, all
the user's own lists) for addedToList and removedFromList. Other fields are ignored.
condition?One node of a condition tree (at most 50 nodes, 10 levels). and and or hold conditions (at least
one). urlContains, urlDoesNotContain, titleContains and titleDoesNotContain take str and compare
case-sensitively; urlDoesNotContain is false for an item that is not a link. bookmarkTypeIs takes
item_type. hasTag takes tag and sees the user's tags and the AI's. search is Trova's own: query
is a search of operators only (see docs/SEARCH.md).
actions?array<>1 <= items <= 10The rule
application/json- response
id*stringname*stringdescription*string|nullenabled*booleanevent*What triggers a rule. tag is required for tagAdded and tagRemoved; list_ids (at least one, all
the user's own lists) for addedToList and removedFromList. Other fields are ignored.
condition*One node of a condition tree (at most 50 nodes, 10 levels). and and or hold conditions (at least
one). urlContains, urlDoesNotContain, titleContains and titleDoesNotContain take str and compare
case-sensitively; urlDoesNotContain is false for an item that is not a link. bookmarkTypeIs takes
item_type. hasTag takes tag and sees the user's tags and the AI's. search is Trova's own: query
is a search of operators only (see docs/SEARCH.md).
actions*array<>applied_count*integerTimes the rule changed an item
last_applied_at*|date-timecreated_at*stringdate-timeupdated_at*stringdate-timecurl -X PATCH 'https://example.com/v1/rules/string' \ -H 'Content-Type: application/json' \ -d '{}'{ "id": "string", "name": "string", "description": "string", "enabled": true, "event": { "type": "bookmarkAdded", "tag": "string", "list_ids": [ "string" ] }, "condition": { "type": "alwaysTrue", "str": "string", "tag": "string", "item_type": "link", "query": "string", "conditions": [ {} ] }, "actions": [ { "type": "addTag", "tag": "string", "list_id": "string" } ], "applied_count": 0, "last_applied_at": "2019-08-24T14:15:22Z", "created_at": "2019-08-24T14:15:22Z", "updated_at": "2019-08-24T14:15:22Z"}bearerAuthorizationBearer <token>Supabase access token (JWT) or personal API key (ga_…). A key gets 403 on a resource it has no access to, and on anything that changes data without write access.
id*stringDeleted
curl -X DELETE 'https://example.com/v1/rules/string'Notifications
The in-app inbox: a kept list of things the user should know about (a reminder went off, an export or import finished or failed, an invitation to a list). Works whether or not push is configured. A notification holds a kind and ids only; clients word it. With realtime on, each new one sends `notification.created` with `{notification_id}` on the user's channel. Needs a signed-in session. See docs/NOTIFICATIONS.md.
Cleanup
Reports on dead links and on pages saved more than once. Cleanup only reports. Nothing is archived, deleted or merged until the user chooses.