IIRC the reason they don't (can't?) provide a search API directly is because they're pulling from other search sources, e.g. Bing, and can't provide an API without licence violations.
Agreed that a DDG API would be pretty great, though.
There are lots of options outside of the companies that make browsers and search input boxes on websites
SERP, EXA, Tavily... they are becoming a dime-a-dozen with the Ai hype b/c (1) making the process of fetch/scraping easier (2) being the primary end user of search API (3) making the creating of such an API easier
I haven't dug in enough to any of them to get a sense of result quality or consistency
Agreed that a DDG API would be pretty great, though.