Portal users API


POST /api/v1/idea_portals/:idea_portal_id/portal_users

Create a portal user

Parameters

Name Description
idea_portal_id * Numeric ID, or key of the idea portal to get portal users for
email * Email address of the portal user, The email address does not need to be of a user of Aha!
first_name First name of the portal user
last_name Last name of the portal user
permission Whether the portal user is an employee/partner. Must be 'true' or 'false'
enabled Whether the portal user is active. Must be 'true' or 'false'

POST /api/v1/idea_portals/1070474755/portal_users

Example CURL command

curl "https://secure.aha.io/api/v1/idea_portals/1070474755/portal_users" -d '{"portal_user":{"email":"sam.doe@example.com","first_name":"sam","last_name":"doe"}}' -X POST \
	-H "Authorization: Bearer 584b6d6b83405011f8c6903d2379f4afdf824cef867db391b7bcb5995f603a76" \
	-H "X-Aha-Account: account1" \
	-H "Content-Type: application/json" \
	-H "Accept: application/json"

Request

Authorization: Bearer 584b6d6b83405011f8c6903d2379f4afdf824cef867db391b7bcb5995f603a76
X-Aha-Account: account1
Content-Type: application/json
Accept: application/json
{
  "portal_user": {
    "email": "sam.doe@example.com",
    "first_name": "sam",
    "last_name": "doe"
  }
}

Response

Status: 200 OK
  Content-Type: application/json; charset=utf-8
{
  "portal_user": {
    "id": "6477599787524182608",
    "email": "sam.doe@example.com",
    "first_name": "sam",
    "last_name": "doe",
    "enabled": true,
    "verified": false,
    "employee": false,
    "created_at": "2017-10-16T19:55:27.860Z"
  }
}

POST /api/v1/idea_portals/:idea_portal_id/portal_users

Create a portal user with employee permissions

Parameters

Name Description
idea_portal_id * Numeric ID, or key of the idea portal to get portal users for
email * Email address of the portal user, The email address does not need to be of a user of Aha!
first_name First name of the portal user
last_name Last name of the portal user
permission Whether the portal user is an employee/partner. Must be 'true' or 'false'
enabled Whether the portal user is active. Must be 'true' or 'false'

POST /api/v1/idea_portals/1070474755/portal_users

Example CURL command

curl "https://secure.aha.io/api/v1/idea_portals/1070474755/portal_users" -d '{"portal_user":{"email":"sam.doe@example.com","first_name":"sam","last_name":"doe","permission":"employee"}}' -X POST \
	-H "Authorization: Bearer 584b6d6b83405011f8c6903d2379f4afdf824cef867db391b7bcb5995f603a76" \
	-H "X-Aha-Account: account1" \
	-H "Content-Type: application/json" \
	-H "Accept: application/json"

Request

Authorization: Bearer 584b6d6b83405011f8c6903d2379f4afdf824cef867db391b7bcb5995f603a76
X-Aha-Account: account1
Content-Type: application/json
Accept: application/json
{
  "portal_user": {
    "email": "sam.doe@example.com",
    "first_name": "sam",
    "last_name": "doe",
    "permission": "employee"
  }
}

Response

Status: 200 OK
  Content-Type: application/json; charset=utf-8
{
  "portal_user": {
    "id": "6477599788573171915",
    "email": "sam.doe@example.com",
    "first_name": "sam",
    "last_name": "doe",
    "enabled": true,
    "verified": false,
    "employee": true,
    "created_at": "2017-10-16T19:55:28.106Z"
  }
}

GET /api/v1/idea_portals/:idea_portal_id/portal_users

Get all portal users for a product

Parameters

Name Description
idea_portal_id * Numeric ID, or key of the idea portal to get portal users for

GET /api/v1/idea_portals/1070474755/portal_users

Example CURL command

curl -g "https://secure.aha.io/api/v1/idea_portals/1070474755/portal_users" -X GET \
	-H "Authorization: Bearer 584b6d6b83405011f8c6903d2379f4afdf824cef867db391b7bcb5995f603a76" \
	-H "X-Aha-Account: account1" \
	-H "Content-Type: application/json" \
	-H "Accept: application/json"

Request

Authorization: Bearer 584b6d6b83405011f8c6903d2379f4afdf824cef867db391b7bcb5995f603a76
X-Aha-Account: account1
Content-Type: application/json
Accept: application/json

