> ## Documentation Index
> Fetch the complete documentation index at: https://docs.kinetica.com/llms.txt
> Use this file to discover all available pages before exploring further.

# gpudb::GrantPermissionDatasourceRequest

> gpudb::GrantPermissionDatasourceRequest — Kinetica C++ API

A set of parameters for [GPUdb::grantPermissionDatasource](https://docs.kinetica.com/content/api/cpp/classgpudb_1_1GPUdb/grantpermissiondatasource.md#a5ea6ea4a2af4895f3acf2131ffe36c56). [More...](#details)`#include <gpudb/protocol/grant_permission_datasource.h>`

<table>
  <tr>
    <td colSpan="2">
      ## Public Member Functions
    </td>
  </tr>

  <tr id="r_acd91171ec96862272e0f224311ae8452">
    <td align="right" valign="top"> </td>
    <td valign="bottom">[GrantPermissionDatasourceRequest](#acd91171ec96862272e0f224311ae8452) ()</td>
  </tr>

  <tr>
    <td> </td>
    <td>Constructs a [GrantPermissionDatasourceRequest](https://docs.kinetica.com/content/api/cpp/structgpudb_1_1GrantPermissionDatasourceRequest.md) object with default parameters. \
    </td>
  </tr>

  <tr>
    <td colSpan="2"> </td>
  </tr>

  <tr id="r_a663f754dbe5eca909dbb972b4b96613c">
    <td align="right" valign="top"> </td>
    <td valign="bottom">[GrantPermissionDatasourceRequest](#a663f754dbe5eca909dbb972b4b96613c) (const std::string \&name\_, const std::string \&permission\_, const std::string \&datasourceName\_, const std::map\< std::string, std::string > \&options\_)</td>
  </tr>

  <tr>
    <td> </td>
    <td>Constructs a [GrantPermissionDatasourceRequest](https://docs.kinetica.com/content/api/cpp/structgpudb_1_1GrantPermissionDatasourceRequest.md) object with the specified parameters. \
    </td>
  </tr>

  <tr>
    <td colSpan="2"> </td>
  </tr>
</table>

<table>
  <tr>
    <td colSpan="2">
      ## Public Attributes
    </td>
  </tr>

  <tr id="r_a6ef25c444f806fb185e2d24282186a7f">
    <td align="right" valign="top">std::string </td>
    <td valign="bottom">[name](#a6ef25c444f806fb185e2d24282186a7f)</td>
  </tr>

  <tr>
    <td> </td>
    <td>Name of the user or role to which the permission will be granted. \
    </td>
  </tr>

  <tr>
    <td colSpan="2"> </td>
  </tr>

  <tr id="r_aeb1fc2099d57bba4a639e8a7ec91c926">
    <td align="right" valign="top">std::string </td>
    <td valign="bottom">[permission](#aeb1fc2099d57bba4a639e8a7ec91c926)</td>
  </tr>

  <tr>
    <td> </td>
    <td>Permission to grant to the user or role. \
    </td>
  </tr>

  <tr>
    <td colSpan="2"> </td>
  </tr>

  <tr id="r_a0b2b98ecece46b8301ffc8db024f6112">
    <td align="right" valign="top">std::string </td>
    <td valign="bottom">[datasourceName](#a0b2b98ecece46b8301ffc8db024f6112)</td>
  </tr>

  <tr>
    <td> </td>
    <td>Name of the data source on which the permission will be granted. \
    </td>
  </tr>

  <tr>
    <td colSpan="2"> </td>
  </tr>

  <tr id="r_aa3eb1a8e895c84be782762c5889cc96e">
    <td align="right" valign="top">std::map\< std::string, std::string > </td>
    <td valign="bottom">[options](#aa3eb1a8e895c84be782762c5889cc96e)</td>
  </tr>

  <tr>
    <td> </td>
    <td>Optional parameters. \
    </td>
  </tr>

  <tr>
    <td colSpan="2"> </td>
  </tr>
</table>

## Detailed Description

A set of parameters for [GPUdb::grantPermissionDatasource](https://docs.kinetica.com/content/api/cpp/classgpudb_1_1GPUdb/grantpermissiondatasource.md#a5ea6ea4a2af4895f3acf2131ffe36c56). \[DEPRECATED–please use [GPUdb::grantPermission](https://docs.kinetica.com/content/api/cpp/classgpudb_1_1GPUdb/grantpermission.md#a9634c497d7035ee98062b6f92a63be8d) instead] Grants a [data source](https://docs.kinetica.com/content/concepts/data_sources.md) permission to a user or role. Definition at line [22](https://github.com/kineticadb/kinetica-api-cpp/blob/master/gpudb/protocol/grant_permission_datasource.h#L22) of file [grant\_permission\_datasource.h](https://github.com/kineticadb/kinetica-api-cpp/blob/master/gpudb/protocol/grant_permission_datasource.h).

## Constructor & Destructor Documentation

## [◆ ](#acd91171ec96862272e0f224311ae8452)GrantPermissionDatasourceRequest() \[1/2]

<table>
  <tr>
    <td>
      <table>
        <tr>
          <td>gpudb::GrantPermissionDatasourceRequest::GrantPermissionDatasourceRequest </td>
          <td>(</td>

          <td />

          <td>)</td>

          <td />
        </tr>
      </table>
    </td>

    <td> inline </td>
  </tr>
</table>

Constructs a [GrantPermissionDatasourceRequest](https://docs.kinetica.com/content/api/cpp/structgpudb_1_1GrantPermissionDatasourceRequest.md) object with default parameters. Definition at line [28](https://github.com/kineticadb/kinetica-api-cpp/blob/master/gpudb/protocol/grant_permission_datasource.h#L28) of file [grant\_permission\_datasource.h](https://github.com/kineticadb/kinetica-api-cpp/blob/master/gpudb/protocol/grant_permission_datasource.h).

## [◆ ](#a663f754dbe5eca909dbb972b4b96613c)GrantPermissionDatasourceRequest() \[2/2]

<table>
  <tr>
    <td>
      <table>
        <tr>
          <td>gpudb::GrantPermissionDatasourceRequest::GrantPermissionDatasourceRequest </td>
          <td>(</td>
          <td>const std::string &</td>
          <td>name\_, </td>
        </tr>

        <tr>
          <td />

          <td />

          <td>const std::string &</td>
          <td>permission\_, </td>
        </tr>

        <tr>
          <td />

          <td />

          <td>const std::string &</td>
          <td>datasourceName\_, </td>
        </tr>

        <tr>
          <td />

          <td />

          <td>const std::map\< std::string, std::string > &</td>
          <td>options\_ )</td>
        </tr>
      </table>
    </td>

    <td> inline </td>
  </tr>
</table>

Constructs a [GrantPermissionDatasourceRequest](https://docs.kinetica.com/content/api/cpp/structgpudb_1_1GrantPermissionDatasourceRequest.md) object with the specified parameters.&#x20;

Parameters

<table>
  <tr>
    <td>\[in]</td>
    <td>name\_</td>
    <td>Name of the user or role to which the permission will be granted. Must be an existing user or role. </td>
  </tr>

  <tr>
    <td>\[in]</td>
    <td>permission\_</td>

    <td>
      Permission to grant to the user or role. Supported values:

      <ul>
        <li> [grant\_permission\_datasource\_admin](https://docs.kinetica.com/content/api/cpp/namespacegpudb.md#a7537475c56ceaa2d2583ba633210c191): Admin access on the given data source. </li>
        <li> [grant\_permission\_datasource\_connect](https://docs.kinetica.com/content/api/cpp/namespacegpudb.md#ae657f681c0269d80d72dd986106ccf28): Connect access on the given data source. </li>
      </ul>
    </td>
  </tr>

  <tr>
    <td>\[in]</td>
    <td>datasourceName\_</td>
    <td>Name of the data source on which the permission will be granted. Must be an existing data source, or an empty string to grant permission on all data sources. </td>
  </tr>

  <tr>
    <td>\[in]</td>
    <td>options\_</td>
    <td>Optional parameters. The default value is an empty map. </td>
  </tr>
</table>

Definition at line [63](https://github.com/kineticadb/kinetica-api-cpp/blob/master/gpudb/protocol/grant_permission_datasource.h#L63) of file [grant\_permission\_datasource.h](https://github.com/kineticadb/kinetica-api-cpp/blob/master/gpudb/protocol/grant_permission_datasource.h).

## Member Data Documentation

## [◆ ](#a0b2b98ecece46b8301ffc8db024f6112)datasourceName

<table>
  <tr>
    <td>std::string gpudb::GrantPermissionDatasourceRequest::datasourceName</td>
  </tr>
</table>

Name of the data source on which the permission will be granted. Must be an existing data source, or an empty string to grant permission on all data sources. Definition at line [96](https://github.com/kineticadb/kinetica-api-cpp/blob/master/gpudb/protocol/grant_permission_datasource.h#L96) of file [grant\_permission\_datasource.h](https://github.com/kineticadb/kinetica-api-cpp/blob/master/gpudb/protocol/grant_permission_datasource.h).

## [◆ ](#a6ef25c444f806fb185e2d24282186a7f)name

<table>
  <tr>
    <td>std::string gpudb::GrantPermissionDatasourceRequest::name</td>
  </tr>
</table>

Name of the user or role to which the permission will be granted. Must be an existing user or role. Definition at line [75](https://github.com/kineticadb/kinetica-api-cpp/blob/master/gpudb/protocol/grant_permission_datasource.h#L75) of file [grant\_permission\_datasource.h](https://github.com/kineticadb/kinetica-api-cpp/blob/master/gpudb/protocol/grant_permission_datasource.h).

## [◆ ](#aa3eb1a8e895c84be782762c5889cc96e)options

<table>
  <tr>
    <td>std::map\<std::string, std::string> gpudb::GrantPermissionDatasourceRequest::options</td>
  </tr>
</table>

Optional parameters. The default value is an empty map. Definition at line [101](https://github.com/kineticadb/kinetica-api-cpp/blob/master/gpudb/protocol/grant_permission_datasource.h#L101) of file [grant\_permission\_datasource.h](https://github.com/kineticadb/kinetica-api-cpp/blob/master/gpudb/protocol/grant_permission_datasource.h).

## [◆ ](#aeb1fc2099d57bba4a639e8a7ec91c926)permission

<table>
  <tr>
    <td>std::string gpudb::GrantPermissionDatasourceRequest::permission</td>
  </tr>
</table>

Permission to grant to the user or role. Supported values:&#x20;

<ul>
  <li> [grant\_permission\_datasource\_admin](https://docs.kinetica.com/content/api/cpp/namespacegpudb.md#a7537475c56ceaa2d2583ba633210c191): Admin access on the given data source. </li>
  <li> [grant\_permission\_datasource\_connect](https://docs.kinetica.com/content/api/cpp/namespacegpudb.md#ae657f681c0269d80d72dd986106ccf28): Connect access on the given data source. </li>
</ul>

Definition at line [89](https://github.com/kineticadb/kinetica-api-cpp/blob/master/gpudb/protocol/grant_permission_datasource.h#L89) of file [grant\_permission\_datasource.h](https://github.com/kineticadb/kinetica-api-cpp/blob/master/gpudb/protocol/grant_permission_datasource.h).

***

The documentation for this struct was generated from the following file:

<ul>
  <li>gpudb/protocol/[grant\_permission\_datasource.h](https://github.com/kineticadb/kinetica-api-cpp/blob/master/gpudb/protocol/grant_permission_datasource.h)</li>
</ul>


This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.