时区转换API - 捷帮开发者API

捷帮时区转换API提供简单易用的RESTful接口,开发者可通过HTTP POST请求快速集成到自己的应用中。

无需API Key即可免费调用(有速率限制),高频使用建议注册免费API Key。
POST https://www.jiebang.site/api/timezone-convert
在线试用 →

请求参数

参数名类型必填说明
timestring时间字符串
from_tzstring源时区,如 Asia/Shanghai
to_tzstring目标时区,如 America/New_York
api_keystringAPI密钥

请求示例

# cURL curl -X POST https://www.jiebang.site/api/timezone-convert \ -H "Content-Type: application/json" \ -d '{"time": "2026-06-05 14:00:00", "from_tz": "Asia/Shanghai", "to_tz": "America/New_York"}'
// JavaScript fetch('https://www.jiebang.site/api/timezone-convert', { method: 'POST', headers: { 'Content-Type': 'application/json' }, body: JSON.stringify({"time": "2026-06-05 14:00:00", "from_tz": "Asia/Shanghai", "to_tz": "America/New_York"}) }) .then(r => r.json()) .then(d => console.log(d))
# Python import requests resp = requests.post( 'https://www.jiebang.site/api/timezone-convert', json={"time": "2026-06-05 14:00:00", "from_tz": "Asia/Shanghai", "to_tz": "America/New_York"} ) print(resp.json())

响应示例

{"success": true, "result": {"output_time": "2026-06-05 02:00:00", "to_timezone": "America/New_York (UTC-4)", "offset_diff": "-12h"}}

支持全球IANA时区数据库中的400+时区互转,自动处理夏令时转换,支持多种输出格式

捷帮API采用RESTful设计,所有接口统一使用POST方法,请求和响应均为JSON格式。基础调用无需认证,高级功能可注册免费API Key。

相关API

常见问题

时区转换API免费

捷帮提供免费的时区转换接口,访问 https://www.jiebang.site/api-docs/timezone-convert.html 查看完整API文档。支持POST请求,无需API Key即可开始使用。

北京时间转纽约时间API

捷帮提供免费的时区转换接口,访问 https://www.jiebang.site/api-docs/timezone-convert.html 查看完整API文档。支持POST请求,无需API Key即可开始使用。

全球时区转换API接口

捷帮提供免费的时区转换接口,访问 https://www.jiebang.site/api-docs/timezone-convert.html 查看完整API文档。支持POST请求,无需API Key即可开始使用。

时差计算API文档

捷帮提供免费的时区转换接口,访问 https://www.jiebang.site/api-docs/timezone-convert.html 查看完整API文档。支持POST请求,无需API Key即可开始使用。

夏令时自动处理API

捷帮提供免费的时区转换接口,访问 https://www.jiebang.site/api-docs/timezone-convert.html 查看完整API文档。支持POST请求,无需API Key即可开始使用。