Expand description

The Scrypto Standard Library

The Scrypto Standard Library is the foundation of Scrypto blueprints, a set of minimal and shared abstractions on top of Radix Engine. It enables asset-oriented programming for feature-rich DeFi dApps.

If you know the name of what you’re looking for, the fastest way to find it is to use the search bar at the top of the page.

Modules

Scrypto blueprint ABI.

Scrypto data encoding, decoding and exchange.

Scrypto component library.

Scrypto constants.

Scrypto core library, mainly process and transaction context.

Scrypto cryptography library.

Radix engine APIs.

Scrypto math library.

Miscellaneous functions.

Scrypto preludes.

Scrypto resource library.

A facade of types in Rust standard library.

Scrypto types.

Scrypto values.

Macros

Encodes arguments according to Scrypto ABI.

Declares a blueprint.

This macro converts a ComponentAddress into a &Component via the Radix Engine component subsystem.

This macro creates a &Package from a PackageAddress via the Radix Engine component subsystem.

This macro creates a &ResourceManager from a ResourceAddress via the Radix Engine resource subsystem.

Compiles a Scrypto package and returns the output WASM file as byte array.

Logs a DEBUG message.

Creates a Decimal from literals.

Logs an ERROR message.

Imports a blueprint from its ABI.

Includes the WASM file of a Scrypto package.

Logs an INFO message.

Logs a TRACE message.

Logs a WARN message.

Traits

A data structure that can be decoded from a byte array using SBOR.

A data structure that can be described using SBOR types.

A data structure that can be serialized into a byte array using SBOR.

A SBOR type ID.

Derive Macros

Derive code that decodes this data structure from a byte array.

Derive code that describes this data structure.

Derive code that encodes this data structure

Derive code that describe a non-fungible data structure.

Derive code that returns the type ID.