openany-cli-dev 0.0.0-stage → 0.1.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.
- package/README.md +461 -2
- package/bin/openany.js +3 -0
- package/package.json +27 -4
- package/skills/openany/SKILL.md +347 -0
- package/skills/openany/SKILL.zh-CN.md +496 -0
- package/skills/openany-provider/SKILL.md +26 -0
- package/skills/openany-provider/SKILL.zh-CN.md +26 -0
- package/skills/openany-provider/references/apis.md +60 -0
- package/skills/openany-provider/references/application.md +49 -0
- package/skills/openany-provider/references/application.zh-CN.md +51 -0
- package/skills/openany-provider/references/auth.md +59 -0
- package/skills/openany-provider/references/connections.md +38 -0
- package/skills/openany-provider/references/connections.zh-CN.md +33 -0
- package/skills/openany-provider/references/imports.md +38 -0
- package/skills/openany-provider/references/imports.zh-CN.md +55 -0
- package/skills/openany-provider/references/listing.md +29 -0
- package/skills/openany-provider/references/login.md +58 -0
- package/skills/openany-provider/references/login.zh-CN.md +59 -0
- package/skills/openany-provider/references/model-import.zh-CN.md +12 -0
- package/skills/openany-provider/references/models.md +107 -0
- package/skills/openany-provider/references/publishing.md +83 -0
- package/skills/openany-provider/references/publishing.zh-CN.md +81 -0
- package/skills/openany-provider/references/reviews.md +22 -0
- package/skills/openany-provider/templates/api-metadata.json +27 -0
- package/skills/openany-provider/templates/bindings.json +1 -0
- package/skills/openany-provider/templates/models-v2.json +545 -0
- package/skills/openany-provider/templates/models.json +10 -0
- package/skills/openany-provider/templates/provider-agent-api-template.json +697 -0
- package/skills/openany-provider/templates/seller-agent-api-import-template.json +839 -0
- package/skills/openany-provider/templates/seller-registration.json +26 -0
- package/src/auth-recovery.js +179 -0
- package/src/auth.js +1001 -0
- package/src/catalog.js +306 -0
- package/src/cli.js +601 -0
- package/src/config.js +260 -0
- package/src/errors.js +53 -0
- package/src/http.js +237 -0
- package/src/model-curl.js +359 -0
- package/src/model-materials.js +58 -0
- package/src/model-request.js +402 -0
- package/src/model-validation.js +56 -0
- package/src/models.js +188 -0
- package/src/native/config-acl.ps1 +34 -0
- package/src/native/connection-macos.js +109 -0
- package/src/native/connection-windows.ps1 +98 -0
- package/src/native/setup-macos.js +72 -0
- package/src/native/setup-windows.ps1 +83 -0
- package/src/native-prompt.js +85 -0
- package/src/payment-signing.js +362 -0
- package/src/prompt.js +69 -0
- package/src/provider-api-import-v2.js +72 -0
- package/src/provider-apis.js +3 -0
- package/src/provider-client.js +153 -0
- package/src/provider-connections.js +152 -0
- package/src/provider-import-format.js +289 -0
- package/src/provider-imports.js +402 -0
- package/src/provider-json.js +49 -0
- package/src/provider-model-import-v2.js +61 -0
- package/src/provider-models.js +253 -0
- package/src/provider-profile.js +65 -0
- package/src/provider-reviews.js +61 -0
- package/src/provider-state.js +176 -0
- package/src/provider.js +75 -0
- package/src/setup.js +201 -0
- package/src/topups.js +845 -0
- package/src/vendor/provider-apply/market-taxonomy.mjs +22 -0
- package/src/vendor/provider-apply/provenance.json +8 -0
- package/src/vendor/provider-apply/registration.mjs +151 -0
- package/src/vendor/provider-import/api-categories.json +29 -0
- package/src/vendor/provider-import/api-fields.json +33 -0
- package/src/vendor/provider-import/model-fields.json +44 -0
- package/src/wallet.js +213 -0
- package/src/windows-permissions.js +22 -0
|
@@ -0,0 +1,839 @@
|
|
|
1
|
+
{
|
|
2
|
+
"schemaVersion": "provider-agent-api-v2",
|
|
3
|
+
"description": "Place Agent API configurations in apis. The templateGuide and fieldGuide sections explain how to fill in the file and are not imported.",
|
|
4
|
+
"templateGuide": {
|
|
5
|
+
"title": "Agent API Import Template",
|
|
6
|
+
"status": "Fill in the Agent API configurations under apis, then upload this file in Agent APIs.",
|
|
7
|
+
"howToFill": [
|
|
8
|
+
"Read fieldGuide first, then edit the example configuration under apis.",
|
|
9
|
+
"Choose one billing method according to templateGuide.billingInstructions. The two configurations in billingOptions are provided only as examples to copy.",
|
|
10
|
+
"templateGuide and fieldGuide are instructions and are not submitted as API configurations.",
|
|
11
|
+
"Keep field names unchanged and edit only field values. Put strings in double quotes; do not quote numbers or booleans.",
|
|
12
|
+
"Keep only the APIs you need to import. Replace example paths and prices with actual values.",
|
|
13
|
+
"Set the connection URL and authentication credentials in the connection configuration, not in this template.",
|
|
14
|
+
"apiDescription must contain at least 150 Unicode characters after trimming, covering core capabilities, how to call the API, and use cases. Incomplete drafts can be previewed and edited; this requirement must be met before importing and saving.",
|
|
15
|
+
"Select a catalogType: skill, bot, service, data, or digital. Fill in includedContentHtml, usageInstructionsHtml, and at least one complete effect example.",
|
|
16
|
+
"For synchronous delivery, keep executionMode set to sync and asyncConfig set to null. For asynchronous delivery, use POST and copy the callback or poll option below. Update the API description and request and response examples to match your service.",
|
|
17
|
+
"The asynchronous examples show fixed billing and an upstream acknowledgement. For polling, implement GET /v1/jobs/{task_id} and return the documented status and result fields. Keep credentials in the connection and webhook settings."
|
|
18
|
+
],
|
|
19
|
+
"pricingExample": "1,000 micro-USD per call, equivalent to USD 0.001.",
|
|
20
|
+
"billingInstructions": "Each API must use exactly one billing method: fixed (per call) or usage (based on consumption). The example under apis uses fixed by default. For usage billing, replace config.billing in its entirety with billingOptions.usage.billing, then update the usage field and response example to match the actual response. Do not mix fields from the two billing methods or add both options from the guide to apis.",
|
|
21
|
+
"billingOptions": {
|
|
22
|
+
"fixed": {
|
|
23
|
+
"description": "Fixed billing: 1,000 micro-USD per call, equivalent to USD 0.001. Fill in only the four fields in this configuration; do not add usage fields.",
|
|
24
|
+
"billing": {
|
|
25
|
+
"mode": "fixed",
|
|
26
|
+
"currency": "USD",
|
|
27
|
+
"unit": "call",
|
|
28
|
+
"pricePerBillingUnitMicroUsd": "1000"
|
|
29
|
+
},
|
|
30
|
+
"responseBodyExample": {
|
|
31
|
+
"result": "Hello"
|
|
32
|
+
}
|
|
33
|
+
},
|
|
34
|
+
"usage": {
|
|
35
|
+
"description": "Usage billing: 1,000 micro-USD per 1,000 tokens, equivalent to USD 0.001. All four usage-related fields are required. The response example shows a usage of 12 tokens.",
|
|
36
|
+
"billing": {
|
|
37
|
+
"mode": "usage",
|
|
38
|
+
"currency": "USD",
|
|
39
|
+
"unit": "token",
|
|
40
|
+
"pricePerBillingUnitMicroUsd": "1000",
|
|
41
|
+
"responseUsageJsonPointer": "/usage/total",
|
|
42
|
+
"usageDecimalPlaces": 0,
|
|
43
|
+
"usageQuantityPerBillingUnit": "1000",
|
|
44
|
+
"costRoundingMode": "ceil"
|
|
45
|
+
},
|
|
46
|
+
"responseBodyExample": {
|
|
47
|
+
"result": "Hello",
|
|
48
|
+
"usage": {
|
|
49
|
+
"total": 12
|
|
50
|
+
}
|
|
51
|
+
}
|
|
52
|
+
}
|
|
53
|
+
},
|
|
54
|
+
"deliveryOptions": {
|
|
55
|
+
"sync": {
|
|
56
|
+
"executionMode": "sync",
|
|
57
|
+
"asyncConfig": null
|
|
58
|
+
},
|
|
59
|
+
"callback": {
|
|
60
|
+
"executionMode": "async",
|
|
61
|
+
"asyncConfig": {
|
|
62
|
+
"adapter_type": "webhook",
|
|
63
|
+
"delivery_mode": "callback",
|
|
64
|
+
"timeout_secs": 300,
|
|
65
|
+
"output_contract": {
|
|
66
|
+
"format": "json"
|
|
67
|
+
},
|
|
68
|
+
"dispatch_path": "/v1/text/process",
|
|
69
|
+
"policy_version": "openany-bot-v1"
|
|
70
|
+
},
|
|
71
|
+
"responseExample": {
|
|
72
|
+
"httpStatus": 200,
|
|
73
|
+
"responseBody": {
|
|
74
|
+
"accepted": true
|
|
75
|
+
}
|
|
76
|
+
}
|
|
77
|
+
},
|
|
78
|
+
"poll": {
|
|
79
|
+
"executionMode": "async",
|
|
80
|
+
"asyncConfig": {
|
|
81
|
+
"adapter_type": "webhook",
|
|
82
|
+
"delivery_mode": "poll",
|
|
83
|
+
"timeout_secs": 300,
|
|
84
|
+
"output_contract": {
|
|
85
|
+
"format": "json"
|
|
86
|
+
},
|
|
87
|
+
"poll": {
|
|
88
|
+
"publication": {},
|
|
89
|
+
"path": "/v1/jobs/{task_id}",
|
|
90
|
+
"interval_secs": 5
|
|
91
|
+
},
|
|
92
|
+
"dispatch_path": "/v1/text/process",
|
|
93
|
+
"policy_version": "openany-bot-v1"
|
|
94
|
+
},
|
|
95
|
+
"responseExample": {
|
|
96
|
+
"httpStatus": 200,
|
|
97
|
+
"responseBody": {
|
|
98
|
+
"accepted": true
|
|
99
|
+
}
|
|
100
|
+
},
|
|
101
|
+
"pollResponseExample": {
|
|
102
|
+
"status": "succeeded",
|
|
103
|
+
"result": {
|
|
104
|
+
"result": "Hello"
|
|
105
|
+
}
|
|
106
|
+
}
|
|
107
|
+
}
|
|
108
|
+
}
|
|
109
|
+
},
|
|
110
|
+
"fieldGuide": {
|
|
111
|
+
"schemaVersion": {
|
|
112
|
+
"label": "Template version",
|
|
113
|
+
"type": "string",
|
|
114
|
+
"required": true,
|
|
115
|
+
"description": "Identifies the template format. Do not change it.",
|
|
116
|
+
"constraints": "Must be provider-agent-api-v2. Do not change it.",
|
|
117
|
+
"example": "provider-agent-api-v2"
|
|
118
|
+
},
|
|
119
|
+
"apis": {
|
|
120
|
+
"label": "List of APIs to import",
|
|
121
|
+
"type": "array",
|
|
122
|
+
"required": true,
|
|
123
|
+
"description": "Each object represents one API. Copy the object to configure multiple APIs.",
|
|
124
|
+
"constraints": "Each template includes one example. You may copy the API object; apis must contain 1 to 100 items. The file must not exceed 8 MiB.",
|
|
125
|
+
"example": []
|
|
126
|
+
},
|
|
127
|
+
"apis[].apiName": {
|
|
128
|
+
"label": "API name",
|
|
129
|
+
"type": "string",
|
|
130
|
+
"required": true,
|
|
131
|
+
"description": "Enter an API name that callers can understand.",
|
|
132
|
+
"constraints": "Must not be empty.",
|
|
133
|
+
"example": "Text Processing"
|
|
134
|
+
},
|
|
135
|
+
"apis[].apiDescription": {
|
|
136
|
+
"label": "API purpose and usage",
|
|
137
|
+
"type": "string",
|
|
138
|
+
"required": true,
|
|
139
|
+
"description": "Describe the core capability, how to call the API, and use cases. At least 150 characters are required after trimming leading and trailing whitespace.",
|
|
140
|
+
"constraints": "apiDescription must contain at least 150 Unicode characters after trimming, covering core capabilities, how to call the API, and use cases. Incomplete drafts can be previewed and edited; this requirement must be met before importing and saving.",
|
|
141
|
+
"example": "This API accepts text submitted by a caller, processes it, and returns structured results. It can be used to organize content, extract information, and automate business workflows. Send a POST request to the configured API path with a text field in the JSON request body, and authenticate with an API key. Handle success or failure according to the returned status code and result field. This API is suitable for customer support ticket classification, internal document organization, and batch text analysis."
|
|
142
|
+
},
|
|
143
|
+
"apis[].overviewHtml": {
|
|
144
|
+
"label": "Overview",
|
|
145
|
+
"type": "string",
|
|
146
|
+
"required": false,
|
|
147
|
+
"description": "Optional rich-text overview as an HTML string. Use the example as a starting point and replace its details with your own.",
|
|
148
|
+
"constraints": "At most 32 KiB. Use supported HTML tags and links. Omit the field or leave it empty for no overview.",
|
|
149
|
+
"example": "<p>Text Processing Agent accepts a text string and returns a structured JSON result.</p><h2>Typical use cases</h2><ul><li>Pass text from a support ticket or internal document into a workflow that reads JSON.</li></ul><h2>Quick start and example</h2><p>Send a POST request to the configured path with <code>{\"text\":\"Hello\"}</code>. A successful response is HTTP 200 with <code>{\"result\":\"Hello\"}</code>.</p><h2>Key parameters</h2><ul><li><code>text</code> is a required string in the JSON request body.</li></ul><h2>Version and route differences</h2><p>This example uses synchronous delivery. The result is returned in the same response.</p><h2>Billing and usage limits</h2><p>This example uses fixed billing at USD 0.001 per call and a request body limit of 4 KiB. Check the published configuration for actual pricing and limits.</p><h2>Common questions</h2><h3>Where is the processed text?</h3><p>Read the <code>result</code> field in the JSON response.</p>"
|
|
150
|
+
},
|
|
151
|
+
"apis[].httpMethod": {
|
|
152
|
+
"label": "HTTP method",
|
|
153
|
+
"type": "string",
|
|
154
|
+
"required": true,
|
|
155
|
+
"description": "Enter the HTTP method actually used by the API.",
|
|
156
|
+
"constraints": "Only GET / POST / PUT / PATCH / DELETE, in uppercase.",
|
|
157
|
+
"example": "POST"
|
|
158
|
+
},
|
|
159
|
+
"apis[].publicPath": {
|
|
160
|
+
"label": "Upstream API relative path",
|
|
161
|
+
"type": "string",
|
|
162
|
+
"required": true,
|
|
163
|
+
"description": "Enter the upstream API's relative path. The public path is the same as the upstream path; the selected connection supplies the domain.",
|
|
164
|
+
"constraints": "Required; must start with /; at most 2048 characters; use {parameterName} for path parameters.",
|
|
165
|
+
"example": "/v1/text/process"
|
|
166
|
+
},
|
|
167
|
+
"apis[].requestContentType": {
|
|
168
|
+
"label": "Request body format",
|
|
169
|
+
"type": "string",
|
|
170
|
+
"required": true,
|
|
171
|
+
"description": "Enter the request body encoding accepted by the upstream API.",
|
|
172
|
+
"constraints": "Only none / application/json / application/x-www-form-urlencoded.",
|
|
173
|
+
"example": "application/json"
|
|
174
|
+
},
|
|
175
|
+
"apis[].categories": {
|
|
176
|
+
"label": "API categories",
|
|
177
|
+
"type": "array<string>",
|
|
178
|
+
"required": false,
|
|
179
|
+
"description": "Choose applicable existing system categories and enter their IDs from allowedValues. options provides the corresponding names and groups.",
|
|
180
|
+
"constraints": "Only values from allowedValues are permitted. Use an array of strings, not localized names, display names, or custom categories. At most 16 distinct items.",
|
|
181
|
+
"example": [
|
|
182
|
+
"ai-generation"
|
|
183
|
+
],
|
|
184
|
+
"allowedValues": [
|
|
185
|
+
"social-media",
|
|
186
|
+
"lead-generation",
|
|
187
|
+
"search-research",
|
|
188
|
+
"news",
|
|
189
|
+
"e-commerce",
|
|
190
|
+
"travel",
|
|
191
|
+
"crypto-defi",
|
|
192
|
+
"finance",
|
|
193
|
+
"ai-generation",
|
|
194
|
+
"compute-storage",
|
|
195
|
+
"email-communication",
|
|
196
|
+
"phone-messaging",
|
|
197
|
+
"web-tools",
|
|
198
|
+
"data",
|
|
199
|
+
"scrapers",
|
|
200
|
+
"developer",
|
|
201
|
+
"other",
|
|
202
|
+
"enrichment",
|
|
203
|
+
"seo-aeo",
|
|
204
|
+
"advertising",
|
|
205
|
+
"reviews-apps",
|
|
206
|
+
"community",
|
|
207
|
+
"market-data",
|
|
208
|
+
"document",
|
|
209
|
+
"media",
|
|
210
|
+
"tools",
|
|
211
|
+
"web"
|
|
212
|
+
],
|
|
213
|
+
"options": [
|
|
214
|
+
{
|
|
215
|
+
"value": "social-media",
|
|
216
|
+
"label": "Social Media"
|
|
217
|
+
},
|
|
218
|
+
{
|
|
219
|
+
"value": "lead-generation",
|
|
220
|
+
"label": "Lead Generation"
|
|
221
|
+
},
|
|
222
|
+
{
|
|
223
|
+
"value": "search-research",
|
|
224
|
+
"label": "Search & Research"
|
|
225
|
+
},
|
|
226
|
+
{
|
|
227
|
+
"value": "news",
|
|
228
|
+
"label": "News"
|
|
229
|
+
},
|
|
230
|
+
{
|
|
231
|
+
"value": "e-commerce",
|
|
232
|
+
"label": "E-commerce"
|
|
233
|
+
},
|
|
234
|
+
{
|
|
235
|
+
"value": "travel",
|
|
236
|
+
"label": "Travel"
|
|
237
|
+
},
|
|
238
|
+
{
|
|
239
|
+
"value": "crypto-defi",
|
|
240
|
+
"label": "Crypto & DeFi"
|
|
241
|
+
},
|
|
242
|
+
{
|
|
243
|
+
"value": "finance",
|
|
244
|
+
"label": "Finance"
|
|
245
|
+
},
|
|
246
|
+
{
|
|
247
|
+
"value": "ai-generation",
|
|
248
|
+
"label": "AI Generation"
|
|
249
|
+
},
|
|
250
|
+
{
|
|
251
|
+
"value": "compute-storage",
|
|
252
|
+
"label": "Compute & Storage"
|
|
253
|
+
},
|
|
254
|
+
{
|
|
255
|
+
"value": "email-communication",
|
|
256
|
+
"label": "Email & Communication"
|
|
257
|
+
},
|
|
258
|
+
{
|
|
259
|
+
"value": "phone-messaging",
|
|
260
|
+
"label": "Phone & Messaging"
|
|
261
|
+
},
|
|
262
|
+
{
|
|
263
|
+
"value": "web-tools",
|
|
264
|
+
"label": "Web Tools"
|
|
265
|
+
},
|
|
266
|
+
{
|
|
267
|
+
"value": "data",
|
|
268
|
+
"label": "Data"
|
|
269
|
+
},
|
|
270
|
+
{
|
|
271
|
+
"value": "scrapers",
|
|
272
|
+
"label": "Scrapers"
|
|
273
|
+
},
|
|
274
|
+
{
|
|
275
|
+
"value": "developer",
|
|
276
|
+
"label": "Developer"
|
|
277
|
+
},
|
|
278
|
+
{
|
|
279
|
+
"value": "other",
|
|
280
|
+
"label": "Other"
|
|
281
|
+
},
|
|
282
|
+
{
|
|
283
|
+
"value": "enrichment",
|
|
284
|
+
"label": "Enrichment"
|
|
285
|
+
},
|
|
286
|
+
{
|
|
287
|
+
"value": "seo-aeo",
|
|
288
|
+
"label": "SEO/AEO"
|
|
289
|
+
},
|
|
290
|
+
{
|
|
291
|
+
"value": "advertising",
|
|
292
|
+
"label": "Advertising"
|
|
293
|
+
},
|
|
294
|
+
{
|
|
295
|
+
"value": "reviews-apps",
|
|
296
|
+
"label": "Reviews & Apps"
|
|
297
|
+
},
|
|
298
|
+
{
|
|
299
|
+
"value": "community",
|
|
300
|
+
"label": "Community"
|
|
301
|
+
},
|
|
302
|
+
{
|
|
303
|
+
"value": "market-data",
|
|
304
|
+
"label": "Market Data"
|
|
305
|
+
},
|
|
306
|
+
{
|
|
307
|
+
"value": "document",
|
|
308
|
+
"label": "Documents"
|
|
309
|
+
},
|
|
310
|
+
{
|
|
311
|
+
"value": "media",
|
|
312
|
+
"label": "Media"
|
|
313
|
+
},
|
|
314
|
+
{
|
|
315
|
+
"value": "tools",
|
|
316
|
+
"label": "Tools"
|
|
317
|
+
},
|
|
318
|
+
{
|
|
319
|
+
"value": "web",
|
|
320
|
+
"label": "Web"
|
|
321
|
+
}
|
|
322
|
+
]
|
|
323
|
+
},
|
|
324
|
+
"apis[].config": {
|
|
325
|
+
"label": "API invocation and billing configuration",
|
|
326
|
+
"type": "object",
|
|
327
|
+
"required": true,
|
|
328
|
+
"description": "Configure request parameters, forwarding rules, limits, billing, and invocation examples.",
|
|
329
|
+
"constraints": "Use the fields described below.",
|
|
330
|
+
"example": {}
|
|
331
|
+
},
|
|
332
|
+
"apis[].config.requestParameters": {
|
|
333
|
+
"label": "Caller request parameters",
|
|
334
|
+
"type": "array<object>",
|
|
335
|
+
"required": true,
|
|
336
|
+
"description": "Declare the parameters that callers are allowed to send when invoking the API.",
|
|
337
|
+
"constraints": "Use [] when there are no parameters. With reject enabled, undeclared query/body parameters are rejected.",
|
|
338
|
+
"example": []
|
|
339
|
+
},
|
|
340
|
+
"apis[].config.parameterMappings": {
|
|
341
|
+
"label": "Upstream parameter mappings",
|
|
342
|
+
"type": "array<object>",
|
|
343
|
+
"required": true,
|
|
344
|
+
"description": "Forward caller parameters to specified upstream locations.",
|
|
345
|
+
"constraints": "source references a declared parameter; target specifies an upstream location.",
|
|
346
|
+
"example": []
|
|
347
|
+
},
|
|
348
|
+
"apis[].config.fixedHeaders": {
|
|
349
|
+
"label": "Fixed upstream request headers",
|
|
350
|
+
"type": "object",
|
|
351
|
+
"required": false,
|
|
352
|
+
"description": "Enter non-sensitive headers added to every forwarded upstream request.",
|
|
353
|
+
"constraints": "Values must be strings. Do not include credentials such as Authorization or Cookie, or reserved headers. Use {} if none.",
|
|
354
|
+
"example": {}
|
|
355
|
+
},
|
|
356
|
+
"apis[].config.fixedBody": {
|
|
357
|
+
"label": "Fixed upstream request body fields",
|
|
358
|
+
"type": "object",
|
|
359
|
+
"required": false,
|
|
360
|
+
"description": "Enter JSON fields added to every forwarded upstream request.",
|
|
361
|
+
"constraints": "Enter a JSON object without secrets. Use {} if none.",
|
|
362
|
+
"example": {}
|
|
363
|
+
},
|
|
364
|
+
"apis[].config.crossFieldRules": {
|
|
365
|
+
"label": "Cross-field validation rules",
|
|
366
|
+
"type": "array<object>",
|
|
367
|
+
"required": false,
|
|
368
|
+
"description": "Advanced configuration for joint validation of multiple parameters.",
|
|
369
|
+
"constraints": "Use [] if there are no rules. Each rule contains op and fields. op can be one_of (exactly one), mutually_exclusive (at most one), or requires (when the first parameter is present, all remaining parameters must also be present). fields contains 2 to 16 references to declared parameters, such as body:/text.",
|
|
370
|
+
"example": []
|
|
371
|
+
},
|
|
372
|
+
"apis[].config.undeclaredParameterPolicy": {
|
|
373
|
+
"label": "Undeclared parameter policy",
|
|
374
|
+
"type": "string",
|
|
375
|
+
"required": false,
|
|
376
|
+
"description": "Controls how undeclared query/body parameters are handled.",
|
|
377
|
+
"constraints": "reject: reject the request; ignore: discard without forwarding. This example explicitly uses reject.",
|
|
378
|
+
"example": "reject"
|
|
379
|
+
},
|
|
380
|
+
"apis[].config.timeoutMs": {
|
|
381
|
+
"label": "Request timeout (milliseconds)",
|
|
382
|
+
"type": "integer",
|
|
383
|
+
"required": false,
|
|
384
|
+
"description": "Enter how long the request may wait.",
|
|
385
|
+
"constraints": "100 to 120000; 2000 milliseconds = 2 seconds.",
|
|
386
|
+
"example": 2000
|
|
387
|
+
},
|
|
388
|
+
"apis[].config.maxRequestBytes": {
|
|
389
|
+
"label": "Maximum request body size (bytes)",
|
|
390
|
+
"type": "integer",
|
|
391
|
+
"required": false,
|
|
392
|
+
"description": "Enter the maximum allowed request body size in bytes.",
|
|
393
|
+
"constraints": "1 to 1048576; 4096 bytes = 4 KiB.",
|
|
394
|
+
"example": 4096
|
|
395
|
+
},
|
|
396
|
+
"apis[].config.maxResponseBytes": {
|
|
397
|
+
"label": "Maximum response body size (bytes)",
|
|
398
|
+
"type": "integer",
|
|
399
|
+
"required": false,
|
|
400
|
+
"description": "Enter the maximum allowed response body size in bytes.",
|
|
401
|
+
"constraints": "1 to 8388608; 65536 bytes = 64 KiB.",
|
|
402
|
+
"example": 65536
|
|
403
|
+
},
|
|
404
|
+
"apis[].config.billingSuccessCondition": {
|
|
405
|
+
"label": "Billable success condition",
|
|
406
|
+
"type": "object|null",
|
|
407
|
+
"required": false,
|
|
408
|
+
"description": "Specify the condition under which the API response is successful and billable.",
|
|
409
|
+
"constraints": "null uses the default success condition of HTTP 200 to 299. You may also provide a single condition object, such as {\"source\":\"body\",\"pointer\":\"/success\",\"op\":\"eq\",\"value\":true}. Nested all/any conditions are not supported.",
|
|
410
|
+
"example": null
|
|
411
|
+
},
|
|
412
|
+
"apis[].config.billing": {
|
|
413
|
+
"label": "Billing configuration",
|
|
414
|
+
"type": "object",
|
|
415
|
+
"required": true,
|
|
416
|
+
"description": "Set fixed or usage billing rules.",
|
|
417
|
+
"constraints": "The two modes use different fields; do not mix them.",
|
|
418
|
+
"example": {}
|
|
419
|
+
},
|
|
420
|
+
"apis[].config.requestResponseExamples": {
|
|
421
|
+
"label": "Request and response examples",
|
|
422
|
+
"type": "array<object>",
|
|
423
|
+
"required": false,
|
|
424
|
+
"description": "Provide sample requests and responses for callers.",
|
|
425
|
+
"constraints": "Examples must match the declared parameters and contain no credentials or private data.",
|
|
426
|
+
"example": []
|
|
427
|
+
},
|
|
428
|
+
"apis[].config.requestParameters[].name": {
|
|
429
|
+
"label": "Parameter name",
|
|
430
|
+
"type": "string",
|
|
431
|
+
"required": true,
|
|
432
|
+
"description": "Enter the parameter's business name.",
|
|
433
|
+
"constraints": "Must not be empty. For path/query/header parameters, use the corresponding actual name.",
|
|
434
|
+
"example": "text"
|
|
435
|
+
},
|
|
436
|
+
"apis[].config.requestParameters[].location": {
|
|
437
|
+
"label": "Parameter location",
|
|
438
|
+
"type": "string",
|
|
439
|
+
"required": true,
|
|
440
|
+
"description": "Specify where the caller supplies the parameter.",
|
|
441
|
+
"constraints": "Only path / query / header / body.",
|
|
442
|
+
"example": "body"
|
|
443
|
+
},
|
|
444
|
+
"apis[].config.requestParameters[].pointer": {
|
|
445
|
+
"label": "Request body field location",
|
|
446
|
+
"type": "string",
|
|
447
|
+
"required": "Required when location is body",
|
|
448
|
+
"description": "Locate the field in the JSON request body.",
|
|
449
|
+
"constraints": "For body parameters, enter a JSON Pointer. /text corresponds to {\"text\":\"Hello\"}. Use /object/field for nested fields. Escape ~ and / in key names as ~0 and ~1, respectively.",
|
|
450
|
+
"example": "/text"
|
|
451
|
+
},
|
|
452
|
+
"apis[].config.requestParameters[].type": {
|
|
453
|
+
"label": "Parameter data type",
|
|
454
|
+
"type": "string",
|
|
455
|
+
"required": true,
|
|
456
|
+
"description": "Specify the allowed data type.",
|
|
457
|
+
"constraints": "Only string / integer / number / boolean / object / array. Advanced types such as arrays also require their respective detailed constraints.",
|
|
458
|
+
"example": "string"
|
|
459
|
+
},
|
|
460
|
+
"apis[].config.requestParameters[].required": {
|
|
461
|
+
"label": "Whether the parameter is required",
|
|
462
|
+
"type": "boolean",
|
|
463
|
+
"required": true,
|
|
464
|
+
"description": "true means the parameter must be provided when calling the API.",
|
|
465
|
+
"constraints": "Only true / false, without quotes; independent of nullable.",
|
|
466
|
+
"example": true
|
|
467
|
+
},
|
|
468
|
+
"apis[].config.requestParameters[].nullable": {
|
|
469
|
+
"label": "Whether the parameter may be null",
|
|
470
|
+
"type": "boolean",
|
|
471
|
+
"required": true,
|
|
472
|
+
"description": "true means the parameter value may be JSON null.",
|
|
473
|
+
"constraints": "Only true / false; an empty string is not null.",
|
|
474
|
+
"example": false
|
|
475
|
+
},
|
|
476
|
+
"apis[].config.requestParameters[].description": {
|
|
477
|
+
"label": "Parameter instructions",
|
|
478
|
+
"type": "string",
|
|
479
|
+
"required": true,
|
|
480
|
+
"description": "Explain what the parameter means and what to enter.",
|
|
481
|
+
"constraints": "Describe its purpose clearly rather than just repeating its name.",
|
|
482
|
+
"example": "Enter the text to process, for example: Hello."
|
|
483
|
+
},
|
|
484
|
+
"apis[].config.parameterMappings[].source": {
|
|
485
|
+
"label": "Caller parameter source",
|
|
486
|
+
"type": "string",
|
|
487
|
+
"required": true,
|
|
488
|
+
"description": "Enter a reference to a declared caller parameter.",
|
|
489
|
+
"constraints": "For example, body:/text refers to the /text field in the JSON request body. An identical source and target forwards it without changing its location.",
|
|
490
|
+
"example": "body:/text"
|
|
491
|
+
},
|
|
492
|
+
"apis[].config.parameterMappings[].target": {
|
|
493
|
+
"label": "Upstream parameter target",
|
|
494
|
+
"type": "string",
|
|
495
|
+
"required": true,
|
|
496
|
+
"description": "Enter where the upstream API receives the parameter.",
|
|
497
|
+
"constraints": "For example, body:/text refers to the /text field in the JSON request body. An identical source and target forwards it without changing its location.",
|
|
498
|
+
"example": "body:/text"
|
|
499
|
+
},
|
|
500
|
+
"apis[].config.billing.mode": {
|
|
501
|
+
"label": "Billing mode",
|
|
502
|
+
"type": "string",
|
|
503
|
+
"required": true,
|
|
504
|
+
"description": "Choose fixed or usage billing.",
|
|
505
|
+
"constraints": "fixed: per call; usage: based on actual usage in the response.",
|
|
506
|
+
"example": "usage"
|
|
507
|
+
},
|
|
508
|
+
"apis[].config.billing.currency": {
|
|
509
|
+
"label": "Billing currency",
|
|
510
|
+
"type": "string",
|
|
511
|
+
"required": true,
|
|
512
|
+
"description": "Enter the currency used for the price.",
|
|
513
|
+
"constraints": "Currently only USD.",
|
|
514
|
+
"example": "USD"
|
|
515
|
+
},
|
|
516
|
+
"apis[].config.billing.unit": {
|
|
517
|
+
"label": "Usage unit name",
|
|
518
|
+
"type": "string",
|
|
519
|
+
"required": true,
|
|
520
|
+
"description": "Describe the business unit being measured.",
|
|
521
|
+
"constraints": "fixed must use call; usage requires a nonempty unit such as token, at most 64 characters.",
|
|
522
|
+
"example": "token"
|
|
523
|
+
},
|
|
524
|
+
"apis[].config.billing.pricePerBillingUnitMicroUsd": {
|
|
525
|
+
"label": "Price per billing unit (micro-USD)",
|
|
526
|
+
"type": "string",
|
|
527
|
+
"required": true,
|
|
528
|
+
"description": "For fixed, the price per call; for usage, the price per usageQuantityPerBillingUnit usage units.",
|
|
529
|
+
"constraints": "An integer string from 0 to 9007199254740991. No decimals, minus sign, leading zeros, or scientific notation. USD 1 = 1000000 micro-USD.",
|
|
530
|
+
"example": "1000"
|
|
531
|
+
},
|
|
532
|
+
"apis[].config.billing.responseUsageJsonPointer": {
|
|
533
|
+
"label": "Response usage field location",
|
|
534
|
+
"type": "string",
|
|
535
|
+
"required": "Required for usage; prohibited for fixed",
|
|
536
|
+
"description": "Specify which field in the JSON response contains the actual usage.",
|
|
537
|
+
"constraints": "Use a JSON Pointer starting with /, at most 512 characters. For example, /usage/total reads 12 from {\"usage\":{\"total\":12}}.",
|
|
538
|
+
"example": "/usage/total"
|
|
539
|
+
},
|
|
540
|
+
"apis[].config.billing.usageDecimalPlaces": {
|
|
541
|
+
"label": "Maximum usage decimal places",
|
|
542
|
+
"type": "integer",
|
|
543
|
+
"required": "Required for usage; prohibited for fixed",
|
|
544
|
+
"description": "Limit the decimal places in the response usage and usage quantity per billing unit.",
|
|
545
|
+
"constraints": "0 to 6; 0 means an integer. Excess precision is treated as invalid usage and is not truncated automatically.",
|
|
546
|
+
"example": 0
|
|
547
|
+
},
|
|
548
|
+
"apis[].config.billing.usageQuantityPerBillingUnit": {
|
|
549
|
+
"label": "Usage quantity per billing unit",
|
|
550
|
+
"type": "string",
|
|
551
|
+
"required": "Required for usage; prohibited for fixed",
|
|
552
|
+
"description": "Enter how many usage units the current price covers.",
|
|
553
|
+
"constraints": "Must be a positive decimal number string with no more decimal places than usageDecimalPlaces.",
|
|
554
|
+
"example": "1000"
|
|
555
|
+
},
|
|
556
|
+
"apis[].config.billing.costRoundingMode": {
|
|
557
|
+
"label": "Final cost rounding mode",
|
|
558
|
+
"type": "string",
|
|
559
|
+
"required": "Required for usage; prohibited for fixed",
|
|
560
|
+
"description": "Round the final calculated cost to micro-USD without rounding the usage itself.",
|
|
561
|
+
"constraints": "ceil: round up; floor: round down; half_up: round to nearest, with ties rounded up.",
|
|
562
|
+
"example": "ceil"
|
|
563
|
+
},
|
|
564
|
+
"apis[].config.requestResponseExamples[].name": {
|
|
565
|
+
"label": "Example name",
|
|
566
|
+
"type": "string",
|
|
567
|
+
"required": true,
|
|
568
|
+
"description": "Name this request and response example.",
|
|
569
|
+
"constraints": "Enter a string.",
|
|
570
|
+
"example": "Basic invocation example"
|
|
571
|
+
},
|
|
572
|
+
"apis[].config.requestResponseExamples[].request": {
|
|
573
|
+
"label": "Example request",
|
|
574
|
+
"type": "object",
|
|
575
|
+
"required": true,
|
|
576
|
+
"description": "Enter the parameters sent by the caller.",
|
|
577
|
+
"constraints": "Include path, query, headers, and body.",
|
|
578
|
+
"example": {
|
|
579
|
+
"path": {},
|
|
580
|
+
"query": {},
|
|
581
|
+
"headers": {},
|
|
582
|
+
"body": {
|
|
583
|
+
"text": "Hello"
|
|
584
|
+
}
|
|
585
|
+
}
|
|
586
|
+
},
|
|
587
|
+
"apis[].config.requestResponseExamples[].request.path": {
|
|
588
|
+
"label": "Example path parameters",
|
|
589
|
+
"type": "object",
|
|
590
|
+
"required": true,
|
|
591
|
+
"description": "Enter path placeholders and their corresponding values.",
|
|
592
|
+
"constraints": "Use {} when there are no path parameters.",
|
|
593
|
+
"example": {}
|
|
594
|
+
},
|
|
595
|
+
"apis[].config.requestResponseExamples[].request.query": {
|
|
596
|
+
"label": "Example query parameters",
|
|
597
|
+
"type": "object",
|
|
598
|
+
"required": true,
|
|
599
|
+
"description": "Enter URL query parameters.",
|
|
600
|
+
"constraints": "Use {} when there are no query parameters.",
|
|
601
|
+
"example": {}
|
|
602
|
+
},
|
|
603
|
+
"apis[].config.requestResponseExamples[].request.headers": {
|
|
604
|
+
"label": "Example request headers",
|
|
605
|
+
"type": "object",
|
|
606
|
+
"required": true,
|
|
607
|
+
"description": "Enter non-sensitive request headers.",
|
|
608
|
+
"constraints": "Do not include authentication credentials. Use {} if there are no extra headers.",
|
|
609
|
+
"example": {}
|
|
610
|
+
},
|
|
611
|
+
"apis[].config.requestResponseExamples[].request.body": {
|
|
612
|
+
"label": "Example request body",
|
|
613
|
+
"type": "JSON",
|
|
614
|
+
"required": true,
|
|
615
|
+
"description": "Enter a request body that matches requestParameters.",
|
|
616
|
+
"constraints": "This example is a JSON object; text is required and cannot be null.",
|
|
617
|
+
"example": {
|
|
618
|
+
"text": "Hello"
|
|
619
|
+
}
|
|
620
|
+
},
|
|
621
|
+
"apis[].config.requestResponseExamples[].httpStatus": {
|
|
622
|
+
"label": "Example response status code",
|
|
623
|
+
"type": "integer",
|
|
624
|
+
"required": true,
|
|
625
|
+
"description": "Enter the HTTP status code returned by this example.",
|
|
626
|
+
"constraints": "Enter a valid HTTP status code, such as 200.",
|
|
627
|
+
"example": 200
|
|
628
|
+
},
|
|
629
|
+
"apis[].config.requestResponseExamples[].responseBody": {
|
|
630
|
+
"label": "Example response body",
|
|
631
|
+
"type": "JSON",
|
|
632
|
+
"required": true,
|
|
633
|
+
"description": "Enter an example response from this API.",
|
|
634
|
+
"constraints": "In usage mode, the configured path must resolve to a valid usage value in the example.",
|
|
635
|
+
"example": {
|
|
636
|
+
"result": "Hello",
|
|
637
|
+
"usage": {
|
|
638
|
+
"total": 12
|
|
639
|
+
}
|
|
640
|
+
}
|
|
641
|
+
},
|
|
642
|
+
"apis[].config.billingSuccessCondition.source": {
|
|
643
|
+
"label": "Success condition data source",
|
|
644
|
+
"type": "string",
|
|
645
|
+
"required": true,
|
|
646
|
+
"description": "Choose the HTTP status code or a response body field.",
|
|
647
|
+
"constraints": "Only http_status / body.",
|
|
648
|
+
"example": "body"
|
|
649
|
+
},
|
|
650
|
+
"apis[].config.billingSuccessCondition.pointer": {
|
|
651
|
+
"label": "Success condition field location",
|
|
652
|
+
"type": "string",
|
|
653
|
+
"required": "Required when source=body; prohibited when source=http_status",
|
|
654
|
+
"description": "Locate the field in the JSON response used to determine success.",
|
|
655
|
+
"constraints": "A JSON Pointer starting with /, at most 512 characters.",
|
|
656
|
+
"example": "/success"
|
|
657
|
+
},
|
|
658
|
+
"apis[].config.billingSuccessCondition.op": {
|
|
659
|
+
"label": "Success condition operator",
|
|
660
|
+
"type": "string",
|
|
661
|
+
"required": true,
|
|
662
|
+
"description": "Specify how to determine whether the response is successful.",
|
|
663
|
+
"constraints": "eq: equals; in: belongs to a list; exists: field exists (body only); http_200_non_empty_string: HTTP 200 and the specified response body field is a nonempty string (body only).",
|
|
664
|
+
"example": "eq"
|
|
665
|
+
},
|
|
666
|
+
"apis[].config.billingSuccessCondition.value": {
|
|
667
|
+
"label": "Success condition comparison value",
|
|
668
|
+
"type": "JSON",
|
|
669
|
+
"required": "Required for eq/in; prohibited for exists/http_200_non_empty_string",
|
|
670
|
+
"description": "Enter a comparison value with the same type as the actual response value.",
|
|
671
|
+
"constraints": "eq accepts a string, number, boolean, or null; in accepts an array of 1 to 128 scalars of the same type; http_status values must be integers from 100 to 599.",
|
|
672
|
+
"example": true
|
|
673
|
+
},
|
|
674
|
+
"apis[].effectContentHtml": {
|
|
675
|
+
"type": "string (HTML)",
|
|
676
|
+
"required": true,
|
|
677
|
+
"description": "Public effect content in allowed HTML, up to 32 KiB. Include a title, an example input and an example result. API request and response samples are configured separately.",
|
|
678
|
+
"example": "<h2>Process a short text sample</h2><h3>Example input</h3><p>Process the text: Hello.</p><h3>Example result</h3><p>The agent returns the processed text in the result field.</p>"
|
|
679
|
+
},
|
|
680
|
+
"apis[].catalogType": {
|
|
681
|
+
"type": "string",
|
|
682
|
+
"required": true,
|
|
683
|
+
"description": "Choose the Agent API product type.",
|
|
684
|
+
"example": "service",
|
|
685
|
+
"allowedValues": [
|
|
686
|
+
"skill",
|
|
687
|
+
"bot",
|
|
688
|
+
"service",
|
|
689
|
+
"data",
|
|
690
|
+
"digital"
|
|
691
|
+
]
|
|
692
|
+
},
|
|
693
|
+
"apis[].executionMode": {
|
|
694
|
+
"type": "string",
|
|
695
|
+
"required": true,
|
|
696
|
+
"description": "Use sync for an immediate result or async for a background task. Async Agent APIs must use POST.",
|
|
697
|
+
"example": "sync",
|
|
698
|
+
"allowedValues": [
|
|
699
|
+
"sync",
|
|
700
|
+
"async"
|
|
701
|
+
]
|
|
702
|
+
},
|
|
703
|
+
"apis[].asyncConfig": {
|
|
704
|
+
"type": "object or null",
|
|
705
|
+
"required": "Required for async",
|
|
706
|
+
"description": "Use null for sync. For async, copy a delivery option and keep the nested field names unchanged.",
|
|
707
|
+
"example": null
|
|
708
|
+
},
|
|
709
|
+
"apis[].asyncConfig.adapter_type": {
|
|
710
|
+
"type": "string",
|
|
711
|
+
"required": "Required for async",
|
|
712
|
+
"description": "Choose webhook or grok_bot, according to the upstream adapter.",
|
|
713
|
+
"example": "webhook"
|
|
714
|
+
},
|
|
715
|
+
"apis[].asyncConfig.delivery_mode": {
|
|
716
|
+
"type": "string",
|
|
717
|
+
"required": "Required for async",
|
|
718
|
+
"description": "Use callback when the upstream sends the result, or poll when the gateway queries the upstream for the result.",
|
|
719
|
+
"example": "callback"
|
|
720
|
+
},
|
|
721
|
+
"apis[].asyncConfig.timeout_secs": {
|
|
722
|
+
"type": "integer",
|
|
723
|
+
"required": "Required for async",
|
|
724
|
+
"description": "Task timeout, from 1 to 604800 seconds.",
|
|
725
|
+
"example": 300
|
|
726
|
+
},
|
|
727
|
+
"apis[].asyncConfig.output_contract": {
|
|
728
|
+
"type": "object",
|
|
729
|
+
"required": "Required for async",
|
|
730
|
+
"description": "Describe the structure of the final result.",
|
|
731
|
+
"example": {
|
|
732
|
+
"format": "json"
|
|
733
|
+
}
|
|
734
|
+
},
|
|
735
|
+
"apis[].asyncConfig.poll": {
|
|
736
|
+
"type": "object",
|
|
737
|
+
"required": "Required for poll",
|
|
738
|
+
"description": "Copy the poll option and use the fixed upstream path GET /v1/jobs/{task_id}. Use the platform task ID from task_id in the submission body or from the Idempotency-Key header for native HTTP JSON. Return HTTP 200 with a top-level status of running, succeeded, or failed. Include a top-level result on success. The optional polling interval is 1 to 300 seconds.",
|
|
739
|
+
"example": {
|
|
740
|
+
"publication": {},
|
|
741
|
+
"path": "/v1/jobs/{task_id}",
|
|
742
|
+
"interval_secs": 5
|
|
743
|
+
}
|
|
744
|
+
},
|
|
745
|
+
"apis[].asyncConfig.dispatch_path": {
|
|
746
|
+
"type": "string",
|
|
747
|
+
"required": false,
|
|
748
|
+
"description": "The upstream relative POST path that receives the task. Update this when changing the example endpoint. If omitted, dispatch uses /.",
|
|
749
|
+
"example": "/v1/text/process"
|
|
750
|
+
},
|
|
751
|
+
"apis[].asyncConfig.policy_version": {
|
|
752
|
+
"type": "string",
|
|
753
|
+
"required": "Required for async bots or grok_bot",
|
|
754
|
+
"description": "Use openany-bot-v1 when catalogType is bot or adapter_type is grok_bot.",
|
|
755
|
+
"example": "openany-bot-v1"
|
|
756
|
+
},
|
|
757
|
+
"apis[].includedContentHtml": {
|
|
758
|
+
"type": "string (HTML)",
|
|
759
|
+
"required": true,
|
|
760
|
+
"description": "Required for skills, bots and services. Describe the deliverables, preparation, scope and limitations in non-empty allowed HTML, up to 32 KiB.",
|
|
761
|
+
"example": "<h2>Included</h2><ul><li>A structured result.</li></ul>"
|
|
762
|
+
},
|
|
763
|
+
"apis[].usageInstructionsHtml": {
|
|
764
|
+
"type": "string (HTML)",
|
|
765
|
+
"required": true,
|
|
766
|
+
"description": "Required for skills, bots and services. Provide non-empty usage instructions in allowed HTML, up to 32 KiB. Headings, paragraphs, lists, tables, links and code are supported.",
|
|
767
|
+
"example": "<h2>Quick start</h2><ol><li>Prepare the input.</li><li>Run the task and retrieve its result.</li></ol>"
|
|
768
|
+
}
|
|
769
|
+
},
|
|
770
|
+
"apis": [
|
|
771
|
+
{
|
|
772
|
+
"apiName": "Text Processing Agent",
|
|
773
|
+
"apiDescription": "This API accepts text submitted by a caller, processes it, and returns structured results. It can be used to organize content, extract information, and automate business workflows. Send a POST request to the configured API path with a text field in the JSON request body, and authenticate with an API key. Handle success or failure according to the returned status code and result field. This API is suitable for customer support ticket classification, internal document organization, and batch text analysis.",
|
|
774
|
+
"overviewHtml": "<p>Text Processing Agent accepts a text string and returns a structured JSON result.</p><h2>Typical use cases</h2><ul><li>Pass text from a support ticket or internal document into a workflow that reads JSON.</li></ul><h2>Quick start and example</h2><p>Send a POST request to the configured path with <code>{\"text\":\"Hello\"}</code>. A successful response is HTTP 200 with <code>{\"result\":\"Hello\"}</code>.</p><h2>Key parameters</h2><ul><li><code>text</code> is a required string in the JSON request body.</li></ul><h2>Version and route differences</h2><p>This example uses synchronous delivery. The result is returned in the same response.</p><h2>Billing and usage limits</h2><p>This example uses fixed billing at USD 0.001 per call and a request body limit of 4 KiB. Check the published configuration for actual pricing and limits.</p><h2>Common questions</h2><h3>Where is the processed text?</h3><p>Read the <code>result</code> field in the JSON response.</p>",
|
|
775
|
+
"catalogType": "service",
|
|
776
|
+
"executionMode": "sync",
|
|
777
|
+
"asyncConfig": null,
|
|
778
|
+
"httpMethod": "POST",
|
|
779
|
+
"publicPath": "/v1/text/process",
|
|
780
|
+
"requestContentType": "application/json",
|
|
781
|
+
"categories": [
|
|
782
|
+
"ai-generation"
|
|
783
|
+
],
|
|
784
|
+
"config": {
|
|
785
|
+
"requestParameters": [
|
|
786
|
+
{
|
|
787
|
+
"name": "text",
|
|
788
|
+
"location": "body",
|
|
789
|
+
"pointer": "/text",
|
|
790
|
+
"type": "string",
|
|
791
|
+
"required": true,
|
|
792
|
+
"nullable": false,
|
|
793
|
+
"description": "Enter the text to process, for example: Hello."
|
|
794
|
+
}
|
|
795
|
+
],
|
|
796
|
+
"parameterMappings": [
|
|
797
|
+
{
|
|
798
|
+
"source": "body:/text",
|
|
799
|
+
"target": "body:/text"
|
|
800
|
+
}
|
|
801
|
+
],
|
|
802
|
+
"fixedHeaders": {},
|
|
803
|
+
"fixedBody": {},
|
|
804
|
+
"crossFieldRules": [],
|
|
805
|
+
"undeclaredParameterPolicy": "reject",
|
|
806
|
+
"timeoutMs": 2000,
|
|
807
|
+
"maxRequestBytes": 4096,
|
|
808
|
+
"maxResponseBytes": 65536,
|
|
809
|
+
"billing": {
|
|
810
|
+
"mode": "fixed",
|
|
811
|
+
"currency": "USD",
|
|
812
|
+
"unit": "call",
|
|
813
|
+
"pricePerBillingUnitMicroUsd": "1000"
|
|
814
|
+
},
|
|
815
|
+
"billingSuccessCondition": null,
|
|
816
|
+
"requestResponseExamples": [
|
|
817
|
+
{
|
|
818
|
+
"name": "Basic invocation example",
|
|
819
|
+
"request": {
|
|
820
|
+
"path": {},
|
|
821
|
+
"query": {},
|
|
822
|
+
"headers": {},
|
|
823
|
+
"body": {
|
|
824
|
+
"text": "Hello"
|
|
825
|
+
}
|
|
826
|
+
},
|
|
827
|
+
"httpStatus": 200,
|
|
828
|
+
"responseBody": {
|
|
829
|
+
"result": "Hello"
|
|
830
|
+
}
|
|
831
|
+
}
|
|
832
|
+
]
|
|
833
|
+
},
|
|
834
|
+
"effectContentHtml": "<h2>Process a short text sample</h2><h3>Example input</h3><p>Process the text: Hello.</p><h3>Example result</h3><p>The agent returns the processed text in the result field.</p>",
|
|
835
|
+
"includedContentHtml": "<h2>Included</h2><ul><li>A structured JSON result containing the processed text.</li></ul><h3>Before you start</h3><ul><li>Provide the text to process as a non-empty string in the JSON request body.</li></ul>",
|
|
836
|
+
"usageInstructionsHtml": "<h2>Quick start</h2><ol><li>Enter the non-empty text to process.</li><li>Confirm the input and published price, then run the service.</li><li>Read the processed text in the result field.</li></ol>"
|
|
837
|
+
}
|
|
838
|
+
]
|
|
839
|
+
}
|