Hotpot API Documentation

Integrate Hotpot functionality into your app, website, or company workflow with the Hotpot API.

Self-hosted options are available for companies requiring on-premise solutions for privacy or regulatory reasons.

The API is based on REST.

The Hotpot API is in open beta. Please contact us to request access.

Demos

The API endpoints listed below power the AI services and graphic platform on Hotpot.ai. The Tools page offers product demos for the AI services.

You can view code examples on our Github repo.

Partners

The Hotpot API is designed for enterprise-level scalability and reliability, suitable for bursty workloads or sustained high-volume traffic.

To ensure we adopt best practices and state-of-the-art technologies, Hotpot is proud to partner with leaders in cloud infrastructure and machine learning.

See partners.

Authentication

All API requests require authentication. To authenticate to the API, pass the X-API-KEY HTTP header to each request.

You can view and manage API credentials from your account.

Base URL

https://api.hotpot.ai/

Responses

The Hotpot API uses standard HTTP status codes to communicate the result of API operations.

Status Codes
200
Success. Enjoy this amazing TikTok video. You deserve it.
400
Bad request. Invalid parameter values were provided or a required parameter was missing.
403
Forbidden. No valid API key provided.
404
Missing endpoint. The requested API endpoint was not found.
429
Rate limit exceeded. Make sure you have enough credits left in your account. Please employ exponential backoff before retrying.
500, 503
Hotpot server errors.

In the event of a 4xx or 5xx error, the API will supply the response listed below. For successful invocations, the API will provide a response as described in the relevant endpoint section.

Error Response Body
{
  "code": 429,
  "message": "Rate limit exceeded"
}
Error Response Properties
code
The status code of the error.
message
Details on the error.

Graphic Creator

Create App Store screenshots, Instagram posts, e-commerce ads, game assets, and other graphics programmatically by customizing Hotpot.ai templates.

Endpoint
POST /create-graphic
Request Parameters
designID
Required
The ID of the Hotpot template to customize.
textList
Optional
Accepted Values: Array of strings.
The text to use in the Hotpot graphic. Text replacement occurs sequentially, that is, the first array element replaces the first text item in the Hotpot template, the second array element replaces the second text item, etc.
screenshotList
Optional
Accepted Values: Array of Base64 image.
The screenshots to use in the Hotpot graphic. Screenshot replacement occurs sequentially, that is, the first array element replaces the first screenshot item in the Hotpot template, the second array element replaces the second screenshot item, etc.
imageList
Optional
Accepted Values: Array of Base64 image.
The images to use in the Hotpot graphic. Image replacement occurs sequentially, that is, the first array element replaces the first image item in the Hotpot template, the second array element replaces the second image item, etc.
Response Properties
base64Image
Base64 image. The resulting image after customizing the Hotpot.ai template with the parameter values.
Response Example
{
  "base64Image": "aHR0cHM6Ly9ob3Rwb3QuYWkvaG90cG90Y2hh"
}

Art Personalization

Create personalized art with AI. Our deep learning model uses Neural Style Transfer to offer arbitrary artistic style transfer, allowing you to extract the style from one image and apply it to another. Most image style transfer models are trained on fixed, pre-defined styles. Ours is designed for flexibility and can accommodate styles not encountered during the training phase.

Endpoint
POST /remix-art
Request Parameters
base64ContentImage
Required
Accepted Values: Base64 image.
The image to modify.
base64StyleImageList
Required
Accepted Values: Array of Base64 images.
An array of images whose styles will be applied to the content image. The array must be non-empty. The image styles will be combined in sequential order.
focusContent
Required
Accepted Values: true or false.
Set to true if you want the result to resemble the base image (base64ContentImage). Setting it to false will result in a more cartoonish image.
Response Properties
base64Image
Base64 image. The resulting image after transferring style to the content image.
Response Example
{
  "base64Image": "aHR0cHM6Ly9ob3Rwb3QuYWkvaG90cG90Y2hh"
}

Picture Restorer

Restore pictures with AI by removing scratches, sharpening colors, and enhancing faces. Repairs color and black & white photos.

Endpoint
POST /restore-picture
Request Parameters
base64Image
Required
Accepted Values: Base64 image.
The picture to restore.
withScratch
Required
Accepted Values: true or false.
Does the image have scratches?
Response Properties
base64Image
Base64 image. The resulting image after AI processing.
Response Example
{
  "base64Image": "aHR0cHM6Ly9ob3Rwb3QuYWkvaG90cG90Y2hh"
}

Picture Colorizer

Colorize black and white pictures with AI.

Endpoint
POST /colorize-picture
Request Parameters
imageBase64
Required
Accepted Values: Base64 image.
The black and white image to colorize.
render_factor
Required
Accepted Values: 0 - 50.
The colorization factor, as described on the DeOldify GitHub.
Response Properties
imageBase64
Base64 image. The resulting image after AI processing.
Response Example
{
  "imageBase64": "aHR0cHM6Ly9ob3Rwb3QuYWkvaG90cG90Y2hh"
}

