steampipe plugin install linear

Table: linear_team_membership - Query Linear Team Memberships using SQL

Linear Team Memberships are a critical part of the Linear service, defining the relationship between teams and their members. They provide a mechanism for grouping members into teams for better organization and management. Team Memberships in Linear are essential for managing workload distribution, task assignment, and overall project management within the service.

Table Usage Guide

The linear_team_membership table provides insights into the team memberships within Linear. As a project manager or team leader, you can explore specific details about the relationship between teams and members through this table. Use it to understand team composition, member roles, and to manage workload distribution and task assignments more effectively.

Examples

Basic info

Explore the creation and modification details of team memberships in Linear. This information can help to understand team dynamics and track changes over time.

select
id,
created_at,
owner,
sort_order,
updated_at
from
linear_team_membership;
select
id,
created_at,
owner,
sort_order,
updated_at
from
linear_team_membership;

List teams with owner details

Discover the segments that include team ownership details, allowing you to understand who holds control over different teams and when the last updates were made. This can be particularly useful in larger organizations where team ownership may shift frequently.

select
id,
jsonb_pretty(team) as team,
jsonb_pretty(membership_user) as user,
updated_at
from
linear_team_membership
where
owner;
select
id,
team,
membership_user as user,
updated_at
from
linear_team_membership
where
owner;

List members of a particular team

Explore which members belong to a specific team, gaining insights into their user ID, name, admin status, email, and activity status. This is particularly useful for managing team dynamics and understanding the roles of different team members.

select
membership_user ->> 'id' as user_id,
membership_user ->> 'name' as name,
membership_user ->> 'admin' as admin,
membership_user ->> 'email' as email,
membership_user ->> 'active' as active
from
linear_team_membership
where
team ->> 'name' = 'linear_team';
select
json_extract(membership_user, '$.id') as user_id,
json_extract(membership_user, '$.name') as name,
json_extract(membership_user, '$.admin') as admin,
json_extract(membership_user, '$.email') as email,
json_extract(membership_user, '$.active') as active
from
linear_team_membership
where
json_extract(team, '$.name') = 'linear_team';

List archived membership

Explore which team memberships in Linear have been archived to manage team structure and access effectively. This could be useful in maintaining the organization's data hygiene and understanding team dynamics over time.

select
id,
created_at,
owner,
sort_order,
updated_at
from
linear_team_membership
where
archived_at is not null;
select
id,
created_at,
owner,
sort_order,
updated_at
from
linear_team_membership
where
archived_at is not null;

Schema for linear_team_membership

NameTypeOperatorsDescription
_ctxjsonbSteampipe context in JSON form.
archived_attimestamp with time zoneThe time at which the entity was archived. Null if the entity has not been archived.
created_attimestamp with time zoneThe time at which the entity was created.
idtext=The unique identifier of the entity.
membership_userjsonbThe user that the membership is associated with.
organization_idtext=, !=, ~~, ~~*, !~~, !~~*Unique identifier for the organization.
ownerbooleanWhether the user is the owner of the team.
sort_orderdouble precisionThe order of the item in the user's team list.
sp_connection_nametext=, !=, ~~, ~~*, !~~, !~~*Steampipe connection name.
sp_ctxjsonbSteampipe context in JSON form.
teamjsonbThe team that the membership is associated with.
titletextThe issue label's title.
updated_attimestamp with time zoneThe last time at which the entity was meaningfully updated, i.e., for all changes of syncable properties except those for which updates should not produce an update to updatedAt (see skipUpdatedAtKeys). This is the same as the creation time if the entity hasn't been updated after creation.

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

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

steampipe_export_linear --config '<your_config>' linear_team_membership