def add_route(route, endpoint=None, **kw):
<EOL>def apiurl(route):<EOL><INDENT>return '<STR_LIT:/>'.join(s.strip('<STR_LIT:/>') for s in ["<STR_LIT>", BASE_URL, route])<EOL><DEDENT>return add_senaite_route(apiurl(route), endpoint, **kw)<EOL>
Add a new JSON API route