Trying to submit a form to create contact but response is 401


#1

Hi, I am trying to create new contact with hubspot API https://developers.hubspot.com/docs/methods/contacts/create_contact
I replaced API key with my API Key, trying with PHP but its return message

“curl Errors: Status code: 401 Response: {“status”:“error”,“message”:“This hapikey () doesn’t exist!”,“correlationId”:“e704d364-9318-46ab-8f43-b51dfa5ee42b”,“requestId”:“f9495d12-cc8e-4ae8-bfe7-7f8c65bfc540”}”


#2

PHP code provided by Hubspot API had an function “readline()” which was not working on my enviroment. now issue has been solved i’ve just place API key in single quotes instead in readline function.