Phisical Cards
API LINK:
List of all routes:
- List all cards
- Card Info
- All Available
- Available cards from one establishment
- Delete All Establishment cards
- Delete card
- Create new card
- Change Card Availability
- Change Card Circulation
- Reset
List All Cards
- GET https://nite-apigateway.herokuapp.com/cards - List all cards
headers: { Authorization: `Bearer ${token}` }
All Available
- GET https://nite-apigateway.herokuapp.com/cards/AllAvailable - List all available cards
headers: { Authorization: `Bearer ${token}` }
Available cards from one establishment
- GET https://nite-apigateway.herokuapp.com/cards/Available - List all available cards from one establishment
ONLY FOR MANAGERS
headers: { Authorization: `Bearer ${token}` }
Card Info
- GET https://nite-apigateway.herokuapp.com/cards/ - List one card info
headers: { Authorization: `Bearer ${token}` }
Delete All Establishment Cards
- DELETE https://nite-apigateway.herokuapp.com/cards/DropAllOrganization - Delete all cards of his establishment.
THIS ROUTE IS ONLY FOR MANAGERS
headers: { Authorization: `Bearer ${token}` }
Delete Card
- DELETE https://nite-apigateway.herokuapp.com/cards/DeleteCard/:card - Delete one card of his establishment.
THIS ROUTE IS ONLY FOR MANAGERS
headers: { Authorization: `Bearer ${token}` }
Create New Card
- POST https://nite-apigateway.herokuapp.com/cards/newCard - New phisical card
THIS ROUTE IS ONLY FOR MANAGERS
headers: { Authorization: `Bearer ${token}` }
req.body = {
idfcard: String
}
Change Card Availability
- PUT https://nite-apigateway.herokuapp.com/cards/Availability - Update card’s availability
THIS ROUTE IS ONLY FOR MANAGERS
headers: { Authorization: `Bearer ${token}` }
req.body = {
id: String,
availability: Boolean
}
Change Card Circulation
- PUT https://nite-apigateway.herokuapp.com/cards/Circulation - Update card’s circulation
THIS ROUTE IS ONLY FOR MANAGERS
headers: { Authorization: `Bearer ${token}` }
req.body = {
id: String,
circulating: Boolean
}
Reset
- PUT https://nite-apigateway.herokuapp.com/cards/Reset - Reset one fcard
THIS ROUTE IS ONLY FOR MANAGERS AND EMPLOYEES
headers: { Authorization: `Bearer ${token}` }
req.body = {
idfcard: String
}