GET /api/companies.json
will return all companies
[
{
"id":1,
"name":"Testing",
"cvr":"test",
"address":"hello",
"city":"just a test",
"country":"dfsd",
"phone":"",
"created_at":"2018-05-07T22:06:33.430Z",
"updated_at":"2018-05-07T22:06:33.430Z"
}, ...
]
POST /api/companies.json
Payload: Requests must include the following:
{
"name": string,
"cvr": string,
"address": string,
"city": string,
"country": string
}
It is also possible to create a company with a phone number, just add the property phone
to the request's json object.
GET /api/companies/1.json
will return the company with id 1, if found, otherwise it'll return 404.
[
{
"id":1,
"name":"Testing",
"cvr":"test",
"address":"hello",
"city":"just a test",
"country":"dfsd",
"phone":"",
"created_at":"2018-05-07T22:06:33.430Z",
"updated_at":"2018-05-07T22:06:33.430Z"
}
]
- https://github.com/ddollar/foreman
- Latest node.js
- A working Ruby enviroment
bundle install
npm install
npm start
npm run build