MarkLogic Server 11.0 Product Documentation
rest:report-error

rest:report-error(
   $error as element()
) as element()

Summary

This function formats the specified error structure.

Parameters
error The error structure to be formatted.

Example

  xquery version "1.0-ml"; 
 
  import module namespace rest="http://marklogic.com/appservices/rest"
      at "/MarkLogic/appservices/utils/rest.xqy";

  try {
     let $params := rest:process-request($request)
     return
       ...the non-error case...
   } catch ($e) {
       rest:report-error($e)
   }

 
    
Powered by MarkLogic Server | Terms of Use | Privacy Policy