# @fiado/gateway-adapter 中文文档

规范地址：https://npmcn.com/package/%40fiado/gateway-adapter/

版本：3\.16\.0
npm 元数据更新时间：2026-11-10T19:07:10.232Z
中文译文更新时间：2026-11-14T16:46:29.672Z
软件包许可：ISC

本文由上游 README 翻译，可能存在偏差，请结合原文核对 API、命令与配置。版权与许可归原作者所有。

原始 npm 页面：https://www.npmjs.com/package/%40fiado/gateway-adapter
原文对照：https://npmcn.com/package/%40fiado/gateway-adapter/?lang=original

## 关键信息（来自 npm 元数据）

- 包体积（解压后）：370 kB，171 个文件
- 模块格式：ES Module
- TypeScript 类型：包内自带
- 运行依赖：9 个
- peer 依赖：inversify ^8\.0\.0，reflect-metadata ^0\.2\.2
- 首次发布：2024-03-22T14:53:18.016Z
- 最新版本发布：2026-11-10T19:07:10.042Z
- 近 30 天下载量：2622（2026-10-15 至 2026-11-13，npm 官方下载统计）
- 已发布版本数：116（近 12 个月 35 个）

## 中文简介

AWS Lambda 和 API Gateways, sqs y Evention Bridge 互联网档案馆的存檔,存档日期2013-12-20

## 安装

```sh
npm install @fiado/gateway-adapter
```

也可以使用：`pnpm add @fiado/gateway-adapter`、`yarn add @fiado/gateway-adapter`、`bun add @fiado/gateway-adapter`

## README

# Fiado 网关适配器

### Lambda微型服务中心

