proof-of-take-sdk 5.0.10 → 5.0.12

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -2092,6 +2092,254 @@
2092
2092
  }
2093
2093
  ]
2094
2094
  },
2095
+ {
2096
+ "name": "create_moonpool",
2097
+ "docs": [
2098
+ "Create a new Moonpool and perform the first launchpad join."
2099
+ ],
2100
+ "discriminator": [
2101
+ 53,
2102
+ 201,
2103
+ 51,
2104
+ 181,
2105
+ 195,
2106
+ 31,
2107
+ 144,
2108
+ 187
2109
+ ],
2110
+ "accounts": [
2111
+ {
2112
+ "name": "season_settings",
2113
+ "writable": true,
2114
+ "pda": {
2115
+ "seeds": [
2116
+ {
2117
+ "kind": "const",
2118
+ "value": [
2119
+ 115,
2120
+ 101,
2121
+ 97,
2122
+ 115,
2123
+ 111,
2124
+ 110,
2125
+ 95,
2126
+ 115,
2127
+ 101,
2128
+ 116,
2129
+ 116,
2130
+ 105,
2131
+ 110,
2132
+ 103,
2133
+ 115
2134
+ ]
2135
+ }
2136
+ ]
2137
+ }
2138
+ },
2139
+ {
2140
+ "name": "season",
2141
+ "docs": [
2142
+ "Season PDA - scoped to launchpad_token_mint."
2143
+ ],
2144
+ "writable": true,
2145
+ "pda": {
2146
+ "seeds": [
2147
+ {
2148
+ "kind": "const",
2149
+ "value": [
2150
+ 115,
2151
+ 101,
2152
+ 97,
2153
+ 115,
2154
+ 111,
2155
+ 110
2156
+ ]
2157
+ },
2158
+ {
2159
+ "kind": "account",
2160
+ "path": "launchpad_token_mint"
2161
+ },
2162
+ {
2163
+ "kind": "const",
2164
+ "value": [
2165
+ 1,
2166
+ 0,
2167
+ 0,
2168
+ 0,
2169
+ 0,
2170
+ 0,
2171
+ 0,
2172
+ 0
2173
+ ]
2174
+ },
2175
+ {
2176
+ "kind": "arg",
2177
+ "path": "season_number"
2178
+ }
2179
+ ]
2180
+ }
2181
+ },
2182
+ {
2183
+ "name": "season_membership",
2184
+ "docs": [
2185
+ "SeasonMembership PDA - scoped to launchpad_token_mint."
2186
+ ],
2187
+ "writable": true
2188
+ },
2189
+ {
2190
+ "name": "moonpool",
2191
+ "docs": [
2192
+ "Moonpool PDA - unique per launchpad_token_mint."
2193
+ ],
2194
+ "writable": true,
2195
+ "pda": {
2196
+ "seeds": [
2197
+ {
2198
+ "kind": "const",
2199
+ "value": [
2200
+ 109,
2201
+ 111,
2202
+ 111,
2203
+ 110,
2204
+ 112,
2205
+ 111,
2206
+ 111,
2207
+ 108
2208
+ ]
2209
+ },
2210
+ {
2211
+ "kind": "account",
2212
+ "path": "launchpad_token_mint"
2213
+ },
2214
+ {
2215
+ "kind": "const",
2216
+ "value": [
2217
+ 1,
2218
+ 0,
2219
+ 0,
2220
+ 0,
2221
+ 0,
2222
+ 0,
2223
+ 0,
2224
+ 0
2225
+ ]
2226
+ }
2227
+ ]
2228
+ }
2229
+ },
2230
+ {
2231
+ "name": "moonpool_treasury",
2232
+ "writable": true,
2233
+ "pda": {
2234
+ "seeds": [
2235
+ {
2236
+ "kind": "const",
2237
+ "value": [
2238
+ 109,
2239
+ 111,
2240
+ 111,
2241
+ 110,
2242
+ 112,
2243
+ 111,
2244
+ 111,
2245
+ 108,
2246
+ 95,
2247
+ 116,
2248
+ 114,
2249
+ 101,
2250
+ 97,
2251
+ 115,
2252
+ 117,
2253
+ 114,
2254
+ 121
2255
+ ]
2256
+ },
2257
+ {
2258
+ "kind": "account",
2259
+ "path": "launchpad_token_mint"
2260
+ },
2261
+ {
2262
+ "kind": "const",
2263
+ "value": [
2264
+ 1,
2265
+ 0,
2266
+ 0,
2267
+ 0,
2268
+ 0,
2269
+ 0,
2270
+ 0,
2271
+ 0
2272
+ ]
2273
+ }
2274
+ ]
2275
+ }
2276
+ },
2277
+ {
2278
+ "name": "launchpad_token_mint",
2279
+ "docs": [
2280
+ "SPL Token-2022 mint for the launchpad token (keypair, not PDA)."
2281
+ ],
2282
+ "writable": true,
2283
+ "signer": true
2284
+ },
2285
+ {
2286
+ "name": "root_admin",
2287
+ "writable": true,
2288
+ "signer": true,
2289
+ "address": "Lude4DE3jDXVViJ3s7bUfPXdXy8Zq7G1stMwHNQrc2s"
2290
+ },
2291
+ {
2292
+ "name": "user",
2293
+ "writable": true,
2294
+ "signer": true
2295
+ },
2296
+ {
2297
+ "name": "token_2022_program"
2298
+ },
2299
+ {
2300
+ "name": "system_program",
2301
+ "address": "11111111111111111111111111111111"
2302
+ }
2303
+ ],
2304
+ "args": [
2305
+ {
2306
+ "name": "season_number",
2307
+ "type": "u64"
2308
+ },
2309
+ {
2310
+ "name": "tier",
2311
+ "type": "u8"
2312
+ },
2313
+ {
2314
+ "name": "referrer",
2315
+ "type": "pubkey"
2316
+ },
2317
+ {
2318
+ "name": "star",
2319
+ "type": "bool"
2320
+ },
2321
+ {
2322
+ "name": "max_sol_in_lamports",
2323
+ "type": "u64"
2324
+ },
2325
+ {
2326
+ "name": "expected_sol_in_lamports",
2327
+ "type": "u64"
2328
+ },
2329
+ {
2330
+ "name": "max_slippage_bps",
2331
+ "type": "u16"
2332
+ },
2333
+ {
2334
+ "name": "star_flag_prompt",
2335
+ "type": "string"
2336
+ },
2337
+ {
2338
+ "name": "symbol",
2339
+ "type": "string"
2340
+ }
2341
+ ]
2342
+ },
2095
2343
  {
2096
2344
  "name": "finalize_empty_window",
2097
2345
  "discriminator": [
@@ -2849,16 +3097,19 @@
2849
3097
  "args": []
2850
3098
  },
2851
3099
  {
2852
- "name": "join_season",
3100
+ "name": "join_moonpool_season",
3101
+ "docs": [
3102
+ "Join an existing Moonpool season (launchpad mode)."
3103
+ ],
2853
3104
  "discriminator": [
2854
- 36,
2855
- 202,
2856
- 202,
2857
- 158,
2858
- 82,
2859
- 34,
2860
- 248,
2861
- 231
3105
+ 197,
3106
+ 20,
3107
+ 110,
3108
+ 170,
3109
+ 212,
3110
+ 45,
3111
+ 13,
3112
+ 133
2862
3113
  ],
2863
3114
  "accounts": [
2864
3115
  {
@@ -2891,6 +3142,9 @@
2891
3142
  },
2892
3143
  {
2893
3144
  "name": "season",
3145
+ "docs": [
3146
+ "Season PDA - scoped to launchpad_token_mint."
3147
+ ],
2894
3148
  "writable": true,
2895
3149
  "pda": {
2896
3150
  "seeds": [
@@ -2907,7 +3161,7 @@
2907
3161
  },
2908
3162
  {
2909
3163
  "kind": "account",
2910
- "path": "token_mint"
3164
+ "path": "launchpad_token_mint"
2911
3165
  },
2912
3166
  {
2913
3167
  "kind": "const",
@@ -2931,22 +3185,15 @@
2931
3185
  },
2932
3186
  {
2933
3187
  "name": "season_membership",
3188
+ "docs": [
3189
+ "SeasonMembership PDA - scoped to launchpad_token_mint."
3190
+ ],
2934
3191
  "writable": true
2935
3192
  },
2936
3193
  {
2937
3194
  "name": "moonpool",
2938
3195
  "docs": [
2939
- "Moonpool PDA - unique per launchpad_token_mint.",
2940
- "The Moonpool is the Moon's seesaw for buying and selling stars (real SPL Token-2022 tokens).",
2941
- "Contains reserve state for the constant-product AMM.",
2942
- "",
2943
- "Each unique launchpad_token_mint creates a unique Moonpool, allowing multiple \"Stars\"",
2944
- "to coexist for the same token_mint.",
2945
- "",
2946
- "SECURITY: This account is MANDATORY (not optional) to prevent bypassing the",
2947
- "launchpad mode check. If a previous season was launchpad mode, subsequent",
2948
- "seasons MUST also be launchpad mode - we enforce this by always checking",
2949
- "the pool state during season initialization."
3196
+ "Moonpool PDA - must already exist."
2950
3197
  ],
2951
3198
  "writable": true,
2952
3199
  "pda": {
@@ -2986,17 +3233,6 @@
2986
3233
  },
2987
3234
  {
2988
3235
  "name": "moonpool_treasury",
2989
- "docs": [
2990
- "Unique per launchpad_token_mint, paired with its corresponding Moonpool.",
2991
- "",
2992
- "SECURITY: This account is MANDATORY alongside the pool to ensure consistent",
2993
- "mode validation across seasons.",
2994
- "",
2995
- "Safety:",
2996
- "- Address is constrained by PDA seeds.",
2997
- "- Owner is constrained to `system_program::ID`.",
2998
- "- Program only transfers lamports via System Program CPI with PDA signer seeds."
2999
- ],
3000
3236
  "writable": true,
3001
3237
  "pda": {
3002
3238
  "seeds": [
@@ -3045,24 +3281,157 @@
3045
3281
  {
3046
3282
  "name": "launchpad_token_mint",
3047
3283
  "docs": [
3048
- "SPL Token-2022 mint for the launchpad token.",
3049
- "Created when the Moonpool is first initialized.",
3050
- "Mint authority is the Moonpool PDA itself.",
3051
- "NOTE: This is a Keypair (not a PDA) to allow creating fresh mints with updated decimals."
3052
- ],
3284
+ "The launchpad token mint for this Moonpool."
3285
+ ]
3286
+ },
3287
+ {
3288
+ "name": "root_admin",
3289
+ "writable": true,
3290
+ "signer": true,
3291
+ "address": "Lude4DE3jDXVViJ3s7bUfPXdXy8Zq7G1stMwHNQrc2s"
3292
+ },
3293
+ {
3294
+ "name": "user",
3053
3295
  "writable": true,
3054
3296
  "signer": true
3055
3297
  },
3298
+ {
3299
+ "name": "token_2022_program"
3300
+ },
3301
+ {
3302
+ "name": "system_program",
3303
+ "address": "11111111111111111111111111111111"
3304
+ }
3305
+ ],
3306
+ "args": [
3307
+ {
3308
+ "name": "season_number",
3309
+ "type": "u64"
3310
+ },
3311
+ {
3312
+ "name": "tier",
3313
+ "type": "u8"
3314
+ },
3315
+ {
3316
+ "name": "referrer",
3317
+ "type": "pubkey"
3318
+ },
3319
+ {
3320
+ "name": "star",
3321
+ "type": "bool"
3322
+ },
3323
+ {
3324
+ "name": "max_sol_in_lamports",
3325
+ "type": "u64"
3326
+ },
3327
+ {
3328
+ "name": "expected_sol_in_lamports",
3329
+ "type": "u64"
3330
+ },
3331
+ {
3332
+ "name": "max_slippage_bps",
3333
+ "type": "u16"
3334
+ }
3335
+ ]
3336
+ },
3337
+ {
3338
+ "name": "join_sunpool",
3339
+ "docs": [
3340
+ "Join a Sunpool season (classic mode with MIZD)."
3341
+ ],
3342
+ "discriminator": [
3343
+ 223,
3344
+ 205,
3345
+ 130,
3346
+ 22,
3347
+ 203,
3348
+ 77,
3349
+ 45,
3350
+ 110
3351
+ ],
3352
+ "accounts": [
3353
+ {
3354
+ "name": "season_settings",
3355
+ "writable": true,
3356
+ "pda": {
3357
+ "seeds": [
3358
+ {
3359
+ "kind": "const",
3360
+ "value": [
3361
+ 115,
3362
+ 101,
3363
+ 97,
3364
+ 115,
3365
+ 111,
3366
+ 110,
3367
+ 95,
3368
+ 115,
3369
+ 101,
3370
+ 116,
3371
+ 116,
3372
+ 105,
3373
+ 110,
3374
+ 103,
3375
+ 115
3376
+ ]
3377
+ }
3378
+ ]
3379
+ }
3380
+ },
3381
+ {
3382
+ "name": "season",
3383
+ "docs": [
3384
+ "Season PDA - scoped to token_mint (MIZD) for Sunpool mode."
3385
+ ],
3386
+ "writable": true,
3387
+ "pda": {
3388
+ "seeds": [
3389
+ {
3390
+ "kind": "const",
3391
+ "value": [
3392
+ 115,
3393
+ 101,
3394
+ 97,
3395
+ 115,
3396
+ 111,
3397
+ 110
3398
+ ]
3399
+ },
3400
+ {
3401
+ "kind": "account",
3402
+ "path": "token_mint"
3403
+ },
3404
+ {
3405
+ "kind": "const",
3406
+ "value": [
3407
+ 1,
3408
+ 0,
3409
+ 0,
3410
+ 0,
3411
+ 0,
3412
+ 0,
3413
+ 0,
3414
+ 0
3415
+ ]
3416
+ },
3417
+ {
3418
+ "kind": "arg",
3419
+ "path": "season_number"
3420
+ }
3421
+ ]
3422
+ }
3423
+ },
3424
+ {
3425
+ "name": "season_membership",
3426
+ "docs": [
3427
+ "SeasonMembership PDA - scoped to token_mint (MIZD) for Sunpool mode."
3428
+ ],
3429
+ "writable": true
3430
+ },
3056
3431
  {
3057
3432
  "name": "sunpool",
3058
3433
  "docs": [
3059
- "Global Sunpool PDA (shared across all seasons for this token mint).",
3060
- "The Sunpool is the Sun's flag shop for classic (non-launchpad) mode.",
3061
- "Contains token_mint and id (always 1) for classic mode sessions.",
3062
- "",
3063
- "SECURITY: This account is MANDATORY (like Moonpool) to prevent bypassing the",
3064
- "mode validation. If Sunpool is initialized, all future seasons for this token",
3065
- "must also be classic mode."
3434
+ "Global Sunpool PDA (shared across all seasons for this token mint)."
3066
3435
  ],
3067
3436
  "writable": true,
3068
3437
  "pda": {
@@ -3101,8 +3470,10 @@
3101
3470
  },
3102
3471
  {
3103
3472
  "name": "season_deposit_vault",
3473
+ "docs": [
3474
+ "Season deposit vault for MIZD."
3475
+ ],
3104
3476
  "writable": true,
3105
- "optional": true,
3106
3477
  "pda": {
3107
3478
  "seeds": [
3108
3479
  {
@@ -3156,8 +3527,10 @@
3156
3527
  },
3157
3528
  {
3158
3529
  "name": "user_join_credit",
3530
+ "docs": [
3531
+ "User join credit PDA."
3532
+ ],
3159
3533
  "writable": true,
3160
- "optional": true,
3161
3534
  "pda": {
3162
3535
  "seeds": [
3163
3536
  {
@@ -3190,8 +3563,10 @@
3190
3563
  },
3191
3564
  {
3192
3565
  "name": "user_join_credit_vault",
3566
+ "docs": [
3567
+ "User join credit vault (ATA for MIZD)."
3568
+ ],
3193
3569
  "writable": true,
3194
- "optional": true,
3195
3570
  "pda": {
3196
3571
  "seeds": [
3197
3572
  {
@@ -3281,12 +3656,15 @@
3281
3656
  },
3282
3657
  {
3283
3658
  "name": "mizd_mint",
3659
+ "docs": [
3660
+ "MIZD mint."
3661
+ ],
3284
3662
  "address": "mizdS9fDNUKWZcXBeRhJoJQHJJmsTeF4fFRyPdXWv99"
3285
3663
  },
3286
3664
  {
3287
3665
  "name": "token_mint",
3288
3666
  "docs": [
3289
- "Token mint this season is scoped to (used for Season PDA derivation)."
3667
+ "Token mint this season is scoped to (MIZD for Sunpool)."
3290
3668
  ]
3291
3669
  },
3292
3670
  {
@@ -3297,8 +3675,10 @@
3297
3675
  },
3298
3676
  {
3299
3677
  "name": "root_admin_token_account",
3678
+ "docs": [
3679
+ "Root admin MIZD token account."
3680
+ ],
3300
3681
  "writable": true,
3301
- "optional": true,
3302
3682
  "pda": {
3303
3683
  "seeds": [
3304
3684
  {
@@ -3389,10 +3769,9 @@
3389
3769
  {
3390
3770
  "name": "user_token_account",
3391
3771
  "docs": [
3392
- "User MIZD ATA (canonical). Created if missing; root admin pays."
3772
+ "User MIZD token account."
3393
3773
  ],
3394
3774
  "writable": true,
3395
- "optional": true,
3396
3775
  "pda": {
3397
3776
  "seeds": [
3398
3777
  {
@@ -3493,12 +3872,6 @@
3493
3872
  "name": "token_program",
3494
3873
  "address": "TokenkegQfeZyiNwAJbNbGKPFXCWuBvf9Ss623VQ5DA"
3495
3874
  },
3496
- {
3497
- "name": "token_2022_program",
3498
- "docs": [
3499
- "Token-2022 program for the launchpad token mint."
3500
- ]
3501
- },
3502
3875
  {
3503
3876
  "name": "system_program",
3504
3877
  "address": "11111111111111111111111111111111"
@@ -3525,22 +3898,6 @@
3525
3898
  "name": "star",
3526
3899
  "type": "bool"
3527
3900
  },
3528
- {
3529
- "name": "launchpad",
3530
- "type": "bool"
3531
- },
3532
- {
3533
- "name": "max_sol_in_lamports",
3534
- "type": "u64"
3535
- },
3536
- {
3537
- "name": "expected_sol_in_lamports",
3538
- "type": "u64"
3539
- },
3540
- {
3541
- "name": "max_slippage_bps",
3542
- "type": "u16"
3543
- },
3544
3901
  {
3545
3902
  "name": "star_flag_prompt",
3546
3903
  "type": "string"
@@ -3548,10 +3905,6 @@
3548
3905
  {
3549
3906
  "name": "symbol",
3550
3907
  "type": "string"
3551
- },
3552
- {
3553
- "name": "force_new_launchpad_mint",
3554
- "type": "bool"
3555
3908
  }
3556
3909
  ]
3557
3910
  },
@@ -5759,6 +6112,21 @@
5759
6112
  "code": 6077,
5760
6113
  "name": "InvalidSunpoolTokenMint",
5761
6114
  "msg": "Invalid sunpool token mint: does not match the stored mint in Sunpool"
6115
+ },
6116
+ {
6117
+ "code": 6078,
6118
+ "name": "SeasonAlreadyInitialized",
6119
+ "msg": "Season is already initialized"
6120
+ },
6121
+ {
6122
+ "code": 6079,
6123
+ "name": "MoonpoolAlreadyInitialized",
6124
+ "msg": "Moonpool is already initialized"
6125
+ },
6126
+ {
6127
+ "code": 6080,
6128
+ "name": "MoonpoolNotInitialized",
6129
+ "msg": "Moonpool is not initialized (use create_moonpool first)"
5762
6130
  }
5763
6131
  ],
5764
6132
  "types": [
@@ -6419,7 +6787,7 @@
6419
6787
  "- x: real SOL reserve (lamports in treasury minus rent minimum)",
6420
6788
  "- y: token reserve (`token_reserve_units`)",
6421
6789
  "",
6422
- "The Moonpool is global and shared across all seasons for a given token mint."
6790
+ "Each Moonpool is uniquely identified by its `launchpad_token_mint`."
6423
6791
  ],
6424
6792
  "type": {
6425
6793
  "kind": "struct",
@@ -6427,22 +6795,16 @@
6427
6795
  {
6428
6796
  "name": "id",
6429
6797
  "docs": [
6430
- "Moonpool ID. Currently always 1 (singleton per token mint)."
6798
+ "Moonpool ID. Currently always 1 (singleton per launchpad token mint)."
6431
6799
  ],
6432
6800
  "type": "u8"
6433
6801
  },
6434
- {
6435
- "name": "token_mint",
6436
- "docs": [
6437
- "The token mint this Moonpool is scoped to (e.g., MIZD)."
6438
- ],
6439
- "type": "pubkey"
6440
- },
6441
6802
  {
6442
6803
  "name": "launchpad_token_mint",
6443
6804
  "docs": [
6444
6805
  "The SPL Token-2022 mint created for launchpad tokens.",
6445
- "This mint's authority is the Moonpool PDA itself."
6806
+ "This mint's authority is the Moonpool PDA itself.",
6807
+ "This is also the unique identifier for this Moonpool."
6446
6808
  ],
6447
6809
  "type": "pubkey"
6448
6810
  },
package/dist/index.d.ts CHANGED
@@ -11,8 +11,8 @@ export type { CreateMiztakeOptions, CreateMiztakeResult, CreateMiztakePdas, Crea
11
11
  export { initializeStatistics, isInitialized, } from "./instructions/initializeStatistics";
12
12
  export { initializeSeasonSettings } from "./instructions/initializeSeasonSettings";
13
13
  export { initializeSeasonVault } from "./instructions/initializeSeasonVault";
14
- export { joinSeason, joinSeasonClassic, joinSeasonLaunchpad, joinSeasonAndInitialize, joinSeasonLaunchpadAndInitialize, } from "./instructions/joinSeason";
15
- export type { JoinSeasonOptions, JoinSeasonClassicOptions, JoinSeasonLaunchpadOptions, JoinSeasonAndInitializeOptions, } from "./instructions/joinSeason";
14
+ export { createMoonpool, joinMoonpoolSeason, joinSunpool, joinSeasonClassic, joinSeasonLaunchpad, joinSeasonAndInitialize, joinSeasonLaunchpadAndInitialize, } from "./instructions/joinSeason";
15
+ export type { CreateMoonpoolOptions, JoinMoonpoolSeasonOptions, JoinSunpoolOptions, JoinSeasonClassicOptions, JoinSeasonLaunchpadOptions, } from "./instructions/joinSeason";
16
16
  export { confirmedPostOnX } from "./instructions/confirmedPostOnX";
17
17
  export type { ConfirmedPostOnXOptions } from "./instructions/confirmedPostOnX";
18
18
  export { claimWindowRewards, claimWindowRewardsClassic, claimWindowRewardsLaunchpad, } from "./instructions/claimWindowRewards";