Unless you are a member of a union where you may have more protective procedural rights, your employer can terminate you under these circumstances, and it is not required to allow you to see the results of explain the basis for the termination.
The only real way to attack a drug test of this sort is to prove that it was not a truly random test, but instead that you were improperly targeted for the testing, rendering the test a violation of your right to medical privacy. However there are even exceptions to that rule, where it is a post accident test, or where the employer has an objective reasonable suspicion of drug use.
If you could prove the test was an invasion of medical privacy, you might be able to allege that some of the damages from that invasion would be the financial losses you will not incur as a result of the loss of your job.
Absent an invasion of privacy claim I am sorry to say you have no other options.
You have no right to a termination letter or even an explanation, nor are you entitled to suspension as a warning prior to termination.
Good luck to you.
This answer should not be construed to create any attorney-client relationship. Such a relationship can be formed only through the mutual execution of an attorney-client agreement. The answer given is based on the extremely limited facts provided and the proper course of action might change significantly with the introduction of other facts. All who read this answer should not rely on the answer to govern their conduct. Please seek the advice of competent counsel after disclosing all facts to that attorney. This answer is intended for California residents only. The answering party is only licensed to practice in the State of California.
In addition to what has been said you should review the companies employment policies to fully know what your rights are. In addition, you should follow up with a letter explaining what OTC drugs you take and ask for a copy of the test results, in writing, along with your employment file.
This is my opinion and should not be construed as legal advise for your specific case as there are many more facts which you have not provided.