-1

`Hi , I was trying to call an IBM content service graphQL URL from my application with spring boot . But getting an exception as mentioned below

**Error Caused by: org.springframework.web.reactive.function.UnsupportedMediaTypeException: Content type 'text/plain;charset=ISO-8859-1' not supported for bodyType=com.DMS.GraphQLP8.graphQL.data.DocumentDTO at org.springframework.web.reactive.function.BodyExtractors.readWithMessageReaders(BodyExtractors.java:205) Suppressed: The stacktrace has been enhanced by Reactor, refer to additional information below: Error has been observed at the following site(s): *__checkpoint ⇢ Body from POST https://graphql-p8-dev.apps.osd01.atradiusnet.com/content-services-graphql/ [DefaultClientResponse] Error Observed

The code which i tried . `**- Calling URL ** the code tried , webclient code and expected response format created

Query which is send and expected response

Ammu
  • 1
  • Please, do not post images of text, but text directly. – dcolazin Aug 11 '23 at 14:54
  • It seems you are explicitly accepting a different mediatype than text/plain (APPLICATION_GRAPHQL_RESPONSE) – dcolazin Aug 11 '23 at 15:00
  • Does this answer your question? [org.springframework.web.reactive.function.UnsupportedMediaTypeException: Content type 'text/xml;charset=UTF-8' not supported for bodyType](https://stackoverflow.com/questions/57033268/org-springframework-web-reactive-function-unsupportedmediatypeexception-content) – dcolazin Aug 11 '23 at 15:02
  • will check this method and reply to you. I attached images because while adding text i got some issues related to formatting , so i added the images – Ammu Aug 14 '23 at 07:07

0 Answers0