@proof-holdings/mcp-server 1.0.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.
Files changed (99) hide show
  1. package/LICENSE +21 -0
  2. package/README.md +345 -0
  3. package/dist/http.d.ts +34 -0
  4. package/dist/http.d.ts.map +1 -0
  5. package/dist/http.js +117 -0
  6. package/dist/http.js.map +1 -0
  7. package/dist/server.d.ts +3 -0
  8. package/dist/server.d.ts.map +1 -0
  9. package/dist/server.js +76 -0
  10. package/dist/server.js.map +1 -0
  11. package/dist/tools/api-keys.d.ts +4 -0
  12. package/dist/tools/api-keys.d.ts.map +1 -0
  13. package/dist/tools/api-keys.js +71 -0
  14. package/dist/tools/api-keys.js.map +1 -0
  15. package/dist/tools/assets.d.ts +4 -0
  16. package/dist/tools/assets.d.ts.map +1 -0
  17. package/dist/tools/assets.js +57 -0
  18. package/dist/tools/assets.js.map +1 -0
  19. package/dist/tools/auth.d.ts +4 -0
  20. package/dist/tools/auth.d.ts.map +1 -0
  21. package/dist/tools/auth.js +41 -0
  22. package/dist/tools/auth.js.map +1 -0
  23. package/dist/tools/billing.d.ts +4 -0
  24. package/dist/tools/billing.d.ts.map +1 -0
  25. package/dist/tools/billing.js +16 -0
  26. package/dist/tools/billing.js.map +1 -0
  27. package/dist/tools/dns-credentials.d.ts +4 -0
  28. package/dist/tools/dns-credentials.d.ts.map +1 -0
  29. package/dist/tools/dns-credentials.js +44 -0
  30. package/dist/tools/dns-credentials.js.map +1 -0
  31. package/dist/tools/domains.d.ts +4 -0
  32. package/dist/tools/domains.d.ts.map +1 -0
  33. package/dist/tools/domains.js +235 -0
  34. package/dist/tools/domains.js.map +1 -0
  35. package/dist/tools/emails.d.ts +4 -0
  36. package/dist/tools/emails.d.ts.map +1 -0
  37. package/dist/tools/emails.js +96 -0
  38. package/dist/tools/emails.js.map +1 -0
  39. package/dist/tools/phones.d.ts +4 -0
  40. package/dist/tools/phones.d.ts.map +1 -0
  41. package/dist/tools/phones.js +69 -0
  42. package/dist/tools/phones.js.map +1 -0
  43. package/dist/tools/profiles.d.ts +4 -0
  44. package/dist/tools/profiles.d.ts.map +1 -0
  45. package/dist/tools/profiles.js +183 -0
  46. package/dist/tools/profiles.js.map +1 -0
  47. package/dist/tools/projects.d.ts +4 -0
  48. package/dist/tools/projects.d.ts.map +1 -0
  49. package/dist/tools/projects.js +159 -0
  50. package/dist/tools/projects.js.map +1 -0
  51. package/dist/tools/proofs.d.ts +4 -0
  52. package/dist/tools/proofs.d.ts.map +1 -0
  53. package/dist/tools/proofs.js +60 -0
  54. package/dist/tools/proofs.js.map +1 -0
  55. package/dist/tools/public-profiles.d.ts +4 -0
  56. package/dist/tools/public-profiles.d.ts.map +1 -0
  57. package/dist/tools/public-profiles.js +38 -0
  58. package/dist/tools/public-profiles.js.map +1 -0
  59. package/dist/tools/sessions.d.ts +4 -0
  60. package/dist/tools/sessions.d.ts.map +1 -0
  61. package/dist/tools/sessions.js +50 -0
  62. package/dist/tools/sessions.js.map +1 -0
  63. package/dist/tools/settings.d.ts +4 -0
  64. package/dist/tools/settings.d.ts.map +1 -0
  65. package/dist/tools/settings.js +66 -0
  66. package/dist/tools/settings.js.map +1 -0
  67. package/dist/tools/templates.d.ts +4 -0
  68. package/dist/tools/templates.d.ts.map +1 -0
  69. package/dist/tools/templates.js +115 -0
  70. package/dist/tools/templates.js.map +1 -0
  71. package/dist/tools/twofa.d.ts +4 -0
  72. package/dist/tools/twofa.d.ts.map +1 -0
  73. package/dist/tools/twofa.js +71 -0
  74. package/dist/tools/twofa.js.map +1 -0
  75. package/dist/tools/user-domain-verify.d.ts +4 -0
  76. package/dist/tools/user-domain-verify.d.ts.map +1 -0
  77. package/dist/tools/user-domain-verify.js +46 -0
  78. package/dist/tools/user-domain-verify.js.map +1 -0
  79. package/dist/tools/user-requests.d.ts +4 -0
  80. package/dist/tools/user-requests.d.ts.map +1 -0
  81. package/dist/tools/user-requests.js +103 -0
  82. package/dist/tools/user-requests.js.map +1 -0
  83. package/dist/tools/verification-requests.d.ts +4 -0
  84. package/dist/tools/verification-requests.d.ts.map +1 -0
  85. package/dist/tools/verification-requests.js +101 -0
  86. package/dist/tools/verification-requests.js.map +1 -0
  87. package/dist/tools/verifications.d.ts +4 -0
  88. package/dist/tools/verifications.d.ts.map +1 -0
  89. package/dist/tools/verifications.js +191 -0
  90. package/dist/tools/verifications.js.map +1 -0
  91. package/dist/tools/webhook-deliveries.d.ts +4 -0
  92. package/dist/tools/webhook-deliveries.d.ts.map +1 -0
  93. package/dist/tools/webhook-deliveries.js +68 -0
  94. package/dist/tools/webhook-deliveries.js.map +1 -0
  95. package/dist/types.d.ts +24 -0
  96. package/dist/types.d.ts.map +1 -0
  97. package/dist/types.js +35 -0
  98. package/dist/types.js.map +1 -0
  99. package/package.json +57 -0
