What sites are using my GitHub hosted script?

Don't do it. Telemetry is tricky - and people will opt to not use your script.

Also without "place" to gather this information you cannot do it on github.

You can try leveraging "code" search engines like: https://publicwww.com/ https://www.nerdydata.com/

and similars


Without addressing the legal aspect, you could embed PAT (Personal Access Key) in your script, which would enable said script to make GitHub API calls.

Typically: "Create or update a file (PUT /repos/:owner/:repo/contents/:path)" (I mentioned it here)

You would replace the content of a file in a dedicated user/repository with the domain name you get from the script.
Each version of that file would represent one instance of the script execution, with the associated domain written in it.

The drawback is that anyone could use that key for accessing the repository, so you need to monitor its content and usage carefully (again, using a dedicated user account/repository just for that one usage).
As noted below by bk2204, this is too insecure.

Instead of a PAT, you can adopt a similar workflow as a GitHub webhook: your script would call a dedicate URL, with a JSON event, which would then register the call.