Asterisk-13-Applications-REST-API_29394318.html 7.0 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171
  1. <!DOCTYPE html>
  2. <html>
  3. <head>
  4. <title>Asterisk Project : Asterisk 13 Applications REST API</title>
  5. <link rel="stylesheet" href="styles/site.css" type="text/css" />
  6. <META http-equiv="Content-Type" content="text/html; charset=UTF-8">
  7. </head>
  8. <body class="theme-default aui-theme-default">
  9. <div id="page">
  10. <div id="main" class="aui-page-panel">
  11. <div id="main-header">
  12. <div id="breadcrumb-section">
  13. <ol id="breadcrumbs">
  14. <li class="first">
  15. <span><a href="index.html">Asterisk Project</a></span>
  16. </li>
  17. <li>
  18. <span><a href="Asterisk-13-Command-Reference_29394274.html">Asterisk 13 Command Reference</a></span>
  19. </li>
  20. <li>
  21. <span><a href="Asterisk-13-ARI_29394283.html">Asterisk 13 ARI</a></span>
  22. </li>
  23. </ol>
  24. </div>
  25. <h1 id="title-heading" class="pagetitle">
  26. <span id="title-text">
  27. Asterisk Project : Asterisk 13 Applications REST API
  28. </span>
  29. </h1>
  30. </div>
  31. <div id="content" class="view">
  32. <div class="page-metadata">
  33. Created by <span class='author'> wikibot</span> on Aug 08, 2014
  34. </div>
  35. <div id="main-content" class="wiki-content group">
  36. <h1 id="Asterisk13ApplicationsRESTAPI-Applications">Applications</h1>
  37. <div class="table-wrap"><table class="confluenceTable"><tbody>
  38. <tr>
  39. <th class="confluenceTh"><p> Method </p></th>
  40. <th class="confluenceTh"><p> Path </p></th>
  41. <th class="confluenceTh"><p> Return Model </p></th>
  42. <th class="confluenceTh"><p> Summary </p></th>
  43. </tr>
  44. <tr>
  45. <td class="confluenceTd"><p> GET </p></td>
  46. <td class="confluenceTd"><p> <a href="Asterisk-13-Applications-REST-API_29394318.html">/applications</a> </p></td>
  47. <td class="confluenceTd"><p> <a href="Asterisk-13-REST-Data-Models_29394316.html#Asterisk13RESTDataModels-Application">List[Application]</a> </p></td>
  48. <td class="confluenceTd"><p> List all applications. </p></td>
  49. </tr>
  50. <tr>
  51. <td class="confluenceTd"><p> GET </p></td>
  52. <td class="confluenceTd"><p> <a href="Asterisk-13-Applications-REST-API_29394318.html">/applications/{applicationName}</a> </p></td>
  53. <td class="confluenceTd"><p> <a href="Asterisk-13-REST-Data-Models_29394316.html#Asterisk13RESTDataModels-Application">Application</a> </p></td>
  54. <td class="confluenceTd"><p> Get details of an application. </p></td>
  55. </tr>
  56. <tr>
  57. <td class="confluenceTd"><p> POST </p></td>
  58. <td class="confluenceTd"><p> <a href="Asterisk-13-Applications-REST-API_29394318.html">/applications/{applicationName}/subscription</a> </p></td>
  59. <td class="confluenceTd"><p> <a href="Asterisk-13-REST-Data-Models_29394316.html#Asterisk13RESTDataModels-Application">Application</a> </p></td>
  60. <td class="confluenceTd"><p> Subscribe an application to a event source. </p></td>
  61. </tr>
  62. <tr>
  63. <td class="confluenceTd"><p> DELETE </p></td>
  64. <td class="confluenceTd"><p> <a href="Asterisk-13-Applications-REST-API_29394318.html">/applications/{applicationName}/subscription</a> </p></td>
  65. <td class="confluenceTd"><p> <a href="Asterisk-13-REST-Data-Models_29394316.html#Asterisk13RESTDataModels-Application">Application</a> </p></td>
  66. <td class="confluenceTd"><p> Unsubscribe an application from an event source. </p></td>
  67. </tr>
  68. </tbody></table></div>
  69. <p><span class="confluence-anchor-link" id="Asterisk13ApplicationsRESTAPI-list"></span></p>
  70. <h2 id="Asterisk13ApplicationsRESTAPI-GET/applications">GET /applications</h2>
  71. <p>List all applications.</p>
  72. <p><span class="confluence-anchor-link" id="Asterisk13ApplicationsRESTAPI-get"></span></p>
  73. <h2 id="Asterisk13ApplicationsRESTAPI-GET/applications/{applicationName}">GET /applications/{applicationName}</h2>
  74. <p>Get details of an application.</p>
  75. <h3 id="Asterisk13ApplicationsRESTAPI-Pathparameters">Path parameters</h3>
  76. <ul>
  77. <li>applicationName: string - Application's name</li>
  78. </ul>
  79. <h3 id="Asterisk13ApplicationsRESTAPI-ErrorResponses">Error Responses</h3>
  80. <ul>
  81. <li>404 - Application does not exist.</li>
  82. </ul>
  83. <p><span class="confluence-anchor-link" id="Asterisk13ApplicationsRESTAPI-subscribe"></span></p>
  84. <h2 id="Asterisk13ApplicationsRESTAPI-POST/applications/{applicationName}/subscription">POST /applications/{applicationName}/subscription</h2>
  85. <p>Subscribe an application to a event source. Returns the state of the application after the subscriptions have changed</p>
  86. <h3 id="Asterisk13ApplicationsRESTAPI-Pathparameters.1">Path parameters</h3>
  87. <ul>
  88. <li>applicationName: string - Application's name</li>
  89. </ul>
  90. <h3 id="Asterisk13ApplicationsRESTAPI-Queryparameters">Query parameters</h3>
  91. <ul>
  92. <li>eventSource: string - <strong>(required)</strong> URI for event source (channel:{channelId}, bridge:{bridgeId}, endpoint:{tech}[/{resource}], deviceState:{deviceName}
  93. <ul>
  94. <li>Allows comma separated values.</li>
  95. </ul>
  96. </li>
  97. </ul>
  98. <h3 id="Asterisk13ApplicationsRESTAPI-ErrorResponses.1">Error Responses</h3>
  99. <ul>
  100. <li>400 - Missing parameter.</li>
  101. <li>404 - Application does not exist.</li>
  102. <li>422 - Event source does not exist.</li>
  103. </ul>
  104. <p><span class="confluence-anchor-link" id="Asterisk13ApplicationsRESTAPI-unsubscribe"></span></p>
  105. <h2 id="Asterisk13ApplicationsRESTAPI-DELETE/applications/{applicationName}/subscription">DELETE /applications/{applicationName}/subscription</h2>
  106. <p>Unsubscribe an application from an event source. Returns the state of the application after the subscriptions have changed</p>
  107. <h3 id="Asterisk13ApplicationsRESTAPI-Pathparameters.2">Path parameters</h3>
  108. <ul>
  109. <li>applicationName: string - Application's name</li>
  110. </ul>
  111. <h3 id="Asterisk13ApplicationsRESTAPI-Queryparameters.1">Query parameters</h3>
  112. <ul>
  113. <li>eventSource: string - <strong>(required)</strong> URI for event source (channel:{channelId}, bridge:{bridgeId}, endpoint:{tech}[/{resource}], deviceState:{deviceName}
  114. <ul>
  115. <li>Allows comma separated values.</li>
  116. </ul>
  117. </li>
  118. </ul>
  119. <h3 id="Asterisk13ApplicationsRESTAPI-ErrorResponses.2">Error Responses</h3>
  120. <ul>
  121. <li>400 - Missing parameter; event source scheme not recognized.</li>
  122. <li>404 - Application does not exist.</li>
  123. <li>409 - Application not subscribed to event source.</li>
  124. <li>422 - Event source does not exist.</li>
  125. </ul>
  126. </div>
  127. </div> </div>
  128. <div id="footer">
  129. <section class="footer-body">
  130. <p>Document generated by Confluence on Aug 11, 2014 13:40</p>
  131. </section>
  132. </div>
  133. </div> </body>
  134. </html>