diff --git a/src/Client.php b/src/Client.php index eec03b9..e76a000 100644 --- a/src/Client.php +++ b/src/Client.php @@ -629,6 +629,13 @@ public function getLeadChanges($nextPageToken, $fields, $args = array(), $return return $this->getResult('getLeadChanges', $args, true, $returnRaw); } + public function getLeadActivities($nextPageToken, $args = array(), $returnRaw = false) + { + $args['nextPageToken'] = $nextPageToken; + + return $this->getResult('getLeadActivities', $args, true, $returnRaw); + } + /** * Update an editable section in an email * diff --git a/src/Response/GetLeadActivities.php b/src/Response/GetLeadActivities.php new file mode 100644 index 0000000..1d6b16f --- /dev/null +++ b/src/Response/GetLeadActivities.php @@ -0,0 +1,22 @@ + + */ +class GetLeadActivities extends Response +{ + public function getActivities() + { + if ($this->isSuccess()) { + $result = $this->getResult(); + return $result; + } + + return null; + } +} \ No newline at end of file diff --git a/src/service.json b/src/service.json index 80d2709..6efa6ea 100644 --- a/src/service.json +++ b/src/service.json @@ -85,6 +85,20 @@ }, "responseClass": "CSD\\Marketo\\Response\\GetLeadsResponse" }, + "getLeadActivities": { + "httpMethod": "GET", + "uri": "activities.json", + "parameters": { + "nextPageToken": {"location": "query"}, + "batchSize": {"location": "query"}, + "nextPageToken": {"location": "query"}, + "listId": {"location": "query"}, + "leadIds": {"location": "query"}, + "activityTypeIds": {"location": "query"}, + "assetIds": {"location": "query"} + }, + "responseClass": "CSD\\Marketo\\Response\\GetLeadActivities" + }, "isMemberOfList": { "httpMethod": "GET", "uri": "lists/{listId}/leads/ismember.json",