How to export / import API Gateway Mappings

0

We are working on a process to create a backup of all API Gateway Mappings in our environments to have on file, in case someone deletes the mappings. I see a way to export the current mappings, using the get-api-mappings, but how could I import the mappings back in case the mappings get deleted and need to be restored? Any assistance would be appreciated.

Thank you,

1 Antwort
3
Akzeptierte Antwort

Hello,

According to your question, you have a question to restore the exported API Gateway mappings.


Through the steps, you can restore the API Gateway mappings:

  1. Export the mappings and save as a JSON file
aws apigateway get-mappings --domain-name <Domain_Name>
  1. Create new mappings with the exported mapping file
aws apigateway create-mapping --domain-name <Domain_Name> --cli-input-json <Mapping_File>

[+] create-api-mapping (AWS CLI Command Reference)


If I have missed anything or answered wrong, please feel free to ask me again. Also you have any questions, comment please!

profile picture
beantwortet vor 6 Monaten
profile pictureAWS
EXPERTE
überprüft vor 6 Monaten

Du bist nicht angemeldet. Anmelden um eine Antwort zu veröffentlichen.

Eine gute Antwort beantwortet die Frage klar, gibt konstruktives Feedback und fördert die berufliche Weiterentwicklung des Fragenstellers.

Richtlinien für die Beantwortung von Fragen