~singpolyma/asterisk

ref: upstream/16.2.1_dfsg asterisk/rest-api-templates/api.wiki.mustache -rw-r--r-- 2.2 KiB
fe6d69c0Stephen Paul Weber import-tar 7 months ago
                                                                                
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
{{#api_declaration}}
h1. {{name_title}}

|| Method || Path<br>h5. Parameters are case-sensitive || Return Model || Summary ||

{{#apis}}
{{#operations}}
| {{http_method}} | [{{wiki_path}}|#{{nickname}}] | {{#response_class}}{{#is_primitive}}{{name}}{{/is_primitive}}{{^is_primitive}}[{{wiki_name}}|{{wiki_prefix}} REST Data Models#{{singular_name}}]{{/is_primitive}}{{/response_class}} | {{{summary}}} |
{{/operations}}
{{/apis}}
{{#apis}}
{{#operations}}

{anchor:{{nickname}}}
h2. {{nickname}}: {{http_method}} {{wiki_path}}

{{{wiki_summary}}}{{#wiki_notes}} {{{wiki_notes}}}{{/wiki_notes}}
{{#has_path_parameters}}

h3. Path parameters
Parameters are case-sensitive.
{{#path_parameters}}
* {{name}}: _{{data_type}}_ - {{{wiki_description}}}
{{#default_value}}
** Default: {{default_value}}
{{/default_value}}
{{#wiki_allowable_values}}
** {{wiki_allowable_values}}
{{/wiki_allowable_values}}
{{/path_parameters}}
{{/has_path_parameters}}
{{#has_query_parameters}}

h3. Query parameters
{{#query_parameters}}
* {{name}}: _{{data_type}}_ -{{#required}} *(required)*{{/required}} {{{wiki_description}}}
{{#default_value}}
** Default: {{default_value}}
{{/default_value}}
{{#wiki_allowable_values}}
** {{wiki_allowable_values}}
{{/wiki_allowable_values}}
{{#allow_multiple}}
** Allows comma separated values.
{{/allow_multiple}}
{{/query_parameters}}
{{/has_query_parameters}}
{{#has_body_parameter}}

h3. Body parameter
{{#body_parameter}}
* {{name}}: {{data_type}}{{#default_value}} = {{default_value}}{{/default_value}} -{{#required}} *(required)*{{/required}} {{{wiki_description}}}
{{#allow_multiple}}
** Allows comma separated values.
{{/allow_multiple}}
{{/body_parameter}}
{{/has_body_parameter}}
{{#has_header_parameters}}

h3. Header parameters
{{#header_parameters}}
* {{name}}: {{data_type}}{{#default_value}} = {{default_value}}{{/default_value}} -{{#required}} *(required)*{{/required}} {{{wiki_description}}}
{{#allow_multiple}}
** Allows comma separated values.
{{/allow_multiple}}
{{/header_parameters}}
{{/has_header_parameters}}
{{#has_error_responses}}

h3. Error Responses
{{#error_responses}}
* {{code}} - {{{wiki_reason}}}
{{/error_responses}}
{{/has_error_responses}}
{{/operations}}
{{/apis}}
{{/api_declaration}}