🚀 Over 20K Worken holders!
Read more about Worken Token.
- CreateTransactionToAssociatedAccount [POST]
- SimulateTransactionToAssociatedAccount [POST]
- CreateTransactionWithBurnToAssociatedAccount [POST]
- SimulateTransactionWithBurnToAssociatedAccount [POST]
- Burn [POST]
- SimulateBurn [POST]
- CreateWallet [POST]
- CreateWalletWordCount [POST]
- CreateWalletWordList [POST]
- CreateWalletFull [POST]
this endpoint send created transaction based on given body and send it to network for processing while returning Hash of such transaction
public class CreateTransactionRequest
{
public string fromAccountPublicKey { get; set; }
public string fromAccountPrivateKey { get; set; }
public string toAccountPublicKey { get; set; }
public ulong lanPorts { get; set; }
public string Memo { get; set; } = string.Empty;
public ulong SolAmount { get; set; } = 0;
}
string
Transaction hash
this endpoint simulate transaction without sending it to network while returning result of complited transaction. This endpoint execute transaction exacly same as CreateTransactionToAssociatedAccount
so this endpoint can be use for testing implementation
public class CreateTransactionRequest
{
public string fromAccountPublicKey { get; set; }
public string fromAccountPrivateKey { get; set; }
public string toAccountPublicKey { get; set; }
public ulong lanPorts { get; set; }
public string Memo { get; set; } = string.Empty;
public ulong SolAmount { get; set; } = 0;
}
public class SimulationLogs
{
public AccountInfo[] Accounts { get; set; }
[JsonPropertyName("err")]
public TransactionError Error { get; set; }
public string[] Logs { get; set; }
}
this endpoint send created transaction based on given body and send it to network for processing while returning Hash of such transaction
public class CreateTransactionBurnRequest
{
public string fromAccountPublicKey { get; set; }
public string fromAccountPrivateKey { get; set; }
public string toAccountPublicKey { get; set; }
public ulong lanPorts { get; set; }
public ulong LamPortsBurn { get; set; }
public string Memo { get; set; } = string.Empty;
public ulong SolAmount { get; set; } = 0;
}
string
Transaction hash
this endpoint simulate transaction without sending it to network while returning result of complited transaction. This endpoint execute transaction exacly same as CreateTransactionToAssociatedAccount
so this endpoint can be use for testing implementation
public class CreateTransactionRequest
{
public string fromAccountPublicKey { get; set; }
public string fromAccountPrivateKey { get; set; }
public string toAccountPublicKey { get; set; }
public ulong lanPorts { get; set; }
public ulong LamPortsBurn { get; set; }
public string Memo { get; set; } = string.Empty;
public ulong SolAmount { get; set; } = 0;
}
public class SimulationLogs
{
public AccountInfo[] Accounts { get; set; }
[JsonPropertyName("err")]
public TransactionError Error { get; set; }
public string[] Logs { get; set; }
}
```## Burn
#### **[POST]** /api/Transactions/Burn
this endpoint send created transaction with only burn instruction
#### Body structure
```c#
public class CreateBurnRequest
{
public string FromAccountPublicKey { get; set; }
public string FromAccountPrivateKey { get; set; }
public ulong Amount { get; set; }
public string Memo { get; set; } = string.Empty;
}
string
Transaction hash ## SimulateBurn
this endpoint send created transaction with only burn instruction but only simulate transaction without sending to network
public class CreateBurnRequest
{
public string FromAccountPublicKey { get; set; }
public string FromAccountPrivateKey { get; set; }
public ulong Amount { get; set; }
public string Memo { get; set; } = string.Empty;
}
public class SimulationLogs
{
public AccountInfo[] Accounts { get; set; }
[JsonPropertyName("err")]
public TransactionError Error { get; set; }
public string[] Logs { get; set; }
}
create base wallet with default values for wordCount and wordList as given
WordCount.Twelve
and WordList.English
empty
{
"account": {
"privateKey": {
"key": "45oED964ffnj1Br6tDbwcLNdi8JaZqHciVdWeaJhLVwB4JWZ3SRWE7LtZn4Zh4ntqjrDD7ksyMaPRBuMEnfdhojz",
"keyBytes": "mjAR0I/E+pNVwqxQ+Z3yGb1o0z5uELRb60DZikAQFDADskNwpOnFtC30jRx+Cyni+o3ALdANvDmJtJVU8cCuNQ=="
},
"publicKey": {
"key": "FRt3vuU8aPPs74ZeH5CA6QD9WYutvVzzsySTYSTD1dn",
"keyBytes": "A7JDcKTpxbQt9I0cfgsp4vqNwC3QDbw5ibSVVPHArjU="
}
},
"mnemonic": {
"isValidChecksum": true,
"wordList": {
"space": " ",
"wordCount": 2048
},
"indices": [
1224,
1684,
34,
1881,
1701,
1350,
453,
1818,
519,
2037,
1451,
1540
],
"words": [
"october",
"spoon",
"affair",
"twenty",
"start",
"potato",
"december",
"today",
"domain",
"wrong",
"rely",
"scene"
]
}
}
create base wallet with default values for wordList as given
WordList.English
while wordCount must be provided
int
12 15 18 21 24
{
"account": {
"privateKey": {
"key": "45oED964ffnj1Br6tDbwcLNdi8JaZqHciVdWeaJhLVwB4JWZ3SRWE7LtZn4Zh4ntqjrDD7ksyMaPRBuMEnfdhojz",
"keyBytes": "mjAR0I/E+pNVwqxQ+Z3yGb1o0z5uELRb60DZikAQFDADskNwpOnFtC30jRx+Cyni+o3ALdANvDmJtJVU8cCuNQ=="
},
"publicKey": {
"key": "FRt3vuU8aPPs74ZeH5CA6QD9WYutvVzzsySTYSTD1dn",
"keyBytes": "A7JDcKTpxbQt9I0cfgsp4vqNwC3QDbw5ibSVVPHArjU="
}
},
"mnemonic": {
"isValidChecksum": true,
"wordList": {
"space": " ",
"wordCount": 2048
},
"indices": [
1224,
1684,
34,
1881,
1701,
1350,
453,
1818,
519,
2037,
1451,
1540
],
"words": [
"october",
"spoon",
"affair",
"twenty",
"start",
"potato",
"december",
"today",
"domain",
"wrong",
"rely",
"scene"
]
}
}
create base wallet with default values for WordCount as given
WordCount count
while WordList must be provided
string
"English", "Japanese", "ChineseSimplified", "ChineseTraditional", "Spanish", "French", "PortugueseBrazil", "Czech"
{
"account": {
"privateKey": {
"key": "45oED964ffnj1Br6tDbwcLNdi8JaZqHciVdWeaJhLVwB4JWZ3SRWE7LtZn4Zh4ntqjrDD7ksyMaPRBuMEnfdhojz",
"keyBytes": "mjAR0I/E+pNVwqxQ+Z3yGb1o0z5uELRb60DZikAQFDADskNwpOnFtC30jRx+Cyni+o3ALdANvDmJtJVU8cCuNQ=="
},
"publicKey": {
"key": "FRt3vuU8aPPs74ZeH5CA6QD9WYutvVzzsySTYSTD1dn",
"keyBytes": "A7JDcKTpxbQt9I0cfgsp4vqNwC3QDbw5ibSVVPHArjU="
}
},
"mnemonic": {
"isValidChecksum": true,
"wordList": {
"space": " ",
"wordCount": 2048
},
"indices": [
1224,
1684,
34,
1881,
1701,
1350,
453,
1818,
519,
2037,
1451,
1540
],
"words": [
"october",
"spoon",
"affair",
"twenty",
"start",
"potato",
"december",
"today",
"domain",
"wrong",
"rely",
"scene"
]
}
}
this endpoint gives you full access to parameters of creating wallet such as WordCount
and WordList
so both must be provided for this endpoint
public class WalletCreationRequest
{
public string WordList { get; set; }
public int WordCount { get; set; }
}
12 15 18 21 24
"English", "Japanese", "ChineseSimplified", "ChineseTraditional", "Spanish", "French", "PortugueseBrazil", "Czech"
{
"account": {
"privateKey": {
"key": "45oED964ffnj1Br6tDbwcLNdi8JaZqHciVdWeaJhLVwB4JWZ3SRWE7LtZn4Zh4ntqjrDD7ksyMaPRBuMEnfdhojz",
"keyBytes": "mjAR0I/E+pNVwqxQ+Z3yGb1o0z5uELRb60DZikAQFDADskNwpOnFtC30jRx+Cyni+o3ALdANvDmJtJVU8cCuNQ=="
},
"publicKey": {
"key": "FRt3vuU8aPPs74ZeH5CA6QD9WYutvVzzsySTYSTD1dn",
"keyBytes": "A7JDcKTpxbQt9I0cfgsp4vqNwC3QDbw5ibSVVPHArjU="
}
},
"mnemonic": {
"isValidChecksum": true,
"wordList": {
"space": " ",
"wordCount": 2048
},
"indices": [
1224,
1684,
34,
1881,
1701,
1350,
453,
1818,
519,
2037,
1451,
1540
],
"words": [
"october",
"spoon",
"affair",
"twenty",
"start",
"potato",
"december",
"today",
"domain",
"wrong",
"rely",
"scene"
]
}
}