Enable a User in a Qubole Account

POST /api/v1.2/accounts/enable_qbol_user

This API is used to enable a user in a particular Qubole account.

Required Role

The following users can make this API call:

  • Users who belong to the system-user or system-admin group.

  • Users who belong to a group associated with a role that allows enabling users. See Managing Groups and Managing Roles for more information.

Parameters

Note

Parameters marked in bold are mandatory. Others are optional and have default values.

Parameter

Description

qbol_user_id

ID of the user, who should be enabled. Or, it can also be the email address of the user. View Users of a QDS Account describes how to get the users. Send the get_users API request. From the successful response, trace the user-id and email, and use its id value.

Request API Syntax

Here is the Request API syntax.

curl  -X POST -H "X-AUTH-TOKEN: $AUTH_TOKEN" -H "Content-Type: application/json" -H "Accept: application/json" \
-d '{"qbol_user_id" : "<id>/<user-email-address>"}' "https://api.qubole.com/api/v1.2/accounts/enable_qbol_user"

Note

The above syntax uses https://api.qubole.com as the endpoint. Qubole provides other endpoints to access QDS that are described in Supported Qubole Endpoints on Different Cloud Providers.

To get the qbol_user_id, perform the following steps:

  1. Send the GET API request, GET /api/v1.2/accounts/get_users as described in View Users of a QDS Account.

  2. A successful API response contains multiple values. For example, the values may look like { id: xyz, ... user_id: abcd, email:abc@.. }. Use the value that is with the id parameter.

Sample Request

Here is a sample request.

curl  -X POST -H "X-AUTH-TOKEN: $AUTH_TOKEN" -H "Content-Type: application/json" -H "Accept: application/json" \
-d '{"qbol_user_id" : "4"}' "https://api.qubole.com/api/v1.2/accounts/enable_qbol_user"

Here is a sample request with the user’s email address.

curl  -X POST -H "X-AUTH-TOKEN: $AUTH_TOKEN" -H "Content-Type: application/json" -H "Accept: application/json" \
-d '{"qbol_user_id" : "[email protected]"}' "https://api.qubole.com/api/v1.2/accounts/enable_qbol_user"