Corrected api-docs for channel variables
[asterisk/asterisk.git] / rest-api / api-docs / asterisk.json
1 {
2         "_copyright": "Copyright (C) 2012 - 2013, Digium, Inc.",
3         "_author": "David M. Lee, II <dlee@digium.com>",
4         "_svn_revision": "$Revision$",
5         "apiVersion": "0.0.1",
6         "swaggerVersion": "1.1",
7         "basePath": "http://localhost:8088/stasis",
8         "resourcePath": "/api-docs/asterisk.{format}",
9         "apis": [
10                 {
11                         "path": "/asterisk/info",
12                         "description": "Asterisk system information (similar to core show settings)",
13                         "operations": [
14                                 {
15                                         "httpMethod": "GET",
16                                         "summary": "Gets Asterisk system information.",
17                                         "nickname": "getAsteriskInfo",
18                                         "responseClass": "AsteriskInfo",
19                                         "parameters": [
20                                                 {
21                                                         "name": "only",
22                                                         "description": "Filter information returned",
23                                                         "paramType": "query",
24                                                         "required": false,
25                                                         "allowMultiple": true,
26                                                         "dataType": "string",
27                                                         "allowableValues": {
28                                                                 "valueType": "LIST",
29                                                                 "values": [
30                                                                         "version",
31                                                                         "modules",
32                                                                         "uptime"
33                                                                 ]
34                                                         }
35                                                 }
36                                         ]
37                                 }
38                         ]
39                 },
40                 {
41                         "path": "/asterisk/variable",
42                         "description": "Global variables",
43                         "operations": [
44                                 {
45                                         "httpMethod": "GET",
46                                         "summary": "Get the value of a global variable.",
47                                         "nickname": "getGlobalVar",
48                                         "responseClass": "Variable",
49                                         "parameters": [
50                                                 {
51                                                         "name": "variable",
52                                                         "description": "The variable to get",
53                                                         "paramType": "query",
54                                                         "required": true,
55                                                         "allowMultiple": false,
56                                                         "dataType": "string"
57                                                 }
58                                         ]
59                                 },
60                                 {
61                                         "httpMethod": "POST",
62                                         "summary": "Set the value of a global variable.",
63                                         "nickname": "setGlobalVar",
64                                         "responseClass": "void",
65                                         "parameters": [
66                                                 {
67                                                         "name": "variable",
68                                                         "description": "The variable to set",
69                                                         "paramType": "query",
70                                                         "required": true,
71                                                         "allowMultiple": false,
72                                                         "dataType": "string"
73                                                 },
74                                                 {
75                                                         "name": "value",
76                                                         "description": "The value to set the variable to",
77                                                         "paramType": "query",
78                                                         "required": false,
79                                                         "allowMultiple": false,
80                                                         "dataType": "string"
81                                                 }
82                                         ]
83                                 }
84                         ]
85                 }
86         ],
87         "models": {
88                 "AsteriskInfo": {
89                         "id": "AsteriskInfo",
90                         "description": "Asterisk system information",
91                         "properties": {}
92                 },
93                 "Variable": {
94                         "id": "Variable",
95                         "description": "The value of a channel variable",
96                         "properties": {
97                                 "value": {
98                                         "required": true,
99                                         "type": "string",
100                                         "description": "The value of the variable requested"
101                                 }
102                         }
103                 }
104         }
105 }