Web service API

How to use PageSeeder's Web service API

list member memberships

/members/{member}/memberships [GET]

com.pageseeder.membership.ListMembershipsForMember

Description

Get the memberships for the member

Returns the list of group memberships for the given member.

Parameters

NameDescriptionRequiredTypeDefault value
archived Whether to return archived projects/groups only no boolean false
subgroups If subgroups should be included in the response no boolean true

Permission

Only the member herself or an administrator can invoke this service.

Response

The XML returned is:

<memberships>
  <member id="[member id]"
          firstname="[first name]"
          surname="[surname]"
          username="[username]"
          flags="[flags]"
          status="[activated|unactivated]">
    <fullname>[full name]</fullname>
  </member>
  <membership id="[membership id]"
              email-listed="[true|false]"
              notification="[notification]"
              flags="[flags]"
              status="normal"
              role="[role]"
             [subgroups="[subgroups]"]
             [created="[date]"]>
     <group|project id="[group id]"
                    name="[group name]"
                    description="[description]"
                    owner="[owner]"
                   [relatedurl="[url]"] />
      <details>
        <field position="1"
               name="[field name]"
               editable="[true|false]"
              [title="[field title]"]
              [type="[field type]"]>[field value]</field>
        ...
      </details>
   </membership>
   <membership status="invited" ...> ... </membership>
   ...
</memberships>

For example, if user Joan Smith belongs to group "acme-asia" and "acme-australia":

<memberships>
  <member id="123" firstname="Joan" surname="Smith" username="jsmith" status="activated">
    <fullname>Joan Smith</fullname>
  </member>
  <membership id="123" email-listed="true" notification="immediate"
      flags="e" status="normal" role="manager" created="2014-07-11T12:25:22+10:00">
    <group id="4" name="acme-asia" description="Demo group for Asia" />
     <details>
       <field position="1" name="organisation" title="Organisation" editable="true">ACME Asia</field>
       <field position="2" name="telephone"    title="Telephone"    editable="true">12345678</field>
       <field position="3" name="notes"        title="Notes"        editable="true">Follow up</field>
     </details>
  </membership>
  <membership id="987" email-listed="true" notification="immediate"
      flags="e" status="normal" role="manager">
    <group id="5" name="acme-australia" description="Demo group for Australia" />
  </membership>
</memberships>

Error handling

No specific errors expected for this service.

Created on , last edited on