Update a Contact
Edit an existing contact in your company contact list
https://api.constructiononline.com/api/Contacts?id={id}
This endpoint allows users to edit an existing contact within their company contact list. Users can update any of the contact's properties, such as email address, phone or trade. To update a contact, users must know the unique numerical ID assigned to the contact. Users should enter the properties to be updated in the body of the request. Only the properties specified in the body will be updated—all other properties will remain as is.
Requests
REQUIRED PARAMETERS
ID: integer
- Unique identifier for the contact.
Contact Info: JSON
-
Updated properties for the contact.
- Allowed properties in Contact Info: FIRSTNAME, LASTNAME, EMAIL, DISPLAY_NAME, COMPANY, ADDRESS, CITY, STATE, ZIP, PHONE, MOBILE_PHONE, MOBILE_PROVIDER, FAX, MIDDLENAME, WEBSITE, LAT, LON, CONTACT_QUALITY, CONTACT_REGION, CONTACT_DIVISION, CONTACT_OFFICE, CONTACT_CATEGORY, CONTACT_TRADE
Individual properties for update should be entered as JSON key-value pairs, as seen below:
{
"EMAIL" : "alice@conwayconstruction.com",
"ADDRESS" : "1420 Piedmont Ave",
"CITY" : "Atlanta",
"STATE" : "Georgia",
"ZIP" : "30002"
}
Example requests in cURL, C#, Python, and JavaScript can be found below:
cURL
# Replace {email} with the email address for your ConstructionOnline account
# {password} with your ConstructionOnline password
# {apikey} with your provided API key
# {id} with the contact's ID
# {data} with the payload containing the contact properties
curl -X PUT https://api.constructiononline.com/api/Contacts?id={id} -d '{data}'-u {email}:{password} -H 'APIKey:{apikey}'
C#
/* Replace {username} with the email address for your ConstructionOnline account
{password} with your ConstructionOnline password
{apikey} with your provided API key
{id} with the contact's ID */
public string MakeRequest(string endpoint, string payload)
{
string username = {username};
string password = {password};
string apiKey = {apikey};
string response = "";
var handler = new HttpClientHandler() { AutomaticDecompression = System.Net.DecompressionMethods.GZip };
using (HttpClient client = new HttpClient(handler))
{
client.BaseAddress = new Uri("http://api.constructiononline.com");
client.DefaultRequestHeaders.Accept.Clear();
client.DefaultRequestHeaders.Accept.Add(new MediaTypeWithQualityHeaderValue("application/json"));
client.DefaultRequestHeaders.Authorization = new AuthenticationHeaderValue("Basic",
System.Convert.ToBase64String(System.Text.Encoding.GetEncoding("ISO-8859-1").GetBytes(username + ":" + password)));
client.DefaultRequestHeaders.Add("APIKey", apiKey);
client.DefaultRequestHeaders.Add("Accept-Encoding", "gzip");
HttpContent content = new StringContent(payload, System.Text.Encoding.UTF32, "application/json");
response = client.PutAsync(endpoint, content).Result.ToString();
}
return response;
}
MakeRequest("api/Contacts?id={id}");
Python
# Replace {username} with the email address for your ConstructionOnline account
# {password} with your ConstructionOnline password
# {apikey} with your provided API key
# {id} with the contact's ID
import base64
import requests
import json
# Global Variables
apikey = "{apikey}"
username = "{username}"
password = "{password}"
# Functions
def makeRequest(endpoint):
url = "https://api.constructiononline.com/" + endpoint
userPass = username + ":" + password
headers = {
"APIKey": apikey,
"Accept-Encoding": "gzip, deflate, br",
"Authorization": "Basic " + base64.b64encode(userPass.encode()).decode(),
}
response = requests.request("PUT", url, headers=headers, data=payload)
return json.dumps(json.loads(response.text), indent=2)
#Main Program
print(makeRequest("api/Contacts?id={id}")
JavaScript
/* Replace {username} with the email address for your ConstructionOnline account
{password} with your ConstructionOnline password
{apikey} with your provided API key
{id} with the contact's ID */
username = '{username}';
password = '{password}';
apikey = '{apikey}';
function makeRequest(endpoint) {
auth = btoa('${username}:${password}');
var myHeaders = new Headers();
myHeaders.append("APIKey", apikey);
myHeaders.append("Accept-Encoding", "gzip, deflate, br");
myHeaders.append("Authorization", "Basic ${auth}");
var requestOptions = {
method: 'PUT',
headers: myHeaders,
redirect: 'follow'
};
fetch("https://api.constructiononline.com/" + endpoint, requestOptions)
.then(response => response.text())
.then(result => console.log(result))
.catch(error => console.log('error', error));
return response;
};
makeRequest("api/Contacts?id={id}");
Responses
A successful request will return a 200 response with a record of the edited contact in the body, as seen below. Definitions for all returned properties can be found here.
{
"$id": "1",
"ID": 1742627,
"FIRSTNAME": "Alice",
"LASTNAME": "Conway",
"EMAIL": "alice@conwayconstruction.com",
"ACCOUNT": null,
"LACCESS": "2025-07-14T17:30:33.097",
"LMOD": "2025-07-14T17:30:33.097",
"DISPLAY_NAME": "Alice Conway",
"COMPANY": null,
"ADDRESS": null,
"CITY": null,
"STATE": null,
"ZIP": null,
"PHONE": "",
"MOBILE_PHONE": null,
"MOBILE_PROVIDER": null,
"FAX": null,
"LMOD_CON_ID": null,
"LMOD_NAME": null,
"ISCOMPANY": false,
"MIDDLENAME": null,
"WEBSITE": null,
"SUMMARY": null,
"EXPERIENCE": null,
"CREATOR_ID": null,
"CREATOR_NAME": null,
"TIMEZONE_OFFSET": -5.0,
"AUTO_TIMEZONE": true,
"COMPANY_ID": null,
"COMPANY_NAME": null,
"COUNTRY_SETTING": 1,
"LANGUAGE_SETTING": 1,
"LAT": null,
"LON": null,
"CS_LMOD": null,
"COMPANY_PERMISSIONS": 0,
"COMPANY_PERMISSIONS_CALENDAR": 0,
"COMPANY_PERMISSIONS_SCHEDULING": 0,
"COMPANY_PERMISSIONS_TODOS": 0,
"COMPANY_PERMISSIONS_CHANGEORDERS": 0,
"COMPANY_PERMISSIONS_SELECTIONS": 0,
"COMPANY_PERMISSIONS_PUNCHLISTS": 0,
"COMPANY_PERMISSIONS_LOGGING": 0,
"COMPANY_PERMISSIONS_RFI": 0,
"COMPANY_PERMISSIONS_BUDGETING": 0,
"COMPANY_PERMISSIONS_TRANSMITTAL": 0,
"COMPANY_PERMISSIONS_SUBMITTAL": 0,
"COMPANY_PERMISSIONS_REDLINE": 0,
"COMPANY_PERMISSIONS_LEADS": 0,
"COMPANY_PERMISSIONS_TIME": 0,
"COMPANY_PERMISSIONS_INBOUND_EMAILS": 0,
"COMPANY_PERMISSIONS_CHECKLISTS": 0,
"COMPANY_PERMISSIONS_SERVICECALLS": 0,
"COMPANY_PERMISSIONS_COSTBOOKS": 0,
"COMPANY_PERMISSIONS_INVOICING": 0,
"COMPANY_PERMISSIONS_MESSAGING": 0,
"COMPANY_PERMISSIONS_CLTL_SETTINGS": 0,
"IS_COMPANY_ADMIN": false,
"PREMIUM": "",
"MOBILETOKENS": "",
"SUBSCRIPTION": "",
"PREMIUM_TYPE": 0,
"FIELD": "Company",
"OFFLINE_FILES": null,
"FAVORITE_PROJECTS": null,
"DATE_FORMAT": 0,
"TIME_FORMAT": 0,
"TIMEZONE_ID": "America/Chicago",
"CONTACT_QUALITY": 0,
"CONTACT_REGION": 0,
"CONTACT_DIVISION": 0,
"CONTACT_OFFICE": 0,
"CONTACT_CATEGORY": 136524,
"CONTACT_TRADE": 0,
"FIELD_ID": null,
"MESSAGE_SIGNATURE": null,
"ISTRIAL": 0,
"GENERAL_CALENDAR_COLOR": "#dfecf5"
}
401 Unauthorized
The credentials entered were incorrect, in an invalid format, or failed to authenticate.
403 Forbidden
Read-only API key: write operations (POST/PUT/DELETE) not permitted.
404 Not Found
The server was not able to locate the resource specified in the request.
429 Too Many Requests
The user has surpassed the request rate limit for the hour, day, week, or month.
500: Error
There was an internal server error and the server was unable to complete the request.
Last updated: Nov 24, 2026