feat(api): add Cognito user pools to the cloud explorer

Adds a userpools catalog entry, schema and AwsUserPoolsAdapter, verified
against Floci core:

- list/get/create/delete user pools; create can set email or username
  sign-in, a relaxed password policy for local test users, and a public
  app client (on by default) whose id is surfaced in the pool metadata
- users as the pool's child items: list (paged), get, create and delete;
  passwords are set permanent by default so users can sign in at once
- map Cognito's HTTP-400 error names (UserNotFoundException,
  UsernameExistsException, AliasExistsException, InvalidPasswordException)
- link Floci's cognito-idp service to the new page on the diagnostics page
This commit is contained in:
Zakaria
2026-10-23 12:12:40 -04:00
parent ece36e4a34
commit 4156afccfe
12 changed files with 930 additions and 5 deletions
+3
View File
@@ -30,6 +30,7 @@ import { SESv2Client } from "@aws-sdk/client-sesv2";
import { CloudWatchClient } from "@aws-sdk/client-cloudwatch";
import { ElastiCacheClient } from "@aws-sdk/client-elasticache";
import { LightsailClient } from "@aws-sdk/client-lightsail";
import { CognitoIdentityProviderClient } from "@aws-sdk/client-cognito-identity-provider";
const endpoint = process.env.FLOCI_ENDPOINT;
const region = process.env.AWS_REGION || "us-east-1";
@@ -91,6 +92,7 @@ export type AwsClients = {
cloudwatch: CloudWatchClient;
elasticache: ElastiCacheClient;
lightsail: LightsailClient;
cognito: CognitoIdentityProviderClient;
};
export type AwsClientName = keyof AwsClients;
@@ -136,6 +138,7 @@ function buildClients(accountId: string): AwsClients {
cloudwatch: new CloudWatchClient(base),
elasticache: new ElastiCacheClient(base),
lightsail: new LightsailClient(base),
cognito: new CognitoIdentityProviderClient(base),
};
}