Published
Jul 11, 2024
2y ago
Total Downloads
1.6K
1,644
Install
dotnet add package Solana.Moonshot --version 1.0.3
| Product | Versions |
|---|---|
| .NET |
README
Solnet.Moonshot
Solnet.Moonshot is a C# client implementation of the Moonshot on-chain program.
Quick start example:
using Solnet.Rpc;
using Solnet.Wallet;
using PublicKey = Solnet.Wallet.PublicKey;
using Solnet.Moonshot;
var rpc = ClientFactory.GetClient(Cluster.MainNet);
MoonshotClient moonshotClient = new MoonshotClient(rpc);
Account botAccount = Account.FromSecretKey("SECRET_KEY_HERE");
PublicKey tokenAddress = new PublicKey("TOKEN_ADDRESS_HERE");
TradeOrder tradeOrder = new TradeOrder()
{
Amount = 8860000000000,
CollateralAmount = 5000000,
SlippageBps = 100
};
string response = await moonshotClient.SendBuyAsync(botAccount, tokenAddress, tradeOrder);
Console.WriteLine(response);
Console.ReadKey();
Changes from Previous Version
No structural changes between v1.0.2 and v1.0.3.
Adoption Assessment
Assess this package against its supported frameworks, license, maintenance signals and dependency graph before making it a project standard.
Compatibility metadata lists 1 target framework; confirm the exact target used by your application.
Related Guides & Workflows
Learn how to evaluate, integrate, or audit this package in your .NET project.