There are several ways, depends on what you need. For general interface info use on of these commands (output syntax is different):
Replace <IF_NAME> with the name of the required WAN interface:
To print only the required values, use the commands listed below:
WAN IP address:
WAN IP address/netmask:
Remember to replace <IF_NAME> with the actual interface name where required.
Hope this helps, good luck!