bounties.schema.json 2.9 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117
  1. {
  2. "$schema": "http://json-schema.org/draft-07/schema",
  3. "$id": "https://joystream.org/bounties.schema.json",
  4. "title": "bountiesSchema",
  5. "description": "JSON schema to describe bounties for the Joystream Community",
  6. "type": "object",
  7. "additionalProperties": false,
  8. "properties": {
  9. "activeBounties": {
  10. "type": "array",
  11. "items": { "$ref": "#/definitions/activeBounty"}
  12. },
  13. "closedBounties": {
  14. "type": "array",
  15. "items": { "$ref": "#/definitions/closedBounty"}
  16. }
  17. },
  18. "definitions": {
  19. "activeBounty": {
  20. "type": "object",
  21. "required": [
  22. "id",
  23. "title",
  24. "description",
  25. "openedDate",
  26. "links",
  27. "reward",
  28. "tags"
  29. ],
  30. "properties": {
  31. "id": { "$ref": "#/definitions/id"},
  32. "title": { "$ref": "#/definitions/title"},
  33. "description": { "$ref": "#/definitions/description"},
  34. "openedDate": { "$ref": "#/definitions/openedDate"},
  35. "links": { "$ref": "#/definitions/links"},
  36. "reward": { "$ref": "#/definitions/reward"},
  37. "tags": { "$ref": "#/definitions/tags"},
  38. "status": { "$ref": "#/definitions/status"},
  39. "format": { "$ref": "#/definitions/format"}
  40. }
  41. },
  42. "closedBounty": {
  43. "type": "object",
  44. "required": [
  45. "id",
  46. "title",
  47. "description",
  48. "openedDate",
  49. "links",
  50. "reward",
  51. "tags"
  52. ],
  53. "properties": {
  54. "id": { "$ref": "#/definitions/id"},
  55. "title": { "$ref": "#/definitions/title"},
  56. "description": { "$ref": "#/definitions/description"},
  57. "openedDate": { "$ref": "#/definitions/openedDate"},
  58. "links": { "$ref": "#/definitions/links"},
  59. "reward": { "$ref": "#/definitions/reward"},
  60. "tags": { "$ref": "#/definitions/tags"},
  61. "closedDate": { "$ref": "#/definitions/closedDate"},
  62. "format": { "$ref": "#/definitions/format"}
  63. }
  64. },
  65. "id": {
  66. "type": "integer",
  67. "uniqueItems": true,
  68. "minimum": 1
  69. },
  70. "title": {
  71. "type": "string",
  72. "minLength": 1,
  73. "maxLength": 29
  74. },
  75. "description": {
  76. "type": "string",
  77. "minLength": 1,
  78. "maxLength": 190
  79. },
  80. "openedDate": {
  81. "type":"string",
  82. "format": "date"
  83. },
  84. "links": {
  85. "type":"array",
  86. "uniqueItems": true,
  87. "items": { "$ref": "#/definitions/link" }
  88. },
  89. "reward": {
  90. "type": "integer"
  91. },
  92. "tags": {
  93. "type": "array",
  94. "uniqueItems": true,
  95. "items": { "$ref": "#/definitions/tagName" }
  96. },
  97. "closedDate": {
  98. "type":"string",
  99. "format": "date"
  100. },
  101. "status": {
  102. "type":"string"
  103. },
  104. "format": {
  105. "type":"string"
  106. },
  107. "tagName": {
  108. "type": "string",
  109. "minLength": 1,
  110. "maxLength": 20
  111. },
  112. "link": {
  113. "type":"string",
  114. "format": "uri"
  115. }
  116. }
  117. }