Sub-Accounts (Contacts)

Each Account can have multiple permissioned users on the account. These sub-users are called sub-accounts. Sub-Accounts are uniquely identified by their email and account.

Adding Sub-Accounts

Additional team members can be added as sub-accounts in your control panel by clicking the gravatar in the upper right corner and selecting account users.

When created from the portal, the sub-account will receive an email prompting them to set their password. After their password is set, they can access the account.

682

You can also create a sub-account by making a POST request to /contact.

curl -X 'POST' \
  'https://core.hivelocity.net/api/v2/contact/' \
  -H 'accept: application/json' \
  -H "X-API-KEY: $API_KEY" \
  -H 'Content-Type: application/json' \
  -d '{
      "description": "IT Manager",
      "phone": "81355555555",
      "email": "[email protected]",
      "fullName": "John Snow",
      "password": "SecurePassword",
      "active": 1
}'

Sharing Sub-Accounts across Accounts

If you manage multiple accounts, you may create sub-accounts with the same email address across those accounts. When you authenticate to the myVelocity portal, you will be prompted to select which sub-account's portal you would like to manage:

1260

πŸ“˜

Controlled Accounts can also share emails

Normally, accounts cannot share emails. If you are a multi account reseller then you can give your controlled accounts the same email address as your primary account.

Permissions

Granular permissions can be modified for each individual sub-account. New sub-accounts have no permissions by default. The permissions granted apply to both portal and API access. You can update a sub-account's permissions by navigating to account users and clicking edit contact on the sub-account you wish to modify.

You can also modify contact permissions with a POST request to the /permission/contact endpoint. The permissions fields must be filled with the keys returned from a GET request to /permission.

Via the API

Getting available permissions from the API

curl -X 'GET' \
  'https://core.hivelocity.net/api/v2/permission/' \
  -H 'accept: application/json' \
  -H "X-API-KEY: $API_KEY"

Getting a user's permissions from the API

curl -X 'GET' \
  'https://core.hivelocity.net/api/v2/permission/contact/$CONTACT_ID' \
  -H 'accept: application/json' \
  -H "X-API-KEY: $API_KEY"

Adding Permissions via the API

curl -X 'POST' \
  'https://core.hivelocity.net/api/v2/permission/contact' \
  -H 'accept: application/json' \
  -H "X-API-KEY: $API_KEY" \
  -H 'Content-Type: application/json' \
  -d '{
  "userId": $CONTACT_ID,
  "permissions": [
    "devices.deploy"
  ]
}'

For more info on managing permissions programmatically, see the Permission API Reference.

Locking Permissions

A sub-account's permissions can be locked and unlocked by the account. Once locked, no other sub-account can modify the locked sub-account's permissions. If a sub-account has permission to update other sub-account's permissions, it is recommended the account lock the sub-account with the permissions to grant.

To lock a sub-account's permission, navigate to account users, click edit contact on the sub-account you wish to lock, then check the box with a lock icon next to permissions.

Permission Groups

For sub-accounts that require identical permissions, permission groups can be created once with the required permissions. Then the group can be assigned to the appropriate sub-accounts.

To create a permissions group, navigate to account users and click Manage Permissions Groups.


What’s Next