Reputation Instructions
report_behavior CPI
Submit a reputation signal. Callable only by whitelisted reporter programs via CPI. The reporter program signs as its registered PDA authority via invoke_signed. The effective delta is calculated as delta * reporter_weight / 5. Rate-limited per reporter per agent, with a daily cap of ±100 points per agent. Note: delta is first clamped to +/-50 before the weight calculation.
delta—i16, clamped to ±50reason_code—u8, categorizes the behavior report
Reporter CPI Integration
To become a reputation reporter, a protocol must:
- Derive a PDA from its own program (e.g.,
Pubkey::find_program_address(&[b"vouch-reporter"], &your_program_id)) - Ask the Vouch admin to call
register_reporterwith that PDA as thereporter_authority - When reporting behavior, CPI into
report_behaviorand sign as the PDA viainvoke_signed
On-chain only. The reporter authority must be a PDA derived by the reporter program. This ensures reputation reports are submitted atomically within program logic — not by off-chain services or keypairs.