-
run
yarn install
-
run
yarn server
User Login
{
"email":"user@user.com",
"password":"password",
"type":"user"
}
User Login
{
"email":"company@company.com",
"password":"password"
}
Get All Users | Get User Info | Get User by Id | Update User | Delete User | User Matches | Save user to Company | Remove user to Company
Get All Companies | Get Company Info | Get Company by Id | Update Company | Delete Company
Get All Jobs | Create Job | Get Job by Id | Update Job Delete Job | Get jobs for signed in Company | Save job to user profile | Remove job from use profile
-
Method URL: /auth/register
HTTP method: [POST]
name type required description Content-type String Yes Must be application/json name type required description email String Yes must be unique password String Yes required type String Yes must be either 'user' or 'company' example
{ email: "johnDoe@test.com", password: "password123" type:'user' }
name type required description companyName string Yes email String Yes must be unique password String Yes required type string Yes must be either 'user' or 'company' example
{ companyName: "Company", email: "johnDoe@test.com", password: "password123" type:'company' }
-
Method URL: /auth/login
HTTP method: [POST]
name type required description Content-type String Yes Must be application/json name type required description email String Yes required password String Yes required example
{ email: "test@test.com", password: "password123" }
On success return user object
{ "token": "eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJzdWJqZWN0IjoyMSwiaWF0IjoxNTUyMTczNDgzLCJleHAiOjE1NTI2MDU0ODN9.AIYdpeMoNtT3FHrSc1_Srrj3dLQfHl1gRNK3hicOe2M", "userInfo": { "id": 21, "firstName": "mike", "lastName": "landers", "email": "test@test.com", "occupation": null, "experience": null, "interests": null } }
On success return company object
{ "token": "eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJzdWJqZWN0IjoxLCJpYXQiOjE1NTIyNDU4ODgsImV4cCI6MTU1MjY3Nzg4OH0.JCY10oa6KVN5HttwK27PCLWr_m8SU9Ptz2lXoryuPeo", "companyInfo": { "id": 1, "name": "apple", "email": "test3@test.com", "bio": null, "address": null } }
-
Method URL: /users
HTTP method: [POST]
name type required description Content-type String Yes Must be application/json Authorization String Yes Token On success return array
[ { "id": 1, "firstName": "Orlando", "lastName": "Nitzsche", "occupation": "Regional Functionality Strategist", "experience": "experience", "interests": "interests" }, { "id": 2, "firstName": "Delphine", "lastName": "Shanahan", "occupation": "Product Factors Orchestrator", "experience": "experience", "interests": "interests" } ]
-
Method URL: /users/info
HTTP method: [GET]
name type required description Content-type String Yes Must be application/json Authorization String Yes Token On success return object
"id": 1, "firstName": "Laurence", "lastName": "Bechtelar", "occupation": "Central Mobility Director", "experience": "experience", "interests": "interests", "saved": [ { "job_id": 47, "jobTitle": "Internal Quality Agent", "jobPosition": "Architect", "jobDescription": "Regional", "jobRequirements": "Brand", "jobSalary": 903, "jobTags": "dolore eos quia", "jobOpenDate": "1552373894247.0", "jobCloseDate": "1559589532036.0" }, { "job_id": 49, "jobTitle": "Future Interactions Technician", "jobPosition": "Analyst", "jobDescription": "District", "jobRequirements": "Data", "jobSalary": 18, "jobTags": "animi quia omnis", "jobOpenDate": "1552355593356.0", "jobCloseDate": "1570538807737.0" } ]
-
Method URL: /users/:id
HTTP method: [GET]
name type required description Content-type String Yes Must be application/json Authorization String Yes Token On success return object
{ "id": 2, "firstName": "Imani", "lastName": "Heidenreich", "occupation": "Future Tactics Agent", "experience": "experience", "interests": "interests" }
-
Method URL: /users/update
HTTP method: [PUT]
name type required description Content-type String Yes Must be application/json Authorization String Yes Token must be from a user account name type required description firstName string No lastName string No occupation string No experience string No interests string No { firstName: "John, lastName: "Doe" }
On success return
1
-
Method URL: /companies
HTTP method: [GET]
name type required description Content-type String Yes Must be application/json Authorization String Yes Token On success return array
[ { "id": 1, "companyName": "Company", "email": "user@company.com", "bio": null, "address": null }, { "id": 2, "companyName": "Apple", "email": "hr@apple.com", "bio": null, "address": "1 Infinite Loop" } ]
-
Method URL: /companies/info
HTTP method: [GET]
name type required description Content-type String Yes Must be application/json Authorization String Yes Token On success return object
{ "id": 2, "companyName": "Apple", "email": "hr@apple.com", "bio": null, "address": "1 Infinite Loop" }
-
Method URL: /companies/:id
HTTP method: [GET]
name type required description Content-type String Yes Must be application/json Authorization String Yes Token On success return object
{ "id": 2, "companyName": "Apple", "email": "hr@apple.com", "bio": null, "address": "1 Infinite Loop", "companyJobs": [ { "id": 3, "jobTitle": "title", "jobPosition": "Position", "jobDescription": "Description", "jobRequirements": "Requirements", "jobSalary": 100000, "jobTags": ["tech", "janitor"], "jobOpenDate": "March 11th, 2019", "jobCloseDate": "June 1st, 2019", "company_id": 2 } ] }
-
Method URL: /companies/update
HTTP method: [PUT]
name type required description Content-type String Yes Must be application/json Authorization String Yes Token must be from a company account name type required description companyName string No email string No bio string No address string No Can send any part of the body that needs updating: companyName, email, bio, address
{ bio: "This is a new bio", address: "123 Company St, Company Town, USA" }
On success return
1
-
Method URL: /jobs
HTTP method: [GET]
name type required description Content-type String Yes Must be application/json Authorization String Yes Token On success return array
[ { "id": 1, "jobTitle": "Dynamic Program Administrator", "jobPosition": "Consultant", "jobDescription": "Direct", "jobRequirements": "Web", "jobSalary": 553, "jobTags": "tempora", "jobOpenDate": "1552312445647.0", "jobCloseDate": "1579476170156.0", "company_id": 11 }, { "id": 2, "jobTitle": "International Configuration Developer", "jobPosition": "Supervisor", "jobDescription": "Future", "jobRequirements": "Marketing", "jobSalary": 206, "jobTags": "nostrum", "jobOpenDate": "1552303764015.0", "jobCloseDate": "1579102031521.0", "company_id": 4 } ]
-
Method URL: /jobs
HTTP method: [Post]
name type required description Content-type String Yes Must be application/json Authorization String Yes Token name type required description jobTitle String No jobPosition String No jobDescription String No jobRequirements String No jobSalary Integer No jobTags String No jobOpenDate Integer No jobCloseDate Intteger No On success return 1
-
Method URL: /jobs/:id
HTTP method: [GET]
name type required description Content-type String Yes Must be application/json Authorization String Yes Token On success return object
{ "id": 13, "jobTitle": "Customer Research Apprentice", "jobPosition": "Executive", "jobDescription": "Lead", "jobRequirements": "Accounts", "jobSalary": 704, "jobTags": "voluptas", "jobOpenDate": "1552282766773.0", "jobCloseDate": "1579250581673.0", "company_id": 1 }
-
Method URL: /jobs/update/:id
HTTP method: [PUT]
name type required description Content-type String Yes Must be application/json Authorization String Yes Token must be from a company account name type required description jobTitle String No jobPosition String No jobDescription String No jobRequirements String No jobSalary Integer No jobTags String No jobOpenDate Integer No jobCloseDate Intteger No { jobSalary: 50000, }
On success return
1
-
Method URL: /jobs/:id/delete
HTTP method: [DELETE]
name type required description Content-type String Yes Must be application/json Authorization String Yes Token must be from a company account On success return status(204)
Method URL: /
HTTP method: [GET]
name | type | required | description |
---|---|---|---|
Content-type | String | Yes | Must be application/json |
Authorization | String | Yes | Token must be from a company account |
name | type | required | description |
---|---|---|---|
item | String | No |
{
jobSalary: 50000,
}
On success return
1
--
-
axios({ method: "post", url: `https://${API_URL}/endpoint`, headers: { Authorization: token }, data: { email: "johndoe@email.com", password: "password123" } }) .then((res) => console.log(res)) .catch(err => console.log("error", err))