mirror of
https://github.com/andwati/zitadel.git
synced 2026-10-18 05:52:51 +00:00
# Which Problems Are Solved - Logins through the new login via a Zitadel identity provider with `instanceRolesInfo` configured (e.g. support access) create/update the user, but the instance member roles from the `urn:zitadel:iam:org:project:roles` claim are never assigned — that synchronization only exists in the login v1 flow. Support users therefore end up without any permissions. # How the Problems Are Solved - New `syncInstanceRolesFromIdpIntent` in the login, called after user auto-creation and on existing-user logins. It mirrors the v1 filtering: roles are only honored for ZITADEL IdPs with `instanceRolesInfo`, when granted in a configured organization (matched on ID and domain) and using an instance role key (`IAM_` prefix). Memberships are written merge-only via the v2 `InternalPermissionService` (existing roles are never removed), and a failed sync logs a warning without blocking the login. # Additional Changes - Unit tests for the claim-to-role filtering. # Additional Context - Part of the "ZITADEL as an Identity Provider" epic: #5127 - Follow-up for PR #xxx (ZITADEL provider sign-in button in the new login)
ZITADEL Client
This package exports services and utilities to interact with ZITADEL
Installation
To install the package, use npm or yarn:
npm install @zitadel/client
or
yarn add @zitadel/client
Usage
Importing Services
You can import and use the services provided by this package to interact with ZITADEL.
import { createSettingsServiceClient, makeReqCtx } from "@zitadel/client/v2";
import { createServerTransport } from "@zitadel/client/node";
// Example usage
const transport = createServerTransport(process.env.ZITADEL_SERVICE_USER_TOKEN!, { baseUrl: process.env.ZITADEL_API_URL! });
const settingsService = createSettingsServiceClient(transport);
settingsService.getBrandingSettings({ ctx: makeReqCtx("orgId") }, {});
Utilities
This package also provides various utilities to work with ZITADEL
import { timestampMs } from "@zitadel/client";
// Example usage
console.log(`${timestampMs(session.creationDate)}`);
Documentation
For detailed documentation and API references, please visit the ZITADEL documentation.
Contributing
Contributions are welcome! Please read the contributing guidelines before getting started.