Skip to content
Snippets Groups Projects
  • Ingo Leindecker's avatar
    41ebf159
    Added nested endpoints as well as some filters · 41ebf159
    Ingo Leindecker authored
    /api/v1/shows/
    /api/v1/shows/?active=true
    /api/v1/shows/1/
    /api/v1/shows/1/schedules
    /api/v1/shows/1/schedules/1
    /api/v1/shows/1/schedules/1/timeslots
    /api/v1/shows/1/schedules/1/timeslots/1/
    /api/v1/shows/1/schedules/1/timeslots/1/notes
    /api/v1/shows/1/schedules/1/timeslots/1/notes/1
    /api/v1/shows/1/notes
    /api/v1/shows/1/notes/1
    /api/v1/shows/1/timeslots
    /api/v1/shows/1/timeslots/1
    /api/v1/shows/1/timeslots/1/notes
    /api/v1/shows/1/timeslots/1/notes/1
    
    On every /timeslot endpoint, filter variables ?start=2017-01-01&end=2017-12-31 are available.
    
    Properly create, update and delete:
    
    * Users
      - only superusers may create
      - common users can only retrieve/update themselves
      - update is constrained to certain non-crucial fields for non-superusers
    
    * Shows
      - only superusers may create
      - update is constrained to certain fields for non-superusers
    
    * Notes
      - creating/updating is constrained to shows and timeslots the non-superuser owns
    
    * Schedules
      - only superusers may add/update/delete
      - collision detection still needed
    
    * Timeslots
      - direct creation is prohibited for everyone (only by adding/updating schedules)
      - update is constrained to certain fields
      - only superusers may delete
    
    
    Available GET endpoints for (only superusers may add/update/delete)
    
    * Hosts
    * Types
    * Topics
    * Categories
    * RTRCategories
    * Languages
    
    
    See #22 #23
    41ebf159
    History
    Added nested endpoints as well as some filters
    Ingo Leindecker authored
    /api/v1/shows/
    /api/v1/shows/?active=true
    /api/v1/shows/1/
    /api/v1/shows/1/schedules
    /api/v1/shows/1/schedules/1
    /api/v1/shows/1/schedules/1/timeslots
    /api/v1/shows/1/schedules/1/timeslots/1/
    /api/v1/shows/1/schedules/1/timeslots/1/notes
    /api/v1/shows/1/schedules/1/timeslots/1/notes/1
    /api/v1/shows/1/notes
    /api/v1/shows/1/notes/1
    /api/v1/shows/1/timeslots
    /api/v1/shows/1/timeslots/1
    /api/v1/shows/1/timeslots/1/notes
    /api/v1/shows/1/timeslots/1/notes/1
    
    On every /timeslot endpoint, filter variables ?start=2017-01-01&end=2017-12-31 are available.
    
    Properly create, update and delete:
    
    * Users
      - only superusers may create
      - common users can only retrieve/update themselves
      - update is constrained to certain non-crucial fields for non-superusers
    
    * Shows
      - only superusers may create
      - update is constrained to certain fields for non-superusers
    
    * Notes
      - creating/updating is constrained to shows and timeslots the non-superuser owns
    
    * Schedules
      - only superusers may add/update/delete
      - collision detection still needed
    
    * Timeslots
      - direct creation is prohibited for everyone (only by adding/updating schedules)
      - update is constrained to certain fields
      - only superusers may delete
    
    
    Available GET endpoints for (only superusers may add/update/delete)
    
    * Hosts
    * Types
    * Topics
    * Categories
    * RTRCategories
    * Languages
    
    
    See #22 #23