Recently Used
Recently Used keeps a lightweight history of items a user interacted with most recently (Tickets, Orders, Documents, Customers, …).
It powers quick navigation lists (e.g., “Recent items” in the UI), helps resume work-in-progress, and can be leveraged for personalized shortcuts.
Typical use cases:
- Agent productivity — jump back to the last few tickets or customers you touched
- Sales & success — reopen the last opportunities or accounts you viewed
- DMS — quickly return to recently opened documents or folders
- Portals — show a simple “last visited” list for end users
Note: Unlike other supporting entities, Recently Used is not owned by a business record via
ownerType/ownerId.
It’s a per-user trail that references any entity byentityTypeandentityId.
Typical Flows
1) Record an item as “recently used”
Call this when a user opens, edits, downloads, or otherwise meaningfully interacts with a record.
@dms.recentlyUsed.create({
"userId": #auth.user.id,
"name": #ticket.key + " - " + #ticket.summary,
"entityType": "Ticket",
"entityId": #ticket.id,
"icon": "ticket",
"url": "/app/tickets/" + #ticket.id,
"data": {
"status": #ticket.status,
"priority": #ticket.priority
}
})
2) Record a DMS document open
@dms.recentlyUsed.create({
"userId": #auth.user.id,
"name": #doc.name,
"entityType": "Document",
"entityId": #doc.id,
"icon": "file",
"url": "/app/dms/documents/" + #doc.id,
"data": { "mimeType": #doc.mimeType }
})
3) List a user’s recent items (for a sidebar widget)
@dms.recentlyUsed.search({
"userId": #auth.user.id
})
Tip: If you want to maintain a fixed-length list (e.g., the latest 20), enforce pruning in your workflow/job or in the client-side logic calling the API.
Business & Governance
- Per-user context — entries are scoped by
userId; UI components should always filter by the current user. - Lightweight metadata — use
name,icon,urlfor quick rendering; put optional attributes indatafor flexible display (status, tags, type-specific hints). - Privacy — this is user-centric navigation data; avoid storing sensitive content in
data. - Retention — set your own policy (e.g., keep last N items per user or items newer than 30 days).
Reference
Recently Used (attributes)
| Field | Type | Required | Read-only | Description / Notes |
|---|---|---|---|---|
id | UUID | – | – | Unique identifier (not intended for end-user display). |
userId | UUID | Yes | – | User to whom this recent entry belongs. |
created | Date | – | Yes (default) | Creation timestamp (defaults to now). |
name | String | Yes | – | Display name shown in “recent items” lists. |
entityId | String | – | – | Identifier of the referenced record. |
entityType | String | Yes | – | Type/class of the referenced record (e.g., Ticket, Order, Document, Customer). |
data | Any | – | – | Optional extra metadata for rendering (status, labels, etc.). |
icon | String | – | – | UI icon identifier (optional). |
url | String | – | – | Deep-link to open the entity in the UI. |
Good Practices
- Record on meaningful interactions (open, edit, upload, download) rather than every view, to keep noise low.
- Use stable names and URLs so old entries remain navigable after minor UI changes.
- Keep
datasmall & non-sensitive; it should assist rendering, not replicate the full entity. - Prune regularly — e.g., keep only the last 20–50 items per user or remove items older than 60 days.
See Also
- Attachment / Comment / Worklog / Log / Sharing — other supporting entities often used alongside recent items
- Supporting Entities – Overview
- SpEL Clients — configuration & usage