> ## Documentation Index
> Fetch the complete documentation index at: https://deepline.com/docs/llms.txt
> Use this file to discover all available pages before exploring further.

# LinkedIn Ads Audiences: Sync Audience Members

> Replace the contacts or companies in a LinkedIn Ads matched audience with a new list. Includes inputs, outputs, SDK V2 examples, and Deepline cost.

Replace the contacts or companies in a LinkedIn Ads matched audience with a new list.

> [!NOTE]
>
> Tool ID: `linkedin_ads_audiences_sync_audience_members`

## Run this action

Use the TypeScript SDK for one call. Use `ctx.tools.execute(...)` inside a Play for durable calls, scheduled calls, or CSV processing.

```ts theme={"languages":{"custom":["/languages/deepline-prompt.json"]}}
import { Deepline } from 'deepline';

const deepline = await Deepline.connect();
const result = await deepline.tools.execute(
  'linkedin_ads_audiences_sync_audience_members',
  {
    "audience_id": "audience_123",
    "rows": [
      {
        "email": "jane.doe@example.com",
        "email_sha256": "jane.doe@example.comxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx",
        "phone": "+14155550123"
      }
    ]
  },
);

console.log(result.toolResponse.raw);
```

### CLI

```bash theme={"languages":{"custom":["/languages/deepline-prompt.json"]}}
deepline tools execute linkedin_ads_audiences_sync_audience_members --input '{
  "audience_id": "audience_123",
  "rows": [
    {
      "email": "jane.doe@example.com",
      "email_sha256": "jane.doe@example.comxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx",
      "phone": "+14155550123"
    }
  ]
}' --json
```

## Example response

The SDK returns this shape at `result.toolResponse.raw`. The example values illustrate the response.

```json theme={"languages":{"custom":["/languages/deepline-prompt.json"]}}
{
  "data": {
    "audience_id": "audience_123",
    "mode": "append",
    "uploaded_count": 123,
    "invalid_count": 123,
    "invalid_rows": [
      {
        "originalIndex": 123,
        "reason": "example"
      }
    ],
    "request_ids": [
      "request_123"
    ]
  }
}
```

Use `deepline describe linkedin_ads_audiences_sync_audience_members --json` for the latest machine-readable contract.

## Input reference

| Name | Type | Required | Default | Details |
| - | - | - | - | - |
| `payload.account_id` | `string` | No | — | LinkedIn sponsored account ID. Find it in Campaign Manager under Account Assets, or in the URL as /campaignmanager/accounts/\{id}. Pass the bare numeric id or a full urn:li:sponsoredAccount:\{id}. Deepline normalizes either form. Optional: defaults to the workspace default account, or the sole enabled account when only one exists. Minimum length: 1. |
| `payload.audience_id` | `string` | Yes | — | Minimum length: 1. |
| `payload.audience_kind` | `"contacts" \| "companies"` | No | `"contacts"` | Allowed: `contacts`, `companies`. |
| `payload.mode` | `"replace"` | No | `"replace"` | LinkedIn LIST\_UPLOAD audiences only support replace semantics. Append mode is not allowed. |
| `payload.rows` | `array` | Yes | — | Audience member rows to upload. Most platforms accept much smaller per-request batches, so Deepline automatically chunks requests. Minimum items: 1. Maximum items: 300000. |

