# @fuwa/rest

> A simple REST client for Discord's public API

Latest version **0.4.0** (published 2023-09-17) · MIT license · 0 weekly downloads

## Install

```sh
npm install @fuwa/rest
pnpm add @fuwa/rest
yarn add @fuwa/rest
bun add @fuwa/rest
```

## Health

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

Positive: has types; no vulnerabilities.

Warnings: low downloads; no esm support; pre 1.0.

Negative: abandoned; low maintenance score.

## Facts

| | |
|---|---|
| Version | 0.4.0 |
| Published | 2023-09-17 |
| First published | 2022-05-03 |
| Weekly downloads | 0 |
| License | MIT |
| TypeScript types | bundled |
| Module format | CommonJS |
| Dependencies | 4 |
| Unpacked size | 246.2 KB |
| Known vulnerabilities | 0 (+16 in 1 direct dependencies) |
| Install scripts | no |
| GitHub stars | 12 |
| Author | Splatterxl |
| Maintainers | splatterxl |

## Links

- npm: https://www.npmjs.com/package/@fuwa/rest
- Repository: https://github.com/fuwa-org/fuwa
- Homepage: https://github.com/fuwa-org/fuwa#readme
- Issues: https://github.com/fuwa-org/fuwa/issues
- npm.io page: https://npm.io/package/@fuwa/rest

## Dependencies (4)

- [undici](https://npm.io/package/undici.md) ^5.24.0
- [form-data](https://npm.io/package/form-data.md) ^4.0.0
- [discord-api-types](https://npm.io/package/discord-api-types.md) ^0.37.56
- [@sapphire/async-queue](https://npm.io/package/@sapphire/async-queue.md) ^1.5.0

## Recent versions

- 0.4.0 (latest) — 2023-09-17
- 0.4.0-beta.1 — 2023-09-17
- 0.3.0 — 2022-09-18
- 0.2.2 — 2022-05-05
- 0.2.1 — 2022-05-05
- 0.2.0 — 2022-05-05
- 0.1.1 — 2022-05-03
- 0.1.0 — 2022-05-03

## README

# @fuwa/rest

A minimal, yet feature-complete, client for [Discord](https://discord.com)'s
public [REST API](https://discord.com/developers/docs). Uses undici internally.

# Installation

```shell
# using yarn
$ yarn add @fuwa/rest
# or pnpm
$ pnpm add @fuwa/rest
# or even npm
$ npm install --save @fuwa/rest
```

# Usage

```js
import { REST } from '@fuwa/rest';

const client = new REST("my_token");

await client.patch("/users/@me", {
  body: {
    username: "fuwa_l0v3r"
  },
});

// want it simpler? here you go:
await client.editCurrentUser({
  username: "fuwa_l0v3r_shorthand"
});
```

# Documentation

All endpoints under `REST` are represented by their name in the [Discord Developer Docs](https://discord.com/developers/docs).

Documentation is planned and on the roadmap. Check back here later.

# Links

- [source code](https://github.com/fuwa-org/fuwa)
- [npm package](https://npmjs.com/@fuwa/rest)

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