> For the complete documentation index, see [llms.txt](https://polkasafe.gitbook.io/polkasafe-sdk/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://polkasafe.gitbook.io/polkasafe-sdk/guides-and-tutorials/cancel-transaction.md).

# Cancel Transaction

Developers can utilize the SDK to cancel a pending transaction within a multisig wallet. This feature provides flexibility and control over the transaction lifecycle.

> Note: Only the creator of a transaction can cancel it.

```typescript
const multisigAddress = '...'; 
const callHash = '...' // trasaction callHash

// A function that takes a single parameter.
const eventGrabber = (message)=>{
    // use message to track transaction progress and events using eventGrabber for real-time visibility
    console.log(message)
}

const { data, error } = await client.cancelTransaction(multisigAddress, callHash, eventGrabber);

if (data){
    console.log(data)
    // use your data
}
else if(error){
    console.log(error)
}
```

#### Response Data

```json
{
    "status":200,
    "message":"Transaction Cancel Successful"
}
```

[Generic Error](/polkasafe-sdk/guides-and-tutorials/generic-errors.md)