Graphic Enlarger

Enlarge pictures, game assets, textures, and other graphics in seconds. This AI upscaler can create images of higher resolution without losing quality and is optimized for e-commerce stores, app graphics, and photo prints.

Endpoint
POST /supersize-image
Request Parameters
imageBase64
Required
Accepted Values: Base64 image.
The image to modify.
sizeFactor
Required
Accepted Values: 2, 4, 8, 16.
The multiple by which to increase image resolution.
imageStyle
Required
Accepted Values: default, anime.
The style that best describes the image to modify. Our AI accounts for different styles when extrapolating from an input image to output images of higher resolution.
noiseCancellationFactor
Required
Accepted Values: 0, 1, 2.
The level of noise cancellation applied. 0 means no noise cancellation. 1 means low noise cancellation. 2 means medium noise cancellation.
Response Properties
imageBase64
Base64 image. The resulting image after extrapolating the input image to a higher resolution.
Response Example
{
  "imageBase64": "aHR0cHM6Ly9ob3Rwb3QuYWkvaG90cG90Y2hh"
}

File Translator

Translate iOS, Android, YouTube, and other localization files with AI.

Endpoint
POST /translate-file
Request Parameters
text
Required
Accepted Values: String array.
The text to translate, organized as an array of strings.
type
Required
Accepted Values: plaintext, localizable.strings, strings.xml, json, resx, html, srt.
The format of the text submitted for translation.
sourceLanaguageCode
Required
Accepted Values: See code list.
The language to translate from, represented by its Microsoft Translator language code
targetLanguageCode
Required
Accepted Values: See code list.
The language to translate to, represented by its Microsoft Translator language code
Response Properties
translatedText
String array. The input string array after translation to the target language.
Response Example
{
  "translatedText": [
    "translatedText1",
    "translatedText2",
    "translatedText3"
  ]
}

Background Remover

Remove the background from images with AI.

Endpoint
POST /remove-background
Request Parameters
imageBase64
Required
Accepted Values: Base64 image.
The image from which to remove the background.
Response Properties
imageBase64
Base64 image. The resulting image after removing the background from the input image.
Response Example
{
  "imageBase64": "aHR0cHM6Ly9ob3Rwb3QuYWkvaG90cG90Y2hh"
}

Color Generator

Generate color palettes or matching colors based on a baseline color.

Endpoint
POST /generate-color
Request Parameters
hintColorList
Required
Accepted Values: Array of 5 RGB colors. Each RGB color is an array of 3 integers which each represent one RGB component: the first integer represents red, the second integer represents green, and the third integer represents blue.
These colors are hints for the machine learning model, which will attempt to generate matching colors based on these hints. At least 1 hint must be provided. If you have fewer than 5 hints, start at index 0 with the first and use [256, 256, 256] to fill the array. For instance, to seed the generator with only [88, 88, 88], use this array: [[88, 88, 88], [256, 256, 256], [256, 256, 256], [256, 256, 256], [256, 256, 256] ]
Response Properties
paletteColorList
Array of RGB colors. Each RGB color is an array of 3 integers which each represent one RGB component: the first integer represents red, the second integer represents green, and the third integer represents blue
Response Example
{
  "paletteColorList": [[128, 168, 188], [22, 88, 22], [88, 22, 68], [28, 68, 88], [168, 188, 188]]
}

Color From Picture

Extract the primary colors from a picture.

Endpoint
POST /color-from-picture
Request Parameters
base64Image
Not required
Accepted Values: Base64 image.
The picture or graphic from which to extract colors.
Response Properties
color0
Array of three integers. RGB color of the most dominant color from the input picture.
color1
Array of three integers. RGB color of the second most dominant color from the input picture.
color2
Array of three integers. RGB color of the third most dominant color from the input picture.
color3
Array of three integers. RGB color of the fourth most dominant color from the input picture.
color4
Array of three integers. RGB color of the fifth most dominant color from the input picture.
Response Example
{
  "color0": [255, 255, 255], 
  "color1": [255, 255, 255], 
  "color2": [255, 255, 255], 
  "color3": [255, 255, 255], 
  "color4": [255, 255, 255]
}

Face Blurrer

Blur faces, text, and other sensitive information in a picture.

Endpoint
POST /blur-face
Request Parameters
base64Image
Required
Accepted Values: Base64 image.
The image to blur.
shouldBlurText
Required
Accepted Values: true or false.
True to blur text, false otherise.
Response Properties
base64Image
Base64 image. The resulting image after redaction.
Response Example
{
  "base64Image": "aHR0cHM6Ly9ob3Rwb3QuYWkvaG90cG90Y2hh"
}