definition-apiv3.js 2.2 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116
  1. const pkg = require('../../package.json');
  2. module.exports = {
  3. openapi: '3.0.1',
  4. info: {
  5. title: 'GROWI REST API v3',
  6. version: pkg.version,
  7. },
  8. servers: [
  9. {
  10. url: 'https://demo.growi.org/_api/v3',
  11. },
  12. ],
  13. security: [
  14. {
  15. api_key: [],
  16. },
  17. ],
  18. components: {
  19. securitySchemes: {
  20. api_key: {
  21. type: 'apiKey',
  22. name: 'access_token',
  23. in: 'query',
  24. },
  25. cookieAuth: {
  26. type: 'apiKey',
  27. in: 'cookie',
  28. name: 'connect.sid',
  29. },
  30. transferHeaderAuth: {
  31. type: 'apiKey',
  32. in: 'header',
  33. name: 'x-growi-transfer-key',
  34. },
  35. },
  36. },
  37. 'x-tagGroups': [
  38. {
  39. name: 'User API',
  40. tags: [
  41. 'Attachment',
  42. 'Bookmarks',
  43. 'BookmarkFolders',
  44. 'Page',
  45. 'Pages',
  46. 'PageListing',
  47. 'Revisions',
  48. 'ShareLinks',
  49. 'Users',
  50. 'UserUISettings',
  51. '',
  52. ],
  53. },
  54. {
  55. name: 'User Personal Settings API',
  56. tags: [
  57. 'GeneralSetting',
  58. 'EditorSetting',
  59. 'InAppNotificationSettings',
  60. '',
  61. '',
  62. '',
  63. '',
  64. '',
  65. ],
  66. },
  67. {
  68. name: 'System Management API',
  69. tags: [
  70. 'Home',
  71. 'Activity',
  72. 'AdminHome',
  73. 'AppSettings',
  74. 'ExternalUserGroups',
  75. 'SecuritySetting',
  76. 'MarkDownSetting',
  77. 'CustomizeSetting',
  78. 'Import',
  79. 'Export',
  80. 'GROWI to GROWI Transfer',
  81. 'MongoDB',
  82. 'NotificationSetting',
  83. 'Plugins',
  84. 'Questionnaire',
  85. 'QuestionnaireSetting',
  86. 'SlackIntegration',
  87. 'SlackIntegrationSettings',
  88. 'SlackIntegrationSettings (with proxy)',
  89. 'SlackIntegrationSettings (without proxy)',
  90. 'SlackIntegrationLegacySetting',
  91. 'ShareLink Management',
  92. 'Templates',
  93. 'Staff',
  94. 'UserGroupRelations',
  95. 'UserGroups',
  96. 'Users Management',
  97. 'FullTextSearch Management',
  98. 'Install',
  99. ],
  100. },
  101. {
  102. name: 'Public API',
  103. tags: [
  104. 'Healthcheck',
  105. 'Statistics',
  106. '',
  107. '',
  108. '',
  109. '',
  110. '',
  111. '',
  112. ],
  113. },
  114. ],
  115. };