DSL (Domain Specific Language) or JSON schema explanation

Opus supports user-defined strategies via JSON-formatted intents or an upcoming DSL.

Example JSON Schema:

{
  "action": "stake",
  "protocol": "aave",
  "token": "USDC",
  "trigger": {
    "type": "apyAbove",
    "value": 5
  }

DSL Version (coming soon):

IF APY(aave.USDC) > 5% THEN STAKE(USDC)

This will be compiled into Solidity-compatible calldata and stored on-chain

Last updated