MCP tools

mastercss_manifest_query

Query active manifest tokens, utilities, variants, modes, conditions, and aliases.

Contract

Look up registered tokens, utilities, variants, modes, conditions, and aliases in the active manifest.

Input

context
stringOptional

Semantic context. Defaults to project; entry discovery or compilation failures are reported without falling back. Select preset explicitly for standalone preset queries. Values: project, preset.

query
stringOptional

Case-insensitive substring query. Omit for all entries in the selected kinds.

kind
stringOptional

Category to return. Defaults to all. Values: all, token, utility, variant, mode, condition, alias.

namespace
stringOptional

Exact namespace filter for tokens and utilities. Other categories are not filtered by namespace.

limit
integerOptional

Maximum entries returned per category, not across the whole response. Defaults to 50. Minimum: 1. Maximum: 500.

Complete input schema
JSON
{  "$schema": "http://json-schema.org/draft-07/schema#",  "type": "object",  "properties": {    "context": {      "type": "string",      "enum": [        "project",        "preset"      ]    },    "query": {      "type": "string"    },    "kind": {      "type": "string",      "enum": [        "all",        "token",        "utility",        "variant",        "mode",        "condition",        "alias"      ]    },    "namespace": {      "type": "string"    },    "limit": {      "type": "integer",      "minimum": 1,      "maximum": 500    }  }}

Example

Call mastercss_manifest_query from a connected MCP client with these arguments:

Arguments
{  "kind": "token",  "namespace": "color",  "query": "brand",  "limit": 10}

This query returns a brand color only if the loaded manifest defines one.

Output

results groups tokens, utilities, variants, modes, conditions, and aliases. summary.total counts matches before per-category limits, while summary.returned counts returned items. Check manifest errors before interpreting an empty result.

Every tool returns an object with version: 3, metadata, diagnostics and result. Success payload fields described above live in result.data; failure has result.status: "error" and a required { code, message } error. JSON text equals structuredContent. Tool errors set isError. Metadata records actual context, package/language/binding versions, manifest fingerprint, entries and dependencies; unavailable information is null or an empty array.

