Skip to main content

Accounts

Get your account details

To get detailed information about your organization account, use this code:

curl \
  --request GET \
  --url 'https://api.hl2.com/panorama/v1/account'

The response JSON looks like the following (the order of the fields may vary):

{
  "name": "Organization name",
  "username": "organization",
  "email": "org@org.com",
  "gravatarURL": "https://s.gravatar.com/avatar/b94308dd4591117626fd18796073be44",
  "type": "organization",
  "createdAt": "2017-12-01T16:16:25.984Z",
  "updatedAt": "2017-12-01T16:16:25.984Z",
  "disabled": false,
  "id": "5a21805903e0870010c8f618"
}

The value of the id field is important : it is the unique identifier for your organization in the system. You will need to pass this value to certain endpoints, either in the URL or as a payload field.

Update your account details

Update your organization account information.

PUT /account

Input

Name Type Description
email string The new email for your organization (required)
username string The new username for your organization (required)
name string The new display name for your organization
curl \
  --request PUT \
  --url 'https://api.hl2.com/panorama/v1/account' \
  --header 'Content-Type: application/json' \
  --data '{
    "email": "myorg@example.com",
    "username": "my-org",
    "name": "My org"
  }'

Response

The response array looks like the following:

{
    "email": "myorg@example.com",
    "username": "my-org",
    "name": "My org",
    "type": "organization",
    "createdAt": "2017-11-14T12:00:46.146Z",
    "gravatarURL": "https://s.gravatar.com/avatar/98a276343a345d4824184d05a353496a",
    "updatedAt": "2017-11-23T09:17:55.624Z",
    "disabled": false,
    "id": "58a6e83030aacc000e29a454"
}

List all user accounts

List all the active users of the HL2 Panorama platform, or search for one using their name or username.

This is useful to figure out their IDs to add them to your organization using the “Add member” endpoint:

GET /accounts

Parameters

Name Type Default Description
limit number 10 The number of items to be returned by page
page number 1 The page number
q string   The search regex in username and name fields
sort string   The sort order
ids array   The list of account identifiers
curl \
  --request GET \
  --url 'https://api.hl2.com/panorama/v1/accounts'

Response

The response array looks like the following (the order of the fields may vary):

[
    {
        "username": "username1",
        "type": "user",
        "gravatarURL": "https://s.gravatar.com/avatar/94a452b39de8adea79901bcac3c5811e",
        "id": "5a0568cccaecf49fa28f1d52"
    },
    {
        "username": "username2",
        "name": "User 2",
        "type": "user",
        "gravatarURL": "https://s.gravatar.com/avatar/d6876db345533776f49d4496880212ae",
        "id": "5a0568cccaecf49fa28f1d62"
    }
]