Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Error encountered when passing parameters to get Balance Transactions #349

Closed
palakraina opened this issue Jul 19, 2024 · 5 comments · Fixed by #351
Closed

Error encountered when passing parameters to get Balance Transactions #349

palakraina opened this issue Jul 19, 2024 · 5 comments · Fixed by #351

Comments

@palakraina
Copy link

palakraina commented Jul 19, 2024

Hi,
In order to get balance transactions with the following code:

balance_obj = self.__mollie_client.balances.get('bal_XXXXXX')
params = {
                        'from': 'baltr_XXX',
                        'sort': "asc",
                        'limit': 10
                    }
balance_transactions = balance_obj.get_transactions(**params)

It errors out mollie.api.error.UnprocessableEntityError: Non-existent query parameter "params.from" for this API call. Did you mean: "from"?
The error is the same even if we pass one param or any individual param standalone as well.

Note: There is no error without passing params. The below works:

balance_transactions = balance_obj.get_transactions()
@maria-swierblewska
Copy link

@geertjanvdenbosch could somebody look into this one as soon as possible?

@maria-swierblewska
Copy link

@palakraina you are trying to retrieve a list of balance transactions from this endpoint, correct? If yes, you would need to change the method from get to list, can you check if this is resolving the error?

@palakraina
Copy link
Author

Hi @maria-swierblewska I had tried that but its giving error Balance' object has no attribute 'list_transactions

balance_transactions = balance_obj.list_transactions()

or even

balance_transactions = balance_obj.list()

These doesn't exist. Also, looking at the source code get_transactions seems to be the method to use - which works but doesn't work with params

@geertjanvdenbosch
Copy link
Collaborator

Hi @palakraina,

We've just released version 3.6.1 (https://github.com/mollie/mollie-api-python/releases/tag/3.6.1), this release fixes the params issue.

@palakraina
Copy link
Author

Hi @geertjanvdenbosch ,
Thanks for the fix! I updated the package and validated it. It works.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
3 participants