use url with parameter wa=...
example : ../read_messages_percontact.php?wa=6285692961782
cURL Error #:URL rejected: No host part in the URL