POST crm/people/hart_courses
Associate a contact or lead with a HART rider course or update the status of course for a contact or lead. (Each request can have multiple associations.)
Request Information
Parameters
Name | Description |
---|---|
json |
Note: If one person is doing to book the course which hasn’t been booked before in salesforce, some fields are mandatory, such as person_id,product_id,date_of_birth,license_type,drivers_license,mobile_phone(home_phone)street,city,state,country. If only need to update the course which has already been booked, the fields are optional but the Asset id or (Product id and Person id) still need to be provided as the begin fields.
|
Request body formats
application/json, text/json, text/plain, application/x-www-form-urlencoded
Sample:
{ "people_product": [{ "person_id": "0039000002Bg9c5", "product_id": "01t90000000P92v", "asset_id": "", "course_datetime": "2017-12-31 13:00:00", "course_date_end": "2018-01-25 13:00:00", "course_location": "st ives", "hart_instructor_1": "Mark", "hart_instructor_2": "Frank", "course_status": "completed - pass", "course_feedback": "pass A", "booking_number": "002", "dealer_code": "1234", "course_price": "400", "booking_source": "Website", "mobile_phone": "012345678", "home_phone": "12345678", "postcode": "1234", "street": "123 Some Street", "city": "Some City", "state": "Some State", "country": "Some Country", "drivers_license": "ABDCEGF", "license_type": "CYL", "date_of_birth": "1993-01-22", "opt_in": false },{ "person_id": "00Q90000015YJnT", "product_id": "01t90000000P92v", "asset_id": "", "course_datetime": "2017-12-31 13:00:00", "course_date_end": "2018-01-25 13:00:00", "course_location": "st ives", "hart_instructor_1": "Mark", "hart_instructor_2": "Frank", "course_status": "completed - fail", "course_feedback": "fail 4", "booking_number": "002", "dealer_code": "1234", "course_price": "400", "booking_source": "Phone", "mobile_phone": "012345678", "home_phone": "12345678", "postcode": "1234", "street": "123 Some Street", "city": "Some City", "state": "Some State", "country": "Some Country", "drivers_license": "ABCDEFG12", "license_type": "CYL", "date_of_birth": "1989-02-21", "opt_in": false },{ "person_id": "00Q90000016CRNO", "asset_id": "02i90000004WVxjAAG", "course_status": "cancelled", "course_datetime": "2015-12-19 12:30:00", "course_date_end": "2015-12-19 14:30:00" }] }
Response Information
Response body formats
application/json, text/json
Sample:
{ "details":[ { "delivery":"true", "receipt": "Update HART course successfully.", "person_id": "0039000002Bg9c5", "product_id": "01t90000000P92v", "contact_id": "0039000002Bg9c5", "asset_id": "02i90000002cRuSAAU", "course_datetime": "2017-12-31 13:00:00", "course_date_end": "2018-01-25 13:00:00" }, { "delivery": "true", "receipt": "Update HART course successfully.", "person_id": "00Q90000002KUwL", "product_id": "01t90000000P92v", "contact_id": "0039000002E1z3GAAR", "asset_id": "02i90000002cRw4AAE", "course_datetime": "2017-12-31 13:00:00", "course_date_end": "2018-01-25 13:00:00" }, { "delivery": "true", "receipt": "Update HART course successfully.", "person_id": "00Q90000016CRNO", "product_id": "01t90000000P92v", "contact_id": "0039000002WWxHaAAL", "asset_id": "02i90000004WVxjAAG", "course_datetime": "2017-12-31 13:00:00", "course_date_end": "2018-01-25 13:00:00" } ], "audit_id": "760" } Or Bad Response: Status update failed.