I am building a web API with FLASK and I want to read some images in `data` folder

```
venv/data/cartes/carte1.png
                 carte2.png
                 carte3.png
                 carte4.png

```

in order to show them in an html file `index.html` and loop over them whit javascript:

```
@app.route('/')
def index():
    return render_template('index.html')

```

I tried to use this but it gaves error GET LINK... not found:

```
app.config["CLIENT_IMAGES"] = "/data/cartes"

@app.route("/get-image/<image_name>",methods=['GET', 'POST'])
def get_image(image_name):

    try:
        return send_from_directory(app.config["CLIENT_IMAGES"], filename=image_name, as_attachment=True)
    except FileNotFoundError:
        print("failure")
        abort(404)

```