/user_agents: get: tags: - user_agents summary: List parameters: ..removed for readability.. responses: '200': description: An array of user_agents schema: type: array items: type: object properties: user_agent_id: type: integer x-dbtype: int x-nullable: false x-primary-key: true user_agent_string: type: string x-dbtype: varchar x-nullable: true maxLength: 255{ "user_agents": [ { "user_agent_id": 1, "user_agent_string": "Mozilla/5.0 (X11; Linux x86_64) AppleWebKit/537.36 (KHTML, like Gecko) Ubuntu Chromium/37.0.2062.94 Chrome/37.0.2062.94 Safari/537.36", "user_agent_use_count": 1 }, { "user_agent_id": 2, "user_agent_string": "Mozilla/5.0 (X11; Linux x86_64) AppleWebKit/537.36 (KHTML, like Gecko) Ubuntu Chromium/37.0.2062.94 Chrome/37.0.2062.94 Safari/537.36", "user_agent_use_count": 1 }, { "user_agent_id": 3, "user_agent_string": "Mozilla/5.0 (X11; Linux x86_64) AppleWebKit/537.36 (KHTML, like Gecko) Ubuntu Chromium/37.0.2062.94 Chrome/37.0.2062.94 Safari/537.36", "user_agent_use_count": 2 } ]}[ { "user_agent_id": 0, "user_agent_string": "string" }]You’re only describing the inner array. You need to describe the encompassing object, the one containing the “user_agents” property.
--
You received this message because you are subscribed to the Google Groups "Swagger" group.
To unsubscribe from this group and stop receiving emails from it, send an email to swagger-swaggers...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.
To unsubscribe from this group and stop receiving emails from it, send an email to swagger-swaggersocket+unsub...@googlegroups.com.
Replace your schema with:
schema:
type: object
properties:
user_agents:
type: array
items:
type: object
properties:
user_agent_id:
type: integer
x-dbtype: int
x-nullable: false
x-primary-key: true
user_agent_string:
type: string
x-dbtype: varchar
x-nullable: true
maxLength: 255
{ "user_agents": [ { "user_agent_id": 1, "string": "asdasdad" } ]}{ "user_agents": [ { "user_agent_id": 0, "user_agent_string": "string" } ]}The UI generates a sample response, it doesn’t show you the actual response unless you execute the call.
From: <swagger-sw...@googlegroups.com> on behalf of xhorntail <xhor...@gmail.com>
Reply-To: "swagger-sw...@googlegroups.com" <swagger-sw...@googlegroups.com>
Date: Thursday, October 5, 2017 at 16:00
To: Swagger <swagger-sw...@googlegroups.com>
Subject: Re: I can't seem to get the model to structure the output properly..
Seems like it should be working, perhaps I'm daft, but the model still isn't populating.
server response:
--
You received this message because you are subscribed to the Google Groups "Swagger" group.
To unsubscribe from this group and stop receiving emails from it, send an email to swagger-swaggers...@googlegroups.com.
To unsubscribe from this group and stop receiving emails from it, send an email to swagger-swaggersocket+unsub...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.
--
You received this message because you are subscribed to a topic in the Google Groups "Swagger" group.
To unsubscribe from this topic, visit https://groups.google.com/d/topic/swagger-swaggersocket/jGJLLUJ9czA/unsubscribe.
To unsubscribe from this group and all its topics, send an email to swagger-swaggersocket+unsub...@googlegroups.com.
Then I don’t understand the issue.
From: <swagger-sw...@googlegroups.com> on behalf of Landon Snell <xhor...@gmail.com>
Reply-To: "swagger-sw...@googlegroups.com" <swagger-sw...@googlegroups.com>
Date: Thursday, October 5, 2017 at 16:43
To: "swagger-sw...@googlegroups.com" <swagger-sw...@googlegroups.com>
Subject: Re: I can't seem to get the model to structure the output properly..
I have clicked the button if that's what you mean
On Oct 5, 2017 5:40 PM, "Ron Ratovsky" <r...@swagger.io> wrote:
The UI generates a sample response, it doesn’t show you the actual response unless you execute the call.
From: <swagger-sw...@googlegroups.com> on behalf of xhorntail <xhor...@gmail.com>
Reply-To: "swagger-sw...@googlegroups.com" <swagger-sw...@googlegroups.com>
Date: Thursday, October 5, 2017 at 16:00
To: Swagger <swagger-sw...@googlegroups.com>
Subject: Re: I can't seem to get the model to structure the output properly..
Seems like it should be working, perhaps I'm daft, but the model still isn't populating.
server response:{
"user_agents": [
{
"user_agent_id": 1,
"string": "asdasdad"
}
]
}
Responses:{
"user_agents": [
{
"user_agent_id": 0,
"user_agent_string": "string"
}
]
}
--
You received this message because you are subscribed to the Google Groups "Swagger" group.
To unsubscribe from this group and stop receiving emails from it, send an email to swagger-swaggers...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.
--
You received this message because you are subscribed to a topic in the Google Groups "Swagger" group.
To unsubscribe from this topic, visit https://groups.google.com/d/topic/swagger-swaggersocket/jGJLLUJ9czA/unsubscribe.
To unsubscribe from this group and all its topics, send an email to swagger-swaggers...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.
--
You received this message because you are subscribed to the Google Groups "Swagger" group.
To unsubscribe from this group and stop receiving emails from it, send an email to swagger-swaggers...@googlegroups.com.