Skip to main content

satrush_client/generated/instructions/
withdraw_protocol_fees.rs

1//! This code was AUTOGENERATED using the codama library.
2//! Please DO NOT EDIT THIS FILE, instead use visitors
3//! to add features, then rerun codama to update it.
4//!
5//! <https://github.com/codama-idl/codama>
6//!
7
8use borsh::BorshSerialize;
9use borsh::BorshDeserialize;
10
11pub const WITHDRAW_PROTOCOL_FEES_DISCRIMINATOR: [u8; 8] = [11, 68, 165, 98, 18, 208, 134, 73];
12
13/// Accounts.
14#[derive(Debug)]
15pub struct WithdrawProtocolFees {
16      
17              
18          pub authority: solana_address::Address,
19          
20              
21          pub satrush_config: solana_address::Address,
22                /// The treasury: owns the fee pool and signs the withdrawal transfer.
23
24    
25              
26          pub treasury: solana_address::Address,
27          
28              
29          pub usd_mint: solana_address::Address,
30                /// Treasury's USD fee pool — the withdrawal source.
31
32    
33              
34          pub treasury_usd_ata: solana_address::Address,
35                /// as the authority of the destination ATA.
36
37    
38              
39          pub fee_recipient: solana_address::Address,
40                /// Fee recipient's USD account — the withdrawal destination. Created by the
41/// crank if missing.
42
43    
44              
45          pub fee_recipient_usd_ata: solana_address::Address,
46          
47              
48          pub token_program: solana_address::Address,
49          
50              
51          pub associated_token_program: solana_address::Address,
52          
53              
54          pub system_program: solana_address::Address,
55      }
56
57impl WithdrawProtocolFees {
58  pub fn instruction(&self) -> solana_instruction::Instruction {
59    self.instruction_with_remaining_accounts(&[])
60  }
61  #[allow(clippy::arithmetic_side_effects)]
62  #[allow(clippy::vec_init_then_push)]
63  pub fn instruction_with_remaining_accounts(&self, remaining_accounts: &[solana_instruction::AccountMeta]) -> solana_instruction::Instruction {
64    let mut accounts = Vec::with_capacity(10+ remaining_accounts.len());
65                            accounts.push(solana_instruction::AccountMeta::new(
66            self.authority,
67            true
68          ));
69                                          accounts.push(solana_instruction::AccountMeta::new_readonly(
70            self.satrush_config,
71            false
72          ));
73                                          accounts.push(solana_instruction::AccountMeta::new(
74            self.treasury,
75            false
76          ));
77                                          accounts.push(solana_instruction::AccountMeta::new_readonly(
78            self.usd_mint,
79            false
80          ));
81                                          accounts.push(solana_instruction::AccountMeta::new(
82            self.treasury_usd_ata,
83            false
84          ));
85                                          accounts.push(solana_instruction::AccountMeta::new_readonly(
86            self.fee_recipient,
87            false
88          ));
89                                          accounts.push(solana_instruction::AccountMeta::new(
90            self.fee_recipient_usd_ata,
91            false
92          ));
93                                          accounts.push(solana_instruction::AccountMeta::new_readonly(
94            self.token_program,
95            false
96          ));
97                                          accounts.push(solana_instruction::AccountMeta::new_readonly(
98            self.associated_token_program,
99            false
100          ));
101                                          accounts.push(solana_instruction::AccountMeta::new_readonly(
102            self.system_program,
103            false
104          ));
105                      accounts.extend_from_slice(remaining_accounts);
106    let data = WithdrawProtocolFeesInstructionData::new().try_to_vec().unwrap();
107    
108    solana_instruction::Instruction {
109      program_id: crate::SATRUSH_ID,
110      accounts,
111      data,
112    }
113  }
114}
115
116#[derive(BorshSerialize, BorshDeserialize, Clone, Debug, Eq, PartialEq)]
117 pub struct WithdrawProtocolFeesInstructionData {
118            discriminator: [u8; 8],
119      }
120
121impl WithdrawProtocolFeesInstructionData {
122  pub fn new() -> Self {
123    Self {
124                        discriminator: [11, 68, 165, 98, 18, 208, 134, 73],
125                  }
126  }
127
128    pub(crate) fn try_to_vec(&self) -> Result<Vec<u8>, std::io::Error> {
129    borsh::to_vec(self)
130  }
131  }
132
133impl Default for WithdrawProtocolFeesInstructionData {
134  fn default() -> Self {
135    Self::new()
136  }
137}
138
139
140
141/// Instruction builder for `WithdrawProtocolFees`.
142///
143/// ### Accounts:
144///
145                      ///   0. `[writable, signer]` authority
146          ///   1. `[]` satrush_config
147                ///   2. `[writable]` treasury
148          ///   3. `[]` usd_mint
149                ///   4. `[writable]` treasury_usd_ata
150          ///   5. `[]` fee_recipient
151                ///   6. `[writable]` fee_recipient_usd_ata
152                ///   7. `[optional]` token_program (default to `TokenkegQfeZyiNwAJbNbGKPFXCWuBvf9Ss623VQ5DA`)
153                ///   8. `[optional]` associated_token_program (default to `ATokenGPvbdGVxr1b2hvZbsiqW5xWH25efTNsLJA8knL`)
154                ///   9. `[optional]` system_program (default to `11111111111111111111111111111111`)
155#[derive(Clone, Debug, Default)]
156pub struct WithdrawProtocolFeesBuilder {
157            authority: Option<solana_address::Address>,
158                satrush_config: Option<solana_address::Address>,
159                treasury: Option<solana_address::Address>,
160                usd_mint: Option<solana_address::Address>,
161                treasury_usd_ata: Option<solana_address::Address>,
162                fee_recipient: Option<solana_address::Address>,
163                fee_recipient_usd_ata: Option<solana_address::Address>,
164                token_program: Option<solana_address::Address>,
165                associated_token_program: Option<solana_address::Address>,
166                system_program: Option<solana_address::Address>,
167                __remaining_accounts: Vec<solana_instruction::AccountMeta>,
168}
169
170impl WithdrawProtocolFeesBuilder {
171  pub fn new() -> Self {
172    Self::default()
173  }
174            #[inline(always)]
175    pub fn authority(&mut self, authority: solana_address::Address) -> &mut Self {
176                        self.authority = Some(authority);
177                    self
178    }
179            #[inline(always)]
180    pub fn satrush_config(&mut self, satrush_config: solana_address::Address) -> &mut Self {
181                        self.satrush_config = Some(satrush_config);
182                    self
183    }
184            /// The treasury: owns the fee pool and signs the withdrawal transfer.
185#[inline(always)]
186    pub fn treasury(&mut self, treasury: solana_address::Address) -> &mut Self {
187                        self.treasury = Some(treasury);
188                    self
189    }
190            #[inline(always)]
191    pub fn usd_mint(&mut self, usd_mint: solana_address::Address) -> &mut Self {
192                        self.usd_mint = Some(usd_mint);
193                    self
194    }
195            /// Treasury's USD fee pool — the withdrawal source.
196#[inline(always)]
197    pub fn treasury_usd_ata(&mut self, treasury_usd_ata: solana_address::Address) -> &mut Self {
198                        self.treasury_usd_ata = Some(treasury_usd_ata);
199                    self
200    }
201            /// as the authority of the destination ATA.
202#[inline(always)]
203    pub fn fee_recipient(&mut self, fee_recipient: solana_address::Address) -> &mut Self {
204                        self.fee_recipient = Some(fee_recipient);
205                    self
206    }
207            /// Fee recipient's USD account — the withdrawal destination. Created by the
208/// crank if missing.
209#[inline(always)]
210    pub fn fee_recipient_usd_ata(&mut self, fee_recipient_usd_ata: solana_address::Address) -> &mut Self {
211                        self.fee_recipient_usd_ata = Some(fee_recipient_usd_ata);
212                    self
213    }
214            /// `[optional account, default to 'TokenkegQfeZyiNwAJbNbGKPFXCWuBvf9Ss623VQ5DA']`
215#[inline(always)]
216    pub fn token_program(&mut self, token_program: solana_address::Address) -> &mut Self {
217                        self.token_program = Some(token_program);
218                    self
219    }
220            /// `[optional account, default to 'ATokenGPvbdGVxr1b2hvZbsiqW5xWH25efTNsLJA8knL']`
221#[inline(always)]
222    pub fn associated_token_program(&mut self, associated_token_program: solana_address::Address) -> &mut Self {
223                        self.associated_token_program = Some(associated_token_program);
224                    self
225    }
226            /// `[optional account, default to '11111111111111111111111111111111']`
227#[inline(always)]
228    pub fn system_program(&mut self, system_program: solana_address::Address) -> &mut Self {
229                        self.system_program = Some(system_program);
230                    self
231    }
232            /// Add an additional account to the instruction.
233  #[inline(always)]
234  pub fn add_remaining_account(&mut self, account: solana_instruction::AccountMeta) -> &mut Self {
235    self.__remaining_accounts.push(account);
236    self
237  }
238  /// Add additional accounts to the instruction.
239  #[inline(always)]
240  pub fn add_remaining_accounts(&mut self, accounts: &[solana_instruction::AccountMeta]) -> &mut Self {
241    self.__remaining_accounts.extend_from_slice(accounts);
242    self
243  }
244  #[allow(clippy::clone_on_copy)]
245  pub fn instruction(&self) -> solana_instruction::Instruction {
246    let accounts = WithdrawProtocolFees {
247                              authority: self.authority.expect("authority is not set"),
248                                        satrush_config: self.satrush_config.expect("satrush_config is not set"),
249                                        treasury: self.treasury.expect("treasury is not set"),
250                                        usd_mint: self.usd_mint.expect("usd_mint is not set"),
251                                        treasury_usd_ata: self.treasury_usd_ata.expect("treasury_usd_ata is not set"),
252                                        fee_recipient: self.fee_recipient.expect("fee_recipient is not set"),
253                                        fee_recipient_usd_ata: self.fee_recipient_usd_ata.expect("fee_recipient_usd_ata is not set"),
254                                        token_program: self.token_program.unwrap_or(solana_address::address!("TokenkegQfeZyiNwAJbNbGKPFXCWuBvf9Ss623VQ5DA")),
255                                        associated_token_program: self.associated_token_program.unwrap_or(solana_address::address!("ATokenGPvbdGVxr1b2hvZbsiqW5xWH25efTNsLJA8knL")),
256                                        system_program: self.system_program.unwrap_or(solana_address::address!("11111111111111111111111111111111")),
257                      };
258    
259    accounts.instruction_with_remaining_accounts(&self.__remaining_accounts)
260  }
261}
262
263  /// `withdraw_protocol_fees` CPI accounts.
264  pub struct WithdrawProtocolFeesCpiAccounts<'a, 'b> {
265          
266                    
267              pub authority: &'b solana_account_info::AccountInfo<'a>,
268                
269                    
270              pub satrush_config: &'b solana_account_info::AccountInfo<'a>,
271                        /// The treasury: owns the fee pool and signs the withdrawal transfer.
272
273      
274                    
275              pub treasury: &'b solana_account_info::AccountInfo<'a>,
276                
277                    
278              pub usd_mint: &'b solana_account_info::AccountInfo<'a>,
279                        /// Treasury's USD fee pool — the withdrawal source.
280
281      
282                    
283              pub treasury_usd_ata: &'b solana_account_info::AccountInfo<'a>,
284                        /// as the authority of the destination ATA.
285
286      
287                    
288              pub fee_recipient: &'b solana_account_info::AccountInfo<'a>,
289                        /// Fee recipient's USD account — the withdrawal destination. Created by the
290/// crank if missing.
291
292      
293                    
294              pub fee_recipient_usd_ata: &'b solana_account_info::AccountInfo<'a>,
295                
296                    
297              pub token_program: &'b solana_account_info::AccountInfo<'a>,
298                
299                    
300              pub associated_token_program: &'b solana_account_info::AccountInfo<'a>,
301                
302                    
303              pub system_program: &'b solana_account_info::AccountInfo<'a>,
304            }
305
306/// `withdraw_protocol_fees` CPI instruction.
307pub struct WithdrawProtocolFeesCpi<'a, 'b> {
308  /// The program to invoke.
309  pub __program: &'b solana_account_info::AccountInfo<'a>,
310      
311              
312          pub authority: &'b solana_account_info::AccountInfo<'a>,
313          
314              
315          pub satrush_config: &'b solana_account_info::AccountInfo<'a>,
316                /// The treasury: owns the fee pool and signs the withdrawal transfer.
317
318    
319              
320          pub treasury: &'b solana_account_info::AccountInfo<'a>,
321          
322              
323          pub usd_mint: &'b solana_account_info::AccountInfo<'a>,
324                /// Treasury's USD fee pool — the withdrawal source.
325
326    
327              
328          pub treasury_usd_ata: &'b solana_account_info::AccountInfo<'a>,
329                /// as the authority of the destination ATA.
330
331    
332              
333          pub fee_recipient: &'b solana_account_info::AccountInfo<'a>,
334                /// Fee recipient's USD account — the withdrawal destination. Created by the
335/// crank if missing.
336
337    
338              
339          pub fee_recipient_usd_ata: &'b solana_account_info::AccountInfo<'a>,
340          
341              
342          pub token_program: &'b solana_account_info::AccountInfo<'a>,
343          
344              
345          pub associated_token_program: &'b solana_account_info::AccountInfo<'a>,
346          
347              
348          pub system_program: &'b solana_account_info::AccountInfo<'a>,
349        }
350
351impl<'a, 'b> WithdrawProtocolFeesCpi<'a, 'b> {
352  pub fn new(
353    program: &'b solana_account_info::AccountInfo<'a>,
354          accounts: WithdrawProtocolFeesCpiAccounts<'a, 'b>,
355          ) -> Self {
356    Self {
357      __program: program,
358              authority: accounts.authority,
359              satrush_config: accounts.satrush_config,
360              treasury: accounts.treasury,
361              usd_mint: accounts.usd_mint,
362              treasury_usd_ata: accounts.treasury_usd_ata,
363              fee_recipient: accounts.fee_recipient,
364              fee_recipient_usd_ata: accounts.fee_recipient_usd_ata,
365              token_program: accounts.token_program,
366              associated_token_program: accounts.associated_token_program,
367              system_program: accounts.system_program,
368                }
369  }
370  #[inline(always)]
371  pub fn invoke(&self) -> solana_program_error::ProgramResult {
372    self.invoke_signed_with_remaining_accounts(&[], &[])
373  }
374  #[inline(always)]
375  pub fn invoke_with_remaining_accounts(&self, remaining_accounts: &[(&'b solana_account_info::AccountInfo<'a>, bool, bool)]) -> solana_program_error::ProgramResult {
376    self.invoke_signed_with_remaining_accounts(&[], remaining_accounts)
377  }
378  #[inline(always)]
379  pub fn invoke_signed(&self, signers_seeds: &[&[&[u8]]]) -> solana_program_error::ProgramResult {
380    self.invoke_signed_with_remaining_accounts(signers_seeds, &[])
381  }
382  #[allow(clippy::arithmetic_side_effects)]
383  #[allow(clippy::clone_on_copy)]
384  #[allow(clippy::vec_init_then_push)]
385  pub fn invoke_signed_with_remaining_accounts(
386    &self,
387    signers_seeds: &[&[&[u8]]],
388    remaining_accounts: &[(&'b solana_account_info::AccountInfo<'a>, bool, bool)]
389  ) -> solana_program_error::ProgramResult {
390    let mut accounts = Vec::with_capacity(10+ remaining_accounts.len());
391                            accounts.push(solana_instruction::AccountMeta::new(
392            *self.authority.key,
393            true
394          ));
395                                          accounts.push(solana_instruction::AccountMeta::new_readonly(
396            *self.satrush_config.key,
397            false
398          ));
399                                          accounts.push(solana_instruction::AccountMeta::new(
400            *self.treasury.key,
401            false
402          ));
403                                          accounts.push(solana_instruction::AccountMeta::new_readonly(
404            *self.usd_mint.key,
405            false
406          ));
407                                          accounts.push(solana_instruction::AccountMeta::new(
408            *self.treasury_usd_ata.key,
409            false
410          ));
411                                          accounts.push(solana_instruction::AccountMeta::new_readonly(
412            *self.fee_recipient.key,
413            false
414          ));
415                                          accounts.push(solana_instruction::AccountMeta::new(
416            *self.fee_recipient_usd_ata.key,
417            false
418          ));
419                                          accounts.push(solana_instruction::AccountMeta::new_readonly(
420            *self.token_program.key,
421            false
422          ));
423                                          accounts.push(solana_instruction::AccountMeta::new_readonly(
424            *self.associated_token_program.key,
425            false
426          ));
427                                          accounts.push(solana_instruction::AccountMeta::new_readonly(
428            *self.system_program.key,
429            false
430          ));
431                      remaining_accounts.iter().for_each(|remaining_account| {
432      accounts.push(solana_instruction::AccountMeta {
433          pubkey: *remaining_account.0.key,
434          is_signer: remaining_account.1,
435          is_writable: remaining_account.2,
436      })
437    });
438    let data = WithdrawProtocolFeesInstructionData::new().try_to_vec().unwrap();
439    
440    let instruction = solana_instruction::Instruction {
441      program_id: crate::SATRUSH_ID,
442      accounts,
443      data,
444    };
445    let mut account_infos = Vec::with_capacity(11 + remaining_accounts.len());
446    account_infos.push(self.__program.clone());
447                  account_infos.push(self.authority.clone());
448                        account_infos.push(self.satrush_config.clone());
449                        account_infos.push(self.treasury.clone());
450                        account_infos.push(self.usd_mint.clone());
451                        account_infos.push(self.treasury_usd_ata.clone());
452                        account_infos.push(self.fee_recipient.clone());
453                        account_infos.push(self.fee_recipient_usd_ata.clone());
454                        account_infos.push(self.token_program.clone());
455                        account_infos.push(self.associated_token_program.clone());
456                        account_infos.push(self.system_program.clone());
457              remaining_accounts.iter().for_each(|remaining_account| account_infos.push(remaining_account.0.clone()));
458
459    if signers_seeds.is_empty() {
460      solana_cpi::invoke(&instruction, &account_infos)
461    } else {
462      solana_cpi::invoke_signed(&instruction, &account_infos, signers_seeds)
463    }
464  }
465}
466
467/// Instruction builder for `WithdrawProtocolFees` via CPI.
468///
469/// ### Accounts:
470///
471                      ///   0. `[writable, signer]` authority
472          ///   1. `[]` satrush_config
473                ///   2. `[writable]` treasury
474          ///   3. `[]` usd_mint
475                ///   4. `[writable]` treasury_usd_ata
476          ///   5. `[]` fee_recipient
477                ///   6. `[writable]` fee_recipient_usd_ata
478          ///   7. `[]` token_program
479          ///   8. `[]` associated_token_program
480          ///   9. `[]` system_program
481#[derive(Clone, Debug)]
482pub struct WithdrawProtocolFeesCpiBuilder<'a, 'b> {
483  instruction: Box<WithdrawProtocolFeesCpiBuilderInstruction<'a, 'b>>,
484}
485
486impl<'a, 'b> WithdrawProtocolFeesCpiBuilder<'a, 'b> {
487  pub fn new(program: &'b solana_account_info::AccountInfo<'a>) -> Self {
488    let instruction = Box::new(WithdrawProtocolFeesCpiBuilderInstruction {
489      __program: program,
490              authority: None,
491              satrush_config: None,
492              treasury: None,
493              usd_mint: None,
494              treasury_usd_ata: None,
495              fee_recipient: None,
496              fee_recipient_usd_ata: None,
497              token_program: None,
498              associated_token_program: None,
499              system_program: None,
500                                __remaining_accounts: Vec::new(),
501    });
502    Self { instruction }
503  }
504      #[inline(always)]
505    pub fn authority(&mut self, authority: &'b solana_account_info::AccountInfo<'a>) -> &mut Self {
506                        self.instruction.authority = Some(authority);
507                    self
508    }
509      #[inline(always)]
510    pub fn satrush_config(&mut self, satrush_config: &'b solana_account_info::AccountInfo<'a>) -> &mut Self {
511                        self.instruction.satrush_config = Some(satrush_config);
512                    self
513    }
514      /// The treasury: owns the fee pool and signs the withdrawal transfer.
515#[inline(always)]
516    pub fn treasury(&mut self, treasury: &'b solana_account_info::AccountInfo<'a>) -> &mut Self {
517                        self.instruction.treasury = Some(treasury);
518                    self
519    }
520      #[inline(always)]
521    pub fn usd_mint(&mut self, usd_mint: &'b solana_account_info::AccountInfo<'a>) -> &mut Self {
522                        self.instruction.usd_mint = Some(usd_mint);
523                    self
524    }
525      /// Treasury's USD fee pool — the withdrawal source.
526#[inline(always)]
527    pub fn treasury_usd_ata(&mut self, treasury_usd_ata: &'b solana_account_info::AccountInfo<'a>) -> &mut Self {
528                        self.instruction.treasury_usd_ata = Some(treasury_usd_ata);
529                    self
530    }
531      /// as the authority of the destination ATA.
532#[inline(always)]
533    pub fn fee_recipient(&mut self, fee_recipient: &'b solana_account_info::AccountInfo<'a>) -> &mut Self {
534                        self.instruction.fee_recipient = Some(fee_recipient);
535                    self
536    }
537      /// Fee recipient's USD account — the withdrawal destination. Created by the
538/// crank if missing.
539#[inline(always)]
540    pub fn fee_recipient_usd_ata(&mut self, fee_recipient_usd_ata: &'b solana_account_info::AccountInfo<'a>) -> &mut Self {
541                        self.instruction.fee_recipient_usd_ata = Some(fee_recipient_usd_ata);
542                    self
543    }
544      #[inline(always)]
545    pub fn token_program(&mut self, token_program: &'b solana_account_info::AccountInfo<'a>) -> &mut Self {
546                        self.instruction.token_program = Some(token_program);
547                    self
548    }
549      #[inline(always)]
550    pub fn associated_token_program(&mut self, associated_token_program: &'b solana_account_info::AccountInfo<'a>) -> &mut Self {
551                        self.instruction.associated_token_program = Some(associated_token_program);
552                    self
553    }
554      #[inline(always)]
555    pub fn system_program(&mut self, system_program: &'b solana_account_info::AccountInfo<'a>) -> &mut Self {
556                        self.instruction.system_program = Some(system_program);
557                    self
558    }
559            /// Add an additional account to the instruction.
560  #[inline(always)]
561  pub fn add_remaining_account(&mut self, account: &'b solana_account_info::AccountInfo<'a>, is_writable: bool, is_signer: bool) -> &mut Self {
562    self.instruction.__remaining_accounts.push((account, is_writable, is_signer));
563    self
564  }
565  /// Add additional accounts to the instruction.
566  ///
567  /// Each account is represented by a tuple of the `AccountInfo`, a `bool` indicating whether the account is writable or not,
568  /// and a `bool` indicating whether the account is a signer or not.
569  #[inline(always)]
570  pub fn add_remaining_accounts(&mut self, accounts: &[(&'b solana_account_info::AccountInfo<'a>, bool, bool)]) -> &mut Self {
571    self.instruction.__remaining_accounts.extend_from_slice(accounts);
572    self
573  }
574  #[inline(always)]
575  pub fn invoke(&self) -> solana_program_error::ProgramResult {
576    self.invoke_signed(&[])
577  }
578  #[allow(clippy::clone_on_copy)]
579  #[allow(clippy::vec_init_then_push)]
580  pub fn invoke_signed(&self, signers_seeds: &[&[&[u8]]]) -> solana_program_error::ProgramResult {
581        let instruction = WithdrawProtocolFeesCpi {
582        __program: self.instruction.__program,
583                  
584          authority: self.instruction.authority.expect("authority is not set"),
585                  
586          satrush_config: self.instruction.satrush_config.expect("satrush_config is not set"),
587                  
588          treasury: self.instruction.treasury.expect("treasury is not set"),
589                  
590          usd_mint: self.instruction.usd_mint.expect("usd_mint is not set"),
591                  
592          treasury_usd_ata: self.instruction.treasury_usd_ata.expect("treasury_usd_ata is not set"),
593                  
594          fee_recipient: self.instruction.fee_recipient.expect("fee_recipient is not set"),
595                  
596          fee_recipient_usd_ata: self.instruction.fee_recipient_usd_ata.expect("fee_recipient_usd_ata is not set"),
597                  
598          token_program: self.instruction.token_program.expect("token_program is not set"),
599                  
600          associated_token_program: self.instruction.associated_token_program.expect("associated_token_program is not set"),
601                  
602          system_program: self.instruction.system_program.expect("system_program is not set"),
603                    };
604    instruction.invoke_signed_with_remaining_accounts(signers_seeds, &self.instruction.__remaining_accounts)
605  }
606}
607
608#[derive(Clone, Debug)]
609struct WithdrawProtocolFeesCpiBuilderInstruction<'a, 'b> {
610  __program: &'b solana_account_info::AccountInfo<'a>,
611            authority: Option<&'b solana_account_info::AccountInfo<'a>>,
612                satrush_config: Option<&'b solana_account_info::AccountInfo<'a>>,
613                treasury: Option<&'b solana_account_info::AccountInfo<'a>>,
614                usd_mint: Option<&'b solana_account_info::AccountInfo<'a>>,
615                treasury_usd_ata: Option<&'b solana_account_info::AccountInfo<'a>>,
616                fee_recipient: Option<&'b solana_account_info::AccountInfo<'a>>,
617                fee_recipient_usd_ata: Option<&'b solana_account_info::AccountInfo<'a>>,
618                token_program: Option<&'b solana_account_info::AccountInfo<'a>>,
619                associated_token_program: Option<&'b solana_account_info::AccountInfo<'a>>,
620                system_program: Option<&'b solana_account_info::AccountInfo<'a>>,
621                /// Additional instruction accounts `(AccountInfo, is_writable, is_signer)`.
622  __remaining_accounts: Vec<(&'b solana_account_info::AccountInfo<'a>, bool, bool)>,
623}
624