soap_session.php 2.4 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103
  1. <?php
  2. /* For licensing terms, see /license.txt */
  3. /**
  4. * Configures the WSSession SOAP service
  5. * @package chamilo.webservices
  6. */
  7. require_once(dirname(__FILE__).'/webservice_session.php');
  8. require_once(dirname(__FILE__).'/soap.php');
  9. $s = WSSoapServer::singleton();
  10. $s->register(
  11. 'WSSession.CreateSession',
  12. array(
  13. 'secret_key' => 'xsd:string',
  14. 'name' => 'xsd:string',
  15. 'start_date' => 'xsd:string',
  16. 'end_date' => 'xsd:string',
  17. 'nb_days_access_before' => 'xsd:int',
  18. 'nb_days_access_after' => 'xsd:int',
  19. 'nolimit' => 'xsd:int',
  20. 'visibility' => 'xsd:int',
  21. 'user_id_field_name' => 'xsd:string',
  22. 'user_id_value' => 'xsd:string',
  23. 'session_id_field_name' => 'xsd:string',
  24. 'session_id_value' => 'xsd:string',
  25. 'extras' => 'tns:extra_field'
  26. ),
  27. array('return' => 'xsd:int')
  28. );
  29. $s->register(
  30. 'WSSession.DeleteSession',
  31. array(
  32. 'secret_key' => 'xsd:string',
  33. 'session_id_field_name' => 'xsd:string',
  34. 'session_id_value' => 'xsd:string'
  35. )
  36. );
  37. $s->register(
  38. 'WSSession.EditSession',
  39. array(
  40. 'secret_key' => 'xsd:string',
  41. 'name' => 'xsd:string',
  42. 'start_date' => 'xsd:string',
  43. 'end_date' => 'xsd:string',
  44. 'nb_days_access_before' => 'xsd:int',
  45. 'nb_days_access_after' => 'xsd:int',
  46. 'nolimit' => 'xsd:int',
  47. 'visibility' => 'xsd:int',
  48. 'user_id_field_name' => 'xsd:string',
  49. 'user_id_value' => 'xsd:string',
  50. 'session_id_field_name' => 'xsd:string',
  51. 'session_id_value' => 'xsd:string',
  52. 'extras' => 'tns:extra_field'
  53. )
  54. );
  55. $s->register(
  56. 'WSSession.SubscribeUserToSession',
  57. array(
  58. 'secret_key' => 'xsd:string',
  59. 'user_id_field_name' => 'xsd:string',
  60. 'user_id_value' => 'xsd:string',
  61. 'session_id_field_name' => 'xsd:string',
  62. 'session_id_value' => 'xsd:string'
  63. )
  64. );
  65. $s->register(
  66. 'WSSession.UnsubscribeUserFromSession',
  67. array(
  68. 'secret_key' => 'xsd:string',
  69. 'user_id_field_name' => 'xsd:string',
  70. 'user_id_value' => 'xsd:string',
  71. 'session_id_field_name' => 'xsd:string',
  72. 'session_id_value' => 'xsd:string'
  73. )
  74. );
  75. $s->register(
  76. 'WSSession.SubscribeCourseToSession',
  77. array(
  78. 'secret_key' => 'xsd:string',
  79. 'course_id_field_name' => 'xsd:string',
  80. 'course_id_value' => 'xsd:string',
  81. 'session_id_field_name' => 'xsd:string',
  82. 'session_id_value' => 'xsd:string'
  83. )
  84. );
  85. $s->register(
  86. 'WSSession.UnsubscribeCourseFromSession',
  87. array(
  88. 'secret_key' => 'xsd:string',
  89. 'course_id_field_name' => 'xsd:string',
  90. 'course_id_value' => 'xsd:string',
  91. 'session_id_field_name' => 'xsd:string',
  92. 'session_id_value' => 'xsd:string'
  93. )
  94. );