List Channels


Get the list of channels (Read and Write) to which the application has the permission to.

Request Format


GET https://{apigw-address}/data-federation/v2.0/channels

Request Parameters (URI)


Name

Location (Path/Query)

Required/Optional

Data Type

Description

orgId

Query

Required

String

The OU ID which the application belongs to. How to get orgId >>

channelType

Query

Optional

String

The channel type. Supports the following values:

  • READ: For querying data from the data sources.

  • WRITE: For writing data to the data sources.

  • DOWNLOAD: For downloading data from the data sources.

If this parameter is not specified, this API will list all the channels to which the application is authorized.

Response Parameters


Name

Data Type

Description

channelType

String

The channel type:

  • READ: For querying data from the data sources.

  • WRITE: For writing data to the data sources.

  • DOWNLOAD: For downloading data from the data sources.

channelResource

JSON Object

The resource details for the channel. For more information, see ChannelResource Struct.

channelUsage

String

The channel usage:

  • TEST: This channel is for testing only.

  • PRODUCT: This channel is for official production.

channelName

String

The channel name.

channelStatus

String

The status of the channel. Supports ``START``(Running) only.

channelId

String

The channel ID.

dataSourceInfo

List<JSON Object>

The list of data sources associated with the channel. For more information, see DataSourceInfo Struct

ChannelResource Struct


Name

Data Type

Description

resourceId

String

Resource ID.

resourceConfig

String

Resource configuration amount.

ifMultiSourceAnalysis

Boolean

Whether the channel is a cross-source channel.

DataSourceInfo Struct


Name

Data Type

Description

dataSourceName

String

The data source name.

dataSourceType

String

The data source type. Supports hive_enos only.

alias

String

Alias of the data source.

Samples

Request Sample


url: https://{apigw-address}/data-federation/v2.0/channels?orgId=yourOrgId&channelType=WRITE
method: GET

Return Sample


{
  "msg": "OK",
  "code": 0,
  "data": [
    {
      "channelId": "yourchannelId",
      "channelName": "yourchannelName",
      "channelType": "WRITE",
      "channelUsage": "TEST",
      "channelStatus": "START",
      "dataSourceInfo": [
        {
          "dataSourceName": "hive_enos",
          "dataSourceType": "hive_enos",
          "alias": "hive_enos"
        }
      ],
      "channelResource": {
        "resourceId": "yourresourceId",
        "resourceConfig": "2cu",
        "ifMultiSourceAnalysis": false
      }
    }
  ]
}