{
  "address": "2jZZEa56EtYm2hdstDrYZPYw1phAUny25k9GKAWKNFq4",
  "metadata": {
    "name": "fade",
    "version": "0.1.0",
    "spec": "0.1.0",
    "description": "Fade: a permissionless payout layer for Solana (devnet deployment)"
  },
  "instructions": [
    {
      "name": "apply_params",
      "docs": [
        "Anyone, once the pending change is due."
      ],
      "discriminator": [
        188,
        203,
        86,
        124,
        178,
        34,
        133,
        116
      ],
      "accounts": [
        {
          "name": "config",
          "writable": true,
          "pda": {
            "seeds": [
              {
                "kind": "const",
                "value": [
                  99,
                  111,
                  110,
                  102,
                  105,
                  103
                ]
              }
            ]
          }
        },
        {
          "name": "event_authority"
        },
        {
          "name": "program"
        }
      ],
      "args": []
    },
    {
      "name": "cancel_params",
      "docs": [
        "Council only."
      ],
      "discriminator": [
        100,
        172,
        113,
        60,
        25,
        68,
        80,
        172
      ],
      "accounts": [
        {
          "name": "council",
          "signer": true
        },
        {
          "name": "config",
          "writable": true,
          "pda": {
            "seeds": [
              {
                "kind": "const",
                "value": [
                  99,
                  111,
                  110,
                  102,
                  105,
                  103
                ]
              }
            ]
          }
        },
        {
          "name": "event_authority"
        },
        {
          "name": "program"
        }
      ],
      "args": []
    },
    {
      "name": "claim_deposit",
      "docs": [
        "Anyone: the request's own `CLAIM_FEE` pays whoever claims it."
      ],
      "discriminator": [
        201,
        106,
        1,
        224,
        122,
        144,
        210,
        155
      ],
      "accounts": [
        {
          "name": "caller",
          "writable": true,
          "signer": true
        },
        {
          "name": "config",
          "pda": {
            "seeds": [
              {
                "kind": "const",
                "value": [
                  99,
                  111,
                  110,
                  102,
                  105,
                  103
                ]
              }
            ]
          }
        },
        {
          "name": "request",
          "writable": true,
          "pda": {
            "seeds": [
              {
                "kind": "const",
                "value": [
                  100,
                  101,
                  112,
                  111,
                  115,
                  105,
                  116
                ]
              },
              {
                "kind": "account",
                "path": "request.epoch_id",
                "account": "DepositRequest"
              },
              {
                "kind": "account",
                "path": "request.owner",
                "account": "DepositRequest"
              }
            ]
          }
        },
        {
          "name": "owner",
          "writable": true,
          "relations": [
            "request"
          ]
        },
        {
          "name": "record",
          "docs": [
            "Exists only once the request's epoch has been struck; absent once the",
            "request is parked."
          ],
          "writable": true,
          "optional": true,
          "pda": {
            "seeds": [
              {
                "kind": "const",
                "value": [
                  101,
                  112,
                  111,
                  99,
                  104
                ]
              },
              {
                "kind": "account",
                "path": "request.epoch_id",
                "account": "DepositRequest"
              }
            ]
          }
        },
        {
          "name": "owner_shares",
          "docs": [
            "handler delivers to it only if it can receive."
          ],
          "writable": true
        },
        {
          "name": "share_claims",
          "writable": true,
          "pda": {
            "seeds": [
              {
                "kind": "const",
                "value": [
                  115,
                  104,
                  97,
                  114,
                  101,
                  45,
                  99,
                  108,
                  97,
                  105,
                  109,
                  115
                ]
              }
            ]
          }
        },
        {
          "name": "share_mint",
          "pda": {
            "seeds": [
              {
                "kind": "const",
                "value": [
                  115,
                  104,
                  97,
                  114,
                  101,
                  115
                ]
              }
            ]
          }
        },
        {
          "name": "vault_authority",
          "pda": {
            "seeds": [
              {
                "kind": "const",
                "value": [
                  118,
                  97,
                  117,
                  108,
                  116,
                  45,
                  97,
                  117,
                  116,
                  104,
                  111,
                  114,
                  105,
                  116,
                  121
                ]
              }
            ]
          }
        },
        {
          "name": "rent_receiver",
          "writable": true,
          "optional": true
        },
        {
          "name": "owner_destination",
          "docs": [
            "another share account of the owner's, checked to be able to receive."
          ],
          "writable": true,
          "optional": true
        },
        {
          "name": "token_program",
          "address": "TokenkegQfeZyiNwAJbNbGKPFXCWuBvf9Ss623VQ5DA"
        },
        {
          "name": "event_authority"
        },
        {
          "name": "program"
        }
      ],
      "args": []
    },
    {
      "name": "claim_payout",
      "docs": [
        "Anyone: delivers a payout parked at settlement."
      ],
      "discriminator": [
        127,
        240,
        132,
        62,
        227,
        198,
        146,
        133
      ],
      "accounts": [
        {
          "name": "caller",
          "signer": true
        },
        {
          "name": "config",
          "pda": {
            "seeds": [
              {
                "kind": "const",
                "value": [
                  99,
                  111,
                  110,
                  102,
                  105,
                  103
                ]
              }
            ]
          }
        },
        {
          "name": "wager",
          "writable": true,
          "pda": {
            "seeds": [
              {
                "kind": "const",
                "value": [
                  119,
                  97,
                  103,
                  101,
                  114
                ]
              },
              {
                "kind": "account",
                "path": "wager.integrator",
                "account": "Wager"
              },
              {
                "kind": "account",
                "path": "wager.nonce",
                "account": "Wager"
              }
            ]
          }
        },
        {
          "name": "beneficiary",
          "docs": [
            "The beneficiary stored at open: the only destination."
          ],
          "writable": true
        },
        {
          "name": "payout_escrow",
          "writable": true,
          "pda": {
            "seeds": [
              {
                "kind": "const",
                "value": [
                  112,
                  97,
                  121,
                  111,
                  117,
                  116,
                  45,
                  101,
                  115,
                  99,
                  114,
                  111,
                  119
                ]
              }
            ]
          }
        },
        {
          "name": "vault_authority",
          "pda": {
            "seeds": [
              {
                "kind": "const",
                "value": [
                  118,
                  97,
                  117,
                  108,
                  116,
                  45,
                  97,
                  117,
                  116,
                  104,
                  111,
                  114,
                  105,
                  116,
                  121
                ]
              }
            ]
          }
        },
        {
          "name": "payer",
          "writable": true
        },
        {
          "name": "usdc_mint"
        },
        {
          "name": "token_program",
          "address": "TokenkegQfeZyiNwAJbNbGKPFXCWuBvf9Ss623VQ5DA"
        },
        {
          "name": "event_authority"
        },
        {
          "name": "program"
        }
      ],
      "args": []
    },
    {
      "name": "claim_withdraw",
      "discriminator": [
        232,
        89,
        154,
        117,
        16,
        204,
        182,
        224
      ],
      "accounts": [
        {
          "name": "caller",
          "writable": true,
          "signer": true
        },
        {
          "name": "config",
          "pda": {
            "seeds": [
              {
                "kind": "const",
                "value": [
                  99,
                  111,
                  110,
                  102,
                  105,
                  103
                ]
              }
            ]
          }
        },
        {
          "name": "request",
          "writable": true,
          "pda": {
            "seeds": [
              {
                "kind": "const",
                "value": [
                  119,
                  105,
                  116,
                  104,
                  100,
                  114,
                  97,
                  119
                ]
              },
              {
                "kind": "account",
                "path": "request.epoch_id",
                "account": "WithdrawRequest"
              },
              {
                "kind": "account",
                "path": "request.owner",
                "account": "WithdrawRequest"
              }
            ]
          }
        },
        {
          "name": "owner",
          "writable": true,
          "relations": [
            "request"
          ]
        },
        {
          "name": "at_record",
          "docs": [
            "The record the chain is read at: the request's own epoch or a later one",
            "of the same chain. The final claim reads the one that ends the chain; a",
            "record where the chain splits carries the request into the next chain.",
            "Absent once the request is parked."
          ],
          "writable": true,
          "optional": true,
          "pda": {
            "seeds": [
              {
                "kind": "const",
                "value": [
                  101,
                  112,
                  111,
                  99,
                  104
                ]
              },
              {
                "kind": "account",
                "path": "at_record.epoch_id",
                "account": "EpochRecord"
              }
            ]
          }
        },
        {
          "name": "entry_record",
          "docs": [
            "The request's own record, when it is not `at_record` and this is the",
            "request's first claim: it holds the chain indices at entry."
          ],
          "writable": true,
          "optional": true,
          "pda": {
            "seeds": [
              {
                "kind": "const",
                "value": [
                  101,
                  112,
                  111,
                  99,
                  104
                ]
              },
              {
                "kind": "account",
                "path": "request.epoch_id",
                "account": "WithdrawRequest"
              }
            ]
          }
        },
        {
          "name": "owner_usdc",
          "docs": [
            "handler delivers to it only if it can receive."
          ],
          "writable": true
        },
        {
          "name": "payable_usdc",
          "writable": true,
          "pda": {
            "seeds": [
              {
                "kind": "const",
                "value": [
                  112,
                  97,
                  121,
                  97,
                  98,
                  108,
                  101
                ]
              }
            ]
          }
        },
        {
          "name": "usdc_mint"
        },
        {
          "name": "vault_authority",
          "pda": {
            "seeds": [
              {
                "kind": "const",
                "value": [
                  118,
                  97,
                  117,
                  108,
                  116,
                  45,
                  97,
                  117,
                  116,
                  104,
                  111,
                  114,
                  105,
                  116,
                  121
                ]
              }
            ]
          }
        },
        {
          "name": "rent_receiver",
          "writable": true,
          "optional": true
        },
        {
          "name": "entry_rent_receiver",
          "writable": true,
          "optional": true
        },
        {
          "name": "owner_destination",
          "docs": [
            "another USDC account of the owner's, checked to be able to receive."
          ],
          "writable": true,
          "optional": true
        },
        {
          "name": "token_program",
          "address": "TokenkegQfeZyiNwAJbNbGKPFXCWuBvf9Ss623VQ5DA"
        },
        {
          "name": "event_authority"
        },
        {
          "name": "program"
        }
      ],
      "args": []
    },
    {
      "name": "expire_wager",
      "docs": [
        "Anyone, after `T_SETTLE`, if the randomness never arrived: forfeiture."
      ],
      "discriminator": [
        87,
        39,
        60,
        122,
        12,
        118,
        126,
        75
      ],
      "accounts": [
        {
          "name": "caller",
          "writable": true,
          "signer": true
        },
        {
          "name": "pool",
          "writable": true,
          "pda": {
            "seeds": [
              {
                "kind": "const",
                "value": [
                  112,
                  111,
                  111,
                  108
                ]
              }
            ]
          }
        },
        {
          "name": "integrator",
          "writable": true
        },
        {
          "name": "wager",
          "writable": true,
          "pda": {
            "seeds": [
              {
                "kind": "const",
                "value": [
                  119,
                  97,
                  103,
                  101,
                  114
                ]
              },
              {
                "kind": "account",
                "path": "wager.integrator",
                "account": "Wager"
              },
              {
                "kind": "account",
                "path": "wager.nonce",
                "account": "Wager"
              }
            ]
          }
        },
        {
          "name": "vrf_payer",
          "writable": true,
          "pda": {
            "seeds": [
              {
                "kind": "const",
                "value": [
                  118,
                  114,
                  102,
                  45,
                  112,
                  97,
                  121,
                  101,
                  114
                ]
              },
              {
                "kind": "account",
                "path": "wager"
              }
            ]
          }
        },
        {
          "name": "randomness",
          "docs": [
            "any account when the wager was never requested."
          ]
        },
        {
          "name": "payer",
          "writable": true
        },
        {
          "name": "system_program",
          "address": "11111111111111111111111111111111"
        },
        {
          "name": "event_authority"
        },
        {
          "name": "program"
        }
      ],
      "args": []
    },
    {
      "name": "initialize",
      "docs": [
        "One-time setup by the program's upgrade authority; seeds the strike fund."
      ],
      "discriminator": [
        175,
        175,
        109,
        31,
        13,
        152,
        155,
        237
      ],
      "accounts": [
        {
          "name": "payer",
          "docs": [
            "Must be the program's upgrade authority: the one party that could",
            "already do anything, so no new trust is created. Pays every rent and",
            "seeds the strike fund."
          ],
          "writable": true,
          "signer": true
        },
        {
          "name": "fade_program",
          "address": "2jZZEa56EtYm2hdstDrYZPYw1phAUny25k9GKAWKNFq4"
        },
        {
          "name": "program_data"
        },
        {
          "name": "config",
          "writable": true,
          "pda": {
            "seeds": [
              {
                "kind": "const",
                "value": [
                  99,
                  111,
                  110,
                  102,
                  105,
                  103
                ]
              }
            ]
          }
        },
        {
          "name": "pool",
          "writable": true,
          "pda": {
            "seeds": [
              {
                "kind": "const",
                "value": [
                  112,
                  111,
                  111,
                  108
                ]
              }
            ]
          }
        },
        {
          "name": "queue",
          "writable": true,
          "pda": {
            "seeds": [
              {
                "kind": "const",
                "value": [
                  113,
                  117,
                  101,
                  117,
                  101
                ]
              }
            ]
          }
        },
        {
          "name": "vault_authority",
          "pda": {
            "seeds": [
              {
                "kind": "const",
                "value": [
                  118,
                  97,
                  117,
                  108,
                  116,
                  45,
                  97,
                  117,
                  116,
                  104,
                  111,
                  114,
                  105,
                  116,
                  121
                ]
              }
            ]
          }
        },
        {
          "name": "usdc_mint",
          "docs": [
            "`Account<Mint>` of the legacy token module: a Token-2022 mint fails the owner check."
          ],
          "address": "E4XYMYALrvMX19P6TxqKXe8ZYGxfj2CjMub6c2ZficTv"
        },
        {
          "name": "vault_usdc",
          "writable": true,
          "pda": {
            "seeds": [
              {
                "kind": "const",
                "value": [
                  117,
                  115,
                  100,
                  99,
                  45,
                  118,
                  97,
                  117,
                  108,
                  116
                ]
              }
            ]
          }
        },
        {
          "name": "payout_escrow",
          "writable": true,
          "pda": {
            "seeds": [
              {
                "kind": "const",
                "value": [
                  112,
                  97,
                  121,
                  111,
                  117,
                  116,
                  45,
                  101,
                  115,
                  99,
                  114,
                  111,
                  119
                ]
              }
            ]
          }
        },
        {
          "name": "deposit_queue_usdc",
          "writable": true,
          "pda": {
            "seeds": [
              {
                "kind": "const",
                "value": [
                  100,
                  101,
                  112,
                  111,
                  115,
                  105,
                  116,
                  45,
                  113,
                  117,
                  101,
                  117,
                  101
                ]
              }
            ]
          }
        },
        {
          "name": "payable_usdc",
          "writable": true,
          "pda": {
            "seeds": [
              {
                "kind": "const",
                "value": [
                  112,
                  97,
                  121,
                  97,
                  98,
                  108,
                  101
                ]
              }
            ]
          }
        },
        {
          "name": "share_mint",
          "writable": true,
          "pda": {
            "seeds": [
              {
                "kind": "const",
                "value": [
                  115,
                  104,
                  97,
                  114,
                  101,
                  115
                ]
              }
            ]
          }
        },
        {
          "name": "share_escrow",
          "writable": true,
          "pda": {
            "seeds": [
              {
                "kind": "const",
                "value": [
                  115,
                  104,
                  97,
                  114,
                  101,
                  45,
                  101,
                  115,
                  99,
                  114,
                  111,
                  119
                ]
              }
            ]
          }
        },
        {
          "name": "share_claims",
          "writable": true,
          "pda": {
            "seeds": [
              {
                "kind": "const",
                "value": [
                  115,
                  104,
                  97,
                  114,
                  101,
                  45,
                  99,
                  108,
                  97,
                  105,
                  109,
                  115
                ]
              }
            ]
          }
        },
        {
          "name": "protocol_treasury",
          "docs": [
            "Where the protocol fee goes. Any USDC token account; its owner is the council's business."
          ]
        },
        {
          "name": "token_program",
          "address": "TokenkegQfeZyiNwAJbNbGKPFXCWuBvf9Ss623VQ5DA"
        },
        {
          "name": "system_program",
          "address": "11111111111111111111111111111111"
        },
        {
          "name": "event_authority"
        },
        {
          "name": "program"
        }
      ],
      "args": [
        {
          "name": "council",
          "type": "pubkey"
        },
        {
          "name": "guardian",
          "type": "pubkey"
        },
        {
          "name": "params",
          "type": {
            "defined": {
              "name": "RiskParams"
            }
          }
        }
      ]
    },
    {
      "name": "open_wager",
      "docs": [
        "Signed by the integrator (a program over CPI with its `[\"fade-integrator\"]`",
        "PDA, or a server or wallet) and by the owner of the stake's source."
      ],
      "discriminator": [
        162,
        239,
        162,
        130,
        22,
        133,
        143,
        161
      ],
      "accounts": [
        {
          "name": "integrator_authority",
          "docs": [
            "The integrator's identity: a program signs with its `[\"fade-integrator\"]`",
            "PDA through `invoke_signed`, a server or a wallet with its own key."
          ],
          "signer": true
        },
        {
          "name": "payer",
          "docs": [
            "Pays the wager's rent, the oracle prefund and the crank fee; receives",
            "every refund when the wager closes."
          ],
          "writable": true,
          "signer": true
        },
        {
          "name": "stake_owner",
          "docs": [
            "Owns the stake's source account and signs this very instruction: the",
            "user, or an app staking funds it holds for its users or its own budget."
          ],
          "signer": true
        },
        {
          "name": "stake_source",
          "writable": true
        },
        {
          "name": "config",
          "pda": {
            "seeds": [
              {
                "kind": "const",
                "value": [
                  99,
                  111,
                  110,
                  102,
                  105,
                  103
                ]
              }
            ]
          }
        },
        {
          "name": "pool",
          "writable": true,
          "pda": {
            "seeds": [
              {
                "kind": "const",
                "value": [
                  112,
                  111,
                  111,
                  108
                ]
              }
            ]
          }
        },
        {
          "name": "integrator",
          "docs": [
            "Created by the integrator's first wager; never re-initialised, never closed."
          ],
          "writable": true,
          "pda": {
            "seeds": [
              {
                "kind": "const",
                "value": [
                  105,
                  110,
                  116,
                  101,
                  103,
                  114,
                  97,
                  116,
                  111,
                  114
                ]
              },
              {
                "kind": "account",
                "path": "integrator_authority"
              }
            ]
          }
        },
        {
          "name": "fee_account",
          "docs": [
            "that it may be the stake's own source: a user acting as its own",
            "integrator. Stored by the first wager, and must equal the stored one after."
          ],
          "writable": true
        },
        {
          "name": "protocol_treasury",
          "writable": true
        },
        {
          "name": "vault_usdc",
          "writable": true,
          "pda": {
            "seeds": [
              {
                "kind": "const",
                "value": [
                  117,
                  115,
                  100,
                  99,
                  45,
                  118,
                  97,
                  117,
                  108,
                  116
                ]
              }
            ]
          }
        },
        {
          "name": "beneficiary",
          "docs": [
            "Any legacy-SPL USDC account; stored, and the only place a payout can go."
          ]
        },
        {
          "name": "wager",
          "docs": [
            "Never `init_if_needed`: the address is nonce-scoped and one-shot."
          ],
          "writable": true,
          "pda": {
            "seeds": [
              {
                "kind": "const",
                "value": [
                  119,
                  97,
                  103,
                  101,
                  114
                ]
              },
              {
                "kind": "account",
                "path": "integrator"
              },
              {
                "kind": "arg",
                "path": "nonce"
              }
            ]
          }
        },
        {
          "name": "vrf_payer",
          "writable": true,
          "pda": {
            "seeds": [
              {
                "kind": "const",
                "value": [
                  118,
                  114,
                  102,
                  45,
                  112,
                  97,
                  121,
                  101,
                  114
                ]
              },
              {
                "kind": "account",
                "path": "wager"
              }
            ]
          }
        },
        {
          "name": "orao_network_state",
          "docs": [
            "owner checked in the handler; the fee is read from it, never set by Fade."
          ],
          "pda": {
            "seeds": [
              {
                "kind": "const",
                "value": [
                  111,
                  114,
                  97,
                  111,
                  45,
                  118,
                  114,
                  102,
                  45,
                  110,
                  101,
                  116,
                  119,
                  111,
                  114,
                  107,
                  45,
                  99,
                  111,
                  110,
                  102,
                  105,
                  103,
                  117,
                  114,
                  97,
                  116,
                  105,
                  111,
                  110
                ]
              }
            ],
            "program": {
              "kind": "const",
              "value": [
                7,
                71,
                177,
                26,
                250,
                145,
                180,
                209,
                249,
                34,
                242,
                123,
                14,
                186,
                193,
                218,
                178,
                59,
                33,
                41,
                164,
                190,
                243,
                79,
                50,
                164,
                123,
                88,
                245,
                206,
                252,
                120
              ]
            }
          }
        },
        {
          "name": "usdc_mint"
        },
        {
          "name": "token_program",
          "address": "TokenkegQfeZyiNwAJbNbGKPFXCWuBvf9Ss623VQ5DA"
        },
        {
          "name": "system_program",
          "address": "11111111111111111111111111111111"
        },
        {
          "name": "event_authority"
        },
        {
          "name": "program"
        }
      ],
      "args": [
        {
          "name": "stake",
          "type": "u64"
        },
        {
          "name": "paytable",
          "type": {
            "vec": {
              "defined": {
                "name": "Bucket"
              }
            }
          }
        },
        {
          "name": "integrator_fee_bps",
          "type": "u64"
        },
        {
          "name": "nonce",
          "type": "u64"
        }
      ]
    },
    {
      "name": "request_deposit",
      "discriminator": [
        243,
        202,
        197,
        215,
        135,
        97,
        213,
        109
      ],
      "accounts": [
        {
          "name": "owner",
          "writable": true,
          "signer": true
        },
        {
          "name": "owner_usdc",
          "writable": true
        },
        {
          "name": "owner_shares",
          "docs": [
            "Where the claim will pay the shares: the owner's canonical account,",
            "created now so that no keeper ever advances someone else's rent."
          ],
          "writable": true,
          "pda": {
            "seeds": [
              {
                "kind": "account",
                "path": "owner"
              },
              {
                "kind": "account",
                "path": "token_program"
              },
              {
                "kind": "account",
                "path": "share_mint"
              }
            ],
            "program": {
              "kind": "const",
              "value": [
                140,
                151,
                37,
                143,
                78,
                36,
                137,
                241,
                187,
                61,
                16,
                41,
                20,
                142,
                13,
                131,
                11,
                90,
                19,
                153,
                218,
                255,
                16,
                132,
                4,
                142,
                123,
                216,
                219,
                233,
                248,
                89
              ]
            }
          }
        },
        {
          "name": "config",
          "pda": {
            "seeds": [
              {
                "kind": "const",
                "value": [
                  99,
                  111,
                  110,
                  102,
                  105,
                  103
                ]
              }
            ]
          }
        },
        {
          "name": "queue",
          "writable": true,
          "pda": {
            "seeds": [
              {
                "kind": "const",
                "value": [
                  113,
                  117,
                  101,
                  117,
                  101
                ]
              }
            ]
          }
        },
        {
          "name": "pool",
          "docs": [
            "Only needed when this request opens an epoch."
          ],
          "writable": true,
          "optional": true,
          "pda": {
            "seeds": [
              {
                "kind": "const",
                "value": [
                  112,
                  111,
                  111,
                  108
                ]
              }
            ]
          }
        },
        {
          "name": "deposit_queue_usdc",
          "writable": true,
          "pda": {
            "seeds": [
              {
                "kind": "const",
                "value": [
                  100,
                  101,
                  112,
                  111,
                  115,
                  105,
                  116,
                  45,
                  113,
                  117,
                  101,
                  117,
                  101
                ]
              }
            ]
          }
        },
        {
          "name": "share_mint",
          "pda": {
            "seeds": [
              {
                "kind": "const",
                "value": [
                  115,
                  104,
                  97,
                  114,
                  101,
                  115
                ]
              }
            ]
          }
        },
        {
          "name": "usdc_mint"
        },
        {
          "name": "clock",
          "address": "SysvarC1ock11111111111111111111111111111111"
        },
        {
          "name": "request",
          "docs": [
            "The epoch is the one the program computes from the queue and the clock,",
            "never an argument: a caller-chosen epoch would choose its price."
          ],
          "writable": true,
          "pda": {
            "seeds": [
              {
                "kind": "const",
                "value": [
                  100,
                  101,
                  112,
                  111,
                  115,
                  105,
                  116
                ]
              },
              {
                "kind": "account",
                "path": "queue.joining_epoch_id(clock.unix_timestamp)",
                "account": "Queue"
              },
              {
                "kind": "account",
                "path": "owner"
              }
            ]
          }
        },
        {
          "name": "instructions",
          "address": "Sysvar1nstructions1111111111111111111111111"
        },
        {
          "name": "token_program",
          "address": "TokenkegQfeZyiNwAJbNbGKPFXCWuBvf9Ss623VQ5DA"
        },
        {
          "name": "associated_token_program",
          "address": "ATokenGPvbdGVxr1b2hvZbsiqW5xWH25efTNsLJA8knL"
        },
        {
          "name": "system_program",
          "address": "11111111111111111111111111111111"
        },
        {
          "name": "event_authority"
        },
        {
          "name": "program"
        }
      ],
      "args": [
        {
          "name": "amount",
          "type": "u64"
        }
      ]
    },
    {
      "name": "request_randomness",
      "docs": [
        "Anyone, from two slots after the open until `T_SETTLE`."
      ],
      "discriminator": [
        213,
        5,
        173,
        166,
        37,
        236,
        31,
        18
      ],
      "accounts": [
        {
          "name": "caller",
          "docs": [
            "Anyone; receives the requester's share of the crank fee."
          ],
          "writable": true,
          "signer": true
        },
        {
          "name": "wager",
          "writable": true,
          "pda": {
            "seeds": [
              {
                "kind": "const",
                "value": [
                  119,
                  97,
                  103,
                  101,
                  114
                ]
              },
              {
                "kind": "account",
                "path": "wager.integrator",
                "account": "Wager"
              },
              {
                "kind": "account",
                "path": "wager.nonce",
                "account": "Wager"
              }
            ]
          }
        },
        {
          "name": "vrf_payer",
          "writable": true,
          "pda": {
            "seeds": [
              {
                "kind": "const",
                "value": [
                  118,
                  114,
                  102,
                  45,
                  112,
                  97,
                  121,
                  101,
                  114
                ]
              },
              {
                "kind": "account",
                "path": "wager"
              }
            ]
          }
        },
        {
          "name": "slot_hashes",
          "address": "SysvarS1otHashes111111111111111111111111111"
        },
        {
          "name": "orao_network_state",
          "writable": true,
          "pda": {
            "seeds": [
              {
                "kind": "const",
                "value": [
                  111,
                  114,
                  97,
                  111,
                  45,
                  118,
                  114,
                  102,
                  45,
                  110,
                  101,
                  116,
                  119,
                  111,
                  114,
                  107,
                  45,
                  99,
                  111,
                  110,
                  102,
                  105,
                  103,
                  117,
                  114,
                  97,
                  116,
                  105,
                  111,
                  110
                ]
              }
            ],
            "program": {
              "kind": "const",
              "value": [
                7,
                71,
                177,
                26,
                250,
                145,
                180,
                209,
                249,
                34,
                242,
                123,
                14,
                186,
                193,
                218,
                178,
                59,
                33,
                41,
                164,
                190,
                243,
                79,
                50,
                164,
                123,
                88,
                245,
                206,
                252,
                120
              ]
            }
          }
        },
        {
          "name": "orao_treasury",
          "writable": true
        },
        {
          "name": "request",
          "writable": true
        },
        {
          "name": "orao_program",
          "address": "VRFzZoJdhFWL8rkvu87LpKM3RbcVezpMEc6X5GVDr7y"
        },
        {
          "name": "system_program",
          "address": "11111111111111111111111111111111"
        },
        {
          "name": "event_authority"
        },
        {
          "name": "program"
        }
      ],
      "args": []
    },
    {
      "name": "request_withdraw",
      "discriminator": [
        137,
        95,
        187,
        96,
        250,
        138,
        31,
        182
      ],
      "accounts": [
        {
          "name": "owner",
          "writable": true,
          "signer": true
        },
        {
          "name": "owner_shares",
          "writable": true
        },
        {
          "name": "owner_usdc",
          "docs": [
            "Where the claim will pay the USDC: the owner's canonical account."
          ],
          "writable": true,
          "pda": {
            "seeds": [
              {
                "kind": "account",
                "path": "owner"
              },
              {
                "kind": "account",
                "path": "token_program"
              },
              {
                "kind": "account",
                "path": "usdc_mint"
              }
            ],
            "program": {
              "kind": "const",
              "value": [
                140,
                151,
                37,
                143,
                78,
                36,
                137,
                241,
                187,
                61,
                16,
                41,
                20,
                142,
                13,
                131,
                11,
                90,
                19,
                153,
                218,
                255,
                16,
                132,
                4,
                142,
                123,
                216,
                219,
                233,
                248,
                89
              ]
            }
          }
        },
        {
          "name": "config",
          "pda": {
            "seeds": [
              {
                "kind": "const",
                "value": [
                  99,
                  111,
                  110,
                  102,
                  105,
                  103
                ]
              }
            ]
          }
        },
        {
          "name": "queue",
          "writable": true,
          "pda": {
            "seeds": [
              {
                "kind": "const",
                "value": [
                  113,
                  117,
                  101,
                  117,
                  101
                ]
              }
            ]
          }
        },
        {
          "name": "pool",
          "docs": [
            "Only needed when this request opens an epoch."
          ],
          "writable": true,
          "optional": true,
          "pda": {
            "seeds": [
              {
                "kind": "const",
                "value": [
                  112,
                  111,
                  111,
                  108
                ]
              }
            ]
          }
        },
        {
          "name": "share_escrow",
          "writable": true,
          "pda": {
            "seeds": [
              {
                "kind": "const",
                "value": [
                  115,
                  104,
                  97,
                  114,
                  101,
                  45,
                  101,
                  115,
                  99,
                  114,
                  111,
                  119
                ]
              }
            ]
          }
        },
        {
          "name": "share_mint",
          "pda": {
            "seeds": [
              {
                "kind": "const",
                "value": [
                  115,
                  104,
                  97,
                  114,
                  101,
                  115
                ]
              }
            ]
          }
        },
        {
          "name": "usdc_mint"
        },
        {
          "name": "clock",
          "address": "SysvarC1ock11111111111111111111111111111111"
        },
        {
          "name": "request",
          "writable": true,
          "pda": {
            "seeds": [
              {
                "kind": "const",
                "value": [
                  119,
                  105,
                  116,
                  104,
                  100,
                  114,
                  97,
                  119
                ]
              },
              {
                "kind": "account",
                "path": "queue.joining_epoch_id(clock.unix_timestamp)",
                "account": "Queue"
              },
              {
                "kind": "account",
                "path": "owner"
              }
            ]
          }
        },
        {
          "name": "instructions",
          "address": "Sysvar1nstructions1111111111111111111111111"
        },
        {
          "name": "token_program",
          "address": "TokenkegQfeZyiNwAJbNbGKPFXCWuBvf9Ss623VQ5DA"
        },
        {
          "name": "associated_token_program",
          "address": "ATokenGPvbdGVxr1b2hvZbsiqW5xWH25efTNsLJA8knL"
        },
        {
          "name": "system_program",
          "address": "11111111111111111111111111111111"
        },
        {
          "name": "event_authority"
        },
        {
          "name": "program"
        }
      ],
      "args": [
        {
          "name": "shares",
          "type": "u64"
        }
      ]
    },
    {
      "name": "set_fee_account",
      "docs": [
        "Signed by the integrator's authority: the only way to move its fee."
      ],
      "discriminator": [
        95,
        69,
        153,
        152,
        138,
        184,
        199,
        203
      ],
      "accounts": [
        {
          "name": "integrator_authority",
          "signer": true
        },
        {
          "name": "config",
          "pda": {
            "seeds": [
              {
                "kind": "const",
                "value": [
                  99,
                  111,
                  110,
                  102,
                  105,
                  103
                ]
              }
            ]
          }
        },
        {
          "name": "integrator",
          "writable": true,
          "pda": {
            "seeds": [
              {
                "kind": "const",
                "value": [
                  105,
                  110,
                  116,
                  101,
                  103,
                  114,
                  97,
                  116,
                  111,
                  114
                ]
              },
              {
                "kind": "account",
                "path": "integrator_authority"
              }
            ]
          }
        },
        {
          "name": "fee_account",
          "docs": [
            "Any USDC account: an integrator may route its fee anywhere."
          ]
        },
        {
          "name": "event_authority"
        },
        {
          "name": "program"
        }
      ],
      "args": []
    },
    {
      "name": "set_params",
      "docs": [
        "Council only. Applies at once if every change tightens, otherwise queues",
        "it behind the longest delay of the fields it loosens."
      ],
      "discriminator": [
        27,
        234,
        178,
        52,
        147,
        2,
        187,
        141
      ],
      "accounts": [
        {
          "name": "council",
          "signer": true
        },
        {
          "name": "config",
          "writable": true,
          "pda": {
            "seeds": [
              {
                "kind": "const",
                "value": [
                  99,
                  111,
                  110,
                  102,
                  105,
                  103
                ]
              }
            ]
          }
        },
        {
          "name": "protocol_treasury",
          "docs": [
            "The treasury the change sets; the current one to leave it alone."
          ]
        },
        {
          "name": "event_authority"
        },
        {
          "name": "program"
        }
      ],
      "args": [
        {
          "name": "params",
          "type": {
            "defined": {
              "name": "RiskParams"
            }
          }
        }
      ]
    },
    {
      "name": "set_pause_flags",
      "docs": [
        "The guardian may only set flags; the council may also clear them."
      ],
      "discriminator": [
        205,
        167,
        85,
        237,
        144,
        202,
        248,
        175
      ],
      "accounts": [
        {
          "name": "authority",
          "docs": [
            "The guardian or the council."
          ],
          "signer": true
        },
        {
          "name": "config",
          "writable": true,
          "pda": {
            "seeds": [
              {
                "kind": "const",
                "value": [
                  99,
                  111,
                  110,
                  102,
                  105,
                  103
                ]
              }
            ]
          }
        },
        {
          "name": "integrator",
          "docs": [
            "The integrator whose own pause changes, if any."
          ],
          "writable": true,
          "optional": true,
          "pda": {
            "seeds": [
              {
                "kind": "const",
                "value": [
                  105,
                  110,
                  116,
                  101,
                  103,
                  114,
                  97,
                  116,
                  111,
                  114
                ]
              },
              {
                "kind": "account",
                "path": "integrator.authority",
                "account": "Integrator"
              }
            ]
          }
        },
        {
          "name": "event_authority"
        },
        {
          "name": "program"
        }
      ],
      "args": [
        {
          "name": "pause_flags",
          "type": "u8"
        },
        {
          "name": "integrator_paused",
          "type": {
            "option": "bool"
          }
        }
      ]
    },
    {
      "name": "settle_wager",
      "docs": [
        "Anyone, once ORAO has fulfilled; no deadline."
      ],
      "discriminator": [
        161,
        242,
        169,
        152,
        172,
        163,
        161,
        104
      ],
      "accounts": [
        {
          "name": "caller",
          "docs": [
            "Anyone, once ORAO has fulfilled; receives the settler's share of the crank fee."
          ],
          "writable": true,
          "signer": true
        },
        {
          "name": "config",
          "pda": {
            "seeds": [
              {
                "kind": "const",
                "value": [
                  99,
                  111,
                  110,
                  102,
                  105,
                  103
                ]
              }
            ]
          }
        },
        {
          "name": "pool",
          "writable": true,
          "pda": {
            "seeds": [
              {
                "kind": "const",
                "value": [
                  112,
                  111,
                  111,
                  108
                ]
              }
            ]
          }
        },
        {
          "name": "integrator",
          "writable": true
        },
        {
          "name": "wager",
          "writable": true,
          "pda": {
            "seeds": [
              {
                "kind": "const",
                "value": [
                  119,
                  97,
                  103,
                  101,
                  114
                ]
              },
              {
                "kind": "account",
                "path": "wager.integrator",
                "account": "Wager"
              },
              {
                "kind": "account",
                "path": "wager.nonce",
                "account": "Wager"
              }
            ]
          }
        },
        {
          "name": "vrf_payer",
          "writable": true,
          "pda": {
            "seeds": [
              {
                "kind": "const",
                "value": [
                  118,
                  114,
                  102,
                  45,
                  112,
                  97,
                  121,
                  101,
                  114
                ]
              },
              {
                "kind": "account",
                "path": "wager"
              }
            ]
          }
        },
        {
          "name": "randomness"
        },
        {
          "name": "beneficiary",
          "writable": true
        },
        {
          "name": "payout_escrow",
          "writable": true,
          "pda": {
            "seeds": [
              {
                "kind": "const",
                "value": [
                  112,
                  97,
                  121,
                  111,
                  117,
                  116,
                  45,
                  101,
                  115,
                  99,
                  114,
                  111,
                  119
                ]
              }
            ]
          }
        },
        {
          "name": "vault_usdc",
          "writable": true,
          "pda": {
            "seeds": [
              {
                "kind": "const",
                "value": [
                  117,
                  115,
                  100,
                  99,
                  45,
                  118,
                  97,
                  117,
                  108,
                  116
                ]
              }
            ]
          }
        },
        {
          "name": "vault_authority",
          "pda": {
            "seeds": [
              {
                "kind": "const",
                "value": [
                  118,
                  97,
                  117,
                  108,
                  116,
                  45,
                  97,
                  117,
                  116,
                  104,
                  111,
                  114,
                  105,
                  116,
                  121
                ]
              }
            ]
          }
        },
        {
          "name": "payer",
          "writable": true
        },
        {
          "name": "usdc_mint"
        },
        {
          "name": "token_program",
          "address": "TokenkegQfeZyiNwAJbNbGKPFXCWuBvf9Ss623VQ5DA"
        },
        {
          "name": "system_program",
          "address": "11111111111111111111111111111111"
        },
        {
          "name": "event_authority"
        },
        {
          "name": "program"
        }
      ],
      "args": []
    },
    {
      "name": "strike_epoch",
      "docs": [
        "Anyone, once the live epoch has closed and no wager opened before the",
        "close is still open."
      ],
      "discriminator": [
        142,
        118,
        147,
        245,
        251,
        183,
        34,
        93
      ],
      "accounts": [
        {
          "name": "caller",
          "docs": [
            "Anyone; advances the record's rent, which the strike fund reimburses,",
            "and receives `STRIKE_REWARD` from the fund."
          ],
          "writable": true,
          "signer": true
        },
        {
          "name": "config",
          "pda": {
            "seeds": [
              {
                "kind": "const",
                "value": [
                  99,
                  111,
                  110,
                  102,
                  105,
                  103
                ]
              }
            ]
          }
        },
        {
          "name": "queue",
          "writable": true,
          "pda": {
            "seeds": [
              {
                "kind": "const",
                "value": [
                  113,
                  117,
                  101,
                  117,
                  101
                ]
              }
            ]
          }
        },
        {
          "name": "pool",
          "writable": true,
          "pda": {
            "seeds": [
              {
                "kind": "const",
                "value": [
                  112,
                  111,
                  111,
                  108
                ]
              }
            ]
          }
        },
        {
          "name": "record",
          "docs": [
            "Written once; afterwards only its count of pending readers changes."
          ],
          "writable": true,
          "pda": {
            "seeds": [
              {
                "kind": "const",
                "value": [
                  101,
                  112,
                  111,
                  99,
                  104
                ]
              },
              {
                "kind": "account",
                "path": "queue.current.epoch_id",
                "account": "Queue"
              }
            ]
          }
        },
        {
          "name": "deposit_queue_usdc",
          "writable": true,
          "pda": {
            "seeds": [
              {
                "kind": "const",
                "value": [
                  100,
                  101,
                  112,
                  111,
                  115,
                  105,
                  116,
                  45,
                  113,
                  117,
                  101,
                  117,
                  101
                ]
              }
            ]
          }
        },
        {
          "name": "vault_usdc",
          "writable": true,
          "pda": {
            "seeds": [
              {
                "kind": "const",
                "value": [
                  117,
                  115,
                  100,
                  99,
                  45,
                  118,
                  97,
                  117,
                  108,
                  116
                ]
              }
            ]
          }
        },
        {
          "name": "payable_usdc",
          "writable": true,
          "pda": {
            "seeds": [
              {
                "kind": "const",
                "value": [
                  112,
                  97,
                  121,
                  97,
                  98,
                  108,
                  101
                ]
              }
            ]
          }
        },
        {
          "name": "share_mint",
          "writable": true,
          "pda": {
            "seeds": [
              {
                "kind": "const",
                "value": [
                  115,
                  104,
                  97,
                  114,
                  101,
                  115
                ]
              }
            ]
          }
        },
        {
          "name": "share_escrow",
          "writable": true,
          "pda": {
            "seeds": [
              {
                "kind": "const",
                "value": [
                  115,
                  104,
                  97,
                  114,
                  101,
                  45,
                  101,
                  115,
                  99,
                  114,
                  111,
                  119
                ]
              }
            ]
          }
        },
        {
          "name": "share_claims",
          "writable": true,
          "pda": {
            "seeds": [
              {
                "kind": "const",
                "value": [
                  115,
                  104,
                  97,
                  114,
                  101,
                  45,
                  99,
                  108,
                  97,
                  105,
                  109,
                  115
                ]
              }
            ]
          }
        },
        {
          "name": "vault_authority",
          "pda": {
            "seeds": [
              {
                "kind": "const",
                "value": [
                  118,
                  97,
                  117,
                  108,
                  116,
                  45,
                  97,
                  117,
                  116,
                  104,
                  111,
                  114,
                  105,
                  116,
                  121
                ]
              }
            ]
          }
        },
        {
          "name": "usdc_mint"
        },
        {
          "name": "token_program",
          "address": "TokenkegQfeZyiNwAJbNbGKPFXCWuBvf9Ss623VQ5DA"
        },
        {
          "name": "system_program",
          "address": "11111111111111111111111111111111"
        },
        {
          "name": "event_authority"
        },
        {
          "name": "program"
        }
      ],
      "args": []
    }
  ],
  "accounts": [
    {
      "name": "Config",
      "discriminator": [
        155,
        12,
        170,
        224,
        30,
        250,
        204,
        130
      ]
    },
    {
      "name": "DepositRequest",
      "discriminator": [
        86,
        27,
        56,
        8,
        25,
        62,
        62,
        243
      ]
    },
    {
      "name": "EpochRecord",
      "discriminator": [
        193,
        72,
        26,
        28,
        161,
        98,
        58,
        132
      ]
    },
    {
      "name": "Integrator",
      "discriminator": [
        188,
        141,
        128,
        161,
        231,
        248,
        0,
        128
      ]
    },
    {
      "name": "Pool",
      "discriminator": [
        241,
        154,
        109,
        4,
        17,
        177,
        109,
        188
      ]
    },
    {
      "name": "Queue",
      "discriminator": [
        204,
        167,
        6,
        247,
        20,
        33,
        2,
        188
      ]
    },
    {
      "name": "Wager",
      "discriminator": [
        3,
        110,
        53,
        190,
        113,
        31,
        230,
        40
      ]
    },
    {
      "name": "WithdrawRequest",
      "discriminator": [
        186,
        239,
        174,
        191,
        189,
        13,
        47,
        196
      ]
    }
  ],
  "events": [
    {
      "name": "ClaimDelivered",
      "discriminator": [
        153,
        180,
        207,
        20,
        6,
        69,
        10,
        36
      ]
    },
    {
      "name": "DepositClaimed",
      "discriminator": [
        119,
        147,
        244,
        76,
        141,
        103,
        170,
        176
      ]
    },
    {
      "name": "DepositRequested",
      "discriminator": [
        35,
        33,
        229,
        138,
        116,
        238,
        192,
        22
      ]
    },
    {
      "name": "EpochStruck",
      "discriminator": [
        104,
        123,
        204,
        144,
        191,
        189,
        72,
        242
      ]
    },
    {
      "name": "FeeAccountChanged",
      "discriminator": [
        246,
        96,
        222,
        117,
        178,
        219,
        96,
        219
      ]
    },
    {
      "name": "Initialized",
      "discriminator": [
        208,
        213,
        115,
        98,
        115,
        82,
        201,
        209
      ]
    },
    {
      "name": "IntegratorCreated",
      "discriminator": [
        154,
        43,
        148,
        226,
        179,
        128,
        14,
        229
      ]
    },
    {
      "name": "ParamsApplied",
      "discriminator": [
        79,
        221,
        60,
        141,
        244,
        69,
        47,
        209
      ]
    },
    {
      "name": "ParamsCancelled",
      "discriminator": [
        160,
        167,
        193,
        145,
        11,
        138,
        30,
        120
      ]
    },
    {
      "name": "ParamsChanged",
      "discriminator": [
        174,
        49,
        9,
        64,
        58,
        171,
        241,
        24
      ]
    },
    {
      "name": "PauseFlagsChanged",
      "discriminator": [
        56,
        73,
        67,
        44,
        237,
        239,
        68,
        124
      ]
    },
    {
      "name": "PayoutClaimed",
      "discriminator": [
        200,
        39,
        105,
        112,
        116,
        63,
        58,
        149
      ]
    },
    {
      "name": "RandomnessRequested",
      "discriminator": [
        10,
        64,
        183,
        29,
        104,
        63,
        90,
        149
      ]
    },
    {
      "name": "WagerExpired",
      "discriminator": [
        149,
        156,
        140,
        134,
        209,
        167,
        171,
        62
      ]
    },
    {
      "name": "WagerOpened",
      "discriminator": [
        69,
        93,
        14,
        232,
        77,
        79,
        50,
        130
      ]
    },
    {
      "name": "WagerSettled",
      "discriminator": [
        180,
        216,
        101,
        152,
        154,
        154,
        136,
        153
      ]
    },
    {
      "name": "WithdrawClaimed",
      "discriminator": [
        77,
        130,
        89,
        38,
        239,
        172,
        174,
        85
      ]
    },
    {
      "name": "WithdrawRequested",
      "discriminator": [
        114,
        16,
        240,
        206,
        93,
        128,
        151,
        39
      ]
    }
  ],
  "errors": [
    {
      "code": 6000,
      "name": "NotUpgradeAuthority",
      "msg": "signer is not the program's upgrade authority"
    },
    {
      "code": 6001,
      "name": "InvalidParams",
      "msg": "parameters are out of range"
    },
    {
      "code": 6002,
      "name": "Paused",
      "msg": "this operation is paused"
    },
    {
      "code": 6003,
      "name": "NotCouncil",
      "msg": "signer is not the council"
    },
    {
      "code": 6004,
      "name": "NotGuardian",
      "msg": "signer is neither the council nor the guardian"
    },
    {
      "code": 6005,
      "name": "GuardianCannotUnpause",
      "msg": "the guardian may only set pause flags, never clear them"
    },
    {
      "code": 6006,
      "name": "NoPendingChange",
      "msg": "no parameter change is pending"
    },
    {
      "code": 6007,
      "name": "ChangeNotDue",
      "msg": "the pending parameter change is not due yet"
    },
    {
      "code": 6008,
      "name": "WrongMint",
      "msg": "wrong mint"
    },
    {
      "code": 6009,
      "name": "MathOverflow",
      "msg": "arithmetic overflow"
    },
    {
      "code": 6010,
      "name": "ZeroAmount",
      "msg": "amount must be non-zero"
    },
    {
      "code": 6011,
      "name": "RemainingAccounts",
      "msg": "unexpected remaining accounts"
    },
    {
      "code": 6012,
      "name": "BucketCount",
      "msg": "paytable: zero buckets or more than 32"
    },
    {
      "code": 6013,
      "name": "ProbabilityRange",
      "msg": "paytable: a probability of zero or above 1"
    },
    {
      "code": 6014,
      "name": "ProbabilitySum",
      "msg": "paytable: probabilities do not sum to exactly 1"
    },
    {
      "code": 6015,
      "name": "MultiplierCeiling",
      "msg": "paytable: a multiplier above 10 000x"
    },
    {
      "code": 6016,
      "name": "PaytableOverpays",
      "msg": "paytable: pays out more than it takes in on average"
    },
    {
      "code": 6017,
      "name": "EdgeFloor",
      "msg": "paytable edge does not cover the LP floor plus the fees"
    },
    {
      "code": 6018,
      "name": "IntegratorFeeTooHigh",
      "msg": "integrator fee above the maximum"
    },
    {
      "code": 6019,
      "name": "StakeBounds",
      "msg": "stake below the minimum or above the maximum"
    },
    {
      "code": 6020,
      "name": "PerWagerCap",
      "msg": "worst-case payout above the per-wager cap"
    },
    {
      "code": 6021,
      "name": "IntegratorCap",
      "msg": "integrator exposure above its ceiling"
    },
    {
      "code": 6022,
      "name": "UtilisationBreaker",
      "msg": "utilisation breaker: the pool is too committed"
    },
    {
      "code": 6023,
      "name": "GlobalExposure",
      "msg": "reserved liability would exceed kappa of assets"
    },
    {
      "code": 6024,
      "name": "Insolvent",
      "msg": "the pool could not pay every open wager at once"
    },
    {
      "code": 6025,
      "name": "DrawdownBreaker",
      "msg": "drawdown breaker: the share price fell too far in 24 hours"
    },
    {
      "code": 6026,
      "name": "WrongNonce",
      "msg": "wager nonce must equal the integrator's next nonce"
    },
    {
      "code": 6027,
      "name": "IntegratorPaused",
      "msg": "this integrator is paused"
    },
    {
      "code": 6028,
      "name": "FeeAccountMismatch",
      "msg": "fee account differs from the integrator record"
    },
    {
      "code": 6029,
      "name": "WrongWagerStatus",
      "msg": "the wager is not in the state this instruction needs"
    },
    {
      "code": 6030,
      "name": "RequestWindow",
      "msg": "randomness may only be requested from two slots after the open until T_SETTLE"
    },
    {
      "code": 6031,
      "name": "EntropyUnavailable",
      "msg": "SlotHashes holds no slot after the open"
    },
    {
      "code": 6032,
      "name": "NetworkStateUnreadable",
      "msg": "ORAO network state could not be read"
    },
    {
      "code": 6033,
      "name": "TreasuryMismatch",
      "msg": "treasury does not match ORAO network state"
    },
    {
      "code": 6034,
      "name": "WrongRandomnessAccount",
      "msg": "randomness account is not the one bound to this wager"
    },
    {
      "code": 6035,
      "name": "NotFulfilled",
      "msg": "randomness is not fulfilled"
    },
    {
      "code": 6036,
      "name": "AlreadyFulfilled",
      "msg": "randomness is fulfilled: settle, do not expire"
    },
    {
      "code": 6037,
      "name": "NotExpired",
      "msg": "T_SETTLE has not elapsed"
    },
    {
      "code": 6038,
      "name": "DrawFailed",
      "msg": "no outcome could be drawn"
    },
    {
      "code": 6039,
      "name": "BeneficiaryMismatch",
      "msg": "beneficiary differs from the one stored at open"
    },
    {
      "code": 6040,
      "name": "NoLiveEpoch",
      "msg": "no epoch is live"
    },
    {
      "code": 6041,
      "name": "EpochNotClosed",
      "msg": "the epoch has not closed yet"
    },
    {
      "code": 6042,
      "name": "StrikeNotClean",
      "msg": "a wager opened before the close is still open"
    },
    {
      "code": 6043,
      "name": "BelowMinimum",
      "msg": "request below the minimum"
    },
    {
      "code": 6044,
      "name": "FirstDepositTooSmall",
      "msg": "a first deposit must be at least min_first_deposit"
    },
    {
      "code": 6045,
      "name": "ForbiddenComposition",
      "msg": "a top-level instruction of this transaction is not allowed with a request"
    },
    {
      "code": 6046,
      "name": "WrongRecord",
      "msg": "the record does not belong to this request's epoch or chain"
    },
    {
      "code": 6047,
      "name": "EntryRecordRequired",
      "msg": "the epoch record of the request's entry is required"
    },
    {
      "code": 6048,
      "name": "RentReceiverRequired",
      "msg": "the account that advanced the record's rent is required"
    },
    {
      "code": 6049,
      "name": "NothingToClaim",
      "msg": "nothing to claim yet"
    },
    {
      "code": 6050,
      "name": "WrongOwner",
      "msg": "wrong owner"
    },
    {
      "code": 6051,
      "name": "NotStruck",
      "msg": "the request's epoch has not been struck"
    },
    {
      "code": 6052,
      "name": "PoolRequired",
      "msg": "this request opens an epoch: the pool account is required"
    },
    {
      "code": 6053,
      "name": "DestinationUnusable",
      "msg": "the owner's token account cannot receive yet"
    }
  ],
  "types": [
    {
      "name": "Bucket",
      "type": {
        "kind": "struct",
        "fields": [
          {
            "name": "p",
            "docs": [
              "Probability in 1e-9."
            ],
            "type": "u64"
          },
          {
            "name": "m",
            "docs": [
              "Multiplier in bps."
            ],
            "type": "u64"
          }
        ]
      }
    },
    {
      "name": "ClaimDelivered",
      "docs": [
        "A parked claim handed over once the owner's account could receive."
      ],
      "type": {
        "kind": "struct",
        "fields": [
          {
            "name": "version",
            "type": "u8"
          },
          {
            "name": "owner",
            "type": "pubkey"
          },
          {
            "name": "epoch_id",
            "type": "u64"
          },
          {
            "name": "deposit",
            "docs": [
              "A deposit request (shares) or a withdrawal request (USDC)."
            ],
            "type": "bool"
          },
          {
            "name": "amount",
            "type": "u64"
          }
        ]
      }
    },
    {
      "name": "Config",
      "type": {
        "kind": "struct",
        "fields": [
          {
            "name": "version",
            "type": "u8"
          },
          {
            "name": "bump",
            "type": "u8"
          },
          {
            "name": "vault_authority_bump",
            "docs": [
              "Bump of `[\"vault-authority\"]`, which owns every token account."
            ],
            "type": "u8"
          },
          {
            "name": "council",
            "docs": [
              "Parameter authority, and the only party that lifts a pause."
            ],
            "type": "pubkey"
          },
          {
            "name": "guardian",
            "docs": [
              "May only set pause flags."
            ],
            "type": "pubkey"
          },
          {
            "name": "protocol_treasury",
            "docs": [
              "USDC token account receiving the protocol fee."
            ],
            "type": "pubkey"
          },
          {
            "name": "usdc_mint",
            "type": "pubkey"
          },
          {
            "name": "pause_flags",
            "docs": [
              "Bit set: see `Config::PAUSE_*`."
            ],
            "type": "u8"
          },
          {
            "name": "params",
            "type": {
              "defined": {
                "name": "RiskParams"
              }
            }
          },
          {
            "name": "pending",
            "type": {
              "defined": {
                "name": "PendingChange"
              }
            }
          },
          {
            "name": "_reserved",
            "type": {
              "array": [
                "u8",
                128
              ]
            }
          }
        ]
      }
    },
    {
      "name": "DepositClaimed",
      "type": {
        "kind": "struct",
        "fields": [
          {
            "name": "version",
            "type": "u8"
          },
          {
            "name": "owner",
            "type": "pubkey"
          },
          {
            "name": "epoch_id",
            "type": "u64"
          },
          {
            "name": "shares",
            "type": "u64"
          },
          {
            "name": "delivered",
            "docs": [
              "The shares reached the owner; otherwise they are parked on the request."
            ],
            "type": "bool"
          }
        ]
      }
    },
    {
      "name": "DepositRequest",
      "type": {
        "kind": "struct",
        "fields": [
          {
            "name": "version",
            "type": "u8"
          },
          {
            "name": "bump",
            "type": "u8"
          },
          {
            "name": "owner",
            "type": "pubkey"
          },
          {
            "name": "epoch_id",
            "type": "u64"
          },
          {
            "name": "amount",
            "type": "u64"
          },
          {
            "name": "parked",
            "docs": [
              "Set by a claim that could not deliver: the owner's share account could",
              "not receive. The epoch's record is released; `shares_due` waits here."
            ],
            "type": "bool"
          },
          {
            "name": "shares_due",
            "type": "u64"
          }
        ]
      }
    },
    {
      "name": "DepositRequested",
      "type": {
        "kind": "struct",
        "fields": [
          {
            "name": "version",
            "type": "u8"
          },
          {
            "name": "owner",
            "type": "pubkey"
          },
          {
            "name": "epoch_id",
            "type": "u64"
          },
          {
            "name": "amount",
            "type": "u64"
          }
        ]
      }
    },
    {
      "name": "EpochRecord",
      "docs": [
        "Written once by the strike; only `pending` changes afterwards."
      ],
      "type": {
        "kind": "struct",
        "fields": [
          {
            "name": "version",
            "type": "u8"
          },
          {
            "name": "bump",
            "type": "u8"
          },
          {
            "name": "epoch_id",
            "type": "u64"
          },
          {
            "name": "close_ts",
            "type": "i64"
          },
          {
            "name": "struck_ts",
            "type": "i64"
          },
          {
            "name": "total_assets",
            "docs": [
              "The pool's settled assets and its shares at the strike, before its",
              "flows: these fix the price."
            ],
            "type": "u64"
          },
          {
            "name": "total_shares",
            "type": "u64"
          },
          {
            "name": "deposits",
            "type": "u64"
          },
          {
            "name": "shares_minted",
            "type": "u64"
          },
          {
            "name": "withdraw_shares",
            "type": "u64"
          },
          {
            "name": "assets_owed",
            "type": "u64"
          },
          {
            "name": "assets_paid",
            "type": "u64"
          },
          {
            "name": "shares_burnt",
            "type": "u64"
          },
          {
            "name": "chain_id",
            "docs": [
              "The epoch id the withdrawal chain this strike belongs to started at."
            ],
            "type": "u64"
          },
          {
            "name": "r_before",
            "type": "u128"
          },
          {
            "name": "v_before",
            "type": "u128"
          },
          {
            "name": "r_after",
            "type": "u128"
          },
          {
            "name": "v_after",
            "type": "u128"
          },
          {
            "name": "pending",
            "docs": [
              "Requests whose remaining claims still read this record."
            ],
            "type": "u32"
          },
          {
            "name": "requests",
            "docs": [
              "Requests made in this epoch."
            ],
            "type": "u32"
          },
          {
            "name": "rent_payer",
            "docs": [
              "Where the rent goes when the record closes: the queue (the strike fund",
              "advanced it) or the striker (the fund could not)."
            ],
            "type": "pubkey"
          }
        ]
      }
    },
    {
      "name": "EpochStruck",
      "type": {
        "kind": "struct",
        "fields": [
          {
            "name": "version",
            "type": "u8"
          },
          {
            "name": "epoch_id",
            "type": "u64"
          },
          {
            "name": "total_assets",
            "type": "u64"
          },
          {
            "name": "total_shares",
            "type": "u64"
          },
          {
            "name": "deposits",
            "type": "u64"
          },
          {
            "name": "shares_minted",
            "type": "u64"
          },
          {
            "name": "withdraw_shares",
            "type": "u64"
          },
          {
            "name": "assets_owed",
            "type": "u64"
          },
          {
            "name": "assets_paid",
            "type": "u64"
          },
          {
            "name": "shares_burnt",
            "type": "u64"
          },
          {
            "name": "reward",
            "type": "u64"
          }
        ]
      }
    },
    {
      "name": "FeeAccountChanged",
      "type": {
        "kind": "struct",
        "fields": [
          {
            "name": "version",
            "type": "u8"
          },
          {
            "name": "integrator",
            "type": "pubkey"
          },
          {
            "name": "fee_account",
            "type": "pubkey"
          }
        ]
      }
    },
    {
      "name": "Initialized",
      "type": {
        "kind": "struct",
        "fields": [
          {
            "name": "version",
            "type": "u8"
          },
          {
            "name": "council",
            "type": "pubkey"
          },
          {
            "name": "guardian",
            "type": "pubkey"
          },
          {
            "name": "protocol_treasury",
            "type": "pubkey"
          }
        ]
      }
    },
    {
      "name": "Integrator",
      "docs": [
        "An integrator's record, keyed on the address that signs its wagers.",
        "Never closed, so its nonce can never restart."
      ],
      "type": {
        "kind": "struct",
        "fields": [
          {
            "name": "version",
            "type": "u8"
          },
          {
            "name": "bump",
            "type": "u8"
          },
          {
            "name": "authority",
            "type": "pubkey"
          },
          {
            "name": "fee_account",
            "docs": [
              "USDC account receiving the integrator fee; changed only by `set_fee_account`."
            ],
            "type": "pubkey"
          },
          {
            "name": "reserved_liability",
            "type": "u64"
          },
          {
            "name": "open_wagers",
            "type": "u64"
          },
          {
            "name": "next_nonce",
            "type": "u64"
          },
          {
            "name": "volume_total",
            "type": "u64"
          },
          {
            "name": "paused",
            "docs": [
              "Set by the guardian or the council: this integrator's new wagers are refused."
            ],
            "type": "bool"
          },
          {
            "name": "created_at",
            "type": "i64"
          },
          {
            "name": "_reserved",
            "type": {
              "array": [
                "u8",
                64
              ]
            }
          }
        ]
      }
    },
    {
      "name": "IntegratorCreated",
      "type": {
        "kind": "struct",
        "fields": [
          {
            "name": "version",
            "type": "u8"
          },
          {
            "name": "integrator",
            "type": "pubkey"
          },
          {
            "name": "authority",
            "type": "pubkey"
          },
          {
            "name": "fee_account",
            "type": "pubkey"
          }
        ]
      }
    },
    {
      "name": "LiveEpoch",
      "docs": [
        "One live epoch in `Queue`."
      ],
      "type": {
        "kind": "struct",
        "fields": [
          {
            "name": "live",
            "type": "bool"
          },
          {
            "name": "epoch_id",
            "type": "u64"
          },
          {
            "name": "close_ts",
            "docs": [
              "0 for `next` until it is promoted."
            ],
            "type": "i64"
          },
          {
            "name": "deposits",
            "type": "u64"
          },
          {
            "name": "withdraw_shares",
            "docs": [
              "Queued withdrawal shares, including those rolled from a rationed strike."
            ],
            "type": "u64"
          },
          {
            "name": "deposit_requests",
            "type": "u32"
          },
          {
            "name": "withdraw_requests",
            "docs": [
              "New withdrawal requests of this epoch; rolled ones are counted by the chain."
            ],
            "type": "u32"
          }
        ]
      }
    },
    {
      "name": "ParamsApplied",
      "type": {
        "kind": "struct",
        "fields": [
          {
            "name": "version",
            "type": "u8"
          },
          {
            "name": "effective_at",
            "type": "i64"
          }
        ]
      }
    },
    {
      "name": "ParamsCancelled",
      "type": {
        "kind": "struct",
        "fields": [
          {
            "name": "version",
            "type": "u8"
          },
          {
            "name": "effective_at",
            "type": "i64"
          }
        ]
      }
    },
    {
      "name": "ParamsChanged",
      "docs": [
        "`set_params` applied a change at once (`effective_at` = now) or queued it."
      ],
      "type": {
        "kind": "struct",
        "fields": [
          {
            "name": "version",
            "type": "u8"
          },
          {
            "name": "applied",
            "type": "bool"
          },
          {
            "name": "effective_at",
            "type": "i64"
          }
        ]
      }
    },
    {
      "name": "PauseFlagsChanged",
      "type": {
        "kind": "struct",
        "fields": [
          {
            "name": "version",
            "type": "u8"
          },
          {
            "name": "by",
            "type": "pubkey"
          },
          {
            "name": "pause_flags",
            "type": "u8"
          },
          {
            "name": "integrator",
            "docs": [
              "The integrator whose pause changed, or the default key."
            ],
            "type": "pubkey"
          },
          {
            "name": "integrator_paused",
            "type": "bool"
          }
        ]
      }
    },
    {
      "name": "PayoutClaimed",
      "type": {
        "kind": "struct",
        "fields": [
          {
            "name": "version",
            "type": "u8"
          },
          {
            "name": "wager",
            "type": "pubkey"
          },
          {
            "name": "beneficiary",
            "type": "pubkey"
          },
          {
            "name": "payout",
            "type": "u64"
          }
        ]
      }
    },
    {
      "name": "PendingChange",
      "docs": [
        "At most one queued parameter change."
      ],
      "type": {
        "kind": "struct",
        "fields": [
          {
            "name": "active",
            "type": "bool"
          },
          {
            "name": "effective_at",
            "type": "i64"
          },
          {
            "name": "params",
            "type": {
              "defined": {
                "name": "RiskParams"
              }
            }
          },
          {
            "name": "protocol_treasury",
            "type": "pubkey"
          }
        ]
      }
    },
    {
      "name": "Pool",
      "docs": [
        "The wager side. Never written by a liquidity-provider",
        "instruction except the strike and the request that opens an epoch."
      ],
      "type": {
        "kind": "struct",
        "fields": [
          {
            "name": "version",
            "type": "u8"
          },
          {
            "name": "bump",
            "type": "u8"
          },
          {
            "name": "total_assets",
            "docs": [
              "Everything the pool owns, tracked internally: never read from a token account."
            ],
            "type": "u64"
          },
          {
            "name": "total_shares",
            "docs": [
              "Equal to the share mint's supply; only the strike mints and burns."
            ],
            "type": "u64"
          },
          {
            "name": "total_reserved_liability",
            "docs": [
              "`Σ payout_max − pool_credit` of open wagers."
            ],
            "type": "u64"
          },
          {
            "name": "open_pool_credits",
            "docs": [
              "`Σ pool_credit` of open wagers."
            ],
            "type": "u64"
          },
          {
            "name": "open_before_close",
            "docs": [
              "Open wagers opened before the live epoch's close."
            ],
            "type": "u32"
          },
          {
            "name": "open_after_close",
            "docs": [
              "Open wagers opened at or after it, or while no epoch was live."
            ],
            "type": "u32"
          },
          {
            "name": "generation",
            "type": "u32"
          },
          {
            "name": "close_ts",
            "docs": [
              "The live epoch's close, or 0."
            ],
            "type": "i64"
          },
          {
            "name": "price_maxima",
            "docs": [
              "Highest share price of each of the last 24 hours."
            ],
            "type": {
              "array": [
                "u128",
                24
              ]
            }
          },
          {
            "name": "price_head_hour",
            "type": "i64"
          },
          {
            "name": "drawdown_trip_ts",
            "docs": [
              "Last time the drawdown condition was seen holding."
            ],
            "type": "i64"
          },
          {
            "name": "volume_total",
            "docs": [
              "Cumulative stake ever opened."
            ],
            "type": "u64"
          },
          {
            "name": "integrators",
            "type": "u64"
          },
          {
            "name": "after_close_gain",
            "docs": [
              "Results of wagers opened after the live close that have already closed:",
              "what the pool gained (`pool_credit − payout`) and lost on them. A strike",
              "leaves them out of its price; they are the next epoch's."
            ],
            "type": "u64"
          },
          {
            "name": "after_close_loss",
            "type": "u64"
          },
          {
            "name": "_reserved",
            "type": {
              "array": [
                "u8",
                112
              ]
            }
          }
        ]
      }
    },
    {
      "name": "Queue",
      "docs": [
        "The liquidity-provider side. Its lamports above its own",
        "rent-exempt minimum are the strike fund."
      ],
      "type": {
        "kind": "struct",
        "fields": [
          {
            "name": "version",
            "type": "u8"
          },
          {
            "name": "bump",
            "type": "u8"
          },
          {
            "name": "current",
            "type": {
              "defined": {
                "name": "LiveEpoch"
              }
            }
          },
          {
            "name": "next",
            "type": {
              "defined": {
                "name": "LiveEpoch"
              }
            }
          },
          {
            "name": "next_epoch_id",
            "docs": [
              "The id the next epoch to be created receives. Starts at 1."
            ],
            "type": "u64"
          },
          {
            "name": "chain_id",
            "docs": [
              "The epoch id the running withdrawal chain started at, or 0."
            ],
            "type": "u64"
          },
          {
            "name": "chain_r",
            "docs": [
              "Withdrawal chain indices, `INDEX_SCALE` fixed point."
            ],
            "type": "u128"
          },
          {
            "name": "chain_v",
            "type": "u128"
          },
          {
            "name": "chain_requests",
            "docs": [
              "Withdrawal requests of struck epochs still waiting for the chain to end."
            ],
            "type": "u32"
          },
          {
            "name": "_reserved",
            "type": {
              "array": [
                "u8",
                128
              ]
            }
          }
        ]
      }
    },
    {
      "name": "RandomnessRequested",
      "type": {
        "kind": "struct",
        "fields": [
          {
            "name": "version",
            "type": "u8"
          },
          {
            "name": "wager",
            "type": "pubkey"
          },
          {
            "name": "request",
            "type": "pubkey"
          },
          {
            "name": "seed",
            "type": {
              "array": [
                "u8",
                32
              ]
            }
          },
          {
            "name": "entropy_slot",
            "type": "u64"
          }
        ]
      }
    },
    {
      "name": "RiskParams",
      "docs": [
        "Governable parameters. Settlement",
        "never reads them; everything a wager needs is snapshotted at open."
      ],
      "type": {
        "kind": "struct",
        "fields": [
          {
            "name": "kelly_fraction_bps",
            "docs": [
              "Fraction of the Kelly-optimal liability a wager may take, in bps."
            ],
            "type": "u64"
          },
          {
            "name": "censorship_bps",
            "docs": [
              "Flat ceiling on a wager's liability as a fraction of assets, in bps."
            ],
            "type": "u64"
          },
          {
            "name": "whale_bps",
            "docs": [
              "One integrator's open liability as a fraction of assets, in bps."
            ],
            "type": "u64"
          },
          {
            "name": "utilisation_breaker_bps",
            "docs": [
              "Committed fraction of assets above which new wagers are refused, in bps."
            ],
            "type": "u64"
          },
          {
            "name": "kappa_bps",
            "docs": [
              "Reserved liability as a fraction of assets never exceeded, in bps."
            ],
            "type": "u64"
          },
          {
            "name": "drawdown_bps",
            "docs": [
              "Fall of the share price within 24 hours that stops new wagers, in bps."
            ],
            "type": "u64"
          },
          {
            "name": "min_stake",
            "type": "u64"
          },
          {
            "name": "max_stake",
            "type": "u64"
          },
          {
            "name": "lp_floor_bps",
            "docs": [
              "Smallest share of the stake the pool must earn in expectation, in bps."
            ],
            "type": "u64"
          },
          {
            "name": "protocol_fee_bps",
            "docs": [
              "Taken from the stake at open, to the treasury, in bps."
            ],
            "type": "u64"
          },
          {
            "name": "max_integrator_fee_bps",
            "type": "u64"
          },
          {
            "name": "t_settle_slots",
            "docs": [
              "Slots from open after which an unfulfilled wager can be expired."
            ],
            "type": "u64"
          },
          {
            "name": "crank_request_lamports",
            "docs": [
              "Part of the crank fee paid to whoever requests the randomness, lamports."
            ],
            "type": "u64"
          },
          {
            "name": "crank_settle_lamports",
            "docs": [
              "Part of the crank fee paid to whoever settles or expires, lamports."
            ],
            "type": "u64"
          },
          {
            "name": "epoch_length_seconds",
            "type": "u64"
          },
          {
            "name": "claim_fee_lamports",
            "docs": [
              "Held in each request, paid to whoever claims it, lamports."
            ],
            "type": "u64"
          },
          {
            "name": "strike_fee_lamports",
            "docs": [
              "Paid into the strike fund by a request while the fund is below target, lamports."
            ],
            "type": "u64"
          },
          {
            "name": "strike_reward_lamports",
            "docs": [
              "Paid from the strike fund to whoever strikes an epoch, lamports."
            ],
            "type": "u64"
          },
          {
            "name": "fund_target_lamports",
            "type": "u64"
          },
          {
            "name": "min_deposit",
            "docs": [
              "Smallest deposit request, USDC base units."
            ],
            "type": "u64"
          },
          {
            "name": "min_withdraw_shares",
            "docs": [
              "Smallest withdrawal request, in share base units, unless it is the owner's whole balance."
            ],
            "type": "u64"
          },
          {
            "name": "min_first_deposit",
            "docs": [
              "Smallest deposit while no share exists."
            ],
            "type": "u64"
          },
          {
            "name": "credit_enabled",
            "type": "bool"
          },
          {
            "name": "credit_base",
            "type": "u64"
          },
          {
            "name": "credit_rate_bps",
            "type": "u64"
          }
        ]
      }
    },
    {
      "name": "Wager",
      "type": {
        "kind": "struct",
        "fields": [
          {
            "name": "version",
            "type": "u8"
          },
          {
            "name": "bump",
            "type": "u8"
          },
          {
            "name": "vrf_payer_bump",
            "type": "u8"
          },
          {
            "name": "status",
            "type": {
              "defined": {
                "name": "WagerStatus"
              }
            }
          },
          {
            "name": "integrator",
            "type": "pubkey"
          },
          {
            "name": "nonce",
            "type": "u64"
          },
          {
            "name": "payer",
            "docs": [
              "Paid the rent and the SOL; receives every refund and the rent at close."
            ],
            "type": "pubkey"
          },
          {
            "name": "beneficiary",
            "docs": [
              "Stored at open, immutable: the only account a payout can go to."
            ],
            "type": "pubkey"
          },
          {
            "name": "stake",
            "type": "u64"
          },
          {
            "name": "pool_credit",
            "type": "u64"
          },
          {
            "name": "payout_max",
            "type": "u64"
          },
          {
            "name": "reserved_liability",
            "type": "u64"
          },
          {
            "name": "cap",
            "docs": [
              "The per-wager cap that applied at open."
            ],
            "type": "u64"
          },
          {
            "name": "paytable_edge_bps",
            "type": "u64"
          },
          {
            "name": "integrator_fee_bps",
            "type": "u64"
          },
          {
            "name": "pool_edge_bps",
            "type": "u64"
          },
          {
            "name": "drawdown_bps",
            "docs": [
              "The drawdown threshold at open: settlement records a trip against it",
              "without reading live parameters."
            ],
            "type": "u64"
          },
          {
            "name": "open_slot",
            "type": "u64"
          },
          {
            "name": "open_ts",
            "type": "i64"
          },
          {
            "name": "expiry_slot",
            "docs": [
              "`open_slot + T_SETTLE`, fixed at open: after it an unfulfilled wager can be expired."
            ],
            "type": "u64"
          },
          {
            "name": "side",
            "docs": [
              "Which epoch counter the wager joined, and in which generation."
            ],
            "type": "u8"
          },
          {
            "name": "generation",
            "type": "u32"
          },
          {
            "name": "crank_request_lamports",
            "docs": [
              "Lamports of crank fee still held for the requester and the settler."
            ],
            "type": "u64"
          },
          {
            "name": "crank_settle_lamports",
            "type": "u64"
          },
          {
            "name": "randomness",
            "docs": [
              "The ORAO request account, bound by `request_randomness`."
            ],
            "type": "pubkey"
          },
          {
            "name": "entropy_slot",
            "type": "u64"
          },
          {
            "name": "entropy_hash",
            "type": {
              "array": [
                "u8",
                32
              ]
            }
          },
          {
            "name": "seed",
            "type": {
              "array": [
                "u8",
                32
              ]
            }
          },
          {
            "name": "bucket",
            "type": "u8"
          },
          {
            "name": "payout",
            "docs": [
              "Set when the payout waits in `payout_escrow`."
            ],
            "type": "u64"
          },
          {
            "name": "paytable_len",
            "type": "u8"
          },
          {
            "name": "paytable",
            "type": {
              "array": [
                {
                  "defined": {
                    "name": "Bucket"
                  }
                },
                32
              ]
            }
          }
        ]
      }
    },
    {
      "name": "WagerExpired",
      "type": {
        "kind": "struct",
        "fields": [
          {
            "name": "version",
            "type": "u8"
          },
          {
            "name": "wager",
            "type": "pubkey"
          },
          {
            "name": "integrator",
            "type": "pubkey"
          },
          {
            "name": "forfeited",
            "type": "u64"
          }
        ]
      }
    },
    {
      "name": "WagerOpened",
      "type": {
        "kind": "struct",
        "fields": [
          {
            "name": "version",
            "type": "u8"
          },
          {
            "name": "wager",
            "type": "pubkey"
          },
          {
            "name": "integrator",
            "type": "pubkey"
          },
          {
            "name": "nonce",
            "type": "u64"
          },
          {
            "name": "beneficiary",
            "type": "pubkey"
          },
          {
            "name": "stake",
            "type": "u64"
          },
          {
            "name": "pool_credit",
            "type": "u64"
          },
          {
            "name": "payout_max",
            "type": "u64"
          },
          {
            "name": "reserved_liability",
            "type": "u64"
          },
          {
            "name": "cap",
            "type": "u64"
          },
          {
            "name": "paytable_edge_bps",
            "type": "u64"
          },
          {
            "name": "integrator_fee_bps",
            "type": "u64"
          },
          {
            "name": "open_slot",
            "type": "u64"
          }
        ]
      }
    },
    {
      "name": "WagerSettled",
      "type": {
        "kind": "struct",
        "fields": [
          {
            "name": "version",
            "type": "u8"
          },
          {
            "name": "wager",
            "type": "pubkey"
          },
          {
            "name": "integrator",
            "type": "pubkey"
          },
          {
            "name": "bucket",
            "type": "u8"
          },
          {
            "name": "payout",
            "type": "u64"
          },
          {
            "name": "pending",
            "docs": [
              "The payout went to `payout_escrow`: the beneficiary could not receive it."
            ],
            "type": "bool"
          }
        ]
      }
    },
    {
      "name": "WagerStatus",
      "type": {
        "kind": "enum",
        "variants": [
          {
            "name": "Open"
          },
          {
            "name": "Requested"
          },
          {
            "name": "PayoutPending"
          }
        ]
      }
    },
    {
      "name": "WithdrawClaimed",
      "type": {
        "kind": "struct",
        "fields": [
          {
            "name": "version",
            "type": "u8"
          },
          {
            "name": "owner",
            "type": "pubkey"
          },
          {
            "name": "epoch_id",
            "type": "u64"
          },
          {
            "name": "at_epoch_id",
            "docs": [
              "The record the claim read the chain at."
            ],
            "type": "u64"
          },
          {
            "name": "assets",
            "type": "u64"
          },
          {
            "name": "closed",
            "docs": [
              "The request is fully served and closed."
            ],
            "type": "bool"
          },
          {
            "name": "delivered",
            "docs": [
              "What was owed reached the owner; otherwise it is parked on the request."
            ],
            "type": "bool"
          }
        ]
      }
    },
    {
      "name": "WithdrawRequest",
      "type": {
        "kind": "struct",
        "fields": [
          {
            "name": "version",
            "type": "u8"
          },
          {
            "name": "bump",
            "type": "u8"
          },
          {
            "name": "owner",
            "type": "pubkey"
          },
          {
            "name": "epoch_id",
            "type": "u64"
          },
          {
            "name": "shares",
            "type": "u64"
          },
          {
            "name": "r_entry",
            "docs": [
              "Chain indices at entry, copied from the entry record by the first claim; 0 before."
            ],
            "type": "u128"
          },
          {
            "name": "v_entry",
            "type": "u128"
          },
          {
            "name": "paid",
            "docs": [
              "Assets already paid by earlier partial claims."
            ],
            "type": "u64"
          },
          {
            "name": "chain_id",
            "docs": [
              "The chain the request entered, copied with the indices; every later",
              "claim must read a record of this chain. A split carries the request into",
              "the next chain: its remaining `shares` at indices `START`."
            ],
            "type": "u64"
          },
          {
            "name": "undelivered",
            "docs": [
              "Assets owed but not delivered: the owner's USDC account could not",
              "receive when a claim ran. Delivered by the next claim that can."
            ],
            "type": "u64"
          },
          {
            "name": "parked",
            "docs": [
              "Set by the final claim when it could not deliver: every record is",
              "released and only `undelivered` remains to hand over."
            ],
            "type": "bool"
          }
        ]
      }
    },
    {
      "name": "WithdrawRequested",
      "type": {
        "kind": "struct",
        "fields": [
          {
            "name": "version",
            "type": "u8"
          },
          {
            "name": "owner",
            "type": "pubkey"
          },
          {
            "name": "epoch_id",
            "type": "u64"
          },
          {
            "name": "shares",
            "type": "u64"
          }
        ]
      }
    }
  ],
  "constants": [
    {
      "name": "CONFIG_SEED",
      "type": "bytes",
      "value": "[99, 111, 110, 102, 105, 103]"
    },
    {
      "name": "DEPOSIT_QUEUE_SEED",
      "docs": [
        "Deposits queued for a strike; not part of the pool's assets yet."
      ],
      "type": "bytes",
      "value": "[100, 101, 112, 111, 115, 105, 116, 45, 113, 117, 101, 117, 101]"
    },
    {
      "name": "DEPOSIT_SEED",
      "docs": [
        "`[\"deposit\", epoch_id, owner]`."
      ],
      "type": "bytes",
      "value": "[100, 101, 112, 111, 115, 105, 116]"
    },
    {
      "name": "EPOCH_SEED",
      "docs": [
        "`[\"epoch\", epoch_id]`."
      ],
      "type": "bytes",
      "value": "[101, 112, 111, 99, 104]"
    },
    {
      "name": "INTEGRATOR_AUTHORITY_SEED",
      "docs": [
        "The seed a program integrator derives its signing PDA with, under its own",
        "program id: `[\"fade-integrator\"]`. Only that program can sign for it."
      ],
      "type": "bytes",
      "value": "[102, 97, 100, 101, 45, 105, 110, 116, 101, 103, 114, 97, 116, 111, 114]"
    },
    {
      "name": "INTEGRATOR_SEED",
      "docs": [
        "`[\"integrator\", authority]`: keyed on the address that signs `open_wager`."
      ],
      "type": "bytes",
      "value": "[105, 110, 116, 101, 103, 114, 97, 116, 111, 114]"
    },
    {
      "name": "PAYABLE_SEED",
      "docs": [
        "Assets struck withdrawals are owed, not yet claimed."
      ],
      "type": "bytes",
      "value": "[112, 97, 121, 97, 98, 108, 101]"
    },
    {
      "name": "PAYOUT_ESCROW_SEED",
      "docs": [
        "Payouts to a beneficiary that could not receive them at settlement."
      ],
      "type": "bytes",
      "value": "[112, 97, 121, 111, 117, 116, 45, 101, 115, 99, 114, 111, 119]"
    },
    {
      "name": "POOL_SEED",
      "docs": [
        "The wager side's state."
      ],
      "type": "bytes",
      "value": "[112, 111, 111, 108]"
    },
    {
      "name": "QUEUE_SEED",
      "docs": [
        "The liquidity-provider side's state; its lamports above rent are the strike fund."
      ],
      "type": "bytes",
      "value": "[113, 117, 101, 117, 101]"
    },
    {
      "name": "SHARE_CLAIMS_SEED",
      "type": "bytes",
      "value": "[115, 104, 97, 114, 101, 45, 99, 108, 97, 105, 109, 115]"
    },
    {
      "name": "SHARE_ESCROW_SEED",
      "type": "bytes",
      "value": "[115, 104, 97, 114, 101, 45, 101, 115, 99, 114, 111, 119]"
    },
    {
      "name": "SHARE_MINT_SEED",
      "type": "bytes",
      "value": "[115, 104, 97, 114, 101, 115]"
    },
    {
      "name": "USDC_VAULT_SEED",
      "docs": [
        "The pool's USDC: backs every open wager."
      ],
      "type": "bytes",
      "value": "[117, 115, 100, 99, 45, 118, 97, 117, 108, 116]"
    },
    {
      "name": "VAULT_AUTHORITY_SEED",
      "docs": [
        "Signs for every token account the vault owns. No data."
      ],
      "type": "bytes",
      "value": "[118, 97, 117, 108, 116, 45, 97, 117, 116, 104, 111, 114, 105, 116, 121]"
    },
    {
      "name": "VRF_PAYER_SEED",
      "docs": [
        "`[\"vrf-payer\", wager]`: the system-owned PDA that pays ORAO."
      ],
      "type": "bytes",
      "value": "[118, 114, 102, 45, 112, 97, 121, 101, 114]"
    },
    {
      "name": "WAGER_SEED",
      "docs": [
        "`[\"wager\", integrator, nonce]`."
      ],
      "type": "bytes",
      "value": "[119, 97, 103, 101, 114]"
    },
    {
      "name": "WITHDRAW_SEED",
      "docs": [
        "`[\"withdraw\", epoch_id, owner]`."
      ],
      "type": "bytes",
      "value": "[119, 105, 116, 104, 100, 114, 97, 119]"
    }
  ]
}