[![npm](https://img.shields.io/badge/npm-@fiado/gateway--adapter-CB3837?logo=npm&logoColor=white)](https://www.npmjs.com/) [![TypeScript](https://img.shields.io/badge/TypeScript-5.x-3178C6?logo=typescript&logoColor=white)](https://www.typescriptlang.org/) [![AWS Lambda](https://img.shields.io/badge/AWS-Lambda-FF9900?logo=aws-lambda&logoColor=white)](https://aws.amazon.com/lambda/) [![InversifyJS](https://img.shields.io/badge/InversifyJS-6.x-1E88E5)](https://inversify.io/)

* * *

## 康特尼多斯塔布拉

-   [取消常规](https://npmcn.com/package/%40fiado/gateway-adapter/#readme-descripcion-general)
-   [阿基特克图拉](https://npmcn.com/package/%40fiado/gateway-adapter/#readme-arquitectura)
-   [伊斯塔拉西翁](https://npmcn.com/package/%40fiado/gateway-adapter/#readme-instalacion)
-   [配置](https://npmcn.com/package/%40fiado/gateway-adapter/#readme-configuracion)
-   [GatewayAdapter - 路由器特等](https://npmcn.com/package/%40fiado/gateway-adapter/#readme-gatewayadapter---router-principal)
-   [API 网关](https://npmcn.com/package/%40fiado/gateway-adapter/#readme-api-gateway)
-   [科拉斯SQS语Name](https://npmcn.com/package/%40fiado/gateway-adapter/#readme-colas-sqs)
-   [事件桥](https://npmcn.com/package/%40fiado/gateway-adapter/#readme-eventbridge)
-   [装饰](https://npmcn.com/package/%40fiado/gateway-adapter/#readme-decoradores)
-   [Sistema de Respuestas 总统府](https://npmcn.com/package/%40fiado/gateway-adapter/#readme-sistema-de-respuestas)
-   [编剧JWE](https://npmcn.com/package/%40fiado/gateway-adapter/#readme-encriptacion-jwe)
-   [普罗耶克托岛](https://npmcn.com/package/%40fiado/gateway-adapter/#readme-estructura-del-proyecto)
-   [依赖性](https://npmcn.com/package/%40fiado/gateway-adapter/#readme-dependencias)

* * *

## 取消常规

`@fiado/gateway-adapter` 对啦 **自由核心** 生态科学 Fiado que actua como (法语) **路由器中心** (原始内容存档于2018-10-21) (英语). para todos los eventos que rebebe un a funcion Lambda. 支持者:

-   **自动操作** aPI 网关, SQS y EventBridge
-   **请求/答复转换** 交锋
-   **自治省** 装饰和特征
-   **代号: JWT** 认知
-   **(原始内容存档于2018-10-21) (英语). Respuestas HTTP estandarizadas** cORS 配置图
-   **编剧JWE** 理智的理性观点
-   **活动登记** 自动

### 提案

En el modelo desarrollo Fiado, cada Lambda rebebes multies tipos de eventos: 维基语录链接:名人名言 - 文学作品 - 谚语 - 谚语 - 谚语

-   **API 网关**: Peticiones HTTP(公共、私营、后台)
-   **质量**: Mensajes de colas para procesamiento asincrono (英语:
-   **事件桥**: 服务活动

自由主义 **曼尼霍岛** (原始内容存档于2019-09-21). de todos estos eventos en unico punto de entrada.

* * *

## 阿基特克图拉

```
                              LAMBDA HANDLER
                                index.ts
                                   |
                                   v
                          +---------------+
                          | GatewayAdapter | <-- Router Principal
                          +-------+-------+
                                  |
              +-------------------+-------------------+
              v                   v                   v
     +-----------------+ +-----------------+ +-----------------+
     |ApiGatewayAdapter| |QueueGatewayAdapter| |EventBridgeAdapter|
     +--------+--------+ +--------+--------+ +--------+--------+
              |                   |                   |
              v                   v                   v
     +-----------------+ +-----------------+ +-----------------+
     |   Controllers   | | SQS Subscriber  | |  EB Subscriber  |
     | Public/Private/ | |IMessageSubscriber| |IEventBridgeSub |
     |   Backoffice    | |                 | |                 |
     +-----------------+ +-----------------+ +-----------------+
```

### 事件预防基金会

El GatewayAdapter 探测出一个自动调试器:

1.  **API 网关**页:1 `event.httpMethod` 已存在
2.  **质量**页:1 `event.Records[0].eventSource === 'aws:sqs'`
3.  **事件桥**页:1 `event.source === 'EVENT_BRIDGE'`

* * *

## 伊斯塔拉西翁

```bash
npm install @fiado/gateway-adapter
```

### 同伴依赖关系

```json
{
  "@fiado/logger": "^1.0.2",
  "@fiado/type-kit": "^2.1.35",
  "inversify": "^6.2.2",
  "reflect-metadata": "^0.2.2"
}
```

* * *

## 配置

### IoC连接器上的Registro

```typescript
import { Container } from "inversify";
import { 
    gatewayAdapterBindings, 
    TypeQueue, 
    TypeEventBridge,
    IController,
    IMessageSubscriber,
    IEventBridgeMessageSubscriber
} from "@fiado/gateway-adapter";

const container = new Container();

// Cargar bindings del gateway adapter
container.load(gatewayAdapterBindings);

// Registrar controladores del proyecto
container.bind<IController>('PublicController').to(PublicController);
container.bind<IController>('PrivateController').to(PrivateController);
container.bind<IController>('BackofficeController').to(BackofficeController);

// Registrar subscriber de SQS (si aplica)
container.bind<IMessageSubscriber<any>>("SQSMessageSubscriber").to(MySqsSubscriber);
container.bind<() => IMessageSubscriber<any>>(TypeQueue.SQSMessageSubscriberFactory)
    .toAutoFactory("SQSMessageSubscriber");

// Registrar subscriber de EventBridge (si aplica)
container.bind<IEventBridgeMessageSubscriber<any>>("EventBridgeMessageSubscriber")
    .to(MyEventBridgeSubscriber);
container.bind<() => IEventBridgeMessageSubscriber<any>>(
    TypeEventBridge.EventBridgeMessageSubscriberFactory
).toAutoFactory("EventBridgeMessageSubscriber");

export { container };
```

### 兰姆达入境点

```typescript
import 'reflect-metadata';
import warmer from "lambda-warmer";
import { container } from './container.config';
import { GatewayAdapter, TypeGateway } from '@fiado/gateway-adapter';
import { log } from "@fiado/logger";

export const handler = async (event: any, context: any) => {
    
    // Soporte para lambda warming
    if (await warmer(event)) {
        return 'warmed';
    }

    log.info(`Event received: ${JSON.stringify(event)}`);

    // Obtener el router y ejecutar
    const gatewayAdapter = container.get<GatewayAdapter>(TypeGateway.GatewayAdapter);
    return await gatewayAdapter.execute(event);
}
```

* * *

## GatewayAdapter - 路由器特等

埃尔 `GatewayAdapter` es el macifite central que systico de evento y lo enruta al 适配器等同体.

### 索波特多斯事件

| 提波 | 解开 | 适应者 |
| --- | --- | --- |
| **API 网关** | `event.httpMethod` 已存在 | `ApiGatewayAdapter` |
| **质量** | `event.Records[0].eventSource === 'aws:sqs'` | `QueueGatewayAdapter` |
| **事件桥** | `event.source === 'EVENT_BRIDGE'` | `EventBridgeGatewayAdapter` |

### 乌苏

```typescript
import { GatewayAdapter, TypeGateway } from '@fiado/gateway-adapter';

const gatewayAdapter = container.get<GatewayAdapter>(TypeGateway.GatewayAdapter);

// El adapter detecta automaticamente el tipo de evento
const result = await gatewayAdapter.execute(event);
```

* * *

## API 网关

### ApiGateway 请求

接口尖端 que 代表了 una peticion HTTP 变形:

```typescript
interface ApiGatewayRequest<TBody> {
    body: TBody | null;                                    // Body parseado
    headers: { [key: string]: string | undefined };        // Headers HTTP
    method: string;                                        // GET, POST, PUT, DELETE
    pathParameter: { [key: string]: string | undefined };  // Path params (/users/:id)
    queryStringParameters: { [key: string]: string };      // Query params (?key=value)
    multiValueQueryStringParameters: { [key: string]: string[] }; // Arrays
    token: TokenPayload | undefined | null;                // Token JWT decodificado
    operationName: string | null;                          // Nombre de la operacion
    base64EncodedFile?: string;                            // Archivos en base64
    requestContext: { identity?: { sourceIp?: string } };  // Contexto de request
}
```

### 控制者

(原始内容存档于2019-03-26) (英语). Los controladores se identifican por prefijo en el `operationName`数字 :

| 预选赛 | 控制器 | 乌苏 |
| --- | --- | --- |
| `public*` | `PublicController` | 端点公示( Internet) |
| `private*` | `PrivateController` | 终点 |
| `backoffice*` | `BackofficeController` | 最终管理点 |
| `agent*` 编号 : `agents*` | `AgentController` | 结束点去代理 |

### 控制者协会

```typescript
import { injectable, inject } from 'inversify';
import { 
    IController, 
    ApiGatewayRequest, 
    ApiResponse,
    AuthorizedFeatures,
    Feature,
    Endpoint,
    HttpMethod,
    SecurityType
} from '@fiado/gateway-adapter';

@injectable()
export class PublicController implements IController {

    constructor(
        @inject("IUserManager") private userManager: IUserManager
    ) {}

    @AuthorizedFeatures(Feature.ANONIMUS)
    @Endpoint({
        method: HttpMethod.GET,
        path: '/users/:id',
        summary: 'Obtener usuario por ID',
        tags: ['PublicController'],
        security: SecurityType.CognitoAppAuthorizer
    })
    async getUser(request: ApiGatewayRequest<void>): Promise<any> {
        const userId = request.pathParameter?.id;
        const user = await this.userManager.getById(userId);
        return ApiResponse.success({ data: user });
    }

    @AuthorizedFeatures(Feature.ANONIMUS)
    @Endpoint({
        method: HttpMethod.POST,
        path: '/users',
        summary: 'Crear usuario',
        tags: ['PublicController'],
        security: SecurityType.CognitoAppAuthorizer
    })
    async createUser(request: ApiGatewayRequest<CreateUserDto>): Promise<any> {
        const user = await this.userManager.create(request.body);
        return ApiResponse.created({ data: user });
    }
}
```

### 托肯服务

塞维西奥·帕·德·科尼托(JWT de Cognto)的装饰品:

```typescript
import { TokenService } from '@fiado/gateway-adapter';

const tokenService = new TokenService();
const payload = tokenService.decodeToken(bearerToken);

// payload contiene:
// - sub: ID del usuario
// - email: Email del usuario
// - permissions: Array de permisos/features
// - cognito:groups: Grupos de Cognito
```

* * *

## 科拉斯SQS语Name

### 用户

接口 processar mensajes de SQS:

```typescript
export interface IMessageSubscriber<T> {
    handle(messageBody: T, receiptHandle: string): Promise<void>;
    deleteMessage(queueUrl: string, receiptHandle: string): Promise<void>;
}
```

### 订户执行

```typescript
import { injectable } from 'inversify';
import { IMessageSubscriber } from '@fiado/gateway-adapter';
import { log } from '@fiado/logger';

@injectable()
export class OrderMessageSubscriber implements IMessageSubscriber<OrderMessage> {
    
    async handle(messageBody: OrderMessage, receiptHandle: string): Promise<void> {
        log.info('Processing order message', { orderId: messageBody.orderId });
        await this.processOrder(messageBody);
    }

    async deleteMessage(queueUrl: string, receiptHandle: string): Promise<void> {
        // Implementar si se necesita borrado manual
    }

    private async processOrder(order: OrderMessage): Promise<void> {
        // Logica de procesamiento
    }
}
```

### 新闻推文

SQS 公共广告界面:

```typescript
export interface IMessagePublisher<T> {
    publish(messageBody: T, options?: PublishOptions): Promise<void>;
}
```

* * *

## 事件桥

### IEvent BridgeMessage 用户

接口 processar 事件- de EventBridge :

```typescript
import { EventBridgeMessageRequest } from "@fiado/type-kit";

export interface IEventBridgeMessageSubscriber<TPayload> {
    handle(message: EventBridgeMessageRequest<TPayload>): Promise<void>;
}
```

### 订户执行

```typescript
import { injectable } from 'inversify';
import { IEventBridgeMessageSubscriber } from '@fiado/gateway-adapter';
import { EventBridgeMessageRequest } from '@fiado/type-kit';

@injectable()
export class PaymentEventSubscriber implements IEventBridgeMessageSubscriber<PaymentEvent> {
    
    async handle(message: EventBridgeMessageRequest<PaymentEvent>): Promise<void> {
        const { payload, eventType } = message;
        
        switch (eventType) {
            case 'PAYMENT_COMPLETED':
                await this.handlePaymentCompleted(payload);
                break;
            case 'PAYMENT_FAILED':
                await this.handlePaymentFailed(payload);
                break;
        }
    }
}
```

* * *

## 装饰

### @ 认证 特征

装饰者 para definir que sets/permisos pueden admiters a un metodo: 装饰者 para definir que sets/permisos pueden acception a un metodo: 装饰者 设计者 设计者 设计师 设计师 设计师 设计师 设计师 设计师

```typescript
import { AuthorizedFeatures, Feature } from '@fiado/gateway-adapter';

// Acceso anonimo (sin token)
@AuthorizedFeatures(Feature.ANONIMUS)
async publicEndpoint(request: ApiGatewayRequest<any>): Promise<any> { }

// Requiere feature especifico en el token
@AuthorizedFeatures(Feature.PAYROLL)
async payrollEndpoint(request: ApiGatewayRequest<any>): Promise<any> { }

// Multiples features (OR - cualquiera autoriza)
@AuthorizedFeatures(Feature.ADMIN, Feature.MANAGER)
async adminEndpoint(request: ApiGatewayRequest<any>): Promise<any> { }
```

### 特性 Enum

```typescript
export enum Feature {
    ANONIMUS = "ANONIMUS",  // Acceso publico sin autenticacion
    TEST = "test",
    FEATURE1 = "feature1",
    PAYROLL = "PAYROLL"
}
```

### 结束点

端点元数据代号:

```typescript
import { Endpoint, HttpMethod, SecurityType } from '@fiado/gateway-adapter';

@Endpoint({
    method: HttpMethod.POST,
    path: '/payments',
    summary: 'Procesar pago',
    tags: ['PaymentController'],
    security: SecurityType.CognitoAppAuthorizer,
    queryParams: ['currency'],
    pathParams: ['id']
})
async processPayment(request: ApiGatewayRequest<PaymentDto>): Promise<any> { }
```

### Http 方法学 Enum

```typescript
export enum HttpMethod {
    GET = 'get',
    POST = 'post',
    PUT = 'put',
    DELETE = 'delete'
}
```

### 安全类型 Enum

```typescript
export enum SecurityType {
    CognitoAppAuthorizer = 'CognitoAppAuthorizer',           // Usuarios de la app
    CognitoBackofficeAuthorizer = 'CognitoBackofficeAuthorizer', // Administradores
    CognitoCombinedAuthorizer = 'CognitoCombinedAuthorizer',     // Ambos pools
    CognitoAgentAuthorizer = 'CognitoAgentAuthorizer'            // Agentes
}
```

* * *

## Sistema de Respuestas 总统府

### 回复

(原始内容存档于2017-10-21) (英语). Clase estatica para construitur respuestas HTTP estandarizadas:

```typescript
import { ApiResponse } from '@fiado/gateway-adapter';

// 200 OK
return ApiResponse.success({ data: result, msg: 'Operacion exitosa' });

// 201 Created
return ApiResponse.created({ data: newResource });

// 400 Bad Request
return ApiResponse.badRequest({ code: 'VALIDATION_ERROR', msg: 'Campo requerido' });

// 401 Unauthorized
return ApiResponse.unauthorized({ msg: 'Token invalido' });

// 403 Forbidden
return ApiResponse.forbidden({ msg: 'Acceso denegado' });

// 404 Not Found
return ApiResponse.notFound({ msg: 'Recurso no encontrado' });

// 425 Too Early
return ApiResponse.tooEarly({ msg: 'Intente mas tarde' });

// 500 Internal Server Error
return ApiResponse.internalServerError({ msg: 'Error interno' });

// 302 Redirect
return ApiResponse.redirect({ data: { url: 'https://...' } });

// Redireccion real con header Location
return ApiResponse.redirectTo('https://example.com/callback', 302);
```

### 重建区

Todas las repuestas siguen el formato estandar: 互联网档案馆的存檔,存档日期2014-12-21

```typescript
{
    statusCode: 200,
    headers: {
        "Access-Control-Allow-Origin": "*",
        "Access-Control-Allow-Headers": "*",
        "Access-Control-Allow-Methods": "*",
        "Content-Type": "application/json"
    },
    body: {
        code: "PROCESS_OK",      // Codigo de respuesta
        date: "2024-01-15T...",  // Timestamp ISO
        data: { ... },           // Datos de respuesta
        description: null,       // Descripcion opcional
        msg: null,               // Mensaje opcional
        encrypted: false         // Flag de encriptacion (opcional)
    }
}
```

### 备选反应

```typescript
interface ResponseOptions<T> {
    data?: T;              // Datos a retornar
    code?: string;         // Codigo personalizado
    msg?: string;          // Mensaje
    description?: string;  // Descripcion
    encrypted?: boolean;   // Flag de encriptacion
}
```

* * *

## 编剧JWE

### Jwe 催化服务

JSON网络加密:

### 配置

学习能力变量:

```yaml
Environment:
  Variables:
    # Encriptar TODOS los endpoints de app
    JWE_ENCRYPTION_APP: "true"
    
    # O encriptar endpoints especificos
    JWE_ENCRYPTION_APP_ENDPOINTS: "publicGetBalance,publicGetTransactions"
    
    # Para backoffice
    JWE_ENCRYPTION_BACKOFFICE: "true"
    JWE_ENCRYPTION_BACKOFFICE_ENDPOINTS: "backofficeGetUserData"
```

### Flujo de Encriptacion (法语)

1.  客户端 envia 信头 `x-session-key` (JWE con lave publica RSA) Con Cession 密钥编码
2.  Lambda descifra 关键usando lave privada de secrets 管理器
3.  复苏a `data` se encripta con AES-256-GCM usando 会话密钥
4.  客户端 descifra respuesta con su 会话密钥

### Uso 自动

自动调试:

-   阿尔端点 esta configurado par encriptar 语句
-   客户端 envia el 信头 `x-session-key`
-   El servicio puede inficializarse 正确和解

```typescript
// La respuesta se encripta automaticamente
return ApiResponse.success({ data: sensitiveData });

// Respuesta encriptada:
{
    code: "PROCESS_OK",
    data: "eyJhbGciOiJkaXIiLCJlbmMiOiJBMjU2R0NNIn0...",  // JWE
    encrypted: true
}
```

* * *

## 普罗耶克托岛

```
src/
├── index.ts                    # Exportaciones publicas
├── container.config.ts         # ContainerModule con bindings
├── GatewayAdapter.ts           # Router principal
│
├── apigateway/                 # Modulo API Gateway
│   ├── abstractions/
│   │   ├── ApiGatewayRequest.ts
│   │   ├── ApiGatewayResponse.ts
│   │   ├── FeatureEnum.ts
│   │   ├── IController.ts
│   │   ├── ResponseOptions.ts
│   │   ├── StandardResponse.ts
│   │   └── TypeGateway.ts
│   ├── decorators/
│   │   └── AuthorizedFeatures.ts
│   └── services/
│       ├── ActivitySessionService.ts
│       ├── ApiGatewayAdapter.ts
│       ├── ApiResponse.ts
│       ├── JweEncryptionService.ts
│       └── TokenService.ts
│
├── queue/                      # Modulo SQS
│   ├── abstractions/
│   │   ├── IMessagePublisher.ts
│   │   ├── IMessageSubscriber.ts
│   │   ├── IPublishOptions.ts
│   │   └── TypeQueue.ts
│   ├── decorators/
│   └── services/
│       └── QueueGatewayAdapter.ts
│
├── eventBridge/                # Modulo EventBridge
│   ├── abstractions/
│   │   ├── IEventBridgeMessageSubscriber.ts
│   │   └── TypeEventBridge.ts
│   └── service/
│       └── EventBridgeGatewayAdapter.ts
│
└── endpoint/                   # Decorador @Endpoint
    └── endpointDecorator.ts
```

* * *

## 依赖性

### 运行时间

| 依赖性 | 版本 | 提案 |
| --- | --- | --- |
| `@fiado/api-invoker` | ^1.4.6 (中文(简体) ) | Invocacion de APIs internas (英语:Invocacion de APIs internas) 互联网档案馆的存檔,存档日期2014-12-02 |
| `@fiado/logger` | ^1.0.2 (中文(简体) ) | 记录构造 |
| `@fiado/type-kit` | ^ 2.1.35 (韩语) | DTOs 和 Tipos 堆肥 |
| `aws-lambda` | ^1.0.7 (中文(简体) ) | Tipos de AWS Lambda 兰克达 |
| `inversify` | ^ 6.2.2 | 依附地 |
| `jose` | ^ 4.15.5 (韩语) | 编剧JWE |
| `jsonwebtoken` | ^ 9.0.2 (韩语) | JWT 解码器 |
| `reflect-metadata` | ^ 0.2.2 (中文(简体) ) | 元代装饰 |
| `uuid` | (单位:千美元) | 乌干达民主联盟 |

### 发展

| 依赖性 | 版本 | 提案 |
| --- | --- | --- |
| `@types/jsonwebtoken` | (单位:千美元) | Tipos de jsonwebtoken (英语) |

* * *

## 合作与公众

### 构建

```bash
npm run build
```

热那拉群岛 `.js` 尔 `.d.ts` 导演 `bin/`。 。 。 .

### 公众

```bash
npm version patch|minor|major
npm publish
```

* * *

**菲亚多公司.** @fiado/gateway-adapterv 1.1.59 (中文(简体) )

\` , \`

## 常见问题

### @fiado/gateway-adapter 是什么？

AWS Lambda 和 API Gateways, sqs y Evention Bridge 互联网档案馆的存檔,存档日期2013-12-20

### 如何安装 @fiado/gateway-adapter？

在项目目录运行 npm install @fiado/gateway-adapter，或使用 pnpm add / yarn add / bun add。它还需要宿主项目提供 peer 依赖：inversify（^8\.0\.0）、reflect-metadata（^0\.2\.2）。npm 7 及以上与 pnpm 8 及以上默认会自动安装必需的 peer 依赖，Yarn 需要手动安装。

### @fiado/gateway-adapter 支持 TypeScript 吗？

支持。包内自带 TypeScript 类型声明（package\.json 声明了 types 入口），安装后即可获得类型提示，无需再安装 @types 包。

### @fiado/gateway-adapter 支持 ESM 还是 CommonJS？

以 ES Module 形式发布，推荐使用 import 引入。在 CommonJS 项目中，Node\.js 20\.19\+ / 22\.12\+ 可以直接 require\(\) 不含顶层 await 的 ES Module，更早的版本需要改用动态 import\(\)。

### @fiado/gateway-adapter 可以商用吗？

@fiado/gateway-adapter 使用 ISC 许可。宽松许可：允许商业使用、修改和再分发，通常只需在分发时保留原版权与许可声明。以上为概括，不构成法律意见，请以许可原文为准。

### @fiado/gateway-adapter 的下载量有多少？

根据 npm 官方下载统计，@fiado/gateway-adapter 在 2026/10/15 – 2026/11/13 这 30 天内被下载 2,622 次，日均约 87 次。下载量会把 CI 构建、镜像同步和作为其他包依赖的安装一并计入，适合横向比较热度，不能直接等同于使用人数。

### @fiado/gateway-adapter 还在维护吗？

最新版本 3\.16\.0 发布于 2026/11/11（3 天前）；至今共发布 116 个版本，其中过去 12 个月发布了 35 个；首次发布于 2024/03/22。发布频率只是参考信号：功能稳定的工具可能很少需要更新，建议结合源码仓库的 issue 和提交记录判断。

