/SDK-CSharp

Activeledger SDK for .Net

Primary LanguageC#MIT LicenseMIT

https://github.com/activeledger/SDK-Ruby/edit/master/README.md

Activeledger .NET SDK

Add the Reference of the ActiveLedger library in your Visual Studio project

Initialise the SDK

ActiveLedgerLib.SDKPreferences.setSettings("protocol", "URL", "port");

Generate KeyPair

AsymmetricCipherKeyPair keypair = ActiveLedgerLib.GenerateKeyPair.GetKeyPair(KeyType);

Creating Onboard transaction

Generate Json Object for onBoaring keys

JObject json = ActiveLedgerLib.GenerateTxJson.GetTxJsonForOnboardingKeys(PathOfPublicKeyFile, AsymmetricKeypair,TypeofKey);

Send a transaction

Submit a transaction to Activeledger

var response = ActiveLedgerLib.MakeRequest.makeRequestAsync(SDKPrefernece, jsonObjectIntheFormOfString);

Key Management

Writing KeyPair in the file in PEM Format

ActiveLedgerLib.Helper.WritekeyPairInFile(PathOfFile, AsymmetricCipherKeyPair);

Writing Only the Public Key in the file in PEM Format

ActiveLedgerLib.Helper.WritePublicKeyInFile(PathOfFile, AsymmetricCipherKeyPair);

Reading Only the Pem Format key pair from the user file and return the Asymmetric Keypair

AsymmetricCipherKeyPair keypair = ActiveLedgerLib.Helper.ReadAsymmetricKeyParameter(PathOfFile);

License


This project is licensed under the MIT License