We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
I have integrated SwaggerWcf 0.2.15.0 in our WCF (SOAP + REST) application.
While most of the API seems to be exported without problems, there are three methods, which are not exported correctly.
[OperationContract] [WebGet] [SwaggerWcfTag("Camera")] CameraStatus GetCameraStatus(string cameraID); [OperationContract] [WebInvoke] [SwaggerWcfTag("Camera")] void SetUsedCameras(string[] cameraIDs); [OperationContract] [WebInvoke] [SwaggerWcfTag("Debug")] object[] GetData(string[] ids);
CameraStatus is an enum.
The endpoints are configured like this:
restEndpoint = this.serviceHost.AddServiceEndpoint(typeof(CoreCommunication.Contracts.ICamera), bindingWeb, "Rest/Camera"); restEndpoint.Behaviors.Add(new WebHttpBehavior() { DefaultOutgoingResponseFormat = System.ServiceModel.Web.WebMessageFormat.Json, DefaultBodyStyle = System.ServiceModel.Web.WebMessageBodyStyle.WrappedRequest });
For the first method the response references "#/definitions/Lap.CoreCommunication.Contracts.CameraStatus", but this type is not created.
For the second and third methods the responses are defined as array of "#/definitions/". This type is also missing.
The text was updated successfully, but these errors were encountered:
they are all Primitive Type, will be skipped.
Sorry, something went wrong.
The problem seems to be caused by setting the body style and format in WebHttpBehavior.
I have fixed the problem by settings BodyStyle, RequestFormat, and "ResponseFormat" in [WebInvoke] and [WebGet].
ok, when use WebMessageBodyStyle.Wrapped & RequestFormat = WebMessageFormat.Xml, be carefull about the namespace of the datacontract
No branches or pull requests
I have integrated SwaggerWcf 0.2.15.0 in our WCF (SOAP + REST) application.
While most of the API seems to be exported without problems, there are three methods, which are not exported correctly.
CameraStatus is an enum.
The endpoints are configured like this:
For the first method the response references "#/definitions/Lap.CoreCommunication.Contracts.CameraStatus", but this type is not created.
For the second and third methods the responses are defined as array of "#/definitions/". This type is also missing.
The text was updated successfully, but these errors were encountered: