Endpoints

Members

Members are at the centre of our company, and are the beating heart of what you do. The members API is orientated around allowing you to retrieve a list of users for your organisation or an organisation who's data you have access to. This is not a search API, but access to search can be provided on request. If you would like to have a webhook that is called on member creation/modification, please also reach out & we will be happy to oblige. All routes in the below API will require an API key in order to be successfully accessed.

Overview

When a user signs up & attends an event, or is created by you, we create a member document with all their information embedded within it. If they fill in a form, their answers are embedded into their document. When a postcode is added, we also add the relevant ward, LSOA, LAD etc. information to enable automatic geographic analysis of trends within your membership.

Members

GET

Retrieve a list of members.

Endpoint

https://app.plinth.org.uk/api/members

Query Parameters

Required: to retrieve a list of members per organisation, you will be required to provide the organisationId. This is for added security, we check that your API key can access this organisation as well as the member while only retrieving the data added to the member object for the given organisation.

{
  organisationId: 'organisation id token' //
}

Optional: In order to paginate through the member list, by default if these are not provided we will return the first page of results.

{
  limit: 100, // limit (max 250), number of members per page
  offset: 0, // offset (0, max n), index of start of page e.g. page 1 = 0, page 2 = previous offset.
}

Response Object

[
  members: [
    {
      "id": "345dfEgfLsdf34", // member id
      "email": "apiDoc@email.com",
      "name": "A. Example",
      "phone": "07123456789",
      "postcode": "AN1 EX2P",
      "created": "ISOstring date", // When this member was created
      "updated": "ISOstring date", // When this member was updated
      "deleted": "ISOstring date",  // Only present if this member was deleted
      "deletionDate": "ISOstring date", // Only present if this member was deleted
      "exists": true, // Quick check value for if this member exists
      "userCreated": "ISOstring date", // Date this member was created.
      "funderMemberId": "3123vcbfgjghLsdf34", // If a member joins through programme, we give them a per-programme Id for reporting & booking purposes.
      "managedBy": "345dfdhjkhwerfsdfLsdf34", // Organisation Id this member belongs to.
      // Demographic fields are added as a result of form questions or admins updating member profiles
      "demographics": {
        "ethnicity": "ETHNICITY",
        "gender": "Other",
        "dateOfBirth": "ISOstring date",
      },
      // Schema fields are added as a result of form questions or admins updating member profiles,
      // This is where the answers to questionaires are stored, if a user has answered multiple forms
      // with the same question we just auto-fill from here so they don't need to answer again.
      "schemaFields": {
        "Why did you come to use us": "answer",
      },
      // lat/lon geopoint -> we take the postcode and convert it into a geopoint as the member location
      "geopoint": {
        "lon": -0.067541,
        "lat": 51.6009,
      },
      // List of UK geographical codes built from user postcode -> Used mostly for geographic analysis
      "geoData": {
        // Census OA codes
        "oa11": "E00004175",
        "oa21": "E00004175",
        // Census LSOA codes
        "lsoa11": "E01000853",
        "lsoa21": "E01000853",
        // Electoral ward code
        "ward": "E05000129",
        "ward21": "E05000129",
        // LAD/UA code
        "laua": "E09000007",
        "laua21": "E09000007",
      },
      // Members can be tagged, this is the list that they were tagged with
      "tags": [
        "long-time attendar",
        "Into work graduate"
      ]
    }
  ],
  // Query parameters as well as total for calculating page boundaries.
  "offset": 0,
  "limit": 100,
  "total": 1000,
];

Members/:id

GET

Get the member with the given id

Endpoint

https://app.plinth.org.uk/api/members/:id

Query Parameters

Required: to retrieve a members of an organisation, you will be required to provide the organisationId. This is for added security, we check that your API key can access this organisation as well as the member while only retrieving the data added to the member object for the given organisation.

{
  organisationId: 'organisation id token' //
}

Response Object

The requested member

{
  "id": "345dfEgfLsdf34", // member id
  "email": "apiDoc@email.com",
  "name": "A. Example",
  "phone": "07123456789",
  "postcode": "AN1 EX2P",
  "created": "ISOstring date", // When this member was created
  "updated": "ISOstring date", // When this member was updated
  "deleted": "ISOstring date", // Only present if this member was deleted
  "deletionDate": "ISOstring date", // Only present if this member was deleted
  "exists": true, // Quick check value for if this member exists
  "userCreated": "ISOstring date", // Date this member was created.
  "funderMemberId": "3123vcbfgjghLsdf34", // If a member joins through programme, we give them a per-programme Id for reporting & booking purposes.
  "managedBy": "345dfdhjkhwerfsdfLsdf34", // Organisation Id this member belongs to.
  // Demographic fields are added as a result of form questions or admins updating member profiles
  "demographics": {
    "ethnicity": "ETHNICITY",
    "gender": "Other",
    "dateOfBirth": "ISOstring date"
  },
  // Schema fields are added as a result of form questions or admins updating member profiles,
  // This is where the answers to questionaires are stored, if a user has answered multiple forms
  // with the same question we just auto-fill from here so they don't need to answer again.
  "schemaFields": {
    "Why did you come to use us": "answer"
  },
  // lat/lon geopoint -> we take the postcode and convert it into a geopoint as the member location
  "geopoint": {
    "lon": -0.067541,
    "lat": 51.6009
  },
  // List of UK geographical codes built from user postcode -> Used mostly for geographic analysis
  "geoData": {
    // Census OA codes
    "oa11": "E00004175",
    "oa21": "E00004175",
    // Census LSOA codes
    "lsoa11": "E01000853",
    "lsoa21": "E01000853",
    // Electoral ward code
    "ward": "E05000129",
    "ward21": "E05000129",
    // LAD/UA code
    "laua": "E09000007",
    "laua21": "E09000007"
  },
  // Members can be tagged, this is the list that they were tagged with
  "tags": ["long-time attendar", "Into work graduate"]
}
Previous
Programmes