user-object.json 1.3 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061
  1. {
  2. "type": "object",
  3. "description": "User object",
  4. "required": ["id", "created_on", "modified_on", "is_disabled", "email", "name", "nickname", "avatar", "roles"],
  5. "additionalProperties": false,
  6. "properties": {
  7. "id": {
  8. "type": "integer",
  9. "description": "User ID",
  10. "minimum": 1,
  11. "example": 1
  12. },
  13. "created_on": {
  14. "type": "string",
  15. "description": "Created Date",
  16. "example": "2020-01-30T09:36:08.000Z"
  17. },
  18. "modified_on": {
  19. "type": "string",
  20. "description": "Modified Date",
  21. "example": "2020-01-30T09:41:04.000Z"
  22. },
  23. "is_disabled": {
  24. "type": "integer",
  25. "minimum": 0,
  26. "maximum": 1,
  27. "description": "Is user Disabled (0 = false, 1 = true)",
  28. "example": 0
  29. },
  30. "email": {
  31. "type": "string",
  32. "description": "Email",
  33. "minLength": 3,
  34. "example": "[email protected]"
  35. },
  36. "name": {
  37. "type": "string",
  38. "description": "Name",
  39. "minLength": 1,
  40. "example": "Jamie Curnow"
  41. },
  42. "nickname": {
  43. "type": "string",
  44. "description": "Nickname",
  45. "example": "James"
  46. },
  47. "avatar": {
  48. "type": "string",
  49. "description": "Gravatar URL based on email, without scheme",
  50. "example": "//www.gravatar.com/avatar/6193176330f8d38747f038c170ddb193?default=mm"
  51. },
  52. "roles": {
  53. "description": "Roles applied",
  54. "example": ["admin"],
  55. "type": "array",
  56. "items": {
  57. "type": "string"
  58. }
  59. }
  60. }
  61. }