Skip to main content
Glama

Tanod Images

imagepeek: extract an image's dominant colours

image_colors
Read-onlyIdempotent

imagepeek: Extract the dominant colours of an image. Returns an image's palette of k colours (hex, rgb, share), the dominant one and the average colour with its luminance, from a 200 px sample (median cut refined by k-means; transparent pixels ignored). Input: url or image_base64, optional k and auto_orient. Reads PNG, JPEG, WebP, GIF, TIFF, BMP, ICO and AVIF; other formats and images over 40 megapixels are refused (not charged). Images are never logged or stored. Typically 0.5-2 s. Price: USD 0.002. Free: 3 imagepeek calls per IP per UTC day.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
kNoPalette size (1-10, default 5).
urlNoPublic http(s) URL of the image (at most 10 MB; private, internal and IP-literal hosts are refused); or use image_base64.
auto_orientNoApply the EXIF orientation first (default true).
image_base64NoThe image as standard or url-safe base64 (at most 10 MB decoded; a data:image/...;base64, prefix is fine); or use url.

Output Schema

TableJSON Schema
NameRequiredDescriptionDefault
errorNoOnly on an error result: an object {code, message}, or the reason string of an x402 PaymentRequired object.
inputNo
notesNo
sourceNo
averageNo
paletteNo
dominantNo
final_urlNo
operationNo
source_urlNo
pixels_sampledNo

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed3 schema fields changed
    • addedInput schema / properties / auto_orient / description
      Added value: +"Apply the EXIF orientation first (default true)."
    • changedInput schema / properties / url / description
      Previous value: -"Public http(s) URL of the image (at most 10 MB); or use image_base64."New value: +"Public http(s) URL of the image (at most 10 MB; private, internal and IP-literal hosts are refused); or use image_base64."
    • changedOutput schema / (root)
      Previous value: -nullNew value: +{
      +  "properties": {
      +    "average": {
      +      "properties": {
      +        "hex": {
      +          "type": [
      +            "string",
      +            "null"
      +          ]
      +        },
      +        "luminance": {
      +          "type": [
      +            "number",
      +            "null"
      +          ]
      +        },
      +        "rgb": {
      +          "items": {
      +            "type": [
      +              "integer",
      +              "null"
      +            ]
      +          },
      +          "type": [
      +            "array",
      +            "null"
      +          ]
      +        },
      +        "share": {
      +          "type": [
      +            "number",
      +            "null"
      +          ]
      +        }
      +      },
      +      "type": [
      +        "object",
      +        "null"
      +      ]
      +    },
      +    "dominant": {
      +      "properties": {
      +        "hex": {
      +          "type": [
      +            "string",
      +            "null"
      +          ]
      +        },
      +        "luminance": {
      +          "type": [
      +            "number",
      +            "null"
      +          ]
      +        },
      +        "rgb": {
      +          "items": {
      +            "type": [
      +              "integer",
      +              "null"
      +            ]
      +          },
      +          "type": [
      +            "array",
      +            "null"
      +          ]
      +        },
      +        "share": {
      +          "type": [
      +            "number",
      +            "null"
      +          ]
      +        }
      +      },
      +      "type": [
      +        "object",
      +        "null"
      +      ]
      +    },
      +    "error": {
      +      "description": "Only on an error result: an object {code, message}, or the reason string of an x402 PaymentRequired object."
      +    },
      +    "final_url": {
      +      "type": [
      +        "string",
      +        "null"
      +      ]
      +    },
      +    "input": {
      +      "properties": {
      +        "animated": {
      +          "type": [
      +            "boolean",
      +            "null"
      +          ]
      +        },
      +        "bytes": {
      +          "type": [
      +            "integer",
      +            "null"
      +          ]
      +        },
      +        "format": {
      +          "type": [
      +            "string",
      +            "null"
      +          ]
      +        },
      +        "frames": {
      +          "type": [
      +            "integer",
      +            "null"
      +          ]
      +        },
      +        "has_alpha": {
      +          "type": [
      +            "boolean",
      +            "null"
      +          ]
      +        },
      +        "height": {
      +          "type": [
      +            "integer",
      +            "null"
      +          ]
      +        },
      +        "width": {
      +          "type": [
      +            "integer",
      +            "null"
      +          ]
      +        }
      +      },
      +      "type": [
      +        "object",
      +        "null"
      +      ]
      +    },
      +    "notes": {
      +      "items": {
      +        "type": [
      +          "string",
      +          "null"
      +        ]
      +      },
      +      "type": [
      +        "array",
      +        "null"
      +      ]
      +    },
      +    "operation": {
      +      "type": [
      +        "string",
      +        "null"
      +      ]
      +    },
      +    "palette": {
      +      "items": {
      +        "properties": {
      +          "hex": {
      +            "type": [
      +              "string",
      +              "null"
      +            ]
      +          },
      +          "luminance": {
      +            "type": [
      +              "number",
      +              "null"
      +            ]
      +          },
      +          "rgb": {
      +            "items": {
      +              "type": [
      +                "integer",
      +                "null"
      +              ]
      +            },
      +            "type": [
      +              "array",
      +              "null"
      +            ]
      +          },
      +          "share": {
      +            "type": [
      +              "number",
      +              "null"
      +            ]
      +          }
      +        },
      +        "type": [
      +          "object",
      +          "null"
      +        ]
      +      },
      +      "type": [
      +        "array",
      +        "null"
      +      ]
      +    },
      +    "pixels_sampled": {
      +      "type": [
      +        "integer",
      +        "null"
      +      ]
      +    },
      +    "source": {
      +      "type": [
      +        "object",
      +        "null"
      +      ]
      +    },
      +    "source_url": {
      +      "type": [
      +        "string",
      +        "null"
      +      ]
      +    }
      +  },
      +  "type": "object"
      +}
  2. First observed

TDQS

Score is being calculated.

Try in Browser

Glama MCP Gateway

Add one secure layer between your agents and this server.

Resources