Territories are optionally included in Customer records and are used with Accounts Receivable reports. They can be useful for filtering and categorizing data, assuming your company has multiple territories.

NEW!


List Territories (Legacy)

get_list

<get_list object="territory" maxitems="10">
</get_list>

Parameters

Name Required Type Description
object Required string Use territory
start Optional integer Start at item, zero-based integer
maxitems Optional integer Max items to return
showprivate Optional boolean Show entity private records if running this at top level. Use either true or false. (Default: false)
filter Optonal object Filter(s) to use in list
sorts Optional sortfield[] Field(s) to sort by in response
fields Optional field[] Field(s) to return in response

filter

Name Required Type Description
logical Optional object Logical filter. Required if not using expression.
expression Optional object Expression filter. Required if not using logical.

logical

Name Required Type Description
logical_operator Required string Operator. Use either and or or.
object Optional string Object of operator
Logical Filter/Expression Required (logical | expression)[1...n] Additional logical objects or expressions to filter by

expression

Name Required Type Description
field Required string Field
operator Required string Operator
value Required string Value. Use either =, !=, <, <=, >=, >, like or is null.

sortfield

Name Required Type Description
order Required string Sort by order. Use either asc or desc.

Get Territory by Name (Legacy)

get

<get object="territory" key="NCAL-01">
</get>

Parameters

Name Required Type Description
object Required string Use territory
key Required string Object territoryid to get
fields Optional field[0...n] Field(s) to return in response

Create Territory (Legacy)

create_territory

<create_territory>
    <territoryid>NCAL-01</territoryid>
    <name>Northern CA Sacto</name>
    <parentid/>
    <managerid/>
    <status>active</status>
</create_territory>

Parameters

Name Required Type Description
territoryid Required string Territory ID
name Required string Name of territory
parentid Optional string Parent territory ID
managerid Optional string Employee ID for the territory manager
status Optional string Status, either active or inactive

Update Territory (Legacy)

update_territory

<update_territory territoryid="NCAL-01">
    <managerid>002</managerid>
</update_territory>

Parameters

Name Required Type Description
territoryid Required string Territory ID
name Optional string Name of territory
parentid Optional string Parent territory ID
managerid Optional string Employee ID for the territory manager
status Optional string Status, either active or inactive

Delete Territory (Legacy)

delete_territory

<delete_territory territoryid="NCAL-01"></delete_territory>

Parameters

Name Required Type Description
key Required string Territory ID to delete

Provide feedback