scense_drag/wwwroot/api/graph_get.dspy
2026-08-29 21:10:23 +08:00

12 lines
435 B
Plaintext
Raw Permalink Blame History

This file contains ambiguous Unicode characters

This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

# -*- coding: utf-8 -*-
# graph_get.dspy — 获取单个画布blocks / connections / content 往返一致)
# GET /drag/api/graph_get.dspy?id=xxx
try:
gid = params_kw.get('id')
if not gid:
return {'success': False, 'message': 'graph_get.dspy: missing id'}
result = await get_drag_graph({'id': gid})
return result
except Exception as e:
return {'success': False, 'message': 'graph_get.dspy: ' + str(e)}