View as Markdown
Element icon

Element ACTION

Resolve Room Alias

Look up the room ID that a human-readable room alias points to, e.g. #engineering:matrix.org. Every other action in this app takes a room ID (!OGEhHVWSdvArJzumhm:matrix.org) and rejects aliases, so use this first whenever you only know the alias. Aliases can be re-pointed to a different room over time, so always trust the returned room_id rather than assuming an alias still maps to the room you expect. Returns the room ID and the servers that know the alias. See the documentation
  • Action
  • Read only
  • API key
  • SDK
  • MCP

IMPLEMENTATION

Call this tool

Connect a user's Element account once, then configure and run Resolve Room Alias from your backend or agent.

import { PipedreamClient } from "@pipedream/sdk"

const pd = new PipedreamClient({
  projectId: process.env.PIPEDREAM_PROJECT_ID!,
  clientId: process.env.PIPEDREAM_CLIENT_ID!,
  clientSecret: process.env.PIPEDREAM_CLIENT_SECRET!,
  projectEnvironment: "production",
})

const result = await pd.actions.run({
  id: "element-resolve-room-alias",
  externalUserId: "{external_user_id}", // any stable ID for this user in your system
  configuredProps: {
    element: { authProvisionId: "apn_xxxxxxx" },
    roomAlias: "Room Alias",
  },
})

console.log(result)

SCHEMA

Inputs

Pipedream supplies the connected account. Your application provides the operation-specific values below. Dynamic inputs are resolved against that user's account.

Resolve Room Alias inputs
Property Type Description
roomAlias Room Alias string
The full room alias to resolve, including the leading # and the homeserver suffix, e.g. #engineering:matrix.org. The homeserver returns M_NOT_FOUND if no room is mapped to the alias.
Required

REFERENCE

Tool details

Behavior hints are published with the component in the Pipedream registry and surface as MCP tool annotations, so an agent can reason about a tool before it calls it.

Registry key
element-resolve-room-alias
Version
0.0.2
App
Element
Authentication
API key
Read-only
Yes
Destructive
No
Open world
Yes