gs.search.people

Author:Michael JasonSmith
Contact:Michael JasonSmith <mpj17@onlinegroups.net>
Date:2015-06-19
Organization:GroupServer.org
Copyright:This document is licensed under a Creative Commons Attribution-Share Alike 4.0 International License by OnlineGroups.net.

This product provides the page that allows the site administrator to search the members of a GroupServer site, and a web hook to allow external systems to search for someone.

Contents:

Page

The form admin_search_people.html, in the context of the site, allows the site administrator to search for a site member. If found the administrator is redirected to the profile-page for that person, otherwise an error is shown.

Note

The page is restricted to site members for privacy reasons.

The viewlet gs-search-people-link provides a link from the site-administration links [1] to the Search for people page.

Web hook

Synopsis

/gs-search-people.json? token =<t> & user =<u> & search

Description

The web hook gs-search-people.json, in the site context, allows external systems to search for a person.

Required arguments

token=<token>

The authentication token [1].

user=<emailOrId>

Either

  • An email address belonging to the person, or
  • The user-identifier for the person.

The “form” action (no value needs to be set, but the argument must be present).

Note

Unlike the page (see Page) the web hook searches all people that have a profile, regardless of their site membership. This can disclose a lot of information, so the data should be used cautiously.

Return value

If no profile was found then an empty JSON object is returned ({}) . Otherwise a JSON object is returned with the standard user-property values set (see the core web-hook documentation).

Example

Using wget to retrieve the profile information for someone with the email address a.person@home.example.com from the web-hook at groups.example.com:

$ wget --post-data='token=fake&user=a.person@home.example.com&search' \
  http://groups.example.com/gs-search-people.json

The returned JSON object:

{
  "id": "qK7SgjsTHcLNrJ2ClevcJ0",
  "name": "A. Person",
  "url": "https:/groups.example.com//p/qK7SgjsTHcLNrJ2ClevcJ0",
  "email": {
    "all": [
      "a.person@home.example.com",
      "a.person@work.example.com"
    ],
    "other": [
      "a.person@work.example.com"
    ],
    "preferred": [
      "a.person@home.example.com"
    ],
    "unverified": []
  }
  "groups": [
    "example",
    "test"
  ],
}
[1]See gs.auth.token for more information <https://github.com/groupserver/gs.auth.token>

Changelog

2.2.0 (2015-06-19)

  • Adding the gs-search-people.json web-hook
  • Adding Sphinx documentation

2.1.1 (2015-03-12)

2.1.0 (2014-10-24)

2.0.1 (2014-06-12)

  • Following the gs.content.form.base code

2.0.0 (2013-07-23)

  • Updating to the new UI

1.1.0 (2012-07-23)

  • Removing an adaptor

1.0.1 (2012-06-22)

  • Update because of the change to SQLalchemy

1.0.0 (2012-03-02)

  • Initial version

Indices and tables