add get ip method