Sure! I have this class (extending %JSON.Adaptor rather than using https://github.com/intersystems/isc-json would be almost as good):
Class pkg.isc.mcp.message.BaseRequest Extends (Ens.Request, %pkg.isc.json.adaptor)
{
/// This method is called by the Management Portal to determine
/// the content type that will be returned by the <method>%ShowContents</method>
/// Override to application/json for pkg.isc.mcp.types.BaseModel.cls extends both
/// %XML.Adaptor and %pkg.isc.json.adaptor but returns JSON
Method %GetContentType() As %String
{
Quit "application/json"
}
Storage Default
{
<Type>%Storage.Persistent</Type>
}
}With a subclass, pkg.isc.mcp.message.ToolCallRequest, that has a few more properties.
This shows up in the visual trace OOTB as:.png)
- Log in to post comments