Skip to content

saved workflows: derive row actions from effective permissions, not created_by #423

Closed

Description

@ibetitsmike

Coder Agents acted on behalf of @ibetitsmike.

Caveat from #404's PR body, never filed.

Saved workflow row actions (edit, delete, share) are chosen from workflow.created_by === user.id (site/src/pages/AgentsPage/AgentSettingsPage/ForkSavedWorkflowsPage/ForkSavedWorkflowsPage.tsx), not from the caller's effective permissions. ForkSavedWorkflowMetadata (codersdk/fork_saved_workflows.go) has no permission field. An owner whose access was revoked, or a user with permissions beyond ownership, sees the wrong actions and gets a 403.

Acceptance:

  • The saved workflow list API returns per-row actions the caller may take, computed server side through dbauthz.
  • The page shows only those actions.
  • Tests on both sides that fail without the change. Run make gen for the SDK and API docs.
  • Behind the existing fork-workflows experiment.

Activity

  1. added
    bug
    followup
    on Nov 23, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugfollowup

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions