智慧水务管理系统 - 精河县供水工程综合管理平台

remote-server.js 449B

1234567891011121314151617181920
  1. require('dotenv').config();
  2. const express = require('express');
  3. const cors = require('cors');
  4. const app = express();
  5. const PORT = process.env.PORT || 3001;
  6. app.use(cors());
  7. app.use(express.json());
  8. // 健康检查
  9. app.get('/api/health', (req, res) => {
  10. res.json({ status: 'ok', service: '远程团队协作 API' });
  11. });
  12. // TODO: 添加业务 API
  13. app.listen(PORT, () => {
  14. console.log(`🚀 远程协作 API:http://localhost:${PORT}`);
  15. });