Setting the output variable for a web service to return a byte array

When i create the output variable as an object and set its content type to byte through the webMethods developer 6.0.1, it does generate a WSDL with the output variable as follows:


So the type is set in the WSDL as “xsd:anyType” instead of byte array. This forces the consumers of my web service to explicitly cast the output object they receive, to a binary array.

Any ideas as to how to generate the output variable as a byte array instead of an object? Thanks much.

We got this to work. Convert the byte array to string. Using the pub.string:base64Encode service, encode the string. Define the output variable as a string and set the content type to be rendered as base64binary. This will do. Also we are using the SOAP RPC processor.