Example 10254

API Routes

REST API route definitions.

{
base_url: "/api/v3"
routes: [
{
method: "PUT"
path: "/comments"
handler: "listProducts"
auth: false
}

{
method: "DELETE"
path: "/users/:id"
handler: "getPosts"
auth: false
}

{
method: "DELETE"
path: "/users/:id"
handler: "getPosts"
auth: false
}

{
method: "PUT"
path: "/orders"
handler: "updateProducts"
auth: true
}

{
method: "GET"
path: "/products/:id"
handler: "deleteOrders"
auth: true
}

{
method: "DELETE"
path: "/products"
handler: "getOrders"
auth: false
}
]
}

See also