<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic Re: WebScriptRequest - how to know different verbs (POST, PUT, DELETE, GET) in Alfresco Forum</title>
    <link>https://connect.hyland.com/t5/alfresco-forum/webscriptrequest-how-to-know-different-verbs-post-put-delete-get/m-p/33069#M13993</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;1. We cannot get the verb (e.g. GET, POST etc.) from WebScriptRequest because, we cannot cast the&amp;nbsp;&lt;SPAN&gt;WebScriptRequest&amp;nbsp;to HttpRequest (it will throw runtime error).&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;2. None of the methods of WebScript request return the verb.&amp;nbsp;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;3. The header does not include the verb (which is obvious, but wanted to state it).&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;Is there anything that I put in descriptor, which will possibly return the verb from the&amp;nbsp;&lt;SPAN style="font-weight: 400;"&gt;&lt;STRONG&gt;WebScriptRequest, inside the execute method&lt;/STRONG&gt;&lt;SPAN&gt;&lt;STRONG&gt;&amp;nbsp;&lt;/STRONG&gt;?&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;My descriptor (xxxx.post.desc.xml loks like):&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;&amp;lt;webscript&amp;gt;&lt;BR /&gt;&amp;nbsp; &amp;nbsp;&amp;lt;shortname&amp;gt;&amp;lt;/shortname&amp;gt;&lt;BR /&gt;&lt;STRONG&gt;&amp;nbsp; &amp;nbsp;&amp;lt;description&amp;gt;??? Can I put anything here&amp;lt;/description&amp;gt;&lt;/STRONG&gt;&lt;BR /&gt;&amp;nbsp; &amp;nbsp;&amp;lt;url&amp;gt;/example/aNumber&amp;lt;/url&amp;gt; &lt;BR /&gt;&amp;nbsp; &amp;nbsp;&amp;lt;format default="json"&amp;gt;extension&amp;lt;/format&amp;gt;&lt;BR /&gt;&amp;nbsp; &amp;nbsp;&amp;lt;transaction&amp;gt;required&amp;lt;/transaction&amp;gt;&lt;BR /&gt; &amp;lt;authentication runas="admin"&amp;gt;none&amp;lt;/authentication&amp;gt;&lt;BR /&gt; &lt;BR /&gt; &amp;lt;/webscript&amp;gt;&lt;BR /&gt; &lt;/SPAN&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Tue, 13 Mar 2018 20:27:24 GMT</pubDate>
    <dc:creator>raghav</dc:creator>
    <dc:date>2018-03-13T20:27:24Z</dc:date>
    <item>
      <title>WebScriptRequest - how to know different verbs (POST, PUT, DELETE, GET)</title>
      <link>https://connect.hyland.com/t5/alfresco-forum/webscriptrequest-how-to-know-different-verbs-post-put-delete-get/m-p/33067#M13991</link>
      <description>Is there a way to know the verb (GET, POST, PUT, DELETE) inside the execute method of&amp;nbsp;AbstractWebScript? Does WebScriptRequest know anything about whether the call is a GET, or a PUT, or a POST, or a DELETE?I can always create another web script &amp;nbsp;(one for PUT, another for POST etc.).&amp;nbsp;I can also diff</description>
      <pubDate>Mon, 03 Apr 2017 19:46:15 GMT</pubDate>
      <guid>https://connect.hyland.com/t5/alfresco-forum/webscriptrequest-how-to-know-different-verbs-post-put-delete-get/m-p/33067#M13991</guid>
      <dc:creator>raghav</dc:creator>
      <dc:date>2017-04-03T19:46:15Z</dc:date>
    </item>
    <item>
      <title>Re: WebScriptRequest - how to know different verbs (POST, PUT, DELETE, GET)</title>
      <link>https://connect.hyland.com/t5/alfresco-forum/webscriptrequest-how-to-know-different-verbs-post-put-delete-get/m-p/33068#M13992</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Yes, you technically can get the verb from the description, which holds the method the web script was defined for. Since each web script inherently is associated to a single verb based on the bean name, you will typically only need to check the verb if you re-use the same implementation class for different web scripts, e.g. to build a dispatcher-like web script.&lt;/P&gt;&lt;P&gt;The web script request itself does not contain that information, though you could technically retrieve it from there as well via the reference to the HttpServletRequest - but that would require you to cast the request to one of the specific implementation classes and it is not guaranteed you will get the one implementation class that will allow you to access the servlet request.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 13 Apr 2017 15:47:33 GMT</pubDate>
      <guid>https://connect.hyland.com/t5/alfresco-forum/webscriptrequest-how-to-know-different-verbs-post-put-delete-get/m-p/33068#M13992</guid>
      <dc:creator>afaust</dc:creator>
      <dc:date>2017-04-13T15:47:33Z</dc:date>
    </item>
    <item>
      <title>Re: WebScriptRequest - how to know different verbs (POST, PUT, DELETE, GET)</title>
      <link>https://connect.hyland.com/t5/alfresco-forum/webscriptrequest-how-to-know-different-verbs-post-put-delete-get/m-p/33069#M13993</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;1. We cannot get the verb (e.g. GET, POST etc.) from WebScriptRequest because, we cannot cast the&amp;nbsp;&lt;SPAN&gt;WebScriptRequest&amp;nbsp;to HttpRequest (it will throw runtime error).&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;2. None of the methods of WebScript request return the verb.&amp;nbsp;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;3. The header does not include the verb (which is obvious, but wanted to state it).&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;Is there anything that I put in descriptor, which will possibly return the verb from the&amp;nbsp;&lt;SPAN style="font-weight: 400;"&gt;&lt;STRONG&gt;WebScriptRequest, inside the execute method&lt;/STRONG&gt;&lt;SPAN&gt;&lt;STRONG&gt;&amp;nbsp;&lt;/STRONG&gt;?&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;My descriptor (xxxx.post.desc.xml loks like):&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;&amp;lt;webscript&amp;gt;&lt;BR /&gt;&amp;nbsp; &amp;nbsp;&amp;lt;shortname&amp;gt;&amp;lt;/shortname&amp;gt;&lt;BR /&gt;&lt;STRONG&gt;&amp;nbsp; &amp;nbsp;&amp;lt;description&amp;gt;??? Can I put anything here&amp;lt;/description&amp;gt;&lt;/STRONG&gt;&lt;BR /&gt;&amp;nbsp; &amp;nbsp;&amp;lt;url&amp;gt;/example/aNumber&amp;lt;/url&amp;gt; &lt;BR /&gt;&amp;nbsp; &amp;nbsp;&amp;lt;format default="json"&amp;gt;extension&amp;lt;/format&amp;gt;&lt;BR /&gt;&amp;nbsp; &amp;nbsp;&amp;lt;transaction&amp;gt;required&amp;lt;/transaction&amp;gt;&lt;BR /&gt; &amp;lt;authentication runas="admin"&amp;gt;none&amp;lt;/authentication&amp;gt;&lt;BR /&gt; &lt;BR /&gt; &amp;lt;/webscript&amp;gt;&lt;BR /&gt; &lt;/SPAN&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 13 Mar 2018 20:27:24 GMT</pubDate>
      <guid>https://connect.hyland.com/t5/alfresco-forum/webscriptrequest-how-to-know-different-verbs-post-put-delete-get/m-p/33069#M13993</guid>
      <dc:creator>raghav</dc:creator>
      <dc:date>2018-03-13T20:27:24Z</dc:date>
    </item>
    <item>
      <title>Re: WebScriptRequest - how to know different verbs (POST, PUT, DELETE, GET)</title>
      <link>https://connect.hyland.com/t5/alfresco-forum/webscriptrequest-how-to-know-different-verbs-post-put-delete-get/m-p/33070#M13994</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;The WebScriptRequest sure does provide that information: request.getServiceMatch().getWebScript().getDescription().getMethod().&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 16 Mar 2018 08:40:28 GMT</pubDate>
      <guid>https://connect.hyland.com/t5/alfresco-forum/webscriptrequest-how-to-know-different-verbs-post-put-delete-get/m-p/33070#M13994</guid>
      <dc:creator>afaust</dc:creator>
      <dc:date>2018-03-16T08:40:28Z</dc:date>
    </item>
  </channel>
</rss>

