# yuque-client

> [![NPM version](https://img.shields.io/npm/v/yuque-client.svg?style=flat)](https://npmjs.org/package/yuque-client) [![NPM downloads](http://img.shields.io/npm/dm/yuque-client.svg?style=flat)](https://npmjs.org/package/yuque-client)

Latest version **0.1.0** (published 2022-09-18) · MIT license · 0 weekly downloads

## Install

```sh
npm install yuque-client
pnpm add yuque-client
yarn add yuque-client
bun add yuque-client
```

## Health

**Score 30/100 (F)** — status: abandoned.

Positive: has types; esm support; no vulnerabilities; high quality score.

Warnings: low downloads; pre 1.0.

Negative: abandoned; low maintenance score.

## Facts

| | |
|---|---|
| Version | 0.1.0 |
| Published | 2022-09-18 |
| First published | 2022-09-18 |
| Weekly downloads | 0 |
| License | MIT |
| TypeScript types | bundled |
| Module format | ESM + CommonJS |
| Dependencies | 3 |
| Unpacked size | 102.9 KB |
| Known vulnerabilities | 0 (+12 in 1 direct dependencies) |
| Install scripts | no |
| Maintainers | hm910705 |
| Keywords | yuque, yuque-sdk, yuque-client |

## Links

- npm: https://www.npmjs.com/package/yuque-client
- npm.io page: https://npm.io/package/yuque-client

## Dependencies (3)

- [debug](https://npm.io/package/debug.md) ^4.3.4
- [undici](https://npm.io/package/undici.md) ^5.10.0
- [@bizjs/biz-utils-node](https://npm.io/package/@bizjs/biz-utils-node.md) ^0.3.5

## Recent versions

- 0.1.0 (latest) — 2022-09-18
- 0.0.2 — 2022-09-18

## README

# yuque-client

[![NPM version](https://img.shields.io/npm/v/yuque-client.svg?style=flat)](https://npmjs.org/package/yuque-client)
[![NPM downloads](http://img.shields.io/npm/dm/yuque-client.svg?style=flat)](https://npmjs.org/package/yuque-client)

## 用法

```ts
import { YuqueClient } from 'yuque-client';

const client = new YuqueClient({
  appName: 'demo',
  accessToken: 'xxx',
});

async function start() {
  const user = await client.user.getCurrentUser();
  console.log(user);
}
```

## 可用 API

### 用户

> https://www.yuque.com/yuque/developer/user

- [x] 获取单个用户信息
- [x] 获取认证的用户的个人信息

### 知识库

> https://www.yuque.com/yuque/developer/repo

- [x] 获取某个用户的知识库列表
- [x] 获取某个团队的知识库列表
- [x] 创建知识库
- [x] 获取知识库详情
- [x] 更新知识库信息
- [x] 删除知识库

### 文档

> https://www.yuque.com/yuque/developer/doc

- [x] 获取一个仓库的文档列表
- [x] 获取单篇文档的详细信息
- [x] 创建文档
- [x] 更新文档
- [x] 删除文档

---
_Source: https://npm.io/package/yuque-client · Machine-readable twin of the npm.io package page. Health data is recomputed on every publish._
