Loading TOC...

MarkLogic 10 Product Documentation
rest:check-request

rest:check-request(
   $options as element(rest:request)
) as element(rest:report)?

Summary

This function takes a request element and returns a report of the problems found. If this function does not return an empty sequence, you have made a mistake and the library will not perform reliably.

Parameters
options The options node that defines the request.

Example

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

  rest:check-request(
    <request uri="^/(.+)$" 
             endpoint="/endpoint.xqy" 
             xmlns="http://marklogic.com/appservices/rest">
      <uri-param name="play">$1.xml</uri-param>
    </request>)
    

Stack Overflow iconStack Overflow: Get the most useful answers to questions from the MarkLogic community, or ask your own question.