System Keys Management BETA
Our REST API supports the following system keys management actions:
- Create a new System Key
- List all System Keys
- Retrieve System Key details
- Update a System Key
- Delete a System Key
- Rotate a System Key
Create a new System Key
Creates a new system key with your Fivetran account.
Request
POST https://api.fivetran.com/v1/system-keys
{
"name": "prod_key",
"expiration_period": "THREE_MONTHS",
"permissions": [
{
"resource_type": "USER",
"access_level": "READ"
},
{
"resource_type": "WEBHOOK",
"access_level": "MANAGE"
},
{
"resource_type": "CONNECTOR",
"access_level": "MANAGE"
},
{
"resource_type": "DESTINATION",
"access_level": "MANAGE"
},
{
"resource_type": "TRANSFORMATION",
"access_level": "MANAGE",
"resource_filter": {
"group_ids": [
"group_id_1",
"group_id_2"
]
}
},
{
"resource_type": "CONNECTOR",
"access_level": "NONE",
"resource_filter": {
"ids": [
"connector_id_1",
"connector_id_2"
]
}
}
]
}
Payload parameters
Name | Description | Possible Values |
---|---|---|
name (required) | The name of the system key. | |
expiration_period | The system key's expiration period. Default value is INFINITE . | ONE_WEEK , ONE_MONTH , THREE_MONTHS , SIX_MONTHS , INFINITE |
permissions (required) | The list of access permissions for the system key. | |
permissions.resource_type (required) | The resource type for the permission. | |
permissions.access_level (required) | The access level for the permission. | |
permissions.resource_filter.ids | The IDs of the managed entities. Allowed only for DESTINATION and CONNECTOR resource types. | |
permissions.resource_filter.group_ids | The IDs of the managed groups. Allowed only for CONNECTOR and TRANSFORMATION resource types. |
Response
HTTP 201 Created
{
"code": "Success",
"message": "System key has been created",
"data": {
"id": "sod_determine",
"name": "prod_key",
"key": "<key_value>",
"secret": "<secret_value>",
"created_at": "2023-11-10T19:32:58.646Z",
"expired_at": "2024-02-10T19:32:58.646Z",
"permissions": [
{
"resource_type": "USER",
"access_level": "READ"
},
{
"resource_type": "WEBHOOK",
"access_level": "MANAGE"
},
{
"resource_type": "DESTINATION",
"access_level": "MANAGE"
},
{
"resource_type": "TRANSFORMATION",
"access_level": "MANAGE",
"resource_filter": {
"group_ids": [
"group_id_1",
"group_id_2"
]
}
},
{
"resource_type": "CONNECTOR",
"access_level": "NONE",
"resource_filter": {
"ids": [
"connector_id_1",
"connector_id_2"
]
}
},
{
"resource_type": "CONNECTOR",
"access_level": "MANAGE"
}
]
}
}
Name | Description |
---|---|
id | The unique identifier for the system key within the Fivetran system. |
name | The system key name within the account. |
key | The key value of the system key. |
secret | The secret value of the system key. |
created_at | The system key creation timestamp. |
expired_at | The system key expiration timestamp. |
permissions | The system key's permissions. |
permissions.resource_type | The resource type for the permission. |
permissions.access_level | The access level for the permission. |
permissions.resource_filter.ids | The IDs of the managed entities. |
permissions.resource_filter.group_ids | The IDs of the managed groups. |
HTTP 400 BAD REQUEST
Field 'name' is required
List all System Keys
Returns a list of system keys within your Fivetran account.
Request
GET https://api.fivetran.com/v1/system-keys
Query parameters
Name | Description |
---|---|
cursor | The paging cursor, read more about pagination |
limit | The number of records to fetch per page, accepts a number in the range 1..1000, the default value is 100 |
Response
HTTP 200 OK
{
"code": "Success",
"data": {
"items": [
{
"id": "_moonbeam_acc_dev",
"name": "dev",
"key": "<key_1_value>",
"created_at": "2023-11-10T22:11:52.326265Z",
"expired_at": "2024-02-10T22:11:52.326265Z"
},
{
"id": "cyclical_prospered",
"name": "prod_key",
"key": "<key_2_value>",
"created_at": "2023-11-10T22:11:58.931Z",
"updated_at": "2023-11-10T22:11:58.931Z",
"expired_at": "2024-02-10T22:11:58.931Z"
}
]
}
}
Name | Description |
---|---|
id | The unique identifier for the system key within the Fivetran system. |
name | The system key name within the account. |
key | The key value of the system key. |
created_at | The system key creation timestamp. |
updated_at | The system key update timestamp. |
expired_at | The system key expiration timestamp. |
last_used_at | The timestamp of the last usage. |
Retrieve System Key details
Retrieves a system key object within your Fivetran account.
Request
GET https://api.fivetran.com/v1/system-keys/{system-key-id}
Path parameters
Name | Description |
---|---|
system-key-id (required) | The unique identifier for the system key within your Fivetran account. |
Response
HTTP 200 OK
{
"code": "Success",
"data": {
"id": "rushed_fainting",
"name": "updated_key",
"key_value": "<key_value>",
"created_at": "2023-10-17T14:01:16.318Z",
"updated_at": "2023-10-17T14:02:20.919291Z",
"expired_at": "2024-01-17T14:01:16.318Z",
"permissions": [
{
"resource_type": "CONNECTOR",
"access_level": "MANAGE"
},
{
"resource_type": "DESTINATION",
"access_level": "MANAGE"
},
{
"resource_type": "TRANSFORMATION",
"access_level": "MANAGE",
"resource_filter": {
"group_ids": [
"group_id_1",
"group_id_2"
]
}
},
{
"resource_type": "CONNECTOR",
"access_level": "NONE",
"resource_filter": {
"ids": [
"connector_id_3",
"connector_id_4"
]
}
}
]
}
}
Name | Description |
---|---|
id | The unique identifier for the system key within the Fivetran system. |
name | The system key name within the account. |
key | The value of the system key. |
created_at | The system key creation timestamp. |
updated_at | The system key update timestamp. |
expired_at | The system key expiration timestamp. |
last_used_at | The timestamp of the last usage. |
permissions | The system key's permissions. |
permissions.resource_type | The resource type for the permission. |
permissions.access_level | The access level for the permission. |
permissions.resource_filter.ids | The IDs of the managed entities. |
permissions.resource_filter.group_ids | The IDs of the managed groups. |
HTTP 404 NOT FOUND
System key with id 'system_key_id' not found
Update a System Key
Updates an existing system key within your Fivetran account.
NOTE: The permissions in the update request completely overwrite the existing permissions.
Request
PATCH https://api.fivetran.com/v1/system-keys/{system-key-id}
{
"name": "updated_key",
"permissions": [
{
"resource_type": "CONNECTOR",
"access_level": "MANAGE"
},
{
"resource_type": "DESTINATION",
"access_level": "MANAGE"
},
{
"resource_type": "TRANSFORMATION",
"access_level": "MANAGE",
"resource_filter": {
"group_ids": ["group_id_3", "group_id_4"]
}
},
{
"resource_type": "CONNECTOR",
"access_level": "NONE",
"resource_filter": {
"ids": ["connector_id_3", "connector_id_4"]
}
}
]
}
Path parameters
Name | Description |
---|---|
system-key-id (required) | The unique identifier for the system key within your Fivetran account. |
Payload parameters
Name | Description |
---|---|
name | The name of the system key. |
permissions | The list of the access permissions for the system key. |
permissions.resource_type | The resource type for the permission. |
permissions.access_level | The access level for the permission. |
permissions.resource_filter.ids | The IDss of applied entities. Allowed only for DESTINATION and CONNECTOR resource types. |
permissions.resource_filter.group_ids | Ids of applied groups. Allowed only for CONNECTOR and TRANSFORMATION resource types. |
Response
HTTP 200 OK
{
"code": "Success",
"message": "System key has been updated",
"data": {
"id": "rushed_fainting",
"name": "updated_key",
"key_value": "<key_value>",
"created_at": "2023-10-17T14:01:16.318Z",
"updated_at": "2023-10-17T14:02:20.919291Z",
"expired_at": "2024-01-17T14:01:16.318Z",
"permissions": [
{
"resource_type": "CONNECTOR",
"access_level": "MANAGE"
},
{
"resource_type": "DESTINATION",
"access_level": "MANAGE"
},
{
"resource_type": "TRANSFORMATION",
"access_level": "MANAGE",
"resource_filter": {
"group_ids": [
"group_id_3",
"group_id_4"
]
}
},
{
"resource_type": "CONNECTOR",
"access_level": "NONE",
"resource_filter": {
"ids": [
"connector_id_3",
"connector_id_4"
]
}
}
]
}
}
Name | Description |
---|---|
id | The unique identifier for the system key within the Fivetran system. |
name | The system key name within the account. |
key | Key value of the system key. |
created_at | The system key creation timestamp. |
updated_at | The system key update timestamp. |
expired_at | The system key expiration timestamp. |
last_used_at | The timestamp of last usage. |
permissions | The system key's permissions. |
permissions.resource_type | The resource type for the permission. |
permissions.access_level | The access level for the permission. |
permissions.resource_filter.ids | The IDs of the managed entities. |
permissions.resource_filter.group_ids | The IDs of the managed groups. |
HTTP 404 NOT FOUND
System key with id 'system_key_id' not found
Delete a System Key
Deletes a system key from your Fivetran account.
Request
DELETE https://api.fivetran.com/v1/system-keys/{system-key-id}
Path parameters
Name | Description |
---|---|
system-key-id (required) | The unique identifier for the system key within your Fivetran account. |
Response
HTTP 200 OK
{
"code": "Success",
"message": "System key with id 'rushed_fainting' has been deleted"
}
HTTP 404 NOT_FOUND
System key with id 'system_key_id' not found.
Rotate a System Key
Updates the secret value and expired_at
date for an existing system key within your Fivetran account.
Request
POST https://api.fivetran.com/v1/system-keys/{system-key-id}/rotate
{
"expiration_period": "THREE_MONTHS"
}
Path parameters
Name | Description |
---|---|
system-key-id (required) | The unique identifier for the system key within your Fivetran account. |
Payload parameters (Optional)
Name | Description | Possible Values |
---|---|---|
expiration_period | The system key's expiration period. Default value is INFINITE . | ONE_WEEK , ONE_MONTH , THREE_MONTHS , SIX_MONTHS , INFINITE |
Response
HTTP 200 OK
{
"code": "Success",
"message": "System key with id 'rushed_fainting' has been rotated",
"data": {
"id": "rushed_fainting",
"name": "prod_key",
"key": "<key_value>",
"secret": "<secret_value>",
"created_at": "2023-11-10T19:32:58.646Z",
"expired_at": "2024-02-10T19:32:58.646Z",
"permissions": [
{
"resource_type": "USER",
"access_level": "READ"
},
{
"resource_type": "WEBHOOK",
"access_level": "MANAGE"
},
{
"resource_type": "DESTINATION",
"access_level": "MANAGE"
},
{
"resource_type": "TRANSFORMATION",
"access_level": "MANAGE",
"resource_filter": {
"group_ids": [
"group_id_1",
"group_id_2"
]
}
},
{
"resource_type": "CONNECTOR",
"access_level": "NONE",
"resource_filter": {
"ids": [
"connector_id_3",
"connector_id_4"
]
}
},
{
"resource_type": "CONNECTOR",
"access_level": "MANAGE"
}
]
}
}
Name | Description |
---|---|
id | The unique identifier for the system key within the Fivetran system. |
name | The system key name within the account. |
key | The key value of the system key. |
secret | The secret value of rotated system key. |
created_at | The system key creation timestamp. |
updated_at | The system key update timestamp. |
expired_at | The system key expiration timestamp. |
last_used_at | The timestamp of the last usage. |
permissions | The system key's permissions. |
permissions.resource_type | The resource type for the permission. |
permissions.access_level | The access level for the permission. |
permissions.resource_filter.ids | The IDs of the managed entities. |
permissions.resource_filter.group_ids | The IDs of the managed groups. |
HTTP 404 NOT_FOUND
System key with id 'system_key_id' not found.