Available Tools

The POST /v1/tools endpoint provides image-analysis utilities powered by the H2I engine (PixLab).

These tools operate on uploaded images and return structured JSON analysis results. Tools can be executed in either:

action=single

or

action=multitask

Requests must upload at least one image using the images field. Tool selection is provided through tools or tools[]. The route parses tool selections from comma-separated text, and action=single requires exactly one tool.

Shared Request Notes #

Endpoint #

POST https://pixlab.davix.dev/v1/tools

Request format #

Requests to /v1/tools must use:

  • Content-Type: multipart/form-data
  • images for uploaded image files
  • tools or tools[] for tool names

Shared fields #

  • actionsingle or multitask
  • images → one or more uploaded images
  • tools or tools[] → selected tool names

Public tool names #

The public external API reference documents these tool names:

  • metadata
  • colors
  • detect-format
  • orientation
  • hash
  • similarity
  • dimensions
  • quality
  • transparency
  • efficiency

Success response shape #

Tool execution returns JSON analysis output in this general form:

{
"results": [
{
"originalName": "image.jpg",
"sizeBytes": 123456,
"tools": {}
}
],
"request_id": "req_abc123"
}

Similarity can also add similarity-specific structures depending on the mode used.


Metadata #

Tool name #

metadata

Description #

Extracts metadata from the uploaded image.

This can include image properties and embedded metadata. Raw EXIF can also be included when requested.

Parameters #

includeRawExif #

Type: boolean-like
Required: No
Default: false

When set to exactly true, raw EXIF data is included in the result.

Single execution example #

curl -sS -X POST "https://pixlab.davix.dev/v1/tools" \
-H "X-Api-Key: <YOUR_API_KEY>" \
-H "Idempotency-Key: tool-metadata-single-001" \
-F "action=single" \
-F "tools=metadata" \
-F "images=@./samples/image.jpg" \
-F "includeRawExif=true"

Multitask example #

curl -sS -X POST "https://pixlab.davix.dev/v1/tools" \
-H "X-Api-Key: <YOUR_API_KEY>" \
-H "Idempotency-Key: tool-metadata-multi-001" \
-F "action=multitask" \
-F "tools=metadata,dimensions" \
-F "images=@./samples/image.jpg"

Colors #

Tool name #

colors

Description #

Analyzes image colors and returns dominant color and palette-related information. The public tools reference documents paletteSize as the colors-specific parameter for controlling palette sizing.

Parameters #

paletteSize #

Type: integer-like
Required: No
Default: 5
Allowed range: 1 to 16

Controls palette size for colors analysis.

Single execution example #

curl -sS -X POST "https://pixlab.davix.dev/v1/tools" \
-H "X-Api-Key: <YOUR_API_KEY>" \
-H "Idempotency-Key: tool-colors-single-001" \
-F "action=single" \
-F "tools=colors" \
-F "images=@./samples/image.jpg" \
-F "paletteSize=5"

Multitask example #

curl -sS -X POST "https://pixlab.davix.dev/v1/tools" \
-H "X-Api-Key: <YOUR_API_KEY>" \
-H "Idempotency-Key: tool-colors-multi-001" \
-F "action=multitask" \
-F "tools=colors,quality" \
-F "images=@./samples/image.jpg" \
-F "paletteSize=5"

Detect Format #

Tool name #

detect-format

Description #

Detects the format and MIME type of the uploaded image.

Parameters #

No additional parameters are documented for this tool in the public /v1/tools reference.

Single execution example #

curl -sS -X POST "https://pixlab.davix.dev/v1/tools" \
-H "X-Api-Key: <YOUR_API_KEY>" \
-H "Idempotency-Key: tool-format-single-001" \
-F "action=single" \
-F "tools=detect-format" \
-F "images=@./samples/image.jpg"

Multitask example #

curl -sS -X POST "https://pixlab.davix.dev/v1/tools" \
-H "X-Api-Key: <YOUR_API_KEY>" \
-H "Idempotency-Key: tool-format-multi-001" \
-F "action=multitask" \
-F "tools=detect-format,metadata" \
-F "images=@./samples/image.jpg"

Orientation #

Tool name #

orientation

Description #

Detects the orientation of the uploaded image.

Parameters #

No additional parameters are documented for this tool in the public /v1/tools reference.

Single execution example #

curl -sS -X POST "https://pixlab.davix.dev/v1/tools" \
-H "X-Api-Key: <YOUR_API_KEY>" \
-H "Idempotency-Key: tool-orientation-single-001" \
-F "action=single" \
-F "tools=orientation" \
-F "images=@./samples/image.jpg"

Multitask example #

curl -sS -X POST "https://pixlab.davix.dev/v1/tools" \
-H "X-Api-Key: <YOUR_API_KEY>" \
-H "Idempotency-Key: tool-orientation-multi-001" \
-F "action=multitask" \
-F "tools=orientation,dimensions" \
-F "images=@./samples/image.jpg"

Hash #

Tool name #

hash

Description #

Generates a hash for the uploaded image. This can be used for comparison, integrity checks, or deduplication workflows.

Parameters #

hashType #

Type: string
Required: No
Default: phash

Accepted values:

  • phash
  • md5
  • sha1
  • sha256

Single execution example #

curl -sS -X POST "https://pixlab.davix.dev/v1/tools" \
-H "X-Api-Key: <YOUR_API_KEY>" \
-H "Idempotency-Key: tool-hash-single-001" \
-F "action=single" \
-F "tools=hash" \
-F "images=@./samples/image.jpg" \
-F "hashType=sha256"

