-
Notifications
You must be signed in to change notification settings - Fork 2
Expand file tree
/
Copy pathplugin.json
More file actions
256 lines (256 loc) · 15.1 KB
/
plugin.json
File metadata and controls
256 lines (256 loc) · 15.1 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
{
"id": "generate_excel_file",
"uuid": "6b522118-b0d1-4357-9b06-3c54a98e28d9",
"emoji": "🧩",
"title": "Excel Generator",
"system": false,
"iconURL": "https://custom.typingmind.com/assets/plugins/microsoft-excel.webp",
"disabled": false,
"syncedAt": null,
"httpAction": {
"id": "1958d5ef-feb1-458a-8bc2-8f77870de439",
"url": "{pluginServer}/excel-generator/generate",
"name": "",
"method": "POST",
"hasBody": true,
"hasHeaders": true,
"requestBody": "\n{\n \"sheetsData\": {sheetsData},\n \"excelConfigs\": {\n \"fontFamily\": \"{fontFamily}\",\n \"fontSize\": {fontSize},\n \"headerFontSize\": {headerFontSize},\n \"tableTitleFontSize\": {tableTitleFontSize},\n \"borderStyle\": \"{borderStyle}\",\n \"autoFitColumnWidth\": {autoFitColumnWidth},\n \"autoFilter\": {autoFilter},\n \"wrapText\": {wrapText} \n }\n}",
"requestHeaders": "{\n \"Content-Type\": \"application/json\"\n}"
},
"openaiSpec": {
"name": "generate_excel_file",
"parameters": {
"type": "object",
"required": [
"sheetsData"
],
"properties": {
"sheetsData": {
"type": "array",
"items": {
"type": "object",
"required": [
"sheetName",
"tables"
],
"properties": {
"tables": {
"type": "array",
"items": {
"type": "object",
"required": [
"startCell",
"columns",
"rows"
],
"properties": {
"rows": {
"type": "array",
"items": {
"type": "array",
"items": {
"type": "object",
"required": [
"type",
"value"
],
"properties": {
"type": {
"enum": [
"static_value",
"formula"
],
"type": "string",
"description": "Indicates whether the cell contains a static value or a formula."
},
"value": {
"type": "string",
"description": "The actual value or formula for the cell. If a formula, do not start with '='. Ensure that any cell ranges used in the formula must not include the header row and title row. For example, if the table starts at A1 with a title in row 1 and header in row 2, a valid formula would be 'SUM(A3:A10)'. When referencing another sheet, include the sheet name followed by an exclamation mark, and use single quotes around the sheet name if it contains spaces. For example, use 'Sheet 2'!A1:B2 to reference a range in a sheet with spaces in its name. If 'type' is 'static_value', do not include percent or currency signs as these are defined in the column format. Avoid creating circular references where a formula directly or indirectly references its own cell."
}
},
"description": "Each cell in a row contains a type ('static_value' or 'formula') and its corresponding value."
},
"description": "Each row is an array of cells. The number of cells in each row must equal the defined columns length, and all rows must have the same length."
},
"description": "Array of rows in the table, where each row is an array of cells."
},
"title": {
"type": "string",
"example": "Q1 Sales Data",
"description": "The title of the table, which will be displayed in the first row."
},
"columns": {
"type": "array",
"items": {
"type": "object",
"required": [
"name",
"type"
],
"properties": {
"name": {
"type": "string",
"example": "Product Name",
"description": "The name of the column."
},
"type": {
"enum": [
"string",
"number",
"boolean",
"percent",
"currency",
"date"
],
"type": "string",
"example": "string",
"description": "The data type of the column."
},
"format": {
"type": "string",
"example": "$#,##0",
"description": "The format of the column (e.g., '0.00%', '$#,##0', etc.)."
}
}
},
"description": "The list of columns in the table, each with a name, type, and optional format."
},
"startCell": {
"type": "string",
"example": "A1",
"description": "The starting cell (e.g., 'A1') where the table will begin."
},
"skipHeader": {
"type": "boolean",
"example": false,
"description": "Whether to skip the header row for this table."
}
}
},
"description": "The tables to include in the sheet."
},
"sheetName": {
"type": "string",
"example": "Sales Data",
"description": "The name of the sheet to be created in the Excel file."
}
}
},
"description": "An array of sheet data, where each sheet contains a name and an array of tables to generate."
}
}
},
"description": "Generate an Excel file (.xlsx) and return the URL for downloading it. If the download URL is not present in the response, inform the user that the Excel file could not be generated. Prompt the user to verify that the correct plugin server URL is being used."
},
"outputType": "respond_to_ai",
"oauthConfig": null,
"userSettings": [
{
"name": "pluginServer",
"label": "Plugin Server",
"required": true,
"description": "The URL of the plugin server. For more details, refer to the documentation: https://docs.typingmind.com/plugins/plugins-server",
"placeholder": "https://...."
},
{
"name": "fontFamily",
"type": "enum",
"label": "Font Family",
"values": [
"Calibri",
"Arial",
"Courier New",
"Georgia",
"Helvetica",
"Impact",
"Lucida Console",
"Tahoma",
"Times New Roman",
"Trebuchet MS",
"Verdana",
"Comic Sans MS",
"Franklin Gothic Medium",
"Century Gothic",
"Gill Sans",
"Garamond",
"Palatino Linotype",
"Segoe UI",
"Book Antiqua",
"Symbol",
"Monospace",
"Webdings",
"Wingdings"
],
"default": "Calibri",
"description": "Select the font family for the Excel file. The default is Calibri."
},
{
"name": "fontSize",
"type": "number",
"label": "Font Size",
"description": "Specify the font size for the Excel file. The default is 11 pt.",
"placeholder": "11"
},
{
"name": "headerFontSize",
"type": "number",
"label": "Header Font Size",
"description": "Set the font size for table headers in the Excel file. The default is 11 pt.",
"placeholder": "11"
},
{
"name": "tableTitleFontSize",
"type": "number",
"label": "Table Title Font Size",
"description": "Set the font size for the titles of each table in the Excel file. The default is 13 pt.",
"placeholder": "13"
},
{
"name": "borderStyle",
"type": "enum",
"label": "Border Style",
"values": [
"none",
"thin",
"double",
"dashed",
"thick"
],
"default": "none",
"description": "Choose the border style for tables in the Excel file. The default is 'none.'"
},
{
"name": "autoFitColumnWidth",
"type": "enum",
"label": "Enable Auto Fit Column Width",
"values": [
"true",
"false"
],
"description": "Enable or disable automatic adjustment of column widths to fit the content. The default is 'true.'"
},
{
"name": "autoFilter",
"type": "enum",
"label": "Enable Auto Filter",
"values": [
"false",
"true"
],
"description": "Enable or disable the auto filter option for table headers. The default is 'false.'"
},
{
"name": "wrapText",
"type": "enum",
"label": "Enable Wrap Text",
"values": [
"false",
"true"
],
"description": "Enable or disable text wrapping for the entire workbook. The default is 'false.'"
}
],
"overviewMarkdown": "# **Excel Generator**\n\nThis plugin enables users to generate Excel files (.xlsx) quickly and efficiently.\n\n### 🎯 **It Supports**\n- **Multiple Sheets:** Create and organize data across multiple sheets in a single workbook.\n- **Multiple Tables per Sheet:** Add multiple tables with independent configurations to each sheet.\n- **Formula Columns:** Define and apply formulas using Excel's syntax (e.g., `=SUM(A1:A10)`).\n- **Auto Filtering Mode**: Enable or disable automatic filtering on table columns.\n- **Customizable Headers:** Option to include or skip headers for tables, ensuring flexibility in design.\n- **Dynamic Cell Range:** Specify starting cells for tables to ensure accurate placement.\n- Ability to **customize basic excel attributes** \n - Choose font family.\n - Adjust font size for text, table titles, and headers.\n - Set border styles (thin, double, dashed, thick).\n - Enable options for column width fitting, auto filtering, and text wrapping.\n\n### 📝 **Note:** \n- A plugin server must be set up to use this feature. Follow the detailed guide to set up a plugin server on Render: [How to Deploy Plugins Server on Render](https://docs.typingmind.com/plugins/plugins-server/how-to-deploy-plugins-server-on-render)\n- The generated Excel files will be automatically removed after one hour.\n- The plugin currently does not support adding graphs or embedding images in Excel files.\n\n## **Example Usage** \n>Please generate an Excel file for a gradebook. The gradebook should include the following columns:\n> 1. Student Name\n> 2. Student ID\n> 3. Assignment 1 Score\n> 4. Assignment 2 Score\n> 5. Midterm Exam Score\n> 6. Final Exam Score\n> 7. Total Score (calculated as the weighted average of assignments, midterm, and final exam)\n> 8. Letter Grade (based on total score)\n>\n>The total score should be calculated with the following weights:\n> * Assignments: 40% (20% for Assignment 1 and 20% for Assignment 2)\n> * Midterm Exam: 30%\n> * Final Exam: 30%\n>\n>The letter grade should be assigned based on the total score:\n>* A: 90% or higher\n>* B: 80%–89%\n>* C: 70%–79%\n>* D: 60%–69%\n>* F: Below 60%",
"authenticationType": "AUTH_TYPE_NONE",
"implementationType": "http"
}