For full details of this API Endpoint, see Locations API.
type
-
Data Type: String
-
Required Field: No
Notes:
Options: “ADDRESS”, “CONTACT”, “SERVICING_EQUIPMENT”, “SERVICE_HOST”, “WORKER”, “REMARK”, “UDF”, and “ATTACHMENT”
location_recid
-
Data Type: String
-
Required Field: Yes*
-
Required Type: none, “CONTACT”, “SERVICING_EQUIPMENT”, “WORKER”, “REMARK”, “UDF”, or “ATTACHMENT”
Notes:
The recid of the Location.
*only required for Updates
parent_location_recid
-
Data Type: Integer
-
Required Field: No
Notes:
The recid of the Location’s parent Location
name
-
Data Type: String
-
Required Field: Yes*
Notes:
The Name of the building.
*only required for New records
status
-
Data Type: Integer
-
Required Field: Yes
-
Default Value: 1
Notes:
“1” for Active, “0” for Inactive
location_type
-
Data Type: String
-
Required Field: Yes*
Notes:
Any LOCATION_TYPE List Code for the Location.
*only required for New records
latitude
-
Data Type: Decimal
-
Required Field: No
Notes:
The latitude of the Location
longitude
-
Data Type: Decimal
-
Required Field: No
Notes:
The longitude of the Location
warehouse
-
Data Type: Integer
-
Required Field: No
-
Default Value: 0
Notes:
Is this a Warehouse? “1” for Yes, “0” for No.
report_911
-
Data Type: Integer
-
Required Field: No
-
Default Value: 0
Notes:
Is this a Location to report for Emergency 911? “1” for Yes, “0” for No.
house_number
-
Data Type: String
-
Required Field: No*
-
Required Type: “ADDRESS”
-
Default Value: NULL
Notes:
*required if report_911 is “1”.
house_suffix
-
Data Type: String
-
Required Field: No*
-
Required Type: “ADDRESS”
-
Default Value: NULL
Notes:
*required if report_911 is “1”.
prefix_directional
-
Data Type: String
-
Required Field: No*
-
Required Type: “ADDRESS”
-
Default Value: NULL
Notes:
*required if report_911 is “1”.
street_name
-
Data Type: String
-
Required Field: No*
-
Required Type: “ADDRESS”
-
Default Value: NULL
Notes:
*required if report_911 is “1”.
street_suffix
-
Data Type: String
-
Required Field: No*
-
Required Type: “ADDRESS”
-
Default Value: NULL
Notes:
*required if report_911 is “1”.
post_direction
-
Data Type: String
-
Required Field: “No*”
-
Required Type: “ADDRESS”
-
Default Value: NULL
Notes:
*required if report_911 is “1”.
default_warehouse_recid
-
Data Type: Integer
-
Required Field: No
Notes:
The recid for the default Warehosue
default_return_warehouse_recid
-
Data Type: Integer
-
Required Field: No
Notes:
The recid for the default Warehosue for Returns
building_type
-
Data Type: String
-
Required Field: Yes
-
Required Type: “ADDRESS”
Notes:
The Building’s Type recid as defined by the LISTS Table for Building Types
community_name
-
Data Type: String
-
Required Field: Yes
-
Required Type: “ADDRESS”
Notes:
The Community Name
street_address
-
Data Type: String
-
Required Field: Yes
-
Required Type: “ADDRESS”
Notes:
First Line of the Address
address2
-
Data Type: String
-
Required Field: Yes
-
Required Type: “ADDRESS”
Notes:
Second Line of the Address
city
-
Data Type: String
-
Required Field: Yes
-
Required Type: “ADDRESS”
Notes:
The City
state
-
Data Type: String
-
Required Field: Yes
-
Required Type: “ADDRESS”
Notes:
The full name or two-letter abbreviation for the State.
zip_code
-
Data Type: String
-
Required Field: Yes
-
Required Type: “ADDRESS”
Notes:
The 5-digit zip code
country
-
Data Type: String
-
Required Field: Yes
-
Required Type: “ADDRESS”
Notes:
The ADDRESS_COUNTIES
List Code for the Country.
contact_recid
-
Data Type: Integer
-
Required Field: Yes
-
Required Type: “CONTACT” or “WOARKER”
Notes:
The recid of the Contact.
service_catalog_recid
-
Data Type: Integer
-
Required Field: Yes
-
Required Type: “SERVICING_EQUIPMENT”
Notes:
The recid of the Service Catalog.
equipment_recid
-
Data Type: Integer
-
Required Field: Yes
-
Required Type: “SERVICING_EQUIPMENT”
Notes:
The recid of the Equipment record
service_host_recid
-
Data Type: Integer
-
Required Field: Yes
-
Required Type: “SERVICE_HOST”
Notes:
The recid of the Service Host
remark
-
Data Type: String
-
Required Field: Yes
-
Required Type: “REMARK”
Notes:
The Remark to be added.
author_contact_recid
-
Data Type: Integer
-
Required Field: Yes
-
Required Type: “REMARK”
Notes:
The recid of the author making the Remark, as defined in the Contact Table.
udf_UDF-RECID
-
Data Type: String
-
Required Field: Yes*
-
Required Type: “UDF”
Notes:
*Conditionally required if “udf_UDF-IDENTIFIER” is not provided
udf_UDF-IDENTIFIER
-
Data Type: String
-
Required Field: Yes*
-
Required Type: “UDF”
Notes:
*Conditionally required if “udf_UDF-RECID” not provided
filename
-
Data Type: String
-
Required Field: Yes
-
Required Type: “ATTACHMENT”
Notes:
The File Name
data
-
Data Type: String
-
Required Field: Yes
-
Required Type: “ATTACHMENT”
Notes:
Base64 Encoded Text
Add New Location Example
$params = [
"name" => "Example Building",
"status" => 1,
"location_type" => "BUILDING"
];
$api_call = $this->call('saveLocation', $params, true)
Update Location Address Example
$params = [
"type" => "ADDRESS",
"street_address" => “555 Nowhere Ave”,
"city" => “Grand Rapids”,
"state" => “MI”,
"zip_code" => “55555”
];
$api_call = $this->call('saveLocation', $params, true)
Add New Contact to Location Example
$params = [
"type" => “CONTACT”,
"contact_recid" => 1
];
$api_call = $this->call('saveLocation', $params, true)
Update Location Servicing Equipment Example
$params = [
"type" => “SERVICING_EQUIPMENT”,
"service_catalog_recid" => 1,
"equipment_recid" => 1
];
$api_call = $this->call('saveLocation', $params, true)
Update Location Service Host Example
$params = [
"type" => “SERVICE_HOST”,
"service_host_recid" => 1
];
$api_call = $this->call('saveLocation', $params, true)
Update Location Worker Example
$params = [
"type" => “WORKER”,
"contact_recid" => 1
];
$api_call = $this->call('saveLocation', $params, true)
Add New Remark to Location Example
$params = [
"type" => “REMARK”,
"remark" => "This is an Example Remark",
"author_contact_recid" => 1
];
$api_call = $this->call('saveLocation', $params, true)
Update UDFs on Location Example
$params = [
"type" => “UDF”,
"udf_1" => "UDF 1 Value",
"udf_two" => "UDF 2 Value"
];
$api_call = $this->call('saveLocation', $params, true)
Add New Attachment to Location Example
$params = [
"type" => “ATTACHMENT”,
"filename" => "File Name",
"data" => "iVBORw0KGgoAAAANSUhEUgAAACQAAAAjCAYAAAD8BaggAAAAAXNSR0IArs4c6QAAAARnQU1BAACxjwv8YQUAAAAJcEhZcwAAEnQAABJ0Ad5mH3gAAAuSSURBVFhH1ZdpUNv3mccBcyMJIYQkBBIChLgE4j7NJXHfGPCFjR1jx1d8BOLY4BsfsTEONmnS"
];
$api_call = $this->call('saveLocation', $params, true)