fix: vault как ATA + фандинг беттора; E2E на localnet ok

This commit is contained in:
Caffeine
2026-09-10 02:12:07 +03:00
parent fb9a7f4e8b
commit f937c8993d
15 changed files with 267 additions and 148 deletions
+17 -36
View File
@@ -73,9 +73,22 @@
{
"name": "vault_token",
"docs": [
"Program-owned token vault: PDA([GLOBAL_SEED, VAULT_SEED]); payouts are paid out from here."
"Token vault ATA (owner = PDA([GLOBAL_SEED, VAULT_SEED])); payouts are paid out from here."
],
"writable": true
},
{
"name": "bettor_token",
"docs": [
"Bettor's SPL-token account; the payout is sent here."
],
"writable": true
},
{
"name": "vault_authority",
"docs": [
"It only serves as the CPI signing authority for the vault ATA payout, so no owner/type check is needed."
],
"writable": true,
"pda": {
"seeds": [
{
@@ -102,13 +115,6 @@
]
}
},
{
"name": "bettor_token",
"docs": [
"Bettor's SPL-token account; the payout is sent here."
],
"writable": true
},
{
"name": "token_program",
"address": "TokenkegQfeZyiNwAJbNbGKPFXCWuBvf9Ss623VQ5DA"
@@ -200,34 +206,9 @@
{
"name": "vault_token",
"docs": [
"Program-owned token vault: PDA([GLOBAL_SEED, VAULT_SEED]); bet amounts are escrowed here."
"Token vault ATA (owner = PDA([GLOBAL_SEED, VAULT_SEED])); bet amounts are escrowed here."
],
"writable": true,
"pda": {
"seeds": [
{
"kind": "const",
"value": [
103,
108,
111,
98,
97,
108
]
},
{
"kind": "const",
"value": [
118,
97,
117,
108,
116
]
}
]
}
"writable": true
},
{
"name": "token_program",