Getting URL from REST

I have the following:

rest:
  - resource: https://www.xxxxxxxxxxxxxxxx.com
    sensor:
      - name: NameOfSensor
        value_template: '{{ code here  }}'

How do I get the “https://www.xxxxxxxxxxxxxxxx.com” into a sensor so that I can trim out the ip address? It’s to show the IP address in lovelace UI…