@fiado/api-invoker 5.6.0 → 5.7.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -1,7 +1,7 @@
1
1
  import { IIdentityApi } from "./interfaces/IIdentityApi.js";
2
2
  import { LegacyApiResponse } from "./interfaces/LegacyApiResponse.js";
3
3
  import type { IHttpRequest } from "@fiado/http-client";
4
- import { PeopleUpdateRequest, UploadDocumentRequest, PeopleResponse, PeopleSelfVerifiedRequest, AgentDocumentKeyResponse, DocumentUploadResponse, PeopleSelfieResponse } from "@fiado/type-kit/bin/identity/index.js";
4
+ import { PeopleUpdateRequest, UploadDocumentRequest, PeopleResponse, PeopleSelfVerifiedRequest, AgentDocumentKeyResponse, DocumentUploadResponse } from "@fiado/type-kit/bin/identity/index.js";
5
5
  export declare class IdentityApi implements IIdentityApi {
6
6
  private httpRequest;
7
7
  private readonly baseUrl;
@@ -14,7 +14,6 @@ export declare class IdentityApi implements IIdentityApi {
14
14
  getPeopleByFullName(fullName: string): Promise<any>;
15
15
  privateGetDocumentsUrlSigned(directoryId: string, documentNames: string[]): Promise<any>;
16
16
  getUserDocuments(directoryId: string): Promise<any>;
17
- privateGetPeopleSelfie(directoryId: string): Promise<LegacyApiResponse<PeopleSelfieResponse>>;
18
17
  privateGetPeopleByDirectoryId(directoryId: string): Promise<LegacyApiResponse<PeopleResponse>>;
19
18
  privateGetLastAgentDocument(directoryId: string): Promise<LegacyApiResponse<AgentDocumentKeyResponse[]>>;
20
19
  privateUploadAgentDocument(directoryId: string, actorDirectoryId: string, document: UploadDocumentRequest): Promise<LegacyApiResponse<DocumentUploadResponse>>;
@@ -75,13 +75,6 @@ let IdentityApi = class IdentityApi {
75
75
  const url = `${this.baseUrl}identities/private/people/${directoryId}/documents`;
76
76
  return await this.httpRequest.get(url);
77
77
  }
78
- async privateGetPeopleSelfie(directoryId) {
79
- if (!directoryId) {
80
- throw new Error("Directory ID is required.");
81
- }
82
- const url = `${this.baseUrl}identities/private/people/${encodeURIComponent(directoryId)}/selfie`;
83
- return await this.httpRequest.get(url);
84
- }
85
78
  // ── Gemelos PRIVATE de los endpoints de agentes (proxy RBAC v2, DEC-PROT-011) ──
86
79
  // Retornan el ENVELOPE legacy completo (httpRequest devuelve response.data = el body de identity),
87
80
  // para que el proxy /v2 de people-business lo re-emita campo por campo (drop-in, sin doble-wrap).
@@ -1,4 +1,4 @@
1
- import { PeopleUpdateRequest, UploadDocumentRequest, PeopleResponse, PeopleSelfVerifiedRequest, AgentDocumentKeyResponse, DocumentUploadResponse, PeopleSelfieResponse } from "@fiado/type-kit/bin/identity/index.js";
1
+ import { PeopleUpdateRequest, UploadDocumentRequest, PeopleResponse, PeopleSelfVerifiedRequest, AgentDocumentKeyResponse, DocumentUploadResponse } from "@fiado/type-kit/bin/identity/index.js";
2
2
  import { LegacyApiResponse } from "./LegacyApiResponse.js";
3
3
  /**
4
4
  * Interfaz para el servicio Directory que permite operaciones sobre directorios.
@@ -36,19 +36,6 @@ export interface IIdentityApi {
36
36
  * Retorna { directoryId, keys: string[] }.
37
37
  */
38
38
  getUserDocuments(directoryId: string): Promise<any>;
39
- /**
40
- * Selfie guardada del usuario: devuelve una URL firmada temporal (no la imagen).
41
- *
42
- * Pensado para el facematch de Metamap contra la merchant database: la `url` se pasa a
43
- * `IMetamapConnectorApi.buildFacematchSignature` para obtener el `userPhotoLinkHash`, y el par
44
- * va en el `metadata` de la verificación con `customInput: true`. El presigned vence
45
- * (`expiresInSeconds`), así que la firma y el disparo del facematch van dentro de esa ventana.
46
- *
47
- * Devuelve el envelope legacy completo porque el resultado se discrimina por `code`, no por
48
- * status: `PROCESS_OK` con la selfie, `SELFIE_NOT_FOUND` si el usuario tiene cuenta pero no hay
49
- * imagen (el toolkit lo emite como HTTP 200). Sin cuenta, el endpoint responde 401 `NO_ACCOUNT`.
50
- */
51
- privateGetPeopleSelfie(directoryId: string): Promise<LegacyApiResponse<PeopleSelfieResponse>>;
52
39
  /** Gemelo private de agentGetPeopleByDirectoryId (con masking del manager). */
53
40
  privateGetPeopleByDirectoryId(directoryId: string): Promise<LegacyApiResponse<PeopleResponse>>;
54
41
  /** Gemelo private de getUserDocumentsAgents (último documento). */
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@fiado/api-invoker",
3
- "version": "5.6.0",
3
+ "version": "5.7.0",
4
4
  "description": "Sirve como un puente entre diferentes funciones lambda, facilitando la comunicación entre ellas a través de invocaciones http",
5
5
  "type": "module",
6
6
  "main": "bin/index.js",
@@ -34,7 +34,7 @@
34
34
  "@fiado/gateway-adapter": "^3.9.0",
35
35
  "@fiado/http-client": "^2.0.1",
36
36
  "@fiado/logger": "^1.1.3",
37
- "@fiado/type-kit": "^3.225.0",
37
+ "@fiado/type-kit": "^3.224.0",
38
38
  "dotenv": "^16.4.7"
39
39
  },
40
40
  "peerDependencies": {
@@ -6,7 +6,6 @@ import dotenv from 'dotenv';
6
6
  import {
7
7
  PeopleUpdateRequest, UploadDocumentRequest, PeopleResponse,
8
8
  PeopleSelfVerifiedRequest, AgentDocumentKeyResponse, DocumentUploadResponse,
9
- PeopleSelfieResponse,
10
9
  } from "@fiado/type-kit/bin/identity/index.js";
11
10
 
12
11
  dotenv.config();
@@ -99,14 +98,6 @@ export class IdentityApi implements IIdentityApi {
99
98
  return await this.httpRequest.get(url);
100
99
  }
101
100
 
102
- async privateGetPeopleSelfie(directoryId: string): Promise<LegacyApiResponse<PeopleSelfieResponse>> {
103
- if (!directoryId) {
104
- throw new Error("Directory ID is required.")
105
- }
106
- const url = `${this.baseUrl}identities/private/people/${encodeURIComponent(directoryId)}/selfie`;
107
- return await this.httpRequest.get<LegacyApiResponse<PeopleSelfieResponse>>(url);
108
- }
109
-
110
101
  // ── Gemelos PRIVATE de los endpoints de agentes (proxy RBAC v2, DEC-PROT-011) ──
111
102
  // Retornan el ENVELOPE legacy completo (httpRequest devuelve response.data = el body de identity),
112
103
  // para que el proxy /v2 de people-business lo re-emita campo por campo (drop-in, sin doble-wrap).
@@ -1,7 +1,6 @@
1
1
  import {
2
2
  PeopleUpdateRequest, UploadDocumentRequest, PeopleResponse,
3
3
  PeopleSelfVerifiedRequest, AgentDocumentKeyResponse, DocumentUploadResponse,
4
- PeopleSelfieResponse,
5
4
  } from "@fiado/type-kit/bin/identity/index.js";
6
5
  import { LegacyApiResponse } from "./LegacyApiResponse.js";
7
6
 
@@ -49,20 +48,6 @@ export interface IIdentityApi {
49
48
  */
50
49
  getUserDocuments(directoryId: string): Promise<any>
51
50
 
52
- /**
53
- * Selfie guardada del usuario: devuelve una URL firmada temporal (no la imagen).
54
- *
55
- * Pensado para el facematch de Metamap contra la merchant database: la `url` se pasa a
56
- * `IMetamapConnectorApi.buildFacematchSignature` para obtener el `userPhotoLinkHash`, y el par
57
- * va en el `metadata` de la verificación con `customInput: true`. El presigned vence
58
- * (`expiresInSeconds`), así que la firma y el disparo del facematch van dentro de esa ventana.
59
- *
60
- * Devuelve el envelope legacy completo porque el resultado se discrimina por `code`, no por
61
- * status: `PROCESS_OK` con la selfie, `SELFIE_NOT_FOUND` si el usuario tiene cuenta pero no hay
62
- * imagen (el toolkit lo emite como HTTP 200). Sin cuenta, el endpoint responde 401 `NO_ACCOUNT`.
63
- */
64
- privateGetPeopleSelfie(directoryId: string): Promise<LegacyApiResponse<PeopleSelfieResponse>>
65
-
66
51
  // ── Gemelos PRIVATE de los endpoints de agentes (proxy RBAC v2, DEC-PROT-011) ──
67
52
  // Devuelven el ENVELOPE legacy completo (LegacyApiResponse) tal como lo emite identity,
68
53
  // para que el proxy /v2 de people-business lo re-emita campo por campo (drop-in exacto, sin doble-wrap).