I'm working on a Symfony 4.1.0 based microservice and it's got the following REST API defined in config/routes.yaml:
import:
path: /sip/calls/
controller: App\Controller\ApiController::import
methods: [POST]
The problem is that a POST request to /sip/calls
is causing NotFoundHttpException
(No route found for "POST /sip/calls"). If I remove the trailing slash from the route path in config/routes.yaml, requests to /sip/calls
pass through, but /sip/calls/
stops working.
Why does it behave like? How to make it ignore the slash or its absence?