If you have any kind of visa, TREC recommends that you contact your immigration authorities who helped you obtain legal status here. Verify with them that you are lawfully in the US. You also must have a Social Security Number in order to apply to become a real estate agent in Texas. Unfortunately, DACA recipients do not qualify to become real estate agents.
If you have a green card or a Permanent Resident card, you are considered a lawfully admitted alien, but feel free to confirm that with your immigration authorities.