Person

model.AddRole(query, role)
Parameters:
  • query (str) – see The Query Parameter
  • role (str) – The name of the role to be added to the persons in the query.

If a user does not exist, the user will be created. The user will have to use forgot password to be emailed a link to set their password. The role itself must exist, prior to calling this method.

The following roles will not be allowed: admin, manageapplication, backgroundcheck, creditcheck, delete, developer, finance, financeadmin, manager, manager2, membership, managetransactions, memberdocs,

model.AddTag(query, tagName, ownerId)
Parameters:
  • query (str) – see The Query Parameter
  • tagName (str) – the name of the tag.
  • ownerId (str) – the PeopleId for the owner of the tag.

The tag will be added to if it already exists.

model.AgeInMonths(birthdate, asof)

:param date birthdate : The birthdate. :param date asof: The as of date.

This will return the age in months given the two dates. Fractional months are not considered.

model.CreateTaskNote(ownerId, aboutPersonId, assigneeId, roleId, isNote, instructions, notes, dueDate, keywordIdList)
Parameters:
  • ownerId (int) – PeopleId of the person who owns the Task. This is a required field.
  • aboutPersonId (int) – PeopleId of the person the Task is about. This is a required field.
  • assigneeId (int) – PeopleId of the person the Task is assigned to. This is an optional field.
  • roleId (int) – RoleId of the Role you want to limit the Task or Note to. This is an optional field.
  • isNote (str) – Boolean. This will either take a 1 or 0, depending on true or false, or a “True” or “False.” This field is for telling the api how to save this Task or Note.
  • instructions (str) – String, for a Task or Note.
  • notes (str) – String, for a Task or Note.
  • dueDate (date) – Due date for the Task. This is an optional field.
  • keywordIdList (list) – List of the KeywordIds that you want to assign to the Task or Note. This is an optional field. These are the acceptable formats: [1,2,3,4,5] or (1,2,3,4,5) or {[1],[2],[3],[4],[5]}

A Task will be created for the minister (lay or staff person). This person must be a User, i.e. have an account to login with. The Task is a ministerial Task, presumably to contact the person the Task is about.

An email will be sent to the minister with a link to complete the Task with a Note record.

model.PeopleIds(query)
Returns:a list of PeopleIds from a query
Return type:an enumerable list of int
Parameters:query (str) – See The Query Parameter

Example:

pids = model.PeopleIds("")
for pid in pids:
    p = model.GetPerson(pid)
    print p.Name
model.RemoveRole(query, role)
Parameters:
  • query (str) – see The Query Parameter
  • role (str) – The name of the role to be removed from the persons in the query.
model.UpdateCampus(query, campus)
Parameters:
  • query (str) – see The Query Parameter
  • campus (int,str) – The CampusId or the campus name (use exact spelling to match an existing campus)
model.UpdateMemberStatus(query, status)
Parameters:
  • query (str) – see The Query Parameter
  • status (int,str) – The MemberStatusId or the member status description (use exact spelling to match existing status)
model.UpdateNamedField(query, field, value)
Parameters:
  • query (str) – see The Query Parameter
  • field (str) – The name of the field to update. See Person Object
  • campus (int,str) – The CampusId or the campus name (use exact spelling to match an existing campus)
model.UpdateNewMemberClassDate(query, date)
Parameters:
model.UpdateNewMemberClassDateIfNullForLastAttended(query, orgid)
Parameters:
  • query (str) – see The Query Parameter
  • orgid (str) – The OrganizationId for the last attend meeting

This will find the most recent attended date for each person in the specified Organization and update the person’s NewMemberClassDate with that date.

model.UpdateNewMemberClassStatus(query, status)
Parameters:
  • query (str) – see The Query Parameter
  • status (int,str) – The NewMemberClassStatusId or the new member class status description (use exact spelling to match existing status)
model.UpdateContributionOption(query, option)
Parameters:
  • query (str) – see The Query Parameter
  • option (int,str) – The Id of the option or the full name of the option as indicated in the table below

This determines what type of statement a person wants, Joint with spouse, or Individual, or None.

model.UpdateEnvelopeOption(query, option)
Parameters:
  • query (str) – see The Query Parameter
  • option (int,str) – The Id of the option or the full name of the option as indicated in the table below

This determines whether the person wants envelopes: either Joint with spouse, or Individual, or None.

model.UpdateElectronicStatement(query, truefalse)
Parameters:
  • query (str) – see The Query Parameter
  • truefalse (bool) – True for wants statements via secure web-site access only. False if wants printed statements.

Statement/Envelope Options

Id Option
0 Not Specified
1 Individual
2 Joint
9 None


Latest Update 10/27/2021

Updated for Adding a Task