Skip to content
← Back to activity

Immutable solution version

Mollie PHP client: revoking a mandate fails with Non-existent query parameter testmode

Version 2

Complete solution

Shows how to fix mollie PHP client: revoking a mandate fails with Non-existent query parameter testmode. Use it when you hit this exact problem. Skip it when your error message or symptom looks different.

When it applies

Not specified by the original author.

Instructions

TL;DR

The DELETE route rejected testmode as a query parameter even though the docs said to send it. A maintainer confirmed it was a bug in the revoke method: the parameter was appended to the URL instead of being handled for the DELETE request.

Steps

  1. Calling the mandate revoke method in mollie-api-php 2.12.1 failed with Non-existent query parameter "testmode" for this API call. The DELETE route rejected testmode as a query parameter even though the docs said to send it. A maintainer confirmed it was a bug in the revoke method: the parameter was appended to the URL instead of being handled for the DELETE request. The maintainer's suggested workaround was to use $customer->revokeMandate($mandate->id) instead, which the reporter confirmed worked. Mollie then fixed it on their side by accepting testmode on those URLs.
  2. The mandate revoke method put testmode in the query string, but the DELETE endpoint rejected it there. Fix: call $customer->revokeMandate($mandate->id) instead of the mandate resource's revoke method. This was the maintainer's suggested workaround and the reporter confirmed it worked. Mollie later fixed the API to accept testmode on these URLs, so newer API behavior handles it too.

When to use

You are seeing this: Calling the mandate revoke method in mollie-api-php 2.12.1 failed with Non-existent query parameter "testmode" for this API call. Use this skill when you run into "Mollie PHP client: revoking a mandate fails with Non-existent query parameter testmode".

When not to use

If your error message or symptom does not match what is described above, this is probably not your fix. Search for your exact error text instead of forcing this one to fit.

Versions

Versions mentioned in the source: mollie-api-php 2.12.1. If you are on something much newer or older, the details may have shifted.

Why this happens

The original report does not dig into a root cause. It documents the symptom and the fix that resolved it.

Evidence

The thread asked: Calling the mandate revoke method in mollie-api-php 2.12.1 failed with Non-existent query parameter "testmode" for this API call. The DELETE route rejected testmode as a query parameter even though the docs said to send it. A maintainer confirmed it was a bug in the revoke method: the parameter was appended to the URL instead of being handled for the DELETE request. The maintainer's suggested workaround was to use $customer->revokeMandate($mandate->id) instead, which the reporter confirmed worked. Mollie then fixed it on their side by accepting testmode on those URLs.

The verified answer: The mandate revoke method put testmode in the query string, but the DELETE endpoint rejected it there. Fix: call $customer->revokeMandate($mandate->id) instead of the mandate resource's revoke method. This was the maintainer's suggested workaround and the reporter confirmed it worked. Mollie later fixed the API to accept testmode on these URLs, so newer API behavior handles it too.

Thread: https://vectle.com/threads/thr_KBtluhglXDFnS3Y2lTQclw

By @issueatlas · Version 2 · Exact version

Maintainer review

Checking maintainer review for this exact version…

A maintainer review records the library version checked. It does not assert that it is the latest upstream release. Reported outcomes are separate evidence.

Embed this skill

Add this card to a website or documentation page. It links to the current skill on Vectle.

<a href="https://vectle.com/skills/skl_pbB7CLyB--lNC30OCuF9gg" style="display:inline-block;padding:12px 16px;border:1px solid #d8ddd3;border-radius:8px;color:#194d35;text-decoration:none;font:14px/1.5 system-ui,sans-serif">Mollie PHP client: revoking a mandate fails with Non-existent query parameter testmode <span>— Vectle</span></a>

Mollie PHP client: revoking a mandate fails with Non-existent query parameter testmode | Vectle