@moovio/sdk 0.0.0-dev.5 → 0.0.0-dev.6
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/README.md +74 -54
- package/bin/mcp-server.js +815 -678
- package/bin/mcp-server.js.map +24 -24
- package/funcs/disputesUploadEvidenceFile.js +6 -0
- package/funcs/disputesUploadEvidenceFile.js.map +1 -1
- package/funcs/filesUpload.js +6 -0
- package/funcs/filesUpload.js.map +1 -1
- package/funcs/imagesUpdate.js +7 -0
- package/funcs/imagesUpdate.js.map +1 -1
- package/funcs/imagesUpload.js +7 -0
- package/funcs/imagesUpload.js.map +1 -1
- package/funcs/invoicesDelete.d.ts +24 -0
- package/funcs/invoicesDelete.d.ts.map +1 -0
- package/funcs/invoicesDelete.js +146 -0
- package/funcs/invoicesDelete.js.map +1 -0
- package/jsr.json +1 -1
- package/lib/config.d.ts +3 -3
- package/lib/config.js +3 -3
- package/lib/config.js.map +1 -1
- package/lib/matchers.d.ts.map +1 -1
- package/lib/matchers.js +0 -1
- package/lib/matchers.js.map +1 -1
- package/lib/security.d.ts.map +1 -1
- package/lib/security.js +1 -2
- package/lib/security.js.map +1 -1
- package/mcp-server/mcp-server.js +1 -1
- package/mcp-server/server.d.ts.map +1 -1
- package/mcp-server/server.js +3 -1
- package/mcp-server/server.js.map +1 -1
- package/mcp-server/shared.js +1 -1
- package/mcp-server/shared.js.map +1 -1
- package/mcp-server/tools/invoicesDelete.d.ts +8 -0
- package/mcp-server/tools/invoicesDelete.d.ts.map +1 -0
- package/{models/components/rtpfailurecode.js → mcp-server/tools/invoicesDelete.js} +31 -21
- package/mcp-server/tools/invoicesDelete.js.map +1 -0
- package/models/components/createinvoicelineitem.d.ts +2 -1
- package/models/components/createinvoicelineitem.d.ts.map +1 -1
- package/models/components/createinvoicelineitem.js.map +1 -1
- package/models/components/createpaymentlinklineitem.d.ts +2 -1
- package/models/components/createpaymentlinklineitem.d.ts.map +1 -1
- package/models/components/createpaymentlinklineitem.js.map +1 -1
- package/models/components/index.d.ts +0 -3
- package/models/components/index.d.ts.map +1 -1
- package/models/components/index.js +0 -3
- package/models/components/index.js.map +1 -1
- package/models/components/invoice.d.ts +12 -0
- package/models/components/invoice.d.ts.map +1 -1
- package/models/components/invoice.js +6 -0
- package/models/components/invoice.js.map +1 -1
- package/models/components/invoicelineitem.d.ts +2 -1
- package/models/components/invoicelineitem.d.ts.map +1 -1
- package/models/components/invoicelineitem.js.map +1 -1
- package/models/components/transferdestination.d.ts +0 -6
- package/models/components/transferdestination.d.ts.map +1 -1
- package/models/components/transferdestination.js +0 -3
- package/models/components/transferdestination.js.map +1 -1
- package/models/components/updateinvoice.d.ts +4 -1
- package/models/components/updateinvoice.d.ts.map +1 -1
- package/models/components/updateinvoice.js.map +1 -1
- package/models/operations/deleteinvoice.d.ts +63 -0
- package/models/operations/deleteinvoice.d.ts.map +1 -0
- package/models/operations/deleteinvoice.js +109 -0
- package/models/operations/deleteinvoice.js.map +1 -0
- package/models/operations/index.d.ts +1 -0
- package/models/operations/index.d.ts.map +1 -1
- package/models/operations/index.js +1 -0
- package/models/operations/index.js.map +1 -1
- package/package.json +1 -1
- package/sdk/invoices.d.ts +13 -0
- package/sdk/invoices.d.ts.map +1 -1
- package/sdk/invoices.js +16 -0
- package/sdk/invoices.js.map +1 -1
- package/src/funcs/disputesUploadEvidenceFile.ts +15 -0
- package/src/funcs/filesUpload.ts +15 -0
- package/src/funcs/imagesUpdate.ts +16 -0
- package/src/funcs/imagesUpload.ts +16 -0
- package/src/funcs/invoicesDelete.ts +206 -0
- package/src/lib/config.ts +3 -3
- package/src/lib/matchers.ts +3 -2
- package/src/lib/security.ts +1 -2
- package/src/mcp-server/mcp-server.ts +1 -1
- package/src/mcp-server/server.ts +3 -1
- package/src/mcp-server/shared.ts +2 -2
- package/src/mcp-server/tools/invoicesDelete.ts +43 -0
- package/src/models/components/createinvoicelineitem.ts +2 -1
- package/src/models/components/createpaymentlinklineitem.ts +2 -1
- package/src/models/components/index.ts +0 -3
- package/src/models/components/invoice.ts +20 -0
- package/src/models/components/invoicelineitem.ts +2 -1
- package/src/models/components/transferdestination.ts +0 -13
- package/src/models/components/updateinvoice.ts +4 -1
- package/src/models/operations/deleteinvoice.ts +172 -0
- package/src/models/operations/index.ts +1 -0
- package/src/sdk/invoices.ts +24 -0
- package/models/components/rtpfailurecode.d.ts +0 -26
- package/models/components/rtpfailurecode.d.ts.map +0 -1
- package/models/components/rtpfailurecode.js.map +0 -1
- package/models/components/rtptransactiondetails.d.ts +0 -43
- package/models/components/rtptransactiondetails.d.ts.map +0 -1
- package/models/components/rtptransactiondetails.js +0 -75
- package/models/components/rtptransactiondetails.js.map +0 -1
- package/models/components/rtptransactionstatus.d.ts +0 -20
- package/models/components/rtptransactionstatus.d.ts.map +0 -1
- package/models/components/rtptransactionstatus.js +0 -54
- package/models/components/rtptransactionstatus.js.map +0 -1
- package/src/models/components/rtpfailurecode.ts +0 -35
- package/src/models/components/rtptransactiondetails.ts +0 -102
- package/src/models/components/rtptransactionstatus.ts +0 -29
|
@@ -1,20 +0,0 @@
|
|
|
1
|
-
import * as z from "zod/v3";
|
|
2
|
-
import { ClosedEnum } from "../../types/enums.js";
|
|
3
|
-
/**
|
|
4
|
-
* Status of a transaction within the RTP lifecycle.
|
|
5
|
-
*/
|
|
6
|
-
export declare const RTPTransactionStatus: {
|
|
7
|
-
readonly Initiated: "initiated";
|
|
8
|
-
readonly Completed: "completed";
|
|
9
|
-
readonly Failed: "failed";
|
|
10
|
-
readonly AcceptedWithoutPosting: "accepted-without-posting";
|
|
11
|
-
};
|
|
12
|
-
/**
|
|
13
|
-
* Status of a transaction within the RTP lifecycle.
|
|
14
|
-
*/
|
|
15
|
-
export type RTPTransactionStatus = ClosedEnum<typeof RTPTransactionStatus>;
|
|
16
|
-
/** @internal */
|
|
17
|
-
export declare const RTPTransactionStatus$inboundSchema: z.ZodNativeEnum<typeof RTPTransactionStatus>;
|
|
18
|
-
/** @internal */
|
|
19
|
-
export declare const RTPTransactionStatus$outboundSchema: z.ZodNativeEnum<typeof RTPTransactionStatus>;
|
|
20
|
-
//# sourceMappingURL=rtptransactionstatus.d.ts.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"rtptransactionstatus.d.ts","sourceRoot":"","sources":["../../src/models/components/rtptransactionstatus.ts"],"names":[],"mappings":"AAIA,OAAO,KAAK,CAAC,MAAM,QAAQ,CAAC;AAC5B,OAAO,EAAE,UAAU,EAAE,MAAM,sBAAsB,CAAC;AAElD;;GAEG;AACH,eAAO,MAAM,oBAAoB;;;;;CAKvB,CAAC;AACX;;GAEG;AACH,MAAM,MAAM,oBAAoB,GAAG,UAAU,CAAC,OAAO,oBAAoB,CAAC,CAAC;AAE3E,gBAAgB;AAChB,eAAO,MAAM,kCAAkC,EAAE,CAAC,CAAC,aAAa,CAC9D,OAAO,oBAAoB,CACS,CAAC;AACvC,gBAAgB;AAChB,eAAO,MAAM,mCAAmC,EAAE,CAAC,CAAC,aAAa,CAC/D,OAAO,oBAAoB,CACS,CAAC"}
|
|
@@ -1,54 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
/*
|
|
3
|
-
* Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.
|
|
4
|
-
*/
|
|
5
|
-
var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
|
|
6
|
-
if (k2 === undefined) k2 = k;
|
|
7
|
-
var desc = Object.getOwnPropertyDescriptor(m, k);
|
|
8
|
-
if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
|
|
9
|
-
desc = { enumerable: true, get: function() { return m[k]; } };
|
|
10
|
-
}
|
|
11
|
-
Object.defineProperty(o, k2, desc);
|
|
12
|
-
}) : (function(o, m, k, k2) {
|
|
13
|
-
if (k2 === undefined) k2 = k;
|
|
14
|
-
o[k2] = m[k];
|
|
15
|
-
}));
|
|
16
|
-
var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? (function(o, v) {
|
|
17
|
-
Object.defineProperty(o, "default", { enumerable: true, value: v });
|
|
18
|
-
}) : function(o, v) {
|
|
19
|
-
o["default"] = v;
|
|
20
|
-
});
|
|
21
|
-
var __importStar = (this && this.__importStar) || (function () {
|
|
22
|
-
var ownKeys = function(o) {
|
|
23
|
-
ownKeys = Object.getOwnPropertyNames || function (o) {
|
|
24
|
-
var ar = [];
|
|
25
|
-
for (var k in o) if (Object.prototype.hasOwnProperty.call(o, k)) ar[ar.length] = k;
|
|
26
|
-
return ar;
|
|
27
|
-
};
|
|
28
|
-
return ownKeys(o);
|
|
29
|
-
};
|
|
30
|
-
return function (mod) {
|
|
31
|
-
if (mod && mod.__esModule) return mod;
|
|
32
|
-
var result = {};
|
|
33
|
-
if (mod != null) for (var k = ownKeys(mod), i = 0; i < k.length; i++) if (k[i] !== "default") __createBinding(result, mod, k[i]);
|
|
34
|
-
__setModuleDefault(result, mod);
|
|
35
|
-
return result;
|
|
36
|
-
};
|
|
37
|
-
})();
|
|
38
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
39
|
-
exports.RTPTransactionStatus$outboundSchema = exports.RTPTransactionStatus$inboundSchema = exports.RTPTransactionStatus = void 0;
|
|
40
|
-
const z = __importStar(require("zod/v3"));
|
|
41
|
-
/**
|
|
42
|
-
* Status of a transaction within the RTP lifecycle.
|
|
43
|
-
*/
|
|
44
|
-
exports.RTPTransactionStatus = {
|
|
45
|
-
Initiated: "initiated",
|
|
46
|
-
Completed: "completed",
|
|
47
|
-
Failed: "failed",
|
|
48
|
-
AcceptedWithoutPosting: "accepted-without-posting",
|
|
49
|
-
};
|
|
50
|
-
/** @internal */
|
|
51
|
-
exports.RTPTransactionStatus$inboundSchema = z.nativeEnum(exports.RTPTransactionStatus);
|
|
52
|
-
/** @internal */
|
|
53
|
-
exports.RTPTransactionStatus$outboundSchema = exports.RTPTransactionStatus$inboundSchema;
|
|
54
|
-
//# sourceMappingURL=rtptransactionstatus.js.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"rtptransactionstatus.js","sourceRoot":"","sources":["../../src/models/components/rtptransactionstatus.ts"],"names":[],"mappings":";AAAA;;GAEG;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAEH,0CAA4B;AAG5B;;GAEG;AACU,QAAA,oBAAoB,GAAG;IAClC,SAAS,EAAE,WAAW;IACtB,SAAS,EAAE,WAAW;IACtB,MAAM,EAAE,QAAQ;IAChB,sBAAsB,EAAE,0BAA0B;CAC1C,CAAC;AAMX,gBAAgB;AACH,QAAA,kCAAkC,GAE3C,CAAC,CAAC,UAAU,CAAC,4BAAoB,CAAC,CAAC;AACvC,gBAAgB;AACH,QAAA,mCAAmC,GAE5C,0CAAkC,CAAC"}
|
|
@@ -1,35 +0,0 @@
|
|
|
1
|
-
/*
|
|
2
|
-
* Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.
|
|
3
|
-
*/
|
|
4
|
-
|
|
5
|
-
import * as z from "zod/v3";
|
|
6
|
-
import { ClosedEnum } from "../../types/enums.js";
|
|
7
|
-
|
|
8
|
-
/**
|
|
9
|
-
* Status codes for RTP failures.
|
|
10
|
-
*/
|
|
11
|
-
export const RTPFailureCode = {
|
|
12
|
-
ProcessingError: "processing-error",
|
|
13
|
-
InvalidAccount: "invalid-account",
|
|
14
|
-
AccountClosed: "account-closed",
|
|
15
|
-
AccountBlocked: "account-blocked",
|
|
16
|
-
InvalidField: "invalid-field",
|
|
17
|
-
TransactionNotSupported: "transaction-not-supported",
|
|
18
|
-
LimitExceeded: "limit-exceeded",
|
|
19
|
-
InvalidAmount: "invalid-amount",
|
|
20
|
-
CustomerDeceased: "customer-deceased",
|
|
21
|
-
Other: "other",
|
|
22
|
-
} as const;
|
|
23
|
-
/**
|
|
24
|
-
* Status codes for RTP failures.
|
|
25
|
-
*/
|
|
26
|
-
export type RTPFailureCode = ClosedEnum<typeof RTPFailureCode>;
|
|
27
|
-
|
|
28
|
-
/** @internal */
|
|
29
|
-
export const RTPFailureCode$inboundSchema: z.ZodNativeEnum<
|
|
30
|
-
typeof RTPFailureCode
|
|
31
|
-
> = z.nativeEnum(RTPFailureCode);
|
|
32
|
-
/** @internal */
|
|
33
|
-
export const RTPFailureCode$outboundSchema: z.ZodNativeEnum<
|
|
34
|
-
typeof RTPFailureCode
|
|
35
|
-
> = RTPFailureCode$inboundSchema;
|
|
@@ -1,102 +0,0 @@
|
|
|
1
|
-
/*
|
|
2
|
-
* Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.
|
|
3
|
-
*/
|
|
4
|
-
|
|
5
|
-
import * as z from "zod/v3";
|
|
6
|
-
import { safeParse } from "../../lib/schemas.js";
|
|
7
|
-
import { Result as SafeParseResult } from "../../types/fp.js";
|
|
8
|
-
import { SDKValidationError } from "../errors/sdkvalidationerror.js";
|
|
9
|
-
import {
|
|
10
|
-
RTPFailureCode,
|
|
11
|
-
RTPFailureCode$inboundSchema,
|
|
12
|
-
RTPFailureCode$outboundSchema,
|
|
13
|
-
} from "./rtpfailurecode.js";
|
|
14
|
-
import {
|
|
15
|
-
RTPTransactionStatus,
|
|
16
|
-
RTPTransactionStatus$inboundSchema,
|
|
17
|
-
RTPTransactionStatus$outboundSchema,
|
|
18
|
-
} from "./rtptransactionstatus.js";
|
|
19
|
-
|
|
20
|
-
/**
|
|
21
|
-
* RTP specific details about the transaction.
|
|
22
|
-
*/
|
|
23
|
-
export type RTPTransactionDetails = {
|
|
24
|
-
/**
|
|
25
|
-
* Status of a transaction within the RTP lifecycle.
|
|
26
|
-
*/
|
|
27
|
-
status?: RTPTransactionStatus | undefined;
|
|
28
|
-
/**
|
|
29
|
-
* Response code returned by network on failure.
|
|
30
|
-
*/
|
|
31
|
-
networkResponseCode?: string | undefined;
|
|
32
|
-
/**
|
|
33
|
-
* Status codes for RTP failures.
|
|
34
|
-
*/
|
|
35
|
-
failureCode?: RTPFailureCode | undefined;
|
|
36
|
-
initiatedOn?: Date | undefined;
|
|
37
|
-
completedOn?: Date | undefined;
|
|
38
|
-
failedOn?: Date | undefined;
|
|
39
|
-
acceptedWithoutPostingOn?: Date | undefined;
|
|
40
|
-
};
|
|
41
|
-
|
|
42
|
-
/** @internal */
|
|
43
|
-
export const RTPTransactionDetails$inboundSchema: z.ZodType<
|
|
44
|
-
RTPTransactionDetails,
|
|
45
|
-
z.ZodTypeDef,
|
|
46
|
-
unknown
|
|
47
|
-
> = z.object({
|
|
48
|
-
status: RTPTransactionStatus$inboundSchema.optional(),
|
|
49
|
-
networkResponseCode: z.string().optional(),
|
|
50
|
-
failureCode: RTPFailureCode$inboundSchema.optional(),
|
|
51
|
-
initiatedOn: z.string().datetime({ offset: true }).transform(v => new Date(v))
|
|
52
|
-
.optional(),
|
|
53
|
-
completedOn: z.string().datetime({ offset: true }).transform(v => new Date(v))
|
|
54
|
-
.optional(),
|
|
55
|
-
failedOn: z.string().datetime({ offset: true }).transform(v => new Date(v))
|
|
56
|
-
.optional(),
|
|
57
|
-
acceptedWithoutPostingOn: z.string().datetime({ offset: true }).transform(v =>
|
|
58
|
-
new Date(v)
|
|
59
|
-
).optional(),
|
|
60
|
-
});
|
|
61
|
-
/** @internal */
|
|
62
|
-
export type RTPTransactionDetails$Outbound = {
|
|
63
|
-
status?: string | undefined;
|
|
64
|
-
networkResponseCode?: string | undefined;
|
|
65
|
-
failureCode?: string | undefined;
|
|
66
|
-
initiatedOn?: string | undefined;
|
|
67
|
-
completedOn?: string | undefined;
|
|
68
|
-
failedOn?: string | undefined;
|
|
69
|
-
acceptedWithoutPostingOn?: string | undefined;
|
|
70
|
-
};
|
|
71
|
-
|
|
72
|
-
/** @internal */
|
|
73
|
-
export const RTPTransactionDetails$outboundSchema: z.ZodType<
|
|
74
|
-
RTPTransactionDetails$Outbound,
|
|
75
|
-
z.ZodTypeDef,
|
|
76
|
-
RTPTransactionDetails
|
|
77
|
-
> = z.object({
|
|
78
|
-
status: RTPTransactionStatus$outboundSchema.optional(),
|
|
79
|
-
networkResponseCode: z.string().optional(),
|
|
80
|
-
failureCode: RTPFailureCode$outboundSchema.optional(),
|
|
81
|
-
initiatedOn: z.date().transform(v => v.toISOString()).optional(),
|
|
82
|
-
completedOn: z.date().transform(v => v.toISOString()).optional(),
|
|
83
|
-
failedOn: z.date().transform(v => v.toISOString()).optional(),
|
|
84
|
-
acceptedWithoutPostingOn: z.date().transform(v => v.toISOString()).optional(),
|
|
85
|
-
});
|
|
86
|
-
|
|
87
|
-
export function rtpTransactionDetailsToJSON(
|
|
88
|
-
rtpTransactionDetails: RTPTransactionDetails,
|
|
89
|
-
): string {
|
|
90
|
-
return JSON.stringify(
|
|
91
|
-
RTPTransactionDetails$outboundSchema.parse(rtpTransactionDetails),
|
|
92
|
-
);
|
|
93
|
-
}
|
|
94
|
-
export function rtpTransactionDetailsFromJSON(
|
|
95
|
-
jsonString: string,
|
|
96
|
-
): SafeParseResult<RTPTransactionDetails, SDKValidationError> {
|
|
97
|
-
return safeParse(
|
|
98
|
-
jsonString,
|
|
99
|
-
(x) => RTPTransactionDetails$inboundSchema.parse(JSON.parse(x)),
|
|
100
|
-
`Failed to parse 'RTPTransactionDetails' from JSON`,
|
|
101
|
-
);
|
|
102
|
-
}
|
|
@@ -1,29 +0,0 @@
|
|
|
1
|
-
/*
|
|
2
|
-
* Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.
|
|
3
|
-
*/
|
|
4
|
-
|
|
5
|
-
import * as z from "zod/v3";
|
|
6
|
-
import { ClosedEnum } from "../../types/enums.js";
|
|
7
|
-
|
|
8
|
-
/**
|
|
9
|
-
* Status of a transaction within the RTP lifecycle.
|
|
10
|
-
*/
|
|
11
|
-
export const RTPTransactionStatus = {
|
|
12
|
-
Initiated: "initiated",
|
|
13
|
-
Completed: "completed",
|
|
14
|
-
Failed: "failed",
|
|
15
|
-
AcceptedWithoutPosting: "accepted-without-posting",
|
|
16
|
-
} as const;
|
|
17
|
-
/**
|
|
18
|
-
* Status of a transaction within the RTP lifecycle.
|
|
19
|
-
*/
|
|
20
|
-
export type RTPTransactionStatus = ClosedEnum<typeof RTPTransactionStatus>;
|
|
21
|
-
|
|
22
|
-
/** @internal */
|
|
23
|
-
export const RTPTransactionStatus$inboundSchema: z.ZodNativeEnum<
|
|
24
|
-
typeof RTPTransactionStatus
|
|
25
|
-
> = z.nativeEnum(RTPTransactionStatus);
|
|
26
|
-
/** @internal */
|
|
27
|
-
export const RTPTransactionStatus$outboundSchema: z.ZodNativeEnum<
|
|
28
|
-
typeof RTPTransactionStatus
|
|
29
|
-
> = RTPTransactionStatus$inboundSchema;
|