Parameters

  • prompt

    • Type: string
    • Required: false
  • number

    • Type: number
    • Required: true
    • Description: Number of images to generate
    • Options: 1, 2, 3, 4
    • Default: 1
  • size

    • Type: string
    • Required: false
    • Options: 512x512, 256x256, 1024x1024
    • Default: 512x512
  • image

    • Type: string
    • Required: false
    • Description: Image you want to vary
  • stream

    • Type: boolean
    • Required: false

Response

  • cost

    • Type: number
  • results

    • Type: array
  • status

    • Type: string
  • progress

    • Type: number
  • id

    • Type: string
  • done

    • Type: boolean

Examples

Dall-e 3 example
import axios from "axios";
(async () => {
  let response = await axios({
    method: "post",
    url: 'https://api.turing.sh/image/dall-e',
    headers: {
      "Content-Type": "application/json",
      Authorization: "Bearer YOUR_API_KEY",
      "x-captcha-token": "Captcha key"
    },
    data: {
"number": 1,
"size": "512x512"
},
  })
})();