agenza-line-bot-mcp 0.0.1-local

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 (85) hide show
  1. package/README.ja.md +199 -0
  2. package/README.md +215 -0
  3. package/dist/common/response.d.ts +14 -0
  4. package/dist/common/response.d.ts.map +1 -0
  5. package/dist/common/response.js +22 -0
  6. package/dist/common/response.js.map +1 -0
  7. package/dist/common/schema/actionSchema.d.ts +139 -0
  8. package/dist/common/schema/actionSchema.d.ts.map +1 -0
  9. package/dist/common/schema/actionSchema.js +85 -0
  10. package/dist/common/schema/actionSchema.js.map +1 -0
  11. package/dist/common/schema/constants.d.ts +2 -0
  12. package/dist/common/schema/constants.d.ts.map +1 -0
  13. package/dist/common/schema/constants.js +2 -0
  14. package/dist/common/schema/constants.js.map +1 -0
  15. package/dist/common/schema/flexMessage.d.ts +1654 -0
  16. package/dist/common/schema/flexMessage.d.ts.map +1 -0
  17. package/dist/common/schema/flexMessage.js +337 -0
  18. package/dist/common/schema/flexMessage.js.map +1 -0
  19. package/dist/common/schema/textMessage.d.ts +12 -0
  20. package/dist/common/schema/textMessage.d.ts.map +1 -0
  21. package/dist/common/schema/textMessage.js +9 -0
  22. package/dist/common/schema/textMessage.js.map +1 -0
  23. package/dist/index.d.ts +18 -0
  24. package/dist/index.d.ts.map +1 -0
  25. package/dist/index.js +73 -0
  26. package/dist/index.js.map +1 -0
  27. package/dist/tools/AbstractTool.d.ts +9 -0
  28. package/dist/tools/AbstractTool.d.ts.map +1 -0
  29. package/dist/tools/AbstractTool.js +3 -0
  30. package/dist/tools/AbstractTool.js.map +1 -0
  31. package/dist/tools/broadcastFlexMessage.d.ts +9 -0
  32. package/dist/tools/broadcastFlexMessage.d.ts.map +1 -0
  33. package/dist/tools/broadcastFlexMessage.js +28 -0
  34. package/dist/tools/broadcastFlexMessage.js.map +1 -0
  35. package/dist/tools/broadcastTextMessage.d.ts +9 -0
  36. package/dist/tools/broadcastTextMessage.d.ts.map +1 -0
  37. package/dist/tools/broadcastTextMessage.js +27 -0
  38. package/dist/tools/broadcastTextMessage.js.map +1 -0
  39. package/dist/tools/cancelRichMenuDefault.d.ts +9 -0
  40. package/dist/tools/cancelRichMenuDefault.d.ts.map +1 -0
  41. package/dist/tools/cancelRichMenuDefault.js +16 -0
  42. package/dist/tools/cancelRichMenuDefault.js.map +1 -0
  43. package/dist/tools/createRichMenu.d.ts +10 -0
  44. package/dist/tools/createRichMenu.d.ts.map +1 -0
  45. package/dist/tools/createRichMenu.js +278 -0
  46. package/dist/tools/createRichMenu.js.map +1 -0
  47. package/dist/tools/deleteRichMenu.d.ts +9 -0
  48. package/dist/tools/deleteRichMenu.d.ts.map +1 -0
  49. package/dist/tools/deleteRichMenu.js +27 -0
  50. package/dist/tools/deleteRichMenu.js.map +1 -0
  51. package/dist/tools/getMessageQuota.d.ts +9 -0
  52. package/dist/tools/getMessageQuota.d.ts.map +1 -0
  53. package/dist/tools/getMessageQuota.js +21 -0
  54. package/dist/tools/getMessageQuota.js.map +1 -0
  55. package/dist/tools/getProfile.d.ts +10 -0
  56. package/dist/tools/getProfile.d.ts.map +1 -0
  57. package/dist/tools/getProfile.js +34 -0
  58. package/dist/tools/getProfile.js.map +1 -0
  59. package/dist/tools/getRichMenuList.d.ts +9 -0
  60. package/dist/tools/getRichMenuList.d.ts.map +1 -0
  61. package/dist/tools/getRichMenuList.js +21 -0
  62. package/dist/tools/getRichMenuList.js.map +1 -0
  63. package/dist/tools/pushFlexMessage.d.ts +10 -0
  64. package/dist/tools/pushFlexMessage.d.ts.map +1 -0
  65. package/dist/tools/pushFlexMessage.js +40 -0
  66. package/dist/tools/pushFlexMessage.js.map +1 -0
  67. package/dist/tools/pushTextMessage.d.ts +10 -0
  68. package/dist/tools/pushTextMessage.d.ts.map +1 -0
  69. package/dist/tools/pushTextMessage.js +39 -0
  70. package/dist/tools/pushTextMessage.js.map +1 -0
  71. package/dist/tools/setRichMenuDefault.d.ts +9 -0
  72. package/dist/tools/setRichMenuDefault.d.ts.map +1 -0
  73. package/dist/tools/setRichMenuDefault.js +22 -0
  74. package/dist/tools/setRichMenuDefault.js.map +1 -0
  75. package/dist/version.d.ts +3 -0
  76. package/dist/version.d.ts.map +1 -0
  77. package/dist/version.js +3 -0
  78. package/dist/version.js.map +1 -0
  79. package/package.json +54 -0
  80. package/richmenu-template/template-01.md +46 -0
  81. package/richmenu-template/template-02.md +49 -0
  82. package/richmenu-template/template-03.md +74 -0
  83. package/richmenu-template/template-04.md +60 -0
  84. package/richmenu-template/template-05.md +67 -0
  85. package/richmenu-template/template-06.md +66 -0
