All Collections
Territory management
Territories: adding, editing properties, drawing and exporting shapes
Territories: adding, editing properties, drawing and exporting shapes

Learn how to create and delete a territory, update edit its properties and data fields, and export it as a GeoJSON file

Sergey Shurygin avatar
Written by Sergey Shurygin
Updated over a week ago

This article covers creating, updating and removing territories, as well as using the shape editor. For information about territory groups visit this article.

Adding a territory

To add a territory:

  • switch the right pane to Territories (by selecting it in the header selector):

  • press the Plus button on the right and select New territory:

  • fill in the territory properties in the Territory properties popup that will open.

Territory properties popup

The popup will open automatically when you're creating a new territory. To edit properties of an existing territory, hover your cursor over a territory and click the Pencil icon-button:

General properties

Name: a visible name of your territory.

Note. If this territory is part of a group with a defined name template, the actual visible name may include other text and data as defined by the template apart from the Name itself.

Code: a unique identifier of the territory across your Mapsly organization. The code is accessible in automation elements.

Territory group: select the territory group to which you'd like to add (or move) your territory. The group may have singificant influence on how your territory is visualized and managed. Learn more about territory groups.

Parent territory (optional): you may select another territory as the parent of your current territory - in this case your territory will appear under the parent territory in the list of territories on the Territory pane.

Note. The position of a territory in the territory hierarchy does not affect how records are assigned to territories, as during the auto-assignment each territory is treated as an independent territory defined by its own shape.

Mode: this field is available only when creating a new territory. Select whether you'd like to draw your territory by hand, or create it using the Mapsly geo-library. Once a territory is created, its mode cannot be modified.

Data fields

If the selected territory group has custom data fields, the Territory properties popup will show a Data fields section where you can edit threse fields:


Color: select whether the territory will inherit the group's default color or will have a fixed color. If you select the fixed color option, you can select the color, and it will take priority over the color settings of the group:

If you selected Geo-library as the territory's Mode, you may also adjust additional settings:

Border detail level: select whether to inherit the group's level of detail when rendering the territory's border or to override it and define a custom level for this territory:

Note. Increasing the border detail level may negatively impact the rendering speed of your territories.

Compound territory visualization: this setting has affect only if the territory is created by merging multiple geo-library regions (like zip codes), and specifies whether to display those component regions inside the territory or not. If you pick to show component areas, you can also specify whether you'd like their names (zip codes) to be shown as well or not. You may select whether to inherit this setting from the group's settings or to override it for this territory (by selecting Custom).

When you select Custom, choose the desired visualization mode (whether to show this territory as one territory or whether to show its components as well):

If you choose to show the territory's components, you may also specify whether to show their names or not:

Exporting a territory

If you open the Territory properties popup for a territory with a defined shape (no matter whether hand-drawn or created with geo-library), at the bottom of the popup you'll have an option to export the shape of this territory as a GeoJSON file:

Saving a new territory

When you're creating a new territory and click Save in the Territory properties popup, Mapsly will automatically invite you to create the shape of your territory:

You may exit the shape editor or geo-selector without defining a shape - in this case your territory will not be participating in the auto-assignment of records. You may create a shape for a such a territory later at any time.

Shape editor (drawing a territory by hand)

For a new territory the shape editor will open automatically when you press Save in the Territory properties popup.

For existing territories you may open it to edit their shape by hovering your cursor over the territory and clicking the Polygon icon-button:

Drawing tools

Mapsly currently offers 4 drawing tools to draw features (shape primitives):

  • Line

  • Polygon

  • Rectangle

  • Circle

A territory's shape may contain one or multiple features at once.

Note. A Line feature does not have an square and thus does not affect auto-assignment of records.

Click on a tool to create a feature.

Drawing a polygon or a line

After you select the Polygon tool, you can start placing handles (base points) that will form your polygon. You may have any number of such points. While you're drawing, Mapsly will be showing you the square of your polyhon shape.

To finish drawing, click on the first handle to "close" the figure, or click Finish in the tool menu:

Editing a primitive

To edit an existing primitive:

  • click Edit here:

  • and drag handles of your features to adjust their shape.

When finished editing, click Save shape in the edit tool menu:

Editing a polygon or a line

When editing a polygon or a line, you may add more handles to your shape by clicking and dragging semi-transparent handles located between every two existing handles:

To remove an existing handle from a feature, simply single-click the handle.

Deleting a feature from the territory shape

To remove a feature:

  • click the Delete tool here:

  • and then click the feature(s) you're like to remove:

When you're done removing features, press Save shape in the Delete tool's menu:

Saving your territory's shape

When you're done creating primitives, click Save territory on TOP of your screen to save the territory's shape:

Or click Cancel to exit the Shape editor without saving your changes.

Did this answer your question?