This API provides the following services:
The request format is:
https://app.forestcrm.hu/api/xml/<API KEY>/activities
Request parameters:
If no parameters are supplied, all activities for the tenant are returned.
https://app.forestcrm.hu/api/xml/demo/activities?companyId=5206
Response conforms the attached XSD.
Notes:
<activities>
<activity id="5018">
<updated>2011-03-20T00:00:00+01:00</updated>
<company id="8093">Second Partner</company>
<description>In the cold call I reminded her of the brilliant colors in our logo that made them interested in the effectiveness of our creative ideas. Would meet Bunny, meeting scheduled.</description>
<type>phone</type>
<status>completed</status>
<priority>1</priority>
<responsible>Charmy Kitty</responsible>
<start_at>2011-03-15T08:30:00+01:00</start_at>
<duration>15</duration>
<completed_at>2011-03-15</completed_at>
</activity>
<activity id="5021">
<updated>2011-03-20T00:00:00+01:00</updated>
<company id="8093">Second Partner</company>
<description>Called us to ask for a shadow for an exhibition. On my suggestion they ordered 3 plastic palm trees. Tiny take it over, please. Meeting the deadline is very important.</description>
<type>background</type>
<status>open</status>
<priority>1</priority>
<responsible>Tiny Mite</responsible>
<start_at>2011-03-23T11:30:00+01:00</start_at>
<duration>60</duration>
<opportunity id="1281">Shadow for Exhibition</opportunity>
<contact id="14560">John Smith</contact>
</activity>
</activities>
The request format is:
https://app.forestcrm.hu/api/xml/<API KEY>/activities
Request HTTP method: POST
Request parameters (optional params default to empty unless noted otherwise):
POST https://app.forestcrm.hu/api/xml/demo/activities
Header:
Content-Type: application/json
Body:
{
"activity": {
"description": "Registered via webform - First Call",
"salesrep_id": 2400,
"company_id": 14566,
"activity_type_id": 3,
"scheduled_start": '2012-09-18 13:30',
"duration": 60
}
}
If the activity could be created the response is of status code 200 and the body contains the the ID of the activity created in XML format:
<activity>
<id type="integer">87665</id>
</activity>
Errors are reported with a status code (422) and the response body contains the errors in XML format.
The request format is:
https://app.forestcrm.hu/api/xml/<API KEY>/activities/<activity ID>or
https://app.forestcrm.hu/api/xml/<API KEY>/activities/<activity ID>?external_ref
Request HTTP method: PUT
Request parameters: same as in create
Note that the requested attributes get updated (overwritten), missing attributes don't change.
PUT https://app.forestcrm.hu/api/xml/demo/activities/87665
Header:
Content-Type: application/json
Body:
{
"activity": {
"duration": 90
}
}
If the activity could be updated the response is of status code 200.
Errors are reported with a status code (422) and the response body contains the errors in XML format.