Answers for "flask get ip address of re"

3

flask get ip address of request

from flask import request
from flask import jsonify

@app.route("/get_my_ip", methods=["GET"])
def get_my_ip():
    return jsonify({'ip': request.remote_addr}), 200
Posted by: Guest on April-24-2020

Code answers related to "flask get ip address of re"

Python Answers by Framework

Browse Popular Code Answers by Language