Skip to content

Commit

Permalink
Merge pull request #325 from Chia-Network/message-conditions
Browse files Browse the repository at this point in the history
document CHIP-25 message conditions
  • Loading branch information
BrandtH22 committed Sep 24, 2024
2 parents 112c170 + aa61552 commit a7f3f98
Showing 1 changed file with 52 additions and 0 deletions.
52 changes: 52 additions & 0 deletions docs/conditions.md
Original file line number Diff line number Diff line change
Expand Up @@ -368,6 +368,58 @@ The following parameters are expected:

---

### 66 `SEND_MESSAGE` {#send-message}

:::info
This condition is part of [CHIP-0025](https://github.com/Chia-Network/chips/blob/main/CHIPs/chip-0025.md), and became available at block height 5,716,000.
:::

Format: `(66 mode message ...)`

Asserts that exactly one of the destination coin issues exactly one corresponding `RECEIVE_MESSAGE` condition.

The following parameters are expected:

| Name | Type |
| ------------- | ------------ |
| `mode` | Unsigned Int |
| `message` | Bytes |
| `destination` | ... |

`mode` may only have bits 0-5 set.

`message` may not be greater than 1024 bytes long.

The parameters after `message` depends on which bits are set in `mode`. They identify the receiving spend.

---

### 67 `RECEIVE_MESSAGE` {#receive-message}

:::info
This condition is part of [CHIP-0025](https://github.com/Chia-Network/chips/blob/main/CHIPs/chip-0025.md), and became available at block height 5,716,000.
:::

Format: `(67 mode message ...)`

Asserts that exactly one of the source coin issues exactly one corresponding `SEND_MESSAGE` condition.

The following parameters are expected:

| Name | Type |
| ------------- | ------------ |
| `mode` | Unsigned Int |
| `message` | Bytes |
| `source` | ... |

`mode` may only have bits 0-5 set.

`message` may not be greater than 1024 bytes long.

The parameters after `message` depend on which bits are set in `mode`. They identify the sending spend.

---

### 70 `ASSERT_MY_COIN_ID` {#assert-my-coin-id}

Format: `(70 coin_id)`
Expand Down

0 comments on commit a7f3f98

Please sign in to comment.