Skip to content

stellar-experimental/zig-soroban-sdk

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

29 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

zig-soroban-sdk

Caution

This is experimental and should not be used for anything other than toy experiments.

A Zig SDK for writing Soroban smart contracts on the Stellar network.

Requirements

Build

Build the SDK library and examples:

zig build examples

Run tests:

zig build test

Examples

Example Description
hello Hello world contract
increment Counter stored in contract data
token SEP-41 fungible token

Usage

Add the SDK as a dependency in your build.zig.zon, then import it in your contract:

const sdk = @import("soroban-sdk");

const MyContract = struct {
    pub fn hello(to: sdk.Symbol) sdk.VecObject {
        // ...
    }
};

comptime {
    _ = sdk.contract.exportContract(MyContract);
}

About

An experimental Zig Soroban SDK Library.

Resources

License

Code of conduct

Contributing

Security policy

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors

Languages