1
0

idl.json 85 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744745746747748749750751752753754755756757758759760761762763764765766767768769770771772773774775776777778779780781782783784785786787788789790791792793794795796797798799800801802803804805806807808809810811812813814815816817818819820821822823824825826827828829830831832833834835836837838839840841842843844845846847848849850851852853854855856857858859860861862863864865866867868869870871872873874875876877878879880881882883884885886887888889890891892893894895896897898899900901902903904905906907908909910911912913914915916917918919920921922923924925926927928929930931932933934935936937938939940941942943944945946947948949950951952953954955956957958959960961962963964965966967968969970971972973974975976977978979980981982983984985986987988989990991992993994995996997998999100010011002100310041005100610071008100910101011101210131014101510161017101810191020102110221023102410251026102710281029103010311032103310341035103610371038103910401041104210431044104510461047104810491050105110521053105410551056105710581059106010611062106310641065106610671068106910701071107210731074107510761077107810791080108110821083108410851086108710881089109010911092109310941095109610971098109911001101110211031104110511061107110811091110111111121113111411151116111711181119112011211122112311241125112611271128112911301131113211331134113511361137113811391140114111421143114411451146114711481149115011511152115311541155115611571158115911601161116211631164116511661167116811691170117111721173117411751176117711781179118011811182118311841185118611871188118911901191119211931194119511961197119811991200120112021203120412051206120712081209121012111212121312141215121612171218121912201221122212231224122512261227122812291230123112321233123412351236123712381239124012411242124312441245124612471248124912501251125212531254125512561257125812591260126112621263126412651266126712681269127012711272127312741275127612771278127912801281128212831284128512861287128812891290129112921293129412951296129712981299130013011302130313041305130613071308130913101311131213131314131513161317131813191320132113221323132413251326132713281329133013311332133313341335133613371338133913401341134213431344134513461347134813491350135113521353135413551356135713581359136013611362136313641365136613671368136913701371137213731374137513761377137813791380138113821383138413851386138713881389139013911392139313941395139613971398139914001401140214031404140514061407140814091410141114121413141414151416141714181419142014211422142314241425142614271428142914301431143214331434143514361437143814391440144114421443144414451446144714481449145014511452145314541455145614571458145914601461146214631464146514661467146814691470147114721473147414751476147714781479148014811482148314841485148614871488148914901491149214931494149514961497149814991500150115021503150415051506150715081509151015111512151315141515151615171518151915201521152215231524152515261527152815291530153115321533153415351536153715381539154015411542154315441545154615471548154915501551155215531554155515561557155815591560156115621563156415651566156715681569157015711572157315741575157615771578157915801581158215831584158515861587158815891590159115921593159415951596159715981599160016011602160316041605160616071608160916101611161216131614161516161617161816191620162116221623162416251626162716281629163016311632163316341635163616371638163916401641164216431644164516461647164816491650165116521653165416551656165716581659166016611662166316641665166616671668166916701671167216731674167516761677167816791680168116821683168416851686168716881689169016911692169316941695169616971698169917001701170217031704170517061707170817091710171117121713171417151716171717181719172017211722172317241725172617271728172917301731173217331734173517361737173817391740174117421743174417451746174717481749175017511752175317541755175617571758175917601761176217631764176517661767176817691770177117721773177417751776177717781779178017811782178317841785178617871788178917901791179217931794179517961797179817991800180118021803180418051806180718081809181018111812181318141815181618171818181918201821182218231824182518261827182818291830183118321833183418351836183718381839184018411842184318441845184618471848184918501851185218531854185518561857185818591860186118621863186418651866186718681869187018711872187318741875187618771878187918801881188218831884188518861887188818891890189118921893189418951896189718981899190019011902190319041905190619071908190919101911191219131914191519161917191819191920192119221923192419251926192719281929193019311932193319341935193619371938193919401941194219431944194519461947194819491950195119521953195419551956195719581959196019611962196319641965196619671968196919701971197219731974197519761977197819791980198119821983198419851986198719881989199019911992199319941995199619971998199920002001200220032004200520062007200820092010201120122013201420152016201720182019202020212022202320242025202620272028202920302031203220332034203520362037203820392040204120422043204420452046204720482049205020512052205320542055205620572058205920602061206220632064206520662067206820692070207120722073207420752076207720782079208020812082208320842085208620872088208920902091209220932094209520962097209820992100210121022103210421052106210721082109211021112112211321142115211621172118211921202121212221232124212521262127212821292130213121322133213421352136213721382139214021412142214321442145214621472148214921502151215221532154215521562157215821592160216121622163216421652166216721682169217021712172217321742175217621772178217921802181218221832184218521862187218821892190219121922193219421952196219721982199220022012202220322042205220622072208220922102211221222132214221522162217221822192220222122222223222422252226222722282229223022312232223322342235223622372238223922402241224222432244224522462247224822492250225122522253225422552256225722582259226022612262226322642265226622672268226922702271227222732274227522762277227822792280228122822283228422852286228722882289229022912292229322942295229622972298229923002301230223032304230523062307230823092310231123122313231423152316231723182319232023212322232323242325232623272328232923302331233223332334233523362337233823392340234123422343234423452346234723482349235023512352235323542355235623572358235923602361236223632364236523662367236823692370237123722373237423752376237723782379238023812382238323842385238623872388238923902391239223932394239523962397239823992400240124022403240424052406240724082409241024112412241324142415241624172418241924202421242224232424242524262427242824292430243124322433243424352436243724382439244024412442244324442445244624472448244924502451245224532454245524562457245824592460246124622463246424652466246724682469247024712472247324742475247624772478247924802481248224832484248524862487248824892490249124922493249424952496249724982499250025012502250325042505250625072508250925102511251225132514251525162517251825192520252125222523252425252526252725282529253025312532253325342535253625372538253925402541254225432544254525462547254825492550255125522553255425552556255725582559256025612562256325642565256625672568256925702571257225732574257525762577257825792580258125822583258425852586258725882589259025912592259325942595259625972598259926002601260226032604260526062607260826092610261126122613261426152616261726182619262026212622262326242625262626272628262926302631263226332634263526362637263826392640264126422643264426452646264726482649265026512652265326542655265626572658265926602661266226632664266526662667266826692670267126722673267426752676267726782679268026812682268326842685268626872688268926902691269226932694269526962697269826992700270127022703270427052706270727082709271027112712271327142715271627172718271927202721272227232724272527262727272827292730273127322733273427352736273727382739274027412742274327442745274627472748274927502751275227532754275527562757275827592760276127622763
  1. {
  2. "kind": "rootNode",
  3. "program": {
  4. "kind": "programNode",
  5. "pdas": [],
  6. "accounts": [
  7. {
  8. "kind": "accountNode",
  9. "data": {
  10. "kind": "structTypeNode",
  11. "fields": [
  12. {
  13. "kind": "structFieldTypeNode",
  14. "name": "mintAuthority",
  15. "type": {
  16. "kind": "optionTypeNode",
  17. "item": { "kind": "publicKeyTypeNode" },
  18. "prefix": {
  19. "kind": "numberTypeNode",
  20. "format": "u32",
  21. "endian": "le"
  22. },
  23. "fixed": true
  24. },
  25. "docs": [
  26. "Optional authority used to mint new tokens. The mint authority may only",
  27. "be provided during mint creation. If no mint authority is present",
  28. "then the mint has a fixed supply and no further tokens may be minted."
  29. ]
  30. },
  31. {
  32. "kind": "structFieldTypeNode",
  33. "name": "supply",
  34. "type": {
  35. "kind": "numberTypeNode",
  36. "format": "u64",
  37. "endian": "le"
  38. },
  39. "docs": ["Total supply of tokens."]
  40. },
  41. {
  42. "kind": "structFieldTypeNode",
  43. "name": "decimals",
  44. "type": {
  45. "kind": "numberTypeNode",
  46. "format": "u8",
  47. "endian": "le"
  48. },
  49. "docs": [
  50. "Number of base 10 digits to the right of the decimal place."
  51. ]
  52. },
  53. {
  54. "kind": "structFieldTypeNode",
  55. "name": "isInitialized",
  56. "type": {
  57. "kind": "booleanTypeNode",
  58. "size": {
  59. "kind": "numberTypeNode",
  60. "format": "u8",
  61. "endian": "le"
  62. }
  63. },
  64. "docs": ["Is `true` if this structure has been initialized."]
  65. },
  66. {
  67. "kind": "structFieldTypeNode",
  68. "name": "freezeAuthority",
  69. "type": {
  70. "kind": "optionTypeNode",
  71. "item": { "kind": "publicKeyTypeNode" },
  72. "prefix": {
  73. "kind": "numberTypeNode",
  74. "format": "u32",
  75. "endian": "le"
  76. },
  77. "fixed": true
  78. },
  79. "docs": ["Optional authority to freeze token accounts."]
  80. }
  81. ]
  82. },
  83. "discriminators": [
  84. {
  85. "kind": "sizeDiscriminatorNode",
  86. "size": 82
  87. }
  88. ],
  89. "name": "mint",
  90. "docs": [],
  91. "size": 82
  92. },
  93. {
  94. "kind": "accountNode",
  95. "data": {
  96. "kind": "structTypeNode",
  97. "fields": [
  98. {
  99. "kind": "structFieldTypeNode",
  100. "name": "mint",
  101. "type": { "kind": "publicKeyTypeNode" },
  102. "docs": ["The mint associated with this account."]
  103. },
  104. {
  105. "kind": "structFieldTypeNode",
  106. "name": "owner",
  107. "type": { "kind": "publicKeyTypeNode" },
  108. "docs": ["The owner of this account."]
  109. },
  110. {
  111. "kind": "structFieldTypeNode",
  112. "name": "amount",
  113. "type": {
  114. "kind": "numberTypeNode",
  115. "format": "u64",
  116. "endian": "le"
  117. },
  118. "docs": ["The amount of tokens this account holds."]
  119. },
  120. {
  121. "kind": "structFieldTypeNode",
  122. "name": "delegate",
  123. "type": {
  124. "kind": "optionTypeNode",
  125. "item": { "kind": "publicKeyTypeNode" },
  126. "prefix": {
  127. "kind": "numberTypeNode",
  128. "format": "u32",
  129. "endian": "le"
  130. },
  131. "fixed": true
  132. },
  133. "docs": [
  134. "If `delegate` is `Some` then `delegated_amount` represents",
  135. "the amount authorized by the delegate."
  136. ]
  137. },
  138. {
  139. "kind": "structFieldTypeNode",
  140. "name": "state",
  141. "type": { "kind": "definedTypeLinkNode", "name": "accountState" },
  142. "docs": ["The account's state."]
  143. },
  144. {
  145. "kind": "structFieldTypeNode",
  146. "name": "isNative",
  147. "type": {
  148. "kind": "optionTypeNode",
  149. "item": {
  150. "kind": "numberTypeNode",
  151. "format": "u64",
  152. "endian": "le"
  153. },
  154. "prefix": {
  155. "kind": "numberTypeNode",
  156. "format": "u32",
  157. "endian": "le"
  158. },
  159. "fixed": true
  160. },
  161. "docs": [
  162. "If is_native.is_some, this is a native token, and the value logs the",
  163. "rent-exempt reserve. An Account is required to be rent-exempt, so",
  164. "the value is used by the Processor to ensure that wrapped SOL",
  165. "accounts do not drop below this threshold."
  166. ]
  167. },
  168. {
  169. "kind": "structFieldTypeNode",
  170. "name": "delegatedAmount",
  171. "type": {
  172. "kind": "numberTypeNode",
  173. "format": "u64",
  174. "endian": "le"
  175. },
  176. "docs": ["The amount delegated."]
  177. },
  178. {
  179. "kind": "structFieldTypeNode",
  180. "name": "closeAuthority",
  181. "type": {
  182. "kind": "optionTypeNode",
  183. "item": { "kind": "publicKeyTypeNode" },
  184. "prefix": {
  185. "kind": "numberTypeNode",
  186. "format": "u32",
  187. "endian": "le"
  188. },
  189. "fixed": true
  190. },
  191. "docs": ["Optional authority to close the account."]
  192. }
  193. ]
  194. },
  195. "discriminators": [
  196. {
  197. "kind": "sizeDiscriminatorNode",
  198. "size": 165
  199. }
  200. ],
  201. "name": "token",
  202. "docs": [],
  203. "size": 165
  204. },
  205. {
  206. "kind": "accountNode",
  207. "data": {
  208. "kind": "structTypeNode",
  209. "fields": [
  210. {
  211. "kind": "structFieldTypeNode",
  212. "name": "m",
  213. "type": {
  214. "kind": "numberTypeNode",
  215. "format": "u8",
  216. "endian": "le"
  217. },
  218. "docs": ["Number of signers required."]
  219. },
  220. {
  221. "kind": "structFieldTypeNode",
  222. "name": "n",
  223. "type": {
  224. "kind": "numberTypeNode",
  225. "format": "u8",
  226. "endian": "le"
  227. },
  228. "docs": ["Number of valid signers."]
  229. },
  230. {
  231. "kind": "structFieldTypeNode",
  232. "name": "isInitialized",
  233. "type": {
  234. "kind": "booleanTypeNode",
  235. "size": {
  236. "kind": "numberTypeNode",
  237. "format": "u8",
  238. "endian": "le"
  239. }
  240. },
  241. "docs": ["Is `true` if this structure has been initialized."]
  242. },
  243. {
  244. "kind": "structFieldTypeNode",
  245. "name": "signers",
  246. "type": {
  247. "kind": "arrayTypeNode",
  248. "item": { "kind": "publicKeyTypeNode" },
  249. "count": { "kind": "fixedCountNode", "value": 11 }
  250. },
  251. "docs": ["Signer public keys."]
  252. }
  253. ]
  254. },
  255. "discriminators": [
  256. {
  257. "kind": "sizeDiscriminatorNode",
  258. "size": 355
  259. }
  260. ],
  261. "name": "multisig",
  262. "docs": [],
  263. "size": 355
  264. }
  265. ],
  266. "instructions": [
  267. {
  268. "kind": "instructionNode",
  269. "accounts": [
  270. {
  271. "kind": "instructionAccountNode",
  272. "name": "mint",
  273. "isWritable": true,
  274. "isSigner": false,
  275. "isOptional": false,
  276. "docs": ["Token mint account."]
  277. },
  278. {
  279. "kind": "instructionAccountNode",
  280. "name": "rent",
  281. "isWritable": false,
  282. "isSigner": false,
  283. "isOptional": false,
  284. "docs": ["Rent sysvar."],
  285. "defaultValue": {
  286. "kind": "publicKeyValueNode",
  287. "publicKey": "SysvarRent111111111111111111111111111111111"
  288. }
  289. }
  290. ],
  291. "arguments": [
  292. {
  293. "kind": "instructionArgumentNode",
  294. "name": "discriminator",
  295. "type": {
  296. "kind": "numberTypeNode",
  297. "format": "u8",
  298. "endian": "le"
  299. },
  300. "docs": [],
  301. "defaultValue": { "kind": "numberValueNode", "number": 0 },
  302. "defaultValueStrategy": "omitted"
  303. },
  304. {
  305. "kind": "instructionArgumentNode",
  306. "name": "decimals",
  307. "type": {
  308. "kind": "numberTypeNode",
  309. "format": "u8",
  310. "endian": "le"
  311. },
  312. "docs": ["Number of decimals in token account amounts."]
  313. },
  314. {
  315. "kind": "instructionArgumentNode",
  316. "name": "mintAuthority",
  317. "type": { "kind": "publicKeyTypeNode" },
  318. "docs": ["Minting authority."]
  319. },
  320. {
  321. "kind": "instructionArgumentNode",
  322. "name": "freezeAuthority",
  323. "type": {
  324. "kind": "optionTypeNode",
  325. "item": { "kind": "publicKeyTypeNode" },
  326. "prefix": {
  327. "kind": "numberTypeNode",
  328. "format": "u8",
  329. "endian": "le"
  330. },
  331. "fixed": false
  332. },
  333. "defaultValue": {
  334. "kind": "noneValueNode"
  335. },
  336. "docs": ["Optional authority that can freeze token accounts."]
  337. }
  338. ],
  339. "discriminators": [
  340. {
  341. "kind": "fieldDiscriminatorNode",
  342. "name": "discriminator",
  343. "offset": 0
  344. }
  345. ],
  346. "name": "initializeMint",
  347. "docs": [
  348. "Initializes a new mint and optionally deposits all the newly minted",
  349. "tokens in an account.",
  350. "",
  351. "The `InitializeMint` instruction requires no signers and MUST be",
  352. "included within the same Transaction as the system program's",
  353. "`CreateAccount` instruction that creates the account being initialized.",
  354. "Otherwise another party can acquire ownership of the uninitialized account."
  355. ],
  356. "optionalAccountStrategy": "programId"
  357. },
  358. {
  359. "kind": "instructionNode",
  360. "accounts": [
  361. {
  362. "kind": "instructionAccountNode",
  363. "name": "account",
  364. "isWritable": true,
  365. "isSigner": false,
  366. "isOptional": false,
  367. "docs": ["The account to initialize."]
  368. },
  369. {
  370. "kind": "instructionAccountNode",
  371. "name": "mint",
  372. "isWritable": false,
  373. "isSigner": false,
  374. "isOptional": false,
  375. "docs": ["The mint this account will be associated with."]
  376. },
  377. {
  378. "kind": "instructionAccountNode",
  379. "name": "owner",
  380. "isWritable": false,
  381. "isSigner": false,
  382. "isOptional": false,
  383. "docs": ["The new account's owner/multisignature."]
  384. },
  385. {
  386. "kind": "instructionAccountNode",
  387. "name": "rent",
  388. "isWritable": false,
  389. "isSigner": false,
  390. "isOptional": false,
  391. "docs": ["Rent sysvar."],
  392. "defaultValue": {
  393. "kind": "publicKeyValueNode",
  394. "publicKey": "SysvarRent111111111111111111111111111111111"
  395. }
  396. }
  397. ],
  398. "arguments": [
  399. {
  400. "kind": "instructionArgumentNode",
  401. "name": "discriminator",
  402. "type": {
  403. "kind": "numberTypeNode",
  404. "format": "u8",
  405. "endian": "le"
  406. },
  407. "docs": [],
  408. "defaultValue": { "kind": "numberValueNode", "number": 1 },
  409. "defaultValueStrategy": "omitted"
  410. }
  411. ],
  412. "discriminators": [
  413. {
  414. "kind": "fieldDiscriminatorNode",
  415. "name": "discriminator",
  416. "offset": 0
  417. }
  418. ],
  419. "name": "initializeAccount",
  420. "docs": [
  421. "Initializes a new account to hold tokens. If this account is associated",
  422. "with the native mint then the token balance of the initialized account",
  423. "will be equal to the amount of SOL in the account. If this account is",
  424. "associated with another mint, that mint must be initialized before this",
  425. "command can succeed.",
  426. "",
  427. "The `InitializeAccount` instruction requires no signers and MUST be",
  428. "included within the same Transaction as the system program's",
  429. "`CreateAccount` instruction that creates the account being initialized.",
  430. "Otherwise another party can acquire ownership of the uninitialized account."
  431. ],
  432. "optionalAccountStrategy": "programId"
  433. },
  434. {
  435. "kind": "instructionNode",
  436. "accounts": [
  437. {
  438. "kind": "instructionAccountNode",
  439. "name": "multisig",
  440. "isWritable": true,
  441. "isSigner": false,
  442. "isOptional": false,
  443. "docs": ["The multisignature account to initialize."]
  444. },
  445. {
  446. "kind": "instructionAccountNode",
  447. "name": "rent",
  448. "isWritable": false,
  449. "isSigner": false,
  450. "isOptional": false,
  451. "docs": ["Rent sysvar."],
  452. "defaultValue": {
  453. "kind": "publicKeyValueNode",
  454. "publicKey": "SysvarRent111111111111111111111111111111111"
  455. }
  456. }
  457. ],
  458. "arguments": [
  459. {
  460. "kind": "instructionArgumentNode",
  461. "name": "discriminator",
  462. "type": {
  463. "kind": "numberTypeNode",
  464. "format": "u8",
  465. "endian": "le"
  466. },
  467. "docs": [],
  468. "defaultValue": { "kind": "numberValueNode", "number": 2 },
  469. "defaultValueStrategy": "omitted"
  470. },
  471. {
  472. "kind": "instructionArgumentNode",
  473. "name": "m",
  474. "type": {
  475. "kind": "numberTypeNode",
  476. "format": "u8",
  477. "endian": "le"
  478. },
  479. "docs": [
  480. "The number of signers (M) required to validate this multisignature account."
  481. ]
  482. }
  483. ],
  484. "discriminators": [
  485. {
  486. "kind": "fieldDiscriminatorNode",
  487. "name": "discriminator",
  488. "offset": 0
  489. }
  490. ],
  491. "remainingAccounts": [
  492. {
  493. "kind": "instructionRemainingAccountsNode",
  494. "value": {
  495. "kind": "argumentValueNode",
  496. "name": "signers"
  497. }
  498. }
  499. ],
  500. "name": "initializeMultisig",
  501. "docs": [
  502. "Initializes a multisignature account with N provided signers.",
  503. "",
  504. "Multisignature accounts can used in place of any single owner/delegate",
  505. "accounts in any token instruction that require an owner/delegate to be",
  506. "present. The variant field represents the number of signers (M)",
  507. "required to validate this multisignature account.",
  508. "",
  509. "The `InitializeMultisig` instruction requires no signers and MUST be",
  510. "included within the same Transaction as the system program's",
  511. "`CreateAccount` instruction that creates the account being initialized.",
  512. "Otherwise another party can acquire ownership of the uninitialized account."
  513. ],
  514. "optionalAccountStrategy": "programId"
  515. },
  516. {
  517. "kind": "instructionNode",
  518. "accounts": [
  519. {
  520. "kind": "instructionAccountNode",
  521. "name": "source",
  522. "isWritable": true,
  523. "isSigner": false,
  524. "isOptional": false,
  525. "docs": ["The source account."]
  526. },
  527. {
  528. "kind": "instructionAccountNode",
  529. "name": "destination",
  530. "isWritable": true,
  531. "isSigner": false,
  532. "isOptional": false,
  533. "docs": ["The destination account."]
  534. },
  535. {
  536. "kind": "instructionAccountNode",
  537. "name": "authority",
  538. "isWritable": false,
  539. "isSigner": "either",
  540. "isOptional": false,
  541. "docs": [
  542. "The source account's owner/delegate or its multisignature account."
  543. ],
  544. "defaultValue": { "kind": "identityValueNode" }
  545. }
  546. ],
  547. "arguments": [
  548. {
  549. "kind": "instructionArgumentNode",
  550. "name": "discriminator",
  551. "type": {
  552. "kind": "numberTypeNode",
  553. "format": "u8",
  554. "endian": "le"
  555. },
  556. "docs": [],
  557. "defaultValue": { "kind": "numberValueNode", "number": 3 },
  558. "defaultValueStrategy": "omitted"
  559. },
  560. {
  561. "kind": "instructionArgumentNode",
  562. "name": "amount",
  563. "type": {
  564. "kind": "numberTypeNode",
  565. "format": "u64",
  566. "endian": "le"
  567. },
  568. "docs": ["The amount of tokens to transfer."]
  569. }
  570. ],
  571. "discriminators": [
  572. {
  573. "kind": "fieldDiscriminatorNode",
  574. "name": "discriminator",
  575. "offset": 0
  576. }
  577. ],
  578. "remainingAccounts": [
  579. {
  580. "kind": "instructionRemainingAccountsNode",
  581. "value": {
  582. "kind": "argumentValueNode",
  583. "name": "multiSigners"
  584. },
  585. "isOptional": true,
  586. "isSigner": true
  587. }
  588. ],
  589. "name": "transfer",
  590. "docs": [
  591. "Transfers tokens from one account to another either directly or via a delegate.",
  592. "If this account is associated with the native mint then equal amounts",
  593. "of SOL and Tokens will be transferred to the destination account."
  594. ],
  595. "optionalAccountStrategy": "programId"
  596. },
  597. {
  598. "kind": "instructionNode",
  599. "accounts": [
  600. {
  601. "kind": "instructionAccountNode",
  602. "name": "source",
  603. "isWritable": true,
  604. "isSigner": false,
  605. "isOptional": false,
  606. "docs": ["The source account."]
  607. },
  608. {
  609. "kind": "instructionAccountNode",
  610. "name": "delegate",
  611. "isWritable": false,
  612. "isSigner": false,
  613. "isOptional": false,
  614. "docs": ["The delegate."]
  615. },
  616. {
  617. "kind": "instructionAccountNode",
  618. "name": "owner",
  619. "isWritable": false,
  620. "isSigner": "either",
  621. "isOptional": false,
  622. "docs": ["The source account owner or its multisignature account."]
  623. }
  624. ],
  625. "arguments": [
  626. {
  627. "kind": "instructionArgumentNode",
  628. "name": "discriminator",
  629. "type": {
  630. "kind": "numberTypeNode",
  631. "format": "u8",
  632. "endian": "le"
  633. },
  634. "docs": [],
  635. "defaultValue": { "kind": "numberValueNode", "number": 4 },
  636. "defaultValueStrategy": "omitted"
  637. },
  638. {
  639. "kind": "instructionArgumentNode",
  640. "name": "amount",
  641. "type": {
  642. "kind": "numberTypeNode",
  643. "format": "u64",
  644. "endian": "le"
  645. },
  646. "docs": ["The amount of tokens the delegate is approved for."]
  647. }
  648. ],
  649. "discriminators": [
  650. {
  651. "kind": "fieldDiscriminatorNode",
  652. "name": "discriminator",
  653. "offset": 0
  654. }
  655. ],
  656. "remainingAccounts": [
  657. {
  658. "kind": "instructionRemainingAccountsNode",
  659. "value": {
  660. "kind": "argumentValueNode",
  661. "name": "multiSigners"
  662. },
  663. "isOptional": true,
  664. "isSigner": true
  665. }
  666. ],
  667. "name": "approve",
  668. "docs": [
  669. "Approves a delegate. A delegate is given the authority over tokens on",
  670. "behalf of the source account's owner."
  671. ],
  672. "optionalAccountStrategy": "programId"
  673. },
  674. {
  675. "kind": "instructionNode",
  676. "accounts": [
  677. {
  678. "kind": "instructionAccountNode",
  679. "name": "source",
  680. "isWritable": true,
  681. "isSigner": false,
  682. "isOptional": false,
  683. "docs": ["The source account."]
  684. },
  685. {
  686. "kind": "instructionAccountNode",
  687. "name": "owner",
  688. "isWritable": false,
  689. "isSigner": "either",
  690. "isOptional": false,
  691. "docs": ["The source account owner or its multisignature."]
  692. }
  693. ],
  694. "arguments": [
  695. {
  696. "kind": "instructionArgumentNode",
  697. "name": "discriminator",
  698. "type": {
  699. "kind": "numberTypeNode",
  700. "format": "u8",
  701. "endian": "le"
  702. },
  703. "docs": [],
  704. "defaultValue": { "kind": "numberValueNode", "number": 5 },
  705. "defaultValueStrategy": "omitted"
  706. }
  707. ],
  708. "discriminators": [
  709. {
  710. "kind": "fieldDiscriminatorNode",
  711. "name": "discriminator",
  712. "offset": 0
  713. }
  714. ],
  715. "remainingAccounts": [
  716. {
  717. "kind": "instructionRemainingAccountsNode",
  718. "value": {
  719. "kind": "argumentValueNode",
  720. "name": "multiSigners"
  721. },
  722. "isOptional": true,
  723. "isSigner": true
  724. }
  725. ],
  726. "name": "revoke",
  727. "docs": ["Revokes the delegate's authority."],
  728. "optionalAccountStrategy": "programId"
  729. },
  730. {
  731. "kind": "instructionNode",
  732. "accounts": [
  733. {
  734. "kind": "instructionAccountNode",
  735. "name": "owned",
  736. "isWritable": true,
  737. "isSigner": false,
  738. "isOptional": false,
  739. "docs": ["The mint or account to change the authority of."]
  740. },
  741. {
  742. "kind": "instructionAccountNode",
  743. "name": "owner",
  744. "isWritable": false,
  745. "isSigner": "either",
  746. "isOptional": false,
  747. "docs": [
  748. "The current authority or the multisignature account of the mint or account to update."
  749. ]
  750. }
  751. ],
  752. "arguments": [
  753. {
  754. "kind": "instructionArgumentNode",
  755. "name": "discriminator",
  756. "type": {
  757. "kind": "numberTypeNode",
  758. "format": "u8",
  759. "endian": "le"
  760. },
  761. "docs": [],
  762. "defaultValue": { "kind": "numberValueNode", "number": 6 },
  763. "defaultValueStrategy": "omitted"
  764. },
  765. {
  766. "kind": "instructionArgumentNode",
  767. "name": "authorityType",
  768. "type": { "kind": "definedTypeLinkNode", "name": "authorityType" },
  769. "docs": ["The type of authority to update."]
  770. },
  771. {
  772. "kind": "instructionArgumentNode",
  773. "name": "newAuthority",
  774. "type": {
  775. "kind": "optionTypeNode",
  776. "item": { "kind": "publicKeyTypeNode" },
  777. "prefix": {
  778. "kind": "numberTypeNode",
  779. "format": "u8",
  780. "endian": "le"
  781. },
  782. "fixed": false
  783. },
  784. "docs": ["The new authority"]
  785. }
  786. ],
  787. "discriminators": [
  788. {
  789. "kind": "fieldDiscriminatorNode",
  790. "name": "discriminator",
  791. "offset": 0
  792. }
  793. ],
  794. "remainingAccounts": [
  795. {
  796. "kind": "instructionRemainingAccountsNode",
  797. "value": {
  798. "kind": "argumentValueNode",
  799. "name": "multiSigners"
  800. },
  801. "isOptional": true,
  802. "isSigner": true
  803. }
  804. ],
  805. "name": "setAuthority",
  806. "docs": ["Sets a new authority of a mint or account."],
  807. "optionalAccountStrategy": "programId"
  808. },
  809. {
  810. "kind": "instructionNode",
  811. "accounts": [
  812. {
  813. "kind": "instructionAccountNode",
  814. "name": "mint",
  815. "isWritable": true,
  816. "isSigner": false,
  817. "isOptional": false,
  818. "docs": ["The mint account."]
  819. },
  820. {
  821. "kind": "instructionAccountNode",
  822. "name": "token",
  823. "isWritable": true,
  824. "isSigner": false,
  825. "isOptional": false,
  826. "docs": ["The account to mint tokens to."]
  827. },
  828. {
  829. "kind": "instructionAccountNode",
  830. "name": "mintAuthority",
  831. "isWritable": false,
  832. "isSigner": "either",
  833. "isOptional": false,
  834. "docs": [
  835. "The mint's minting authority or its multisignature account."
  836. ]
  837. }
  838. ],
  839. "arguments": [
  840. {
  841. "kind": "instructionArgumentNode",
  842. "name": "discriminator",
  843. "type": {
  844. "kind": "numberTypeNode",
  845. "format": "u8",
  846. "endian": "le"
  847. },
  848. "docs": [],
  849. "defaultValue": { "kind": "numberValueNode", "number": 7 },
  850. "defaultValueStrategy": "omitted"
  851. },
  852. {
  853. "kind": "instructionArgumentNode",
  854. "name": "amount",
  855. "type": {
  856. "kind": "numberTypeNode",
  857. "format": "u64",
  858. "endian": "le"
  859. },
  860. "docs": ["The amount of new tokens to mint."]
  861. }
  862. ],
  863. "discriminators": [
  864. {
  865. "kind": "fieldDiscriminatorNode",
  866. "name": "discriminator",
  867. "offset": 0
  868. }
  869. ],
  870. "remainingAccounts": [
  871. {
  872. "kind": "instructionRemainingAccountsNode",
  873. "value": {
  874. "kind": "argumentValueNode",
  875. "name": "multiSigners"
  876. },
  877. "isOptional": true,
  878. "isSigner": true
  879. }
  880. ],
  881. "name": "mintTo",
  882. "docs": [
  883. "Mints new tokens to an account. The native mint does not support minting."
  884. ],
  885. "optionalAccountStrategy": "programId"
  886. },
  887. {
  888. "kind": "instructionNode",
  889. "accounts": [
  890. {
  891. "kind": "instructionAccountNode",
  892. "name": "account",
  893. "isWritable": true,
  894. "isSigner": false,
  895. "isOptional": false,
  896. "docs": ["The account to burn from."]
  897. },
  898. {
  899. "kind": "instructionAccountNode",
  900. "name": "mint",
  901. "isWritable": true,
  902. "isSigner": false,
  903. "isOptional": false,
  904. "docs": ["The token mint."]
  905. },
  906. {
  907. "kind": "instructionAccountNode",
  908. "name": "authority",
  909. "isWritable": false,
  910. "isSigner": "either",
  911. "isOptional": false,
  912. "docs": [
  913. "The account's owner/delegate or its multisignature account."
  914. ],
  915. "defaultValue": { "kind": "identityValueNode" }
  916. }
  917. ],
  918. "arguments": [
  919. {
  920. "kind": "instructionArgumentNode",
  921. "name": "discriminator",
  922. "type": {
  923. "kind": "numberTypeNode",
  924. "format": "u8",
  925. "endian": "le"
  926. },
  927. "docs": ["The amount of tokens to burn."],
  928. "defaultValue": { "kind": "numberValueNode", "number": 8 },
  929. "defaultValueStrategy": "omitted"
  930. },
  931. {
  932. "kind": "instructionArgumentNode",
  933. "name": "amount",
  934. "type": {
  935. "kind": "numberTypeNode",
  936. "format": "u64",
  937. "endian": "le"
  938. },
  939. "docs": []
  940. }
  941. ],
  942. "discriminators": [
  943. {
  944. "kind": "fieldDiscriminatorNode",
  945. "name": "discriminator",
  946. "offset": 0
  947. }
  948. ],
  949. "remainingAccounts": [
  950. {
  951. "kind": "instructionRemainingAccountsNode",
  952. "value": {
  953. "kind": "argumentValueNode",
  954. "name": "multiSigners"
  955. },
  956. "isOptional": true,
  957. "isSigner": true
  958. }
  959. ],
  960. "name": "burn",
  961. "docs": [
  962. "Burns tokens by removing them from an account. `Burn` does not support",
  963. "accounts associated with the native mint, use `CloseAccount` instead."
  964. ],
  965. "optionalAccountStrategy": "programId"
  966. },
  967. {
  968. "kind": "instructionNode",
  969. "accounts": [
  970. {
  971. "kind": "instructionAccountNode",
  972. "name": "account",
  973. "isWritable": true,
  974. "isSigner": false,
  975. "isOptional": false,
  976. "docs": ["The account to close."]
  977. },
  978. {
  979. "kind": "instructionAccountNode",
  980. "name": "destination",
  981. "isWritable": true,
  982. "isSigner": false,
  983. "isOptional": false,
  984. "docs": ["The destination account."]
  985. },
  986. {
  987. "kind": "instructionAccountNode",
  988. "name": "owner",
  989. "isWritable": false,
  990. "isSigner": "either",
  991. "isOptional": false,
  992. "docs": ["The account's owner or its multisignature account."]
  993. }
  994. ],
  995. "arguments": [
  996. {
  997. "kind": "instructionArgumentNode",
  998. "name": "discriminator",
  999. "type": {
  1000. "kind": "numberTypeNode",
  1001. "format": "u8",
  1002. "endian": "le"
  1003. },
  1004. "docs": [],
  1005. "defaultValue": { "kind": "numberValueNode", "number": 9 },
  1006. "defaultValueStrategy": "omitted"
  1007. }
  1008. ],
  1009. "discriminators": [
  1010. {
  1011. "kind": "fieldDiscriminatorNode",
  1012. "name": "discriminator",
  1013. "offset": 0
  1014. }
  1015. ],
  1016. "remainingAccounts": [
  1017. {
  1018. "kind": "instructionRemainingAccountsNode",
  1019. "value": {
  1020. "kind": "argumentValueNode",
  1021. "name": "multiSigners"
  1022. },
  1023. "isOptional": true,
  1024. "isSigner": true
  1025. }
  1026. ],
  1027. "name": "closeAccount",
  1028. "docs": [
  1029. "Close an account by transferring all its SOL to the destination account.",
  1030. "Non-native accounts may only be closed if its token amount is zero."
  1031. ],
  1032. "optionalAccountStrategy": "programId"
  1033. },
  1034. {
  1035. "kind": "instructionNode",
  1036. "accounts": [
  1037. {
  1038. "kind": "instructionAccountNode",
  1039. "name": "account",
  1040. "isWritable": true,
  1041. "isSigner": false,
  1042. "isOptional": false,
  1043. "docs": ["The account to freeze."]
  1044. },
  1045. {
  1046. "kind": "instructionAccountNode",
  1047. "name": "mint",
  1048. "isWritable": false,
  1049. "isSigner": false,
  1050. "isOptional": false,
  1051. "docs": ["The token mint."]
  1052. },
  1053. {
  1054. "kind": "instructionAccountNode",
  1055. "name": "owner",
  1056. "isWritable": false,
  1057. "isSigner": "either",
  1058. "isOptional": false,
  1059. "docs": ["The mint freeze authority or its multisignature account."]
  1060. }
  1061. ],
  1062. "arguments": [
  1063. {
  1064. "kind": "instructionArgumentNode",
  1065. "name": "discriminator",
  1066. "type": {
  1067. "kind": "numberTypeNode",
  1068. "format": "u8",
  1069. "endian": "le"
  1070. },
  1071. "docs": [],
  1072. "defaultValue": { "kind": "numberValueNode", "number": 10 },
  1073. "defaultValueStrategy": "omitted"
  1074. }
  1075. ],
  1076. "discriminators": [
  1077. {
  1078. "kind": "fieldDiscriminatorNode",
  1079. "name": "discriminator",
  1080. "offset": 0
  1081. }
  1082. ],
  1083. "remainingAccounts": [
  1084. {
  1085. "kind": "instructionRemainingAccountsNode",
  1086. "value": {
  1087. "kind": "argumentValueNode",
  1088. "name": "multiSigners"
  1089. },
  1090. "isOptional": true,
  1091. "isSigner": true
  1092. }
  1093. ],
  1094. "name": "freezeAccount",
  1095. "docs": [
  1096. "Freeze an Initialized account using the Mint's freeze_authority (if set)."
  1097. ],
  1098. "optionalAccountStrategy": "programId"
  1099. },
  1100. {
  1101. "kind": "instructionNode",
  1102. "accounts": [
  1103. {
  1104. "kind": "instructionAccountNode",
  1105. "name": "account",
  1106. "isWritable": true,
  1107. "isSigner": false,
  1108. "isOptional": false,
  1109. "docs": ["The account to thaw."]
  1110. },
  1111. {
  1112. "kind": "instructionAccountNode",
  1113. "name": "mint",
  1114. "isWritable": false,
  1115. "isSigner": false,
  1116. "isOptional": false,
  1117. "docs": ["The token mint."]
  1118. },
  1119. {
  1120. "kind": "instructionAccountNode",
  1121. "name": "owner",
  1122. "isWritable": false,
  1123. "isSigner": "either",
  1124. "isOptional": false,
  1125. "docs": ["The mint freeze authority or its multisignature account."]
  1126. }
  1127. ],
  1128. "arguments": [
  1129. {
  1130. "kind": "instructionArgumentNode",
  1131. "name": "discriminator",
  1132. "type": {
  1133. "kind": "numberTypeNode",
  1134. "format": "u8",
  1135. "endian": "le"
  1136. },
  1137. "docs": [],
  1138. "defaultValue": { "kind": "numberValueNode", "number": 11 },
  1139. "defaultValueStrategy": "omitted"
  1140. }
  1141. ],
  1142. "discriminators": [
  1143. {
  1144. "kind": "fieldDiscriminatorNode",
  1145. "name": "discriminator",
  1146. "offset": 0
  1147. }
  1148. ],
  1149. "remainingAccounts": [
  1150. {
  1151. "kind": "instructionRemainingAccountsNode",
  1152. "value": {
  1153. "kind": "argumentValueNode",
  1154. "name": "multiSigners"
  1155. },
  1156. "isOptional": true,
  1157. "isSigner": true
  1158. }
  1159. ],
  1160. "name": "thawAccount",
  1161. "docs": [
  1162. "Thaw a Frozen account using the Mint's freeze_authority (if set)."
  1163. ],
  1164. "optionalAccountStrategy": "programId"
  1165. },
  1166. {
  1167. "kind": "instructionNode",
  1168. "accounts": [
  1169. {
  1170. "kind": "instructionAccountNode",
  1171. "name": "source",
  1172. "isWritable": true,
  1173. "isSigner": false,
  1174. "isOptional": false,
  1175. "docs": ["The source account."]
  1176. },
  1177. {
  1178. "kind": "instructionAccountNode",
  1179. "name": "mint",
  1180. "isWritable": false,
  1181. "isSigner": false,
  1182. "isOptional": false,
  1183. "docs": ["The token mint."]
  1184. },
  1185. {
  1186. "kind": "instructionAccountNode",
  1187. "name": "destination",
  1188. "isWritable": true,
  1189. "isSigner": false,
  1190. "isOptional": false,
  1191. "docs": ["The destination account."]
  1192. },
  1193. {
  1194. "kind": "instructionAccountNode",
  1195. "name": "authority",
  1196. "isWritable": false,
  1197. "isSigner": "either",
  1198. "isOptional": false,
  1199. "docs": [
  1200. "The source account's owner/delegate or its multisignature account."
  1201. ],
  1202. "defaultValue": { "kind": "identityValueNode" }
  1203. }
  1204. ],
  1205. "arguments": [
  1206. {
  1207. "kind": "instructionArgumentNode",
  1208. "name": "discriminator",
  1209. "type": {
  1210. "kind": "numberTypeNode",
  1211. "format": "u8",
  1212. "endian": "le"
  1213. },
  1214. "docs": [],
  1215. "defaultValue": { "kind": "numberValueNode", "number": 12 },
  1216. "defaultValueStrategy": "omitted"
  1217. },
  1218. {
  1219. "kind": "instructionArgumentNode",
  1220. "name": "amount",
  1221. "type": {
  1222. "kind": "numberTypeNode",
  1223. "format": "u64",
  1224. "endian": "le"
  1225. },
  1226. "docs": ["The amount of tokens to transfer."]
  1227. },
  1228. {
  1229. "kind": "instructionArgumentNode",
  1230. "name": "decimals",
  1231. "type": {
  1232. "kind": "numberTypeNode",
  1233. "format": "u8",
  1234. "endian": "le"
  1235. },
  1236. "docs": [
  1237. "Expected number of base 10 digits to the right of the decimal place."
  1238. ]
  1239. }
  1240. ],
  1241. "discriminators": [
  1242. {
  1243. "kind": "fieldDiscriminatorNode",
  1244. "name": "discriminator",
  1245. "offset": 0
  1246. }
  1247. ],
  1248. "remainingAccounts": [
  1249. {
  1250. "kind": "instructionRemainingAccountsNode",
  1251. "value": {
  1252. "kind": "argumentValueNode",
  1253. "name": "multiSigners"
  1254. },
  1255. "isOptional": true,
  1256. "isSigner": true
  1257. }
  1258. ],
  1259. "name": "transferChecked",
  1260. "docs": [
  1261. "Transfers tokens from one account to another either directly or via a",
  1262. "delegate. If this account is associated with the native mint then equal",
  1263. "amounts of SOL and Tokens will be transferred to the destination account.",
  1264. "",
  1265. "This instruction differs from Transfer in that the token mint and",
  1266. "decimals value is checked by the caller. This may be useful when",
  1267. "creating transactions offline or within a hardware wallet."
  1268. ],
  1269. "optionalAccountStrategy": "programId"
  1270. },
  1271. {
  1272. "kind": "instructionNode",
  1273. "accounts": [
  1274. {
  1275. "kind": "instructionAccountNode",
  1276. "name": "source",
  1277. "isWritable": true,
  1278. "isSigner": false,
  1279. "isOptional": false,
  1280. "docs": ["The source account."]
  1281. },
  1282. {
  1283. "kind": "instructionAccountNode",
  1284. "name": "mint",
  1285. "isWritable": false,
  1286. "isSigner": false,
  1287. "isOptional": false,
  1288. "docs": ["The token mint."]
  1289. },
  1290. {
  1291. "kind": "instructionAccountNode",
  1292. "name": "delegate",
  1293. "isWritable": false,
  1294. "isSigner": false,
  1295. "isOptional": false,
  1296. "docs": ["The delegate."]
  1297. },
  1298. {
  1299. "kind": "instructionAccountNode",
  1300. "name": "owner",
  1301. "isWritable": false,
  1302. "isSigner": "either",
  1303. "isOptional": false,
  1304. "docs": ["The source account owner or its multisignature account."]
  1305. }
  1306. ],
  1307. "arguments": [
  1308. {
  1309. "kind": "instructionArgumentNode",
  1310. "name": "discriminator",
  1311. "type": {
  1312. "kind": "numberTypeNode",
  1313. "format": "u8",
  1314. "endian": "le"
  1315. },
  1316. "docs": [],
  1317. "defaultValue": { "kind": "numberValueNode", "number": 13 },
  1318. "defaultValueStrategy": "omitted"
  1319. },
  1320. {
  1321. "kind": "instructionArgumentNode",
  1322. "name": "amount",
  1323. "type": {
  1324. "kind": "numberTypeNode",
  1325. "format": "u64",
  1326. "endian": "le"
  1327. },
  1328. "docs": ["The amount of tokens the delegate is approved for."]
  1329. },
  1330. {
  1331. "kind": "instructionArgumentNode",
  1332. "name": "decimals",
  1333. "type": {
  1334. "kind": "numberTypeNode",
  1335. "format": "u8",
  1336. "endian": "le"
  1337. },
  1338. "docs": [
  1339. "Expected number of base 10 digits to the right of the decimal place."
  1340. ]
  1341. }
  1342. ],
  1343. "discriminators": [
  1344. {
  1345. "kind": "fieldDiscriminatorNode",
  1346. "name": "discriminator",
  1347. "offset": 0
  1348. }
  1349. ],
  1350. "remainingAccounts": [
  1351. {
  1352. "kind": "instructionRemainingAccountsNode",
  1353. "value": {
  1354. "kind": "argumentValueNode",
  1355. "name": "multiSigners"
  1356. },
  1357. "isOptional": true,
  1358. "isSigner": true
  1359. }
  1360. ],
  1361. "name": "approveChecked",
  1362. "docs": [
  1363. "Approves a delegate. A delegate is given the authority over tokens on",
  1364. "behalf of the source account's owner.",
  1365. "",
  1366. "This instruction differs from Approve in that the token mint and",
  1367. "decimals value is checked by the caller. This may be useful when",
  1368. "creating transactions offline or within a hardware wallet."
  1369. ],
  1370. "optionalAccountStrategy": "programId"
  1371. },
  1372. {
  1373. "kind": "instructionNode",
  1374. "accounts": [
  1375. {
  1376. "kind": "instructionAccountNode",
  1377. "name": "mint",
  1378. "isWritable": true,
  1379. "isSigner": false,
  1380. "isOptional": false,
  1381. "docs": ["The mint."]
  1382. },
  1383. {
  1384. "kind": "instructionAccountNode",
  1385. "name": "token",
  1386. "isWritable": true,
  1387. "isSigner": false,
  1388. "isOptional": false,
  1389. "docs": ["The account to mint tokens to."]
  1390. },
  1391. {
  1392. "kind": "instructionAccountNode",
  1393. "name": "mintAuthority",
  1394. "isWritable": false,
  1395. "isSigner": "either",
  1396. "isOptional": false,
  1397. "docs": [
  1398. "The mint's minting authority or its multisignature account."
  1399. ]
  1400. }
  1401. ],
  1402. "arguments": [
  1403. {
  1404. "kind": "instructionArgumentNode",
  1405. "name": "discriminator",
  1406. "type": {
  1407. "kind": "numberTypeNode",
  1408. "format": "u8",
  1409. "endian": "le"
  1410. },
  1411. "docs": [],
  1412. "defaultValue": { "kind": "numberValueNode", "number": 14 },
  1413. "defaultValueStrategy": "omitted"
  1414. },
  1415. {
  1416. "kind": "instructionArgumentNode",
  1417. "name": "amount",
  1418. "type": {
  1419. "kind": "numberTypeNode",
  1420. "format": "u64",
  1421. "endian": "le"
  1422. },
  1423. "docs": ["The amount of new tokens to mint."]
  1424. },
  1425. {
  1426. "kind": "instructionArgumentNode",
  1427. "name": "decimals",
  1428. "type": {
  1429. "kind": "numberTypeNode",
  1430. "format": "u8",
  1431. "endian": "le"
  1432. },
  1433. "docs": [
  1434. "Expected number of base 10 digits to the right of the decimal place."
  1435. ]
  1436. }
  1437. ],
  1438. "discriminators": [
  1439. {
  1440. "kind": "fieldDiscriminatorNode",
  1441. "name": "discriminator",
  1442. "offset": 0
  1443. }
  1444. ],
  1445. "remainingAccounts": [
  1446. {
  1447. "kind": "instructionRemainingAccountsNode",
  1448. "value": {
  1449. "kind": "argumentValueNode",
  1450. "name": "multiSigners"
  1451. },
  1452. "isOptional": true,
  1453. "isSigner": true
  1454. }
  1455. ],
  1456. "name": "mintToChecked",
  1457. "docs": [
  1458. "Mints new tokens to an account. The native mint does not support minting.",
  1459. "",
  1460. "This instruction differs from MintTo in that the decimals value is",
  1461. "checked by the caller. This may be useful when creating transactions",
  1462. "offline or within a hardware wallet."
  1463. ],
  1464. "optionalAccountStrategy": "programId"
  1465. },
  1466. {
  1467. "kind": "instructionNode",
  1468. "accounts": [
  1469. {
  1470. "kind": "instructionAccountNode",
  1471. "name": "account",
  1472. "isWritable": true,
  1473. "isSigner": false,
  1474. "isOptional": false,
  1475. "docs": ["The account to burn from."]
  1476. },
  1477. {
  1478. "kind": "instructionAccountNode",
  1479. "name": "mint",
  1480. "isWritable": true,
  1481. "isSigner": false,
  1482. "isOptional": false,
  1483. "docs": ["The token mint."]
  1484. },
  1485. {
  1486. "kind": "instructionAccountNode",
  1487. "name": "authority",
  1488. "isWritable": false,
  1489. "isSigner": "either",
  1490. "isOptional": false,
  1491. "docs": [
  1492. "The account's owner/delegate or its multisignature account."
  1493. ],
  1494. "defaultValue": { "kind": "identityValueNode" }
  1495. }
  1496. ],
  1497. "arguments": [
  1498. {
  1499. "kind": "instructionArgumentNode",
  1500. "name": "discriminator",
  1501. "type": {
  1502. "kind": "numberTypeNode",
  1503. "format": "u8",
  1504. "endian": "le"
  1505. },
  1506. "docs": [],
  1507. "defaultValue": { "kind": "numberValueNode", "number": 15 },
  1508. "defaultValueStrategy": "omitted"
  1509. },
  1510. {
  1511. "kind": "instructionArgumentNode",
  1512. "name": "amount",
  1513. "type": {
  1514. "kind": "numberTypeNode",
  1515. "format": "u64",
  1516. "endian": "le"
  1517. },
  1518. "docs": ["The amount of tokens to burn."]
  1519. },
  1520. {
  1521. "kind": "instructionArgumentNode",
  1522. "name": "decimals",
  1523. "type": {
  1524. "kind": "numberTypeNode",
  1525. "format": "u8",
  1526. "endian": "le"
  1527. },
  1528. "docs": [
  1529. "Expected number of base 10 digits to the right of the decimal place."
  1530. ]
  1531. }
  1532. ],
  1533. "discriminators": [
  1534. {
  1535. "kind": "fieldDiscriminatorNode",
  1536. "name": "discriminator",
  1537. "offset": 0
  1538. }
  1539. ],
  1540. "remainingAccounts": [
  1541. {
  1542. "kind": "instructionRemainingAccountsNode",
  1543. "value": {
  1544. "kind": "argumentValueNode",
  1545. "name": "multiSigners"
  1546. },
  1547. "isOptional": true,
  1548. "isSigner": true
  1549. }
  1550. ],
  1551. "name": "burnChecked",
  1552. "docs": [
  1553. "Burns tokens by removing them from an account. `BurnChecked` does not",
  1554. "support accounts associated with the native mint, use `CloseAccount` instead.",
  1555. "",
  1556. "This instruction differs from Burn in that the decimals value is checked",
  1557. "by the caller. This may be useful when creating transactions offline or",
  1558. "within a hardware wallet."
  1559. ],
  1560. "optionalAccountStrategy": "programId"
  1561. },
  1562. {
  1563. "kind": "instructionNode",
  1564. "accounts": [
  1565. {
  1566. "kind": "instructionAccountNode",
  1567. "name": "account",
  1568. "isWritable": true,
  1569. "isSigner": false,
  1570. "isOptional": false,
  1571. "docs": ["The account to initialize."]
  1572. },
  1573. {
  1574. "kind": "instructionAccountNode",
  1575. "name": "mint",
  1576. "isWritable": false,
  1577. "isSigner": false,
  1578. "isOptional": false,
  1579. "docs": ["The mint this account will be associated with."]
  1580. },
  1581. {
  1582. "kind": "instructionAccountNode",
  1583. "name": "rent",
  1584. "isWritable": false,
  1585. "isSigner": false,
  1586. "isOptional": false,
  1587. "docs": ["Rent sysvar."],
  1588. "defaultValue": {
  1589. "kind": "publicKeyValueNode",
  1590. "publicKey": "SysvarRent111111111111111111111111111111111"
  1591. }
  1592. }
  1593. ],
  1594. "arguments": [
  1595. {
  1596. "kind": "instructionArgumentNode",
  1597. "name": "discriminator",
  1598. "type": {
  1599. "kind": "numberTypeNode",
  1600. "format": "u8",
  1601. "endian": "le"
  1602. },
  1603. "docs": [],
  1604. "defaultValue": { "kind": "numberValueNode", "number": 16 },
  1605. "defaultValueStrategy": "omitted"
  1606. },
  1607. {
  1608. "kind": "instructionArgumentNode",
  1609. "name": "owner",
  1610. "type": { "kind": "publicKeyTypeNode" },
  1611. "docs": ["The new account's owner/multisignature."]
  1612. }
  1613. ],
  1614. "discriminators": [
  1615. {
  1616. "kind": "fieldDiscriminatorNode",
  1617. "name": "discriminator",
  1618. "offset": 0
  1619. }
  1620. ],
  1621. "name": "initializeAccount2",
  1622. "docs": [
  1623. "Like InitializeAccount, but the owner pubkey is passed via instruction",
  1624. "data rather than the accounts list. This variant may be preferable",
  1625. "when using Cross Program Invocation from an instruction that does",
  1626. "not need the owner's `AccountInfo` otherwise."
  1627. ],
  1628. "optionalAccountStrategy": "programId"
  1629. },
  1630. {
  1631. "kind": "instructionNode",
  1632. "accounts": [
  1633. {
  1634. "kind": "instructionAccountNode",
  1635. "name": "account",
  1636. "isWritable": true,
  1637. "isSigner": false,
  1638. "isOptional": false,
  1639. "docs": [
  1640. "The native token account to sync with its underlying lamports."
  1641. ]
  1642. }
  1643. ],
  1644. "arguments": [
  1645. {
  1646. "kind": "instructionArgumentNode",
  1647. "name": "discriminator",
  1648. "type": {
  1649. "kind": "numberTypeNode",
  1650. "format": "u8",
  1651. "endian": "le"
  1652. },
  1653. "docs": [],
  1654. "defaultValue": { "kind": "numberValueNode", "number": 17 },
  1655. "defaultValueStrategy": "omitted"
  1656. }
  1657. ],
  1658. "discriminators": [
  1659. {
  1660. "kind": "fieldDiscriminatorNode",
  1661. "name": "discriminator",
  1662. "offset": 0
  1663. }
  1664. ],
  1665. "name": "syncNative",
  1666. "docs": [
  1667. "Given a wrapped / native token account (a token account containing SOL)",
  1668. "updates its amount field based on the account's underlying `lamports`.",
  1669. "This is useful if a non-wrapped SOL account uses",
  1670. "`system_instruction::transfer` to move lamports to a wrapped token",
  1671. "account, and needs to have its token `amount` field updated."
  1672. ],
  1673. "optionalAccountStrategy": "programId"
  1674. },
  1675. {
  1676. "kind": "instructionNode",
  1677. "accounts": [
  1678. {
  1679. "kind": "instructionAccountNode",
  1680. "name": "account",
  1681. "isWritable": true,
  1682. "isSigner": false,
  1683. "isOptional": false,
  1684. "docs": ["The account to initialize."]
  1685. },
  1686. {
  1687. "kind": "instructionAccountNode",
  1688. "name": "mint",
  1689. "isWritable": false,
  1690. "isSigner": false,
  1691. "isOptional": false,
  1692. "docs": ["The mint this account will be associated with."]
  1693. }
  1694. ],
  1695. "arguments": [
  1696. {
  1697. "kind": "instructionArgumentNode",
  1698. "name": "discriminator",
  1699. "type": {
  1700. "kind": "numberTypeNode",
  1701. "format": "u8",
  1702. "endian": "le"
  1703. },
  1704. "docs": [],
  1705. "defaultValue": { "kind": "numberValueNode", "number": 18 },
  1706. "defaultValueStrategy": "omitted"
  1707. },
  1708. {
  1709. "kind": "instructionArgumentNode",
  1710. "name": "owner",
  1711. "type": { "kind": "publicKeyTypeNode" },
  1712. "docs": ["The new account's owner/multisignature."]
  1713. }
  1714. ],
  1715. "discriminators": [
  1716. {
  1717. "kind": "fieldDiscriminatorNode",
  1718. "name": "discriminator",
  1719. "offset": 0
  1720. }
  1721. ],
  1722. "name": "initializeAccount3",
  1723. "docs": [
  1724. "Like InitializeAccount2, but does not require the Rent sysvar to be provided."
  1725. ],
  1726. "optionalAccountStrategy": "programId"
  1727. },
  1728. {
  1729. "kind": "instructionNode",
  1730. "accounts": [
  1731. {
  1732. "kind": "instructionAccountNode",
  1733. "name": "multisig",
  1734. "isWritable": true,
  1735. "isSigner": false,
  1736. "isOptional": false,
  1737. "docs": ["The multisignature account to initialize."]
  1738. }
  1739. ],
  1740. "arguments": [
  1741. {
  1742. "kind": "instructionArgumentNode",
  1743. "name": "discriminator",
  1744. "type": {
  1745. "kind": "numberTypeNode",
  1746. "format": "u8",
  1747. "endian": "le"
  1748. },
  1749. "docs": [],
  1750. "defaultValue": { "kind": "numberValueNode", "number": 19 },
  1751. "defaultValueStrategy": "omitted"
  1752. },
  1753. {
  1754. "kind": "instructionArgumentNode",
  1755. "name": "m",
  1756. "type": {
  1757. "kind": "numberTypeNode",
  1758. "format": "u8",
  1759. "endian": "le"
  1760. },
  1761. "docs": [
  1762. "The number of signers (M) required to validate this multisignature account."
  1763. ]
  1764. }
  1765. ],
  1766. "discriminators": [
  1767. {
  1768. "kind": "fieldDiscriminatorNode",
  1769. "name": "discriminator",
  1770. "offset": 0
  1771. }
  1772. ],
  1773. "remainingAccounts": [
  1774. {
  1775. "kind": "instructionRemainingAccountsNode",
  1776. "value": {
  1777. "kind": "argumentValueNode",
  1778. "name": "signers"
  1779. }
  1780. }
  1781. ],
  1782. "name": "initializeMultisig2",
  1783. "docs": [
  1784. "Like InitializeMultisig, but does not require the Rent sysvar to be provided."
  1785. ],
  1786. "optionalAccountStrategy": "programId"
  1787. },
  1788. {
  1789. "kind": "instructionNode",
  1790. "accounts": [
  1791. {
  1792. "kind": "instructionAccountNode",
  1793. "name": "mint",
  1794. "isWritable": true,
  1795. "isSigner": false,
  1796. "isOptional": false,
  1797. "docs": ["The mint to initialize."]
  1798. }
  1799. ],
  1800. "arguments": [
  1801. {
  1802. "kind": "instructionArgumentNode",
  1803. "name": "discriminator",
  1804. "type": {
  1805. "kind": "numberTypeNode",
  1806. "format": "u8",
  1807. "endian": "le"
  1808. },
  1809. "docs": [],
  1810. "defaultValue": { "kind": "numberValueNode", "number": 20 },
  1811. "defaultValueStrategy": "omitted"
  1812. },
  1813. {
  1814. "kind": "instructionArgumentNode",
  1815. "name": "decimals",
  1816. "type": {
  1817. "kind": "numberTypeNode",
  1818. "format": "u8",
  1819. "endian": "le"
  1820. },
  1821. "docs": [
  1822. "Number of base 10 digits to the right of the decimal place."
  1823. ]
  1824. },
  1825. {
  1826. "kind": "instructionArgumentNode",
  1827. "name": "mintAuthority",
  1828. "type": { "kind": "publicKeyTypeNode" },
  1829. "docs": ["The authority/multisignature to mint tokens."]
  1830. },
  1831. {
  1832. "kind": "instructionArgumentNode",
  1833. "name": "freezeAuthority",
  1834. "type": {
  1835. "kind": "optionTypeNode",
  1836. "item": { "kind": "publicKeyTypeNode" },
  1837. "prefix": {
  1838. "kind": "numberTypeNode",
  1839. "format": "u8",
  1840. "endian": "le"
  1841. },
  1842. "fixed": false
  1843. },
  1844. "defaultValue": {
  1845. "kind": "noneValueNode"
  1846. },
  1847. "docs": [
  1848. "The optional freeze authority/multisignature of the mint."
  1849. ]
  1850. }
  1851. ],
  1852. "discriminators": [
  1853. {
  1854. "kind": "fieldDiscriminatorNode",
  1855. "name": "discriminator",
  1856. "offset": 0
  1857. }
  1858. ],
  1859. "name": "initializeMint2",
  1860. "docs": [
  1861. "Like [`InitializeMint`], but does not require the Rent sysvar to be provided."
  1862. ],
  1863. "optionalAccountStrategy": "programId"
  1864. },
  1865. {
  1866. "kind": "instructionNode",
  1867. "accounts": [
  1868. {
  1869. "kind": "instructionAccountNode",
  1870. "name": "mint",
  1871. "isWritable": false,
  1872. "isSigner": false,
  1873. "isOptional": false,
  1874. "docs": ["The mint to calculate for."]
  1875. }
  1876. ],
  1877. "arguments": [
  1878. {
  1879. "kind": "instructionArgumentNode",
  1880. "name": "discriminator",
  1881. "type": {
  1882. "kind": "numberTypeNode",
  1883. "format": "u8",
  1884. "endian": "le"
  1885. },
  1886. "docs": [],
  1887. "defaultValue": { "kind": "numberValueNode", "number": 21 },
  1888. "defaultValueStrategy": "omitted"
  1889. }
  1890. ],
  1891. "discriminators": [
  1892. {
  1893. "kind": "fieldDiscriminatorNode",
  1894. "name": "discriminator",
  1895. "offset": 0
  1896. }
  1897. ],
  1898. "name": "getAccountDataSize",
  1899. "docs": [
  1900. "Gets the required size of an account for the given mint as a",
  1901. "little-endian `u64`.",
  1902. "",
  1903. "Return data can be fetched using `sol_get_return_data` and deserializing",
  1904. "the return data as a little-endian `u64`."
  1905. ],
  1906. "optionalAccountStrategy": "programId"
  1907. },
  1908. {
  1909. "kind": "instructionNode",
  1910. "accounts": [
  1911. {
  1912. "kind": "instructionAccountNode",
  1913. "name": "account",
  1914. "isWritable": true,
  1915. "isSigner": false,
  1916. "isOptional": false,
  1917. "docs": ["The account to initialize."]
  1918. }
  1919. ],
  1920. "arguments": [
  1921. {
  1922. "kind": "instructionArgumentNode",
  1923. "name": "discriminator",
  1924. "type": {
  1925. "kind": "numberTypeNode",
  1926. "format": "u8",
  1927. "endian": "le"
  1928. },
  1929. "docs": [],
  1930. "defaultValue": { "kind": "numberValueNode", "number": 22 },
  1931. "defaultValueStrategy": "omitted"
  1932. }
  1933. ],
  1934. "discriminators": [
  1935. {
  1936. "kind": "fieldDiscriminatorNode",
  1937. "name": "discriminator",
  1938. "offset": 0
  1939. }
  1940. ],
  1941. "name": "initializeImmutableOwner",
  1942. "docs": [
  1943. "Initialize the Immutable Owner extension for the given token account",
  1944. "",
  1945. "Fails if the account has already been initialized, so must be called",
  1946. "before `InitializeAccount`.",
  1947. "",
  1948. "No-ops in this version of the program, but is included for compatibility",
  1949. "with the Associated Token Account program."
  1950. ],
  1951. "optionalAccountStrategy": "programId"
  1952. },
  1953. {
  1954. "kind": "instructionNode",
  1955. "accounts": [
  1956. {
  1957. "kind": "instructionAccountNode",
  1958. "name": "mint",
  1959. "isWritable": false,
  1960. "isSigner": false,
  1961. "isOptional": false,
  1962. "docs": ["The mint to calculate for."]
  1963. }
  1964. ],
  1965. "arguments": [
  1966. {
  1967. "kind": "instructionArgumentNode",
  1968. "name": "discriminator",
  1969. "type": {
  1970. "kind": "numberTypeNode",
  1971. "format": "u8",
  1972. "endian": "le"
  1973. },
  1974. "docs": [],
  1975. "defaultValue": { "kind": "numberValueNode", "number": 23 },
  1976. "defaultValueStrategy": "omitted"
  1977. },
  1978. {
  1979. "kind": "instructionArgumentNode",
  1980. "name": "amount",
  1981. "type": {
  1982. "kind": "numberTypeNode",
  1983. "format": "u64",
  1984. "endian": "le"
  1985. },
  1986. "docs": ["The amount of tokens to reformat."]
  1987. }
  1988. ],
  1989. "discriminators": [
  1990. {
  1991. "kind": "fieldDiscriminatorNode",
  1992. "name": "discriminator",
  1993. "offset": 0
  1994. }
  1995. ],
  1996. "name": "amountToUiAmount",
  1997. "docs": [
  1998. "Convert an Amount of tokens to a UiAmount `string`, using the given",
  1999. "mint. In this version of the program, the mint can only specify the",
  2000. "number of decimals.",
  2001. "",
  2002. "Fails on an invalid mint.",
  2003. "",
  2004. "Return data can be fetched using `sol_get_return_data` and deserialized",
  2005. "with `String::from_utf8`."
  2006. ],
  2007. "optionalAccountStrategy": "programId"
  2008. },
  2009. {
  2010. "kind": "instructionNode",
  2011. "accounts": [
  2012. {
  2013. "kind": "instructionAccountNode",
  2014. "name": "mint",
  2015. "isWritable": false,
  2016. "isSigner": false,
  2017. "isOptional": false,
  2018. "docs": ["The mint to calculate for."]
  2019. }
  2020. ],
  2021. "arguments": [
  2022. {
  2023. "kind": "instructionArgumentNode",
  2024. "name": "discriminator",
  2025. "type": {
  2026. "kind": "numberTypeNode",
  2027. "format": "u8",
  2028. "endian": "le"
  2029. },
  2030. "docs": [],
  2031. "defaultValue": { "kind": "numberValueNode", "number": 24 },
  2032. "defaultValueStrategy": "omitted"
  2033. },
  2034. {
  2035. "kind": "instructionArgumentNode",
  2036. "name": "uiAmount",
  2037. "type": {
  2038. "kind": "stringTypeNode",
  2039. "encoding": "utf8"
  2040. },
  2041. "docs": ["The ui_amount of tokens to reformat."]
  2042. }
  2043. ],
  2044. "discriminators": [
  2045. {
  2046. "kind": "fieldDiscriminatorNode",
  2047. "name": "discriminator",
  2048. "offset": 0
  2049. }
  2050. ],
  2051. "name": "uiAmountToAmount",
  2052. "docs": [
  2053. "Convert a UiAmount of tokens to a little-endian `u64` raw Amount, using",
  2054. "the given mint. In this version of the program, the mint can only",
  2055. "specify the number of decimals.",
  2056. "",
  2057. "Return data can be fetched using `sol_get_return_data` and deserializing",
  2058. "the return data as a little-endian `u64`."
  2059. ],
  2060. "optionalAccountStrategy": "programId"
  2061. }
  2062. ],
  2063. "definedTypes": [
  2064. {
  2065. "kind": "definedTypeNode",
  2066. "name": "accountState",
  2067. "type": {
  2068. "kind": "enumTypeNode",
  2069. "variants": [
  2070. { "kind": "enumEmptyVariantTypeNode", "name": "uninitialized" },
  2071. { "kind": "enumEmptyVariantTypeNode", "name": "initialized" },
  2072. { "kind": "enumEmptyVariantTypeNode", "name": "frozen" }
  2073. ],
  2074. "size": { "kind": "numberTypeNode", "format": "u8", "endian": "le" }
  2075. },
  2076. "docs": []
  2077. },
  2078. {
  2079. "kind": "definedTypeNode",
  2080. "name": "authorityType",
  2081. "type": {
  2082. "kind": "enumTypeNode",
  2083. "variants": [
  2084. { "kind": "enumEmptyVariantTypeNode", "name": "mintTokens" },
  2085. { "kind": "enumEmptyVariantTypeNode", "name": "freezeAccount" },
  2086. { "kind": "enumEmptyVariantTypeNode", "name": "accountOwner" },
  2087. { "kind": "enumEmptyVariantTypeNode", "name": "closeAccount" }
  2088. ],
  2089. "size": { "kind": "numberTypeNode", "format": "u8", "endian": "le" }
  2090. },
  2091. "docs": []
  2092. }
  2093. ],
  2094. "errors": [
  2095. {
  2096. "kind": "errorNode",
  2097. "name": "notRentExempt",
  2098. "code": 0,
  2099. "message": "Lamport balance below rent-exempt threshold",
  2100. "docs": ["NotRentExempt: Lamport balance below rent-exempt threshold"]
  2101. },
  2102. {
  2103. "kind": "errorNode",
  2104. "name": "insufficientFunds",
  2105. "code": 1,
  2106. "message": "Insufficient funds",
  2107. "docs": ["InsufficientFunds: Insufficient funds"]
  2108. },
  2109. {
  2110. "kind": "errorNode",
  2111. "name": "invalidMint",
  2112. "code": 2,
  2113. "message": "Invalid Mint",
  2114. "docs": ["InvalidMint: Invalid Mint"]
  2115. },
  2116. {
  2117. "kind": "errorNode",
  2118. "name": "mintMismatch",
  2119. "code": 3,
  2120. "message": "Account not associated with this Mint",
  2121. "docs": ["MintMismatch: Account not associated with this Mint"]
  2122. },
  2123. {
  2124. "kind": "errorNode",
  2125. "name": "ownerMismatch",
  2126. "code": 4,
  2127. "message": "Owner does not match",
  2128. "docs": ["OwnerMismatch: Owner does not match"]
  2129. },
  2130. {
  2131. "kind": "errorNode",
  2132. "name": "fixedSupply",
  2133. "code": 5,
  2134. "message": "Fixed supply",
  2135. "docs": ["FixedSupply: Fixed supply"]
  2136. },
  2137. {
  2138. "kind": "errorNode",
  2139. "name": "alreadyInUse",
  2140. "code": 6,
  2141. "message": "Already in use",
  2142. "docs": ["AlreadyInUse: Already in use"]
  2143. },
  2144. {
  2145. "kind": "errorNode",
  2146. "name": "invalidNumberOfProvidedSigners",
  2147. "code": 7,
  2148. "message": "Invalid number of provided signers",
  2149. "docs": [
  2150. "InvalidNumberOfProvidedSigners: Invalid number of provided signers"
  2151. ]
  2152. },
  2153. {
  2154. "kind": "errorNode",
  2155. "name": "invalidNumberOfRequiredSigners",
  2156. "code": 8,
  2157. "message": "Invalid number of required signers",
  2158. "docs": [
  2159. "InvalidNumberOfRequiredSigners: Invalid number of required signers"
  2160. ]
  2161. },
  2162. {
  2163. "kind": "errorNode",
  2164. "name": "uninitializedState",
  2165. "code": 9,
  2166. "message": "State is unititialized",
  2167. "docs": ["UninitializedState: State is unititialized"]
  2168. },
  2169. {
  2170. "kind": "errorNode",
  2171. "name": "nativeNotSupported",
  2172. "code": 10,
  2173. "message": "Instruction does not support native tokens",
  2174. "docs": [
  2175. "NativeNotSupported: Instruction does not support native tokens"
  2176. ]
  2177. },
  2178. {
  2179. "kind": "errorNode",
  2180. "name": "nonNativeHasBalance",
  2181. "code": 11,
  2182. "message": "Non-native account can only be closed if its balance is zero",
  2183. "docs": [
  2184. "NonNativeHasBalance: Non-native account can only be closed if its balance is zero"
  2185. ]
  2186. },
  2187. {
  2188. "kind": "errorNode",
  2189. "name": "invalidInstruction",
  2190. "code": 12,
  2191. "message": "Invalid instruction",
  2192. "docs": ["InvalidInstruction: Invalid instruction"]
  2193. },
  2194. {
  2195. "kind": "errorNode",
  2196. "name": "invalidState",
  2197. "code": 13,
  2198. "message": "State is invalid for requested operation",
  2199. "docs": ["InvalidState: State is invalid for requested operation"]
  2200. },
  2201. {
  2202. "kind": "errorNode",
  2203. "name": "overflow",
  2204. "code": 14,
  2205. "message": "Operation overflowed",
  2206. "docs": ["Overflow: Operation overflowed"]
  2207. },
  2208. {
  2209. "kind": "errorNode",
  2210. "name": "authorityTypeNotSupported",
  2211. "code": 15,
  2212. "message": "Account does not support specified authority type",
  2213. "docs": [
  2214. "AuthorityTypeNotSupported: Account does not support specified authority type"
  2215. ]
  2216. },
  2217. {
  2218. "kind": "errorNode",
  2219. "name": "mintCannotFreeze",
  2220. "code": 16,
  2221. "message": "This token mint cannot freeze accounts",
  2222. "docs": ["MintCannotFreeze: This token mint cannot freeze accounts"]
  2223. },
  2224. {
  2225. "kind": "errorNode",
  2226. "name": "accountFrozen",
  2227. "code": 17,
  2228. "message": "Account is frozen",
  2229. "docs": ["AccountFrozen: Account is frozen"]
  2230. },
  2231. {
  2232. "kind": "errorNode",
  2233. "name": "mintDecimalsMismatch",
  2234. "code": 18,
  2235. "message": "The provided decimals value different from the Mint decimals",
  2236. "docs": [
  2237. "MintDecimalsMismatch: The provided decimals value different from the Mint decimals"
  2238. ]
  2239. },
  2240. {
  2241. "kind": "errorNode",
  2242. "name": "nonNativeNotSupported",
  2243. "code": 19,
  2244. "message": "Instruction does not support non-native tokens",
  2245. "docs": [
  2246. "NonNativeNotSupported: Instruction does not support non-native tokens"
  2247. ]
  2248. }
  2249. ],
  2250. "name": "token",
  2251. "prefix": "",
  2252. "publicKey": "TokenkegQfeZyiNwAJbNbGKPFXCWuBvf9Ss623VQ5DA",
  2253. "version": "3.3.0",
  2254. "origin": "shank"
  2255. },
  2256. "additionalPrograms": [
  2257. {
  2258. "kind": "programNode",
  2259. "pdas": [
  2260. {
  2261. "kind": "pdaNode",
  2262. "name": "associatedToken",
  2263. "seeds": [
  2264. {
  2265. "kind": "variablePdaSeedNode",
  2266. "name": "owner",
  2267. "docs": ["The wallet address of the associated token account."],
  2268. "type": {
  2269. "kind": "publicKeyTypeNode"
  2270. }
  2271. },
  2272. {
  2273. "kind": "variablePdaSeedNode",
  2274. "name": "tokenProgram",
  2275. "docs": ["The address of the token program to use."],
  2276. "type": {
  2277. "kind": "publicKeyTypeNode"
  2278. }
  2279. },
  2280. {
  2281. "kind": "variablePdaSeedNode",
  2282. "name": "mint",
  2283. "docs": ["The mint address of the associated token account."],
  2284. "type": {
  2285. "kind": "publicKeyTypeNode"
  2286. }
  2287. }
  2288. ]
  2289. }
  2290. ],
  2291. "accounts": [],
  2292. "instructions": [
  2293. {
  2294. "kind": "instructionNode",
  2295. "accounts": [
  2296. {
  2297. "kind": "instructionAccountNode",
  2298. "name": "payer",
  2299. "isWritable": true,
  2300. "isSigner": true,
  2301. "isOptional": false,
  2302. "docs": ["Funding account (must be a system account)."],
  2303. "defaultValue": { "kind": "payerValueNode" }
  2304. },
  2305. {
  2306. "kind": "instructionAccountNode",
  2307. "name": "ata",
  2308. "isWritable": true,
  2309. "isSigner": false,
  2310. "isOptional": false,
  2311. "docs": ["Associated token account address to be created."],
  2312. "defaultValue": {
  2313. "kind": "pdaValueNode",
  2314. "pda": {
  2315. "kind": "pdaLinkNode",
  2316. "name": "associatedToken"
  2317. },
  2318. "seeds": [
  2319. {
  2320. "kind": "pdaSeedValueNode",
  2321. "name": "owner",
  2322. "value": {
  2323. "kind": "accountValueNode",
  2324. "name": "owner"
  2325. }
  2326. },
  2327. {
  2328. "kind": "pdaSeedValueNode",
  2329. "name": "tokenProgram",
  2330. "value": {
  2331. "kind": "accountValueNode",
  2332. "name": "tokenProgram"
  2333. }
  2334. },
  2335. {
  2336. "kind": "pdaSeedValueNode",
  2337. "name": "mint",
  2338. "value": {
  2339. "kind": "accountValueNode",
  2340. "name": "mint"
  2341. }
  2342. }
  2343. ]
  2344. }
  2345. },
  2346. {
  2347. "kind": "instructionAccountNode",
  2348. "name": "owner",
  2349. "isWritable": false,
  2350. "isSigner": false,
  2351. "isOptional": false,
  2352. "docs": ["Wallet address for the new associated token account."]
  2353. },
  2354. {
  2355. "kind": "instructionAccountNode",
  2356. "name": "mint",
  2357. "isWritable": false,
  2358. "isSigner": false,
  2359. "isOptional": false,
  2360. "docs": ["The token mint for the new associated token account."]
  2361. },
  2362. {
  2363. "kind": "instructionAccountNode",
  2364. "name": "systemProgram",
  2365. "isWritable": false,
  2366. "isSigner": false,
  2367. "isOptional": false,
  2368. "docs": ["System program."],
  2369. "defaultValue": {
  2370. "kind": "publicKeyValueNode",
  2371. "publicKey": "11111111111111111111111111111111"
  2372. }
  2373. },
  2374. {
  2375. "kind": "instructionAccountNode",
  2376. "name": "tokenProgram",
  2377. "isWritable": false,
  2378. "isSigner": false,
  2379. "isOptional": false,
  2380. "docs": ["SPL Token program."],
  2381. "defaultValue": {
  2382. "kind": "publicKeyValueNode",
  2383. "publicKey": "TokenkegQfeZyiNwAJbNbGKPFXCWuBvf9Ss623VQ5DA"
  2384. }
  2385. }
  2386. ],
  2387. "arguments": [
  2388. {
  2389. "kind": "instructionArgumentNode",
  2390. "name": "discriminator",
  2391. "type": {
  2392. "kind": "numberTypeNode",
  2393. "format": "u8",
  2394. "endian": "le"
  2395. },
  2396. "docs": [],
  2397. "defaultValue": { "kind": "numberValueNode", "number": 0 },
  2398. "defaultValueStrategy": "omitted"
  2399. }
  2400. ],
  2401. "discriminators": [
  2402. {
  2403. "kind": "fieldDiscriminatorNode",
  2404. "name": "discriminator",
  2405. "offset": 0
  2406. }
  2407. ],
  2408. "name": "createAssociatedToken",
  2409. "docs": [
  2410. "Creates an associated token account for the given wallet address and",
  2411. "token mint Returns an error if the account exists."
  2412. ],
  2413. "optionalAccountStrategy": "programId"
  2414. },
  2415. {
  2416. "kind": "instructionNode",
  2417. "accounts": [
  2418. {
  2419. "kind": "instructionAccountNode",
  2420. "name": "payer",
  2421. "isWritable": true,
  2422. "isSigner": true,
  2423. "isOptional": false,
  2424. "docs": ["Funding account (must be a system account)."],
  2425. "defaultValue": { "kind": "payerValueNode" }
  2426. },
  2427. {
  2428. "kind": "instructionAccountNode",
  2429. "name": "ata",
  2430. "isWritable": true,
  2431. "isSigner": false,
  2432. "isOptional": false,
  2433. "docs": ["Associated token account address to be created."],
  2434. "defaultValue": {
  2435. "kind": "pdaValueNode",
  2436. "pda": {
  2437. "kind": "pdaLinkNode",
  2438. "name": "associatedToken"
  2439. },
  2440. "seeds": [
  2441. {
  2442. "kind": "pdaSeedValueNode",
  2443. "name": "owner",
  2444. "value": {
  2445. "kind": "accountValueNode",
  2446. "name": "owner"
  2447. }
  2448. },
  2449. {
  2450. "kind": "pdaSeedValueNode",
  2451. "name": "tokenProgram",
  2452. "value": {
  2453. "kind": "accountValueNode",
  2454. "name": "tokenProgram"
  2455. }
  2456. },
  2457. {
  2458. "kind": "pdaSeedValueNode",
  2459. "name": "mint",
  2460. "value": {
  2461. "kind": "accountValueNode",
  2462. "name": "mint"
  2463. }
  2464. }
  2465. ]
  2466. }
  2467. },
  2468. {
  2469. "kind": "instructionAccountNode",
  2470. "name": "owner",
  2471. "isWritable": false,
  2472. "isSigner": false,
  2473. "isOptional": false,
  2474. "docs": ["Wallet address for the new associated token account."]
  2475. },
  2476. {
  2477. "kind": "instructionAccountNode",
  2478. "name": "mint",
  2479. "isWritable": false,
  2480. "isSigner": false,
  2481. "isOptional": false,
  2482. "docs": ["The token mint for the new associated token account."]
  2483. },
  2484. {
  2485. "kind": "instructionAccountNode",
  2486. "name": "systemProgram",
  2487. "isWritable": false,
  2488. "isSigner": false,
  2489. "isOptional": false,
  2490. "docs": ["System program."],
  2491. "defaultValue": {
  2492. "kind": "publicKeyValueNode",
  2493. "publicKey": "11111111111111111111111111111111"
  2494. }
  2495. },
  2496. {
  2497. "kind": "instructionAccountNode",
  2498. "name": "tokenProgram",
  2499. "isWritable": false,
  2500. "isSigner": false,
  2501. "isOptional": false,
  2502. "docs": ["SPL Token program."],
  2503. "defaultValue": {
  2504. "kind": "publicKeyValueNode",
  2505. "publicKey": "TokenkegQfeZyiNwAJbNbGKPFXCWuBvf9Ss623VQ5DA"
  2506. }
  2507. }
  2508. ],
  2509. "arguments": [
  2510. {
  2511. "kind": "instructionArgumentNode",
  2512. "name": "discriminator",
  2513. "type": {
  2514. "kind": "numberTypeNode",
  2515. "format": "u8",
  2516. "endian": "le"
  2517. },
  2518. "docs": [],
  2519. "defaultValue": { "kind": "numberValueNode", "number": 1 },
  2520. "defaultValueStrategy": "omitted"
  2521. }
  2522. ],
  2523. "discriminators": [
  2524. {
  2525. "kind": "fieldDiscriminatorNode",
  2526. "name": "discriminator",
  2527. "offset": 0
  2528. }
  2529. ],
  2530. "name": "createAssociatedTokenIdempotent",
  2531. "docs": [
  2532. "Creates an associated token account for the given wallet address and",
  2533. "token mint, if it doesn't already exist. Returns an error if the",
  2534. "account exists, but with a different owner."
  2535. ],
  2536. "optionalAccountStrategy": "programId"
  2537. },
  2538. {
  2539. "kind": "instructionNode",
  2540. "accounts": [
  2541. {
  2542. "kind": "instructionAccountNode",
  2543. "name": "nestedAssociatedAccountAddress",
  2544. "isWritable": true,
  2545. "isSigner": false,
  2546. "isOptional": false,
  2547. "docs": [
  2548. "Nested associated token account, must be owned by `ownerAssociatedAccountAddress`."
  2549. ],
  2550. "defaultValue": {
  2551. "kind": "pdaValueNode",
  2552. "pda": {
  2553. "kind": "pdaLinkNode",
  2554. "name": "associatedToken"
  2555. },
  2556. "seeds": [
  2557. {
  2558. "kind": "pdaSeedValueNode",
  2559. "name": "owner",
  2560. "value": {
  2561. "kind": "accountValueNode",
  2562. "name": "ownerAssociatedAccountAddress"
  2563. }
  2564. },
  2565. {
  2566. "kind": "pdaSeedValueNode",
  2567. "name": "tokenProgram",
  2568. "value": {
  2569. "kind": "accountValueNode",
  2570. "name": "tokenProgram"
  2571. }
  2572. },
  2573. {
  2574. "kind": "pdaSeedValueNode",
  2575. "name": "mint",
  2576. "value": {
  2577. "kind": "accountValueNode",
  2578. "name": "nestedTokenMintAddress"
  2579. }
  2580. }
  2581. ]
  2582. }
  2583. },
  2584. {
  2585. "kind": "instructionAccountNode",
  2586. "name": "nestedTokenMintAddress",
  2587. "isWritable": false,
  2588. "isSigner": false,
  2589. "isOptional": false,
  2590. "docs": ["Token mint for the nested associated token account."]
  2591. },
  2592. {
  2593. "kind": "instructionAccountNode",
  2594. "name": "destinationAssociatedAccountAddress",
  2595. "isWritable": true,
  2596. "isSigner": false,
  2597. "isOptional": false,
  2598. "docs": ["Wallet's associated token account."],
  2599. "defaultValue": {
  2600. "kind": "pdaValueNode",
  2601. "pda": {
  2602. "kind": "pdaLinkNode",
  2603. "name": "associatedToken"
  2604. },
  2605. "seeds": [
  2606. {
  2607. "kind": "pdaSeedValueNode",
  2608. "name": "owner",
  2609. "value": {
  2610. "kind": "accountValueNode",
  2611. "name": "walletAddress"
  2612. }
  2613. },
  2614. {
  2615. "kind": "pdaSeedValueNode",
  2616. "name": "tokenProgram",
  2617. "value": {
  2618. "kind": "accountValueNode",
  2619. "name": "tokenProgram"
  2620. }
  2621. },
  2622. {
  2623. "kind": "pdaSeedValueNode",
  2624. "name": "mint",
  2625. "value": {
  2626. "kind": "accountValueNode",
  2627. "name": "nestedTokenMintAddress"
  2628. }
  2629. }
  2630. ]
  2631. }
  2632. },
  2633. {
  2634. "kind": "instructionAccountNode",
  2635. "name": "ownerAssociatedAccountAddress",
  2636. "isWritable": false,
  2637. "isSigner": false,
  2638. "isOptional": false,
  2639. "docs": [
  2640. "Owner associated token account address, must be owned by `walletAddress`."
  2641. ],
  2642. "defaultValue": {
  2643. "kind": "pdaValueNode",
  2644. "pda": {
  2645. "kind": "pdaLinkNode",
  2646. "name": "associatedToken"
  2647. },
  2648. "seeds": [
  2649. {
  2650. "kind": "pdaSeedValueNode",
  2651. "name": "owner",
  2652. "value": {
  2653. "kind": "accountValueNode",
  2654. "name": "walletAddress"
  2655. }
  2656. },
  2657. {
  2658. "kind": "pdaSeedValueNode",
  2659. "name": "tokenProgram",
  2660. "value": {
  2661. "kind": "accountValueNode",
  2662. "name": "tokenProgram"
  2663. }
  2664. },
  2665. {
  2666. "kind": "pdaSeedValueNode",
  2667. "name": "mint",
  2668. "value": {
  2669. "kind": "accountValueNode",
  2670. "name": "ownerTokenMintAddress"
  2671. }
  2672. }
  2673. ]
  2674. }
  2675. },
  2676. {
  2677. "kind": "instructionAccountNode",
  2678. "name": "ownerTokenMintAddress",
  2679. "isWritable": false,
  2680. "isSigner": false,
  2681. "isOptional": false,
  2682. "docs": ["Token mint for the owner associated token account."]
  2683. },
  2684. {
  2685. "kind": "instructionAccountNode",
  2686. "name": "walletAddress",
  2687. "isWritable": true,
  2688. "isSigner": true,
  2689. "isOptional": false,
  2690. "docs": ["Wallet address for the owner associated token account."]
  2691. },
  2692. {
  2693. "kind": "instructionAccountNode",
  2694. "name": "tokenProgram",
  2695. "isWritable": false,
  2696. "isSigner": false,
  2697. "isOptional": false,
  2698. "docs": ["SPL Token program."],
  2699. "defaultValue": {
  2700. "kind": "publicKeyValueNode",
  2701. "publicKey": "TokenkegQfeZyiNwAJbNbGKPFXCWuBvf9Ss623VQ5DA"
  2702. }
  2703. }
  2704. ],
  2705. "arguments": [
  2706. {
  2707. "kind": "instructionArgumentNode",
  2708. "name": "discriminator",
  2709. "type": {
  2710. "kind": "numberTypeNode",
  2711. "format": "u8",
  2712. "endian": "le"
  2713. },
  2714. "docs": [],
  2715. "defaultValue": { "kind": "numberValueNode", "number": 2 },
  2716. "defaultValueStrategy": "omitted"
  2717. }
  2718. ],
  2719. "discriminators": [
  2720. {
  2721. "kind": "fieldDiscriminatorNode",
  2722. "name": "discriminator",
  2723. "offset": 0
  2724. }
  2725. ],
  2726. "name": "recoverNestedAssociatedToken",
  2727. "docs": [
  2728. "Transfers from and closes a nested associated token account: an",
  2729. "associated token account owned by an associated token account.",
  2730. "",
  2731. "The tokens are moved from the nested associated token account to the",
  2732. "wallet's associated token account, and the nested account lamports are",
  2733. "moved to the wallet.",
  2734. "",
  2735. "Note: Nested token accounts are an anti-pattern, and almost always",
  2736. "created unintentionally, so this instruction should only be used to",
  2737. "recover from errors."
  2738. ],
  2739. "optionalAccountStrategy": "programId"
  2740. }
  2741. ],
  2742. "definedTypes": [],
  2743. "errors": [
  2744. {
  2745. "kind": "errorNode",
  2746. "name": "invalidOwner",
  2747. "code": 0,
  2748. "message": "Associated token account owner does not match address derivation",
  2749. "docs": [
  2750. "InvalidOwner: Associated token account owner does not match address derivation"
  2751. ]
  2752. }
  2753. ],
  2754. "name": "associatedToken",
  2755. "prefix": "",
  2756. "publicKey": "ATokenGPvbdGVxr1b2hvZbsiqW5xWH25efTNsLJA8knL",
  2757. "version": "1.1.1",
  2758. "origin": "shank"
  2759. }
  2760. ],
  2761. "standard": "codama",
  2762. "version": "1.0.0"
  2763. }