i stuck creating model key , array of values. unable expected result. guide me how achieve expected result
model.json
"models":{ "searchtask":{ "id":"searchtask", "properties":{ "taskstatuslist":{ "type": "array", "items": { "type": "string" } } } } }
output:
{ "taskstatuslist": ["string"] }
expected output:
{ "taskstatuslist": ["a","b"] }
for array inner type, can use example
construct give single example value:
{ "models": { "searchtask": { "id": "searchtask", "properties": { "taskstatuslist": { "type": "array", "items": { "type": "string", "example": "a" } } } } } }
you cannot have multiple examples current spec, can't [ "a", "b" ]
. if feel iportant , common use case, please add issue oai spec repository.
Comments
Post a Comment