Generate the rights synchronization (In-Site step 3)
sync_usage_rightsGenerates code that reads customer rights from the ProAbono Usage API, caches them, and gates access to features, determining what a signed-in user can do.
Instructions
Generates the code that reads a customer's rights from the ProAbono Usage API, caches them correctly and gates access on them -- step 3 of the In-Site installation, and the one that decides what a signed-in user may actually do. Returns the rights module for the stack, the gate at a call site, the write-back for a Feature the application changes (quoted and confirmed with the end customer when it is billable), and the cache expiry policy. Reads the account's real Features so the code names them. Give customer_ref to also diagnose what that customer's Usages currently say, which is how an empty response is told apart from a broken integration. Never gate on the offer reference: rights come from the Usage API.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| stack | Yes | The host project's stack. Detect it from the open project (package.json, composer.json, requirements.txt, Gemfile, .csproj) and confirm with the developer. Use "generic" when none fits. | |
| customer_ref | No | A real customer to check the wiring against. Their Usages are read and an empty answer is diagnosed against their subscriptions. | |
| feature_refs | No | The Features to gate on. Left out, every Feature of the business is listed with its type so the developer can choose. | |
| project_root | No | Root of the developer's project, where `.proabono/installation.json` is written. Defaults to the directory this server was launched in, which is the project for every MCP client that starts the server inside it. Pass it when that is not the case. | |
| record_state | No | Record this step in `.proabono/installation.json`. Default true. Set false to generate code without touching the developer's filesystem at all. |