Invision Community 4: SEO, prepare for v5 and dormant account notifications Matt November 11, 2024Nov 11
Posted November 8, 20168 yr I am not sure how to send the API key and data to the post API request. I have tried making a forum and sending it to the API method that calls for a post request. <form action="/api/forums/topics" method="post"> <input type="hidden" name="key" value="XXXXXXXXXXX"> <input type="text" name="forum"><br /> <input type="text" name="author"><br /> <input type="text" name="title"><br /> <input type="text" name="post"><br /> <input type="submit" name="submit" value="Submit"> </form>
November 9, 20168 yr On 11/7/2016 at 6:47 PM, Ryan Carr said: I am not sure how to send the API key and data to the post API request. I have tried making a forum and sending it to the API method that calls for a post request. <form action="/api/forums/topics" method="post"> <input type="hidden" name="key" value="XXXXXXXXXXX"> <input type="text" name="forum"><br /> <input type="text" name="author"><br /> <input type="text" name="title"><br /> <input type="text" name="post"><br /> <input type="submit" name="submit" value="Submit"> </form> Point the form at a local controller(php file) that uses the API to actually create the post, and remove the 'key' as an input. Never, ever, evereverever reveal your API key in visible code like that, it opens it up to abuse. One page inspection with debug tools is all one requires to obtain the API key with the form like that.
Archived
This topic is now archived and is closed to further replies.