# GMP Redeem Tracing

Filter `RedeemForBtc` call made on [AssetRouter contract.](https://etherscan.io/advanced-filter?ps=25\&eladd=0x964677F337d6528d659b1892D0045B8B27183fc0\&eltpc=0x8784acf2b096380844b252c1cc85752ea2dcccf0fd55ed7a440e0ccd3b56b908\&mtd=0x30b93d85%7eRedeem+For+Btc)

![](https://1161095600-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2Fl7wTwC5uXA2Yk5tvZMBg%2Fuploads%2FQOk3p2HAMXxk5wuh0Ymn%2F01-redeem-for-btc-transactions.png?alt=media\&token=eb4ff116-7e4e-41cc-a680-78d27fab44cd)

Open the transaction and navigate to "Logs" tab. Find `MessageSent` event.

![](https://1161095600-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2Fl7wTwC5uXA2Yk5tvZMBg%2Fuploads%2FZNAFoQWZiLAkZKc3KieJ%2F02-message-sent-event.png?alt=media\&token=5747b343-9fa2-463c-930a-5093d87e1538)

Copy data.

Open [input data decoder.](https://etherscan.io/inputdatadecoder)&#x20;

Paste data as Input Data, and ABI as Input ABI:

```json
[{
    "inputs": [
      {
        "internalType": "bytes32",
        "name": "pathId",
        "type": "bytes32"
      },
      {
        "internalType": "uint256",
        "name": "nonce",
        "type": "uint256"
      },
      {
        "internalType": "bytes32",
        "name": "sender",
        "type": "bytes32"
      },
      {
        "internalType": "bytes32",
        "name": "recipient",
        "type": "bytes32"
      },
      {
        "internalType": "bytes32",
        "name": "destinationCaller",
        "type": "bytes32"
      },
      {
        "internalType": "bytes",
        "name": "body",
        "type": "bytes"
      }
    ],
    "name": "MessageV1",
    "outputs": [],
    "stateMutability": "view",
    "type": "function"
  },
  {
    "inputs": [
      {
        "internalType": "bytes32",
        "name": "toChainID",
        "type": "bytes32"
      },
      {
        "internalType": "bytes32",
        "name": "fromToken",
        "type": "bytes32"
      },
      {
        "internalType": "bytes32",
        "name": "redeemer",
        "type": "bytes32"
      },
      {
        "internalType": "bytes",
        "name": "scriptpubkey",
        "type": "bytes"
      },
      {
        "internalType": "uint256",
        "name": "amount",
        "type": "uint256"
      }
    ],
    "name": "redeem",
    "outputs": [],
    "stateMutability": "view",
    "type": "function"
  }]
```

Click decode.

![](https://1161095600-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2Fl7wTwC5uXA2Yk5tvZMBg%2Fuploads%2FfhdrazMc78YTyTic2qaM%2F03-decoded-message-v1.png?alt=media\&token=753e601b-8f36-4113-a30a-87d09ef616c2)

Copy body to Input Data field and Click "Decode" again.

![](https://1161095600-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2Fl7wTwC5uXA2Yk5tvZMBg%2Fuploads%2FlkDaMyy3qqHI1cW5g1Ss%2F04-decoded-redeem-function.png?alt=media\&token=4e87c1b3-bfbc-4993-bc83-bffc9c771ddb)

In the result you can see script pubkey which can be converted to bitcoin address.
