- This API was built in conjunction with the JobHouse_Fe Front End application
-
base
/api/v1
-
GET
/search/jobs?city=WHATEVER
- Returns a list of jobs matching the city param
- Here we reach into a third party Job board API
- Returns a list of jobs matching the city param
-
Get
/users?email=someemailadress.com
- returns the specific user requested by email address, if one does not exist, creates a new one and returns that user
- Here we store our user table for our front end program to control access via Google-Oauth2
- returns the specific user requested by email address, if one does not exist, creates a new one and returns that user
-
Post
/jobs
- takes a formatted param with a
job
key and JSON body - creates a job entry in our database, or locates on if it already exists, and assigns a relationship to an existing users
- this endpoint store job data in the local database, this is required because the current free jobboard API does not have a search by ID endpoint Available to return specfic jobs for our users
- takes a formatted param with a
-
Get
/jobs/id/houses
- returns an index of houses that meet the 30% income affordability criteria
- this endpoint current only returns test data for Houston Texas, Mock data. this is a limitation of the Free nature of the API. If i paid version were subscribed to, this feature would automatically expand
- returns an index of houses that meet the 30% income affordability criteria
-
Post
/jobs/houses
- creates a
user_job_house
relationship with a house_id from the API, a Job_id, and a user email from the joins table in the database
- creates a
-
Get
/jobs/houses
- when given params[:email]¶ms[:job_id]
- returns a list of all a users homes saved to a specfic job
- when given params[:email]¶ms[:job_id]
-
Delete
/user/:id/jobs/:id
- destroys a user_job relationship
- Ruby version - 2.7.4
- Rails - 5.2.7