Controls access to cutting-edge but potentially changing APIs.
Current Value
falseRelevant for: developers
The Big Picture
Some host functions are experimental and may change. This flag controls whether they're exposed. Production networks typically disable this; testnets may enable it.
From Chain Metadata
Make contract callable functions marked as `#[unstable]` available. Contracts that use `#[unstable]` functions won't be able to be uploaded unless this is set to `true`. This is only meant for testnets and dev nodes in order to experiment with new features. # Warning Do **not** set to `true` on productions chains.
Use Cases
- Check availability of experimental features
- Plan for API stability
Code Examples
import { createClient, Binary } from "polkadot-api";
import { getWsProvider } from "polkadot-api/ws";
import { sub } from "@polkadot-api/descriptors"; // generated by: npx papi add sub -w wss://entrypoint-finney.opentensor.ai:443
const client = createClient(getWsProvider("wss://entrypoint-finney.opentensor.ai:443"));
const api = client.getTypedApi(sub);
// Query UnsafeUnstableInterface constant
const value = await api.constants.Contracts.UnsafeUnstableInterface();
console.log("UnsafeUnstableInterface:", value);Type Information
- Type
- bool
- Byte Size
- 1 bytes
- Encoding
- fixed
- Raw Hex
- 0x00
Runtime Info
- Pallet
- Contracts
- First Version
- v334
- Latest Version
- v334
- Current Runtime
- v411