Response

Status: 200 OK
  Content-Type: application/json; charset=utf-8
{
  "portal_users": [
    {
      "id": "144817500",
      "email": "timmy@smith.com",
      "first_name": "Timmy",
      "last_name": "Smith",
      "enabled": true,
      "verified": true,
      "employee": true,
      "created_at": "2017-10-16T19:54:35.000Z"
    },
    {
      "id": "646391926",
      "email": "john@long.com",
      "first_name": "John",
      "last_name": "Long",
      "enabled": true,
      "verified": false,
      "employee": false,
      "created_at": "2017-10-16T19:54:35.000Z"
    },
    {
      "id": "1066301902",
      "email": "tim@smith.com",
      "first_name": "Tim",
      "last_name": "Smith",
      "enabled": true,
      "verified": false,
      "employee": false,
      "created_at": "2017-10-16T19:54:35.000Z"
    }
  ],
  "pagination": {
    "total_records": 3,
    "total_pages": 1,
    "current_page": 1
  }
}

GET /api/v1/idea_portals/:idea_portal_id/portal_users

Get all portal users whose email address contains a string

Parameters

Name Description
idea_portal_id * Numeric ID, or key of the idea portal to get portal users for
email Email address (or part of an email address) to search by

GET /api/v1/idea_portals/1070474755/portal_users?email=john%40long.com

Example CURL command

curl -g "https://secure.aha.io/api/v1/idea_portals/1070474755/portal_users?email=john%40long.com" -X GET \
	-H "Authorization: Bearer 584b6d6b83405011f8c6903d2379f4afdf824cef867db391b7bcb5995f603a76" \
	-H "X-Aha-Account: account1" \
	-H "Content-Type: application/json" \
	-H "Accept: application/json"

Request

Authorization: Bearer 584b6d6b83405011f8c6903d2379f4afdf824cef867db391b7bcb5995f603a76
X-Aha-Account: account1
Content-Type: application/json
Accept: application/json

Response

Status: 200 OK
  Content-Type: application/json; charset=utf-8
{
  "portal_users": [
    {
      "id": "646391926",
      "email": "john@long.com",
      "first_name": "John",
      "last_name": "Long",
      "enabled": true,
      "verified": false,
      "employee": false,
      "created_at": "2017-10-16T19:54:35.000Z"
    }
  ],
  "pagination": {
    "total_records": 1,
    "total_pages": 1,
    "current_page": 1
  }
}

GET /api/v1/idea_portals/:idea_portal_id/portal_users/:id

Get a specific portal user

Parameters

Name Description
idea_portal_id * Numeric ID, or key of the idea portal to get portal users for
id * Numeric ID, or key of the portal user to be retrieved

GET /api/v1/idea_portals/1070474755/portal_users/646391926

Example CURL command

curl -g "https://secure.aha.io/api/v1/idea_portals/1070474755/portal_users/646391926" -X GET \
	-H "Authorization: Bearer 584b6d6b83405011f8c6903d2379f4afdf824cef867db391b7bcb5995f603a76" \
	-H "X-Aha-Account: account1" \
	-H "Content-Type: application/json" \
	-H "Accept: application/json"

Request

Authorization: Bearer 584b6d6b83405011f8c6903d2379f4afdf824cef867db391b7bcb5995f603a76
X-Aha-Account: account1
Content-Type: application/json
Accept: application/json

Response

Status: 200 OK
  Content-Type: application/json; charset=utf-8
{
  "portal_user": {
    "id": "646391926",
    "email": "john@long.com",
    "first_name": "John",
    "last_name": "Long",
    "enabled": true,
    "verified": false,
    "employee": false,
    "created_at": "2017-10-16T19:54:35.000Z"
  }
}

PUT /api/v1/idea_portals/:idea_portal_id/portal_users/:id

Update a portal user

Parameters

Name Description
idea_portal_id * Numeric ID, or key of the idea portal to get portal users for
id * Numeric ID, or key of the portal user to be edited
email Email address of the portal user, The email address does not need to be of a user of Aha!
first_name First name of the portal user
last_name Last name of the portal user
permission Whether the portal user is an employee/partner. Must be 'true' or 'false'
enabled Whether the portal user is active. Must be 'true' or 'false'

PUT /api/v1/idea_portals/1070474755/portal_users/646391926

Example CURL command

