After adding null check for schema object it got resolved and able to see the API details in swagger. It is a OOTB file needs to be modified.