()
| 19303 | |
| 19304 | @app.route('/api/save_creds', methods=['POST']) |
| 19305 | def api_save(): |
| 19306 | denied = require_sensitive_request("save_creds", limit=10, window=60) |
| 19307 | if denied: |
| 19308 | return denied |
| 19309 | data = request.get_json(silent=True) or {} |
| 19310 | if not isinstance(data, dict): |
| 19311 | return jsonify({"status": "error", "message": "Payload credenziali non valido."}), 400 |
| 19312 | core.save_creds(data) |
| 19313 | return jsonify({"status":"ok"}) |
| 19314 | |
| 19315 | @app.route('/api/tg/send_code', methods=['POST']) |
| 19316 | def tg_send(): |
nothing calls this directly
no test coverage detected