<?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>Liferay Invitation module integrate in Liferay Rest Module</title>
  <link rel="self" href="https://liferay.dev/c/message_boards/find_thread?p_l_id=119785294&amp;threadId=111608669" />
  <subtitle>Liferay Invitation module integrate in Liferay Rest Module</subtitle>
  <id>https://liferay.dev/c/message_boards/find_thread?p_l_id=119785294&amp;threadId=111608669</id>
  <updated>2026-04-07T09:39:09Z</updated>
  <dc:date>2026-04-07T09:39:09Z</dc:date>
  <entry>
    <title>RE: Liferay Invitation module integrate in Liferay Rest Module</title>
    <link rel="alternate" href="https://liferay.dev/c/message_boards/find_message?p_l_id=119785294&amp;messageId=111643722" />
    <author>
      <name>Andrew Jardine</name>
    </author>
    <id>https://liferay.dev/c/message_boards/find_message?p_l_id=119785294&amp;messageId=111643722</id>
    <updated>2018-11-22T18:52:40Z</updated>
    <published>2018-11-22T18:52:40Z</published>
    <summary type="html">&lt;p&gt;Hi Dipesh, &lt;/p&gt;
&lt;p&gt; &lt;/p&gt;
&lt;p&gt;Are you saying that you are trying to access the web module from your
  REST module? if you are, then I would say that is the wrong solution.
  You should instead be trying to access the api module (which will in
  turn use the service) to perform your operation. If that is what you
  are doing, but you can't call the api method because you need a
  ServiceContext, you have two options.&lt;/p&gt;
&lt;p&gt; &lt;/p&gt;
&lt;p&gt;1. Check to see if there is a method (or series of methods) that you
  can call that don't require the context object (though you probably
  already did this)&lt;/p&gt;
&lt;p&gt;2. Build the service context yourself&lt;/p&gt;
&lt;p&gt; &lt;/p&gt;
&lt;p&gt;The service context is just a helper class that caries a bunch of
  information to save you having to type out a million parameters. Not
  all the fields are necessarily populated, and even if the are, often
  onl;y a few of the actual fields are even used by the service. You
  sould be able to check the portal soource (service implementation) to
  see which fields are necessary and then build the service context yourself. &lt;/p&gt;</summary>
    <dc:creator>Andrew Jardine</dc:creator>
    <dc:date>2018-11-22T18:52:40Z</dc:date>
  </entry>
  <entry>
    <title>Liferay Invitation module integrate in Liferay Rest Module</title>
    <link rel="alternate" href="https://liferay.dev/c/message_boards/find_message?p_l_id=119785294&amp;messageId=111608668" />
    <author>
      <name>dipesh bhavsar</name>
    </author>
    <id>https://liferay.dev/c/message_boards/find_message?p_l_id=119785294&amp;messageId=111608668</id>
    <updated>2018-11-20T14:05:46Z</updated>
    <published>2018-11-20T14:05:46Z</published>
    <summary type="html">&lt;p&gt;We are trying to integrate liferay's
  &lt;strong&gt;com-liferay-invitation&lt;/strong&gt; module in my own custome Rest
  Module, for that i have added gradle&lt;br /&gt; depandancy in the rest module.&lt;/p&gt;
&lt;p&gt;So After the gradle build i am able to use the member invitation
  related classes and methods.&lt;/p&gt;
&lt;p&gt;
  &lt;strong&gt;https://github.com/liferay/com-liferay-invitation/blob/master/invitation-invite-members-web/src/main/java/com/liferay/invitation/invite/members/web/internal/portlet/InviteMembersPortlet.java&lt;/strong&gt;&lt;/p&gt;
&lt;p&gt;same way when i try to write the code for addMemberRequests i need a
  object of &lt;strong&gt;serviceContext &lt;/strong&gt;and in the serviceContext
  they pass the request object for portleturl, createAccountUrl etc parameter.&lt;/p&gt;
&lt;p&gt; &lt;/p&gt;
&lt;p&gt;So here my Question is in the Rest Module is there any way so i am
  able to access the http servlet or any other request.&lt;/p&gt;
&lt;p&gt; &lt;/p&gt;
&lt;p&gt; &lt;/p&gt;
&lt;p&gt;Thanks in advance&lt;/p&gt;</summary>
    <dc:creator>dipesh bhavsar</dc:creator>
    <dc:date>2018-11-20T14:05:46Z</dc:date>
  </entry>
</feed>
