<?xml version="1.0"?>
<feed xmlns="http://www.w3.org/2005/Atom" xml:lang="en-GB">
	<id>https://www.substance.net/views-api-docs/api.php?action=feedcontributions&amp;feedformat=atom&amp;user=Wikiadmin</id>
	<title>Views API Documentation - User contributions [en-gb]</title>
	<link rel="self" type="application/atom+xml" href="https://www.substance.net/views-api-docs/api.php?action=feedcontributions&amp;feedformat=atom&amp;user=Wikiadmin"/>
	<link rel="alternate" type="text/html" href="https://www.substance.net/views-api-docs/index.php?title=Special:Contributions/Wikiadmin"/>
	<updated>2026-04-27T20:20:20Z</updated>
	<subtitle>User contributions</subtitle>
	<generator>MediaWiki 1.39.4</generator>
	<entry>
		<id>https://www.substance.net/views-api-docs/index.php?title=Views_API_Documentation&amp;diff=320</id>
		<title>Views API Documentation</title>
		<link rel="alternate" type="text/html" href="https://www.substance.net/views-api-docs/index.php?title=Views_API_Documentation&amp;diff=320"/>
		<updated>2025-04-04T09:16:18Z</updated>

		<summary type="html">&lt;p&gt;Wikiadmin: /* Contacts */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;==Rest==&lt;br /&gt;
===General Overview===&lt;br /&gt;
All of our REST services are available in both XML and JSON formats, unless otherwise stated. The default format is XML. For the purposes of this documentation we only document the XML method. If you want to interact using json, then you should either make sure you request using &amp;lt;code&amp;gt;Content-Type: application/json&amp;lt;/code&amp;gt;, alternatively you have append the extension &amp;lt;code&amp;gt;.json&amp;lt;/code&amp;gt; to the URI e.g:&lt;br /&gt;
 curl --url &amp;lt;Base URL&amp;gt;/&amp;lt;id&amp;gt; -u&amp;lt;username&amp;gt;:&amp;lt;password&amp;gt; -H Accept:application/json&lt;br /&gt;
&lt;br /&gt;
or&lt;br /&gt;
&lt;br /&gt;
 curl --url &amp;lt;Base URL&amp;gt;/&amp;lt;id&amp;gt;.json -u&amp;lt;username&amp;gt;:&amp;lt;password&amp;gt;&lt;br /&gt;
&lt;br /&gt;
====Using OAuth2====&lt;br /&gt;
&lt;br /&gt;
The use of OAthu2 access_tokens can be used. To do this, you must first request an &amp;lt;code&amp;gt;access_token&amp;lt;/code&amp;gt; from the authentication portal https://authport.viewsapp.net/. This can be done in the following way (using Google Apps Script:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
// Get access_token&lt;br /&gt;
var response = UrlFetchApp.fetch(&#039;https://authportal.viewsapp.net/token.php&#039;, {&lt;br /&gt;
  &#039;method&#039;  : &#039;post&#039;,&lt;br /&gt;
  &#039;payload&#039; : {&#039;grant_type&#039;: &#039;password&#039;, &#039;username&#039; : &#039;my_username&#039;, &#039;password&#039; : &#039;my_password&#039;},&lt;br /&gt;
  &#039;headers&#039; : {&amp;quot;Authorization&amp;quot;: &amp;quot;Basic &amp;quot; + Utilities.base64Encode(&#039;my_username&#039; + &amp;quot;:&amp;quot; + &#039;my_password&#039;)}&lt;br /&gt;
});&lt;br /&gt;
var access_token = JSON.parse(response.getContentText()).access_token;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
  &lt;br /&gt;
You would then pass the following fields along side any request:&lt;br /&gt;
&lt;br /&gt;
* client_id=&amp;lt;username&amp;gt;&lt;br /&gt;
* access_token=&amp;lt;access_token&amp;gt;&lt;br /&gt;
&lt;br /&gt;
via curl:&lt;br /&gt;
&amp;lt;pre&amp;gt;curl --url https://authportal.viewsapp.net/token.php -X POST -d &amp;quot;grant_type=password&amp;quot; -u&amp;lt;username&amp;gt;:&amp;lt;password&amp;gt; -H Accept:application/json&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
====Searching the API&#039;s====&lt;br /&gt;
A lot of the API&#039;s have a search capabilities and share some parameters:&lt;br /&gt;
* q=&amp;lt;string&amp;gt; - This is a free text field for basic searching&lt;br /&gt;
* pageFold=&amp;lt;int&amp;gt; - This the number of results to return in any result set&lt;br /&gt;
* offset=&amp;lt;int&amp;gt; - This is how many records to offset in the result set&lt;br /&gt;
* page=&amp;lt;int&amp;gt; - This can be used in place of offset as is just makes an adjustment to the offset value using the following fomula: &amp;lt;code&amp;gt;offset = (page-1)*pageFold&amp;lt;/code&amp;gt;. &lt;br /&gt;
** &#039;&#039;If used in conjunction with offset, then each page is offset by the specified values also.&#039;&#039;&lt;br /&gt;
** By default this equals 1.&lt;br /&gt;
* archived - By default, only non-archived results are returned. Setting this parameter to 1 result in searching archived records&lt;br /&gt;
&lt;br /&gt;
===Contacts===&lt;br /&gt;
* [[Rest - Contacts - Participants|Particpants]]&lt;br /&gt;
** [[Rest - Contacts - Participants - Sessions|Session Attendance]]&lt;br /&gt;
** [[Rest - Contacts - Participants - Notes|Notes]]&lt;br /&gt;
** [[Rest - Contacts - Participants - Address Book|Address Book]]&lt;br /&gt;
** [[Rest - Contacts - Participants - Questionnaires|Questionnaires]]&lt;br /&gt;
** [[Rest - Contacts - Participants - Volunteering|Volunteering]]&lt;br /&gt;
** [[Rest - Contacts - Participants - Conditions|Conditions]]&lt;br /&gt;
** [[Rest - Contacts - Participants - Restrictions|Restrictions]]&lt;br /&gt;
** [[Rest - Contacts - Participants - Associations|Associations]]&lt;br /&gt;
* [[Rest - Contacts - Groups|Groups]]&lt;br /&gt;
** [[Rest - Contacts - Groups - Sessions|Session Attendance]]&lt;br /&gt;
** [[Rest - Contacts - Groups - Notes|Notes]]&lt;br /&gt;
** [[Rest - Contacts - Groups - Address Book|Address Book]]&lt;br /&gt;
** [[Rest - Contacts - Groups - Questionnaires|Questionnaires]]&lt;br /&gt;
** [[Rest - Contacts - Groups - Associations|Associations]]&lt;br /&gt;
* [[Rest - Contacts - Staff|Staff]]&lt;br /&gt;
** [[Rest - Contacts - Staff - Sessions|Session Attendance]]&lt;br /&gt;
** [[Rest - Contacts - Staff - Notes|Notes]]&lt;br /&gt;
** [[Rest - Contacts - Staff - Address Book|Address Book]]&lt;br /&gt;
** [[Rest - Contacts - Staff - Questionnaires|Questionnaires]]&lt;br /&gt;
** [[Rest - Contacts - Staff - Volunteering|Volunteering]]&lt;br /&gt;
** [[Rest - Contacts - Staff - Associations|Associations]]&lt;br /&gt;
* [[Rest - Contacts - Professionals|Professionals]]&lt;br /&gt;
** [[Rest - Contacts - Professionals - Sessions|Session Attendance]]&lt;br /&gt;
** [[Rest - Contacts - Professionals - Notes|Notes]]&lt;br /&gt;
** [[Rest - Contacts - Professionals - Questionnaires|Questionnaires]]&lt;br /&gt;
** [[Rest - Contacts - Professionals - Associations|Associations]]&lt;br /&gt;
* [[Rest - Contacts - Volunteers|Volunteers]]&lt;br /&gt;
** [[Rest - Contacts - Volunteers - Sessions|Session Attendance]]&lt;br /&gt;
** [[Rest - Contacts - Volunteers - Notes|Notes]]&lt;br /&gt;
** [[Rest - Contacts - Volunteers - Address Book|Address Book]]&lt;br /&gt;
** [[Rest - Contacts - Volunteers - Questionnaires|Questionnaires]]&lt;br /&gt;
** [[Rest - Contacts - Volunteers - Volunteering|Volunteering]]&lt;br /&gt;
&lt;br /&gt;
===Work===&lt;br /&gt;
* [[Rest - Work - Venues|Venues]]&lt;br /&gt;
* [[Rest - Work - Session Groups|Session Groups]]&lt;br /&gt;
** [[Rest - Work - Session Groups - Participants|Session Group Participants]]&lt;br /&gt;
** [[Rest - Work - Session Groups - Sessions|Sessions]]&lt;br /&gt;
*** [[Rest - Work - Session Groups - Session Notes|Session Notes]]&lt;br /&gt;
*** [[Rest - Work - Session Groups - Session Participants|Session Participants]]&lt;br /&gt;
*** [[Rest - Work - Session Groups - Session Staff|Session Staff]]&lt;br /&gt;
*** [[Rest - Work - Session Groups - Session Questionnaires|Session Questionnaires]]&lt;br /&gt;
* [[Rest - Work - Agency Projects|Agency Projects]]&lt;br /&gt;
** [[Rest - Work - Agency Projects - Session Groups|Agency Project Session Groups]]&lt;br /&gt;
** [[Rest - Work - Agency Projects - Objectives|Objectives]]&lt;br /&gt;
** [[Rest - Work - Agency Projects - Outcomes|Outcomes]]&lt;br /&gt;
&lt;br /&gt;
===Evidence===&lt;br /&gt;
* [[Rest - Evidence - Questionnaires|Questionnaires]]&lt;br /&gt;
** [[Rest - Evidence - Questionnaires - Questions|Questions]]&lt;br /&gt;
** [[Rest - Evidence - Questionnaires - Answers|Answers]]&lt;br /&gt;
&lt;br /&gt;
===Admin===&lt;br /&gt;
* [[Rest - Admin - Value Lists|Value Lists]]&lt;br /&gt;
* [[Rest - Admin - Programmes|Programmes]]&lt;br /&gt;
* [[Rest - Admin - Objectives|Objectives]]&lt;br /&gt;
* [[Rest - Admin - Outcomes|Outcomes]]&lt;br /&gt;
* [[Rest - Admin - ProgrammeFields|Programme Fields]]&lt;br /&gt;
* [[Rest - Admin - Change Log|Change Log]]&lt;br /&gt;
* [[Rest - Admin - Flatpack|Flatpack]]&lt;br /&gt;
&lt;br /&gt;
==SOAP Documention==&lt;br /&gt;
===Contacts===&lt;br /&gt;
* [[SOAP - Contacts - Particpants|Particpants]]&lt;br /&gt;
* [[SOAP - Contacts - Staff|Staff]]&lt;br /&gt;
===Evidence===&lt;br /&gt;
* [[SOAP - Questionaires|Questionaires]]&lt;/div&gt;</summary>
		<author><name>Wikiadmin</name></author>
	</entry>
	<entry>
		<id>https://www.substance.net/views-api-docs/index.php?title=Rest_-_Contacts_-_Professionals_-_Questionnaires&amp;diff=319</id>
		<title>Rest - Contacts - Professionals - Questionnaires</title>
		<link rel="alternate" type="text/html" href="https://www.substance.net/views-api-docs/index.php?title=Rest_-_Contacts_-_Professionals_-_Questionnaires&amp;diff=319"/>
		<updated>2025-04-04T09:15:30Z</updated>

		<summary type="html">&lt;p&gt;Wikiadmin: Created page with &amp;quot;==Purpose==  Used for submitting answer sets to questionnaires against professionals and for retrieving the details of answered questionnaires that have been submitted against a professional. This is only really a filtered version of the Questionnaires - Answers API  ===Base URL=== &amp;lt;nowiki&amp;gt;https://app.viewsapp.net/api/restful/contacts/professionals/&amp;lt;id&amp;gt;/questionnaires&amp;lt;/nowiki&amp;gt; * id - This is the professional id  ===Schema===...&amp;quot;&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;==Purpose==&lt;br /&gt;
&lt;br /&gt;
Used for submitting answer sets to questionnaires against professionals and for retrieving the details of answered questionnaires that have been submitted against a professional. This is only really a filtered version of the [[Rest - Evidence - Questionnaires - Answers|Questionnaires - Answers API]]&lt;br /&gt;
&lt;br /&gt;
===Base URL===&lt;br /&gt;
&amp;lt;nowiki&amp;gt;https://app.viewsapp.net/api/restful/contacts/professionals/&amp;lt;id&amp;gt;/questionnaires&amp;lt;/nowiki&amp;gt;&lt;br /&gt;
* id - This is the professional id&lt;br /&gt;
&lt;br /&gt;
===Schema===&lt;br /&gt;
For details of the schemas, please refer to [[Rest - Evidence - Questionnaires - Answers]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
==Fetching a list of answer sets==&lt;br /&gt;
The default call will return a list of questionnaires (answer sets) that have been recorded against the professional&lt;br /&gt;
 curl --url &amp;lt;Base URL&amp;gt; -u&amp;lt;username&amp;gt;:&amp;lt;password&amp;gt; -H Content-Type:text/xml&lt;br /&gt;
&lt;br /&gt;
This will return data similar to the following:&lt;br /&gt;
 &amp;lt;answersets count=&amp;quot;7&amp;quot;&amp;gt;&lt;br /&gt;
     &amp;lt;answerset id=&amp;quot;1&amp;quot; questionnaireid=&amp;quot;14&amp;quot;&amp;gt;&lt;br /&gt;
         &amp;lt;EntityType&amp;gt;Professional&amp;lt;/EntityType&amp;gt;&lt;br /&gt;
         &amp;lt;EntityID&amp;gt;1&amp;lt;/EntityID&amp;gt;&lt;br /&gt;
         &amp;lt;Date&amp;gt;2012-07-31T10:00:00&amp;lt;/Date&amp;gt;&lt;br /&gt;
         &amp;lt;QuestionnaireID&amp;gt;14&amp;lt;/QuestionnaireID&amp;gt;&lt;br /&gt;
         &amp;lt;AnswerSetID&amp;gt;1&amp;lt;/AnswerSetID&amp;gt;&lt;br /&gt;
         &amp;lt;Questionnaire&amp;gt;Impact&amp;lt;/Questionnaire&amp;gt;&lt;br /&gt;
     &amp;lt;/answerset&amp;gt;&lt;br /&gt;
     &amp;lt;answerset id=&amp;quot;4&amp;quot; questionnaireid=&amp;quot;5&amp;quot;&amp;gt;&lt;br /&gt;
         &amp;lt;EntityType&amp;gt;Professional&amp;lt;/EntityType&amp;gt;&lt;br /&gt;
         &amp;lt;EntityID&amp;gt;1&amp;lt;/EntityID&amp;gt;&lt;br /&gt;
         &amp;lt;Date&amp;gt;2012-05-04T10:11:00&amp;lt;/Date&amp;gt;&lt;br /&gt;
         &amp;lt;QuestionnaireID&amp;gt;14&amp;lt;/QuestionnaireID&amp;gt;&lt;br /&gt;
         &amp;lt;AnswerSetID&amp;gt;4&amp;lt;/AnswerSetID&amp;gt;&lt;br /&gt;
         &amp;lt;Questionnaire&amp;gt;Interests&amp;lt;/Questionnaire&amp;gt;&lt;br /&gt;
     &amp;lt;/answerset&amp;gt;&lt;br /&gt;
     ...&lt;br /&gt;
 &amp;lt;/answersets&amp;gt;&lt;br /&gt;
&lt;br /&gt;
If you are only interested in a particular questionnaire, you should us the following:&lt;br /&gt;
 curl --url &amp;lt;Base URL&amp;gt;/&amp;lt;questionnairId&amp;gt; -u&amp;lt;username&amp;gt;:&amp;lt;password&amp;gt; -H Content-Type:text/xml&lt;br /&gt;
&lt;br /&gt;
This will return data similar to the following:&lt;br /&gt;
 &amp;lt;answersets count=&amp;quot;2&amp;quot;&amp;gt;&lt;br /&gt;
     &amp;lt;answerset id=&amp;quot;1&amp;quot; questionnaireid=&amp;quot;14&amp;quot;&amp;gt;&lt;br /&gt;
         &amp;lt;EntityType&amp;gt;Professional&amp;lt;/EntityType&amp;gt;&lt;br /&gt;
         &amp;lt;EntityID&amp;gt;1&amp;lt;/EntityID&amp;gt;&lt;br /&gt;
         &amp;lt;Date&amp;gt;2012-07-31T10:00:00&amp;lt;/Date&amp;gt;&lt;br /&gt;
         &amp;lt;QuestionnaireID&amp;gt;14&amp;lt;/QuestionnaireID&amp;gt;&lt;br /&gt;
         &amp;lt;AnswerSetID&amp;gt;1&amp;lt;/AnswerSetID&amp;gt;&lt;br /&gt;
         &amp;lt;Questionnaire&amp;gt;Impact&amp;lt;/Questionnaire&amp;gt;&lt;br /&gt;
     &amp;lt;/answerset&amp;gt;&lt;br /&gt;
     &amp;lt;answerset id=&amp;quot;6&amp;quot; questionnaireid=&amp;quot;14&amp;quot;&amp;gt;&lt;br /&gt;
         &amp;lt;EntityType&amp;gt;Professional&amp;lt;/EntityType&amp;gt;&lt;br /&gt;
         &amp;lt;EntityID&amp;gt;1&amp;lt;/EntityID&amp;gt;&lt;br /&gt;
         &amp;lt;Date&amp;gt;2012-05-02T09:10:00&amp;lt;/Date&amp;gt;&lt;br /&gt;
         &amp;lt;QuestionnaireID&amp;gt;14&amp;lt;/QuestionnaireID&amp;gt;&lt;br /&gt;
         &amp;lt;AnswerSetID&amp;gt;6&amp;lt;/AnswerSetID&amp;gt;&lt;br /&gt;
         &amp;lt;Questionnaire&amp;gt;Impact&amp;lt;/Questionnaire&amp;gt;&lt;br /&gt;
     &amp;lt;/answerset&amp;gt;&lt;br /&gt;
 &amp;lt;/answersets&amp;gt;&lt;br /&gt;
&lt;br /&gt;
The results are order by the most recent first. This means to get the latest version of a questionnaire, you would only need to fetch the first result.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
==Fetching the answers of a given questionnaire==&lt;br /&gt;
 curl --url &amp;lt;Base URL&amp;gt;/&amp;lt;questionnairId&amp;gt;/&amp;lt;setId&amp;gt; -u&amp;lt;username&amp;gt;:&amp;lt;password&amp;gt; -H Content-Type:text/xml&lt;br /&gt;
* questionnaireId - This is the id of the questionnaire&lt;br /&gt;
* setId - This is the id of the Answers Set you want to retrieve&lt;br /&gt;
&lt;br /&gt;
It&#039;s will return something along the lines of&lt;br /&gt;
 &amp;lt;answerset questionaireid=&amp;quot;14&amp;quot; id=&amp;quot;1&amp;quot;&amp;gt;&lt;br /&gt;
     &amp;lt;EntityType&amp;gt;Professional&amp;lt;/EntityType&amp;gt;&lt;br /&gt;
     &amp;lt;EntityID&amp;gt;1&amp;lt;/EntityID&amp;gt;&lt;br /&gt;
     &amp;lt;TargetType/&amp;gt;&lt;br /&gt;
     &amp;lt;TargetID&amp;gt;0&amp;lt;/TargetID&amp;gt;&lt;br /&gt;
     &amp;lt;Date&amp;gt;2012-07-31T10:00:00&amp;lt;/Date&amp;gt;&lt;br /&gt;
     &amp;lt;answers count=&amp;quot;9&amp;quot;&amp;gt;&lt;br /&gt;
         &amp;lt;answer id=&amp;quot;78&amp;quot;&amp;gt;&lt;br /&gt;
             &amp;lt;QuestionID&amp;gt;78&amp;lt;/QuestionID&amp;gt;&lt;br /&gt;
             &amp;lt;Answer&amp;gt;Fully Agree&amp;lt;/Answer&amp;gt;&lt;br /&gt;
         &amp;lt;/answer&amp;gt;&lt;br /&gt;
         &amp;lt;answer id=&amp;quot;79&amp;quot;&amp;gt;&lt;br /&gt;
             &amp;lt;QuestionID&amp;gt;79&amp;lt;/QuestionID&amp;gt;&lt;br /&gt;
             &amp;lt;Answer&amp;gt;Truly Agree&amp;lt;/Answer&amp;gt;&lt;br /&gt;
         &amp;lt;/answer&amp;gt;&lt;br /&gt;
         &amp;lt;answer id=&amp;quot;80&amp;quot;&amp;gt;&lt;br /&gt;
             &amp;lt;QuestionID&amp;gt;80&amp;lt;/QuestionID&amp;gt;&lt;br /&gt;
             &amp;lt;Answer&amp;gt;Agree&amp;lt;/Answer&amp;gt;&lt;br /&gt;
         &amp;lt;/answer&amp;gt;&lt;br /&gt;
         ...&lt;br /&gt;
     &amp;lt;/answers&amp;gt;&lt;br /&gt;
 &amp;lt;/answerset&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
==Fetching a single answer from a questionnaire==&lt;br /&gt;
 curl --url &amp;lt;Base URL&amp;gt;/&amp;lt;questionnairId&amp;gt;/&amp;lt;setId&amp;gt;/&amp;lt;questionId&amp;gt; -u&amp;lt;username&amp;gt;:&amp;lt;password&amp;gt; -H Content-Type:text/xml&lt;br /&gt;
* questionnaireId - This is the id of the questionnaire&lt;br /&gt;
* setId - This is the id of the Answers Set you want to retrieve&lt;br /&gt;
* questionId - This is the id of the question you want the answer for&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;answer id=&amp;quot;78&amp;quot;&amp;gt;&lt;br /&gt;
     &amp;lt;QuestionnaireID&amp;gt;14&amp;lt;/QuestionnaireID&amp;gt;&lt;br /&gt;
     &amp;lt;AnswerSetID&amp;gt;1&amp;lt;/AnswerSetID&amp;gt;&lt;br /&gt;
     &amp;lt;QuestionID&amp;gt;78&amp;lt;/QuestionID&amp;gt;&lt;br /&gt;
     &amp;lt;Answer&amp;gt;Fully Agree&amp;lt;/Answer&amp;gt;&lt;br /&gt;
 &amp;lt;/answer&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
==Creating a new Answer Set==&lt;br /&gt;
 curl --url &amp;lt;Base URL&amp;gt;/&amp;lt;questionnairId&amp;gt; -u&amp;lt;username&amp;gt;:&amp;lt;password&amp;gt; -H Content-Type:text/xml -X POST -d &#039;&amp;lt;xml&amp;gt;&#039;&lt;br /&gt;
&lt;br /&gt;
To submit a new set of answers against a questionnaire, you should send data in the following structure:&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;answers&amp;gt;&lt;br /&gt;
     &amp;lt;Date&amp;gt;2012-07-31T10:00:00&amp;lt;/Date&amp;gt;&lt;br /&gt;
     &amp;lt;answer id=&amp;quot;78&amp;quot;&amp;gt;&lt;br /&gt;
       &amp;lt;QuestionID&amp;gt;78&amp;lt;/QuestionID&amp;gt;&lt;br /&gt;
       &amp;lt;Answer&amp;gt;Fully Agree&amp;lt;/Answer&amp;gt;&lt;br /&gt;
     &amp;lt;/answer&amp;gt;&lt;br /&gt;
     &amp;lt;answer id=&amp;quot;79&amp;quot;&amp;gt;&lt;br /&gt;
       &amp;lt;QuestionID&amp;gt;79&amp;lt;/QuestionID&amp;gt;&lt;br /&gt;
       &amp;lt;Answer&amp;gt;Truly Agree&amp;lt;/Answer&amp;gt;&lt;br /&gt;
     &amp;lt;/answer&amp;gt;&lt;br /&gt;
     ...&lt;br /&gt;
 &amp;lt;/answers&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Note:&#039;&#039;&#039; If you specify the attribute &#039;&#039;&amp;lt;code&amp;gt;id&amp;lt;/code&amp;gt;&#039;&#039; then you do not need to specify the &amp;lt;code&amp;gt;&amp;lt;QuestionID&amp;gt;&amp;lt;/code&amp;gt; entity.&lt;br /&gt;
&lt;br /&gt;
You can also relate the questionnaire to a Session (and SessionGroup) by specifying the &amp;lt;code&amp;gt;&amp;lt;TargetType&amp;gt;&amp;lt;/code&amp;gt; and &amp;lt;code&amp;gt;&amp;lt;TargetID&amp;gt;&amp;lt;/code&amp;gt; entities&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;answers&amp;gt;&lt;br /&gt;
     &amp;lt;TargetType&amp;gt;Session&amp;lt;/TargetType&amp;gt;&lt;br /&gt;
     &amp;lt;TargetID&amp;gt;214&amp;lt;/TargetID&amp;gt;&lt;br /&gt;
     &amp;lt;Date&amp;gt;2012-07-31T10:00:00&amp;lt;/Date&amp;gt;&lt;br /&gt;
     &amp;lt;answer id=&amp;quot;78&amp;quot;&amp;gt;&lt;br /&gt;
       &amp;lt;QuestionID&amp;gt;78&amp;lt;/QuestionID&amp;gt;&lt;br /&gt;
       &amp;lt;Answer&amp;gt;Fully Agree&amp;lt;/Answer&amp;gt;&lt;br /&gt;
     &amp;lt;/answer&amp;gt;&lt;br /&gt;
     ....&lt;br /&gt;
 &amp;lt;/answers&amp;gt;&lt;br /&gt;
&lt;br /&gt;
You can also omit the &amp;lt;code&amp;gt;&amp;lt;Date&amp;gt;&amp;lt;/code&amp;gt; entity. If you do this, then the current system date/time will be used.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
==Updating an existing Answer Set==&lt;br /&gt;
 curl --url &amp;lt;Base URL&amp;gt;/&amp;lt;questionnairId&amp;gt;/&amp;lt;setid&amp;gt; -u&amp;lt;username&amp;gt;:&amp;lt;password&amp;gt; -H Content-Type:text/xml -X PUT -d &#039;&amp;lt;xml&amp;gt;&#039;&lt;br /&gt;
&lt;br /&gt;
When updating the answers in an answer set, you should use the same structure as when creating a new answer set. However, if you specify the entities &amp;lt;code&amp;gt;TargetType&amp;gt;&amp;lt;/code&amp;gt; and &amp;lt;code&amp;gt;TargetID&amp;gt;&amp;lt;/code&amp;gt; they will be ignored.&lt;/div&gt;</summary>
		<author><name>Wikiadmin</name></author>
	</entry>
	<entry>
		<id>https://www.substance.net/views-api-docs/index.php?title=Rest_-_Contacts_-_Professionals_-_Notes&amp;diff=318</id>
		<title>Rest - Contacts - Professionals - Notes</title>
		<link rel="alternate" type="text/html" href="https://www.substance.net/views-api-docs/index.php?title=Rest_-_Contacts_-_Professionals_-_Notes&amp;diff=318"/>
		<updated>2025-04-04T09:13:16Z</updated>

		<summary type="html">&lt;p&gt;Wikiadmin: Created page with &amp;quot;==Purpose==  Used for creating, editing and deleting notes against a professional in the Views system.  ===Base URL=== &amp;lt;nowiki&amp;gt;https://app.viewsapp.net/api/restful/contacts/professionals/&amp;lt;id&amp;gt;/notes&amp;lt;/nowiki&amp;gt;  ==Creating Notes==   curl --url &amp;lt;Base URL&amp;gt; -u&amp;lt;username&amp;gt;:&amp;lt;password&amp;gt; -H Content-Type:text/xml -X POST -d &amp;quot;&amp;lt;xml&amp;gt;&amp;quot;  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 th...&amp;quot;&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;==Purpose==&lt;br /&gt;
&lt;br /&gt;
Used for creating, editing and deleting notes against a professional in the Views system.&lt;br /&gt;
&lt;br /&gt;
===Base URL===&lt;br /&gt;
&amp;lt;nowiki&amp;gt;https://app.viewsapp.net/api/restful/contacts/professionals/&amp;lt;id&amp;gt;/notes&amp;lt;/nowiki&amp;gt;&lt;br /&gt;
&lt;br /&gt;
==Creating Notes==&lt;br /&gt;
&lt;br /&gt;
 curl --url &amp;lt;Base URL&amp;gt; -u&amp;lt;username&amp;gt;:&amp;lt;password&amp;gt; -H Content-Type:text/xml -X POST -d &amp;quot;&amp;lt;xml&amp;gt;&amp;quot;&lt;br /&gt;
&lt;br /&gt;
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.&lt;br /&gt;
&lt;br /&gt;
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.&lt;br /&gt;
&lt;br /&gt;
==Searching for a Note==&lt;br /&gt;
 curl --url &amp;lt;Base URL&amp;gt;/&amp;lt;id&amp;gt; -u&amp;lt;username&amp;gt;:&amp;lt;password&amp;gt; -H Content-Type:text/xml&lt;br /&gt;
&lt;br /&gt;
This will list all notes against a professional. you can append one of the following to limit the list:&lt;br /&gt;
* /contact - Professional only notes&lt;br /&gt;
* /attendance - Professional attendance notes&lt;br /&gt;
* /session - Notes on sessions that the professional is registered against&lt;br /&gt;
&lt;br /&gt;
By default ALL notes from the 3 categories are returned.&lt;br /&gt;
&lt;br /&gt;
==Fetching a Notes==&lt;br /&gt;
 curl --url &amp;lt;Base URL&amp;gt;/&amp;lt;id&amp;gt; -u&amp;lt;username&amp;gt;:&amp;lt;password&amp;gt; -H Content-Type:text/xml&lt;br /&gt;
&lt;br /&gt;
This method will only fetch Professional notes. If you attempt to fetch a note that is either of type attendance or session, &lt;br /&gt;
you will receive a 303 response directing you to the actual location of that note.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
==Updating a Note==&lt;br /&gt;
&#039;&#039;Please note&#039;&#039; You can only update professional notes via this api. For attendance and session notes, you should use the appropriate API.&lt;br /&gt;
&lt;br /&gt;
 curl --url &amp;lt;Base URL&amp;gt;/&amp;lt;id&amp;gt; -u&amp;lt;username&amp;gt;:&amp;lt;password&amp;gt; -H Content-Type:text/xml -X PUT -d &amp;quot;&amp;lt;xml&amp;gt;&amp;quot;&lt;br /&gt;
* id - The ID of the note&lt;br /&gt;
&lt;br /&gt;
The XML should be in the same format as the create, as specified by the schema&lt;br /&gt;
&lt;br /&gt;
==Deleting a Note==&lt;br /&gt;
&#039;&#039;Please note&#039;&#039; You can only update professional notes via this api. For attendance and session notes, you should use the appropriate API.&lt;br /&gt;
 curl --url &amp;lt;Base URL&amp;gt;/&amp;lt;id&amp;gt; -u&amp;lt;username&amp;gt;:&amp;lt;password&amp;gt; -H Content-Type:text/xml -X DELETE&lt;br /&gt;
* id - The ID of the note&lt;br /&gt;
&lt;br /&gt;
This should be used with great care as it will permanently delete a note record.&lt;/div&gt;</summary>
		<author><name>Wikiadmin</name></author>
	</entry>
	<entry>
		<id>https://www.substance.net/views-api-docs/index.php?title=Rest_-_Contacts_-_Professionals_-_Sessions&amp;diff=317</id>
		<title>Rest - Contacts - Professionals - Sessions</title>
		<link rel="alternate" type="text/html" href="https://www.substance.net/views-api-docs/index.php?title=Rest_-_Contacts_-_Professionals_-_Sessions&amp;diff=317"/>
		<updated>2025-04-04T09:11:09Z</updated>

		<summary type="html">&lt;p&gt;Wikiadmin: Created page with &amp;quot;==Purpose==  This is a read only service. It is a search API to return sessions that a professional is associated with.  ===Base URL=== &amp;lt;nowiki&amp;gt;https://app.viewsapp.net/api/restful/contacts/professionals/&amp;lt;id&amp;gt;/sessions&amp;lt;/nowiki&amp;gt;  ==Usage==   curl --url &amp;lt;Base URL&amp;gt;?q=&amp;lt;query&amp;gt; -u&amp;lt;username&amp;gt;:&amp;lt;password&amp;gt; -H Content-Type:text/xml   Calling the Base URL without any parameters will return all Sessions that a professional is associated with, regardless of their attendance status.   Pa...&amp;quot;&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;==Purpose==&lt;br /&gt;
&lt;br /&gt;
This is a read only service. It is a search API to return sessions that a professional is associated with.&lt;br /&gt;
&lt;br /&gt;
===Base URL===&lt;br /&gt;
&amp;lt;nowiki&amp;gt;https://app.viewsapp.net/api/restful/contacts/professionals/&amp;lt;id&amp;gt;/sessions&amp;lt;/nowiki&amp;gt;&lt;br /&gt;
&lt;br /&gt;
==Usage==&lt;br /&gt;
&lt;br /&gt;
 curl --url &amp;lt;Base URL&amp;gt;?q=&amp;lt;query&amp;gt; -u&amp;lt;username&amp;gt;:&amp;lt;password&amp;gt; -H Content-Type:text/xml &lt;br /&gt;
&lt;br /&gt;
Calling the Base URL without any parameters will return all Sessions that a professional is associated with, regardless of their attendance status. &lt;br /&gt;
&lt;br /&gt;
Parameter:&lt;br /&gt;
* q - string - A string to search the results for&lt;br /&gt;
* SessionGroupID - int - Restrict the results to a given Session Group&lt;br /&gt;
* Attended - int - 1 = Attended, 0 = Registered Only&lt;br /&gt;
&lt;br /&gt;
This returns something along the lines of:&lt;br /&gt;
 &amp;lt;?xml version=&amp;quot;1.0&amp;quot; encoding=&amp;quot;utf-8&amp;quot;?&amp;gt;&lt;br /&gt;
 &amp;lt;professional id=&amp;quot;104240&amp;quot;&amp;gt;&lt;br /&gt;
     &amp;lt;sessions&amp;gt;&lt;br /&gt;
         &amp;lt;session id=&amp;quot;164&amp;quot;&amp;gt;&lt;br /&gt;
             &amp;lt;SessionID&amp;gt;164&amp;lt;/SessionID&amp;gt;&lt;br /&gt;
             &amp;lt;SessionGroupID&amp;gt;38&amp;lt;/SessionGroupID&amp;gt;&lt;br /&gt;
             &amp;lt;Title&amp;gt;Session 1&amp;lt;/Title&amp;gt;&lt;br /&gt;
             &amp;lt;Type&amp;gt;Individual&amp;lt;/Type&amp;gt;&lt;br /&gt;
             &amp;lt;StartDate&amp;gt;2010-10-10T12:00&amp;lt;/StartDate&amp;gt;&lt;br /&gt;
             &amp;lt;Duration&amp;gt;01:00&amp;lt;/Duration&amp;gt;&lt;br /&gt;
             &amp;lt;Status&amp;gt;Booked&amp;lt;/Status&amp;gt;&lt;br /&gt;
             &amp;lt;Link&amp;gt;/restful/work/sessiongroups/sessions/164/participants&amp;lt;/Link&amp;gt;&lt;br /&gt;
         &amp;lt;/session&amp;gt;&lt;br /&gt;
         &amp;lt;session id=&amp;quot;573&amp;quot;&amp;gt;&lt;br /&gt;
             &amp;lt;SessionID&amp;gt;573&amp;lt;/SessionID&amp;gt;&lt;br /&gt;
             &amp;lt;SessionGroupID&amp;gt;7&amp;lt;/SessionGroupID&amp;gt;&lt;br /&gt;
             &amp;lt;Title&amp;gt;Session 2&amp;lt;/Title&amp;gt;&lt;br /&gt;
             &amp;lt;Type&amp;gt;Individual&amp;lt;/Type&amp;gt;&lt;br /&gt;
             &amp;lt;StartDate&amp;gt;2012-10-02T12:00&amp;lt;/StartDate&amp;gt;&lt;br /&gt;
             &amp;lt;Duration&amp;gt;01:00&amp;lt;/Duration&amp;gt;&lt;br /&gt;
             &amp;lt;Status&amp;gt;Attended&amp;lt;/Status&amp;gt;&lt;br /&gt;
             &amp;lt;Link&amp;gt;/restful/work/sessiongroups/sessions/573/participants&amp;lt;/Link&amp;gt;&lt;br /&gt;
         &amp;lt;/session&amp;gt;&lt;br /&gt;
     &amp;lt;/sessions&amp;gt;&lt;br /&gt;
 &amp;lt;/professional&amp;gt;&lt;/div&gt;</summary>
		<author><name>Wikiadmin</name></author>
	</entry>
	<entry>
		<id>https://www.substance.net/views-api-docs/index.php?title=Rest_-_Contacts_-_Groups_-_Questionnaires&amp;diff=316</id>
		<title>Rest - Contacts - Groups - Questionnaires</title>
		<link rel="alternate" type="text/html" href="https://www.substance.net/views-api-docs/index.php?title=Rest_-_Contacts_-_Groups_-_Questionnaires&amp;diff=316"/>
		<updated>2025-04-04T09:06:35Z</updated>

		<summary type="html">&lt;p&gt;Wikiadmin: Created page with &amp;quot;==Purpose==  Used for submitting answer sets to questionnaires against groups and for retrieving the details of answered questionnaires that have been submitted against a group. This is only really a filtered version of the Questionnaires - Answers API  ===Base URL=== &amp;lt;nowiki&amp;gt;https://app.viewsapp.net/api/restful/contacts/groups/&amp;lt;id&amp;gt;/questionnaires&amp;lt;/nowiki&amp;gt; * id - This is the group id  ===Schema=== For details of the schemas,...&amp;quot;&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;==Purpose==&lt;br /&gt;
&lt;br /&gt;
Used for submitting answer sets to questionnaires against groups and for retrieving the details of answered questionnaires that have been submitted against a group. This is only really a filtered version of the [[Rest - Evidence - Questionnaires - Answers|Questionnaires - Answers API]]&lt;br /&gt;
&lt;br /&gt;
===Base URL===&lt;br /&gt;
&amp;lt;nowiki&amp;gt;https://app.viewsapp.net/api/restful/contacts/groups/&amp;lt;id&amp;gt;/questionnaires&amp;lt;/nowiki&amp;gt;&lt;br /&gt;
* id - This is the group id&lt;br /&gt;
&lt;br /&gt;
===Schema===&lt;br /&gt;
For details of the schemas, please refer to [[Rest - Evidence - Questionnaires - Answers]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
==Fetching a list of answer sets==&lt;br /&gt;
The default call will return a list of questionnaires (answer sets) that have been recorded against the group&lt;br /&gt;
 curl --url &amp;lt;Base URL&amp;gt; -u&amp;lt;username&amp;gt;:&amp;lt;password&amp;gt; -H Content-Type:text/xml&lt;br /&gt;
&lt;br /&gt;
This will return data similar to the following:&lt;br /&gt;
 &amp;lt;answersets count=&amp;quot;7&amp;quot;&amp;gt;&lt;br /&gt;
     &amp;lt;answerset id=&amp;quot;1&amp;quot; questionnaireid=&amp;quot;14&amp;quot;&amp;gt;&lt;br /&gt;
         &amp;lt;EntityType&amp;gt;Group&amp;lt;/EntityType&amp;gt;&lt;br /&gt;
         &amp;lt;EntityID&amp;gt;1&amp;lt;/EntityID&amp;gt;&lt;br /&gt;
         &amp;lt;Date&amp;gt;2012-07-31T10:00:00&amp;lt;/Date&amp;gt;&lt;br /&gt;
         &amp;lt;QuestionnaireID&amp;gt;14&amp;lt;/QuestionnaireID&amp;gt;&lt;br /&gt;
         &amp;lt;AnswerSetID&amp;gt;1&amp;lt;/AnswerSetID&amp;gt;&lt;br /&gt;
         &amp;lt;Questionnaire&amp;gt;Impact&amp;lt;/Questionnaire&amp;gt;&lt;br /&gt;
     &amp;lt;/answerset&amp;gt;&lt;br /&gt;
     &amp;lt;answerset id=&amp;quot;4&amp;quot; questionnaireid=&amp;quot;5&amp;quot;&amp;gt;&lt;br /&gt;
         &amp;lt;EntityType&amp;gt;Group&amp;lt;/EntityType&amp;gt;&lt;br /&gt;
         &amp;lt;EntityID&amp;gt;1&amp;lt;/EntityID&amp;gt;&lt;br /&gt;
         &amp;lt;Date&amp;gt;2012-05-04T10:11:00&amp;lt;/Date&amp;gt;&lt;br /&gt;
         &amp;lt;QuestionnaireID&amp;gt;14&amp;lt;/QuestionnaireID&amp;gt;&lt;br /&gt;
         &amp;lt;AnswerSetID&amp;gt;4&amp;lt;/AnswerSetID&amp;gt;&lt;br /&gt;
         &amp;lt;Questionnaire&amp;gt;Interests&amp;lt;/Questionnaire&amp;gt;&lt;br /&gt;
     &amp;lt;/answerset&amp;gt;&lt;br /&gt;
     ...&lt;br /&gt;
 &amp;lt;/answersets&amp;gt;&lt;br /&gt;
&lt;br /&gt;
If you are only interested in a particular questionnaire, you should us the following:&lt;br /&gt;
 curl --url &amp;lt;Base URL&amp;gt;/&amp;lt;questionnairId&amp;gt; -u&amp;lt;username&amp;gt;:&amp;lt;password&amp;gt; -H Content-Type:text/xml&lt;br /&gt;
&lt;br /&gt;
This will return data similar to the following:&lt;br /&gt;
 &amp;lt;answersets count=&amp;quot;2&amp;quot;&amp;gt;&lt;br /&gt;
     &amp;lt;answerset id=&amp;quot;1&amp;quot; questionnaireid=&amp;quot;14&amp;quot;&amp;gt;&lt;br /&gt;
         &amp;lt;EntityType&amp;gt;Group&amp;lt;/EntityType&amp;gt;&lt;br /&gt;
         &amp;lt;EntityID&amp;gt;1&amp;lt;/EntityID&amp;gt;&lt;br /&gt;
         &amp;lt;Date&amp;gt;2012-07-31T10:00:00&amp;lt;/Date&amp;gt;&lt;br /&gt;
         &amp;lt;QuestionnaireID&amp;gt;14&amp;lt;/QuestionnaireID&amp;gt;&lt;br /&gt;
         &amp;lt;AnswerSetID&amp;gt;1&amp;lt;/AnswerSetID&amp;gt;&lt;br /&gt;
         &amp;lt;Questionnaire&amp;gt;Impact&amp;lt;/Questionnaire&amp;gt;&lt;br /&gt;
     &amp;lt;/answerset&amp;gt;&lt;br /&gt;
     &amp;lt;answerset id=&amp;quot;6&amp;quot; questionnaireid=&amp;quot;14&amp;quot;&amp;gt;&lt;br /&gt;
         &amp;lt;EntityType&amp;gt;Group&amp;lt;/EntityType&amp;gt;&lt;br /&gt;
         &amp;lt;EntityID&amp;gt;1&amp;lt;/EntityID&amp;gt;&lt;br /&gt;
         &amp;lt;Date&amp;gt;2012-05-02T09:10:00&amp;lt;/Date&amp;gt;&lt;br /&gt;
         &amp;lt;QuestionnaireID&amp;gt;14&amp;lt;/QuestionnaireID&amp;gt;&lt;br /&gt;
         &amp;lt;AnswerSetID&amp;gt;6&amp;lt;/AnswerSetID&amp;gt;&lt;br /&gt;
         &amp;lt;Questionnaire&amp;gt;Impact&amp;lt;/Questionnaire&amp;gt;&lt;br /&gt;
     &amp;lt;/answerset&amp;gt;&lt;br /&gt;
 &amp;lt;/answersets&amp;gt;&lt;br /&gt;
&lt;br /&gt;
The results are order by the most recent first. This means to get the latest version of a questionnaire, you would only need to fetch the first result.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
==Fetching the answers of a given questionnaire==&lt;br /&gt;
 curl --url &amp;lt;Base URL&amp;gt;/&amp;lt;questionnairId&amp;gt;/&amp;lt;setId&amp;gt; -u&amp;lt;username&amp;gt;:&amp;lt;password&amp;gt; -H Content-Type:text/xml&lt;br /&gt;
* questionnaireId - This is the id of the questionnaire&lt;br /&gt;
* setId - This is the id of the Answers Set you want to retrieve&lt;br /&gt;
&lt;br /&gt;
It&#039;s will return something along the lines of&lt;br /&gt;
 &amp;lt;answerset questionaireid=&amp;quot;14&amp;quot; id=&amp;quot;1&amp;quot;&amp;gt;&lt;br /&gt;
     &amp;lt;EntityType&amp;gt;Group&amp;lt;/EntityType&amp;gt;&lt;br /&gt;
     &amp;lt;EntityID&amp;gt;1&amp;lt;/EntityID&amp;gt;&lt;br /&gt;
     &amp;lt;TargetType/&amp;gt;&lt;br /&gt;
     &amp;lt;TargetID&amp;gt;0&amp;lt;/TargetID&amp;gt;&lt;br /&gt;
     &amp;lt;Date&amp;gt;2012-07-31T10:00:00&amp;lt;/Date&amp;gt;&lt;br /&gt;
     &amp;lt;answers count=&amp;quot;9&amp;quot;&amp;gt;&lt;br /&gt;
         &amp;lt;answer id=&amp;quot;78&amp;quot;&amp;gt;&lt;br /&gt;
             &amp;lt;QuestionID&amp;gt;78&amp;lt;/QuestionID&amp;gt;&lt;br /&gt;
             &amp;lt;Answer&amp;gt;Fully Agree&amp;lt;/Answer&amp;gt;&lt;br /&gt;
         &amp;lt;/answer&amp;gt;&lt;br /&gt;
         &amp;lt;answer id=&amp;quot;79&amp;quot;&amp;gt;&lt;br /&gt;
             &amp;lt;QuestionID&amp;gt;79&amp;lt;/QuestionID&amp;gt;&lt;br /&gt;
             &amp;lt;Answer&amp;gt;Truly Agree&amp;lt;/Answer&amp;gt;&lt;br /&gt;
         &amp;lt;/answer&amp;gt;&lt;br /&gt;
         &amp;lt;answer id=&amp;quot;80&amp;quot;&amp;gt;&lt;br /&gt;
             &amp;lt;QuestionID&amp;gt;80&amp;lt;/QuestionID&amp;gt;&lt;br /&gt;
             &amp;lt;Answer&amp;gt;Agree&amp;lt;/Answer&amp;gt;&lt;br /&gt;
         &amp;lt;/answer&amp;gt;&lt;br /&gt;
         ...&lt;br /&gt;
     &amp;lt;/answers&amp;gt;&lt;br /&gt;
 &amp;lt;/answerset&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
==Fetching a single answer from a questionnaire==&lt;br /&gt;
 curl --url &amp;lt;Base URL&amp;gt;/&amp;lt;questionnairId&amp;gt;/&amp;lt;setId&amp;gt;/&amp;lt;questionId&amp;gt; -u&amp;lt;username&amp;gt;:&amp;lt;password&amp;gt; -H Content-Type:text/xml&lt;br /&gt;
* questionnaireId - This is the id of the questionnaire&lt;br /&gt;
* setId - This is the id of the Answers Set you want to retrieve&lt;br /&gt;
* questionId - This is the id of the question you want the answer for&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;answer id=&amp;quot;78&amp;quot;&amp;gt;&lt;br /&gt;
     &amp;lt;QuestionnaireID&amp;gt;14&amp;lt;/QuestionnaireID&amp;gt;&lt;br /&gt;
     &amp;lt;AnswerSetID&amp;gt;1&amp;lt;/AnswerSetID&amp;gt;&lt;br /&gt;
     &amp;lt;QuestionID&amp;gt;78&amp;lt;/QuestionID&amp;gt;&lt;br /&gt;
     &amp;lt;Answer&amp;gt;Fully Agree&amp;lt;/Answer&amp;gt;&lt;br /&gt;
 &amp;lt;/answer&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
==Creating a new Answer Set==&lt;br /&gt;
 curl --url &amp;lt;Base URL&amp;gt;/&amp;lt;questionnairId&amp;gt; -u&amp;lt;username&amp;gt;:&amp;lt;password&amp;gt; -H Content-Type:text/xml -X POST -d &#039;&amp;lt;xml&amp;gt;&#039;&lt;br /&gt;
&lt;br /&gt;
To submit a new set of answers against a questionnaire, you should send data in the following structure:&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;answers&amp;gt;&lt;br /&gt;
     &amp;lt;Date&amp;gt;2012-07-31T10:00:00&amp;lt;/Date&amp;gt;&lt;br /&gt;
     &amp;lt;answer id=&amp;quot;78&amp;quot;&amp;gt;&lt;br /&gt;
       &amp;lt;QuestionID&amp;gt;78&amp;lt;/QuestionID&amp;gt;&lt;br /&gt;
       &amp;lt;Answer&amp;gt;Fully Agree&amp;lt;/Answer&amp;gt;&lt;br /&gt;
     &amp;lt;/answer&amp;gt;&lt;br /&gt;
     &amp;lt;answer id=&amp;quot;79&amp;quot;&amp;gt;&lt;br /&gt;
       &amp;lt;QuestionID&amp;gt;79&amp;lt;/QuestionID&amp;gt;&lt;br /&gt;
       &amp;lt;Answer&amp;gt;Truly Agree&amp;lt;/Answer&amp;gt;&lt;br /&gt;
     &amp;lt;/answer&amp;gt;&lt;br /&gt;
     ...&lt;br /&gt;
 &amp;lt;/answers&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Note:&#039;&#039;&#039; If you specify the attribute &#039;&#039;&amp;lt;code&amp;gt;id&amp;lt;/code&amp;gt;&#039;&#039; then you do not need to specify the &amp;lt;code&amp;gt;&amp;lt;QuestionID&amp;gt;&amp;lt;/code&amp;gt; entity.&lt;br /&gt;
&lt;br /&gt;
You can also relate the questionnaire to a Session (and SessionGroup) by specifying the &amp;lt;code&amp;gt;&amp;lt;TargetType&amp;gt;&amp;lt;/code&amp;gt; and &amp;lt;code&amp;gt;&amp;lt;TargetID&amp;gt;&amp;lt;/code&amp;gt; entities&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;answers&amp;gt;&lt;br /&gt;
     &amp;lt;TargetType&amp;gt;Session&amp;lt;/TargetType&amp;gt;&lt;br /&gt;
     &amp;lt;TargetID&amp;gt;214&amp;lt;/TargetID&amp;gt;&lt;br /&gt;
     &amp;lt;Date&amp;gt;2012-07-31T10:00:00&amp;lt;/Date&amp;gt;&lt;br /&gt;
     &amp;lt;answer id=&amp;quot;78&amp;quot;&amp;gt;&lt;br /&gt;
       &amp;lt;QuestionID&amp;gt;78&amp;lt;/QuestionID&amp;gt;&lt;br /&gt;
       &amp;lt;Answer&amp;gt;Fully Agree&amp;lt;/Answer&amp;gt;&lt;br /&gt;
     &amp;lt;/answer&amp;gt;&lt;br /&gt;
     ....&lt;br /&gt;
 &amp;lt;/answers&amp;gt;&lt;br /&gt;
&lt;br /&gt;
You can also omit the &amp;lt;code&amp;gt;&amp;lt;Date&amp;gt;&amp;lt;/code&amp;gt; entity. If you do this, then the current system date/time will be used.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
==Updating an existing Answer Set==&lt;br /&gt;
 curl --url &amp;lt;Base URL&amp;gt;/&amp;lt;questionnairId&amp;gt;/&amp;lt;setid&amp;gt; -u&amp;lt;username&amp;gt;:&amp;lt;password&amp;gt; -H Content-Type:text/xml -X PUT -d &#039;&amp;lt;xml&amp;gt;&#039;&lt;br /&gt;
&lt;br /&gt;
When updating the answers in an answer set, you should use the same structure as when creating a new answer set. However, if you specify the entities &amp;lt;code&amp;gt;TargetType&amp;gt;&amp;lt;/code&amp;gt; and &amp;lt;code&amp;gt;TargetID&amp;gt;&amp;lt;/code&amp;gt; they will be ignored.&lt;/div&gt;</summary>
		<author><name>Wikiadmin</name></author>
	</entry>
	<entry>
		<id>https://www.substance.net/views-api-docs/index.php?title=Rest_-_Contacts_-_Groups_-_Address_Book&amp;diff=315</id>
		<title>Rest - Contacts - Groups - Address Book</title>
		<link rel="alternate" type="text/html" href="https://www.substance.net/views-api-docs/index.php?title=Rest_-_Contacts_-_Groups_-_Address_Book&amp;diff=315"/>
		<updated>2025-04-04T09:03:29Z</updated>

		<summary type="html">&lt;p&gt;Wikiadmin: Created page with &amp;quot;==Purpose==  Used for creating, editing and deleting address book entries against a group in the Views system.  ===Base URL=== &amp;lt;nowiki&amp;gt;https://app.viewsapp.net/api/restful/contacts/groups/&amp;lt;id&amp;gt;/addressbook&amp;lt;/nowiki&amp;gt;  ===Schema=== &amp;lt;nowiki&amp;gt;https://app.viewsapp.net/api/restful/contacts/groups/&amp;lt;id&amp;gt;/addressbook/scheme(.xml|.json|.xsd)&amp;lt;/nowiki&amp;gt;  ==Creating Address Book Entries==   curl --url &amp;lt;Base URL&amp;gt; -u&amp;lt;username&amp;gt;:&amp;lt;password&amp;gt; -H Content-Type:text/xml -X POST -d &amp;quot;&amp;lt;xml&amp;gt;&amp;quot;   &amp;lt;xml&amp;gt; s...&amp;quot;&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;==Purpose==&lt;br /&gt;
&lt;br /&gt;
Used for creating, editing and deleting address book entries against a group in the Views system.&lt;br /&gt;
&lt;br /&gt;
===Base URL===&lt;br /&gt;
&amp;lt;nowiki&amp;gt;https://app.viewsapp.net/api/restful/contacts/groups/&amp;lt;id&amp;gt;/addressbook&amp;lt;/nowiki&amp;gt;&lt;br /&gt;
&lt;br /&gt;
===Schema===&lt;br /&gt;
&amp;lt;nowiki&amp;gt;https://app.viewsapp.net/api/restful/contacts/groups/&amp;lt;id&amp;gt;/addressbook/scheme(.xml|.json|.xsd)&amp;lt;/nowiki&amp;gt;&lt;br /&gt;
&lt;br /&gt;
==Creating Address Book Entries==&lt;br /&gt;
&lt;br /&gt;
 curl --url &amp;lt;Base URL&amp;gt; -u&amp;lt;username&amp;gt;:&amp;lt;password&amp;gt; -H Content-Type:text/xml -X POST -d &amp;quot;&amp;lt;xml&amp;gt;&amp;quot;&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;xml&amp;gt; should be in the following format:&lt;br /&gt;
 &amp;lt;entry&amp;gt;&lt;br /&gt;
      &amp;lt;Forename&amp;gt;Jane&amp;lt;/Forename&amp;gt;&lt;br /&gt;
      &amp;lt;Surname&amp;gt;Smith&amp;lt;/Surname&amp;gt;&lt;br /&gt;
      &amp;lt;Type&amp;gt;Next of Kin&amp;lt;/Type&amp;gt;&lt;br /&gt;
      &amp;lt;Relation&amp;gt;Wife&amp;lt;/Relation&amp;gt;&lt;br /&gt;
      &amp;lt;Address1&amp;gt;&amp;lt;/Address1&amp;gt;&lt;br /&gt;
      &amp;lt;Address2&amp;gt;&amp;lt;/Address2&amp;gt;&lt;br /&gt;
      &amp;lt;Town&amp;gt;The Sticks&amp;lt;/Town&amp;gt;&lt;br /&gt;
      &amp;lt;County&amp;gt;&amp;lt;/County&amp;gt;&lt;br /&gt;
      &amp;lt;Postcode&amp;gt;&amp;lt;/Postcode&amp;gt;&lt;br /&gt;
      &amp;lt;Telephone&amp;gt;&amp;lt;/Telephone&amp;gt;&lt;br /&gt;
      &amp;lt;Mobile&amp;gt;&amp;lt;/Mobile&amp;gt;&lt;br /&gt;
      &amp;lt;Email&amp;gt;&amp;lt;/Email&amp;gt;&lt;br /&gt;
      &amp;lt;CanCollect&amp;gt;1&amp;lt;/CanCollect&amp;gt;&lt;br /&gt;
 &amp;lt;/entry&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
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.&lt;br /&gt;
&lt;br /&gt;
If the record was created successfully, the service will return a complete record for the newly created record if the attribute id set as the newly created id.&lt;br /&gt;
&lt;br /&gt;
==Listing Address Book Entries==&lt;br /&gt;
 curl --url &amp;lt;Base URL&amp;gt;/&amp;lt;id&amp;gt; -u&amp;lt;username&amp;gt;:&amp;lt;password&amp;gt; -H Content-Type:text/xml&lt;br /&gt;
&lt;br /&gt;
This will list all address book entries under a group. I you wish to filter the address book to only return entries that are allowed to pick the group up from Sessions etc, then you can append the following:&lt;br /&gt;
* /authorisedcollectors&lt;br /&gt;
&lt;br /&gt;
==Fetching an Address Book Entry==&lt;br /&gt;
 curl --url &amp;lt;Base URL&amp;gt;/&amp;lt;id&amp;gt; -u&amp;lt;username&amp;gt;:&amp;lt;password&amp;gt; -H Content-Type:text/xml&lt;br /&gt;
* id - The ID of the address book entry&lt;br /&gt;
&lt;br /&gt;
This will return a records similar to the following:&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;?xml version=&amp;quot;1.0&amp;quot; encoding=&amp;quot;utf-8&amp;quot;?&amp;gt;&lt;br /&gt;
 &amp;lt;entry id=&amp;quot;41&amp;quot;&amp;gt;&lt;br /&gt;
     &amp;lt;EntryID&amp;gt;41&amp;lt;/EntryID&amp;gt;&lt;br /&gt;
     &amp;lt;ContactType&amp;gt;Group&amp;lt;/ContactType&amp;gt;&lt;br /&gt;
     &amp;lt;ContactID&amp;gt;100554&amp;lt;/ContactID&amp;gt;&lt;br /&gt;
     &amp;lt;Forename&amp;gt;Jane&amp;lt;/Forename&amp;gt;&lt;br /&gt;
     &amp;lt;Surname&amp;gt;Smith&amp;lt;/Surname&amp;gt;&lt;br /&gt;
     &amp;lt;Type&amp;gt;Next of Kin&amp;lt;/Type&amp;gt;&lt;br /&gt;
     &amp;lt;Relation&amp;gt;Wife&amp;lt;/Relation&amp;gt;&lt;br /&gt;
     &amp;lt;Address1&amp;gt;&amp;lt;/Address1&amp;gt;&lt;br /&gt;
     &amp;lt;Address2&amp;gt;&amp;lt;/Address2&amp;gt;&lt;br /&gt;
     &amp;lt;Town&amp;gt;The Sticks&amp;lt;/Town&amp;gt;&lt;br /&gt;
     &amp;lt;County&amp;gt;&amp;lt;/County&amp;gt;&lt;br /&gt;
     &amp;lt;Postcode&amp;gt;&amp;lt;/Postcode&amp;gt;&lt;br /&gt;
     &amp;lt;Telephone&amp;gt;&amp;lt;/Telephone&amp;gt;&lt;br /&gt;
     &amp;lt;Mobile&amp;gt;&amp;lt;/Mobile&amp;gt;&lt;br /&gt;
     &amp;lt;Email&amp;gt;&amp;lt;/Email&amp;gt;&lt;br /&gt;
     &amp;lt;CanCollect&amp;gt;1&amp;lt;/CanCollect&amp;gt;&lt;br /&gt;
     &amp;lt;Created&amp;gt;2012-07-05 10:09:36&amp;lt;/Created&amp;gt;&lt;br /&gt;
     &amp;lt;CreatedBy&amp;gt;al.mccaig.transit&amp;lt;/CreatedBy&amp;gt;&lt;br /&gt;
     &amp;lt;Updated&amp;gt;2012-07-05 10:51:00&amp;lt;/Updated&amp;gt;&lt;br /&gt;
     &amp;lt;UpdatedBy&amp;gt;al.mccaig.transit&amp;lt;/UpdatedBy&amp;gt;&lt;br /&gt;
 &amp;lt;/entry&amp;gt;&lt;br /&gt;
&lt;br /&gt;
==Updating an Address Book Entry==&lt;br /&gt;
 curl --url &amp;lt;Base URL&amp;gt;/&amp;lt;id&amp;gt; -u&amp;lt;username&amp;gt;:&amp;lt;password&amp;gt; -H Content-Type:text/xml -X PUT -d &amp;quot;&amp;lt;xml&amp;gt;&amp;quot;&lt;br /&gt;
* id - The ID of the address book entry&lt;br /&gt;
&lt;br /&gt;
The XML should be in the same format as the create, as specified by the schema&lt;br /&gt;
&lt;br /&gt;
==Deleting an Address Book Entry==&lt;br /&gt;
 curl --url &amp;lt;Base URL&amp;gt;/&amp;lt;id&amp;gt; -u&amp;lt;username&amp;gt;:&amp;lt;password&amp;gt; -H Content-Type:text/xml -X DELETE&lt;br /&gt;
* id - The ID of the address book entry&lt;br /&gt;
&lt;br /&gt;
This should be used with great care as it will permanently delete an address book entry.&lt;/div&gt;</summary>
		<author><name>Wikiadmin</name></author>
	</entry>
	<entry>
		<id>https://www.substance.net/views-api-docs/index.php?title=Rest_-_Contacts_-_Groups_-_Notes&amp;diff=314</id>
		<title>Rest - Contacts - Groups - Notes</title>
		<link rel="alternate" type="text/html" href="https://www.substance.net/views-api-docs/index.php?title=Rest_-_Contacts_-_Groups_-_Notes&amp;diff=314"/>
		<updated>2025-04-04T08:59:28Z</updated>

		<summary type="html">&lt;p&gt;Wikiadmin: Created page with &amp;quot;==Purpose==  Used for creating, editing and deleting notes against a group in the Views system.  ===Base URL=== &amp;lt;nowiki&amp;gt;https://app.viewsapp.net/api/restful/contacts/groups/&amp;lt;id&amp;gt;/notes&amp;lt;/nowiki&amp;gt;  ==Creating Notes==   curl --url &amp;lt;Base URL&amp;gt; -u&amp;lt;username&amp;gt;:&amp;lt;password&amp;gt; -H Content-Type:text/xml -X POST -d &amp;quot;&amp;lt;xml&amp;gt;&amp;quot;  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 c...&amp;quot;&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;==Purpose==&lt;br /&gt;
&lt;br /&gt;
Used for creating, editing and deleting notes against a group in the Views system.&lt;br /&gt;
&lt;br /&gt;
===Base URL===&lt;br /&gt;
&amp;lt;nowiki&amp;gt;https://app.viewsapp.net/api/restful/contacts/groups/&amp;lt;id&amp;gt;/notes&amp;lt;/nowiki&amp;gt;&lt;br /&gt;
&lt;br /&gt;
==Creating Notes==&lt;br /&gt;
&lt;br /&gt;
 curl --url &amp;lt;Base URL&amp;gt; -u&amp;lt;username&amp;gt;:&amp;lt;password&amp;gt; -H Content-Type:text/xml -X POST -d &amp;quot;&amp;lt;xml&amp;gt;&amp;quot;&lt;br /&gt;
&lt;br /&gt;
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.&lt;br /&gt;
&lt;br /&gt;
If the record was created successfully, the service will return a complete record for the newly created record if the attribute id set as the newly created id.&lt;br /&gt;
&lt;br /&gt;
==Searching for a Note==&lt;br /&gt;
 curl --url &amp;lt;Base URL&amp;gt;/&amp;lt;id&amp;gt; -u&amp;lt;username&amp;gt;:&amp;lt;password&amp;gt; -H Content-Type:text/xml&lt;br /&gt;
&lt;br /&gt;
This will list all notes against a group. you can append one of the following to limit the list:&lt;br /&gt;
* /contact - Group only notes&lt;br /&gt;
* /attendance - Group attendance notes&lt;br /&gt;
* /session - Notes on sessions that the group is registered against&lt;br /&gt;
&lt;br /&gt;
By default ALL notes from the 3 categories are returned.&lt;br /&gt;
&lt;br /&gt;
==Fetching a Notes==&lt;br /&gt;
 curl --url &amp;lt;Base URL&amp;gt;/&amp;lt;id&amp;gt; -u&amp;lt;username&amp;gt;:&amp;lt;password&amp;gt; -H Content-Type:text/xml&lt;br /&gt;
&lt;br /&gt;
This method will only fetch Group notes. If you attempt to fetch a note that is either of type attendance or session, &lt;br /&gt;
you will receive a 303 response directing you to the actual location of that note.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
==Updating a Note==&lt;br /&gt;
&#039;&#039;Please note&#039;&#039; You can only update group notes via this api. For attendance and session notes, you should use the appropriate API.&lt;br /&gt;
&lt;br /&gt;
 curl --url &amp;lt;Base URL&amp;gt;/&amp;lt;id&amp;gt; -u&amp;lt;username&amp;gt;:&amp;lt;password&amp;gt; -H Content-Type:text/xml -X PUT -d &amp;quot;&amp;lt;xml&amp;gt;&amp;quot;&lt;br /&gt;
* id - The ID of the note&lt;br /&gt;
&lt;br /&gt;
The XML should be in the same format as the create, as specified by the schema&lt;br /&gt;
&lt;br /&gt;
==Deleting a Note==&lt;br /&gt;
&#039;&#039;Please note&#039;&#039; You can only update group notes via this api. For attendance and session notes, you should use the appropriate API.&lt;br /&gt;
 curl --url &amp;lt;Base URL&amp;gt;/&amp;lt;id&amp;gt; -u&amp;lt;username&amp;gt;:&amp;lt;password&amp;gt; -H Content-Type:text/xml -X DELETE&lt;br /&gt;
* id - The ID of the note&lt;br /&gt;
&lt;br /&gt;
This should be used with great care as it will permanently delete a note record.&lt;/div&gt;</summary>
		<author><name>Wikiadmin</name></author>
	</entry>
	<entry>
		<id>https://www.substance.net/views-api-docs/index.php?title=Rest_-_Contacts_-_Groups_-_Sessions&amp;diff=313</id>
		<title>Rest - Contacts - Groups - Sessions</title>
		<link rel="alternate" type="text/html" href="https://www.substance.net/views-api-docs/index.php?title=Rest_-_Contacts_-_Groups_-_Sessions&amp;diff=313"/>
		<updated>2025-04-04T08:56:44Z</updated>

		<summary type="html">&lt;p&gt;Wikiadmin: Created page with &amp;quot;==Purpose==  This is a read only service. It is a search API to return sessions that a group is associated with.  ===Base URL=== &amp;lt;nowiki&amp;gt;https://app.viewsapp.net/api/restful/contacts/groups/&amp;lt;id&amp;gt;/sessions&amp;lt;/nowiki&amp;gt;  ==Usage==   curl --url &amp;lt;Base URL&amp;gt;?q=&amp;lt;query&amp;gt; -u&amp;lt;username&amp;gt;:&amp;lt;password&amp;gt; -H Content-Type:text/xml   Calling the Base URL without any parameters will return all Sessions that a group is associated with, regardless of their attendance status.   Parameter: * q - string...&amp;quot;&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;==Purpose==&lt;br /&gt;
&lt;br /&gt;
This is a read only service. It is a search API to return sessions that a group is associated with.&lt;br /&gt;
&lt;br /&gt;
===Base URL===&lt;br /&gt;
&amp;lt;nowiki&amp;gt;https://app.viewsapp.net/api/restful/contacts/groups/&amp;lt;id&amp;gt;/sessions&amp;lt;/nowiki&amp;gt;&lt;br /&gt;
&lt;br /&gt;
==Usage==&lt;br /&gt;
&lt;br /&gt;
 curl --url &amp;lt;Base URL&amp;gt;?q=&amp;lt;query&amp;gt; -u&amp;lt;username&amp;gt;:&amp;lt;password&amp;gt; -H Content-Type:text/xml &lt;br /&gt;
&lt;br /&gt;
Calling the Base URL without any parameters will return all Sessions that a group is associated with, regardless of their attendance status. &lt;br /&gt;
&lt;br /&gt;
Parameter:&lt;br /&gt;
* q - string - A string to search the results for&lt;br /&gt;
* SessionGroupID - int - Restrict the results to a given Session Group&lt;br /&gt;
* Attended - int - 1 = Attended, 0 = Registered Only&lt;br /&gt;
&lt;br /&gt;
This returns something along the lines of:&lt;br /&gt;
 &amp;lt;?xml version=&amp;quot;1.0&amp;quot; encoding=&amp;quot;utf-8&amp;quot;?&amp;gt;&lt;br /&gt;
 &amp;lt;group id=&amp;quot;104240&amp;quot;&amp;gt;&lt;br /&gt;
     &amp;lt;sessions&amp;gt;&lt;br /&gt;
         &amp;lt;session id=&amp;quot;164&amp;quot;&amp;gt;&lt;br /&gt;
             &amp;lt;SessionID&amp;gt;164&amp;lt;/SessionID&amp;gt;&lt;br /&gt;
             &amp;lt;SessionGroupID&amp;gt;38&amp;lt;/SessionGroupID&amp;gt;&lt;br /&gt;
             &amp;lt;Title&amp;gt;Session 1&amp;lt;/Title&amp;gt;&lt;br /&gt;
             &amp;lt;Type&amp;gt;Individual&amp;lt;/Type&amp;gt;&lt;br /&gt;
             &amp;lt;StartDate&amp;gt;2010-10-10T12:00&amp;lt;/StartDate&amp;gt;&lt;br /&gt;
             &amp;lt;Duration&amp;gt;01:00&amp;lt;/Duration&amp;gt;&lt;br /&gt;
             &amp;lt;Status&amp;gt;Booked&amp;lt;/Status&amp;gt;&lt;br /&gt;
             &amp;lt;Link&amp;gt;/restful/work/sessiongroups/sessions/164/participants&amp;lt;/Link&amp;gt;&lt;br /&gt;
         &amp;lt;/session&amp;gt;&lt;br /&gt;
         &amp;lt;session id=&amp;quot;573&amp;quot;&amp;gt;&lt;br /&gt;
             &amp;lt;SessionID&amp;gt;573&amp;lt;/SessionID&amp;gt;&lt;br /&gt;
             &amp;lt;SessionGroupID&amp;gt;7&amp;lt;/SessionGroupID&amp;gt;&lt;br /&gt;
             &amp;lt;Title&amp;gt;Session 2&amp;lt;/Title&amp;gt;&lt;br /&gt;
             &amp;lt;Type&amp;gt;Individual&amp;lt;/Type&amp;gt;&lt;br /&gt;
             &amp;lt;StartDate&amp;gt;2012-10-02T12:00&amp;lt;/StartDate&amp;gt;&lt;br /&gt;
             &amp;lt;Duration&amp;gt;01:00&amp;lt;/Duration&amp;gt;&lt;br /&gt;
             &amp;lt;Status&amp;gt;Attended&amp;lt;/Status&amp;gt;&lt;br /&gt;
             &amp;lt;Link&amp;gt;/restful/work/sessiongroups/sessions/573/participants&amp;lt;/Link&amp;gt;&lt;br /&gt;
         &amp;lt;/session&amp;gt;&lt;br /&gt;
     &amp;lt;/sessions&amp;gt;&lt;br /&gt;
 &amp;lt;/group&amp;gt;&lt;/div&gt;</summary>
		<author><name>Wikiadmin</name></author>
	</entry>
	<entry>
		<id>https://www.substance.net/views-api-docs/index.php?title=Rest_-_Contacts_-_Professionals&amp;diff=312</id>
		<title>Rest - Contacts - Professionals</title>
		<link rel="alternate" type="text/html" href="https://www.substance.net/views-api-docs/index.php?title=Rest_-_Contacts_-_Professionals&amp;diff=312"/>
		<updated>2025-04-04T08:53:30Z</updated>

		<summary type="html">&lt;p&gt;Wikiadmin: Created page with &amp;quot;==Purpose==  Used for creating, editing and deleting Professionals from the Views system.  ===Base URL=== https://app.viewsapp.net/api/restful/contacts/professionals  ===Schema=== &amp;lt;nowiki&amp;gt;https://app.viewsapp.net/api/restful/contacts/professionals/schema(.xml|.json|.xsd)&amp;lt;/nowiki&amp;gt;  ==Creating a professional==  Once you have created your data file, you can send it using the following:   curl --url &amp;lt;Base URL&amp;gt; -u&amp;lt;username&amp;gt;:&amp;lt;password&amp;gt; -H Content-Type:text/xml -X POST -d &amp;quot;&amp;lt;xml...&amp;quot;&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;==Purpose==&lt;br /&gt;
&lt;br /&gt;
Used for creating, editing and deleting Professionals from the Views system.&lt;br /&gt;
&lt;br /&gt;
===Base URL===&lt;br /&gt;
https://app.viewsapp.net/api/restful/contacts/professionals&lt;br /&gt;
&lt;br /&gt;
===Schema===&lt;br /&gt;
&amp;lt;nowiki&amp;gt;https://app.viewsapp.net/api/restful/contacts/professionals/schema(.xml|.json|.xsd)&amp;lt;/nowiki&amp;gt;&lt;br /&gt;
&lt;br /&gt;
==Creating a professional==&lt;br /&gt;
&lt;br /&gt;
Once you have created your data file, you can send it using the following:&lt;br /&gt;
&lt;br /&gt;
 curl --url &amp;lt;Base URL&amp;gt; -u&amp;lt;username&amp;gt;:&amp;lt;password&amp;gt; -H Content-Type:text/xml -X POST -d &amp;quot;&amp;lt;xml&amp;gt;&amp;quot;&lt;br /&gt;
&lt;br /&gt;
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.&lt;br /&gt;
&lt;br /&gt;
If the record was created successfully, the service will return a complete record for the newly created record if the attribute id set as the newly created id.&lt;br /&gt;
&lt;br /&gt;
==Fetching a professional==&lt;br /&gt;
 curl --url &amp;lt;Base URL&amp;gt;/&amp;lt;id&amp;gt; -u&amp;lt;username&amp;gt;:&amp;lt;password&amp;gt; -H Content-Type:text/xml&lt;br /&gt;
&lt;br /&gt;
This will return an xml file similar to this&lt;br /&gt;
 &amp;lt;?xml version=&amp;quot;1.0&amp;quot; encoding=&amp;quot;utf-8&amp;quot;?&amp;gt;&lt;br /&gt;
 &amp;lt;professional id=&amp;quot;100001&amp;quot;&amp;gt;&lt;br /&gt;
    &amp;lt;Nickname&amp;gt;&amp;lt;/Nickname&amp;gt;&lt;br /&gt;
    &amp;lt;Forename&amp;gt;John&amp;lt;/Forename&amp;gt;&lt;br /&gt;
    &amp;lt;Surname&amp;gt;Smith&amp;lt;/Surname&amp;gt;&lt;br /&gt;
    ...&lt;br /&gt;
    &amp;lt;Created&amp;gt;2011-05-09 10:26:09&amp;lt;/Created&amp;gt;&lt;br /&gt;
    &amp;lt;CreatedBy&amp;gt;a.user&amp;lt;/CreatedBy&amp;gt;&lt;br /&gt;
    &amp;lt;Updated&amp;gt;2011-05-09 10:26:09&amp;lt;/Updated&amp;gt;&lt;br /&gt;
    &amp;lt;UpdatedBy&amp;gt;a.user&amp;lt;/UpdatedBy&amp;gt;&lt;br /&gt;
    &amp;lt;Archived&amp;gt;0000-00-00 00:00:00&amp;lt;/Archived&amp;gt;&lt;br /&gt;
    &amp;lt;ArchivedBy&amp;gt;&amp;lt;/ArchivedBy&amp;gt;&lt;br /&gt;
    &amp;lt;Type&amp;gt;16&amp;lt;/Type&amp;gt;&lt;br /&gt;
    &amp;lt;PersonID&amp;gt;100001&amp;lt;/PersonID&amp;gt;&lt;br /&gt;
    &amp;lt;TypeName&amp;gt;professional&amp;lt;/TypeName&amp;gt;&lt;br /&gt;
 &amp;lt;/professional&amp;gt;&lt;br /&gt;
&lt;br /&gt;
==Fetching multiple professional records in one call==&lt;br /&gt;
It is possible to use the search endpoint to retrieve multiple records&lt;br /&gt;
&lt;br /&gt;
 curl --url &amp;lt;Base URL&amp;gt;/search?PersonID[]=xxx&amp;amp;PersonID[]=xxx&amp;amp;PersonID[]=xxx&amp;amp; -u&amp;lt;username&amp;gt;:&amp;lt;password&amp;gt; -H Content-Type:text/xml &lt;br /&gt;
&lt;br /&gt;
Depending on how many you are fetching, you may need to use POST rather than GET&lt;br /&gt;
&lt;br /&gt;
==Searching for a professional==&lt;br /&gt;
 curl --url &amp;lt;Base URL&amp;gt;/search?q=&amp;lt;query&amp;gt; -u&amp;lt;username&amp;gt;:&amp;lt;password&amp;gt; -H Content-Type:text/xml &lt;br /&gt;
* query - This is a text string to use to search for in the professionals records&lt;br /&gt;
&lt;br /&gt;
You can search for any field for a specific value by setting the field as a parameter. Please refer to the schema for fieldnames.&lt;br /&gt;
&lt;br /&gt;
There are also a series of fields that you use -from and -to modifiers to express a range:&lt;br /&gt;
* DateOfBirth - yyyy-mm-dd&lt;br /&gt;
* Age - int (Please note that this is in days)&lt;br /&gt;
* Created - yyyy-mm-dd&lt;br /&gt;
* Updated - yyyy-mm-dd&lt;br /&gt;
* Archived - yyyy-mm-dd&lt;br /&gt;
&lt;br /&gt;
==Updating a professional==&lt;br /&gt;
 curl --url &amp;lt;Base URL&amp;gt;/&amp;lt;id&amp;gt; -u&amp;lt;username&amp;gt;:&amp;lt;password&amp;gt; -H Content-Type:text/xml -X PUT -d &amp;quot;&amp;lt;xml&amp;gt;&amp;quot;&lt;br /&gt;
* id - The ID of the professional&lt;br /&gt;
&lt;br /&gt;
The XML should be in the same format as the create XML. However, you only need to supply fields that you wish to update. For example:&lt;br /&gt;
 &amp;lt;?xml version=&amp;quot;1.0&amp;quot; encoding=&amp;quot;utf-8&amp;quot;?&amp;gt;&lt;br /&gt;
 &amp;lt;professional id=&amp;quot;100001&amp;quot;&amp;gt;&lt;br /&gt;
    &amp;lt;Forename&amp;gt;Jane&amp;lt;/Forename&amp;gt;&lt;br /&gt;
    &amp;lt;Surname&amp;gt;Smith&amp;lt;/Surname&amp;gt;&lt;br /&gt;
 &amp;lt;/professional&amp;gt;&lt;br /&gt;
&#039;&#039;The above would result in updating professional 1000001&#039;s Forename and Surname values&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
==Archiving a professional==&lt;br /&gt;
 curl --url &amp;lt;Base URL&amp;gt;/&amp;lt;id&amp;gt;/archive -u&amp;lt;username&amp;gt;:&amp;lt;password&amp;gt; -H Content-Type:text/xml -X PUT -d &#039;&amp;lt;status&amp;gt;1&amp;lt;/status&amp;gt;&#039;&lt;br /&gt;
* id - The ID of the professional&lt;br /&gt;
&lt;br /&gt;
This will set the archive flag on a professional. If you set the status to 0, then it will remove the archive flag.&lt;br /&gt;
&lt;br /&gt;
==Deleting a professional==&lt;br /&gt;
 curl --url &amp;lt;Base URL&amp;gt;/&amp;lt;id&amp;gt; -u&amp;lt;username&amp;gt;:&amp;lt;password&amp;gt; -H Content-Type:text/xml -X DELETE&lt;br /&gt;
* id - The ID of the professional&lt;br /&gt;
&lt;br /&gt;
This should be used with great care as it will permanently delete a professionals record.&lt;/div&gt;</summary>
		<author><name>Wikiadmin</name></author>
	</entry>
	<entry>
		<id>https://www.substance.net/views-api-docs/index.php?title=Rest_-_Contacts_-_Participants&amp;diff=311</id>
		<title>Rest - Contacts - Participants</title>
		<link rel="alternate" type="text/html" href="https://www.substance.net/views-api-docs/index.php?title=Rest_-_Contacts_-_Participants&amp;diff=311"/>
		<updated>2025-04-04T08:50:10Z</updated>

		<summary type="html">&lt;p&gt;Wikiadmin: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;==Purpose==&lt;br /&gt;
&lt;br /&gt;
Used for creating, editing and deleting Participants from the Views system.&lt;br /&gt;
&lt;br /&gt;
===Base URL===&lt;br /&gt;
https://app.viewsapp.net/api/restful/contacts/participants&lt;br /&gt;
&lt;br /&gt;
===Schema===&lt;br /&gt;
&amp;lt;nowiki&amp;gt;https://app.viewsapp.net/api/restful/contacts/participants/schema(.xml|.json|.xsd)&amp;lt;/nowiki&amp;gt;&lt;br /&gt;
&lt;br /&gt;
==Creating a participant==&lt;br /&gt;
&lt;br /&gt;
Once you have created your data file, you can send it using the following:&lt;br /&gt;
&lt;br /&gt;
 curl --url &amp;lt;Base URL&amp;gt; -u&amp;lt;username&amp;gt;:&amp;lt;password&amp;gt; -H Content-Type:text/xml -X POST -d &amp;quot;&amp;lt;xml&amp;gt;&amp;quot;&lt;br /&gt;
&lt;br /&gt;
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.&lt;br /&gt;
&lt;br /&gt;
If the record was created successfully, the service will return a complete record for the newly created record if the attribute id set as the newly created id.&lt;br /&gt;
&lt;br /&gt;
==Fetching a participant==&lt;br /&gt;
 curl --url &amp;lt;Base URL&amp;gt;/&amp;lt;id&amp;gt; -u&amp;lt;username&amp;gt;:&amp;lt;password&amp;gt; -H Content-Type:text/xml&lt;br /&gt;
&lt;br /&gt;
This will return an xml file similar to this&lt;br /&gt;
 &amp;lt;?xml version=&amp;quot;1.0&amp;quot; encoding=&amp;quot;utf-8&amp;quot;?&amp;gt;&lt;br /&gt;
 &amp;lt;participant id=&amp;quot;100001&amp;quot;&amp;gt;&lt;br /&gt;
    &amp;lt;Nickname&amp;gt;&amp;lt;/Nickname&amp;gt;&lt;br /&gt;
    &amp;lt;Forename&amp;gt;John&amp;lt;/Forename&amp;gt;&lt;br /&gt;
    &amp;lt;Surname&amp;gt;Smith&amp;lt;/Surname&amp;gt;&lt;br /&gt;
    ...&lt;br /&gt;
    &amp;lt;Created&amp;gt;2011-05-09 10:26:09&amp;lt;/Created&amp;gt;&lt;br /&gt;
    &amp;lt;CreatedBy&amp;gt;a.user&amp;lt;/CreatedBy&amp;gt;&lt;br /&gt;
    &amp;lt;Updated&amp;gt;2011-05-09 10:26:09&amp;lt;/Updated&amp;gt;&lt;br /&gt;
    &amp;lt;UpdatedBy&amp;gt;a.user&amp;lt;/UpdatedBy&amp;gt;&lt;br /&gt;
    &amp;lt;Archived&amp;gt;0000-00-00 00:00:00&amp;lt;/Archived&amp;gt;&lt;br /&gt;
    &amp;lt;ArchivedBy&amp;gt;&amp;lt;/ArchivedBy&amp;gt;&lt;br /&gt;
    &amp;lt;Type&amp;gt;1&amp;lt;/Type&amp;gt;&lt;br /&gt;
    &amp;lt;PersonID&amp;gt;100001&amp;lt;/PersonID&amp;gt;&lt;br /&gt;
    &amp;lt;TypeName&amp;gt;participant&amp;lt;/TypeName&amp;gt;&lt;br /&gt;
 &amp;lt;/participant&amp;gt;&lt;br /&gt;
&lt;br /&gt;
==Fetching multiple partcipant records in one call==&lt;br /&gt;
It is possible to use the search endpoint to retrieve multiple records&lt;br /&gt;
&lt;br /&gt;
 curl --url &amp;lt;Base URL&amp;gt;/search?PersonID[]=xxx&amp;amp;PersonID[]=xxx&amp;amp;PersonID[]=xxx&amp;amp; -u&amp;lt;username&amp;gt;:&amp;lt;password&amp;gt; -H Content-Type:text/xml &lt;br /&gt;
&lt;br /&gt;
Depending on howm any you are fetching, you may need to use POST rather than GET&lt;br /&gt;
&lt;br /&gt;
==Searching for a participant==&lt;br /&gt;
 curl --url &amp;lt;Base URL&amp;gt;/search?q=&amp;lt;query&amp;gt; -u&amp;lt;username&amp;gt;:&amp;lt;password&amp;gt; -H Content-Type:text/xml &lt;br /&gt;
* query - This is a text string to use to search for in the participants records&lt;br /&gt;
&lt;br /&gt;
You can search for any field for a specific value by setting the field as a parameter. Please refer to the schema for fieldnames.&lt;br /&gt;
&lt;br /&gt;
There are also a series of fields that you use -from and -to modifiers to express a range:&lt;br /&gt;
* DateOfBirth - yyyy-mm-dd&lt;br /&gt;
* Age - int (Please note that this is in days)&lt;br /&gt;
* Created - yyyy-mm-dd&lt;br /&gt;
* Updated - yyyy-mm-dd&lt;br /&gt;
* Archived - yyyy-mm-dd&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
==Searching for a participant that has volunteered==&lt;br /&gt;
This can be achieved by adding &amp;lt;code&amp;gt;hasvolunteeres&amp;lt;/code&amp;gt; to the search method as so:&lt;br /&gt;
&lt;br /&gt;
 curl --url &amp;lt;Base URL&amp;gt;/search?hasvoluteered&amp;amp;q=&amp;lt;query&amp;gt; -u&amp;lt;username&amp;gt;:&amp;lt;password&amp;gt; -H Content-Type:text/xml &lt;br /&gt;
&lt;br /&gt;
The default is to filter the results to those that have volunteering records, however you can negate the search results by setting this parameter to one of the following values:&lt;br /&gt;
* 0&lt;br /&gt;
* no&lt;br /&gt;
* false&lt;br /&gt;
&lt;br /&gt;
For example:&lt;br /&gt;
 curl --url &amp;lt;Base URL&amp;gt;/search?hasvoluteered&amp;amp;q=&amp;lt;query&amp;gt; -u&amp;lt;username&amp;gt;:&amp;lt;password&amp;gt; -H Content-Type:text/xml&lt;br /&gt;
&lt;br /&gt;
==Updating a participant==&lt;br /&gt;
 curl --url &amp;lt;Base URL&amp;gt;/&amp;lt;id&amp;gt; -u&amp;lt;username&amp;gt;:&amp;lt;password&amp;gt; -H Content-Type:text/xml -X PUT -d &amp;quot;&amp;lt;xml&amp;gt;&amp;quot;&lt;br /&gt;
* id - The ID of the participant&lt;br /&gt;
&lt;br /&gt;
The XML should be in the same format as the create XML. However, you only need to supply fields that you wish to update. For example:&lt;br /&gt;
 &amp;lt;?xml version=&amp;quot;1.0&amp;quot; encoding=&amp;quot;utf-8&amp;quot;?&amp;gt;&lt;br /&gt;
 &amp;lt;participant id=&amp;quot;100001&amp;quot;&amp;gt;&lt;br /&gt;
    &amp;lt;Forename&amp;gt;Jane&amp;lt;/Forename&amp;gt;&lt;br /&gt;
    &amp;lt;Surname&amp;gt;Smith&amp;lt;/Surname&amp;gt;&lt;br /&gt;
 &amp;lt;/participant&amp;gt;&lt;br /&gt;
&#039;&#039;The above would result in updating participant 1000001&#039;s Forename and Surname values&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
==Archiving a participant==&lt;br /&gt;
 curl --url &amp;lt;Base URL&amp;gt;/&amp;lt;id&amp;gt;/archive -u&amp;lt;username&amp;gt;:&amp;lt;password&amp;gt; -H Content-Type:text/xml -X PUT -d &#039;&amp;lt;status&amp;gt;1&amp;lt;/status&amp;gt;&#039;&lt;br /&gt;
* id - The ID of the participant&lt;br /&gt;
&lt;br /&gt;
This will set the archive flag on a participant. If you set the status to 0, then it will remove the archive flag.&lt;br /&gt;
&lt;br /&gt;
==Deleting a participant==&lt;br /&gt;
 curl --url &amp;lt;Base URL&amp;gt;/&amp;lt;id&amp;gt; -u&amp;lt;username&amp;gt;:&amp;lt;password&amp;gt; -H Content-Type:text/xml -X DELETE&lt;br /&gt;
* id - The ID of the participant&lt;br /&gt;
&lt;br /&gt;
This should be used with great care as it will permanently delete a participants record.&lt;/div&gt;</summary>
		<author><name>Wikiadmin</name></author>
	</entry>
	<entry>
		<id>https://www.substance.net/views-api-docs/index.php?title=Rest_-_Contacts_-_Groups&amp;diff=310</id>
		<title>Rest - Contacts - Groups</title>
		<link rel="alternate" type="text/html" href="https://www.substance.net/views-api-docs/index.php?title=Rest_-_Contacts_-_Groups&amp;diff=310"/>
		<updated>2025-04-04T08:44:36Z</updated>

		<summary type="html">&lt;p&gt;Wikiadmin: Created page with &amp;quot;==Purpose==  Used for creating, editing and deleting Groups from the Views system.  ===Base URL=== https://app.viewsapp.net/api/restful/contacts/groups  ===Schema=== &amp;lt;nowiki&amp;gt;https://app.viewsapp.net/api/restful/contacts/groups/schema(.xml|.json|.xsd)&amp;lt;/nowiki&amp;gt;  ==Creating a group==  Once you have created your data file, you can send it using the following:   curl --url &amp;lt;Base URL&amp;gt; -u&amp;lt;username&amp;gt;:&amp;lt;password&amp;gt; -H Content-Type:text/xml -X POST -d &amp;quot;&amp;lt;xml&amp;gt;&amp;quot;  If there is a problem wi...&amp;quot;&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;==Purpose==&lt;br /&gt;
&lt;br /&gt;
Used for creating, editing and deleting Groups from the Views system.&lt;br /&gt;
&lt;br /&gt;
===Base URL===&lt;br /&gt;
https://app.viewsapp.net/api/restful/contacts/groups&lt;br /&gt;
&lt;br /&gt;
===Schema===&lt;br /&gt;
&amp;lt;nowiki&amp;gt;https://app.viewsapp.net/api/restful/contacts/groups/schema(.xml|.json|.xsd)&amp;lt;/nowiki&amp;gt;&lt;br /&gt;
&lt;br /&gt;
==Creating a group==&lt;br /&gt;
&lt;br /&gt;
Once you have created your data file, you can send it using the following:&lt;br /&gt;
&lt;br /&gt;
 curl --url &amp;lt;Base URL&amp;gt; -u&amp;lt;username&amp;gt;:&amp;lt;password&amp;gt; -H Content-Type:text/xml -X POST -d &amp;quot;&amp;lt;xml&amp;gt;&amp;quot;&lt;br /&gt;
&lt;br /&gt;
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.&lt;br /&gt;
&lt;br /&gt;
If the record was created successfully, the service will return a complete record for the newly created record if the attribute id set as the newly created id.&lt;br /&gt;
&lt;br /&gt;
==Fetching a group==&lt;br /&gt;
 curl --url &amp;lt;Base URL&amp;gt;/&amp;lt;id&amp;gt; -u&amp;lt;username&amp;gt;:&amp;lt;password&amp;gt; -H Content-Type:text/xml&lt;br /&gt;
&lt;br /&gt;
This will return an xml file similar to this&lt;br /&gt;
 &amp;lt;?xml version=&amp;quot;1.0&amp;quot; encoding=&amp;quot;utf-8&amp;quot;?&amp;gt;&lt;br /&gt;
 &amp;lt;group id=&amp;quot;100001&amp;quot;&amp;gt;&lt;br /&gt;
    &amp;lt;Name&amp;gt;Group&amp;lt;/Name&amp;gt;&lt;br /&gt;
    ...&lt;br /&gt;
    &amp;lt;Created&amp;gt;2011-05-09 10:26:09&amp;lt;/Created&amp;gt;&lt;br /&gt;
    &amp;lt;CreatedBy&amp;gt;a.user&amp;lt;/CreatedBy&amp;gt;&lt;br /&gt;
    &amp;lt;Updated&amp;gt;2011-05-09 10:26:09&amp;lt;/Updated&amp;gt;&lt;br /&gt;
    &amp;lt;UpdatedBy&amp;gt;a.user&amp;lt;/UpdatedBy&amp;gt;&lt;br /&gt;
    &amp;lt;Archived&amp;gt;0000-00-00 00:00:00&amp;lt;/Archived&amp;gt;&lt;br /&gt;
    &amp;lt;ArchivedBy&amp;gt;&amp;lt;/ArchivedBy&amp;gt;&lt;br /&gt;
    &amp;lt;GroupID&amp;gt;100001&amp;lt;/GroupID&amp;gt;&lt;br /&gt;
    &amp;lt;TypeName&amp;gt;group&amp;lt;/TypeName&amp;gt;&lt;br /&gt;
 &amp;lt;/group&amp;gt;&lt;br /&gt;
&lt;br /&gt;
==Fetching multiple groups records in one call==&lt;br /&gt;
It is possible to use the search endpoint to retrieve multiple records&lt;br /&gt;
&lt;br /&gt;
 curl --url &amp;lt;Base URL&amp;gt;/search?ids[]=xxx&amp;amp;ids[]=xxx&amp;amp;ids[]=xxx&amp;amp; -u&amp;lt;username&amp;gt;:&amp;lt;password&amp;gt; -H Content-Type:text/xml &lt;br /&gt;
&lt;br /&gt;
Depending on how many you are fetching, you may need to use POST rather than GET&lt;br /&gt;
&lt;br /&gt;
==Searching for a group==&lt;br /&gt;
 curl --url &amp;lt;Base URL&amp;gt;/search?q=&amp;lt;query&amp;gt; -u&amp;lt;username&amp;gt;:&amp;lt;password&amp;gt; -H Content-Type:text/xml &lt;br /&gt;
* query - This is a text string to use to search for in the groups records&lt;br /&gt;
&lt;br /&gt;
You can search for any field for a specific value by setting the field as a parameter. Please refer to the schema for fieldnames.&lt;br /&gt;
&lt;br /&gt;
There are also a series of fields that you use -from and -to modifiers to express a range:&lt;br /&gt;
* Created - yyyy-mm-dd&lt;br /&gt;
* Updated - yyyy-mm-dd&lt;br /&gt;
* Archived - yyyy-mm-dd&lt;br /&gt;
&lt;br /&gt;
==Updating a group==&lt;br /&gt;
 curl --url &amp;lt;Base URL&amp;gt;/&amp;lt;id&amp;gt; -u&amp;lt;username&amp;gt;:&amp;lt;password&amp;gt; -H Content-Type:text/xml -X PUT -d &amp;quot;&amp;lt;xml&amp;gt;&amp;quot;&lt;br /&gt;
* id - The ID of the group&lt;br /&gt;
&lt;br /&gt;
The XML should be in the same format as the create XML. However, you only need to supply fields that you wish to update. For example:&lt;br /&gt;
 &amp;lt;?xml version=&amp;quot;1.0&amp;quot; encoding=&amp;quot;utf-8&amp;quot;?&amp;gt;&lt;br /&gt;
 &amp;lt;group id=&amp;quot;100001&amp;quot;&amp;gt;&lt;br /&gt;
    &amp;lt;Name&amp;gt;Group&amp;lt;/Name&amp;gt;&lt;br /&gt;
 &amp;lt;/group&amp;gt;&lt;br /&gt;
&#039;&#039;The above would result in updating group 1000001&#039;s Name value&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
==Archiving a group==&lt;br /&gt;
 curl --url &amp;lt;Base URL&amp;gt;/&amp;lt;id&amp;gt;/archive -u&amp;lt;username&amp;gt;:&amp;lt;password&amp;gt; -H Content-Type:text/xml -X PUT -d &#039;&amp;lt;status&amp;gt;1&amp;lt;/status&amp;gt;&#039;&lt;br /&gt;
* id - The ID of the group&lt;br /&gt;
&lt;br /&gt;
This will set the archive flag on a group. If you set the status to 0, then it will remove the archive flag.&lt;br /&gt;
&lt;br /&gt;
==Deleting a group==&lt;br /&gt;
 curl --url &amp;lt;Base URL&amp;gt;/&amp;lt;id&amp;gt; -u&amp;lt;username&amp;gt;:&amp;lt;password&amp;gt; -H Content-Type:text/xml -X DELETE&lt;br /&gt;
* id - The ID of the group&lt;br /&gt;
&lt;br /&gt;
This should be used with great care as it will permanently delete a group record.&lt;/div&gt;</summary>
		<author><name>Wikiadmin</name></author>
	</entry>
	<entry>
		<id>https://www.substance.net/views-api-docs/index.php?title=Rest_-_Work_-_Session_Groups_-_Session_Participants&amp;diff=308</id>
		<title>Rest - Work - Session Groups - Session Participants</title>
		<link rel="alternate" type="text/html" href="https://www.substance.net/views-api-docs/index.php?title=Rest_-_Work_-_Session_Groups_-_Session_Participants&amp;diff=308"/>
		<updated>2023-05-25T08:36:56Z</updated>

		<summary type="html">&lt;p&gt;Wikiadmin: /* Adding multiple participants to a session */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;==Purpose==&lt;br /&gt;
&lt;br /&gt;
Used for administering participation by participants at sessions in the Views system.&lt;br /&gt;
&lt;br /&gt;
===Base URL===&lt;br /&gt;
&amp;lt;nowiki&amp;gt;https://app.viewsapp.net/api/restful/work/sessiongroups/sessions/&amp;lt;sid&amp;gt;/participants&amp;lt;/nowiki&amp;gt;&lt;br /&gt;
* &#039;&#039;&#039;sid&#039;&#039;&#039; - This is the id of the session group&lt;br /&gt;
&lt;br /&gt;
==Getting the list of participants==&lt;br /&gt;
 curl --url &amp;lt;Base URL&amp;gt; -u&amp;lt;username&amp;gt;:&amp;lt;password&amp;gt; -H Content-Type:text/xml&lt;br /&gt;
&lt;br /&gt;
This will return a list of participants that are associated with a session, similar to the following:&lt;br /&gt;
 &amp;lt;session id=&amp;quot;7&amp;quot;&amp;gt;&lt;br /&gt;
     &amp;lt;participants&amp;gt;&lt;br /&gt;
         &amp;lt;participant id=&amp;quot;123&amp;quot;&amp;gt;&lt;br /&gt;
             &amp;lt;SessionID&amp;gt;25&amp;lt;/SessionID&amp;gt;&lt;br /&gt;
             &amp;lt;SessionGroupID&amp;gt;7&amp;lt;/SessionGroupID&amp;gt;&lt;br /&gt;
             &amp;lt;Name&amp;gt;Jane Smith&amp;lt;/Name&amp;gt;&lt;br /&gt;
             &amp;lt;ContactType&amp;gt;Individual&amp;lt;/ContactType&amp;gt;&lt;br /&gt;
             &amp;lt;Attended&amp;gt;0&amp;lt;/Attended&amp;gt;&lt;br /&gt;
             &amp;lt;Volunteering&amp;gt;&amp;lt;/Volunteering&amp;gt;&lt;br /&gt;
         &amp;lt;/participant&amp;gt;&lt;br /&gt;
         &amp;lt;participant id=&amp;quot;102&amp;quot;&amp;gt;&lt;br /&gt;
             &amp;lt;SessionID&amp;gt;25&amp;lt;/SessionID&amp;gt;&lt;br /&gt;
             &amp;lt;SessionGroupID&amp;gt;7&amp;lt;/SessionGroupID&amp;gt;&lt;br /&gt;
             &amp;lt;Name&amp;gt;John Smith&amp;lt;/Name&amp;gt;&lt;br /&gt;
             &amp;lt;ContactType&amp;gt;Individual&amp;lt;/ContactType&amp;gt;&lt;br /&gt;
             &amp;lt;Attended&amp;gt;1&amp;lt;/Attended&amp;gt;&lt;br /&gt;
             &amp;lt;Volunteering&amp;gt;Made Coffee&amp;lt;/Volunteering&amp;gt;&lt;br /&gt;
         &amp;lt;/participant&amp;gt;&lt;br /&gt;
     &amp;lt;participants&amp;gt;&lt;br /&gt;
 &amp;lt;/sessiongroup&amp;gt;&lt;br /&gt;
&lt;br /&gt;
==Adding Participants to a session==&lt;br /&gt;
&lt;br /&gt;
===Adding participants to a bookable session===&lt;br /&gt;
Due to financial information being required for bookable sessions, the method of adding participants in slightly different.&lt;br /&gt;
&lt;br /&gt;
 curl --url &amp;lt;Base URL&amp;gt; -u&amp;lt;username&amp;gt;:&amp;lt;password&amp;gt; -H Content-Type:text/xml -X POST&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;participant&amp;gt;&lt;br /&gt;
     &amp;lt;PersonID&amp;gt;100748&amp;lt;/PersonID&amp;gt;&lt;br /&gt;
     &amp;lt;PaymentType&amp;gt;Debit Card&amp;lt;/PaymentType&amp;gt;&lt;br /&gt;
     &amp;lt;PaymentAmount&amp;gt;20&amp;lt;/PaymentAmount&amp;gt;&lt;br /&gt;
     &amp;lt;PaymentFee&amp;gt;2.50&amp;lt;/PaymentFee&amp;gt;&lt;br /&gt;
     &amp;lt;PaymentReference&amp;gt;7002&amp;lt;/PaymentReference&amp;gt;&lt;br /&gt;
     &amp;lt;Forename&amp;gt;Father&amp;lt;/Forename&amp;gt;&lt;br /&gt;
     &amp;lt;Surname&amp;gt;Test&amp;lt;/Surname&amp;gt;&lt;br /&gt;
     &amp;lt;Address1/&amp;gt;&lt;br /&gt;
     &amp;lt;Address2/&amp;gt;&lt;br /&gt;
     &amp;lt;Town/&amp;gt;&lt;br /&gt;
     &amp;lt;County/&amp;gt;&lt;br /&gt;
     &amp;lt;Postcode/&amp;gt;&lt;br /&gt;
     &amp;lt;Telephone/&amp;gt;&lt;br /&gt;
     &amp;lt;Email&amp;gt;test@test.com&amp;lt;/Email&amp;gt;&lt;br /&gt;
 &amp;lt;/participant&amp;gt;&lt;br /&gt;
&lt;br /&gt;
This will return errors on a fail or the full booking record on a successful submit.&lt;br /&gt;
&lt;br /&gt;
The required fields are all required:&lt;br /&gt;
* PersonID - This is the ID of the participant&lt;br /&gt;
* PaymentType - One of the following value &#039;Cash&#039;, &#039;Cheque&#039;, &#039;Debit Card&#039;, &#039;Credit Card&#039;, &#039;Other&#039;&lt;br /&gt;
* PaymentAmount - This is the amount paid&lt;br /&gt;
&lt;br /&gt;
===Adding a single participant to a session===&lt;br /&gt;
You can add a single participant via the following:&lt;br /&gt;
 curl --url &amp;lt;Base URL&amp;gt; -u&amp;lt;username&amp;gt;:&amp;lt;password&amp;gt; -H Content-Type:text/xml -X PUT&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;participant&amp;gt;&lt;br /&gt;
     &amp;lt;ContactID&amp;gt;101457&amp;lt;/ContactID&amp;gt;&lt;br /&gt;
     &amp;lt;Attended&amp;gt;0&amp;lt;/Attended&amp;gt;&lt;br /&gt;
     &amp;lt;Volunteering&amp;gt;Volunteered|Made Coffee&amp;lt;/Volunteering&amp;gt;&lt;br /&gt;
 &amp;lt;/participant&amp;gt;&lt;br /&gt;
&lt;br /&gt;
The value for Attended is either 1 or 0, 1 = Attended. This is optional and will default to 0, unless the session has started, in which case the default is 1.&lt;br /&gt;
&lt;br /&gt;
===Adding multiple participants to a session===&lt;br /&gt;
You can also upload a a list of participants to add to the session register via the following URL&lt;br /&gt;
 curl --url &amp;lt;Base URL&amp;gt; -u&amp;lt;username&amp;gt;:&amp;lt;password&amp;gt; -H Content-Type:text/xml -X PUT&lt;br /&gt;
&lt;br /&gt;
This is an example of JSON data you must send on the server to add multiple participants&lt;br /&gt;
&lt;br /&gt;
 &amp;quot;participant&amp;quot;: [&lt;br /&gt;
      {&amp;quot;ContactID&amp;quot;:&amp;quot;101457&amp;quot;,&amp;quot;Attended&amp;quot;:0},&lt;br /&gt;
      {&amp;quot;ContactID&amp;quot;:&amp;quot;457&amp;quot;,&amp;quot;Attended&amp;quot;:1, &amp;quot;Volunteering&amp;quot;: &amp;quot;Volunteered|Made Coffee&amp;quot;},&lt;br /&gt;
      {&amp;quot;ContactID&amp;quot;:&amp;quot;57&amp;quot;,&amp;quot;Attended&amp;quot;:1, &amp;quot;Volunteering&amp;quot;: &amp;quot;Cleaned Up&amp;quot;}&lt;br /&gt;
  ]&lt;br /&gt;
&lt;br /&gt;
This can be useful for setting a register of attending participants.&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;participants&amp;gt;&lt;br /&gt;
     &amp;lt;participant&amp;gt;&lt;br /&gt;
         &amp;lt;ContactID&amp;gt;101457&amp;lt;/ContactID&amp;gt;&lt;br /&gt;
         &amp;lt;Attended&amp;gt;0&amp;lt;/Attended&amp;gt;&lt;br /&gt;
     &amp;lt;/participant&amp;gt;&lt;br /&gt;
     &amp;lt;participant&amp;gt;&lt;br /&gt;
         &amp;lt;ContactID&amp;gt;457&amp;lt;/ContactID&amp;gt;&lt;br /&gt;
         &amp;lt;Attended&amp;gt;1&amp;lt;/Attended&amp;gt;&lt;br /&gt;
         &amp;lt;Volunteering&amp;gt;Volunteered|Made Coffee&amp;lt;/Volunteering&amp;gt;&lt;br /&gt;
     &amp;lt;/participant&amp;gt;&lt;br /&gt;
     &amp;lt;participant&amp;gt;&lt;br /&gt;
         &amp;lt;ContactID&amp;gt;57&amp;lt;/ContactID&amp;gt;&lt;br /&gt;
         &amp;lt;Attended&amp;gt;1&amp;lt;/Attended&amp;gt;&lt;br /&gt;
         &amp;lt;Volunteering&amp;gt;Cleaned Up&amp;lt;/Volunteering&amp;gt;&lt;br /&gt;
     &amp;lt;/participant&amp;gt;&lt;br /&gt;
 &amp;lt;/participants&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;&#039;&#039;Please note:&#039;&#039;&#039; This will replace all existing participant data for the session&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
==Removing participants from a session==&lt;br /&gt;
&lt;br /&gt;
===Removing participants from a non bookable session group===&lt;br /&gt;
&lt;br /&gt;
You can remove a single participant from a session via the following:&lt;br /&gt;
 curl --url &amp;lt;Base URL&amp;gt;/&amp;lt;pid&amp;gt; -u&amp;lt;username&amp;gt;:&amp;lt;password&amp;gt; -H Content-Type:text/xml -X DELETE&lt;br /&gt;
*&#039;&#039;&#039;pid&#039;&#039;&#039; - The ID of the participant to add&lt;br /&gt;
&lt;br /&gt;
You can also upload a a list of participants to remove from the session via the following URL&lt;br /&gt;
 curl --url &amp;lt;Base URL&amp;gt; -u&amp;lt;username&amp;gt;:&amp;lt;password&amp;gt; -H Content-Type:text/xml -X DELETE&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;participants&amp;gt;&lt;br /&gt;
     &amp;lt;participant&amp;gt;101162&amp;lt;/participant&amp;gt;&lt;br /&gt;
     &amp;lt;participant&amp;gt;103124&amp;lt;/participant&amp;gt;&lt;br /&gt;
     &amp;lt;participant&amp;gt;103413&amp;lt;/participant&amp;gt;&lt;br /&gt;
 &amp;lt;/participants&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
===Removing participants from a bookable session===&lt;br /&gt;
You can only remove a single participant&#039;s booking from a session group via the following:&lt;br /&gt;
 curl --url &amp;lt;Base URL&amp;gt;/&amp;lt;pid&amp;gt; -u&amp;lt;username&amp;gt;:&amp;lt;password&amp;gt; -H Content-Type:text/xml -X DELETE&lt;br /&gt;
*&#039;&#039;&#039;pid&#039;&#039;&#039; - The ID of the participant to remove&lt;br /&gt;
&lt;br /&gt;
By default this will flag the participant as cancelled, but will not do anything with the financial side of the booking. To flag a refund was give or a credit note, you should pass the following:&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;refundtype&amp;gt;Refund&amp;lt;/refundtype&amp;gt;&lt;br /&gt;
&lt;br /&gt;
or &lt;br /&gt;
&lt;br /&gt;
 &amp;lt;refundtype&amp;gt;Credit&amp;lt;/refundtype&amp;gt;&lt;br /&gt;
&lt;br /&gt;
This will result in the participants booking being completely being removed from the session&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
==Making payments to a booking==&lt;br /&gt;
 curl --url &amp;lt;Base URL&amp;gt;/&amp;lt;id&amp;gt; -u&amp;lt;username&amp;gt;:&amp;lt;password&amp;gt; -H Content-Type:text/xml -X PUT -d &#039;&amp;lt;xml&amp;gt;&#039;&lt;br /&gt;
&lt;br /&gt;
* *id* - This is the participant id&lt;br /&gt;
&lt;br /&gt;
The data for submitting a payment record is currently quite basic. It is our intention to expand on this:&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;payment&amp;gt;&lt;br /&gt;
     &amp;lt;PaymentType&amp;gt;Debit Card&amp;lt;/PaymentType&amp;gt;&lt;br /&gt;
     &amp;lt;PaymentAmount&amp;gt;20&amp;lt;/PaymentAmount&amp;gt;&lt;br /&gt;
 &amp;lt;/payment&amp;gt;&lt;br /&gt;
&lt;br /&gt;
* PaymentType - This must be one of the following values &#039;Cash&#039;, &#039;Cheque&#039;, &#039;Debit Card&#039;, &#039;Credit Card&#039;, &#039;Other&#039;&lt;br /&gt;
* PaymentAmount - This is an amount in pounds.pence&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
==Confirming/Unconfirming a booking==&lt;br /&gt;
 curl --url &amp;lt;Base URL&amp;gt;/&amp;lt;id&amp;gt; -u&amp;lt;username&amp;gt;:&amp;lt;password&amp;gt; -H Content-Type:text/xml -X PUT -d &#039;&amp;lt;xml&amp;gt;&#039;&lt;br /&gt;
&lt;br /&gt;
* *id* - This is the participant id&lt;br /&gt;
&lt;br /&gt;
The data for submitting a payment record is currently quite basic. It is our intention to expand on this:&lt;br /&gt;
 &amp;lt;booking&amp;gt;&lt;br /&gt;
     &amp;lt;Confirmed&amp;gt;1&amp;lt;/Confirmed&amp;gt;&lt;br /&gt;
 &amp;lt;/booking&amp;gt;&#039;&lt;br /&gt;
&lt;br /&gt;
This can also be combined with a payment as such:&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;payment&amp;gt;&lt;br /&gt;
     &amp;lt;PaymentType&amp;gt;Debit Card&amp;lt;/PaymentType&amp;gt;&lt;br /&gt;
     &amp;lt;PaymentAmount&amp;gt;20&amp;lt;/PaymentAmount&amp;gt;&lt;br /&gt;
     &amp;lt;Confirmed&amp;gt;1&amp;lt;/Confirmed&amp;gt;&lt;br /&gt;
 &amp;lt;/payment&amp;gt;&lt;/div&gt;</summary>
		<author><name>Wikiadmin</name></author>
	</entry>
	<entry>
		<id>https://www.substance.net/views-api-docs/index.php?title=Views_API_Documentation&amp;diff=307</id>
		<title>Views API Documentation</title>
		<link rel="alternate" type="text/html" href="https://www.substance.net/views-api-docs/index.php?title=Views_API_Documentation&amp;diff=307"/>
		<updated>2022-01-17T13:57:51Z</updated>

		<summary type="html">&lt;p&gt;Wikiadmin: /* Contacts */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;==Rest==&lt;br /&gt;
===General Overview===&lt;br /&gt;
All of our REST services are available in both XML and JSON formats, unless otherwise stated. The default format is XML. For the purposes of this documentation we only document the XML method. If you want to interact using json, then you should either make sure you request using &amp;lt;code&amp;gt;Content-Type: application/json&amp;lt;/code&amp;gt;, alternatively you have append the extension &amp;lt;code&amp;gt;.json&amp;lt;/code&amp;gt; to the URI e.g:&lt;br /&gt;
 curl --url &amp;lt;Base URL&amp;gt;/&amp;lt;id&amp;gt; -u&amp;lt;username&amp;gt;:&amp;lt;password&amp;gt; -H Accept:application/json&lt;br /&gt;
&lt;br /&gt;
or&lt;br /&gt;
&lt;br /&gt;
 curl --url &amp;lt;Base URL&amp;gt;/&amp;lt;id&amp;gt;.json -u&amp;lt;username&amp;gt;:&amp;lt;password&amp;gt;&lt;br /&gt;
&lt;br /&gt;
====Using OAuth2====&lt;br /&gt;
&lt;br /&gt;
The use of OAthu2 access_tokens can be used. To do this, you must first request an &amp;lt;code&amp;gt;access_token&amp;lt;/code&amp;gt; from the authentication portal https://authport.viewsapp.net/. This can be done in the following way (using Google Apps Script:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
// Get access_token&lt;br /&gt;
var response = UrlFetchApp.fetch(&#039;https://authportal.viewsapp.net/token.php&#039;, {&lt;br /&gt;
  &#039;method&#039;  : &#039;post&#039;,&lt;br /&gt;
  &#039;payload&#039; : {&#039;grant_type&#039;: &#039;password&#039;, &#039;username&#039; : &#039;my_username&#039;, &#039;password&#039; : &#039;my_password&#039;},&lt;br /&gt;
  &#039;headers&#039; : {&amp;quot;Authorization&amp;quot;: &amp;quot;Basic &amp;quot; + Utilities.base64Encode(&#039;my_username&#039; + &amp;quot;:&amp;quot; + &#039;my_password&#039;)}&lt;br /&gt;
});&lt;br /&gt;
var access_token = JSON.parse(response.getContentText()).access_token;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
  &lt;br /&gt;
You would then pass the following fields along side any request:&lt;br /&gt;
&lt;br /&gt;
* client_id=&amp;lt;username&amp;gt;&lt;br /&gt;
* access_token=&amp;lt;access_token&amp;gt;&lt;br /&gt;
&lt;br /&gt;
via curl:&lt;br /&gt;
&amp;lt;pre&amp;gt;curl --url https://authportal.viewsapp.net/token.php -X POST -d &amp;quot;grant_type=password&amp;quot; -u&amp;lt;username&amp;gt;:&amp;lt;password&amp;gt; -H Accept:application/json&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
====Searching the API&#039;s====&lt;br /&gt;
A lot of the API&#039;s have a search capabilities and share some parameters:&lt;br /&gt;
* q=&amp;lt;string&amp;gt; - This is a free text field for basic searching&lt;br /&gt;
* pageFold=&amp;lt;int&amp;gt; - This the number of results to return in any result set&lt;br /&gt;
* offset=&amp;lt;int&amp;gt; - This is how many records to offset in the result set&lt;br /&gt;
* page=&amp;lt;int&amp;gt; - This can be used in place of offset as is just makes an adjustment to the offset value using the following fomula: &amp;lt;code&amp;gt;offset = (page-1)*pageFold&amp;lt;/code&amp;gt;. &lt;br /&gt;
** &#039;&#039;If used in conjunction with offset, then each page is offset by the specified values also.&#039;&#039;&lt;br /&gt;
** By default this equals 1.&lt;br /&gt;
* archived - By default, only non-archived results are returned. Setting this parameter to 1 result in searching archived records&lt;br /&gt;
&lt;br /&gt;
===Contacts===&lt;br /&gt;
* [[Rest - Contacts - Participants|Particpants]]&lt;br /&gt;
** [[Rest - Contacts - Participants - Sessions|Session Attendance]]&lt;br /&gt;
** [[Rest - Contacts - Participants - Notes|Notes]]&lt;br /&gt;
** [[Rest - Contacts - Participants - Address Book|Address Book]]&lt;br /&gt;
** [[Rest - Contacts - Participants - Questionnaires|Questionnaires]]&lt;br /&gt;
** [[Rest - Contacts - Participants - Volunteering|Volunteering]]&lt;br /&gt;
** [[Rest - Contacts - Participants - Conditions|Conditions]]&lt;br /&gt;
** [[Rest - Contacts - Participants - Restrictions|Restrictions]]&lt;br /&gt;
** [[Rest - Contacts - Participants - Associations|Associations]]&lt;br /&gt;
* [[Rest - Contacts - Staff|Staff]]&lt;br /&gt;
** [[Rest - Contacts - Staff - Sessions|Session Attendance]]&lt;br /&gt;
** [[Rest - Contacts - Staff - Notes|Notes]]&lt;br /&gt;
** [[Rest - Contacts - Staff - Address Book|Address Book]]&lt;br /&gt;
** [[Rest - Contacts - Staff - Questionnaires|Questionnaires]]&lt;br /&gt;
** [[Rest - Contacts - Staff - Volunteering|Volunteering]]&lt;br /&gt;
** [[Rest - Contacts - Staff - Associations|Associations]]&lt;br /&gt;
* [[Rest - Contacts - Volunteers|Volunteers]]&lt;br /&gt;
** [[Rest - Contacts - Volunteers - Sessions|Session Attendance]]&lt;br /&gt;
** [[Rest - Contacts - Volunteers - Notes|Notes]]&lt;br /&gt;
** [[Rest - Contacts - Volunteers - Address Book|Address Book]]&lt;br /&gt;
** [[Rest - Contacts - Volunteers - Questionnaires|Questionnaires]]&lt;br /&gt;
** [[Rest - Contacts - Volunteers - Volunteering|Volunteering]]&lt;br /&gt;
&lt;br /&gt;
===Work===&lt;br /&gt;
* [[Rest - Work - Venues|Venues]]&lt;br /&gt;
* [[Rest - Work - Session Groups|Session Groups]]&lt;br /&gt;
** [[Rest - Work - Session Groups - Participants|Session Group Participants]]&lt;br /&gt;
** [[Rest - Work - Session Groups - Sessions|Sessions]]&lt;br /&gt;
*** [[Rest - Work - Session Groups - Session Notes|Session Notes]]&lt;br /&gt;
*** [[Rest - Work - Session Groups - Session Participants|Session Participants]]&lt;br /&gt;
*** [[Rest - Work - Session Groups - Session Staff|Session Staff]]&lt;br /&gt;
*** [[Rest - Work - Session Groups - Session Questionnaires|Session Questionnaires]]&lt;br /&gt;
* [[Rest - Work - Agency Projects|Agency Projects]]&lt;br /&gt;
** [[Rest - Work - Agency Projects - Session Groups|Agency Project Session Groups]]&lt;br /&gt;
** [[Rest - Work - Agency Projects - Objectives|Objectives]]&lt;br /&gt;
** [[Rest - Work - Agency Projects - Outcomes|Outcomes]]&lt;br /&gt;
&lt;br /&gt;
===Evidence===&lt;br /&gt;
* [[Rest - Evidence - Questionnaires|Questionnaires]]&lt;br /&gt;
** [[Rest - Evidence - Questionnaires - Questions|Questions]]&lt;br /&gt;
** [[Rest - Evidence - Questionnaires - Answers|Answers]]&lt;br /&gt;
&lt;br /&gt;
===Admin===&lt;br /&gt;
* [[Rest - Admin - Value Lists|Value Lists]]&lt;br /&gt;
* [[Rest - Admin - Programmes|Programmes]]&lt;br /&gt;
* [[Rest - Admin - Objectives|Objectives]]&lt;br /&gt;
* [[Rest - Admin - Outcomes|Outcomes]]&lt;br /&gt;
* [[Rest - Admin - ProgrammeFields|Programme Fields]]&lt;br /&gt;
* [[Rest - Admin - Change Log|Change Log]]&lt;br /&gt;
* [[Rest - Admin - Flatpack|Flatpack]]&lt;br /&gt;
&lt;br /&gt;
==SOAP Documention==&lt;br /&gt;
===Contacts===&lt;br /&gt;
* [[SOAP - Contacts - Particpants|Particpants]]&lt;br /&gt;
* [[SOAP - Contacts - Staff|Staff]]&lt;br /&gt;
===Evidence===&lt;br /&gt;
* [[SOAP - Questionaires|Questionaires]]&lt;/div&gt;</summary>
		<author><name>Wikiadmin</name></author>
	</entry>
	<entry>
		<id>https://www.substance.net/views-api-docs/index.php?title=Rest_-_Contacts_-_Groups_-_Associations&amp;diff=306</id>
		<title>Rest - Contacts - Groups - Associations</title>
		<link rel="alternate" type="text/html" href="https://www.substance.net/views-api-docs/index.php?title=Rest_-_Contacts_-_Groups_-_Associations&amp;diff=306"/>
		<updated>2022-01-17T12:26:17Z</updated>

		<summary type="html">&lt;p&gt;Wikiadmin: Created page with &amp;quot;==Purpose==  Used for viewing, creating, editing and deleting associations against a group in the Views system.  ===Base URL=== &amp;lt;nowiki&amp;gt;https://app.viewsapp.net/api/restful/co...&amp;quot;&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;==Purpose==&lt;br /&gt;
&lt;br /&gt;
Used for viewing, creating, editing and deleting associations against a group in the Views system.&lt;br /&gt;
&lt;br /&gt;
===Base URL===&lt;br /&gt;
&amp;lt;nowiki&amp;gt;https://app.viewsapp.net/api/restful/contacts/groups/&amp;lt;id&amp;gt;/associations&amp;lt;/nowiki&amp;gt;&lt;br /&gt;
&lt;br /&gt;
==Creating Associations==&lt;br /&gt;
&#039;&#039;Please note&#039;&#039; All parameters with * are required.&lt;br /&gt;
&lt;br /&gt;
 curl --url &amp;lt;Base URL&amp;gt; -u&amp;lt;username&amp;gt;:&amp;lt;password&amp;gt; -H Content-Type:text/xml -X POST -d &amp;quot;&amp;lt;xml&amp;gt;&amp;quot;&lt;br /&gt;
* associationType* - The association contact type&lt;br /&gt;
* associationId* - The association contactID&lt;br /&gt;
* association* - The association&lt;br /&gt;
* description - The association description&lt;br /&gt;
* validityFrom - The association validity start date&lt;br /&gt;
* validityTo - The association validity end date&lt;br /&gt;
&lt;br /&gt;
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.&lt;br /&gt;
&lt;br /&gt;
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.&lt;br /&gt;
&lt;br /&gt;
==Searching for Associations==&lt;br /&gt;
 curl --url &amp;lt;Base URL&amp;gt; -u&amp;lt;username&amp;gt;:&amp;lt;password&amp;gt; -H Content-Type:text/xml&lt;br /&gt;
&lt;br /&gt;
This will list all associations against a group. You can append one of the following to limit the list:&lt;br /&gt;
* associationType - The association contact type&lt;br /&gt;
* q - The search value can contain text or date in d/m/Y format [the results will be filtered by Association, Description, StartDate and EndDate columns]&lt;br /&gt;
&lt;br /&gt;
By default ALL group associations are returned.&lt;br /&gt;
&lt;br /&gt;
==Fetching an Association==&lt;br /&gt;
 curl --url &amp;lt;Base URL&amp;gt;/&amp;lt;id&amp;gt; -u&amp;lt;username&amp;gt;:&amp;lt;password&amp;gt; -H Content-Type:text/xml&lt;br /&gt;
* id - The ID of the association&lt;br /&gt;
&lt;br /&gt;
This method will only fetch Hroup association.&lt;br /&gt;
&lt;br /&gt;
==Updating an Association==&lt;br /&gt;
&lt;br /&gt;
 curl --url &amp;lt;Base URL&amp;gt;/&amp;lt;id&amp;gt; -u&amp;lt;username&amp;gt;:&amp;lt;password&amp;gt; -H Content-Type:text/xml -X PUT -d &amp;quot;&amp;lt;xml&amp;gt;&amp;quot;&lt;br /&gt;
* id - The ID of the association&lt;br /&gt;
* association - The association&lt;br /&gt;
* description - The association description&lt;br /&gt;
* validityFrom - The association validity start date&lt;br /&gt;
* validityTo - The association validity end date&lt;br /&gt;
&lt;br /&gt;
The XML should be in the same format as the create, as specified by the schema&lt;br /&gt;
&lt;br /&gt;
==Deleting an Association==&lt;br /&gt;
&lt;br /&gt;
 curl --url &amp;lt;Base URL&amp;gt;/&amp;lt;id&amp;gt; -u&amp;lt;username&amp;gt;:&amp;lt;password&amp;gt; -H Content-Type:text/xml -X DELETE&lt;br /&gt;
* id - The ID of the association&lt;br /&gt;
&lt;br /&gt;
This should be used with great care as it will permanently delete the association record.&lt;/div&gt;</summary>
		<author><name>Wikiadmin</name></author>
	</entry>
	<entry>
		<id>https://www.substance.net/views-api-docs/index.php?title=Rest_-_Contacts_-_Professionals_-_Associations&amp;diff=305</id>
		<title>Rest - Contacts - Professionals - Associations</title>
		<link rel="alternate" type="text/html" href="https://www.substance.net/views-api-docs/index.php?title=Rest_-_Contacts_-_Professionals_-_Associations&amp;diff=305"/>
		<updated>2022-01-17T12:25:46Z</updated>

		<summary type="html">&lt;p&gt;Wikiadmin: Created page with &amp;quot;==Purpose==  Used for viewing, creating, editing and deleting associations against a professional in the Views system.  ===Base URL=== &amp;lt;nowiki&amp;gt;https://app.viewsapp.net/api/res...&amp;quot;&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;==Purpose==&lt;br /&gt;
&lt;br /&gt;
Used for viewing, creating, editing and deleting associations against a professional in the Views system.&lt;br /&gt;
&lt;br /&gt;
===Base URL===&lt;br /&gt;
&amp;lt;nowiki&amp;gt;https://app.viewsapp.net/api/restful/contacts/professionals/&amp;lt;id&amp;gt;/associations&amp;lt;/nowiki&amp;gt;&lt;br /&gt;
&lt;br /&gt;
==Creating Associations==&lt;br /&gt;
&#039;&#039;Please note&#039;&#039; All parameters with * are required.&lt;br /&gt;
&lt;br /&gt;
 curl --url &amp;lt;Base URL&amp;gt; -u&amp;lt;username&amp;gt;:&amp;lt;password&amp;gt; -H Content-Type:text/xml -X POST -d &amp;quot;&amp;lt;xml&amp;gt;&amp;quot;&lt;br /&gt;
* associationType* - The association contact type&lt;br /&gt;
* associationId* - The association contactID&lt;br /&gt;
* association* - The association&lt;br /&gt;
* description - The association description&lt;br /&gt;
* validityFrom - The association validity start date&lt;br /&gt;
* validityTo - The association validity end date&lt;br /&gt;
&lt;br /&gt;
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.&lt;br /&gt;
&lt;br /&gt;
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.&lt;br /&gt;
&lt;br /&gt;
==Searching for Associations==&lt;br /&gt;
 curl --url &amp;lt;Base URL&amp;gt; -u&amp;lt;username&amp;gt;:&amp;lt;password&amp;gt; -H Content-Type:text/xml&lt;br /&gt;
&lt;br /&gt;
This will list all associations against a professional. You can append one of the following to limit the list:&lt;br /&gt;
* associationType - The association contact type&lt;br /&gt;
* q - The search value can contain text or date in d/m/Y format [the results will be filtered by Association, Description, StartDate and EndDate columns]&lt;br /&gt;
&lt;br /&gt;
By default ALL professional associations are returned.&lt;br /&gt;
&lt;br /&gt;
==Fetching an Association==&lt;br /&gt;
 curl --url &amp;lt;Base URL&amp;gt;/&amp;lt;id&amp;gt; -u&amp;lt;username&amp;gt;:&amp;lt;password&amp;gt; -H Content-Type:text/xml&lt;br /&gt;
* id - The ID of the association&lt;br /&gt;
&lt;br /&gt;
This method will only fetch Professional association.&lt;br /&gt;
&lt;br /&gt;
==Updating an Association==&lt;br /&gt;
&lt;br /&gt;
 curl --url &amp;lt;Base URL&amp;gt;/&amp;lt;id&amp;gt; -u&amp;lt;username&amp;gt;:&amp;lt;password&amp;gt; -H Content-Type:text/xml -X PUT -d &amp;quot;&amp;lt;xml&amp;gt;&amp;quot;&lt;br /&gt;
* id - The ID of the association&lt;br /&gt;
* association - The association&lt;br /&gt;
* description - The association description&lt;br /&gt;
* validityFrom - The association validity start date&lt;br /&gt;
* validityTo - The association validity end date&lt;br /&gt;
&lt;br /&gt;
The XML should be in the same format as the create, as specified by the schema&lt;br /&gt;
&lt;br /&gt;
==Deleting an Association==&lt;br /&gt;
&lt;br /&gt;
 curl --url &amp;lt;Base URL&amp;gt;/&amp;lt;id&amp;gt; -u&amp;lt;username&amp;gt;:&amp;lt;password&amp;gt; -H Content-Type:text/xml -X DELETE&lt;br /&gt;
* id - The ID of the association&lt;br /&gt;
&lt;br /&gt;
This should be used with great care as it will permanently delete the association record.&lt;/div&gt;</summary>
		<author><name>Wikiadmin</name></author>
	</entry>
	<entry>
		<id>https://www.substance.net/views-api-docs/index.php?title=Rest_-_Contacts_-_Staff_-_Associations&amp;diff=304</id>
		<title>Rest - Contacts - Staff - Associations</title>
		<link rel="alternate" type="text/html" href="https://www.substance.net/views-api-docs/index.php?title=Rest_-_Contacts_-_Staff_-_Associations&amp;diff=304"/>
		<updated>2022-01-17T12:22:55Z</updated>

		<summary type="html">&lt;p&gt;Wikiadmin: Created page with &amp;quot;==Purpose==  Used for viewing, creating, editing and deleting associations against a staff in the Views system.  ===Base URL=== &amp;lt;nowiki&amp;gt;https://app.viewsapp.net/api/restful/co...&amp;quot;&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;==Purpose==&lt;br /&gt;
&lt;br /&gt;
Used for viewing, creating, editing and deleting associations against a staff in the Views system.&lt;br /&gt;
&lt;br /&gt;
===Base URL===&lt;br /&gt;
&amp;lt;nowiki&amp;gt;https://app.viewsapp.net/api/restful/contacts/staff/&amp;lt;id&amp;gt;/associations&amp;lt;/nowiki&amp;gt;&lt;br /&gt;
&lt;br /&gt;
==Creating Associations==&lt;br /&gt;
&#039;&#039;Please note&#039;&#039; All parameters with * are required.&lt;br /&gt;
&lt;br /&gt;
 curl --url &amp;lt;Base URL&amp;gt; -u&amp;lt;username&amp;gt;:&amp;lt;password&amp;gt; -H Content-Type:text/xml -X POST -d &amp;quot;&amp;lt;xml&amp;gt;&amp;quot;&lt;br /&gt;
* associationType* - The association contact type&lt;br /&gt;
* associationId* - The association contactID&lt;br /&gt;
* association* - The association&lt;br /&gt;
* description - The association description&lt;br /&gt;
* validityFrom - The association validity start date&lt;br /&gt;
* validityTo - The association validity end date&lt;br /&gt;
&lt;br /&gt;
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.&lt;br /&gt;
&lt;br /&gt;
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.&lt;br /&gt;
&lt;br /&gt;
==Searching for Associations==&lt;br /&gt;
 curl --url &amp;lt;Base URL&amp;gt; -u&amp;lt;username&amp;gt;:&amp;lt;password&amp;gt; -H Content-Type:text/xml&lt;br /&gt;
&lt;br /&gt;
This will list all associations against a staff. You can append one of the following to limit the list:&lt;br /&gt;
* associationType - The association contact type&lt;br /&gt;
* q - The search value can contain text or date in d/m/Y format [the results will be filtered by Association, Description, StartDate and EndDate columns]&lt;br /&gt;
&lt;br /&gt;
By default ALL staff associations are returned.&lt;br /&gt;
&lt;br /&gt;
==Fetching an Association==&lt;br /&gt;
 curl --url &amp;lt;Base URL&amp;gt;/&amp;lt;id&amp;gt; -u&amp;lt;username&amp;gt;:&amp;lt;password&amp;gt; -H Content-Type:text/xml&lt;br /&gt;
* id - The ID of the association&lt;br /&gt;
&lt;br /&gt;
This method will only fetch Staff association.&lt;br /&gt;
&lt;br /&gt;
==Updating an Association==&lt;br /&gt;
&lt;br /&gt;
 curl --url &amp;lt;Base URL&amp;gt;/&amp;lt;id&amp;gt; -u&amp;lt;username&amp;gt;:&amp;lt;password&amp;gt; -H Content-Type:text/xml -X PUT -d &amp;quot;&amp;lt;xml&amp;gt;&amp;quot;&lt;br /&gt;
* id - The ID of the association&lt;br /&gt;
* association - The association&lt;br /&gt;
* description - The association description&lt;br /&gt;
* validityFrom - The association validity start date&lt;br /&gt;
* validityTo - The association validity end date&lt;br /&gt;
&lt;br /&gt;
The XML should be in the same format as the create, as specified by the schema&lt;br /&gt;
&lt;br /&gt;
==Deleting an Association==&lt;br /&gt;
&lt;br /&gt;
 curl --url &amp;lt;Base URL&amp;gt;/&amp;lt;id&amp;gt; -u&amp;lt;username&amp;gt;:&amp;lt;password&amp;gt; -H Content-Type:text/xml -X DELETE&lt;br /&gt;
* id - The ID of the association&lt;br /&gt;
&lt;br /&gt;
This should be used with great care as it will permanently delete the association record.&lt;/div&gt;</summary>
		<author><name>Wikiadmin</name></author>
	</entry>
	<entry>
		<id>https://www.substance.net/views-api-docs/index.php?title=Rest_-_Contacts_-_Participants_-_Associations&amp;diff=303</id>
		<title>Rest - Contacts - Participants - Associations</title>
		<link rel="alternate" type="text/html" href="https://www.substance.net/views-api-docs/index.php?title=Rest_-_Contacts_-_Participants_-_Associations&amp;diff=303"/>
		<updated>2022-01-17T12:21:13Z</updated>

		<summary type="html">&lt;p&gt;Wikiadmin: Created page with &amp;quot;==Purpose==  Used for viewing, creating, editing and deleting associations against a participant in the Views system.  ===Base URL=== &amp;lt;nowiki&amp;gt;https://app.viewsapp.net/api/rest...&amp;quot;&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;==Purpose==&lt;br /&gt;
&lt;br /&gt;
Used for viewing, creating, editing and deleting associations against a participant in the Views system.&lt;br /&gt;
&lt;br /&gt;
===Base URL===&lt;br /&gt;
&amp;lt;nowiki&amp;gt;https://app.viewsapp.net/api/restful/contacts/participants/&amp;lt;id&amp;gt;/associations&amp;lt;/nowiki&amp;gt;&lt;br /&gt;
&lt;br /&gt;
==Creating Associations==&lt;br /&gt;
&#039;&#039;Please note&#039;&#039; All parameters with * are required.&lt;br /&gt;
&lt;br /&gt;
 curl --url &amp;lt;Base URL&amp;gt; -u&amp;lt;username&amp;gt;:&amp;lt;password&amp;gt; -H Content-Type:text/xml -X POST -d &amp;quot;&amp;lt;xml&amp;gt;&amp;quot;&lt;br /&gt;
* associationType* - The association contact type&lt;br /&gt;
* associationId* - The association contactID&lt;br /&gt;
* association* - The association&lt;br /&gt;
* description - The association description&lt;br /&gt;
* validityFrom - The association validity start date&lt;br /&gt;
* validityTo - The association validity end date&lt;br /&gt;
&lt;br /&gt;
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.&lt;br /&gt;
&lt;br /&gt;
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.&lt;br /&gt;
&lt;br /&gt;
==Searching for Associations==&lt;br /&gt;
 curl --url &amp;lt;Base URL&amp;gt; -u&amp;lt;username&amp;gt;:&amp;lt;password&amp;gt; -H Content-Type:text/xml&lt;br /&gt;
&lt;br /&gt;
This will list all associations against a participant. You can append one of the following to limit the list:&lt;br /&gt;
* associationType - The association contact type&lt;br /&gt;
* q - The search value can contain text or date in d/m/Y format [the results will be filtered by Association, Description, StartDate and EndDate columns]&lt;br /&gt;
&lt;br /&gt;
By default ALL participant associations are returned.&lt;br /&gt;
&lt;br /&gt;
==Fetching an Association==&lt;br /&gt;
 curl --url &amp;lt;Base URL&amp;gt;/&amp;lt;id&amp;gt; -u&amp;lt;username&amp;gt;:&amp;lt;password&amp;gt; -H Content-Type:text/xml&lt;br /&gt;
* id - The ID of the association&lt;br /&gt;
&lt;br /&gt;
This method will only fetch Participant association.&lt;br /&gt;
&lt;br /&gt;
==Updating an Association==&lt;br /&gt;
&lt;br /&gt;
 curl --url &amp;lt;Base URL&amp;gt;/&amp;lt;id&amp;gt; -u&amp;lt;username&amp;gt;:&amp;lt;password&amp;gt; -H Content-Type:text/xml -X PUT -d &amp;quot;&amp;lt;xml&amp;gt;&amp;quot;&lt;br /&gt;
* id - The ID of the association&lt;br /&gt;
* association - The association&lt;br /&gt;
* description - The association description&lt;br /&gt;
* validityFrom - The association validity start date&lt;br /&gt;
* validityTo - The association validity end date&lt;br /&gt;
&lt;br /&gt;
The XML should be in the same format as the create, as specified by the schema&lt;br /&gt;
&lt;br /&gt;
==Deleting an Association==&lt;br /&gt;
&lt;br /&gt;
 curl --url &amp;lt;Base URL&amp;gt;/&amp;lt;id&amp;gt; -u&amp;lt;username&amp;gt;:&amp;lt;password&amp;gt; -H Content-Type:text/xml -X DELETE&lt;br /&gt;
* id - The ID of the association&lt;br /&gt;
&lt;br /&gt;
This should be used with great care as it will permanently delete the association record.&lt;/div&gt;</summary>
		<author><name>Wikiadmin</name></author>
	</entry>
	<entry>
		<id>https://www.substance.net/views-api-docs/index.php?title=Rest_-_Work_-_Session_Groups_-_Session_Notes&amp;diff=302</id>
		<title>Rest - Work - Session Groups - Session Notes</title>
		<link rel="alternate" type="text/html" href="https://www.substance.net/views-api-docs/index.php?title=Rest_-_Work_-_Session_Groups_-_Session_Notes&amp;diff=302"/>
		<updated>2021-11-09T10:52:47Z</updated>

		<summary type="html">&lt;p&gt;Wikiadmin: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;==Purpose==&lt;br /&gt;
&lt;br /&gt;
Used for creating, editing and deleting notes against a session record in the Views system.&lt;br /&gt;
&lt;br /&gt;
===Base URL===&lt;br /&gt;
https://app.viewsapp.net/api/restful/work/sessiongroups/sessions/&amp;lt;id&amp;gt;/notes&lt;br /&gt;
&lt;br /&gt;
==Creating Sessions==&lt;br /&gt;
&lt;br /&gt;
 curl --url &amp;lt;Base URL&amp;gt; -u&amp;lt;username&amp;gt;:&amp;lt;password&amp;gt; -H Content-Type:text/xml -X POST -d &amp;quot;&amp;lt;xml&amp;gt;&amp;quot;&lt;br /&gt;
&lt;br /&gt;
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.&lt;br /&gt;
&lt;br /&gt;
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.&lt;br /&gt;
&lt;br /&gt;
==Searching for a Note==&lt;br /&gt;
 curl --url &amp;lt;Base URL&amp;gt;/&amp;lt;id&amp;gt; -u&amp;lt;username&amp;gt;:&amp;lt;password&amp;gt; -H Content-Type:text/xml&lt;br /&gt;
&lt;br /&gt;
This will list all notes against a session&lt;br /&gt;
&lt;br /&gt;
==Fetching a Note==&lt;br /&gt;
 curl --url &amp;lt;Base URL&amp;gt;/&amp;lt;id&amp;gt; -u&amp;lt;username&amp;gt;:&amp;lt;password&amp;gt; -H Content-Type:text/xml&lt;br /&gt;
&lt;br /&gt;
This will retreive a note from the views system.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
==Updating a Note==&lt;br /&gt;
&#039;&#039;Please note&#039;&#039; You can only update session record notes via this api.&lt;br /&gt;
&lt;br /&gt;
 curl --url &amp;lt;Base URL&amp;gt;/&amp;lt;id&amp;gt; -u&amp;lt;username&amp;gt;:&amp;lt;password&amp;gt; -H Content-Type:text/xml -X PUT -d &amp;quot;&amp;lt;xml&amp;gt;&amp;quot;&lt;br /&gt;
* id - The ID of the session&lt;br /&gt;
&lt;br /&gt;
The XML should be in the same format as the create, as specified by the schema&lt;br /&gt;
&lt;br /&gt;
==Deleting a Note==&lt;br /&gt;
&#039;&#039;Please note&#039;&#039; You can only delete session record notes via this api. &lt;br /&gt;
 curl --url &amp;lt;Base URL&amp;gt;/&amp;lt;id&amp;gt; -u&amp;lt;username&amp;gt;:&amp;lt;password&amp;gt; -H Content-Type:text/xml -X DELETE&lt;br /&gt;
* id - The ID of the session&lt;br /&gt;
&lt;br /&gt;
This should be used with great care as it will permanently delete a note record.&lt;/div&gt;</summary>
		<author><name>Wikiadmin</name></author>
	</entry>
	<entry>
		<id>https://www.substance.net/views-api-docs/index.php?title=Rest_-_Contacts_-_Volunteers&amp;diff=301</id>
		<title>Rest - Contacts - Volunteers</title>
		<link rel="alternate" type="text/html" href="https://www.substance.net/views-api-docs/index.php?title=Rest_-_Contacts_-_Volunteers&amp;diff=301"/>
		<updated>2021-10-06T08:34:28Z</updated>

		<summary type="html">&lt;p&gt;Wikiadmin: /* Fetching a volunteers record */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;==Purpose==&lt;br /&gt;
&lt;br /&gt;
This is a read-only API for fetching volunteers regardless of whether they are Staff Volunteers or Participant Volunteers&lt;br /&gt;
&lt;br /&gt;
===Base URL===&lt;br /&gt;
https://app.viewsapp.net/api/restful/contacts/volunteers&lt;br /&gt;
&lt;br /&gt;
===Schema===&lt;br /&gt;
&amp;lt;nowiki&amp;gt;https://app.viewsapp.net/api/restful/contacts/volunteers/schema(.xml|.json|.xsd)&amp;lt;/nowiki&amp;gt;&lt;br /&gt;
&lt;br /&gt;
==Fetching a volunteers record==&lt;br /&gt;
 curl --url &amp;lt;Base URL&amp;gt;/&amp;lt;id&amp;gt; -u&amp;lt;username&amp;gt;:&amp;lt;password&amp;gt; -H Content-Type:text/xml&lt;br /&gt;
&lt;br /&gt;
This will return an xml file similar to this&lt;br /&gt;
 &amp;lt;?xml version=&amp;quot;1.0&amp;quot; encoding=&amp;quot;utf-8&amp;quot;?&amp;gt;&lt;br /&gt;
 &amp;lt;volunteers id=&amp;quot;100001&amp;quot;&amp;gt;&lt;br /&gt;
    &amp;lt;Nickname&amp;gt;&amp;lt;/Nickname&amp;gt;&lt;br /&gt;
    &amp;lt;Forename&amp;gt;John&amp;lt;/Forename&amp;gt;&lt;br /&gt;
    &amp;lt;Surname&amp;gt;Smith&amp;lt;/Surname&amp;gt;&lt;br /&gt;
    ...&lt;br /&gt;
    &amp;lt;Created&amp;gt;2011-05-09 10:26:09&amp;lt;/Created&amp;gt;&lt;br /&gt;
    &amp;lt;CreatedBy&amp;gt;a.user&amp;lt;/CreatedBy&amp;gt;&lt;br /&gt;
    &amp;lt;Updated&amp;gt;2011-05-09 10:26:09&amp;lt;/Updated&amp;gt;&lt;br /&gt;
    &amp;lt;UpdatedBy&amp;gt;a.user&amp;lt;/UpdatedBy&amp;gt;&lt;br /&gt;
    &amp;lt;Archived&amp;gt;0000-00-00 00:00:00&amp;lt;/Archived&amp;gt;&lt;br /&gt;
    &amp;lt;ArchivedBy&amp;gt;&amp;lt;/ArchivedBy&amp;gt;&lt;br /&gt;
    &amp;lt;Type&amp;gt;1&amp;lt;/Type&amp;gt;&lt;br /&gt;
    &amp;lt;PersonID&amp;gt;100001&amp;lt;/PersonID&amp;gt;&lt;br /&gt;
    &amp;lt;TypeName&amp;gt;volunteers&amp;lt;/TypeName&amp;gt;&lt;br /&gt;
 &amp;lt;/volunteers&amp;gt;&lt;br /&gt;
&lt;br /&gt;
==Fetching multiple volunteer records in one call==&lt;br /&gt;
It is possible to use the search endpoint to retrieve multiple records&lt;br /&gt;
&lt;br /&gt;
 curl --url &amp;lt;Base URL&amp;gt;/search?PersonID[]=xxx&amp;amp;PersonID[]=xxx&amp;amp;PersonID[]=xxx&amp;amp; -u&amp;lt;username&amp;gt;:&amp;lt;password&amp;gt; -H Content-Type:text/xml &lt;br /&gt;
&lt;br /&gt;
Depending on how many you are fetching, you may need to use POST rather than GET&lt;br /&gt;
&lt;br /&gt;
==Searching for a volunteer record==&lt;br /&gt;
 curl --url &amp;lt;Base URL&amp;gt;/search?q=&amp;lt;query&amp;gt; -u&amp;lt;username&amp;gt;:&amp;lt;password&amp;gt; -H Content-Type:text/xml &lt;br /&gt;
* query - This is a text string to use to search for in the volunteers records&lt;br /&gt;
&lt;br /&gt;
You can search for any field for a specific value by setting the field as a parameter. Please refer to the schema for field names. &lt;br /&gt;
&lt;br /&gt;
There are also a series of fields that you use -from and -to modifiers to express a range:&lt;br /&gt;
* DateOfBirth - yyyy-mm-dd&lt;br /&gt;
* Age - int (Please note that this is in days)&lt;br /&gt;
* Created - yyyy-mm-dd&lt;br /&gt;
* Updated - yyyy-mm-dd&lt;br /&gt;
* Archived - yyyy-mm-dd&lt;br /&gt;
&lt;br /&gt;
==Creating a volunteer record==&lt;br /&gt;
&lt;br /&gt;
Once you have created your data file, you can send it using the following:&lt;br /&gt;
&lt;br /&gt;
 curl --url &amp;lt;Base URL&amp;gt; -u&amp;lt;username&amp;gt;:&amp;lt;password&amp;gt; -H Content-Type:text/xml -X POST -d &amp;quot;&amp;lt;xml&amp;gt;&amp;quot;&lt;br /&gt;
&lt;br /&gt;
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.&lt;br /&gt;
&lt;br /&gt;
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.&lt;br /&gt;
&lt;br /&gt;
==Updating a volunteer record==&lt;br /&gt;
 curl --url &amp;lt;Base URL&amp;gt;/&amp;lt;id&amp;gt; -u&amp;lt;username&amp;gt;:&amp;lt;password&amp;gt; -H Content-Type:text/xml -X PUT -d &amp;quot;&amp;lt;xml&amp;gt;&amp;quot;&lt;br /&gt;
* id - The ID of the volunteer&lt;br /&gt;
&lt;br /&gt;
The XML should be in the same format as the create XML. However, you only need to supply fields that you wish to update. For example:&lt;br /&gt;
 &amp;lt;?xml version=&amp;quot;1.0&amp;quot; encoding=&amp;quot;utf-8&amp;quot;?&amp;gt;&lt;br /&gt;
 &amp;lt;volunteer id=&amp;quot;100001&amp;quot;&amp;gt;&lt;br /&gt;
    &amp;lt;Forename&amp;gt;Jane&amp;lt;/Forename&amp;gt;&lt;br /&gt;
    &amp;lt;Surname&amp;gt;Smith&amp;lt;/Surname&amp;gt;&lt;br /&gt;
 &amp;lt;/volunteer&amp;gt;&lt;br /&gt;
&#039;&#039;The above would result in updating volunteer 1000001&#039;s Forename and Surname values&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
==Archiving a volunteer record==&lt;br /&gt;
 curl --url &amp;lt;Base URL&amp;gt;/&amp;lt;id&amp;gt;/archive -u&amp;lt;username&amp;gt;:&amp;lt;password&amp;gt; -H Content-Type:text/xml -X PUT -d &#039;&amp;lt;status&amp;gt;1&amp;lt;/status&amp;gt;&#039;&lt;br /&gt;
* id - The ID of the volunteer record&lt;br /&gt;
&lt;br /&gt;
This will set the archive flag on a volunteer record. If you set the status to 0, then it will remove the archive flag.&lt;br /&gt;
&lt;br /&gt;
==Deleting a volunteer record==&lt;br /&gt;
 curl --url &amp;lt;Base URL&amp;gt;/&amp;lt;id&amp;gt; -u&amp;lt;username&amp;gt;:&amp;lt;password&amp;gt; -H Content-Type:text/xml -X DELETE&lt;br /&gt;
* id - The ID of the volunteer&lt;br /&gt;
&lt;br /&gt;
This should be used with great care as it will permenently delete a volunteer record.&lt;/div&gt;</summary>
		<author><name>Wikiadmin</name></author>
	</entry>
	<entry>
		<id>https://www.substance.net/views-api-docs/index.php?title=Rest_-_Contacts_-_Participants&amp;diff=300</id>
		<title>Rest - Contacts - Participants</title>
		<link rel="alternate" type="text/html" href="https://www.substance.net/views-api-docs/index.php?title=Rest_-_Contacts_-_Participants&amp;diff=300"/>
		<updated>2021-10-06T08:33:46Z</updated>

		<summary type="html">&lt;p&gt;Wikiadmin: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;==Purpose==&lt;br /&gt;
&lt;br /&gt;
Used for creating, editing and deleting Participants from the Views system.&lt;br /&gt;
&lt;br /&gt;
===Base URL===&lt;br /&gt;
https://app.viewsapp.net/api/restful/contacts/participants&lt;br /&gt;
&lt;br /&gt;
===Schema===&lt;br /&gt;
&amp;lt;nowiki&amp;gt;https://app.viewsapp.net/api/restful/contacts/participants/schema(.xml|.json|.xsd)&amp;lt;/nowiki&amp;gt;&lt;br /&gt;
&lt;br /&gt;
==Creating a participant==&lt;br /&gt;
&lt;br /&gt;
Once you have created your data file, you can send it using the following:&lt;br /&gt;
&lt;br /&gt;
 curl --url &amp;lt;Base URL&amp;gt; -u&amp;lt;username&amp;gt;:&amp;lt;password&amp;gt; -H Content-Type:text/xml -X POST -d &amp;quot;&amp;lt;xml&amp;gt;&amp;quot;&lt;br /&gt;
&lt;br /&gt;
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.&lt;br /&gt;
&lt;br /&gt;
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.&lt;br /&gt;
&lt;br /&gt;
==Fetching a partcipant==&lt;br /&gt;
 curl --url &amp;lt;Base URL&amp;gt;/&amp;lt;id&amp;gt; -u&amp;lt;username&amp;gt;:&amp;lt;password&amp;gt; -H Content-Type:text/xml&lt;br /&gt;
&lt;br /&gt;
This will return an xml file similar to this&lt;br /&gt;
 &amp;lt;?xml version=&amp;quot;1.0&amp;quot; encoding=&amp;quot;utf-8&amp;quot;?&amp;gt;&lt;br /&gt;
 &amp;lt;participant id=&amp;quot;100001&amp;quot;&amp;gt;&lt;br /&gt;
    &amp;lt;Nickname&amp;gt;&amp;lt;/Nickname&amp;gt;&lt;br /&gt;
    &amp;lt;Forename&amp;gt;John&amp;lt;/Forename&amp;gt;&lt;br /&gt;
    &amp;lt;Surname&amp;gt;Smith&amp;lt;/Surname&amp;gt;&lt;br /&gt;
    ...&lt;br /&gt;
    &amp;lt;Created&amp;gt;2011-05-09 10:26:09&amp;lt;/Created&amp;gt;&lt;br /&gt;
    &amp;lt;CreatedBy&amp;gt;a.user&amp;lt;/CreatedBy&amp;gt;&lt;br /&gt;
    &amp;lt;Updated&amp;gt;2011-05-09 10:26:09&amp;lt;/Updated&amp;gt;&lt;br /&gt;
    &amp;lt;UpdatedBy&amp;gt;a.user&amp;lt;/UpdatedBy&amp;gt;&lt;br /&gt;
    &amp;lt;Archived&amp;gt;0000-00-00 00:00:00&amp;lt;/Archived&amp;gt;&lt;br /&gt;
    &amp;lt;ArchivedBy&amp;gt;&amp;lt;/ArchivedBy&amp;gt;&lt;br /&gt;
    &amp;lt;Type&amp;gt;1&amp;lt;/Type&amp;gt;&lt;br /&gt;
    &amp;lt;PersonID&amp;gt;100001&amp;lt;/PersonID&amp;gt;&lt;br /&gt;
    &amp;lt;TypeName&amp;gt;participant&amp;lt;/TypeName&amp;gt;&lt;br /&gt;
 &amp;lt;/participant&amp;gt;&lt;br /&gt;
&lt;br /&gt;
==Fetching multiple partcipant records in one call==&lt;br /&gt;
It is possible to use the search endpoint to retrieve multiple records&lt;br /&gt;
&lt;br /&gt;
 curl --url &amp;lt;Base URL&amp;gt;/search?PersonID[]=xxx&amp;amp;PersonID[]=xxx&amp;amp;PersonID[]=xxx&amp;amp; -u&amp;lt;username&amp;gt;:&amp;lt;password&amp;gt; -H Content-Type:text/xml &lt;br /&gt;
&lt;br /&gt;
Depending on howm any you are fetching, you may need to use POST rather than GET&lt;br /&gt;
&lt;br /&gt;
==Searching for a participant==&lt;br /&gt;
 curl --url &amp;lt;Base URL&amp;gt;/search?q=&amp;lt;query&amp;gt; -u&amp;lt;username&amp;gt;:&amp;lt;password&amp;gt; -H Content-Type:text/xml &lt;br /&gt;
* query - This is a text string to use to search for in the participants records&lt;br /&gt;
&lt;br /&gt;
You can search for any field for a specific value by setting the field as a parameter. Please refer to the schema for fieldnames.&lt;br /&gt;
&lt;br /&gt;
There are also a series of fields that you use -from and -to modifiers to express a range:&lt;br /&gt;
* DateOfBirth - yyyy-mm-dd&lt;br /&gt;
* Age - int (Please note that this is in days)&lt;br /&gt;
* Created - yyyy-mm-dd&lt;br /&gt;
* Updated - yyyy-mm-dd&lt;br /&gt;
* Archived - yyyy-mm-dd&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
==Searching for a participant that has volunteered==&lt;br /&gt;
This can be achieved by adding &amp;lt;code&amp;gt;hasvolunteeres&amp;lt;/code&amp;gt; to the search method as so:&lt;br /&gt;
&lt;br /&gt;
 curl --url &amp;lt;Base URL&amp;gt;/search?hasvoluteered&amp;amp;q=&amp;lt;query&amp;gt; -u&amp;lt;username&amp;gt;:&amp;lt;password&amp;gt; -H Content-Type:text/xml &lt;br /&gt;
&lt;br /&gt;
The default is to filter the results to those that have volunteering records, however you can negate the search results by setting this parameter to one of the following values:&lt;br /&gt;
* 0&lt;br /&gt;
* no&lt;br /&gt;
* false&lt;br /&gt;
&lt;br /&gt;
For example:&lt;br /&gt;
 curl --url &amp;lt;Base URL&amp;gt;/search?hasvoluteered&amp;amp;q=&amp;lt;query&amp;gt; -u&amp;lt;username&amp;gt;:&amp;lt;password&amp;gt; -H Content-Type:text/xml&lt;br /&gt;
&lt;br /&gt;
==Updating a participant==&lt;br /&gt;
 curl --url &amp;lt;Base URL&amp;gt;/&amp;lt;id&amp;gt; -u&amp;lt;username&amp;gt;:&amp;lt;password&amp;gt; -H Content-Type:text/xml -X PUT -d &amp;quot;&amp;lt;xml&amp;gt;&amp;quot;&lt;br /&gt;
* id - The ID of the participant&lt;br /&gt;
&lt;br /&gt;
The XML should be in the same format as the create XML. However, you only need to supply fields that you wish to update. For example:&lt;br /&gt;
 &amp;lt;?xml version=&amp;quot;1.0&amp;quot; encoding=&amp;quot;utf-8&amp;quot;?&amp;gt;&lt;br /&gt;
 &amp;lt;participant id=&amp;quot;100001&amp;quot;&amp;gt;&lt;br /&gt;
    &amp;lt;Forename&amp;gt;Jane&amp;lt;/Forename&amp;gt;&lt;br /&gt;
    &amp;lt;Surname&amp;gt;Smith&amp;lt;/Surname&amp;gt;&lt;br /&gt;
 &amp;lt;/participant&amp;gt;&lt;br /&gt;
&#039;&#039;The above would result in updating participant 1000001&#039;s Forename and Surname values&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
==Archiving a participant==&lt;br /&gt;
 curl --url &amp;lt;Base URL&amp;gt;/&amp;lt;id&amp;gt;/archive -u&amp;lt;username&amp;gt;:&amp;lt;password&amp;gt; -H Content-Type:text/xml -X PUT -d &#039;&amp;lt;status&amp;gt;1&amp;lt;/status&amp;gt;&#039;&lt;br /&gt;
* id - The ID of the participant&lt;br /&gt;
&lt;br /&gt;
This will set the archive flag on a participant. If you set the status to 0, then it will remove the archive flag.&lt;br /&gt;
&lt;br /&gt;
==Deleting a participant==&lt;br /&gt;
 curl --url &amp;lt;Base URL&amp;gt;/&amp;lt;id&amp;gt; -u&amp;lt;username&amp;gt;:&amp;lt;password&amp;gt; -H Content-Type:text/xml -X DELETE&lt;br /&gt;
* id - The ID of the participant&lt;br /&gt;
&lt;br /&gt;
This should be used with great care as it will permenently delet a participants record.&lt;/div&gt;</summary>
		<author><name>Wikiadmin</name></author>
	</entry>
	<entry>
		<id>https://www.substance.net/views-api-docs/index.php?title=Rest_-_Contacts_-_Staff&amp;diff=299</id>
		<title>Rest - Contacts - Staff</title>
		<link rel="alternate" type="text/html" href="https://www.substance.net/views-api-docs/index.php?title=Rest_-_Contacts_-_Staff&amp;diff=299"/>
		<updated>2021-10-06T08:32:37Z</updated>

		<summary type="html">&lt;p&gt;Wikiadmin: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;==Purpose==&lt;br /&gt;
&lt;br /&gt;
TUsed for creating, editing and deleting Staff from the Views system.&lt;br /&gt;
&lt;br /&gt;
===Base URL===&lt;br /&gt;
https://app.viewsapp.net/api/restful/contacts/staff&lt;br /&gt;
&lt;br /&gt;
===Schema===&lt;br /&gt;
&amp;lt;nowiki&amp;gt;https://app.viewsapp.net/api/restful/contacts/staff/schema(.xml|.json|.xsd)&amp;lt;/nowiki&amp;gt;&lt;br /&gt;
&lt;br /&gt;
==Creating a staff record==&lt;br /&gt;
&lt;br /&gt;
Once you have created your data file, you can send it using the following:&lt;br /&gt;
&lt;br /&gt;
 curl --url &amp;lt;Base URL&amp;gt; -u&amp;lt;username&amp;gt;:&amp;lt;password&amp;gt; -H Content-Type:text/xml -X POST -d &amp;quot;&amp;lt;xml&amp;gt;&amp;quot;&lt;br /&gt;
&lt;br /&gt;
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.&lt;br /&gt;
&lt;br /&gt;
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.&lt;br /&gt;
&lt;br /&gt;
==Fetching a staff record==&lt;br /&gt;
 curl --url &amp;lt;Base URL&amp;gt;/&amp;lt;id&amp;gt; -u&amp;lt;username&amp;gt;:&amp;lt;password&amp;gt; -H Content-Type:text/xml&lt;br /&gt;
&lt;br /&gt;
This will return an xml file similar to this&lt;br /&gt;
 &amp;lt;?xml version=&amp;quot;1.0&amp;quot; encoding=&amp;quot;utf-8&amp;quot;?&amp;gt;&lt;br /&gt;
 &amp;lt;staff id=&amp;quot;100001&amp;quot;&amp;gt;&lt;br /&gt;
    &amp;lt;Nickname&amp;gt;&amp;lt;/Nickname&amp;gt;&lt;br /&gt;
    &amp;lt;Forename&amp;gt;John&amp;lt;/Forename&amp;gt;&lt;br /&gt;
    &amp;lt;Surname&amp;gt;Smith&amp;lt;/Surname&amp;gt;&lt;br /&gt;
    ...&lt;br /&gt;
    &amp;lt;Created&amp;gt;2011-05-09 10:26:09&amp;lt;/Created&amp;gt;&lt;br /&gt;
    &amp;lt;CreatedBy&amp;gt;a.user&amp;lt;/CreatedBy&amp;gt;&lt;br /&gt;
    &amp;lt;Updated&amp;gt;2011-05-09 10:26:09&amp;lt;/Updated&amp;gt;&lt;br /&gt;
    &amp;lt;UpdatedBy&amp;gt;a.user&amp;lt;/UpdatedBy&amp;gt;&lt;br /&gt;
    &amp;lt;Archived&amp;gt;0000-00-00 00:00:00&amp;lt;/Archived&amp;gt;&lt;br /&gt;
    &amp;lt;ArchivedBy&amp;gt;&amp;lt;/ArchivedBy&amp;gt;&lt;br /&gt;
    &amp;lt;Type&amp;gt;1&amp;lt;/Type&amp;gt;&lt;br /&gt;
    &amp;lt;PersonID&amp;gt;100001&amp;lt;/PersonID&amp;gt;&lt;br /&gt;
    &amp;lt;TypeName&amp;gt;staff&amp;lt;/TypeName&amp;gt;&lt;br /&gt;
 &amp;lt;/staff&amp;gt;&lt;br /&gt;
&lt;br /&gt;
==Fetching multiple staff records in one call==&lt;br /&gt;
It is possible to use the search endpoint to retrieve multiple records&lt;br /&gt;
&lt;br /&gt;
 curl --url &amp;lt;Base URL&amp;gt;/search?PersonID[]=xxx&amp;amp;PersonID[]=xxx&amp;amp;PersonID[]=xxx&amp;amp; -u&amp;lt;username&amp;gt;:&amp;lt;password&amp;gt; -H Content-Type:text/xml &lt;br /&gt;
&lt;br /&gt;
Depending on how many you are fetching, you may need to use POST rather than GET&lt;br /&gt;
&lt;br /&gt;
==Searching for a staff record==&lt;br /&gt;
 curl --url &amp;lt;Base URL&amp;gt;/search?q=&amp;lt;query&amp;gt; -u&amp;lt;username&amp;gt;:&amp;lt;password&amp;gt; -H Content-Type:text/xml &lt;br /&gt;
* query - This is a text string to use to search for in the staff records&lt;br /&gt;
&lt;br /&gt;
You can search for any field for a specific value by setting the field as a parameter. Please refer to the schema for field names. &lt;br /&gt;
&lt;br /&gt;
There are also a series of fields that you use -from and -to modifiers to express a range:&lt;br /&gt;
* DateOfBirth - yyyy-mm-dd&lt;br /&gt;
* Age - int (Please note that this is in days)&lt;br /&gt;
* Created - yyyy-mm-dd&lt;br /&gt;
* Updated - yyyy-mm-dd&lt;br /&gt;
* Archived - yyyy-mm-dd&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
==Searching for staff that have volunteered==&lt;br /&gt;
This can be achieved by adding &amp;lt;code&amp;gt;hasvolunteeres&amp;lt;/code&amp;gt; to the search method as so:&lt;br /&gt;
&lt;br /&gt;
 curl --url &amp;lt;Base URL&amp;gt;/search?hasvoluteered&amp;amp;q=&amp;lt;query&amp;gt; -u&amp;lt;username&amp;gt;:&amp;lt;password&amp;gt; -H Content-Type:text/xml &lt;br /&gt;
&lt;br /&gt;
The default is to filter the results to those that have volunteering records, however you can negate the search results by setting this parameter to one of the following values:&lt;br /&gt;
* 0&lt;br /&gt;
* no&lt;br /&gt;
* false&lt;br /&gt;
&lt;br /&gt;
For example:&lt;br /&gt;
 curl --url &amp;lt;Base URL&amp;gt;/search?hasvoluteered&amp;amp;q=&amp;lt;query&amp;gt; -u&amp;lt;username&amp;gt;:&amp;lt;password&amp;gt; -H Content-Type:text/xml&lt;br /&gt;
&lt;br /&gt;
==Updating a staff record==&lt;br /&gt;
 curl --url &amp;lt;Base URL&amp;gt;/&amp;lt;id&amp;gt; -u&amp;lt;username&amp;gt;:&amp;lt;password&amp;gt; -H Content-Type:text/xml -X PUT -d &amp;quot;&amp;lt;xml&amp;gt;&amp;quot;&lt;br /&gt;
* id - The ID of the staff&lt;br /&gt;
&lt;br /&gt;
The XML should be in the same format as the create XML. However, you only need to supply fields that you wish to update. For example:&lt;br /&gt;
 &amp;lt;?xml version=&amp;quot;1.0&amp;quot; encoding=&amp;quot;utf-8&amp;quot;?&amp;gt;&lt;br /&gt;
 &amp;lt;staff id=&amp;quot;100001&amp;quot;&amp;gt;&lt;br /&gt;
    &amp;lt;Forename&amp;gt;Jane&amp;lt;/Forename&amp;gt;&lt;br /&gt;
    &amp;lt;Surname&amp;gt;Smith&amp;lt;/Surname&amp;gt;&lt;br /&gt;
 &amp;lt;/staff&amp;gt;&lt;br /&gt;
&#039;&#039;The above would result in updating staff 1000001&#039;s Forename and Surname values&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
==Archiving a staff record==&lt;br /&gt;
 curl --url &amp;lt;Base URL&amp;gt;/&amp;lt;id&amp;gt;/archive -u&amp;lt;username&amp;gt;:&amp;lt;password&amp;gt; -H Content-Type:text/xml -X PUT -d &#039;&amp;lt;status&amp;gt;1&amp;lt;/status&amp;gt;&#039;&lt;br /&gt;
* id - The ID of the staff record&lt;br /&gt;
&lt;br /&gt;
This will set the archive flag on a staff record. If you set the status to 0, then it will remove the archive flag.&lt;br /&gt;
&lt;br /&gt;
==Deleting a staff record==&lt;br /&gt;
 curl --url &amp;lt;Base URL&amp;gt;/&amp;lt;id&amp;gt; -u&amp;lt;username&amp;gt;:&amp;lt;password&amp;gt; -H Content-Type:text/xml -X DELETE&lt;br /&gt;
* id - The ID of the staff&lt;br /&gt;
&lt;br /&gt;
This should be used with great care as it will permenently delete a staff record.&lt;/div&gt;</summary>
		<author><name>Wikiadmin</name></author>
	</entry>
	<entry>
		<id>https://www.substance.net/views-api-docs/index.php?title=Rest_-_Contacts_-_Participants&amp;diff=298</id>
		<title>Rest - Contacts - Participants</title>
		<link rel="alternate" type="text/html" href="https://www.substance.net/views-api-docs/index.php?title=Rest_-_Contacts_-_Participants&amp;diff=298"/>
		<updated>2021-10-06T08:31:35Z</updated>

		<summary type="html">&lt;p&gt;Wikiadmin: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;==Purpose==&lt;br /&gt;
&lt;br /&gt;
Used for creating, editing and deleting Participants from the Views system.&lt;br /&gt;
&lt;br /&gt;
===Base URL===&lt;br /&gt;
https://app.viewsapp.net/api/restful/contacts/participants&lt;br /&gt;
&lt;br /&gt;
===Schema===&lt;br /&gt;
&amp;lt;nowiki&amp;gt;https://app.viewsapp.net/api/restful/contacts/participants/schema(.xml|.json|.xsd)&amp;lt;/nowiki&amp;gt;&lt;br /&gt;
&lt;br /&gt;
==Creating a participant==&lt;br /&gt;
&lt;br /&gt;
Once you have created your data file, you can send it using the following:&lt;br /&gt;
&lt;br /&gt;
 curl --url &amp;lt;Base URL&amp;gt; -u&amp;lt;username&amp;gt;:&amp;lt;password&amp;gt; -H Content-Type:text/xml -X POST -d &amp;quot;&amp;lt;xml&amp;gt;&amp;quot;&lt;br /&gt;
&lt;br /&gt;
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.&lt;br /&gt;
&lt;br /&gt;
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.&lt;br /&gt;
&lt;br /&gt;
==Fetching a partcipant==&lt;br /&gt;
 curl --url &amp;lt;Base URL&amp;gt;/&amp;lt;id&amp;gt; -u&amp;lt;username&amp;gt;:&amp;lt;password&amp;gt; -H Content-Type:text/xml&lt;br /&gt;
&lt;br /&gt;
This will return an xml file similar to this&lt;br /&gt;
 &amp;lt;?xml version=&amp;quot;1.0&amp;quot; encoding=&amp;quot;utf-8&amp;quot;?&amp;gt;&lt;br /&gt;
 &amp;lt;participant id=&amp;quot;100001&amp;quot;&amp;gt;&lt;br /&gt;
    &amp;lt;Nickname&amp;gt;&amp;lt;/Nickname&amp;gt;&lt;br /&gt;
    &amp;lt;Forename&amp;gt;John&amp;lt;/Forename&amp;gt;&lt;br /&gt;
    &amp;lt;Surname&amp;gt;Smith&amp;lt;/Surname&amp;gt;&lt;br /&gt;
    ...&lt;br /&gt;
    &amp;lt;Created&amp;gt;2011-05-09 10:26:09&amp;lt;/Created&amp;gt;&lt;br /&gt;
    &amp;lt;CreatedBy&amp;gt;a.user&amp;lt;/CreatedBy&amp;gt;&lt;br /&gt;
    &amp;lt;Updated&amp;gt;2011-05-09 10:26:09&amp;lt;/Updated&amp;gt;&lt;br /&gt;
    &amp;lt;UpdatedBy&amp;gt;a.user&amp;lt;/UpdatedBy&amp;gt;&lt;br /&gt;
    &amp;lt;Archived&amp;gt;0000-00-00 00:00:00&amp;lt;/Archived&amp;gt;&lt;br /&gt;
    &amp;lt;ArchivedBy&amp;gt;&amp;lt;/ArchivedBy&amp;gt;&lt;br /&gt;
    &amp;lt;Type&amp;gt;1&amp;lt;/Type&amp;gt;&lt;br /&gt;
    &amp;lt;PersonID&amp;gt;100001&amp;lt;/PersonID&amp;gt;&lt;br /&gt;
    &amp;lt;TypeName&amp;gt;participant&amp;lt;/TypeName&amp;gt;&lt;br /&gt;
 &amp;lt;/participant&amp;gt;&lt;br /&gt;
&lt;br /&gt;
==Fetching multiple partcipant records in one call==&lt;br /&gt;
It is possible to use the search endpoint to retrieve multiple records&lt;br /&gt;
&lt;br /&gt;
 curl --url &amp;lt;Base URL&amp;gt;/search?PersonID[]=xxx&amp;amp;PersonID[]=xxx&amp;amp;PersonID[]=xxx&amp;amp; -u&amp;lt;username&amp;gt;:&amp;lt;password&amp;gt; -H Content-Type:text/xml &lt;br /&gt;
&lt;br /&gt;
Depending on howmany you are fetching, you may need to use POST rather than GET&lt;br /&gt;
&lt;br /&gt;
==Searching for a participant==&lt;br /&gt;
 curl --url &amp;lt;Base URL&amp;gt;/search?q=&amp;lt;query&amp;gt; -u&amp;lt;username&amp;gt;:&amp;lt;password&amp;gt; -H Content-Type:text/xml &lt;br /&gt;
* query - This is a text string to use to search for in the participants records&lt;br /&gt;
&lt;br /&gt;
You can search for any field for a specific value by setting the field as a parameter. Please refer to the schema for fieldnames.&lt;br /&gt;
&lt;br /&gt;
There are also a series of fields that you use -from and -to modifiers to express a range:&lt;br /&gt;
* DateOfBirth - yyyy-mm-dd&lt;br /&gt;
* Age - int (Please note that this is in days)&lt;br /&gt;
* Created - yyyy-mm-dd&lt;br /&gt;
* Updated - yyyy-mm-dd&lt;br /&gt;
* Archived - yyyy-mm-dd&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
==Searching for a participant that has volunteered==&lt;br /&gt;
This can be achieved by adding &amp;lt;code&amp;gt;hasvolunteeres&amp;lt;/code&amp;gt; to the search method as so:&lt;br /&gt;
&lt;br /&gt;
 curl --url &amp;lt;Base URL&amp;gt;/search?hasvoluteered&amp;amp;q=&amp;lt;query&amp;gt; -u&amp;lt;username&amp;gt;:&amp;lt;password&amp;gt; -H Content-Type:text/xml &lt;br /&gt;
&lt;br /&gt;
The default is to filter the results to those that have volunteering records, however you can negate the search results by setting this parameter to one of the following values:&lt;br /&gt;
* 0&lt;br /&gt;
* no&lt;br /&gt;
* false&lt;br /&gt;
&lt;br /&gt;
For example:&lt;br /&gt;
 curl --url &amp;lt;Base URL&amp;gt;/search?hasvoluteered&amp;amp;q=&amp;lt;query&amp;gt; -u&amp;lt;username&amp;gt;:&amp;lt;password&amp;gt; -H Content-Type:text/xml&lt;br /&gt;
&lt;br /&gt;
==Updating a participant==&lt;br /&gt;
 curl --url &amp;lt;Base URL&amp;gt;/&amp;lt;id&amp;gt; -u&amp;lt;username&amp;gt;:&amp;lt;password&amp;gt; -H Content-Type:text/xml -X PUT -d &amp;quot;&amp;lt;xml&amp;gt;&amp;quot;&lt;br /&gt;
* id - The ID of the participant&lt;br /&gt;
&lt;br /&gt;
The XML should be in the same format as the create XML. However, you only need to supply fields that you wish to update. For example:&lt;br /&gt;
 &amp;lt;?xml version=&amp;quot;1.0&amp;quot; encoding=&amp;quot;utf-8&amp;quot;?&amp;gt;&lt;br /&gt;
 &amp;lt;participant id=&amp;quot;100001&amp;quot;&amp;gt;&lt;br /&gt;
    &amp;lt;Forename&amp;gt;Jane&amp;lt;/Forename&amp;gt;&lt;br /&gt;
    &amp;lt;Surname&amp;gt;Smith&amp;lt;/Surname&amp;gt;&lt;br /&gt;
 &amp;lt;/participant&amp;gt;&lt;br /&gt;
&#039;&#039;The above would result in updating participant 1000001&#039;s Forename and Surname values&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
==Archiving a participant==&lt;br /&gt;
 curl --url &amp;lt;Base URL&amp;gt;/&amp;lt;id&amp;gt;/archive -u&amp;lt;username&amp;gt;:&amp;lt;password&amp;gt; -H Content-Type:text/xml -X PUT -d &#039;&amp;lt;status&amp;gt;1&amp;lt;/status&amp;gt;&#039;&lt;br /&gt;
* id - The ID of the participant&lt;br /&gt;
&lt;br /&gt;
This will set the archive flag on a participant. If you set the status to 0, then it will remove the archive flag.&lt;br /&gt;
&lt;br /&gt;
==Deleting a participant==&lt;br /&gt;
 curl --url &amp;lt;Base URL&amp;gt;/&amp;lt;id&amp;gt; -u&amp;lt;username&amp;gt;:&amp;lt;password&amp;gt; -H Content-Type:text/xml -X DELETE&lt;br /&gt;
* id - The ID of the participant&lt;br /&gt;
&lt;br /&gt;
This should be used with great care as it will permenently delet a participants record.&lt;/div&gt;</summary>
		<author><name>Wikiadmin</name></author>
	</entry>
	<entry>
		<id>https://www.substance.net/views-api-docs/index.php?title=Views_API_Documentation&amp;diff=297</id>
		<title>Views API Documentation</title>
		<link rel="alternate" type="text/html" href="https://www.substance.net/views-api-docs/index.php?title=Views_API_Documentation&amp;diff=297"/>
		<updated>2021-09-28T08:35:27Z</updated>

		<summary type="html">&lt;p&gt;Wikiadmin: /* Using OAuth2 */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;==Rest==&lt;br /&gt;
===General Overview===&lt;br /&gt;
All of our REST services are available in both XML and JSON formats, unless otherwise stated. The default format is XML. For the purposes of this documentation we only document the XML method. If you want to interact using json, then you should either make sure you request using &amp;lt;code&amp;gt;Content-Type: application/json&amp;lt;/code&amp;gt;, alternatively you have append the extension &amp;lt;code&amp;gt;.json&amp;lt;/code&amp;gt; to the URI e.g:&lt;br /&gt;
 curl --url &amp;lt;Base URL&amp;gt;/&amp;lt;id&amp;gt; -u&amp;lt;username&amp;gt;:&amp;lt;password&amp;gt; -H Accept:application/json&lt;br /&gt;
&lt;br /&gt;
or&lt;br /&gt;
&lt;br /&gt;
 curl --url &amp;lt;Base URL&amp;gt;/&amp;lt;id&amp;gt;.json -u&amp;lt;username&amp;gt;:&amp;lt;password&amp;gt;&lt;br /&gt;
&lt;br /&gt;
====Using OAuth2====&lt;br /&gt;
&lt;br /&gt;
The use of OAthu2 access_tokens can be used. To do this, you must first request an &amp;lt;code&amp;gt;access_token&amp;lt;/code&amp;gt; from the authentication portal https://authport.viewsapp.net/. This can be done in the following way (using Google Apps Script:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
// Get access_token&lt;br /&gt;
var response = UrlFetchApp.fetch(&#039;https://authportal.viewsapp.net/token.php&#039;, {&lt;br /&gt;
  &#039;method&#039;  : &#039;post&#039;,&lt;br /&gt;
  &#039;payload&#039; : {&#039;grant_type&#039;: &#039;password&#039;, &#039;username&#039; : &#039;my_username&#039;, &#039;password&#039; : &#039;my_password&#039;},&lt;br /&gt;
  &#039;headers&#039; : {&amp;quot;Authorization&amp;quot;: &amp;quot;Basic &amp;quot; + Utilities.base64Encode(&#039;my_username&#039; + &amp;quot;:&amp;quot; + &#039;my_password&#039;)}&lt;br /&gt;
});&lt;br /&gt;
var access_token = JSON.parse(response.getContentText()).access_token;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
  &lt;br /&gt;
You would then pass the following fields along side any request:&lt;br /&gt;
&lt;br /&gt;
* client_id=&amp;lt;username&amp;gt;&lt;br /&gt;
* access_token=&amp;lt;access_token&amp;gt;&lt;br /&gt;
&lt;br /&gt;
via curl:&lt;br /&gt;
&amp;lt;pre&amp;gt;curl --url https://authportal.viewsapp.net/token.php -X POST -d &amp;quot;grant_type=password&amp;quot; -u&amp;lt;username&amp;gt;:&amp;lt;password&amp;gt; -H Accept:application/json&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
====Searching the API&#039;s====&lt;br /&gt;
A lot of the API&#039;s have a search capabilities and share some parameters:&lt;br /&gt;
* q=&amp;lt;string&amp;gt; - This is a free text field for basic searching&lt;br /&gt;
* pageFold=&amp;lt;int&amp;gt; - This the number of results to return in any result set&lt;br /&gt;
* offset=&amp;lt;int&amp;gt; - This is how many records to offset in the result set&lt;br /&gt;
* page=&amp;lt;int&amp;gt; - This can be used in place of offset as is just makes an adjustment to the offset value using the following fomula: &amp;lt;code&amp;gt;offset = (page-1)*pageFold&amp;lt;/code&amp;gt;. &lt;br /&gt;
** &#039;&#039;If used in conjunction with offset, then each page is offset by the specified values also.&#039;&#039;&lt;br /&gt;
** By default this equals 1.&lt;br /&gt;
* archived - By default, only non-archived results are returned. Setting this parameter to 1 result in searching archived records&lt;br /&gt;
&lt;br /&gt;
===Contacts===&lt;br /&gt;
* [[Rest - Contacts - Participants|Particpants]]&lt;br /&gt;
** [[Rest - Contacts - Participants - Sessions|Session Attendance]]&lt;br /&gt;
** [[Rest - Contacts - Participants - Notes|Notes]]&lt;br /&gt;
** [[Rest - Contacts - Participants - Address Book|Address Book]]&lt;br /&gt;
** [[Rest - Contacts - Participants - Questionnaires|Questionnaires]]&lt;br /&gt;
** [[Rest - Contacts - Participants - Volunteering|Volunteering]]&lt;br /&gt;
** [[Rest - Contacts - Participants - Conditions|Conditions]]&lt;br /&gt;
** [[Rest - Contacts - Participants - Restrictions|Restrictions]]&lt;br /&gt;
* [[Rest - Contacts - Staff|Staff]]&lt;br /&gt;
** [[Rest - Contacts - Staff - Sessions|Session Attendance]]&lt;br /&gt;
** [[Rest - Contacts - Staff - Notes|Notes]]&lt;br /&gt;
** [[Rest - Contacts - Staff - Address Book|Address Book]]&lt;br /&gt;
** [[Rest - Contacts - Staff - Questionnaires|Questionnaires]]&lt;br /&gt;
** [[Rest - Contacts - Staff - Volunteering|Volunteering]]&lt;br /&gt;
* [[Rest - Contacts - Volunteers|Volunteers]]&lt;br /&gt;
** [[Rest - Contacts - Volunteers - Sessions|Session Attendance]]&lt;br /&gt;
** [[Rest - Contacts - Volunteers - Notes|Notes]]&lt;br /&gt;
** [[Rest - Contacts - Volunteers - Address Book|Address Book]]&lt;br /&gt;
** [[Rest - Contacts - Volunteers - Questionnaires|Questionnaires]]&lt;br /&gt;
** [[Rest - Contacts - Volunteers - Volunteering|Volunteering]]&lt;br /&gt;
&lt;br /&gt;
===Work===&lt;br /&gt;
* [[Rest - Work - Venues|Venues]]&lt;br /&gt;
* [[Rest - Work - Session Groups|Session Groups]]&lt;br /&gt;
** [[Rest - Work - Session Groups - Participants|Session Group Participants]]&lt;br /&gt;
** [[Rest - Work - Session Groups - Sessions|Sessions]]&lt;br /&gt;
*** [[Rest - Work - Session Groups - Session Notes|Session Notes]]&lt;br /&gt;
*** [[Rest - Work - Session Groups - Session Participants|Session Participants]]&lt;br /&gt;
*** [[Rest - Work - Session Groups - Session Staff|Session Staff]]&lt;br /&gt;
*** [[Rest - Work - Session Groups - Session Questionnaires|Session Questionnaires]]&lt;br /&gt;
* [[Rest - Work - Agency Projects|Agency Projects]]&lt;br /&gt;
** [[Rest - Work - Agency Projects - Session Groups|Agency Project Session Groups]]&lt;br /&gt;
** [[Rest - Work - Agency Projects - Objectives|Objectives]]&lt;br /&gt;
** [[Rest - Work - Agency Projects - Outcomes|Outcomes]]&lt;br /&gt;
&lt;br /&gt;
===Evidence===&lt;br /&gt;
* [[Rest - Evidence - Questionnaires|Questionnaires]]&lt;br /&gt;
** [[Rest - Evidence - Questionnaires - Questions|Questions]]&lt;br /&gt;
** [[Rest - Evidence - Questionnaires - Answers|Answers]]&lt;br /&gt;
&lt;br /&gt;
===Admin===&lt;br /&gt;
* [[Rest - Admin - Value Lists|Value Lists]]&lt;br /&gt;
* [[Rest - Admin - Programmes|Programmes]]&lt;br /&gt;
* [[Rest - Admin - Objectives|Objectives]]&lt;br /&gt;
* [[Rest - Admin - Outcomes|Outcomes]]&lt;br /&gt;
* [[Rest - Admin - ProgrammeFields|Programme Fields]]&lt;br /&gt;
* [[Rest - Admin - Change Log|Change Log]]&lt;br /&gt;
* [[Rest - Admin - Flatpack|Flatpack]]&lt;br /&gt;
&lt;br /&gt;
==SOAP Documention==&lt;br /&gt;
===Contacts===&lt;br /&gt;
* [[SOAP - Contacts - Particpants|Particpants]]&lt;br /&gt;
* [[SOAP - Contacts - Staff|Staff]]&lt;br /&gt;
===Evidence===&lt;br /&gt;
* [[SOAP - Questionaires|Questionaires]]&lt;/div&gt;</summary>
		<author><name>Wikiadmin</name></author>
	</entry>
	<entry>
		<id>https://www.substance.net/views-api-docs/index.php?title=Views_API_Documentation&amp;diff=296</id>
		<title>Views API Documentation</title>
		<link rel="alternate" type="text/html" href="https://www.substance.net/views-api-docs/index.php?title=Views_API_Documentation&amp;diff=296"/>
		<updated>2021-09-28T08:32:06Z</updated>

		<summary type="html">&lt;p&gt;Wikiadmin: /* Applying for access to the API */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;==Rest==&lt;br /&gt;
===General Overview===&lt;br /&gt;
All of our REST services are available in both XML and JSON formats, unless otherwise stated. The default format is XML. For the purposes of this documentation we only document the XML method. If you want to interact using json, then you should either make sure you request using &amp;lt;code&amp;gt;Content-Type: application/json&amp;lt;/code&amp;gt;, alternatively you have append the extension &amp;lt;code&amp;gt;.json&amp;lt;/code&amp;gt; to the URI e.g:&lt;br /&gt;
 curl --url &amp;lt;Base URL&amp;gt;/&amp;lt;id&amp;gt; -u&amp;lt;username&amp;gt;:&amp;lt;password&amp;gt; -H Accept:application/json&lt;br /&gt;
&lt;br /&gt;
or&lt;br /&gt;
&lt;br /&gt;
 curl --url &amp;lt;Base URL&amp;gt;/&amp;lt;id&amp;gt;.json -u&amp;lt;username&amp;gt;:&amp;lt;password&amp;gt;&lt;br /&gt;
&lt;br /&gt;
====Using OAuth2====&lt;br /&gt;
&lt;br /&gt;
The use of OAthu2 access_tokens can be used. To do this, you must first request an &amp;lt;code&amp;gt;access_token&amp;lt;/code&amp;gt; from the authentication portal https://authport.viewsapp.net/. This can be done in the following way (using Google Apps Script:&lt;br /&gt;
&lt;br /&gt;
  // Get access_token&lt;br /&gt;
  var response = UrlFetchApp.fetch(&#039;ttps://authportal.viewsapp.net/token.php&#039;, {&lt;br /&gt;
    &#039;method&#039;  : &#039;post&#039;,&lt;br /&gt;
    &#039;payload&#039; : {&#039;grant_type&#039;: &#039;password&#039;, &#039;username&#039; : &#039;my_username&#039;, &#039;password&#039; : &#039;my_password&#039;},&lt;br /&gt;
    &#039;headers&#039; : {&amp;quot;Authorization&amp;quot;: &amp;quot;Basic &amp;quot; + Utilities.base64Encode(&#039;my_username&#039; + &amp;quot;:&amp;quot; + &#039;my_password&#039;)}&lt;br /&gt;
  });&lt;br /&gt;
  var access_token = JSON.parse(response.getContentText()).access_token;&lt;br /&gt;
  &lt;br /&gt;
You would then pass the following fields along side any request:&lt;br /&gt;
&lt;br /&gt;
* client_id=&amp;lt;username&amp;gt;&lt;br /&gt;
* access_token=&amp;lt;access_token&amp;gt;&lt;br /&gt;
&lt;br /&gt;
  &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
====Searching the API&#039;s====&lt;br /&gt;
A lot of the API&#039;s have a search capabilities and share some parameters:&lt;br /&gt;
* q=&amp;lt;string&amp;gt; - This is a free text field for basic searching&lt;br /&gt;
* pageFold=&amp;lt;int&amp;gt; - This the number of results to return in any result set&lt;br /&gt;
* offset=&amp;lt;int&amp;gt; - This is how many records to offset in the result set&lt;br /&gt;
* page=&amp;lt;int&amp;gt; - This can be used in place of offset as is just makes an adjustment to the offset value using the following fomula: &amp;lt;code&amp;gt;offset = (page-1)*pageFold&amp;lt;/code&amp;gt;. &lt;br /&gt;
** &#039;&#039;If used in conjunction with offset, then each page is offset by the specified values also.&#039;&#039;&lt;br /&gt;
** By default this equals 1.&lt;br /&gt;
* archived - By default, only non-archived results are returned. Setting this parameter to 1 result in searching archived records&lt;br /&gt;
&lt;br /&gt;
===Contacts===&lt;br /&gt;
* [[Rest - Contacts - Participants|Particpants]]&lt;br /&gt;
** [[Rest - Contacts - Participants - Sessions|Session Attendance]]&lt;br /&gt;
** [[Rest - Contacts - Participants - Notes|Notes]]&lt;br /&gt;
** [[Rest - Contacts - Participants - Address Book|Address Book]]&lt;br /&gt;
** [[Rest - Contacts - Participants - Questionnaires|Questionnaires]]&lt;br /&gt;
** [[Rest - Contacts - Participants - Volunteering|Volunteering]]&lt;br /&gt;
** [[Rest - Contacts - Participants - Conditions|Conditions]]&lt;br /&gt;
** [[Rest - Contacts - Participants - Restrictions|Restrictions]]&lt;br /&gt;
* [[Rest - Contacts - Staff|Staff]]&lt;br /&gt;
** [[Rest - Contacts - Staff - Sessions|Session Attendance]]&lt;br /&gt;
** [[Rest - Contacts - Staff - Notes|Notes]]&lt;br /&gt;
** [[Rest - Contacts - Staff - Address Book|Address Book]]&lt;br /&gt;
** [[Rest - Contacts - Staff - Questionnaires|Questionnaires]]&lt;br /&gt;
** [[Rest - Contacts - Staff - Volunteering|Volunteering]]&lt;br /&gt;
* [[Rest - Contacts - Volunteers|Volunteers]]&lt;br /&gt;
** [[Rest - Contacts - Volunteers - Sessions|Session Attendance]]&lt;br /&gt;
** [[Rest - Contacts - Volunteers - Notes|Notes]]&lt;br /&gt;
** [[Rest - Contacts - Volunteers - Address Book|Address Book]]&lt;br /&gt;
** [[Rest - Contacts - Volunteers - Questionnaires|Questionnaires]]&lt;br /&gt;
** [[Rest - Contacts - Volunteers - Volunteering|Volunteering]]&lt;br /&gt;
&lt;br /&gt;
===Work===&lt;br /&gt;
* [[Rest - Work - Venues|Venues]]&lt;br /&gt;
* [[Rest - Work - Session Groups|Session Groups]]&lt;br /&gt;
** [[Rest - Work - Session Groups - Participants|Session Group Participants]]&lt;br /&gt;
** [[Rest - Work - Session Groups - Sessions|Sessions]]&lt;br /&gt;
*** [[Rest - Work - Session Groups - Session Notes|Session Notes]]&lt;br /&gt;
*** [[Rest - Work - Session Groups - Session Participants|Session Participants]]&lt;br /&gt;
*** [[Rest - Work - Session Groups - Session Staff|Session Staff]]&lt;br /&gt;
*** [[Rest - Work - Session Groups - Session Questionnaires|Session Questionnaires]]&lt;br /&gt;
* [[Rest - Work - Agency Projects|Agency Projects]]&lt;br /&gt;
** [[Rest - Work - Agency Projects - Session Groups|Agency Project Session Groups]]&lt;br /&gt;
** [[Rest - Work - Agency Projects - Objectives|Objectives]]&lt;br /&gt;
** [[Rest - Work - Agency Projects - Outcomes|Outcomes]]&lt;br /&gt;
&lt;br /&gt;
===Evidence===&lt;br /&gt;
* [[Rest - Evidence - Questionnaires|Questionnaires]]&lt;br /&gt;
** [[Rest - Evidence - Questionnaires - Questions|Questions]]&lt;br /&gt;
** [[Rest - Evidence - Questionnaires - Answers|Answers]]&lt;br /&gt;
&lt;br /&gt;
===Admin===&lt;br /&gt;
* [[Rest - Admin - Value Lists|Value Lists]]&lt;br /&gt;
* [[Rest - Admin - Programmes|Programmes]]&lt;br /&gt;
* [[Rest - Admin - Objectives|Objectives]]&lt;br /&gt;
* [[Rest - Admin - Outcomes|Outcomes]]&lt;br /&gt;
* [[Rest - Admin - ProgrammeFields|Programme Fields]]&lt;br /&gt;
* [[Rest - Admin - Change Log|Change Log]]&lt;br /&gt;
* [[Rest - Admin - Flatpack|Flatpack]]&lt;br /&gt;
&lt;br /&gt;
==SOAP Documention==&lt;br /&gt;
===Contacts===&lt;br /&gt;
* [[SOAP - Contacts - Particpants|Particpants]]&lt;br /&gt;
* [[SOAP - Contacts - Staff|Staff]]&lt;br /&gt;
===Evidence===&lt;br /&gt;
* [[SOAP - Questionaires|Questionaires]]&lt;/div&gt;</summary>
		<author><name>Wikiadmin</name></author>
	</entry>
	<entry>
		<id>https://www.substance.net/views-api-docs/index.php?title=Rest_-_Admin_-_Value_Lists&amp;diff=295</id>
		<title>Rest - Admin - Value Lists</title>
		<link rel="alternate" type="text/html" href="https://www.substance.net/views-api-docs/index.php?title=Rest_-_Admin_-_Value_Lists&amp;diff=295"/>
		<updated>2020-09-21T06:59:59Z</updated>

		<summary type="html">&lt;p&gt;Wikiadmin: /* Fetching a Value List */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;==Purpose==&lt;br /&gt;
&lt;br /&gt;
Used for maintaining the value lists within Views.&lt;br /&gt;
&lt;br /&gt;
===Base URL===&lt;br /&gt;
https://app.viewsapp.net/api/restful/admin/valuelists&lt;br /&gt;
&lt;br /&gt;
==Retrieve a list of available value lists==&lt;br /&gt;
 curl --url &amp;lt;Base URL&amp;gt;?type=&amp;lt;type&amp;gt;&amp;amp;mode=&amp;lt;mode&amp;gt; -u&amp;lt;username&amp;gt;:&amp;lt;password&amp;gt; -H Content-Type:text/xml -X POST -d &amp;quot;&amp;lt;xml&amp;gt;&amp;quot;&lt;br /&gt;
&lt;br /&gt;
* type &#039;&#039;&#039;required&#039;&#039;&#039; - This must be one of the following values: &lt;br /&gt;
*# Staff&lt;br /&gt;
*# Volunteer&lt;br /&gt;
*# Individual&lt;br /&gt;
*# Person&lt;br /&gt;
*# Group&lt;br /&gt;
*# Session&lt;br /&gt;
*# SessionGroup&lt;br /&gt;
*# Question&lt;br /&gt;
*# Agency&lt;br /&gt;
*# Venue&lt;br /&gt;
*# QualificationProgress&lt;br /&gt;
*# QualificationAchievement&lt;br /&gt;
*# AddressBook&lt;br /&gt;
*# Report&lt;br /&gt;
* mode - this can be left blank to return a complete list, or one of the following values:&lt;br /&gt;
*# editable - filters the returned value lists that are allowed to be extended&lt;br /&gt;
*# nonsystem - filters the returned value lists to only Non System lists&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
==Retreive the details of a Value List==&lt;br /&gt;
&lt;br /&gt;
 curl --url &amp;lt;Base URL&amp;gt;/&amp;lt;id&amp;gt;/details -u&amp;lt;username&amp;gt;:&amp;lt;password&amp;gt; -H Content-Type:text/xml&lt;br /&gt;
* &#039;&#039;&#039;id&#039;&#039;&#039; - The ID of the Value List&lt;br /&gt;
&lt;br /&gt;
This will return all the meta data about a Value list. &#039;&#039;&#039;&#039;&#039;Needs more detail&#039;&#039;&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
==Fetching a Value List==&lt;br /&gt;
&lt;br /&gt;
 curl --url &amp;lt;Base URL&amp;gt;/&amp;lt;id&amp;gt; -u&amp;lt;username&amp;gt;:&amp;lt;password&amp;gt; -H Content-Type:text/xml&lt;br /&gt;
* &#039;&#039;&#039;id&#039;&#039;&#039; - The ID of the Value List&lt;br /&gt;
&lt;br /&gt;
This will return an xml file similar to the following:&lt;br /&gt;
 &amp;lt;?xml version=&amp;quot;1.0&amp;quot; encoding=&amp;quot;utf-8&amp;quot;?&amp;gt;&lt;br /&gt;
 &amp;lt;valuelist id=&amp;quot;42&amp;quot; count=&amp;quot;4&amp;quot; archived-items=&amp;quot;2&amp;quot;&amp;gt;&lt;br /&gt;
     &amp;lt;items&amp;gt;&lt;br /&gt;
         &amp;lt;item id=&amp;quot;7&amp;quot;&amp;gt;Red&amp;lt;/item&amp;gt;&lt;br /&gt;
         &amp;lt;item id=&amp;quot;18&amp;quot;&amp;gt;Green&amp;lt;/item&amp;gt;&lt;br /&gt;
         &amp;lt;item id=&amp;quot;19&amp;quot;&amp;gt;Blue&amp;lt;/item&amp;gt;&lt;br /&gt;
         &amp;lt;item id=&amp;quot;25&amp;quot;&amp;gt;Purple&amp;lt;/item&amp;gt;&lt;br /&gt;
     &amp;lt;/items&amp;gt;&lt;br /&gt;
 &amp;lt;/valuelist&amp;gt;&lt;br /&gt;
&lt;br /&gt;
==Returning Archived Values==&lt;br /&gt;
&lt;br /&gt;
If an additional parameter &#039;&#039;&#039;include-archived=1&#039;&#039;&#039; is passed then the following would be output:&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;?xml version=&amp;quot;1.0&amp;quot; encoding=&amp;quot;utf-8&amp;quot;?&amp;gt;&lt;br /&gt;
 &amp;lt;valuelist id=&amp;quot;42&amp;quot; count=&amp;quot;6&amp;quot; archived-items=&amp;quot;2&amp;quot;&amp;gt;&lt;br /&gt;
     &amp;lt;items&amp;gt;&lt;br /&gt;
         &amp;lt;item id=&amp;quot;7&amp;quot;&amp;gt;Red&amp;lt;/item&amp;gt;&lt;br /&gt;
         &amp;lt;item id=&amp;quot;18&amp;quot;&amp;gt;Green&amp;lt;/item&amp;gt;&lt;br /&gt;
         &amp;lt;item id=&amp;quot;19&amp;quot;&amp;gt;Blue&amp;lt;/item&amp;gt;&lt;br /&gt;
         &amp;lt;item id=&amp;quot;25&amp;quot;&amp;gt;Purple&amp;lt;/item&amp;gt;&lt;br /&gt;
         &amp;lt;item id=&amp;quot;26&amp;quot; archived=&amp;quot;true&amp;quot;&amp;gt;Orange&amp;lt;/item&amp;gt;&lt;br /&gt;
         &amp;lt;item id=&amp;quot;27&amp;quot; archived=&amp;quot;true&amp;quot;&amp;gt;White&amp;lt;/item&amp;gt;&lt;br /&gt;
     &amp;lt;/items&amp;gt;&lt;br /&gt;
 &amp;lt;/valuelist&amp;gt;&lt;br /&gt;
&lt;br /&gt;
==Fetching a Value List By Name==&lt;br /&gt;
&lt;br /&gt;
 curl --url &amp;lt;Base URL&amp;gt;/&amp;lt;type&amp;gt;/&amp;lt;name&amp;gt; -u&amp;lt;username&amp;gt;:&amp;lt;password&amp;gt; -H Content-Type:text/xml&lt;br /&gt;
* &#039;&#039;&#039;type&#039;&#039;&#039; - This is the type of the Value List. This must be one of the values stated above&lt;br /&gt;
* &#039;&#039;&#039;name&#039;&#039;&#039; - The name of the Value List&lt;br /&gt;
&lt;br /&gt;
This will return an xml file in the same format as fetching a list by id&lt;br /&gt;
&lt;br /&gt;
For eaxample, the following call will get a list of session group volunteering types:&lt;br /&gt;
&lt;br /&gt;
 curl --url &amp;lt;Base URL&amp;gt;/sessiongroup/volunteeringtypes -u&amp;lt;username&amp;gt;:&amp;lt;password&amp;gt; -H Content-Type:text/xml&lt;/div&gt;</summary>
		<author><name>Wikiadmin</name></author>
	</entry>
	<entry>
		<id>https://www.substance.net/views-api-docs/index.php?title=Rest_-_Contacts_-_Volunteers&amp;diff=294</id>
		<title>Rest - Contacts - Volunteers</title>
		<link rel="alternate" type="text/html" href="https://www.substance.net/views-api-docs/index.php?title=Rest_-_Contacts_-_Volunteers&amp;diff=294"/>
		<updated>2019-11-25T11:44:59Z</updated>

		<summary type="html">&lt;p&gt;Wikiadmin: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;==Purpose==&lt;br /&gt;
&lt;br /&gt;
This is a read-only API for fetching volunteers regardless of whether they are Staff Volunteers or Participant Volunteers&lt;br /&gt;
&lt;br /&gt;
===Base URL===&lt;br /&gt;
https://app.viewsapp.net/api/restful/contacts/volunteers&lt;br /&gt;
&lt;br /&gt;
===Schema===&lt;br /&gt;
&amp;lt;nowiki&amp;gt;https://app.viewsapp.net/api/restful/contacts/volunteers/schema(.xml|.json|.xsd)&amp;lt;/nowiki&amp;gt;&lt;br /&gt;
&lt;br /&gt;
==Fetching a volunteers record==&lt;br /&gt;
 curl --url &amp;lt;Base URL&amp;gt;/&amp;lt;id&amp;gt; -u&amp;lt;username&amp;gt;:&amp;lt;password&amp;gt; -H Content-Type:text/xml&lt;br /&gt;
&lt;br /&gt;
This will return an xml file similar to this&lt;br /&gt;
 &amp;lt;?xml version=&amp;quot;1.0&amp;quot; encoding=&amp;quot;utf-8&amp;quot;?&amp;gt;&lt;br /&gt;
 &amp;lt;volunteers id=&amp;quot;100001&amp;quot;&amp;gt;&lt;br /&gt;
    &amp;lt;Nickname&amp;gt;&amp;lt;/Nickname&amp;gt;&lt;br /&gt;
    &amp;lt;Forename&amp;gt;John&amp;lt;/Forename&amp;gt;&lt;br /&gt;
    &amp;lt;Surname&amp;gt;Smith&amp;lt;/Surname&amp;gt;&lt;br /&gt;
    ...&lt;br /&gt;
    &amp;lt;Created&amp;gt;2011-05-09 10:26:09&amp;lt;/Created&amp;gt;&lt;br /&gt;
    &amp;lt;CreatedBy&amp;gt;a.user&amp;lt;/CreatedBy&amp;gt;&lt;br /&gt;
    &amp;lt;Updated&amp;gt;2011-05-09 10:26:09&amp;lt;/Updated&amp;gt;&lt;br /&gt;
    &amp;lt;UpdatedBy&amp;gt;a.user&amp;lt;/UpdatedBy&amp;gt;&lt;br /&gt;
    &amp;lt;Archived&amp;gt;0000-00-00 00:00:00&amp;lt;/Archived&amp;gt;&lt;br /&gt;
    &amp;lt;ArchivedBy&amp;gt;&amp;lt;/ArchivedBy&amp;gt;&lt;br /&gt;
    &amp;lt;Type&amp;gt;1&amp;lt;/Type&amp;gt;&lt;br /&gt;
    &amp;lt;PersonID&amp;gt;100001&amp;lt;/PersonID&amp;gt;&lt;br /&gt;
    &amp;lt;TypeName&amp;gt;volunteers&amp;lt;/TypeName&amp;gt;&lt;br /&gt;
 &amp;lt;/volunteers&amp;gt;&lt;br /&gt;
&lt;br /&gt;
==Searching for a volunteer record==&lt;br /&gt;
 curl --url &amp;lt;Base URL&amp;gt;/search?q=&amp;lt;query&amp;gt; -u&amp;lt;username&amp;gt;:&amp;lt;password&amp;gt; -H Content-Type:text/xml &lt;br /&gt;
* query - This is a text string to use to search for in the volunteers records&lt;br /&gt;
&lt;br /&gt;
You can search for any field for a specific value by setting the field as a parameter. Please refer to the schema for field names. &lt;br /&gt;
&lt;br /&gt;
There are also a series of fields that you use -from and -to modifiers to express a range:&lt;br /&gt;
* DateOfBirth - yyyy-mm-dd&lt;br /&gt;
* Age - int (Please note that this is in days)&lt;br /&gt;
* Created - yyyy-mm-dd&lt;br /&gt;
* Updated - yyyy-mm-dd&lt;br /&gt;
* Archived - yyyy-mm-dd&lt;br /&gt;
&lt;br /&gt;
==Creating a volunteer record==&lt;br /&gt;
&lt;br /&gt;
Once you have created your data file, you can send it using the following:&lt;br /&gt;
&lt;br /&gt;
 curl --url &amp;lt;Base URL&amp;gt; -u&amp;lt;username&amp;gt;:&amp;lt;password&amp;gt; -H Content-Type:text/xml -X POST -d &amp;quot;&amp;lt;xml&amp;gt;&amp;quot;&lt;br /&gt;
&lt;br /&gt;
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.&lt;br /&gt;
&lt;br /&gt;
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.&lt;br /&gt;
&lt;br /&gt;
==Updating a volunteer record==&lt;br /&gt;
 curl --url &amp;lt;Base URL&amp;gt;/&amp;lt;id&amp;gt; -u&amp;lt;username&amp;gt;:&amp;lt;password&amp;gt; -H Content-Type:text/xml -X PUT -d &amp;quot;&amp;lt;xml&amp;gt;&amp;quot;&lt;br /&gt;
* id - The ID of the volunteer&lt;br /&gt;
&lt;br /&gt;
The XML should be in the same format as the create XML. However, you only need to supply fields that you wish to update. For example:&lt;br /&gt;
 &amp;lt;?xml version=&amp;quot;1.0&amp;quot; encoding=&amp;quot;utf-8&amp;quot;?&amp;gt;&lt;br /&gt;
 &amp;lt;volunteer id=&amp;quot;100001&amp;quot;&amp;gt;&lt;br /&gt;
    &amp;lt;Forename&amp;gt;Jane&amp;lt;/Forename&amp;gt;&lt;br /&gt;
    &amp;lt;Surname&amp;gt;Smith&amp;lt;/Surname&amp;gt;&lt;br /&gt;
 &amp;lt;/volunteer&amp;gt;&lt;br /&gt;
&#039;&#039;The above would result in updating volunteer 1000001&#039;s Forename and Surname values&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
==Archiving a volunteer record==&lt;br /&gt;
 curl --url &amp;lt;Base URL&amp;gt;/&amp;lt;id&amp;gt;/archive -u&amp;lt;username&amp;gt;:&amp;lt;password&amp;gt; -H Content-Type:text/xml -X PUT -d &#039;&amp;lt;status&amp;gt;1&amp;lt;/status&amp;gt;&#039;&lt;br /&gt;
* id - The ID of the volunteer record&lt;br /&gt;
&lt;br /&gt;
This will set the archive flag on a volunteer record. If you set the status to 0, then it will remove the archive flag.&lt;br /&gt;
&lt;br /&gt;
==Deleting a volunteer record==&lt;br /&gt;
 curl --url &amp;lt;Base URL&amp;gt;/&amp;lt;id&amp;gt; -u&amp;lt;username&amp;gt;:&amp;lt;password&amp;gt; -H Content-Type:text/xml -X DELETE&lt;br /&gt;
* id - The ID of the volunteer&lt;br /&gt;
&lt;br /&gt;
This should be used with great care as it will permenently delete a volunteer record.&lt;/div&gt;</summary>
		<author><name>Wikiadmin</name></author>
	</entry>
	<entry>
		<id>https://www.substance.net/views-api-docs/index.php?title=Rest_-_Work_-_Session_Groups_-_Participants&amp;diff=293</id>
		<title>Rest - Work - Session Groups - Participants</title>
		<link rel="alternate" type="text/html" href="https://www.substance.net/views-api-docs/index.php?title=Rest_-_Work_-_Session_Groups_-_Participants&amp;diff=293"/>
		<updated>2019-03-18T12:24:01Z</updated>

		<summary type="html">&lt;p&gt;Wikiadmin: Keeping docs up to date with API changes in 5052&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;==Purpose==&lt;br /&gt;
&lt;br /&gt;
Used for administering participant registrations on session groups in the Views system.&lt;br /&gt;
&lt;br /&gt;
===Base URL===&lt;br /&gt;
&amp;lt;nowiki&amp;gt;https://app.viewsapp.net/api/restful/work/sessiongroups/&amp;lt;sid&amp;gt;/participants&amp;lt;/nowiki&amp;gt;&lt;br /&gt;
* &#039;&#039;&#039;sid&#039;&#039;&#039; - This is the id of the session group&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Note:&#039;&#039;&#039; If the Session Group has been archived, this API becomes read only.&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
==Getting the list of participants==&lt;br /&gt;
 curl --url &amp;lt;Base URL&amp;gt; -u&amp;lt;username&amp;gt;:&amp;lt;password&amp;gt; -H Content-Type:text/xml&lt;br /&gt;
&lt;br /&gt;
This will return a list of participants that are associated wit the session group, similar to the following:&lt;br /&gt;
 &amp;lt;sessiongroup id=&amp;quot;7&amp;quot;&amp;gt;&lt;br /&gt;
     &amp;lt;participants&amp;gt;&lt;br /&gt;
         &amp;lt;participant id=&amp;quot;123&amp;quot;&amp;gt;&lt;br /&gt;
             &amp;lt;Name&amp;gt;Jane Smith&amp;lt;/Name&amp;gt;&lt;br /&gt;
             &amp;lt;Type&amp;gt;1&amp;lt;/Type&amp;gt;&lt;br /&gt;
             &amp;lt;Attended/&amp;gt;&lt;br /&gt;
             &amp;lt;FirstAttended/&amp;gt;&lt;br /&gt;
             &amp;lt;Nickname/&amp;gt;&lt;br /&gt;
             &amp;lt;Forename&amp;gt;Jane&amp;lt;/Forename&amp;gt;&lt;br /&gt;
             &amp;lt;Surname&amp;gt;Smith&amp;lt;/Surname&amp;gt;&lt;br /&gt;
             ...&lt;br /&gt;
             &amp;lt;EngagmentLevel&amp;gt;0&amp;lt;/EngagmentLevel&amp;gt;&lt;br /&gt;
             &amp;lt;EngagmentLevelName&amp;gt;Not Set&amp;lt;/EngagmentLevelName&amp;gt;&lt;br /&gt;
         &amp;lt;/participant&amp;gt;&lt;br /&gt;
         &amp;lt;participant id=&amp;quot;102&amp;quot;&amp;gt;&lt;br /&gt;
             &amp;lt;Name&amp;gt;John Smith&amp;lt;/Name&amp;gt;&lt;br /&gt;
             &amp;lt;Type&amp;gt;1&amp;lt;/Type&amp;gt;&lt;br /&gt;
             &amp;lt;Attended/&amp;gt;&lt;br /&gt;
             &amp;lt;FirstAttended/&amp;gt;&lt;br /&gt;
             &amp;lt;Nickname/&amp;gt;&lt;br /&gt;
             &amp;lt;Forename&amp;gt;john&amp;lt;/Forename&amp;gt;&lt;br /&gt;
             &amp;lt;Surname&amp;gt;Smith&amp;lt;/Surname&amp;gt;&lt;br /&gt;
             ...&lt;br /&gt;
             &amp;lt;EngagmentLevel&amp;gt;0&amp;lt;/EngagmentLevel&amp;gt;&lt;br /&gt;
             &amp;lt;EngagmentLevelName&amp;gt;Not Set&lt;br /&gt;
             &amp;lt;/EngagmentLevelName&amp;gt;&lt;br /&gt;
         &amp;lt;/participant&amp;gt;&lt;br /&gt;
     &amp;lt;participants&amp;gt;&lt;br /&gt;
 &amp;lt;/sessiongroup&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Note:&#039;&#039;&#039; If the Session Group is bookable, each participant record will also contain a booking object as well.&lt;br /&gt;
&lt;br /&gt;
==Adding participants to a session group==&lt;br /&gt;
===Adding participants to a non-bookable session group===&lt;br /&gt;
You can add a single participant via the following:&lt;br /&gt;
 curl --url &amp;lt;Base URL&amp;gt;/&amp;lt;pid&amp;gt; -u&amp;lt;username&amp;gt;:&amp;lt;password&amp;gt; -H Content-Type:text/xml -X POST&lt;br /&gt;
*&#039;&#039;&#039;pid&#039;&#039;&#039; - The ID of the participant to add&lt;br /&gt;
&lt;br /&gt;
You can also upload a a list of participants to add to the session register via the following URL&lt;br /&gt;
 curl --url &amp;lt;Base URL&amp;gt; -u&amp;lt;username&amp;gt;:&amp;lt;password&amp;gt; -H Content-Type:text/xml -X PUT&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;participants&amp;gt;&lt;br /&gt;
     &amp;lt;participant&amp;gt;101162&amp;lt;/participant&amp;gt;&lt;br /&gt;
     &amp;lt;participant&amp;gt;103124&amp;lt;/participant&amp;gt;&lt;br /&gt;
     &amp;lt;participant&amp;gt;103413&amp;lt;/participant&amp;gt;&lt;br /&gt;
 &amp;lt;/participants&amp;gt;&lt;br /&gt;
&lt;br /&gt;
===Adding participants to a bookable session groups===&lt;br /&gt;
Due to financial information being required for bookable session groups the method of adding participants in slightly different.&lt;br /&gt;
&lt;br /&gt;
 curl --url &amp;lt;Base URL&amp;gt; -u&amp;lt;username&amp;gt;:&amp;lt;password&amp;gt; -H Content-Type:text/xml -X POST&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;participant&amp;gt;&lt;br /&gt;
     &amp;lt;PersonID&amp;gt;100748&amp;lt;/PersonID&amp;gt;&lt;br /&gt;
     &amp;lt;PaymentType&amp;gt;Debit Card&amp;lt;/PaymentType&amp;gt;&lt;br /&gt;
     &amp;lt;PaymentAmount&amp;gt;20&amp;lt;/PaymentAmount&amp;gt;&lt;br /&gt;
     &amp;lt;PaymentFee&amp;gt;2.50&amp;lt;/PaymentFee&amp;gt;&lt;br /&gt;
     &amp;lt;PaymentReference&amp;gt;7002&amp;lt;/PaymentReference&amp;gt;&lt;br /&gt;
     &amp;lt;Confirmed&amp;gt;1&amp;lt;/Confirmed&amp;gt;&lt;br /&gt;
     &amp;lt;Forename&amp;gt;Father&amp;lt;/Forename&amp;gt;&lt;br /&gt;
     &amp;lt;Surname&amp;gt;Test&amp;lt;/Surname&amp;gt;&lt;br /&gt;
     &amp;lt;Address1/&amp;gt;&lt;br /&gt;
     &amp;lt;Address2/&amp;gt;&lt;br /&gt;
     &amp;lt;Town/&amp;gt;&lt;br /&gt;
     &amp;lt;County/&amp;gt;&lt;br /&gt;
     &amp;lt;Postcode/&amp;gt;&lt;br /&gt;
     &amp;lt;Telephone/&amp;gt;&lt;br /&gt;
     &amp;lt;Email&amp;gt;test@test.com&amp;lt;/Email&amp;gt;&lt;br /&gt;
 &amp;lt;/participant&amp;gt;&lt;br /&gt;
&lt;br /&gt;
This will return errors on a fail or the full booking record on a successful submit.&lt;br /&gt;
&lt;br /&gt;
The required fields are all required:&lt;br /&gt;
* PersonID - This is the ID of the participant&lt;br /&gt;
* PaymentType - One of the following value &#039;Cash&#039;, &#039;Cheque&#039;, &#039;Debit Card&#039;, &#039;Credit Card&#039;, &#039;Other&#039;&lt;br /&gt;
* PaymentAmount - This is the amount paid&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;&#039;&#039;Note:&#039;&#039;&#039;&#039;&#039; If the Booking Mode is Session, then you will be required to pass an extra &amp;lt;code&amp;gt;SessionID&amp;lt;/code&amp;gt; element. For example:&lt;br /&gt;
 &amp;lt;participant&amp;gt;&lt;br /&gt;
     &amp;lt;SessionID&amp;gt;776&amp;lt;/SessionID&amp;gt;&lt;br /&gt;
     &amp;lt;PersonID&amp;gt;100748&amp;lt;/PersonID&amp;gt;&lt;br /&gt;
     &amp;lt;PaymentType&amp;gt;Debit Card&amp;lt;/PaymentType&amp;gt;&lt;br /&gt;
     &amp;lt;PaymentAmount&amp;gt;20&amp;lt;/PaymentAmount&amp;gt;&lt;br /&gt;
     &amp;lt;PaymentFee&amp;gt;2.50&amp;lt;/PaymentFee&amp;gt;&lt;br /&gt;
     &amp;lt;PaymentReference&amp;gt;7002&amp;lt;/PaymentReference&amp;gt;&lt;br /&gt;
     &amp;lt;Confirmed&amp;gt;1&amp;lt;/Confirmed&amp;gt;&lt;br /&gt;
     &amp;lt;Forename&amp;gt;Father&amp;lt;/Forename&amp;gt;&lt;br /&gt;
     &amp;lt;Surname&amp;gt;Test&amp;lt;/Surname&amp;gt;&lt;br /&gt;
     &amp;lt;Address1/&amp;gt;&lt;br /&gt;
     &amp;lt;Address2/&amp;gt;&lt;br /&gt;
     &amp;lt;Town/&amp;gt;&lt;br /&gt;
     &amp;lt;County/&amp;gt;&lt;br /&gt;
     &amp;lt;Postcode/&amp;gt;&lt;br /&gt;
     &amp;lt;Telephone/&amp;gt;&lt;br /&gt;
     &amp;lt;Email&amp;gt;test@test.com&amp;lt;/Email&amp;gt;&lt;br /&gt;
 &amp;lt;/participant&amp;gt;&lt;br /&gt;
&#039;&#039; It is prefered that you use the [[Rest - Work - Session Groups - Session Participants|Session Participants]] API &#039;&#039;&lt;br /&gt;
&lt;br /&gt;
==Removing participants from a session group==&lt;br /&gt;
===Removing participants from a non bookable session group===&lt;br /&gt;
You can remove a single participant from a session group via the following:&lt;br /&gt;
 curl --url &amp;lt;Base URL&amp;gt;/&amp;lt;pid&amp;gt; -u&amp;lt;username&amp;gt;:&amp;lt;password&amp;gt; -H Content-Type:text/xml -X DELETE&lt;br /&gt;
*&#039;&#039;&#039;pid&#039;&#039;&#039; - The ID of the participant to add&lt;br /&gt;
&lt;br /&gt;
You can also upload a a list of participants to remove from the session group via the following URL&lt;br /&gt;
 curl --url &amp;lt;Base URL&amp;gt; -u&amp;lt;username&amp;gt;:&amp;lt;password&amp;gt; -H Content-Type:text/xml -X DELETE&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;participants&amp;gt;&lt;br /&gt;
     &amp;lt;participant&amp;gt;101162&amp;lt;/participant&amp;gt;&lt;br /&gt;
     &amp;lt;participant&amp;gt;103124&amp;lt;/participant&amp;gt;&lt;br /&gt;
     &amp;lt;participant&amp;gt;103413&amp;lt;/participant&amp;gt;&lt;br /&gt;
 &amp;lt;/participants&amp;gt;&lt;br /&gt;
&lt;br /&gt;
In either case server will respond in such format with status for each individual participant:&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;work&amp;gt;&lt;br /&gt;
    &amp;lt;participant id=&amp;quot;1&amp;quot;&amp;gt;Does not exist&amp;lt;/participant&amp;gt;&lt;br /&gt;
    &amp;lt;participant id=&amp;quot;2&amp;quot;&amp;gt;Deleted&amp;lt;/participant&amp;gt;&lt;br /&gt;
    &amp;lt;participant id=&amp;quot;3&amp;quot;&amp;gt;Archived&amp;lt;/participant&amp;gt;&lt;br /&gt;
 &amp;lt;/work&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;&#039;&#039;Note:&#039;&#039;&#039;&#039;&#039; If participant has attended a Session within target Session Group and therefore can&#039;t be removed from Session Group register - his record will be archived.&lt;br /&gt;
&lt;br /&gt;
===Removing participants from a bookable session group===&lt;br /&gt;
You can only remove a single participant&#039;s booking from a session group via the following:&lt;br /&gt;
 curl --url &amp;lt;Base URL&amp;gt;/&amp;lt;pid&amp;gt; -u&amp;lt;username&amp;gt;:&amp;lt;password&amp;gt; -H Content-Type:text/xml -X DELETE&lt;br /&gt;
*&#039;&#039;&#039;pid&#039;&#039;&#039; - The ID of the participant to remove&lt;br /&gt;
&lt;br /&gt;
By default this will flag the participant as cancelled, but will not do anything with the financial side of the booking. To flag a refund was give or a credit note, you should pass the following:&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;refundtype&amp;gt;Refund&amp;lt;/refundtype&amp;gt;&lt;br /&gt;
&lt;br /&gt;
or &lt;br /&gt;
&lt;br /&gt;
 &amp;lt;refundtype&amp;gt;Credit&amp;lt;/refundtype&amp;gt;&lt;br /&gt;
&lt;br /&gt;
This will result in the participants booking being completely being removed from the session group&lt;br /&gt;
&lt;br /&gt;
==Making payments to a booking==&lt;br /&gt;
 curl --url &amp;lt;Base URL&amp;gt;/&amp;lt;id&amp;gt; -u&amp;lt;username&amp;gt;:&amp;lt;password&amp;gt; -H Content-Type:text/xml -X PUT -d &#039;&amp;lt;xml&amp;gt;&#039;&lt;br /&gt;
&lt;br /&gt;
* *id* - This is the participant id&lt;br /&gt;
&lt;br /&gt;
The data for submitting a payment record is currently quite basic. It is our intention to expand on this:&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;payment&amp;gt;&lt;br /&gt;
     &amp;lt;PaymentType&amp;gt;Debit Card&amp;lt;/PaymentType&amp;gt;&lt;br /&gt;
     &amp;lt;PaymentAmount&amp;gt;20&amp;lt;/PaymentAmount&amp;gt;&lt;br /&gt;
 &amp;lt;/payment&amp;gt;&lt;br /&gt;
&lt;br /&gt;
* PaymentType - This must be one of the following values &#039;Cash&#039;, &#039;Cheque&#039;, &#039;Debit Card&#039;, &#039;Credit Card&#039;, &#039;Other&#039;&lt;br /&gt;
* PaymentAmount - This is an amount in pounds.pence&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
==Confirming/Unconfirming a booking==&lt;br /&gt;
 curl --url &amp;lt;Base URL&amp;gt;/&amp;lt;id&amp;gt; -u&amp;lt;username&amp;gt;:&amp;lt;password&amp;gt; -H Content-Type:text/xml -X PUT -d &#039;&amp;lt;xml&amp;gt;&#039;&lt;br /&gt;
&lt;br /&gt;
* *id* - This is the participant id&lt;br /&gt;
&lt;br /&gt;
The data for submitting a payment record is currently quite basic. It is our intention to expand on this:&lt;br /&gt;
 &amp;lt;booking&amp;gt;&lt;br /&gt;
     &amp;lt;Confirmed&amp;gt;1&amp;lt;/Confirmed&amp;gt;&lt;br /&gt;
 &amp;lt;/booking&amp;gt;&#039;&lt;br /&gt;
&lt;br /&gt;
This can also be combined with a payment as such:&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;payment&amp;gt;&lt;br /&gt;
     &amp;lt;PaymentType&amp;gt;Debit Card&amp;lt;/PaymentType&amp;gt;&lt;br /&gt;
     &amp;lt;PaymentAmount&amp;gt;20&amp;lt;/PaymentAmount&amp;gt;&lt;br /&gt;
     &amp;lt;Confirmed&amp;gt;1&amp;lt;/Confirmed&amp;gt;&lt;br /&gt;
 &amp;lt;/payment&amp;gt;&lt;/div&gt;</summary>
		<author><name>Wikiadmin</name></author>
	</entry>
	<entry>
		<id>https://www.substance.net/views-api-docs/index.php?title=Rest_-_Work_-_Session_Groups_-_Session_Participants&amp;diff=292</id>
		<title>Rest - Work - Session Groups - Session Participants</title>
		<link rel="alternate" type="text/html" href="https://www.substance.net/views-api-docs/index.php?title=Rest_-_Work_-_Session_Groups_-_Session_Participants&amp;diff=292"/>
		<updated>2018-02-01T12:39:58Z</updated>

		<summary type="html">&lt;p&gt;Wikiadmin: /* Removing participants from a bookable session */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;==Purpose==&lt;br /&gt;
&lt;br /&gt;
Used for administering participation by participants at sessions in the Views system.&lt;br /&gt;
&lt;br /&gt;
===Base URL===&lt;br /&gt;
&amp;lt;nowiki&amp;gt;https://app.viewsapp.net/api/restful/work/sessiongroups/sessions/&amp;lt;sid&amp;gt;/participants&amp;lt;/nowiki&amp;gt;&lt;br /&gt;
* &#039;&#039;&#039;sid&#039;&#039;&#039; - This is the id of the session group&lt;br /&gt;
&lt;br /&gt;
==Getting the list of participants==&lt;br /&gt;
 curl --url &amp;lt;Base URL&amp;gt; -u&amp;lt;username&amp;gt;:&amp;lt;password&amp;gt; -H Content-Type:text/xml&lt;br /&gt;
&lt;br /&gt;
This will return a list of participants that are associated with a session, similar to the following:&lt;br /&gt;
 &amp;lt;session id=&amp;quot;7&amp;quot;&amp;gt;&lt;br /&gt;
     &amp;lt;participants&amp;gt;&lt;br /&gt;
         &amp;lt;participant id=&amp;quot;123&amp;quot;&amp;gt;&lt;br /&gt;
             &amp;lt;SessionID&amp;gt;25&amp;lt;/SessionID&amp;gt;&lt;br /&gt;
             &amp;lt;SessionGroupID&amp;gt;7&amp;lt;/SessionGroupID&amp;gt;&lt;br /&gt;
             &amp;lt;Name&amp;gt;Jane Smith&amp;lt;/Name&amp;gt;&lt;br /&gt;
             &amp;lt;ContactType&amp;gt;Individual&amp;lt;/ContactType&amp;gt;&lt;br /&gt;
             &amp;lt;Attended&amp;gt;0&amp;lt;/Attended&amp;gt;&lt;br /&gt;
             &amp;lt;Volunteering&amp;gt;&amp;lt;/Volunteering&amp;gt;&lt;br /&gt;
         &amp;lt;/participant&amp;gt;&lt;br /&gt;
         &amp;lt;participant id=&amp;quot;102&amp;quot;&amp;gt;&lt;br /&gt;
             &amp;lt;SessionID&amp;gt;25&amp;lt;/SessionID&amp;gt;&lt;br /&gt;
             &amp;lt;SessionGroupID&amp;gt;7&amp;lt;/SessionGroupID&amp;gt;&lt;br /&gt;
             &amp;lt;Name&amp;gt;John Smith&amp;lt;/Name&amp;gt;&lt;br /&gt;
             &amp;lt;ContactType&amp;gt;Individual&amp;lt;/ContactType&amp;gt;&lt;br /&gt;
             &amp;lt;Attended&amp;gt;1&amp;lt;/Attended&amp;gt;&lt;br /&gt;
             &amp;lt;Volunteering&amp;gt;Made Coffee&amp;lt;/Volunteering&amp;gt;&lt;br /&gt;
         &amp;lt;/participant&amp;gt;&lt;br /&gt;
     &amp;lt;participants&amp;gt;&lt;br /&gt;
 &amp;lt;/sessiongroup&amp;gt;&lt;br /&gt;
&lt;br /&gt;
==Adding Participants to a session==&lt;br /&gt;
&lt;br /&gt;
===Adding participants to a bookable session===&lt;br /&gt;
Due to financial information being required for bookable sessions, the method of adding participants in slightly different.&lt;br /&gt;
&lt;br /&gt;
 curl --url &amp;lt;Base URL&amp;gt; -u&amp;lt;username&amp;gt;:&amp;lt;password&amp;gt; -H Content-Type:text/xml -X POST&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;participant&amp;gt;&lt;br /&gt;
     &amp;lt;PersonID&amp;gt;100748&amp;lt;/PersonID&amp;gt;&lt;br /&gt;
     &amp;lt;PaymentType&amp;gt;Debit Card&amp;lt;/PaymentType&amp;gt;&lt;br /&gt;
     &amp;lt;PaymentAmount&amp;gt;20&amp;lt;/PaymentAmount&amp;gt;&lt;br /&gt;
     &amp;lt;PaymentFee&amp;gt;2.50&amp;lt;/PaymentFee&amp;gt;&lt;br /&gt;
     &amp;lt;PaymentReference&amp;gt;7002&amp;lt;/PaymentReference&amp;gt;&lt;br /&gt;
     &amp;lt;Forename&amp;gt;Father&amp;lt;/Forename&amp;gt;&lt;br /&gt;
     &amp;lt;Surname&amp;gt;Test&amp;lt;/Surname&amp;gt;&lt;br /&gt;
     &amp;lt;Address1/&amp;gt;&lt;br /&gt;
     &amp;lt;Address2/&amp;gt;&lt;br /&gt;
     &amp;lt;Town/&amp;gt;&lt;br /&gt;
     &amp;lt;County/&amp;gt;&lt;br /&gt;
     &amp;lt;Postcode/&amp;gt;&lt;br /&gt;
     &amp;lt;Telephone/&amp;gt;&lt;br /&gt;
     &amp;lt;Email&amp;gt;test@test.com&amp;lt;/Email&amp;gt;&lt;br /&gt;
 &amp;lt;/participant&amp;gt;&lt;br /&gt;
&lt;br /&gt;
This will return errors on a fail or the full booking record on a successful submit.&lt;br /&gt;
&lt;br /&gt;
The required fields are all required:&lt;br /&gt;
* PersonID - This is the ID of the participant&lt;br /&gt;
* PaymentType - One of the following value &#039;Cash&#039;, &#039;Cheque&#039;, &#039;Debit Card&#039;, &#039;Credit Card&#039;, &#039;Other&#039;&lt;br /&gt;
* PaymentAmount - This is the amount paid&lt;br /&gt;
&lt;br /&gt;
===Adding a single participant to a session===&lt;br /&gt;
You can add a single participant via the following:&lt;br /&gt;
 curl --url &amp;lt;Base URL&amp;gt; -u&amp;lt;username&amp;gt;:&amp;lt;password&amp;gt; -H Content-Type:text/xml -X PUT&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;participant&amp;gt;&lt;br /&gt;
     &amp;lt;ContactID&amp;gt;101457&amp;lt;/ContactID&amp;gt;&lt;br /&gt;
     &amp;lt;Attended&amp;gt;0&amp;lt;/Attended&amp;gt;&lt;br /&gt;
     &amp;lt;Volunteering&amp;gt;Volunteered|Made Coffee&amp;lt;/Volunteering&amp;gt;&lt;br /&gt;
 &amp;lt;/participant&amp;gt;&lt;br /&gt;
&lt;br /&gt;
The value for Attended is either 1 or 0, 1 = Attended. This is optional and will default to 0, unless the session has started, in which case the default is 1.&lt;br /&gt;
&lt;br /&gt;
===Adding multiple participants to a session===&lt;br /&gt;
You can also upload a a list of participants to add to the session register via the following URL&lt;br /&gt;
 curl --url &amp;lt;Base URL&amp;gt; -u&amp;lt;username&amp;gt;:&amp;lt;password&amp;gt; -H Content-Type:text/xml -X PUT&lt;br /&gt;
&lt;br /&gt;
This can be useful for setting a register of attending participants.&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;participants&amp;gt;&lt;br /&gt;
     &amp;lt;participant&amp;gt;&lt;br /&gt;
         &amp;lt;ContactID&amp;gt;101457&amp;lt;/ContactID&amp;gt;&lt;br /&gt;
         &amp;lt;Attended&amp;gt;0&amp;lt;/Attended&amp;gt;&lt;br /&gt;
     &amp;lt;/participant&amp;gt;&lt;br /&gt;
     &amp;lt;participant&amp;gt;&lt;br /&gt;
         &amp;lt;ContactID&amp;gt;457&amp;lt;/ContactID&amp;gt;&lt;br /&gt;
         &amp;lt;Attended&amp;gt;1&amp;lt;/Attended&amp;gt;&lt;br /&gt;
         &amp;lt;Volunteering&amp;gt;Volunteered|Made Coffee&amp;lt;/Volunteering&amp;gt;&lt;br /&gt;
     &amp;lt;/participant&amp;gt;&lt;br /&gt;
     &amp;lt;participant&amp;gt;&lt;br /&gt;
         &amp;lt;ContactID&amp;gt;57&amp;lt;/ContactID&amp;gt;&lt;br /&gt;
         &amp;lt;Attended&amp;gt;1&amp;lt;/Attended&amp;gt;&lt;br /&gt;
         &amp;lt;Volunteering&amp;gt;Cleaned Up&amp;lt;/Volunteering&amp;gt;&lt;br /&gt;
     &amp;lt;/participant&amp;gt;&lt;br /&gt;
 &amp;lt;/participants&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;&#039;&#039;Please note:&#039;&#039;&#039; This will replace all existing participant data for the session&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
==Removing participants from a session==&lt;br /&gt;
&lt;br /&gt;
===Removing participants from a non bookable session group===&lt;br /&gt;
&lt;br /&gt;
You can remove a single participant from a session via the following:&lt;br /&gt;
 curl --url &amp;lt;Base URL&amp;gt;/&amp;lt;pid&amp;gt; -u&amp;lt;username&amp;gt;:&amp;lt;password&amp;gt; -H Content-Type:text/xml -X DELETE&lt;br /&gt;
*&#039;&#039;&#039;pid&#039;&#039;&#039; - The ID of the participant to add&lt;br /&gt;
&lt;br /&gt;
You can also upload a a list of participants to remove from the session via the following URL&lt;br /&gt;
 curl --url &amp;lt;Base URL&amp;gt; -u&amp;lt;username&amp;gt;:&amp;lt;password&amp;gt; -H Content-Type:text/xml -X DELETE&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;participants&amp;gt;&lt;br /&gt;
     &amp;lt;participant&amp;gt;101162&amp;lt;/participant&amp;gt;&lt;br /&gt;
     &amp;lt;participant&amp;gt;103124&amp;lt;/participant&amp;gt;&lt;br /&gt;
     &amp;lt;participant&amp;gt;103413&amp;lt;/participant&amp;gt;&lt;br /&gt;
 &amp;lt;/participants&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
===Removing participants from a bookable session===&lt;br /&gt;
You can only remove a single participant&#039;s booking from a session group via the following:&lt;br /&gt;
 curl --url &amp;lt;Base URL&amp;gt;/&amp;lt;pid&amp;gt; -u&amp;lt;username&amp;gt;:&amp;lt;password&amp;gt; -H Content-Type:text/xml -X DELETE&lt;br /&gt;
*&#039;&#039;&#039;pid&#039;&#039;&#039; - The ID of the participant to remove&lt;br /&gt;
&lt;br /&gt;
By default this will flag the participant as cancelled, but will not do anything with the financial side of the booking. To flag a refund was give or a credit note, you should pass the following:&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;refundtype&amp;gt;Refund&amp;lt;/refundtype&amp;gt;&lt;br /&gt;
&lt;br /&gt;
or &lt;br /&gt;
&lt;br /&gt;
 &amp;lt;refundtype&amp;gt;Credit&amp;lt;/refundtype&amp;gt;&lt;br /&gt;
&lt;br /&gt;
This will result in the participants booking being completely being removed from the session&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
==Making payments to a booking==&lt;br /&gt;
 curl --url &amp;lt;Base URL&amp;gt;/&amp;lt;id&amp;gt; -u&amp;lt;username&amp;gt;:&amp;lt;password&amp;gt; -H Content-Type:text/xml -X PUT -d &#039;&amp;lt;xml&amp;gt;&#039;&lt;br /&gt;
&lt;br /&gt;
* *id* - This is the participant id&lt;br /&gt;
&lt;br /&gt;
The data for submitting a payment record is currently quite basic. It is our intention to expand on this:&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;payment&amp;gt;&lt;br /&gt;
     &amp;lt;PaymentType&amp;gt;Debit Card&amp;lt;/PaymentType&amp;gt;&lt;br /&gt;
     &amp;lt;PaymentAmount&amp;gt;20&amp;lt;/PaymentAmount&amp;gt;&lt;br /&gt;
 &amp;lt;/payment&amp;gt;&lt;br /&gt;
&lt;br /&gt;
* PaymentType - This must be one of the following values &#039;Cash&#039;, &#039;Cheque&#039;, &#039;Debit Card&#039;, &#039;Credit Card&#039;, &#039;Other&#039;&lt;br /&gt;
* PaymentAmount - This is an amount in pounds.pence&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
==Confirming/Unconfirming a booking==&lt;br /&gt;
 curl --url &amp;lt;Base URL&amp;gt;/&amp;lt;id&amp;gt; -u&amp;lt;username&amp;gt;:&amp;lt;password&amp;gt; -H Content-Type:text/xml -X PUT -d &#039;&amp;lt;xml&amp;gt;&#039;&lt;br /&gt;
&lt;br /&gt;
* *id* - This is the participant id&lt;br /&gt;
&lt;br /&gt;
The data for submitting a payment record is currently quite basic. It is our intention to expand on this:&lt;br /&gt;
 &amp;lt;booking&amp;gt;&lt;br /&gt;
     &amp;lt;Confirmed&amp;gt;1&amp;lt;/Confirmed&amp;gt;&lt;br /&gt;
 &amp;lt;/booking&amp;gt;&#039;&lt;br /&gt;
&lt;br /&gt;
This can also be combined with a payment as such:&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;payment&amp;gt;&lt;br /&gt;
     &amp;lt;PaymentType&amp;gt;Debit Card&amp;lt;/PaymentType&amp;gt;&lt;br /&gt;
     &amp;lt;PaymentAmount&amp;gt;20&amp;lt;/PaymentAmount&amp;gt;&lt;br /&gt;
     &amp;lt;Confirmed&amp;gt;1&amp;lt;/Confirmed&amp;gt;&lt;br /&gt;
 &amp;lt;/payment&amp;gt;&lt;/div&gt;</summary>
		<author><name>Wikiadmin</name></author>
	</entry>
	<entry>
		<id>https://www.substance.net/views-api-docs/index.php?title=Rest_-_Work_-_Session_Groups_-_Participants&amp;diff=291</id>
		<title>Rest - Work - Session Groups - Participants</title>
		<link rel="alternate" type="text/html" href="https://www.substance.net/views-api-docs/index.php?title=Rest_-_Work_-_Session_Groups_-_Participants&amp;diff=291"/>
		<updated>2018-02-01T12:38:01Z</updated>

		<summary type="html">&lt;p&gt;Wikiadmin: /* Adding participants to a bookable session groups */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;==Purpose==&lt;br /&gt;
&lt;br /&gt;
Used for administering participant registrations on session groups in the Views system.&lt;br /&gt;
&lt;br /&gt;
===Base URL===&lt;br /&gt;
&amp;lt;nowiki&amp;gt;https://app.viewsapp.net/api/restful/work/sessiongroups/&amp;lt;sid&amp;gt;/participants&amp;lt;/nowiki&amp;gt;&lt;br /&gt;
* &#039;&#039;&#039;sid&#039;&#039;&#039; - This is the id of the session group&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Note:&#039;&#039;&#039; If the Session Group has been archived, this API becomes read only.&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
==Getting the list of participants==&lt;br /&gt;
 curl --url &amp;lt;Base URL&amp;gt; -u&amp;lt;username&amp;gt;:&amp;lt;password&amp;gt; -H Content-Type:text/xml&lt;br /&gt;
&lt;br /&gt;
This will return a list of participants that are associated wit the session group, similar to the following:&lt;br /&gt;
 &amp;lt;sessiongroup id=&amp;quot;7&amp;quot;&amp;gt;&lt;br /&gt;
     &amp;lt;participants&amp;gt;&lt;br /&gt;
         &amp;lt;participant id=&amp;quot;123&amp;quot;&amp;gt;&lt;br /&gt;
             &amp;lt;Name&amp;gt;Jane Smith&amp;lt;/Name&amp;gt;&lt;br /&gt;
             &amp;lt;Type&amp;gt;1&amp;lt;/Type&amp;gt;&lt;br /&gt;
             &amp;lt;Attended/&amp;gt;&lt;br /&gt;
             &amp;lt;FirstAttended/&amp;gt;&lt;br /&gt;
             &amp;lt;Nickname/&amp;gt;&lt;br /&gt;
             &amp;lt;Forename&amp;gt;Jane&amp;lt;/Forename&amp;gt;&lt;br /&gt;
             &amp;lt;Surname&amp;gt;Smith&amp;lt;/Surname&amp;gt;&lt;br /&gt;
             ...&lt;br /&gt;
             &amp;lt;EngagmentLevel&amp;gt;0&amp;lt;/EngagmentLevel&amp;gt;&lt;br /&gt;
             &amp;lt;EngagmentLevelName&amp;gt;Not Set&amp;lt;/EngagmentLevelName&amp;gt;&lt;br /&gt;
         &amp;lt;/participant&amp;gt;&lt;br /&gt;
         &amp;lt;participant id=&amp;quot;102&amp;quot;&amp;gt;&lt;br /&gt;
             &amp;lt;Name&amp;gt;John Smith&amp;lt;/Name&amp;gt;&lt;br /&gt;
             &amp;lt;Type&amp;gt;1&amp;lt;/Type&amp;gt;&lt;br /&gt;
             &amp;lt;Attended/&amp;gt;&lt;br /&gt;
             &amp;lt;FirstAttended/&amp;gt;&lt;br /&gt;
             &amp;lt;Nickname/&amp;gt;&lt;br /&gt;
             &amp;lt;Forename&amp;gt;john&amp;lt;/Forename&amp;gt;&lt;br /&gt;
             &amp;lt;Surname&amp;gt;Smith&amp;lt;/Surname&amp;gt;&lt;br /&gt;
             ...&lt;br /&gt;
             &amp;lt;EngagmentLevel&amp;gt;0&amp;lt;/EngagmentLevel&amp;gt;&lt;br /&gt;
             &amp;lt;EngagmentLevelName&amp;gt;Not Set&lt;br /&gt;
             &amp;lt;/EngagmentLevelName&amp;gt;&lt;br /&gt;
         &amp;lt;/participant&amp;gt;&lt;br /&gt;
     &amp;lt;participants&amp;gt;&lt;br /&gt;
 &amp;lt;/sessiongroup&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Note:&#039;&#039;&#039; If the Session Group is bookable, each participant record will also contain a booking object as well.&lt;br /&gt;
&lt;br /&gt;
==Adding participants to a session group==&lt;br /&gt;
===Adding participants to a non-bookable session group===&lt;br /&gt;
You can add a single participant via the following:&lt;br /&gt;
 curl --url &amp;lt;Base URL&amp;gt;/&amp;lt;pid&amp;gt; -u&amp;lt;username&amp;gt;:&amp;lt;password&amp;gt; -H Content-Type:text/xml -X POST&lt;br /&gt;
*&#039;&#039;&#039;pid&#039;&#039;&#039; - The ID of the participant to add&lt;br /&gt;
&lt;br /&gt;
You can also upload a a list of participants to add to the session register via the following URL&lt;br /&gt;
 curl --url &amp;lt;Base URL&amp;gt; -u&amp;lt;username&amp;gt;:&amp;lt;password&amp;gt; -H Content-Type:text/xml -X PUT&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;participants&amp;gt;&lt;br /&gt;
     &amp;lt;participant&amp;gt;101162&amp;lt;/participant&amp;gt;&lt;br /&gt;
     &amp;lt;participant&amp;gt;103124&amp;lt;/participant&amp;gt;&lt;br /&gt;
     &amp;lt;participant&amp;gt;103413&amp;lt;/participant&amp;gt;&lt;br /&gt;
 &amp;lt;/participants&amp;gt;&lt;br /&gt;
&lt;br /&gt;
===Adding participants to a bookable session groups===&lt;br /&gt;
Due to financial information being required for bookable session groups the method of adding participants in slightly different.&lt;br /&gt;
&lt;br /&gt;
 curl --url &amp;lt;Base URL&amp;gt; -u&amp;lt;username&amp;gt;:&amp;lt;password&amp;gt; -H Content-Type:text/xml -X POST&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;participant&amp;gt;&lt;br /&gt;
     &amp;lt;PersonID&amp;gt;100748&amp;lt;/PersonID&amp;gt;&lt;br /&gt;
     &amp;lt;PaymentType&amp;gt;Debit Card&amp;lt;/PaymentType&amp;gt;&lt;br /&gt;
     &amp;lt;PaymentAmount&amp;gt;20&amp;lt;/PaymentAmount&amp;gt;&lt;br /&gt;
     &amp;lt;PaymentFee&amp;gt;2.50&amp;lt;/PaymentFee&amp;gt;&lt;br /&gt;
     &amp;lt;PaymentReference&amp;gt;7002&amp;lt;/PaymentReference&amp;gt;&lt;br /&gt;
     &amp;lt;Confirmed&amp;gt;1&amp;lt;/Confirmed&amp;gt;&lt;br /&gt;
     &amp;lt;Forename&amp;gt;Father&amp;lt;/Forename&amp;gt;&lt;br /&gt;
     &amp;lt;Surname&amp;gt;Test&amp;lt;/Surname&amp;gt;&lt;br /&gt;
     &amp;lt;Address1/&amp;gt;&lt;br /&gt;
     &amp;lt;Address2/&amp;gt;&lt;br /&gt;
     &amp;lt;Town/&amp;gt;&lt;br /&gt;
     &amp;lt;County/&amp;gt;&lt;br /&gt;
     &amp;lt;Postcode/&amp;gt;&lt;br /&gt;
     &amp;lt;Telephone/&amp;gt;&lt;br /&gt;
     &amp;lt;Email&amp;gt;test@test.com&amp;lt;/Email&amp;gt;&lt;br /&gt;
 &amp;lt;/participant&amp;gt;&lt;br /&gt;
&lt;br /&gt;
This will return errors on a fail or the full booking record on a successful submit.&lt;br /&gt;
&lt;br /&gt;
The required fields are all required:&lt;br /&gt;
* PersonID - This is the ID of the participant&lt;br /&gt;
* PaymentType - One of the following value &#039;Cash&#039;, &#039;Cheque&#039;, &#039;Debit Card&#039;, &#039;Credit Card&#039;, &#039;Other&#039;&lt;br /&gt;
* PaymentAmount - This is the amount paid&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;&#039;&#039;Note:&#039;&#039;&#039;&#039;&#039; If the Booking Mode is Session, then you will be required to pass an extra &amp;lt;code&amp;gt;SessionID&amp;lt;/code&amp;gt; element. For example:&lt;br /&gt;
 &amp;lt;participant&amp;gt;&lt;br /&gt;
     &amp;lt;SessionID&amp;gt;776&amp;lt;/SessionID&amp;gt;&lt;br /&gt;
     &amp;lt;PersonID&amp;gt;100748&amp;lt;/PersonID&amp;gt;&lt;br /&gt;
     &amp;lt;PaymentType&amp;gt;Debit Card&amp;lt;/PaymentType&amp;gt;&lt;br /&gt;
     &amp;lt;PaymentAmount&amp;gt;20&amp;lt;/PaymentAmount&amp;gt;&lt;br /&gt;
     &amp;lt;PaymentFee&amp;gt;2.50&amp;lt;/PaymentFee&amp;gt;&lt;br /&gt;
     &amp;lt;PaymentReference&amp;gt;7002&amp;lt;/PaymentReference&amp;gt;&lt;br /&gt;
     &amp;lt;Confirmed&amp;gt;1&amp;lt;/Confirmed&amp;gt;&lt;br /&gt;
     &amp;lt;Forename&amp;gt;Father&amp;lt;/Forename&amp;gt;&lt;br /&gt;
     &amp;lt;Surname&amp;gt;Test&amp;lt;/Surname&amp;gt;&lt;br /&gt;
     &amp;lt;Address1/&amp;gt;&lt;br /&gt;
     &amp;lt;Address2/&amp;gt;&lt;br /&gt;
     &amp;lt;Town/&amp;gt;&lt;br /&gt;
     &amp;lt;County/&amp;gt;&lt;br /&gt;
     &amp;lt;Postcode/&amp;gt;&lt;br /&gt;
     &amp;lt;Telephone/&amp;gt;&lt;br /&gt;
     &amp;lt;Email&amp;gt;test@test.com&amp;lt;/Email&amp;gt;&lt;br /&gt;
 &amp;lt;/participant&amp;gt;&lt;br /&gt;
&#039;&#039; It is prefered that you use the [[Rest - Work - Session Groups - Session Participants|Session Participants]] API &#039;&#039;&lt;br /&gt;
&lt;br /&gt;
==Removing participants from a session group==&lt;br /&gt;
===Removing participants from a non bookable session group===&lt;br /&gt;
You can remove a single participant from a session group via the following:&lt;br /&gt;
 curl --url &amp;lt;Base URL&amp;gt;/&amp;lt;pid&amp;gt; -u&amp;lt;username&amp;gt;:&amp;lt;password&amp;gt; -H Content-Type:text/xml -X DELETE&lt;br /&gt;
*&#039;&#039;&#039;pid&#039;&#039;&#039; - The ID of the participant to add&lt;br /&gt;
&lt;br /&gt;
You can also upload a a list of participants to remove from the session group via the following URL&lt;br /&gt;
 curl --url &amp;lt;Base URL&amp;gt; -u&amp;lt;username&amp;gt;:&amp;lt;password&amp;gt; -H Content-Type:text/xml -X DELETE&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;participants&amp;gt;&lt;br /&gt;
     &amp;lt;participant&amp;gt;101162&amp;lt;/participant&amp;gt;&lt;br /&gt;
     &amp;lt;participant&amp;gt;103124&amp;lt;/participant&amp;gt;&lt;br /&gt;
     &amp;lt;participant&amp;gt;103413&amp;lt;/participant&amp;gt;&lt;br /&gt;
 &amp;lt;/participants&amp;gt;&lt;br /&gt;
&lt;br /&gt;
===Removing participants from a bookable session group===&lt;br /&gt;
You can only remove a single participant&#039;s booking from a session group via the following:&lt;br /&gt;
 curl --url &amp;lt;Base URL&amp;gt;/&amp;lt;pid&amp;gt; -u&amp;lt;username&amp;gt;:&amp;lt;password&amp;gt; -H Content-Type:text/xml -X DELETE&lt;br /&gt;
*&#039;&#039;&#039;pid&#039;&#039;&#039; - The ID of the participant to remove&lt;br /&gt;
&lt;br /&gt;
By default this will flag the participant as cancelled, but will not do anything with the financial side of the booking. To flag a refund was give or a credit note, you should pass the following:&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;refundtype&amp;gt;Refund&amp;lt;/refundtype&amp;gt;&lt;br /&gt;
&lt;br /&gt;
or &lt;br /&gt;
&lt;br /&gt;
 &amp;lt;refundtype&amp;gt;Credit&amp;lt;/refundtype&amp;gt;&lt;br /&gt;
&lt;br /&gt;
This will result in the participants booking being completely being removed from the session group&lt;br /&gt;
&lt;br /&gt;
==Making payments to a booking==&lt;br /&gt;
 curl --url &amp;lt;Base URL&amp;gt;/&amp;lt;id&amp;gt; -u&amp;lt;username&amp;gt;:&amp;lt;password&amp;gt; -H Content-Type:text/xml -X PUT -d &#039;&amp;lt;xml&amp;gt;&#039;&lt;br /&gt;
&lt;br /&gt;
* *id* - This is the participant id&lt;br /&gt;
&lt;br /&gt;
The data for submitting a payment record is currently quite basic. It is our intention to expand on this:&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;payment&amp;gt;&lt;br /&gt;
     &amp;lt;PaymentType&amp;gt;Debit Card&amp;lt;/PaymentType&amp;gt;&lt;br /&gt;
     &amp;lt;PaymentAmount&amp;gt;20&amp;lt;/PaymentAmount&amp;gt;&lt;br /&gt;
 &amp;lt;/payment&amp;gt;&lt;br /&gt;
&lt;br /&gt;
* PaymentType - This must be one of the following values &#039;Cash&#039;, &#039;Cheque&#039;, &#039;Debit Card&#039;, &#039;Credit Card&#039;, &#039;Other&#039;&lt;br /&gt;
* PaymentAmount - This is an amount in pounds.pence&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
==Confirming/Unconfirming a booking==&lt;br /&gt;
 curl --url &amp;lt;Base URL&amp;gt;/&amp;lt;id&amp;gt; -u&amp;lt;username&amp;gt;:&amp;lt;password&amp;gt; -H Content-Type:text/xml -X PUT -d &#039;&amp;lt;xml&amp;gt;&#039;&lt;br /&gt;
&lt;br /&gt;
* *id* - This is the participant id&lt;br /&gt;
&lt;br /&gt;
The data for submitting a payment record is currently quite basic. It is our intention to expand on this:&lt;br /&gt;
 &amp;lt;booking&amp;gt;&lt;br /&gt;
     &amp;lt;Confirmed&amp;gt;1&amp;lt;/Confirmed&amp;gt;&lt;br /&gt;
 &amp;lt;/booking&amp;gt;&#039;&lt;br /&gt;
&lt;br /&gt;
This can also be combined with a payment as such:&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;payment&amp;gt;&lt;br /&gt;
     &amp;lt;PaymentType&amp;gt;Debit Card&amp;lt;/PaymentType&amp;gt;&lt;br /&gt;
     &amp;lt;PaymentAmount&amp;gt;20&amp;lt;/PaymentAmount&amp;gt;&lt;br /&gt;
     &amp;lt;Confirmed&amp;gt;1&amp;lt;/Confirmed&amp;gt;&lt;br /&gt;
 &amp;lt;/payment&amp;gt;&lt;/div&gt;</summary>
		<author><name>Wikiadmin</name></author>
	</entry>
	<entry>
		<id>https://www.substance.net/views-api-docs/index.php?title=Rest_-_Work_-_Session_Groups_-_Participants&amp;diff=290</id>
		<title>Rest - Work - Session Groups - Participants</title>
		<link rel="alternate" type="text/html" href="https://www.substance.net/views-api-docs/index.php?title=Rest_-_Work_-_Session_Groups_-_Participants&amp;diff=290"/>
		<updated>2018-02-01T12:33:28Z</updated>

		<summary type="html">&lt;p&gt;Wikiadmin: /* Making payments to a booking */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;==Purpose==&lt;br /&gt;
&lt;br /&gt;
Used for administering participant registrations on session groups in the Views system.&lt;br /&gt;
&lt;br /&gt;
===Base URL===&lt;br /&gt;
&amp;lt;nowiki&amp;gt;https://app.viewsapp.net/api/restful/work/sessiongroups/&amp;lt;sid&amp;gt;/participants&amp;lt;/nowiki&amp;gt;&lt;br /&gt;
* &#039;&#039;&#039;sid&#039;&#039;&#039; - This is the id of the session group&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Note:&#039;&#039;&#039; If the Session Group has been archived, this API becomes read only.&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
==Getting the list of participants==&lt;br /&gt;
 curl --url &amp;lt;Base URL&amp;gt; -u&amp;lt;username&amp;gt;:&amp;lt;password&amp;gt; -H Content-Type:text/xml&lt;br /&gt;
&lt;br /&gt;
This will return a list of participants that are associated wit the session group, similar to the following:&lt;br /&gt;
 &amp;lt;sessiongroup id=&amp;quot;7&amp;quot;&amp;gt;&lt;br /&gt;
     &amp;lt;participants&amp;gt;&lt;br /&gt;
         &amp;lt;participant id=&amp;quot;123&amp;quot;&amp;gt;&lt;br /&gt;
             &amp;lt;Name&amp;gt;Jane Smith&amp;lt;/Name&amp;gt;&lt;br /&gt;
             &amp;lt;Type&amp;gt;1&amp;lt;/Type&amp;gt;&lt;br /&gt;
             &amp;lt;Attended/&amp;gt;&lt;br /&gt;
             &amp;lt;FirstAttended/&amp;gt;&lt;br /&gt;
             &amp;lt;Nickname/&amp;gt;&lt;br /&gt;
             &amp;lt;Forename&amp;gt;Jane&amp;lt;/Forename&amp;gt;&lt;br /&gt;
             &amp;lt;Surname&amp;gt;Smith&amp;lt;/Surname&amp;gt;&lt;br /&gt;
             ...&lt;br /&gt;
             &amp;lt;EngagmentLevel&amp;gt;0&amp;lt;/EngagmentLevel&amp;gt;&lt;br /&gt;
             &amp;lt;EngagmentLevelName&amp;gt;Not Set&amp;lt;/EngagmentLevelName&amp;gt;&lt;br /&gt;
         &amp;lt;/participant&amp;gt;&lt;br /&gt;
         &amp;lt;participant id=&amp;quot;102&amp;quot;&amp;gt;&lt;br /&gt;
             &amp;lt;Name&amp;gt;John Smith&amp;lt;/Name&amp;gt;&lt;br /&gt;
             &amp;lt;Type&amp;gt;1&amp;lt;/Type&amp;gt;&lt;br /&gt;
             &amp;lt;Attended/&amp;gt;&lt;br /&gt;
             &amp;lt;FirstAttended/&amp;gt;&lt;br /&gt;
             &amp;lt;Nickname/&amp;gt;&lt;br /&gt;
             &amp;lt;Forename&amp;gt;john&amp;lt;/Forename&amp;gt;&lt;br /&gt;
             &amp;lt;Surname&amp;gt;Smith&amp;lt;/Surname&amp;gt;&lt;br /&gt;
             ...&lt;br /&gt;
             &amp;lt;EngagmentLevel&amp;gt;0&amp;lt;/EngagmentLevel&amp;gt;&lt;br /&gt;
             &amp;lt;EngagmentLevelName&amp;gt;Not Set&lt;br /&gt;
             &amp;lt;/EngagmentLevelName&amp;gt;&lt;br /&gt;
         &amp;lt;/participant&amp;gt;&lt;br /&gt;
     &amp;lt;participants&amp;gt;&lt;br /&gt;
 &amp;lt;/sessiongroup&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Note:&#039;&#039;&#039; If the Session Group is bookable, each participant record will also contain a booking object as well.&lt;br /&gt;
&lt;br /&gt;
==Adding participants to a session group==&lt;br /&gt;
===Adding participants to a non-bookable session group===&lt;br /&gt;
You can add a single participant via the following:&lt;br /&gt;
 curl --url &amp;lt;Base URL&amp;gt;/&amp;lt;pid&amp;gt; -u&amp;lt;username&amp;gt;:&amp;lt;password&amp;gt; -H Content-Type:text/xml -X POST&lt;br /&gt;
*&#039;&#039;&#039;pid&#039;&#039;&#039; - The ID of the participant to add&lt;br /&gt;
&lt;br /&gt;
You can also upload a a list of participants to add to the session register via the following URL&lt;br /&gt;
 curl --url &amp;lt;Base URL&amp;gt; -u&amp;lt;username&amp;gt;:&amp;lt;password&amp;gt; -H Content-Type:text/xml -X PUT&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;participants&amp;gt;&lt;br /&gt;
     &amp;lt;participant&amp;gt;101162&amp;lt;/participant&amp;gt;&lt;br /&gt;
     &amp;lt;participant&amp;gt;103124&amp;lt;/participant&amp;gt;&lt;br /&gt;
     &amp;lt;participant&amp;gt;103413&amp;lt;/participant&amp;gt;&lt;br /&gt;
 &amp;lt;/participants&amp;gt;&lt;br /&gt;
&lt;br /&gt;
===Adding participants to a bookable session groups===&lt;br /&gt;
Due to financial information being required for bookable session groups the method of adding participants in slightly different.&lt;br /&gt;
&lt;br /&gt;
 curl --url &amp;lt;Base URL&amp;gt; -u&amp;lt;username&amp;gt;:&amp;lt;password&amp;gt; -H Content-Type:text/xml -X POST&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;participant&amp;gt;&lt;br /&gt;
     &amp;lt;PersonID&amp;gt;100748&amp;lt;/PersonID&amp;gt;&lt;br /&gt;
     &amp;lt;PaymentType&amp;gt;Debit Card&amp;lt;/PaymentType&amp;gt;&lt;br /&gt;
     &amp;lt;PaymentAmount&amp;gt;20&amp;lt;/PaymentAmount&amp;gt;&lt;br /&gt;
     &amp;lt;PaymentFee&amp;gt;2.50&amp;lt;/PaymentFee&amp;gt;&lt;br /&gt;
     &amp;lt;PaymentReference&amp;gt;7002&amp;lt;/PaymentReference&amp;gt;&lt;br /&gt;
     &amp;lt;Forename&amp;gt;Father&amp;lt;/Forename&amp;gt;&lt;br /&gt;
     &amp;lt;Surname&amp;gt;Test&amp;lt;/Surname&amp;gt;&lt;br /&gt;
     &amp;lt;Address1/&amp;gt;&lt;br /&gt;
     &amp;lt;Address2/&amp;gt;&lt;br /&gt;
     &amp;lt;Town/&amp;gt;&lt;br /&gt;
     &amp;lt;County/&amp;gt;&lt;br /&gt;
     &amp;lt;Postcode/&amp;gt;&lt;br /&gt;
     &amp;lt;Telephone/&amp;gt;&lt;br /&gt;
     &amp;lt;Email&amp;gt;test@test.com&amp;lt;/Email&amp;gt;&lt;br /&gt;
 &amp;lt;/participant&amp;gt;&lt;br /&gt;
&lt;br /&gt;
This will return errors on a fail or the full booking record on a successful submit.&lt;br /&gt;
&lt;br /&gt;
The required fields are all required:&lt;br /&gt;
* PersonID - This is the ID of the participant&lt;br /&gt;
* PaymentType - One of the following value &#039;Cash&#039;, &#039;Cheque&#039;, &#039;Debit Card&#039;, &#039;Credit Card&#039;, &#039;Other&#039;&lt;br /&gt;
* PaymentAmount - This is the amount paid&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;&#039;&#039;Note:&#039;&#039;&#039;&#039;&#039; If the Booking Mode is Session, then you will be required to pass an extra &amp;lt;code&amp;gt;SessionID&amp;lt;/code&amp;gt; element. For example:&lt;br /&gt;
 &amp;lt;participant&amp;gt;&lt;br /&gt;
     &amp;lt;SessionID&amp;gt;776&amp;lt;/SessionID&amp;gt;&lt;br /&gt;
     &amp;lt;PersonID&amp;gt;100748&amp;lt;/PersonID&amp;gt;&lt;br /&gt;
     &amp;lt;PaymentType&amp;gt;Debit Card&amp;lt;/PaymentType&amp;gt;&lt;br /&gt;
     &amp;lt;PaymentAmount&amp;gt;20&amp;lt;/PaymentAmount&amp;gt;&lt;br /&gt;
     &amp;lt;PaymentFee&amp;gt;2.50&amp;lt;/PaymentFee&amp;gt;&lt;br /&gt;
     &amp;lt;PaymentReference&amp;gt;7002&amp;lt;/PaymentReference&amp;gt;&lt;br /&gt;
     &amp;lt;Forename&amp;gt;Father&amp;lt;/Forename&amp;gt;&lt;br /&gt;
     &amp;lt;Surname&amp;gt;Test&amp;lt;/Surname&amp;gt;&lt;br /&gt;
     &amp;lt;Address1/&amp;gt;&lt;br /&gt;
     &amp;lt;Address2/&amp;gt;&lt;br /&gt;
     &amp;lt;Town/&amp;gt;&lt;br /&gt;
     &amp;lt;County/&amp;gt;&lt;br /&gt;
     &amp;lt;Postcode/&amp;gt;&lt;br /&gt;
     &amp;lt;Telephone/&amp;gt;&lt;br /&gt;
     &amp;lt;Email&amp;gt;test@test.com&amp;lt;/Email&amp;gt;&lt;br /&gt;
 &amp;lt;/participant&amp;gt;&lt;br /&gt;
&#039;&#039; It is prefered that you use the [[Rest - Work - Session Groups - Session Participants|Session Participants]] API &#039;&#039;&lt;br /&gt;
&lt;br /&gt;
==Removing participants from a session group==&lt;br /&gt;
===Removing participants from a non bookable session group===&lt;br /&gt;
You can remove a single participant from a session group via the following:&lt;br /&gt;
 curl --url &amp;lt;Base URL&amp;gt;/&amp;lt;pid&amp;gt; -u&amp;lt;username&amp;gt;:&amp;lt;password&amp;gt; -H Content-Type:text/xml -X DELETE&lt;br /&gt;
*&#039;&#039;&#039;pid&#039;&#039;&#039; - The ID of the participant to add&lt;br /&gt;
&lt;br /&gt;
You can also upload a a list of participants to remove from the session group via the following URL&lt;br /&gt;
 curl --url &amp;lt;Base URL&amp;gt; -u&amp;lt;username&amp;gt;:&amp;lt;password&amp;gt; -H Content-Type:text/xml -X DELETE&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;participants&amp;gt;&lt;br /&gt;
     &amp;lt;participant&amp;gt;101162&amp;lt;/participant&amp;gt;&lt;br /&gt;
     &amp;lt;participant&amp;gt;103124&amp;lt;/participant&amp;gt;&lt;br /&gt;
     &amp;lt;participant&amp;gt;103413&amp;lt;/participant&amp;gt;&lt;br /&gt;
 &amp;lt;/participants&amp;gt;&lt;br /&gt;
&lt;br /&gt;
===Removing participants from a bookable session group===&lt;br /&gt;
You can only remove a single participant&#039;s booking from a session group via the following:&lt;br /&gt;
 curl --url &amp;lt;Base URL&amp;gt;/&amp;lt;pid&amp;gt; -u&amp;lt;username&amp;gt;:&amp;lt;password&amp;gt; -H Content-Type:text/xml -X DELETE&lt;br /&gt;
*&#039;&#039;&#039;pid&#039;&#039;&#039; - The ID of the participant to remove&lt;br /&gt;
&lt;br /&gt;
By default this will flag the participant as cancelled, but will not do anything with the financial side of the booking. To flag a refund was give or a credit note, you should pass the following:&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;refundtype&amp;gt;Refund&amp;lt;/refundtype&amp;gt;&lt;br /&gt;
&lt;br /&gt;
or &lt;br /&gt;
&lt;br /&gt;
 &amp;lt;refundtype&amp;gt;Credit&amp;lt;/refundtype&amp;gt;&lt;br /&gt;
&lt;br /&gt;
This will result in the participants booking being completely being removed from the session group&lt;br /&gt;
&lt;br /&gt;
==Making payments to a booking==&lt;br /&gt;
 curl --url &amp;lt;Base URL&amp;gt;/&amp;lt;id&amp;gt; -u&amp;lt;username&amp;gt;:&amp;lt;password&amp;gt; -H Content-Type:text/xml -X PUT -d &#039;&amp;lt;xml&amp;gt;&#039;&lt;br /&gt;
&lt;br /&gt;
* *id* - This is the participant id&lt;br /&gt;
&lt;br /&gt;
The data for submitting a payment record is currently quite basic. It is our intention to expand on this:&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;payment&amp;gt;&lt;br /&gt;
     &amp;lt;PaymentType&amp;gt;Debit Card&amp;lt;/PaymentType&amp;gt;&lt;br /&gt;
     &amp;lt;PaymentAmount&amp;gt;20&amp;lt;/PaymentAmount&amp;gt;&lt;br /&gt;
 &amp;lt;/payment&amp;gt;&lt;br /&gt;
&lt;br /&gt;
* PaymentType - This must be one of the following values &#039;Cash&#039;, &#039;Cheque&#039;, &#039;Debit Card&#039;, &#039;Credit Card&#039;, &#039;Other&#039;&lt;br /&gt;
* PaymentAmount - This is an amount in pounds.pence&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
==Confirming/Unconfirming a booking==&lt;br /&gt;
 curl --url &amp;lt;Base URL&amp;gt;/&amp;lt;id&amp;gt; -u&amp;lt;username&amp;gt;:&amp;lt;password&amp;gt; -H Content-Type:text/xml -X PUT -d &#039;&amp;lt;xml&amp;gt;&#039;&lt;br /&gt;
&lt;br /&gt;
* *id* - This is the participant id&lt;br /&gt;
&lt;br /&gt;
The data for submitting a payment record is currently quite basic. It is our intention to expand on this:&lt;br /&gt;
 &amp;lt;booking&amp;gt;&lt;br /&gt;
     &amp;lt;Confirmed&amp;gt;1&amp;lt;/Confirmed&amp;gt;&lt;br /&gt;
 &amp;lt;/booking&amp;gt;&#039;&lt;br /&gt;
&lt;br /&gt;
This can also be combined with a payment as such:&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;payment&amp;gt;&lt;br /&gt;
     &amp;lt;PaymentType&amp;gt;Debit Card&amp;lt;/PaymentType&amp;gt;&lt;br /&gt;
     &amp;lt;PaymentAmount&amp;gt;20&amp;lt;/PaymentAmount&amp;gt;&lt;br /&gt;
     &amp;lt;Confirmed&amp;gt;1&amp;lt;/Confirmed&amp;gt;&lt;br /&gt;
 &amp;lt;/payment&amp;gt;&lt;/div&gt;</summary>
		<author><name>Wikiadmin</name></author>
	</entry>
	<entry>
		<id>https://www.substance.net/views-api-docs/index.php?title=Views_API_Documentation&amp;diff=289</id>
		<title>Views API Documentation</title>
		<link rel="alternate" type="text/html" href="https://www.substance.net/views-api-docs/index.php?title=Views_API_Documentation&amp;diff=289"/>
		<updated>2017-06-21T13:15:33Z</updated>

		<summary type="html">&lt;p&gt;Wikiadmin: /* General Overview */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;== Applying for access to the API ==&lt;br /&gt;
&lt;br /&gt;
The views API&#039;s are a restricted access service. To request access to the API&#039;s you must complete and submit the following form and someone will be in contact shortly.&lt;br /&gt;
&lt;br /&gt;
===[http://goo.gl/forms/Q0PNX5Qo1x Click here to apply]===&lt;br /&gt;
&lt;br /&gt;
==Rest==&lt;br /&gt;
===General Overview===&lt;br /&gt;
All of our REST services are available in both XML and JSON formats, unless otherwise stated. The default format is XML. For the purposes of this documentation we only document the XML method. If you want to interact using json, then you should either make sure you request using &amp;lt;code&amp;gt;Content-Type: application/json&amp;lt;/code&amp;gt;, alternatively you have append the extension &amp;lt;code&amp;gt;.json&amp;lt;/code&amp;gt; to the URI e.g:&lt;br /&gt;
 curl --url &amp;lt;Base URL&amp;gt;/&amp;lt;id&amp;gt; -u&amp;lt;username&amp;gt;:&amp;lt;password&amp;gt; -H Accept:application/json&lt;br /&gt;
&lt;br /&gt;
or&lt;br /&gt;
&lt;br /&gt;
 curl --url &amp;lt;Base URL&amp;gt;/&amp;lt;id&amp;gt;.json -u&amp;lt;username&amp;gt;:&amp;lt;password&amp;gt;&lt;br /&gt;
&lt;br /&gt;
====Using OAuth2====&lt;br /&gt;
&lt;br /&gt;
The use of OAthu2 access_tokens can be used. To do this, you must first request an &amp;lt;code&amp;gt;access_token&amp;lt;/code&amp;gt; from the authentication portal https://authport.viewsapp.net/. This can be done in the following way (using Google Apps Script:&lt;br /&gt;
&lt;br /&gt;
  // Get access_token&lt;br /&gt;
  var response = UrlFetchApp.fetch(&#039;ttps://authportal.viewsapp.net/token.php&#039;, {&lt;br /&gt;
    &#039;method&#039;  : &#039;post&#039;,&lt;br /&gt;
    &#039;payload&#039; : {&#039;grant_type&#039;: &#039;password&#039;, &#039;username&#039; : &#039;my_username&#039;, &#039;password&#039; : &#039;my_password&#039;},&lt;br /&gt;
    &#039;headers&#039; : {&amp;quot;Authorization&amp;quot;: &amp;quot;Basic &amp;quot; + Utilities.base64Encode(&#039;my_username&#039; + &amp;quot;:&amp;quot; + &#039;my_password&#039;)}&lt;br /&gt;
  });&lt;br /&gt;
  var access_token = JSON.parse(response.getContentText()).access_token;&lt;br /&gt;
  &lt;br /&gt;
You would then pass the following fields along side any request:&lt;br /&gt;
&lt;br /&gt;
* client_id=&amp;lt;username&amp;gt;&lt;br /&gt;
* access_token=&amp;lt;access_token&amp;gt;&lt;br /&gt;
&lt;br /&gt;
  &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
====Searching the API&#039;s====&lt;br /&gt;
A lot of the API&#039;s have a search capabilities and share some parameters:&lt;br /&gt;
* q=&amp;lt;string&amp;gt; - This is a free text field for basic searching&lt;br /&gt;
* pageFold=&amp;lt;int&amp;gt; - This the number of results to return in any result set&lt;br /&gt;
* offset=&amp;lt;int&amp;gt; - This is how many records to offset in the result set&lt;br /&gt;
* page=&amp;lt;int&amp;gt; - This can be used in place of offset as is just makes an adjustment to the offset value using the following fomula: &amp;lt;code&amp;gt;offset = (page-1)*pageFold&amp;lt;/code&amp;gt;. &lt;br /&gt;
** &#039;&#039;If used in conjunction with offset, then each page is offset by the specified values also.&#039;&#039;&lt;br /&gt;
** By default this equals 1.&lt;br /&gt;
* archived - By default, only non-archived results are returned. Setting this parameter to 1 result in searching archived records&lt;br /&gt;
&lt;br /&gt;
===Contacts===&lt;br /&gt;
* [[Rest - Contacts - Participants|Particpants]]&lt;br /&gt;
** [[Rest - Contacts - Participants - Sessions|Session Attendance]]&lt;br /&gt;
** [[Rest - Contacts - Participants - Notes|Notes]]&lt;br /&gt;
** [[Rest - Contacts - Participants - Address Book|Address Book]]&lt;br /&gt;
** [[Rest - Contacts - Participants - Questionnaires|Questionnaires]]&lt;br /&gt;
** [[Rest - Contacts - Participants - Volunteering|Volunteering]]&lt;br /&gt;
** [[Rest - Contacts - Participants - Conditions|Conditions]]&lt;br /&gt;
** [[Rest - Contacts - Participants - Restrictions|Restrictions]]&lt;br /&gt;
* [[Rest - Contacts - Staff|Staff]]&lt;br /&gt;
** [[Rest - Contacts - Staff - Sessions|Session Attendance]]&lt;br /&gt;
** [[Rest - Contacts - Staff - Notes|Notes]]&lt;br /&gt;
** [[Rest - Contacts - Staff - Address Book|Address Book]]&lt;br /&gt;
** [[Rest - Contacts - Staff - Questionnaires|Questionnaires]]&lt;br /&gt;
** [[Rest - Contacts - Staff - Volunteering|Volunteering]]&lt;br /&gt;
* [[Rest - Contacts - Volunteers|Volunteers]]&lt;br /&gt;
** [[Rest - Contacts - Volunteers - Sessions|Session Attendance]]&lt;br /&gt;
** [[Rest - Contacts - Volunteers - Notes|Notes]]&lt;br /&gt;
** [[Rest - Contacts - Volunteers - Address Book|Address Book]]&lt;br /&gt;
** [[Rest - Contacts - Volunteers - Questionnaires|Questionnaires]]&lt;br /&gt;
** [[Rest - Contacts - Volunteers - Volunteering|Volunteering]]&lt;br /&gt;
&lt;br /&gt;
===Work===&lt;br /&gt;
* [[Rest - Work - Venues|Venues]]&lt;br /&gt;
* [[Rest - Work - Session Groups|Session Groups]]&lt;br /&gt;
** [[Rest - Work - Session Groups - Participants|Session Group Participants]]&lt;br /&gt;
** [[Rest - Work - Session Groups - Sessions|Sessions]]&lt;br /&gt;
*** [[Rest - Work - Session Groups - Session Notes|Session Notes]]&lt;br /&gt;
*** [[Rest - Work - Session Groups - Session Participants|Session Participants]]&lt;br /&gt;
*** [[Rest - Work - Session Groups - Session Staff|Session Staff]]&lt;br /&gt;
*** [[Rest - Work - Session Groups - Session Questionnaires|Session Questionnaires]]&lt;br /&gt;
* [[Rest - Work - Agency Projects|Agency Projects]]&lt;br /&gt;
** [[Rest - Work - Agency Projects - Session Groups|Agency Project Session Groups]]&lt;br /&gt;
** [[Rest - Work - Agency Projects - Objectives|Objectives]]&lt;br /&gt;
** [[Rest - Work - Agency Projects - Outcomes|Outcomes]]&lt;br /&gt;
&lt;br /&gt;
===Evidence===&lt;br /&gt;
* [[Rest - Evidence - Questionnaires|Questionnaires]]&lt;br /&gt;
** [[Rest - Evidence - Questionnaires - Questions|Questions]]&lt;br /&gt;
** [[Rest - Evidence - Questionnaires - Answers|Answers]]&lt;br /&gt;
&lt;br /&gt;
===Admin===&lt;br /&gt;
* [[Rest - Admin - Value Lists|Value Lists]]&lt;br /&gt;
* [[Rest - Admin - Programmes|Programmes]]&lt;br /&gt;
* [[Rest - Admin - Objectives|Objectives]]&lt;br /&gt;
* [[Rest - Admin - Outcomes|Outcomes]]&lt;br /&gt;
* [[Rest - Admin - ProgrammeFields|Programme Fields]]&lt;br /&gt;
* [[Rest - Admin - Change Log|Change Log]]&lt;br /&gt;
* [[Rest - Admin - Flatpack|Flatpack]]&lt;br /&gt;
&lt;br /&gt;
==SOAP Documention==&lt;br /&gt;
===Contacts===&lt;br /&gt;
* [[SOAP - Contacts - Particpants|Particpants]]&lt;br /&gt;
* [[SOAP - Contacts - Staff|Staff]]&lt;br /&gt;
===Evidence===&lt;br /&gt;
* [[SOAP - Questionaires|Questionaires]]&lt;/div&gt;</summary>
		<author><name>Wikiadmin</name></author>
	</entry>
	<entry>
		<id>https://www.substance.net/views-api-docs/index.php?title=Rest_-_Admin_-_Flatpack&amp;diff=288</id>
		<title>Rest - Admin - Flatpack</title>
		<link rel="alternate" type="text/html" href="https://www.substance.net/views-api-docs/index.php?title=Rest_-_Admin_-_Flatpack&amp;diff=288"/>
		<updated>2016-02-26T13:12:28Z</updated>

		<summary type="html">&lt;p&gt;Wikiadmin: /* Base URL */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;==Purpose==&lt;br /&gt;
To automate and retrieve flatpack archives from views&lt;br /&gt;
&lt;br /&gt;
===Base URL===&lt;br /&gt;
https://app.viewsapp.net/api/restful/admin/flatpack&lt;br /&gt;
&lt;br /&gt;
==Get a list of available blocks==&lt;br /&gt;
&lt;br /&gt;
  curl --url &amp;lt;Base URL&amp;gt;/getblocks(.json|xml) -u&amp;lt;username&amp;gt;:&amp;lt;password&amp;gt; &lt;br /&gt;
&lt;br /&gt;
These are the objects can be packed into a flatpack. By default all available data is stored within the flatpack&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;?xml version=&amp;quot;1.0&amp;quot; encoding=&amp;quot;UTF-8&amp;quot;?&amp;gt;&lt;br /&gt;
 &amp;lt;admin&amp;gt;&lt;br /&gt;
     &amp;lt;flatpackblocks&amp;gt;&lt;br /&gt;
         &amp;lt;flatpackblock id=&amp;quot;0&amp;quot;&amp;gt;reports&amp;lt;/flatpackblock&amp;gt;&lt;br /&gt;
         &amp;lt;flatpackblock id=&amp;quot;1&amp;quot;&amp;gt;agencyProject&amp;lt;/flatpackblock&amp;gt;&lt;br /&gt;
         &amp;lt;flatpackblock id=&amp;quot;2&amp;quot;&amp;gt;caseStudies&amp;lt;/flatpackblock&amp;gt;&lt;br /&gt;
         &amp;lt;flatpackblock id=&amp;quot;3&amp;quot;&amp;gt;finance&amp;lt;/flatpackblock&amp;gt;&lt;br /&gt;
         &amp;lt;flatpackblock id=&amp;quot;4&amp;quot;&amp;gt;group&amp;lt;/flatpackblock&amp;gt;&lt;br /&gt;
         &amp;lt;flatpackblock id=&amp;quot;5&amp;quot;&amp;gt;media&amp;lt;/flatpackblock&amp;gt;&lt;br /&gt;
         &amp;lt;flatpackblock id=&amp;quot;6&amp;quot;&amp;gt;note&amp;lt;/flatpackblock&amp;gt;&lt;br /&gt;
         &amp;lt;flatpackblock id=&amp;quot;7&amp;quot;&amp;gt;objectives&amp;lt;/flatpackblock&amp;gt;&lt;br /&gt;
         &amp;lt;flatpackblock id=&amp;quot;8&amp;quot;&amp;gt;outcomes&amp;lt;/flatpackblock&amp;gt;&lt;br /&gt;
         &amp;lt;flatpackblock id=&amp;quot;9&amp;quot;&amp;gt;personCondition&amp;lt;/flatpackblock&amp;gt;&lt;br /&gt;
         &amp;lt;flatpackblock id=&amp;quot;10&amp;quot;&amp;gt;personContact&amp;lt;/flatpackblock&amp;gt;&lt;br /&gt;
         &amp;lt;flatpackblock id=&amp;quot;11&amp;quot;&amp;gt;personQualifications&amp;lt;/flatpackblock&amp;gt;&lt;br /&gt;
         &amp;lt;flatpackblock id=&amp;quot;12&amp;quot;&amp;gt;personRestriction&amp;lt;/flatpackblock&amp;gt;&lt;br /&gt;
         &amp;lt;flatpackblock id=&amp;quot;13&amp;quot;&amp;gt;questionnaireAnswers&amp;lt;/flatpackblock&amp;gt;&lt;br /&gt;
         &amp;lt;flatpackblock id=&amp;quot;14&amp;quot;&amp;gt;questionnaire&amp;lt;/flatpackblock&amp;gt;&lt;br /&gt;
         &amp;lt;flatpackblock id=&amp;quot;15&amp;quot;&amp;gt;questionsData&amp;lt;/flatpackblock&amp;gt;&lt;br /&gt;
         &amp;lt;flatpackblock id=&amp;quot;16&amp;quot;&amp;gt;reportsPublished&amp;lt;/flatpackblock&amp;gt;&lt;br /&gt;
         &amp;lt;flatpackblock id=&amp;quot;17&amp;quot;&amp;gt;session&amp;lt;/flatpackblock&amp;gt;&lt;br /&gt;
         &amp;lt;flatpackblock id=&amp;quot;18&amp;quot;&amp;gt;sessionGroup&amp;lt;/flatpackblock&amp;gt;&lt;br /&gt;
         &amp;lt;flatpackblock id=&amp;quot;19&amp;quot;&amp;gt;sessionStaffAttendance&amp;lt;/flatpackblock&amp;gt;&lt;br /&gt;
         &amp;lt;flatpackblock id=&amp;quot;20&amp;quot;&amp;gt;stock&amp;lt;/flatpackblock&amp;gt;&lt;br /&gt;
         &amp;lt;flatpackblock id=&amp;quot;21&amp;quot;&amp;gt;stockCategory&amp;lt;/flatpackblock&amp;gt; &lt;br /&gt;
         &amp;lt;flatpackblock id=&amp;quot;22&amp;quot;&amp;gt;stockLoan&amp;lt;/flatpackblock&amp;gt;&lt;br /&gt;
         &amp;lt;flatpackblock id=&amp;quot;23&amp;quot;&amp;gt;venue&amp;lt;/flatpackblock&amp;gt;&lt;br /&gt;
         &amp;lt;flatpackblock id=&amp;quot;24&amp;quot;&amp;gt;personTypePerson&amp;lt;/flatpackblock&amp;gt;&lt;br /&gt;
         &amp;lt;flatpackblock id=&amp;quot;25&amp;quot;&amp;gt;personTypeStaff&amp;lt;/flatpackblock&amp;gt;&lt;br /&gt;
         &amp;lt;flatpackblock id=&amp;quot;26&amp;quot;&amp;gt;personTypeVolunteer&amp;lt;/flatpackblock&amp;gt;&lt;br /&gt;
         &amp;lt;flatpackblock id=&amp;quot;27&amp;quot;&amp;gt;personTypeProfessional&amp;lt;/flatpackblock&amp;gt;&lt;br /&gt;
         &amp;lt;flatpackblock id=&amp;quot;28&amp;quot;&amp;gt;sessionAttendance&amp;lt;/flatpackblock&amp;gt;&lt;br /&gt;
     &amp;lt;/flatpackblocks&amp;gt;&lt;br /&gt;
 &amp;lt;/admin&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;&#039;&#039;Note 1:&#039;&#039;&#039; The list above may vary from agency to agency&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;&#039;&#039;Note 2:&#039;&#039;&#039; The id&#039;s in the resulting XML data are irrelevant and can be ignored&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
==Generate a Flatpack==&lt;br /&gt;
&lt;br /&gt;
 curl --url &amp;lt;Base URL&amp;gt;/&amp;lt;file&amp;gt; -u&amp;lt;username&amp;gt;:&amp;lt;password&amp;gt; -XPOST [--data &amp;quot;&amp;lt;xml&amp;gt;&amp;quot;]&lt;br /&gt;
&lt;br /&gt;
This will generate a new flatpack, if one does not already exist. If not data is posted to the API, the the flatpack is generated with all the available blocks.&lt;br /&gt;
To restrict the data within the flatpack archive, you should pass a list of blocks you want:&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;flatpackblocks&amp;gt;&lt;br /&gt;
     &amp;lt;flatpackblock&amp;gt;personTypePerson&amp;lt;/flatpackblock&amp;gt;&lt;br /&gt;
     &amp;lt;flatpackblock&amp;gt;personTypeStaff&amp;lt;/flatpackblock&amp;gt;&lt;br /&gt;
     &amp;lt;flatpackblock&amp;gt;personTypeVolunteer&amp;lt;/flatpackblock&amp;gt;&lt;br /&gt;
     &amp;lt;flatpackblock&amp;gt;personTypeProfessional&amp;lt;/flatpackblock&amp;gt;&lt;br /&gt;
     &amp;lt;flatpackblock&amp;gt;sessionAttendance&amp;lt;/flatpackblock&amp;gt;&lt;br /&gt;
 &amp;lt;/flatpackblocks&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
==Listing available Flatpacks==&lt;br /&gt;
&lt;br /&gt;
 curl --url &amp;lt;Base URL&amp;gt;/list(.json|xml) -u&amp;lt;username&amp;gt;:&amp;lt;password&amp;gt; &lt;br /&gt;
&lt;br /&gt;
 &amp;lt;?xml version=&amp;quot;1.0&amp;quot; encoding=&amp;quot;UTF-8&amp;quot;?&amp;gt;&lt;br /&gt;
 &amp;lt;admin&amp;gt;&lt;br /&gt;
     &amp;lt;flatpacks&amp;gt;&lt;br /&gt;
         &amp;lt;flatpack id=&amp;quot;0&amp;quot;&amp;gt;&lt;br /&gt;
             &amp;lt;file&amp;gt;flatpack20160113.zip&amp;lt;/file&amp;gt;&lt;br /&gt;
             &amp;lt;date&amp;gt;13/01/2016&amp;lt;/date&amp;gt;&lt;br /&gt;
             &amp;lt;size&amp;gt;1100021&amp;lt;/size&amp;gt;&lt;br /&gt;
             &amp;lt;sha1sum&amp;gt;2b77ba54249c7a25f4a05be2b9a7c28a5fe9071f&amp;lt;/sha1sum&amp;gt;&lt;br /&gt;
         &amp;lt;/flatpack&amp;gt;&lt;br /&gt;
         &amp;lt;flatpack id=&amp;quot;1&amp;quot;&amp;gt;&lt;br /&gt;
             &amp;lt;file&amp;gt;flatpack20160112.zip&amp;lt;/file&amp;gt;&lt;br /&gt;
             &amp;lt;date&amp;gt;2016-01-12&amp;lt;/date&amp;gt;&lt;br /&gt;
             &amp;lt;size&amp;gt;1099668&amp;lt;/size&amp;gt;&lt;br /&gt;
             &amp;lt;sha1sum&amp;gt;68eac14b20480b9e77f599b8685307153e3f43db&amp;lt;/sha1sum&amp;gt;&lt;br /&gt;
         &amp;lt;/flatpack&amp;gt;&lt;br /&gt;
     &amp;lt;/flatpacks&amp;gt;&lt;br /&gt;
 &amp;lt;/admin&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;&#039;&#039;Note:&#039;&#039;&#039; The id&#039;s in the resulting XML data are irrelevant and can be ignored&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
==Downloading a Flatpack==&lt;br /&gt;
&lt;br /&gt;
 curl --url &amp;lt;Base URL&amp;gt;/&amp;lt;file&amp;gt; -u&amp;lt;username&amp;gt;:&amp;lt;password&amp;gt; &lt;br /&gt;
&lt;br /&gt;
This will download a the flatpack zip file requested.&lt;br /&gt;
&lt;br /&gt;
==Deleting Flatpacks / House keeping==&lt;br /&gt;
&lt;br /&gt;
This is currently not implemented. Please contact us if you need this&lt;/div&gt;</summary>
		<author><name>Wikiadmin</name></author>
	</entry>
	<entry>
		<id>https://www.substance.net/views-api-docs/index.php?title=Views_API_Documentation&amp;diff=287</id>
		<title>Views API Documentation</title>
		<link rel="alternate" type="text/html" href="https://www.substance.net/views-api-docs/index.php?title=Views_API_Documentation&amp;diff=287"/>
		<updated>2016-02-26T13:12:06Z</updated>

		<summary type="html">&lt;p&gt;Wikiadmin: /* Admin */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;== Applying for access to the API ==&lt;br /&gt;
&lt;br /&gt;
The views API&#039;s are a restricted access service. To request access to the API&#039;s you must complete and submit the following form and someone will be in contact shortly.&lt;br /&gt;
&lt;br /&gt;
===[http://goo.gl/forms/Q0PNX5Qo1x Click here to apply]===&lt;br /&gt;
&lt;br /&gt;
==Rest==&lt;br /&gt;
===General Overview===&lt;br /&gt;
All of our REST services are available in both XML and JSON formats, unless otherwise stated. The default format is XML. For the purposes of this documentation we only document the XML method. If you want to interact using json, then you should either make sure you request using &amp;lt;code&amp;gt;Content-Type: application/json&amp;lt;/code&amp;gt;, alternatively you have append the extension &amp;lt;code&amp;gt;.json&amp;lt;/code&amp;gt; to the URI e.g:&lt;br /&gt;
 curl --url &amp;lt;Base URL&amp;gt;/&amp;lt;id&amp;gt; -u&amp;lt;username&amp;gt;:&amp;lt;password&amp;gt; -H Accept:application/json&lt;br /&gt;
&lt;br /&gt;
or&lt;br /&gt;
&lt;br /&gt;
 curl --url &amp;lt;Base URL&amp;gt;/&amp;lt;id&amp;gt;.json -u&amp;lt;username&amp;gt;:&amp;lt;password&amp;gt;&lt;br /&gt;
&lt;br /&gt;
====Searching the API&#039;s====&lt;br /&gt;
A lot of the API&#039;s have a search capabilities and share some parameters:&lt;br /&gt;
* q=&amp;lt;string&amp;gt; - This is a free text field for basic searching&lt;br /&gt;
* pageFold=&amp;lt;int&amp;gt; - This the number of results to return in any result set&lt;br /&gt;
* offset=&amp;lt;int&amp;gt; - This is how many records to offset in the result set&lt;br /&gt;
* page=&amp;lt;int&amp;gt; - This can be used in place of offset as is just makes an adjustment to the offset value using the following fomula: &amp;lt;code&amp;gt;offset = (page-1)*pageFold&amp;lt;/code&amp;gt;. &lt;br /&gt;
** &#039;&#039;If used in conjunction with offset, then each page is offset by the specified values also.&#039;&#039;&lt;br /&gt;
** By default this equals 1.&lt;br /&gt;
* archived - By default, only non-archived results are returned. Setting this parameter to 1 result in searching archived records&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
===Contacts===&lt;br /&gt;
* [[Rest - Contacts - Participants|Particpants]]&lt;br /&gt;
** [[Rest - Contacts - Participants - Sessions|Session Attendance]]&lt;br /&gt;
** [[Rest - Contacts - Participants - Notes|Notes]]&lt;br /&gt;
** [[Rest - Contacts - Participants - Address Book|Address Book]]&lt;br /&gt;
** [[Rest - Contacts - Participants - Questionnaires|Questionnaires]]&lt;br /&gt;
** [[Rest - Contacts - Participants - Volunteering|Volunteering]]&lt;br /&gt;
** [[Rest - Contacts - Participants - Conditions|Conditions]]&lt;br /&gt;
** [[Rest - Contacts - Participants - Restrictions|Restrictions]]&lt;br /&gt;
* [[Rest - Contacts - Staff|Staff]]&lt;br /&gt;
** [[Rest - Contacts - Staff - Sessions|Session Attendance]]&lt;br /&gt;
** [[Rest - Contacts - Staff - Notes|Notes]]&lt;br /&gt;
** [[Rest - Contacts - Staff - Address Book|Address Book]]&lt;br /&gt;
** [[Rest - Contacts - Staff - Questionnaires|Questionnaires]]&lt;br /&gt;
** [[Rest - Contacts - Staff - Volunteering|Volunteering]]&lt;br /&gt;
* [[Rest - Contacts - Volunteers|Volunteers]]&lt;br /&gt;
** [[Rest - Contacts - Volunteers - Sessions|Session Attendance]]&lt;br /&gt;
** [[Rest - Contacts - Volunteers - Notes|Notes]]&lt;br /&gt;
** [[Rest - Contacts - Volunteers - Address Book|Address Book]]&lt;br /&gt;
** [[Rest - Contacts - Volunteers - Questionnaires|Questionnaires]]&lt;br /&gt;
** [[Rest - Contacts - Volunteers - Volunteering|Volunteering]]&lt;br /&gt;
&lt;br /&gt;
===Work===&lt;br /&gt;
* [[Rest - Work - Venues|Venues]]&lt;br /&gt;
* [[Rest - Work - Session Groups|Session Groups]]&lt;br /&gt;
** [[Rest - Work - Session Groups - Participants|Session Group Participants]]&lt;br /&gt;
** [[Rest - Work - Session Groups - Sessions|Sessions]]&lt;br /&gt;
*** [[Rest - Work - Session Groups - Session Notes|Session Notes]]&lt;br /&gt;
*** [[Rest - Work - Session Groups - Session Participants|Session Participants]]&lt;br /&gt;
*** [[Rest - Work - Session Groups - Session Staff|Session Staff]]&lt;br /&gt;
*** [[Rest - Work - Session Groups - Session Questionnaires|Session Questionnaires]]&lt;br /&gt;
* [[Rest - Work - Agency Projects|Agency Projects]]&lt;br /&gt;
** [[Rest - Work - Agency Projects - Session Groups|Agency Project Session Groups]]&lt;br /&gt;
** [[Rest - Work - Agency Projects - Objectives|Objectives]]&lt;br /&gt;
** [[Rest - Work - Agency Projects - Outcomes|Outcomes]]&lt;br /&gt;
&lt;br /&gt;
===Evidence===&lt;br /&gt;
* [[Rest - Evidence - Questionnaires|Questionnaires]]&lt;br /&gt;
** [[Rest - Evidence - Questionnaires - Questions|Questions]]&lt;br /&gt;
** [[Rest - Evidence - Questionnaires - Answers|Answers]]&lt;br /&gt;
&lt;br /&gt;
===Admin===&lt;br /&gt;
* [[Rest - Admin - Value Lists|Value Lists]]&lt;br /&gt;
* [[Rest - Admin - Programmes|Programmes]]&lt;br /&gt;
* [[Rest - Admin - Objectives|Objectives]]&lt;br /&gt;
* [[Rest - Admin - Outcomes|Outcomes]]&lt;br /&gt;
* [[Rest - Admin - ProgrammeFields|Programme Fields]]&lt;br /&gt;
* [[Rest - Admin - Change Log|Change Log]]&lt;br /&gt;
* [[Rest - Admin - Flatpack|Flatpack]]&lt;br /&gt;
&lt;br /&gt;
==SOAP Documention==&lt;br /&gt;
===Contacts===&lt;br /&gt;
* [[SOAP - Contacts - Particpants|Particpants]]&lt;br /&gt;
* [[SOAP - Contacts - Staff|Staff]]&lt;br /&gt;
===Evidence===&lt;br /&gt;
* [[SOAP - Questionaires|Questionaires]]&lt;/div&gt;</summary>
		<author><name>Wikiadmin</name></author>
	</entry>
	<entry>
		<id>https://www.substance.net/views-api-docs/index.php?title=Rest_-_Admin_-_Change_Log&amp;diff=286</id>
		<title>Rest - Admin - Change Log</title>
		<link rel="alternate" type="text/html" href="https://www.substance.net/views-api-docs/index.php?title=Rest_-_Admin_-_Change_Log&amp;diff=286"/>
		<updated>2016-02-26T13:11:01Z</updated>

		<summary type="html">&lt;p&gt;Wikiadmin: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;==Purpose==&lt;br /&gt;
&lt;br /&gt;
The intention of this API is to allow a system to keep in sync with the views server or trigger custom actions on data changes.&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Please note:&#039;&#039;&#039; &#039;&#039;This API is still in development. While this API is stable and &#039;&#039;&#039;all&#039;&#039;&#039; the methods documented on this page will be improved rather than than changed, it will be with checking back with this documentation prior to any new interactions with this API.&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
===Base URL===&lt;br /&gt;
https://app.viewsapp.net/api/restful/admin/changelog&lt;br /&gt;
&lt;br /&gt;
==Basic Usage==&lt;br /&gt;
&lt;br /&gt;
 curl --url &amp;lt;Base URL&amp;gt; -u&amp;lt;username&amp;gt;:&amp;lt;password&amp;gt; -H Content-Type:text/xml&lt;br /&gt;
&lt;br /&gt;
This will return something similar to:&lt;br /&gt;
 &amp;lt;?xml version=&amp;quot;1.0&amp;quot; encoding=&amp;quot;utf-8&amp;quot;?&amp;gt;&lt;br /&gt;
 &amp;lt;changelog&amp;gt;&lt;br /&gt;
    &amp;lt;log id=&amp;quot;8487&amp;quot;&amp;gt;&lt;br /&gt;
        &amp;lt;object&amp;gt;Agency&amp;lt;/object&amp;gt;&lt;br /&gt;
        &amp;lt;objectId&amp;gt;354&amp;lt;/objectId&amp;gt;&lt;br /&gt;
        &amp;lt;action&amp;gt;edit&amp;lt;/action&amp;gt;&lt;br /&gt;
        &amp;lt;timestamp&amp;gt;2014-02-07T10:42:40&amp;lt;/timestamp&amp;gt;&lt;br /&gt;
        &amp;lt;username&amp;gt;nowhere.man&amp;lt;/username&amp;gt;&lt;br /&gt;
    &amp;lt;/log&amp;gt;&lt;br /&gt;
    &amp;lt;log id=&amp;quot;8488&amp;quot;&amp;gt;&lt;br /&gt;
        &amp;lt;object&amp;gt;PersonContact&amp;lt;/object&amp;gt;&lt;br /&gt;
        &amp;lt;objectId&amp;gt;1&amp;lt;/objectId&amp;gt;&lt;br /&gt;
        &amp;lt;action&amp;gt;update&amp;lt;/action&amp;gt;&lt;br /&gt;
        &amp;lt;timestamp&amp;gt;2014-02-07T10:43:13&amp;lt;/timestamp&amp;gt;&lt;br /&gt;
        &amp;lt;username&amp;gt;nowhere.man&amp;lt;/username&amp;gt;&lt;br /&gt;
    &amp;lt;/log&amp;gt;&lt;br /&gt;
    &amp;lt;log id=&amp;quot;8489&amp;quot;&amp;gt;&lt;br /&gt;
        &amp;lt;object&amp;gt;Booking&amp;lt;/object&amp;gt;&lt;br /&gt;
        &amp;lt;objectId&amp;gt;245&amp;lt;/objectId&amp;gt;&lt;br /&gt;
        &amp;lt;action&amp;gt;update&amp;lt;/action&amp;gt;&lt;br /&gt;
        &amp;lt;timestamp&amp;gt;2014-02-07T10:43:26&amp;lt;/timestamp&amp;gt;&lt;br /&gt;
        &amp;lt;username&amp;gt;nowhere.man&amp;lt;/username&amp;gt;&lt;br /&gt;
    &amp;lt;/log&amp;gt;&lt;br /&gt;
    &amp;lt;log id=&amp;quot;8490&amp;quot;&amp;gt;&lt;br /&gt;
        &amp;lt;object&amp;gt;SessionGroup&amp;lt;/object&amp;gt;&lt;br /&gt;
        &amp;lt;objectId&amp;gt;8&amp;lt;/objectId&amp;gt;&lt;br /&gt;
        &amp;lt;action&amp;gt;insert&amp;lt;/action&amp;gt;&lt;br /&gt;
        &amp;lt;timestamp&amp;gt;2014-02-07T10:43:29&amp;lt;/timestamp&amp;gt;&lt;br /&gt;
        &amp;lt;username&amp;gt;nowhere.man&amp;lt;/username&amp;gt;&lt;br /&gt;
    &amp;lt;/log&amp;gt;&lt;br /&gt;
    &amp;lt;log id=&amp;quot;8492&amp;quot;&amp;gt;&lt;br /&gt;
        &amp;lt;object&amp;gt;Participant&amp;lt;/object&amp;gt;&lt;br /&gt;
        &amp;lt;objectId&amp;gt;25489&amp;lt;/objectId&amp;gt;&lt;br /&gt;
        &amp;lt;action&amp;gt;update&amp;lt;/action&amp;gt;&lt;br /&gt;
        &amp;lt;timestamp&amp;gt;2014-02-07T10:43:29&amp;lt;/timestamp&amp;gt;&lt;br /&gt;
        &amp;lt;username&amp;gt;al.mccaig.transit&amp;lt;/username&amp;gt;&lt;br /&gt;
        &amp;lt;relates&amp;gt;&lt;br /&gt;
            &amp;lt;Session&amp;gt;606&amp;lt;/Session&amp;gt;&lt;br /&gt;
            &amp;lt;Person&amp;gt;1&amp;lt;/Person&amp;gt;&lt;br /&gt;
        &amp;lt;/relates&amp;gt;&lt;br /&gt;
    &amp;lt;/log&amp;gt;&lt;br /&gt;
 &amp;lt;/changelog&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
==Object Specific Calls==&lt;br /&gt;
If you are only interested to changes to a specific object, you can append the object name to the call:&lt;br /&gt;
 curl --url &amp;lt;Base URL&amp;gt;/&amp;lt;objectType&amp;gt; -u&amp;lt;username&amp;gt;:&amp;lt;password&amp;gt; -H Content-Type:text/xml&lt;br /&gt;
&lt;br /&gt;
* &#039;&#039;objectType&#039;&#039; - One for the following values&lt;br /&gt;
** AgencyProject&lt;br /&gt;
** Note&lt;br /&gt;
** Participant&lt;br /&gt;
** Person&lt;br /&gt;
** PersonContact&lt;br /&gt;
** Questionnaire&lt;br /&gt;
** Session&lt;br /&gt;
** SessionGroup&lt;br /&gt;
** ValueList&lt;br /&gt;
&lt;br /&gt;
e.g. for sessions&lt;br /&gt;
 curl --url &amp;lt;Base URL&amp;gt;/session -u&amp;lt;username&amp;gt;:&amp;lt;password&amp;gt; -H Content-Type:text/xml&lt;br /&gt;
&lt;br /&gt;
==Restricting the changes by date==&lt;br /&gt;
By default the API will return up to the last 4000 changes logged. However, you can fetch specific date ranges using the &amp;lt;code&amp;gt;timestamp&amp;lt;/code&amp;gt;, you can also use the &#039;&#039;-from&#039;&#039; and &#039;&#039;-to&#039;&#039; modifiers to specify a date range:&lt;br /&gt;
 curl --url &amp;lt;Base URL&amp;gt;/&amp;lt;objectType&amp;gt;?timestamp-from=&amp;lt;date&amp;gt;&amp;amp;timestamp-to=&amp;lt;date&amp;gt; -u&amp;lt;username&amp;gt;:&amp;lt;password&amp;gt; -H Content-Type:text/xml&lt;br /&gt;
&lt;br /&gt;
==An example use==&lt;br /&gt;
&lt;br /&gt;
This is an example script to check for changes of 3 objectTypes that occurred during the previous day and will build a list of object URL&#039;s for objects ready for fetching.&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;php&amp;quot; &amp;gt;&lt;br /&gt;
&amp;lt;?php&lt;br /&gt;
print &amp;quot;Begin...\n&amp;quot;;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
// The API credentials&lt;br /&gt;
$username = &#039;YOUR USERNAME&#039;;&lt;br /&gt;
$password = &#039;YOUR PASSWORD&#039;;&lt;br /&gt;
&lt;br /&gt;
// Uncomment the the relevant API URL&lt;br /&gt;
//$baseURL = &#039;http://dev.views.coop/api/restful/&#039;;  // Development Server&lt;br /&gt;
$baseURL = &#039;http://testing.views.coop/api/restful/&#039;; // Live Server&lt;br /&gt;
//$baseURL = &#039;https://app.views.coop/api/restful/&#039;; // Live Server&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
if (!ini_get(&#039;display_errors&#039;)) {&lt;br /&gt;
    ini_set(&#039;display_errors&#039;, true);&lt;br /&gt;
}&lt;br /&gt;
&lt;br /&gt;
function curl_download($Url, $params, $username, $password, $headers=&#039;&#039;){&lt;br /&gt;
 &lt;br /&gt;
    // is cURL installed yet?&lt;br /&gt;
    if (!function_exists(&#039;curl_init&#039;)){&lt;br /&gt;
        die(&#039;Sorry cURL is not installed!&#039;);&lt;br /&gt;
    }&lt;br /&gt;
 &lt;br /&gt;
    // OK cool - then let&#039;s create a new cURL resource handle&lt;br /&gt;
    $ch = curl_init();&lt;br /&gt;
 &lt;br /&gt;
    // Now set some options (most are optional)&lt;br /&gt;
 &lt;br /&gt;
    $Url.=&#039;?&#039;.http_build_query($params);&lt;br /&gt;
    &lt;br /&gt;
    // Set URL to download&lt;br /&gt;
    curl_setopt($ch, CURLOPT_URL, $Url);&lt;br /&gt;
    &lt;br /&gt;
    // Set username and password&lt;br /&gt;
    curl_setopt($ch, CURLOPT_USERPWD, &amp;quot;$username:$password&amp;quot;);&lt;br /&gt;
    curl_setopt($ch, CURLOPT_HTTPAUTH, CURLAUTH_BASIC);&lt;br /&gt;
    &lt;br /&gt;
    // See if we pass any headers&lt;br /&gt;
    if (is_array($headers) &amp;amp;&amp;amp; sizeof($headers)) {&lt;br /&gt;
        curl_setopt($ch, CURLOPT_HTTPHEADER, $headers);&lt;br /&gt;
    }&lt;br /&gt;
&lt;br /&gt;
    // User agent&lt;br /&gt;
    curl_setopt($ch, CURLOPT_USERAGENT, &amp;quot;APIChangeLogProcessor/1.0&amp;quot;);&lt;br /&gt;
 &lt;br /&gt;
    // Include header in result? (0 = yes, 1 = no)&lt;br /&gt;
    curl_setopt($ch, CURLOPT_HEADER, 0);&lt;br /&gt;
 &lt;br /&gt;
    // Should cURL return or print out the data? (true = return, false = print)&lt;br /&gt;
    curl_setopt($ch, CURLOPT_RETURNTRANSFER, true);&lt;br /&gt;
 &lt;br /&gt;
    // Timeout in seconds&lt;br /&gt;
    curl_setopt($ch, CURLOPT_TIMEOUT, 30);&lt;br /&gt;
 &lt;br /&gt;
    // Download the given URL, and return output&lt;br /&gt;
    $output = curl_exec($ch);&lt;br /&gt;
 &lt;br /&gt;
    // Close the cURL resource, and free system resources&lt;br /&gt;
    curl_close($ch);&lt;br /&gt;
 &lt;br /&gt;
    return $output;&lt;br /&gt;
}&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
$baseURL .= &#039;/admin/changelog&#039;;&lt;br /&gt;
&lt;br /&gt;
// Use the following to define the desired file format&lt;br /&gt;
// Please Note: The json format has not been fully tested with these scripts&lt;br /&gt;
//$contentType = &#039;text/xml&#039;;&lt;br /&gt;
$contentType = &#039;application/json&#039;;&lt;br /&gt;
//$extension = &#039;xml&#039;;&lt;br /&gt;
$extension = &#039;json&#039;;&lt;br /&gt;
&lt;br /&gt;
// I would not recomend fetching more than a days worth of changelogs. If you want to fecth more, then loop through the days individually&lt;br /&gt;
$params[&#039;timestamp-from&#039;] = date(&#039;Y-m-d&#039;, strtotime(&#039;yesterday&#039;)); // Could be a param and set to an exact time it last ran&lt;br /&gt;
&lt;br /&gt;
// You can use the updated field for person records&lt;br /&gt;
$objects = array(&#039;agencyproject&#039;, &#039;participant&#039;,&#039;session&#039;,&#039;sessionGroup&#039;);&lt;br /&gt;
&lt;br /&gt;
$recordsToFetch = array();&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
// Loop through each of the change log objects&lt;br /&gt;
foreach( $objects as $thisObject ) {&lt;br /&gt;
&lt;br /&gt;
    $response = json_decode(curl_download($baseURL.&#039;/&#039;.$thisObject, $params, $username, $password, array(&amp;quot;Accept: {$contentType}&amp;quot;)), true);;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
    while( ($thisRecord = array_shift($response) ) ) {&lt;br /&gt;
        &lt;br /&gt;
        if (strtolower($thisRecord[&#039;object&#039;]) == &#039;participant&#039;) {&lt;br /&gt;
            if (!$thisRecord[&#039;relates&#039;][&#039;Session&#039;]) {&lt;br /&gt;
                // There are a few cases where an extra log line is printed.&lt;br /&gt;
                // We just need to skip these&lt;br /&gt;
                continue;&lt;br /&gt;
            }&lt;br /&gt;
            &lt;br /&gt;
            $recordsToFetch[] = &amp;quot;/sessions/{$thisRecord[&#039;relates&#039;][&#039;Session&#039;]}/participants&amp;quot;;&lt;br /&gt;
&lt;br /&gt;
        } else {&lt;br /&gt;
            $recordsToFetch[] = &amp;quot;/&amp;quot;.strtolower($thisRecord[&#039;object&#039;]).&amp;quot;s/{$thisRecord[&#039;objectId&#039;]}&amp;quot;;&lt;br /&gt;
        }&lt;br /&gt;
    }&lt;br /&gt;
    &lt;br /&gt;
    $thisRecord = $response = null; // Clean up to keep memory in control&lt;br /&gt;
    &lt;br /&gt;
}&lt;br /&gt;
sort($recordsToFetch);&lt;br /&gt;
&lt;br /&gt;
$recordsToFetch = array_unique($recordsToFetch); // Strip duplicates&lt;br /&gt;
&lt;br /&gt;
/**&lt;br /&gt;
 * $recordsToFetch should now contain a list of all the records you need to refresh&lt;br /&gt;
 * Which while testing on your data, a day and a half is returning &amp;lt; 4000 records to fetch&lt;br /&gt;
 */&lt;br /&gt;
print_r($recordsToFetch);&lt;br /&gt;
?&amp;gt;&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;/div&gt;</summary>
		<author><name>Wikiadmin</name></author>
	</entry>
	<entry>
		<id>https://www.substance.net/views-api-docs/index.php?title=Rest_-_Admin_-_ProgrammeFields&amp;diff=285</id>
		<title>Rest - Admin - ProgrammeFields</title>
		<link rel="alternate" type="text/html" href="https://www.substance.net/views-api-docs/index.php?title=Rest_-_Admin_-_ProgrammeFields&amp;diff=285"/>
		<updated>2016-02-26T13:10:44Z</updated>

		<summary type="html">&lt;p&gt;Wikiadmin: /* Base URL */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;==Purpose==&lt;br /&gt;
&lt;br /&gt;
When interacting with Views accounts, it is sometimes necessary to identify a field that is derieved from a program, and implemented in all agencies within that program. For example a Disability field. This can be achieved via this API&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
===Base URL===&lt;br /&gt;
https://app.viewsapp.net/api/restful/admin/programmefields&lt;br /&gt;
&lt;br /&gt;
==Identify a programme field==&lt;br /&gt;
&lt;br /&gt;
 curl --url &amp;lt;Base URL&amp;gt;/&amp;lt;structure&amp;gt;/&amp;lt;fieldname&amp;gt; -u&amp;lt;username&amp;gt;:&amp;lt;password&amp;gt; -H Content-Type:text/xml -X POST -d &amp;quot;&amp;lt;xml&amp;gt;&amp;quot;&lt;br /&gt;
&lt;br /&gt;
This will return a list of programme fields for the given field, for the programmes that the agency is associated with in the following format:&lt;br /&gt;
 &amp;lt;?xml version=&amp;quot;1.0&amp;quot; encoding=&amp;quot;utf-8&amp;quot;?&amp;gt;&lt;br /&gt;
 &amp;lt;programmefields&amp;gt;&lt;br /&gt;
     &amp;lt;programmefield progid=&amp;quot;18&amp;quot; sourceid=&amp;quot;21&amp;quot;&amp;gt;&lt;br /&gt;
         &amp;lt;id&amp;gt;51&amp;lt;/id&amp;gt;&lt;br /&gt;
         &amp;lt;SourceID&amp;gt;21&amp;lt;/SourceID&amp;gt;&lt;br /&gt;
         &amp;lt;fieldName&amp;gt;Disability_P_51&amp;lt;/fieldName&amp;gt;&lt;br /&gt;
         &amp;lt;fieldLoc&amp;gt;f&amp;lt;/fieldLoc&amp;gt;&lt;br /&gt;
         &amp;lt;fieldType&amp;gt;text&amp;lt;/fieldType&amp;gt;&lt;br /&gt;
         &amp;lt;inputType&amp;gt;select&lt;br /&gt;
         &amp;lt;/inputType&amp;gt;&lt;br /&gt;
         &amp;lt;validation&amp;gt;&lt;br /&gt;
         &amp;lt;/validation&amp;gt;&lt;br /&gt;
         &amp;lt;valueListID&amp;gt;140&amp;lt;/valueListID&amp;gt;&lt;br /&gt;
         &amp;lt;tagline&amp;gt;&amp;lt;/tagline&amp;gt;&lt;br /&gt;
         &amp;lt;category&amp;gt;Demographic&amp;lt;/category&amp;gt;&lt;br /&gt;
         &amp;lt;displayName&amp;gt;Disability&amp;lt;/displayName&amp;gt;&lt;br /&gt;
         &amp;lt;flags&amp;gt;255&amp;lt;/flags&amp;gt;&lt;br /&gt;
         &amp;lt;enabled&amp;gt;1&amp;lt;/enabled&amp;gt;&lt;br /&gt;
         &amp;lt;value&amp;gt;&amp;lt;/value&amp;gt;&lt;br /&gt;
     &amp;lt;/programmefield&amp;gt;&lt;br /&gt;
     &amp;lt;programmefield progid=&amp;quot;19&amp;quot; sourceid=&amp;quot;40&amp;quot;&amp;gt;&lt;br /&gt;
         &amp;lt;id&amp;gt;80&amp;lt;/id&amp;gt;&lt;br /&gt;
         &amp;lt;SourceID&amp;gt;40&amp;lt;/SourceID&amp;gt;&lt;br /&gt;
         &amp;lt;fieldName&amp;gt;Disability_P_80&amp;lt;/fieldName&amp;gt;&lt;br /&gt;
         &amp;lt;fieldLoc&amp;gt;f&amp;lt;/fieldLoc&amp;gt;&lt;br /&gt;
         &amp;lt;fieldType&amp;gt;text&amp;lt;/fieldType&amp;gt;&lt;br /&gt;
         &amp;lt;inputType&amp;gt;select&amp;lt;/inputType&amp;gt;&lt;br /&gt;
         &amp;lt;validation&amp;gt;&amp;lt;/validation&amp;gt;&lt;br /&gt;
         &amp;lt;valueListID&amp;gt;154&amp;lt;/valueListID&amp;gt;&lt;br /&gt;
         &amp;lt;tagline&amp;gt;&amp;lt;/tagline&amp;gt;&lt;br /&gt;
         &amp;lt;category&amp;gt;Demographic&amp;lt;/category&amp;gt;&lt;br /&gt;
         &amp;lt;displayName&amp;gt;Disability&amp;lt;/displayName&amp;gt;&lt;br /&gt;
         &amp;lt;flags&amp;gt;993&amp;lt;/flags&amp;gt;&lt;br /&gt;
         &amp;lt;enabled&amp;gt;1&amp;lt;/enabled&amp;gt;&lt;br /&gt;
         &amp;lt;value&amp;gt;&amp;lt;/value&amp;gt;&lt;br /&gt;
     &amp;lt;/programmefield&amp;gt;&lt;br /&gt;
 &amp;lt;/programmefields&amp;gt;&lt;br /&gt;
&lt;br /&gt;
This shows there are 2 Disability fields, one for each Programme.&lt;br /&gt;
&lt;br /&gt;
==Identify a programme field for a specific programme==&lt;br /&gt;
&lt;br /&gt;
If you are only interested in knowing what a field is for a given programme, then you should use the following:&lt;br /&gt;
 curl --url &amp;lt;Base URL&amp;gt;/&amp;lt;structure&amp;gt;/&amp;lt;fieldname&amp;gt;/&amp;lt;ProgID&amp;gt; -u&amp;lt;username&amp;gt;:&amp;lt;password&amp;gt; -H Content-Type:text/xml -X POST -d &amp;quot;&amp;lt;xml&amp;gt;&amp;quot;&lt;br /&gt;
&lt;br /&gt;
Which will return:&lt;br /&gt;
 &amp;lt;?xml version=&amp;quot;1.0&amp;quot; encoding=&amp;quot;utf-8&amp;quot;?&amp;gt;&lt;br /&gt;
 &amp;lt;programmefields&amp;gt;&lt;br /&gt;
     &amp;lt;programmefield progid=&amp;quot;18&amp;quot; sourceid=&amp;quot;21&amp;quot;&amp;gt;&lt;br /&gt;
         &amp;lt;id&amp;gt;51&amp;lt;/id&amp;gt;&lt;br /&gt;
         &amp;lt;SourceID&amp;gt;21&amp;lt;/SourceID&amp;gt;&lt;br /&gt;
         &amp;lt;fieldName&amp;gt;Disability_P_51&amp;lt;/fieldName&amp;gt;&lt;br /&gt;
         &amp;lt;fieldLoc&amp;gt;f&amp;lt;/fieldLoc&amp;gt;&lt;br /&gt;
         &amp;lt;fieldType&amp;gt;text&amp;lt;/fieldType&amp;gt;&lt;br /&gt;
         &amp;lt;inputType&amp;gt;select&lt;br /&gt;
         &amp;lt;/inputType&amp;gt;&lt;br /&gt;
         &amp;lt;validation&amp;gt;&lt;br /&gt;
         &amp;lt;/validation&amp;gt;&lt;br /&gt;
         &amp;lt;valueListID&amp;gt;140&amp;lt;/valueListID&amp;gt;&lt;br /&gt;
         &amp;lt;tagline&amp;gt;&amp;lt;/tagline&amp;gt;&lt;br /&gt;
         &amp;lt;category&amp;gt;Demographic&amp;lt;/category&amp;gt;&lt;br /&gt;
         &amp;lt;displayName&amp;gt;Disability&amp;lt;/displayName&amp;gt;&lt;br /&gt;
         &amp;lt;flags&amp;gt;255&amp;lt;/flags&amp;gt;&lt;br /&gt;
         &amp;lt;enabled&amp;gt;1&amp;lt;/enabled&amp;gt;&lt;br /&gt;
         &amp;lt;value&amp;gt;&amp;lt;/value&amp;gt;&lt;br /&gt;
     &amp;lt;/programmefield&amp;gt;&lt;br /&gt;
 &amp;lt;/programmefields&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Supported Structures ==&lt;br /&gt;
* Group&lt;br /&gt;
* Staff&lt;br /&gt;
* Volunteer&lt;br /&gt;
* Person&lt;br /&gt;
* SessionGroup&lt;br /&gt;
* Session&lt;br /&gt;
* Venue&lt;br /&gt;
* Field&lt;br /&gt;
* Media&lt;br /&gt;
* PersonContact&lt;br /&gt;
* CaseStudy&lt;/div&gt;</summary>
		<author><name>Wikiadmin</name></author>
	</entry>
	<entry>
		<id>https://www.substance.net/views-api-docs/index.php?title=Rest_-_Admin_-_Outcomes&amp;diff=284</id>
		<title>Rest - Admin - Outcomes</title>
		<link rel="alternate" type="text/html" href="https://www.substance.net/views-api-docs/index.php?title=Rest_-_Admin_-_Outcomes&amp;diff=284"/>
		<updated>2016-02-26T13:10:19Z</updated>

		<summary type="html">&lt;p&gt;Wikiadmin: /* Base URL */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;==Purpose==&lt;br /&gt;
&lt;br /&gt;
To fetch information about the outcomes an agency is associated with.&lt;br /&gt;
&#039;&#039;&#039;&#039;&#039;Please note that this is currently a read only service&#039;&#039;&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
===Base URL===&lt;br /&gt;
https://app.viewsapp.net/api/restful/admin/outcomes&lt;br /&gt;
&lt;br /&gt;
==Retreive associated outcomes==&lt;br /&gt;
&lt;br /&gt;
 curl --url &amp;lt;Base URL&amp;gt; -u&amp;lt;username&amp;gt;:&amp;lt;password&amp;gt; -H Content-Type:text/xml -X POST -d &amp;quot;&amp;lt;xml&amp;gt;&amp;quot;&lt;br /&gt;
&lt;br /&gt;
This will return a list of outcomes that the agency is associated with in the following format:&lt;br /&gt;
 &amp;lt;?xml version=&amp;quot;1.0&amp;quot; encoding=&amp;quot;utf-8&amp;quot;?&amp;gt;&lt;br /&gt;
 &amp;lt;admin&amp;gt;&lt;br /&gt;
     &amp;lt;outcomes&amp;gt;&lt;br /&gt;
         &amp;lt;outcome id=&amp;quot;7&amp;quot;&amp;gt;An Outcome&amp;lt;/outcome&amp;gt;&lt;br /&gt;
         &amp;lt;outcome id=&amp;quot;18&amp;quot;&amp;gt;Outcome 2&amp;lt;/outcome&amp;gt;&lt;br /&gt;
         &amp;lt;outcome id=&amp;quot;19&amp;quot;&amp;gt;Another Outcome&amp;lt;/outcome&amp;gt;&lt;br /&gt;
     &amp;lt;/outcomes&amp;gt;&lt;br /&gt;
 &amp;lt;/admin&amp;gt;&lt;/div&gt;</summary>
		<author><name>Wikiadmin</name></author>
	</entry>
	<entry>
		<id>https://www.substance.net/views-api-docs/index.php?title=Rest_-_Admin_-_Objectives&amp;diff=283</id>
		<title>Rest - Admin - Objectives</title>
		<link rel="alternate" type="text/html" href="https://www.substance.net/views-api-docs/index.php?title=Rest_-_Admin_-_Objectives&amp;diff=283"/>
		<updated>2016-02-26T13:10:03Z</updated>

		<summary type="html">&lt;p&gt;Wikiadmin: /* Base URL */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;==Purpose==&lt;br /&gt;
&lt;br /&gt;
To fetch information about the objectives an agency is associated with.&lt;br /&gt;
&#039;&#039;&#039;&#039;&#039;Please note that this is currently a read only service&#039;&#039;&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
===Base URL===&lt;br /&gt;
https://app.viewsapp.net/api/restful/admin/objectives&lt;br /&gt;
&lt;br /&gt;
==Retreive associated objectives==&lt;br /&gt;
&lt;br /&gt;
 curl --url &amp;lt;Base URL&amp;gt; -u&amp;lt;username&amp;gt;:&amp;lt;password&amp;gt; -H Content-Type:text/xml -X POST -d &amp;quot;&amp;lt;xml&amp;gt;&amp;quot;&lt;br /&gt;
&lt;br /&gt;
This will return a list of objectives that the agency is associated with in the following format:&lt;br /&gt;
 &amp;lt;?xml version=&amp;quot;1.0&amp;quot; encoding=&amp;quot;utf-8&amp;quot;?&amp;gt;&lt;br /&gt;
 &amp;lt;admin&amp;gt;&lt;br /&gt;
     &amp;lt;objectives&amp;gt;&lt;br /&gt;
         &amp;lt;objective id=&amp;quot;7&amp;quot;&amp;gt;An Objective&amp;lt;/objective&amp;gt;&lt;br /&gt;
         &amp;lt;objective id=&amp;quot;18&amp;quot;&amp;gt;Objective 2&amp;lt;/objective&amp;gt;&lt;br /&gt;
         &amp;lt;objective id=&amp;quot;19&amp;quot;&amp;gt;Another Objective&amp;lt;/objective&amp;gt;&lt;br /&gt;
     &amp;lt;/objectives&amp;gt;&lt;br /&gt;
 &amp;lt;/admin&amp;gt;&lt;/div&gt;</summary>
		<author><name>Wikiadmin</name></author>
	</entry>
	<entry>
		<id>https://www.substance.net/views-api-docs/index.php?title=Rest_-_Admin_-_Programmes&amp;diff=282</id>
		<title>Rest - Admin - Programmes</title>
		<link rel="alternate" type="text/html" href="https://www.substance.net/views-api-docs/index.php?title=Rest_-_Admin_-_Programmes&amp;diff=282"/>
		<updated>2016-02-26T13:09:46Z</updated>

		<summary type="html">&lt;p&gt;Wikiadmin: /* Purpose */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;==Purpose==&lt;br /&gt;
&lt;br /&gt;
To fetch information about the programmes an agency is associated with.&lt;br /&gt;
&lt;br /&gt;
===Base URL===&lt;br /&gt;
https://app.viewsapp.net/api/restful/admin/programmes&lt;br /&gt;
&lt;br /&gt;
==Retreive associated programmes==&lt;br /&gt;
&lt;br /&gt;
 curl --url &amp;lt;Base URL&amp;gt; -u&amp;lt;username&amp;gt;:&amp;lt;password&amp;gt; -H Content-Type:text/xml -X POST -d &amp;quot;&amp;lt;xml&amp;gt;&amp;quot;&lt;br /&gt;
&lt;br /&gt;
This will return a list of programmes that the agency is associated with in the following format:&lt;br /&gt;
 &amp;lt;?xml version=&amp;quot;1.0&amp;quot; encoding=&amp;quot;utf-8&amp;quot;?&amp;gt;&lt;br /&gt;
 &amp;lt;admin&amp;gt;&lt;br /&gt;
     &amp;lt;programmes&amp;gt;&lt;br /&gt;
         &amp;lt;programme id=&amp;quot;7&amp;quot;&amp;gt;Football League Trust&amp;lt;/programme&amp;gt;&lt;br /&gt;
         &amp;lt;programme id=&amp;quot;18&amp;quot;&amp;gt;FLT + NCS Collaboration&amp;lt;/programme&amp;gt;&lt;br /&gt;
         &amp;lt;programme id=&amp;quot;19&amp;quot;&amp;gt;Sported Impact Analysis&amp;lt;/programme&amp;gt;&lt;br /&gt;
         &amp;lt;programme id=&amp;quot;25&amp;quot;&amp;gt;DFE YPFN&amp;lt;/programme&amp;gt;&lt;br /&gt;
     &amp;lt;/programmes&amp;gt;&lt;br /&gt;
 &amp;lt;/admin&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
==Fetching information about a programme==&lt;br /&gt;
&lt;br /&gt;
 curl --url &amp;lt;Base URL&amp;gt;/&amp;lt;id&amp;gt; -u&amp;lt;username&amp;gt;:&amp;lt;password&amp;gt; -H Content-Type:text/xml -X POST -d &amp;quot;&amp;lt;xml&amp;gt;&amp;quot;&lt;br /&gt;
* &#039;&#039;&#039;id&#039;&#039;&#039; - The ID of the Value List&lt;br /&gt;
&lt;br /&gt;
This will return an xml file similar to the following:&lt;br /&gt;
 &amp;lt;?xml version=&amp;quot;1.0&amp;quot; encoding=&amp;quot;utf-8&amp;quot;?&amp;gt;&lt;br /&gt;
 &amp;lt;programme id=&amp;quot;7&amp;quot;&amp;gt;&lt;br /&gt;
     &amp;lt;ProgramID&amp;gt;7&amp;lt;/ProgramID&amp;gt;&lt;br /&gt;
     &amp;lt;Name&amp;gt;Football League Trust&amp;lt;/Name&amp;gt;&lt;br /&gt;
     &amp;lt;outcomeFrameworks&amp;gt;2|3|4&amp;lt;/outcomeFrameworks&amp;gt;&lt;br /&gt;
     &amp;lt;shortCode&amp;gt;FLT&amp;lt;/shortCode&amp;gt;&lt;br /&gt;
 &amp;lt;/programme&amp;gt;&lt;/div&gt;</summary>
		<author><name>Wikiadmin</name></author>
	</entry>
	<entry>
		<id>https://www.substance.net/views-api-docs/index.php?title=Rest_-_Admin_-_Value_Lists&amp;diff=281</id>
		<title>Rest - Admin - Value Lists</title>
		<link rel="alternate" type="text/html" href="https://www.substance.net/views-api-docs/index.php?title=Rest_-_Admin_-_Value_Lists&amp;diff=281"/>
		<updated>2016-02-26T13:09:29Z</updated>

		<summary type="html">&lt;p&gt;Wikiadmin: /* Purpose */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;==Purpose==&lt;br /&gt;
&lt;br /&gt;
Used for maintaining the value lists within Views.&lt;br /&gt;
&lt;br /&gt;
===Base URL===&lt;br /&gt;
https://app.viewsapp.net/api/restful/admin/valuelists&lt;br /&gt;
&lt;br /&gt;
==Retrieve a list of available value lists==&lt;br /&gt;
 curl --url &amp;lt;Base URL&amp;gt;?type=&amp;lt;type&amp;gt;&amp;amp;mode=&amp;lt;mode&amp;gt; -u&amp;lt;username&amp;gt;:&amp;lt;password&amp;gt; -H Content-Type:text/xml -X POST -d &amp;quot;&amp;lt;xml&amp;gt;&amp;quot;&lt;br /&gt;
&lt;br /&gt;
* type &#039;&#039;&#039;required&#039;&#039;&#039; - This must be one of the following values: &lt;br /&gt;
*# Staff&lt;br /&gt;
*# Volunteer&lt;br /&gt;
*# Individual&lt;br /&gt;
*# Person&lt;br /&gt;
*# Group&lt;br /&gt;
*# Session&lt;br /&gt;
*# SessionGroup&lt;br /&gt;
*# Question&lt;br /&gt;
*# Agency&lt;br /&gt;
*# Venue&lt;br /&gt;
*# QualificationProgress&lt;br /&gt;
*# QualificationAchievement&lt;br /&gt;
*# AddressBook&lt;br /&gt;
*# Report&lt;br /&gt;
* mode - this can be left blank to return a complete list, or one of the following values:&lt;br /&gt;
*# editable - filters the returned value lists that are allowed to be extended&lt;br /&gt;
*# nonsystem - filters the returned value lists to only Non System lists&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
==Retreive the details of a Value List==&lt;br /&gt;
&lt;br /&gt;
 curl --url &amp;lt;Base URL&amp;gt;/&amp;lt;id&amp;gt;/details -u&amp;lt;username&amp;gt;:&amp;lt;password&amp;gt; -H Content-Type:text/xml&lt;br /&gt;
* &#039;&#039;&#039;id&#039;&#039;&#039; - The ID of the Value List&lt;br /&gt;
&lt;br /&gt;
This will return all the meta data about a Value list. &#039;&#039;&#039;&#039;&#039;Needs more detail&#039;&#039;&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
==Fetching a Value List==&lt;br /&gt;
&lt;br /&gt;
 curl --url &amp;lt;Base URL&amp;gt;/&amp;lt;id&amp;gt; -u&amp;lt;username&amp;gt;:&amp;lt;password&amp;gt; -H Content-Type:text/xml&lt;br /&gt;
* &#039;&#039;&#039;id&#039;&#039;&#039; - The ID of the Value List&lt;br /&gt;
&lt;br /&gt;
This will return an xml file similar to the following:&lt;br /&gt;
 &amp;lt;?xml version=&amp;quot;1.0&amp;quot; encoding=&amp;quot;utf-8&amp;quot;?&amp;gt;&lt;br /&gt;
 &amp;lt;valuelist id=&amp;quot;42&amp;quot;&amp;gt;&lt;br /&gt;
     &amp;lt;items&amp;gt;&lt;br /&gt;
         &amp;lt;item id=&amp;quot;7&amp;quot;&amp;gt;Red&amp;lt;/item&amp;gt;&lt;br /&gt;
         &amp;lt;item id=&amp;quot;18&amp;quot;&amp;gt;Green&amp;lt;/item&amp;gt;&lt;br /&gt;
         &amp;lt;item id=&amp;quot;19&amp;quot;&amp;gt;Blue&amp;lt;/item&amp;gt;&lt;br /&gt;
         &amp;lt;item id=&amp;quot;25&amp;quot;&amp;gt;Purple&amp;lt;/item&amp;gt;&lt;br /&gt;
     &amp;lt;/items&amp;gt;&lt;br /&gt;
 &amp;lt;/valuelist&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
==Fetching a Value List By Name==&lt;br /&gt;
&lt;br /&gt;
 curl --url &amp;lt;Base URL&amp;gt;/&amp;lt;type&amp;gt;/&amp;lt;name&amp;gt; -u&amp;lt;username&amp;gt;:&amp;lt;password&amp;gt; -H Content-Type:text/xml&lt;br /&gt;
* &#039;&#039;&#039;type&#039;&#039;&#039; - This is the type of the Value List. This must be one of the values stated above&lt;br /&gt;
* &#039;&#039;&#039;name&#039;&#039;&#039; - The name of the Value List&lt;br /&gt;
&lt;br /&gt;
This will return an xml file in the same format as fetching a list by id&lt;br /&gt;
&lt;br /&gt;
For eaxample, the following call will get a list of session group volunteering types:&lt;br /&gt;
&lt;br /&gt;
 curl --url &amp;lt;Base URL&amp;gt;/sessiongroup/volunteeringtypes -u&amp;lt;username&amp;gt;:&amp;lt;password&amp;gt; -H Content-Type:text/xml&lt;/div&gt;</summary>
		<author><name>Wikiadmin</name></author>
	</entry>
	<entry>
		<id>https://www.substance.net/views-api-docs/index.php?title=Rest_-_Evidence_-_Questionnaires_-_Answers&amp;diff=280</id>
		<title>Rest - Evidence - Questionnaires - Answers</title>
		<link rel="alternate" type="text/html" href="https://www.substance.net/views-api-docs/index.php?title=Rest_-_Evidence_-_Questionnaires_-_Answers&amp;diff=280"/>
		<updated>2016-02-26T13:09:00Z</updated>

		<summary type="html">&lt;p&gt;Wikiadmin: /* Schema */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;==Purpose==&lt;br /&gt;
&lt;br /&gt;
Used for submitting answer sets to questionnaires against participants and for retrieving the details of answered questionnaires that have been submitted. It is the preferred solution to use the contextualised version of this API.&lt;br /&gt;
&lt;br /&gt;
===Base URL===&lt;br /&gt;
&amp;lt;nowiki&amp;gt;https://app.viewsapp.net/api/restful/evidence/questionnaires/&amp;lt;qid&amp;gt;/answers&amp;lt;/nowiki&amp;gt;&lt;br /&gt;
* qid - This is the questionnaire id&lt;br /&gt;
&lt;br /&gt;
===Schema===&lt;br /&gt;
&amp;lt;nowiki&amp;gt;https://app.viewsapp.net/api/restful/evidence/questionnaires/answers/answerset-schema(.xml|.json|.xsd)&amp;lt;/nowiki&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;nowiki&amp;gt;https://app.viewsapp.net/api/restful/evidence/questionnaires/answers/answers-schema(.xml|.json|.xsd)&amp;lt;/nowiki&amp;gt;&lt;br /&gt;
&lt;br /&gt;
==Fetching a list of answer sets==&lt;br /&gt;
The default call will return a list of questionnaires (answer sets) that have been recorded against the questionnaire&lt;br /&gt;
 curl --url &amp;lt;Base URL&amp;gt; -u&amp;lt;username&amp;gt;:&amp;lt;password&amp;gt; -H Content-Type:text/xml&lt;br /&gt;
&lt;br /&gt;
This will return data similar to the following:&lt;br /&gt;
 &amp;lt;answersets count=&amp;quot;2&amp;quot;&amp;gt;&lt;br /&gt;
     &amp;lt;answerset id=&amp;quot;1&amp;quot; questionnaireid=&amp;quot;14&amp;quot;&amp;gt;&lt;br /&gt;
         &amp;lt;EntityType&amp;gt;Person&amp;lt;/EntityType&amp;gt;&lt;br /&gt;
         &amp;lt;EntityID&amp;gt;1&amp;lt;/EntityID&amp;gt;&lt;br /&gt;
         &amp;lt;Date&amp;gt;2012-07-31T10:00:00&amp;lt;/Date&amp;gt;&lt;br /&gt;
         &amp;lt;QuestionnaireID&amp;gt;14&amp;lt;/QuestionnaireID&amp;gt;&lt;br /&gt;
         &amp;lt;AnswerSetID&amp;gt;1&amp;lt;/AnswerSetID&amp;gt;&lt;br /&gt;
         &amp;lt;Questionnaire&amp;gt;Impact&amp;lt;/Questionnaire&amp;gt;&lt;br /&gt;
     &amp;lt;/answerset&amp;gt;&lt;br /&gt;
     &amp;lt;answerset id=&amp;quot;6&amp;quot; questionnaireid=&amp;quot;14&amp;quot;&amp;gt;&lt;br /&gt;
         &amp;lt;EntityType&amp;gt;Person&amp;lt;/EntityType&amp;gt;&lt;br /&gt;
         &amp;lt;EntityID&amp;gt;1&amp;lt;/EntityID&amp;gt;&lt;br /&gt;
         &amp;lt;Date&amp;gt;2012-05-02T09:10:00&amp;lt;/Date&amp;gt;&lt;br /&gt;
         &amp;lt;QuestionnaireID&amp;gt;14&amp;lt;/QuestionnaireID&amp;gt;&lt;br /&gt;
         &amp;lt;AnswerSetID&amp;gt;6&amp;lt;/AnswerSetID&amp;gt;&lt;br /&gt;
         &amp;lt;Questionnaire&amp;gt;Impact&amp;lt;/Questionnaire&amp;gt;&lt;br /&gt;
     &amp;lt;/answerset&amp;gt;&lt;br /&gt;
 &amp;lt;/answersets&amp;gt;&lt;br /&gt;
&lt;br /&gt;
The results are order by the most recent first. This means to get the latest version of a questionnaire, you would only need to fetch the first result.&lt;br /&gt;
&lt;br /&gt;
Optionally, you can can append the &amp;lt;code&amp;gt;?include-answers&amp;lt;/code&amp;gt; parameter to include all the actual answer data alongside the answer set details. This will convert the &amp;lt;nowiki&amp;gt;&amp;lt;answerset&amp;gt;&amp;lt;/nowiki&amp;gt; object to something more like that described below. &lt;br /&gt;
This is not recommended due to the volume of data that it could return&lt;br /&gt;
&lt;br /&gt;
==Fetching the answers of a given questionnaire answerset==&lt;br /&gt;
 curl --url &amp;lt;Base URL&amp;gt;/&amp;lt;setId&amp;gt; -u&amp;lt;username&amp;gt;:&amp;lt;password&amp;gt; -H Content-Type:text/xml&lt;br /&gt;
* setId - This is the id of the Answers Set you want to retrieve&lt;br /&gt;
&lt;br /&gt;
It&#039;s will return something along the lines of&lt;br /&gt;
 &amp;lt;answerset questionaireid=&amp;quot;14&amp;quot; id=&amp;quot;1&amp;quot;&amp;gt;&lt;br /&gt;
     &amp;lt;EntityType&amp;gt;Person&amp;lt;/EntityType&amp;gt;&lt;br /&gt;
     &amp;lt;EntityID&amp;gt;1&amp;lt;/EntityID&amp;gt;&lt;br /&gt;
     &amp;lt;TargetType/&amp;gt;&lt;br /&gt;
     &amp;lt;TargetID&amp;gt;0&amp;lt;/TargetID&amp;gt;&lt;br /&gt;
     &amp;lt;Date&amp;gt;2012-07-31T10:00:00&amp;lt;/Date&amp;gt;&lt;br /&gt;
     &amp;lt;answers count=&amp;quot;9&amp;quot;&amp;gt;&lt;br /&gt;
         &amp;lt;answer id=&amp;quot;78&amp;quot;&amp;gt;&lt;br /&gt;
             &amp;lt;QuestionID&amp;gt;78&amp;lt;/QuestionID&amp;gt;&lt;br /&gt;
             &amp;lt;Answer&amp;gt;Fully Agree&amp;lt;/Answer&amp;gt;&lt;br /&gt;
         &amp;lt;/answer&amp;gt;&lt;br /&gt;
         &amp;lt;answer id=&amp;quot;79&amp;quot;&amp;gt;&lt;br /&gt;
             &amp;lt;QuestionID&amp;gt;79&amp;lt;/QuestionID&amp;gt;&lt;br /&gt;
             &amp;lt;Answer&amp;gt;Truly Agree&amp;lt;/Answer&amp;gt;&lt;br /&gt;
         &amp;lt;/answer&amp;gt;&lt;br /&gt;
         &amp;lt;answer id=&amp;quot;80&amp;quot;&amp;gt;&lt;br /&gt;
             &amp;lt;QuestionID&amp;gt;80&amp;lt;/QuestionID&amp;gt;&lt;br /&gt;
             &amp;lt;Answer&amp;gt;Agree&amp;lt;/Answer&amp;gt;&lt;br /&gt;
         &amp;lt;/answer&amp;gt;&lt;br /&gt;
         ...&lt;br /&gt;
     &amp;lt;/answers&amp;gt;&lt;br /&gt;
 &amp;lt;/answerset&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
==Fetching a single answer from a questionnaire==&lt;br /&gt;
 curl --url &amp;lt;Base URL&amp;gt;/&amp;lt;setId&amp;gt;/&amp;lt;questionId&amp;gt; -u&amp;lt;username&amp;gt;:&amp;lt;password&amp;gt; -H Content-Type:text/xml&lt;br /&gt;
* setId - This is the id of the Answers Set you want to retrieve&lt;br /&gt;
* questionId - This is the id of the question you want the answer for&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;answer id=&amp;quot;78&amp;quot;&amp;gt;&lt;br /&gt;
     &amp;lt;QuestionnaireID&amp;gt;14&amp;lt;/QuestionnaireID&amp;gt;&lt;br /&gt;
     &amp;lt;AnswerSetID&amp;gt;1&amp;lt;/AnswerSetID&amp;gt;&lt;br /&gt;
     &amp;lt;QuestionID&amp;gt;78&amp;lt;/QuestionID&amp;gt;&lt;br /&gt;
     &amp;lt;Answer&amp;gt;Fully Agree&amp;lt;/Answer&amp;gt;&lt;br /&gt;
 &amp;lt;/answer&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
==Creating a new Answer Set==&lt;br /&gt;
 curl --url &amp;lt;Base URL&amp;gt; -u&amp;lt;username&amp;gt;:&amp;lt;password&amp;gt; -H Content-Type:text/xml -X POST -d &#039;&amp;lt;xml&amp;gt;&#039;&lt;br /&gt;
&lt;br /&gt;
To submit a new set of answers against a questionnaire, you should send data in the following structure:&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;answers&amp;gt;&lt;br /&gt;
     &amp;lt;Date&amp;gt;2012-07-31T10:00:00&amp;lt;/Date&amp;gt;&lt;br /&gt;
     &amp;lt;answer id=&amp;quot;78&amp;quot;&amp;gt;&lt;br /&gt;
       &amp;lt;QuestionID&amp;gt;78&amp;lt;/QuestionID&amp;gt;&lt;br /&gt;
       &amp;lt;Answer&amp;gt;Fully Agree&amp;lt;/Answer&amp;gt;&lt;br /&gt;
     &amp;lt;/answer&amp;gt;&lt;br /&gt;
     &amp;lt;answer id=&amp;quot;79&amp;quot;&amp;gt;&lt;br /&gt;
       &amp;lt;QuestionID&amp;gt;79&amp;lt;/QuestionID&amp;gt;&lt;br /&gt;
       &amp;lt;Answer&amp;gt;Truly Agree&amp;lt;/Answer&amp;gt;&lt;br /&gt;
     &amp;lt;/answer&amp;gt;&lt;br /&gt;
     ...&lt;br /&gt;
 &amp;lt;/answers&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Note:&#039;&#039;&#039; If you specify the attribute &#039;&#039;&amp;lt;code&amp;gt;id&amp;lt;/code&amp;gt;&#039;&#039; then you do not need to specify the &amp;lt;code&amp;gt;&amp;lt;QuestionID&amp;gt;&amp;lt;/code&amp;gt; entity.&lt;br /&gt;
&lt;br /&gt;
You can also relate the questionnaire to a Session (and SessionGroup) by specifying the &amp;lt;code&amp;gt;&amp;lt;TargetType&amp;gt;&amp;lt;/code&amp;gt; and &amp;lt;code&amp;gt;&amp;lt;TargetID&amp;gt;&amp;lt;/code&amp;gt; entities&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;answers&amp;gt;&lt;br /&gt;
     &amp;lt;TargetType&amp;gt;Session&amp;lt;/TargetType&amp;gt;&lt;br /&gt;
     &amp;lt;TargetID&amp;gt;214&amp;lt;/TargetID&amp;gt;&lt;br /&gt;
     &amp;lt;Date&amp;gt;2012-07-31T10:00:00&amp;lt;/Date&amp;gt;&lt;br /&gt;
     &amp;lt;answer id=&amp;quot;78&amp;quot;&amp;gt;&lt;br /&gt;
       &amp;lt;QuestionID&amp;gt;78&amp;lt;/QuestionID&amp;gt;&lt;br /&gt;
       &amp;lt;Answer&amp;gt;Fully Agree&amp;lt;/Answer&amp;gt;&lt;br /&gt;
     &amp;lt;/answer&amp;gt;&lt;br /&gt;
     ....&lt;br /&gt;
 &amp;lt;/answers&amp;gt;&lt;br /&gt;
&lt;br /&gt;
You can also omit the &amp;lt;code&amp;gt;&amp;lt;Date&amp;gt;&amp;lt;/code&amp;gt; entity. If you do this, then the current system date/time will be used.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
==Updating an existing Answer Set==&lt;br /&gt;
 curl --url &amp;lt;Base URL&amp;gt;/&amp;lt;setid&amp;gt; -u&amp;lt;username&amp;gt;:&amp;lt;password&amp;gt; -H Content-Type:text/xml -X PUT -d &#039;&amp;lt;xml&amp;gt;&#039;&lt;br /&gt;
&lt;br /&gt;
When updating the answers in an answer set, you should use the same structure as when creating a new answer set. However, if you specify the entities &amp;lt;code&amp;gt;TargetType&amp;gt;&amp;lt;/code&amp;gt; and &amp;lt;code&amp;gt;TargetID&amp;gt;&amp;lt;/code&amp;gt; they will be ignored.&lt;/div&gt;</summary>
		<author><name>Wikiadmin</name></author>
	</entry>
	<entry>
		<id>https://www.substance.net/views-api-docs/index.php?title=Rest_-_Evidence_-_Questionnaires_-_Answers&amp;diff=279</id>
		<title>Rest - Evidence - Questionnaires - Answers</title>
		<link rel="alternate" type="text/html" href="https://www.substance.net/views-api-docs/index.php?title=Rest_-_Evidence_-_Questionnaires_-_Answers&amp;diff=279"/>
		<updated>2016-02-26T13:08:46Z</updated>

		<summary type="html">&lt;p&gt;Wikiadmin: /* Purpose */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;==Purpose==&lt;br /&gt;
&lt;br /&gt;
Used for submitting answer sets to questionnaires against participants and for retrieving the details of answered questionnaires that have been submitted. It is the preferred solution to use the contextualised version of this API.&lt;br /&gt;
&lt;br /&gt;
===Base URL===&lt;br /&gt;
&amp;lt;nowiki&amp;gt;https://app.viewsapp.net/api/restful/evidence/questionnaires/&amp;lt;qid&amp;gt;/answers&amp;lt;/nowiki&amp;gt;&lt;br /&gt;
* qid - This is the questionnaire id&lt;br /&gt;
&lt;br /&gt;
===Schema===&lt;br /&gt;
&amp;lt;nowiki&amp;gt;https://app.viewsapp.net/api/restful/evidence/questionnaires/answers/answerset-schema(.xml|.json|.xsd)&amp;lt;/nowiki&amp;gt;&lt;br /&gt;
&amp;lt;nowiki&amp;gt;https://app.viewsapp.net/api/restful/evidence/questionnaires/answers/answers-schema(.xml|.json|.xsd)&amp;lt;/nowiki&amp;gt;&lt;br /&gt;
&lt;br /&gt;
==Fetching a list of answer sets==&lt;br /&gt;
The default call will return a list of questionnaires (answer sets) that have been recorded against the questionnaire&lt;br /&gt;
 curl --url &amp;lt;Base URL&amp;gt; -u&amp;lt;username&amp;gt;:&amp;lt;password&amp;gt; -H Content-Type:text/xml&lt;br /&gt;
&lt;br /&gt;
This will return data similar to the following:&lt;br /&gt;
 &amp;lt;answersets count=&amp;quot;2&amp;quot;&amp;gt;&lt;br /&gt;
     &amp;lt;answerset id=&amp;quot;1&amp;quot; questionnaireid=&amp;quot;14&amp;quot;&amp;gt;&lt;br /&gt;
         &amp;lt;EntityType&amp;gt;Person&amp;lt;/EntityType&amp;gt;&lt;br /&gt;
         &amp;lt;EntityID&amp;gt;1&amp;lt;/EntityID&amp;gt;&lt;br /&gt;
         &amp;lt;Date&amp;gt;2012-07-31T10:00:00&amp;lt;/Date&amp;gt;&lt;br /&gt;
         &amp;lt;QuestionnaireID&amp;gt;14&amp;lt;/QuestionnaireID&amp;gt;&lt;br /&gt;
         &amp;lt;AnswerSetID&amp;gt;1&amp;lt;/AnswerSetID&amp;gt;&lt;br /&gt;
         &amp;lt;Questionnaire&amp;gt;Impact&amp;lt;/Questionnaire&amp;gt;&lt;br /&gt;
     &amp;lt;/answerset&amp;gt;&lt;br /&gt;
     &amp;lt;answerset id=&amp;quot;6&amp;quot; questionnaireid=&amp;quot;14&amp;quot;&amp;gt;&lt;br /&gt;
         &amp;lt;EntityType&amp;gt;Person&amp;lt;/EntityType&amp;gt;&lt;br /&gt;
         &amp;lt;EntityID&amp;gt;1&amp;lt;/EntityID&amp;gt;&lt;br /&gt;
         &amp;lt;Date&amp;gt;2012-05-02T09:10:00&amp;lt;/Date&amp;gt;&lt;br /&gt;
         &amp;lt;QuestionnaireID&amp;gt;14&amp;lt;/QuestionnaireID&amp;gt;&lt;br /&gt;
         &amp;lt;AnswerSetID&amp;gt;6&amp;lt;/AnswerSetID&amp;gt;&lt;br /&gt;
         &amp;lt;Questionnaire&amp;gt;Impact&amp;lt;/Questionnaire&amp;gt;&lt;br /&gt;
     &amp;lt;/answerset&amp;gt;&lt;br /&gt;
 &amp;lt;/answersets&amp;gt;&lt;br /&gt;
&lt;br /&gt;
The results are order by the most recent first. This means to get the latest version of a questionnaire, you would only need to fetch the first result.&lt;br /&gt;
&lt;br /&gt;
Optionally, you can can append the &amp;lt;code&amp;gt;?include-answers&amp;lt;/code&amp;gt; parameter to include all the actual answer data alongside the answer set details. This will convert the &amp;lt;nowiki&amp;gt;&amp;lt;answerset&amp;gt;&amp;lt;/nowiki&amp;gt; object to something more like that described below. &lt;br /&gt;
This is not recommended due to the volume of data that it could return&lt;br /&gt;
&lt;br /&gt;
==Fetching the answers of a given questionnaire answerset==&lt;br /&gt;
 curl --url &amp;lt;Base URL&amp;gt;/&amp;lt;setId&amp;gt; -u&amp;lt;username&amp;gt;:&amp;lt;password&amp;gt; -H Content-Type:text/xml&lt;br /&gt;
* setId - This is the id of the Answers Set you want to retrieve&lt;br /&gt;
&lt;br /&gt;
It&#039;s will return something along the lines of&lt;br /&gt;
 &amp;lt;answerset questionaireid=&amp;quot;14&amp;quot; id=&amp;quot;1&amp;quot;&amp;gt;&lt;br /&gt;
     &amp;lt;EntityType&amp;gt;Person&amp;lt;/EntityType&amp;gt;&lt;br /&gt;
     &amp;lt;EntityID&amp;gt;1&amp;lt;/EntityID&amp;gt;&lt;br /&gt;
     &amp;lt;TargetType/&amp;gt;&lt;br /&gt;
     &amp;lt;TargetID&amp;gt;0&amp;lt;/TargetID&amp;gt;&lt;br /&gt;
     &amp;lt;Date&amp;gt;2012-07-31T10:00:00&amp;lt;/Date&amp;gt;&lt;br /&gt;
     &amp;lt;answers count=&amp;quot;9&amp;quot;&amp;gt;&lt;br /&gt;
         &amp;lt;answer id=&amp;quot;78&amp;quot;&amp;gt;&lt;br /&gt;
             &amp;lt;QuestionID&amp;gt;78&amp;lt;/QuestionID&amp;gt;&lt;br /&gt;
             &amp;lt;Answer&amp;gt;Fully Agree&amp;lt;/Answer&amp;gt;&lt;br /&gt;
         &amp;lt;/answer&amp;gt;&lt;br /&gt;
         &amp;lt;answer id=&amp;quot;79&amp;quot;&amp;gt;&lt;br /&gt;
             &amp;lt;QuestionID&amp;gt;79&amp;lt;/QuestionID&amp;gt;&lt;br /&gt;
             &amp;lt;Answer&amp;gt;Truly Agree&amp;lt;/Answer&amp;gt;&lt;br /&gt;
         &amp;lt;/answer&amp;gt;&lt;br /&gt;
         &amp;lt;answer id=&amp;quot;80&amp;quot;&amp;gt;&lt;br /&gt;
             &amp;lt;QuestionID&amp;gt;80&amp;lt;/QuestionID&amp;gt;&lt;br /&gt;
             &amp;lt;Answer&amp;gt;Agree&amp;lt;/Answer&amp;gt;&lt;br /&gt;
         &amp;lt;/answer&amp;gt;&lt;br /&gt;
         ...&lt;br /&gt;
     &amp;lt;/answers&amp;gt;&lt;br /&gt;
 &amp;lt;/answerset&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
==Fetching a single answer from a questionnaire==&lt;br /&gt;
 curl --url &amp;lt;Base URL&amp;gt;/&amp;lt;setId&amp;gt;/&amp;lt;questionId&amp;gt; -u&amp;lt;username&amp;gt;:&amp;lt;password&amp;gt; -H Content-Type:text/xml&lt;br /&gt;
* setId - This is the id of the Answers Set you want to retrieve&lt;br /&gt;
* questionId - This is the id of the question you want the answer for&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;answer id=&amp;quot;78&amp;quot;&amp;gt;&lt;br /&gt;
     &amp;lt;QuestionnaireID&amp;gt;14&amp;lt;/QuestionnaireID&amp;gt;&lt;br /&gt;
     &amp;lt;AnswerSetID&amp;gt;1&amp;lt;/AnswerSetID&amp;gt;&lt;br /&gt;
     &amp;lt;QuestionID&amp;gt;78&amp;lt;/QuestionID&amp;gt;&lt;br /&gt;
     &amp;lt;Answer&amp;gt;Fully Agree&amp;lt;/Answer&amp;gt;&lt;br /&gt;
 &amp;lt;/answer&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
==Creating a new Answer Set==&lt;br /&gt;
 curl --url &amp;lt;Base URL&amp;gt; -u&amp;lt;username&amp;gt;:&amp;lt;password&amp;gt; -H Content-Type:text/xml -X POST -d &#039;&amp;lt;xml&amp;gt;&#039;&lt;br /&gt;
&lt;br /&gt;
To submit a new set of answers against a questionnaire, you should send data in the following structure:&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;answers&amp;gt;&lt;br /&gt;
     &amp;lt;Date&amp;gt;2012-07-31T10:00:00&amp;lt;/Date&amp;gt;&lt;br /&gt;
     &amp;lt;answer id=&amp;quot;78&amp;quot;&amp;gt;&lt;br /&gt;
       &amp;lt;QuestionID&amp;gt;78&amp;lt;/QuestionID&amp;gt;&lt;br /&gt;
       &amp;lt;Answer&amp;gt;Fully Agree&amp;lt;/Answer&amp;gt;&lt;br /&gt;
     &amp;lt;/answer&amp;gt;&lt;br /&gt;
     &amp;lt;answer id=&amp;quot;79&amp;quot;&amp;gt;&lt;br /&gt;
       &amp;lt;QuestionID&amp;gt;79&amp;lt;/QuestionID&amp;gt;&lt;br /&gt;
       &amp;lt;Answer&amp;gt;Truly Agree&amp;lt;/Answer&amp;gt;&lt;br /&gt;
     &amp;lt;/answer&amp;gt;&lt;br /&gt;
     ...&lt;br /&gt;
 &amp;lt;/answers&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Note:&#039;&#039;&#039; If you specify the attribute &#039;&#039;&amp;lt;code&amp;gt;id&amp;lt;/code&amp;gt;&#039;&#039; then you do not need to specify the &amp;lt;code&amp;gt;&amp;lt;QuestionID&amp;gt;&amp;lt;/code&amp;gt; entity.&lt;br /&gt;
&lt;br /&gt;
You can also relate the questionnaire to a Session (and SessionGroup) by specifying the &amp;lt;code&amp;gt;&amp;lt;TargetType&amp;gt;&amp;lt;/code&amp;gt; and &amp;lt;code&amp;gt;&amp;lt;TargetID&amp;gt;&amp;lt;/code&amp;gt; entities&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;answers&amp;gt;&lt;br /&gt;
     &amp;lt;TargetType&amp;gt;Session&amp;lt;/TargetType&amp;gt;&lt;br /&gt;
     &amp;lt;TargetID&amp;gt;214&amp;lt;/TargetID&amp;gt;&lt;br /&gt;
     &amp;lt;Date&amp;gt;2012-07-31T10:00:00&amp;lt;/Date&amp;gt;&lt;br /&gt;
     &amp;lt;answer id=&amp;quot;78&amp;quot;&amp;gt;&lt;br /&gt;
       &amp;lt;QuestionID&amp;gt;78&amp;lt;/QuestionID&amp;gt;&lt;br /&gt;
       &amp;lt;Answer&amp;gt;Fully Agree&amp;lt;/Answer&amp;gt;&lt;br /&gt;
     &amp;lt;/answer&amp;gt;&lt;br /&gt;
     ....&lt;br /&gt;
 &amp;lt;/answers&amp;gt;&lt;br /&gt;
&lt;br /&gt;
You can also omit the &amp;lt;code&amp;gt;&amp;lt;Date&amp;gt;&amp;lt;/code&amp;gt; entity. If you do this, then the current system date/time will be used.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
==Updating an existing Answer Set==&lt;br /&gt;
 curl --url &amp;lt;Base URL&amp;gt;/&amp;lt;setid&amp;gt; -u&amp;lt;username&amp;gt;:&amp;lt;password&amp;gt; -H Content-Type:text/xml -X PUT -d &#039;&amp;lt;xml&amp;gt;&#039;&lt;br /&gt;
&lt;br /&gt;
When updating the answers in an answer set, you should use the same structure as when creating a new answer set. However, if you specify the entities &amp;lt;code&amp;gt;TargetType&amp;gt;&amp;lt;/code&amp;gt; and &amp;lt;code&amp;gt;TargetID&amp;gt;&amp;lt;/code&amp;gt; they will be ignored.&lt;/div&gt;</summary>
		<author><name>Wikiadmin</name></author>
	</entry>
	<entry>
		<id>https://www.substance.net/views-api-docs/index.php?title=Rest_-_Evidence_-_Questionnaires_-_Questions&amp;diff=278</id>
		<title>Rest - Evidence - Questionnaires - Questions</title>
		<link rel="alternate" type="text/html" href="https://www.substance.net/views-api-docs/index.php?title=Rest_-_Evidence_-_Questionnaires_-_Questions&amp;diff=278"/>
		<updated>2016-02-26T13:08:16Z</updated>

		<summary type="html">&lt;p&gt;Wikiadmin: /* Purpose */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;==Purpose==&lt;br /&gt;
&lt;br /&gt;
This API is used for creating, editing and deleting questionnaires from the Views system. It is &#039;&#039;&#039;not&#039;&#039;&#039; a way to submit questionnaire answer data. That is done via the other various sections.&lt;br /&gt;
&lt;br /&gt;
===Base URL===&lt;br /&gt;
&amp;lt;nowiki&amp;gt;https://app.viewsapp.net/api/restful/evidence/questionnaires/&amp;lt;id&amp;gt;/questions&amp;lt;/nowiki&amp;gt;&lt;br /&gt;
* id - The is the id of the questionnaire.&lt;br /&gt;
&lt;br /&gt;
===Schema===&lt;br /&gt;
&amp;lt;nowiki&amp;gt;https://app.viewsapp.net/api/restful/evidence/questionnaires/questions/schema(.xml|.json|.xsd)&amp;lt;/nowiki&amp;gt;&lt;br /&gt;
&lt;br /&gt;
==Listing available Questions==&lt;br /&gt;
 curl --url &amp;lt;Base URL&amp;gt; -u&amp;lt;username&amp;gt;:&amp;lt;password&amp;gt; -H Content-Type:text/xml &lt;br /&gt;
* query - This is a text string to use to search for in the venues records&lt;br /&gt;
&lt;br /&gt;
Questions are not searchable, and by default &#039;&#039;only&#039;&#039; the enabled questions are returned. If you want to get a complete list of questions, then you should use the following:&lt;br /&gt;
 curl --url &amp;lt;Base URL&amp;gt;?allquestions=1 -u&amp;lt;username&amp;gt;:&amp;lt;password&amp;gt; -H Content-Type:text/xml &lt;br /&gt;
&lt;br /&gt;
 &amp;lt;questions count=&amp;quot;21&amp;quot;&amp;gt;&lt;br /&gt;
     &amp;lt;question id=&amp;quot;12&amp;quot;&amp;gt;&lt;br /&gt;
         &amp;lt;QuestionID&amp;gt;12&amp;lt;/QuestionID&amp;gt;&lt;br /&gt;
         &amp;lt;QuestionnaireID&amp;gt;3&amp;lt;/QuestionnaireID&amp;gt;&lt;br /&gt;
         &amp;lt;Question&amp;gt;What?&amp;lt;/Question&amp;gt;&lt;br /&gt;
         &amp;lt;valueListID&amp;gt;83&amp;lt;/valueListID&amp;gt;&lt;br /&gt;
         &amp;lt;inputType&amp;gt;radio&amp;lt;/inputType&amp;gt;&lt;br /&gt;
         &amp;lt;validation&amp;gt;&amp;lt;/validation&amp;gt;&lt;br /&gt;
         &amp;lt;category&amp;gt;What&amp;lt;/category&amp;gt;&lt;br /&gt;
         &amp;lt;enabled&amp;gt;1&amp;lt;/enabled&amp;gt;&lt;br /&gt;
         &amp;lt;order&amp;gt;0&amp;lt;/order&amp;gt;&lt;br /&gt;
         &amp;lt;Created&amp;gt;2011-03-04 01:09:55&amp;lt;/Created&amp;gt;&lt;br /&gt;
         &amp;lt;CreatedBy&amp;gt;ant&amp;lt;/CreatedBy&amp;gt;&lt;br /&gt;
         &amp;lt;Updated&amp;gt;2011-03-04 01:09:55&amp;lt;/Updated&amp;gt;&lt;br /&gt;
         &amp;lt;UpdatedBy&amp;gt;ant&amp;lt;/UpdatedBy&amp;gt;&lt;br /&gt;
     &amp;lt;/question&amp;gt;&lt;br /&gt;
 ...&lt;br /&gt;
     &amp;lt;question id=&amp;quot;13&amp;quot;&amp;gt;&lt;br /&gt;
         &amp;lt;QuestionID&amp;gt;13&amp;lt;/QuestionID&amp;gt;&lt;br /&gt;
         &amp;lt;QuestionnaireID&amp;gt;3&amp;lt;/QuestionnaireID&amp;gt;&lt;br /&gt;
         &amp;lt;Question&amp;gt;Date&amp;lt;/Question&amp;gt;&lt;br /&gt;
         &amp;lt;valueListID&amp;gt;0&amp;lt;/valueListID&amp;gt;&lt;br /&gt;
         &amp;lt;inputType&amp;gt;date&amp;lt;/inputType&amp;gt;&lt;br /&gt;
         &amp;lt;validation&amp;gt;valid_date&amp;lt;/validation&amp;gt;&lt;br /&gt;
         &amp;lt;category&amp;gt;What&amp;lt;/category&amp;gt;&lt;br /&gt;
         &amp;lt;enabled&amp;gt;1&amp;lt;/enabled&amp;gt;&lt;br /&gt;
         &amp;lt;order&amp;gt;0&amp;lt;/order&amp;gt;&lt;br /&gt;
         &amp;lt;Created&amp;gt;2011-03-04 01:10:09&amp;lt;/Created&amp;gt;&lt;br /&gt;
         &amp;lt;CreatedBy&amp;gt;ant&amp;lt;/CreatedBy&amp;gt;&lt;br /&gt;
         &amp;lt;Updated&amp;gt;2011-03-04 01:10:09&amp;lt;/Updated&amp;gt;&lt;br /&gt;
         &amp;lt;UpdatedBy&amp;gt;ant&amp;lt;/UpdatedBy&amp;gt;&lt;br /&gt;
     &amp;lt;/question&amp;gt;&lt;br /&gt;
 &amp;lt;/questions&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
==Fetching a Question&#039;s details==&lt;br /&gt;
 curl --url &amp;lt;Base URL&amp;gt;/&amp;lt;id&amp;gt; -u&amp;lt;username&amp;gt;:&amp;lt;password&amp;gt; -H Content-Type:text/xml&lt;br /&gt;
* id - The id of the Question&lt;br /&gt;
&lt;br /&gt;
This will return a single question in the format of:&lt;br /&gt;
 &amp;lt;question id=&amp;quot;12&amp;quot;&amp;gt;&lt;br /&gt;
     &amp;lt;QuestionID&amp;gt;12&amp;lt;/QuestionID&amp;gt;&lt;br /&gt;
     &amp;lt;QuestionnaireID&amp;gt;3&amp;lt;/QuestionnaireID&amp;gt;&lt;br /&gt;
     &amp;lt;Question&amp;gt;What is the question&amp;lt;/Question&amp;gt;&lt;br /&gt;
     &amp;lt;valueListID&amp;gt;83&amp;lt;/valueListID&amp;gt;&lt;br /&gt;
     &amp;lt;inputType&amp;gt;radio&amp;lt;/inputType&amp;gt;&lt;br /&gt;
     &amp;lt;validation&amp;gt;&amp;lt;/validation&amp;gt;&lt;br /&gt;
     &amp;lt;category&amp;gt;What&amp;lt;/category&amp;gt;&lt;br /&gt;
     &amp;lt;enabled&amp;gt;1&amp;lt;/enabled&amp;gt;&lt;br /&gt;
     &amp;lt;Created&amp;gt;2011-03-04 01:09:55&amp;lt;/Created&amp;gt;&lt;br /&gt;
     &amp;lt;CreatedBy&amp;gt;ant&amp;lt;/CreatedBy&amp;gt;&lt;br /&gt;
     &amp;lt;Updated&amp;gt;2011-03-04 01:09:55&amp;lt;/Updated&amp;gt;&lt;br /&gt;
     &amp;lt;UpdatedBy&amp;gt;ant&amp;lt;/UpdatedBy&amp;gt;&lt;br /&gt;
 &amp;lt;/question&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
==Creating a Single Question==&lt;br /&gt;
 curl --url &amp;lt;Base URL&amp;gt; -u&amp;lt;username&amp;gt;:&amp;lt;password&amp;gt; -H Content-Type:text/xml -X POST -d &#039;&amp;lt;xml&amp;gt;&#039;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;code&amp;gt;&amp;lt;xml&amp;gt;&amp;lt;/code&amp;gt; should be in the following format:&lt;br /&gt;
 &amp;lt;question&amp;gt;&lt;br /&gt;
     &amp;lt;Question&amp;gt;The question test...&amp;lt;/Question&amp;gt;&lt;br /&gt;
     &amp;lt;inputType&amp;gt;text&amp;lt;/inputType&amp;gt;&lt;br /&gt;
     &amp;lt;valueListID&amp;gt;0&amp;lt;/valueListID&amp;gt;&lt;br /&gt;
     &amp;lt;validation/&amp;gt;&lt;br /&gt;
     &amp;lt;category&amp;gt;General&amp;lt;/category&amp;gt;&lt;br /&gt;
 &amp;lt;/question&amp;gt;&lt;br /&gt;
&lt;br /&gt;
* Question - This should contain the wording for the question&lt;br /&gt;
* inputTypes - This can be ne of the following:&lt;br /&gt;
*# text&lt;br /&gt;
*# textare&lt;br /&gt;
*# date&lt;br /&gt;
*# time&lt;br /&gt;
*# number&lt;br /&gt;
*# select&lt;br /&gt;
*# selectother&lt;br /&gt;
*# checkselect&lt;br /&gt;
*# radio&lt;br /&gt;
* valueListID - refers to a [[Rest - Admin - Value Lists|value list]]. This is only used with multiple choice inputTypes&lt;br /&gt;
* category - This is the section title that the question should be grouped in&lt;br /&gt;
&lt;br /&gt;
===Validation Field===&lt;br /&gt;
This can contain values similar to those found in the validation field for structure objects. However, here is a more specific explanation of the various optionsyou can place into this field:&lt;br /&gt;
&lt;br /&gt;
* &#039;&#039;&#039;oneOf&#039;&#039;&#039;  - One of the questions are required to be answered.&lt;br /&gt;
* &#039;&#039;&#039;required_if&#039;&#039;&#039;  - The answer is required if condition met.&lt;br /&gt;
* &#039;&#039;&#039;required&#039;&#039;&#039; - The answer is required.&lt;br /&gt;
* &#039;&#039;&#039;valid_password&#039;&#039;&#039; - The answer field must contain a valid password as defined above&lt;br /&gt;
* &#039;&#039;&#039;valid_postcode&#039;&#039;&#039; - The answer field must contain a valid postcode.&lt;br /&gt;
* &#039;&#039;&#039;valid_email&#039;&#039;&#039; - The answer must contain a valid email address.&lt;br /&gt;
* &#039;&#039;&#039;valid_emails&#039;&#039;&#039;  - The answer must contain all valid email addresses.&lt;br /&gt;
* &#039;&#039;&#039;valid_url&#039;&#039;&#039; - The answer must contain a valid URL.&lt;br /&gt;
* &#039;&#039;&#039;real_url&#039;&#039;&#039; - The answer must contain a real URL.&lt;br /&gt;
* &#039;&#039;&#039;valid_ip&#039;&#039;&#039; - The answer must contain a valid IP.&lt;br /&gt;
* &#039;&#039;&#039;valid_date&#039;&#039;&#039; - The answer must contain a valid date.&lt;br /&gt;
* &#039;&#039;&#039;min_length[n]&#039;&#039;&#039; - The answer must be at least &#039;&#039;n&#039;&#039; characters in length.&lt;br /&gt;
* &#039;&#039;&#039;max_length[n]&#039;&#039;&#039; - The answer can not exceed &#039;&#039;n&#039;&#039; characters in length.&lt;br /&gt;
* &#039;&#039;&#039;exact_length[n]&#039;&#039;&#039; - The answer must be exactly &#039;&#039;n&#039;&#039; characters in length.&lt;br /&gt;
* &#039;&#039;&#039;alpha&#039;&#039;&#039; - The answer may only contain alphabetical characters.&lt;br /&gt;
* &#039;&#039;&#039;alpha_numeric&#039;&#039;&#039; - The answer may only contain alpha-numeric characters.&lt;br /&gt;
* &#039;&#039;&#039;alpha_dash&#039;&#039;&#039; - The answer may only contain alpha-numeric characters, underscores, and dashes.&lt;br /&gt;
* &#039;&#039;&#039;alpha_dot&#039;&#039;&#039; - The answer field may only contain alpha-numeric characters, and dots.&lt;br /&gt;
* &#039;&#039;&#039;numeric&#039;&#039;&#039; - The answer must contain only numbers.&lt;br /&gt;
* &#039;&#039;&#039;is_numeric&#039;&#039;&#039; - The answer must contain only numeric characters.&lt;br /&gt;
* &#039;&#039;&#039;is_numeric_non_zero&#039;&#039;&#039; - The answer must contain only numeric characters greater than zero.&lt;br /&gt;
* &#039;&#039;&#039;integer&#039;&#039;&#039; - The answer must contain an integer.&lt;br /&gt;
* &#039;&#039;&#039;is_natural&#039;&#039;&#039; - The answer must contain only positive numbers.&lt;br /&gt;
* &#039;&#039;&#039;is_natural_no_zero&#039;&#039;&#039; - The answer must contain a number greater than zero.&lt;br /&gt;
* &#039;&#039;&#039;range[min,max]&#039;&#039;&#039; - The answer is not within range.&lt;br /&gt;
* &#039;&#039;&#039;unique_username&#039;&#039;&#039; - The answer value is already assigned, please try another&lt;br /&gt;
* &#039;&#039;&#039;punique&#039;&#039;&#039; - The answer value already exists, within The, or another agency with the Programme&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;&#039;&#039;Note&#039;&#039;&#039; The following require further documentation (currently the wording isfor the error&#039;&#039;&lt;br /&gt;
* &#039;&#039;&#039;matches&#039;&#039;&#039; - The answer does not match any other Answer.&lt;br /&gt;
* &#039;&#039;&#039;nomatches&#039;&#039;&#039; - The answer matches the other answers.&lt;br /&gt;
* &#039;&#039;&#039;matches1M&#039;&#039;&#039; - The answer value matches none of the other answer values.&lt;br /&gt;
* &#039;&#039;&#039;nomatches1M&#039;&#039;&#039; - The answer value matches one of the other answer values.&lt;br /&gt;
* &#039;&#039;&#039;matchesM1&#039;&#039;&#039; - None of the answer values match this answer value.&lt;br /&gt;
* &#039;&#039;&#039;nomatchesM1&#039;&#039;&#039; - One of the answer values matches this answer field.&lt;br /&gt;
* &#039;&#039;&#039;matchesMM&#039;&#039;&#039; - None of the answer values match any of this answer values.&lt;br /&gt;
* &#039;&#039;&#039;nomatchesMM&#039;&#039;&#039; - Some of the answer values match some of this answer values.&lt;br /&gt;
&lt;br /&gt;
==Updating a Single Question==&lt;br /&gt;
 curl --url &amp;lt;Base URL&amp;gt;/&amp;lt;id&amp;gt; -u&amp;lt;username&amp;gt;:&amp;lt;password&amp;gt; -H Content-Type:text/xml -X PUT -d &#039;&amp;lt;xml&amp;gt;&#039;&lt;br /&gt;
* id - The id of the question&lt;br /&gt;
&lt;br /&gt;
The xml for updating a single question is exactly the same as the create xml.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
==Disable / Enable Questions==&lt;br /&gt;
 curl --url &amp;lt;Base URL&amp;gt;/&amp;lt;id&amp;gt;/enable -u&amp;lt;username&amp;gt;:&amp;lt;password&amp;gt; -H Content-Type:text/xml -X PUT -d &#039;&amp;lt;xml&amp;gt;&#039;&lt;br /&gt;
* id - The id of the question&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
To disable a question you need to send the following xml:&lt;br /&gt;
 &amp;lt;enable&amp;gt;0&amp;lt;/enable&amp;gt;&lt;br /&gt;
&#039;&#039;or&#039;&#039;&lt;br /&gt;
 &amp;lt;enable&amp;gt;false&amp;lt;/enable&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
To enable a question you need to send the following xml:&lt;br /&gt;
 &amp;lt;enable&amp;gt;1&amp;lt;/enable&amp;gt;&lt;br /&gt;
&#039;&#039;or&#039;&#039;&lt;br /&gt;
 &amp;lt;enable&amp;gt;true&amp;lt;/enable&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
==Creating / Updating Multiple Question==&lt;br /&gt;
 curl --url &amp;lt;Base URL&amp;gt; -u&amp;lt;username&amp;gt;:&amp;lt;password&amp;gt; -H Content-Type:text/xml -X [POST|PUT] -d &#039;&amp;lt;xml&amp;gt;&#039;&lt;br /&gt;
* id - The id of a Questionnaire&lt;br /&gt;
&lt;br /&gt;
This allows you to upload a complete questionnaire in one go&lt;br /&gt;
&lt;br /&gt;
&amp;lt;questions&amp;gt;&lt;br /&gt;
     &amp;lt;question id=&amp;quot;12&amp;quot;&amp;gt;&lt;br /&gt;
         &amp;lt;Question&amp;gt;Update question 12&amp;lt;/Question&amp;gt;&lt;br /&gt;
         &amp;lt;valueListID&amp;gt;83&amp;lt;/valueListID&amp;gt;&lt;br /&gt;
         &amp;lt;inputType&amp;gt;radio&amp;lt;/inputType&amp;gt;&lt;br /&gt;
         &amp;lt;validation&amp;gt;&amp;lt;/validation&amp;gt;&lt;br /&gt;
         &amp;lt;category&amp;gt;What&amp;lt;/category&amp;gt;&lt;br /&gt;
     &amp;lt;/question&amp;gt;&lt;br /&gt;
 ...&lt;br /&gt;
    &amp;lt;question&amp;gt;&lt;br /&gt;
         &amp;lt;Question&amp;gt;Add a new question&amp;lt;/Question&amp;gt;&lt;br /&gt;
         &amp;lt;inputType&amp;gt;text&amp;lt;/inputType&amp;gt;&lt;br /&gt;
         &amp;lt;valueListID&amp;gt;0&amp;lt;/valueListID&amp;gt;&lt;br /&gt;
         &amp;lt;validation/&amp;gt;&lt;br /&gt;
         &amp;lt;category&amp;gt;General&amp;lt;/category&amp;gt;&lt;br /&gt;
     &amp;lt;/question&amp;gt;&lt;br /&gt;
 &amp;lt;/questions&amp;gt;&lt;br /&gt;
&lt;br /&gt;
By specifying the id attribute for the question, it will update the question rather than create a new one.&lt;br /&gt;
&lt;br /&gt;
It is recommended that you stip to using the PUT method for this, as in the future we make make POST and method to replace all the questions on a questionnaire&lt;/div&gt;</summary>
		<author><name>Wikiadmin</name></author>
	</entry>
	<entry>
		<id>https://www.substance.net/views-api-docs/index.php?title=Rest_-_Evidence_-_Questionnaires&amp;diff=277</id>
		<title>Rest - Evidence - Questionnaires</title>
		<link rel="alternate" type="text/html" href="https://www.substance.net/views-api-docs/index.php?title=Rest_-_Evidence_-_Questionnaires&amp;diff=277"/>
		<updated>2016-02-26T13:07:57Z</updated>

		<summary type="html">&lt;p&gt;Wikiadmin: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;==Purpose==&lt;br /&gt;
&lt;br /&gt;
This API is used for creating, editing and deleting questionnaires from the Views system. It is &#039;&#039;&#039;not&#039;&#039;&#039; a way to submit questionnaire answer data. That is done via the other various sections.&lt;br /&gt;
&lt;br /&gt;
===Base URL===&lt;br /&gt;
https://app.viewsapp.net/api/restful/evidence/questionnaires&lt;br /&gt;
&lt;br /&gt;
===Schema===&lt;br /&gt;
&amp;lt;nowiki&amp;gt;https://app.viewsapp.net/api/restful/evidence/questionnaires/schema(.xml|.json|.xsd)&amp;lt;/nowiki&amp;gt;&lt;br /&gt;
&lt;br /&gt;
==Searching for available Questionnaires==&lt;br /&gt;
 curl --url &amp;lt;Base URL&amp;gt;/search?q=&amp;lt;query&amp;gt; -u&amp;lt;username&amp;gt;:&amp;lt;password&amp;gt; -H Content-Type:text/xml &lt;br /&gt;
* query - This is a text string to use to search for in the venues records&lt;br /&gt;
&lt;br /&gt;
You can search for any field for a specific value by setting the field as a parameter. Please refer to the schema for field names.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
==Fetching a Questionnaire&#039;s details==&lt;br /&gt;
 curl --url &amp;lt;Base URL&amp;gt;/&amp;lt;id&amp;gt; -u&amp;lt;username&amp;gt;:&amp;lt;password&amp;gt; -H Content-Type:text/xml&lt;br /&gt;
* id - The id of the Questionnaire&lt;br /&gt;
&lt;br /&gt;
This will also return all enabled questions for the specified questionnaire.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
==Creating a Questionnaire==&lt;br /&gt;
 curl --url &amp;lt;Base URL&amp;gt; -u&amp;lt;username&amp;gt;:&amp;lt;password&amp;gt; -H Content-Type:text/xml -X POST -d &#039;&amp;lt;xml&amp;gt;&#039;&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;questionnaire&amp;gt;&lt;br /&gt;
     &amp;lt;Title&amp;gt;Questionnaire Title&amp;lt;/Title&amp;gt;&lt;br /&gt;
     &amp;lt;Description&amp;gt;A description of the questionnaire&amp;lt;/Description&amp;gt;&lt;br /&gt;
 &amp;lt;/questionnaire&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Currently the creation of questionnaires is a two stage process. Create the questionnaire overview and then add the questions. It is possible that we will in the future, add the ability to submit a complete questionnaire data structure from this call. For more information about applying questions to a Questionnaire, please refer to the [[Rest - Evidence - Questionnaires - Questions|Questionnaire - Questions]] API&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
==Updating a Questnnaire==&lt;br /&gt;
 curl --url &amp;lt;Base URL&amp;gt;/&amp;lt;id&amp;gt; -u&amp;lt;username&amp;gt;:&amp;lt;password&amp;gt; -H Content-Type:text/xml -X PUT -d &#039;&amp;lt;xml&amp;gt;&#039;&lt;br /&gt;
* id - The id of a Questionnaire&lt;br /&gt;
&lt;br /&gt;
By passing the the same xml structure as creating a questionnaire, you are able to update the overview information.&lt;br /&gt;
To archive the questionnaire, use the following:&lt;br /&gt;
&lt;br /&gt;
 curl --url &amp;lt;Base URL&amp;gt;/&amp;lt;id&amp;gt;/archive -u&amp;lt;username&amp;gt;:&amp;lt;password&amp;gt; -H Content-Type:text/xml -X PUT -d &#039;&amp;lt;xml&amp;gt;&#039;&lt;br /&gt;
&lt;br /&gt;
and pass the following XML:&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;archive&amp;gt;1&amp;lt;/archive&amp;gt;&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;archive&amp;gt;0&amp;lt;/archive&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
==Deleting a Questionnaire==&lt;br /&gt;
&amp;lt;font color=&amp;quot;red&amp;quot;&amp;gt;&#039;&#039;&#039;This method will completely wipe the question and all associated data, including the answers. You should be very careful when using this method.&#039;&#039;&#039;&amp;lt;/font&amp;gt;&lt;br /&gt;
 curl --url &amp;lt;Base URL&amp;gt;/&amp;lt;id&amp;gt; -u&amp;lt;username&amp;gt;:&amp;lt;password&amp;gt; -H Content-Type:text/xml -X DELETE&lt;/div&gt;</summary>
		<author><name>Wikiadmin</name></author>
	</entry>
	<entry>
		<id>https://www.substance.net/views-api-docs/index.php?title=Rest_-_Work_-_Agency_Projects_-_Outcomes&amp;diff=276</id>
		<title>Rest - Work - Agency Projects - Outcomes</title>
		<link rel="alternate" type="text/html" href="https://www.substance.net/views-api-docs/index.php?title=Rest_-_Work_-_Agency_Projects_-_Outcomes&amp;diff=276"/>
		<updated>2016-02-26T13:07:35Z</updated>

		<summary type="html">&lt;p&gt;Wikiadmin: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;==Purpose==&lt;br /&gt;
&lt;br /&gt;
Used for administering the association of outcomes with agency projects in the Views system.&lt;br /&gt;
&lt;br /&gt;
===Base URL===&lt;br /&gt;
&amp;lt;nowiki&amp;gt;https://app.viewsapp.net/api/restful/work/agencyprojects/id/outcomes&amp;lt;/nowiki&amp;gt;&lt;br /&gt;
* &#039;&#039;&#039;id&#039;&#039;&#039; - This is the id of the agency project&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Note:&#039;&#039;&#039; If the Agency Project has been archived, this API becomes read only.&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
===Getting the list of outcomes===&lt;br /&gt;
 curl --url &amp;lt;Base URL&amp;gt; -u&amp;lt;username&amp;gt;:&amp;lt;password&amp;gt; -H Content-Type:text/xml&lt;br /&gt;
&lt;br /&gt;
This will return a list of outcomes that are associated with the agency project.&lt;br /&gt;
 &amp;lt;?xml version=&amp;quot;1.0&amp;quot; encoding=&amp;quot;utf-8&amp;quot;?&amp;gt;&lt;br /&gt;
 &amp;lt;agencyproject id=&amp;quot;1&amp;quot;&amp;gt;&lt;br /&gt;
     &amp;lt;outcomes&amp;gt;&lt;br /&gt;
         &amp;lt;outcome id=&amp;quot;2&amp;quot;&amp;gt;Outcome Hits Sported&amp;lt;/outcome&amp;gt;&lt;br /&gt;
         &amp;lt;outcome id=&amp;quot;5&amp;quot;&amp;gt;Outcome that hist sported not obesity&amp;lt;/outcome&amp;gt;&lt;br /&gt;
     &amp;lt;/outcomes&amp;gt;&lt;br /&gt;
 &amp;lt;/agencyproject&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
===Adding outcomes to an Agency Project===&lt;br /&gt;
You can add a single outcome via the following:&lt;br /&gt;
 curl --url &amp;lt;Base URL&amp;gt;/&amp;lt;sid&amp;gt; -u&amp;lt;username&amp;gt;:&amp;lt;password&amp;gt; -H Content-Type:text/xml -X PUT&lt;br /&gt;
*&#039;&#039;&#039;sid&#039;&#039;&#039; - The ID of the outcome to add&lt;br /&gt;
&lt;br /&gt;
You can also upload a a list of outcomes to add to the agency project  via the following URL&lt;br /&gt;
 curl --url &amp;lt;Base URL&amp;gt; -u&amp;lt;username&amp;gt;:&amp;lt;password&amp;gt; -H Content-Type:text/xml -X PUT&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;outcomes&amp;gt;&lt;br /&gt;
     &amp;lt;outcome&amp;gt;1&amp;lt;/outcome&amp;gt;&lt;br /&gt;
     &amp;lt;outcome&amp;gt;2&amp;lt;/outcome&amp;gt;&lt;br /&gt;
     &amp;lt;outcome&amp;gt;3&amp;lt;/outcome&amp;gt;&lt;br /&gt;
 &amp;lt;/outcomes&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Used for administering participant registrations on outcomes in the Views system.&lt;br /&gt;
&lt;br /&gt;
===Removing an outcome from an Agency Project===&lt;br /&gt;
You can remove a single outcome from an agency project  via the following:&lt;br /&gt;
 curl --url &amp;lt;Base URL&amp;gt;/&amp;lt;sid&amp;gt; -u&amp;lt;username&amp;gt;:&amp;lt;password&amp;gt; -H Content-Type:text/xml -X DELETE&lt;br /&gt;
*&#039;&#039;&#039;sid&#039;&#039;&#039; - The ID of the outcome to add&lt;br /&gt;
&lt;br /&gt;
You can also upload a a list of outcomes to remove from the agency project via the following URL&lt;br /&gt;
 curl --url &amp;lt;Base URL&amp;gt; -u&amp;lt;username&amp;gt;:&amp;lt;password&amp;gt; -H Content-Type:text/xml -X DELETE&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;outcomes&amp;gt;&lt;br /&gt;
     &amp;lt;outcome&amp;gt;1&amp;lt;/outcome&amp;gt;&lt;br /&gt;
     &amp;lt;outcome&amp;gt;2&amp;lt;/outcome&amp;gt;&lt;br /&gt;
     &amp;lt;outcome&amp;gt;3&amp;lt;/outcome&amp;gt;&lt;br /&gt;
 &amp;lt;/outcomes&amp;gt;&lt;/div&gt;</summary>
		<author><name>Wikiadmin</name></author>
	</entry>
	<entry>
		<id>https://www.substance.net/views-api-docs/index.php?title=Rest_-_Work_-_Agency_Projects_-_Objectives&amp;diff=275</id>
		<title>Rest - Work - Agency Projects - Objectives</title>
		<link rel="alternate" type="text/html" href="https://www.substance.net/views-api-docs/index.php?title=Rest_-_Work_-_Agency_Projects_-_Objectives&amp;diff=275"/>
		<updated>2016-02-26T13:07:16Z</updated>

		<summary type="html">&lt;p&gt;Wikiadmin: /* Purpose */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;==Purpose==&lt;br /&gt;
&lt;br /&gt;
Used for administering the association of objectives with agency projects in the Views system.&lt;br /&gt;
&lt;br /&gt;
===Base URL===&lt;br /&gt;
&amp;lt;nowiki&amp;gt;https://app.viewsapp.net/api/restful/work/agencyprojects/id/objectives&amp;lt;/nowiki&amp;gt;&lt;br /&gt;
* &#039;&#039;&#039;id&#039;&#039;&#039; - This is the id of the agency project&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Note:&#039;&#039;&#039; If the Agency Project has been archived, this API becomes read only.&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
===Getting the list of objectives===&lt;br /&gt;
 curl --url &amp;lt;Base URL&amp;gt; -u&amp;lt;username&amp;gt;:&amp;lt;password&amp;gt; -H Content-Type:text/xml&lt;br /&gt;
&lt;br /&gt;
This will return a list of objectives that are associated with the agency project.&lt;br /&gt;
 &amp;lt;?xml version=&amp;quot;1.0&amp;quot; encoding=&amp;quot;utf-8&amp;quot;?&amp;gt;&lt;br /&gt;
 &amp;lt;agencyproject id=&amp;quot;1&amp;quot;&amp;gt;&lt;br /&gt;
     &amp;lt;objectives&amp;gt;&lt;br /&gt;
         &amp;lt;objective id=&amp;quot;2&amp;quot;&amp;gt;Objective Hits Sported&amp;lt;/objective&amp;gt;&lt;br /&gt;
         &amp;lt;objective id=&amp;quot;5&amp;quot;&amp;gt;Objective that hist sported not obesity&amp;lt;/objective&amp;gt;&lt;br /&gt;
     &amp;lt;/objectives&amp;gt;&lt;br /&gt;
 &amp;lt;/agencyproject&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
===Adding objectives to an Agency Project===&lt;br /&gt;
You can add a single objective via the following:&lt;br /&gt;
 curl --url &amp;lt;Base URL&amp;gt;/&amp;lt;sid&amp;gt; -u&amp;lt;username&amp;gt;:&amp;lt;password&amp;gt; -H Content-Type:text/xml -X PUT&lt;br /&gt;
*&#039;&#039;&#039;sid&#039;&#039;&#039; - The ID of the objective to add&lt;br /&gt;
&lt;br /&gt;
You can also upload a a list of objectives to add to the agency project  via the following URL&lt;br /&gt;
 curl --url &amp;lt;Base URL&amp;gt; -u&amp;lt;username&amp;gt;:&amp;lt;password&amp;gt; -H Content-Type:text/xml -X PUT&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;objectives&amp;gt;&lt;br /&gt;
     &amp;lt;objective&amp;gt;1&amp;lt;/objective&amp;gt;&lt;br /&gt;
     &amp;lt;objective&amp;gt;2&amp;lt;/objective&amp;gt;&lt;br /&gt;
     &amp;lt;objective&amp;gt;3&amp;lt;/objective&amp;gt;&lt;br /&gt;
 &amp;lt;/objectives&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Used for administering participant registrations on objectives in the Views system.&lt;br /&gt;
&lt;br /&gt;
===Removing an objective from an Agency Project===&lt;br /&gt;
You can remove a single objective from an agency project  via the following:&lt;br /&gt;
 curl --url &amp;lt;Base URL&amp;gt;/&amp;lt;sid&amp;gt; -u&amp;lt;username&amp;gt;:&amp;lt;password&amp;gt; -H Content-Type:text/xml -X DELETE&lt;br /&gt;
*&#039;&#039;&#039;sid&#039;&#039;&#039; - The ID of the objective to add&lt;br /&gt;
&lt;br /&gt;
You can also upload a a list of objectives to remove from the agency project via the following URL&lt;br /&gt;
 curl --url &amp;lt;Base URL&amp;gt; -u&amp;lt;username&amp;gt;:&amp;lt;password&amp;gt; -H Content-Type:text/xml -X DELETE&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;objectives&amp;gt;&lt;br /&gt;
     &amp;lt;objective&amp;gt;1&amp;lt;/objective&amp;gt;&lt;br /&gt;
     &amp;lt;objective&amp;gt;2&amp;lt;/objective&amp;gt;&lt;br /&gt;
     &amp;lt;objective&amp;gt;3&amp;lt;/objective&amp;gt;&lt;br /&gt;
 &amp;lt;/objectives&amp;gt;&lt;/div&gt;</summary>
		<author><name>Wikiadmin</name></author>
	</entry>
	<entry>
		<id>https://www.substance.net/views-api-docs/index.php?title=Rest_-_Work_-_Agency_Projects_-_Session_Groups&amp;diff=274</id>
		<title>Rest - Work - Agency Projects - Session Groups</title>
		<link rel="alternate" type="text/html" href="https://www.substance.net/views-api-docs/index.php?title=Rest_-_Work_-_Agency_Projects_-_Session_Groups&amp;diff=274"/>
		<updated>2016-02-26T13:06:57Z</updated>

		<summary type="html">&lt;p&gt;Wikiadmin: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;==Purpose==&lt;br /&gt;
&lt;br /&gt;
Used for administering the association of session groups with agency projects in the Views system.&lt;br /&gt;
&lt;br /&gt;
===Base URL===&lt;br /&gt;
&amp;lt;nowiki&amp;gt;https://app.viewsapp.net/api/restful/work/agencyprojects/id/sessiongroups&amp;lt;/nowiki&amp;gt;&lt;br /&gt;
* &#039;&#039;&#039;id&#039;&#039;&#039; - This is the id of the agency project&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Note:&#039;&#039;&#039; If the Agency Project has been archived, this API becomes read only.&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
===Getting the list of session groups===&lt;br /&gt;
 curl --url &amp;lt;Base URL&amp;gt; -u&amp;lt;username&amp;gt;:&amp;lt;password&amp;gt; -H Content-Type:text/xml&lt;br /&gt;
&lt;br /&gt;
This will return a list of session groups that are associated with the agency project.&lt;br /&gt;
&lt;br /&gt;
===Adding session groups to an Agency Project===&lt;br /&gt;
You can add a single session group via the following:&lt;br /&gt;
 curl --url &amp;lt;Base URL&amp;gt;/&amp;lt;sid&amp;gt; -u&amp;lt;username&amp;gt;:&amp;lt;password&amp;gt; -H Content-Type:text/xml -X PUT&lt;br /&gt;
*&#039;&#039;&#039;sid&#039;&#039;&#039; - The ID of the session group to add&lt;br /&gt;
&lt;br /&gt;
You can also upload a a list of session groups to add to the agency project  via the following URL&lt;br /&gt;
 curl --url &amp;lt;Base URL&amp;gt; -u&amp;lt;username&amp;gt;:&amp;lt;password&amp;gt; -H Content-Type:text/xml -X PUT&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;sessiongroups&amp;gt;&lt;br /&gt;
     &amp;lt;sessiongroup&amp;gt;1&amp;lt;/sessiongroup&amp;gt;&lt;br /&gt;
     &amp;lt;sessiongroup&amp;gt;2&amp;lt;/sessiongroup&amp;gt;&lt;br /&gt;
     &amp;lt;sessiongroup&amp;gt;3&amp;lt;/sessiongroup&amp;gt;&lt;br /&gt;
 &amp;lt;/sessiongroups&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Used for administering participant registrations on session groups in the Views system.&lt;br /&gt;
&lt;br /&gt;
===Removing a session group from an Agency Project===&lt;br /&gt;
You can remove a single session group from an agency project  via the following:&lt;br /&gt;
 curl --url &amp;lt;Base URL&amp;gt;/&amp;lt;sid&amp;gt; -u&amp;lt;username&amp;gt;:&amp;lt;password&amp;gt; -H Content-Type:text/xml -X DELETE&lt;br /&gt;
*&#039;&#039;&#039;sid&#039;&#039;&#039; - The ID of the session group to add&lt;br /&gt;
&lt;br /&gt;
You can also upload a a list of session groups to remove from the agency project via the following URL&lt;br /&gt;
 curl --url &amp;lt;Base URL&amp;gt; -u&amp;lt;username&amp;gt;:&amp;lt;password&amp;gt; -H Content-Type:text/xml -X DELETE&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;sessiongroups&amp;gt;&lt;br /&gt;
     &amp;lt;sessiongroup&amp;gt;1&amp;lt;/sessiongroup&amp;gt;&lt;br /&gt;
     &amp;lt;sessiongroup&amp;gt;2&amp;lt;/sessiongroup&amp;gt;&lt;br /&gt;
     &amp;lt;sessiongroup&amp;gt;3&amp;lt;/sessiongroup&amp;gt;&lt;br /&gt;
 &amp;lt;/sessiongroups&amp;gt;&lt;/div&gt;</summary>
		<author><name>Wikiadmin</name></author>
	</entry>
	<entry>
		<id>https://www.substance.net/views-api-docs/index.php?title=Rest_-_Work_-_Agency_Projects&amp;diff=273</id>
		<title>Rest - Work - Agency Projects</title>
		<link rel="alternate" type="text/html" href="https://www.substance.net/views-api-docs/index.php?title=Rest_-_Work_-_Agency_Projects&amp;diff=273"/>
		<updated>2016-02-26T13:06:42Z</updated>

		<summary type="html">&lt;p&gt;Wikiadmin: /* Purpose */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;==Purpose==&lt;br /&gt;
&lt;br /&gt;
Used for creating, editing and deleting Agency Projects from the Views system.&lt;br /&gt;
&lt;br /&gt;
===Base URL===&lt;br /&gt;
https://app.viewsapp.net/api/restful/work/agencyprojects&lt;br /&gt;
&lt;br /&gt;
===Schema===&lt;br /&gt;
&amp;lt;nowiki&amp;gt;https://app.viewsapp.net/api/restful/work/agencyprojects/schema(.xml|.json|.xsd)&amp;lt;/nowiki&amp;gt;&lt;br /&gt;
&lt;br /&gt;
==Creating Agency Projects==&lt;br /&gt;
&lt;br /&gt;
Once you have created your data file, you can send it using the following:&lt;br /&gt;
&lt;br /&gt;
 curl --url &amp;lt;Base URL&amp;gt; -u&amp;lt;username&amp;gt;:&amp;lt;password&amp;gt; -H Content-Type:text/xml -X POST -d &amp;quot;&amp;lt;xml&amp;gt;&amp;quot;&lt;br /&gt;
&lt;br /&gt;
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.&lt;br /&gt;
&lt;br /&gt;
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.&lt;br /&gt;
&lt;br /&gt;
==Fetching an Agency Project==&lt;br /&gt;
 curl --url &amp;lt;Base URL&amp;gt;/&amp;lt;id&amp;gt; -u&amp;lt;username&amp;gt;:&amp;lt;password&amp;gt; -H Content-Type:text/xml&lt;br /&gt;
&lt;br /&gt;
==Searching for Agency Projects==&lt;br /&gt;
 curl --url &amp;lt;Base URL&amp;gt;/search?q=&amp;lt;query&amp;gt; -u&amp;lt;username&amp;gt;:&amp;lt;password&amp;gt; -H Content-Type:text/xml &lt;br /&gt;
* query - This is a text string to use to search for in the agency project records&lt;br /&gt;
&lt;br /&gt;
You can search for any field for a specific value by setting the field as a parameter. Please refer to the schema for field names.&lt;br /&gt;
&lt;br /&gt;
There are also a series of fields that you use -from and -to modifiers to express a range:&lt;br /&gt;
* Created - yyyy-mm-dd&lt;br /&gt;
* Updated - yyyy-mm-dd&lt;br /&gt;
* Archived - yyyy-mm-dd&lt;br /&gt;
&lt;br /&gt;
==Updating an Agency Project==&lt;br /&gt;
 curl --url &amp;lt;Base URL&amp;gt;/&amp;lt;id&amp;gt; -u&amp;lt;username&amp;gt;:&amp;lt;password&amp;gt; -H Content-Type:text/xml -X PUT -d &amp;quot;&amp;lt;xml&amp;gt;&amp;quot;&lt;br /&gt;
* id - The ID of the agency project&lt;br /&gt;
&lt;br /&gt;
The XML should be in the same format as the create XML. &lt;br /&gt;
&lt;br /&gt;
==Archiving an Agency Project==&lt;br /&gt;
 curl --url &amp;lt;Base URL&amp;gt;/&amp;lt;id&amp;gt;/archive -u&amp;lt;username&amp;gt;:&amp;lt;password&amp;gt; -H Content-Type:text/xml -X PUT -d &#039;&amp;lt;status&amp;gt;1&amp;lt;/status&amp;gt;&#039;&lt;br /&gt;
* id - The ID of the agency project&lt;br /&gt;
&lt;br /&gt;
This will set the archive flag on an Agency project. If you set the status to 0, then it will remove the archive flag.&lt;br /&gt;
&lt;br /&gt;
==Deleting an Agency Project==&lt;br /&gt;
 curl --url &amp;lt;Base URL&amp;gt;/&amp;lt;id&amp;gt; -u&amp;lt;username&amp;gt;:&amp;lt;password&amp;gt; -H Content-Type:text/xml -X DELETE&lt;br /&gt;
* id - The ID of the agencyprojects&lt;br /&gt;
&lt;br /&gt;
This should be used with great care as it will permenently delete an Agency Projects record.&lt;/div&gt;</summary>
		<author><name>Wikiadmin</name></author>
	</entry>
	<entry>
		<id>https://www.substance.net/views-api-docs/index.php?title=Rest_-_Work_-_Session_Groups_-_Session_Questionnaires&amp;diff=272</id>
		<title>Rest - Work - Session Groups - Session Questionnaires</title>
		<link rel="alternate" type="text/html" href="https://www.substance.net/views-api-docs/index.php?title=Rest_-_Work_-_Session_Groups_-_Session_Questionnaires&amp;diff=272"/>
		<updated>2016-02-26T13:06:23Z</updated>

		<summary type="html">&lt;p&gt;Wikiadmin: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;==Purpose==&lt;br /&gt;
&lt;br /&gt;
Used for submitting answer sets to questionnaires against sessions and for retrieving the details of answered questionnaires that have been submitted against a participant. This is only really a filtered version of the [[Rest - Evidence - Questionnaires - Answers|Questionnaires - Answers API]]&lt;br /&gt;
&lt;br /&gt;
===Base URL===&lt;br /&gt;
&amp;lt;nowiki&amp;gt;https://app.viewsapp.net/api/restful/work/sessiongroups/sessions/&amp;lt;id&amp;gt;/questionnaires&amp;lt;/nowiki&amp;gt;&lt;br /&gt;
* id - This is the session id&lt;br /&gt;
&lt;br /&gt;
===Schema===&lt;br /&gt;
For details of the schemas, please refer to [[Rest - Evidence - Questionnaires - Answers]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
==Fetching a list of answer sets==&lt;br /&gt;
The default call will return a list of questionnaires (answer sets) that have been recorded against the participant&lt;br /&gt;
 curl --url &amp;lt;Base URL&amp;gt; -u&amp;lt;username&amp;gt;:&amp;lt;password&amp;gt; -H Content-Type:text/xml&lt;br /&gt;
&lt;br /&gt;
This will return data similar to the following:&lt;br /&gt;
 &amp;lt;answersets count=&amp;quot;3&amp;quot;&amp;gt;&lt;br /&gt;
     &amp;lt;answerset id=&amp;quot;13&amp;quot; questionnaireid=&amp;quot;3&amp;quot;&amp;gt;&lt;br /&gt;
         &amp;lt;EntityType&amp;gt;Person&amp;lt;/EntityType&amp;gt;&lt;br /&gt;
         &amp;lt;EntityID&amp;gt;1&amp;lt;/EntityID&amp;gt;&lt;br /&gt;
         &amp;lt;TargetType&amp;gt;Session&amp;lt;/TargetType&amp;gt;&lt;br /&gt;
         &amp;lt;TargetID&amp;gt;68&amp;lt;/TargetID&amp;gt;&lt;br /&gt;
         &amp;lt;Date&amp;gt;2012-07-31T10:00:00&amp;lt;/Date&amp;gt;&lt;br /&gt;
         &amp;lt;QuestionnaireID&amp;gt;14&amp;lt;/QuestionnaireID&amp;gt;&lt;br /&gt;
         &amp;lt;AnswerSetID&amp;gt;1&amp;lt;/AnswerSetID&amp;gt;&lt;br /&gt;
         &amp;lt;Questionnaire&amp;gt;Session Attendance Questionnaire&amp;lt;/Questionnaire&amp;gt;&lt;br /&gt;
     &amp;lt;/answerset&amp;gt;&lt;br /&gt;
     &amp;lt;answerset id=&amp;quot;14&amp;quot; questionnaireid=&amp;quot;4&amp;quot;&amp;gt;&lt;br /&gt;
         &amp;lt;EntityType&amp;gt;Session&amp;lt;/EntityType&amp;gt;&lt;br /&gt;
         &amp;lt;EntityID&amp;gt;68&amp;lt;/EntityID&amp;gt;&lt;br /&gt;
         &amp;lt;TargetType&amp;gt;Session&amp;lt;/TargetType&amp;gt;&lt;br /&gt;
         &amp;lt;TargetID&amp;gt;68&amp;lt;/TargetID&amp;gt;&lt;br /&gt;
         &amp;lt;Date&amp;gt;2012-05-04T10:11:00&amp;lt;/Date&amp;gt;&lt;br /&gt;
         &amp;lt;QuestionnaireID&amp;gt;14&amp;lt;/QuestionnaireID&amp;gt;&lt;br /&gt;
         &amp;lt;AnswerSetID&amp;gt;4&amp;lt;/AnswerSetID&amp;gt;&lt;br /&gt;
         &amp;lt;Questionnaire&amp;gt;Questionnaire about the session&amp;lt;/Questionnaire&amp;gt;&lt;br /&gt;
     &amp;lt;/answerset&amp;gt;&lt;br /&gt;
     ...&lt;br /&gt;
 &amp;lt;/answersets&amp;gt;&lt;br /&gt;
&lt;br /&gt;
If you are only interested in a particular questionnaire, you should us the following:&lt;br /&gt;
 curl --url &amp;lt;Base URL&amp;gt;/&amp;lt;questionnairId&amp;gt; -u&amp;lt;username&amp;gt;:&amp;lt;password&amp;gt; -H Content-Type:text/xml&lt;br /&gt;
&lt;br /&gt;
This will return data similar to the following:&lt;br /&gt;
 &amp;lt;answersets count=&amp;quot;1&amp;quot;&amp;gt;&lt;br /&gt;
     &amp;lt;answerset id=&amp;quot;13&amp;quot; questionnaireid=&amp;quot;3&amp;quot;&amp;gt;&lt;br /&gt;
         &amp;lt;EntityType&amp;gt;Person&amp;lt;/EntityType&amp;gt;&lt;br /&gt;
         &amp;lt;EntityID&amp;gt;1&amp;lt;/EntityID&amp;gt;&lt;br /&gt;
         &amp;lt;TargetType&amp;gt;Session&amp;lt;/TargetType&amp;gt;&lt;br /&gt;
         &amp;lt;TargetID&amp;gt;68&amp;lt;/TargetID&amp;gt;&lt;br /&gt;
         &amp;lt;Date&amp;gt;2012-07-31T10:00:00&amp;lt;/Date&amp;gt;&lt;br /&gt;
         &amp;lt;QuestionnaireID&amp;gt;14&amp;lt;/QuestionnaireID&amp;gt;&lt;br /&gt;
         &amp;lt;AnswerSetID&amp;gt;1&amp;lt;/AnswerSetID&amp;gt;&lt;br /&gt;
         &amp;lt;Questionnaire&amp;gt;Session Attendance Questionnaire&amp;lt;/Questionnaire&amp;gt;&lt;br /&gt;
     &amp;lt;/answerset&amp;gt;&lt;br /&gt;
 &amp;lt;/answersets&amp;gt;&lt;br /&gt;
&lt;br /&gt;
The results are order by the most recent first. This means to get the latest version of a questionnaire, you would only need to fetch the first result.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
==Fetching the answers of a given questionnaire==&lt;br /&gt;
 curl --url &amp;lt;Base URL&amp;gt;/&amp;lt;questionnairId&amp;gt;/&amp;lt;setId&amp;gt; -u&amp;lt;username&amp;gt;:&amp;lt;password&amp;gt; -H Content-Type:text/xml&lt;br /&gt;
* questionnaireId - This is the id of the questionnaire&lt;br /&gt;
* setId - This is the id of the Answers Set you want to retrieve&lt;br /&gt;
&lt;br /&gt;
It&#039;s will return something along the lines of&lt;br /&gt;
 &amp;lt;answerset questionaireid=&amp;quot;3&amp;quot; id=&amp;quot;13&amp;quot;&amp;gt;&lt;br /&gt;
     &amp;lt;EntityType&amp;gt;Person&amp;lt;/EntityType&amp;gt;&lt;br /&gt;
     &amp;lt;EntityID&amp;gt;1&amp;lt;/EntityID&amp;gt;&lt;br /&gt;
     &amp;lt;TargetType&amp;gt;Session&amp;lt;/TargetType&amp;gt;&lt;br /&gt;
     &amp;lt;TargetID&amp;gt;68&amp;lt;/TargetID&amp;gt;&lt;br /&gt;
     &amp;lt;Date&amp;gt;2012-07-31T10:00:00&amp;lt;/Date&amp;gt;&lt;br /&gt;
     &amp;lt;answers count=&amp;quot;5&amp;quot;&amp;gt;&lt;br /&gt;
         &amp;lt;answer id=&amp;quot;23&amp;quot;&amp;gt;&lt;br /&gt;
             &amp;lt;QuestionID&amp;gt;25&amp;lt;/QuestionID&amp;gt;&lt;br /&gt;
             &amp;lt;Answer&amp;gt;On time&amp;lt;/Answer&amp;gt;&lt;br /&gt;
         &amp;lt;/answer&amp;gt;&lt;br /&gt;
         &amp;lt;answer id=&amp;quot;24&amp;quot;&amp;gt;&lt;br /&gt;
             &amp;lt;QuestionID&amp;gt;25&amp;lt;/QuestionID&amp;gt;&lt;br /&gt;
             &amp;lt;Answer&amp;gt;Tidy&amp;lt;/Answer&amp;gt;&lt;br /&gt;
         &amp;lt;/answer&amp;gt;&lt;br /&gt;
         &amp;lt;answer id=&amp;quot;25&amp;quot;&amp;gt;&lt;br /&gt;
             &amp;lt;QuestionID&amp;gt;25&amp;lt;/QuestionID&amp;gt;&lt;br /&gt;
             &amp;lt;Answer&amp;gt;Yes&amp;lt;/Answer&amp;gt;&lt;br /&gt;
         &amp;lt;/answer&amp;gt;&lt;br /&gt;
         ...&lt;br /&gt;
     &amp;lt;/answers&amp;gt;&lt;br /&gt;
 &amp;lt;/answerset&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
==Fetching a single answer from a questionnaire==&lt;br /&gt;
 curl --url &amp;lt;Base URL&amp;gt;/&amp;lt;questionnairId&amp;gt;/&amp;lt;setId&amp;gt;/&amp;lt;questionId&amp;gt; -u&amp;lt;username&amp;gt;:&amp;lt;password&amp;gt; -H Content-Type:text/xml&lt;br /&gt;
* questionnaireId - This is the id of the questionnaire&lt;br /&gt;
* setId - This is the id of the Answers Set you want to retrieve&lt;br /&gt;
* questionId - This is the id of the question you want the answer for&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;answer id=&amp;quot;78&amp;quot;&amp;gt;&lt;br /&gt;
     &amp;lt;QuestionnaireID&amp;gt;3&amp;lt;/QuestionnaireID&amp;gt;&lt;br /&gt;
     &amp;lt;AnswerSetID&amp;gt;13&amp;lt;/AnswerSetID&amp;gt;&lt;br /&gt;
     &amp;lt;QuestionID&amp;gt;25&amp;lt;/QuestionID&amp;gt;&lt;br /&gt;
     &amp;lt;Answer&amp;gt;Yes&amp;lt;/Answer&amp;gt;&lt;br /&gt;
 &amp;lt;/answer&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
==Creating a new Answer Set==&lt;br /&gt;
 curl --url &amp;lt;Base URL&amp;gt;/&amp;lt;questionnairId&amp;gt; -u&amp;lt;username&amp;gt;:&amp;lt;password&amp;gt; -H Content-Type:text/xml -X POST -d &#039;&amp;lt;xml&amp;gt;&#039;&lt;br /&gt;
&lt;br /&gt;
To submit a new set of answers against a questionnaire, you should send data in the following structure:&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;answers&amp;gt;&lt;br /&gt;
     &amp;lt;EntityType&amp;gt;Person&amp;lt;/EntityType&amp;gt;&lt;br /&gt;
     &amp;lt;EntityID&amp;gt;1&amp;lt;/EntityID&amp;gt;&lt;br /&gt;
     &amp;lt;Date&amp;gt;2012-07-31T10:00:00&amp;lt;/Date&amp;gt;&lt;br /&gt;
     &amp;lt;answer id=&amp;quot;78&amp;quot;&amp;gt;&lt;br /&gt;
       &amp;lt;QuestionID&amp;gt;78&amp;lt;/QuestionID&amp;gt;&lt;br /&gt;
       &amp;lt;Answer&amp;gt;Fully Agree&amp;lt;/Answer&amp;gt;&lt;br /&gt;
     &amp;lt;/answer&amp;gt;&lt;br /&gt;
     &amp;lt;answer id=&amp;quot;79&amp;quot;&amp;gt;&lt;br /&gt;
       &amp;lt;QuestionID&amp;gt;79&amp;lt;/QuestionID&amp;gt;&lt;br /&gt;
       &amp;lt;Answer&amp;gt;Truly Agree&amp;lt;/Answer&amp;gt;&lt;br /&gt;
     &amp;lt;/answer&amp;gt;&lt;br /&gt;
     ...&lt;br /&gt;
 &amp;lt;/answers&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Note:&#039;&#039;&#039; If you specify the attribute &#039;&#039;&amp;lt;code&amp;gt;id&amp;lt;/code&amp;gt;&#039;&#039; then you do not need to specify the &amp;lt;code&amp;gt;&amp;lt;QuestionID&amp;gt;&amp;lt;/code&amp;gt; entity.&lt;br /&gt;
&lt;br /&gt;
If you omit the entities &amp;lt;code&amp;gt;&amp;lt;EntityType&amp;gt;&amp;lt;/code&amp;gt; and &amp;lt;code&amp;gt;&amp;lt;EntityID&amp;gt;&amp;lt;/code&amp;gt;, then the answer set is related to the Session it&#039;s self. Currently, this is &#039;&#039;not&#039;&#039; supported via the UI.&lt;br /&gt;
&lt;br /&gt;
You can also omit the &amp;lt;code&amp;gt;&amp;lt;Date&amp;gt;&amp;lt;/code&amp;gt; entity. If you do this, then the current system date/time will be used.&lt;br /&gt;
&lt;br /&gt;
==Updating an existing Answer Set==&lt;br /&gt;
 curl --url &amp;lt;Base URL&amp;gt;/&amp;lt;questionnairId&amp;gt;/&amp;lt;setid&amp;gt; -u&amp;lt;username&amp;gt;:&amp;lt;password&amp;gt; -H Content-Type:text/xml -X PUT -d &#039;&amp;lt;xml&amp;gt;&#039;&lt;br /&gt;
&lt;br /&gt;
When updating the answers in an answer set, you should use the same structure as when creating a new answer set. However, if you specify the entities &amp;lt;code&amp;gt;&amp;lt;EntityType&amp;gt;&amp;lt;/code&amp;gt;, &amp;lt;code&amp;gt;&amp;lt;EntityID&amp;gt;&amp;lt;/code&amp;gt;, &amp;lt;code&amp;gt;TargetType&amp;gt;&amp;lt;/code&amp;gt;, &amp;lt;code&amp;gt;TargetID&amp;gt;&amp;lt;/code&amp;gt; they will be ignored.&lt;/div&gt;</summary>
		<author><name>Wikiadmin</name></author>
	</entry>
	<entry>
		<id>https://www.substance.net/views-api-docs/index.php?title=Rest_-_Work_-_Session_Groups_-_Session_Staff&amp;diff=271</id>
		<title>Rest - Work - Session Groups - Session Staff</title>
		<link rel="alternate" type="text/html" href="https://www.substance.net/views-api-docs/index.php?title=Rest_-_Work_-_Session_Groups_-_Session_Staff&amp;diff=271"/>
		<updated>2016-02-26T13:06:04Z</updated>

		<summary type="html">&lt;p&gt;Wikiadmin: /* Purpose */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;==Purpose==&lt;br /&gt;
&lt;br /&gt;
Used for administering participation by staff at sessions in the Views system.&lt;br /&gt;
&lt;br /&gt;
===Base URL===&lt;br /&gt;
&amp;lt;nowiki&amp;gt;https://app.viewsapp.net/api/restful/work/sessiongroups/sessions/&amp;lt;sid&amp;gt;/staff&amp;lt;/nowiki&amp;gt;&lt;br /&gt;
* &#039;&#039;&#039;sid&#039;&#039;&#039; - This is the id of the session group&lt;br /&gt;
&lt;br /&gt;
==Getting the list of staff==&lt;br /&gt;
 curl --url &amp;lt;Base URL&amp;gt; -u&amp;lt;username&amp;gt;:&amp;lt;password&amp;gt; -H Content-Type:text/xml&lt;br /&gt;
&lt;br /&gt;
This will return a list of staff that are associated with a session, similar to the following:&lt;br /&gt;
 &amp;lt;session id=&amp;quot;7&amp;quot;&amp;gt;&lt;br /&gt;
     &amp;lt;staff&amp;gt;&lt;br /&gt;
         &amp;lt;staff id=&amp;quot;123&amp;quot;&amp;gt;&lt;br /&gt;
             &amp;lt;SessionID&amp;gt;25&amp;lt;/SessionID&amp;gt;&lt;br /&gt;
             &amp;lt;SessionGroupID&amp;gt;7&amp;lt;/SessionGroupID&amp;gt;&lt;br /&gt;
             &amp;lt;ContactType&amp;gt;Staff&amp;lt;/ContactType&amp;gt;&lt;br /&gt;
             &amp;lt;ContactID&amp;gt;123&amp;lt;/ContactID&amp;gt;&lt;br /&gt;
             &amp;lt;Name&amp;gt;Jane Smith&amp;lt;/Name&amp;gt;&lt;br /&gt;
             &amp;lt;Role&amp;gt;Lead&amp;lt;/Role&amp;gt;&lt;br /&gt;
             &amp;lt;Attended&amp;gt;0&amp;lt;/Attended&amp;gt;&lt;br /&gt;
             &amp;lt;Volunteering&amp;gt;&amp;lt;/Volunteering&amp;gt;&lt;br /&gt;
         &amp;lt;/staff&amp;gt;&lt;br /&gt;
         &amp;lt;staff id=&amp;quot;102&amp;quot;&amp;gt;&lt;br /&gt;
             &amp;lt;SessionID&amp;gt;25&amp;lt;/SessionID&amp;gt;&lt;br /&gt;
             &amp;lt;SessionGroupID&amp;gt;7&amp;lt;/SessionGroupID&amp;gt;&lt;br /&gt;
             &amp;lt;ContactType&amp;gt;Staff&amp;lt;/ContactType&amp;gt;&lt;br /&gt;
             &amp;lt;ContactID&amp;gt;102&amp;lt;/ContactID&amp;gt;&lt;br /&gt;
             &amp;lt;Name&amp;gt;John Smith&amp;lt;/Name&amp;gt;&lt;br /&gt;
             &amp;lt;Role&amp;gt;Assistant&amp;lt;/Role&amp;gt;&lt;br /&gt;
             &amp;lt;Attended&amp;gt;1&amp;lt;/Attended&amp;gt;&lt;br /&gt;
             &amp;lt;Volunteering&amp;gt;Volunteered|Made Coffee&amp;lt;/Volunteering&amp;gt;&lt;br /&gt;
         &amp;lt;/staff&amp;gt;&lt;br /&gt;
     &amp;lt;staff&amp;gt;&lt;br /&gt;
 &amp;lt;/sessiongroup&amp;gt;&lt;br /&gt;
&lt;br /&gt;
==Adding Staff to a session==&lt;br /&gt;
===Adding a single staff to a session===&lt;br /&gt;
You can add a single staff record via the following:&lt;br /&gt;
 curl --url &amp;lt;Base URL&amp;gt; -u&amp;lt;username&amp;gt;:&amp;lt;password&amp;gt; -H Content-Type:text/xml -X PUT&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;staff&amp;gt;&lt;br /&gt;
     &amp;lt;ContactID&amp;gt;101457&amp;lt;/ContactID&amp;gt;&lt;br /&gt;
     &amp;lt;Attended&amp;gt;0&amp;lt;/Attended&amp;gt;&lt;br /&gt;
     &amp;lt;Role&amp;gt;Assistant&amp;lt;/Role&amp;gt;&lt;br /&gt;
     &amp;lt;Volunteering&amp;gt;Volunteered|Made Coffee&amp;lt;/Volunteering&amp;gt;&lt;br /&gt;
 &amp;lt;/staff&amp;gt;&lt;br /&gt;
&lt;br /&gt;
* Attended is either 1 or 0, 1 = Attended. This is optional and will default to 0, unless the session has started, in which case the default is 1.&lt;br /&gt;
* Role - This is optional, but can contain a value of Lead or Assistant&lt;br /&gt;
* Volunteering - Values should be pipe(|) delimited. This is optional, but will clear volunteering for the member of staff for that session.&lt;br /&gt;
&lt;br /&gt;
===Adding multiple staff to a session===&lt;br /&gt;
You can also upload a a list of staff to add to the session register via the following URL&lt;br /&gt;
 curl --url &amp;lt;Base URL&amp;gt; -u&amp;lt;username&amp;gt;:&amp;lt;password&amp;gt; -H Content-Type:text/xml -X PUT&lt;br /&gt;
&lt;br /&gt;
This can be useful for setting a register of attending staff.&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;staff&amp;gt;&lt;br /&gt;
     &amp;lt;staff&amp;gt;&lt;br /&gt;
         &amp;lt;ContactID&amp;gt;101457&amp;lt;/ContactID&amp;gt;&lt;br /&gt;
         &amp;lt;Attended&amp;gt;0&amp;lt;/Attended&amp;gt;&lt;br /&gt;
        &amp;lt;Role&amp;gt;Lead&amp;lt;/Role&amp;gt;&lt;br /&gt;
     &amp;lt;/staff&amp;gt;&lt;br /&gt;
     &amp;lt;staff&amp;gt;&lt;br /&gt;
         &amp;lt;ContactID&amp;gt;457&amp;lt;/ContactID&amp;gt;&lt;br /&gt;
         &amp;lt;Attended&amp;gt;1&amp;lt;/Attended&amp;gt;&lt;br /&gt;
         &amp;lt;Role&amp;gt;Assistant&amp;lt;/Role&amp;gt;&lt;br /&gt;
         &amp;lt;Volunteering&amp;gt;Volunteered|Made Coffee&amp;lt;/Volunteering&amp;gt;&lt;br /&gt;
     &amp;lt;/staff&amp;gt;&lt;br /&gt;
     &amp;lt;staff&amp;gt;&lt;br /&gt;
         &amp;lt;ContactID&amp;gt;57&amp;lt;/ContactID&amp;gt;&lt;br /&gt;
         &amp;lt;Attended&amp;gt;1&amp;lt;/Attended&amp;gt;&lt;br /&gt;
         &amp;lt;Role&amp;gt;&amp;lt;/Role&amp;gt;&lt;br /&gt;
         &amp;lt;Volunteering&amp;gt;Cleaned up&amp;lt;/Volunteering&amp;gt;&lt;br /&gt;
     &amp;lt;/staff&amp;gt;&lt;br /&gt;
 &amp;lt;/staff&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;&#039;&#039;Please note:&#039;&#039;&#039; This will replace all existing participant data for the session&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
==Removing staff from a session==&lt;br /&gt;
You can remove a single staff record from a session via the following:&lt;br /&gt;
 curl --url &amp;lt;Base URL&amp;gt;/&amp;lt;pid&amp;gt; -u&amp;lt;username&amp;gt;:&amp;lt;password&amp;gt; -H Content-Type:text/xml -X DELETE&lt;br /&gt;
*&#039;&#039;&#039;pid&#039;&#039;&#039; - The ID of the staff to add&lt;br /&gt;
&lt;br /&gt;
You can also upload a a list of staff to remove from the session via the following URL&lt;br /&gt;
 curl --url &amp;lt;Base URL&amp;gt; -u&amp;lt;username&amp;gt;:&amp;lt;password&amp;gt; -H Content-Type:text/xml -X DELETE&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;staff&amp;gt;&lt;br /&gt;
     &amp;lt;staff&amp;gt;101162&amp;lt;/staff&amp;gt;&lt;br /&gt;
     &amp;lt;staff&amp;gt;103124&amp;lt;/staff&amp;gt;&lt;br /&gt;
     &amp;lt;staff&amp;gt;103413&amp;lt;/staff&amp;gt;&lt;br /&gt;
 &amp;lt;/staff&amp;gt;&lt;/div&gt;</summary>
		<author><name>Wikiadmin</name></author>
	</entry>
	<entry>
		<id>https://www.substance.net/views-api-docs/index.php?title=Rest_-_Work_-_Session_Groups_-_Session_Participants&amp;diff=270</id>
		<title>Rest - Work - Session Groups - Session Participants</title>
		<link rel="alternate" type="text/html" href="https://www.substance.net/views-api-docs/index.php?title=Rest_-_Work_-_Session_Groups_-_Session_Participants&amp;diff=270"/>
		<updated>2016-02-26T13:05:46Z</updated>

		<summary type="html">&lt;p&gt;Wikiadmin: /* Purpose */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;==Purpose==&lt;br /&gt;
&lt;br /&gt;
Used for administering participation by participants at sessions in the Views system.&lt;br /&gt;
&lt;br /&gt;
===Base URL===&lt;br /&gt;
&amp;lt;nowiki&amp;gt;https://app.viewsapp.net/api/restful/work/sessiongroups/sessions/&amp;lt;sid&amp;gt;/participants&amp;lt;/nowiki&amp;gt;&lt;br /&gt;
* &#039;&#039;&#039;sid&#039;&#039;&#039; - This is the id of the session group&lt;br /&gt;
&lt;br /&gt;
==Getting the list of participants==&lt;br /&gt;
 curl --url &amp;lt;Base URL&amp;gt; -u&amp;lt;username&amp;gt;:&amp;lt;password&amp;gt; -H Content-Type:text/xml&lt;br /&gt;
&lt;br /&gt;
This will return a list of participants that are associated with a session, similar to the following:&lt;br /&gt;
 &amp;lt;session id=&amp;quot;7&amp;quot;&amp;gt;&lt;br /&gt;
     &amp;lt;participants&amp;gt;&lt;br /&gt;
         &amp;lt;participant id=&amp;quot;123&amp;quot;&amp;gt;&lt;br /&gt;
             &amp;lt;SessionID&amp;gt;25&amp;lt;/SessionID&amp;gt;&lt;br /&gt;
             &amp;lt;SessionGroupID&amp;gt;7&amp;lt;/SessionGroupID&amp;gt;&lt;br /&gt;
             &amp;lt;Name&amp;gt;Jane Smith&amp;lt;/Name&amp;gt;&lt;br /&gt;
             &amp;lt;ContactType&amp;gt;Individual&amp;lt;/ContactType&amp;gt;&lt;br /&gt;
             &amp;lt;Attended&amp;gt;0&amp;lt;/Attended&amp;gt;&lt;br /&gt;
             &amp;lt;Volunteering&amp;gt;&amp;lt;/Volunteering&amp;gt;&lt;br /&gt;
         &amp;lt;/participant&amp;gt;&lt;br /&gt;
         &amp;lt;participant id=&amp;quot;102&amp;quot;&amp;gt;&lt;br /&gt;
             &amp;lt;SessionID&amp;gt;25&amp;lt;/SessionID&amp;gt;&lt;br /&gt;
             &amp;lt;SessionGroupID&amp;gt;7&amp;lt;/SessionGroupID&amp;gt;&lt;br /&gt;
             &amp;lt;Name&amp;gt;John Smith&amp;lt;/Name&amp;gt;&lt;br /&gt;
             &amp;lt;ContactType&amp;gt;Individual&amp;lt;/ContactType&amp;gt;&lt;br /&gt;
             &amp;lt;Attended&amp;gt;1&amp;lt;/Attended&amp;gt;&lt;br /&gt;
             &amp;lt;Volunteering&amp;gt;Made Coffee&amp;lt;/Volunteering&amp;gt;&lt;br /&gt;
         &amp;lt;/participant&amp;gt;&lt;br /&gt;
     &amp;lt;participants&amp;gt;&lt;br /&gt;
 &amp;lt;/sessiongroup&amp;gt;&lt;br /&gt;
&lt;br /&gt;
==Adding Participants to a session==&lt;br /&gt;
&lt;br /&gt;
===Adding participants to a bookable session===&lt;br /&gt;
Due to financial information being required for bookable sessions, the method of adding participants in slightly different.&lt;br /&gt;
&lt;br /&gt;
 curl --url &amp;lt;Base URL&amp;gt; -u&amp;lt;username&amp;gt;:&amp;lt;password&amp;gt; -H Content-Type:text/xml -X POST&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;participant&amp;gt;&lt;br /&gt;
     &amp;lt;PersonID&amp;gt;100748&amp;lt;/PersonID&amp;gt;&lt;br /&gt;
     &amp;lt;PaymentType&amp;gt;Debit Card&amp;lt;/PaymentType&amp;gt;&lt;br /&gt;
     &amp;lt;PaymentAmount&amp;gt;20&amp;lt;/PaymentAmount&amp;gt;&lt;br /&gt;
     &amp;lt;PaymentFee&amp;gt;2.50&amp;lt;/PaymentFee&amp;gt;&lt;br /&gt;
     &amp;lt;PaymentReference&amp;gt;7002&amp;lt;/PaymentReference&amp;gt;&lt;br /&gt;
     &amp;lt;Forename&amp;gt;Father&amp;lt;/Forename&amp;gt;&lt;br /&gt;
     &amp;lt;Surname&amp;gt;Test&amp;lt;/Surname&amp;gt;&lt;br /&gt;
     &amp;lt;Address1/&amp;gt;&lt;br /&gt;
     &amp;lt;Address2/&amp;gt;&lt;br /&gt;
     &amp;lt;Town/&amp;gt;&lt;br /&gt;
     &amp;lt;County/&amp;gt;&lt;br /&gt;
     &amp;lt;Postcode/&amp;gt;&lt;br /&gt;
     &amp;lt;Telephone/&amp;gt;&lt;br /&gt;
     &amp;lt;Email&amp;gt;test@test.com&amp;lt;/Email&amp;gt;&lt;br /&gt;
 &amp;lt;/participant&amp;gt;&lt;br /&gt;
&lt;br /&gt;
This will return errors on a fail or the full booking record on a successful submit.&lt;br /&gt;
&lt;br /&gt;
The required fields are all required:&lt;br /&gt;
* PersonID - This is the ID of the participant&lt;br /&gt;
* PaymentType - One of the following value &#039;Cash&#039;, &#039;Cheque&#039;, &#039;Debit Card&#039;, &#039;Credit Card&#039;, &#039;Other&#039;&lt;br /&gt;
* PaymentAmount - This is the amount paid&lt;br /&gt;
&lt;br /&gt;
===Adding a single participant to a session===&lt;br /&gt;
You can add a single participant via the following:&lt;br /&gt;
 curl --url &amp;lt;Base URL&amp;gt; -u&amp;lt;username&amp;gt;:&amp;lt;password&amp;gt; -H Content-Type:text/xml -X PUT&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;participant&amp;gt;&lt;br /&gt;
     &amp;lt;ContactID&amp;gt;101457&amp;lt;/ContactID&amp;gt;&lt;br /&gt;
     &amp;lt;Attended&amp;gt;0&amp;lt;/Attended&amp;gt;&lt;br /&gt;
     &amp;lt;Volunteering&amp;gt;Volunteered|Made Coffee&amp;lt;/Volunteering&amp;gt;&lt;br /&gt;
 &amp;lt;/participant&amp;gt;&lt;br /&gt;
&lt;br /&gt;
The value for Attended is either 1 or 0, 1 = Attended. This is optional and will default to 0, unless the session has started, in which case the default is 1.&lt;br /&gt;
&lt;br /&gt;
===Adding multiple participants to a session===&lt;br /&gt;
You can also upload a a list of participants to add to the session register via the following URL&lt;br /&gt;
 curl --url &amp;lt;Base URL&amp;gt; -u&amp;lt;username&amp;gt;:&amp;lt;password&amp;gt; -H Content-Type:text/xml -X PUT&lt;br /&gt;
&lt;br /&gt;
This can be useful for setting a register of attending participants.&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;participants&amp;gt;&lt;br /&gt;
     &amp;lt;participant&amp;gt;&lt;br /&gt;
         &amp;lt;ContactID&amp;gt;101457&amp;lt;/ContactID&amp;gt;&lt;br /&gt;
         &amp;lt;Attended&amp;gt;0&amp;lt;/Attended&amp;gt;&lt;br /&gt;
     &amp;lt;/participant&amp;gt;&lt;br /&gt;
     &amp;lt;participant&amp;gt;&lt;br /&gt;
         &amp;lt;ContactID&amp;gt;457&amp;lt;/ContactID&amp;gt;&lt;br /&gt;
         &amp;lt;Attended&amp;gt;1&amp;lt;/Attended&amp;gt;&lt;br /&gt;
         &amp;lt;Volunteering&amp;gt;Volunteered|Made Coffee&amp;lt;/Volunteering&amp;gt;&lt;br /&gt;
     &amp;lt;/participant&amp;gt;&lt;br /&gt;
     &amp;lt;participant&amp;gt;&lt;br /&gt;
         &amp;lt;ContactID&amp;gt;57&amp;lt;/ContactID&amp;gt;&lt;br /&gt;
         &amp;lt;Attended&amp;gt;1&amp;lt;/Attended&amp;gt;&lt;br /&gt;
         &amp;lt;Volunteering&amp;gt;Cleaned Up&amp;lt;/Volunteering&amp;gt;&lt;br /&gt;
     &amp;lt;/participant&amp;gt;&lt;br /&gt;
 &amp;lt;/participants&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;&#039;&#039;Please note:&#039;&#039;&#039; This will replace all existing participant data for the session&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
==Removing participants from a session==&lt;br /&gt;
&lt;br /&gt;
===Removing participants from a non bookable session group===&lt;br /&gt;
&lt;br /&gt;
You can remove a single participant from a session via the following:&lt;br /&gt;
 curl --url &amp;lt;Base URL&amp;gt;/&amp;lt;pid&amp;gt; -u&amp;lt;username&amp;gt;:&amp;lt;password&amp;gt; -H Content-Type:text/xml -X DELETE&lt;br /&gt;
*&#039;&#039;&#039;pid&#039;&#039;&#039; - The ID of the participant to add&lt;br /&gt;
&lt;br /&gt;
You can also upload a a list of participants to remove from the session via the following URL&lt;br /&gt;
 curl --url &amp;lt;Base URL&amp;gt; -u&amp;lt;username&amp;gt;:&amp;lt;password&amp;gt; -H Content-Type:text/xml -X DELETE&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;participants&amp;gt;&lt;br /&gt;
     &amp;lt;participant&amp;gt;101162&amp;lt;/participant&amp;gt;&lt;br /&gt;
     &amp;lt;participant&amp;gt;103124&amp;lt;/participant&amp;gt;&lt;br /&gt;
     &amp;lt;participant&amp;gt;103413&amp;lt;/participant&amp;gt;&lt;br /&gt;
 &amp;lt;/participants&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
===Removing participants from a bookable session===&lt;br /&gt;
You can only remove a single participant&#039;s booking from a session group via the following:&lt;br /&gt;
 curl --url &amp;lt;Base URL&amp;gt;/&amp;lt;pid&amp;gt; -u&amp;lt;username&amp;gt;:&amp;lt;password&amp;gt; -H Content-Type:text/xml -X DELETE&lt;br /&gt;
*&#039;&#039;&#039;pid&#039;&#039;&#039; - The ID of the participant to remove&lt;br /&gt;
&lt;br /&gt;
By default this will flag the participant as cancelled, but will not do anything with the financial side of the booking. To flag a refund was give or a credit note, you should pass the following:&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;refundtype&amp;gt;Refund&amp;lt;/refundtype&amp;gt;&lt;br /&gt;
&lt;br /&gt;
or &lt;br /&gt;
&lt;br /&gt;
 &amp;lt;refundtype&amp;gt;Credit&amp;lt;/refundtype&amp;gt;&lt;br /&gt;
&lt;br /&gt;
This will result in the participants booking being completely being removed from the session&lt;/div&gt;</summary>
		<author><name>Wikiadmin</name></author>
	</entry>
</feed>