Medical practices around the world have been trialling different substances such as psylocibyn and ketamine for depression and PTSD and have come out with positive results under safe and controlled settings. Does halocho allow one to find healing from all other psychoactive substances such as from plants like ayahausca, I.e. the insights in the trip are specifically to find healing and not for some spiritual enlightenment.
Not every substance under the sun is mentioned in our current shulchan aruch. So the general approach is:
Dina demalchuta dina hih: you must obey the law of the country you currently find yourself in.
Once legal, you must consider the proven health effects. Benefit vs. side effects (not according to tale but with proper studies). The Rambam is famously mentioned regarding our duty of caring for our bodies' health.
Finally one should consider one's behavior when taking said medicine. Some make lechaim (i.e. a toast, toasts) with alcoholic beverages and are able to channel it into positive deeds and constructive attitudes.
Once you have covered all three points, ask a competent Halachic authority for permission.
The drugs you have mentioned are known to cause psychosis, schizophrenia, and hallucinogen persisting perception disorder. Additionally they can cause serious mental health problems. These are not medications nor are they healing but recreational drugs with very serious risks for ones health. Additionally while someone is intoxicated they are unfit to fulfill the functions required of a Jewish person by Jewish law for a very long time. There is no justification that can be found in Jewish law for abusing such substances.