Call these to validate input before you generate, so you never hard-code a value that changes. All take a bearer key.

Diagram types

GET /meta/diagram-types returns the valid diagram_type values.

Providers

GET /meta/providers returns the supported cloud_provider values, such as aws, azure, gcp, and general.

Formats

GET /meta/formats returns the valid export format values (see Export formats).

Features

GET /meta/features returns your plan and the features it includes. It needs the usage:read scope. Branch on features, not on plan: on Paid accounts this endpoint can still report an older internal plan id. Use GET /me for the public free or paid name. all_export_formats is the draw.io file. When it is missing, replies carry xml: null and export?format=drawio returns 403 (see Free plan replies).
Response (Free)
These change rarely. Fetch what you need at startup and cache it, refreshing occasionally.