For the complete documentation index, see llms.txt. This page is also available as Markdown.

Sub-user places

Which of the master account's places a sub-user can see.

These operations set which places a sub-user can see. Places are scoped separately from trackers, so a sub-user's place list is bound here rather than following from their trackers.

Two list operations exist because they answer different questions: list_ids returns only the IDs, which is what a permissions screen needs, and list returns the place objects themselves.

API actions

API base path: /subuser/places.

Every operation on this page needs the multilevel_access tariff feature on all trackers, and the admin right, which is available only to master users. Failing either returns error 13 for the right and error 236 for the feature, so those two are not repeated per operation below.

Every operation here also returns error 201, Not found in the database, when the sub-user does not exist or belongs to another master user.


Bind places to sub-user

post
/subuser/places/bind

Give a sub-user access to places, either a named set or all of them.

Give either access_to_all or place_ids. A request with neither reports a missing parameter named has_at_least_one_parameter, which is the internal name of the validation group rather than a parameter you can send; it carries a message naming the two real choices.

Master users only, and the account needs the multilevel_access plan feature on all trackers. A sub-user calling this gets error 13, and an account without the feature gets error 236.

Requires the admin right.

Authorizations
AuthorizationstringRequired

Either a user session hash or an API key, with the "NVX " prefix, for example "NVX 22eac1c27af4be7b9d04da2ce1af111b". Obtain a session hash from the userAuth operation, or create an API key from the API keys operations. A small number of operations accept a session hash only and reject an API key with error code 4; each says so in its description.

Body
subuser_idinteger · min: 1Required

ID of a sub-user belonging to the current account.

access_to_allbooleanOptional

When true, the sub-user gets access to every place of the master account. Use this or place_ids.

place_idsinteger[]Optional

IDs of the places to associate with the sub-user. All must belong to the current master account. Use this or access_to_all.

Responses
200

Places bound

application/json
successbooleanRead-onlyOptional

true if request finished successfully.

Example: true
post/subuser/places/bind
POST /v2/subuser/places/bind HTTP/1.1
Host: api.eu.navixy.com
Authorization: YOUR_API_KEY
Content-Type: application/json
Accept: */*
Content-Length: 53

{
  "subuser_id": 1,
  "access_to_all": true,
  "place_ids": [
    1
  ]
}
{
  "success": true
}

Errors

These errors come in addition to the general error codes:

  • 13 - The caller is a sub-user.

  • 236 - The account lacks the multilevel_access feature.


Unbind places from sub-user

post
/subuser/places/unbind

Take away a sub-user's access to places.

Master users only, and the account needs the multilevel_access plan feature on all trackers. A sub-user calling this gets error 13, and an account without the feature gets error 236.

Requires the admin right.

Authorizations
AuthorizationstringRequired

Either a user session hash or an API key, with the "NVX " prefix, for example "NVX 22eac1c27af4be7b9d04da2ce1af111b". Obtain a session hash from the userAuth operation, or create an API key from the API keys operations. A small number of operations accept a session hash only and reject an API key with error code 4; each says so in its description.

Body
subuser_idinteger · min: 1Required

ID of a sub-user belonging to the current account.

place_idsinteger[]Required

IDs of the places to remove from the sub-user. All must belong to the current master account.

Responses
200

Places unbound

application/json
successbooleanRead-onlyOptional

true if request finished successfully.

Example: true
post/subuser/places/unbind
POST /v2/subuser/places/unbind HTTP/1.1
Host: api.eu.navixy.com
Authorization: YOUR_API_KEY
Content-Type: application/json
Accept: */*
Content-Length: 32

{
  "subuser_id": 1,
  "place_ids": [
    1
  ]
}
{
  "success": true
}

Errors

These errors come in addition to the general error codes:

  • 13 - The caller is a sub-user.

  • 236 - The account lacks the multilevel_access feature.


List sub-user place IDs

post
/subuser/places/list_ids

Return just the IDs of the places a sub-user can see.

Use subuser/places/list when you want the place objects themselves.

Master users only, and the account needs the multilevel_access plan feature on all trackers. A sub-user calling this gets error 13, and an account without the feature gets error 236.

Requires the admin right.

Authorizations
AuthorizationstringRequired

Either a user session hash or an API key, with the "NVX " prefix, for example "NVX 22eac1c27af4be7b9d04da2ce1af111b". Obtain a session hash from the userAuth operation, or create an API key from the API keys operations. A small number of operations accept a session hash only and reject an API key with error code 4; each says so in its description.

Body
subuser_idinteger · min: 1Required

ID of a sub-user belonging to the current account.

Responses
200

The place IDs in the sub-user's scope

application/json
successbooleanRead-onlyOptional

true if request finished successfully.

Example: true
listinteger[]Optional

IDs of the places available to the sub-user.

post/subuser/places/list_ids
POST /v2/subuser/places/list_ids HTTP/1.1
Host: api.eu.navixy.com
Authorization: YOUR_API_KEY
Content-Type: application/json
Accept: */*
Content-Length: 16

{
  "subuser_id": 1
}
{
  "success": true,
  "list": [
    1
  ]
}

Errors

These errors come in addition to the general error codes:

  • 13 - The caller is a sub-user.

  • 236 - The account lacks the multilevel_access feature.


List sub-user places

post
/subuser/places/list

Return the places a sub-user can see, as full place objects, with filtering and pagination.

Master users only, and the account needs the multilevel_access plan feature on all trackers. A sub-user calling this gets error 13, and an account without the feature gets error 236.

Requires the admin right.

Authorizations
AuthorizationstringRequired

Either a user session hash or an API key, with the "NVX " prefix, for example "NVX 22eac1c27af4be7b9d04da2ce1af111b". Obtain a session hash from the userAuth operation, or create an API key from the API keys operations. A small number of operations accept a session hash only and reject an API key with error code 4; each says so in its description.

Body
subuser_idinteger · min: 1Required

ID of a sub-user belonging to the current account.

filterstringOptional

Optional. Filter over place label, description, address, external ID and custom fields.

tag_idsinteger[]Optional

Optional. Tag IDs. A place must carry all the tags in the list to be returned.

orderstring · enumOptional

Optional. Default id. How to order the list.

Possible values:
limitintegerOptional

Optional. Maximum number of places to return.

offsetintegerOptional

Optional. Default 0. Offset into the results, for pagination.

Responses
200

The places in the sub-user's scope

application/json
successbooleanRead-onlyOptional

true if request finished successfully.

Example: true
post/subuser/places/list
POST /v2/subuser/places/list HTTP/1.1
Host: api.eu.navixy.com
Authorization: YOUR_API_KEY
Content-Type: application/json
Accept: */*
Content-Length: 80

{
  "subuser_id": 1,
  "filter": "text",
  "tag_ids": [
    1
  ],
  "order": "id",
  "limit": 1,
  "offset": 1
}
{
  "success": true,
  "list": [
    {
      "id": 1,
      "icon_id": null,
      "avatar_file_name": null,
      "location": {
        "lat": 1,
        "lng": 1,
        "address": "text",
        "radius": 1
      },
      "fields": {
        "ANY_ADDITIONAL_PROPERTY": "anything"
      },
      "label": "text",
      "description": null,
      "tags": [
        1
      ],
      "external_id": null,
      "files": [
        {
          "ANY_ADDITIONAL_PROPERTY": "anything"
        }
      ]
    }
  ]
}

Errors

These errors come in addition to the general error codes:

  • 13 - The caller is a sub-user.

  • 236 - The account lacks the multilevel_access feature.

Last updated

Was this helpful?