Datacomponents
Datacomponents hold configuration for dataplugins, and are the building blocks for constructing pipelines. One dataplugin may be referenced by many datacomponents, each with a different set of properties for the dataplugin settings. One pipeline may reference multiple datacomponents.
Objects
Datacomponent
| Path | JSON Type | Format | Description |
|---|---|---|---|
id | string | Version 4 UUID | The datacomponent ID |
created | string | ISO 8601 timestamp | When the datacomponent was created |
lastModified | string | ISO 8601 timestamp | When the datacomponent was last modified |
name | string | The datacomponent name | |
dataPlugin | string | Create / update with dataplugin fullyQualifiedName | |
properties | object | Properties | The datacomponent properties, defined by the dataplugin settingsProperties are key-value pairs, where keys reference setting names |
Example response body
Extractor Datacomponent
Datacomponents that are backed by dataplugins of type EXTRACTOR expose the following additional configuration:
| Path | JSON Type | Format | Description |
|---|---|---|---|
streams | object[] | Array of Streams | The available streams (populated after verifying a pipeline that references this datacomponent) |
Properties
For each setting in the dataplugin settings:
| Path | JSON Type | Format | Description |
|---|---|---|---|
Refer to setting name | Refer to setting kind | Refer to setting kind | Refer to setting description |
Reserved Properties for Extractor Datacomponents
| Path | JSON Type | Format | Description |
|---|---|---|---|
_select | string | JSON array | Meltano stream and property selection rules |
_metadata | string | JSON object | Meltano stream and property metadata rules |
Stream
| Path | JSON Type | Format | Description |
|---|---|---|---|
name | string | The stream name | |
selected | string | Entity Selection | The stream entity selection type |
fields | object[] | Array of Fields | The available stream fields |
Field
| Path | JSON Type | Format | Description |
|---|---|---|---|
name | string | The field name | |
selected | string | Entity Selection | The field entity selection type |
Formats
Entity Selection
| Value | Description |
|---|---|
AUTOMATIC | The entity is automatically selected by the underlying extractor and will always be synced |
SELECTED | The entity is selected and will be synced |
EXCLUDED | The entity is excluded and will not be synced |
Requests
View all datacomponents in a workspace
GET /api/workspaces/{workspace-id}/datacomponents
Returns all datacomponents in the workspace {workspace-id}.
Prerequisites
- Workspace
{workspace-id}must exist
Examples
- cURL
- Python (requests)
curl -H "Authorization: Bearer $ACCESS_TOKEN" 'https://app.meltano.com:443/api/workspaces/7d4af0a7-b482-4b12-b40e-e956cd2c9d9d/datacomponents' -i -X GET
import requests
url = "https://app.meltano.com:443/api/workspaces/7d4af0a7-b482-4b12-b40e-e956cd2c9d9d/datacomponents"
headers = {
'Authorization': ACCESS_TOKEN
}
response = requests.request("GET", url, headers=headers)
print(response.text.encode('utf8'))
Response
200 OK
Datacomponent collection with HAL links.
Example response body
View a datacomponent
GET /api/datacomponents/{datacomponent-id}
Returns the datacomponent {datacomponent-id}.
Prerequisites
- Datacomponent
{datacomponent-id}must exist
Examples
- cURL
- Python (requests)
curl -H "Authorization: Bearer $ACCESS_TOKEN" 'https://app.meltano.com:443/api/datacomponents/e3af6bd4-9082-4e68-bf3e-75c5c4e0154e' -i -X GET
import requests
url = "https://app.meltano.com:443/api/datacomponents/e3af6bd4-9082-4e68-bf3e-75c5c4e0154e"
headers = {
'Authorization': ACCESS_TOKEN
}
response = requests.request("GET", url, headers=headers)
print(response.text.encode('utf8'))
Response
200 OK
Datacomponent with HAL links.
Example response body
Initialise a new datacomponent in a workspace
POST /api/workspaces/{workspace-id}/datacomponents
Initialises a new datacomponent in the workspace {workspace-id}.
Examples
- cURL
- Python (requests)
curl -H "Authorization: Bearer $ACCESS_TOKEN" 'https://app.meltano.com:443/api/workspaces/7d4af0a7-b482-4b12-b40e-e956cd2c9d9d/datacomponents' -i -X POST \
-H 'Content-Type: application/json'
import requests
url = "https://app.meltano.com:443/api/workspaces/7d4af0a7-b482-4b12-b40e-e956cd2c9d9d/datacomponents"
headers = {
'Authorization': ACCESS_TOKEN
}
response = requests.request("POST", url, headers=headers)
print(response.text.encode('utf8'))
Response
200 OK
datacomponent with HAL links.
Example response body
Create or update a datacomponent in a workspace
PUT /api/workspaces/{workspace-id}/datacomponents/{datacomponent-id}
Creates or updates the datacomponent {datacomponent-id} in the workspace {workspace-id}.
Body
Datacomponent resource.
{
"name" : "extractors/tap-matatika-sit",
"dataPlugin" : "extractors/tap-matatika-sit"
}
Examples
- cURL
- Python (requests)
curl -H "Authorization: Bearer $ACCESS_TOKEN" 'https://app.meltano.com:443/api/workspaces/7d4af0a7-b482-4b12-b40e-e956cd2c9d9d/datacomponents/e3af6bd4-9082-4e68-bf3e-75c5c4e0154e' -i -X PUT \
-H 'Content-Type: application/json' \
-d '{
"name" : "extractors/tap-matatika-sit",
"dataPlugin" : "extractors/tap-matatika-sit"
}'
import requests
url = "https://app.meltano.com:443/api/workspaces/7d4af0a7-b482-4b12-b40e-e956cd2c9d9d/datacomponents/e3af6bd4-9082-4e68-bf3e-75c5c4e0154e"
data = {
"name" : "extractors/tap-matatika-sit",
"dataPlugin" : "extractors/tap-matatika-sit"
}
headers = {
'Authorization': ACCESS_TOKEN
}
response = requests.request("PUT", url, headers=headers, data=data)
print(response.text.encode('utf8'))
Response
200 OK / 201 Created
Datacomponent with HAL links.
Example response body
Update a datacomponent
PUT /api/datacomponents/{datacomponent-id}
Updates the datacomponent {datacomponent-id}.
Prerequisites
- Datacomponent
{datacomponent-id}must exist
Body
Datacomponent resource.
{
"name" : "extractors/tap-matatika-sit",
"dataPlugin" : "extractors/tap-matatika-sit"
}
Examples
- cURL
- Python (requests)
curl -H "Authorization: Bearer $ACCESS_TOKEN" 'https://app.meltano.com:443/api/datacomponents/e3af6bd4-9082-4e68-bf3e-75c5c4e0154e' -i -X PUT \
-H 'Content-Type: application/json' \
-d '{
"name" : "extractors/tap-matatika-sit",
"dataPlugin" : "extractors/tap-matatika-sit"
}'
import requests
url = "https://app.meltano.com:443/api/datacomponents/e3af6bd4-9082-4e68-bf3e-75c5c4e0154e"
data = {
"name" : "extractors/tap-matatika-sit",
"dataPlugin" : "extractors/tap-matatika-sit"
}
headers = {
'Authorization': ACCESS_TOKEN
}
response = requests.request("PUT", url, headers=headers, data=data)
print(response.text.encode('utf8'))
Response
200 OK
Datacomponent with HAL links.
Example response body
Delete a datacomponent
DELETE /api/datacomponents/{datacomponent-id}
Deletes the datacomponent {datacomponent-id}.
Examples
- cURL
- Python (requests)
curl -H "Authorization: Bearer $ACCESS_TOKEN" 'https://app.meltano.com:443/api/datacomponents/e3af6bd4-9082-4e68-bf3e-75c5c4e0154e' -i -X DELETE
import requests
url = "https://app.meltano.com:443/api/datacomponents/e3af6bd4-9082-4e68-bf3e-75c5c4e0154e"
headers = {
'Authorization': ACCESS_TOKEN
}
response = requests.request("DELETE", url, headers=headers)
print(response.text.encode('utf8'))
Response
204 No Content
No response body provided.