Rest - Contacts - Participants - Notes

From Views API Documentation
Jump to navigation Jump to search

Purpose

Used for creating, editing and deleting notes against a participant in the Views system.

Base URL

https://app.viewsapp.net/api/restful/contacts/participants/<id>/notes

Creating Notes

curl --url <Base URL> -u<username>:<password> -H Content-Type:text/xml -X POST -d "<xml>"

If there is a problem with creating that record, you will get a response containing all the errors, plus a copy of the translated data you supplied.

If the record was created successfully, the service will return a complete reocrd for the newly created record if the attribute id set as the newly created id.

Searching for a Note

curl --url <Base URL>/<id> -u<username>:<password> -H Content-Type:text/xml

This will list all notes against a participnat. you can append one of the following to limit the list:

  • /contact - Participant only notes
  • /attendance - Participant attendance notes
  • /session - Notes on sessions that the participant is registered against

By default ALL notes from the 3 categories are returned.

Fetching a Notes

curl --url <Base URL>/<id> -u<username>:<password> -H Content-Type:text/xml

This method will only fetch Participant notes. If you attempt to fetch a note that is either of type attendance or session, you will receive a 303 response directing you to the actual location of that note.


Updating a Note

Please note You can only update participant notes via this api. For attendance and session notes, you should use the appropriate API.

curl --url <Base URL>/<id> -u<username>:<password> -H Content-Type:text/xml -X PUT -d "<xml>"
  • id - The ID of the note

The XML should be in the same format as the create, as specified by the schema

Deleting a Note

Please note You can only update participant notes via this api. For attendance and session notes, you should use the appropriate API.

curl --url <Base URL>/<id> -u<username>:<password> -H Content-Type:text/xml -X DELETE
  • id - The ID of the note

This should be used with great care as it will permanently delete a note record.