Skip to content

updateDirectoryContactForUser ​

Updates a User's own Contact record within a given Company's Directory. hide in the context below means that the User wishes the particular field to be hidden from others viewing it in the Directory.

Request ​

http
PUT /rest/smartdirectory/{smartDirectoryUUID}/contactRecord

Headers ​

HeaderRequiredDescription
x-nextinteract-authtokenYesAuth token returned from loginUser

Parameters ​

smartDirectoryUUID - path parameter. UUID of the Smart Directory as set up in SAM.

REQUEST BODY:

json
{
    {
    "fields" : [
        {
            "id" : 36,
            "name" : "contactFirstName",
            "value" : "Updated First Name",
            "hide" : "N",
            "type": "text"
        },
        {
            "id": 33,
            "name": "contactLastname",
            "value": "Update Last Name",
            "hide": "N",
            "type": "text"
        }
    ],
    "addresses": [
        {
            "uuid": null,
            "type": "Work",
            "typeCode": "W",
            "name": "Address 1 Name",
            "street": "Address 1 Street",
            "city": "Address 1 City",
            "suburb": null,
            "stateCode": "AU-NSW",
            "state": "New South Wales",
            "postcode": "2000",
            "countryCode": "AU",
            "country": "AUSTRALIA",
            "email": null,
            "phone": "1234567",
            "fax": "1234567",
            "mobile": "1234567",
            "department": "Address 1 Department",
            "division": null,
            "jobTitle": "Address 1 Job Title"
        }
    ]
    }
}

Response ​

200 OK ​

json
{
    {
    "fields" : [
        {
            "id" : 36,
            "name" : "contactFirstName",
            "value" : "Updated First Name",
            "hide" : "N",
            "type": "text"
        },
        {
            "id": 33,
            "name": "contactLastname",
            "value": "Update Last Name",
            "hide": "N",
            "type": "text"
        }
    ],
    "addresses": [
        {
            "uuid": null,
            "type": "Work",
            "typeCode": "W",
            "name": "Address 1 Name",
            "street": "Address 1 Street",
            "city": "Address 1 City",
            "suburb": null,
            "stateCode": "AU-NSW",
            "state": "New South Wales",
            "postcode": "2000",
            "countryCode": "AU",
            "country": "AUSTRALIA",
            "email": null,
            "phone": "1234567",
            "fax": "1234567",
            "mobile": "1234567",
            "department": "Address 1 Department",
            "division": null,
            "jobTitle": "Address 1 Job Title"
        }
    ]
    }
}

Errors ​

ExceptionDescription
WSInvalidAuthTokenExceptionSee Error Definitions
WSCacheServiceExceptionSee Error Definitions
WSInvalidParameterExceptionSee Error Definitions
WSSmartDirectoryNotFoundExceptionSee Error Definitions
WSSmartDirectoryServiceExceptioSee Error Definitions
WSSmartDirectoryNotEnabledForCompanyExceptionSee Error Definitions
WSUserContactNotFoundExceptionSee Error Definitions
WSUserNotInSmartDirectoryExceptionSee Error Definitions