Om.Chainlogger
1.0.3
dotnet add package Om.Chainlogger --version 1.0.3
NuGet\Install-Package Om.Chainlogger -Version 1.0.3
This command is intended to be used within the Package Manager Console in Visual Studio, as it uses the NuGet module's version of Install-Package.
<PackageReference Include="Om.Chainlogger" Version="1.0.3" />
For projects that support PackageReference, copy this XML node into the project file to reference the package.
paket add Om.Chainlogger --version 1.0.3
The NuGet Team does not provide support for this client. Please contact its maintainers for support.
#r "nuget: Om.Chainlogger, 1.0.3"
#r directive can be used in F# Interactive and Polyglot Notebooks. Copy this into the interactive tool or source code of the script to reference the package.
// Install Om.Chainlogger as a Cake Addin
#addin nuget:?package=Om.Chainlogger&version=1.0.3
// Install Om.Chainlogger as a Cake Tool
#tool nuget:?package=Om.Chainlogger&version=1.0.3
The NuGet Team does not provide support for this client. Please contact its maintainers for support.
chainlogger-csharp
Simple csharp package for using Chain Logger on omChain Jupiter
ABI:
[{"type":"constructor","stateMutability":"nonpayable","inputs":[]},{"type":"event","name":"LogRegistered","inputs":[{"type":"address","name":"_vendorAddress","internalType":"address","indexed":true},{"type":"uint256","name":"_projectId","internalType":"uint256","indexed":false},{"type":"uint256","name":"_projectLogCounter","internalType":"uint256","indexed":false},{"type":"bytes32","name":"_data","internalType":"bytes32","indexed":true}],"anonymous":false},{"type":"event","name":"VendorRegistered","inputs":[{"type":"uint256","name":"_id","internalType":"uint256","indexed":true},{"type":"address","name":"_vendorAddress","internalType":"address","indexed":true}],"anonymous":false},{"type":"function","stateMutability":"nonpayable","outputs":[{"type":"bool","name":"","internalType":"bool"}],"name":"_changeOwner","inputs":[{"type":"address","name":"toOwner","internalType":"address"}]},{"type":"function","stateMutability":"view","outputs":[{"type":"bytes32","name":"","internalType":"bytes32"}],"name":"getLog","inputs":[{"type":"address","name":"vendorAddress","internalType":"address"},{"type":"uint256","name":"projectId","internalType":"uint256"},{"type":"uint256","name":"logId","internalType":"uint256"}]},{"type":"function","stateMutability":"view","outputs":[{"type":"uint256","name":"","internalType":"uint256"}],"name":"numVendors","inputs":[]},{"type":"function","stateMutability":"view","outputs":[{"type":"address","name":"","internalType":"address"}],"name":"owner","inputs":[]},{"type":"function","stateMutability":"nonpayable","outputs":[{"type":"address","name":"","internalType":"address"},{"type":"uint256","name":"","internalType":"uint256"},{"type":"uint256","name":"","internalType":"uint256"},{"type":"bytes32","name":"","internalType":"bytes32"}],"name":"registerLog","inputs":[{"type":"uint256","name":"projectId","internalType":"uint256"},{"type":"bytes32","name":"data","internalType":"bytes32"}]},{"type":"function","stateMutability":"nonpayable","outputs":[{"type":"uint256","name":"","internalType":"uint256"}],"name":"registerProject","inputs":[]},{"type":"function","stateMutability":"nonpayable","outputs":[{"type":"uint256","name":"","internalType":"uint256"}],"name":"registerVendor","inputs":[]},{"type":"function","stateMutability":"view","outputs":[{"type":"address","name":"vendorAddress","internalType":"address"},{"type":"uint256","name":"projectCounter","internalType":"uint256"}],"name":"vendorLogs","inputs":[{"type":"uint256","name":"","internalType":"uint256"}]},{"type":"function","stateMutability":"view","outputs":[{"type":"address","name":"","internalType":"address"}],"name":"vendors","inputs":[{"type":"uint256","name":"","internalType":"uint256"}]},{"type":"function","stateMutability":"view","outputs":[{"type":"uint256","name":"","internalType":"uint256"}],"name":"vendorsReverse","inputs":[{"type":"address","name":"","internalType":"address"}]}]
Installation
Import package from nuget or download from github
After installing or downloading, you can include the Chain Logger on your projects as following
using Src.Chainlogger;
var logger = new Logger();
logger.SetProvider('YOUR_PROVIDER_URL');
logger.SetAbi('CONTRACT_ABI');
logger.SetEthSigner('YOUR_ETH_SIGNER_PROVIDER');
logger.SetWeb3();
logger.SetSalt("MY_SECRET_SALT");
logger.SetContract('CONTRACT_ADDRESS');
logger.SetSendContract('CONTRACT_ADDRESS');
logger.SetAccount('YOUR_WALLET_ADDRESS');
Registering vendor
await this.logger.RegisterVendorAsync()
#Returns the txHash of the call
Registering project
await this.logger.RegisterProjectAsync()
#Returns the txHash of the call
Registering a log
await this.logger.RegisterLogAsync(projectId, rawInput);
#Returns the txHash of the call
Getting tx receipt for registerLog method
await this.logger.GetTransactionReceiptAsync(txId);
Verifying data from blockchain
this.logger.VerifyData(hashedDataFromBlockchain, rawInput, salt)
#Returns boolean
Product | Versions Compatible and additional computed target framework versions. |
---|---|
.NET | net5.0 is compatible. net5.0-windows was computed. net6.0 was computed. net6.0-android was computed. net6.0-ios was computed. net6.0-maccatalyst was computed. net6.0-macos was computed. net6.0-tvos was computed. net6.0-windows was computed. net7.0 was computed. net7.0-android was computed. net7.0-ios was computed. net7.0-maccatalyst was computed. net7.0-macos was computed. net7.0-tvos was computed. net7.0-windows was computed. net8.0 was computed. net8.0-android was computed. net8.0-browser was computed. net8.0-ios was computed. net8.0-maccatalyst was computed. net8.0-macos was computed. net8.0-tvos was computed. net8.0-windows was computed. |
Compatible target framework(s)
Included target framework(s) (in package)
Learn more about Target Frameworks and .NET Standard.
-
net5.0
- Nethereum.Web3 (>= 4.1.0)
NuGet packages
This package is not used by any NuGet packages.
GitHub repositories
This package is not used by any popular GitHub repositories.
Version | Downloads | Last updated |
---|---|---|
1.0.3 | 350 | 10/23/2021 |
Simple csharp package for using Chain Logger on omChain Jupiter