Former-commit-id: 8708e747b91f3652e6c1832d23fe37a74f9566f5
This commit is contained in:
Benjamin Kyd
2022-03-28 13:35:17 +01:00
parent fef9291b24
commit 58187aa300

View File

@@ -10,11 +10,11 @@ automatically every request
| Type | Route | Queries | Auth? | Notes |
| --- | --- | --- | -- | --- |
| GET | /api/search/ | query, page | no | |
| GET | /api/bricks/ | query, page | no | |
| GET | /api/sets/ | query, page | no | |
| GET | /api/sets/featured | page | no | |
| GET | /api/brick/:id/ | | no | |
| GET | /api/search/ | query, page | no | Query endpoint |
| GET | /api/bricks/ | query, page | no | Query endpoint |
| GET | /api/sets/ | query, page | no | Query endpoint |
| GET | /api/sets/featured | page | no | Query endpoint |
| GET | /api/brick/:id/ | | no | |
| GET | /api/set/:id/ | | no | |
| GET | /api/cdn/:id/ | | no | |
| PUT | /api/auth/login/ | | yes | |
@@ -26,11 +26,26 @@ automatically every request
| DEL | /api/auth/basket/:id | quantity | yes | if no id, delete whole |
| DEL | /api/auth/basket/ | | yes | if no id, delete whole |
Query endpoints do not return the full data on a brick/set, they return
a subset for product listing pages
## Query structure
## Query parameters
For all endpoints that query, the following parameters are supported:
tags: tags to include in search
page: starting page
pages: pages to return starting from page
q: string to search for (fuzzy)
brick: brick to search for (absolute)
set: brick to search for (absolute)
### /api/search/
### /api/bricks/
GET