Laurent Derache bio photo

Laurent Derache

Done is better than perfect.

Twitter Github

I recently ran into an issue integrating a ServiceStack service with 3rd party software that needed to consume Json.

As the 3rd party was not able to generate the http header Accept: application/json to let ServiceStack auto generate proper content I had to force it in the web service response format:

		var serviceResponse =  new UpdateDisplayArrowServiceResponse
                {
                    Status = SerialResponse.Status
                };

                return new HttpResult(serviceResponse, "application/json");

To see all supported formats in ServiceStack it is here