---
title: "Validate OpenAPI (POST)"
method: POST
path: "/v1/oas/validate"
tags: ["Tools"]
---

# Validate OpenAPI (POST)

`POST /v1/oas/validate`

Valideert een OpenAPI specificatie met de DON ADR ruleset. Standaard wordt ruleset 2.1 gebruikt; geef targetVersion "2.0" of "2.1" mee om een versie te kiezen. Body: { oasUrl } of { oasBody } (stringified JSON of YAML).

## Request body

- OasInput
  - `oasBody` string
  - `oasUrl` string
  - `targetVersion` string — Doelversie. Voor conversie: 3.0 of 3.1. Voor validatie: 2.0 of 2.1.

## Response `200`

OK

- ModelsLintResult
  - `apiId` string
  - `createdAt` string, date-time
  - `failures` integer
  - `id` string
  - `messages` ModelsLintMessage[]
    - `code` string
    - `createdAt` string, date-time
    - `id` string
    - `infos` ModelsLintMessageInfo[]
      - `id` string
      - `lintMessageId` string
      - `message` string
      - `path` string
    - `severity` string
  - `score` integer
  - `successes` boolean
  - `rulesetVersion` string — De gebruikte ruleset-versie voor validatie.

## Other responses

- `404` — Resource does not exist

---

[API](https://skmtc.dev/overheid/apis/tools-api-v1.md) · [All operations](https://skmtc.dev/overheid/apis/tools-api-v1/llms.txt) · [OpenAPI document](https://skmtc-service-production.skmtc.workers.dev/v1/apis/overheid/tools-api-v1/revisions/960229fe38bf/schema)
