mirror of https://github.com/gophish/gophish
Filling in some more API docs
parent
594aef49a5
commit
69034c8e3f
|
@ -541,10 +541,6 @@ ers</p>
|
||||||
"<span class="hljs-attribute">success</span>": <span class="hljs-value"><span class="hljs-literal">false</span></span>,
|
"<span class="hljs-attribute">success</span>": <span class="hljs-value"><span class="hljs-literal">false</span></span>,
|
||||||
"<span class="hljs-attribute">data</span>": <span class="hljs-value"><span class="hljs-literal">null</span>
|
"<span class="hljs-attribute">data</span>": <span class="hljs-value"><span class="hljs-literal">null</span>
|
||||||
</span>}</code></pre><div style="height: 1px;"></div></div></div></div><div id="campaigns-campaign-delete" class="action delete"><h4 class="action-heading"><div class="name">Delete a Campaign</div><a href="#campaigns-campaign-delete" class="method delete">DELETE</a><code class="uri">/campaigns/{id}</code></h4><p>Delete a campaign by its ID.</p>
|
</span>}</code></pre><div style="height: 1px;"></div></div></div></div><div id="campaigns-campaign-delete" class="action delete"><h4 class="action-heading"><div class="name">Delete a Campaign</div><a href="#campaigns-campaign-delete" class="method delete">DELETE</a><code class="uri">/campaigns/{id}</code></h4><p>Delete a campaign by its ID.</p>
|
||||||
<div class="warning">
|
|
||||||
<h4 id="header-i-class-fa-fa-warning-i-caution"><i class="fa fa-warning"></i> Caution <a class="permalink" href="#header-i-class-fa-fa-warning-i-caution" aria-hidden="true">¶</a></h4>
|
|
||||||
<p>If the value for <code>title</code> or <code>body</code> is <code>null</code> or <code>undefined</code>, then the corresponding value is not modified on the server. However, if you send an empty string instead then it will <strong>permanently overwrite</strong> the original value.</p>
|
|
||||||
</div>
|
|
||||||
<div class="title"><strong>Parameters</strong><div class="collapse-button show"><span class="close">Hide</span><span class="open">Show</span></div></div><div class="collapse-content"><dl class="inner"><dt>id</dt><dd><code>number</code> <span class="required">(required)</span> <span class="text-muted example"><strong>Example: </strong><span>1</span></span><p>The Campaign ID</p>
|
<div class="title"><strong>Parameters</strong><div class="collapse-button show"><span class="close">Hide</span><span class="open">Show</span></div></div><div class="collapse-content"><dl class="inner"><dt>id</dt><dd><code>number</code> <span class="required">(required)</span> <span class="text-muted example"><strong>Example: </strong><span>1</span></span><p>The Campaign ID</p>
|
||||||
</dd></dl></div><div class="title"><strong>Response <code>200</code></strong><div class="collapse-button"><span class="close">Hide</span><span class="open">Show</span></div></div><div class="collapse-content"><div class="inner"><h5>Headers</h5><pre><code><span class="hljs-attribute">Content-Type</span>: <span class="hljs-string">application/json</span></code></pre><div style="height: 1px;"></div><h5>Body</h5><pre><code>{
|
</dd></dl></div><div class="title"><strong>Response <code>200</code></strong><div class="collapse-button"><span class="close">Hide</span><span class="open">Show</span></div></div><div class="collapse-content"><div class="inner"><h5>Headers</h5><pre><code><span class="hljs-attribute">Content-Type</span>: <span class="hljs-string">application/json</span></code></pre><div style="height: 1px;"></div><h5>Body</h5><pre><code>{
|
||||||
"<span class="hljs-attribute">id</span>": <span class="hljs-value"><span class="hljs-number">1</span></span>,
|
"<span class="hljs-attribute">id</span>": <span class="hljs-value"><span class="hljs-number">1</span></span>,
|
||||||
|
@ -910,10 +906,6 @@ ers</p>
|
||||||
"<span class="hljs-attribute">success</span>": <span class="hljs-value"><span class="hljs-literal">false</span></span>,
|
"<span class="hljs-attribute">success</span>": <span class="hljs-value"><span class="hljs-literal">false</span></span>,
|
||||||
"<span class="hljs-attribute">data</span>": <span class="hljs-value"><span class="hljs-literal">null</span>
|
"<span class="hljs-attribute">data</span>": <span class="hljs-value"><span class="hljs-literal">null</span>
|
||||||
</span>}</code></pre><div style="height: 1px;"></div></div></div></div><div id="templates-template-delete" class="action delete"><h4 class="action-heading"><div class="name">Delete a Template</div><a href="#templates-template-delete" class="method delete">DELETE</a><code class="uri">/templates/{id}</code></h4><p>Delete a template by its ID.</p>
|
</span>}</code></pre><div style="height: 1px;"></div></div></div></div><div id="templates-template-delete" class="action delete"><h4 class="action-heading"><div class="name">Delete a Template</div><a href="#templates-template-delete" class="method delete">DELETE</a><code class="uri">/templates/{id}</code></h4><p>Delete a template by its ID.</p>
|
||||||
<div class="warning">
|
|
||||||
<h4 id="header-i-class-fa-fa-warning-i-caution-1"><i class="fa fa-warning"></i> Caution <a class="permalink" href="#header-i-class-fa-fa-warning-i-caution-1" aria-hidden="true">¶</a></h4>
|
|
||||||
<p>If the value for <code>title</code> or <code>body</code> is <code>null</code> or <code>undefined</code>, then the corresponding value is not modified on the server. However, if you send an empty string instead then it will <strong>permanently overwrite</strong> the original value.</p>
|
|
||||||
</div>
|
|
||||||
<div class="title"><strong>Parameters</strong><div class="collapse-button show"><span class="close">Hide</span><span class="open">Show</span></div></div><div class="collapse-content"><dl class="inner"><dt>id</dt><dd><code>number</code> <span class="required">(required)</span> <span class="text-muted example"><strong>Example: </strong><span>1</span></span><p>The Template ID</p>
|
<div class="title"><strong>Parameters</strong><div class="collapse-button show"><span class="close">Hide</span><span class="open">Show</span></div></div><div class="collapse-content"><dl class="inner"><dt>id</dt><dd><code>number</code> <span class="required">(required)</span> <span class="text-muted example"><strong>Example: </strong><span>1</span></span><p>The Template ID</p>
|
||||||
</dd></dl></div><div class="title"><strong>Response <code>200</code></strong><div class="collapse-button"><span class="close">Hide</span><span class="open">Show</span></div></div><div class="collapse-content"><div class="inner"><h5>Headers</h5><pre><code><span class="hljs-attribute">Content-Type</span>: <span class="hljs-string">application/json</span></code></pre><div style="height: 1px;"></div><h5>Body</h5><pre><code>{
|
</dd></dl></div><div class="title"><strong>Response <code>200</code></strong><div class="collapse-button"><span class="close">Hide</span><span class="open">Show</span></div></div><div class="collapse-content"><div class="inner"><h5>Headers</h5><pre><code><span class="hljs-attribute">Content-Type</span>: <span class="hljs-string">application/json</span></code></pre><div style="height: 1px;"></div><h5>Body</h5><pre><code>{
|
||||||
"<span class="hljs-attribute">id</span>": <span class="hljs-value"><span class="hljs-number">1</span></span>,
|
"<span class="hljs-attribute">id</span>": <span class="hljs-value"><span class="hljs-number">1</span></span>,
|
||||||
|
@ -1123,10 +1115,6 @@ ers</p>
|
||||||
"<span class="hljs-attribute">success</span>": <span class="hljs-value"><span class="hljs-literal">false</span></span>,
|
"<span class="hljs-attribute">success</span>": <span class="hljs-value"><span class="hljs-literal">false</span></span>,
|
||||||
"<span class="hljs-attribute">data</span>": <span class="hljs-value"><span class="hljs-literal">null</span>
|
"<span class="hljs-attribute">data</span>": <span class="hljs-value"><span class="hljs-literal">null</span>
|
||||||
</span>}</code></pre><div style="height: 1px;"></div></div></div></div><div id="groups-group-delete" class="action delete"><h4 class="action-heading"><div class="name">Delete a Group</div><a href="#groups-group-delete" class="method delete">DELETE</a><code class="uri">/groups/{id}</code></h4><p>Delete a Group by its ID.</p>
|
</span>}</code></pre><div style="height: 1px;"></div></div></div></div><div id="groups-group-delete" class="action delete"><h4 class="action-heading"><div class="name">Delete a Group</div><a href="#groups-group-delete" class="method delete">DELETE</a><code class="uri">/groups/{id}</code></h4><p>Delete a Group by its ID.</p>
|
||||||
<div class="warning">
|
|
||||||
<h4 id="header-i-class-fa-fa-warning-i-caution-2"><i class="fa fa-warning"></i> Caution <a class="permalink" href="#header-i-class-fa-fa-warning-i-caution-2" aria-hidden="true">¶</a></h4>
|
|
||||||
<p>If the value for <code>title</code> or <code>body</code> is <code>null</code> or <code>undefined</code>, then the corresponding value is not modified on the server. However, if you send an empty string instead then it will <strong>permanently overwrite</strong> the original value.</p>
|
|
||||||
</div>
|
|
||||||
<div class="title"><strong>Parameters</strong><div class="collapse-button show"><span class="close">Hide</span><span class="open">Show</span></div></div><div class="collapse-content"><dl class="inner"><dt>id</dt><dd><code>number</code> <span class="required">(required)</span> <span class="text-muted example"><strong>Example: </strong><span>1</span></span><p>The Template ID</p>
|
<div class="title"><strong>Parameters</strong><div class="collapse-button show"><span class="close">Hide</span><span class="open">Show</span></div></div><div class="collapse-content"><dl class="inner"><dt>id</dt><dd><code>number</code> <span class="required">(required)</span> <span class="text-muted example"><strong>Example: </strong><span>1</span></span><p>The Template ID</p>
|
||||||
</dd></dl></div><div class="title"><strong>Response <code>200</code></strong><div class="collapse-button"><span class="close">Hide</span><span class="open">Show</span></div></div><div class="collapse-content"><div class="inner"><h5>Headers</h5><pre><code><span class="hljs-attribute">Content-Type</span>: <span class="hljs-string">application/json</span></code></pre><div style="height: 1px;"></div><h5>Body</h5><pre><code>{
|
</dd></dl></div><div class="title"><strong>Response <code>200</code></strong><div class="collapse-button"><span class="close">Hide</span><span class="open">Show</span></div></div><div class="collapse-content"><div class="inner"><h5>Headers</h5><pre><code><span class="hljs-attribute">Content-Type</span>: <span class="hljs-string">application/json</span></code></pre><div style="height: 1px;"></div><h5>Body</h5><pre><code>{
|
||||||
"<span class="hljs-attribute">id</span>": <span class="hljs-value"><span class="hljs-number">1</span></span>,
|
"<span class="hljs-attribute">id</span>": <span class="hljs-value"><span class="hljs-number">1</span></span>,
|
||||||
|
@ -1324,9 +1312,8 @@ ers</p>
|
||||||
"<span class="hljs-attribute">message</span>": <span class="hljs-value"><span class="hljs-string">"Page not found"</span></span>,
|
"<span class="hljs-attribute">message</span>": <span class="hljs-value"><span class="hljs-string">"Page not found"</span></span>,
|
||||||
"<span class="hljs-attribute">success</span>": <span class="hljs-value"><span class="hljs-literal">false</span></span>,
|
"<span class="hljs-attribute">success</span>": <span class="hljs-value"><span class="hljs-literal">false</span></span>,
|
||||||
"<span class="hljs-attribute">data</span>": <span class="hljs-value"><span class="hljs-literal">null</span>
|
"<span class="hljs-attribute">data</span>": <span class="hljs-value"><span class="hljs-literal">null</span>
|
||||||
</span>}</code></pre><div style="height: 1px;"></div></div></div></div><div id="pages-page-put" class="action put"><h4 class="action-heading"><div class="name">Put Page</div><a href="#pages-page-put" class="method put">PUT</a><code class="uri">/pages/{id}</code></h4><p>Modify a page by its ID.</p>
|
</span>}</code></pre><div style="height: 1px;"></div></div></div></div><div id="pages-page-put" class="action put"><h4 class="action-heading"><div class="name">Put Page</div><a href="#pages-page-put" class="method put">PUT</a><code class="uri">/pages</code></h4><p>Modify a page by its ID.</p>
|
||||||
<div class="title"><strong>Parameters</strong><div class="collapse-button show"><span class="close">Hide</span><span class="open">Show</span></div></div><div class="collapse-content"><dl class="inner"><dt>id</dt><dd><code>number</code> <span class="required">(required)</span> <span class="text-muted example"><strong>Example: </strong><span>1</span></span><p>The Page ID</p>
|
<div class="title"><strong>Request</strong></div><div class="title"><strong>Response <code>200</code></strong><div class="collapse-button"><span class="close">Hide</span><span class="open">Show</span></div></div><div class="collapse-content"><div class="inner"><h5>Headers</h5><pre><code><span class="hljs-attribute">Content-Type</span>: <span class="hljs-string">application/json</span></code></pre><div style="height: 1px;"></div><h5>Body</h5><pre><code>{
|
||||||
</dd></dl></div><div class="title"><strong>Response <code>200</code></strong><div class="collapse-button"><span class="close">Hide</span><span class="open">Show</span></div></div><div class="collapse-content"><div class="inner"><h5>Headers</h5><pre><code><span class="hljs-attribute">Content-Type</span>: <span class="hljs-string">application/json</span></code></pre><div style="height: 1px;"></div><h5>Body</h5><pre><code>{
|
|
||||||
"<span class="hljs-attribute">id</span>": <span class="hljs-value"><span class="hljs-number">1</span></span>,
|
"<span class="hljs-attribute">id</span>": <span class="hljs-value"><span class="hljs-number">1</span></span>,
|
||||||
"<span class="hljs-attribute">name</span>": <span class="hljs-value"><span class="hljs-string">"Example Page"</span></span>,
|
"<span class="hljs-attribute">name</span>": <span class="hljs-value"><span class="hljs-string">"Example Page"</span></span>,
|
||||||
"<span class="hljs-attribute">html</span>": <span class="hljs-value"><span class="hljs-string">"<html><head></head><body>This is a test message!</body></html>"</span></span>,
|
"<span class="hljs-attribute">html</span>": <span class="hljs-value"><span class="hljs-string">"<html><head></head><body>This is a test message!</body></html>"</span></span>,
|
||||||
|
@ -1362,10 +1349,6 @@ ers</p>
|
||||||
"<span class="hljs-attribute">success</span>": <span class="hljs-value"><span class="hljs-literal">false</span></span>,
|
"<span class="hljs-attribute">success</span>": <span class="hljs-value"><span class="hljs-literal">false</span></span>,
|
||||||
"<span class="hljs-attribute">data</span>": <span class="hljs-value"><span class="hljs-literal">null</span>
|
"<span class="hljs-attribute">data</span>": <span class="hljs-value"><span class="hljs-literal">null</span>
|
||||||
</span>}</code></pre><div style="height: 1px;"></div></div></div></div><div id="pages-page-delete" class="action delete"><h4 class="action-heading"><div class="name">Delete a Page</div><a href="#pages-page-delete" class="method delete">DELETE</a><code class="uri">/pages/{id}</code></h4><p>Delete a page by its ID.</p>
|
</span>}</code></pre><div style="height: 1px;"></div></div></div></div><div id="pages-page-delete" class="action delete"><h4 class="action-heading"><div class="name">Delete a Page</div><a href="#pages-page-delete" class="method delete">DELETE</a><code class="uri">/pages/{id}</code></h4><p>Delete a page by its ID.</p>
|
||||||
<div class="warning">
|
|
||||||
<h4 id="header-i-class-fa-fa-warning-i-caution-3"><i class="fa fa-warning"></i> Caution <a class="permalink" href="#header-i-class-fa-fa-warning-i-caution-3" aria-hidden="true">¶</a></h4>
|
|
||||||
<p>If the value for <code>title</code> or <code>body</code> is <code>null</code> or <code>undefined</code>, then the corresponding value is not modified on the server. However, if you send an empty string instead then it will <strong>permanently overwrite</strong> the original value.</p>
|
|
||||||
</div>
|
|
||||||
<div class="title"><strong>Parameters</strong><div class="collapse-button show"><span class="close">Hide</span><span class="open">Show</span></div></div><div class="collapse-content"><dl class="inner"><dt>id</dt><dd><code>number</code> <span class="required">(required)</span> <span class="text-muted example"><strong>Example: </strong><span>1</span></span><p>The Page ID</p>
|
<div class="title"><strong>Parameters</strong><div class="collapse-button show"><span class="close">Hide</span><span class="open">Show</span></div></div><div class="collapse-content"><dl class="inner"><dt>id</dt><dd><code>number</code> <span class="required">(required)</span> <span class="text-muted example"><strong>Example: </strong><span>1</span></span><p>The Page ID</p>
|
||||||
</dd></dl></div><div class="title"><strong>Response <code>200</code></strong><div class="collapse-button"><span class="close">Hide</span><span class="open">Show</span></div></div><div class="collapse-content"><div class="inner"><h5>Headers</h5><pre><code><span class="hljs-attribute">Content-Type</span>: <span class="hljs-string">application/json</span></code></pre><div style="height: 1px;"></div><h5>Body</h5><pre><code>{
|
</dd></dl></div><div class="title"><strong>Response <code>200</code></strong><div class="collapse-button"><span class="close">Hide</span><span class="open">Show</span></div></div><div class="collapse-content"><div class="inner"><h5>Headers</h5><pre><code><span class="hljs-attribute">Content-Type</span>: <span class="hljs-string">application/json</span></code></pre><div style="height: 1px;"></div><h5>Body</h5><pre><code>{
|
||||||
"<span class="hljs-attribute">id</span>": <span class="hljs-value"><span class="hljs-number">1</span></span>,
|
"<span class="hljs-attribute">id</span>": <span class="hljs-value"><span class="hljs-number">1</span></span>,
|
||||||
|
@ -1410,101 +1393,36 @@ ers</p>
|
||||||
<p>The fields expected in the CSV are as follows:</p>
|
<p>The fields expected in the CSV are as follows:</p>
|
||||||
<ul>
|
<ul>
|
||||||
<li>
|
<li>
|
||||||
<p>Test</p>
|
<p>First Name</p>
|
||||||
</li>
|
</li>
|
||||||
<li>
|
<li>
|
||||||
<p>two</p>
|
<p>Last Name</p>
|
||||||
|
</li>
|
||||||
|
<li>
|
||||||
|
<p>Position</p>
|
||||||
|
</li>
|
||||||
|
<li>
|
||||||
|
<p>Email</p>
|
||||||
|
</li>
|
||||||
|
<li>
|
||||||
|
<p>Company</p>
|
||||||
</li>
|
</li>
|
||||||
</ul>
|
</ul>
|
||||||
<div class="title"><strong>Request</strong><div class="collapse-button"><span class="close">Hide</span><span class="open">Show</span></div></div><div class="collapse-content"><div class="inner"><h5>Headers</h5><pre><code><span class="hljs-attribute">Content-Type</span>: <span class="hljs-string">application/json</span></code></pre><div style="height: 1px;"></div><h5>Body</h5><pre><code>{
|
<div class="title"><strong>Request</strong><div class="collapse-button"><span class="close">Hide</span><span class="open">Show</span></div></div><div class="collapse-content"><div class="inner"><h5>Headers</h5><pre><code><span class="hljs-attribute">Content-Type</span>: <span class="hljs-string">multipart/form-data; boundary=----BOUNDARY</span></code></pre><div style="height: 1px;"></div><h5>Body</h5><pre><code>------BOUNDARY
|
||||||
|
Content-Disposition: form-data; name=<span class="hljs-string">"files[]"</span>; filename=<span class="hljs-string">"filename.csv"</span>
|
||||||
|
Content-Type: application/vnd.ms-excel
|
||||||
|
|
||||||
|
[File Content]
|
||||||
|
------BOUNDARY</code></pre><div style="height: 1px;"></div></div></div><div class="title"><strong>Response <code>201</code></strong><div class="collapse-button"><span class="close">Hide</span><span class="open">Show</span></div></div><div class="collapse-content"><div class="inner"><h5>Headers</h5><pre><code><span class="hljs-attribute">Content-Type</span>: <span class="hljs-string">application/json</span></code></pre><div style="height: 1px;"></div><h5>Body</h5><pre><code>[
|
||||||
|
{
|
||||||
"<span class="hljs-attribute">id</span>": <span class="hljs-value"><span class="hljs-number">1</span></span>,
|
"<span class="hljs-attribute">id</span>": <span class="hljs-value"><span class="hljs-number">1</span></span>,
|
||||||
"<span class="hljs-attribute">name</span>": <span class="hljs-value"><span class="hljs-string">"Example Template"</span></span>,
|
"<span class="hljs-attribute">first_name</span>": <span class="hljs-value"><span class="hljs-string">"John"</span></span>,
|
||||||
"<span class="hljs-attribute">subject</span>": <span class="hljs-value"><span class="hljs-string">"Example email template subject"</span></span>,
|
"<span class="hljs-attribute">last_name</span>": <span class="hljs-value"><span class="hljs-string">"Doe"</span></span>,
|
||||||
"<span class="hljs-attribute">text</span>": <span class="hljs-value"><span class="hljs-string">"This is a test message!"</span></span>,
|
"<span class="hljs-attribute">email</span>": <span class="hljs-value"><span class="hljs-string">"john.doe@example.com"</span></span>,
|
||||||
"<span class="hljs-attribute">html</span>": <span class="hljs-value"><span class="hljs-string">"<html><head></head><body>This is a test message!</body></html>"</span></span>,
|
"<span class="hljs-attribute">position</span>": <span class="hljs-value"><span class="hljs-string">"System Administrator"</span>
|
||||||
"<span class="hljs-attribute">attachments</span>": <span class="hljs-value">[]</span>,
|
|
||||||
"<span class="hljs-attribute">modified_date</span>": <span class="hljs-value"><span class="hljs-string">"2015-01-01T01:02:03.000000Z"</span>
|
|
||||||
</span>}</code></pre><div style="height: 1px;"></div><h5>Schema</h5><pre><code>{
|
|
||||||
"<span class="hljs-attribute">type</span>": <span class="hljs-value"><span class="hljs-string">"object"</span></span>,
|
|
||||||
"<span class="hljs-attribute">properties</span>": <span class="hljs-value">{
|
|
||||||
"<span class="hljs-attribute">id</span>": <span class="hljs-value">{
|
|
||||||
"<span class="hljs-attribute">type</span>": <span class="hljs-value"><span class="hljs-string">"number"</span></span>,
|
|
||||||
"<span class="hljs-attribute">description</span>": <span class="hljs-value"><span class="hljs-string">"Unique identifier"</span>
|
|
||||||
</span>}</span>,
|
|
||||||
"<span class="hljs-attribute">name</span>": <span class="hljs-value">{
|
|
||||||
"<span class="hljs-attribute">type</span>": <span class="hljs-value"><span class="hljs-string">"string"</span></span>,
|
|
||||||
"<span class="hljs-attribute">description</span>": <span class="hljs-value"><span class="hljs-string">"Name of template"</span>
|
|
||||||
</span>}</span>,
|
|
||||||
"<span class="hljs-attribute">subject</span>": <span class="hljs-value">{
|
|
||||||
"<span class="hljs-attribute">type</span>": <span class="hljs-value"><span class="hljs-string">"string"</span></span>,
|
|
||||||
"<span class="hljs-attribute">description</span>": <span class="hljs-value"><span class="hljs-string">"Subject of email sent to users"</span>
|
|
||||||
</span>}</span>,
|
|
||||||
"<span class="hljs-attribute">text</span>": <span class="hljs-value">{
|
|
||||||
"<span class="hljs-attribute">type</span>": <span class="hljs-value"><span class="hljs-string">"string"</span></span>,
|
|
||||||
"<span class="hljs-attribute">description</span>": <span class="hljs-value"><span class="hljs-string">"Raw text of email sent to users"</span>
|
|
||||||
</span>}</span>,
|
|
||||||
"<span class="hljs-attribute">html</span>": <span class="hljs-value">{
|
|
||||||
"<span class="hljs-attribute">type</span>": <span class="hljs-value"><span class="hljs-string">"string"</span></span>,
|
|
||||||
"<span class="hljs-attribute">description</span>": <span class="hljs-value"><span class="hljs-string">"HTML of email sent to users"</span>
|
|
||||||
</span>}</span>,
|
|
||||||
"<span class="hljs-attribute">attachments</span>": <span class="hljs-value">{
|
|
||||||
"<span class="hljs-attribute">type</span>": <span class="hljs-value"><span class="hljs-string">"array"</span></span>,
|
|
||||||
"<span class="hljs-attribute">description</span>": <span class="hljs-value"><span class="hljs-string">"The attachments sent with the email template"</span>
|
|
||||||
</span>}</span>,
|
|
||||||
"<span class="hljs-attribute">modified_date</span>": <span class="hljs-value">{
|
|
||||||
"<span class="hljs-attribute">type</span>": <span class="hljs-value"><span class="hljs-string">"string"</span></span>,
|
|
||||||
"<span class="hljs-attribute">description</span>": <span class="hljs-value"><span class="hljs-string">"Date the Template was last modified"</span>
|
|
||||||
</span>}
|
</span>}
|
||||||
</span>}</span>,
|
]</code></pre><div style="height: 1px;"></div><h5>Schema</h5><pre><code>{
|
||||||
"<span class="hljs-attribute">required</span>": <span class="hljs-value">[
|
|
||||||
<span class="hljs-string">"id"</span>,
|
|
||||||
<span class="hljs-string">"name"</span>
|
|
||||||
]</span>,
|
|
||||||
"<span class="hljs-attribute">$schema</span>": <span class="hljs-value"><span class="hljs-string">"http://json-schema.org/draft-04/schema#"</span>
|
|
||||||
</span>}</code></pre><div style="height: 1px;"></div></div></div><div class="title"><strong>Response <code>201</code></strong><div class="collapse-button"><span class="close">Hide</span><span class="open">Show</span></div></div><div class="collapse-content"><div class="inner"><h5>Headers</h5><pre><code><span class="hljs-attribute">Content-Type</span>: <span class="hljs-string">application/json</span></code></pre><div style="height: 1px;"></div><h5>Body</h5><pre><code>{
|
|
||||||
"<span class="hljs-attribute">id</span>": <span class="hljs-value"><span class="hljs-number">1</span></span>,
|
|
||||||
"<span class="hljs-attribute">name</span>": <span class="hljs-value"><span class="hljs-string">"Example Template"</span></span>,
|
|
||||||
"<span class="hljs-attribute">subject</span>": <span class="hljs-value"><span class="hljs-string">"Example email template subject"</span></span>,
|
|
||||||
"<span class="hljs-attribute">text</span>": <span class="hljs-value"><span class="hljs-string">"This is a test message!"</span></span>,
|
|
||||||
"<span class="hljs-attribute">html</span>": <span class="hljs-value"><span class="hljs-string">"<html><head></head><body>This is a test message!</body></html>"</span></span>,
|
|
||||||
"<span class="hljs-attribute">attachments</span>": <span class="hljs-value">[]</span>,
|
|
||||||
"<span class="hljs-attribute">modified_date</span>": <span class="hljs-value"><span class="hljs-string">"2015-01-01T01:02:03.000000Z"</span>
|
|
||||||
</span>}</code></pre><div style="height: 1px;"></div><h5>Schema</h5><pre><code>{
|
|
||||||
"<span class="hljs-attribute">type</span>": <span class="hljs-value"><span class="hljs-string">"object"</span></span>,
|
|
||||||
"<span class="hljs-attribute">properties</span>": <span class="hljs-value">{
|
|
||||||
"<span class="hljs-attribute">id</span>": <span class="hljs-value">{
|
|
||||||
"<span class="hljs-attribute">type</span>": <span class="hljs-value"><span class="hljs-string">"number"</span></span>,
|
|
||||||
"<span class="hljs-attribute">description</span>": <span class="hljs-value"><span class="hljs-string">"Unique identifier"</span>
|
|
||||||
</span>}</span>,
|
|
||||||
"<span class="hljs-attribute">name</span>": <span class="hljs-value">{
|
|
||||||
"<span class="hljs-attribute">type</span>": <span class="hljs-value"><span class="hljs-string">"string"</span></span>,
|
|
||||||
"<span class="hljs-attribute">description</span>": <span class="hljs-value"><span class="hljs-string">"Name of template"</span>
|
|
||||||
</span>}</span>,
|
|
||||||
"<span class="hljs-attribute">subject</span>": <span class="hljs-value">{
|
|
||||||
"<span class="hljs-attribute">type</span>": <span class="hljs-value"><span class="hljs-string">"string"</span></span>,
|
|
||||||
"<span class="hljs-attribute">description</span>": <span class="hljs-value"><span class="hljs-string">"Subject of email sent to users"</span>
|
|
||||||
</span>}</span>,
|
|
||||||
"<span class="hljs-attribute">text</span>": <span class="hljs-value">{
|
|
||||||
"<span class="hljs-attribute">type</span>": <span class="hljs-value"><span class="hljs-string">"string"</span></span>,
|
|
||||||
"<span class="hljs-attribute">description</span>": <span class="hljs-value"><span class="hljs-string">"Raw text of email sent to users"</span>
|
|
||||||
</span>}</span>,
|
|
||||||
"<span class="hljs-attribute">html</span>": <span class="hljs-value">{
|
|
||||||
"<span class="hljs-attribute">type</span>": <span class="hljs-value"><span class="hljs-string">"string"</span></span>,
|
|
||||||
"<span class="hljs-attribute">description</span>": <span class="hljs-value"><span class="hljs-string">"HTML of email sent to users"</span>
|
|
||||||
</span>}</span>,
|
|
||||||
"<span class="hljs-attribute">attachments</span>": <span class="hljs-value">{
|
|
||||||
"<span class="hljs-attribute">type</span>": <span class="hljs-value"><span class="hljs-string">"array"</span></span>,
|
"<span class="hljs-attribute">type</span>": <span class="hljs-value"><span class="hljs-string">"array"</span></span>,
|
||||||
"<span class="hljs-attribute">description</span>": <span class="hljs-value"><span class="hljs-string">"The attachments sent with the email template"</span>
|
|
||||||
</span>}</span>,
|
|
||||||
"<span class="hljs-attribute">modified_date</span>": <span class="hljs-value">{
|
|
||||||
"<span class="hljs-attribute">type</span>": <span class="hljs-value"><span class="hljs-string">"string"</span></span>,
|
|
||||||
"<span class="hljs-attribute">description</span>": <span class="hljs-value"><span class="hljs-string">"Date the Template was last modified"</span>
|
|
||||||
</span>}
|
|
||||||
</span>}</span>,
|
|
||||||
"<span class="hljs-attribute">required</span>": <span class="hljs-value">[
|
|
||||||
<span class="hljs-string">"id"</span>,
|
|
||||||
<span class="hljs-string">"name"</span>
|
|
||||||
]</span>,
|
|
||||||
"<span class="hljs-attribute">$schema</span>": <span class="hljs-value"><span class="hljs-string">"http://json-schema.org/draft-04/schema#"</span>
|
"<span class="hljs-attribute">$schema</span>": <span class="hljs-value"><span class="hljs-string">"http://json-schema.org/draft-04/schema#"</span>
|
||||||
</span>}</code></pre><div style="height: 1px;"></div></div></div><div class="title"><strong>Response <code>400</code></strong><div class="collapse-button"><span class="close">Hide</span><span class="open">Show</span></div></div><div class="collapse-content"><div class="inner"><h5>Headers</h5><pre><code><span class="hljs-attribute">Content-Type</span>: <span class="hljs-string">application/json</span></code></pre><div style="height: 1px;"></div><h5>Body</h5><pre><code>{
|
</span>}</code></pre><div style="height: 1px;"></div></div></div><div class="title"><strong>Response <code>400</code></strong><div class="collapse-button"><span class="close">Hide</span><span class="open">Show</span></div></div><div class="collapse-content"><div class="inner"><h5>Headers</h5><pre><code><span class="hljs-attribute">Content-Type</span>: <span class="hljs-string">application/json</span></code></pre><div style="height: 1px;"></div><h5>Body</h5><pre><code>{
|
||||||
"<span class="hljs-attribute">message</span>": <span class="hljs-value"><span class="hljs-string">"\"Error message\""</span></span>,
|
"<span class="hljs-attribute">message</span>": <span class="hljs-value"><span class="hljs-string">"\"Error message\""</span></span>,
|
||||||
|
|
|
@ -184,11 +184,6 @@ Get a campaign by its ID.
|
||||||
### Delete a Campaign [DELETE]
|
### Delete a Campaign [DELETE]
|
||||||
Delete a campaign by its ID.
|
Delete a campaign by its ID.
|
||||||
|
|
||||||
::: warning
|
|
||||||
#### <i class="fa fa-warning"></i> Caution
|
|
||||||
If the value for `title` or `body` is `null` or `undefined`, then the corresponding value is not modified on the server. However, if you send an empty string instead then it will **permanently overwrite** the original value.
|
|
||||||
:::
|
|
||||||
|
|
||||||
+ Parameters
|
+ Parameters
|
||||||
|
|
||||||
+ id: `1` (required, number) - The Campaign ID
|
+ id: `1` (required, number) - The Campaign ID
|
||||||
|
@ -275,11 +270,6 @@ Get a template by its ID.
|
||||||
### Delete a Template [DELETE]
|
### Delete a Template [DELETE]
|
||||||
Delete a template by its ID.
|
Delete a template by its ID.
|
||||||
|
|
||||||
::: warning
|
|
||||||
#### <i class="fa fa-warning"></i> Caution
|
|
||||||
If the value for `title` or `body` is `null` or `undefined`, then the corresponding value is not modified on the server. However, if you send an empty string instead then it will **permanently overwrite** the original value.
|
|
||||||
:::
|
|
||||||
|
|
||||||
+ Parameters
|
+ Parameters
|
||||||
|
|
||||||
+ id: `1` (required, number) - The Template ID
|
+ id: `1` (required, number) - The Template ID
|
||||||
|
@ -363,11 +353,6 @@ Get a group by its ID.
|
||||||
### Delete a Group [DELETE]
|
### Delete a Group [DELETE]
|
||||||
Delete a Group by its ID.
|
Delete a Group by its ID.
|
||||||
|
|
||||||
::: warning
|
|
||||||
#### <i class="fa fa-warning"></i> Caution
|
|
||||||
If the value for `title` or `body` is `null` or `undefined`, then the corresponding value is not modified on the server. However, if you send an empty string instead then it will **permanently overwrite** the original value.
|
|
||||||
:::
|
|
||||||
|
|
||||||
+ Parameters
|
+ Parameters
|
||||||
|
|
||||||
+ id: `1` (required, number) - The Template ID
|
+ id: `1` (required, number) - The Template ID
|
||||||
|
@ -465,11 +450,6 @@ Modify a page by its ID.
|
||||||
### Delete a Page [DELETE]
|
### Delete a Page [DELETE]
|
||||||
Delete a page by its ID.
|
Delete a page by its ID.
|
||||||
|
|
||||||
::: warning
|
|
||||||
#### <i class="fa fa-warning"></i> Caution
|
|
||||||
If the value for `title` or `body` is `null` or `undefined`, then the corresponding value is not modified on the server. However, if you send an empty string instead then it will **permanently overwrite** the original value.
|
|
||||||
:::
|
|
||||||
|
|
||||||
+ Parameters
|
+ Parameters
|
||||||
|
|
||||||
+ id: `1` (required, number) - The Page ID
|
+ id: `1` (required, number) - The Page ID
|
||||||
|
@ -501,16 +481,26 @@ This endpoint allows you to import a group from a CSV.
|
||||||
|
|
||||||
The fields expected in the CSV are as follows:
|
The fields expected in the CSV are as follows:
|
||||||
|
|
||||||
+ Test
|
+ First Name
|
||||||
+ two
|
+ Last Name
|
||||||
|
+ Position
|
||||||
|
+ Email
|
||||||
|
+ Company
|
||||||
|
|
||||||
+ Request (application/json)
|
+ Request (multipart/form-data; boundary=----BOUNDARY)
|
||||||
|
|
||||||
+ Attributes (Template)
|
+ Body
|
||||||
|
|
||||||
|
------BOUNDARY
|
||||||
|
Content-Disposition: form-data; name="files[]"; filename="filename.csv"
|
||||||
|
Content-Type: application/vnd.ms-excel
|
||||||
|
|
||||||
|
[File Content]
|
||||||
|
------BOUNDARY
|
||||||
|
|
||||||
+ Response 201 (application/json)
|
+ Response 201 (application/json)
|
||||||
|
|
||||||
+ Attributes (Template)
|
+ Attributes (TargetList)
|
||||||
|
|
||||||
+ Response 400 (application/json)
|
+ Response 400 (application/json)
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue