Hello, I am attempting to self manage oauth, I want to post a code state from client side to server side. The server action for this working great when I enter the code manually to test but I don’t understand how pass the code dynamically.
Hi @fdgfdgfdg, where are you getting the code value from?
If you want to send a variable from client-side to server-side, the best way I’ve found is with a server connect form. You can dynamically add your code value to the value of a hidden form field and submit that to the server for use as a POST variable.
Hi, the code is returned from authorisation url redirect back into my app.
Thanks for the tip about the form, since the code is automatic without user interaction to submit I used a get parameter and it worked fine.
I'm having another issue trying to exchange the code for an access token with snapchat. It works fine with postman, manually inserting the code I get from passed via the Wappler api action to my server.
Everything is the same, I can't figure it out why it doesnt work, maybe some parsing issue or how I am concatenating the get parameter at the end..
I tried to insert the returned scope data, it does the same so most likely an issue of how i’m constructing the token post url with code in Wappler … needs to be prepared differently.