Table: workos_group - Query WorkOS Groups using SQL
WorkOS is a service that allows developers to implement enterprise-level features into their applications. It provides functionalities such as Single Sign-On (SSO), Directory Sync, and Audit Trail, making it easier to manage and secure applications. A WorkOS Group is a collection of users from an organization's identity provider that can be managed as a single entity.
Table Usage Guide
The workos_group
table provides insights into WorkOS Groups within WorkOS. As a developer or IT administrator, explore details about each group through this table, including group ID, name, description, and associated users. Utilize it to manage and organize users effectively, ensuring appropriate access control and security within your application.
Examples
Basic info
Explore which groups have been created within your organization, including their unique identifiers and the time of creation. This can help you keep track of group formation and understand the structure of your organization over time.
select id, name, directory_id, organization_id, created_atfrom workos_group;
select id, name, directory_id, organization_id, created_atfrom workos_group;
List groups of a particular organization
Explore which groups belong to a specific organization. This is useful to understand the structure and distribution of groups within that organization, providing insights for management and organizational planning.
select g.id as group_id, g.name as group_name, g.directory_id, g.organization_id, g.created_atfrom workos_group as g, workos_organization as owhere g.organization_id = o.id and o.name = 'test';
select g.id as group_id, g.name as group_name, g.directory_id, g.organization_id, g.created_atfrom workos_group as g, workos_organization as owhere g.organization_id = o.id and o.name = 'test';
List groups of a particular directory
Explore which groups belong to a specific directory to better manage and organize your resources. This can be particularly useful in identifying and sorting groups for administrative or security purposes.
select g.id as group_id, g.name as group_name, g.directory_id, g.organization_id, g.created_atfrom workos_group as g, workos_directory as dwhere g.directory_id = d.id and d.name = 'test';
select g.id as group_id, g.name as group_name, g.directory_id, g.organization_id, g.created_atfrom workos_group as g join workos_directory as d on g.directory_id = d.idwhere d.name = 'test';
List groups created in the last 30 days
Explore groups that have been established within the past month. This can be beneficial for understanding recent organizational changes or additions.
select id, name, directory_id, organization_id, created_atfrom workos_groupwhere created_at >= now() - interval '30' day;
select id, name, directory_id, organization_id, created_atfrom workos_groupwhere created_at >= datetime('now', '-30 day');
Schema for workos_group
Name | Type | Operators | Description |
---|---|---|---|
_ctx | jsonb | Steampipe context in JSON form. | |
created_at | timestamp with time zone | The Group's created at date. | |
directory_id | text | = | The identifier of the directory the group belongs to. |
id | text | = | The Group's unique identifier. |
idp_id | text | The Group's unique identifier assigned by the directory provider. | |
name | text | The Group's name. | |
organization_id | text | The identifier for the organization in which the directory resides. | |
raw_attributes | jsonb | The Group's raw attributes in raw encoded JSON. | |
sp_connection_name | text | =, !=, ~~, ~~*, !~~, !~~* | Steampipe connection name. |
sp_ctx | jsonb | Steampipe context in JSON form. | |
title | text | Title of the resource. | |
updated_at | timestamp with time zone | The Group's updated at date. |
Export
This table is available as a standalone Exporter CLI. Steampipe exporters are stand-alone binaries that allow you to extract data using Steampipe plugins without a database.
You can download the tarball for your platform from the Releases page, but it is simplest to install them with the steampipe_export_installer.sh
script:
/bin/sh -c "$(curl -fsSL https://steampipe.io/install/export.sh)" -- workos
You can pass the configuration to the command with the --config
argument:
steampipe_export_workos --config '<your_config>' workos_group