Skip to content

Braga has been retired. The next public testnet is coming in September 2026. Read the announcement →

u64(value): U64Value

Defined in: src/attr/values.ts:146

A 64-bit unsigned integer, indexed for equality and range queries.

This is the width the protocol counts in: block heights, $expiresAt and the entity-nonce are all u64, so it is the type to reach for when a value has to line up with one of them. Use u256 for token amounts and anything else that can exceed 2⁶⁴.

A non-negative integer, as a bigint, a safe number, or a decimal or 0x hex string.

string | number | bigint

U64Value

If the value is negative, non-integral, or wider than 64 bits.

u64(1_200_000n) // a block height
u64(Date.now()) // safe integers are accepted
u64("0x124f80") // hex, as it comes back over JSON-RPC