# Serialize an unsigned transaction

**URL:** <https://forums.sui.io/t/serialize-an-unsigned-transaction/45591>\
**Category:** SDK\
**Created:** [May 17, 2024, 12:02pm UTC](https://forums.sui.io/t/serialize-an-unsigned-transaction/45591 "2024-05-17T12:02:24Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![dimakogan](https://avatars.discourse-cdn.com/v4/letter/d/e0b2c6/32.png) [@dimakogan](https://forums.sui.io/u/dimakogan)\
**Post date:** [May 17, 2024, 12:02pm UTC](https://forums.sui.io/t/serialize-an-unsigned-transaction/45591/1 "2024-05-17T12:02:24Z")

</div>

Hi all,

Is there a standard way to serialize an unsigned transaction (such that it is supported in Python/TS/Rust SDKs). A few things I considered, but didn’t quite work:

- In the TS SDK, calling `build` to get the BCS representation requires (TransactionBlock.ts#L524) the transaction to be “fully prepared” (all objects resolved, etc.), which I’d rather avoid, since I want to capture the transaction in its original form (for example, as it’s passed from a dApp to a Wallet).
- The TS SDK also supports a custom serialization (TransactionBlock.ts#L484), but that seems to be TS-specific and is not compatible with other languages.

I’d be happy if anyone has a suggestion?

Best,  
Dima

---

<div class="post-metadata">

**Author:** ![kristaki90](https://dub1.discourse-cdn.com/sui/user_avatar/forums.sui.io/kristaki90/32/30483_2.png) [@kristaki90](https://forums.sui.io/u/kristaki90)\
**Post date:** [June 4, 2024, 8:00am UTC](https://forums.sui.io/t/serialize-an-unsigned-transaction/45591/3 "2024-06-04T08:00:39Z")

</div>

Hi @dimakogan Transactions can be serialized by calling `tx.toJSON()` on the transaction instance.
