Files
logan dec66db5aa feat: OpsxAPI v1.0 全协议接口工作台
- 六协议调试:HTTP/GraphQL/WebSocket/SSE/Socket.IO/MQTT
- 集合树/多标签/多环境变量/历史记录,localStorage 持久化
- 导入:OpenAPI 2/3/3.1、Postman、Apifox、Apipost、cURL、HAR、
  Insomnia、Hoppscotch、Markdown(自动识别,21 个单测覆盖)
- 导出:OpenAPI 3.0 JSON/YAML、Postman v2.1、Markdown 文档、
  全量备份;单请求生成 cURL/fetch/Python/Go 代码
- Gin 服务:HTTP 代理、NDJSON 流式代理(SSE 透传)、
  WebSocket 隧道(浏览器自定义握手 Header)
- 内置产品官网 /home 与用户文档站 /docs(SSR,随二进制交付)
- lucide 图标体系 + 品牌标识(Logo/favicon),明暗双主题
- 环境变量:彩色徽标切换器、管理弹窗、{{ 自动补全
2026-09-18 00:16:59 +08:00

70 lines
1.7 KiB
YAML

openapi: 3.0.3
info:
title: OpsxAPI Server
version: 0.1.0
description: Minimal health + HTTP proxy API
servers:
- url: http://127.0.0.1:8787
paths:
/health:
get:
summary: Health check
responses:
"200":
description: OK
content:
application/json:
schema:
type: object
properties:
ok: { type: boolean }
service: { type: string }
/v1/proxy/http:
post:
summary: Proxy an HTTP request
requestBody:
required: true
content:
application/json:
schema:
$ref: "#/components/schemas/HttpSpec"
responses:
"200":
description: Proxied result
content:
application/json:
schema:
$ref: "#/components/schemas/HttpResult"
components:
schemas:
HttpSpec:
type: object
required: [method, url]
properties:
method:
type: string
enum: [GET, POST, PUT, PATCH, DELETE]
url: { type: string }
headers:
type: object
additionalProperties: { type: string }
query:
type: object
additionalProperties: { type: string }
body:
type: object
properties:
mode: { type: string, enum: [none, json, raw, form, urlencoded] }
raw: { type: string }
timeoutMs: { type: integer }
HttpResult:
type: object
properties:
status: { type: integer }
headers:
type: object
additionalProperties: { type: string }
body: { type: string }
timeMs: { type: number }
size: { type: integer }