No Description

api notes 1.6KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445
  1. /random/:id ?
  2. - id specified for random is currently undefined, but will be used to get a random from a list id/name
  3. /list/:page
  4. - id specified for list is currently undefined, but will be used to get via list ids/names
  5. ---- new stuff to do with multiple lists:
  6. lists {
  7. id: serial
  8. user_id: user this belongs to!
  9. parent_id: another list, optional
  10. name: when generated, make a slug, if slug is not unique, append a number and try again (incrementing number until a new unique slug is found)
  11. slug: based on name, uniqueness required (enforced behind the scenes by name, unless explicitly given (in which case, must meet constraints and not exist already))
  12. timestamp
  13. }
  14. tasks -> {
  15. list_id: optional foreign key
  16. parent_id: optional foreign key (to a task!)
  17. }
  18. /new -> option to add list_id or parent_id or parent_content or list_name
  19. /edit -> option to add / remove same things
  20. /list -> option to only select from same things
  21. - deprecate /list and use /get for its options!
  22. /random -> option to only select from same things
  23. /get -> option to get from list / parent via id/content/name
  24. /list/new/:name -> create a list
  25. /list/get/:nameORslugORid -> get a list
  26. /list/do/:nameORslugORid -> mark everything on a list done (alternately, lists themselves can have seperate done values!!)
  27. /list/undo/:nameORslugORid ->
  28. /list/edit/:nameORslugORid ->
  29. /list/delete/:nameORslugORid -> all tasks are deleted or are removed from list to either its parent, or no list (depending on options sent)
  30. /list/parent -> get parent list
  31. /list/children -> get children lists
  32. /parent -> get parent task
  33. /children -> get children tasks
  34. /list(/:id_or_slug)(/:page) --- ?