Complete output schema
JSON
{  "$schema": "http://json-schema.org/draft-07/schema#",  "type": "object",  "properties": {    "version": {      "type": "number",      "const": 3    },    "metadata": {      "type": "object",      "properties": {        "versions": {          "anyOf": [            {              "type": "object",              "properties": {                "languageVersion": {                  "type": "number"                },                "bindingAbiVersion": {                  "type": "number"                },                "packageVersion": {                  "type": "string"                }              },              "required": [                "languageVersion",                "bindingAbiVersion",                "packageVersion"              ],              "additionalProperties": {}            },            {              "type": "null"            }          ]        },        "context": {          "anyOf": [            {              "type": "string",              "enum": [                "project",                "preset"              ]            },            {              "type": "null"            }          ]        },        "manifestFingerprint": {          "type": [            "string",            "null"          ]        },        "entries": {          "type": "array",          "items": {            "type": "string"          }        },        "dependencies": {          "type": "array",          "items": {            "type": "string"          }        }      },      "required": [        "versions",        "context",        "manifestFingerprint",        "entries",        "dependencies"      ],      "additionalProperties": false    },    "diagnostics": {      "type": "array",      "items": {        "type": "object",        "properties": {          "code": {            "type": "string"          },          "phase": {            "type": "string"          },          "severity": {            "type": [              "string",              "number"            ]          },          "message": {            "type": "string"          },          "notes": {            "type": "array",            "items": {              "type": "string"            }          },          "alternatives": {            "type": "array",            "items": {              "type": "string"            }          },          "source": {            "type": "string"          },          "range": {            "anyOf": [              {                "type": "object",                "properties": {                  "start": {                    "type": "number"                  },                  "end": {                    "type": "number"                  }                },                "required": [                  "start",                  "end"                ],                "additionalProperties": false              },              {                "type": "object",                "properties": {                  "start": {                    "type": "object",                    "properties": {                      "line": {                        "type": "number"                      },                      "character": {                        "type": "number"                      }                    },                    "required": [                      "line",                      "character"                    ],                    "additionalProperties": false                  },                  "end": {                    "type": "object",                    "properties": {                      "line": {                        "type": "number"                      },                      "character": {                        "type": "number"                      }                    },                    "required": [                      "line",                      "character"                    ],                    "additionalProperties": false                  }                },                "required": [                  "start",                  "end"                ],                "additionalProperties": false              }            ]          }        },        "required": [          "message"        ],        "additionalProperties": {}      }    },    "result": {      "oneOf": [        {          "type": "object",          "properties": {            "status": {              "type": "string",              "const": "success"            },            "data": {              "type": "object",              "properties": {                "manifest": {                  "type": "object",                  "properties": {                    "context": {                      "type": "string",                      "enum": [                        "project",                        "preset"                      ]                    },                    "status": {                      "type": "string",                      "enum": [                        "loaded",                        "error"                      ]                    },                    "fingerprint": {                      "type": [                        "string",                        "null"                      ]                    },                    "entries": {                      "type": "array",                      "items": {                        "type": "string"                      }                    },                    "dependencies": {                      "type": "array",                      "items": {                        "type": "string"                      }                    },                    "versions": {                      "type": "object",                      "properties": {                        "languageVersion": {                          "type": "number"                        },                        "bindingAbiVersion": {                          "type": "number"                        },                        "packageVersion": {                          "type": "string"                        }                      },                      "required": [                        "languageVersion",                        "bindingAbiVersion",                        "packageVersion"                      ],                      "additionalProperties": {}                    }                  },                  "required": [                    "context",                    "status",                    "fingerprint",                    "entries",                    "dependencies"                  ],                  "additionalProperties": {}                },                "results": {                  "type": "object",                  "properties": {                    "tokens": {                      "type": "array",                      "items": {                        "type": "object",                        "properties": {                          "key": {                            "type": "string"                          },                          "name": {                            "type": "string"                          },                          "namespace": {                            "type": "string"                          },                          "type": {                            "type": "string"                          },                          "value": {                            "anyOf": [                              {                                "type": "string"                              },                              {                                "type": "number"                              },                              {                                "type": "boolean",                                "const": false                              },                              {                                "type": "array",                                "items": {                                  "type": [                                    "string",                                    "number"                                  ]                                }                              }                            ]                          },                          "numeric": {                            "type": "object",                            "properties": {                              "value": {                                "type": "number"                              },                              "unit": {                                "type": "string"                              }                            },                            "required": [                              "value"                            ],                            "additionalProperties": false                          },                          "dependencies": {                            "type": "array",                            "items": {                              "type": "string"                            }                          },                          "modes": {                            "type": "object",                            "propertyNames": {                              "type": "string"                            },                            "additionalProperties": {                              "type": "object",                              "properties": {                                "type": {                                  "type": "string",                                  "enum": [                                    "string",                                    "number"                                  ]                                },                                "value": {                                  "type": [                                    "string",                                    "number"                                  ]                                },                                "numeric": {                                  "type": "object",                                  "properties": {                                    "value": {                                      "type": "number"                                    },                                    "unit": {                                      "type": "string"                                    }                                  },                                  "required": [                                    "value"                                  ],                                  "additionalProperties": false                                }                              },                              "required": [                                "type",                                "value"                              ],                              "additionalProperties": false                            }                          },                          "inline": {                            "type": "boolean"                          },                          "static": {                            "type": "boolean"                          },                          "mode": {                            "type": "string"                          }                        },                        "required": [                          "key",                          "name",                          "type",                          "dependencies"                        ],                        "additionalProperties": false                      }                    },                    "utilities": {                      "type": "array",                      "items": {                        "type": "object",                        "properties": {                          "id": {                            "type": "string"                          },                          "type": {                            "type": "number"                          },                          "matchers": {                            "type": "array",                            "items": {                              "oneOf": [                                {                                  "type": "object",                                  "properties": {                                    "type": {                                      "type": "string",                                      "const": "static"                                    },                                    "name": {                                      "type": "string"                                    }                                  },                                  "required": [                                    "type",                                    "name"                                  ],                                  "additionalProperties": false                                },                                {                                  "type": "object",                                  "properties": {                                    "type": {                                      "type": "string",                                      "const": "pattern"                                    },                                    "prefix": {                                      "type": "string"                                    },                                    "values": {                                      "type": "array",                                      "items": {                                        "type": "string"                                      }                                    },                                    "valueMap": {                                      "type": "object",                                      "propertyNames": {                                        "type": "string"                                      },                                      "additionalProperties": {                                        "type": "string"                                      }                                    }                                  },                                  "required": [                                    "type",                                    "prefix",                                    "values"                                  ],                                  "additionalProperties": false                                },                                {                                  "type": "object",                                  "properties": {                                    "type": {                                      "type": "string",                                      "const": "key"                                    },                                    "keys": {                                      "type": "array",                                      "items": {                                        "type": "string"                                      }                                    }                                  },                                  "required": [                                    "type",                                    "keys"                                  ],                                  "additionalProperties": false                                },                                {                                  "type": "object",                                  "properties": {                                    "type": {                                      "type": "string",                                      "const": "token"                                    },                                    "prefix": {                                      "type": "string"                                    }                                  },                                  "required": [                                    "type",                                    "prefix"                                  ],                                  "additionalProperties": false                                }                              ]                            }                          },                          "emit": {                            "oneOf": [                              {                                "type": "object",                                "properties": {                                  "type": {                                    "type": "string",                                    "const": "declarations"                                  },                                  "declarations": {                                    "type": "array",                                    "items": {                                      "type": "string"                                    }                                  }                                },                                "required": [                                  "type",                                  "declarations"                                ],                                "additionalProperties": false                              },                              {                                "type": "object",                                "properties": {                                  "type": {                                    "type": "string",                                    "const": "template"                                  },                                  "declarations": {                                    "type": "object",                                    "propertyNames": {                                      "type": "string"                                    },                                    "additionalProperties": {                                      "anyOf": [                                        {                                          "type": [                                            "string",                                            "number",                                            "null"                                          ]                                        },                                        {                                          "type": "array",                                          "items": {                                            "type": [                                              "string",                                              "number",                                              "null"                                            ]                                          }                                        }                                      ]                                    }                                  }                                },                                "required": [                                  "type",                                  "declarations"                                ],                                "additionalProperties": false                              },                              {                                "type": "object",                                "properties": {                                  "type": {                                    "type": "string",                                    "const": "property"                                  },                                  "property": {                                    "type": "string"                                  }                                },                                "required": [                                  "type",                                  "property"                                ],                                "additionalProperties": false                              },                              {                                "type": "object",                                "properties": {                                  "type": {                                    "type": "string",                                    "const": "static"                                  },                                  "rules": {                                    "type": "array",                                    "items": {                                      "type": "object",                                      "properties": {                                        "declarations": {                                          "type": "object",                                          "propertyNames": {                                            "type": "string"                                          },                                          "additionalProperties": {                                            "anyOf": [                                              {                                                "type": [                                                  "string",                                                  "number",                                                  "null"                                                ]                                              },                                              {                                                "type": "array",                                                "items": {                                                  "type": [                                                    "string",                                                    "number",                                                    "null"                                                  ]                                                }                                              }                                            ]                                          }                                        },                                        "selector": {                                          "type": "string"                                        },                                        "conditions": {                                          "type": "array",                                          "items": {                                            "type": "string"                                          }                                        }                                      },                                      "required": [                                        "declarations"                                      ],                                      "additionalProperties": false                                    }                                  }                                },                                "required": [                                  "type",                                  "rules"                                ],                                "additionalProperties": false                              }                            ]                          },                          "key": {                            "type": "string"                          },                          "keys": {                            "type": "array",                            "items": {                              "type": "string"                            }                          },                          "subkey": {                            "type": "string"                          },                          "name": {                            "type": "string"                          },                          "order": {                            "type": "number"                          },                          "layer": {                            "type": "string"                          },                          "namespaces": {                            "type": "array",                            "items": {                              "type": "string"                            }                          },                          "variableAliases": {                            "type": "array",                            "items": {                              "type": "array",                              "items": [                                {                                  "type": "string"                                },                                {                                  "type": "string"                                }                              ],                              "additionalItems": false,                              "minItems": 2,                              "maxItems": 2                            }                          },                          "variableAliasRefs": {                            "type": "array",                            "items": {                              "type": "string"                            }                          },                          "aliasGroups": {                            "type": "array",                            "items": {                              "type": "string"                            }                          },                          "conditions": {                            "type": "array",                            "items": {                              "type": "string"                            }                          },                          "matcherTypes": {                            "type": "array",                            "items": {                              "type": "string"                            }                          },                          "emitType": {                            "type": "string"                          }                        },                        "required": [                          "id",                          "type",                          "matchers",                          "emit",                          "matcherTypes",                          "emitType"                        ],                        "additionalProperties": {}                      }                    },                    "variants": {                      "type": "array",                      "items": {                        "type": "object",                        "properties": {                          "token": {                            "type": "string"                          },                          "branches": {                            "type": "number"                          },                          "layers": {                            "type": "array",                            "items": {                              "type": "string"                            }                          }                        },                        "required": [                          "token",                          "branches",                          "layers"                        ],                        "additionalProperties": false                      }                    },                    "modes": {                      "type": "array",                      "items": {                        "type": "object",                        "properties": {                          "name": {                            "type": "string"                          },                          "branches": {                            "type": "array",                            "items": {                              "type": "object",                              "properties": {                                "selector": {                                  "type": "string"                                },                                "conditions": {                                  "type": "array",                                  "items": {                                    "type": "string"                                  }                                }                              },                              "required": [                                "selector"                              ],                              "additionalProperties": false                            }                          }                        },                        "required": [                          "name",                          "branches"                        ],                        "additionalProperties": false                      }                    },                    "conditions": {                      "type": "array",                      "items": {                        "type": "object",                        "properties": {                          "name": {                            "type": "string"                          },                          "id": {                            "type": "string"                          },                          "nodes": {                            "type": "array",                            "items": {                              "$ref": "#/definitions/__schema0"                            }                          },                          "nodeCount": {                            "type": "number"                          }                        },                        "required": [                          "name",                          "id",                          "nodes",                          "nodeCount"                        ],                        "additionalProperties": false                      }                    },                    "aliases": {                      "type": "array",                      "items": {                        "oneOf": [                          {                            "type": "object",                            "properties": {                              "type": {                                "type": "string",                                "const": "variable-alias"                              },                              "utility": {                                "type": "string"                              },                              "key": {                                "type": "string"                              },                              "name": {                                "type": "string"                              }                            },                            "required": [                              "type",                              "utility",                              "key",                              "name"                            ],                            "additionalProperties": false                          },                          {                            "type": "object",                            "properties": {                              "type": {                                "type": "string",                                "const": "variable-alias-ref"                              },                              "utility": {                                "type": "string"                              },                              "ref": {                                "type": "string"                              }                            },                            "required": [                              "type",                              "utility",                              "ref"                            ],                            "additionalProperties": false                          },                          {                            "type": "object",                            "properties": {                              "type": {                                "type": "string",                                "const": "alias-group"                              },                              "utility": {                                "type": "string"                              },                              "group": {                                "type": "string"                              }                            },                            "required": [                              "type",                              "utility",                              "group"                            ],                            "additionalProperties": false                          }                        ]                      }                    }                  },                  "required": [                    "tokens",                    "utilities",                    "variants",                    "modes",                    "conditions",                    "aliases"                  ],                  "additionalProperties": false                },                "summary": {                  "type": "object",                  "propertyNames": {                    "type": "string"                  },                  "additionalProperties": {                    "$ref": "#/definitions/__schema1"                  }                }              },              "required": [                "manifest",                "results",                "summary"              ],              "additionalProperties": {}            }          },          "required": [            "status",            "data"          ],          "additionalProperties": false        },        {          "type": "object",          "properties": {            "status": {              "type": "string",              "const": "error"            },            "error": {              "type": "object",              "properties": {                "code": {                  "type": "string"                },                "message": {                  "type": "string"                }              },              "required": [                "code",                "message"              ],              "additionalProperties": false            }          },          "required": [            "status",            "error"          ],          "additionalProperties": false        }      ]    }  },  "required": [    "version",    "metadata",    "diagnostics",    "result"  ],  "additionalProperties": false,  "definitions": {    "__schema0": {      "anyOf": [        {          "type": "object",          "properties": {            "type": {              "type": "string",              "const": "boolean"            },            "name": {              "type": "string"            },            "raw": {              "type": "string"            }          },          "required": [            "type",            "name"          ],          "additionalProperties": false        },        {          "type": "object",          "properties": {            "type": {              "type": "string",              "const": "number"            },            "value": {              "type": "number"            },            "name": {              "type": "string"            },            "unit": {              "type": "string"            },            "operator": {              "type": "string"            },            "raw": {              "type": "string"            }          },          "required": [            "type",            "value"          ],          "additionalProperties": false        },        {          "type": "object",          "properties": {            "type": {              "type": "string",              "enum": [                "string",                "logical",                "comparison"              ]            },            "value": {              "type": "string"            },            "name": {              "type": "string"            },            "raw": {              "type": "string"            }          },          "required": [            "type",            "value"          ],          "additionalProperties": false        },        {          "type": "object",          "properties": {            "type": {              "type": "string",              "const": "group"            },            "children": {              "type": "array",              "items": {                "$ref": "#/definitions/__schema0"              }            },            "raw": {              "type": "string"            }          },          "required": [            "children"          ],          "additionalProperties": false        }      ]    },    "__schema1": {      "anyOf": [        {          "type": "string"        },        {          "type": "number"        },        {          "type": "boolean"        },        {          "type": "null"        },        {          "type": "array",          "items": {            "$ref": "#/definitions/__schema1"          }        },        {          "type": "object",          "propertyNames": {            "type": "string"          },          "additionalProperties": {            "$ref": "#/definitions/__schema1"          }        }      ]    }  }}

Project context and lifecycle

This operation does not write workspace files.

The local stdio server uses the workspace passed to --root. Confirm the root and intended CSS entries with mastercss_workspace_info before relying on project-dependent values.

See the MCP workflow guide for client setup and the preview/apply workflow.


© 2026 Aoyue Design LLC.MIT License
Trademark Policy