added an 'api' route to support dynamic requests