TeamAccessLogs
Gets the access logs for the current team.
View-Specific Information
SELECT
The component uses the Slack API to filter the results by the following columns and operators while the rest of the filter is executed client-side within the component.
- TeamId supports the = operator.
The TeamAccessLogs table requires TeamId column in the WHERE clause; otherwise, the driver will automatically add the column.
Note: TeamId is only relevant when you connect with an org-level token. When you connect with a workspace-level token, the Slack API accepts the TeamId but ignores it and returns data for the authenticated workspace. Filtering on an invalid TeamId therefore does not raise an error and does not return an empty result set.
For example, the following query is processed server side:
SELECT * FROM TeamAccessLogs WHERE TeamId = 'T01LC4ASB3M'
Columns
| Name | Type | References | Description |
| TeamId [KEY] | String | The Id of the team. Required if org token is used. It is only relevant when you connect with an org-level token. This will be ignored if workspace-level token is used. | |
| UserId | String | The Id of the user who accessed Slack. | |
| Username | String | The username of the user who accessed Slack. | |
| DateFirst | Datetime | The first login date time. | |
| DateLast | Datetime | The last login date time. | |
| Count | Integer | The login count. | |
| IP | String | The IP address of the user. | |
| UserAgent | String | The user agent with which the user logged in. | |
| Isp | String | The internet service provider. | |
| Country | String | The country where the access originated. | |
| Region | String | The region where the access originated. |