Random

Random Image

0calls
Free

Need a random image as placeholder or background? This endpoint is your best choice.

Overview

This is a very simple endpoint that randomly selects an image from our vast gallery and curated external image hosts, then redirects you directly to it via 302. This makes it very convenient to use directly in HTML <img> tags.

You can get images provided by UapiPro server through requests like /api/v1/random/image?category=acg&type=4k, or get images curated from external image hosts through /api/v1/random/image?category=ai_drawing.

If you don't provide any category parameter, the program will randomly select one from all images (including local and URL) (global random images do not include ikun and AI art).

Tip

If you need more precise control over image types, please use the/image/random/{category}/{type} endpoint.

Supported Main Categories and Subcategories

  • acg (Anime)
    • pc
    • mb
  • External Image Host Curated/Mixed Anime
    • landscape: Landscape images.
    • anime: Mixed images from UapiPro server's acg and external image host's general_anime category.
    • pc_wallpaper: PC wallpapers.
    • mobile_wallpaper: Mobile wallpapers.
    • general_anime: Anime images.
    • ai_drawing: AI art.
  • Other Categories
    • bq (Memes/Funny Images)
      • eciyuan
      • ikun
      • xiongmao
      • waiguoren
      • maomao
    • furry (Furry)
      • z4k
      • szs8k
      • s4k
      • 4k
Note

Default global random (when category parameter is not specified) does not include ikun and AI art (ai_drawing) category images.

Query parameters

category
stringoptional

(Optional) Specify image main category.

Supported main categories:

  • acg (Anime, UapiPro server)
  • landscape (Landscape images, external image host)
  • anime (Mixed anime)
  • pc_wallpaper (PC wallpapers, external image host)
  • mobile_wallpaper (Mobile wallpapers, external image host)
  • general_anime (Anime images, external image host)
  • ai_drawing (AI art, external image host)
  • bq (Memes/funny images, UapiPro server)
  • furry (Furry, UapiPro server)
Tip

If not specified, will randomly select from all images (does not includeikun and ai_drawing).

type
stringoptional

(Optional, only supported by UapiPro server images) Specify image subcategory.

  • bq: xiongmao, waiguoren, maomao, ikun, eciyuan
  • acg: pc, mb
  • furry: z4k, szs8k, s4k, 4k
Tip

External image hosting categories andanime mixed category do not support the type parameter.

Response

200 / OK

Success! Returns a random image as binary data (image/jpeg) directly to the client, can be used directly in tags.

image/jpeg

404 / Not Found

No images found for the specified category.

JSON

500 / Internal Server Error

Internal server error.

JSON