Contributions
Re: Example Model
Hi Helen, Thank you for your response. I tried this: paths: /Customers/GetAllCustomersAU: get: tags: - "Customer" summary: Retrieve all customers description: | Retrieve all customers from a specific laboratory. responses: '200': description: Retrieves all customers content: application/json: schema: items: $ref: "#/definitions/data" definitions: data: type: object properties: data: type: array items: type: object properties: id: type: integer customername: type: string example: - id: 1930 customername: Customer 1 - id: 1900 customername: Customer 2 The result is: [ { "data": [ { "id": 1930, "customername": "Customer 1" }, { "id": 1900, "customername": "Customer 2" } ] } ] How to remove the first set of square brackets? So that it will appear only as: { "data": [ { "id": 1930, "customername": "Customer 1" }, { "id": 1900, "customername": "Customer 2" } ] } Many thanks1.4KViews0likes1CommentExample Model
Hi, my current model example looks like this: [ { "id": 1930, "customername": "Customer 1" }, { "id": 1900, "customername": "Customer 2" } ] how to display it like this: { "data": [ { "id": 1930, "customername": "Customer 1" }, { "id": 1900, "customername": "Customer 2" } ] } Many thanks,1.5KViews0likes3Comments