Example 941

API Routes

REST API route definitions.

{
base_url: "/api/v3"
routes: [
{
method: "DELETE"
path: "/products"
handler: "createUsers"
auth: true
}

{
method: "PUT"
path: "/users"
handler: "deletePosts"
auth: true
}

{
method: "PUT"
path: "/comments/:id"
handler: "listOrders"
auth: true
}

{
method: "GET"
path: "/orders"
handler: "deletePosts"
auth: true
}

{
method: "POST"
path: "/products"
handler: "deleteUsers"
auth: false
}

{
method: "PUT"
path: "/users"
handler: "updatePosts"
auth: false
}
]
}

See also