jsonifyreturns an object Response, so grab it before returning from your view and add a cookie, then Response.set_cookie.
out = jsonify(state=0, msg='success')
out.set_cookie('my_key', 'my_value')
return out
You might want to simply add a value to the session cookie. Flask sessionwill json encode values ββand sign cookies for security, which you need to do manually when using set_cookie.
from flask import session
session['my_key'] = 'my_value'