save_ad_image_locally
Download and save a Meta ad image locally by specifying the ad ID and output directory. Retrieve the file path for easy access and storage of ad creatives.
Instructions
Get, download, and save a Meta ad image locally, returning the file path.
Args:
access_token: Meta API access token (optional - will use cached token if not provided)
ad_id: Meta Ads ad ID
output_dir: Directory to save the image file (default: 'ad_images')
Returns:
The file path to the saved image, or an error message string.
Input Schema
Name | Required | Description | Default |
---|---|---|---|
access_token | No | ||
ad_id | No | ||
output_dir | No | ad_images |
Input Schema (JSON Schema)
{
"properties": {
"access_token": {
"default": null,
"title": "Access Token",
"type": "string"
},
"ad_id": {
"default": null,
"title": "Ad Id",
"type": "string"
},
"output_dir": {
"default": "ad_images",
"title": "Output Dir",
"type": "string"
}
},
"title": "save_ad_image_locallyArguments",
"type": "object"
}