skip to main content
Hybrid Data Pipeline API reference : Management API : Data Sources API : Get data source details
  

Try Now
Get data source details

Purpose

Retrieves the details for a specified data source. The details include the ID and name of the data source, the options specified for the data source, and other information, such as whether the data source is a member of a data source group.
Note: An administrator can execute this operation on behalf of a user by appending the user query parameter to the request and specifying a user name. See also Managing resources on behalf of users.

URL

https://<myserver>:<port>/api/mgmt/datasources/{datasourceId}

Method

GET

URL Parameters

<myserver> is the hostname or IP address of the machine hosting the Hybrid Data Pipeline server for a standalone installation, or the machine hosting the load balancer for a load balancer installation. For a standalone installation, <port> is the port number specified as the Server Access Port during installation. For a load balancer installation, <port> must be either 80 for http or 443 for https. Whenever port 80 or 443 are used, it is not necessary to include the port number in the URL.
The {datasourceId} parameter must also be specified in the URL.
Parameter
Description
Valid Values
{datasourceId}
The ID of the data source.
The ID is auto-generated when the data source is created and cannot be changed.

Response Definition

The response takes the following format. The properties of the response are described in the table that follows.
Note: The sharedByAnotherUser and sharedWithAnotherUser properties will only be included in the response when the ?details=true parameter is appended to the query and the actual value of either property is true.
{
"id": "datasource_id",
"name": "datasource_name",
"dataStore": datastore_id,
"connectionType": "connection_type",
"description": "datasource_description",
"sharedByAnotherUser": boolean,
"sharedWithAnotherUser": boolean,
"options": {
"option1": "option1_value",
"option2": "option2_value",
...
},
"permissions": [integer, integer, ...],
"members": ["datasource1", "datasource2", ...]
}
Parameter
Description
Valid Values
"id"
The ID of the data source
The ID is auto-generated when the data source is created and cannot be changed.
"name"
The name of the data source. This name is passed as a database parameter when establishing a connection to the data source with the ODBC driver, the JDBC driver, or the OData API.
The first character of the name must be a letter, and the name can contain only alphanumeric, underscores, and dashes.
"dataStore"
The ID of the data store on which the data source is being created. The data store defines the options that can be specified when creating the data source.
Group data sources must be created on the Hybrid Data Pipeline group data store. A group data source is comprised of multiple member data sources that connect to one or more back end data stores such as Salesforce or SQL Server.
The integer ID of the data store
For a group data source, this property is set to 56 to specify the DataSource Group data store.
Data store IDs can be obtained with the Get data stores call.
"connectionType"
Specifies whether the data source is a cloud, hybrid, or group data source
"Cloud" | "Hybrid" | Group
If set to "Cloud", the data source is accessible from the public WAN.
If set to "Hybrid" the data source is a hybrid data source. Depending on how it is configured, a hybrid data source can connect to either a public WAN data source or to a data source behind a firewall using the On-Premises Connector to create a cloud-only data source.
If set to Group, the data source is a group data source. A group data source must be created on the DataSource Group data store by setting the "dataStore" property to 56.
"description"
A description of the data source
A description of the data source provided by the user who created the data source
"sharedByAnotherUser"
Indicates whether the data source is being shared by another user.
Provided only when the ?details=true parameter is appended to the query and the data source is being shared by another user.
true when the data source is being shared by another user.
"sharedWithAnotherUser"
Indicates whether the data source is being shared with another user.
Provided only when the ?details=true parameter is appended to the query and the data source is being shared with another user.
true when the data source is being shared with another user.
"options"
The list of option names and values to be set on the data source. The list of allowed options depends on the data store. Data store options can be retrieved with the Get options for a data store call.
A comma separated list of options and their values.
The content of the options object is zero or more sets of option names and values.
"permissions"
A list of permissions associated explicitly with the data source. Permissions can only be set on a data source by an administrator when creating or updating the data source on behalf of a user.
Any permissions specified for this data source will override the permissions for the user or the user's role that own this data source. You must specify the exact set of permissions that you want to set for this data source as no permissions are inherited from the user or user's role if permissions are specified on a data source.
Permissions set on a group data source override permissions set on any of its member data sources.
A comma separated list of permission IDs
See Data source permissions for supported permissions.
"members"
The members object can be used to assign member data sources to a group data source. Member data sources can be assigned when a group data source is being created or added after the group data source has been created.
The members object includes an "id" property and an "entityPrefix" property.
The "id" specifies the ID of a member data source. The member data source cannot itself be a group data source.
The "entityPrefix" is a user-defined prefix associated with a specific data source to resolve naming conflicts. The prefix must be 1 to 64 characters in length and must be unique.

Sample Server Response

Note: The response will not return settings for optional properties that were not set in a previous POST or PUT request.
Example 1

Status code: 200
Successful response

{
"id":"5039",
"name":"SF2",
"dataStore":1,
"connectionType":"Cloud",
"description":"Test",
"options":{
"User":"mysfusername",
"Password":"mysfpassword",
"SecurityToken":"mysecuritytoken",
"EnableBulkLoad": "true",
"MaxPooledStatements": "60"
},
"permissions": [
1,
2,
3,
4,
5
]
}
Example 2
The following server response is for a group data source. As shown here, a "members" array is returned for group data sources.

Status code: 200
Successful response
{
"id":"5051",
"name": "OData_Group",
"dataStore": "56",
"connectionType": "Group",
"description": "Test OData connectivity",
"options": {
"Name": "OData_Group",
"Description": "Test OData connectivity",
"ODataVersion": "4",
"MaximumEntityNameLength": "64"
},
"permissions": [
1,
2,
3,
4,
5
],
"members": [
{
"id": 3,
"entityPrefix": "fin"
},
{
"id": 6,
"entityPrefix": "mkt"
}
]
}

Authentication

Basic Authentication using Login ID and Password.

Authorization

The user must have the MgmtAPI (11) and ViewDataSource (2) permissions.