๋ค์๊ณผ ๊ฐ์ด ์๋ต ํ
ํ๋ฆฟ์ null
๋ฅผ ์ง์ ํฉ๋๋ค.
aws apigateway put-integration-response \
--region "$region" \
--rest-api-id "$api_id" \
--resource-id "$resource_id" \
--http-method GET \
--status-code 200 \
--response-templates '{"application/json":null}'
์ค๋ฅ๊ฐ ๋ฐ์ํฉ๋๋ค.
Parameter validation failed:
Invalid type for parameter responseTemplates.application/json, value: None, type: <type 'NoneType'>, valid types: <type 'basestring'>
null
๋ฅผ "Empty"
๋ก ๋ฐ๊พธ๋ฉด cli๊ฐ ๋งค๊ฐ๋ณ์๋ฅผ ์๋ฝํฉ๋๋ค.
--response-templates '{"application/json":"Empty"}'
AWS ์ฝ์์์ ๋์ผํ ๋ฉ์๋๋ฅผ ์์ฑํ๊ณ ์ฟผ๋ฆฌํ๋ฉด ๊ฐ์ด null
๋ก ํ์๋ฉ๋๋ค. aws-cli๋ฅผ ํตํด์ ๊ฐ์ ๊ฐ์ผ๋ก ์ค์ ํ๋ฉด ๋ ๊ฒ ๊ฐ์ต๋๋ค.
aws-cli/v1.9.2
ํด๊ฒฐ ๋ฐฉ๋ฒ์ null
๋์ ๋น ๋ฌธ์์ด์ ์ ๋ฌํ๋ ๊ฒ์
๋๋ค(์: --response-templates '{"application/json":""}'
).
{
"statusCode": "200",
"responseTemplates": {
"application/json": null
}
}
๊ฐ์ฌ ํด์.
@quiver ์ @ehammond ์๊ฒ ๊ฐ์ฌ๋๋ฆฝ๋๋ค. "ํด๊ฒฐ ๋ฐฉ๋ฒ"์ด ์ค์ ๋ก ์ฌ๋ฐ๋ฅธ ๋ฐฉ๋ฒ์ธ์ง ๊ฑฑ์ ๋ฉ๋๋ค. ์ฌ์ค apigateway ์๋น์ค๋ ๋ฌธ์์ด์ ์ ๋ ฅ์ผ๋ก ์์ํ๋ ๊ฒ์ผ๋ก ๋ชจ๋ธ๋ง๋์์ผ๋ฏ๋ก ๋ชจ๋ AWS SDK๊ฐ ์ด๋ฌํ ๋ฐฉ์์ผ๋ก ์๋ํ๊ณ apigateway๋ ๊ฒ๋ณด๊ธฐ์ ๋น ๋ฌธ์์ด์ ๋ด๋ถ์ ์ผ๋ก null๋ก ๋ณํํฉ๋๋ค. ์๋ง๋ AWS ์ฝ์์์๋ ๊ฐ์ ์ด์ผ๊ธฐ๊ฐ ์ผ์ด๋ ๊ฒ์ ๋๋ค.
๊ฐ์ฅ ์ ์ฉํ ๋๊ธ
ํด๊ฒฐ ๋ฐฉ๋ฒ์
null
๋์ ๋น ๋ฌธ์์ด์ ์ ๋ฌํ๋ ๊ฒ์ ๋๋ค(์:--response-templates '{"application/json":""}'
).