@capxul/mcp 4.2.0-rc.12 → 4.2.0-rc.13
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/dist/capxul-source.json +3 -3
- package/dist/main.mjs +55 -11
- package/package.json +4 -4
package/dist/capxul-source.json
CHANGED
|
@@ -1,11 +1,11 @@
|
|
|
1
1
|
{
|
|
2
2
|
"source": {
|
|
3
|
-
"commit": "
|
|
4
|
-
"tree": "
|
|
3
|
+
"commit": "887920e1ba54e17bd8465975fcbc6e1537dfb6b8",
|
|
4
|
+
"tree": "deed16dc942ed9d6b587ceead4dbf8b0b4174e2c",
|
|
5
5
|
"branch": "codex/programme-rc",
|
|
6
6
|
"repository": "https://github.com/Xelmar-tech/infrastructure",
|
|
7
7
|
"lockfileSha256": "5870f53b72706d103220c1bcf733cb4fb71196aea32a9cfbdc277d73cc959264"
|
|
8
8
|
},
|
|
9
9
|
"name": "@capxul/mcp",
|
|
10
|
-
"version": "4.2.0-rc.
|
|
10
|
+
"version": "4.2.0-rc.13"
|
|
11
11
|
}
|
package/dist/main.mjs
CHANGED
|
@@ -9644,6 +9644,13 @@ Schema.Struct({
|
|
|
9644
9644
|
transfers: Schema.Array(TransferEvidenceSchema),
|
|
9645
9645
|
requestCount: nonNegativeInteger("requestCount")
|
|
9646
9646
|
});
|
|
9647
|
+
/**
|
|
9648
|
+
* `chainId:txHash:transactionLogOrdinal` — the indexer's own row id. The
|
|
9649
|
+
* ordinal is the position in the transaction's receipt logs, never the
|
|
9650
|
+
* block-global index that `eventLogIndex` carries.
|
|
9651
|
+
*/
|
|
9652
|
+
const LOGICAL_EVENT_ID_RE = /^[1-9][0-9]{0,9}:0x[0-9a-f]{64}:(0|[1-9][0-9]{0,5})$/u;
|
|
9653
|
+
const LogicalEventIdSchema = Schema.String.pipe(Schema.refine((value) => LOGICAL_EVENT_ID_RE.test(value), { message: "must be chainId:txHash:transactionLogOrdinal" }));
|
|
9647
9654
|
const VerifiedMoneyEvidenceCommonSchema = Schema.Struct({
|
|
9648
9655
|
chainId: BaseSepoliaChainIdSchema,
|
|
9649
9656
|
contractAddress: AddressSchema,
|
|
@@ -9652,7 +9659,17 @@ const VerifiedMoneyEvidenceCommonSchema = Schema.Struct({
|
|
|
9652
9659
|
blockNumber: BlockNumberSchema,
|
|
9653
9660
|
blockHash: Bytes32Schema,
|
|
9654
9661
|
blockTimestamp: Uint48Schema,
|
|
9655
|
-
|
|
9662
|
+
/**
|
|
9663
|
+
* The block-global log index of the settled event, as
|
|
9664
|
+
* `eth_getTransactionReceipt` reports it. Both readers key on this value, and
|
|
9665
|
+
* the ledger de-duplicates a settlement on `(txHash, eventLogIndex)`.
|
|
9666
|
+
*/
|
|
9667
|
+
eventLogIndex: LogIndexSchema,
|
|
9668
|
+
/**
|
|
9669
|
+
* The indexer row the fact was read from. Present only when the indexer
|
|
9670
|
+
* answered; the receipt-backed reader reads no row and sets nothing.
|
|
9671
|
+
*/
|
|
9672
|
+
logicalEventId: Schema.optional(LogicalEventIdSchema)
|
|
9656
9673
|
});
|
|
9657
9674
|
const VerifiedPaymentEvidenceSchema = Schema.Struct({
|
|
9658
9675
|
...VerifiedMoneyEvidenceCommonSchema.fields,
|
|
@@ -12783,7 +12800,7 @@ function subscribeActivity(deps, actor, controls, onChange) {
|
|
|
12783
12800
|
}
|
|
12784
12801
|
//#endregion
|
|
12785
12802
|
//#region ../../packages/sdk/package.json
|
|
12786
|
-
var version$1 = "4.2.0-rc.
|
|
12803
|
+
var version$1 = "4.2.0-rc.13";
|
|
12787
12804
|
//#endregion
|
|
12788
12805
|
//#region ../../packages/sdk/src/telemetry/exception-projection.ts
|
|
12789
12806
|
/** Fixed fallback for failures that have no safe message. */
|
|
@@ -14036,10 +14053,12 @@ function makeFinancialOpsMethods(deps) {
|
|
|
14036
14053
|
return runPortEffect(Effect.suspend(() => deps.convexCall.query(fns.depositInstructions, copyInvocationObservation(controls, {}))).pipe(Effect.tap((instructions) => emitDepositInitiated(deps.telemetry, instructions, controls))), controls, CAPXUL_OPERATIONS.me.depositInstructions, deps.runPromise);
|
|
14037
14054
|
}
|
|
14038
14055
|
},
|
|
14039
|
-
targets: { resolve:
|
|
14040
|
-
const
|
|
14041
|
-
|
|
14042
|
-
|
|
14056
|
+
targets: { resolve: (reference, options) => {
|
|
14057
|
+
const controls = deps.invocationControls?.(options) ?? options;
|
|
14058
|
+
return runPortEffect(projectReply(Effect.suspend(() => {
|
|
14059
|
+
const recipient = normalizeTargetForBackend(reference, "reference");
|
|
14060
|
+
return recipient.ok ? deps.convexCall.query(fns.resolveRecipient, copyInvocationObservation(controls, { recipient: recipient.value })) : Effect.fail({ publicError: recipient.error });
|
|
14061
|
+
}), resolvedTargetFromResolution), controls, CAPXUL_OPERATIONS.recipient.resolve, deps.runPromise);
|
|
14043
14062
|
} },
|
|
14044
14063
|
destinations: {
|
|
14045
14064
|
add: (input, options) => {
|
|
@@ -14102,8 +14121,14 @@ function makeFinancialOpsMethods(deps) {
|
|
|
14102
14121
|
kind: "claim",
|
|
14103
14122
|
paymentId
|
|
14104
14123
|
}, deps.invocationControls?.(options) ?? options, CAPXUL_OPERATIONS.payments.claim),
|
|
14105
|
-
list:
|
|
14106
|
-
|
|
14124
|
+
list: (options) => {
|
|
14125
|
+
const controls = deps.invocationControls?.(options) ?? options;
|
|
14126
|
+
return runPortEffect(projectReply(Effect.suspend(() => deps.convexCall.query(fns.listPayments, copyInvocationObservation(controls, {}))), (payments) => payments.map(normalizePaymentTiming)), controls, CAPXUL_OPERATIONS.payments.list, deps.runPromise);
|
|
14127
|
+
},
|
|
14128
|
+
get: (paymentId, options) => {
|
|
14129
|
+
const controls = deps.invocationControls?.(options) ?? options;
|
|
14130
|
+
return runPortEffect(projectReply(Effect.suspend(() => deps.convexCall.query(fns.getPayment, copyInvocationObservation(controls, { paymentId }))), (payment) => payment === null ? null : normalizePaymentTiming(payment)), controls, CAPXUL_OPERATIONS.payments.get, deps.runPromise);
|
|
14131
|
+
},
|
|
14107
14132
|
cancel: (paymentId, options) => runLifecycle({
|
|
14108
14133
|
kind: "cancel",
|
|
14109
14134
|
paymentId
|
|
@@ -14471,6 +14496,22 @@ function normalizePaymentTiming(payment) {
|
|
|
14471
14496
|
timing: payment.timing ?? payment.release ?? { kind: "instant" }
|
|
14472
14497
|
};
|
|
14473
14498
|
}
|
|
14499
|
+
/**
|
|
14500
|
+
* `mapOk`, moved inside the observed Effect (R09 #1967).
|
|
14501
|
+
*
|
|
14502
|
+
* The projection can refuse — `toAddress` and `toPartyId` throw on a malformed
|
|
14503
|
+
* reply — and every verb on this surface returns a `CapxulResult`, so that
|
|
14504
|
+
* throw stays a value here (ADR-0023). The error identity is `mapOk`'s: a
|
|
14505
|
+
* `CapxulError` passes through, anything else becomes `Errors.unknown(cause)`.
|
|
14506
|
+
* Running it inside the runner is what puts the decode failure on the same
|
|
14507
|
+
* operation record as the read that produced the reply.
|
|
14508
|
+
*/
|
|
14509
|
+
function projectReply(program, project) {
|
|
14510
|
+
return program.pipe(Effect.flatMap((value) => Effect.try({
|
|
14511
|
+
try: () => project(value),
|
|
14512
|
+
catch: (cause) => ({ publicError: cause instanceof CapxulError ? cause : Errors.unknown(cause) })
|
|
14513
|
+
})));
|
|
14514
|
+
}
|
|
14474
14515
|
function mapOk(result, f) {
|
|
14475
14516
|
if (!result.ok) return result;
|
|
14476
14517
|
try {
|
|
@@ -19121,6 +19162,8 @@ const OBSERVED_CONVEX_QUERIES = /* @__PURE__ */ new Set([
|
|
|
19121
19162
|
"movement/activity:summary",
|
|
19122
19163
|
"movement/activity:get",
|
|
19123
19164
|
"financialOps/queries:depositInstructions",
|
|
19165
|
+
"financialOps/queries:listPayments",
|
|
19166
|
+
"financialOps/queries:getPayment",
|
|
19124
19167
|
"financialOps/destinations:list",
|
|
19125
19168
|
"financialOps/queries:verifyPaymentDocument",
|
|
19126
19169
|
"financialOps/queries:renderStoredDocument",
|
|
@@ -47221,6 +47264,7 @@ function identity(row) {
|
|
|
47221
47264
|
chainId: toChainId(integer(row, "chain_id")),
|
|
47222
47265
|
txHash: toTxHash(hex(row, "tx_hash")),
|
|
47223
47266
|
transactionLogOrdinal: integer(row, "transaction_log_ordinal"),
|
|
47267
|
+
logIndex: integer(row, "log_index"),
|
|
47224
47268
|
blockNumber: big(row, "block_number"),
|
|
47225
47269
|
blockHash: hex(row, "block_hash"),
|
|
47226
47270
|
timestamp: big(row, "timestamp")
|
|
@@ -47303,8 +47347,8 @@ function decodeStatus(body) {
|
|
|
47303
47347
|
* that allowlist changes, this file changes with it or every read fails 403.
|
|
47304
47348
|
*/
|
|
47305
47349
|
const HEADS = {
|
|
47306
|
-
transfer: "select \"id\", \"chain_id\", \"tx_hash\", \"transaction_log_ordinal\", \"block_number\", \"block_hash\", \"timestamp\", \"asset_id\", \"token\", \"from\", \"to\", \"amount\" from \"transfer\" where (\"transfer\".\"from\" = $1 or \"transfer\".\"to\" = $2) order by \"transfer\".\"block_number\" desc, \"transfer\".\"id\" desc",
|
|
47307
|
-
payment: "select \"id\", \"chain_id\", \"tx_hash\", \"transaction_log_ordinal\", \"block_number\", \"block_hash\", \"timestamp\", \"contract\", \"settlement_id\", \"sender\", \"recipient\", \"asset_id\", \"token\", \"amount\", \"kind\", \"document_hash\" from \"payment\" where (\"payment\".\"sender\" = $1 or \"payment\".\"recipient\" = $2) order by \"payment\".\"block_number\" desc, \"payment\".\"id\" desc",
|
|
47350
|
+
transfer: "select \"id\", \"chain_id\", \"tx_hash\", \"transaction_log_ordinal\", \"log_index\", \"block_number\", \"block_hash\", \"timestamp\", \"asset_id\", \"token\", \"from\", \"to\", \"amount\" from \"transfer\" where (\"transfer\".\"from\" = $1 or \"transfer\".\"to\" = $2) order by \"transfer\".\"block_number\" desc, \"transfer\".\"id\" desc",
|
|
47351
|
+
payment: "select \"id\", \"chain_id\", \"tx_hash\", \"transaction_log_ordinal\", \"log_index\", \"block_number\", \"block_hash\", \"timestamp\", \"contract\", \"settlement_id\", \"sender\", \"recipient\", \"asset_id\", \"token\", \"amount\", \"kind\", \"document_hash\" from \"payment\" where (\"payment\".\"sender\" = $1 or \"payment\".\"recipient\" = $2) order by \"payment\".\"block_number\" desc, \"payment\".\"id\" desc",
|
|
47308
47352
|
balance: "select \"chain_id\", \"asset_id\", \"to\", \"amount\" from \"balance\" where \"balance\".\"to\" = $1"
|
|
47309
47353
|
};
|
|
47310
47354
|
/** How many times the statement binds the Safe address. */
|
|
@@ -48949,7 +48993,7 @@ function stdioIdentity(env = process.env, options = {}) {
|
|
|
48949
48993
|
}
|
|
48950
48994
|
//#endregion
|
|
48951
48995
|
//#region package.json
|
|
48952
|
-
var version = "4.2.0-rc.
|
|
48996
|
+
var version = "4.2.0-rc.13";
|
|
48953
48997
|
//#endregion
|
|
48954
48998
|
//#region src/deps.ts
|
|
48955
48999
|
const NO_IDENTITY = async () => void 0;
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@capxul/mcp",
|
|
3
|
-
"version": "4.2.0-rc.
|
|
3
|
+
"version": "4.2.0-rc.13",
|
|
4
4
|
"private": false,
|
|
5
5
|
"description": "Capxul MCP server for auth, Account readiness, identity, Organizations, relationships, requests, destinations, and testnet funding over Streamable HTTP.",
|
|
6
6
|
"keywords": [
|
|
@@ -50,9 +50,9 @@
|
|
|
50
50
|
"typescript": "npm:@typescript/typescript6@6.0.2",
|
|
51
51
|
"vite": "npm:@voidzero-dev/vite-plus-core@0.3.0",
|
|
52
52
|
"vite-plus": "0.3.0",
|
|
53
|
-
"@capxul/
|
|
54
|
-
"@capxul/
|
|
55
|
-
"@capxul/config": "0.
|
|
53
|
+
"@capxul/config": "0.3.0",
|
|
54
|
+
"@capxul/sdk": "4.2.0-rc.13",
|
|
55
|
+
"@capxul/typescript-config": "0.0.0"
|
|
56
56
|
},
|
|
57
57
|
"scripts": {
|
|
58
58
|
"dev": "vp exec tsx src/main.ts serve",
|