{"version":"2.1.333","anchor":"plugin-permission-asks-and-ask-only-request-fields","canonical_anchor":"plugin-permission-asks-and-ask-only-request-fields","heading":"SDK permission requests gain managed_rules_only, plan_floor_ask_only and refusal codes","tier":"notice","area":"Plugin API","scope":"both","heads_up":false,"url":"https:\/\/changelogs.core-directive.com\/v\/2.1.333\/e\/plugin-permission-asks-and-ask-only-request-fields","release_url":"https:\/\/changelogs.core-directive.com\/v\/2.1.333","markdown":"### SDK permission requests gain managed_rules_only, plan_floor_ask_only and refusal codes\n\nPermission requests sent to SDK host apps gain `managed_rules_only`, `plan_floor_ask_only` and `ask_only_false_cause`, plugin asks and rule refusal codes\n\n**Unclear.** What each of the three new control request fields does is not stated.\n\n**What**\n\nWhen Claude Code runs inside another app through the SDK, it asks that app for permission before using a tool with a `can_use_tool` request. The permission messages change in several ways:\n\n- Permission requests accept three new fields: `plan_floor_ask_only`, `ask_only_false_cause` and `managed_rules_only`.\n\n- `managed_rules_only: true` is added to outgoing `can_use_tool` requests that suggest rules to add (`addRules`) when managed policy, meaning settings set by an administrator, restricts rules. This applies only when the connection is not remote. Forwarded requests have it cleared.\n\n- A request that is asked again now clears `plan_floor_ask_only` as well as `server_policy_ask_only`.\n\n- A permission request can now come from a plugin. Its prompt text gets a prefix, and it can only be answered by a person.\n\n- When adding or removing a permission rule fails, the reply now carries a `refusal` code: `empty`, `certified_namespace`, `invalid_rule`, `not_found` or `twin_rule`. Before, it carried only a message. The \"rule not found\" message is reworded to say the file has no rule with that text.\n\n**Why**\n\nApps built on the SDK get more structured information about each permission request. For example, they can tell when managed rules apply and adjust which \"always allow\" options they show, and they can react to the exact reason a rule change was refused.\n\n- Area: Plugin API\n- Tier: You'll notice\n- Useful: 3\/5\n- Signal: 3\/5\n- Scope: both\n- Heads-up: no"}