how to describe react native sockets in swagger API?

Viewed 48

for example i can show socket listener

there is no route, its just socket listener and how can i describe this socket event to show like this? -> 1

![sample swagger][]

# Get information about user 
Socket Event emit: 'getUserData’
Emit body: { email: String, token: String }
Socket Event listener: ‘getUserData’
Returned body:  { 
    userData: { picture: String,
          miniPicture: String,
          microPicture:String,
          username: String,
          email: String,
          location: String,
          description: String,
          interests: Array,  
          socialIntegrations: 
   [{type: String (Instagram/Twitter/LinkedIn), id: String, username: String, profileUrl:  String}],
     }, 
     eventsHosted: Array of event objects
}

0 Answers
Related