proxy-host-object.json 3.5 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178
  1. {
  2. "type": "object",
  3. "description": "Proxy Host object",
  4. "required": [
  5. "id",
  6. "created_on",
  7. "modified_on",
  8. "owner_user_id",
  9. "domain_names",
  10. "forward_host",
  11. "forward_port",
  12. "access_list_id",
  13. "certificate_id",
  14. "ssl_forced",
  15. "caching_enabled",
  16. "block_exploits",
  17. "advanced_config",
  18. "meta",
  19. "allow_websocket_upgrade",
  20. "http2_support",
  21. "forward_scheme",
  22. "enabled",
  23. "locations",
  24. "hsts_enabled",
  25. "hsts_subdomains",
  26. "trust_forwarded_proto"
  27. ],
  28. "properties": {
  29. "id": {
  30. "$ref": "../common.json#/properties/id"
  31. },
  32. "created_on": {
  33. "$ref": "../common.json#/properties/created_on"
  34. },
  35. "modified_on": {
  36. "$ref": "../common.json#/properties/modified_on"
  37. },
  38. "owner_user_id": {
  39. "$ref": "../common.json#/properties/user_id"
  40. },
  41. "domain_names": {
  42. "$ref": "../common.json#/properties/domain_names"
  43. },
  44. "forward_host": {
  45. "type": "string",
  46. "minLength": 1,
  47. "maxLength": 255,
  48. "example": "127.0.0.1"
  49. },
  50. "forward_port": {
  51. "type": "integer",
  52. "minimum": 1,
  53. "maximum": 65535,
  54. "example": 8080
  55. },
  56. "access_list_id": {
  57. "$ref": "../common.json#/properties/access_list_id"
  58. },
  59. "certificate_id": {
  60. "$ref": "../common.json#/properties/certificate_id"
  61. },
  62. "ssl_forced": {
  63. "$ref": "../common.json#/properties/ssl_forced"
  64. },
  65. "caching_enabled": {
  66. "$ref": "../common.json#/properties/caching_enabled"
  67. },
  68. "block_exploits": {
  69. "$ref": "../common.json#/properties/block_exploits"
  70. },
  71. "advanced_config": {
  72. "type": "string",
  73. "example": ""
  74. },
  75. "meta": {
  76. "type": "object",
  77. "example": {
  78. "nginx_online": true,
  79. "nginx_err": null
  80. }
  81. },
  82. "allow_websocket_upgrade": {
  83. "description": "Allow Websocket Upgrade for all paths",
  84. "type": "boolean",
  85. "example": true
  86. },
  87. "http2_support": {
  88. "$ref": "../common.json#/properties/http2_support"
  89. },
  90. "forward_scheme": {
  91. "type": "string",
  92. "enum": ["http", "https"],
  93. "example": "http"
  94. },
  95. "enabled": {
  96. "$ref": "../common.json#/properties/enabled"
  97. },
  98. "locations": {
  99. "type": "array",
  100. "minItems": 0,
  101. "items": {
  102. "type": "object",
  103. "required": ["forward_scheme", "forward_host", "forward_port", "path"],
  104. "additionalProperties": false,
  105. "properties": {
  106. "id": {
  107. "type": ["integer", "null"]
  108. },
  109. "path": {
  110. "type": "string",
  111. "minLength": 1
  112. },
  113. "forward_scheme": {
  114. "$ref": "#/properties/forward_scheme"
  115. },
  116. "forward_host": {
  117. "$ref": "#/properties/forward_host"
  118. },
  119. "forward_port": {
  120. "$ref": "#/properties/forward_port"
  121. },
  122. "forward_path": {
  123. "type": "string"
  124. },
  125. "advanced_config": {
  126. "type": "string"
  127. }
  128. }
  129. },
  130. "example": [
  131. {
  132. "path": "/app",
  133. "forward_scheme": "http",
  134. "forward_host": "example.com",
  135. "forward_port": 80
  136. }
  137. ]
  138. },
  139. "hsts_enabled": {
  140. "$ref": "../common.json#/properties/hsts_enabled"
  141. },
  142. "hsts_subdomains": {
  143. "$ref": "../common.json#/properties/hsts_subdomains"
  144. },
  145. "trust_forwarded_proto":{
  146. "type": "boolean",
  147. "description": "Trust the forwarded headers",
  148. "example": false
  149. },
  150. "certificate": {
  151. "oneOf": [
  152. {
  153. "type": "null",
  154. "example": null
  155. },
  156. {
  157. "$ref": "./certificate-object.json"
  158. }
  159. ],
  160. "example": null
  161. },
  162. "owner": {
  163. "$ref": "./user-object.json"
  164. },
  165. "access_list": {
  166. "oneOf": [
  167. {
  168. "type": "null",
  169. "example": null
  170. },
  171. {
  172. "$ref": "./access-list-object.json"
  173. }
  174. ],
  175. "example": null
  176. }
  177. }
  178. }