Home > Blockchain >  AWS CLI Error - "Expected: '=', received: ''' for input:"
AWS CLI Error - "Expected: '=', received: ''' for input:"

Time:08-25

Trying to add mapping for an integration to pass the websocket connectionId to my http backend. Below command works fine in cloud shell but fails in AWS CLI on Windows.

aws apigatewayv2 update-integration --integration-id foobar --api-id fooapi --request-parameters 'integration.request.header.connectionId'='context.connectionId'

This is the error message

Error parsing parameter '--request-parameters': Expected: '=', received: ''' for input:
'integration.request.header.connectionId'='context.connectionId'

Does anyone know the right syntax to issue in CLI? I tried escaping and double escaping the single quotes. No luck. Making it double quotes will execute but the intended result (the mapping being created) does not happen

CodePudding user response:

Do not wrap the quotes around individual elements. Instead, try:

--request-parameters 'integration.request.header.connectionId=context.connectionId'

CodePudding user response:

Please Don't use ' in between of ' you used there four times ' you can write this command like this

--request-parameters 'integration.request.header.connectionId=context.connectionId'

because you are using here argument --request-parameters

  • Related