Latihan 1: API Documentation (OpenAPI) — API

Latihan 1 dari materi API Documentation (OpenAPI) di API — praktek dengan editor kode interaktif, test case otomatis, dan hint terpandu. Langsung jalan di browser.

Tulis OpenAPI spec (YAML) untuk endpoint GET /api/products yang menerima query parameter category (string, opsional) dan mengembalikan array of Product (id, name, price). Sertakan response 200 dan 500.

Hint