Describing an array of JSON objects #1612
-
|
Hello, I am not sure if I am doing something wrong or if this is a bug. I am trying to describe the payload of an MQTT topic, it should be an array of objects. Below is a stripped down version of my asyncapi document. The payload section and example payload do not render properly in https://studio.asyncapi.com/ or in the asyncapi-preview vscode extension. Am I doing something wrong?
|
Beta Was this translation helpful? Give feedback.
Replies: 2 comments 1 reply
-
|
Hey @jayzym , I found the issue 😀 . the issue lies here above ☝️ there is an extra nested instead it should be like this 👇 This is because you are writing the schema for the message. not the message itself. I hope i am able to explain it 😁 below 👇 is the final document after the correction |
Beta Was this translation helpful? Give feedback.
-
|
Thank you @catosaurusrex2003! I thought I was going crazy. |
Beta Was this translation helpful? Give feedback.

Hey @jayzym , I found the issue 😀 .
the issue lies here
above ☝️ there is an extra nested
payloadwhich is causing the problem.instead it should be like this 👇
This …