This short example shows how you can easing send different types of data from Arduino to NodeMCU via a json object. SoftwareSerial and ArduinoJson5 was used in the example. ArduinoJson6 does not have the same syntax and if used it will throw an error. If you want to upgrade to ArduinoJson6 check out this documentation Migrate from v5 to v6.
MY-Sabil/Send-Data-From-Arduino-To-NodeMCU
A short example on how to send data from Arduino to NodeMCU
C++