Move resource in AWS API gateway

Question:

I would like to move a few resources one level above such as:

The documentation here say that it is possible. But when I run the following command:

I get the error that it is an invalid patch operation.

Answer:

You can “reparent” a resource by issuing a replace patch operation to the /parentId path with the resourceId of the new parent:

[edited to replace patchOperations with patch-operations – comment to meet 6 character minimum edit]

Leave a Reply