Get a Flarum resource
flarum_getRetrieve a Flarum resource by type and ID. Optionally include related data and select specific fields to reduce token consumption.
Instructions
Fetch a single Flarum resource by type and id, optionally including relationships and narrowing fields. Returns full field values by default (no truncation). Example: type="discussions", id="42", include="posts,user".
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| id | Yes | Resource id. | |
| type | Yes | Resource type, e.g. "discussions", "users". | |
| fields | No | Sparse fieldsets: return only named fields per type to save tokens, e.g. { discussions: "title,slug,commentCount", users: "username" }. | |
| include | No | Comma-separated relationships to include. | |
| maxFieldChars | No | Truncate string fields longer than this. 0 (default) disables truncation. |