Create contacts response is NOT hubspot's documentation json response

Colaborador Ocasional



When I create a new contact I do not get the json response shared in documentation. I get the below response. I need to get the documentation response that contains the newly created contact's id.

Please advise



Hubspot response: {
statusCode: 201,
headers: {
date: 'Tue, 07 Jul 2020 22:09:17 GMT',
'content-type': 'application/json;charset=utf-8',
'transfer-encoding': 'chunked',
connection: 'close',
'set-cookie': [
'__cfduid=df5e4cc71b1b689d3479d235b7e74f3e91594159757; expires=Thu, 06-Aug-20 22:09:17 GMT; path=/;; HttpOnly; SameSite=Lax'
'x-trace': '2B0CC11537DE88598EC6BB6CC4590FC32119700770000000000000000000',
'x-hubspot-ratelimit-daily': '500000',
'x-hubspot-ratelimit-daily-remaining': '499984',
'x-hubspot-ratelimit-interval-milliseconds': '10000',
'x-hubspot-ratelimit-remaining': '99',
'x-hubspot-ratelimit-max': '100',
'x-hubspot-ratelimit-secondly': '10',
'x-hubspot-ratelimit-secondly-remaining': '9',
location: '',
vary: 'Accept-Encoding',
'access-control-allow-credentials': 'false',
'cf-cache-status': 'DYNAMIC',
'cf-request-id': '03ccec90910000e372b389c200000001',
'expect-ct': 'max-age=604800, report-uri=""',
'strict-transport-security': 'max-age=31536000; includeSubDomains; preload',
server: 'cloudflare',
'cf-ray': '5af4e3941eb1e372-SEA'



0 Avaliação positiva
2 Respostas 2
Moderador da HubSpot

Hey @jandrews ,


When I test that endpoint on my end, I'm getting the correct response body. At a glance, it doesn't look like what you've included here is in a format I'm familiar with. Is it possible that you're logging the response information in such a way that it's not printing the response body?

0 Avaliação positiva
Colaborador Ocasional

Thanks for looking into it. I figured it out. Hubspot returned the body as some weird Buffer type thing

0 Avaliação positiva