> ## Documentation Index
> Fetch the complete documentation index at: https://lummi.mintlify.site/llms.txt
> Use this file to discover all available pages before exploring further.

# Get Random Images

This function allows you to retrieve multiple random images based on the specified type. Useful for displaying images in a feed or gallery.

<Info>
  You should initialize [InitLummi](/authentication) before using this method.
</Info>

```typescript
import { SearchImages } from 'lummi'

const { data, success, message } = await SearchImages({
    imageType: '3d',
    limit: 5,
    free: true
})
```

## Props

<ParamField path="imageType" type="string">
  Specifies the image type: `'3d'`, `'illustrations'`, or `'images'`.
</ParamField>

<ParamField path="limit" type="number">
  Maximum number of results to fetch. Defaults to `1`; maximum is `20`.
</ParamField>

<ParamField path="free" type="boolean">
  Filters for free images only if `true`. Includes both free and pro by
  default.
</ParamField>

## Return Props

<ResponseField name="data" type="Array<Image> | null">
  The downloand url of the image if success, otherwise `null`.

  <Info>Check the [Image Interface](/interfaces/Image) and what promps it includes.</Info>
</ResponseField>

<ResponseField name="success" type="boolean">
  `true` if the request was successful, otherwise `false`.
</ResponseField>

<ResponseField name="message" type="string">
  A message describing the result of the request.
</ResponseField>

<ResponseField name="code" type="number">
  `200`, `400`, `401`, `403`, `404`, `500`.

  <Info>Read more about [status codes](/status-codes) and what they mean.</Info>
</ResponseField>
