{
    "openapi": "3.1.0",
    "info": {
        "title": "DrohnenAtlas",
        "version": "0.0.1",
        "description": "DrohnenAtlas Partner Data API (`\/partner\/v1`) - commercial, licence-gated read access to airspace-rules, authority-contact, and flight-legality-verdict data for external B2B partners. Every zone-derived response carries the mandatory dipul attribution and a \"guidance, not legal advice\" disclaimer; the verdict endpoint is hard-gated behind a per-country commercial-reuse licence check that defaults to deny. Authenticate with `Authorization: Bearer {key_prefix}.{secret}` (see the security scheme below) - issued per partner client, scoped, rate-limited, and metered per plan."
    },
    "servers": [
        {
            "url": "https:\/\/app.drohnenatlas.app\/api\/partner\/v1"
        }
    ],
    "security": [
        {
            "http": []
        }
    ],
    "paths": {
        "\/authorities": {
            "get": {
                "operationId": "authorities.index",
                "tags": [
                    "Authorities"
                ],
                "responses": {
                    "200": {
                        "description": "`AuthorityResource`",
                        "content": {
                            "application\/json": {
                                "schema": {
                                    "type": "object",
                                    "properties": {
                                        "data": {
                                            "$ref": "#\/components\/schemas\/AuthorityResource"
                                        }
                                    },
                                    "required": [
                                        "data"
                                    ]
                                }
                            }
                        }
                    },
                    "404": {
                        "$ref": "#\/components\/responses\/NotFoundHttpException"
                    }
                }
            }
        },
        "\/coverage": {
            "get": {
                "operationId": "coverage.index",
                "tags": [
                    "Coverage"
                ],
                "responses": {
                    "200": {
                        "description": "",
                        "content": {
                            "application\/json": {
                                "schema": {
                                    "type": "object",
                                    "properties": {
                                        "data": {
                                            "type": "array",
                                            "items": {
                                                "type": "object",
                                                "properties": {
                                                    "country": {
                                                        "type": "string"
                                                    },
                                                    "coverage": {
                                                        "type": "string",
                                                        "enum": [
                                                            "full",
                                                            "none"
                                                        ]
                                                    },
                                                    "licence_status": {
                                                        "type": [
                                                            "string",
                                                            "null"
                                                        ]
                                                    },
                                                    "allowed": {
                                                        "type": "boolean"
                                                    },
                                                    "reason": {
                                                        "type": "string"
                                                    }
                                                },
                                                "required": [
                                                    "country",
                                                    "coverage",
                                                    "licence_status",
                                                    "allowed",
                                                    "reason"
                                                ]
                                            }
                                        },
                                        "meta": {
                                            "type": "object",
                                            "properties": {
                                                "queried_at": {
                                                    "type": "string"
                                                }
                                            },
                                            "required": [
                                                "queried_at"
                                            ]
                                        }
                                    },
                                    "required": [
                                        "data",
                                        "meta"
                                    ]
                                }
                            }
                        }
                    }
                }
            }
        },
        "\/meta\/health": {
            "get": {
                "operationId": "health.index",
                "tags": [
                    "Health"
                ],
                "responses": {
                    "200": {
                        "description": "",
                        "content": {
                            "application\/json": {
                                "schema": {
                                    "type": "object",
                                    "properties": {
                                        "status": {
                                            "type": "string",
                                            "const": "ok"
                                        },
                                        "version": {
                                            "type": "string",
                                            "const": "v1"
                                        },
                                        "queried_at": {
                                            "type": "string"
                                        }
                                    },
                                    "required": [
                                        "status",
                                        "version",
                                        "queried_at"
                                    ]
                                }
                            }
                        }
                    }
                }
            }
        },
        "\/rules": {
            "get": {
                "operationId": "rules.index",
                "tags": [
                    "Rules"
                ],
                "responses": {
                    "200": {
                        "description": "`RulesResource`",
                        "content": {
                            "application\/json": {
                                "schema": {
                                    "type": "object",
                                    "properties": {
                                        "data": {
                                            "$ref": "#\/components\/schemas\/RulesResource"
                                        }
                                    },
                                    "required": [
                                        "data"
                                    ]
                                }
                            }
                        }
                    },
                    "404": {
                        "$ref": "#\/components\/responses\/NotFoundHttpException"
                    }
                }
            }
        },
        "\/verdict": {
            "get": {
                "operationId": "verdict.index",
                "tags": [
                    "Verdict"
                ],
                "parameters": [
                    {
                        "name": "country",
                        "in": "query",
                        "required": true,
                        "schema": {
                            "type": "string",
                            "minLength": 2,
                            "maxLength": 2
                        }
                    },
                    {
                        "name": "lat",
                        "in": "query",
                        "schema": {
                            "type": [
                                "number",
                                "null"
                            ],
                            "minimum": -90,
                            "maximum": 90
                        }
                    },
                    {
                        "name": "lng",
                        "in": "query",
                        "schema": {
                            "type": [
                                "number",
                                "null"
                            ],
                            "minimum": -180,
                            "maximum": 180
                        }
                    },
                    {
                        "name": "drone_class",
                        "in": "query",
                        "schema": {
                            "type": [
                                "string",
                                "null"
                            ],
                            "enum": [
                                "C0",
                                "C1",
                                "C2",
                                "C3",
                                "C4",
                                "legacy",
                                "privately_built",
                                null
                            ]
                        }
                    },
                    {
                        "name": "scenario",
                        "in": "query",
                        "description": "Accepted per Docs\/revenue\/08-DATA-API-B2B.md's URL shape but\nnot used - FlightEligibilityService has no \"scenario\" concept.",
                        "schema": {
                            "type": [
                                "string",
                                "null"
                            ],
                            "maxLength": 100
                        }
                    }
                ],
                "responses": {
                    "200": {
                        "description": "",
                        "content": {
                            "application\/json": {
                                "schema": {
                                    "type": "object",
                                    "properties": {
                                        "data": {
                                            "anyOf": [
                                                {
                                                    "type": "object",
                                                    "properties": {
                                                        "coverage": {
                                                            "type": "string",
                                                            "const": "full"
                                                        },
                                                        "country": {
                                                            "type": "string"
                                                        },
                                                        "verdict": {
                                                            "type": "string"
                                                        },
                                                        "reasons": {
                                                            "type": "array",
                                                            "prefixItems": [
                                                                {
                                                                    "type": "string"
                                                                },
                                                                {
                                                                    "type": "string"
                                                                }
                                                            ],
                                                            "minItems": 2,
                                                            "maxItems": 2
                                                        },
                                                        "applicable_rules": {
                                                            "type": "string"
                                                        },
                                                        "required_actions": {
                                                            "type": "string"
                                                        },
                                                        "authority_to_contact": {
                                                            "type": [
                                                                "object",
                                                                "null"
                                                            ],
                                                            "properties": {
                                                                "name": {
                                                                    "type": "string"
                                                                },
                                                                "email": {
                                                                    "type": [
                                                                        "string",
                                                                        "null"
                                                                    ]
                                                                },
                                                                "phone": {
                                                                    "type": [
                                                                        "string",
                                                                        "null"
                                                                    ]
                                                                },
                                                                "website": {
                                                                    "type": [
                                                                        "string",
                                                                        "null"
                                                                    ]
                                                                }
                                                            },
                                                            "required": [
                                                                "name",
                                                                "email",
                                                                "phone",
                                                                "website"
                                                            ]
                                                        },
                                                        "source_attribution": {
                                                            "type": "string"
                                                        },
                                                        "disclaimer": {
                                                            "type": "string"
                                                        },
                                                        "queried_at": {
                                                            "type": "string"
                                                        }
                                                    },
                                                    "required": [
                                                        "coverage",
                                                        "country",
                                                        "verdict",
                                                        "reasons",
                                                        "applicable_rules",
                                                        "required_actions",
                                                        "authority_to_contact",
                                                        "source_attribution",
                                                        "disclaimer",
                                                        "queried_at"
                                                    ]
                                                },
                                                {
                                                    "type": "object",
                                                    "properties": {
                                                        "coverage": {
                                                            "type": "string",
                                                            "const": "none"
                                                        },
                                                        "country": {
                                                            "type": "string"
                                                        },
                                                        "reason": {
                                                            "type": "string",
                                                            "const": "no_zone_data_for_point"
                                                        },
                                                        "message": {
                                                            "type": "string",
                                                            "enum": [
                                                                "F\u00fcr diesen Punkt liegen derzeit keine Zonendaten vor (keine Koordinaten \u00fcbermittelt oder der Datenbestand des Landes ist nicht synchronisiert). Es ist kein Verdict verf\u00fcgbar - das bedeutet NICHT, dass der Flug erlaubt ist.",
                                                                "F\u00fcr dieses Land ist serverseitig keine Zonenaufl\u00f6sung eingerichtet. Es ist kein Verdict verf\u00fcgbar - das bedeutet NICHT, dass der Flug erlaubt ist.",
                                                                "F\u00fcr dieses Land liegt derzeit keine lizenzrechtlich freigegebene Zonenquelle vor. Es ist kein Verdict verf\u00fcgbar - das bedeutet NICHT, dass der Flug erlaubt ist."
                                                            ]
                                                        },
                                                        "rules_available_at": {
                                                            "type": "string",
                                                            "const": "\/partner\/v1\/rules"
                                                        },
                                                        "authority_to_contact": {
                                                            "type": [
                                                                "object",
                                                                "null"
                                                            ],
                                                            "properties": {
                                                                "name": {
                                                                    "type": "string"
                                                                },
                                                                "email": {
                                                                    "type": [
                                                                        "string",
                                                                        "null"
                                                                    ]
                                                                },
                                                                "phone": {
                                                                    "type": [
                                                                        "string",
                                                                        "null"
                                                                    ]
                                                                },
                                                                "website": {
                                                                    "type": [
                                                                        "string",
                                                                        "null"
                                                                    ]
                                                                }
                                                            },
                                                            "required": [
                                                                "name",
                                                                "email",
                                                                "phone",
                                                                "website"
                                                            ]
                                                        },
                                                        "disclaimer": {
                                                            "type": "string"
                                                        },
                                                        "queried_at": {
                                                            "type": "string"
                                                        }
                                                    },
                                                    "required": [
                                                        "coverage",
                                                        "country",
                                                        "reason",
                                                        "message",
                                                        "rules_available_at",
                                                        "authority_to_contact",
                                                        "disclaimer",
                                                        "queried_at"
                                                    ]
                                                },
                                                {
                                                    "type": "object",
                                                    "properties": {
                                                        "coverage": {
                                                            "type": "string",
                                                            "const": "none"
                                                        },
                                                        "country": {
                                                            "type": "string"
                                                        },
                                                        "reason": {
                                                            "type": "string",
                                                            "const": "no_zone_engine_for_country"
                                                        },
                                                        "message": {
                                                            "type": "string",
                                                            "enum": [
                                                                "F\u00fcr diesen Punkt liegen derzeit keine Zonendaten vor (keine Koordinaten \u00fcbermittelt oder der Datenbestand des Landes ist nicht synchronisiert). Es ist kein Verdict verf\u00fcgbar - das bedeutet NICHT, dass der Flug erlaubt ist.",
                                                                "F\u00fcr dieses Land ist serverseitig keine Zonenaufl\u00f6sung eingerichtet. Es ist kein Verdict verf\u00fcgbar - das bedeutet NICHT, dass der Flug erlaubt ist.",
                                                                "F\u00fcr dieses Land liegt derzeit keine lizenzrechtlich freigegebene Zonenquelle vor. Es ist kein Verdict verf\u00fcgbar - das bedeutet NICHT, dass der Flug erlaubt ist."
                                                            ]
                                                        },
                                                        "rules_available_at": {
                                                            "type": "string",
                                                            "const": "\/partner\/v1\/rules"
                                                        },
                                                        "authority_to_contact": {
                                                            "type": [
                                                                "object",
                                                                "null"
                                                            ],
                                                            "properties": {
                                                                "name": {
                                                                    "type": "string"
                                                                },
                                                                "email": {
                                                                    "type": [
                                                                        "string",
                                                                        "null"
                                                                    ]
                                                                },
                                                                "phone": {
                                                                    "type": [
                                                                        "string",
                                                                        "null"
                                                                    ]
                                                                },
                                                                "website": {
                                                                    "type": [
                                                                        "string",
                                                                        "null"
                                                                    ]
                                                                }
                                                            },
                                                            "required": [
                                                                "name",
                                                                "email",
                                                                "phone",
                                                                "website"
                                                            ]
                                                        },
                                                        "disclaimer": {
                                                            "type": "string"
                                                        },
                                                        "queried_at": {
                                                            "type": "string"
                                                        }
                                                    },
                                                    "required": [
                                                        "coverage",
                                                        "country",
                                                        "reason",
                                                        "message",
                                                        "rules_available_at",
                                                        "authority_to_contact",
                                                        "disclaimer",
                                                        "queried_at"
                                                    ]
                                                },
                                                {
                                                    "type": "object",
                                                    "properties": {
                                                        "coverage": {
                                                            "type": "string",
                                                            "const": "none"
                                                        },
                                                        "country": {
                                                            "type": "string"
                                                        },
                                                        "reason": {
                                                            "type": "string"
                                                        },
                                                        "message": {
                                                            "type": "string",
                                                            "enum": [
                                                                "F\u00fcr diesen Punkt liegen derzeit keine Zonendaten vor (keine Koordinaten \u00fcbermittelt oder der Datenbestand des Landes ist nicht synchronisiert). Es ist kein Verdict verf\u00fcgbar - das bedeutet NICHT, dass der Flug erlaubt ist.",
                                                                "F\u00fcr dieses Land ist serverseitig keine Zonenaufl\u00f6sung eingerichtet. Es ist kein Verdict verf\u00fcgbar - das bedeutet NICHT, dass der Flug erlaubt ist.",
                                                                "F\u00fcr dieses Land liegt derzeit keine lizenzrechtlich freigegebene Zonenquelle vor. Es ist kein Verdict verf\u00fcgbar - das bedeutet NICHT, dass der Flug erlaubt ist."
                                                            ]
                                                        },
                                                        "rules_available_at": {
                                                            "type": "string",
                                                            "const": "\/partner\/v1\/rules"
                                                        },
                                                        "authority_to_contact": {
                                                            "type": [
                                                                "object",
                                                                "null"
                                                            ],
                                                            "properties": {
                                                                "name": {
                                                                    "type": "string"
                                                                },
                                                                "email": {
                                                                    "type": [
                                                                        "string",
                                                                        "null"
                                                                    ]
                                                                },
                                                                "phone": {
                                                                    "type": [
                                                                        "string",
                                                                        "null"
                                                                    ]
                                                                },
                                                                "website": {
                                                                    "type": [
                                                                        "string",
                                                                        "null"
                                                                    ]
                                                                }
                                                            },
                                                            "required": [
                                                                "name",
                                                                "email",
                                                                "phone",
                                                                "website"
                                                            ]
                                                        },
                                                        "disclaimer": {
                                                            "type": "string"
                                                        },
                                                        "queried_at": {
                                                            "type": "string"
                                                        }
                                                    },
                                                    "required": [
                                                        "coverage",
                                                        "country",
                                                        "reason",
                                                        "message",
                                                        "rules_available_at",
                                                        "authority_to_contact",
                                                        "disclaimer",
                                                        "queried_at"
                                                    ]
                                                }
                                            ]
                                        }
                                    },
                                    "required": [
                                        "data"
                                    ]
                                }
                            }
                        }
                    },
                    "422": {
                        "$ref": "#\/components\/responses\/ValidationException"
                    }
                }
            }
        }
    },
    "components": {
        "securitySchemes": {
            "http": {
                "type": "http",
                "description": "Partner API key, format `{key_prefix}.{secret}` (see PartnerApiKeyAuth).",
                "scheme": "bearer"
            }
        },
        "schemas": {
            "AuthorityResource": {
                "type": "object",
                "properties": {
                    "name": {
                        "type": "string"
                    },
                    "authority_type": {
                        "type": "string"
                    },
                    "authority_type_label": {
                        "type": "string",
                        "enum": [
                            "Polizei",
                            "Ordnungsamt",
                            "Landesluftfahrtbeh\u00f6rde",
                            "Naturschutzbeh\u00f6rde",
                            "BAF (ED-R)",
                            "Grundst\u00fcckseigent\u00fcmer",
                            "Sonstige"
                        ]
                    },
                    "level": {
                        "type": "string",
                        "enum": [
                            "Bund",
                            "Land",
                            "Kommune",
                            "Sonstige"
                        ]
                    },
                    "jurisdiction": {
                        "type": "object",
                        "properties": {
                            "bundesland": {
                                "type": [
                                    "string",
                                    "null"
                                ]
                            },
                            "landkreis": {
                                "type": [
                                    "string",
                                    "null"
                                ]
                            },
                            "jurisdiction_key": {
                                "type": [
                                    "string",
                                    "null"
                                ]
                            },
                            "ags_land": {
                                "type": [
                                    "string",
                                    "null"
                                ]
                            }
                        },
                        "required": [
                            "bundesland",
                            "landkreis",
                            "jurisdiction_key",
                            "ags_land"
                        ]
                    },
                    "phone": {
                        "type": [
                            "string",
                            "null"
                        ]
                    },
                    "emails": {
                        "type": "array",
                        "items": {}
                    },
                    "website": {
                        "type": [
                            "string",
                            "null"
                        ]
                    },
                    "provenance": {
                        "type": [
                            "array",
                            "null"
                        ],
                        "items": {}
                    },
                    "last_verified": {
                        "type": [
                            "string",
                            "null"
                        ]
                    }
                },
                "required": [
                    "name",
                    "authority_type",
                    "authority_type_label",
                    "level",
                    "jurisdiction",
                    "phone",
                    "emails",
                    "website",
                    "provenance",
                    "last_verified"
                ],
                "title": "AuthorityResource"
            },
            "RulesResource": {
                "type": "object",
                "properties": {
                    "country_code": {
                        "type": "string"
                    },
                    "locale": {
                        "type": "string"
                    },
                    "version": {
                        "type": "string"
                    },
                    "last_reviewed": {
                        "type": [
                            "string",
                            "null"
                        ]
                    },
                    "payload": {
                        "type": "array",
                        "items": {}
                    },
                    "disclaimer": {
                        "type": "string",
                        "description": "The not-legal-advice disclaimer (Docs\/revenue\/08-DATA-API-B2B.md\n\u00a79.3) is our own authored meta.disclaimer field, not a\npartner-surface addition - single source of truth with the\napp's \/v1\/regulations payload."
                    }
                },
                "required": [
                    "country_code",
                    "locale",
                    "version",
                    "last_reviewed",
                    "payload",
                    "disclaimer"
                ],
                "title": "RulesResource"
            }
        },
        "responses": {
            "NotFoundHttpException": {
                "description": "Not found",
                "content": {
                    "application\/json": {
                        "schema": {
                            "type": "object",
                            "properties": {
                                "message": {
                                    "type": "string",
                                    "description": "Error overview."
                                }
                            },
                            "required": [
                                "message"
                            ]
                        }
                    }
                }
            },
            "ValidationException": {
                "description": "Validation error",
                "content": {
                    "application\/json": {
                        "schema": {
                            "type": "object",
                            "properties": {
                                "message": {
                                    "type": "string",
                                    "description": "Errors overview."
                                },
                                "errors": {
                                    "type": "object",
                                    "description": "A detailed description of each field that failed validation.",
                                    "additionalProperties": {
                                        "type": "array",
                                        "items": {
                                            "type": "string"
                                        }
                                    }
                                }
                            },
                            "required": [
                                "message",
                                "errors"
                            ]
                        }
                    }
                }
            }
        }
    }
}