python - Flask base route -


this question has answer here:

i want create rest api app flask. possible run flask base route fe. localhost:5000/webservice that

@app.route('/users') 

will handle localhost:5000/webservice/users?

use flask blueprints. when registering blueprint can add url prefix.

app.register_blueprint(restapi, url_prefix='/webservice') 

here link flask blueprint docs: flask blueprints


Comments

Popular posts from this blog

'hasOwnProperty' in javascript -

How to put a lock and transaction on table using spring 4 or above using jdbcTemplate and annotations like @Transactional? -

java - How to implement an entity bound odata action in olingo v4.3 -