A Flarum extension. Creator-provided content disclosures for the posts.
The extension helps authors describe the source, authenticity, safety context, and commercial nature of each posts.
This extension was built with AI assistance and will continue to be improved and maintained based on community feedback.
- Select multiple declarations when starting a discussion or writing a reply.
- Show declaration details and notes in modal.
- Display source declarations as standalone notices when no other declaration types are selected.
- ……
| Category | Declaration |
|---|---|
| Content source | Original content |
| Content source | Reposted content |
| Content source | Referenced or quoted content |
| Authenticity | AI-generated content |
| Authenticity | Fictional or staged content |
| Authenticity | Personal opinions or perspectives |
| Safety | Dangerous behavior; do not imitate |
| Safety | Potentially disturbing |
| Commercial disclosure | Contains marketing or promotional information |
| Commercial disclosure | Paid partnership, sponsorship, or material interest |
| Flarum version | Extension version | Branch |
|---|---|---|
| 2.x | 0.2.x or 2.x |
main |
| 1.x | 0.1.x or 1.x |
1.x |
Install with Composer:
composer require ffans/creator-declarations
php flarum cache:clearYou can enable the extension from the Flarum administration dashboard.
composer update ffans/creator-declarations
php flarum migrate
php flarum cache:clearOpen Administration → Extensions → FFans Creator Declarations.
| Setting | Default |
|---|---|
| Require a declaration when starting a discussion | Off |
| Require a declaration when replying | Off |
| Maximum declarations per post | 5 |
| Show declarations in user profile Posts lists | Off |
| Declaration order | Built-in order |
| Individual declaration types | All enabled |
The extension also adds these permissions:
- Allow editing own creator declarations — controls how long authors may edit declarations on their own posts.
- Edit creator declarations on posts — allows moderators to edit declarations on any post.
When composing a discussion or reply, select Add self declarations, choose the declarations that apply, add any required details, and save. The declarations are submitted together with the post.
Users with permission can edit existing declarations from the post controls menu. Disclosures are informational and should be considered together with the post content.
Configure a Composer path repository from the Flarum root directory and install the extension:
composer config repositories.creator-declarations path "/path/to/your/local/dir/creator-declarations"
composer require ffans/creator-declarations:"@dev"
php flarum extension:enable ffans-creator-declarations
php flarum cache:clearcd js
npm install
npm run check-typings
npm run build
php flarum cache:clear; & php flarum assets:publishUse npm run dev for a development build that watches for frontend changes.
Install the development dependencies, initialize the integration-test environment once, then run the test suite:
composer install
composer test:setup
composer testIntegration tests use a MySQL or MariaDB instance. Connection details are configured with DB_DRIVER (default sqlite), DB_HOST (default localhost), DB_PORT (default 3306), DB_DATABASE (default flarum_test), DB_USERNAME (default root), DB_PASSWORD (default root), and DB_PREFIX (default empty). The test directory can be configured with FLARUM_TEST_TMP_DIR_LOCAL or FLARUM_TEST_TMP_DIR.
Create the dedicated test database before running composer test:setup. Setup wipes the selected database, so never point these variables at a development or production Flarum database. Subsequent integration tests run database changes inside transactions, allowing the initialized test database to be reused.
Run only the database-free unit tests with:
composer test:unitWant to help translate this extension? Visit Robert Korulczyk's Weblate.
Released under the MIT License.

