{"_id":"@arkafund/sdk","_rev":"11-3ca9a5cb75e43fce117652dcbec9b3cd","name":"@arkafund/sdk","dist-tags":{"latest":"0.4.2"},"versions":{"0.1.0":{"name":"@arkafund/sdk","version":"0.1.0","_id":"@arkafund/sdk@0.1.0","maintainers":[{"name":"arkafund-admin","email":"dogstarcoin@gmail.com"}],"dist":{"shasum":"40221c904db702bba8f3fa45e17aa587a9311a8d","tarball":"https://registry.npmjs.org/@arkafund/sdk/-/sdk-0.1.0.tgz","fileCount":28,"integrity":"sha512-5k845Lte9Fabs2SY0otXKUiLoDrqUmUfSNc7v2JgGWpy2vuXWKm8jzXfdLwLAg5eCDREViPqKADXQ4pyB5KC1Q==","signatures":[{"sig":"MEUCIQCqeOuWTZeCBuENZYJIqG2BrpK/1Kp5wDAwI6oytvgpfQIgWfCpsoOTjjEEniHSMwJojaJ+VJF3LEBkGVzKUevEbrM=","keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U"}],"unpackedSize":153553},"type":"module","types":"./dist/src/index.d.ts","engines":{"node":">=20.0.0"},"exports":{".":"./dist/src/index.js"},"gitHead":"2bfdb7574ec96c199e76311e527cb224e08ddef6","scripts":{"build":"tsc -p tsconfig.json","test:e2e":"bash ./scripts/e2e-local.sh","test:unit":"npm run build && node --test dist/tests/unit/*.test.js","regen:bindings":"bash ./scripts/generate-bindings.sh","test:integration":"bash ./scripts/integration-local.sh","test:integration:live":"npm run build && node --test dist/tests/integration/*.test.js"},"_npmUser":{"name":"arkafund-admin","email":"dogstarcoin@gmail.com"},"_npmVersion":"11.13.0","description":"Public TypeScript SDK for Arkafund on-chain integrations","directories":{},"_nodeVersion":"24.17.0","dependencies":{"buffer":"6.0.3","@stellar/stellar-sdk":"^14.1.1"},"_hasShrinkwrap":false,"devDependencies":{"typescript":"^5.9.2","@types/node":"^24.3.0"},"_npmOperationalInternal":{"tmp":"tmp/sdk_0.1.0_1783702159876_0.4669648377767872","host":"s3://npm-registry-packages-npm-production"}},"0.1.1":{"name":"@arkafund/sdk","version":"0.1.1","_id":"@arkafund/sdk@0.1.1","maintainers":[{"name":"arkafund-admin","email":"dogstarcoin@gmail.com"}],"dist":{"shasum":"a586d9eb632eaa052c3b59032aac0854b432640e","tarball":"https://registry.npmjs.org/@arkafund/sdk/-/sdk-0.1.1.tgz","fileCount":28,"integrity":"sha512-MwctqFud0Cqki63+Bdo/Lj6TcczJWV/FqO34V7ll7zm+C5p7AKKqLXLHXDKOIybyWu45T9HAf/0X3OpKWtvwVA==","signatures":[{"sig":"MEYCIQCi2FYyDQTd3aJ6qTDneFTSyTTHGOHJpSZaVODmQvQCfAIhAIixnSHr1b1hwqVmzG5wfB7FaIfRB78VThp4ESai5o+3","keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U"}],"unpackedSize":153553},"type":"module","types":"./dist/src/index.d.ts","engines":{"node":">=22.0.0"},"exports":{".":"./dist/src/index.js"},"scripts":{"build":"tsc -p tsconfig.json","test:e2e":"bash ./scripts/e2e-local.sh","test:unit":"npm run build && node --test dist/tests/unit/*.test.js","regen:bindings":"bash ./scripts/generate-bindings.sh","test:integration":"bash ./scripts/integration-local.sh","test:integration:live":"npm run build && node --test dist/tests/integration/*.test.js"},"_npmUser":{"name":"arkafund-admin","email":"dogstarcoin@gmail.com"},"_npmVersion":"11.13.0","description":"Public TypeScript SDK for Arkafund on-chain integrations","directories":{},"_nodeVersion":"24.17.0","dependencies":{"buffer":"6.0.3","@stellar/stellar-sdk":"^16.0.1"},"_hasShrinkwrap":false,"devDependencies":{"typescript":"^5.9.2","@types/node":"^24.3.0"},"_npmOperationalInternal":{"tmp":"tmp/sdk_0.1.1_1783702867847_0.2659303321628774","host":"s3://npm-registry-packages-npm-production"}},"0.2.1":{"name":"@arkafund/sdk","version":"0.2.1","_id":"@arkafund/sdk@0.2.1","maintainers":[{"name":"arkafund-admin","email":"dogstarcoin@gmail.com"}],"dist":{"shasum":"67ca4715becc0fb217de6714bbc76d743f24d60b","tarball":"https://registry.npmjs.org/@arkafund/sdk/-/sdk-0.2.1.tgz","fileCount":42,"integrity":"sha512-YP6xpaHGssBeic/Y1JegYEKX+r2lkBnJa+2XMGQ2ULPzR1unJlYGsWYFRofN5wq4UtDFES7tCyaVSc1CJamMdw==","signatures":[{"sig":"MEYCIQCcgkr2YzGl3HK0mSND9yN6YyexBedFI0ideqBZxs4ihwIhAMN57+9kE6ItPS9INN1B1xW6u2vx8jA+x/X9W6xgXCWq","keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U"}],"unpackedSize":253674},"type":"module","types":"./dist/src/index.d.ts","engines":{"node":">=22.0.0"},"exports":{".":"./dist/src/index.js"},"scripts":{"build":"tsc -p tsconfig.json","test:e2e":"bash ./scripts/e2e-local.sh","test:unit":"npm run build && node --test dist/tests/unit/*.test.js","regen:bindings":"bash ./scripts/generate-bindings.sh","test:integration":"bash ./scripts/integration-local.sh","test:integration:live":"npm run build && node --test dist/tests/integration/*.test.js","verify:mainnet-preset":"node ./scripts/verify-mainnet-preset.mjs"},"_npmUser":{"name":"arkafund-admin","email":"dogstarcoin@gmail.com"},"_npmVersion":"11.13.0","description":"Public TypeScript SDK for Arkafund on-chain integrations","directories":{},"_nodeVersion":"24.17.0","dependencies":{"buffer":"6.0.3","@stellar/stellar-sdk":"^16.0.1"},"_hasShrinkwrap":false,"devDependencies":{"typescript":"^5.9.2","@types/node":"^24.3.0"},"_npmOperationalInternal":{"tmp":"tmp/sdk_0.2.1_1783933625106_0.6572284564539499","host":"s3://npm-registry-packages-npm-production"}},"0.2.2":{"name":"@arkafund/sdk","version":"0.2.2","_id":"@arkafund/sdk@0.2.2","maintainers":[{"name":"arkafund-admin","email":"dogstarcoin@gmail.com"}],"dist":{"shasum":"5dbee2ff11d72488737fb819c251edd08c9b19d0","tarball":"https://registry.npmjs.org/@arkafund/sdk/-/sdk-0.2.2.tgz","fileCount":49,"integrity":"sha512-V/5FLIZWdvyHuI59yrrwYO+95LZ+AsgDcJlztv4d72o7B8oY6rQzcNeXqFqCsJCl2FXkBzWWv5ccl1QexdwIdQ==","signatures":[{"sig":"MEUCIQDo13bG+av7+a6br3JOXzPSFsvJtMEJiylCFgN6aDbRKwIgFTR7qxVZ3wrTjtY3nr9C1W+DV1AofnLei7Z1Vn6xjJQ=","keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U"}],"unpackedSize":269804},"type":"module","types":"./dist/src/index.d.ts","engines":{"node":">=22.0.0"},"exports":{".":"./dist/src/index.js"},"gitHead":"2bfdb7574ec96c199e76311e527cb224e08ddef6","scripts":{"build":"tsc -p tsconfig.json","docs:api":"typedoc --options typedoc.json","test:e2e":"bash ./scripts/e2e-local.sh","test:unit":"npm run build && node --test dist/tests/unit/*.test.js","test:consumer":"bash ./scripts/test-consumer.sh","regen:bindings":"bash ./scripts/generate-bindings.sh","example:mainnet":"node ./examples/mainnet-read.mjs","test:integration":"bash ./scripts/integration-local.sh","test:integration:live":"npm run build && node --test dist/tests/integration/*.test.js","verify:mainnet-preset":"node ./scripts/verify-mainnet-preset.mjs"},"_npmUser":{"name":"arkafund-admin","email":"dogstarcoin@gmail.com"},"_npmVersion":"11.13.0","description":"Public TypeScript SDK for Arkafund on-chain integrations","directories":{},"_nodeVersion":"24.17.0","dependencies":{"buffer":"6.0.3","@stellar/stellar-sdk":"^16.0.1"},"_hasShrinkwrap":false,"devDependencies":{"typedoc":"^0.28.20","typescript":"^5.9.2","@types/node":"^24.3.0"},"_npmOperationalInternal":{"tmp":"tmp/sdk_0.2.2_1784395973265_0.8711962037369374","host":"s3://npm-registry-packages-npm-production"}},"0.3.0":{"name":"@arkafund/sdk","version":"0.3.0","_id":"@arkafund/sdk@0.3.0","maintainers":[{"name":"arkafund-admin","email":"dogstarcoin@gmail.com"}],"dist":{"shasum":"70cdb2d2b2aa659e7de72b056da7390ec986708a","tarball":"https://registry.npmjs.org/@arkafund/sdk/-/sdk-0.3.0.tgz","fileCount":51,"integrity":"sha512-o2ynx1l+mVk6xbg/Z2VecyVeYxo0ZusQHeGPJ+Fbc5h+dlMaUJvQD7mYY3MISfshon1xgBBjvvdYepuqa332Tg==","signatures":[{"sig":"MEYCIQCiUvhN0eQYN8X8M722mtQLGPiFE8rCHxxIVBIHuqyP7QIhAOdJJ0Doxv6yQAiWXyG6IfDEWmUK3fsGN5YNpdrch7Op","keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U"}],"unpackedSize":286584},"type":"module","types":"./dist/src/index.d.ts","engines":{"node":">=22.0.0"},"exports":{".":"./dist/src/index.js"},"gitHead":"763283346194e5ff07c8f7cc2fb4ce9fe9f0e96f","scripts":{"build":"tsc -p tsconfig.json","docs:api":"typedoc --options typedoc.json","test:e2e":"bash ./scripts/e2e-local.sh","test:unit":"npm run build && node --test dist/tests/unit/*.test.js","test:consumer":"bash ./scripts/test-consumer.sh","regen:bindings":"bash ./scripts/generate-bindings.sh","example:mainnet":"node ./examples/mainnet-read.mjs","test:integration":"bash ./scripts/integration-local.sh","test:integration:live":"npm run build && node --test dist/tests/integration/*.test.js","verify:mainnet-preset":"node ./scripts/verify-mainnet-preset.mjs"},"_npmUser":{"name":"arkafund-admin","email":"dogstarcoin@gmail.com"},"_npmVersion":"11.13.0","description":"Public TypeScript SDK for Arkafund on-chain integrations","directories":{},"_nodeVersion":"24.14.0","dependencies":{"buffer":"6.0.3","@stellar/stellar-sdk":"^16.0.1"},"_hasShrinkwrap":false,"devDependencies":{"typedoc":"^0.28.20","typescript":"^5.9.2","@types/node":"^24.3.0"},"_npmOperationalInternal":{"tmp":"tmp/sdk_0.3.0_1784460937256_0.9179870937890164","host":"s3://npm-registry-packages-npm-production"}},"0.3.1":{"name":"@arkafund/sdk","version":"0.3.1","_id":"@arkafund/sdk@0.3.1","maintainers":[{"name":"arkafund-admin","email":"dogstarcoin@gmail.com"}],"dist":{"shasum":"8b3fc05e5d0e1647e7b3a305de9d79fcae3c0376","tarball":"https://registry.npmjs.org/@arkafund/sdk/-/sdk-0.3.1.tgz","fileCount":52,"integrity":"sha512-pRHY2OYMHML09lT23avCSxyl7f+t2Hdj+OX5f4lcoQqW7ccTaRhND4JFFH4R4FZxnWyZHMV4Bq6jzWdO48/hQQ==","signatures":[{"sig":"MEUCIQCr+JRPdejo0a8ntvv3nKQaI6LQbVZKw5CLExpRwldHNAIgKxtVK0obeGW1apchVpsIYFK9woJfoIOhK/3HsnEpiu4=","keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U"}],"unpackedSize":288791},"type":"module","types":"./dist/src/index.d.ts","engines":{"node":">=22.0.0"},"exports":{".":"./dist/src/index.js"},"gitHead":"763283346194e5ff07c8f7cc2fb4ce9fe9f0e96f","scripts":{"build":"tsc -p tsconfig.json","docs:api":"typedoc --options typedoc.json","test:e2e":"bash ./scripts/e2e-local.sh","test:unit":"npm run build && node --test dist/tests/unit/*.test.js","test:consumer":"bash ./scripts/test-consumer.sh","test:examples":"npm run build && tsc -p tsconfig.examples.json","regen:bindings":"bash ./scripts/generate-bindings.sh","example:mainnet":"node ./examples/mainnet-read.mjs","test:integration":"bash ./scripts/integration-local.sh","test:integration:live":"npm run build && node --test dist/tests/integration/*.test.js","verify:mainnet-preset":"node ./scripts/verify-mainnet-preset.mjs"},"_npmUser":{"name":"arkafund-admin","email":"dogstarcoin@gmail.com"},"_npmVersion":"11.13.0","description":"Public TypeScript SDK for Arkafund on-chain integrations","directories":{},"_nodeVersion":"24.17.0","dependencies":{"buffer":"6.0.3","@stellar/stellar-sdk":"^16.0.1"},"_hasShrinkwrap":false,"devDependencies":{"typedoc":"^0.28.20","typescript":"^5.9.2","@types/node":"^24.3.0"},"_npmOperationalInternal":{"tmp":"tmp/sdk_0.3.1_1784466708088_0.10406689722076701","host":"s3://npm-registry-packages-npm-production"}},"0.4.0":{"name":"@arkafund/sdk","version":"0.4.0","_id":"@arkafund/sdk@0.4.0","maintainers":[{"name":"arkafund-admin","email":"dogstarcoin@gmail.com"}],"dist":{"shasum":"98f5af209b77334cd8b5961594ae5885338675b9","tarball":"https://registry.npmjs.org/@arkafund/sdk/-/sdk-0.4.0.tgz","fileCount":63,"integrity":"sha512-FqDraP1SlWe7KqqR0bPFK3E0s+RjbvXtXrknLh7oTh8EZGltcjJhhic/qxRTF5DcQjXNKszFbhQdAOwGd6v6XA==","signatures":[{"sig":"MEUCIBgWYCbCMATFmU3BarUFto/dqyWwv6U1rqXqxGNHlVeHAiEA0qjdXz7XH82uVHJeRvuYE+MQzb5AepW3RPU4IgZ9+Uc=","keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U"}],"unpackedSize":336768},"type":"module","types":"./dist/src/index.d.ts","engines":{"node":">=22.0.0"},"exports":{".":"./dist/src/index.js"},"gitHead":"04dd355831130b00df95c1d9a332d0c2d0fd820c","scripts":{"build":"tsc -p tsconfig.json","docs:api":"typedoc --options typedoc.json","test:e2e":"bash ./scripts/e2e-local.sh","test:unit":"npm run build && node --test dist/tests/unit/*.test.js","test:consumer":"bash ./scripts/test-consumer.sh","test:examples":"npm run build && tsc -p tsconfig.examples.json","regen:bindings":"bash ./scripts/generate-bindings.sh","example:mainnet":"node ./examples/mainnet-read.mjs","test:integration":"bash ./scripts/integration-local.sh","test:integration:live":"npm run build && node --test dist/tests/integration/*.test.js","verify:mainnet-preset":"node ./scripts/verify-mainnet-preset.mjs"},"_npmUser":{"name":"arkafund-admin","email":"dogstarcoin@gmail.com"},"_npmVersion":"11.13.0","description":"Public TypeScript SDK for Arkafund on-chain integrations","directories":{},"_nodeVersion":"24.17.0","dependencies":{"buffer":"6.0.3","@stellar/stellar-sdk":"^16.0.1"},"_hasShrinkwrap":false,"devDependencies":{"typedoc":"^0.28.20","typescript":"^5.9.2","@types/node":"^24.3.0"},"_npmOperationalInternal":{"tmp":"tmp/sdk_0.4.0_1784483070036_0.7078344081592496","host":"s3://npm-registry-packages-npm-production"}},"0.4.1":{"name":"@arkafund/sdk","version":"0.4.1","_id":"@arkafund/sdk@0.4.1","maintainers":[{"name":"arkafund-admin","email":"dogstarcoin@gmail.com"}],"dist":{"shasum":"a796373cb81358756e0368b812d3a239b2dd6ad6","tarball":"https://registry.npmjs.org/@arkafund/sdk/-/sdk-0.4.1.tgz","fileCount":64,"integrity":"sha512-Hw8eTWf8A7ss5ULYEZfhll6U8TwMGvcAldV/NdQKGgUDsvuC3lAprLj86vAbfE2YnS8rz8PMX6pgRp9SPP9ZLg==","signatures":[{"sig":"MEYCIQD/0ueEEwRknpTilKBcp+1dfffJ3HRAPilsYWvz9pLJ9wIhALN4wHwUYczEM/8lBP76u345tyC0sUhLrnk7r8uUEgvu","keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U"}],"unpackedSize":342318},"type":"module","types":"./dist/src/index.d.ts","engines":{"node":">=22.0.0"},"exports":{".":"./dist/src/index.js"},"gitHead":"42efd92a24da2a59839fda23a437834a8f07321d","scripts":{"build":"tsc -p tsconfig.json","docs:api":"typedoc --options typedoc.json","test:e2e":"bash ./scripts/e2e-local.sh","test:unit":"npm run build && node --test dist/tests/unit/*.test.js","test:consumer":"bash ./scripts/test-consumer.sh","test:examples":"npm run build && tsc -p tsconfig.examples.json","regen:bindings":"bash ./scripts/generate-bindings.sh","example:mainnet":"node ./examples/mainnet-read.mjs","test:integration":"bash ./scripts/integration-local.sh","test:integration:live":"npm run build && node --test dist/tests/integration/*.test.js","verify:mainnet-preset":"node ./scripts/verify-mainnet-preset.mjs","example:mainnet:wallet":"node ./examples/mainnet-wallet-canary.mjs"},"_npmUser":{"name":"arkafund-admin","email":"dogstarcoin@gmail.com"},"_npmVersion":"11.13.0","description":"Public TypeScript SDK for Arkafund on-chain integrations","directories":{},"_nodeVersion":"24.17.0","dependencies":{"buffer":"6.0.3","@stellar/stellar-sdk":"^16.0.1"},"_hasShrinkwrap":false,"devDependencies":{"typedoc":"^0.28.20","typescript":"^5.9.2","@types/node":"^24.3.0"},"_npmOperationalInternal":{"tmp":"tmp/sdk_0.4.1_1784543898822_0.2759910658854243","host":"s3://npm-registry-packages-npm-production"}},"0.4.2":{"name":"@arkafund/sdk","version":"0.4.2","description":"Public TypeScript SDK for Arkafund on-chain integrations","type":"module","exports":{".":"./dist/src/index.js"},"types":"./dist/src/index.d.ts","engines":{"node":">=22.0.0"},"scripts":{"build":"tsc -p tsconfig.json","regen:bindings":"bash ./scripts/generate-bindings.sh","verify:mainnet-preset":"node ./scripts/verify-mainnet-preset.mjs","docs:api":"typedoc --options typedoc.json","example:mainnet":"node ./examples/mainnet-read.mjs","example:mainnet:wallet":"node ./examples/mainnet-wallet-canary.mjs","test:consumer":"bash ./scripts/test-consumer.sh","test:examples":"npm run build && tsc -p tsconfig.examples.json","test:unit":"npm run build && node --test dist/tests/unit/*.test.js","test:integration":"bash ./scripts/integration-local.sh","test:integration:live":"npm run build && node --test dist/tests/integration/*.test.js","test:e2e":"bash ./scripts/e2e-local.sh"},"dependencies":{"@stellar/stellar-sdk":"^16.0.1","buffer":"6.0.3"},"devDependencies":{"@types/node":"^24.3.0","typedoc":"^0.28.20","typescript":"^5.9.2"},"gitHead":"0bcd8ec88192cce2f348982445c3dc7d271bb0a3","_id":"@arkafund/sdk@0.4.2","_nodeVersion":"24.17.0","_npmVersion":"11.13.0","dist":{"integrity":"sha512-FnXxKaO91Al1Z0OHVOjH5toS8845dUtrVkFExi8z8CmJfXbsFSh/t0C1EeOmJqIPEWOlXL8uUaKT/g/xWnMLYA==","shasum":"13a75d7cf903f0405a0a9536bb65fe38dd31f7b4","tarball":"https://registry.npmjs.org/@arkafund/sdk/-/sdk-0.4.2.tgz","fileCount":64,"unpackedSize":343491,"signatures":[{"keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U","sig":"MEYCIQCsQ3XsI2c9iyR9K4QzD28yljPoc2zpxHEzjDvwrJ88iwIhAJRL8fbhM3RbuL3adCVFQKMCon7UZPD6K1kvcCIsd3s+"}]},"_npmUser":{"name":"arkafund-admin","email":"dogstarcoin@gmail.com"},"directories":{},"maintainers":[{"name":"arkafund-admin","email":"dogstarcoin@gmail.com"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages-npm-production","tmp":"tmp/sdk_0.4.2_1784979458395_0.13838967347995657"},"_hasShrinkwrap":false}},"time":{"created":"2026-07-10T16:49:19.725Z","modified":"2026-07-25T11:37:38.704Z","0.1.0":"2026-07-10T16:49:20.046Z","0.1.1":"2026-07-10T17:01:08.003Z","0.2.0":"2026-07-10T17:49:15.587Z","0.2.1":"2026-07-13T09:07:05.235Z","0.2.2":"2026-07-18T17:32:53.420Z","0.3.0":"2026-07-19T11:35:37.379Z","0.3.1":"2026-07-19T13:11:48.254Z","0.4.0":"2026-07-19T17:44:30.161Z","0.4.1":"2026-07-20T10:38:18.937Z","0.4.2":"2026-07-25T11:37:38.559Z"},"description":"Public TypeScript SDK for Arkafund on-chain integrations","maintainers":[{"name":"arkafund-admin","email":"dogstarcoin@gmail.com"}],"readme":"# Arkafund TypeScript SDK\n\nPublic TypeScript SDK for reading the Arka catalog and building wallet-signed\nStellar contract interactions. The package combines:\n\n- a typed client for the public indexer and NAV API\n- Stellar mainnet network and contract presets\n- factory, vault, registry, router, venue-registry and oracle-guard modules\n- a high-level workflow for creation, deposits, redemptions, routing and credit actions\n- exact amount and percentage formatting helpers\n- transaction builders that preserve wallet custody and on-chain authorization\n\n## Requirements\n\n- Node.js 22 or newer\n- a supported Stellar wallet or signer for state-changing actions\n- no API key for public catalog and contract reads\n\n## Install\n\n```bash\nnpm install @arkafund/sdk\n```\n\n## Read mainnet data\n\nThe public catalog is read-only. Values such as NAV and balances are exact\ninteger strings so consumers do not lose on-chain precision.\n\n```ts\nimport {\n  CatalogClient,\n  formatAssetAmount,\n  formatBasisPoints,\n} from \"@arkafund/sdk\";\n\nconst catalog = new CatalogClient();\nconst health = await catalog.health();\nconst nav = await catalog.nav();\nconst arkAs = await catalog.arkas({\n  curated: true,\n  delisted: false,\n  limit: 20,\n});\n\nfor (const arka of arkAs.items) {\n  console.log({\n    contractId: arka.arkaId,\n    name: arka.identity?.displayName ?? arka.arkaId,\n    nav: formatAssetAmount(arka.nav, 7),\n    managementFee: formatBasisPoints(arka.fees.mgmtBps),\n  });\n}\n\nconsole.log({\n  healthy: health.healthy,\n  indexedArkas: health.indexedArkas,\n  failedArkas: health.failedArkas,\n  totalNav: nav.totalNav,\n});\n```\n\nPublic API reference: <https://arka.fund/docs/api-reference.html>\n\n## Verify catalog data on-chain\n\nThe SDK can read the same Arka directly from its Soroban contract. This example\ncompares the indexed manager and NAV with the contract values.\n\n```ts\nimport {\n  ArkafundSdk,\n  CatalogClient,\n  createMainnetConfig,\n} from \"@arkafund/sdk\";\n\nconst catalog = new CatalogClient();\nconst sdk = new ArkafundSdk(createMainnetConfig());\nconst curated = await catalog.arkas({ curated: true, delisted: false, limit: 1 });\nconst indexed = curated.items[0];\n\nconst vault = sdk.vault(indexed.arkaId);\nconst [manager, nav, fees, whitelist] = await Promise.all([\n  vault.manager(),\n  vault.nav(),\n  vault.fees(),\n  vault.whitelist(),\n]);\n\nconsole.log({\n  managerMatches: manager === indexed.manager,\n  navMatches: nav.toString() === indexed.nav,\n  fees,\n  whitelist,\n});\n```\n\nThe package includes a complete executable version at\n`examples/mainnet-read.mjs`.\n\n## Wallet signing\n\nReads do not require a wallet. Deposits, redemptions, Arka creation, routing and\ngovernance actions require a public key and a wallet-backed `signTransaction`\ncallback.\n\n```ts\nimport {\n  ArkafundSdk,\n  STELLAR_MAINNET_PASSPHRASE,\n  createMainnetConfig,\n} from \"@arkafund/sdk\";\n\nconst signedSdk = new ArkafundSdk(createMainnetConfig({\n  publicKey: walletAddress,\n  signTransaction: async (xdr) => {\n    const signed = await wallet.signTransaction(xdr, {\n      networkPassphrase: STELLAR_MAINNET_PASSPHRASE,\n    });\n    return { signedTxXdr: signed.signedTxXdr };\n  },\n}));\n```\n\nThe wallet remains the transaction signer. The SDK does not include private\nkeys, signing authority or a custody layer.\n\n## Deposit and redeem\n\nConvert user-entered decimal amounts with the asset's declared decimals. This\nkeeps product interfaces human-readable while preserving exact on-chain values.\n\n```ts\nconst workflow = signedSdk.workflow();\nconst { approval, deposit } = await workflow.depositWithApproval({\n  arkaId: arkaContractId,\n  account: walletAddress,\n  assetContract: usdcContractId,\n  amount: \"25.50\",\n}, approvalExpirationLedger);\n\nconsole.log(approval?.hash, deposit.hash);\n\nconst redemption = await workflow.redeem({\n  arkaId: arkaContractId,\n  account: walletAddress,\n  shares: \"10\",\n});\n\nconsole.log(redemption.hash);\n```\n\n## Rebalance an Arka\n\nManagers can ask Arka's routing service for the best admitted route and then build\nthe corresponding vault transaction. `AUTO` compares the supported venues; an\nexplicit protocol can be requested when the product needs direct execution.\n\n```ts\nconst plan = await workflow.planRebalance({\n  protocol: \"AUTO\",\n  amount: \"10\",\n  tokenIn: usdcContractId,\n  tokenOut: xlmContractId,\n  slippagePercent: 0.5,\n  readerPubKey: walletAddress,\n  vaultNav: \"1000\",\n  dailyTurnoverUsed: \"0\",\n  projectedAllocationShiftPercent: \"1\",\n});\n\nconst result = await workflow.rebalance(arkaContractId, walletAddress, plan);\n\nconsole.log(result.hash);\n```\n\nThe route must also satisfy the Arka whitelist, allowed-venue configuration and\non-chain swap-risk policy. The SDK cannot bypass those controls.\nThe allocation-shift percentage must come from a common valuation basis such as\nCatalog's verified USD prices; raw units from different assets are never compared.\n\n## Blend credit actions\n\nThe vault module exposes explicit supply, withdraw, borrow and repay builders.\nThe manager signs the transaction and the Arka contract applies the configured\nmarket and risk policy.\n\n```ts\nawait vault.blendLend({\n  manager: walletAddress,\n  adapter: ARKAFUND_MAINNET_CONTRACTS.adapterBlendFixedXlmUsdc,\n  marketId: 1,\n  asset: usdcContractId,\n  amount: parseAssetAmount(\"50\", 7),\n});\n\nawait vault.creditRepay({\n  manager: walletAddress,\n  protocol: { tag: \"Blend\", values: undefined },\n  marketId: 1,\n  asset: usdcContractId,\n  amount: parseAssetAmount(\"5\", 7),\n});\n```\n\nEquivalent methods are available for `blendWithdraw`, `blendBorrow`,\n`blendRepay`, `creditSupply`, `creditWithdraw` and `creditBorrow`. Every action\nalso has a `build...` variant for applications that manage submission separately.\n\nThe complete wallet integration example is compiled in CI and ships with the\npackage at `examples/wallet-integration.ts`.\n\nThe reversible Mainnet canary at `examples/mainnet-wallet-canary.mjs` exercises\nthe same workflow with environment-provided signing. It approves the selected\nvault, deposits a human-readable amount and redeems the newly minted shares.\n\n## Public Arka and manager profiles\n\nProfile updates are signed by the manager wallet using Stellar SEP-53. Build the\ncanonical message, ask a SEP-53-compatible wallet to sign the message, then send\nthe signed request to the Catalog API.\n\n```ts\nconst payload = {\n  displayName: \"Stellar Growth\",\n  description: \"A diversified Stellar asset strategy.\", // concise summary for lists\n  strategy: \"Diversified liquid exposure.\\n\\nRebalanced within the stated mandate.\",\n  riskDisclosure: \"Market, liquidity and smart-contract risks apply.\",\n  targetReturn: \"Long-term objective; not a guarantee.\",\n  nonce: crypto.randomUUID(),\n  issuedAt: new Date().toISOString(),\n};\nconst message = buildCatalogIdentityUpdateMessage({\n  scope: \"arka\",\n  target: arkaContractId,\n  signer: walletAddress,\n  payload,\n});\nconst signature = await wallet.signMessage(message);\n\nawait catalog.updateArkaIdentity(arkaContractId, {\n  signer: walletAddress,\n  message,\n  signature,\n  payload,\n});\n```\n\nPass the base64, base64url or hexadecimal signature string returned by the\nwallet. Freighter and Stellar Wallets Kit use the required SEP-53 format.\n\n## Create an Arka\n\nThe workflow reads the current creation fee, verifies the wallet balance, reuses\nan adequate allowance or requests approval, and then calls the canonical factory.\nCreation, registration, venue policy and risk policy remain enforced on-chain.\n\n```ts\nconst created = await workflow.createArkaWithFeeApproval({\n  denomination: usdcContractId,\n  managementFeePercent: \"1\",\n  performanceFeePercent: \"15\",\n  depositFeePercent: \"0\",\n  redemptionFeePercent: \"0\",\n  whitelist: [usdcContractId, xlmContractId],\n}, approvalExpirationLedger);\n\nconsole.log(created.approval?.hash, created.creation.hash);\n```\n\nProduct inputs use percentages. The SDK converts them exactly to the contract\nrepresentation and rejects values with more than two decimal places.\n\n## Prices and NAV\n\n`CatalogClient.nav()` returns the aggregate indexed NAV. `CatalogClient.prices()`\nreturns the OracleGuard state used for USD valuation. USDC uses declared USD\nparity; other assets require a verified on-chain price. Stale, invalid, paused or\nmissing feeds return `priceUsd: null` with an explicit status. The SDK does not\nsubstitute a guessed price.\n\n```ts\nconst [nav, prices] = await Promise.all([\n  workflow.catalog.nav(),\n  workflow.catalog.prices(),\n]);\n\nfor (const price of prices.items) {\n  console.log(price.assetContract, price.priceUsd, price.oracleStatus);\n}\n```\n\nThe Catalog API is the canonical indexed data service. Its `/v1/nav` route is the\nNAV aggregate. The DApp's `/api/nav` route is a cache-aware proxy of that same\nresponse for browser clients; it is not a second indexer or valuation source.\n\n## Execute a routed swap\n\nThe router executes a route selected by an application or quote engine. Every\nhop requires an explicit minimum output; the SDK rejects empty routes and a\nzero first-hop input before any network request.\n\n```ts\nconst router = signedSdk.router(ARKAFUND_MAINNET_CONTRACTS.router);\nconst result = await router.execute({\n  caller: walletAddress,\n  steps: [\n    {\n      adapter: ARKAFUND_MAINNET_CONTRACTS.adapterPhoenix,\n      poolId: 0,\n      amountIn: 10_0000000n,\n      minOut: 9_9000000n,\n      assetOut: xlmContractId,\n    },\n  ],\n});\n\nconsole.log(result.hash);\n```\n\n## Venue safety controls\n\nVenue status is public. Status changes require the configured governor or, for\nemergency disabling, the authorized guardian. The SDK constructs the signed\ntransaction but cannot bypass those contract controls.\n\n```ts\nimport { VenueStatus } from \"@arkafund/sdk\";\n\nconst registry = signedSdk.venueRegistry(ARKAFUND_MAINNET_CONTRACTS.venueRegistry);\nconst phoenix = ARKAFUND_MAINNET_CONTRACTS.adapterPhoenix;\n\nconsole.log(await registry.configFor(phoenix));\nconsole.log(await registry.isAutoAllowed(phoenix));\n\nawait registry.setStatus(governorAddress, phoenix, VenueStatus.ManualOnly);\n```\n\n## Error handling\n\nCatalog requests reject with `CatalogApiError`, including the HTTP status, path\nand decoded response body. Contract methods reject simulation failures before a\ntransaction is submitted; submitted methods return the transaction hash,\nsimulation result and Stellar send/get responses.\n\n```ts\nimport { CatalogApiError } from \"@arkafund/sdk\";\n\ntry {\n  await catalog.arka(unknownContractId);\n} catch (error) {\n  if (error instanceof CatalogApiError) {\n    console.error(error.status, error.path, error.body);\n  }\n}\n```\n\n## Modules\n\n- `catalog`: health, NAV, Arkas, assets, managers, profiles, activity and monitoring\n- `registry(contractId)`: registration, curation, delisting and discovery reads\n- `factory(contractId)`: creation, pagination, creation fee and default policies\n- `vault(contractId)`: NAV, deposits, redemptions, rebalance and credit operations\n- `router(contractId)`: signed route execution with mandatory minimum outputs\n- `venueRegistry(contractId)`: venue configuration and governed status changes\n- `oracleGuard(contractId)`: price-policy configuration and guarded price reads\n- `workflow()`: human-readable creation, deposit, redemption, routing and credit actions\n\n## Validation\n\nMaintainers validate the release with:\n\n```bash\nnpm run test:unit\nnpm run test:consumer\nnpm run example:mainnet\n```\n\n`test:consumer` packs the SDK, installs the tarball into an empty npm project and\nverifies that its public exports work without relying on repository-local files.\n","readmeFilename":"README.md"}