Skip to main content
Event Types

Trustline Events

Trust lines are the authorization mechanism on the XRPL that links an account to a token issuer. An account must hold an open trust line before it can receive or hold any issued token. XRNotify tracks trust line creation, modification, and removal across the entire ledger.

trustline.createdtrustline.modifiedtrustline.deleted

trustline.created

TrustSet (new)

Fires when a TrustSet transaction creates a brand new trust line with a non-zero limit. This signals that an account has opted in to holding a specific issued token from a specific issuer.

Payload schema

FieldTypeDescription
accountstringAccount address that created the trust line
issuerstringAccount address of the token issuer being trusted
currencystringCurrency code — 3-letter ASCII or 40-character hex
limitstringMaximum token amount the account is willing to hold (decimal string)
balancestringCurrent token balance (typically "0" on creation)
no_ripplebooleanTrue if rippling (token routing) is disabled on this trust line
freezebooleanTrue if the issuer has frozen this trust line
authorizedbooleanTrue if the issuer has authorized this trust line (required for tokens with RequireAuth enabled)
ledger_indexnumberLedger in which the trust line was created
tx_hashstringTransaction hash of the TrustSet transaction

Example payload

{
  "event_id": "xrpl:89570000:C5D6E7F8A9B0:trustline.created",
  "event_type": "trustline.created",
  "ledger_index": 89570000,
  "timestamp": "2024-01-15T16:00:00Z",
  "network": "mainnet",
  "payload": {
    "account": "rN7n3473SaZBCG4dFL83w7PB2bBdDiAkzN",
    "issuer": "rhub8VRN55s94qWKDv6jmDy1pUykJzF3wq",
    "currency": "USD",
    "limit": "10000",
    "balance": "0",
    "no_ripple": true,
    "freeze": false,
    "authorized": false,
    "ledger_index": 89570000,
    "tx_hash": "C5D6E7F8A9B0C5D6E7F8A9B0C5D6E7F8A9B0C5D6E7F8A9B0C5D6E7F8A9B0C5D6"
  }
}

trustline.modified

TrustSet (update)

Fires when a TrustSet transaction changes an existing trust line — for example, updating the limit amount, toggling the NoRipple flag, or when an issuer freezes or unfreezes the line. The payload includes both the new values and the previous values so you can see exactly what changed.

Freeze note: When freeze: true appears in this event, the issuer has frozen this trust line. The account cannot send tokens until the issuer unfreezes it, though they can still receive tokens.

Payload schema

All fields from trustline.created are present, plus the following "previous" fields showing what changed:

FieldTypeDescription
previous_limitstringTrust line limit before this transaction
previous_no_ripplebooleanNoRipple flag value before this transaction
previous_freezebooleanFreeze flag value before this transaction

Example payload

{
  "event_id": "xrpl:89572000:D6E7F8A9B0C1:trustline.modified",
  "event_type": "trustline.modified",
  "ledger_index": 89572000,
  "timestamp": "2024-01-15T16:30:00Z",
  "network": "mainnet",
  "payload": {
    "account": "rN7n3473SaZBCG4dFL83w7PB2bBdDiAkzN",
    "issuer": "rhub8VRN55s94qWKDv6jmDy1pUykJzF3wq",
    "currency": "USD",
    "limit": "50000",
    "balance": "250.00",
    "no_ripple": true,
    "freeze": false,
    "authorized": false,
    "previous_limit": "10000",
    "previous_no_ripple": true,
    "previous_freeze": false,
    "ledger_index": 89572000,
    "tx_hash": "D6E7F8A9B0C1D6E7F8A9B0C1D6E7F8A9B0C1D6E7F8A9B0C1D6E7F8A9B0C1D6E7"
  }
}

trustline.deleted

TrustSet (remove)

Fires when a trust line is removed from the ledger. This happens when an account submits a TrustSet with a limit of 0 and the balance is also 0, or when the balance reaches 0 and the ledger automatically removes the trust line object to reclaim the reserve.

Payload schema

FieldTypeDescription
accountstringAccount that held the trust line
issuerstringIssuer address the trust line was with
currencystringCurrency code of the removed trust line
final_balancestringToken balance at the time of deletion (should be "0")
ledger_indexnumberLedger in which the trust line was deleted
tx_hashstringTransaction hash

Related event types