GraphQL API and utilities for the rpdata project
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.

85 lines
1.6 KiB

  1. """
  2. A change represents a a change in the history.
  3. """
  4. type Change {
  5. "A unique ID of the change."
  6. id: String!
  7. "The model of the changed object."
  8. model: ChangeModel!
  9. "The operation performed."
  10. op: String!
  11. "The author that performed the change."
  12. author: String!
  13. "Whether the change will be listed without a matching key."
  14. listed: Boolean!
  15. "The keys indexing this change."
  16. keys: [ChangeKey!]!
  17. "The date when the change happened."
  18. date: Time
  19. "The changed objects."
  20. objects: [ChangeObject!]!
  21. }
  22. union ChangeObject = Character | Channel | Log | Post | Story | Tag | Chapter | Comment | File
  23. """
  24. A change key is a key associated with a change, used for filtering
  25. and subscription. A log post edit has keys for both the log and post,
  26. making it suitable to use it to patch an active log file.
  27. """
  28. type ChangeKey {
  29. "The model the key is for."
  30. model: ChangeModel!
  31. "The model's id, or * if it's a key indicating a model list should be updated."
  32. id: String!
  33. }
  34. """
  35. See ChangeKey
  36. """
  37. input ChangeKeyInput {
  38. "The model the key is for."
  39. model: ChangeModel!
  40. "The model's id, or * if it's a key indicating a model list should be updated."
  41. id: String!
  42. }
  43. """
  44. A model related to the change.
  45. """
  46. enum ChangeModel {
  47. Character
  48. Channel
  49. Log
  50. Post
  51. Story
  52. Tag
  53. Chapter
  54. Comment
  55. File
  56. }
  57. """
  58. Optional filter for the changes query.
  59. """
  60. input ChangesFilter {
  61. "The keys to query for."
  62. keys: [ChangeKeyInput!]
  63. "Only show changes by this author"
  64. author: String
  65. "Only show changes more recent than this date."
  66. earliestDate: Time
  67. "Limit the amount of results. This even goes for subscriptions!"
  68. limit: Int
  69. }