How to get a domain variable value

so I have a question, which maybe it’s a little ez, but… I don’t know hehe, so, how do you get a value that’s in the domain? like:

https://example.com?test=helloworld

how do I get the value of the “test” variable that is there?