# Error when canceling an item of a MassPayment

**URL:** <https://discuss.dwolla.com/t/error-when-canceling-an-item-of-a-masspayment/5639>\
**Category:** API Support\
**Created:** [April 3, 2020, 8:44pm UTC](https://discuss.dwolla.com/t/error-when-canceling-an-item-of-a-masspayment/5639 "2020-04-03T20:44:55Z")\
**Posts on this page:** 6\
**Page:** 1

<div class="post-metadata">

**Author:** ![matheustex](https://avatars.discourse-cdn.com/v4/letter/m/e99b99/32.png) [@matheustex](https://discuss.dwolla.com/u/matheustex)\
**Post date:** [April 3, 2020, 8:44pm UTC](https://discuss.dwolla.com/t/error-when-canceling-an-item-of-a-masspayment/5639/1 "2020-04-03T20:44:55Z")

</div>

Hello,

I’m facing a weird problem that I couldn’t identify the cause but I believe it’s a bug.

When I create a Mass Payment with N Items, I’m able to cancel all items but the last one always fails. I’m seeing the link to cancel so it’s because I should be able to do it. I created the same Mass Payment multiple times and every payment I can cancel but not when the payment is the last one.

Any ideas?  
The payment returns the cancel link so I’m in the right time to cancel it and sending the right status to do that.

Thanks!

---

<div class="post-metadata">

**Author:** ![matheustex](https://avatars.discourse-cdn.com/v4/letter/m/e99b99/32.png) [@matheustex](https://discuss.dwolla.com/u/matheustex)\
**Post date:** [April 3, 2020, 8:47pm UTC](https://discuss.dwolla.com/t/error-when-canceling-an-item-of-a-masspayment/5639/3 "2020-04-03T20:47:34Z")

</div>

“Error: {“code”:“ValidationError”,“message”:“Validation error(s) present. See embedded errors list for more details.”,”\_embedded":{“errors”:[{“code”:“NotAllowed”,“message”:“Status not allowed.”,“path”:"/status","\_links":{}}]}}",

---

<div class="post-metadata">

**Author:** ![spencer](https://sea2.discourse-cdn.com/dwolla/user_avatar/discuss.dwolla.com/spencer/32/2143_2.png) [@spencer](https://discuss.dwolla.com/u/spencer)\
**Post date:** [April 3, 2020, 9:43pm UTC](https://discuss.dwolla.com/t/error-when-canceling-an-item-of-a-masspayment/5639/4 "2020-04-03T21:43:56Z")

</div>

Hi @matheustex, do you have an example Mass Payment ID or Transfer ID for the payment you’re attempting to cancel?

---

<div class="post-metadata">

**Author:** ![matheustex](https://avatars.discourse-cdn.com/v4/letter/m/e99b99/32.png) [@matheustex](https://discuss.dwolla.com/u/matheustex)\
**Post date:** [April 6, 2020, 8:02pm UTC](https://discuss.dwolla.com/t/error-when-canceling-an-item-of-a-masspayment/5639/5 "2020-04-06T20:02:46Z")

</div>

Right,

I just created a new one with the same problem

MassPaymentId : 5d60ad3e-4b69-4089-a14c-ab9501469aac

I canceled the first two and left this one which is failing

TransferId: ab2839ad-3f78-ea11-8122-8a922a24160f

---

<div class="post-metadata">

**Author:** ![spencer](https://sea2.discourse-cdn.com/dwolla/user_avatar/discuss.dwolla.com/spencer/32/2143_2.png) [@spencer](https://discuss.dwolla.com/u/spencer)\
**Post date:** [April 8, 2020, 1:33pm UTC](https://discuss.dwolla.com/t/error-when-canceling-an-item-of-a-masspayment/5639/6 "2020-04-08T13:33:10Z")

</div>

hmm, I’m wondering if it is related to the `R01` sentinel value that’s being used on the source funding source. Would you be able to update that name to something else and retry this same flow of creation and cancellation?

---

<div class="post-metadata">

**Author:** ![matheustex](https://avatars.discourse-cdn.com/v4/letter/m/e99b99/32.png) [@matheustex](https://discuss.dwolla.com/u/matheustex)\
**Post date:** [April 9, 2020, 2:03pm UTC](https://discuss.dwolla.com/t/error-when-canceling-an-item-of-a-masspayment/5639/7 "2020-04-09T14:03:57Z")

</div>

Right, I tried in a different source without sentinel values and found the same problem.

Mass Payment:  
0f455911-ea32-4750-a354-ab9800e5e89d

Transfers:  
7133b708-6a7a-ea11-8122-8a922a24160f  
677b3e02-6a7a-ea11-8122-8a922a24160f

The second fails, the one I left for last.
