Como configurar uma integração via webhook e JSON Web Tokens (JWT)
Assista o video e saiba como criar e configurar uma integração via webhook:
Exemplos de post utilizados no video
Quando os campos são mapeados:
{
"method": "POST",
"path": "/",
"query": {},
"headers": {
"x-forwarded-for": "187.23.74.204",
"x-forwarded-proto": "https",
"x-forwarded-port": "443",
"host": "b49d7154afc0aa78bd28a33d58728909.m.pipedream.net",
"x-amzn-trace-id": "Root=1-5fa43252-5638cea6170999f2337bd3ed",
"content-length": "108",
"content-type": "application/json"
},
"bodyRaw": "{\"phone\":\"(41) 99999-9999\",\"name\":\"André\",\"email\":\"andre@neurologic.com.br\",\"url\":\"http://localhost:8000/\"}",
"body": {
"phone": "(41) 99999-9999",
"name": "André",
"email": "andre@neurologic.com.br",
"url": "http://localhost:8000/"
}
}
Quando os campos não são mapeados:
{
"method": "POST",
"path": "/",
"query": {},
"headers": {
"x-forwarded-for": "187.23.74.204",
"x-forwarded-proto": "https",
"x-forwarded-port": "443",
"host": "b49d7154afc0aa78bd28a33d58728909.m.pipedream.net",
"x-amzn-trace-id": "Root=1-5fa43252-119b26c84c692fff35eab1a3",
"content-length": "1085",
"content-type": "application/json"
},
"bodyRaw": "{\"lead\":{\"id\":\"7151042b-3ee3-9eac-19d3-fadcd342d13b\",\"data\":{\"url\":\"http://localhost:8000/\",\"nome\":\"André\",\"e_mail\":\"andre@neurologic.com.br\",\"telefone\":\"(41) 99999-9999\"},\"script\":{\"id\":8025,\"name\":\"Principal - editando\",\"default\":true,\"enabled\":true,\"ab_test_id\":null,\"company_id\":10,\"discarded_at\":null,\"script_rule_id\":7778,\"script_version_id\":59945,\"privacy_policy_url\":null},\"synced\":false,\"email_to\":\"felipe@test.com\",\"lead_data\":[{\"key\":\"1::Telefone\",\"step\":1,\"value\":\"(41) 99999-9999\",\"created_at\":\"2020-11-05T14:11:32.642-03:00\"},{\"key\":\"9999::URL\",\"step\":1,\"value\":\"http://localhost:8000/\",\"created_at\":\"2020-11-05T14:11:32.646-03:00\"},{\"key\":\"2::Nome\",\"step\":2,\"value\":\"André\",\"created_at\":\"2020-11-05T14:11:38.507-03:00\"},{\"key\":\"3::E-Mail\",\"step\":3,\"value\":\"andre@neurologic.com.br\",\"created_at\":\"2020-11-05T14:11:45.707-03:00\"}],\"script_id\":8025,\"created_at\":\"2020-11-05T14:11:32.636-03:00\",\"email_from\":\"leads@neurologic.com.br\",\"updated_at\":\"2020-11-05T14:11:45.723-03:00\",\"integrations\":{},\"email_subject\":\"Novo lead gerado [Neurologic]\",\"script_version_id\":59945}}",
"body": {
"lead": {
"id": "7151042b-3ee3-9eac-19d3-fadcd342d13b",
"data": {
"url": "http://localhost:8000/",
"nome": "André",
"e_mail": "andre@neurologic.com.br",
"telefone": "(41) 99999-9999"
},
"script": {
"id": 8025,
"name": "Principal - editando",
"default": true,
"enabled": true,
"ab_test_id": null,
"company_id": 10,
"discarded_at": null,
"script_rule_id": 7778,
"script_version_id": 59945,
"privacy_policy_url": null
},
"synced": false,
"email_to": "felipe@test.com",
"lead_data": [
{
"key": "1::Telefone",
"step": 1,
"value": "(41) 99999-9999",
"created_at": "2020-11-05T14:11:32.642-03:00"
},
{
"key": "9999::URL",
"step": 1,
"value": "http://localhost:8000/",
"created_at": "2020-11-05T14:11:32.646-03:00"
},
{
"key": "2::Nome",
"step": 2,
"value": "André",
"created_at": "2020-11-05T14:11:38.507-03:00"
},
{
"key": "3::E-Mail",
"step": 3,
"value": "andre@neurologic.com.br",
"created_at": "2020-11-05T14:11:45.707-03:00"
}
],
"script_id": 8025,
"created_at": "2020-11-05T14:11:32.636-03:00",
"email_from": "leads@neurologic.com.br",
"updated_at": "2020-11-05T14:11:45.723-03:00",
"integrations": {},
"email_subject": "Novo lead gerado [Neurologic]",
"script_version_id": 59945
}
}
}
Caso tenha dúvidas envie uma mensagem no chat dentro da plataforma.
Grande abraço!