steampipe plugin install sentry

Table: sentry_organization_member - Query Sentry Organization Members using SQL

Sentry is an open-source error tracking tool that helps developers monitor and fix crashes in real time. It provides full stack trace details for all programming languages in a single dashboard. This enables developers to replicate and resolve errors that occur in their applications, improving the overall performance and user experience.

Table Usage Guide

The sentry_organization_member table provides insights into members within Sentry organizations. As a developer or team lead, you can use this table to explore specific member details, including their roles, email, and user status. This can be particularly useful for managing team access, understanding member roles, and tracking the status of each member within your organization.

Examples

Basic info

Gain insights into the members of an organization, including their roles and whether their access has expired. This can be useful for auditing purposes or to manage user access.

select
id,
name,
expired,
role,
organization_slug,
email
from
sentry_organization_member;
select
id,
name,
expired,
role,
organization_slug,
email
from
sentry_organization_member;

List expired members

Discover the members of your organization whose memberships have expired. This can be useful in auditing and managing your organization's active and inactive members.

select
id,
name,
expired,
role,
organization_slug,
email
from
sentry_organization_member
where
expired;
select
id,
name,
expired,
role,
organization_slug,
email
from
sentry_organization_member
where
expired = 1;

List members with owner access

Discover the segments that have owner access within an organization. This can be useful to manage permissions and access rights, ensuring only the appropriate members have high-level control.

select
id,
name,
expired,
role,
organization_slug,
email
from
sentry_organization_member
where
role = 'owner';
select
id,
name,
expired,
role,
organization_slug,
email
from
sentry_organization_member
where
role = 'owner';

List members of a particular organization

Explore which individuals are part of a specific organization, allowing you to understand their roles and contact details for better team management and communication.

select
id,
name,
expired,
role,
organization_slug,
email
from
sentry_organization_member
where
organization_slug = 'myorg';
select
id,
name,
expired,
role,
organization_slug,
email
from
sentry_organization_member
where
organization_slug = 'myorg';

List members of a particular team

Explore which individuals are part of a specific team and gain insights into their roles, active status, and contact details. This is useful for understanding team composition and managing team-related operations effectively.

select
id,
name,
expired,
role,
organization_slug,
email
from
sentry_organization_member,
jsonb_array_elements_text(teams) as team
where
team = 'turbot';
select
id,
name,
expired,
role,
organization_slug,
email
from
sentry_organization_member,
json_each(teams) as team
where
team.value = 'turbot';

List members with 2FA disabled

Identify members who have not enabled two-factor authentication. This can help enhance security measures by pinpointing potential vulnerabilities within your organization.

select
id,
name,
expired,
role,
organization_slug,
email
from
sentry_organization_member
where
"user" ->> 'has2fa' = 'false';
select
id,
name,
expired,
role,
organization_slug,
email
from
sentry_organization_member
where
json_extract("user", '$.has2fa') = 'false';

List members associated with a particular project

Discover the individuals tied to a specific project, enabling a comprehensive understanding of team composition and roles. This is useful for project management, offering insights into team structure and member responsibilities.

select
id,
name,
expired,
role,
organization_slug,
email
from
sentry_organization_member,
jsonb_array_elements_text(teams) as team
where
team in (
select
t ->> 'name'
from
sentry_project,
jsonb_array_elements(teams) as t
where
name = 'project1'
);
select
id,
name,
expired,
role,
organization_slug,
email
from
sentry_organization_member,
json_each(teams) as team
where
team.value in (
select
json_extract(t.value, '$.name')
from
sentry_project,
json_each(teams) as t
where
name = 'project1'
);

Schema for sentry_organization_member

NameTypeOperatorsDescription
_ctxjsonbSteampipe context in JSON form, e.g. connection_name.
date_createdtimestamp with time zoneThe creation timestamp of the member.
emailtextThe email of the organization member.
expiredbooleanThe invite has expired.
flagsjsonbThe member flags
idtext=The ID of this member.
invite_statustextThe status of the invite.
inviter_nametextThe inviter name who invited the member.
nametextThe name of the member.
organization_slugtext=The slug of the organization the member belongs to.
pendingbooleanThe invite is pending.
roletextThe role of the organization member.
role_nametextThe role name of the organization member.
teamsjsonbThe teams the organization member should be added to.
titletextTitle of the resource.
userjsonbRepresents a Sentry user.

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)" -- sentry

You can pass the configuration to the command with the --config argument:

steampipe_export_sentry --config '<your_config>' sentry_organization_member