# CCIP v1.6.0 TON Events API Reference
Source: https://docs.chain.link/ccip/v1/ton/api-reference/v1.6.0/events

> For the complete documentation index, see [llms.txt](/llms.txt).

## Events

TON contracts emit events by calling `emit(topic, data)` — a convention that serializes the topic (a 32-bit CRC) and data into an external message. Events can be observed by indexers and explorers.

***

## Receiver Events

### `CCIPMessageReceived`

Emitted by receiver contracts to signal a successful CCIP message processing. This is a convention used in the Starter Kit examples, not a protocol-level event.

> **NOTE**
>
> `CCIPMessageReceived` is not a standard part of CCIP and is not emitted by CCIP protocol contracts. It is emitted by
> the receiver implementations in the TON Starter Kit for testing and observability purposes. Emitting this event is not
> a requirement for a valid CCIP receiver.

```tolk
const RECEIVED_MESSAGE_TOPIC = 0xc5a40ab3; // crc32("Receiver_CCIPMessageReceived")

struct CCIPMessageReceived {
    message: Any2TVMMessage;
}
```

***

## OnRamp Events

### `CCIPMessageSent`

Emitted by the OnRamp when a `Router_CCIPSend` message is accepted and a CCIP message is committed to the cross-chain pipeline.

```tolk
const CCIP_MESSAGE_SENT_TOPIC: int = stringCrc32("CCIPMessageSent");

struct CCIPMessageSent {
    message: TVM2AnyRampMessage;
}
```

**Fields of `TVM2AnyRampMessage`**

| Field           | Type                           | Description                                                                                           |
| --------------- | ------------------------------ | ----------------------------------------------------------------------------------------------------- |
| `header`        | `RampMessageHeader`            | Message metadata: `messageId`, `sourceChainSelector`, `destChainSelector`, `sequenceNumber`, `nonce`. |
| `sender`        | `address`                      | TON address of the sender (the Router on behalf of the user).                                         |
| `body`          | `Cell<TVM2AnyRampMessageBody>` | Encoded message body containing `receiver`, `data`, `extraArgs`, `feeToken`, `feeTokenAmount`.        |
| `feeValueJuels` | `uint96`                       | Fee value in LINK Juels for standardized cross-chain accounting.                                      |

**When it's emitted:** After the FeeQuoter validates the message and the OnRamp processes the CCIP send. Use the `messageId` in this event to track your message in the [CCIP Explorer](https://ccip.chain.link/).

***

### `DestChainSelectorAdded`

Emitted when a new destination chain is configured on the OnRamp.

```tolk
const DEST_CHAIN_SELECTOR_ADDED_TOPIC: int = stringCrc32("DestChainSelectorAdded");
struct DestChainSelectorAdded {
    destChainSelector: uint64;
}
```

***

### `DestChainConfigUpdated`

Emitted when the configuration for a destination chain is updated on the OnRamp.

```tolk
const DEST_CHAIN_CONFIG_UPDATED_TOPIC: int = stringCrc32("DestChainConfigUpdated");
struct DestChainConfigUpdated {
    destChainSelector: uint64;
    destChainConfig: OnRamp_DestChainConfig;
}
```

***

## Router Admin Events

### `OnRampSet`

Emitted when an OnRamp is configured or updated for a destination chain selector.

```tolk
const ON_RAMP_SET_TOPIC: int = stringCrc32("OnRampSet");
struct OnRampSet {
    destChainSelectors: SnakedCell<uint64>;
    onRamp: address?;
}
```

***

### `OffRampAdded`

Emitted when an OffRamp is added for a source chain selector.

```tolk
const OFF_RAMP_ADDED_TOPIC: int = stringCrc32("OffRampAdded");
struct OffRampAdded {
    sourceChainSelectors: SnakedCell<uint64>;
    offRampAdded: address;
}
```

***

### `OffRampRemoved`

Emitted when an OffRamp is removed.

```tolk
const OFF_RAMP_REMOVED_TOPIC: int = stringCrc32("OffRampRemoved");
struct OffRampRemoved {
    sourceChainSelectors: SnakedCell<uint64>;
    offRampRemoved: address;
}
```

***

### `Cursed` / `Uncursed`

Emitted by the Router when an RMN curse is applied or lifted for a subject (e.g., a source chain).

```tolk
const CURSED_TOPIC: int = stringCrc32("Cursed");
struct Cursed { subject: uint128; }

const UNCURSED_TOPIC: int = stringCrc32("Uncursed");
struct Uncursed { subject: uint128; }
```

> **CAUTION: Educational Example Disclaimer**
>
> Please note, this page contains community examples only — these are not Chainlink products or services and are not
> supported or maintained by Chainlink. This code represents an example of using a Chainlink product or service, and is
> intended for demonstration and educational purposes only. It is provided "AS IS" and "AS AVAILABLE" without warranties
> of any kind, may not have been audited, and may omit checks or error handling. Each party intending to use this
> example code does so entirely at their own risk and must perform its own audits, security and code review, key
> management, and testing before any production deployment and ensure the operation and performance of such code matches
> expectations. Neither Chainlink Labs nor the Chainlink Foundation deploys, operates, monitors, maintains or endorses
> any deployment of this code. Note that this is not a Chainlink product, feature or service, and there are no
> commitments made with respect to the code, including compatibility with future Chainlink releases. You should not rely
> on this code without first conducting your own technical, engineering, and security review. This code is also outside
> the scope of any Chainlink bug bounty programs. Neither Chainlink Labs, the Chainlink Foundation, nor Chainlink node
> operators are responsible for outcomes due to errors in this example or how it is deployed or operated, or liable for
> any resulting claims or damages. Use of the Chainlink Network is subject to the Chainlink Foundation [Terms of
> Service](https://chain.link/terms), which provides important information and disclosures. By using this code, you
> acknowledge and agree to these terms.