# Why is there no \`submitUserMustFail\`?

**URL:** <https://forum.canton.network/t/why-is-there-no-submitusermustfail/4978>\
**Category:** App Development\
**Tags:** daml-script\
**Created:** [July 26, 2022, 1:30pm UTC](https://forum.canton.network/t/why-is-there-no-submitusermustfail/4978 "2022-07-26T13:30:58Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![Darko](https://yyz2.discourse-cdn.com/flex034/user_avatar/forum.canton.network/darko/32/42_2.png) [@Darko](https://forum.canton.network/u/Darko)\
**Post date:** [July 26, 2022, 1:30pm UTC](https://forum.canton.network/t/why-is-there-no-submitusermustfail/4978/1 "2022-07-26T13:30:58Z")

</div>

Is there a particular reason why not all party submission functions also exist for users?  
(For example `submitUserMustFail`)

When it comes to `submitMulti` I’m assuming that the argument would be to just add the additional actAs/readAs parties to the user, but I don’t see an easy workaround for `..MustFail`, except to use

```haskell
(fromSome myUser.primaryParty) `submitMustFail` ...

```

---

<div class="post-metadata">

**Author:** ![Darko](https://yyz2.discourse-cdn.com/flex034/user_avatar/forum.canton.network/darko/32/42_2.png) [@Darko](https://forum.canton.network/u/Darko)\
**Post date:** [July 26, 2022, 1:35pm UTC](https://forum.canton.network/t/why-is-there-no-submitusermustfail/4978/2 "2022-07-26T13:35:37Z")

</div>

The same question also holds for queries

---

<div class="post-metadata">

**Author:** ![cocreature](https://yyz2.discourse-cdn.com/flex034/user_avatar/forum.canton.network/cocreature/32/36_2.png) [@cocreature](https://forum.canton.network/u/cocreature)\
**Post date:** [July 26, 2022, 1:57pm UTC](https://forum.canton.network/t/why-is-there-no-submitusermustfail/4978/3 "2022-07-26T13:57:48Z")

</div>

There is no good reason, we just started with the minimal API. However, `submitUser` is just a wrapper, you can see the definition in the [code](https://github.com/digital-asset/daml/blob/74b7878d6ec77080681f09310e299f54ea752371/daml-script/daml/Daml/Script.daml#L953).

You can relatively easily define your own wrapper for `submitMultiMustFail`:

```haskell
submitUserMustFail : HasCallStack => UserId -> Commands a -> Script ()
submitUserMustFail userId cmds = do
  rights <- listUserRights userId
  let actAs = [p | CanActAs p <- rights]
  let readAs = [p | CanReadAs p <- rights]
  submitMultiMustFail actAs readAs cmds

```
