- In order to access the API, knowledge of Axios is essential
- In order to make use of global variables through the store, knowledge of vuex is essential
To install all node dependencies make sure to run
$ npm run serve
on the root directory of the cloned project.
To make use of the live API locally, change the following line
// src/backend/axios/index.js
...
var API_URL = 'http://localhost:3000' // Development
...
to the value:
var API_URL = 'http://api.napoly.ch' // Development
or, in case you are an authenticated user and would like to safely edit data, use:
var API_URL = 'http://staging.api.napoly.ch' // Development
which will connect you to the staging API which has a separate database that can be edited however you please.
The API json directories that can be indexed without authentication are available via the following links:
- https://api.napoly.ch/api/v1/fields
- https://api.napoly.ch/api/v1/semesters
- https://api.napoly.ch/api/v1/subjects
- https://api.napoly.ch/api/v1/links
The links of a specific subject (in this case with subject_id === 1) can be accessed via:
The infos and buttons of a specific subject (in this case with subject_id === 1) can be accessed via:
- https://api.napoly.ch/api/v1/subjectButtons?subject_id=1
- https://api.napoly.ch/api/v1/infos?subject_id=1
Userdata cannot be accessed unless logged in.