Page 1 of 1

Feature request: Make /tool fetch compatible with HTTP/HTTPS POST/PUT/PATCH methods

Posted: Wed May 18, 2016 12:08 am
by Lukasz032
At present, the only thing I can do using /tool fetch command is to make a GET call over HTTP/HTTPS or transfer files using FTP/TFTP. This tool is lacking a proper support for POST, PUT and PATCH methods over HTTP/HTTPS, which is problematic mainly because of it's impossible to do things the right way, like i.e. sending logfiles over HTTP PUT to a remote server.

There is also a more reasonable reason to implement this feature. As you can read, CloudFlare has deprecated their "normal" API calls used to set parameters like IP address on their hosted (D)DNS service. After November 9, all the RBs will be unable to update their records, which will affect dynamic IP users running webservers over their links. The only way to update the records will be to issue a HTTPS PUT or PATCH call with the new address, not a GET one.

Screw all the REST thing, but in my opinion, this will be a very desirable feature and it would simplify some scripting on RBs.

Re: Feature request: Make /tool fetch compatible with HTTP/HTTPS POST/PUT/PATCH methods

Posted: Fri Nov 04, 2016 12:49 pm
by Tinuva
Also would like this.

Sadly no more DynDNS with CloudFlare :(

Re: Feature request: Make /tool fetch compatible with HTTP/HTTPS POST/PUT/PATCH methods

Posted: Fri Nov 04, 2016 2:36 pm
by savage
dst-path=/dev/null would also be very nice considering we're talking about fetch...

There's very few (none?) methods to test speeds from an ACTUAL mikrotik, that is compatible with the rest of the world... A simple HTTP download, bypassing the slow storage disks, may be a good start.

Asking for something like netperf in MT would more than likely be too much :lol:

Re: Feature request: Make /tool fetch compatible with HTTP/HTTPS POST/PUT/PATCH methods

Posted: Sat Nov 05, 2016 1:49 pm
by boen_robot
dst-path=/dev/null would also be very nice considering we're talking about fetch...
That one is already doable with 'keep-result=no'.

Re: Feature request: Make /tool fetch compatible with HTTP/HTTPS POST/PUT/PATCH methods

Posted: Wed Sep 13, 2017 4:53 am
by Lukasz032
For now, I've developed a substitute, temporary solution: change the update URL to this: http://ldev.pl/cloudflare_updater.php with the same parameters as in the previous API. It just repacks the request payload into a "new" format and sends it to Cloudflare. Besides, it isn't an ideal solution since it relies on an external server, but for now it's working :)

Re: Feature request: Make /tool fetch compatible with HTTP/HTTPS POST/PUT/PATCH methods

Posted: Wed Sep 20, 2017 6:27 pm
by Paxy
Custom headers for /tool fetch too.

Re: Feature request: Make /tool fetch compatible with HTTP/HTTPS POST/PUT/PATCH methods

Posted: Fri Sep 22, 2017 11:36 am
by Cha0s
Or just replace fetch with cURL and almost everyone will be happier :)

Re: Feature request: Make /tool fetch compatible with HTTP/HTTPS POST/PUT/PATCH methods

Posted: Mon Sep 25, 2017 4:43 pm
by eriitguy
Hello!

May be related to the compatibility: tool fetch - 2xx HTTP response codes

Thank you!