Chrysalis 0.4.0
dotnet add package Chrysalis --version 0.4.0
NuGet\Install-Package Chrysalis -Version 0.4.0
<PackageReference Include="Chrysalis" Version="0.4.0" />
paket add Chrysalis --version 0.4.0
#r "nuget: Chrysalis, 0.4.0"
// Install Chrysalis as a Cake Addin #addin nuget:?package=Chrysalis&version=0.4.0 // Install Chrysalis as a Cake Tool #tool nuget:?package=Chrysalis&version=0.4.0
Chrysalis: Cardano Serialization Library for .NET 🦋
Chrysalis is an open-source .NET library designed to facilitate the serialization and deserialization of Cardano blockchain data structures. With a strong focus on adhering to the Cardano standards and enhancing the .NET Cardano developer ecosystem, Chrysalis aims to provide developers with a reliable and consistent toolkit for working with Cardano.
🚧 NOTE: This library is currently a work in progress. Feedback and contributions are welcome!
Features
- Cardano Serialization: Convert Cardano data structures to and from CBOR (Concise Binary Object Representation).
- Bech32 Address Encoding/Decoding: Handle Cardano addresses seamlessly.
- Extensive Data Model Support: Work with a wide range of Cardano data types, including Transactions, Assets, MultiAssets, and more.
- Smart Contract Interaction: Interact with Cardano smart contracts.
- Cross-Platform Compatibility: Use Chrysalis in any .NET project, including .NET Core, .NET Framework, Xamarin, and more.
Roadmap 🚀
- (De)serialization Support: Achieve complete serialization and deserialization for any Cardano data type described in CDDL https://github.com/input-output-hk/cardano-ledger/blob/master/eras/alonzo/test-suite/cddl-files/alonzo.cddl.
- Transaction Handling: Introduce capabilities for building and signing Cardano transactions.
- Advanced Address Management: Implement address generation, derivation, and other associated functionalities.
Getting Started
To use Chrysalis in your .NET project:
dotnet add package Chrysalis
Example Usage
CBOR (De)serialization
var originalTransaction = CborSerializerV2.FromHex<Transaction>(originalTransactionCborHex)!; var serializedTransaction = CborSerializerV2.Serialize(originalTransaction); var deserializedTransaction = CborSerializerV2.Deserialize<Transaction>(serializedTransaction);
Bech32 Address Encoding/Decoding
var addressBech32 = "addr..."; var addressObject = Address.FromBech32(addressBech32); var addressBech32Again = addressObject.ToBech32(); var paymentKeyHash = addressObject.GetPaymentKeyHash(); var stakeKeyHash = addressObject.GetStakeKeyHash();
How to Contribute
Interested in contributing to Chrysalis? Great! We appreciate any help, be it in the form of code contributions, documentation, or even bug reports.
- Fork and Clone: Fork this repository, clone it locally, and set up the necessary development environment.
- Branch: Always create a new branch for your work.
- Pull Request: Submit a pull request once you're ready. Ensure you describe your changes clearly.
- Feedback: Wait for feedback and address any comments or suggestions.
License
MIT License
Copyright (c) 2023 0xAccretion
Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions:
The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
Give your feedback, star the repository if you found it useful, and consider contributing to push the Cardano .NET ecosystem forward! 🌟
Product | Versions Compatible and additional computed target framework versions. |
---|---|
.NET | net9.0 is compatible. |
-
net9.0
- NSec.Cryptography (>= 24.4.0)
- SauceControl.Blake2Fast (>= 2.0.0)
- System.Formats.Cbor (>= 8.0.0)
NuGet packages (1)
Showing the top 1 NuGet packages that depend on Chrysalis:
Package | Downloads |
---|---|
Argus.Sync
A ASP.NET Framework for Indexing Cardano Data storing it in PostgresSQL |
GitHub repositories
This package is not used by any popular GitHub repositories.
Version | Downloads | Last updated |
---|---|---|
0.4.0 | 0 | 11/22/2024 |
0.3.1 | 1 | 11/22/2024 |
0.3.0 | 76 | 11/5/2024 |
0.2.8 | 87 | 10/21/2024 |
0.2.7 | 119 | 10/20/2024 |
0.2.6 | 139 | 10/18/2024 |
0.2.5 | 91 | 10/17/2024 |
0.2.4 | 87 | 10/17/2024 |
0.2.3 | 93 | 10/16/2024 |
0.2.2 | 164 | 9/20/2024 |
0.2.1 | 100 | 9/19/2024 |
0.2.0 | 81 | 9/19/2024 |
0.1.9 | 338 | 9/13/2024 |
0.1.8 | 125 | 9/11/2024 |
0.1.7 | 118 | 9/11/2024 |
0.1.6 | 119 | 9/11/2024 |
0.1.5 | 108 | 9/6/2024 |
0.1.4 | 101 | 9/5/2024 |
0.1.3 | 100 | 9/5/2024 |
0.1.0 | 58 | 9/3/2024 |
0.0.7 | 99 | 10/10/2023 |
0.0.6 | 84 | 10/6/2023 |
0.0.5 | 84 | 10/6/2023 |
0.0.1 | 47 | 9/3/2024 |