How to list all apps to get appID on app engine in google cloud platform using python API

320 Views Asked by At

I'm trying to write a simple python code to list out the apps such that i will get all the appIDs in google-cloud-platform , In command prompt i'm able to list it by passing the below command

gcloud app instances list

When i searched in stack overflow and other websites i couldn't find any piece of code that can list me apps. Any information related this will be thankful. Thanks in advance

1

There are 1 best solutions below

1
On

If you can run it in cmd, you could simply run the command from within Python:

import os
os.system("gcloud app instances list")

There is also the official google cloud python package, but it might be overkill if all you want to do is to run that one command.