ADD API Role - Discord

Hello everyone, I come to you because I can’t find the solution.

I have a PUT-like API that performs an action with my Discord/bot app.
This API adds a specific role in a guild and works perfectly if the data is written as shown in image 2.

On the other hand, as soon as I want the data to be recovered dynamically, I get an error (image 3) and it doesn’t work. However, I do retrieve the same type of data expected by the API. I even tried to enter the exact same value as image 2.

Any idea? Thank you for your help.



1 Like

Message error

I thought I had found the solution by changing the data type to text rather than the number, but I also get an error.

It’s not normal to get the role added by writing to the fields but not to get there if the data is retrieved dynamically.

Type need to stay empty because the API will only return 204 code.
Debug using step-by-step mode or LOGS to see what you are sending to API. The error is in your action, not in your API Connector because you was able to initialize it.
Question: did you save any of theses ID into a number field?

When I change the type to number, I don’t know why, the last 2 digits are changed and rounded up. So I opted for the text type. = Solution

I just added a Privacy Rule on one of the data that didn’t have one and it seems to work.

Thanks for trying to help me, I’ll tweak the workflow and add here if needed what I did.

This topic was automatically closed after 70 days. New replies are no longer allowed.