Example 12356

API Routes

REST API route definitions.

{
base_url: "/api/v2"
routes: [
{
method: "PATCH"
path: "/orders/:id"
handler: "updateProducts"
auth: true
}

{
method: "POST"
path: "/posts"
handler: "createUsers"
auth: true
}

{
method: "PATCH"
path: "/orders/:id"
handler: "getPosts"
auth: true
}
]
}

See also