{
  "name": "Proofpoint Security Awareness Training Results API",
  "version": "0.1.0",
  "description": "",
  "order": [
    "Introduction",
    "API_Endpoints",
    "Code_Samples",
    "AuthenticationAPI",
    "CyberStrengthFunction",
    "PhishAlarmFunction",
    "PhishingEventFunction",
    "TrainingFunction",
    "UsersFunction",
    "ExampleUsageBash",
    "ExampleUsageCmd"
  ],
  "template": {
    "forceLanguage": "en"
  },
  "footer": {
    "title": "Appendix A",
    "content": "<p><b><h2 id=\"url_encoding\"> Appendix A </h2></b></p>\n<p>Some characters cannot be part of a URL (for example, the space) and some other characters have a special meaning in a URL (for example, the character <code> =</code>  is used to separate a name from a value). The URI generic syntax uses URL encoding to deal with this problem. </p>\n<p> It is recommended you use your platform's normal URL building libraries to automatically encode parts in your URLs (the filters and values), to ensure the URLs are properly escaped for your platform. </p>\n<br />\n<p><b>Importance of URL encoding</b></p>\n<p>URL encoding is required to convert special characters because: </p>\n<p>&nbsp; &ndash; Have special meaning in some contexts </p>\n<p>&nbsp; &ndash; Are not valid character for an URL </p>\n<p>&nbsp; &ndash; Could be altered during transfer </p>\n<br />\n<p><b>Safe and unsafe characters</b></p>\n<p>Based on Web Standards, the following quick reference chart explains which characters are “safe” and which characters should be encoded in URLs. </p>\n<table>\n\t<thead>\n        <tr>\n            <th style=\"width: 25%\">Classification</th>\n            <th style=\"width: 65%\">Included Characters</th>\n            <th style=\"width: 10%\">Encoding Required</th>\n        </tr>\n\t</thead>\n\t<tbody>\n        <tr>\n            <td class=\"code\">Safe characters </td>\n            <td>Alphanumeric <code>[0-9a-zA-Z]</code>, special characters <code>$-_.!*'()</code>, and reserved characters used for their reserved purposes (e.g., question mark used to denote a query string) </td>\n            <td>NO </td>\n        </tr>\n        <tr>\n            <td class=\"code\">ASCII Control characters </td>\n            <td>Includes the ISO-8859-1 (ISO-Latin) character ranges 00-1F hex (0-31 decimal) and 7F (127 decimal) </td>\n            <td>YES </td>\n        </tr>\n        <tr>\n            <td class=\"code\">Non-ASCII characters </td>\n            <td>Includes the entire “top half” of the ISO-Latin set 80-FF hex (128-255 decimal.) </td>\n            <td>YES </td>\n\t\t</tr>\n\t\t<tr>\n            <td class=\"code\">Reserved characters </td>\n            <td><code>$ & + , / : ; = ? @</code> (not including blank space) </td>\n            <td>YES* </td>\n        </tr>\n        <tr>\n            <td class=\"code\">Unsafe characters </td>\n            <td>Includes the blank/empty space and <code>\" < > # % { } | \\ ^ ~ [ ] `</code> </td>\n            <td>YES </td>\n        </tr>\n\t</tbody>\n</table>\n  <p>* Note: Reserved characters only need encoding when not used for their defined, reserved purposes.</p>\n<br/>\n<p><b>Example of encoding</b></p>\n<p>Your platform's normal URL building libraries will automatically encode parts in your URLs. Any unsafe or unprintable characters that will be provided as filters and values will be replaced with a percent sign (%), followed by the hexadecimal digits that correspond to the character's value.  </p>\n<p>Some common characters that must be encoded are:</p>\n<table>\n\t<thead>\n        <tr>\n            <th style=\"width: 50%\">Unsafe character</th>\n            <th style=\"width: 50%\">Encoded value</th>\n        </tr>\n\t</thead>\n\t<tbody>\n        <tr>\n            <td class=\"code\">= </td>\n            <td>%3d </td>\n        </tr>\n        <tr>\n            <td class=\"code\">+ </td>\n            <td>%2b </td>\n        </tr>\n        <tr>\n            <td class=\"code\">& </td>\n            <td>%26 </td>\n\t\t</tr>\n\t\t<tr>\n            <td class=\"code\"># </td>\n            <td>%23 </td>\n        </tr>\n        <tr>\n            <td class=\"code\">\" </td>\n            <td>%22 </td>\n        </tr>\n        <tr>\n            <td class=\"code\">&lt; </td>\n            <td>%3C </td>\n        </tr>\n        <tr>\n            <td class=\"code\">&gt; </td>\n            <td>%3E </td>\n        </tr>\n        <tr>\n            <td class=\"code\">% </td>\n            <td>%25 </td>\n        </tr>\n        <tr>\n            <td class=\"code\">| </td>\n            <td>%7C </td>\n        </tr>\n\t</tbody>\n</table>\n<p> Consider the example where a filter is supplied in a URL and filter value has a special character in it. For example, a user may enter an email address as <code>\"joe&user,main\"@example.org</code> . In this example, double quote and & need to be handled specially, otherwise it may not be interpreted correctly. </p>\n<br/>\n<ul class=\"nav nav-tabs nav-tabs-examples\">\n    <li class=\"active\">\n        <a href=\"#before-encoding\">The URL, before encoding:</a>\n    </li>\n    <li>\n        <a href=\"#after-encoding\">The URL, after encoding:</a>\n    </li>\n</ul>\n<div class=\"tab-content\">\n    <div class=\"tab-pane active\" id=\"before-encoding\">\n        <pre class=\"prettyprint language-json prettyprinted\" data-type=\"json\" style=\"\"><code><span class=\"pln\">http</span><span class=\"pun\">://</span><span class=\"pln\">host</span><span class=\"pun\">.</span><span class=\"pln\">server</span><span class=\"pun\">:</span><span class=\"pln\">port</span><span class=\"pun\">/</span><span class=\"pln\">api</span><span class=\"pun\">/</span><span class=\"pln\">reporting</span><span class=\"pun\">/</span><span class=\"pln\">v0</span><span class=\"pun\">.</span><span class=\"lit\">1.0</span><span class=\"pun\">/</span><span class=\"pln\">users</span><span class=\"pun\">?</span><span class=\"pln\">filter</span><span class=\"pun\">[</span><span class=\"pln\">_useremailaddress</span><span class=\"pun\">]=[</span><span class=\"str\">\"joe&amp;user,main\"</span><span class=\"lit\">@example</span><span class=\"pun\">.</span><span class=\"pln\">org</span><span class=\"pun\">]</span></code></pre>\n    </div>\n    <div class=\"tab-pane\" id=\"after-encoding\">\n        <pre class=\"prettyprint language-json prettyprinted\" data-type=\"json\" style=\"\"><code><span class=\"pln\">http</span><span class=\"pun\">://</span><span class=\"pln\">host</span><span class=\"pun\">.</span><span class=\"pln\">server</span><span class=\"pun\">:</span><span class=\"pln\">port</span><span class=\"pun\">/</span><span class=\"pln\">api</span><span class=\"pun\">/</span><span class=\"pln\">reporting</span><span class=\"pun\">/</span><span class=\"pln\">v0</span><span class=\"pun\">.</span><span class=\"lit\">1.0</span><span class=\"pun\">/</span><span class=\"pln\">users</span><span class=\"pun\">?</span><span class=\"pln\">filter</span><span class=\"pun\">%</span><span class=\"lit\">5b</span><span class=\"pln\">_useremailaddress</span><span class=\"pun\">%</span><span class=\"lit\">5d</span><span class=\"pun\">%</span><span class=\"lit\">3d</span><span class=\"pun\">%</span><span class=\"lit\">5b</span><span class=\"pun\">%</span><span class=\"lit\">22joe</span><span class=\"pun\">%</span><span class=\"lit\">26user</span><span class=\"pun\">%</span><span class=\"lit\">2cmain</span><span class=\"pun\">%</span><span class=\"lit\">22</span><span class=\"pun\">%</span><span class=\"lit\">40example</span><span class=\"pun\">.</span><span class=\"pln\">org</span><span class=\"pun\">%</span><span class=\"lit\">5d</span></code></pre>\n    </div>\n</div>\n</br>"
  },
  "sampleUrl": false,
  "defaultVersion": "0.0.0",
  "apidoc": "0.3.0",
  "generator": {
    "name": "apidoc",
    "time": "2019-04-29T17:56:54.381Z",
    "url": "http://apidocjs.com",
    "version": "0.17.7"
  }
}
