You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

123 lines
3.8 KiB

5 years ago
5 years ago
5 years ago
5 years ago
5 years ago
  1. # ===============================================
  2. # SYSTEM
  3. # ===============================================
  4. extend type Query {
  5. system: SystemQuery
  6. }
  7. extend type Mutation {
  8. system: SystemMutation
  9. }
  10. # -----------------------------------------------
  11. # QUERIES
  12. # -----------------------------------------------
  13. type SystemQuery {
  14. flags: [SystemFlag] @auth(requires: ["manage:system"])
  15. info: SystemInfo
  16. extensions: [SystemExtension]! @auth(requires: ["manage:system"])
  17. }
  18. # -----------------------------------------------
  19. # MUTATIONS
  20. # -----------------------------------------------
  21. type SystemMutation {
  22. updateFlags(
  23. flags: [SystemFlagInput]!
  24. ): DefaultResponse @auth(requires: ["manage:system"])
  25. resetTelemetryClientId: DefaultResponse @auth(requires: ["manage:system"])
  26. setTelemetry(
  27. enabled: Boolean!
  28. ): DefaultResponse @auth(requires: ["manage:system"])
  29. performUpgrade: DefaultResponse @auth(requires: ["manage:system"])
  30. importUsersFromV1(
  31. mongoDbConnString: String!
  32. groupMode: SystemImportUsersGroupMode!
  33. ): SystemImportUsersResponse @auth(requires: ["manage:system"])
  34. setHTTPSRedirection(
  35. enabled: Boolean!
  36. ): DefaultResponse @auth(requires: ["manage:system"])
  37. renewHTTPSCertificate: DefaultResponse @auth(requires: ["manage:system"])
  38. }
  39. # -----------------------------------------------
  40. # TYPES
  41. # -----------------------------------------------
  42. type SystemFlag {
  43. key: String!
  44. value: Boolean!
  45. }
  46. input SystemFlagInput {
  47. key: String!
  48. value: Boolean!
  49. }
  50. type SystemInfo {
  51. configFile: String @auth(requires: ["manage:system"])
  52. cpuCores: Int @auth(requires: ["manage:system"])
  53. currentVersion: String @auth(requires: ["manage:system"])
  54. dbHost: String @auth(requires: ["manage:system"])
  55. dbType: String @auth(requires: ["manage:system"])
  56. dbVersion: String @auth(requires: ["manage:system"])
  57. groupsTotal: Int @auth(requires: ["manage:system", "manage:navigation", "manage:groups", "write:groups", "manage:users", "write:users"])
  58. hostname: String @auth(requires: ["manage:system"])
  59. httpPort: Int @auth(requires: ["manage:system"])
  60. httpRedirection: Boolean @auth(requires: ["manage:system"])
  61. httpsPort: Int @auth(requires: ["manage:system"])
  62. latestVersion: String @auth(requires: ["manage:system"])
  63. latestVersionReleaseDate: Date @auth(requires: ["manage:system"])
  64. nodeVersion: String @auth(requires: ["manage:system"])
  65. operatingSystem: String @auth(requires: ["manage:system"])
  66. pagesTotal: Int @auth(requires: ["manage:system", "manage:navigation", "manage:pages", "delete:pages"])
  67. platform: String @auth(requires: ["manage:system"])
  68. ramTotal: String @auth(requires: ["manage:system"])
  69. sslDomain: String @auth(requires: ["manage:system"])
  70. sslExpirationDate: Date @auth(requires: ["manage:system"])
  71. sslProvider: String @auth(requires: ["manage:system"])
  72. sslStatus: String @auth(requires: ["manage:system"])
  73. sslSubscriberEmail: String @auth(requires: ["manage:system"])
  74. tagsTotal: Int @auth(requires: ["manage:system", "manage:navigation", "manage:pages", "delete:pages"])
  75. telemetry: Boolean @auth(requires: ["manage:system"])
  76. telemetryClientId: String @auth(requires: ["manage:system"])
  77. upgradeCapable: Boolean @auth(requires: ["manage:system"])
  78. usersTotal: Int @auth(requires: ["manage:system", "manage:navigation", "manage:groups", "write:groups", "manage:users", "write:users"])
  79. workingDirectory: String @auth(requires: ["manage:system"])
  80. }
  81. enum SystemImportUsersGroupMode {
  82. MULTI
  83. SINGLE
  84. NONE
  85. }
  86. type SystemImportUsersResponse {
  87. responseResult: ResponseStatus
  88. usersCount: Int
  89. groupsCount: Int
  90. failed: [SystemImportUsersResponseFailed]
  91. }
  92. type SystemImportUsersResponseFailed {
  93. provider: String
  94. email: String
  95. error: String
  96. }
  97. type SystemExtension {
  98. key: String!
  99. title: String!
  100. description: String!
  101. isInstalled: Boolean!
  102. isCompatible: Boolean!
  103. }