How do I do something like this:
"groups":{
"href":"https://api.mydomain.com/account/abC132/groups",
"items":[
]
}
I have this:
groups:
type: array
properties:
href:
type: string
items:
type: object
name: division
properties:
href:
type: string
id:
type: string
But the swagger editor isn't recognizing the href under properties for the group.
I believe you're looking for something along the lines of this:
definitions:
groups:
title: groups
type: object
properties:
href:
type: string
items:
type: array
items:
$ref: '#/definitions/group'
group:
type: object
properties:
href:
type: string
id:
type: string
I had to do the following:
definitions:
groups:
title: groups
type: object
properties:
href:
type: string
items:
type: array
items:
$ref: '#/definitions/group'
group:
type: object
properties:
href:
type: string
id:
type: string
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With