Update contact by ID
curl --request PATCH \
--url https://incoming.qomon.app/contacts/{contactId} \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"data": {
"contact": {
"action_ids": [
1
],
"address": {
"addition": "<string>",
"building": "<string>",
"city": "Paris",
"country": "France",
"county": "<string>",
"door": "<string>",
"floor": "<string>",
"housenumber": "12",
"infos": "<string>",
"pollingstation": "<string>",
"postalcode": "75001",
"state": "<string>",
"street": "Rue de Rivoli"
},
"age_category": 1,
"birth_city": "<string>",
"birth_country": "<string>",
"birth_dept": "<string>",
"birthdate": "2023-11-07T05:31:56Z",
"black_list": true,
"custom_fields": [
{
"data": "XL",
"form_id": 1,
"form_ref_id": 1
}
],
"external_id": "<string>",
"firstname": "Jane",
"formdatas": [
{
"data": "Some answer",
"form_id": 1,
"form_ref_id": 1,
"date": "2023-11-07T05:31:56Z",
"survey_id": 1
}
],
"gender": "female",
"mail": "jane@example.com",
"married_name": "<string>",
"membership_code": "<string>",
"membership_number": 1,
"mobile": "<string>",
"mobile_invalid": true,
"nationality": "<string>",
"nationbuilderid": 1,
"notes": [
{
"id": 1,
"contact_id": 1,
"created_at": "2023-11-07T05:31:56Z",
"data": "<string>",
"group_id": 1,
"only_super_admin": true,
"pinned": true,
"updated_at": "2023-11-07T05:31:56Z",
"user": {
"address": "1 rue de la paix",
"avatar": "https://example.com/avatar.png",
"birthdate": "2023-11-07T05:31:56Z",
"city": "Paris",
"contacts": [
{
"id": 42
}
],
"firstname": "John",
"group_id": [
123
],
"locale": "en",
"location": "1.826483,-1.549486",
"mail": "john.doe@example.com",
"phone": "0123456789",
"postal": "75000",
"role_data": {
"color": "#DF0D73",
"id": 1,
"mobile": true,
"name": "<string>",
"order": 1,
"web": true
},
"status": "available_week_morning,available_weekend",
"surname": "Doe",
"two_factor_enable": true
}
}
],
"phone": "<string>",
"phone_invalid": true,
"surname": "Doe",
"tags": [
{
"name": "volunteer"
}
],
"user_contact_id": 123
}
}
}
'import requests
url = "https://incoming.qomon.app/contacts/{contactId}"
payload = { "data": { "contact": {
"action_ids": [1],
"address": {
"addition": "<string>",
"building": "<string>",
"city": "Paris",
"country": "France",
"county": "<string>",
"door": "<string>",
"floor": "<string>",
"housenumber": "12",
"infos": "<string>",
"pollingstation": "<string>",
"postalcode": "75001",
"state": "<string>",
"street": "Rue de Rivoli"
},
"age_category": 1,
"birth_city": "<string>",
"birth_country": "<string>",
"birth_dept": "<string>",
"birthdate": "2023-11-07T05:31:56Z",
"black_list": True,
"custom_fields": [
{
"data": "XL",
"form_id": 1,
"form_ref_id": 1
}
],
"external_id": "<string>",
"firstname": "Jane",
"formdatas": [
{
"data": "Some answer",
"form_id": 1,
"form_ref_id": 1,
"date": "2023-11-07T05:31:56Z",
"survey_id": 1
}
],
"gender": "female",
"mail": "jane@example.com",
"married_name": "<string>",
"membership_code": "<string>",
"membership_number": 1,
"mobile": "<string>",
"mobile_invalid": True,
"nationality": "<string>",
"nationbuilderid": 1,
"notes": [
{
"id": 1,
"contact_id": 1,
"created_at": "2023-11-07T05:31:56Z",
"data": "<string>",
"group_id": 1,
"only_super_admin": True,
"pinned": True,
"updated_at": "2023-11-07T05:31:56Z",
"user": {
"address": "1 rue de la paix",
"avatar": "https://example.com/avatar.png",
"birthdate": "2023-11-07T05:31:56Z",
"city": "Paris",
"contacts": [{ "id": 42 }],
"firstname": "John",
"group_id": [123],
"locale": "en",
"location": "1.826483,-1.549486",
"mail": "john.doe@example.com",
"phone": "0123456789",
"postal": "75000",
"role_data": {
"color": "#DF0D73",
"id": 1,
"mobile": True,
"name": "<string>",
"order": 1,
"web": True
},
"status": "available_week_morning,available_weekend",
"surname": "Doe",
"two_factor_enable": True
}
}
],
"phone": "<string>",
"phone_invalid": True,
"surname": "Doe",
"tags": [{ "name": "volunteer" }],
"user_contact_id": 123
} } }
headers = {
"Authorization": "Bearer <token>",
"Content-Type": "application/json"
}
response = requests.patch(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'PATCH',
headers: {Authorization: 'Bearer <token>', 'Content-Type': 'application/json'},
body: JSON.stringify({
data: {
contact: {
action_ids: [1],
address: {
addition: '<string>',
building: '<string>',
city: 'Paris',
country: 'France',
county: '<string>',
door: '<string>',
floor: '<string>',
housenumber: '12',
infos: '<string>',
pollingstation: '<string>',
postalcode: '75001',
state: '<string>',
street: 'Rue de Rivoli'
},
age_category: 1,
birth_city: '<string>',
birth_country: '<string>',
birth_dept: '<string>',
birthdate: '2023-11-07T05:31:56Z',
black_list: true,
custom_fields: [{data: 'XL', form_id: 1, form_ref_id: 1}],
external_id: '<string>',
firstname: 'Jane',
formdatas: [
{
data: 'Some answer',
form_id: 1,
form_ref_id: 1,
date: '2023-11-07T05:31:56Z',
survey_id: 1
}
],
gender: 'female',
mail: 'jane@example.com',
married_name: '<string>',
membership_code: '<string>',
membership_number: 1,
mobile: '<string>',
mobile_invalid: true,
nationality: '<string>',
nationbuilderid: 1,
notes: [
{
id: 1,
contact_id: 1,
created_at: '2023-11-07T05:31:56Z',
data: '<string>',
group_id: 1,
only_super_admin: true,
pinned: true,
updated_at: '2023-11-07T05:31:56Z',
user: {
address: '1 rue de la paix',
avatar: 'https://example.com/avatar.png',
birthdate: '2023-11-07T05:31:56Z',
city: 'Paris',
contacts: [{id: 42}],
firstname: 'John',
group_id: [123],
locale: 'en',
location: '1.826483,-1.549486',
mail: 'john.doe@example.com',
phone: '0123456789',
postal: '75000',
role_data: {color: '#DF0D73', id: 1, mobile: true, name: '<string>', order: 1, web: true},
status: 'available_week_morning,available_weekend',
surname: 'Doe',
two_factor_enable: true
}
}
],
phone: '<string>',
phone_invalid: true,
surname: 'Doe',
tags: [{name: 'volunteer'}],
user_contact_id: 123
}
}
})
};
fetch('https://incoming.qomon.app/contacts/{contactId}', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://incoming.qomon.app/contacts/{contactId}",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "PATCH",
CURLOPT_POSTFIELDS => json_encode([
'data' => [
'contact' => [
'action_ids' => [
1
],
'address' => [
'addition' => '<string>',
'building' => '<string>',
'city' => 'Paris',
'country' => 'France',
'county' => '<string>',
'door' => '<string>',
'floor' => '<string>',
'housenumber' => '12',
'infos' => '<string>',
'pollingstation' => '<string>',
'postalcode' => '75001',
'state' => '<string>',
'street' => 'Rue de Rivoli'
],
'age_category' => 1,
'birth_city' => '<string>',
'birth_country' => '<string>',
'birth_dept' => '<string>',
'birthdate' => '2023-11-07T05:31:56Z',
'black_list' => true,
'custom_fields' => [
[
'data' => 'XL',
'form_id' => 1,
'form_ref_id' => 1
]
],
'external_id' => '<string>',
'firstname' => 'Jane',
'formdatas' => [
[
'data' => 'Some answer',
'form_id' => 1,
'form_ref_id' => 1,
'date' => '2023-11-07T05:31:56Z',
'survey_id' => 1
]
],
'gender' => 'female',
'mail' => 'jane@example.com',
'married_name' => '<string>',
'membership_code' => '<string>',
'membership_number' => 1,
'mobile' => '<string>',
'mobile_invalid' => true,
'nationality' => '<string>',
'nationbuilderid' => 1,
'notes' => [
[
'id' => 1,
'contact_id' => 1,
'created_at' => '2023-11-07T05:31:56Z',
'data' => '<string>',
'group_id' => 1,
'only_super_admin' => true,
'pinned' => true,
'updated_at' => '2023-11-07T05:31:56Z',
'user' => [
'address' => '1 rue de la paix',
'avatar' => 'https://example.com/avatar.png',
'birthdate' => '2023-11-07T05:31:56Z',
'city' => 'Paris',
'contacts' => [
[
'id' => 42
]
],
'firstname' => 'John',
'group_id' => [
123
],
'locale' => 'en',
'location' => '1.826483,-1.549486',
'mail' => 'john.doe@example.com',
'phone' => '0123456789',
'postal' => '75000',
'role_data' => [
'color' => '#DF0D73',
'id' => 1,
'mobile' => true,
'name' => '<string>',
'order' => 1,
'web' => true
],
'status' => 'available_week_morning,available_weekend',
'surname' => 'Doe',
'two_factor_enable' => true
]
]
],
'phone' => '<string>',
'phone_invalid' => true,
'surname' => 'Doe',
'tags' => [
[
'name' => 'volunteer'
]
],
'user_contact_id' => 123
]
]
]),
CURLOPT_HTTPHEADER => [
"Authorization: Bearer <token>",
"Content-Type: application/json"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"strings"
"net/http"
"io"
)
func main() {
url := "https://incoming.qomon.app/contacts/{contactId}"
payload := strings.NewReader("{\n \"data\": {\n \"contact\": {\n \"action_ids\": [\n 1\n ],\n \"address\": {\n \"addition\": \"<string>\",\n \"building\": \"<string>\",\n \"city\": \"Paris\",\n \"country\": \"France\",\n \"county\": \"<string>\",\n \"door\": \"<string>\",\n \"floor\": \"<string>\",\n \"housenumber\": \"12\",\n \"infos\": \"<string>\",\n \"pollingstation\": \"<string>\",\n \"postalcode\": \"75001\",\n \"state\": \"<string>\",\n \"street\": \"Rue de Rivoli\"\n },\n \"age_category\": 1,\n \"birth_city\": \"<string>\",\n \"birth_country\": \"<string>\",\n \"birth_dept\": \"<string>\",\n \"birthdate\": \"2023-11-07T05:31:56Z\",\n \"black_list\": true,\n \"custom_fields\": [\n {\n \"data\": \"XL\",\n \"form_id\": 1,\n \"form_ref_id\": 1\n }\n ],\n \"external_id\": \"<string>\",\n \"firstname\": \"Jane\",\n \"formdatas\": [\n {\n \"data\": \"Some answer\",\n \"form_id\": 1,\n \"form_ref_id\": 1,\n \"date\": \"2023-11-07T05:31:56Z\",\n \"survey_id\": 1\n }\n ],\n \"gender\": \"female\",\n \"mail\": \"jane@example.com\",\n \"married_name\": \"<string>\",\n \"membership_code\": \"<string>\",\n \"membership_number\": 1,\n \"mobile\": \"<string>\",\n \"mobile_invalid\": true,\n \"nationality\": \"<string>\",\n \"nationbuilderid\": 1,\n \"notes\": [\n {\n \"id\": 1,\n \"contact_id\": 1,\n \"created_at\": \"2023-11-07T05:31:56Z\",\n \"data\": \"<string>\",\n \"group_id\": 1,\n \"only_super_admin\": true,\n \"pinned\": true,\n \"updated_at\": \"2023-11-07T05:31:56Z\",\n \"user\": {\n \"address\": \"1 rue de la paix\",\n \"avatar\": \"https://example.com/avatar.png\",\n \"birthdate\": \"2023-11-07T05:31:56Z\",\n \"city\": \"Paris\",\n \"contacts\": [\n {\n \"id\": 42\n }\n ],\n \"firstname\": \"John\",\n \"group_id\": [\n 123\n ],\n \"locale\": \"en\",\n \"location\": \"1.826483,-1.549486\",\n \"mail\": \"john.doe@example.com\",\n \"phone\": \"0123456789\",\n \"postal\": \"75000\",\n \"role_data\": {\n \"color\": \"#DF0D73\",\n \"id\": 1,\n \"mobile\": true,\n \"name\": \"<string>\",\n \"order\": 1,\n \"web\": true\n },\n \"status\": \"available_week_morning,available_weekend\",\n \"surname\": \"Doe\",\n \"two_factor_enable\": true\n }\n }\n ],\n \"phone\": \"<string>\",\n \"phone_invalid\": true,\n \"surname\": \"Doe\",\n \"tags\": [\n {\n \"name\": \"volunteer\"\n }\n ],\n \"user_contact_id\": 123\n }\n }\n}")
req, _ := http.NewRequest("PATCH", 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))
}HttpResponse<String> response = Unirest.patch("https://incoming.qomon.app/contacts/{contactId}")
.header("Authorization", "Bearer <token>")
.header("Content-Type", "application/json")
.body("{\n \"data\": {\n \"contact\": {\n \"action_ids\": [\n 1\n ],\n \"address\": {\n \"addition\": \"<string>\",\n \"building\": \"<string>\",\n \"city\": \"Paris\",\n \"country\": \"France\",\n \"county\": \"<string>\",\n \"door\": \"<string>\",\n \"floor\": \"<string>\",\n \"housenumber\": \"12\",\n \"infos\": \"<string>\",\n \"pollingstation\": \"<string>\",\n \"postalcode\": \"75001\",\n \"state\": \"<string>\",\n \"street\": \"Rue de Rivoli\"\n },\n \"age_category\": 1,\n \"birth_city\": \"<string>\",\n \"birth_country\": \"<string>\",\n \"birth_dept\": \"<string>\",\n \"birthdate\": \"2023-11-07T05:31:56Z\",\n \"black_list\": true,\n \"custom_fields\": [\n {\n \"data\": \"XL\",\n \"form_id\": 1,\n \"form_ref_id\": 1\n }\n ],\n \"external_id\": \"<string>\",\n \"firstname\": \"Jane\",\n \"formdatas\": [\n {\n \"data\": \"Some answer\",\n \"form_id\": 1,\n \"form_ref_id\": 1,\n \"date\": \"2023-11-07T05:31:56Z\",\n \"survey_id\": 1\n }\n ],\n \"gender\": \"female\",\n \"mail\": \"jane@example.com\",\n \"married_name\": \"<string>\",\n \"membership_code\": \"<string>\",\n \"membership_number\": 1,\n \"mobile\": \"<string>\",\n \"mobile_invalid\": true,\n \"nationality\": \"<string>\",\n \"nationbuilderid\": 1,\n \"notes\": [\n {\n \"id\": 1,\n \"contact_id\": 1,\n \"created_at\": \"2023-11-07T05:31:56Z\",\n \"data\": \"<string>\",\n \"group_id\": 1,\n \"only_super_admin\": true,\n \"pinned\": true,\n \"updated_at\": \"2023-11-07T05:31:56Z\",\n \"user\": {\n \"address\": \"1 rue de la paix\",\n \"avatar\": \"https://example.com/avatar.png\",\n \"birthdate\": \"2023-11-07T05:31:56Z\",\n \"city\": \"Paris\",\n \"contacts\": [\n {\n \"id\": 42\n }\n ],\n \"firstname\": \"John\",\n \"group_id\": [\n 123\n ],\n \"locale\": \"en\",\n \"location\": \"1.826483,-1.549486\",\n \"mail\": \"john.doe@example.com\",\n \"phone\": \"0123456789\",\n \"postal\": \"75000\",\n \"role_data\": {\n \"color\": \"#DF0D73\",\n \"id\": 1,\n \"mobile\": true,\n \"name\": \"<string>\",\n \"order\": 1,\n \"web\": true\n },\n \"status\": \"available_week_morning,available_weekend\",\n \"surname\": \"Doe\",\n \"two_factor_enable\": true\n }\n }\n ],\n \"phone\": \"<string>\",\n \"phone_invalid\": true,\n \"surname\": \"Doe\",\n \"tags\": [\n {\n \"name\": \"volunteer\"\n }\n ],\n \"user_contact_id\": 123\n }\n }\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://incoming.qomon.app/contacts/{contactId}")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Patch.new(url)
request["Authorization"] = 'Bearer <token>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"data\": {\n \"contact\": {\n \"action_ids\": [\n 1\n ],\n \"address\": {\n \"addition\": \"<string>\",\n \"building\": \"<string>\",\n \"city\": \"Paris\",\n \"country\": \"France\",\n \"county\": \"<string>\",\n \"door\": \"<string>\",\n \"floor\": \"<string>\",\n \"housenumber\": \"12\",\n \"infos\": \"<string>\",\n \"pollingstation\": \"<string>\",\n \"postalcode\": \"75001\",\n \"state\": \"<string>\",\n \"street\": \"Rue de Rivoli\"\n },\n \"age_category\": 1,\n \"birth_city\": \"<string>\",\n \"birth_country\": \"<string>\",\n \"birth_dept\": \"<string>\",\n \"birthdate\": \"2023-11-07T05:31:56Z\",\n \"black_list\": true,\n \"custom_fields\": [\n {\n \"data\": \"XL\",\n \"form_id\": 1,\n \"form_ref_id\": 1\n }\n ],\n \"external_id\": \"<string>\",\n \"firstname\": \"Jane\",\n \"formdatas\": [\n {\n \"data\": \"Some answer\",\n \"form_id\": 1,\n \"form_ref_id\": 1,\n \"date\": \"2023-11-07T05:31:56Z\",\n \"survey_id\": 1\n }\n ],\n \"gender\": \"female\",\n \"mail\": \"jane@example.com\",\n \"married_name\": \"<string>\",\n \"membership_code\": \"<string>\",\n \"membership_number\": 1,\n \"mobile\": \"<string>\",\n \"mobile_invalid\": true,\n \"nationality\": \"<string>\",\n \"nationbuilderid\": 1,\n \"notes\": [\n {\n \"id\": 1,\n \"contact_id\": 1,\n \"created_at\": \"2023-11-07T05:31:56Z\",\n \"data\": \"<string>\",\n \"group_id\": 1,\n \"only_super_admin\": true,\n \"pinned\": true,\n \"updated_at\": \"2023-11-07T05:31:56Z\",\n \"user\": {\n \"address\": \"1 rue de la paix\",\n \"avatar\": \"https://example.com/avatar.png\",\n \"birthdate\": \"2023-11-07T05:31:56Z\",\n \"city\": \"Paris\",\n \"contacts\": [\n {\n \"id\": 42\n }\n ],\n \"firstname\": \"John\",\n \"group_id\": [\n 123\n ],\n \"locale\": \"en\",\n \"location\": \"1.826483,-1.549486\",\n \"mail\": \"john.doe@example.com\",\n \"phone\": \"0123456789\",\n \"postal\": \"75000\",\n \"role_data\": {\n \"color\": \"#DF0D73\",\n \"id\": 1,\n \"mobile\": true,\n \"name\": \"<string>\",\n \"order\": 1,\n \"web\": true\n },\n \"status\": \"available_week_morning,available_weekend\",\n \"surname\": \"Doe\",\n \"two_factor_enable\": true\n }\n }\n ],\n \"phone\": \"<string>\",\n \"phone_invalid\": true,\n \"surname\": \"Doe\",\n \"tags\": [\n {\n \"name\": \"volunteer\"\n }\n ],\n \"user_contact_id\": 123\n }\n }\n}"
response = http.request(request)
puts response.read_body{
"data": {
"contact": {
"id": 1,
"CreatedAt": "2023-11-07T05:31:56Z",
"UpdatedAt": "2023-11-07T05:31:56Z",
"action_ids": [
1
],
"address": {
"addition": "<string>",
"building": "<string>",
"building_type": "house",
"city": "Paris",
"country": "France",
"county": "<string>",
"door": "<string>",
"floor": "<string>",
"housenumber": "12",
"id": 7,
"infos": "<string>",
"latitude": "48.8606",
"location": "48.8606,2.3376",
"longitude": "2.3376",
"pollingstation": "<string>",
"postalcode": "75001",
"score": 123,
"state": "<string>",
"street": "Rue de Rivoli"
},
"age_category": 1,
"birth_city": "<string>",
"birth_country": "<string>",
"birth_dept": "<string>",
"birthdate": "2023-11-07T05:31:56Z",
"black_list": true,
"custom_fields": [
{
"data": "XL",
"form_id": 1,
"form_ref_id": 1,
"id": 1
}
],
"external_id": "<string>",
"firstname": "Jane",
"formdatas": [
{
"data": "Some answer",
"form_id": 1,
"form_ref_id": 1,
"id": 1,
"contact_id": 1,
"date": "2023-11-07T05:31:56Z",
"group_id": 1,
"survey_id": 1
}
],
"gender": "female",
"group_id": 1,
"lastchange": "2023-11-07T05:31:56Z",
"lastchangeuserid": 1,
"mail": "jane@example.com",
"married_name": "<string>",
"membership_code": "<string>",
"membership_number": 1,
"mobile": "<string>",
"mobile_invalid": true,
"nationality": "<string>",
"nationbuilderid": 1,
"notes": [
{
"id": 1,
"contact_id": 1,
"created_at": "2023-11-07T05:31:56Z",
"data": "<string>",
"group_id": 1,
"only_super_admin": true,
"pinned": true,
"updated_at": "2023-11-07T05:31:56Z",
"user": {
"CreatedAt": "2023-11-07T05:31:56Z",
"UpdatedAt": "2023-11-07T05:31:56Z",
"address": "1 rue de la paix",
"avatar": "https://example.com/avatar.png",
"birthdate": "2023-11-07T05:31:56Z",
"city": "Paris",
"contacts": [
{
"id": 42
}
],
"created": "2023-11-07T05:31:56Z",
"firstname": "John",
"group_id": [
123
],
"id": 101,
"locale": "en",
"location": "1.826483,-1.549486",
"mail": "john.doe@example.com",
"phone": "0123456789",
"postal": "75000",
"role_data": {
"color": "#DF0D73",
"id": 1,
"mobile": true,
"name": "<string>",
"order": 1,
"type": "superadmin",
"web": true
},
"status": "available_week_morning,available_weekend",
"surname": "Doe",
"two_factor_enable": true,
"two_factor_method": "email"
}
}
],
"phone": "<string>",
"phone_invalid": true,
"surname": "Doe",
"tags": [
{
"name": "volunteer"
}
],
"user_contact_id": 123
}
},
"status": "success"
}{
"detail": "Property foo is required but is missing.",
"errors": [
{
"location": "<string>",
"message": "<string>",
"value": "<unknown>"
}
],
"instance": "https://example.com/error-log/abc123",
"status": 400,
"title": "Bad Request",
"type": "https://example.com/errors/example"
}Contacts
Update contact by ID
Fully replace an existing contact in the Qomon database (behaves like PUT).
PATCH
/
contacts
/
{contactId}
Update contact by ID
curl --request PATCH \
--url https://incoming.qomon.app/contacts/{contactId} \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"data": {
"contact": {
"action_ids": [
1
],
"address": {
"addition": "<string>",
"building": "<string>",
"city": "Paris",
"country": "France",
"county": "<string>",
"door": "<string>",
"floor": "<string>",
"housenumber": "12",
"infos": "<string>",
"pollingstation": "<string>",
"postalcode": "75001",
"state": "<string>",
"street": "Rue de Rivoli"
},
"age_category": 1,
"birth_city": "<string>",
"birth_country": "<string>",
"birth_dept": "<string>",
"birthdate": "2023-11-07T05:31:56Z",
"black_list": true,
"custom_fields": [
{
"data": "XL",
"form_id": 1,
"form_ref_id": 1
}
],
"external_id": "<string>",
"firstname": "Jane",
"formdatas": [
{
"data": "Some answer",
"form_id": 1,
"form_ref_id": 1,
"date": "2023-11-07T05:31:56Z",
"survey_id": 1
}
],
"gender": "female",
"mail": "jane@example.com",
"married_name": "<string>",
"membership_code": "<string>",
"membership_number": 1,
"mobile": "<string>",
"mobile_invalid": true,
"nationality": "<string>",
"nationbuilderid": 1,
"notes": [
{
"id": 1,
"contact_id": 1,
"created_at": "2023-11-07T05:31:56Z",
"data": "<string>",
"group_id": 1,
"only_super_admin": true,
"pinned": true,
"updated_at": "2023-11-07T05:31:56Z",
"user": {
"address": "1 rue de la paix",
"avatar": "https://example.com/avatar.png",
"birthdate": "2023-11-07T05:31:56Z",
"city": "Paris",
"contacts": [
{
"id": 42
}
],
"firstname": "John",
"group_id": [
123
],
"locale": "en",
"location": "1.826483,-1.549486",
"mail": "john.doe@example.com",
"phone": "0123456789",
"postal": "75000",
"role_data": {
"color": "#DF0D73",
"id": 1,
"mobile": true,
"name": "<string>",
"order": 1,
"web": true
},
"status": "available_week_morning,available_weekend",
"surname": "Doe",
"two_factor_enable": true
}
}
],
"phone": "<string>",
"phone_invalid": true,
"surname": "Doe",
"tags": [
{
"name": "volunteer"
}
],
"user_contact_id": 123
}
}
}
'import requests
url = "https://incoming.qomon.app/contacts/{contactId}"
payload = { "data": { "contact": {
"action_ids": [1],
"address": {
"addition": "<string>",
"building": "<string>",
"city": "Paris",
"country": "France",
"county": "<string>",
"door": "<string>",
"floor": "<string>",
"housenumber": "12",
"infos": "<string>",
"pollingstation": "<string>",
"postalcode": "75001",
"state": "<string>",
"street": "Rue de Rivoli"
},
"age_category": 1,
"birth_city": "<string>",
"birth_country": "<string>",
"birth_dept": "<string>",
"birthdate": "2023-11-07T05:31:56Z",
"black_list": True,
"custom_fields": [
{
"data": "XL",
"form_id": 1,
"form_ref_id": 1
}
],
"external_id": "<string>",
"firstname": "Jane",
"formdatas": [
{
"data": "Some answer",
"form_id": 1,
"form_ref_id": 1,
"date": "2023-11-07T05:31:56Z",
"survey_id": 1
}
],
"gender": "female",
"mail": "jane@example.com",
"married_name": "<string>",
"membership_code": "<string>",
"membership_number": 1,
"mobile": "<string>",
"mobile_invalid": True,
"nationality": "<string>",
"nationbuilderid": 1,
"notes": [
{
"id": 1,
"contact_id": 1,
"created_at": "2023-11-07T05:31:56Z",
"data": "<string>",
"group_id": 1,
"only_super_admin": True,
"pinned": True,
"updated_at": "2023-11-07T05:31:56Z",
"user": {
"address": "1 rue de la paix",
"avatar": "https://example.com/avatar.png",
"birthdate": "2023-11-07T05:31:56Z",
"city": "Paris",
"contacts": [{ "id": 42 }],
"firstname": "John",
"group_id": [123],
"locale": "en",
"location": "1.826483,-1.549486",
"mail": "john.doe@example.com",
"phone": "0123456789",
"postal": "75000",
"role_data": {
"color": "#DF0D73",
"id": 1,
"mobile": True,
"name": "<string>",
"order": 1,
"web": True
},
"status": "available_week_morning,available_weekend",
"surname": "Doe",
"two_factor_enable": True
}
}
],
"phone": "<string>",
"phone_invalid": True,
"surname": "Doe",
"tags": [{ "name": "volunteer" }],
"user_contact_id": 123
} } }
headers = {
"Authorization": "Bearer <token>",
"Content-Type": "application/json"
}
response = requests.patch(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'PATCH',
headers: {Authorization: 'Bearer <token>', 'Content-Type': 'application/json'},
body: JSON.stringify({
data: {
contact: {
action_ids: [1],
address: {
addition: '<string>',
building: '<string>',
city: 'Paris',
country: 'France',
county: '<string>',
door: '<string>',
floor: '<string>',
housenumber: '12',
infos: '<string>',
pollingstation: '<string>',
postalcode: '75001',
state: '<string>',
street: 'Rue de Rivoli'
},
age_category: 1,
birth_city: '<string>',
birth_country: '<string>',
birth_dept: '<string>',
birthdate: '2023-11-07T05:31:56Z',
black_list: true,
custom_fields: [{data: 'XL', form_id: 1, form_ref_id: 1}],
external_id: '<string>',
firstname: 'Jane',
formdatas: [
{
data: 'Some answer',
form_id: 1,
form_ref_id: 1,
date: '2023-11-07T05:31:56Z',
survey_id: 1
}
],
gender: 'female',
mail: 'jane@example.com',
married_name: '<string>',
membership_code: '<string>',
membership_number: 1,
mobile: '<string>',
mobile_invalid: true,
nationality: '<string>',
nationbuilderid: 1,
notes: [
{
id: 1,
contact_id: 1,
created_at: '2023-11-07T05:31:56Z',
data: '<string>',
group_id: 1,
only_super_admin: true,
pinned: true,
updated_at: '2023-11-07T05:31:56Z',
user: {
address: '1 rue de la paix',
avatar: 'https://example.com/avatar.png',
birthdate: '2023-11-07T05:31:56Z',
city: 'Paris',
contacts: [{id: 42}],
firstname: 'John',
group_id: [123],
locale: 'en',
location: '1.826483,-1.549486',
mail: 'john.doe@example.com',
phone: '0123456789',
postal: '75000',
role_data: {color: '#DF0D73', id: 1, mobile: true, name: '<string>', order: 1, web: true},
status: 'available_week_morning,available_weekend',
surname: 'Doe',
two_factor_enable: true
}
}
],
phone: '<string>',
phone_invalid: true,
surname: 'Doe',
tags: [{name: 'volunteer'}],
user_contact_id: 123
}
}
})
};
fetch('https://incoming.qomon.app/contacts/{contactId}', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://incoming.qomon.app/contacts/{contactId}",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "PATCH",
CURLOPT_POSTFIELDS => json_encode([
'data' => [
'contact' => [
'action_ids' => [
1
],
'address' => [
'addition' => '<string>',
'building' => '<string>',
'city' => 'Paris',
'country' => 'France',
'county' => '<string>',
'door' => '<string>',
'floor' => '<string>',
'housenumber' => '12',
'infos' => '<string>',
'pollingstation' => '<string>',
'postalcode' => '75001',
'state' => '<string>',
'street' => 'Rue de Rivoli'
],
'age_category' => 1,
'birth_city' => '<string>',
'birth_country' => '<string>',
'birth_dept' => '<string>',
'birthdate' => '2023-11-07T05:31:56Z',
'black_list' => true,
'custom_fields' => [
[
'data' => 'XL',
'form_id' => 1,
'form_ref_id' => 1
]
],
'external_id' => '<string>',
'firstname' => 'Jane',
'formdatas' => [
[
'data' => 'Some answer',
'form_id' => 1,
'form_ref_id' => 1,
'date' => '2023-11-07T05:31:56Z',
'survey_id' => 1
]
],
'gender' => 'female',
'mail' => 'jane@example.com',
'married_name' => '<string>',
'membership_code' => '<string>',
'membership_number' => 1,
'mobile' => '<string>',
'mobile_invalid' => true,
'nationality' => '<string>',
'nationbuilderid' => 1,
'notes' => [
[
'id' => 1,
'contact_id' => 1,
'created_at' => '2023-11-07T05:31:56Z',
'data' => '<string>',
'group_id' => 1,
'only_super_admin' => true,
'pinned' => true,
'updated_at' => '2023-11-07T05:31:56Z',
'user' => [
'address' => '1 rue de la paix',
'avatar' => 'https://example.com/avatar.png',
'birthdate' => '2023-11-07T05:31:56Z',
'city' => 'Paris',
'contacts' => [
[
'id' => 42
]
],
'firstname' => 'John',
'group_id' => [
123
],
'locale' => 'en',
'location' => '1.826483,-1.549486',
'mail' => 'john.doe@example.com',
'phone' => '0123456789',
'postal' => '75000',
'role_data' => [
'color' => '#DF0D73',
'id' => 1,
'mobile' => true,
'name' => '<string>',
'order' => 1,
'web' => true
],
'status' => 'available_week_morning,available_weekend',
'surname' => 'Doe',
'two_factor_enable' => true
]
]
],
'phone' => '<string>',
'phone_invalid' => true,
'surname' => 'Doe',
'tags' => [
[
'name' => 'volunteer'
]
],
'user_contact_id' => 123
]
]
]),
CURLOPT_HTTPHEADER => [
"Authorization: Bearer <token>",
"Content-Type: application/json"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"strings"
"net/http"
"io"
)
func main() {
url := "https://incoming.qomon.app/contacts/{contactId}"
payload := strings.NewReader("{\n \"data\": {\n \"contact\": {\n \"action_ids\": [\n 1\n ],\n \"address\": {\n \"addition\": \"<string>\",\n \"building\": \"<string>\",\n \"city\": \"Paris\",\n \"country\": \"France\",\n \"county\": \"<string>\",\n \"door\": \"<string>\",\n \"floor\": \"<string>\",\n \"housenumber\": \"12\",\n \"infos\": \"<string>\",\n \"pollingstation\": \"<string>\",\n \"postalcode\": \"75001\",\n \"state\": \"<string>\",\n \"street\": \"Rue de Rivoli\"\n },\n \"age_category\": 1,\n \"birth_city\": \"<string>\",\n \"birth_country\": \"<string>\",\n \"birth_dept\": \"<string>\",\n \"birthdate\": \"2023-11-07T05:31:56Z\",\n \"black_list\": true,\n \"custom_fields\": [\n {\n \"data\": \"XL\",\n \"form_id\": 1,\n \"form_ref_id\": 1\n }\n ],\n \"external_id\": \"<string>\",\n \"firstname\": \"Jane\",\n \"formdatas\": [\n {\n \"data\": \"Some answer\",\n \"form_id\": 1,\n \"form_ref_id\": 1,\n \"date\": \"2023-11-07T05:31:56Z\",\n \"survey_id\": 1\n }\n ],\n \"gender\": \"female\",\n \"mail\": \"jane@example.com\",\n \"married_name\": \"<string>\",\n \"membership_code\": \"<string>\",\n \"membership_number\": 1,\n \"mobile\": \"<string>\",\n \"mobile_invalid\": true,\n \"nationality\": \"<string>\",\n \"nationbuilderid\": 1,\n \"notes\": [\n {\n \"id\": 1,\n \"contact_id\": 1,\n \"created_at\": \"2023-11-07T05:31:56Z\",\n \"data\": \"<string>\",\n \"group_id\": 1,\n \"only_super_admin\": true,\n \"pinned\": true,\n \"updated_at\": \"2023-11-07T05:31:56Z\",\n \"user\": {\n \"address\": \"1 rue de la paix\",\n \"avatar\": \"https://example.com/avatar.png\",\n \"birthdate\": \"2023-11-07T05:31:56Z\",\n \"city\": \"Paris\",\n \"contacts\": [\n {\n \"id\": 42\n }\n ],\n \"firstname\": \"John\",\n \"group_id\": [\n 123\n ],\n \"locale\": \"en\",\n \"location\": \"1.826483,-1.549486\",\n \"mail\": \"john.doe@example.com\",\n \"phone\": \"0123456789\",\n \"postal\": \"75000\",\n \"role_data\": {\n \"color\": \"#DF0D73\",\n \"id\": 1,\n \"mobile\": true,\n \"name\": \"<string>\",\n \"order\": 1,\n \"web\": true\n },\n \"status\": \"available_week_morning,available_weekend\",\n \"surname\": \"Doe\",\n \"two_factor_enable\": true\n }\n }\n ],\n \"phone\": \"<string>\",\n \"phone_invalid\": true,\n \"surname\": \"Doe\",\n \"tags\": [\n {\n \"name\": \"volunteer\"\n }\n ],\n \"user_contact_id\": 123\n }\n }\n}")
req, _ := http.NewRequest("PATCH", 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))
}HttpResponse<String> response = Unirest.patch("https://incoming.qomon.app/contacts/{contactId}")
.header("Authorization", "Bearer <token>")
.header("Content-Type", "application/json")
.body("{\n \"data\": {\n \"contact\": {\n \"action_ids\": [\n 1\n ],\n \"address\": {\n \"addition\": \"<string>\",\n \"building\": \"<string>\",\n \"city\": \"Paris\",\n \"country\": \"France\",\n \"county\": \"<string>\",\n \"door\": \"<string>\",\n \"floor\": \"<string>\",\n \"housenumber\": \"12\",\n \"infos\": \"<string>\",\n \"pollingstation\": \"<string>\",\n \"postalcode\": \"75001\",\n \"state\": \"<string>\",\n \"street\": \"Rue de Rivoli\"\n },\n \"age_category\": 1,\n \"birth_city\": \"<string>\",\n \"birth_country\": \"<string>\",\n \"birth_dept\": \"<string>\",\n \"birthdate\": \"2023-11-07T05:31:56Z\",\n \"black_list\": true,\n \"custom_fields\": [\n {\n \"data\": \"XL\",\n \"form_id\": 1,\n \"form_ref_id\": 1\n }\n ],\n \"external_id\": \"<string>\",\n \"firstname\": \"Jane\",\n \"formdatas\": [\n {\n \"data\": \"Some answer\",\n \"form_id\": 1,\n \"form_ref_id\": 1,\n \"date\": \"2023-11-07T05:31:56Z\",\n \"survey_id\": 1\n }\n ],\n \"gender\": \"female\",\n \"mail\": \"jane@example.com\",\n \"married_name\": \"<string>\",\n \"membership_code\": \"<string>\",\n \"membership_number\": 1,\n \"mobile\": \"<string>\",\n \"mobile_invalid\": true,\n \"nationality\": \"<string>\",\n \"nationbuilderid\": 1,\n \"notes\": [\n {\n \"id\": 1,\n \"contact_id\": 1,\n \"created_at\": \"2023-11-07T05:31:56Z\",\n \"data\": \"<string>\",\n \"group_id\": 1,\n \"only_super_admin\": true,\n \"pinned\": true,\n \"updated_at\": \"2023-11-07T05:31:56Z\",\n \"user\": {\n \"address\": \"1 rue de la paix\",\n \"avatar\": \"https://example.com/avatar.png\",\n \"birthdate\": \"2023-11-07T05:31:56Z\",\n \"city\": \"Paris\",\n \"contacts\": [\n {\n \"id\": 42\n }\n ],\n \"firstname\": \"John\",\n \"group_id\": [\n 123\n ],\n \"locale\": \"en\",\n \"location\": \"1.826483,-1.549486\",\n \"mail\": \"john.doe@example.com\",\n \"phone\": \"0123456789\",\n \"postal\": \"75000\",\n \"role_data\": {\n \"color\": \"#DF0D73\",\n \"id\": 1,\n \"mobile\": true,\n \"name\": \"<string>\",\n \"order\": 1,\n \"web\": true\n },\n \"status\": \"available_week_morning,available_weekend\",\n \"surname\": \"Doe\",\n \"two_factor_enable\": true\n }\n }\n ],\n \"phone\": \"<string>\",\n \"phone_invalid\": true,\n \"surname\": \"Doe\",\n \"tags\": [\n {\n \"name\": \"volunteer\"\n }\n ],\n \"user_contact_id\": 123\n }\n }\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://incoming.qomon.app/contacts/{contactId}")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Patch.new(url)
request["Authorization"] = 'Bearer <token>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"data\": {\n \"contact\": {\n \"action_ids\": [\n 1\n ],\n \"address\": {\n \"addition\": \"<string>\",\n \"building\": \"<string>\",\n \"city\": \"Paris\",\n \"country\": \"France\",\n \"county\": \"<string>\",\n \"door\": \"<string>\",\n \"floor\": \"<string>\",\n \"housenumber\": \"12\",\n \"infos\": \"<string>\",\n \"pollingstation\": \"<string>\",\n \"postalcode\": \"75001\",\n \"state\": \"<string>\",\n \"street\": \"Rue de Rivoli\"\n },\n \"age_category\": 1,\n \"birth_city\": \"<string>\",\n \"birth_country\": \"<string>\",\n \"birth_dept\": \"<string>\",\n \"birthdate\": \"2023-11-07T05:31:56Z\",\n \"black_list\": true,\n \"custom_fields\": [\n {\n \"data\": \"XL\",\n \"form_id\": 1,\n \"form_ref_id\": 1\n }\n ],\n \"external_id\": \"<string>\",\n \"firstname\": \"Jane\",\n \"formdatas\": [\n {\n \"data\": \"Some answer\",\n \"form_id\": 1,\n \"form_ref_id\": 1,\n \"date\": \"2023-11-07T05:31:56Z\",\n \"survey_id\": 1\n }\n ],\n \"gender\": \"female\",\n \"mail\": \"jane@example.com\",\n \"married_name\": \"<string>\",\n \"membership_code\": \"<string>\",\n \"membership_number\": 1,\n \"mobile\": \"<string>\",\n \"mobile_invalid\": true,\n \"nationality\": \"<string>\",\n \"nationbuilderid\": 1,\n \"notes\": [\n {\n \"id\": 1,\n \"contact_id\": 1,\n \"created_at\": \"2023-11-07T05:31:56Z\",\n \"data\": \"<string>\",\n \"group_id\": 1,\n \"only_super_admin\": true,\n \"pinned\": true,\n \"updated_at\": \"2023-11-07T05:31:56Z\",\n \"user\": {\n \"address\": \"1 rue de la paix\",\n \"avatar\": \"https://example.com/avatar.png\",\n \"birthdate\": \"2023-11-07T05:31:56Z\",\n \"city\": \"Paris\",\n \"contacts\": [\n {\n \"id\": 42\n }\n ],\n \"firstname\": \"John\",\n \"group_id\": [\n 123\n ],\n \"locale\": \"en\",\n \"location\": \"1.826483,-1.549486\",\n \"mail\": \"john.doe@example.com\",\n \"phone\": \"0123456789\",\n \"postal\": \"75000\",\n \"role_data\": {\n \"color\": \"#DF0D73\",\n \"id\": 1,\n \"mobile\": true,\n \"name\": \"<string>\",\n \"order\": 1,\n \"web\": true\n },\n \"status\": \"available_week_morning,available_weekend\",\n \"surname\": \"Doe\",\n \"two_factor_enable\": true\n }\n }\n ],\n \"phone\": \"<string>\",\n \"phone_invalid\": true,\n \"surname\": \"Doe\",\n \"tags\": [\n {\n \"name\": \"volunteer\"\n }\n ],\n \"user_contact_id\": 123\n }\n }\n}"
response = http.request(request)
puts response.read_body{
"data": {
"contact": {
"id": 1,
"CreatedAt": "2023-11-07T05:31:56Z",
"UpdatedAt": "2023-11-07T05:31:56Z",
"action_ids": [
1
],
"address": {
"addition": "<string>",
"building": "<string>",
"building_type": "house",
"city": "Paris",
"country": "France",
"county": "<string>",
"door": "<string>",
"floor": "<string>",
"housenumber": "12",
"id": 7,
"infos": "<string>",
"latitude": "48.8606",
"location": "48.8606,2.3376",
"longitude": "2.3376",
"pollingstation": "<string>",
"postalcode": "75001",
"score": 123,
"state": "<string>",
"street": "Rue de Rivoli"
},
"age_category": 1,
"birth_city": "<string>",
"birth_country": "<string>",
"birth_dept": "<string>",
"birthdate": "2023-11-07T05:31:56Z",
"black_list": true,
"custom_fields": [
{
"data": "XL",
"form_id": 1,
"form_ref_id": 1,
"id": 1
}
],
"external_id": "<string>",
"firstname": "Jane",
"formdatas": [
{
"data": "Some answer",
"form_id": 1,
"form_ref_id": 1,
"id": 1,
"contact_id": 1,
"date": "2023-11-07T05:31:56Z",
"group_id": 1,
"survey_id": 1
}
],
"gender": "female",
"group_id": 1,
"lastchange": "2023-11-07T05:31:56Z",
"lastchangeuserid": 1,
"mail": "jane@example.com",
"married_name": "<string>",
"membership_code": "<string>",
"membership_number": 1,
"mobile": "<string>",
"mobile_invalid": true,
"nationality": "<string>",
"nationbuilderid": 1,
"notes": [
{
"id": 1,
"contact_id": 1,
"created_at": "2023-11-07T05:31:56Z",
"data": "<string>",
"group_id": 1,
"only_super_admin": true,
"pinned": true,
"updated_at": "2023-11-07T05:31:56Z",
"user": {
"CreatedAt": "2023-11-07T05:31:56Z",
"UpdatedAt": "2023-11-07T05:31:56Z",
"address": "1 rue de la paix",
"avatar": "https://example.com/avatar.png",
"birthdate": "2023-11-07T05:31:56Z",
"city": "Paris",
"contacts": [
{
"id": 42
}
],
"created": "2023-11-07T05:31:56Z",
"firstname": "John",
"group_id": [
123
],
"id": 101,
"locale": "en",
"location": "1.826483,-1.549486",
"mail": "john.doe@example.com",
"phone": "0123456789",
"postal": "75000",
"role_data": {
"color": "#DF0D73",
"id": 1,
"mobile": true,
"name": "<string>",
"order": 1,
"type": "superadmin",
"web": true
},
"status": "available_week_morning,available_weekend",
"surname": "Doe",
"two_factor_enable": true,
"two_factor_method": "email"
}
}
],
"phone": "<string>",
"phone_invalid": true,
"surname": "Doe",
"tags": [
{
"name": "volunteer"
}
],
"user_contact_id": 123
}
},
"status": "success"
}{
"detail": "Property foo is required but is missing.",
"errors": [
{
"location": "<string>",
"message": "<string>",
"value": "<unknown>"
}
],
"instance": "https://example.com/error-log/abc123",
"status": 400,
"title": "Bad Request",
"type": "https://example.com/errors/example"
}Authorizations
OAuth2 access token. Pass the token in the Authorization header as Bearer <token>. The token is looked up in Redis to resolve the caller identity.
Path Parameters
Contact ID.
Required range:
x >= 0Example:
42
Body
application/json
Show child attributes
Show child attributes
Last modified on September 3, 2026
Was this page helpful?
⌘I

