-
Notifications
You must be signed in to change notification settings - Fork 4.8k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[request] Add an api to expose the plugin schema #309
Comments
The tricky part with this will be custom validation functions that are used for some values. On a side note, it would be cool to also have an endpoint to explain what the plugin is doing, like a description string. |
Kind of like the package details, I like this idea. 👍 You could also have |
{
"name": "filelog",
"description": "Logs to file [...]",
"conf": {
"path": { "type": "string" [...], "default": "...", "description": "where the logs will be written" }
}
} It only needs work on the |
For custom functions, we can require a structured format that also includes a description, like: local custom_validations = {
validate_username = {
description = "Validates that the username is an alphanumeric string",
func = function(val)
-- Do something
end
},
validate_zipcode = {
description = "Something",
func = function(val)
-- Do something
end
}
} |
Implement a suggestion from #309 to expose a plugin's schema in the API. This allows UI builders to abstract a part of their code. This adds an endpoint: `/plugins` to retrieve the `enabled_plugins` of the node and `/plugins/:name/schema` to retrieve the schema. `/plugins` can be confounded with `/plugins_configurations` but I see no better name for it now. Fix #309.
Implement a suggestion from #309 to expose a plugin's schema in the API. This allows UI builders to abstract a part of their code. This adds an endpoint: `/plugins` to retrieve the `enabled_plugins` of the node and `/plugins/:name/schema` to retrieve the schema. `/plugins` can be confounded with `/plugins_configurations` but I see no better name for it now. Fix #309.
@thibaultcha 👍 Sorry for the delayed response , works like a charm ! |
Pleased to hear it'll be useful to you then |
Implement a suggestion from Kong#309 to expose a plugin's schema in the API. This allows UI builders to abstract a part of their code. This adds an endpoint: `/plugins` to retrieve the `enabled_plugins` of the node and `/plugins/:name/schema` to retrieve the schema. `/plugins` can be confounded with `/plugins_configurations` but I see no better name for it now. Fix Kong#309. Former-commit-id: 4f06a2f9a611945e2d88dfe1f392f89970908f68
feat(openresty-patches) add patches for OpenResty 1.17.8.1
For a plugin like filelog , an api like "/plugins/filelog/schema" which returns the plugin schema if exposed would help in creating an automated ui generation for the ever growing plugins
The text was updated successfully, but these errors were encountered: