Geo objects
Complete reference for geo objects: queries, mutations, and types for geofences, points of interest, and routes with GeoJSON geometry.
Geo objects define geographic boundaries and points of interest - geofences, routes, and landmarks used for location-based automation.
Queries
geoObjectTypes
Lists geo object types in the caller's workspace.
geoObjectTypes(
filter: CatalogItemFilter
first: Int
after: String
last: Int
before: String
orderBy: CatalogItemOrder = { field: ORDER, direction: ASC }
): GeoObjectTypeConnection!Arguments
filter
CatalogItemFilter
Filtering options for the returned geo object types.
orderBy
CatalogItemOrder
The ordering options for the returned geo object types.
Input types:
Output types:
geoObject (query)
Retrieves a geo object by its ID.
Arguments
id
ID!
The ID of the geo object to retrieve.
Output types:
geoObjects
Lists geo objects in the caller's workspace.
Arguments
filter
GeoObjectFilter
Filtering options for the returned geo objects.
orderBy
GeoObjectOrder
The ordering options for the returned geo objects.
Input types:
Output types:
Mutations
geoObjectCreate
Creates a new geo object.
Arguments
input
GeoObjectCreateInput!
The input fields for creating the geo object.
Input types:
Output types:
geoObjectUpdate
Updates an existing geo object.
Arguments
input
GeoObjectUpdateInput!
The input fields for updating the geo object.
Input types:
Output types:
geoObjectDelete
Deletes a geo object.
Refused with IN_USE while another live entity points at it through one of its own fields, custom-field values and field definitions included; the error's blockers name the first five of them, and hasMoreBlockers says whether it left any out.
Arguments
input
GeoObjectDeleteInput!
The input fields for deleting the geo object.
Input types:
Output types:
geoObjectTypeCreate
Creates a new geo object type.
Arguments
input
GeoObjectTypeCreateInput!
The input fields for creating the geo object type.
Input types:
Output types:
geoObjectTypeUpdate
Updates a geo object type.
Arguments
input
GeoObjectTypeUpdateInput!
The input fields for updating the geo object type.
Input types:
Output types:
geoObjectTypeDelete
Deletes a geo object type.
Refused with IN_USE while another live entity points at it through one of its own fields, custom-field values and field definitions included; the error's blockers name the first five of them, and hasMoreBlockers says whether it left any out.
Arguments
input
CatalogItemDeleteInput!
The input fields for deleting the geo object type.
Input types:
Output types:
Objects
GeoObjectType
A classification type for geographic objects.
Implements: CatalogItem, Node, Versioned, Titled
id
ID!
A globally unique identifier.
version
Int!
The version number for optimistic locking.
title
String!
The human-readable display name. Can be localized.
code
Code!
A machine-readable code, unique within the catalog for a given workspace. A workspace item may reuse the code of the system item it overrides.
order
Int!
The display order within the same level or category.
customFieldDefinitions
Custom field definitions specific to this geo object type, ordered by display order.
GeoPoint
A geographic coordinate point.
GeoObject
A geographic object such as a geofence, point of interest, or route.
Implements: Node, Titled, Customizable, Versioned
id
ID!
A globally unique identifier. This ID is opaque and should not be parsed by clients.
version
Int!
The version number for optimistic locking. Incremented on each update. Can be provided in update/delete mutations to prevent lost updates. If omitted, the update proceeds without stale-read protection.
title
String!
The human-readable display name.
containsPoint
Boolean!
Whether this geo object's area covers the point: the point lies inside the area or on its boundary, and not inside a hole (a hole's boundary counts as covered). Edges are straight lines in longitude and latitude. The area is the geojsonData geometry when it's a well-formed Polygon or MultiPolygon. Any other geometry has no area, and the field returns false.
customFields
[CustomFieldValue!]!
Typed custom field values, one entry per set field code. Each element is a concrete CustomFieldValue implementation matching the field's FieldType — select fields via inline fragments. The system-reserved code geojson_data is excluded — it is exposed through GeoObject.geojsonData instead.
Arguments of containsPoint
Arguments of customFields
GeoObjectPayload
The result of a geo object mutation.
GeoObjectTypePayload
The result of a geo object type mutation.
Inputs
GeoPointInput
A point to test against geo object areas: WGS 84 latitude and longitude in decimal degrees. Longitude 180 and -180 are different points.
GeoObjectFilter
Filtering options for geo objects.
typeIds
[ID!]
Filter by geo object types (OR within field).
titleContains
String
Partial match on title (case-insensitive contains).
customFields
Filter by custom field values. Unlike the ID list filter above, the conditions in this list combine with AND: a geo object must satisfy every one of them. See CustomFieldFilter for how a single condition matches.
containsPoint
Only geo objects whose area covers this point, as GeoObject.containsPoint answers it. A geo object without an area (a geometry other than a well-formed Polygon or MultiPolygon) never matches.
GeoObjectOrder
Ordering options for geo objects.
customFieldCode
The custom field code to order by. Mutually exclusive with field. Supported field types: STRING, DECIMAL, INTEGER, DATE, DATETIME, and the reference types DEVICE and single-value REFERENCE, which sort by the title of the entity they point at rather than by the stored id. TEXT, OPTIONS, BOOLEAN and GEOJSON are not supported for sorting, nor is a multi-value REFERENCE or a REFERENCE at an entity with no title.
GeoObjectCreateInput
Input for creating a new geo object.
typeId
ID!
The geo object type ID.
title
String!
The geo object display name.
geojsonData
The GeoJSON geometry. A Polygon or MultiPolygon must be a well-formed area, or the mutation fails with VALIDATION_ERROR on input.geojsonData: a Polygon is a non-empty array of rings, a MultiPolygon a non-empty array of such polygons; a ring has at least four positions, and its first and last positions have equal longitude and latitude; a position has at least two elements, all numbers, with longitude in [-180, 180] and latitude in [-90, 90]. Elements after the second (altitude) and a crs member do not change the area; ring winding is not checked.
GeoObjectUpdateInput
Input for updating an existing geo object.
id
ID!
The geo object ID to update.
version
Int
The current version for optimistic locking. If omitted, auto-increments without conflict check.
title
String
The new display name.
geojsonData
The new geometry; omitted keeps the stored one. A Polygon or MultiPolygon must be a well-formed area, as GeoObjectCreateInput.geojsonData states.
GeoObjectDeleteInput
Input for deleting a geo object.
id
ID!
The geo object ID to delete.
version
Int
The current version for optimistic locking. If omitted, auto-increments without conflict check.
GeoObjectTypeCreateInput
Input for creating a geo object type.
title
String!
The display name.
order
Int
The display order. Auto-calculated as last position if omitted.
customFieldDefinitions
Operations on custom field definitions for this geo object type. Only create is allowed when creating a new catalog item.
GeoObjectTypeUpdateInput
Input for updating a geo object type.
id
ID!
The item ID to update.
version
Int
The current version for optimistic locking. If omitted, auto-increments without conflict check.
title
String
The new display name.
order
Int
The new display order.
customFieldDefinitions
Operations on custom field definitions belonging to this geo object type.
Enums
GeoObjectOrderField
Fields available for ordering geo objects.
TITLE
Order by title.
GeoJsonGeometryType
The type of GeoJSON geometry.
POINT
A single geographic point.
MULTI_POINT
A collection of points.
LINE_STRING
A sequence of connected line segments.
MULTI_LINE_STRING
A collection of line strings.
POLYGON
A closed shape defined by a linear ring.
MULTI_POLYGON
A collection of polygons.
GEOMETRY_COLLECTION
A heterogeneous collection of geometry objects.
Pagination types
GeoObjectConnection
A paginated list of GeoObject items.
Implements: Connection
GeoObjectEdge
An edge in the GeoObject connection.
Implements: Edge
cursor
String!
An opaque cursor for this edge.
GeoObjectTypeConnection
A paginated list of GeoObjectType items.
Implements: Connection
GeoObjectTypeEdge
An edge in the GeoObjectType connection.
Implements: Edge
cursor
String!
An opaque cursor for this edge.
See also
Last updated
Was this helpful?