Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add facebook ads audience APIs #1013

Merged
merged 2 commits into from
Oct 9, 2024
Merged
Show file tree
Hide file tree
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -725,6 +725,154 @@ To use the Facebook Ads connector, first create the connection with your configu
"ad_id": "456456456"
}
```
??? note "createCustomAudience"
The `createCustomAudience` operation creates a custom audience.
<table>
<tr>
<th>Parameter Name</th>
<th>Description</th>
<th>Required</th>
</tr>
<tr>
<td>adAccountId</td>
aashikam marked this conversation as resolved.
Show resolved Hide resolved
<td>ID of the ad account.</td>
<td>Yes</td>
</tr>
<tr>
<td>properties</td>
<td>Custom audience properties.</td>
<td>Yes</td>
</tr>
</table>

**Sample configuration**

```xml
<facebookAds.createCustomAudience configKey="FB_CONN_1">
<adId>{json-eval($.ad_id)}</adId>
<properties>{json-eval($.properties)}</properties>
</facebookAds.createCustomAudience>
```

**Sample request**

```json
{
"ad_id": "456456456",
"properties": {
"name": "My Custom Audience",
"subtype": "CUSTOM",
"description": "Audience based on website traffic",
"customer_file_source": "USER_PROVIDED_ONLY"
}
}
```

??? note "createAdCreative"
The `createAdCreative` operation creates an ad creative.
<table>
<tr>
<th>Parameter Name</th>
<th>Description</th>
<th>Required</th>
</tr>
<tr>
<td>adAccountId</td>
<td>ID of the ad account.</td>
<td>Yes</td>
</tr>
<tr>
<td>properties</td>
<td>Ad creative properties.</td>
<td>Yes</td>
</tr>
</table>

**Sample configuration**

```xml
<facebookAds.createAdCreative configKey="FB_CONN_1">
<adId>{json-eval($.ad_id)}</adId>
<properties>{json-eval($.properties)}</properties>
</facebookAds.createAdCreative>
```

**Sample request**

```json
{
"ad_id": "456456456",
"properties": {
"name": "My Ad Creative",
"object_story_spec": {
"page_id": "465229476789834",
"link_data": {
"description": "My ad creative",
"image_hash": "f2cafafae01fc9201c8d2e70687dhk675Ddsac",
"link": "https://sample.com/",
"message": "Check out my website!",
"name": "headline",
"call_to_action": {
"type": "LEARN_MORE",
"value": {
"link": "https://sample.com/",
"link_caption": ""
}
}
}
},
"degrees_of_freedom_spec": {
"creative_features_spec": {
"standard_enhancements": {
"enroll_status": "OPT_OUT"
}
}
}
}
}
```

??? note "updateCustomAudience"
The `updateCustomAudience` operation updates a custom audience.
<table>
<tr>
<th>Parameter Name</th>
<th>Description</th>
<th>Required</th>
</tr>
<tr>
<td>customAudienceId</td>
<td>ID of the ad set.</td>
<td>Yes</td>
</tr>
<tr>
<td>properties</td>
<td>Custom audience update properties.</td>
<td>Yes</td>
</tr>
</table>

**Sample configuration**

```xml
<facebookAds.updateCustomAudience configKey="FB_CONN_1">
<adId>{json-eval($.audience_id)}</adId>
<properties>{json-eval($.properties)}</properties>
</facebookAds.updateCustomAudience>
```

**Sample request**

```json
{
"audience_id": "456456456",
"properties": {
"name": "My Custom Audience Update",
"subtype": "CUSTOM",
"description": "Audience based on website traffic",
}
}
```

## Error codes related to Facebook Ads Connector

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ To see the Facebook Ads Connector, navigate to the [connector store](https://sto

| Connector Version | Supported product versions |
| ------------- |-------------|
| 1.0.0 | MI 4.3.0 |
| 1.0.1 | MI 4.3.0 |

## Facebook Ads Connector documentation

Expand Down