Images

An API Key is not required for MOST endpoints of this service. See Shared Responses for common error responses.

Online Check

GET https://v2.yiff.rest/online

{
  "success": true,
  "uptime": 0
}

List Categories

GET https://v2.yiff.rest/categories

{
  "success": true,
  "data": {
    "enabled": [
      {
        "name": "Animals > Birb",
        "db": "animals.birb"
      }
      // (...)
    ],
    "disabled": [
      {
        "name": "Animals > Fox",
        "db": "animals.fox",
        "_comment": "Category has never had any content."
      }
      // (...)
    ]
  }
}

Get Information About A Category

GET https://v2.yiff.rest/categories/:db

Path Parameters

Name
Type
Description

db*

String

The "db" representation of the category (see GET /categories)

Get Image

GET https://v2.yiff.rest/images/:id.json

Path Parameters

Name
Type
Description

id*

String

The ID of the image.

Get Random Image

GET https://v2.yiff.rest/:category

Path Parameters

Name
Type
Description

category*

String

The category, see GET /categories (db, replace periods with forward slashes)

Query Parameters

Name
Type
Description

amount

Number

The amount of images to request, between 1-5.

notes

String

If notes should be hidden. Use the literal string "disabled".

sizeLimit

Number

The maximum size of image to get, in powers of 2. Prefixes such as KB/MB can be used.

Get Images Bulk

POST https://v2.yiff.rest/bulk

Get an arbitrary amount of images across many categories. This endpoint requires an api key, and is restricted to developer approval.

By default, a maximum of 100 images total can be fetched in one request. You can request your limit to be raised by contacting a developer.

Path Parameters

Name
Type
Description

sizeLimit

String

The maximum size of image to get, in powers of 2. Prefixes such as KB/MB can be used.

Request Body

Name
Type
Description

some.category*

Number

A map of category (in db format) to the amount of images. See List Categories for the list of categories.

Last updated

Was this helpful?