Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "docs.waifu.it",
"version": "2.0.4",
"version": "3.0.4",
"description": "The new and improved documentation for Waifu.it",
"scripts": {
"dev": "next dev",
Expand All @@ -17,7 +17,7 @@
},
"homepage": "https://github.com/WaifuAPI/Documentation/#readme",
"dependencies": {
"next": "^13.4.9",
"next": "^13.4.12",
"nextra": "2.0.1",
"nextra-theme-docs": "2.0.1",
"react": "^18.2.0",
Expand Down
2 changes: 1 addition & 1 deletion pages/faq.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
<br />

### How do I get the API token?
- To get your API token, join this [discord server](https://discord.gg/yyW389c), then type `-claim` in [#bot-commands](https://discord.com/channels/479300008118714388/800784815908454452), fill the questions asked by [@Kohai](https://discord.com/channels/@me/834416864766591016) in DM, and receive your token.
- To get your API token, join this [discord server](https://discord.gg/yyW389c), then type `-claim` in [#bot-commands](https://discord.com/channels/479300008118714388/800784815908454452), fill the questions asked by `@Kohai` in DM, and receive your token.

{/* ### CORS causing trouble?

Expand Down
4 changes: 4 additions & 0 deletions pages/libraries/Javascript/_meta.json
Original file line number Diff line number Diff line change
Expand Up @@ -2,5 +2,9 @@
"animefact": {
"title": "anime-facts",
"theme": { "collapsed": true }
},
"waifuit": {
"title": "waifu.it",
"theme": { "collapsed": true }
}
}
6 changes: 6 additions & 0 deletions pages/libraries/Javascript/waifuit/_meta.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
{
"getstarted": "Get Started",
"generatefact": "Generate Fact",
"generatequote": "Generate Quote",
"generatewaifu": "Generate Waifu"
}
47 changes: 47 additions & 0 deletions pages/libraries/Javascript/waifuit/generatefact.mdx
Original file line number Diff line number Diff line change
@@ -0,0 +1,47 @@
---
title: waifu.it | Generate Fact
---

import { Tab, Tabs } from "nextra-theme-docs";

# Generate Fact

Generate random anime facts from a huge database.


## Functions

| Function | Type | Description | Required? |
| :------: | :------: | ---------------------------------------------------- | :-------: |
| getFact | function | The search function to generate a random anime fact. | Yes |

## Request Samples

<Tabs items={["Node.js"]}>
<Tab>
<>
```js
import Client from "waifu.it";

// Replace <TOKEN> with your API Token
const api = new Client("<TOKEN>");
api.getFact().then((res) => console.log(res));
```
</>

</Tab>
</Tabs>

## Response Schema

<Tabs items={["200 OK"]}>
<Tab>
**Content Type:** `application/json`
```json copy=false
{
"id": 5,
"fact": "TEZUKA Osamu is the most famous manga artist in Japan.",
}
```
</Tab>
</Tabs>
49 changes: 49 additions & 0 deletions pages/libraries/Javascript/waifuit/generatequote.mdx
Original file line number Diff line number Diff line change
@@ -0,0 +1,49 @@
---
title: waifu.it | Generate Quote
---

import { Tab, Tabs } from "nextra-theme-docs";

# Generate Fact

Generate random anime Quote from a huge database.


## Functions

| Function | Type | Description | Required? |
| :------: | :------: | ---------------------------------------------------- | :-------: |
| getQuote | function | The search function to generate a random anime quote. | Yes |

## Request Samples

<Tabs items={["Node.js"]}>
<Tab>
<>
```js
import Client from "waifu.it";

// Replace <TOKEN> with your API Token
const api = new Client("<TOKEN>");
api.getQuote().then((res) => console.log(res));
```
</>

</Tab>
</Tabs>

## Response Schema

<Tabs items={["200 OK"]}>
<Tab>
**Content Type:** `application/json`
```json copy=false
{
"id": 5,
"quote": "Even children are forced to grow up in the face of pain.",
"author": "Pain",
"anime": "Naruto"
}
```
</Tab>
</Tabs>
46 changes: 46 additions & 0 deletions pages/libraries/Javascript/waifuit/generatewaifu.mdx
Original file line number Diff line number Diff line change
@@ -0,0 +1,46 @@
---
title: waifu.it | Generate Waifu
---

import { Tab, Tabs } from "nextra-theme-docs";

# Generate Fact

Generate random anime Waifu from a huge database.


## Functions

| Function | Type | Description | Required? |
| :------: | :------: | ---------------------------------------------------- | :-------: |
| getWaifu | function | The search function to generate a random anime Waifu. | Yes |

## Request Samples

<Tabs items={["Node.js"]}>
<Tab>
<>
```js
import Client from "waifu.it";

// Replace <TOKEN> with your API Token
const api = new Client("<TOKEN>");
api.getWaifu().then((res) => console.log(res));
```
</>

</Tab>
</Tabs>

## Response Schema

<Tabs items={["200 OK"]}>
<Tab>
**Content Type:** `application/json`
```json copy=false
{
"id": 5,
}
```
</Tab>
</Tabs>
26 changes: 26 additions & 0 deletions pages/libraries/Javascript/waifuit/getstarted.mdx
Original file line number Diff line number Diff line change
@@ -0,0 +1,26 @@
import { Tab, Tabs } from "nextra-theme-docs";

# Get Started

The "waifu.it" library is the official wrapper for waifu.it! Very small install size.

## Installation

Instructions for installing the library can be found below.

{/* NOTE: do NOT run a formatter for the time being; it breaks the code blocks below. */}

<Tabs items={["npm", "yarn"]}>
<Tab>
```bash
npm i waifu.it
```
View package at [npmjs.com](https://www.npmjs.com/package/waifu.it)
</Tab>
<Tab>
```bash
yarn add waifu.it
```
View package at [yarnpkg.com](https://yarnpkg.com/package/waifu.it)
</Tab>
</Tabs>
2 changes: 1 addition & 1 deletion pages/libraries/Python/waifuit/search.mdx
Original file line number Diff line number Diff line change
@@ -1 +1 @@
owo WIP
The developer hasn't provided documentation yet. Reach them at -> [Discord](https://discord.gg/yyW389c)
Loading