From 48443c5b3a51439a1e460e8de96c050c1ea3eb09 Mon Sep 17 00:00:00 2001 From: fiatjaf_ Date: Sun, 5 Apr 2026 12:08:51 -0300 Subject: u32 Co-authored-by: Awiteb --- 5C.md | 16 ++++++++-------- 1 file changed, 8 insertions(+), 8 deletions(-) diff --git a/5C.md b/5C.md index f4b8e64..fc46ed2 100644 --- a/5C.md +++ b/5C.md @@ -125,14 +125,14 @@ When the host calls `run()`, it passes a single pointer to a buffer containing a The host must prefix every parameter with a single presence byte: `1` indicates the parameter is provided, and `0` indicates it is omitted. If a required parameter is prefixed with `0`, the program must panic. -| Type | Encoding | Size (if provided) | -| ------------ | --------------------------------------------------------------------- | ------------------ | -| `public_key` | 32 bytes | 32 bytes | -| `event` | i32 handle | 4 bytes | -| `string` | u32_be length followed by UTF-8 bytes | 4 + len bytes | -| `number` | i32 | 4 bytes | -| `timestamp` | Unix timestamp as u32_be | 4 bytes | -| `relay` | Relay URL, same encoding as string | 4 + len bytes | +| Type | Encoding | Size (if provided) | +| ------------ | -----------------------------------| ------------------ | +| `public_key` | 32 bytes | 32 bytes | +| `event` | i32 handle | 4 bytes | +| `string` | u32 length followed by UTF-8 bytes | 4 + len bytes | +| `number` | i32 | 4 bytes | +| `timestamp` | Unix timestamp as u32 | 4 bytes | +| `relay` | Relay URL, same encoding as string | 4 + len bytes | For example, in a scroll with these parameters: -- cgit v1.2.3