trypost/database/factories
Paulo Castellano eb2b345163
feat: Asset Library list, preview, and attach via API and MCP (#282)
* feat: list, preview, and attach Asset Library media via API and MCP

Let API and MCP clients reuse workspace assets instead of re-uploading, sharing the same scoped query, signed preview, and idempotent attach path.

Co-authored-by: Cursor <cursoragent@cursor.com>

* Align Asset Library API and MCP with main media patterns.

Drop the signed-preview stack, return Storage URLs and PostResource like existing attach flows, and query medias by morph owner instead of getMedia().

Co-authored-by: Cursor <cursoragent@cursor.com>

* Paginate workspace assets with the app default page size.

Keep list pagination in the action via config('app.pagination.default') instead of a hardcoded API page size.

Co-authored-by: Cursor <cursoragent@cursor.com>

* Move asset API and MCP input rules into FormRequests.

Keep controllers and tools free of inline field validation; MCP tools reuse the request rule definitions.

Co-authored-by: Cursor <cursoragent@cursor.com>

* Document asset MCP tools with explicit parameters and constraints.

Spell out workspace scope, return fields, sibling tools, and rejection cases so agents can call list/get/attach without guessing.

Co-authored-by: Cursor <cursoragent@cursor.com>

* Harden asset attach against races and keep library metadata on the post.

Co-authored-by: Cursor <cursoragent@cursor.com>

* Relock the library asset on attach so a deleted file cannot land on the post.

Co-authored-by: Cursor <cursoragent@cursor.com>

* Document that omitting alt on attach keeps the library alt text.

Co-authored-by: Cursor <cursoragent@cursor.com>

---------

Co-authored-by: Cursor <cursoragent@cursor.com>
2026-08-16 17:08:20 -03:00
..
AccountFactory.php feat: introduce Account entity as billing owner and refactor architecture 2026-04-14 22:22:04 -03:00
AiUsageLogFactory.php feat: transition AI usage from feature-based limits to a centralized monthly credit system with token tracking. 2026-05-03 19:36:26 -03:00
AutomationFactory.php Add strict_types to automation files and AutomationNodeState factory 2026-06-10 17:26:50 -03:00
AutomationNodeRunFactory.php Add strict_types to automation files and AutomationNodeState factory 2026-06-10 17:26:50 -03:00
AutomationNodeStateFactory.php Add strict_types to automation files and AutomationNodeState factory 2026-06-10 17:26:50 -03:00
AutomationRunFactory.php Add strict_types to automation files and AutomationNodeState factory 2026-06-10 17:26:50 -03:00
AutomationTriggerItemFactory.php Add strict_types to automation files and AutomationNodeState factory 2026-06-10 17:26:50 -03:00
InviteFactory.php feat: introduce Account entity as billing owner and refactor architecture 2026-04-14 22:22:04 -03:00
MediaFactory.php feat: Asset Library list, preview, and attach via API and MCP (#282) 2026-08-16 17:08:20 -03:00
NotificationFactory.php feat: notification system with SendNotification job, dialog UI, tests 2026-03-30 16:47:03 -03:00
NotificationPreferenceFactory.php feat: proactive connection check for at-risk posts + SocialAccount name centralization (#256) 2026-08-09 11:10:39 -03:00
PlanFactory.php chore: remove legacy plan tiers (starter/plus/pro/max) 2026-06-22 15:31:32 -03:00
PostCommentFactory.php feat: add post_comments table, model, and factory 2026-04-15 20:08:16 -03:00
PostFactory.php feat: add PostCommentCreated broadcast event 2026-04-15 20:11:36 -03:00
PostPlatformFactory.php feat(api,mcp): full per-platform meta parity for posts 2026-06-16 17:39:07 -03:00
SocialAccountFactory.php feat(channels): add Discord as a social channel 2026-06-16 14:44:00 -03:00
UserFactory.php feat: per-workspace pricing, onboarding, and billing overhaul 2026-06-21 20:40:03 -03:00
WorkspaceFactory.php Structure brand voice and make generated copy platform-aware 2026-06-12 17:09:39 -03:00
WorkspaceInviteFactory.php refactor: settings redesign, Spanish translations, language system, strict_types 2026-03-30 00:20:43 -03:00
WorkspaceLabelFactory.php refactor: settings redesign, Spanish translations, language system, strict_types 2026-03-30 00:20:43 -03:00
WorkspaceSignatureFactory.php chore: remove deprecated localization files 2026-05-03 15:23:25 -03:00