Multitask example #

curl -sS -X POST "https://pixlab.davix.dev/v1/tools" \
-H "X-Api-Key: <YOUR_API_KEY>" \
-H "Idempotency-Key: tool-hash-multi-001" \
-F "action=multitask" \
-F "tools=hash,similarity" \
-F "images=@./samples/image1.jpg" \
-F "images=@./samples/image2.jpg"

Similarity #

Tool name #

similarity

Description #

Compares uploaded images and calculates visual similarity.

Parameters #

similarityMode #

Type: string
Required: No
Default: pairs

Accepted values documented across the uploaded public source files:

  • pairs
  • toFirst in public cURL examples

The external API reference documents the normalized mode set as pairs and tofirst.

similarityThreshold #

Type: integer-like
Required: No
Default: 8
Allowed range: 0 to 64

Single execution example #

curl -sS -X POST "https://pixlab.davix.dev/v1/tools" \
-H "X-Api-Key: <YOUR_API_KEY>" \
-H "Idempotency-Key: tool-similarity-single-001" \
-F "action=single" \
-F "tools=similarity" \
-F "images=@./samples/a.jpg" \
-F "images=@./samples/b.jpg"

Multitask example #

curl -sS -X POST "https://pixlab.davix.dev/v1/tools" \
-H "X-Api-Key: <YOUR_API_KEY>" \
-H "Idempotency-Key: tool-similarity-multi-001" \
-F "action=multitask" \
-F "tools=hash,similarity,quality" \
-F "images=@./samples/a.jpg" \
-F "images=@./samples/b.jpg"

Dimensions #

Tool name #

dimensions

Description #

Returns image dimension information for the uploaded file. The documented result shape includes width, height, aspect, and orientation class. This is described in the external cURL examples.

Parameters #

No additional parameters are documented for this tool in the public /v1/tools reference.

Single execution example #

curl -sS -X POST "https://pixlab.davix.dev/v1/tools" \
-H "X-Api-Key: <YOUR_API_KEY>" \
-H "Idempotency-Key: tool-dimensions-single-001" \
-F "action=single" \
-F "tools=dimensions" \
-F "images=@./samples/image.jpg"

Multitask example #

curl -sS -X POST "https://pixlab.davix.dev/v1/tools" \
-H "X-Api-Key: <YOUR_API_KEY>" \
-H "Idempotency-Key: tool-dimensions-multi-001" \
-F "action=multitask" \
-F "tools=dimensions,metadata,quality" \
-F "images=@./samples/image.jpg"

Quality #

Tool name #

quality

Description #

Estimates image sharpness and visual quality using sampling analysis.

Parameters #

qualitySample #

Type: integer-like
Required: No
Default: 256
Allowed range: 64 to 512

Single execution example #

curl -sS -X POST "https://pixlab.davix.dev/v1/tools" \
-H "X-Api-Key: <YOUR_API_KEY>" \
-H "Idempotency-Key: tool-quality-single-001" \
-F "action=single" \
-F "tools=quality" \
-F "images=@./samples/image.jpg" \
-F "qualitySample=256"

Multitask example #

curl -sS -X POST "https://pixlab.davix.dev/v1/tools" \
-H "X-Api-Key: <YOUR_API_KEY>" \
-H "Idempotency-Key: tool-quality-multi-001" \
-F "action=multitask" \
-F "tools=quality,metadata,dimensions" \
-F "images=@./samples/image.jpg"

Transparency #

Tool name #

transparency

Description #

Analyzes transparency in an uploaded image.

Parameters #

transparencySample #

Type: integer-like
Required: No
Default: 64
Allowed range: 16 to 128

Single execution example #

curl -sS -X POST "https://pixlab.davix.dev/v1/tools" \
-H "X-Api-Key: <YOUR_API_KEY>" \
-H "Idempotency-Key: tool-transparency-single-001" \
-F "action=single" \
-F "tools=transparency" \
-F "images=@./samples/image.png" \
-F "transparencySample=64"

Multitask example #

curl -sS -X POST "https://pixlab.davix.dev/v1/tools" \
-H "X-Api-Key: <YOUR_API_KEY>" \
-H "Idempotency-Key: tool-transparency-multi-001" \
-F "action=multitask" \
-F "tools=transparency,quality" \
-F "images=@./samples/image.png"

Efficiency #

Tool name #

efficiency

Description #

Estimates how efficiently an image would compress when converted to another format.

Parameters #

efficiencyFormat #

Type: string
Required: No

Accepted values:

  • jpeg
  • jpg
  • png
  • webp
  • avif
efficiencyQuality #

Type: integer-like
Required: No
Default: 80
Range: 1 to 100

Single execution example #

curl -sS -X POST "https://pixlab.davix.dev/v1/tools" \
-H "X-Api-Key: <YOUR_API_KEY>" \
-H "Idempotency-Key: tool-efficiency-single-001" \
-F "action=single" \
-F "tools=efficiency" \
-F "images=@./samples/image.jpg" \
-F "efficiencyFormat=webp"

Multitask example #

curl -sS -X POST "https://pixlab.davix.dev/v1/tools" \
-H "X-Api-Key: <YOUR_API_KEY>" \
-H "Idempotency-Key: tool-efficiency-multi-001" \
-F "action=multitask" \
-F "tools=efficiency,quality" \
-F "images=@./samples/image.jpg"
Was it helpful ?
Scroll to Top