Stoplight
11 months agoCommunity Manager
Question about roles
Originally posted by user Rajtechwriter to the Stoplight Community on 07/06/2023 at 01:32 ET.
Hi, we are on the starter pack and I had the following questions:
How many members can be added to ...
- 4 years ago
Hi raghug,
This payload is an array of objects. It can be defined as follows (assuming you're using OpenAPI 3.0)
openapi: 3.0.0 ... paths: /anything: post: requestBody: content: application/json: schema: type: array # <---------- items: $ref: '#/components/schemas/Field' example: # <--- Optional array-level example - fieldName: field1 fieldType: string fieldValue: '12345677' - fieldName: field2 fieldType: string fieldValue: '12345677' responses: '200': description: OK components: schemas: Field: # <----- Objects inside the array type: object properties: fieldName: type: string example: field1 fieldType: type: string example: string fieldValue: type: string example: '12345677'