Protocol Constants#
This page provides a comprehensive reference for all constants, limits, and default values defined in the Dash Platform Protocol implementation (rs-dpp).
System Limits#
Maximum sizes and limits for various platform components.
Limit |
Value |
Description |
Source |
|---|---|---|---|
Max contract size |
16,384 bytes (16 KiB) |
Maximum serialized data contract |
|
Max field value size |
5,120 bytes (5 KiB) |
Maximum single field value |
|
Max document value depth |
256 nested containers |
Maximum nesting depth within a document property value (protocol version 13 and later; unbounded earlier) |
|
Max state transition size |
20,480 bytes (20 KiB) |
Maximum serialized state transition |
|
Max transitions in documents batch |
1 |
Maximum transitions per batch state transition (document and token transitions counted together) |
|
Withdrawals per block |
4 |
Maximum withdrawal transactions per block |
|
Retry signing expired withdrawals per block |
1 |
Max expired withdrawal retries per block |
|
Max withdrawal amount |
50,000,000,000,000 credits |
500 Dash maximum per withdrawal |
|
Daily withdrawal limit |
Protocol versions 8-13: 200,000,000,000,000 credits (2000 Dash) |
The relative limit added in 5.0.0 is |
|
Core credit pool unlock limit |
15% of Core’s credit pool balance at the window start, at least 150,000,000,000,000 credits (1500 Dash) |
Added in 5.0.0. Platform pools a withdrawal only while Core’s credit pool would drop by at most this amount over the Core credit pool window, counting withdrawals already queued or broadcast but not yet completed. A stricter copy of Core v24’s unlock rule (20%, 2000-Dash floor), so Platform does not pool more than Core will mine |
|
Core credit pool window |
576 Core blocks (100 on regtest) |
Added in 5.0.0. Window over which the Core credit pool unlock limit is measured (Core’s |
|
Max group member count |
256 |
Maximum members of a change-control group defined in a data contract (renamed from |
|
Max token redemption cycles |
128 |
Maximum redemption cycles |
|
Max contenders per contest |
1,000 |
Added in 5.0.0. Maximum contenders a contested document vote poll accepts |
|
Max shielded transition actions |
16 |
Consensus cap on actions per shielded transition. The effective limit is 6: each action adds ~2,681 bytes to the transition (the 408-byte serialized action plus ~2,273 bytes of Halo 2 proof), so larger transitions exceed the max state transition size |
|
Max time-range overlap factor |
24 |
Added in 5.0.0. Maximum |
|
Max time-range TTL |
604,800 seconds (1 week) |
Added in 5.0.0. Maximum |
|
Min time-range TTL drop operations per write |
32 |
Added in 5.0.0. Minimum expired-entry cleanup operations Drive performs on each write into a |
|
Max time-range phase |
31,536,000 seconds (365 days) |
Added in 5.0.0. Maximum |
|
Core dust relay fee |
3,000 duffs/kB |
Added in 5.0.0. Used to compute the Core dust threshold of a withdrawal’s output script (546 duffs for P2PKH). An expired withdrawal whose whole amount is below it is marked |
|
Min GroveDB proof envelope version |
1 |
Added in 5.0.0. Client-side proof verification policy, not a consensus rule: clients reject the legacy V0 proof envelope at every protocol version. Nodes have served V1 since protocol version 12 |
|
Max CBOR encoded length |
16,384 bytes (16 KiB) |
Maximum CBOR encoding size (defined as |
|
Contract deserialization limit |
15,000 |
Maximum contract deserialization |
Credit System#
Credits are the unit of account for fees on Dash Platform. They are created from Dash locked on the Core blockchain.
Constant |
Value |
Description |
Source |
|---|---|---|---|
|
1,000 |
Credits created per duff (satoshi) |
|
|
9,223,372,036,854,775,807 |
Maximum credit value (i64::MAX) |
Conversion: 1 Dash = 100,000,000 duffs = 100,000,000,000 credits
Protocol Fees#
Base Processing#
These constants define the base costs for state transition processing.
Constant |
Value (Credits) |
Description |
Source |
|---|---|---|---|
|
10,000 |
Base state transition processing fee |
|
|
0 |
Default priority tip |
|
|
5,000 |
Storage cost per byte |
|
|
12 |
Processing cost per byte |
|
|
2,000 |
Base deletion cost |
|
|
8,400 |
Base read cost |
|
|
6,000 |
Base write cost |
State Transition Pricing#
These constants define minimum values required for a state transition to be considered valid.
State Transition |
Min Fee (Credits) |
Min Fee (Dash) |
Source |
|---|---|---|---|
Credit Transfer |
100,000 |
0.000001 |
|
Credit Transfer to Addresses |
500,000 |
0.000005 |
|
Credit Withdrawal |
400,000,000 |
0.004 |
|
Identity Update |
100,000 |
0.000001 |
|
Document Batch (per sub-transition) |
100,000 |
0.000001 |
|
Contract Create |
100,000 |
0.000001 |
|
Contract Update |
100,000 |
0.000001 |
|
Masternode Vote |
100,000 |
0.000001 |
|
Address Credit Withdrawal |
400,000,000 |
0.004 |
|
Address Funds Transfer (per input) |
500,000 |
0.000005 |
|
Address Funds Transfer (per output) |
6,000,000 |
0.00006 |
|
Identity Create (base) |
2,000,000 |
0.00002 |
|
Identity Key (per key at creation) |
6,500,000 |
0.000065 |
|
Identity TopUp (base) |
500,000 |
0.000005 |
Execution and Resource Pricing#
These fees meter execution and resource usage. They do not affect validity, but determine total cost.
Processing#
Fees for specific operations during state transition processing.
Operation |
Fee (Credits) |
Source |
|---|---|---|
Fetch identity balance |
10,000 |
|
Fetch identity revision |
9,000 |
|
Fetch identity balance and revision |
15,000 |
|
Fetch identity key by ID |
9,000 |
|
Fetch identity token balance |
10,000 |
|
Fetch prefunded specialized balance |
10,000 |
|
Fetch key with type, nonce and balance |
12,000 |
|
Fetch single identity key |
10,000 |
|
Network threshold signing |
100,000,000 |
|
Validate key structure |
50 |
Storage#
Fees related to data storage operations.
Operation |
Fee (Credits) |
Source |
|---|---|---|
Storage disk usage (per byte) |
27,000 |
|
Storage processing (per byte) |
400 |
|
Storage load (per byte) |
20 |
|
Non-storage load (per byte) |
10 |
|
Storage seek |
2,000 |
|
TTL ephemeral disk usage (per byte) |
270 |
Added in 5.0.0. Charged as processing for bytes written under a timeRange |
Cryptographic Operations#
Signature Verification#
Fees for verifying different signature types.
Key Type |
Verification Fee (Credits) |
Source |
|---|---|---|
ECDSA Secp256k1 |
15,000 |
|
BLS 12-381 |
300,000 |
|
ECDSA Hash160 |
15,500 |
|
BIP13 Script Hash |
300,000 |
|
EdDSA 25519 Hash160 |
3,500 |
Hashing#
Fees for cryptographic hash operations.
Operation |
Fee (Credits) |
Source |
|---|---|---|
Single SHA256 (base) |
100 |
|
Blake3 (base) |
100 |
|
SHA256 + RIPEMD160 (base) |
6,000 |
|
SHA256 (per block) |
5,000 |
|
Blake3 (per block) |
300 |
|
RIPEMD160 (per block) |
5,000 |
|
Sinsemilla (base) |
40,000 |
Data Contract Validation#
Fees for validating data contract structure during state transition processing.
Fee Type |
Amount (Credits) |
Source |
|---|---|---|
Document type base fee |
500 |
|
Schema size fee (per byte) |
10 |
|
Per property fee |
40 |
|
Non-unique index base fee |
50 |
|
Non-unique index per property fee |
30 |
|
Unique index base fee |
100 |
|
Unique index per property fee |
60 |
Document TTL#
Added in version 5.0.0.
Documents of a type that declares a ttl are stored without a storage refund. Instead of the perpetual storage rate, each byte the document writes is priced by its remaining lifetime, and the document prepays the processing cost of its eventual deletion.
Fee |
Amount (Credits) |
Source |
|---|---|---|
Lifetime up to 1 hour (per byte) |
1 |
|
Lifetime up to 1 day (per byte) |
4 |
|
Lifetime up to 2 days (per byte) |
8 |
|
Lifetime up to 4 days (per byte) |
15 |
|
Lifetime up to 7 days (per byte) |
26 |
|
Longer lifetimes (per byte, per 788,400-second period spanned, rounded up) |
34 |
|
Deletion prepayment (base) |
1,200,000 |
|
Deletion prepayment (per index level) |
400,000 |
|
Deletion prepayment (per document byte) |
420 |
Document References#
Added in version 5.0.0.
Fee |
Amount (Credits) |
Description |
Source |
|---|---|---|---|
|
100,000 |
Charged per competing document a |
|
|
100 |
Charged per list element a |
Shielded Fees#
Fees for the zero-knowledge compute and storage of shielded transitions that GroveDB metering does not price. The minimum shielded fee for a bundle of n actions is proof verification fee + n × per-action processing fee + n × storage bytes per action × (27,000 + 400), where 27,000 and 400 are the storage disk usage and storage processing rates per byte. Transitions that meter their storage instead charge only the compute portion (proof verification plus per-action processing).
Fee |
Amount |
Source |
|---|---|---|
Proof verification (per bundle) |
Updated in 5.0.0. |
|
Processing (per action) |
22,000,000 credits |
|
Storage bytes (per action) |
Updated in 5.0.0. |
Voting#
Fees related to contested document voting.
Fee Type |
Amount (Credits) |
Amount (Dash) |
Source |
|---|---|---|---|
Contested document vote resolution fund |
Updated in 5.0.0. |
0.2 |
|
Contested document unlock fund |
400,000,000,000 |
4.0 |
|
Single vote cost |
Updated in 5.0.0. |
0.0001 |
|
Moderation election vote resolution fund |
50,000,000,000 |
0.5 |
Added in 5.0.0. Paid by each application in a moderation team election. rs-platform-version |
Added in 5.0.0. Starting in protocol version 14, the first 250 contenders of a contest pay the vote resolution fund, and the fund then doubles for every 50 additional contenders (twice the fund for the 251st to 300th contender, up to 32,768 times the fund for the 951st to 1,000th).
Identity Model#
Identity Limits#
Limit |
Value |
Description |
Source |
|---|---|---|---|
Max public keys per identity |
15,000 |
Maximum keys an identity can have |
|
Max keys in creation |
6 |
Keys allowed at identity creation |
|
Identity nonce value filter |
0xFFFFFFFFFF |
40-bit nonce filter |
|
Max missing identity revisions |
24 |
Maximum revision gaps |
Identity Create Fees#
Requirement |
Value |
Description |
Source |
|---|---|---|---|
Min asset lock balance |
200,000 duffs |
0.002 Dash minimum |
|
Min top-up balance |
50,000 duffs |
0.0005 Dash minimum |
|
Min address funding balance |
50,000 duffs |
0.0005 Dash minimum |
|
Min identity funding amount |
200,000 credits |
Minimum for address-based creation |
|
Max asset-lock transaction inputs |
100 |
Maximum Core inputs in an asset-lock transaction used to fund an identity or top-up (introduced in protocol v3 to prevent stuck funds; v1/v2 had no effective limit) |
Document & Data Contract Model#
Document and Index Limits#
Limit |
Value |
Description |
Source |
|---|---|---|---|
Max indexed string length |
63 characters |
Maximum indexable string |
|
Max indexed byte array length |
255 bytes |
Maximum indexable byte array |
|
Max index size |
255 bytes |
Maximum total index size |
|
Default hash size |
32 bytes |
Standard hash size |
|
Default float size |
8 bytes |
Standard float size |
|
Empty tree storage size |
33 bytes |
Storage for empty tree |
|
Storage flags size |
2 bytes |
Size of storage flags |
|
Contract version stamp size |
5 bytes |
Added in 5.0.0. Extra bytes document serialization format 3 adds to the estimated document size |
Document Type Limits#
Added in version 5.0.0.
Limits on the document type keywords added in protocol version 14, enforced when a data contract is registered or updated unless noted otherwise.
Limit |
Value |
Description |
Source |
|---|---|---|---|
Max typed array items |
1,024 |
Maximum |
|
Max indexed typed array items |
16 |
Maximum |
|
Max windowed indexed typed array items |
4 |
Maximum |
|
Max index entries per document |
256 |
Maximum index entries one document of a type with an indexed typed array can write across all of the type’s indexes |
|
Max references per document |
256 |
Maximum |
|
Max reference operands |
4 |
Maximum operands in one |
|
Max reference expression depth |
4 |
Maximum nesting of |
|
Max |
1,000 |
Maximum competing documents a create reads for a |
|
Max |
10 |
Maximum properties a |
|
Max property constraints |
16 |
Maximum |
|
Max property constraint nodes |
32 |
Maximum nodes (comparisons, operators, properties, and values) in one |
|
Max property constraint aggregates |
4 |
Maximum distinct |
|
Min document TTL |
3,600 seconds (1 hour) |
Minimum |
|
Max document TTL |
31,536,000 seconds (365 days) |
Maximum |
|
Max document expirations per block |
128 |
Maximum expired documents Platform deletes in one block; the rest wait for later blocks, oldest first |
|
Max document expiration weight per block |
1,024 |
Maximum expiry cleanup work per block, where each deleted document weighs 1 plus the weighted index levels of its type |
|
Max contested summed value magnitude |
134,217,728 (2^27) |
A summed property of a document type with a contested index must declare a |
|
Max expiring signed summed value magnitude |
134,217,728 (2^27) |
A summed property that may be negative, on a document type with a |
Contract Groups and Moderation#
Added in version 5.0.0.
Limit |
Value |
Description |
Source |
|---|---|---|---|
Max contract group memberships per contract |
16 |
Maximum contract group memberships a data contract create transition may declare |
|
Max contract group admins |
16 |
Maximum admins a contract group may name besides its owner |
|
Max contract group name length |
64 characters |
Maximum length of a contract group name |
|
Max contract group description length |
256 characters |
Maximum length of a contract group description |
|
Max contract moderators |
16 |
Maximum moderator identities a moderated data contract may name (the owner counts when named) |
|
Max suspension end time |
9,007,199,254,740,991 ms (2^53 - 1) |
Latest block time a contract suspension may run until |
|
Max moderation reason length |
1,024 bytes |
Maximum UTF-8 length of the text of a ban, suspension, warning, or moderator document deletion reason |
|
Max warnings per identity |
16 |
Maximum warnings one identity may carry on a contract at a time |
|
Max moderation reason documents |
16 |
Maximum documents a moderation reason may cite |
|
Election window (join and vote) |
Min: 86,400 seconds (1 day) on mainnet, none on other networks |
Bounds on the join window and vote window of an elected moderation team declaration |
|
Default election window |
604,800 seconds (1 week) |
Join window and vote window of an elected moderation team declaration that omits them |
|
Challenge cool-down |
Min: 1,209,600 seconds (2 weeks) |
Bounds on how long a seated moderation team is safe from a challenge after a seat change |
|
Document restore window |
604,800,000 ms (7 days) |
How long after a moderator deletes a document the contract’s moderators may restore it |
|
Max added moderators |
15 |
Maximum members an elected moderation declaration may let a seated team’s leader add ( |
|
Max charter elected members |
15 |
Maximum members a moderation charter elects besides its leader |
Data Contract Constants#
Constant |
Value |
Description |
Source |
|---|---|---|---|
Initial contract version |
1 |
Starting version number |
Data Contract Registration Fees#
One-time fees for registering data contracts and their components.
Component |
Fee (Credits) |
Fee (Dash) |
Source |
|---|---|---|---|
Base contract registration |
10,000,000,000 |
0.1 |
|
Document type registration |
2,000,000,000 |
0.02 |
|
Non-unique index registration |
1,000,000,000 |
0.01 |
|
Unique index registration |
1,000,000,000 |
0.01 |
|
Contested index registration |
100,000,000,000 |
1.0 |
|
Token registration |
10,000,000,000 |
0.1 |
|
Token perpetual distribution |
10,000,000,000 |
0.1 |
|
Token pre-programmed distribution |
10,000,000,000 |
0.1 |
|
Token once-per-identity distribution |
Updated in 5.0.0. |
0 |
|
Search keyword (per keyword) |
10,000,000,000 |
0.1 |
Tokens#
Tokens are defined within data contracts and share the same lifecycle, versioning, and validation model as documents.
Token Limits#
Limit |
Value |
Description |
Source |
|---|---|---|---|
Max token note length |
2,048 bytes |
Maximum note/memo length |
|
Max token pool notes for outgoing |
250 |
Added in 5.0.0. Highest |
|
Max evonode reward claim epochs |
100 |
Added in 5.0.0. Maximum finalized epochs one |
Token Distribution Function Limits#
These limits apply to token perpetual distribution function parameters.
Parameter |
Min |
Max |
Source |
|---|---|---|---|
|
1 |
281,474,976,710,655 (2^48 - 1) |
|
|
1 |
32,767 (2^(63-48) - 1) |
|
Linear slope A |
-255 |
256 |
|
Polynomial M |
-8 |
8 |
|
Polynomial N |
0 |
32 |
|
Polynomial A |
-255 |
256 |
|
Log A |
-32,766 |
32,767 |
|
Exponential A |
1 |
256 |
|
Exponential M |
-8 |
8 |
|
Exponential N |
0 |
32 |
|
Default step decreasing max cycles |
128 |
128 |
Address System#
Added in version 3.0.0.
Address Constants#
Constant |
Value |
Description |
Source |
|---|---|---|---|
Address hash size |
20 bytes |
Size of address hash |
|
Platform HRP (mainnet) |
“dash” |
Human-readable prefix |
|
Platform HRP (non-mainnet) |
“tdash” |
Human-readable prefix used for testnet, devnet, and regtest |
|
P2PKH address type (bech32m) |
0xb0 (176) |
Pay-to-public-key-hash bech32m encoding type byte |
|
P2SH address type (bech32m) |
0x80 (128) |
Pay-to-script-hash bech32m encoding type byte |
Transaction Limits#
Limit |
Value |
Description |
Source |
|---|---|---|---|
Min output amount |
500,000 credits |
Minimum output per address |
|
Min input amount |
100,000 credits |
Minimum input per address |
|
Max fee strategies |
4 |
Maximum fee strategy steps |
|
Max address inputs |
16 |
Maximum input addresses per address-based transition |
|
Max address outputs |
128 |
Maximum output addresses per address-based transition |
|
Max asset lock transaction inputs |
100 |
Maximum L1 transaction inputs in an asset lock proof |
Epoch and Time Constants#
Constant |
Value |
Description |
Source |
|---|---|---|---|
Genesis epoch index |
0 |
First epoch number |
|
Perpetual storage eras |
50 |
Number of storage eras (~50 years) |
|
Default epochs per era |
40 |
Epochs in each era (~1 year) |
|
Epoch key offset |
256 |
Offset for epoch keys |
|
Max epoch |
65,279 |
Maximum epoch number (u16::MAX - 256) |
Refund Constants#
Constant |
Value |
Description |
Source |
|---|---|---|---|
Min refund limit |
32 bytes |
Minimum bytes for refund |
Withdrawal Constants#
Constant |
Value |
Description |
Source |
|---|---|---|---|
Min withdrawal amount |
1,000,000 credits |
1,000 duffs minimum per withdrawal (protocol version 12 and later; raised from 190,000 credits in earlier versions). Starting in protocol version 14, the Core transaction fee is deducted from the withdrawn amount, so a withdrawal must be at least this minimum plus the Core fee (190-byte asset unlock transaction × |
|
Min core fee per byte |
1 |
Must be Fibonacci number |
|
Max core fee per byte |
6,765 |
Added in 5.0.0. Highest |