@@ -0,0 +1,96 @@
1
+ import { z } from 'zod';
2
+ import { jsonResult, errorResult } from '../types.js';
3
+ import { ApiError } from '../http.js';
4
+ export function registerTools(tool, http) {
5
+ tool('list_emails', 'List all email addresses associated with the authenticated account.', {}, async () => {
6
+ try {
7
+ const result = await http.get('/api/v1/me/emails');
8
+ return jsonResult(result);
9
+ }
10
+ catch (e) {
11
+ if (e instanceof ApiError)
12
+ return errorResult(`${e.code}: ${e.message}`);
13
+ throw e;
14
+ }
15
+ });
16
+ tool('remove_email', 'Remove an email address from the account by ID. May require 2FA verification for sensitive operations.', {
17
+ id: z.string().describe('Email record ID'),
18
+ }, async ({ id }) => {
19
+ try {
20
+ const result = await http.del(`/api/v1/me/emails/${encodeURIComponent(id)}`);
21
+ return jsonResult(result);
22
+ }
23
+ catch (e) {
24
+ if (e instanceof ApiError)
25
+ return errorResult(`${e.code}: ${e.message}`);
26
+ throw e;
27
+ }
28
+ });
29
+ tool('set_primary_email', 'Set an email address as the primary email for the account.', {
30
+ id: z.string().describe('Email record ID to set as primary'),
31
+ }, async ({ id }) => {
32
+ try {
33
+ const result = await http.put(`/api/v1/me/emails/${encodeURIComponent(id)}/primary`);
34
+ return jsonResult(result);
35
+ }
36
+ catch (e) {
37
+ if (e instanceof ApiError)
38
+ return errorResult(`${e.code}: ${e.message}`);
39
+ throw e;
40
+ }
41
+ });
42
+ tool('start_add_email', 'Start adding a new email address. Sends an OTP code to the email. Returns a session ID to verify with.', {
43
+ email: z.string().email().describe('Email address to add'),
44
+ }, async (args) => {
45
+ try {
46
+ const result = await http.post('/api/v1/me/emails/add', args);
47
+ return jsonResult(result);
48
+ }
49
+ catch (e) {
50
+ if (e instanceof ApiError)
51
+ return errorResult(`${e.code}: ${e.message}`);
52
+ throw e;
53
+ }
54
+ });
55
+ tool('get_add_email_status', 'Check the status of an in-progress email addition by session ID.', {
56
+ session_id: z.string().describe('Add-email session ID'),
57
+ }, async ({ session_id }) => {
58
+ try {
59
+ const result = await http.get(`/api/v1/me/emails/add/${encodeURIComponent(session_id)}`);
60
+ return jsonResult(result);
61
+ }
62
+ catch (e) {
63
+ if (e instanceof ApiError)
64
+ return errorResult(`${e.code}: ${e.message}`);
65
+ throw e;
66
+ }
67
+ });
68
+ tool('verify_email_otp', 'Submit the OTP code to verify an email addition. Completes the add-email flow if the code is correct.', {
69
+ session_id: z.string().describe('Add-email session ID'),
70
+ code: z.string().min(1).max(10).describe('OTP code received via email'),
71
+ }, async ({ session_id, code }) => {
72
+ try {
73
+ const result = await http.post(`/api/v1/me/emails/add/${encodeURIComponent(session_id)}/verify`, { code });
74
+ return jsonResult(result);
75
+ }
76
+ catch (e) {
77
+ if (e instanceof ApiError)
78
+ return errorResult(`${e.code}: ${e.message}`);
79
+ throw e;
80
+ }
81
+ });
82
+ tool('resend_email_otp', 'Resend the OTP code for an in-progress email addition.', {
83
+ session_id: z.string().describe('Add-email session ID'),
84
+ }, async ({ session_id }) => {
85
+ try {
86
+ const result = await http.post(`/api/v1/me/emails/add/${encodeURIComponent(session_id)}/resend`);
87
+ return jsonResult(result);
88
+ }
89
+ catch (e) {
90
+ if (e instanceof ApiError)
91
+ return errorResult(`${e.code}: ${e.message}`);
92
+ throw e;
93
+ }
94
+ });
95
+ }
96
+ //# sourceMappingURL=emails.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"emails.js","sourceRoot":"","sources":["../../src/tools/emails.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AAGxB,OAAO,EAAE,UAAU,EAAE,WAAW,EAAE,MAAM,aAAa,CAAC;AACtD,OAAO,EAAE,QAAQ,EAAE,MAAM,YAAY,CAAC;AAEtC,MAAM,UAAU,aAAa,CAAC,IAAmB,EAAE,IAAgB;IACjE,IAAI,CACF,aAAa,EACb,qEAAqE,EACrE,EAAE,EACF,KAAK,IAAI,EAAE;QACT,IAAI,CAAC;YACH,MAAM,MAAM,GAAG,MAAM,IAAI,CAAC,GAAG,CAAC,mBAAmB,CAAC,CAAC;YACnD,OAAO,UAAU,CAAC,MAAM,CAAC,CAAC;QAC5B,CAAC;QAAC,OAAO,CAAC,EAAE,CAAC;YACX,IAAI,CAAC,YAAY,QAAQ;gBAAE,OAAO,WAAW,CAAC,GAAG,CAAC,CAAC,IAAI,KAAK,CAAC,CAAC,OAAO,EAAE,CAAC,CAAC;YACzE,MAAM,CAAC,CAAC;QACV,CAAC;IACH,CAAC,CACF,CAAC;IAEF,IAAI,CACF,cAAc,EACd,wGAAwG,EACxG;QACE,EAAE,EAAE,CAAC,CAAC,MAAM,EAAE,CAAC,QAAQ,CAAC,iBAAiB,CAAC;KAC3C,EACD,KAAK,EAAE,EAAE,EAAE,EAAE,EAAE,EAAE;QACf,IAAI,CAAC;YACH,MAAM,MAAM,GAAG,MAAM,IAAI,CAAC,GAAG,CAAC,qBAAqB,kBAAkB,CAAC,EAAE,CAAC,EAAE,CAAC,CAAC;YAC7E,OAAO,UAAU,CAAC,MAAM,CAAC,CAAC;QAC5B,CAAC;QAAC,OAAO,CAAC,EAAE,CAAC;YACX,IAAI,CAAC,YAAY,QAAQ;gBAAE,OAAO,WAAW,CAAC,GA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AAC;YACzE,MAAM,CAAC,CAAC;QACV,CAAC;IACH,CAAC,CACF,CAAC;IAEF,IAAI,CACF,kBAAkB,EAClB,wDAAwD,EACxD;QACE,UAAU,EAAE,CAAC,CAAC,MAAM,EAAE,CAAC,QAAQ,CAAC,sBAAsB,CAAC;KACxD,EACD,KAAK,EAAE,EAAE,UAAU,EAAE,EAAE,EAAE;QACvB,IAAI,CAAC;YACH,MAAM,MAAM,GAAG,MAAM,IAAI,CAAC,IAAI,CAAC,yBAAyB,kBAAkB,CAAC,UAAU,CAAC,SAAS,CAAC,CAAC;YACjG,OAAO,UAAU,CAAC,MAAM,CAAC,CAAC;QAC5B,CAAC;QAAC,OAAO,CAAC,EAAE,CAAC;YACX,IAAI,CAAC,YAAY,QAAQ;gBAAE,OAAO,WAAW,CAAC,GAAG,CAAC,CAAC,IAAI,KAAK,CAAC,CAAC,OAAO,EAAE,CAAC,CAAC;YACzE,MAAM,CAAC,CAAC;QACV,CAAC;IACH,CAAC,CACF,CAAC;AACJ,CAAC"}
@@ -0,0 +1,4 @@
1
+ import type { HttpClient } from '../http.js';
2
+ import type { ToolRegistrar } from '../types.js';
3
+ export declare function registerTools(tool: ToolRegistrar, http: HttpClient): void;
4
+ //# sourceMappingURL=phones.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"phones.d.ts","sourceRoot":"","sources":["../../src/tools/phones.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,UAAU,EAAE,MAAM,YAAY,CAAC;AAC7C,OAAO,KAAK,EAAE,aAAa,EAAE,MAAM,aAAa,CAAC;AAIjD,wBAAgB,aAAa,CAAC,IAAI,EAAE,aAAa,EAAE,IAAI,EAAE,UAAU,QAmFlE"}
@@ -0,0 +1,69 @@
1
+ import { z } from 'zod';
2
+ import { jsonResult, errorResult } from '../types.js';
3
+ import { ApiError } from '../http.js';
4
+ export function registerTools(tool, http) {
5
+ tool('list_phones', 'List all phone numbers associated with the authenticated account.', {}, async () => {
6
+ try {
7
+ const result = await http.get('/api/v1/me/phones');
8
+ return jsonResult(result);
9
+ }
10
+ catch (e) {
11
+ if (e instanceof ApiError)
12
+ return errorResult(`${e.code}: ${e.message}`);
13
+ throw e;
14
+ }
15
+ });
16
+ tool('remove_phone', 'Remove a phone number from the account by ID. May require 2FA verification for sensitive operations.', {
17
+ id: z.string().describe('Phone record ID'),
18
+ }, async ({ id }) => {
19
+ try {
20
+ const result = await http.del(`/api/v1/me/phones/${encodeURIComponent(id)}`);
21
+ return jsonResult(result);
22
+ }
23
+ catch (e) {
24
+ if (e instanceof ApiError)
25
+ return errorResult(`${e.code}: ${e.message}`);
26
+ throw e;
27
+ }
28
+ });
29
+ tool('set_primary_phone', 'Set a phone number as the primary phone for the account.', {
30
+ id: z.string().describe('Phone record ID to set as primary'),
31
+ }, async ({ id }) => {
32
+ try {
33
+ const result = await http.put(`/api/v1/me/phones/${encodeURIComponent(id)}/primary`);
34
+ return jsonResult(result);
35
+ }
36
+ catch (e) {
37
+ if (e instanceof ApiError)
38
+ return errorResult(`${e.code}: ${e.message}`);
39
+ throw e;
40
+ }
41
+ });
42
+ tool('start_add_phone', 'Start adding a new phone number. Uses reverse OTP: the system sends a message and the user replies. Returns a session ID to poll for status.', {
43
+ channel: z.enum(['telegram', 'whatsapp', 'sms']).describe('Channel for phone verification'),
44
+ }, async (args) => {
45
+ try {
46
+ const result = await http.post('/api/v1/me/phones/add', args);
47
+ return jsonResult(result);
48
+ }
49
+ catch (e) {
50
+ if (e instanceof ApiError)
51
+ return errorResult(`${e.code}: ${e.message}`);
52
+ throw e;
53
+ }
54
+ });
55
+ tool('get_add_phone_status', 'Check the status of an in-progress phone addition by session ID. Poll until terminal state.', {
56
+ session_id: z.string().describe('Add-phone session ID'),
57
+ }, async ({ session_id }) => {
58
+ try {
59
+ const result = await http.get(`/api/v1/me/phones/add/${encodeURIComponent(session_id)}`);
60
+ return jsonResult(result);
61
+ }
62
+ catch (e) {
63
+ if (e instanceof ApiError)
64
+ return errorResult(`${e.code}: ${e.message}`);
65
+ throw e;
66
+ }
67
+ });
68
+ }
69
+ //# sourceMappingURL=phones.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"phones.js","sourceRoot":"","sources":["../../src/tools/phones.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AAGxB,OAAO,EAAE,UAAU,EAAE,WAAW,EAAE,MAAM,aAAa,CAAC;AACtD,OAAO,EAAE,QAAQ,EAAE,MAAM,YAAY,CAAC;AAEtC,MAAM,UAAU,aAAa,CAAC,IAAmB,EAAE,IAAgB;IACjE,IAAI,CACF,aAAa,EACb,mEAAmE,EACnE,EAAE,EACF,KAAK,IAAI,EAAE;QACT,IAAI,CAAC;YACH,MAAM,MAAM,GAAG,MAAM,IAAI,CAAC,GAAG,CAAC,mBAAmB,CAAC,CAAC;YACnD,OAAO,UAAU,CAAC,MAAM,CAAC,CAAC;QAC5B,CAAC;QAAC,OAAO,CAAC,EAAE,CAAC;YACX,IAAI,CAAC,YAAY,QAAQ;gBAAE,OAAO,WAAW,CAAC,GAAG,CAAC,CAAC,IAAI,KAAK,CAAC,CAAC,OAAO,EAAE,CAAC,CAAC;YACzE,MAAM,CAAC,CAAC;QACV,CAAC;IACH,CAAC,CACF,CAAC;IAEF,IAAI,CACF,cAAc,EACd,sGAAsG,EACtG;QACE,EAAE,EAAE,CAAC,CAAC,MAAM,EAAE,CAAC,QAAQ,CAAC,iBAAiB,CAAC;KAC3C,EACD,KAAK,EAAE,EAAE,EAAE,EAAE,EAAE,EAAE;QACf,IAAI,CAAC;YACH,MAAM,MAAM,GAAG,MAAM,IAAI,CAAC,GAAG,CAAC,qBAAqB,kBAAkB,CAAC,EAAE,CAAC,EAAE,CAAC,CAAC;YAC7E,OAAO,UAAU,CAAC,MAAM,CAAC,CAAC;QAC5B,CAAC;QAAC,OAAO,CAAC,EAAE,CAAC;YACX,IAAI,CAAC,YAAY,QAAQ;gBAAE,OAAO,WAAW,CAAC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QACV,CAAC;IACH,CAAC,CACF,CAAC;IAEF,IAAI,CACF,sBAAsB,EACtB,6FAA6F,EAC7F;QACE,UAAU,EAAE,CAAC,CAAC,MAAM,EAAE,CAAC,QAAQ,CAAC,sBAAsB,CAAC;KACxD,EACD,KAAK,EAAE,EAAE,UAAU,EAAE,EAAE,EAAE;QACvB,IAAI,CAAC;YACH,MAAM,MAAM,GAAG,MAAM,IAAI,CAAC,GAAG,CAAC,yBAAyB,kBAAkB,CAAC,UAAU,CAAC,EAAE,CAAC,CAAC;YACzF,OAAO,UAAU,CAAC,MAAM,CAAC,CAAC;QAC5B,CAAC;QAAC,OAAO,CAAC,EAAE,CAAC;YACX,IAAI,CAAC,YAAY,QAAQ;gBAAE,OAAO,WAAW,CAAC,GAAG,CAAC,CAAC,IAAI,KAAK,CAAC,CAAC,OAAO,EAAE,CAAC,CAAC;YACzE,MAAM,CAAC,CAAC;QACV,CAAC;IACH,CAAC,CACF,CAAC;AACJ,CAAC"}
@@ -0,0 +1,4 @@
1
+ import type { HttpClient } from '../http.js';
2
+ import type { ToolRegistrar } from '../types.js';
3
+ export declare function registerTools(tool: ToolRegistrar, http: HttpClient): void;
4
+ //# sourceMappingURL=profiles.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"profiles.d.ts","sourceRoot":"","sources":["../../src/tools/profiles.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,UAAU,EAAE,MAAM,YAAY,CAAC;AAC7C,OAAO,KAAK,EAAE,aAAa,EAAE,MAAM,aAAa,CAAC;AAqBjD,wBAAgB,aAAa,CAAC,IAAI,EAAE,aAAa,EAAE,IAAI,EAAE,UAAU,QA4MlE"}
@@ -0,0 +1,183 @@
1
+ import { z } from 'zod';
2
+ import { jsonResult, errorResult } from '../types.js';
3
+ import { ApiError } from '../http.js';
4
+ const themeSchema = z.object({
5
+ primary_color: z.string().regex(/^#[0-9A-Fa-f]{6}$/).optional().describe('Primary color (hex)'),
6
+ background_type: z.enum(['solid', 'gradient']).optional().describe('Background type'),
7
+ background_color: z.string().regex(/^#[0-9A-Fa-f]{6}$/).optional().describe('Background color (hex)'),
8
+ gradient_start: z.string().regex(/^#[0-9A-Fa-f]{6}$/).optional().describe('Gradient start color'),
9
+ gradient_end: z.string().regex(/^#[0-9A-Fa-f]{6}$/).optional().describe('Gradient end color'),
10
+ font_style: z.enum(['default', 'modern', 'classic']).optional().describe('Font style'),
11
+ }).optional().describe('Profile theme settings');
12
+ const customLinksSchema = z.array(z.object({
13
+ title: z.string().max(100).describe('Link title'),
14
+ url: z.string().url().max(500).describe('Link URL'),
15
+ icon: z.string().max(50).optional().describe('Icon identifier'),
16
+ is_visible: z.boolean().optional().describe('Whether the link is visible'),
17
+ display_order: z.number().int().min(0).optional().describe('Display order'),
18
+ })).max(20).optional().describe('Custom links (max 20)');
19
+ export function registerTools(tool, http) {
20
+ // =========================================================================
21
+ // Multi-Profile CRUD (via /api/v1/me/profiles — dual auth)
22
+ // =========================================================================
23
+ tool('list_profiles', 'List all profiles for the authenticated account. Returns all profiles including primary and secondary.', {}, async () => {
24
+ try {
25
+ const result = await http.get('/api/v1/me/profiles');
26
+ return jsonResult(result);
27
+ }
28
+ catch (e) {
29
+ if (e instanceof ApiError)
30
+ return errorResult(`${e.code}: ${e.message}`);
31
+ throw e;
32
+ }
33
+ });
34
+ tool('create_profile', 'Create a new profile with optional display name, bio, avatar, business info, and theme settings.', {
35
+ display_name: z.string().max(100).optional().describe('Display name'),
36
+ bio: z.string().max(500).optional().describe('Profile bio'),
37
+ avatar_url: z.string().max(100000).optional().describe('Avatar as base64 data URI or URL (~75KB limit)'),
38
+ business_name: z.string().max(100).optional().describe('Business name'),
39
+ is_business: z.boolean().optional().describe('Whether this is a business profile'),
40
+ is_public: z.boolean().optional().describe('Whether the profile is publicly visible'),
41
+ is_primary: z.boolean().optional().describe('Set as primary profile'),
42
+ theme: themeSchema,
43
+ }, async (args) => {
44
+ try {
45
+ const result = await http.post('/api/v1/me/profiles', args);
46
+ return jsonResult(result);
47
+ }
48
+ catch (e) {
49
+ if (e instanceof ApiError)
50
+ return errorResult(`${e.code}: ${e.message}`);
51
+ throw e;
52
+ }
53
+ });
54
+ tool('get_profile', 'Get a specific profile by ID. Returns full profile details including theme, custom links, and verification display settings.', {
55
+ profile_id: z.string().describe('Profile ID'),
56
+ }, async ({ profile_id }) => {
57
+ try {
58
+ const result = await http.get(`/api/v1/me/profiles/${encodeURIComponent(profile_id)}`);
59
+ return jsonResult(result);
60
+ }
61
+ catch (e) {
62
+ if (e instanceof ApiError)
63
+ return errorResult(`${e.code}: ${e.message}`);
64
+ throw e;
65
+ }
66
+ });
67
+ tool('update_profile', 'Update a profile by ID. Supports changing display info, theme, custom links, and verification display settings.', {
68
+ profile_id: z.string().describe('Profile ID'),
69
+ display_name: z.string().max(100).optional().describe('Display name'),
70
+ bio: z.string().max(500).optional().describe('Profile bio'),
71
+ avatar_url: z.string().max(100000).optional().nullable().describe('Avatar (base64 or URL, null to remove)'),
72
+ business_name: z.string().max(100).optional().describe('Business name'),
73
+ is_business: z.boolean().optional().describe('Whether this is a business profile'),
74
+ is_public: z.boolean().optional().describe('Whether the profile is publicly visible'),
75
+ is_primary: z.boolean().optional().describe('Set as primary profile'),
76
+ show_verification_dates: z.boolean().optional().describe('Show verification dates on public profile'),
77
+ show_proof_channels: z.boolean().optional().describe('Show proof channels on public profile'),
78
+ theme: themeSchema,
79
+ custom_links: customLinksSchema,
80
+ }, async ({ profile_id, ...body }) => {
81
+ try {
82
+ const result = await http.patch(`/api/v1/me/profiles/${encodeURIComponent(profile_id)}`, body);
83
+ return jsonResult(result);
84
+ }
85
+ catch (e) {
86
+ if (e instanceof ApiError)
87
+ return errorResult(`${e.code}: ${e.message}`);
88
+ throw e;
89
+ }
90
+ });
91
+ tool('delete_profile', 'Delete a profile by ID. Cannot delete the primary profile if it is the only one.', {
92
+ profile_id: z.string().describe('Profile ID'),
93
+ }, async ({ profile_id }) => {
94
+ try {
95
+ const result = await http.del(`/api/v1/me/profiles/${encodeURIComponent(profile_id)}`);
96
+ return jsonResult(result);
97
+ }
98
+ catch (e) {
99
+ if (e instanceof ApiError)
100
+ return errorResult(`${e.code}: ${e.message}`);
101
+ throw e;
102
+ }
103
+ });
104
+ tool('set_primary_profile', 'Set a profile as the primary profile. The previous primary profile becomes secondary.', {
105
+ profile_id: z.string().describe('Profile ID to set as primary'),
106
+ }, async ({ profile_id }) => {
107
+ try {
108
+ const result = await http.post(`/api/v1/me/profiles/${encodeURIComponent(profile_id)}/primary`);
109
+ return jsonResult(result);
110
+ }
111
+ catch (e) {
112
+ if (e instanceof ApiError)
113
+ return errorResult(`${e.code}: ${e.message}`);
114
+ throw e;
115
+ }
116
+ });
117
+ // =========================================================================
118
+ // Profile Proofs & Legacy Endpoints (via /api/v1/profiles/* — dual auth)
119
+ // =========================================================================
120
+ tool('update_profile_proofs', 'Update which verified assets (proofs) are displayed on a specific profile. Controls visibility, privacy masking, ordering, and labels.', {
121
+ profile_id: z.string().describe('Profile ID'),
122
+ proofs: z.array(z.object({
123
+ asset_id: z.string().describe('Asset ID to display'),
124
+ is_visible: z.boolean().optional().describe('Whether this proof is visible'),
125
+ mask_level: z.enum(['full', 'partial', 'hidden']).optional().describe('Privacy masking level'),
126
+ display_order: z.number().int().min(0).optional().describe('Display order'),
127
+ label: z.string().max(50).optional().describe('Custom label (e.g. "Support Phone")'),
128
+ })).max(50).describe('Proofs to display on profile'),
129
+ }, async ({ profile_id, proofs }) => {
130
+ try {
131
+ const result = await http.put(`/api/v1/profiles/profiles/${encodeURIComponent(profile_id)}/proofs`, { proofs });
132
+ return jsonResult(result);
133
+ }
134
+ catch (e) {
135
+ if (e instanceof ApiError)
136
+ return errorResult(`${e.code}: ${e.message}`);
137
+ throw e;
138
+ }
139
+ });
140
+ tool('get_my_profile', 'Get the current user\'s primary profile. Returns profile details, theme, custom links, and public proof display settings.', {}, async () => {
141
+ try {
142
+ const result = await http.get('/api/v1/profiles/me');
143
+ return jsonResult(result);
144
+ }
145
+ catch (e) {
146
+ if (e instanceof ApiError)
147
+ return errorResult(`${e.code}: ${e.message}`);
148
+ throw e;
149
+ }
150
+ });
151
+ tool('update_my_profile', 'Update the current user\'s primary profile. Supports display name, bio, avatar, theme, custom links, and verification display settings.', {
152
+ display_name: z.string().max(100).optional().describe('Display name'),
153
+ bio: z.string().max(500).optional().describe('Profile bio'),
154
+ avatar_url: z.string().max(500000).refine((v) => v.startsWith('https://') || v.startsWith('data:image/'), { message: 'Must be an HTTPS URL or base64 data URI' }).optional().nullable().describe('Avatar (HTTPS URL or base64 data URI, null to remove)'),
155
+ is_public: z.boolean().optional().describe('Whether the profile is publicly visible'),
156
+ show_verification_dates: z.boolean().optional().describe('Show verification dates'),
157
+ show_proof_channels: z.boolean().optional().describe('Show proof channels'),
158
+ theme: themeSchema,
159
+ custom_links: customLinksSchema,
160
+ }, async (args) => {
161
+ try {
162
+ const result = await http.put('/api/v1/profiles/me', args);
163
+ return jsonResult(result);
164
+ }
165
+ catch (e) {
166
+ if (e instanceof ApiError)
167
+ return errorResult(`${e.code}: ${e.message}`);
168
+ throw e;
169
+ }
170
+ });
171
+ tool('get_profile_assets', 'Get available verified assets that can be displayed on the user\'s profile. Returns assets eligible for public proof display.', {}, async () => {
172
+ try {
173
+ const result = await http.get('/api/v1/profiles/me/assets');
174
+ return jsonResult(result);
175
+ }
176
+ catch (e) {
177
+ if (e instanceof ApiError)
178
+ return errorResult(`${e.code}: ${e.message}`);
179
+ throw e;
180
+ }
181
+ });
182
+ }
183
+ //# sourceMappingURL=profiles.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"profiles.js","sourceRoot":"","sources":["../../src/tools/profiles.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AAGxB,OAAO,EAAE,UAAU,EAAE,WAAW,EAAE,MAAM,aAAa,CAAC;AACtD,OAAO,EAAE,QAAQ,EAAE,MAAM,YAAY,CAAC;AAEtC,MAAM,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CAAC,CAAC;YACzE,MAAM,CAAC,CAAC;QACV,CAAC;IACH,CAAC,CACF,CAAC;IAEF,IAAI,CACF,oBAAoB,EACpB,+HAA+H,EAC/H,EAAE,EACF,KAAK,IAAI,EAAE;QACT,IAAI,CAAC;YACH,MAAM,MAAM,GAAG,MAAM,IAAI,CAAC,GAAG,CAAC,4BAA4B,CAAC,CAAC;YAC5D,OAAO,UAAU,CAAC,MAAM,CAAC,CAAC;QAC5B,CAAC;QAAC,OAAO,CAAC,EAAE,CAAC;YACX,IAAI,CAAC,YAAY,QAAQ;gBAAE,OAAO,WAAW,CAAC,GAAG,CAAC,CAAC,IAAI,KAAK,CAAC,CAAC,OAAO,EAAE,CAAC,CAAC;YACzE,MAAM,CAAC,CAAC;QACV,CAAC;IACH,CAAC,CACF,CAAC;AACJ,CAAC"}
@@ -0,0 +1,4 @@
1
+ import type { HttpClient } from '../http.js';
2
+ import type { ToolRegistrar } from '../types.js';
3
+ export declare function registerTools(tool: ToolRegistrar, http: HttpClient): void;
4
+ //# sourceMappingURL=projects.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"projects.d.ts","sourceRoot":"","sources":["../../src/tools/projects.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,UAAU,EAAE,MAAM,YAAY,CAAC;AAC7C,OAAO,KAAK,EAAE,aAAa,EAAE,MAAM,aAAa,CAAC;AAIjD,wBAAgB,aAAa,CAAC,IAAI,EAAE,aAAa,EAAE,IAAI,EAAE,UAAU,QA6LlE"}
@@ -0,0 +1,159 @@
1
+ import { z } from 'zod';
2
+ import { jsonResult, errorResult } from '../types.js';
3
+ import { ApiError } from '../http.js';
4
+ export function registerTools(tool, http) {
5
+ tool('list_projects', 'List all projects for the authenticated account. Projects enable multi-brand support with separate branding and templates.', {}, async () => {
6
+ try {
7
+ const result = await http.get('/api/v1/me/projects');
8
+ return jsonResult(result);
9
+ }
10
+ catch (e) {
11
+ if (e instanceof ApiError)
12
+ return errorResult(`${e.code}: ${e.message}`);
13
+ throw e;
14
+ }
15
+ });
16
+ tool('create_project', 'Create a new project with optional branding configuration (business name, logo, colors, support email).', {
17
+ name: z.string().min(1).max(100).describe('Project name'),
18
+ description: z.string().max(500).optional().describe('Project description'),
19
+ branding: z.object({
20
+ business_name: z.string().max(100).optional().describe('Business name for this project'),
21
+ logo_url: z.string().url().refine((u) => u.startsWith('https://'), { message: 'Logo URL must use HTTPS' }).optional().describe('HTTPS URL to project logo'),
22
+ primary_color: z.string().regex(/^#[0-9A-Fa-f]{6}$/).optional().describe('Primary brand color (hex, e.g. #FF5733)'),
23
+ support_email: z.string().email().optional().describe('Support email for this project'),
24
+ }).optional().describe('Project branding configuration'),
25
+ }, async (args) => {
26
+ try {
27
+ const result = await http.post('/api/v1/me/projects', args);
28
+ return jsonResult(result);
29
+ }
30
+ catch (e) {
31
+ if (e instanceof ApiError)
32
+ return errorResult(`${e.code}: ${e.message}`);
33
+ throw e;
34
+ }
35
+ });
36
+ tool('get_project', 'Get a project by ID. Returns project details including name, description, branding, and callback URLs.', {
37
+ id: z.string().describe('Project ID'),
38
+ }, async ({ id }) => {
39
+ try {
40
+ const result = await http.get(`/api/v1/me/projects/${encodeURIComponent(id)}`);
41
+ return jsonResult(result);
42
+ }
43
+ catch (e) {
44
+ if (e instanceof ApiError)
45
+ return errorResult(`${e.code}: ${e.message}`);
46
+ throw e;
47
+ }
48
+ });
49
+ tool('update_project', 'Update a project. Supports changing name, description, branding, and callback URLs.', {
50
+ id: z.string().describe('Project ID'),
51
+ name: z.string().min(1).max(100).optional().describe('Project name'),
52
+ description: z.string().max(500).optional().describe('Project description'),
53
+ branding: z.object({
54
+ business_name: z.string().max(100).optional().describe('Business name'),
55
+ logo_url: z.string().url().refine((u) => u.startsWith('https://'), { message: 'Logo URL must use HTTPS' }).optional().describe('HTTPS URL to project logo'),
56
+ primary_color: z.string().regex(/^#[0-9A-Fa-f]{6}$/).optional().describe('Primary brand color (hex)'),
57
+ support_email: z.string().email().optional().describe('Support email'),
58
+ }).optional().describe('Branding configuration'),
59
+ callbacks: z.object({
60
+ success_url: z.string().url().refine((u) => u.startsWith('https://'), { message: 'Callback URL must use HTTPS' }).optional().describe('Success callback URL'),
61
+ failure_url: z.string().url().refine((u) => u.startsWith('https://'), { message: 'Callback URL must use HTTPS' }).optional().describe('Failure callback URL'),
62
+ cancel_url: z.string().url().refine((u) => u.startsWith('https://'), { message: 'Callback URL must use HTTPS' }).optional().describe('Cancel callback URL'),
63
+ }).optional().describe('Callback URLs'),
64
+ }, async ({ id, ...body }) => {
65
+ try {
66
+ const result = await http.put(`/api/v1/me/projects/${encodeURIComponent(id)}`, body);
67
+ return jsonResult(result);
68
+ }
69
+ catch (e) {
70
+ if (e instanceof ApiError)
71
+ return errorResult(`${e.code}: ${e.message}`);
72
+ throw e;
73
+ }
74
+ });
75
+ tool('delete_project', 'Delete a project by ID. This removes the project and all its custom templates.', {
76
+ id: z.string().describe('Project ID'),
77
+ }, async ({ id }) => {
78
+ try {
79
+ const result = await http.del(`/api/v1/me/projects/${encodeURIComponent(id)}`);
80
+ return jsonResult(result);
81
+ }
82
+ catch (e) {
83
+ if (e instanceof ApiError)
84
+ return errorResult(`${e.code}: ${e.message}`);
85
+ throw e;
86
+ }
87
+ });
88
+ tool('list_project_templates', 'List all custom templates for a project. Returns templates organized by channel and message type.', {
89
+ id: z.string().describe('Project ID'),
90
+ }, async ({ id }) => {
91
+ try {
92
+ const result = await http.get(`/api/v1/me/projects/${encodeURIComponent(id)}/templates`);
93
+ return jsonResult(result);
94
+ }
95
+ catch (e) {
96
+ if (e instanceof ApiError)
97
+ return errorResult(`${e.code}: ${e.message}`);
98
+ throw e;
99
+ }
100
+ });
101
+ tool('update_project_template', 'Create or update a custom template for a specific project, channel, and message type.', {
102
+ id: z.string().describe('Project ID'),
103
+ channel: z.enum(['telegram', 'whatsapp', 'sms', 'email']).describe('Message channel'),
104
+ type: z.string().describe('Message type (e.g. verification_request, login_request)'),
105
+ subject: z.string().max(200).optional().describe('Email subject line (email channel only)'),
106
+ body: z.string().min(1).max(2000).describe('Template body text with variable placeholders'),
107
+ button_text: z.string().max(50).optional().describe('Button text (email channel only)'),
108
+ button_url_template: z.string().max(500).optional().describe('Button URL template with placeholders'),
109
+ is_active: z.boolean().optional().describe('Whether the template is active'),
110
+ }, async ({ id, channel, type, ...body }) => {
111
+ try {
112
+ const result = await http.put(`/api/v1/me/projects/${encodeURIComponent(id)}/templates/${encodeURIComponent(channel)}/${encodeURIComponent(type)}`, body);
113
+ return jsonResult(result);
114
+ }
115
+ catch (e) {
116
+ if (e instanceof ApiError)
117
+ return errorResult(`${e.code}: ${e.message}`);
118
+ throw e;
119
+ }
120
+ });
121
+ tool('delete_project_template', 'Delete a custom project template, reverting to the default template for that channel and message type.', {
122
+ id: z.string().describe('Project ID'),
123
+ channel: z.enum(['telegram', 'whatsapp', 'sms', 'email']).describe('Message channel'),
124
+ type: z.string().describe('Message type (e.g. verification_request, login_request)'),
125
+ }, async ({ id, channel, type }) => {
126
+ try {
127
+ const result = await http.del(`/api/v1/me/projects/${encodeURIComponent(id)}/templates/${encodeURIComponent(channel)}/${encodeURIComponent(type)}`);
128
+ return jsonResult(result);
129
+ }
130
+ catch (e) {
131
+ if (e instanceof ApiError)
132
+ return errorResult(`${e.code}: ${e.message}`);
133
+ throw e;
134
+ }
135
+ });
136
+ tool('preview_project_template', 'Preview a project template with sample data before saving. Shows how the message will look with placeholder variables filled in.', {
137
+ id: z.string().describe('Project ID'),
138
+ channel: z.enum(['telegram', 'whatsapp', 'sms', 'email']).describe('Message channel'),
139
+ message_type: z.enum([
140
+ 'verification_request', 'verification_success', 'verification_expired',
141
+ 'login_request', 'login_success', '2fa_request', '2fa_success',
142
+ ]).describe('Message type'),
143
+ subject: z.string().max(200).optional().describe('Email subject line'),
144
+ body: z.string().min(1).max(2000).describe('Template body text'),
145
+ button_text: z.string().max(50).optional().describe('Button text'),
146
+ button_url_template: z.string().max(500).optional().describe('Button URL template'),
147
+ }, async ({ id, ...body }) => {
148
+ try {
149
+ const result = await http.post(`/api/v1/me/projects/${encodeURIComponent(id)}/templates/preview`, body);
150
+ return jsonResult(result);
151
+ }
152
+ catch (e) {
153
+ if (e instanceof ApiError)
154
+ return errorResult(`${e.code}: ${e.message}`);
155
+ throw e;
156
+ }
157
+ });
158
+ }
159
+ //# sourceMappingURL=projects.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"projects.js","sourceRoot":"","sources":["../../src/tools/projects.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AAGxB,OAAO,EAAE,UAAU,EAAE,WAAW,EAAE,MAAM,aAAa,CAAC;AACtD,OAAO,EAAE,QAAQ,EAAE,MAAM,YAAY,CAAC;AAEtC,MAAM,UAAU,aAAa,CAAC,IAAmB,EAAE,IAAgB;IACjE,IAAI,CACF,eAAe,EACf,4HAA4H,EAC5H,EAAE,EACF,KAAK,IAAI,EAAE;QACT,IAAI,CAAC;YACH,MAAM,MAAM,GAAG,MAAM,IAAI,CAAC,GAAG,CAAC,qBAAqB,CAAC,CAAC;YACrD,OAAO,UAAU,CAAC,MAAM,CAAC,CAAC;QAC5B,CAAC;QAAC,OAAO,CAAC,EAAE,CAAC;YACX,IAAI,CAAC,YAAY,QAAQ;gBAAE,OAAO,WAAW,CAAC,GAAG,CAAC,CAAC,IAAI,KAAK,CAAC,CAAC,OAAO,EAAE,CAAC,CAAC;YACzE,MAAM,CAAC,CAAC;QACV,CAAC;IACH,CAAC,CACF,CAAC;IAEF,IAAI,CACF,gBAAgB,EAChB,yGAAyG,EACzG;QACE,IAAI,EAAE,CAAC,CAAC,MAAM,EAAE,CAAC,GAAG,CAAC,CAAC,CAAC,CAAC,GAAG,CAAC,GAAG,CAAC,CAAC,QAAQ,CAAC,cAAc,CAAC;QACzD,WAAW,EAAE,CAAC,CAAC,MAAM,EAAE,CAAC,GAAG,CAAC,GAAG,CAAC,CAAC,QAAQ,EAAE,CAAC,QAAQ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I,CAAC;YACH,MAAM,MAAM,GAAG,MAAM,IAAI,CAAC,IAAI,CAAC,uBAAuB,kBAAkB,CAAC,EAAE,CAAC,oBAAoB,EAAE,IAAI,CAAC,CAAC;YACxG,OAAO,UAAU,CAAC,MAAM,CAAC,CAAC;QAC5B,CAAC;QAAC,OAAO,CAAC,EAAE,CAAC;YACX,IAAI,CAAC,YAAY,QAAQ;gBAAE,OAAO,WAAW,CAAC,GAAG,CAAC,CAAC,IAAI,KAAK,CAAC,CAAC,OAAO,EAAE,CAAC,CAAC;YACzE,MAAM,CAAC,CAAC;QACV,CAAC;IACH,CAAC,CACF,CAAC;AACJ,CAAC"}
@@ -0,0 +1,4 @@
1
+ import type { HttpClient } from '../http.js';
2
+ import type { ToolRegistrar } from '../types.js';
3
+ export declare function registerTools(tool: ToolRegistrar, http: HttpClient): void;
4
+ //# sourceMappingURL=proofs.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"proofs.d.ts","sourceRoot":"","sources":["../../src/tools/proofs.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,UAAU,EAAE,MAAM,YAAY,CAAC;AAC7C,OAAO,KAAK,EAAE,aAAa,EAAE,MAAM,aAAa,CAAC;AAIjD,wBAAgB,aAAa,CAAC,IAAI,EAAE,aAAa,EAAE,IAAI,EAAE,UAAU,QAsElE"}