<?xml version="1.0" encoding="UTF-8"?>
<feed xmlns="http://www.w3.org/2005/Atom" xmlns:dc="http://purl.org/dc/elements/1.1/">
  <title>Can we design different response code for the rest builder</title>
  <link rel="self" href="https://liferay.dev/c/message_boards/find_thread?p_l_id=119785294&amp;threadId=121411046" />
  <subtitle>Can we design different response code for the rest builder</subtitle>
  <id>https://liferay.dev/c/message_boards/find_thread?p_l_id=119785294&amp;threadId=121411046</id>
  <updated>2026-04-05T10:34:51Z</updated>
  <dc:date>2026-04-05T10:34:51Z</dc:date>
  <entry>
    <title>Can we design different response code for the rest builder</title>
    <link rel="alternate" href="https://liferay.dev/c/message_boards/find_message?p_l_id=119785294&amp;messageId=121411045" />
    <author>
      <name>Bhargav Vaghasiya</name>
    </author>
    <id>https://liferay.dev/c/message_boards/find_message?p_l_id=119785294&amp;messageId=121411045</id>
    <updated>2022-04-28T15:44:36Z</updated>
    <published>2022-04-28T10:40:04Z</published>
    <summary type="html">&lt;p&gt;Hello,&lt;/p&gt;
&lt;p&gt;I am using the rest builder template for my application.&lt;/p&gt;
&lt;p&gt;I want to design different error codes (like 500, 501, 502...)&lt;/p&gt;
&lt;blockquote&gt;
  &lt;p&gt;responses:&lt;br /&gt;         200:&lt;br /&gt;           description:
    &amp;quot;&amp;quot;&lt;br /&gt;           content:&lt;br /&gt;            
    application/json:&lt;br /&gt;               schema:&lt;br /&gt;                
      $ref:
    &amp;quot;#/components/schemas/GetWebInformationBoxes&amp;quot;&lt;br /&gt;      
          application/xml:&lt;br /&gt;               schema:&lt;br /&gt;            
          $ref:
    &amp;quot;#/components/schemas/GetWebInformationBoxes&amp;quot;&lt;br /&gt;      
      500:&lt;br /&gt;           description: &amp;quot;&amp;quot;&lt;br /&gt;          
    content:&lt;br /&gt;             application/json:&lt;br /&gt;              
    schema:&lt;br /&gt;                   $ref:
    &amp;quot;#/components/schemas/error500&amp;quot;&lt;br /&gt;            
    application/xml:&lt;br /&gt;               schema:&lt;br /&gt;                  
    $ref: &amp;quot;#/components/schemas/error500&amp;quot;&lt;/p&gt;&lt;/blockquote&gt;
&lt;p&gt;But I am not able to achieve this.&lt;/p&gt;
&lt;p&gt;Is it possible with the Liferay to do this? let me know if we can do
  any customization for this.&lt;/p&gt;
&lt;p&gt;Thank you in Advance&lt;/p&gt;</summary>
    <dc:creator>Bhargav Vaghasiya</dc:creator>
    <dc:date>2022-04-28T10:40:04Z</dc:date>
  </entry>
</feed>
