# How to fetch a contract from dumlhub Ledger via Java

**URL:** <https://forum.canton.network/t/how-to-fetch-a-contract-from-dumlhub-ledger-via-java/4638>\
**Category:** App Development\
**Tags:** daml\
**Created:** [May 29, 2022, 4:27pm UTC](https://forum.canton.network/t/how-to-fetch-a-contract-from-dumlhub-ledger-via-java/4638 "2022-05-29T16:27:55Z")\
**Posts on this page:** 1\
**Showing post:** 20

<div class="post-metadata">

**Author:** ![Leonid\_Rozenberg](https://yyz2.discourse-cdn.com/flex034/user_avatar/forum.canton.network/leonid_rozenberg/32/48_2.png) [@Leonid\_Rozenberg](https://forum.canton.network/u/Leonid_Rozenberg)\
**Post date:** [June 2, 2022, 2:32am UTC](https://forum.canton.network/t/how-to-fetch-a-contract-from-dumlhub-ledger-via-java/4638/20 "2022-06-02T02:32:59Z")

</div>

@liav To correct @cocreature slightly, you have to ask hub to create a multiparty token for you, which you can do using the cli [damlhub-cli - npm](https://www.npmjs.com/package/damlhub-cli), please see

`damlhub-cli ledger multipartyToken`

With that token you can make `submitMulti` requests as those are natural requests via the LedgerAPI. The only wrinkle is that all of the parties that you aggregate into a single token must be **controlled** by the party that created the ledger; which I think is true in your case.

---

_[View the full topic](https://forum.canton.network/t/how-to-fetch-a-contract-from-dumlhub-ledger-via-java/4638)._
