Enhance JSON handling in concepts API and update tests
Merged
AL
13d ago+177+177+012345678901234567890123456789-12-12-01234567890123456789
- Updated the
concept_ids,relationship_types,vocabulary_ids, anddomain_idsin the API to preserve JSON array structure by using unname and as.list. - Modified tests to reflect these changes, ensuring that the body of requests maintains the correct format for concept recommendations.
- Added
httpuvas a suggested dependency in DESCRIPTION. - Documented improvements in NEWS.md regarding JSON array preservation for various filters.
Summary by cubic
Fixes JSON encoding in concepts$batch and concepts$recommended so filter parameters preserve JSON array structure, including single values and named input vectors. Previously httr2 auto-unboxed single-element and named vectors into JSON scalars and objects, breaking the expected request format.
- Adds
httpuvas a suggested dependency to inspect the real JSON wire format viareq_dry_run. - Validates batch
vocabulary_filterentries are non-missing strings before sending. - Adds tests covering single values, multiple values, named inputs, and omitted filters for both endpoints; existing request-body assertions now expect lists.
- Documents the JSON array fixes in
NEWS.md.