# Generated by ShowAPI OpenAPI generator
# source: market/1690
# generated-at: 2026-09-20T13:24:35.678Z
openapi: 3.0.3
info:
title: 单位换算器
description: 提供单位转换API,支持长度、面积、重量、体积、容量、温度、速度、时间、压力、功率等常见物理量,适用于科研、工程、物流等领域,为开发者实现便捷准确的单位换算。
termsOfService: https://www.showapi.com/helpcenter/view#/4019/2
version: 1.0.0
servers:
- url: https://route.showapi.com
paths:
/1690-16:
x-pointCode: 16
x-mode: mapping
x-read-timeout: 15
x-connect-timeout: 15
post:
summary: 支持的类型
description: 该接口提供单位换算功能,支持返回多种类型,可应用于日常生活、科学研究、工业生产等场景,帮助用户进行准确的单位转换。
responses:
"200":
description: 成功响应
content:
application/json:
schema:
allOf:
- $ref: "#/components/schemas/ShowapiResEnvelope"
- type: object
properties:
showapi_res_body:
type: object
properties:
ret_code:
type: number
description: 接口调用是否成功,0:扣费,表示成功,-1:不扣费,表示查询失败
result:
type: array
items:
type: object
properties:
unit:
type: string
description: 单位名称
type:
type: string
description: 所属分类
code:
type: string
description: 请填写参数描述
description: 返回结果
description: 业务返回体
operationId: 1690_16_POST
parameters: []
requestBody:
content:
application/x-www-form-urlencoded:
schema:
type: object
properties:
type:
type: string
description: |-
angle=角度
dataStorage=数据存储
speed=速度
time=时间
energy=力
density=密度
work=功、能、热
power=功率
pressure=压力
temperature=温度
weight=质量
volume=体积
area=面积
longness=长度
/1690-1:
x-pointCode: 1
x-mode: mapping
x-read-timeout: 15
x-connect-timeout: 15
post:
summary: 单位换算
description: 提供在线单位转换服务,涵盖公里、米、分米、厘米、里、丈、尺、寸、分、厘、海里、英寻、英里、弗隆、码、英尺、英寸、毫米、微米等长度单位。
responses:
"200":
description: 成功响应
content:
application/json:
schema:
allOf:
- $ref: "#/components/schemas/ShowapiResEnvelope"
- type: object
properties:
showapi_res_body:
type: object
properties:
ret_code:
type: number
description: 接口调用是否成功,0:扣费,表示成功,-1:不扣费,表示查询失败
result_list:
type: array
items:
type: object
properties:
result_str:
type: string
description: 字符型结果
unit:
type: string
description: 单位
result:
type: number
description: 结果
type:
type: string
description: 请填写参数描述
description: 返回结果
remark:
type: string
description: 返回说明
description: 业务返回体
operationId: 1690_1_POST
parameters: []
requestBody:
content:
application/x-www-form-urlencoded:
schema:
type: object
properties:
num:
type: string
description: 需要转换的数字
from:
type: string
description: 源单位
to:
type: string
description: 目标单位
type:
type: string
description: |-
angle=角度
dataStorage=数据存储
speed=速度
time=时间
energy=力
density=密度
work=功、能、热
power=功率
pressure=压力
temperature=温度
weight=质量
volume=体积
area=面积
longness=长度
required:
- num
- from
- to
components:
securitySchemes:
AppKeyAuth:
type: apiKey
in: query
name: appKey
description: 从 ShowAPI 控制台获取的 appKey,管理地址:https://www.showapi.com/console#/myApp
schemas:
ShowapiResEnvelope:
type: object
description: ShowAPI 统一返回包裹(业务数据位于 showapi_res_body)
properties:
showapi_res_code:
type: integer
description: API 返回的状态码
showapi_res_error:
type: string
description: API 返回的错误信息
showapi_res_id:
type: string
description: API 请求的唯一标识
showapi_fee_num:
type: integer
description: API 调用计费次数
security:
- AppKeyAuth: []
externalDocs:
url: https://www.showapi.com/apiGateway/view/1690?tab=book
x-apiCode: "1690"
x-is-own: false
x-is-op: false