2012-04-13 11:24:57 +02:00
|
|
|
<li class="{{ data.method|lower }} operation">
|
|
|
|
<div class="heading toggler">
|
2012-05-24 01:22:45 +02:00
|
|
|
<h3>
|
|
|
|
<span class="http_method">
|
|
|
|
<a>{{ data.method|upper }}</a>
|
|
|
|
</span>
|
|
|
|
<span class="path">
|
|
|
|
{{ data.uri }}
|
|
|
|
</span>
|
|
|
|
</h3>
|
|
|
|
<ul class="options">
|
|
|
|
{% if data.description is defined %}
|
|
|
|
<li>{{ data.description }}</li>
|
|
|
|
{% endif %}
|
|
|
|
</ul>
|
2012-04-13 11:24:57 +02:00
|
|
|
</div>
|
2012-05-24 01:22:45 +02:00
|
|
|
|
2012-04-13 14:00:13 +02:00
|
|
|
<div class="content" style="display: {% if displayContent is defined and displayContent == true %}display{% else %}none{% endif %};">
|
2012-05-24 01:22:45 +02:00
|
|
|
<ul class="tabs">
|
|
|
|
<li class="selected" data-pane="content">Documentation</li>
|
|
|
|
<li data-pane="sandbox">Sandbox</li>
|
|
|
|
</ul>
|
|
|
|
|
|
|
|
<div class="panes">
|
|
|
|
<div class="pane content selected">
|
|
|
|
{% if data.requirements is defined and data.requirements is not empty %}
|
|
|
|
<h4>Requirements</h4>
|
|
|
|
<table class="fullwidth">
|
|
|
|
<thead>
|
2012-04-13 11:24:57 +02:00
|
|
|
<tr>
|
2012-05-24 01:22:45 +02:00
|
|
|
<th>Name</th>
|
|
|
|
<th>Value</th>
|
|
|
|
<th>Type</th>
|
|
|
|
<th>Description</th>
|
2012-04-13 11:24:57 +02:00
|
|
|
</tr>
|
2012-05-24 01:22:45 +02:00
|
|
|
</thead>
|
|
|
|
<tbody>
|
|
|
|
{% for name, infos in data.requirements %}
|
|
|
|
<tr>
|
|
|
|
<td>{{ name }}</td>
|
|
|
|
<td>{{ infos.value }}</td>
|
|
|
|
<td>{{ infos.type }}</td>
|
|
|
|
<td>{{ infos.description }}</td>
|
|
|
|
</tr>
|
|
|
|
{% endfor %}
|
|
|
|
</tbody>
|
|
|
|
</table>
|
|
|
|
{% endif %}
|
2012-04-13 11:24:57 +02:00
|
|
|
|
2012-05-24 01:22:45 +02:00
|
|
|
{% if data.filters is defined and data.filters is not empty %}
|
|
|
|
<h4>Filters</h4>
|
|
|
|
<table class="fullwidth">
|
|
|
|
<thead>
|
|
|
|
<tr>
|
|
|
|
<th>Name</th>
|
|
|
|
<th>Information</th>
|
|
|
|
</tr>
|
|
|
|
</thead>
|
|
|
|
<tbody>
|
|
|
|
{% for name, infos in data.filters %}
|
2012-04-13 11:24:57 +02:00
|
|
|
<tr>
|
|
|
|
<td>{{ name }}</td>
|
2012-05-24 01:22:45 +02:00
|
|
|
<td>
|
|
|
|
<ul>
|
|
|
|
{% for key, value in infos %}
|
|
|
|
<li><em>{{ key }}</em> : {{ value|json_encode|trim('"') }}</li>
|
|
|
|
{% endfor %}
|
|
|
|
</ul>
|
|
|
|
</td>
|
2012-04-13 11:24:57 +02:00
|
|
|
</tr>
|
|
|
|
{% endfor %}
|
2012-05-24 01:22:45 +02:00
|
|
|
</tbody>
|
|
|
|
</table>
|
|
|
|
{% endif %}
|
|
|
|
|
|
|
|
{% if data.parameters is defined and data.parameters is not empty %}
|
|
|
|
<h4>Parameters</h4>
|
|
|
|
<table class='fullwidth'>
|
|
|
|
<thead>
|
|
|
|
<tr>
|
|
|
|
<th>Parameter</th>
|
|
|
|
<th>Type</th>
|
|
|
|
<th>Required?</th>
|
|
|
|
<th>Description</th>
|
|
|
|
</tr>
|
|
|
|
</thead>
|
|
|
|
<tbody>
|
|
|
|
{% for name, infos in data.parameters %}
|
|
|
|
<tr>
|
|
|
|
<td>{{ name }}</td>
|
|
|
|
<td>{{ infos.dataType }}</td>
|
|
|
|
<td>{{ infos.required ? 'true' : 'false' }}</td>
|
|
|
|
<td>{{ infos.description }}</td>
|
|
|
|
</tr>
|
|
|
|
{% endfor %}
|
|
|
|
</tbody>
|
|
|
|
</table>
|
|
|
|
{% endif %}
|
|
|
|
</div>
|
|
|
|
|
|
|
|
<div class="pane sandbox">
|
|
|
|
<form method="{{ data.method|upper }}" action="{{ data.uri }}">
|
|
|
|
<fieldset class="parameters">
|
|
|
|
<legend>Parameters</legend>
|
|
|
|
{% if data.filters is defined %}
|
|
|
|
{% for name, infos in data.filters %}
|
|
|
|
<p class="tuple">
|
|
|
|
<input type="text" class="key" value="{{ name }}" placeholder="Key" />
|
|
|
|
<span>=</span>
|
|
|
|
<input type="text" class="value" placeholder="{% if infos.description is defined %}{{ infos.description }}{% else %}Value{% endif %}" /> <span class="remove">-</span>
|
|
|
|
</p>
|
|
|
|
{% endfor %}
|
|
|
|
{% endif %}
|
|
|
|
|
|
|
|
<button class="add">New parameter</button>
|
|
|
|
</fieldset>
|
|
|
|
|
|
|
|
<fieldset class="headers">
|
|
|
|
<legend>Headers</legend>
|
|
|
|
|
|
|
|
<p class="tuple">
|
|
|
|
<input type="text" class="key" placeholder="Key" />
|
|
|
|
<span>=</span>
|
|
|
|
<input type="text" class="value" placeholder="Value" /> <span class="remove">-</span>
|
|
|
|
</p>
|
|
|
|
|
|
|
|
<button class="add">New header</button>
|
|
|
|
</fieldset>
|
|
|
|
|
|
|
|
<div class="buttons">
|
|
|
|
|
|
|
|
<input type="submit" value="Try!" />
|
|
|
|
</div>
|
|
|
|
</form>
|
|
|
|
|
|
|
|
<script type="text/x-tmpl" class="tuple_template">
|
|
|
|
<p class="tuple">
|
|
|
|
<input type="text" class="key" placeholder="Key" />
|
|
|
|
<span>=</span>
|
|
|
|
<input type="text" class="value" placeholder="Value" /> <span class="remove">-</span>
|
|
|
|
</p>
|
|
|
|
</script>
|
|
|
|
|
|
|
|
<div class="result">
|
|
|
|
<h4>Request URL</h4>
|
|
|
|
<pre class="url"></pre>
|
|
|
|
|
2012-06-28 10:37:35 +02:00
|
|
|
<h4>Response Body <small>[<a href="" class="to-raw">Raw</a>]</small></h4>
|
2012-05-24 01:22:45 +02:00
|
|
|
<pre class="response prettyprint"></pre>
|
|
|
|
|
2012-06-28 10:37:35 +02:00
|
|
|
<h4>Response Headers</h4>
|
2012-05-24 01:22:45 +02:00
|
|
|
<pre class="headers"></pre>
|
|
|
|
</div>
|
|
|
|
</div>
|
|
|
|
</div>
|
2012-04-13 11:24:57 +02:00
|
|
|
</div>
|
|
|
|
</li>
|