Share

Share Revoke Endpoint

DELETE /share/{component} — revoke a share rule for an object.

Gated by can_share (same as grant); rejects over-broad deletes. Every ACL delete goes through the :class:AuthorizationPort. Audited on all paths.

delete/share/{component}

Request

Path parameters

component'skill' | 'skill_version' | 'application' required

Request body

object_idstring required
usersstring[] nullable
organizationstring nullable
public_scope'org' | 'tenant' | 'everyone' | 'app'

Public-visibility scopes accepted by the /share API request body.

This is the externally documented contract (docs/planning/openfga-skills-authz.md, "CRUD: /share/skills": public_scope: "org" | "tenant" | "everyone" | "app") — deliberately distinct from the internal :class:UserType, which names OpenFGA subject types (organization / tenant / public / application). Keeping them separate stops the internal enum leaking into the public API; :meth:to_user_type maps a scope onto the userset :class:UserType the domain layer expects.

app makes a skill viewable (read-only) to everyone connecting through the caller's own application; it is OpenFGA-only (the Postgres owner/public subset rejects it).

permission'owner' | 'editor' | 'viewer' | 'shared_in_app' | 'pharia-ai-admin'

Assignable roles on the skill / tenant / organization types.

These are the only relations that may be written as tuples. The computed permissions (can_admin, can_view, etc.) are never written as tuples, only queried via :meth:AuthorizationPort.check.

Response

Successful Response

unknown required

Changes

No recorded changes to this operation across all 1 revision of this API.