DataExportClient
armis_sdk.clients.data_export_client.DataExportClient
Bases: BaseEntityClient
Methods:
| Name | Description |
|---|---|
disable |
Disable data export of the entity. |
enable |
Enable data export of the entity. |
iterate |
Iterate over the exported data. |
get |
Get the |
toggle |
Enable / disable export of an entity. |
disable(entity)
async
Disable data export of the entity.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
entity
|
type[BaseExportedEntity]
|
The entity to disable exporting for. |
required |
Example
enable(entity)
async
Enable data export of the entity.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
entity
|
type[BaseExportedEntity]
|
The entity to enable exporting for. |
required |
Example
iterate(entity, **kwargs)
async
Iterate over the exported data.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
entity
|
type[T]
|
The entity type to iterate over (must be a subclass of BaseExportedEntity). |
required |
**kwargs
|
Any
|
Additional keyword arguments to pass to pandas.read_parquet(). |
{}
|
Returns:
| Type | Description |
|---|---|
AsyncIterator[T]
|
An (async) iterator of the underlying entity. |
Raises:
| Type | Description |
|---|---|
ArmisError
|
If data export is disabled for the entity or if the file format is not parquet. |
Example
Example
You can also pass additional parquet kwargs to filter columns or apply other parquet-specific operations:
get(entity)
async
Get the DataExport of the entity
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
entity
|
type[BaseExportedEntity]
|
The entity to get the data for. |
required |
Returns:
| Type | Description |
|---|---|
DataExport
|
A |
Example
toggle(entity, enabled)
async
Enable / disable export of an entity.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
entity
|
type[BaseExportedEntity]
|
The entity to enable/disable exporting for. |
required |
enabled
|
bool
|
The new value to set. |
required |
Raises:
| Type | Description |
|---|---|
ResponseError
|
If an error occurs while communicating with the API. |