Can you delete your API keys already created via AWS Management Console's Amazon API Gateway page? Perhaps we can only turn on-off 'Enabled' checkbox?
With the official aws python client you can do
aws apigateway delete-api-key --api-key "MyLoOnGGaNDdObScuEddDKeYYy"
For the time being you have to use the Amazon API Gateway REST API to delete an API key.
Here is a way with Node.js:
Install aws4 package
npm install aws4
Use the apikey:delete link relation to delete the API key:
var https = require('https'),
aws4 = require('aws4');
https.request(aws4.sign({
host : 'apigateway.us-east-1.amazonaws.com',
method: 'DELETE',
path : '/apikeys/<BASE64-API-KEY-VALUE>'
}, {
accessKeyId : '<YOUR-ACCESS-KEY-ID>',
secretAccessKey: '<YOUR-SECRET-ACCESS-KEY>'
}), function(res) {
res.pipe(process.stdout);
}).end();
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With