Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Update apigateway deployment with cli

How do I update a apigateway deployment using the cli? I can find the update-deployment command, but I do not know what to put in for the values it needs in this skeleton (taken from the documentation):

{
  "op": "add"|"remove"|"replace"|"move"|"copy"|"test",
  "path": "string",
  "value": "string",
  "from": "string"
}
like image 458
Nathan Avatar asked Nov 17 '25 12:11

Nathan


1 Answers

update-deployment is used to update the metadata of an existing deployment. For example, to update the description of a deployment:

aws apigateway update-deployment \
               --rest-api-id <value> \
               --deployment-id <value> \ 
               --patch-operations 'op=replace,path=/description,value=<value>'

If you wanted to re-deploy an API (this is what happens when you click on "Deploy API" in the web console), you'd use the create-deployment command:

aws apigateway create-deployment \
               --rest-api-id <value> \
               --stage-name <value>
like image 118
Lorenzo de Lara Avatar answered Nov 19 '25 06:11

Lorenzo de Lara