definition-apiv3.js 2.1 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110
  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. 'Revisions',
  47. 'ShareLinks',
  48. 'Users',
  49. 'UserUISettings',
  50. '',
  51. ],
  52. },
  53. {
  54. name: 'User Personal Settings API',
  55. tags: [
  56. 'GeneralSetting',
  57. 'EditorSetting',
  58. 'InAppNotificationSettings',
  59. '',
  60. '',
  61. '',
  62. '',
  63. '',
  64. ],
  65. },
  66. {
  67. name: 'System Management API',
  68. tags: [
  69. 'Home',
  70. 'AdminHome',
  71. 'AppSettings',
  72. 'ExternalUserGroups',
  73. 'SecuritySetting',
  74. 'MarkDownSetting',
  75. 'CustomizeSetting',
  76. 'Import',
  77. 'Export',
  78. 'GROWI to GROWI Transfer',
  79. 'MongoDB',
  80. 'NotificationSetting',
  81. 'QuestionnaireSetting',
  82. 'SlackIntegrationSettings',
  83. 'SlackIntegrationSettings (with proxy)',
  84. 'SlackIntegrationSettings (without proxy)',
  85. 'SlackIntegrationLegacySetting',
  86. 'ShareLink Management',
  87. 'Staff',
  88. 'UserGroupRelations',
  89. 'UserGroups',
  90. 'Users Management',
  91. 'FullTextSearch Management',
  92. 'Install',
  93. ],
  94. },
  95. {
  96. name: 'Public API',
  97. tags: [
  98. 'Healthcheck',
  99. 'Statistics',
  100. '',
  101. '',
  102. '',
  103. '',
  104. '',
  105. '',
  106. ],
  107. },
  108. ],
  109. };