codeforsanjose / courtbot

People need help to not miss a court date. This is a lightweight app for notifications that can be integrated with any county's data.
GNU General Public License v3.0
0 stars 5 forks source link

Application that allows a user to register a case number and a phone number to be notified #10

Open ying1 opened 2 years ago

ying1 commented 2 years ago

This should be a simple client / server application.

Parts:

Application flow:

Two REST endpoints are needed

  1. /get_court_date?case=<case_number> . This endpoint will query the database for the nearest court date for this case. This will also add as a verification for the user so that they can validate if they had set the case properly. if case not found:
    {
    "case": <case_number>
    "court_date": null,
    "court_data": null,
    "system_last_updated" : <last_scanned_date> 
    } 

if case is found -

{
   "case": <case_number>
   "court_date": <date_closest_to_today_in_future>
   "court_data": { ...some sort of info maybe to display to user? ...  } 
   "system_last_updated" : <last_scanned_date> 
} 
  1. /notify_case?case=<case_number>&phone=<phone_number> . This endpoint should create an entry in the notification table for case number and the phone. This table will be used by the cron job that will send out notification.