Skip to main content

IS_USER

Written by Tom Williams

Type: Function

Function: IS_USER

Syntax: IS_USER(username, "<user id>")

Description: Returns true if the username is one of the user's usernames.

The user is given by their Keypup user ID, written as text, and must be a member of the team. To find your teammates' IDs, run { companies { nodes { name users { nodes { id firstName email } } } } } on the HQ API of the API Explorer (see Using the API). In the insight designer, the is user filter lets you pick the person by name instead.

IS_USER(username, "<user id>") is the same as IN(username, USERNAMES("<user id>")): see USERNAMES.

It is the same condition as the is user filter of the insight designer (see Using filters). Use it in a custom formula, to count, group or label records on that condition, or as a filter in a query sent through the Keypup API or MCP server.

Usernames are matched as text. A user's usernames are the ones of the apps they connected to their Keypup account (see Managing app identities), one per app. Someone else with the same username in another app, or with the same display name in an app which identifies people by name, such as Jira or Bitbucket, also matches. A user with no app connected matches nothing. The is user filter of the insight designer matches the user's accounts exactly: prefer it when building an insight.

Sample usage:

  • IS_USER(author_username, "<user id>") returns true for the records the user created.

  • COUNT_IF(IS_USER(merged_by_username, "<user id>")) as a metric counts the pull requests the user merged.

Did this answer your question?