API v1 Reference

List Activities

This request is used to retrieve a list of Activity records. You can either:

  • Search for activities by the System User who owns the activity
  • Search for activities by the Account of the constituent to whom the activity is related.

REST

Request

https://api.neoncrm.com/neonws/services/api/account/listActivities?usersessionid=T1356770280483&activitySearchCriteria.systemUserId=3&activitySearchCriteria.clientId=3480&activitySearchcriteria.keywork=sub&activitySearchCriteria.startDate=2012-11-10&activitySearchCriteria.endDate=2012-12-20

Response

{
   "listActivitiesResponse":
   {
       "operationResult": "SUCCESS",
       "responseDateTime": "2014-12-12T21:34:05.409+0000",
       "page":
       {
           "currentPage": 1,
           "pageSize": 10,
           "totalPage": 1,
           "totalResults": 1
       },
       "searchResults":
       {
           "nameValuePairs":
           [
           ]
       },
       "activities":
       {
           "activity":
           [
               {
                   "createdDateTime": "2014-12-11T10:38:11.000+0000",
                   "createdBy": "z2Administrator ",
                   "lastModifiedDateTime": "2014-12-11T10:38:11.000+0000",
                   "lastModifiedBy": "z2Administrator ",
                   "activityId": 5,
                   "subject": "Phone Call",
                   "note": "",
                   "startDateTime": "2014-12-12T14:00:00.661+0000",
                   "endDateTime": "2014-12-12T17:00:00.661+0000",
                   "clientId": 55,
                   "systemUserId": 7,
                   "activityStatus":
                   {
                       "id": "2",
                       "name": "Not Started"
                   },
                   "activityPriority": "NORMAL",
                   "customFieldDataList":
                   {
                       "customFieldData":
                       [
                           {
                               "fieldId": "56",
                               "fieldValue": "1231"
                           }
                       ]
                   }
               }
           ]
       }
   }
}

SOAP

Request

<soapenv:envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/" xmlns:neon="http://www.z2systems.com/schemas/neonws/">
   <soapenv:header>
       <soapenv:body>
          <neon:listactivitiesrequest>
             <usersessionid>T1357624094982</usersessionid>
             <activitysearchcriteria>
                <systemuserid>3</systemuserid>
             </activitysearchcriteria>
          </neon:listactivitiesrequest>
       </soapenv:body>
    </soapenv:header>
</soapenv:envelope>

Response

<soap:envelope xmlns:soap="http://schemas.xmlsoap.org/soap/envelope/">
   <soap:body>
      <ns2:listactivitiesresponse xmlns:ns2="http://www.z2systems.com/schemas/neonws/">
         <operationresult>SUCCESS</operationresult>
         <responsemessage>1records found.</responsemessage>
         <responsedatetime>2013-01-08T00:36:49.709-06:00</responsedatetime>
         <activities>
            <acticity>
               <createddatetime>2013-01-08T00:03:18.000-06:00</createddatetime>
               <createdby>
               <lastmodifieddatetime>2013-01-08T00:03:18.000-06:00</lastmodifieddatetime>
               <lastmodifiedby>
               <activityid>1</activityid>
               <subject>test activity 1</subject>
               <note>note</note>
               <startdatetime>2012-11-19T14:00:00.000+08:00</startdatetime>
               <enddatetime>2012-12-19T14:00:00.000+08:00</enddatetime>
               <clientid>5786</clientid>
               <systemuserid>3</systemuserid>
               <activitystatus>
                  <id>2</id>
                  <name>Not Started</name>
               </activitystatus>
               <activitypriority>Normal</activitypriority>
            </lastmodifiedby></createdby></acticity>
         </activities>
      </ns2:listactivitiesresponse>
   </soap:body>
</soap:envelope>

Request Parameters

Name Required Description
activitySearchCriteria.clientId Yes * Account ID of the constituent record associated with this activity. This is required if systemUserId is not provided.
activitySearchCriteria.systemUserId Yes * Account ID of the system user associated with this activity. This is required if clientId is not provided.
activitySearchCriteria.keyword Searches keywords in the Subject field of Activities
activitySearchCriteria.activityStatusId Search for activies by Status ID. Possible values are found in the List Activity Status API method.
activitySearchCriteria.startDate Search for Activities by Start date. Use this format: 2012-11-18-05:00. Note: this is an exact match and cannot be used for date ranges.
activitySearchCriteria.endDate Search for Activities by End date. Use this format: 2012-11-18-05:00. Note: this is an exact match and cannot be used for date ranges.
searches.search.key Search for Activities based on Activity custom field values. Use Activity Custom Field ID, found in the List Custom Fields method.
searches.search.searchOperator Possible values: EQUAL, NOT_EQUAL, BLANK, NOT_BLANK, LESS_THAN, LESS_AND_EQUAL, GREATER_THAN, GREATER_AND_EQUAL, CONTAIN
searches.search.value Search value for an Activity custom field query
outputfields.idnamepair.id Include Activity custom field values in the server response. Use Activity Custom Field ID, found in the List Custom Fields method.
Page.totalPage
Page.totalResults
Page.sortColumn The name of the field by which results should be sorted.
Page.sortDirection Possible values: ASC, DESC

Response Parameters

Name Required Description
Activity.activityId Yes The ID of the activity.
Activity.subject Yes Subject field for the activity record.
Activity.note
Activity.startDateTime Yes Activity Start timestamp. Format example: [2012-11-19T15:35:53+08:00]
Activity.endDateTime Activity End timestamp. Format example: [2012-11-19T15:35:53+10:00]
Activity.clientId Account ID of the constituent record associated with this activity
Activity.systemUserId Account ID of the system user associated with this activity
Activity.activityStatus.id Yes Possible values are found in the List Activity Status API method.
Activity.activityStatus.name Yes Possible values are found in the List Activity Status API method.
Activity.activityPriority Yes Possible values: High, Normal, Low
Activity.customFieldDataList.customFieldData.fieldId Id of Activity Custom Fields returned as output.
Activity.customFieldDataList.customFieldData.fieldValue Value of Activity Custom Fields returned as output.

Error Codes

Code Text Description
10100 Client account id or SystemUser accountId is required.