我想用这个请求将我的 api 密钥头从 api-key 重命名为 apikey
curl -X POST http://localhost:8001/plugins \
--data "name=request-transformer" \
--data-urlencode "config.rename.headers=apikey:\$(headers['api-key'] or 'api-key')" \
--data "config.remove.headers=api-key"
但我收到错误
{"message":"schema violation (config.rename: {\n headers = {\n \"'$(headers['api-key'] or 'api-key')' is not a valid header\"\n }\n})","name":"schema violation","fields":{"config":{"rename":{"headers":["'$(headers['api-key'] or 'api-key')' is not a valid header"]}}},"code":2}
任何解决此问题的建议谢谢