curl "https://secure.aha.io/api/v1/idea_portals/1070474755/portal_users/646391926" -d '{"portal_user":{"first_name":"Sarah"}}' -X PUT \
	-H "Authorization: Bearer 584b6d6b83405011f8c6903d2379f4afdf824cef867db391b7bcb5995f603a76" \
	-H "X-Aha-Account: account1" \
	-H "Content-Type: application/json" \
	-H "Accept: application/json"

Request

Authorization: Bearer 584b6d6b83405011f8c6903d2379f4afdf824cef867db391b7bcb5995f603a76
X-Aha-Account: account1
Content-Type: application/json
Accept: application/json
{
  "portal_user": {
    "first_name": "Sarah"
  }
}

Response

Status: 200 OK
  Content-Type: application/json; charset=utf-8
{
  "portal_user": {
    "id": "646391926",
    "email": "john@long.com",
    "first_name": "Sarah",
    "last_name": "Long",
    "enabled": true,
    "verified": false,
    "employee": false,
    "created_at": "2017-10-16T19:54:35.000Z"
  }
}

PUT /api/v1/idea_portals/:idea_portal_id/portal_users/:id

Disable a portal user

Parameters

Name Description
idea_portal_id * Numeric ID, or key of the idea portal to get portal users for
id * Numeric ID, or key of the portal user to be edited
email Email address of the portal user, The email address does not need to be of a user of Aha!
first_name First name of the portal user
last_name Last name of the portal user
permission Whether the portal user is an employee/partner. Must be 'true' or 'false'
enabled Whether the portal user is active. Must be 'true' or 'false'

PUT /api/v1/idea_portals/1070474755/portal_users/646391926

Example CURL command

curl "https://secure.aha.io/api/v1/idea_portals/1070474755/portal_users/646391926" -d '{"portal_user":{"enabled":"0"}}' -X PUT \
	-H "Authorization: Bearer 584b6d6b83405011f8c6903d2379f4afdf824cef867db391b7bcb5995f603a76" \
	-H "X-Aha-Account: account1" \
	-H "Content-Type: application/json" \
	-H "Accept: application/json"

Request

Authorization: Bearer 584b6d6b83405011f8c6903d2379f4afdf824cef867db391b7bcb5995f603a76
X-Aha-Account: account1
Content-Type: application/json
Accept: application/json
{
  "portal_user": {
    "enabled": "0"
  }
}

Response

Status: 200 OK
  Content-Type: application/json; charset=utf-8
{
  "portal_user": {
    "id": "646391926",
    "email": "john@long.com",
    "first_name": "John",
    "last_name": "Long",
    "enabled": false,
    "verified": false,
    "employee": false,
    "created_at": "2017-10-16T19:54:35.000Z"
  }
}

PUT /api/v1/idea_portals/:idea_portal_id/portal_users/:id

Enable a portal user

Parameters

Name Description
idea_portal_id * Numeric ID, or key of the idea portal to get portal users for
id * Numeric ID, or key of the portal user to be edited
email Email address of the portal user, The email address does not need to be of a user of Aha!
first_name First name of the portal user
last_name Last name of the portal user
permission Whether the portal user is an employee/partner. Must be 'true' or 'false'
enabled Whether the portal user is active. Must be 'true' or 'false'

PUT /api/v1/idea_portals/1070474755/portal_users/646391926

Example CURL command

curl "https://secure.aha.io/api/v1/idea_portals/1070474755/portal_users/646391926" -d '{"portal_user":{"enabled":"1"}}' -X PUT \
	-H "Authorization: Bearer 584b6d6b83405011f8c6903d2379f4afdf824cef867db391b7bcb5995f603a76" \
	-H "X-Aha-Account: account1" \
	-H "Content-Type: application/json" \
	-H "Accept: application/json"

Request

Authorization: Bearer 584b6d6b83405011f8c6903d2379f4afdf824cef867db391b7bcb5995f603a76
X-Aha-Account: account1
Content-Type: application/json
Accept: application/json
{
  "portal_user": {
    "enabled": "1"
  }
}

Response

Status: 200 OK
  Content-Type: application/json; charset=utf-8
{
  "portal_user": {
    "id": "646391926",
    "email": "john@long.com",
    "first_name": "John",
    "last_name": "Long",
    "enabled": true,
    "verified": false,
    "employee": false,
    "created_at": "2017-10-16T19:54:35.000Z"
  }
}

Overview

API Resources