[OpenSIPS-Users] !rest_get behavior
Tito Cumpen
tito at xsvoce.com
Tue Jul 25 14:18:22 EDT 2017
Group
I am using the latest opensips 2.3 and I am wondering why a 404 response
doesn't invoke this block ?
if
(!rest_get("http://$avp(api)/cc/authorized/$fU/$rU",
"$json(authresponse)", "$var(ct)", "$var(rcode)")) {
xlog("Error code $var(rcode) in HTTP GET!\n");
xlog("on account of admittance error we are sending the call to the AS
server for processing");
route(ASroute);
}
the far end response looks like this.
HTTP/1.1 404 Not Found.
X-Powered-By: Express.
Vary: Origin, Accept-Encoding.
Access-Control-Allow-Credentials: true.
Content-Type: text/plain; charset=utf-8.
Content-Length: 9.
ETag: W/"9-nR6tc+Z4+i9RpwqTOwvwFw".
Date: Tue, 25 Jul 2017 18:11:39 GMT.
Connection: keep-alive.
.
Not Found
from the example it looks like other 4XX responses are considered.
Thanks,
Tito
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.opensips.org/pipermail/users/attachments/20170725/1c926a7a/attachment.html>
More information about the Users
mailing list