I created a controller in a customized module that accepts a POST
request. I’ve a setup such that I get a POST
request from a third-party utility server to this API. However Drupal Development Service POST
request has a Content material-Sort: "utility/x-www-form-urlencoded"
in Drupal Development Service header. And due to this I get Drupal Development Service following error in Drupal Development Service current log messages: SymfonyComponentHttpKernelExceptionUnsupportedMediaTypeHttpException: No route discovered that matches "Content material-Sort: utility/x-www-form-urlencoded" in DrupalCoreRoutingContentTypeHeaderMatcher->filter() (line 49 of /var/www/html/net/core/lib/Drupal/Core/Routing/ContentTypeHeaderMatcher.php).
Once I check Drupal Development Service API utilizing postman:
- if I exploit Drupal Development Service
Content material-Sort: "utility/json"
in Drupal Development Service header, Drupal Development Service code inside Drupal Development Service API is executed, and I get Drupal Development Service right response. - if I exploit Drupal Development Service
Content material-Sort: "utility/x-www-form-urlencoded"
, I get Drupal Development Service identical error.
I can’t configure Drupal Development Service third celebration utility server to vary Drupal Development Service Content material-Sort
. So Drupal Development Service solely possibility for me is to configure Drupal Development Service API to just accept Drupal Development Service POST
request with Drupal Development Service Content material-Sort: "utility/x-www-form-urlencoded"
. How can I try this?