@@ -0,0 +1,22 @@
1
+ import { createSuccessResponse } from "../common/response.js";
2
+ import { AbstractTool } from "./AbstractTool.js";
3
+ import { z } from "zod";
4
+ export default class SetRichMenuDefault extends AbstractTool {
5
+ client;
6
+ constructor(client) {
7
+ super();
8
+ this.client = client;
9
+ }
10
+ register(server) {
11
+ const richMenuIdSchema = z
12
+ .string()
13
+ .describe("The ID of the rich menu to set as default.");
14
+ server.tool("set_rich_menu_default", "Set a rich menu as the default rich menu.", {
15
+ richMenuId: richMenuIdSchema.describe("The ID of the rich menu to set as default."),
16
+ }, async ({ richMenuId }) => {
17
+ const response = await this.client.setDefaultRichMenu(richMenuId);
18
+ return createSuccessResponse(response);
19
+ });
20
+ }
21
+ }
22
+ //# sourceMappingURL=setRichMenuDefault.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"setRichMenuDefault.js","sourceRoot":"","sources":["../../src/tools/setRichMenuDefault.ts"],"names":[],"mappings":"AAEA,OAAO,EAAE,qBAAqB,EAAE,MAAM,uBAAuB,CAAC;AAC9D,OAAO,EAAE,YAAY,EAAE,MAAM,mBAAmB,CAAC;AACjD,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AAExB,MAAM,CAAC,OAAO,OAAO,kBAAmB,SAAQ,YAAY;IAClD,MAAM,CAAkC;IAEhD,YAAY,MAAuC;QACjD,KAAK,EAAE,CAAC;QACR,IAAI,CAAC,MAAM,GAAG,MAAM,CAAC;IACvB,CAAC;IAED,QAAQ,CAAC,MAAiB;QACxB,MAAM,gBAAgB,GAAG,CAAC;aACvB,MAAM,EAAE;aACR,QAAQ,CAAC,4CAA4C,CAAC,CAAC;QAE1D,MAAM,CAAC,IAAI,CACT,uBAAuB,EACvB,2CAA2C,EAC3C;YACE,UAAU,EAAE,gBAAgB,CAAC,QAAQ,CACnC,4CAA4C,CAC7C;SACF,EACD,KAAK,EAAE,EAAE,UAAU,EAAE,EAAE,EAAE;YACvB,MAAM,QAAQ,GAAG,MAAM,IAAI,CAAC,MAAM,CAAC,kBAAkB,CAAC,UAAU,CAAC,CAAC;YAClE,OAAO,qBAAqB,CAAC,QAAQ,CAAC,CAAC;QACzC,CAAC,CACF,CAAC;IACJ,CAAC;CACF"}
@@ -0,0 +1,3 @@
1
+ export declare const LINE_BOT_MCP_SERVER_VERSION = "0.1.0-local";
2
+ export declare const USER_AGENT = "@line/line-bot-mcp-server/0.1.0-local";
3
+ //# sourceMappingURL=version.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"version.d.ts","sourceRoot":"","sources":["../src/version.ts"],"names":[],"mappings":"AAAA,eAAO,MAAM,2BAA2B,gBAAgB,CAAC;AACzD,eAAO,MAAM,UAAU,0CAA6D,CAAC"}
@@ -0,0 +1,3 @@
1
+ export const LINE_BOT_MCP_SERVER_VERSION = "0.1.0-local";
2
+ export const USER_AGENT = `@line/line-bot-mcp-server/${LINE_BOT_MCP_SERVER_VERSION}`;
3
+ //# sourceMappingURL=version.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"version.js","sourceRoot":"","sources":["../src/version.ts"],"names":[],"mappings":"AAAA,MAAM,CAAC,MAAM,2BAA2B,GAAG,aAAa,CAAC;AACzD,MAAM,CAAC,MAAM,UAAU,GAAG,6BAA6B,2BAA2B,EAAE,CAAC"}
package/package.json ADDED
@@ -0,0 +1,54 @@
1
+ {
2
+ "name": "agenza-line-bot-mcp",
3
+ "version": "0.0.1-local",
4
+ "description": "MCP server for interacting with LINE Official Account",
5
+ "type": "module",
6
+ "engines": {
7
+ "node": ">=20"
8
+ },
9
+ "module": "./dist/index.js",
10
+ "bin": {
11
+ "agenza-line-bot-mcp": "./dist/index.js"
12
+ },
13
+ "files": [
14
+ "dist",
15
+ "richmenu-template"
16
+ ],
17
+ "scripts": {
18
+ "build": "tsc && shx chmod +x dist/*.js",
19
+ "prettier": "prettier \"src/**/*.ts\"",
20
+ "format": "npm run prettier -- --write",
21
+ "format:check": "npm run prettier -- -l",
22
+ "clean": "rm -rf dist/*",
23
+ "prebuild": "npm run format:check && npm run clean",
24
+ "release": "npm run build && npm publish --provenance --access public"
25
+ },
26
+ "repository": {
27
+ "type": "git",
28
+ "url": "git@github.com:your-username/agenza-line-bot-mcp.git"
29
+ },
30
+ "keywords": [
31
+ "line",
32
+ "bot",
33
+ "mcp"
34
+ ],
35
+ "homepage": "https://github.com/your-username/agenza-line-bot-mcp",
36
+ "bugs": "https://github.com/your-username/agenza-line-bot-mcp/issues",
37
+ "dependencies": {
38
+ "@cfworker/json-schema": "^4.1.1",
39
+ "@line/bot-sdk": "^10.0.0",
40
+ "@marp-team/marp-cli": "^4.2.3",
41
+ "@marp-team/marp-core": "^4.1.0",
42
+ "@modelcontextprotocol/sdk": "^1.8.0",
43
+ "puppeteer": "^24.27.0",
44
+ "zod": "^3.25.76"
45
+ },
46
+ "devDependencies": {
47
+ "@types/node": "^24.9.2",
48
+ "prettier": "3.7.3",
49
+ "shx": "^0.4.0",
50
+ "tsx": "^4.19.3",
51
+ "typescript": "^5.6.2"
52
+ },
53
+ "license": "Apache-2.0"
54
+ }
@@ -0,0 +1,46 @@
1
+ ---
2
+ marp: true
3
+ size: 16:9
4
+ ---
5
+ <style>
6
+ section {
7
+ padding: 0 !important;
8
+ background-color: orange;
9
+ height: 100% !important;
10
+ margin-top: 0 !important;
11
+ margin-bottom: 0 !important;
12
+ }
13
+ .columns-container {
14
+ display: flex;
15
+ flex-wrap: wrap;
16
+ width: 100%;
17
+ height: 100%;
18
+ }
19
+ .column-item {
20
+ display: flex;
21
+ flex-direction: column;
22
+ justify-content: center;
23
+ align-items: center;
24
+ background-color: white;
25
+ box-sizing: border-box;
26
+ overflow: hidden;
27
+ }
28
+ .column-item h3 {
29
+ font-weight: bold;
30
+ width: 100%;
31
+ text-align: center;
32
+ font-size: 100px;
33
+ white-space: normal;
34
+ word-break: break-all;
35
+ }
36
+ .column-item-01 {
37
+ margin: 10px;
38
+ height: calc((100% - 20px));
39
+ width: calc((100% - 20px));
40
+ }
41
+ </style>
42
+ <div class="columns-container">
43
+ <div class="column-item column-item-01">
44
+ <h3>item01</h3>
45
+ </div>
46
+ </div>
@@ -0,0 +1,49 @@
1
+ ---
2
+ marp: true
3
+ size: 16:9
4
+ ---
5
+ <style>
6
+ section {
7
+ padding: 0 !important;
8
+ background-color: orange;
9
+ height: 100% !important;
10
+ margin-top: 0 !important;
11
+ margin-bottom: 0 !important;
12
+ }
13
+ .columns-container {
14
+ display: flex;
15
+ flex-wrap: wrap;
16
+ width: 100%;
17
+ height: 100%;
18
+ }
19
+ .column-item {
20
+ display: flex;
21
+ flex-direction: column;
22
+ justify-content: center;
23
+ align-items: center;
24
+ background-color: white;
25
+ box-sizing: border-box;
26
+ overflow: hidden;
27
+ }
28
+ .column-item h3 {
29
+ font-weight: bold;
30
+ width: 100%;
31
+ text-align: center;
32
+ font-size: 70px;
33
+ white-space: normal;
34
+ word-break: break-all;
35
+ }
36
+ .column-item-02 {
37
+ margin: 10px 0px 10px 10px;
38
+ height: calc((100% - 20px));
39
+ width: calc((100% - 30px) / 2);
40
+ }
41
+ </style>
42
+ <div class="columns-container">
43
+ <div class="column-item column-item-02">
44
+ <h3>item01</h3>
45
+ </div>
46
+ <div class="column-item column-item-02">
47
+ <h3>item02</h3>
48
+ </div>
49
+ </div>
@@ -0,0 +1,74 @@
1
+ ---
2
+ marp: true
3
+ size: 16:9
4
+ ---
5
+ <style>
6
+ section {
7
+ padding: 0 !important;
8
+ background-color: orange;
9
+ height: 100% !important;
10
+ margin-top: 0 !important;
11
+ margin-bottom: 0 !important;
12
+ }
13
+ .columns-container {
14
+ display: flex;
15
+ flex-wrap: wrap;
16
+ width: 100%;
17
+ height: 100%;
18
+ }
19
+ .column-item {
20
+ display: flex;
21
+ flex-direction: column;
22
+ justify-content: center;
23
+ align-items: center;
24
+ background-color: white;
25
+ box-sizing: border-box;
26
+ overflow: hidden;
27
+ }
28
+ .column-item h3 {
29
+ font-weight: bold;
30
+ width: 100%;
31
+ text-align: center;
32
+ white-space: normal;
33
+ word-break: break-all;
34
+ }
35
+ .column-item-left {
36
+ display: flex;
37
+ flex: 2;
38
+ font-size: 70px;
39
+ }
40
+ .column-item-right {
41
+ display: flex;
42
+ flex: 1;
43
+ flex-direction: column;
44
+ height: 100%;
45
+ font-size: 50px;
46
+ }
47
+ .column-item-03-right {
48
+ flex: 1;
49
+ margin: 10px 0px 10px 10px;
50
+ }
51
+ .column-item-03-left-top {
52
+ flex: 1;
53
+ margin: 10px 10px 10px 10px;
54
+ }
55
+ .column-item-03-left-bottom {
56
+ flex: 1;
57
+ margin: 0px 10px 10px 10px;
58
+ }
59
+ </style>
60
+ <div class="columns-container">
61
+ <div class="column-item-left">
62
+ <div class="column-item column-item-03-right">
63
+ <h3>item01</h3>
64
+ </div>
65
+ </div>
66
+ <div class="column-item-right">
67
+ <div class="column-item column-item-03-left-top">
68
+ <h3>item02</h3>
69
+ </div>
70
+ <div class="column-item column-item-03-left-bottom">
71
+ <h3>item03</h3>
72
+ </div>
73
+ </div>
74
+ </div>
@@ -0,0 +1,60 @@
1
+ ---
2
+ marp: true
3
+ size: 16:9
4
+ ---
5
+ <style>
6
+ section {
7
+ padding: 0 !important;
8
+ background-color: orange;
9
+ height: 100% !important;
10
+ margin-top: 0 !important;
11
+ margin-bottom: 0 !important;
12
+ }
13
+ .columns-container {
14
+ display: flex;
15
+ flex-wrap: wrap;
16
+ width: 100%;
17
+ height: 100%;
18
+ }
19
+ .column-item {
20
+ display: flex;
21
+ flex-direction: column;
22
+ justify-content: center;
23
+ align-items: center;
24
+ background-color: white;
25
+ box-sizing: border-box;
26
+ overflow: hidden;
27
+ }
28
+ .column-item h3 {
29
+ font-weight: bold;
30
+ width: 100%;
31
+ text-align: center;
32
+ font-size: 50px;
33
+ white-space: normal;
34
+ word-break: break-all;
35
+ }
36
+ .column-item-04 {
37
+ height: calc((100% - 30px) / 2);
38
+ width: calc((100% - 30px) / 2);
39
+ }
40
+ .column-item-04-top {
41
+ margin: 10px 0px 0px 10px;
42
+ }
43
+ .column-item-04-bottom {
44
+ margin: 0px 0px 0px 10px;
45
+ }
46
+ </style>
47
+ <div class="columns-container">
48
+ <div class="column-item column-item-04 column-item-04-top">
49
+ <h3>item01</h3>
50
+ </div>
51
+ <div class="column-item column-item-04 column-item-04-top">
52
+ <h3>item02</h3>
53
+ </div>
54
+ <div class="column-item column-item-04 column-item-04-bottom">
55
+ <h3>item03</h3>
56
+ </div>
57
+ <div class="column-item column-item-04 column-item-04-bottom">
58
+ <h3>item04</h3>
59
+ </div>
60
+ </div>
@@ -0,0 +1,67 @@
1
+ ---
2
+ marp: true
3
+ size: 16:9
4
+ ---
5
+ <style>
6
+ section {
7
+ padding: 0 !important;
8
+ background-color: orange;
9
+ height: 100% !important;
10
+ margin-top: 0 !important;
11
+ margin-bottom: 0 !important;
12
+ }
13
+ .columns-container {
14
+ display: flex;
15
+ flex-wrap: wrap;
16
+ width: 100%;
17
+ height: 100%;
18
+ }
19
+ .column-item {
20
+ display: flex;
21
+ flex-direction: column;
22
+ justify-content: center;
23
+ align-items: center;
24
+ background-color: white;
25
+ box-sizing: border-box;
26
+ overflow: hidden;
27
+ }
28
+ .column-item h3 {
29
+ font-weight: bold;
30
+ width: 100%;
31
+ text-align: center;
32
+ font-size: 50px;
33
+ white-space: normal;
34
+ word-break: break-all;
35
+ }
36
+ .column-item-05 {
37
+ height: calc((100% - 30px) / 2);
38
+ width: calc((100% - 40px) / 3);
39
+ }
40
+ .column-item-05-top-wide {
41
+ width: calc((100% - 40px) / 3 * 2 + 10px);
42
+ margin: 10px 0px 0px 10px;
43
+ }
44
+ .column-item-05-top-small {
45
+ margin: 10px 0px 0px 10px;
46
+ }
47
+ .column-item-05-bottom {
48
+ margin: 0px 0px 0px 10px;
49
+ }
50
+ </style>
51
+ <div class="columns-container">
52
+ <div class="column-item column-item-05 column-item column-item-05-top-wide">
53
+ <h3>item01</h3>
54
+ </div>
55
+ <div class="column-item column-item-05 column-item column-item-05-top-small">
56
+ <h3>item02</h3>
57
+ </div>
58
+ <div class="column-item column-item-05 column-item column-item-05-bottom">
59
+ <h3>item03</h3>
60
+ </div>
61
+ <div class="column-item column-item-05 column-item column-item-05-bottom">
62
+ <h3>item04</h3>
63
+ </div>
64
+ <div class="column-item column-item-05 column-item column-item-05-bottom">
65
+ <h3>item05</h3>
66
+ </div>
67
+ </div>
@@ -0,0 +1,66 @@
1
+ ---
2
+ marp: true
3
+ size: 16:9
4
+ ---
5
+ <style>
6
+ section {
7
+ padding: 0 !important;
8
+ background-color: orange;
9
+ height: 100% !important;
10
+ margin-top: 0 !important;
11
+ margin-bottom: 0 !important;
12
+ }
13
+ .columns-container {
14
+ display: flex;
15
+ flex-wrap: wrap;
16
+ width: 100%;
17
+ height: 100%;
18
+ }
19
+ .column-item {
20
+ display: flex;
21
+ flex-direction: column;
22
+ justify-content: center;
23
+ align-items: center;
24
+ background-color: white;
25
+ box-sizing: border-box;
26
+ overflow: hidden;
27
+ }
28
+ .column-item h3 {
29
+ font-weight: bold;
30
+ width: 100%;
31
+ text-align: center;
32
+ font-size: 50px;
33
+ white-space: normal;
34
+ word-break: break-all;
35
+ }
36
+ .column-item-06 {
37
+ height: calc((100% - 30px) / 2);
38
+ width: calc((100% - 40px) / 3);
39
+ }
40
+ .column-item-06-top {
41
+ margin: 10px 0px 0px 10px;
42
+ }
43
+ .column-item-06-bottom {
44
+ margin: 0px 0px 0px 10px;
45
+ }
46
+ </style>
47
+ <div class="columns-container">
48
+ <div class="column-item column-item-06 column-item column-item-06-top">
49
+ <h3>item01</h3>
50
+ </div>
51
+ <div class="column-item column-item-06 column-item column-item-06-top">
52
+ <h3>item02</h3>
53
+ </div>
54
+ <div class="column-item column-item-06 column-item column-item-06-top">
55
+ <h3>item03</h3>
56
+ </div>
57
+ <div class="column-item column-item-06 column-item column-item-06-bottom">
58
+ <h3>item04</h3>
59
+ </div>
60
+ <div class="column-item column-item-06 column-item column-item-06-bottom">
61
+ <h3>item05</h3>
62
+ </div>
63
+ <div class="column-item column-item-06 column-item column-item-06-bottom">
64
+ <h3>item06</h3>
65
+ </div>
66
+ </div>