<details>
  <summary>Show raw input schema</summary>

  ### Input JSON Schema

  ```json theme={"languages":{"custom":["/languages/deepline-prompt.json"]}}
  {
    "type": "object",
    "properties": {
      "account_id": {
        "type": "string",
        "description": "LinkedIn sponsored account ID. Find it in Campaign Manager under Account Assets, or in the URL as /campaignmanager/accounts/{id}. Pass the bare numeric id or a full urn:li:sponsoredAccount:{id}; Deepline normalizes either form. Optional: defaults to the workspace default account, or the sole enabled account when only one exists.",
        "minLength": 1
      },
      "audience_id": {
        "type": "string",
        "minLength": 1
      },
      "audience_kind": {
        "type": "string",
        "default": "contacts",
        "enum": [
          "contacts",
          "companies"
        ]
      },
      "mode": {
        "type": "string",
        "description": "LinkedIn LIST_UPLOAD audiences only support replace semantics. Append mode is not allowed.",
        "default": "replace",
        "const": "replace"
      },
      "rows": {
        "type": "array",
        "description": "Audience member rows to upload. Most platforms accept much smaller per-request batches, so Deepline automatically chunks requests.",
        "minItems": 1,
        "maxItems": 300000,
        "items": {
          "type": "object",
          "description": "One audience member source row. Deepline normalizes and hashes supported identifiers before sending them to each destination.",
          "properties": {
            "email": {
              "type": "string",
              "minLength": 1
            },
            "email_sha256": {
              "type": "string",
              "minLength": 64,
              "maxLength": 64
            },
            "phone": {
              "type": "string",
              "minLength": 1
            },
            "phone_sha256": {
              "type": "string",
              "minLength": 64,
              "maxLength": 64
            },
            "first_name": {
              "type": "string",
              "minLength": 1
            },
            "last_name": {
              "type": "string",
              "minLength": 1
            },
            "country_code": {
              "type": "string",
              "minLength": 2,
              "maxLength": 2
            },
            "postal_code": {
              "type": "string",
              "minLength": 1
            },
            "company_name": {
              "type": "string",
              "minLength": 1
            },
            "title": {
              "type": "string",
              "minLength": 1
            },
            "company_domain": {
              "type": "string",
              "minLength": 1
            },
            "company_website": {
              "type": "string",
              "minLength": 1
            },
            "company_linkedin_url": {
              "type": "string",
              "minLength": 1
            },
            "person_linkedin_url": {
              "type": "string",
              "minLength": 1
            },
            "external_id": {
              "type": "string",
              "minLength": 1
            }
          },
          "additionalProperties": false
        }
      }
    },
    "required": [
      "audience_id",
      "rows"
    ],
    "additionalProperties": false
  }
  ```
</details>

## Output reference

| Name | Type | Required | Default | Details |
| - | - | - | - | - |
| `result.data` | `object` | Yes | — | — |
| `result.data.audience_id` | `string` | Yes | — | — |
| `result.data.mode` | `"append" \| "replace"` | Yes | — | Allowed: `append`, `replace`. |
| `result.data.uploaded_count` | `integer` | Yes | — | Minimum: 0. |
| `result.data.invalid_count` | `integer` | Yes | — | Minimum: 0. |
| `result.data.invalid_rows` | `array` | Yes | — | — |
| `result.data.invalid_rows[].originalIndex` | `integer` | Yes | — | Minimum: 0. |
| `result.data.invalid_rows[].reason` | `string` | Yes | — | — |
| `result.data.request_ids` | `array` | Yes | — | — |
| `result.meta` | `record` | No | — | — |

<details>
  <summary>Show raw output schema</summary>

  ### Output JSON Schema

  ```json theme={"languages":{"custom":["/languages/deepline-prompt.json"]}}
  {
    "type": "object",
    "properties": {
      "data": {
        "type": "object",
        "properties": {
          "audience_id": {
            "type": "string"
          },
          "mode": {
            "type": "string",
            "enum": [
              "append",
              "replace"
            ]
          },
          "uploaded_count": {
            "type": "integer",
            "minimum": 0
          },
          "invalid_count": {
            "type": "integer",
            "minimum": 0
          },
          "invalid_rows": {
            "type": "array",
            "items": {
              "type": "object",
              "properties": {
                "originalIndex": {
                  "type": "integer",
                  "minimum": 0
                },
                "reason": {
                  "type": "string"
                }
              },
              "required": [
                "originalIndex",
                "reason"
              ],
              "additionalProperties": false
            }
          },
          "request_ids": {
            "type": "array",
            "items": {
              "type": "string"
            }
          }
        },
        "required": [
          "audience_id",
          "mode",
          "uploaded_count",
          "invalid_count",
          "invalid_rows",
          "request_ids"
        ],
        "additionalProperties": false
      },
      "meta": {
        "type": "object",
        "additionalProperties": {}
      }
    },
    "required": [
      "data"
    ],
    "additionalProperties": false
  }
  ```
</details>

## Deepline cost

* Pricing model: `fixed` (per call).
* Estimated Deepline credits: `0` per pricing unit.
* Provider-native pricing may still exist outside Deepline credit billing.

## Related documentation

* [SDK V2 quickstart](https://deepline.com/docs/sdk-v2/quickstart.md)
* [SDK reference](https://deepline.com/docs/sdk-v2/sdk-reference.md)
* [Run tools across a CSV](https://deepline.com/docs/sdk-v2/batch-csv.md)


This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.