百科.dev
全部条目AI 编程趋势榜开源项目技术资讯提交条目
登录
< 返回工具列表
A

aktools

> 后端框架
开源

AKTools 是一款为 AKShare 打造的优雅、简单的 HTTP API 库,专为 AKShare 使用者而设计!

1.4K stars0 点赞0 次浏览
访问官网GitHub

工具介绍

AKTools 是一款为 AKShare 打造的优雅、简单的 HTTP API 库,专为 AKShare 使用者而设计!

AKTools

AKTools is a package of HTTP API for AKShare! It depends on AKShare, FastAPI and Typer.

AKTools 是一款用于快速搭建 AKShare HTTP API 的工具,通过 AKTools 可以利用一行命令来启动 HTTP 服务,从而让原本专属服务于 Python 用户的开源财经数据接口库 AKShare 的使用 突破编程语言的限制。无论您使用的是 C/C++、Java、Go、Rust、Ruby、PHP、JavaScript、R、Matlab、Stata 等编程语言或软件都可以快速、轻松获取财经数据,助力您更好地展开研究和开发工作。 AKTools 中文文档

Installation

pip install aktools

Upgrade

pip install aktools --upgrade -i https://pypi.org/simple  # AKTools's version should great than 0.0.88

AKShare

Please visit AKShare's Documentation

FastAPI

Please visit FastAPI's Documentation

Typer

Please visit Typer's Documentation

Fast Run

  1. just type the cmd/bash command: python -m aktools
  2. then type http://127.0.0.1:8080/ in your Chrome and you can fetch your homepage and more information
  3. if you just want to test data api, you can type http://127.0.0.1:8080/api/public/stock_zh_a_hist in your Chrome
  4. if you want to set parameter for API, then you just type like http://127.0.0.1:8080/api/public/stock_zh_a_hist?symbol=600000

Homepage

AKTools set a simple homepage for user to provide simple reference information. When you set up your environment and deploy your local application, then you can type http:127.0.0.1:8080 in your browser. We are developing more functions now, please pay more attention!

Demo

Test-Postman

Test-R

R-Program

library(RCurl)  # 需要先安装该包
library(jsonlite)  # 需要先安装该包
options (warn = -1)  # 该行有助于在无参数请求时去掉 warning 信息

temp_df <-
  getForm(
    uri = 'http://127.0.0.1:8080/api/public/stock_zh_a_hist',  # 此处的 http://127.0.0.1:8080 需要替换为您定义的地址和端口
    symbol = '000001',
    period = 'daily',
    start_date = '20211109',
    end_date = '20211209',
    adjust = 'hfq',
    .encoding = "utf-8"
  )
inner_df <- fromJSON(temp_df)
inner_df

R-Result

…

Test-MATLAB

MATLAB-Program

api = 'http://127.0.0.1:8080/api/public/';
url = [api 'stock_zh_a_hist'];
options = weboptions('ContentType','json', 'CharacterEncoding', 'utf-8');
data = webread(url, options, symbol = '000001', period = 'daily', start_date = '20211109', end_date = '20211209', adjust = 'hfq');
data % 由于 MATLAB 无法显示中文字段名,请自行修改为英文字段,参考链接:https://iso2mesh.sourceforge.net/cgi-bin/index.cgi?jsonlab/Doc/Examples

MATLAB-Result

…

Test-Rust

Rust-Program

…

Rust-Result

…

GitHub Issues· 2 开放

在 GitHub 查看全部
  • #238

    [Bug] Windows 下路径包含空格导致 aktools 启动崩溃闪退

    更新于 2026年9月4日

核心特点

  • •Python
  • •akshare
  • •asyncio
  • •data
  • •data-science

> 标签

Pythonakshareasynciodatadata-science

暂无评论,来聊聊你的看法吧

> 工具信息

发布日期2026年8月1日
最后更新2026年9月17日
分类后端框架
定价开源

> 相关工具

N
Node.js
基于 V8 的 JavaScript 运行时
D
Django
Python 高级 Web 框架
S
Spring Boot
Java 生态主流微服务框架