@ajna-inc/workflow 0.6.7 → 0.6.8
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.
- package/.npmvc/attestations.jsonld +8 -8
- package/.npmvc/sbom.cdx.json +3 -3
- package/build/actions/ActionRegistry.d.mts.map +1 -1
- package/build/actions/ActionRegistry.mjs +8 -1
- package/build/actions/ActionRegistry.mjs.map +1 -1
- package/build/protocol/messages/CancelMessage.d.mts +2 -2
- package/build/protocol/messages/CompleteMessage.d.mts +2 -2
- package/build/protocol/messages/DiscoverMessage.d.mts +2 -2
- package/build/protocol/messages/DiscoverMessage.d.mts.map +1 -1
- package/build/protocol/messages/PauseMessage.d.mts +2 -2
- package/build/protocol/messages/ProblemReportMessage.d.mts +2 -2
- package/build/protocol/messages/PublishTemplateMessage.d.mts +2 -2
- package/build/protocol/messages/StartMessage.d.mts +2 -2
- package/build/protocol/messages/StatusMessage.d.mts +2 -2
- package/build/protocol/messages/StatusRequestMessage.d.mts +2 -2
- package/build/protocol/messages/WorkflowsMessage.d.mts +2 -2
- package/build/protocol/messages/WorkflowsMessage.d.mts.map +1 -1
- package/package.json +1 -1
|
@@ -2,40 +2,40 @@
|
|
|
2
2
|
"schema": "https://npmvc.com/schemas/attestation-bundle/v1",
|
|
3
3
|
"package": {
|
|
4
4
|
"name": "@ajna-inc/workflow",
|
|
5
|
-
"version": "0.6.
|
|
5
|
+
"version": "0.6.8"
|
|
6
6
|
},
|
|
7
|
-
"bundledAt": "2026-05-
|
|
7
|
+
"bundledAt": "2026-05-01T18:25:01.146Z",
|
|
8
8
|
"envelopes": [
|
|
9
9
|
{
|
|
10
10
|
"payloadType": "application/vc+json",
|
|
11
|
-
"payload": "
|
|
11
|
+
"payload": "eyJAY29udGV4dCI6WyJodHRwczovL3d3dy53My5vcmcvbnMvY3JlZGVudGlhbHMvdjIiLCJodHRwczovL25wbXZjLmNvbS9zY2hlbWFzL3N1cHBseWNoYWluL3YxIl0sImNyZ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|
+
"sig": "Yg098Q4cTJ8mTfFCrHNhUctLOiDKn/mdgPjSgvfRLXa4jkYElII0Db2AyXkqg+ID39yl8XoA04CaAtElXZr2DA=="
|
|
17
17
|
}
|
|
18
18
|
]
|
|
19
19
|
},
|
|
20
20
|
{
|
|
21
21
|
"payloadType": "application/vc+json",
|
|
22
|
-
"payload": "
|
|
22
|
+
"payload": "eyJAY29udGV4dCI6WyJodHRwczovL3d3dy53My5vcmcvbnMvY3JlZGVudGlhbHMvdjIiLCJodHRwczovL25wbXZjLmNvbS9zY2hlbWFzL3N1cHBseWNoYWluL3YxIl0sImNyZWRlbnRpYWxTdWJqZWN0Ijp7ImRlY2xhcmVkU2NyaXB0cyI6WyJidWlsZCIsInByZXB1Ymxpc2hPbmx5IiwiY2xlYW4iLCJwcmVwYWNrIl0sImlkIjoicGtnOm5wbS9AYWpuYS1pbmMvd29ya2Zsb3dAMC42LjgiLCJwb3N0SW5zdGFsbFBvbGljeSI6ImZvcmJpZGRlbiIsInRhcmJhbGwiOnsiZGlnZXN0Ijp7fSwibmFtZSI6IkBham5hLWluYy93b3JrZmxvdyIsInZlcnNpb24iOiIwLjYuOCJ9LCJ3aGl0ZWxpc3RlZFNjcmlwdHMiOltdfSwiaWQiOiJ1cm46dXVpZDo3OGNiNzM2OS04MTU3LTRjNDctYjZjOC0xM2I3ZGUxZGRjY2UiLCJpc3N1ZXIiOiJkaWQ6a2V5Ono2TWtoSjVZQlNkQkxISEpiamk0NWtpSm5SZExVRFB1VFZpN2RQODRNalN1RXVjbyIsInR5cGUiOlsiVmVyaWZpYWJsZUNyZWRlbnRpYWwiLCJMaWZlY3ljbGVQb2xpY3lDcmVkZW50aWFsIl0sInZhbGlkRnJvbSI6IjIwMjYtMDUtMDFUMTg6MjU6MDAuOTE0WiJ9",
|
|
23
23
|
"signatures": [
|
|
24
24
|
{
|
|
25
25
|
"keyid": "did:key:z6MkhJ5YBSdBLHHJbji45kiJnRdLUDPuTVi7dP84MjSuEuco#z6MkhJ5YBSdBLHHJbji45kiJnRdLUDPuTVi7dP84MjSuEuco",
|
|
26
26
|
"alg": "Ed25519",
|
|
27
|
-
"sig": "
|
|
27
|
+
"sig": "tyThCSr59cJ3GLwK63Ko4goI/DI5GiLQcukiLOp4vkYa/dT/fHUwl70rv9AYNzcgmKQfcflBgvCoSdjNqe7DCQ=="
|
|
28
28
|
}
|
|
29
29
|
]
|
|
30
30
|
},
|
|
31
31
|
{
|
|
32
32
|
"payloadType": "application/vc+json",
|
|
33
|
-
"payload": "
|
|
33
|
+
"payload": "eyJAY29udGV4dCI6WyJodHRwczovL3d3dy53My5vcmcvbnMvY3JlZGVudGlhbHMvdjIiLCJodHRwczovL25wbXZjLmNvbS9zY2hlbWFzL3N1cHBseWNoYWluL3YxIl0sImNyZWRlbnRpYWxTdWJqZWN0Ijp7ImZvcm1hdCI6ImN5Y2xvbmVkeC0xLjYiLCJpZCI6InBrZzpucG0vQGFqbmEtaW5jL3dvcmtmbG93QDAuNi44Iiwic2JvbURpZ2VzdCI6eyJhbGciOiJzaGEyNTYiLCJoZXgiOiJkNDJlOTY4ZDFkZTVkNGM0MjE4ZDc2OGJkMGZjYjE5OWQzOTJiMzY3ZmE0ZjJmMzQ5NTZiYzg3MDRiMWVjZmZhIn0sInNib21VcmwiOiIuLy5ucG12Yy9zYm9tLmNkeC5qc29uIiwidGFyYmFsbCI6eyJkaWdlc3QiOnt9LCJuYW1lIjoiQGFqbmEtaW5jL3dvcmtmbG93IiwidmVyc2lvbiI6IjAuNi44In19LCJpZCI6InVybjp1dWlkOjg5MmFhOTU2LTI5MjktNDQ0NS1iY2E1LTM2MDcxYmRjZmRiZiIsImlzc3VlciI6ImRpZDprZXk6ejZNa2hKNVlCU2RCTEhISmJqaTQ1a2lKblJkTFVEUHVUVmk3ZFA4NE1qU3VFdWNvIiwidHlwZSI6WyJWZXJpZmlhYmxlQ3JlZGVudGlhbCIsIlNib21DcmVkZW50aWFsIl0sInZhbGlkRnJvbSI6IjIwMjYtMDUtMDFUMTg6MjU6MDEuMTQ2WiJ9",
|
|
34
34
|
"signatures": [
|
|
35
35
|
{
|
|
36
36
|
"keyid": "did:key:z6MkhJ5YBSdBLHHJbji45kiJnRdLUDPuTVi7dP84MjSuEuco#z6MkhJ5YBSdBLHHJbji45kiJnRdLUDPuTVi7dP84MjSuEuco",
|
|
37
37
|
"alg": "Ed25519",
|
|
38
|
-
"sig": "
|
|
38
|
+
"sig": "nt3v86E6irAhMnDgRPWlo6EMIjAhMq3Ej+3I5hByjD9P+Utm91tGBtXdA6GgVwVRcZsTzSuOjGtqsdOgZB2EAw=="
|
|
39
39
|
}
|
|
40
40
|
]
|
|
41
41
|
}
|
package/.npmvc/sbom.cdx.json
CHANGED
|
@@ -3,12 +3,12 @@
|
|
|
3
3
|
"specVersion": "1.6",
|
|
4
4
|
"version": 1,
|
|
5
5
|
"metadata": {
|
|
6
|
-
"timestamp": "2026-05-
|
|
6
|
+
"timestamp": "2026-05-01T18:25:01.141Z",
|
|
7
7
|
"component": {
|
|
8
8
|
"type": "application",
|
|
9
9
|
"name": "@ajna-inc/workflow",
|
|
10
|
-
"version": "0.6.
|
|
11
|
-
"purl": "pkg:npm/%40ajna-inc/workflow@0.6.
|
|
10
|
+
"version": "0.6.8",
|
|
11
|
+
"purl": "pkg:npm/%40ajna-inc/workflow@0.6.8"
|
|
12
12
|
},
|
|
13
13
|
"tools": [
|
|
14
14
|
{
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"ActionRegistry.d.mts","names":[],"sources":["../../src/actions/ActionRegistry.ts"],"sourcesContent":[],"mappings":";;;;KASY,SAAA;gBACI;EADJ,QAAA,EAEA,gBAFS;EACL,QAAA,EAEJ,oBAFI;EACJ,MAAA,EAEF,SAFE;EACA,KAAA,CAAA,EAEF,MAFE,CAAA,MAAA,EAAA,OAAA,CAAA;CACF;AACA,KAGE,YAAA,GAHF;EAAM,SAAA,CAAA,EAIF,MAJE,CAAA,MAAA,EAAA,OAAA,CAAA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YAA+B,qBAAqB,CAAA;EA0DpD,SAAA,OAAA,GAAA,kDAAwB;EAET,OAAA,CAAA,GAAA,EA1DA,SA0DA,CAAA,EA1DY,OA0DZ,CA1DoB,YA0DpB,CAAA;;AAAY,cAF3B,uBAAA,YAAmC,qBAER,CAAA;EAFQ,SAAA,OAAA,GAAA,2DAAA;EAAqB,OAAA,CAAA,GAAA,EAEzC,SAFyC,CAAA,EAE7B,OAF6B,CAErB,YAFqB,CAAA;AA2DrE;;;;;AAAuE,cAA1D,yBAAA,YAAqC,qBAAqB,CAAA;EAkE1D,SAAA,OAAA,GAAA,6DAA0B;EAGX,OAAA,CAAA,GAAA,EAlEA,SAkEA,CAAA,EAlEY,OAkEZ,CAlEoB,YAkEpB,CAAA;;;;;AA4D5B;AAG4B,cAlEf,yBAAA,YAAqC,qBAkEtB,CAAA;EAAoB,SAAA,OAAA,GAAA,6DAAA;EAAR,OAAA,CAAA,GAAA,EA/DZ,SA+DY,CAAA,EA/DA,OA+DA,CA/DQ,YA+DR,CAAA;;;AAsDxC;;;AAEwC,cA3D3B,8BAAA,YAA0C,qBA2Df,CAAA;EAFK,SAAA,OAAA,GAAA,2DAAA;EAAqB,OAAA,CAAA,GAAA,EAtDtC,SAsDsC,CAAA,EAtD1B,OAsD0B,CAtDlB,YAsDkB,CAAA;;cAArD,oBAAA,YAAgC;;eAEjB,YAAY,QAAQ"}
|
|
@@ -60,7 +60,14 @@ var LocalStateSetAction = class {
|
|
|
60
60
|
participants: ctx.instance.participants || {},
|
|
61
61
|
artifacts: ctx.instance.artifacts || {}
|
|
62
62
|
};
|
|
63
|
-
if (merge
|
|
63
|
+
if (typeof merge === "string") {
|
|
64
|
+
const match = merge.match(/^\{\{\s*(.+?)\s*\}\}$/);
|
|
65
|
+
if (match) {
|
|
66
|
+
const resolved = resolvePath(env, match[1]);
|
|
67
|
+
if (resolved !== void 0) merge = resolved;
|
|
68
|
+
}
|
|
69
|
+
}
|
|
70
|
+
if (merge !== void 0 && typeof merge !== "string") merge = substituteTemplates(merge, env);
|
|
64
71
|
if (typeof merge === "string") {
|
|
65
72
|
const trimmed = merge.replace(/\{\{|\}\}/g, "").trim();
|
|
66
73
|
if (trimmed.includes(".")) {
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"ActionRegistry.mjs","names":["cur: unknown","out: Record<string, unknown>","merge: unknown","env: Record<string, unknown>","mergeObj: Record<string, unknown> | undefined","ref: string","messageId: string | undefined"],"sources":["../../src/actions/ActionRegistry.ts"],"sourcesContent":["import type { ActionDef, WorkflowInstanceData, WorkflowTemplate } from '../model/types'\nimport type { AgentContext } from '@credo-ts/core'\n\nimport { DidCommCredentialsApi, DidCommProofsApi } from '@credo-ts/didcomm'\n\nimport { DidCommConnectionService } from '@credo-ts/didcomm'\n\nimport { AttributePlanner, deepMerge } from '../engine/AttributePlanner'\n\nexport type ActionCtx = {\n agentContext: AgentContext\n template: WorkflowTemplate\n instance: WorkflowInstanceData\n action: ActionDef\n input?: Record<string, unknown>\n}\n\nexport type ActionResult = {\n artifacts?: Record<string, unknown>\n contextMerge?: Record<string, unknown>\n messageId?: string\n}\n\nexport interface WorkflowActionHandler {\n readonly typeUri: string\n execute(ctx: ActionCtx): Promise<ActionResult>\n}\n\nexport class ActionRegistry {\n private handlers = new Map<string, WorkflowActionHandler>()\n public register(handler: WorkflowActionHandler) {\n this.handlers.set(handler.typeUri, handler)\n }\n public get(typeUri: string): WorkflowActionHandler | undefined {\n return this.handlers.get(typeUri)\n }\n}\n\n// Template interpolation helpers (ported from Credo 5)\nconst TPL_RE = /\\{\\{\\s*([^}]+?)\\s*\\}\\}/g\n\nconst resolvePath = (env: Record<string, unknown>, expr: string): unknown => {\n const parts = expr.trim().split('.')\n let cur: unknown = env\n for (const p of parts) {\n if (cur == null || typeof cur !== 'object') return undefined\n cur = (cur as Record<string, unknown>)[p]\n }\n return cur\n}\n\nconst interpolateString = (s: string, env: Record<string, unknown>): string => {\n TPL_RE.lastIndex = 0\n if (!TPL_RE.test(s)) return s\n TPL_RE.lastIndex = 0\n return s.replace(TPL_RE, (_, expr: string) => {\n const v = resolvePath(env, expr)\n return v == null ? '' : String(v)\n })\n}\n\nconst substituteTemplates = (node: unknown, env: Record<string, unknown>): unknown => {\n if (typeof node === 'string') return interpolateString(node, env)\n if (Array.isArray(node)) return node.map((x) => substituteTemplates(x, env))\n if (node && typeof node === 'object') {\n const out: Record<string, unknown> = {}\n for (const [k, v] of Object.entries(node as Record<string, unknown>)) {\n const newKey = typeof k === 'string' ? interpolateString(k, env) : k\n out[newKey] = substituteTemplates(v, env)\n }\n return out\n }\n return node\n}\n\nexport class LocalStateSetAction implements WorkflowActionHandler {\n public readonly typeUri = 'https://didcomm.org/workflow/actions/state:set@1'\n public async execute(ctx: ActionCtx): Promise<ActionResult> {\n const raw = (ctx.action as { staticInput?: unknown })?.staticInput\n // Accept {merge:{...}} (legacy) or a plain object/string (preferred).\n let merge: unknown = raw\n if (raw && typeof raw === 'object' && !Array.isArray(raw) && 'merge' in (raw as object)) {\n merge = (raw as { merge?: unknown }).merge\n }\n\n const env: Record<string, unknown> = {\n input: (ctx.input as Record<string, unknown>) || {},\n context: (ctx.instance.context as Record<string, unknown>) || {},\n context_data: (ctx.instance.context as Record<string, unknown>) || {},\n participants: (ctx.instance.participants as Record<string, unknown>) || {},\n artifacts: (ctx.instance.artifacts as Record<string, unknown>) || {},\n }\n\n // Substitute {{...}} in keys + values throughout the merge tree.\n if (merge !== undefined) merge = substituteTemplates(merge, env)\n\n // String fallback: '{{ input.form }}' resolves to an object subtree.\n if (typeof merge === 'string') {\n const trimmed = merge.replace(/\\{\\{|\\}\\}/g, '').trim()\n if (trimmed.includes('.')) {\n const resolved = resolvePath(env, trimmed)\n if (resolved && typeof resolved === 'object') merge = resolved\n }\n }\n\n let mergeObj: Record<string, unknown> | undefined\n if (merge && typeof merge === 'object' && !Array.isArray(merge)) {\n mergeObj = merge as Record<string, unknown>\n }\n\n // Match the Python plugin: advance input merges on top of staticInput.\n if (ctx.input && typeof ctx.input === 'object' && !Array.isArray(ctx.input)) {\n mergeObj = deepMerge({ ...(mergeObj || {}) }, ctx.input as Record<string, unknown>)\n }\n\n if (mergeObj && Object.keys(mergeObj).length > 0) {\n const next = deepMerge({ ...(ctx.instance.context || {}) }, mergeObj)\n return { contextMerge: next }\n }\n return {}\n }\n}\n\nexport class IssueCredentialV2Action implements WorkflowActionHandler {\n public readonly typeUri = 'https://didcomm.org/issue-credential/2.0/offer-credential'\n public async execute(ctx: ActionCtx): Promise<ActionResult> {\n const act = ctx.action as { profile_ref: string }\n const ref: string = act.profile_ref\n if (!ref?.startsWith('cp.')) throw Object.assign(new Error('invalid profile_ref'), { code: 'action_error' })\n const key = ref.slice(3)\n const profile = ctx.template.catalog?.credential_profiles?.[key]\n if (!profile) throw Object.assign(new Error('missing catalog profile'), { code: 'action_error' })\n const attrs = AttributePlanner.materialize(profile.attribute_plan || {}, ctx.instance)\n const attributes = Object.entries(attrs).map(([name, value]) => ({ name, value: String(value) }))\n const connectionId = ctx.instance.connection_id\n if (!connectionId) throw Object.assign(new Error('connectionId required'), { code: 'action_error' })\n // Enforce to_ref recipient DID against connection counterparty DID (if available)\n {\n const toRef = profile.to_ref\n const expectedDid = toRef ? ctx.instance.participants?.[toRef]?.did : undefined\n if (expectedDid && ctx.instance.connection_id) {\n const connSvc = ctx.agentContext.dependencyManager.resolve(DidCommConnectionService)\n const conn = await connSvc.getById(ctx.agentContext, ctx.instance.connection_id)\n const theirDid = (conn as unknown as { theirDid?: string })?.theirDid\n if (theirDid && theirDid !== expectedDid)\n throw Object.assign(new Error('to_ref DID mismatch'), { code: 'forbidden' })\n }\n }\n try {\n const credsApi = ctx.agentContext.dependencyManager.resolve(DidCommCredentialsApi) as unknown as {\n offerCredential: (options: unknown) => Promise<{ id: string; credentialRecord?: { id?: string } }>\n findOfferMessage: (id: string) => Promise<unknown>\n }\n const record = await credsApi.offerCredential({\n connectionId,\n protocolVersion: 'v2',\n credentialFormats: { anoncreds: { credentialDefinitionId: profile.cred_def_id, attributes } },\n comment: profile.options?.comment,\n })\n let messageId: string | undefined = record?.id || record?.credentialRecord?.id\n try {\n if (messageId) {\n const found = (await credsApi.findOfferMessage(messageId)) as unknown\n if (found && typeof found === 'object') {\n const f = found as { id?: string; message?: { id?: string } }\n messageId = f.message?.id || f.id || messageId\n }\n }\n } catch (_e) {\n void 0\n }\n return { artifacts: { issueRecordId: record?.id || record?.credentialRecord?.id }, messageId }\n } catch (e) {\n throw Object.assign(new Error(`issue action error: ${(e as Error).message}`), { code: 'action_error' })\n }\n }\n}\n\n/**\n * ProposeCredentialV2Action - Holder proposes a credential to the issuer\n * Used when holder initiates the credential issuance flow\n */\nexport class ProposeCredentialV2Action implements WorkflowActionHandler {\n public readonly typeUri = 'https://didcomm.org/issue-credential/2.0/propose-credential'\n\n public async execute(ctx: ActionCtx): Promise<ActionResult> {\n const act = ctx.action as { profile_ref: string }\n const ref: string = act.profile_ref\n if (!ref?.startsWith('cp.')) throw Object.assign(new Error('invalid profile_ref'), { code: 'action_error' })\n\n const key = ref.slice(3)\n const profile = ctx.template.catalog?.credential_profiles?.[key]\n if (!profile) throw Object.assign(new Error('missing catalog profile'), { code: 'action_error' })\n\n // Materialize attributes from context using attribute_plan\n const attrs = AttributePlanner.materialize(profile.attribute_plan || {}, ctx.instance)\n const attributes = Object.entries(attrs).map(([name, value]) => ({ name, value: String(value) }))\n\n const connectionId = ctx.instance.connection_id\n if (!connectionId) throw Object.assign(new Error('connectionId required'), { code: 'action_error' })\n\n try {\n const credsApi = ctx.agentContext.dependencyManager.resolve(DidCommCredentialsApi) as unknown as {\n proposeCredential: (options: unknown) => Promise<{ id: string; credentialRecord?: { id?: string } }>\n findProposalMessage: (id: string) => Promise<unknown>\n }\n\n const record = await credsApi.proposeCredential({\n connectionId,\n protocolVersion: 'v2',\n credentialFormats: {\n anoncreds: {\n credentialDefinitionId: profile.cred_def_id,\n attributes,\n },\n },\n comment: profile.options?.comment,\n })\n\n // Extract message ID for correlation\n let messageId: string | undefined = record?.id || record?.credentialRecord?.id\n try {\n if (messageId) {\n const found = await credsApi.findProposalMessage(messageId)\n if (found && typeof found === 'object') {\n const f = found as { id?: string; message?: { id?: string } }\n messageId = f.message?.id || f.id || messageId\n }\n }\n } catch (_e) {\n void 0\n }\n\n // Store record ID in artifacts for later actions to find\n return {\n artifacts: { credentialRecordId: record?.id || record?.credentialRecord?.id },\n messageId,\n }\n } catch (e) {\n throw Object.assign(new Error(`propose action error: ${(e as Error).message}`), { code: 'action_error' })\n }\n }\n}\n\n/**\n * RequestCredentialV2Action - Holder accepts a credential offer\n * Used when holder receives an offer and wants to request the credential\n */\nexport class RequestCredentialV2Action implements WorkflowActionHandler {\n public readonly typeUri = 'https://didcomm.org/issue-credential/2.0/request-credential'\n\n public async execute(ctx: ActionCtx): Promise<ActionResult> {\n const connectionId = ctx.instance.connection_id\n if (!connectionId) throw Object.assign(new Error('connectionId required'), { code: 'action_error' })\n\n try {\n const credsApi = ctx.agentContext.dependencyManager.resolve(DidCommCredentialsApi) as unknown as {\n acceptOffer: (options: { credentialRecordId: string }) => Promise<{ id: string }>\n getAll: () => Promise<Array<{ id: string; connectionId?: string; state: string; updatedAt?: Date }>>\n findRequestMessage: (id: string) => Promise<unknown>\n }\n\n // Find the credential record with OfferReceived state for this connection\n // Option 1: Check artifacts for stored credentialRecordId\n let credentialRecordId = ctx.instance.artifacts?.credentialRecordId as string | undefined\n\n // Option 2: Query by connection + state if not in artifacts\n if (!credentialRecordId) {\n const all = await credsApi.getAll()\n const matches = all\n .filter((r) => r.connectionId === connectionId && r.state === 'offer-received')\n .sort((a, b) => {\n const dateA = a.updatedAt ? new Date(a.updatedAt).getTime() : 0\n const dateB = b.updatedAt ? new Date(b.updatedAt).getTime() : 0\n return dateB - dateA // Most recent first\n })\n if (matches.length === 0) {\n throw Object.assign(new Error('no offer found to accept'), { code: 'action_error' })\n }\n credentialRecordId = matches[0].id\n }\n\n const record = await credsApi.acceptOffer({ credentialRecordId })\n\n let messageId: string | undefined = record?.id\n try {\n if (messageId) {\n const found = await credsApi.findRequestMessage(messageId)\n if (found && typeof found === 'object') {\n const f = found as { id?: string; message?: { id?: string } }\n messageId = f.message?.id || f.id || messageId\n }\n }\n } catch (_e) {\n void 0\n }\n\n return {\n artifacts: { credentialRecordId: record?.id },\n messageId,\n }\n } catch (e) {\n throw Object.assign(new Error(`request action error: ${(e as Error).message}`), { code: 'action_error' })\n }\n }\n}\n\n/**\n * IssueCredentialMessageV2Action - Issuer issues the credential after receiving a request\n * Used when issuer receives a credential request and wants to issue the credential\n */\nexport class IssueCredentialMessageV2Action implements WorkflowActionHandler {\n public readonly typeUri = 'https://didcomm.org/issue-credential/2.0/issue-credential'\n\n public async execute(ctx: ActionCtx): Promise<ActionResult> {\n const connectionId = ctx.instance.connection_id\n if (!connectionId) throw Object.assign(new Error('connectionId required'), { code: 'action_error' })\n\n try {\n const credsApi = ctx.agentContext.dependencyManager.resolve(DidCommCredentialsApi) as unknown as {\n acceptRequest: (options: { credentialRecordId: string }) => Promise<{ id: string }>\n getAll: () => Promise<Array<{ id: string; connectionId?: string; state: string; updatedAt?: Date }>>\n findCredentialMessage: (id: string) => Promise<unknown>\n }\n\n // Find the credential record with RequestReceived state for this connection\n let credentialRecordId = ctx.instance.artifacts?.credentialRecordId as string | undefined\n\n if (!credentialRecordId) {\n const all = await credsApi.getAll()\n const matches = all\n .filter((r) => r.connectionId === connectionId && r.state === 'request-received')\n .sort((a, b) => {\n const dateA = a.updatedAt ? new Date(a.updatedAt).getTime() : 0\n const dateB = b.updatedAt ? new Date(b.updatedAt).getTime() : 0\n return dateB - dateA // Most recent first\n })\n if (matches.length === 0) {\n throw Object.assign(new Error('no request found to issue'), { code: 'action_error' })\n }\n credentialRecordId = matches[0].id\n }\n\n const record = await credsApi.acceptRequest({ credentialRecordId })\n\n let messageId: string | undefined = record?.id\n try {\n if (messageId) {\n const found = await credsApi.findCredentialMessage(messageId)\n if (found && typeof found === 'object') {\n const f = found as { id?: string; message?: { id?: string } }\n messageId = f.message?.id || f.id || messageId\n }\n }\n } catch (_e) {\n void 0\n }\n\n return {\n artifacts: { issuedCredentialRecordId: record?.id },\n messageId,\n }\n } catch (e) {\n throw Object.assign(new Error(`issue action error: ${(e as Error).message}`), { code: 'action_error' })\n }\n }\n}\n\nexport class PresentProofV2Action implements WorkflowActionHandler {\n public readonly typeUri = 'https://didcomm.org/present-proof/2.0/request-presentation'\n public async execute(ctx: ActionCtx): Promise<ActionResult> {\n const act = ctx.action as { profile_ref: string }\n const ref: string = act.profile_ref\n if (!ref?.startsWith('pp.')) throw Object.assign(new Error('invalid profile_ref'), { code: 'action_error' })\n const key = ref.slice(3)\n const profile = ctx.template.catalog?.proof_profiles?.[key]\n if (!profile) throw Object.assign(new Error('missing catalog profile'), { code: 'action_error' })\n const connectionId = ctx.instance.connection_id\n if (!connectionId) throw Object.assign(new Error('connectionId required'), { code: 'action_error' })\n // Enforce to_ref recipient DID against connection counterparty DID (if available)\n {\n const toRef2 = profile.to_ref\n const expectedDid2 = toRef2 ? ctx.instance.participants?.[toRef2]?.did : undefined\n if (expectedDid2 && ctx.instance.connection_id) {\n const connSvc = ctx.agentContext.dependencyManager.resolve(DidCommConnectionService)\n const conn = await connSvc.getById(ctx.agentContext, ctx.instance.connection_id)\n const theirDid = (conn as unknown as { theirDid?: string })?.theirDid\n if (theirDid && theirDid !== expectedDid2)\n throw Object.assign(new Error('to_ref DID mismatch'), { code: 'forbidden' })\n }\n }\n try {\n const proofsApi = ctx.agentContext.dependencyManager.resolve(DidCommProofsApi) as unknown as {\n requestProof: (options: unknown) => Promise<{ id: string; proofRecord?: { id?: string } }>\n findRequestMessage: (id: string) => Promise<unknown>\n }\n const credDefId = (profile as { cred_def_id?: string }).cred_def_id\n const schemaId = (profile as { schema_id?: string }).schema_id\n const restriction = credDefId ? { cred_def_id: credDefId } : schemaId ? { schema_id: schemaId } : undefined\n\n const reqAttrs = (profile.requested_attributes || []).reduce<Record<string, unknown>>(\n (acc, name: string, idx: number) => {\n acc[`attr${idx + 1}`] = restriction ? { name, restrictions: [restriction] } : { name }\n return acc\n },\n {}\n )\n const reqPreds = (profile.requested_predicates || []).reduce<Record<string, unknown>>(\n (acc, p: { name: string; p_type: string; p_value: number }, idx: number) => {\n acc[`pred${idx + 1}`] = restriction\n ? { name: p.name, p_type: p.p_type, p_value: p.p_value, restrictions: [restriction] }\n : { name: p.name, p_type: p.p_type, p_value: p.p_value }\n return acc\n },\n {}\n )\n const record = await proofsApi.requestProof({\n connectionId,\n protocolVersion: 'v2',\n proofFormats: {\n anoncreds: {\n name: 'Workflow Proof Request',\n version: '1.0',\n requested_attributes: reqAttrs,\n requested_predicates: reqPreds,\n },\n },\n willConfirm: true,\n comment: profile.options?.comment,\n })\n let messageId: string | undefined = record?.id || record?.proofRecord?.id\n try {\n if (messageId) {\n const found = (await proofsApi.findRequestMessage(messageId)) as unknown\n if (found && typeof found === 'object') {\n const f = found as { id?: string; message?: { id?: string } }\n messageId = f.message?.id || f.id || messageId\n }\n }\n } catch (_e) {\n void 0\n }\n return { artifacts: { proofRecordId: record?.id || record?.proofRecord?.id }, messageId }\n } catch (e) {\n throw Object.assign(new Error(`proof action error: ${(e as Error).message}`), { code: 'action_error' })\n }\n }\n}\n"],"mappings":";;;;AA4BA,IAAa,iBAAb,MAA4B;;OAClB,2BAAW,IAAI,KAAoC;;CAC3D,AAAO,SAAS,SAAgC;AAC9C,OAAK,SAAS,IAAI,QAAQ,SAAS,QAAQ;;CAE7C,AAAO,IAAI,SAAoD;AAC7D,SAAO,KAAK,SAAS,IAAI,QAAQ;;;AAKrC,MAAM,SAAS;AAEf,MAAM,eAAe,KAA8B,SAA0B;CAC3E,MAAM,QAAQ,KAAK,MAAM,CAAC,MAAM,IAAI;CACpC,IAAIA,MAAe;AACnB,MAAK,MAAM,KAAK,OAAO;AACrB,MAAI,OAAO,QAAQ,OAAO,QAAQ,SAAU,QAAO;AACnD,QAAO,IAAgC;;AAEz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AAc,CAAC,YAAY;KAAE,GACnF;KAAE,MAAM,EAAE;KAAM,QAAQ,EAAE;KAAQ,SAAS,EAAE;KAAS;AAC1D,WAAO;MAET,EAAE,CACH;GACD,MAAM,SAAS,MAAM,UAAU,aAAa;IAC1C;IACA,iBAAiB;IACjB,cAAc,EACZ,WAAW;KACT,MAAM;KACN,SAAS;KACT,sBAAsB;KACtB,sBAAsB;KACvB,EACF;IACD,aAAa;IACb,SAAS,QAAQ,SAAS;IAC3B,CAAC;GACF,IAAIC,YAAgC,QAAQ,MAAM,QAAQ,aAAa;AACvE,OAAI;AACF,QAAI,WAAW;KACb,MAAM,QAAS,MAAM,UAAU,mBAAmB,UAAU;AAC5D,SAAI,SAAS,OAAO,UAAU,UAAU;MACtC,MAAM,IAAI;AACV,kBAAY,EAAE,SAAS,MAAM,EAAE,MAAM;;;YAGlC,IAAI;AAGb,UAAO;IAAE,WAAW,EAAE,eAAe,QAAQ,MAAM,QAAQ,aAAa,IAAI;IAAE;IAAW;WAClF,GAAG;AACV,SAAM,OAAO,uBAAO,IAAI,MAAM,uBAAwB,EAAY,UAAU,EAAE,EAAE,MAAM,gBAAgB,CAAC"}
|
|
1
|
+
{"version":3,"file":"ActionRegistry.mjs","names":["cur: unknown","out: Record<string, unknown>","merge: unknown","env: Record<string, unknown>","mergeObj: Record<string, unknown> | undefined","ref: string","messageId: string | undefined"],"sources":["../../src/actions/ActionRegistry.ts"],"sourcesContent":["import type { ActionDef, WorkflowInstanceData, WorkflowTemplate } from '../model/types'\nimport type { AgentContext } from '@credo-ts/core'\n\nimport { DidCommCredentialsApi, DidCommProofsApi } from '@credo-ts/didcomm'\n\nimport { DidCommConnectionService } from '@credo-ts/didcomm'\n\nimport { AttributePlanner, deepMerge } from '../engine/AttributePlanner'\n\nexport type ActionCtx = {\n agentContext: AgentContext\n template: WorkflowTemplate\n instance: WorkflowInstanceData\n action: ActionDef\n input?: Record<string, unknown>\n}\n\nexport type ActionResult = {\n artifacts?: Record<string, unknown>\n contextMerge?: Record<string, unknown>\n messageId?: string\n}\n\nexport interface WorkflowActionHandler {\n readonly typeUri: string\n execute(ctx: ActionCtx): Promise<ActionResult>\n}\n\nexport class ActionRegistry {\n private handlers = new Map<string, WorkflowActionHandler>()\n public register(handler: WorkflowActionHandler) {\n this.handlers.set(handler.typeUri, handler)\n }\n public get(typeUri: string): WorkflowActionHandler | undefined {\n return this.handlers.get(typeUri)\n }\n}\n\n// Template interpolation helpers (ported from Credo 5)\nconst TPL_RE = /\\{\\{\\s*([^}]+?)\\s*\\}\\}/g\n\nconst resolvePath = (env: Record<string, unknown>, expr: string): unknown => {\n const parts = expr.trim().split('.')\n let cur: unknown = env\n for (const p of parts) {\n if (cur == null || typeof cur !== 'object') return undefined\n cur = (cur as Record<string, unknown>)[p]\n }\n return cur\n}\n\nconst interpolateString = (s: string, env: Record<string, unknown>): string => {\n TPL_RE.lastIndex = 0\n if (!TPL_RE.test(s)) return s\n TPL_RE.lastIndex = 0\n return s.replace(TPL_RE, (_, expr: string) => {\n const v = resolvePath(env, expr)\n return v == null ? '' : String(v)\n })\n}\n\nconst substituteTemplates = (node: unknown, env: Record<string, unknown>): unknown => {\n if (typeof node === 'string') return interpolateString(node, env)\n if (Array.isArray(node)) return node.map((x) => substituteTemplates(x, env))\n if (node && typeof node === 'object') {\n const out: Record<string, unknown> = {}\n for (const [k, v] of Object.entries(node as Record<string, unknown>)) {\n const newKey = typeof k === 'string' ? interpolateString(k, env) : k\n out[newKey] = substituteTemplates(v, env)\n }\n return out\n }\n return node\n}\n\nexport class LocalStateSetAction implements WorkflowActionHandler {\n public readonly typeUri = 'https://didcomm.org/workflow/actions/state:set@1'\n public async execute(ctx: ActionCtx): Promise<ActionResult> {\n const raw = (ctx.action as { staticInput?: unknown })?.staticInput\n // Accept {merge:{...}} (legacy) or a plain object/string (preferred).\n let merge: unknown = raw\n if (raw && typeof raw === 'object' && !Array.isArray(raw) && 'merge' in (raw as object)) {\n merge = (raw as { merge?: unknown }).merge\n }\n\n const env: Record<string, unknown> = {\n input: (ctx.input as Record<string, unknown>) || {},\n context: (ctx.instance.context as Record<string, unknown>) || {},\n context_data: (ctx.instance.context as Record<string, unknown>) || {},\n participants: (ctx.instance.participants as Record<string, unknown>) || {},\n artifacts: (ctx.instance.artifacts as Record<string, unknown>) || {},\n }\n\n // If staticInput is a pure template string like '{{ input.application }}',\n // resolve the path directly to preserve object values (don't stringify).\n if (typeof merge === 'string') {\n const match = merge.match(/^\\{\\{\\s*(.+?)\\s*\\}\\}$/)\n if (match) {\n const resolved = resolvePath(env, match[1])\n if (resolved !== undefined) merge = resolved\n }\n }\n\n // Substitute {{...}} in keys + values throughout the merge tree (for mixed templates).\n if (merge !== undefined && typeof merge !== 'string') merge = substituteTemplates(merge, env)\n\n // String fallback: if still a string after template resolution, try path resolution.\n if (typeof merge === 'string') {\n const trimmed = merge.replace(/\\{\\{|\\}\\}/g, '').trim()\n if (trimmed.includes('.')) {\n const resolved = resolvePath(env, trimmed)\n if (resolved && typeof resolved === 'object') merge = resolved\n }\n }\n\n let mergeObj: Record<string, unknown> | undefined\n if (merge && typeof merge === 'object' && !Array.isArray(merge)) {\n mergeObj = merge as Record<string, unknown>\n }\n\n // Match the Python plugin: advance input merges on top of staticInput.\n if (ctx.input && typeof ctx.input === 'object' && !Array.isArray(ctx.input)) {\n mergeObj = deepMerge({ ...(mergeObj || {}) }, ctx.input as Record<string, unknown>)\n }\n\n if (mergeObj && Object.keys(mergeObj).length > 0) {\n const next = deepMerge({ ...(ctx.instance.context || {}) }, mergeObj)\n return { contextMerge: next }\n }\n return {}\n }\n}\n\nexport class IssueCredentialV2Action implements WorkflowActionHandler {\n public readonly typeUri = 'https://didcomm.org/issue-credential/2.0/offer-credential'\n public async execute(ctx: ActionCtx): Promise<ActionResult> {\n const act = ctx.action as { profile_ref: string }\n const ref: string = act.profile_ref\n if (!ref?.startsWith('cp.')) throw Object.assign(new Error('invalid profile_ref'), { code: 'action_error' })\n const key = ref.slice(3)\n const profile = ctx.template.catalog?.credential_profiles?.[key]\n if (!profile) throw Object.assign(new Error('missing catalog profile'), { code: 'action_error' })\n const attrs = AttributePlanner.materialize(profile.attribute_plan || {}, ctx.instance)\n const attributes = Object.entries(attrs).map(([name, value]) => ({ name, value: String(value) }))\n const connectionId = ctx.instance.connection_id\n if (!connectionId) throw Object.assign(new Error('connectionId required'), { code: 'action_error' })\n // Enforce to_ref recipient DID against connection counterparty DID (if available)\n {\n const toRef = profile.to_ref\n const expectedDid = toRef ? ctx.instance.participants?.[toRef]?.did : undefined\n if (expectedDid && ctx.instance.connection_id) {\n const connSvc = ctx.agentContext.dependencyManager.resolve(DidCommConnectionService)\n const conn = await connSvc.getById(ctx.agentContext, ctx.instance.connection_id)\n const theirDid = (conn as unknown as { theirDid?: string })?.theirDid\n if (theirDid && theirDid !== expectedDid)\n throw Object.assign(new Error('to_ref DID mismatch'), { code: 'forbidden' })\n }\n }\n try {\n const credsApi = ctx.agentContext.dependencyManager.resolve(DidCommCredentialsApi) as unknown as {\n offerCredential: (options: unknown) => Promise<{ id: string; credentialRecord?: { id?: string } }>\n findOfferMessage: (id: string) => Promise<unknown>\n }\n const record = await credsApi.offerCredential({\n connectionId,\n protocolVersion: 'v2',\n credentialFormats: { anoncreds: { credentialDefinitionId: profile.cred_def_id, attributes } },\n comment: profile.options?.comment,\n })\n let messageId: string | undefined = record?.id || record?.credentialRecord?.id\n try {\n if (messageId) {\n const found = (await credsApi.findOfferMessage(messageId)) as unknown\n if (found && typeof found === 'object') {\n const f = found as { id?: string; message?: { id?: string } }\n messageId = f.message?.id || f.id || messageId\n }\n }\n } catch (_e) {\n void 0\n }\n return { artifacts: { issueRecordId: record?.id || record?.credentialRecord?.id }, messageId }\n } catch (e) {\n throw Object.assign(new Error(`issue action error: ${(e as Error).message}`), { code: 'action_error' })\n }\n }\n}\n\n/**\n * ProposeCredentialV2Action - Holder proposes a credential to the issuer\n * Used when holder initiates the credential issuance flow\n */\nexport class ProposeCredentialV2Action implements WorkflowActionHandler {\n public readonly typeUri = 'https://didcomm.org/issue-credential/2.0/propose-credential'\n\n public async execute(ctx: ActionCtx): Promise<ActionResult> {\n const act = ctx.action as { profile_ref: string }\n const ref: string = act.profile_ref\n if (!ref?.startsWith('cp.')) throw Object.assign(new Error('invalid profile_ref'), { code: 'action_error' })\n\n const key = ref.slice(3)\n const profile = ctx.template.catalog?.credential_profiles?.[key]\n if (!profile) throw Object.assign(new Error('missing catalog profile'), { code: 'action_error' })\n\n // Materialize attributes from context using attribute_plan\n const attrs = AttributePlanner.materialize(profile.attribute_plan || {}, ctx.instance)\n const attributes = Object.entries(attrs).map(([name, value]) => ({ name, value: String(value) }))\n\n const connectionId = ctx.instance.connection_id\n if (!connectionId) throw Object.assign(new Error('connectionId required'), { code: 'action_error' })\n\n try {\n const credsApi = ctx.agentContext.dependencyManager.resolve(DidCommCredentialsApi) as unknown as {\n proposeCredential: (options: unknown) => Promise<{ id: string; credentialRecord?: { id?: string } }>\n findProposalMessage: (id: string) => Promise<unknown>\n }\n\n const record = await credsApi.proposeCredential({\n connectionId,\n protocolVersion: 'v2',\n credentialFormats: {\n anoncreds: {\n credentialDefinitionId: profile.cred_def_id,\n attributes,\n },\n },\n comment: profile.options?.comment,\n })\n\n // Extract message ID for correlation\n let messageId: string | undefined = record?.id || record?.credentialRecord?.id\n try {\n if (messageId) {\n const found = await credsApi.findProposalMessage(messageId)\n if (found && typeof found === 'object') {\n const f = found as { id?: string; message?: { id?: string } }\n messageId = f.message?.id || f.id || messageId\n }\n }\n } catch (_e) {\n void 0\n }\n\n // Store record ID in artifacts for later actions to find\n return {\n artifacts: { credentialRecordId: record?.id || record?.credentialRecord?.id },\n messageId,\n }\n } catch (e) {\n throw Object.assign(new Error(`propose action error: ${(e as Error).message}`), { code: 'action_error' })\n }\n }\n}\n\n/**\n * RequestCredentialV2Action - Holder accepts a credential offer\n * Used when holder receives an offer and wants to request the credential\n */\nexport class RequestCredentialV2Action implements WorkflowActionHandler {\n public readonly typeUri = 'https://didcomm.org/issue-credential/2.0/request-credential'\n\n public async execute(ctx: ActionCtx): Promise<ActionResult> {\n const connectionId = ctx.instance.connection_id\n if (!connectionId) throw Object.assign(new Error('connectionId required'), { code: 'action_error' })\n\n try {\n const credsApi = ctx.agentContext.dependencyManager.resolve(DidCommCredentialsApi) as unknown as {\n acceptOffer: (options: { credentialRecordId: string }) => Promise<{ id: string }>\n getAll: () => Promise<Array<{ id: string; connectionId?: string; state: string; updatedAt?: Date }>>\n findRequestMessage: (id: string) => Promise<unknown>\n }\n\n // Find the credential record with OfferReceived state for this connection\n // Option 1: Check artifacts for stored credentialRecordId\n let credentialRecordId = ctx.instance.artifacts?.credentialRecordId as string | undefined\n\n // Option 2: Query by connection + state if not in artifacts\n if (!credentialRecordId) {\n const all = await credsApi.getAll()\n const matches = all\n .filter((r) => r.connectionId === connectionId && r.state === 'offer-received')\n .sort((a, b) => {\n const dateA = a.updatedAt ? new Date(a.updatedAt).getTime() : 0\n const dateB = b.updatedAt ? new Date(b.updatedAt).getTime() : 0\n return dateB - dateA // Most recent first\n })\n if (matches.length === 0) {\n throw Object.assign(new Error('no offer found to accept'), { code: 'action_error' })\n }\n credentialRecordId = matches[0].id\n }\n\n const record = await credsApi.acceptOffer({ credentialRecordId })\n\n let messageId: string | undefined = record?.id\n try {\n if (messageId) {\n const found = await credsApi.findRequestMessage(messageId)\n if (found && typeof found === 'object') {\n const f = found as { id?: string; message?: { id?: string } }\n messageId = f.message?.id || f.id || messageId\n }\n }\n } catch (_e) {\n void 0\n }\n\n return {\n artifacts: { credentialRecordId: record?.id },\n messageId,\n }\n } catch (e) {\n throw Object.assign(new Error(`request action error: ${(e as Error).message}`), { code: 'action_error' })\n }\n }\n}\n\n/**\n * IssueCredentialMessageV2Action - Issuer issues the credential after receiving a request\n * Used when issuer receives a credential request and wants to issue the credential\n */\nexport class IssueCredentialMessageV2Action implements WorkflowActionHandler {\n public readonly typeUri = 'https://didcomm.org/issue-credential/2.0/issue-credential'\n\n public async execute(ctx: ActionCtx): Promise<ActionResult> {\n const connectionId = ctx.instance.connection_id\n if (!connectionId) throw Object.assign(new Error('connectionId required'), { code: 'action_error' })\n\n try {\n const credsApi = ctx.agentContext.dependencyManager.resolve(DidCommCredentialsApi) as unknown as {\n acceptRequest: (options: { credentialRecordId: string }) => Promise<{ id: string }>\n getAll: () => Promise<Array<{ id: string; connectionId?: string; state: string; updatedAt?: Date }>>\n findCredentialMessage: (id: string) => Promise<unknown>\n }\n\n // Find the credential record with RequestReceived state for this connection\n let credentialRecordId = ctx.instance.artifacts?.credentialRecordId as string | undefined\n\n if (!credentialRecordId) {\n const all = await credsApi.getAll()\n const matches = all\n .filter((r) => r.connectionId === connectionId && r.state === 'request-received')\n .sort((a, b) => {\n const dateA = a.updatedAt ? new Date(a.updatedAt).getTime() : 0\n const dateB = b.updatedAt ? new Date(b.updatedAt).getTime() : 0\n return dateB - dateA // Most recent first\n })\n if (matches.length === 0) {\n throw Object.assign(new Error('no request found to issue'), { code: 'action_error' })\n }\n credentialRecordId = matches[0].id\n }\n\n const record = await credsApi.acceptRequest({ credentialRecordId })\n\n let messageId: string | undefined = record?.id\n try {\n if (messageId) {\n const found = await credsApi.findCredentialMessage(messageId)\n if (found && typeof found === 'object') {\n const f = found as { id?: string; message?: { id?: string } }\n messageId = f.message?.id || f.id || messageId\n }\n }\n } catch (_e) {\n void 0\n }\n\n return {\n artifacts: { issuedCredentialRecordId: record?.id },\n messageId,\n }\n } catch (e) {\n throw Object.assign(new Error(`issue action error: ${(e as Error).message}`), { code: 'action_error' })\n }\n }\n}\n\nexport class PresentProofV2Action implements WorkflowActionHandler {\n public readonly typeUri = 'https://didcomm.org/present-proof/2.0/request-presentation'\n public async execute(ctx: ActionCtx): Promise<ActionResult> {\n const act = ctx.action as { profile_ref: string }\n const ref: string = act.profile_ref\n if (!ref?.startsWith('pp.')) throw Object.assign(new Error('invalid profile_ref'), { code: 'action_error' })\n const key = ref.slice(3)\n const profile = ctx.template.catalog?.proof_profiles?.[key]\n if (!profile) throw Object.assign(new Error('missing catalog profile'), { code: 'action_error' })\n const connectionId = ctx.instance.connection_id\n if (!connectionId) throw Object.assign(new Error('connectionId required'), { code: 'action_error' })\n // Enforce to_ref recipient DID against connection counterparty DID (if available)\n {\n const toRef2 = profile.to_ref\n const expectedDid2 = toRef2 ? ctx.instance.participants?.[toRef2]?.did : undefined\n if (expectedDid2 && ctx.instance.connection_id) {\n const connSvc = ctx.agentContext.dependencyManager.resolve(DidCommConnectionService)\n const conn = await connSvc.getById(ctx.agentContext, ctx.instance.connection_id)\n const theirDid = (conn as unknown as { theirDid?: string })?.theirDid\n if (theirDid && theirDid !== expectedDid2)\n throw Object.assign(new Error('to_ref DID mismatch'), { code: 'forbidden' })\n }\n }\n try {\n const proofsApi = ctx.agentContext.dependencyManager.resolve(DidCommProofsApi) as unknown as {\n requestProof: (options: unknown) => Promise<{ id: string; proofRecord?: { id?: string } }>\n findRequestMessage: (id: string) => Promise<unknown>\n }\n const credDefId = (profile as { cred_def_id?: string }).cred_def_id\n const schemaId = (profile as { schema_id?: string }).schema_id\n const restriction = credDefId ? { cred_def_id: credDefId } : schemaId ? { schema_id: schemaId } : undefined\n\n const reqAttrs = (profile.requested_attributes || []).reduce<Record<string, unknown>>(\n (acc, name: string, idx: number) => {\n acc[`attr${idx + 1}`] = restriction ? { name, restrictions: [restriction] } : { name }\n return acc\n },\n {}\n )\n const reqPreds = (profile.requested_predicates || []).reduce<Record<string, unknown>>(\n (acc, p: { name: string; p_type: string; p_value: number }, idx: number) => {\n acc[`pred${idx + 1}`] = restriction\n ? { name: p.name, p_type: p.p_type, p_value: p.p_value, restrictions: [restriction] }\n : { name: p.name, p_type: p.p_type, p_value: p.p_value }\n return acc\n },\n {}\n )\n const record = await proofsApi.requestProof({\n connectionId,\n protocolVersion: 'v2',\n proofFormats: {\n anoncreds: {\n name: 'Workflow Proof Request',\n version: '1.0',\n requested_attributes: reqAttrs,\n requested_predicates: reqPreds,\n },\n },\n willConfirm: true,\n comment: profile.options?.comment,\n })\n let messageId: string | undefined = record?.id || record?.proofRecord?.id\n try {\n if (messageId) {\n const found = (await proofsApi.findRequestMessage(messageId)) as unknown\n if (found && typeof found === 'object') {\n const f = found as { id?: string; message?: { id?: string } }\n messageId = f.message?.id || f.id || messageId\n }\n }\n } catch (_e) {\n void 0\n }\n return { artifacts: { proofRecordId: record?.id || record?.proofRecord?.id }, messageId }\n } catch (e) {\n throw Object.assign(new Error(`proof action error: ${(e as Error).message}`), { code: 'action_error' })\n }\n }\n}\n"],"mappings":";;;;AA4BA,IAAa,iBAAb,MAA4B;;OAClB,2BAAW,IAAI,KAAoC;;CAC3D,AAAO,SAAS,SAAgC;AAC9C,OAAK,SAAS,IAAI,QAAQ,SAAS,QAAQ;;CAE7C,AAAO,IAAI,SAAoD;AAC7D,SAAO,KAAK,SAAS,IAAI,QAAQ;;;AAKrC,MAAM,SAAS;AAEf,MAAM,eAAe,KAA8B,SAA0B;CAC3E,MAAM,QAAQ,KAAK,MAAM,CAAC,MAAM,IAAI;CACpC,IAAIA,MAAe;AACnB,MAAK,MAAM,KAAK,OAAO;AACrB,MAAI,OAAO,QAAQ,OAAO,QAAQ,SAAU,QAAO;AACnD,QAAO,IAAgC;;AAEzC,QAAO;;AAGT,MAAM,qBAAqB,GAAW,QAAyC;AAC7E,QAAO,YAAY;AACnB,KAAI,CAAC,OAAO,KAAK,EAAE,CAAE,QAAO;AAC5B,QAAO,YAAY;AACnB,QAAO,EAAE,QAAQ,SAAS,GAAG,SAAiB;EAC5C,MAAM,IAAI,YAAY,KAAK,KAAK;AAChC,SAAO,KAAK,OAAO,KAAK,OAAO,EAAE;GACjC;;AAGJ,MAAM,uBAAuB,MAAe,QAA0C;AACpF,KAAI,OAAO,SAAS,SAAU,QAAO,kBAAkB,MAAM,IAAI;AACjE,KAAI,MAAM,QAAQ,KAAK,CAAE,QAAO,KAAK,KAAK,MAAM,oBAAoB,GAAG,IAAI,CAAC;AAC5E,KAAI,QAAQ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AAS,QAAQ,SAAS;IAC3B,CAAC;GACF,IAAIC,YAAgC,QAAQ,MAAM,QAAQ,aAAa;AACvE,OAAI;AACF,QAAI,WAAW;KACb,MAAM,QAAS,MAAM,UAAU,mBAAmB,UAAU;AAC5D,SAAI,SAAS,OAAO,UAAU,UAAU;MACtC,MAAM,IAAI;AACV,kBAAY,EAAE,SAAS,MAAM,EAAE,MAAM;;;YAGlC,IAAI;AAGb,UAAO;IAAE,WAAW,EAAE,eAAe,QAAQ,MAAM,QAAQ,aAAa,IAAI;IAAE;IAAW;WAClF,GAAG;AACV,SAAM,OAAO,uBAAO,IAAI,MAAM,uBAAwB,EAAY,UAAU,EAAE,EAAE,MAAM,gBAAgB,CAAC"}
|
|
@@ -1,9 +1,9 @@
|
|
|
1
|
-
import * as
|
|
1
|
+
import * as _credo_ts_didcomm5 from "@credo-ts/didcomm";
|
|
2
2
|
import { DidCommMessage } from "@credo-ts/didcomm";
|
|
3
3
|
|
|
4
4
|
//#region src/protocol/messages/CancelMessage.d.ts
|
|
5
5
|
declare class CancelMessage extends DidCommMessage {
|
|
6
|
-
static readonly type:
|
|
6
|
+
static readonly type: _credo_ts_didcomm5.ParsedMessageType;
|
|
7
7
|
type: string;
|
|
8
8
|
body: {
|
|
9
9
|
instance_id: string;
|
|
@@ -1,9 +1,9 @@
|
|
|
1
|
-
import * as
|
|
1
|
+
import * as _credo_ts_didcomm8 from "@credo-ts/didcomm";
|
|
2
2
|
import { DidCommMessage } from "@credo-ts/didcomm";
|
|
3
3
|
|
|
4
4
|
//#region src/protocol/messages/CompleteMessage.d.ts
|
|
5
5
|
declare class CompleteMessage extends DidCommMessage {
|
|
6
|
-
static readonly type:
|
|
6
|
+
static readonly type: _credo_ts_didcomm8.ParsedMessageType;
|
|
7
7
|
type: string;
|
|
8
8
|
body: {
|
|
9
9
|
instance_id: string;
|
|
@@ -1,9 +1,9 @@
|
|
|
1
|
-
import * as
|
|
1
|
+
import * as _credo_ts_didcomm9 from "@credo-ts/didcomm";
|
|
2
2
|
import { DidCommMessage } from "@credo-ts/didcomm";
|
|
3
3
|
|
|
4
4
|
//#region src/protocol/messages/DiscoverMessage.d.ts
|
|
5
5
|
declare class DiscoverMessage extends DidCommMessage {
|
|
6
|
-
static readonly type:
|
|
6
|
+
static readonly type: _credo_ts_didcomm9.ParsedMessageType;
|
|
7
7
|
type: string;
|
|
8
8
|
body: {
|
|
9
9
|
filters?: {
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"DiscoverMessage.d.mts","names":[],"sources":["../../../src/protocol/messages/DiscoverMessage.ts"],"sourcesContent":[],"mappings":";;;;cAEa,eAAA,SAAwB,cAAA;wBAAR,
|
|
1
|
+
{"version":3,"file":"DiscoverMessage.d.mts","names":[],"sources":["../../../src/protocol/messages/DiscoverMessage.ts"],"sourcesContent":[],"mappings":";;;;cAEa,eAAA,SAAwB,cAAA;wBAAR,kBAAA,CACA;;EADhB,IAAA,EAAA;IAAgB,OAAA,CAAA,EAAA;MAYuB,WAAA,CAAA,EAAA,MAAA;MAZf,OAAA,CAAA,EAAA,MAAA;MAAc,GAAA,CAAA,EAAA,MAAA;;;;;;;;;;;UAYC"}
|
|
@@ -1,9 +1,9 @@
|
|
|
1
|
-
import * as
|
|
1
|
+
import * as _credo_ts_didcomm6 from "@credo-ts/didcomm";
|
|
2
2
|
import { DidCommMessage } from "@credo-ts/didcomm";
|
|
3
3
|
|
|
4
4
|
//#region src/protocol/messages/PauseMessage.d.ts
|
|
5
5
|
declare class PauseMessage extends DidCommMessage {
|
|
6
|
-
static readonly type:
|
|
6
|
+
static readonly type: _credo_ts_didcomm6.ParsedMessageType;
|
|
7
7
|
type: string;
|
|
8
8
|
body: {
|
|
9
9
|
instance_id: string;
|
|
@@ -1,9 +1,9 @@
|
|
|
1
|
-
import * as
|
|
1
|
+
import * as _credo_ts_didcomm4 from "@credo-ts/didcomm";
|
|
2
2
|
import { DidCommMessage } from "@credo-ts/didcomm";
|
|
3
3
|
|
|
4
4
|
//#region src/protocol/messages/ProblemReportMessage.d.ts
|
|
5
5
|
declare class ProblemReportMessage extends DidCommMessage {
|
|
6
|
-
static readonly type:
|
|
6
|
+
static readonly type: _credo_ts_didcomm4.ParsedMessageType;
|
|
7
7
|
type: string;
|
|
8
8
|
body: {
|
|
9
9
|
code: string;
|
|
@@ -1,10 +1,10 @@
|
|
|
1
1
|
import { WorkflowTemplate } from "../../model/types.mjs";
|
|
2
|
-
import * as
|
|
2
|
+
import * as _credo_ts_didcomm2 from "@credo-ts/didcomm";
|
|
3
3
|
import { DidCommMessage } from "@credo-ts/didcomm";
|
|
4
4
|
|
|
5
5
|
//#region src/protocol/messages/PublishTemplateMessage.d.ts
|
|
6
6
|
declare class PublishTemplateMessage extends DidCommMessage {
|
|
7
|
-
static readonly type:
|
|
7
|
+
static readonly type: _credo_ts_didcomm2.ParsedMessageType;
|
|
8
8
|
type: string;
|
|
9
9
|
body: {
|
|
10
10
|
template: WorkflowTemplate;
|
|
@@ -1,10 +1,10 @@
|
|
|
1
1
|
import { Participants } from "../../model/types.mjs";
|
|
2
|
-
import * as
|
|
2
|
+
import * as _credo_ts_didcomm0 from "@credo-ts/didcomm";
|
|
3
3
|
import { DidCommMessage } from "@credo-ts/didcomm";
|
|
4
4
|
|
|
5
5
|
//#region src/protocol/messages/StartMessage.d.ts
|
|
6
6
|
declare class StartMessage extends DidCommMessage {
|
|
7
|
-
static readonly type:
|
|
7
|
+
static readonly type: _credo_ts_didcomm0.ParsedMessageType;
|
|
8
8
|
type: string;
|
|
9
9
|
body: {
|
|
10
10
|
template_id: string;
|
|
@@ -1,10 +1,10 @@
|
|
|
1
1
|
import { UiItem } from "../../model/types.mjs";
|
|
2
|
-
import * as
|
|
2
|
+
import * as _credo_ts_didcomm3 from "@credo-ts/didcomm";
|
|
3
3
|
import { DidCommMessage } from "@credo-ts/didcomm";
|
|
4
4
|
|
|
5
5
|
//#region src/protocol/messages/StatusMessage.d.ts
|
|
6
6
|
declare class StatusMessage extends DidCommMessage {
|
|
7
|
-
static readonly type:
|
|
7
|
+
static readonly type: _credo_ts_didcomm3.ParsedMessageType;
|
|
8
8
|
type: string;
|
|
9
9
|
body: {
|
|
10
10
|
instance_id: string;
|
|
@@ -1,9 +1,9 @@
|
|
|
1
|
-
import * as
|
|
1
|
+
import * as _credo_ts_didcomm1 from "@credo-ts/didcomm";
|
|
2
2
|
import { DidCommMessage } from "@credo-ts/didcomm";
|
|
3
3
|
|
|
4
4
|
//#region src/protocol/messages/StatusRequestMessage.d.ts
|
|
5
5
|
declare class StatusRequestMessage extends DidCommMessage {
|
|
6
|
-
static readonly type:
|
|
6
|
+
static readonly type: _credo_ts_didcomm1.ParsedMessageType;
|
|
7
7
|
type: string;
|
|
8
8
|
body: {
|
|
9
9
|
instance_id: string;
|
|
@@ -1,9 +1,9 @@
|
|
|
1
|
-
import * as
|
|
1
|
+
import * as _credo_ts_didcomm10 from "@credo-ts/didcomm";
|
|
2
2
|
import { DidCommMessage } from "@credo-ts/didcomm";
|
|
3
3
|
|
|
4
4
|
//#region src/protocol/messages/WorkflowsMessage.d.ts
|
|
5
5
|
declare class WorkflowsMessage extends DidCommMessage {
|
|
6
|
-
static readonly type:
|
|
6
|
+
static readonly type: _credo_ts_didcomm10.ParsedMessageType;
|
|
7
7
|
type: string;
|
|
8
8
|
body: {
|
|
9
9
|
workflows: Array<{
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"WorkflowsMessage.d.mts","names":[],"sources":["../../../src/protocol/messages/WorkflowsMessage.ts"],"sourcesContent":[],"mappings":";;;;cAEa,gBAAA,SAAyB,cAAA;wBAAR,
|
|
1
|
+
{"version":3,"file":"WorkflowsMessage.d.mts","names":[],"sources":["../../../src/protocol/messages/WorkflowsMessage.ts"],"sourcesContent":[],"mappings":";;;;cAEa,gBAAA,SAAyB,cAAA;wBAAR,mBAAA,CACD;;EADhB,IAAA,EAAA;IAAiB,SAAA,EAOf,KANc,CAAA;MAMd,WAAA,EAAA,MAAA;MAIqC,QAAA,EAAA,MAAA,EAAA;MAXd,KAAA,CAAA,EAAA,MAAA;MAAc,IAAA,CAAA,EAAA,MAAA;;;;;;;;;UAWA"}
|