All URIs are relative to https://api.powerbi.com
Method | HTTP request | Description |
---|---|---|
addDatasourceUser | POST /v1.0/myorg/gateways/{gatewayId}/datasources/{datasourceId}/users | Get a datasource user |
createDatasource | POST /v1.0/myorg/gateways/{gatewayId}/datasources | Create a datasource |
deleteDatasource | DELETE /v1.0/myorg/gateways/{gatewayId}/datasources/{datasourceId} | Delete a datasource |
deleteDatasourceUser | DELETE /v1.0/myorg/gateways/{gatewayId}/datasources/{datasourceId}/users/{emailAdress} | Delete a datasource user |
getDatasourceById | GET /v1.0/myorg/gateways/{gatewayId}/datasources/{datasourceId} | Get a datasource by id |
getDatasourceStatusById | GET /v1.0/myorg/gateways/{gatewayId}/datasources/{datasourceId}/status | Get a datasource status by id |
getDatasourceUsers | GET /v1.0/myorg/gateways/{gatewayId}/datasources/{datasourceId}/users | Get a datasource users list |
getDatasources | GET /v1.0/myorg/gateways/{gatewayId}/datasources | Get all datasources of specific gateway |
updateDatasource | PATCH /v1.0/myorg/gateways/{gatewayId}/datasources/{datasourceId} | Update a datasource credentials |
Object addDatasourceUser(gatewayId, datasourceId, addUserToDatasourceRequest)
Get a datasource user
// Import classes:
//import com.microsoft.powerbi.ApiException;
//import com.microsoft.powerbi.api.DatasourcesApi;
DatasourcesApi apiInstance = new DatasourcesApi();
String gatewayId = "gatewayId_example"; // String | The gateway id
String datasourceId = "datasourceId_example"; // String | The datasource id
UserAccessRight addUserToDatasourceRequest = new UserAccessRight(); // UserAccessRight | The add user to datasource request
try {
Object result = apiInstance.addDatasourceUser(gatewayId, datasourceId, addUserToDatasourceRequest);
System.out.println(result);
} catch (ApiException e) {
System.err.println("Exception when calling DatasourcesApi#addDatasourceUser");
e.printStackTrace();
}
Name | Type | Description | Notes |
---|---|---|---|
gatewayId | String | The gateway id | |
datasourceId | String | The datasource id | |
addUserToDatasourceRequest | UserAccessRight | The add user to datasource request |
Object
No authorization required
- Content-Type: application/json
- Accept: Not defined
GatewayDatasource createDatasource(gatewayId, datasourceToGatewayRequest)
Create a datasource
// Import classes:
//import com.microsoft.powerbi.ApiException;
//import com.microsoft.powerbi.api.DatasourcesApi;
DatasourcesApi apiInstance = new DatasourcesApi();
String gatewayId = "gatewayId_example"; // String | The gateway id
PublishDatasourceToGatewayRequest datasourceToGatewayRequest = new PublishDatasourceToGatewayRequest(); // PublishDatasourceToGatewayRequest | The datasource requested to create
try {
GatewayDatasource result = apiInstance.createDatasource(gatewayId, datasourceToGatewayRequest);
System.out.println(result);
} catch (ApiException e) {
System.err.println("Exception when calling DatasourcesApi#createDatasource");
e.printStackTrace();
}
Name | Type | Description | Notes |
---|---|---|---|
gatewayId | String | The gateway id | |
datasourceToGatewayRequest | PublishDatasourceToGatewayRequest | The datasource requested to create |
No authorization required
- Content-Type: application/json
- Accept: application/json
Object deleteDatasource(gatewayId, datasourceId)
Delete a datasource
// Import classes:
//import com.microsoft.powerbi.ApiException;
//import com.microsoft.powerbi.api.DatasourcesApi;
DatasourcesApi apiInstance = new DatasourcesApi();
String gatewayId = "gatewayId_example"; // String | The gateway id
String datasourceId = "datasourceId_example"; // String | The datasource id
try {
Object result = apiInstance.deleteDatasource(gatewayId, datasourceId);
System.out.println(result);
} catch (ApiException e) {
System.err.println("Exception when calling DatasourcesApi#deleteDatasource");
e.printStackTrace();
}
Name | Type | Description | Notes |
---|---|---|---|
gatewayId | String | The gateway id | |
datasourceId | String | The datasource id |
Object
No authorization required
- Content-Type: Not defined
- Accept: Not defined
Object deleteDatasourceUser(gatewayId, datasourceId, emailAdress)
Delete a datasource user
// Import classes:
//import com.microsoft.powerbi.ApiException;
//import com.microsoft.powerbi.api.DatasourcesApi;
DatasourcesApi apiInstance = new DatasourcesApi();
String gatewayId = "gatewayId_example"; // String | The gateway id
String datasourceId = "datasourceId_example"; // String | The datasource id
String emailAdress = "emailAdress_example"; // String | The user's email address
try {
Object result = apiInstance.deleteDatasourceUser(gatewayId, datasourceId, emailAdress);
System.out.println(result);
} catch (ApiException e) {
System.err.println("Exception when calling DatasourcesApi#deleteDatasourceUser");
e.printStackTrace();
}
Name | Type | Description | Notes |
---|---|---|---|
gatewayId | String | The gateway id | |
datasourceId | String | The datasource id | |
emailAdress | String | The user's email address |
Object
No authorization required
- Content-Type: application/json
- Accept: Not defined
GatewayDatasource getDatasourceById(gatewayId, datasourceId)
Get a datasource by id
// Import classes:
//import com.microsoft.powerbi.ApiException;
//import com.microsoft.powerbi.api.DatasourcesApi;
DatasourcesApi apiInstance = new DatasourcesApi();
String gatewayId = "gatewayId_example"; // String | The gateway id
String datasourceId = "datasourceId_example"; // String | The datasource id
try {
GatewayDatasource result = apiInstance.getDatasourceById(gatewayId, datasourceId);
System.out.println(result);
} catch (ApiException e) {
System.err.println("Exception when calling DatasourcesApi#getDatasourceById");
e.printStackTrace();
}
Name | Type | Description | Notes |
---|---|---|---|
gatewayId | String | The gateway id | |
datasourceId | String | The datasource id |
No authorization required
- Content-Type: Not defined
- Accept: application/json
Object getDatasourceStatusById(gatewayId, datasourceId)
Get a datasource status by id
// Import classes:
//import com.microsoft.powerbi.ApiException;
//import com.microsoft.powerbi.api.DatasourcesApi;
DatasourcesApi apiInstance = new DatasourcesApi();
String gatewayId = "gatewayId_example"; // String | The gateway id
String datasourceId = "datasourceId_example"; // String | The datasource id
try {
Object result = apiInstance.getDatasourceStatusById(gatewayId, datasourceId);
System.out.println(result);
} catch (ApiException e) {
System.err.println("Exception when calling DatasourcesApi#getDatasourceStatusById");
e.printStackTrace();
}
Name | Type | Description | Notes |
---|---|---|---|
gatewayId | String | The gateway id | |
datasourceId | String | The datasource id |
Object
No authorization required
- Content-Type: Not defined
- Accept: application/json
ODataResponseListUserAccessRight getDatasourceUsers(gatewayId, datasourceId)
Get a datasource users list
// Import classes:
//import com.microsoft.powerbi.ApiException;
//import com.microsoft.powerbi.api.DatasourcesApi;
DatasourcesApi apiInstance = new DatasourcesApi();
String gatewayId = "gatewayId_example"; // String | The gateway id
String datasourceId = "datasourceId_example"; // String | The datasource id
try {
ODataResponseListUserAccessRight result = apiInstance.getDatasourceUsers(gatewayId, datasourceId);
System.out.println(result);
} catch (ApiException e) {
System.err.println("Exception when calling DatasourcesApi#getDatasourceUsers");
e.printStackTrace();
}
Name | Type | Description | Notes |
---|---|---|---|
gatewayId | String | The gateway id | |
datasourceId | String | The datasource id |
ODataResponseListUserAccessRight
No authorization required
- Content-Type: Not defined
- Accept: application/json
ODataResponseListGatewayDatasource getDatasources(gatewayId)
Get all datasources of specific gateway
// Import classes:
//import com.microsoft.powerbi.ApiException;
//import com.microsoft.powerbi.api.DatasourcesApi;
DatasourcesApi apiInstance = new DatasourcesApi();
String gatewayId = "gatewayId_example"; // String | The gateway id
try {
ODataResponseListGatewayDatasource result = apiInstance.getDatasources(gatewayId);
System.out.println(result);
} catch (ApiException e) {
System.err.println("Exception when calling DatasourcesApi#getDatasources");
e.printStackTrace();
}
Name | Type | Description | Notes |
---|---|---|---|
gatewayId | String | The gateway id |
ODataResponseListGatewayDatasource
No authorization required
- Content-Type: Not defined
- Accept: application/json
Object updateDatasource(gatewayId, datasourceId, updateDatasourceRequest)
Update a datasource credentials
// Import classes:
//import com.microsoft.powerbi.ApiException;
//import com.microsoft.powerbi.api.DatasourcesApi;
DatasourcesApi apiInstance = new DatasourcesApi();
String gatewayId = "gatewayId_example"; // String | The gateway id
String datasourceId = "datasourceId_example"; // String | The datasource id
UpdateDatasourceRequest updateDatasourceRequest = new UpdateDatasourceRequest(); // UpdateDatasourceRequest | The update datasource request
try {
Object result = apiInstance.updateDatasource(gatewayId, datasourceId, updateDatasourceRequest);
System.out.println(result);
} catch (ApiException e) {
System.err.println("Exception when calling DatasourcesApi#updateDatasource");
e.printStackTrace();
}
Name | Type | Description | Notes |
---|---|---|---|
gatewayId | String | The gateway id | |
datasourceId | String | The datasource id | |
updateDatasourceRequest | UpdateDatasourceRequest | The update datasource request |
Object
No authorization required
- Content-Type: Not defined
- Accept: Not defined