Untitled Page
API Overview
Example
Customers  
Companies  
Technicians  
Technician Groups  
Tickets  
Ticket History  
Ticket Attachments  
Billing Line Items  
Billing Invoices  
Time Tracking  
Knowledge Base Articles  
Scheduling  
Asset Managements  
 
get_asset_fields
Input Variable Input Value Description
id Integer value A valid asset field ID.
label String value A valid asset field label to limit the returned values by. You may use * as a wildcard.
start_name String value This can be a single letter or the first few letters of a field label. The returned records will have a field label that starts with this value and go to the last record, unless you include the end_name and/or count variables. Example: If you include start_name=j in your request, only records with a field label starting with j or later in the alphabet will be returned.
end_name String value This can be a single letter or the first few letters of a company name. The returned records will stop at records that have a field label that starts with this value. It can be used in conjunction with start_name or alone. When used alone the returned records will start with first record in the database. Example: If you include end_name=j in your request, only records with a field label starting with j or earlier in the alphabet will be returned.
count Integer value This would be the number of records to return.
count_only String value Defines whether or not to return only the number of records. This is used in conjunction with the "page" variable or just to get the total number of records. Accepted values are "N" and "Y" (without the quotes). The default value is "N", and if this variable is excluded the detailed data is returned.
page Integer value This would be the number of the "page" of records to return. You must use a wildcard like "id=*" or "field_label=*" to get paged records, and you must also include the "count" variable". Example: &id=*&count=10&page=1.
order String value Defines the sort order of the returned records. You will need to examine the database to determine the exact field names to sort by. You may also include " ASC" (ascending) and " DESC" (descending) in the value for the sort direction (note the precedding blank space). For example, to sort by ID in descending order you would include the following in the URL: &order=ID DESC. You can optionally include the "order_direction" variable separately.
order_direction String value Defines the sort order direction of the returned records. Accepted values are "ASC" (ascending) and "DESC" (descending). The default value is "ASC". For example, to sort by ID in descending order you would include the following in the URL: &order=ID&order_direction=DESC.

Output Variable URL Encoded Description
id No Unique ID of the asset field.
label Yes The field label.
type No The field type. Possible return values are "text", "textarea" and "list" (without the quotes).
size No The size of the field. There will only be a value if the field type is "text".
max_size No The maximum size of the field. There will only be a value if the field type is "text".
rows No The number of rows of the field. There will only be a value if the field type is "textarea".
columns No The number of columns of the field. There will only be a value if the field type is "textarea".
visible No The visibility of property of the field. Possible return values are "" (blank) and "visible" (without the quotes).
required No Denotes if the field is required. Possible return values are "N" and "Y" (without the quotes).
customer_viewable No Denotes if the field is visible in the customer portal. Possible return values are "N" and "Y" (without the quotes).
data_type No The data type of the field. Possible return values are "Text", "Number", "Decimal", "Date/Time" and "Large Text" (without the quotes).
default_state No The default visibility state of the field. Possible return values are "" (blank) and "visible" (without the quotes).
display_in_overview No Denotes if the field is displayed in the overview. Possible return values are "N" and "Y" (witohut the quotes).
position No The vertical position of the field on the add/edit asset forms.
values Yes The values of the field. There will only be a value if the field type is "list".
Example Usage
http://localhost/API/default.aspx?key=your key here&action=get_asset_fields&cid=*
Example Response
XML:
<?xml version="1.0"?>
<asset_fields>
	<field>
		<id>1</id>
		<label>Field Label 1</label>
		<type>text</type>
		<size>20</size>
		<max_size>20</max_size>
		<rows>0</rows>
		<columns>0</columns>
		<field_visible></field_visible>
		<customer_viewable>Y</customer_viewable>
		<data_type>text</data_type>
		<default_state></default_state>
		<display_in_overview>Y</display_in_overview>
		<position>1</position>
		<values></values>
	</field>
</asset_fields>
JSON:
{
	"asset_fields": [
		{
			"id" : "1",
			"field_label" : "Field Label 1",
			"type" : "text",
			"size" : "20",
			"max_size" : "20",
			"rows" : "0",
			"columns" : "0",
			"field_visible" : "",
			"customer_viewable" : "Y",
			"data_type" : "text",
			"default_state" : "",
			"display_in_overview" : "Y",
			"position" : "1",
			"values" : ""
		}
	]
}
URL DELIMITED:
id=1&label=Field Label 1&type=text&size=20&max_size=20&rows=0&columns=0&visible=&required=
&customer_viewable=Y&data_type=--&default_state=&display_in_overview=Y&position=1&values=