Example 6951
API Routes
REST API route definitions.
{
base_url: "/api/v1"
routes: [
{
method: "DELETE"
path: "/products/:id"
handler: "updateProducts"
auth: true
}
{
method: "POST"
path: "/products/:id"
handler: "getOrders"
auth: true
}
{
method: "GET"
path: "/posts"
handler: "createUsers"
auth: true
}
{
method: "DELETE"
path: "/comments"
handler: "createPosts"
auth: true
}
{
method: "PUT"
path: "/products"
handler: "getPosts"
auth: true
}
{
method: "GET"
path: "/products"
handler: "deleteOrders"
auth: true
}
{
method: "DELETE"
path: "/products/:id"
handler: "updateOrders"
auth: true
}
]
}