Image build failed - Connected Action Python Code

Hey,

I’m getting “Image build for im-0zKpXw2FIjLHXiupQtptOZ failed with the exception: task exited with failure, status = exit status: 1”

When try to run my API CODE for get API Google com search results from code:

import requests
url = "https://api.serphouse.com/serp/live"
payload = '{"data":{
			"q": "Hosting",
			"domain": "google.com",
			"loc": "Abernathy,Texas,United States",
			"lang": "en",
			"device": "desktop",
			"serp_type": "web",
			"page": "1",
			"verbatim": "0"
}}'
headers = {
    'accept': "application/json",
    'content-type': "application/json",
    'authorization': "Bearer MYAPIKEY"
}
response = requests.request("POST", url, data=payload, headers=headers)
print(response.text)

Image build failed is a sign that the instance that was gonna run the python code can’t build.

Usually, this is because one of the packages is not found. Did you add any packages to this action? Could you let me know what this action is called?

1 Like