We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 1da8675 commit 1f5b6e1Copy full SHA for 1f5b6e1
get_email_webhook.py
@@ -123,12 +123,13 @@ def health_check():
123
124
# --- Main Entry Point ---
125
if __name__ == "__main__":
126
+ port = int(os.getenv("PORT", 8000)) # Use Azure PORT or default 8000
127
if TEST_MODE:
128
print("🔹 TEST_MODE: sending test email")
129
send_email_via_graph(
130
"[Test] Graph Email",
131
"This is a test email sent via Microsoft Graph with application permissions."
132
)
133
else:
- print("✅ Flask is up and listening on /webhook and /health")
134
- app.run(host="0.0.0.0", port=5000)
+ print(f"✅ Flask is up and listening on /webhook and /health (port {port})")
135
+ app.run(host="0.0.0.0", port=port)
0 commit comments