---
title: "Validate Team Command"
method: POST
path: "/api/mesh/policies/{team_key}/validate"
tags: ["mesh"]
---

# Validate Team Command

`POST /api/mesh/policies/{team_key}/validate`

## Request

- Base URL: `https://api.superit.ai` (the document declares no server; this is the origin it was published from)
- URL: `https://api.superit.ai/api/mesh/policies/{team_key}/validate`
- Auth: HTTP bearer

## Path parameters

- `team_key` string, required

## Request body

- PolicyValidateBody: Request body for dry-running a script against team policies.
  - `command` string, required
  - `operatingSystem` 'windows' | 'linux' | 'darwin', required

## Response `200`

Successful Response

- PolicyValidateResponse: Result of a dry-run validation.
  - `status` 'approved' | 'denied' | 'pending', required
  - `reason` string, required
  - `astBlocked` boolean
  - `matchedStep` integer, nullable
  - `parsedCmdlets` string[], nullable
  - `astBlocks` AstBlock[], nullable
    - `type` string, required
    - `text` string, required
  - `evaluationOrder` EvaluationStep[]
    - `step` integer, required
    - `kind` 'cmdlet' | 'pattern' | 'parameter_override' | 'default', required
    - `decision` 'allow' | 'deny' | 'needs_approval', required
    - `source` 'ast' | 'system_blocklist' | 'cmdlet_policy_team' | 'cmdlet_policy_global' | 'pattern_rule_team' | 'pattern_rule_global' | 'parameter_override' | 'default', required
    - `matched` boolean
    - `isSystemLocked` boolean
    - `cmdletName` string, nullable
    - `pattern` string, nullable
    - `priority` integer, nullable
    - `ruleId` integer, nullable
    - `reason` string, nullable

## Other responses

- `400`: Invalid input
- `401`: Not authenticated
- `403`: Forbidden
- `404`: Not found
- `405`: Method not allowed
- `409`: Conflict
- `422`: Validation Error

---

[API](https://skmtc.dev/superit/apis/super-it-api.md) - [All operations](https://skmtc.dev/superit/apis/super-it-api/llms.txt) - [OpenAPI document](https://skmtc.dev/superit/apis/super-it-api/revisions/4944d556c2bb?raw)
