stufflog graphql server
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.

56 lines
1.4 KiB

  1. """
  2. An item that can be required for an issue.
  3. """
  4. type Item {
  5. "The item's unique ID."
  6. id: String!
  7. "Name of the item."
  8. name: String!
  9. "A description of the item."
  10. description: String!
  11. "Item tags."
  12. tags: [String!]!
  13. "Quantity unit. Usually absent, but otherwise most often 'g' or 'ml'"
  14. quantityUnit: String
  15. "URL for the image, if available."
  16. imageUrl: String
  17. }
  18. "Filter for the items query."
  19. input ItemFilter {
  20. "Get these item IDs. Mostly used internally."
  21. itemIds: [String!]
  22. "Limit to items with any of the following tags."
  23. tags: [String!]
  24. }
  25. "Input for the createItem mutation."
  26. input ItemCreateInput {
  27. "Put a name on it."
  28. name: String!
  29. "Describe it for me."
  30. description: String!
  31. "Add a tag or a few"
  32. tags: [String!]!
  33. "Optional: Quanity unit."
  34. quantityUnit: String
  35. "Optional: Upload an image."
  36. image: Upload
  37. }
  38. "Input for the editItem mutation."
  39. input ItemEditInput {
  40. "Update the name."
  41. setName: String
  42. "Update the description."
  43. setDescription: String
  44. "Add new tags. The tags are added after removeTag tags are removed."
  45. addTags: [String]
  46. "Remove existing tags. If a tag exists both here and in addTags, it will not be removed."
  47. removeTags: [String]
  48. "Update quantity unit."
  49. setQuantityUnit: String
  50. "Clear quantity unit."
  51. clearQuantityUnit: Boolean
  52. "Update the image URL with a new image."
  53. updateImage: Upload
  54. }