List¶
GET /api/v1/outer_function/list
Overview¶
List the functions and parameter metadata that the central Func service allows to be executed through OpenAPI.
Before Calling and Usage Steps¶
Use the target workspace API Key; either the routine.defaultAccess or anonymous.snapshotShared entry permission is required. This entry only lists functions with category=openapi in the central Func service, and local Func functions are excluded by default; you cannot switch this with undeclared isLocalFunction/funcSourceType/funcCategory/targetWorkspaceUUID parameters. The list is the currently allowed candidate catalog; it does not mean the function has already been called, nor is it a code upload or function creation interface.
First filter by function title/script/tag, then read content[].id as the funcId for Execute External Function; it is not name, scriptId, or url. kwargsJSON/argsJSON/definition are used to understand parameter definitions and default values; do not use the definition object in kwargsJSON directly as the actual parameter value; fill in real business values according to description/function documentation. The list is not paginated and returns a native array; raw fields depend on the Func version, and titles and descriptions can be localized according to the request language.
The historical SDK adaptation of the central Func list/pre-execution whitelist does not determine failure solely by the upstream HTTP status: for a JSON dictionary, only ok=false or a numeric 0 triggers a business error; if the status is non-200 but ok is absent/true, it may still continue to fetch data; only a non-dictionary with a non-200 HTTP status always reports an external function error. An empty catalog does not by itself prove that the upstream service is properly connected; in case of an exception, ask the administrator to check with the service logs.
For more information about functions, see Func documentation.
Request Headers¶
| Parameter Name | Type | Required | Description |
|---|---|---|---|
| DF-API-KEY | string | Y | OpenAPI authentication credential for the workspace. Example: <DF-API-KEY>How to obtain or fill in: Obtain an OpenAPI Key with this operation permission from the API Key management of the target workspace. |
Query Request Parameters¶
| Parameter Name | Type | Required | Description |
|---|---|---|---|
| _fuzzySearch | string | Optional string; discarded during the current controller mapping and has no actual filtering effect for this entry. Allow null: False Example: exampleHow to obtain or fill in: This legacy field does not currently participate in actual central function filtering; use funcTitle instead. |
|
| funcId | string | Optional; used as the central Func id query condition, not the script ID; examples are subject to actual deployment existence. Allow null: False Example: example__openapi.testHow to obtain or fill in: Obtain the actual function ID from content[].id of this API. |
|
| funcTitle | string | Optional; passed to the central Func as the title condition; the matching rule is determined by the Func service and is not guaranteed to be exactly the same as the local database LIKE. Allow null: False Example: exampleHow to obtain or fill in: Choose keywords based on the list title or function purpose. |
|
| funcTags | commaarray | Optional comma-separated list format string; the public type name has the historical spelling commaarray; passed as a string to the central Func, and the tag combination semantics are determined by that service. Allow null: False Example: tag-a,tag-bHow to obtain or fill in: Select names according to the tags in the function metadata, not global tag UUIDs. |
|
| funcScriptId | string | Optional string, mapped to the scriptId of the central Func; not the complete funcId. Example: example__openapiHow to obtain or fill in: Obtain the function script collection identifier from the list scriptId. |
Request Example¶
curl --get 'https://openapi.guance.com/api/v1/outer_function/list' \
-H 'DF-API-KEY: <DF-API-KEY>' \
--data-urlencode funcId=example__openapi.test
Response¶
HTTP 200, application/json. The example below shows the main fields that can be read directly.
| Field | Type | Description |
|---|---|---|
| content | array | Native function metadata array, with no pageInfo; may be empty. |
| content[].id | string | Complete function identifier; use this value as the funcId for execution. |
| content[].name | string | Short function name; does not replace the complete id. |
| content[].title | string | Display title, which may vary by language. |
| content[].description | string | Function and parameter description, which may vary by language. |
| content[].category | string | This entry always filters the openapi category; the actual value comes from the central Func. |
| content[].definition | string | Illustration of the function signature and parameter default values. |
| content[].argsJSON | JSON | Positional parameter definition, usually a string array; the actual metadata form is subject to what Func returns. |
| content[].kwargsJSON | JSON | Dictionary parameter metadata/default value definition; not a directly executable parameter instance. |
| content[].scriptId | string | Script identifier, used for funcScriptId filtering. |
| content[].url | string | Internal execution path of the Func service; not a Studio OpenAPI Endpoint and should not be concatenated directly for calling. |
| content[].isLocalFunction | boolean | For central functions via this entry, this is false. |
| content[].funcSourceType | string | For central functions, this is centre. |
| content[].declaration | object or null | Workspace public declaration for non-empty business objects; may be null or an empty object when not configured; empty business objects are not appended. |
| content[].other Func metadata fields | JSON | Script/integration/tag/extension information is returned as actually provided by upstream; undeclared parts cannot be treated as Studio writable fields. |
{
"code": 200,
"content": [
{
"id": "example__openapi.test",
"name": "test",
"title": "示例问候",
"description": "用于验证Func调用链的示例函数。",
"category": "openapi",
"definition": "test(workspace_uuid, workspace_token, your_name=\"OpenAPI User\")",
"argsJSON": [
"workspace_uuid",
"workspace_token",
"your_name"
],
"kwargsJSON": {
"workspace_uuid": {},
"workspace_token": {},
"your_name": {
"default": "OpenAPI User"
}
},
"scriptId": "example__openapi",
"url": "/api/v1/func/example__openapi.test",
"isLocalFunction": false,
"funcSourceType": "centre",
"declaration": {}
}
],
"errorCode": "",
"message": "",
"success": true,
"traceId": "TRACE-EXAMPLE"
}
Error Responses¶
For authentication, rate limiting, and common request errors, see Common Error Definitions.
This depends on the central Func service; do not treat fields specific to local Func/frontend calls as the contract of this entry. Service errors and metadata additional keys are subject to the actual version.
| HTTP Status | errorCode | Trigger Condition | Message or Response Description | Handling |
|---|---|---|---|---|
| 406 | ft.ParameterValidationFailed | Using an undeclared Query parameter or a parameter violating the rules | Parameter parsing failed | Check the Query parameter table and examples. |
| 400 | ft.OuterFuncFailed | The central Func returns a JSON dictionary with ok=false or a numeric 0 (special reasons are mapped separately), or a non-dictionary with a non-200 HTTP status | External function call failed | Check the Func service connection and the returned message, and retain the traceId; do not confuse an empty list with a request failure. |
| 500 | ft.InternalServerError | Connection timeout/other network exceptions, invalid JSON, or abnormal metadata structure | Internal error | Check the Func service address/availability and retain the traceId; timeout errors are ultimately unified as 500 in this entry. |
| 400 | ft.SameSetTraggerExists | The central Func list/whitelist returns ok=false with reason being EBizCondition.DuplicatedCrontabConfig | A trigger with the same configuration already exists | This is a shared SDK-specific error mapping; check the actual upstream response and configuration, and do not judge that the function does not exist based solely on this page's request. |