Atualizar contato
curl --request PUT \
--url https://api.notifique.dev/v1/contacts/{id} \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"phone": "string",
"email": "string",
"name": "Exemplo",
"telegramLinks": [
{
"instanceId": "clxx...",
"peer": "string"
}
],
"languages": [
"string"
],
"url": "https://example.com/resource",
"tagIds": [
"clxx..."
],
"receiveMarketing": true
}
'const options = {
method: 'PUT',
headers: {Authorization: 'Bearer <token>', 'Content-Type': 'application/json'},
body: JSON.stringify({
phone: 'string',
email: 'string',
name: 'Exemplo',
telegramLinks: [{instanceId: 'clxx...', peer: 'string'}],
languages: ['string'],
url: 'https://example.com/resource',
tagIds: ['clxx...'],
receiveMarketing: true
})
};
fetch('https://api.notifique.dev/v1/contacts/{id}', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));import requests
url = "https://api.notifique.dev/v1/contacts/{id}"
payload = {
"phone": "string",
"email": "string",
"name": "Exemplo",
"telegramLinks": [
{
"instanceId": "clxx...",
"peer": "string"
}
],
"languages": ["string"],
"url": "https://example.com/resource",
"tagIds": ["clxx..."],
"receiveMarketing": True
}
headers = {
"Authorization": "Bearer <token>",
"Content-Type": "application/json"
}
response = requests.put(url, json=payload, headers=headers)
print(response.text)package main
import (
"fmt"
"strings"
"net/http"
"io"
)
func main() {
url := "https://api.notifique.dev/v1/contacts/{id}"
payload := strings.NewReader("{\n \"phone\": \"string\",\n \"email\": \"string\",\n \"name\": \"Exemplo\",\n \"telegramLinks\": [\n {\n \"instanceId\": \"clxx...\",\n \"peer\": \"string\"\n }\n ],\n \"languages\": [\n \"string\"\n ],\n \"url\": \"https://example.com/resource\",\n \"tagIds\": [\n \"clxx...\"\n ],\n \"receiveMarketing\": true\n}")
req, _ := http.NewRequest("PUT", url, payload)
req.Header.Add("Authorization", "Bearer <token>")
req.Header.Add("Content-Type", "application/json")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}{
"success": true,
"data": {
"id": "clxx...",
"name": "Exemplo",
"phone": "string",
"email": "string",
"languages": [
"string"
],
"receiveMarketing": true,
"telegramLinks": [
{
"instanceId": "clxx...",
"peer": "string",
"instanceName": "string"
}
],
"url": "https://example.com/resource",
"createdAt": "2025-02-10T14:00:00.000Z",
"updatedAt": "2025-02-10T14:00:00.000Z",
"tags": [
{
"id": "clxx...",
"name": "Exemplo"
}
]
}
}{
"success": false,
"error": "Bad Request",
"code": "VALIDATION_ERROR",
"message": "Campo inválido ou ausente."
}{
"success": false,
"error": "Bad Request",
"code": "VALIDATION_ERROR",
"message": "Campo inválido ou ausente."
}{
"success": false,
"error": "Bad Request",
"code": "VALIDATION_ERROR",
"message": "Campo inválido ou ausente."
}{
"success": false,
"error": "Bad Request",
"code": "VALIDATION_ERROR",
"message": "Campo inválido ou ausente."
}{
"success": false,
"error": "Bad Request",
"code": "VALIDATION_ERROR",
"message": "Campo inválido ou ausente."
}{
"success": false,
"error": "Bad Request",
"code": "VALIDATION_ERROR",
"message": "Campo inválido ou ausente."
}Contatos
Atualizar contato
Altera dados de um contato.
PUT
/
v1
/
contacts
/
{id}
Atualizar contato
curl --request PUT \
--url https://api.notifique.dev/v1/contacts/{id} \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"phone": "string",
"email": "string",
"name": "Exemplo",
"telegramLinks": [
{
"instanceId": "clxx...",
"peer": "string"
}
],
"languages": [
"string"
],
"url": "https://example.com/resource",
"tagIds": [
"clxx..."
],
"receiveMarketing": true
}
'const options = {
method: 'PUT',
headers: {Authorization: 'Bearer <token>', 'Content-Type': 'application/json'},
body: JSON.stringify({
phone: 'string',
email: 'string',
name: 'Exemplo',
telegramLinks: [{instanceId: 'clxx...', peer: 'string'}],
languages: ['string'],
url: 'https://example.com/resource',
tagIds: ['clxx...'],
receiveMarketing: true
})
};
fetch('https://api.notifique.dev/v1/contacts/{id}', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));import requests
url = "https://api.notifique.dev/v1/contacts/{id}"
payload = {
"phone": "string",
"email": "string",
"name": "Exemplo",
"telegramLinks": [
{
"instanceId": "clxx...",
"peer": "string"
}
],
"languages": ["string"],
"url": "https://example.com/resource",
"tagIds": ["clxx..."],
"receiveMarketing": True
}
headers = {
"Authorization": "Bearer <token>",
"Content-Type": "application/json"
}
response = requests.put(url, json=payload, headers=headers)
print(response.text)package main
import (
"fmt"
"strings"
"net/http"
"io"
)
func main() {
url := "https://api.notifique.dev/v1/contacts/{id}"
payload := strings.NewReader("{\n \"phone\": \"string\",\n \"email\": \"string\",\n \"name\": \"Exemplo\",\n \"telegramLinks\": [\n {\n \"instanceId\": \"clxx...\",\n \"peer\": \"string\"\n }\n ],\n \"languages\": [\n \"string\"\n ],\n \"url\": \"https://example.com/resource\",\n \"tagIds\": [\n \"clxx...\"\n ],\n \"receiveMarketing\": true\n}")
req, _ := http.NewRequest("PUT", url, payload)
req.Header.Add("Authorization", "Bearer <token>")
req.Header.Add("Content-Type", "application/json")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}{
"success": true,
"data": {
"id": "clxx...",
"name": "Exemplo",
"phone": "string",
"email": "string",
"languages": [
"string"
],
"receiveMarketing": true,
"telegramLinks": [
{
"instanceId": "clxx...",
"peer": "string",
"instanceName": "string"
}
],
"url": "https://example.com/resource",
"createdAt": "2025-02-10T14:00:00.000Z",
"updatedAt": "2025-02-10T14:00:00.000Z",
"tags": [
{
"id": "clxx...",
"name": "Exemplo"
}
]
}
}{
"success": false,
"error": "Bad Request",
"code": "VALIDATION_ERROR",
"message": "Campo inválido ou ausente."
}{
"success": false,
"error": "Bad Request",
"code": "VALIDATION_ERROR",
"message": "Campo inválido ou ausente."
}{
"success": false,
"error": "Bad Request",
"code": "VALIDATION_ERROR",
"message": "Campo inválido ou ausente."
}{
"success": false,
"error": "Bad Request",
"code": "VALIDATION_ERROR",
"message": "Campo inválido ou ausente."
}{
"success": false,
"error": "Bad Request",
"code": "VALIDATION_ERROR",
"message": "Campo inválido ou ausente."
}{
"success": false,
"error": "Bad Request",
"code": "VALIDATION_ERROR",
"message": "Campo inválido ou ausente."
}Autorizações
ntfContactBearerAuthntfContactApiKeyHeader
Authorization: Bearer sk_live_xxxxx
Parâmetros de caminho
Corpo
application/json
Todos os campos opcionais; tagIds substitui a lista de tags. telegramLinks (incl. array vazio) substitui todas as ligações.
Resposta
Contato atualizado.
Exemplo:
true
Contato do workspace (phone e/ou email; tags). telegramLinks por instância Telegram;
Show child attributes
Show child attributes
Exemplo:
{ "id": "clxx...", "name": "Exemplo", "phone": "string", "email": "string", "languages": ["string"], "receiveMarketing": true, "telegramLinks": [ { "instanceId": "clxx...", "peer": "string", "instanceName": "string" } ], "url": "https://example.com/resource", "createdAt": "2025-02-10T14:00:00.000Z", "updatedAt": "2025-02-10T14:00:00.000Z", "tags": [{ "id": "clxx...", "name": "Exemplo" }] }
Esta página foi útil?

