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

# ETL: Connecting to LinkedIn

> How to create a LinkedIn Marketing connection in Integrate.io ETL and build a data pipeline to read campaign, ad, and lead generation data using OAuth.

Integrate.io ETL can access your LinkedIn data. This article details creating the LinkedIn connection and the process of building a data pipeline to read LinkedIn data in Integrate.io ETL. There are also pre-built templates to read data from LinkedIn. Please see [Create a package from a template](/etl/create-a-package-from-a-template) for instructions on using a template.

## To create a LinkedIn connection in Integrate.io ETL

<Steps>
  <Step>
    Click the **Connections** icon (lightning bolt) on the top left menu.
  </Step>

  <Step>
    To create a connection, click **New connection.**

    <Frame>
      <img src="https://mintcdn.com/integrateio/V1Ns1A4dfxUcZVN3/images/connectivity-and-security/image-223.webp?fit=max&auto=format&n=V1Ns1A4dfxUcZVN3&q=85&s=e5afddf0f8984f9f61f20e62db3d7733" alt="New connection button in the Connections menu" width="1200" height="828" data-path="images/connectivity-and-security/image-223.webp" />
    </Frame>
  </Step>

  <Step>
    Choose LinkedIn.

    <Frame>
      <img src="https://mintcdn.com/integrateio/V1Ns1A4dfxUcZVN3/images/connectivity-and-security/image-224.webp?fit=max&auto=format&n=V1Ns1A4dfxUcZVN3&q=85&s=c81afb5b578ef0c68e18624b75c96204" alt="Selecting LinkedIn from the connection type list" width="1200" height="828" data-path="images/connectivity-and-security/image-224.webp" />
    </Frame>
  </Step>

  <Step>
    Click **Authenticate.** (If required, sign in to LinkedIn.)

    <Frame>
      <img src="https://mintcdn.com/integrateio/V1Ns1A4dfxUcZVN3/images/connectivity-and-security/image-225.webp?fit=max&auto=format&n=V1Ns1A4dfxUcZVN3&q=85&s=dbdbe818276532f30eb3d0e2def1ba1c" alt="LinkedIn connection window with Authenticate button" width="1200" height="828" data-path="images/connectivity-and-security/image-225.webp" />
    </Frame>
  </Step>

  <Step>
    Click **Authenticate** to authorize Integrate.io ETL access to your LinkedIn account.
  </Step>

  <Step>
    In the new LinkedIn connection window, name the connection and click **Create LinkedIn connection.**

    <Frame>
      <img src="https://mintcdn.com/integrateio/V1Ns1A4dfxUcZVN3/images/connectivity-and-security/image-226.webp?fit=max&auto=format&n=V1Ns1A4dfxUcZVN3&q=85&s=28371a96e2c12c28af850bdcea83491e" alt="Naming the LinkedIn connection before creation" width="1200" height="828" data-path="images/connectivity-and-security/image-226.webp" />
    </Frame>

    <Frame>
      <img src="https://mintcdn.com/integrateio/V1Ns1A4dfxUcZVN3/images/connectivity-and-security/image-227.webp?fit=max&auto=format&n=V1Ns1A4dfxUcZVN3&q=85&s=33f8cd4d0152209aada67c9ff32025c7" alt="LinkedIn connection created successfully" width="1200" height="828" data-path="images/connectivity-and-security/image-227.webp" />
    </Frame>
  </Step>
</Steps>

## To modify LinkedIn connections in Integrate.io ETL

<Steps>
  <Step>
    Click the Connections icon (lightning bolt) on the top left menu.
  </Step>

  <Step>
    Click a connection to open it and re-connect if your password has changed or the token has expired. Make any necessary changes, then click Reconnect, and Save changes. To exit the LinkedIn connection window without changes, click Back to connections (grey tab on the left side) on the LinkedIn connection window.
  </Step>

  <Step>
    To delete a LinkedIn connection, click on the three vertical dots on the far right of the connection listing and select the Delete connection option.

    <Frame>
      <img src="https://mintcdn.com/integrateio/V1Ns1A4dfxUcZVN3/images/connectivity-and-security/image-228.webp?fit=max&auto=format&n=V1Ns1A4dfxUcZVN3&q=85&s=f81190f466553af2faeb40dd0228eb24" alt="Delete connection option in the connection listing menu" width="1200" height="828" data-path="images/connectivity-and-security/image-228.webp" />
    </Frame>
  </Step>
</Steps>

## To build a data pipeline to read LinkedIn campaign data in Integrate.io ETL

<Frame>
  <img src="https://mintcdn.com/integrateio/V1Ns1A4dfxUcZVN3/images/connectivity-and-security/image-229.webp?fit=max&auto=format&n=V1Ns1A4dfxUcZVN3&q=85&s=623b81a2af021e5af705c62f365bef0f" alt="LinkedIn campaign data pipeline overview in the package designer" width="1322" height="1512" data-path="images/connectivity-and-security/image-229.webp" />
</Frame>

## REST API Component: get\_campaigns

* **Authentication** - Click **Connection** and then select your LinkedIn connection. If you haven't created your LinkedIn connection yet, click **+ New** and follow the instructions found above.
  <Frame>
    <img src="https://mintcdn.com/integrateio/V1Ns1A4dfxUcZVN3/images/connectivity-and-security/image-230.webp?fit=max&auto=format&n=V1Ns1A4dfxUcZVN3&q=85&s=24143263ae0eac29cd8aa0a3746b5fd6" alt="REST API component authentication with LinkedIn connection selected" width="2048" height="828" data-path="images/connectivity-and-security/image-230.webp" />
  </Frame>
* **URL** - Enter the URL for the Campaigns endpoint of the LinkedIn API: **[https://api.linkedin.com/v2/adCampaignsV2?q=search](https://api.linkedin.com/v2/adCampaignsV2?q=search)**. Make sure the method is set to **GET.**
  <Frame>
    <img src="https://mintcdn.com/integrateio/V1Ns1A4dfxUcZVN3/images/connectivity-and-security/image-231.webp?fit=max&auto=format&n=V1Ns1A4dfxUcZVN3&q=85&s=a810495cc9bf82165862cf9ecf31fca9" alt="LinkedIn Campaigns API endpoint URL configuration" width="2124" height="624" data-path="images/connectivity-and-security/image-231.webp" />
  </Frame>
* **Response** - Make sure the **JSON** response type. Edit the **Base record JSONPath Expression** field like this: **\$.elements\[\*].**
  <Frame>
    <img src="https://mintcdn.com/integrateio/V1Ns1A4dfxUcZVN3/images/connectivity-and-security/image-232.webp?fit=max&auto=format&n=V1Ns1A4dfxUcZVN3&q=85&s=fdd423d89eac064fe40660c751133a3e" alt="JSON response type with base record JSONPath expression" width="1702" height="700" data-path="images/connectivity-and-security/image-232.webp" />
  </Frame>
* **Input fields** - Click **Select all** to move all the Available fields over to the Selected fields or pick and choose which fields you would like by clicking on the + icon next to the field name in the Available Fields column. Then click **Save**.
  <Frame>
    <img src="https://mintcdn.com/integrateio/V1Ns1A4dfxUcZVN3/images/connectivity-and-security/image-233.webp?fit=max&auto=format&n=V1Ns1A4dfxUcZVN3&q=85&s=6da3f1e017891f39626d55b97fcdb36e" alt="Input fields selection with available and selected fields" width="1091" height="836" data-path="images/connectivity-and-security/image-233.webp" />
  </Frame>

## Select Component: extract\_campaign\_meta

* Click **Autofill** to bring in all the fields from the source component. Parse the nested fields inside the five Map fields (totalBudget, locale, runSchedule, changeAuditStamps, and unitCost) using this syntax: field\_name#'key' For example, **totalBudget#'amount'.** For more information on parsing JSON data see [this](/etl/how-do-i-process-json-data/) article. Click **Save.**
  <Frame>
    <img src="https://mintcdn.com/integrateio/V1Ns1A4dfxUcZVN3/images/connectivity-and-security/image-234.webp?fit=max&auto=format&n=V1Ns1A4dfxUcZVN3&q=85&s=0ecd1a623524d77621c20f3989969173" alt="Select component parsing nested campaign metadata fields" width="1089" height="932" data-path="images/connectivity-and-security/image-234.webp" />
  </Frame>

## Destination Component: campaigns

* The template shows a Redshift destination component; however, if you'd prefer to use a different destination, delete the Redshift component and select a destination component of your choice.
  <Frame>
    <img src="https://mintcdn.com/integrateio/V1Ns1A4dfxUcZVN3/images/connectivity-and-security/image-235.webp?fit=max&auto=format&n=V1Ns1A4dfxUcZVN3&q=85&s=2fe4d873f845a00b428ffa5fe6e43752" alt="Redshift destination component in the pipeline designer" width="1200" height="1151" data-path="images/connectivity-and-security/image-235.webp" />
  </Frame>
* **Choose target connection** - Select your target connection. If you haven't created your connection yet, click **+ New.**
  <Frame>
    <img src="https://mintcdn.com/integrateio/V1Ns1A4dfxUcZVN3/images/connectivity-and-security/image-236.webp?fit=max&auto=format&n=V1Ns1A4dfxUcZVN3&q=85&s=ea6cc53ee26f647ef5ba4fbf4ea0b6a2" alt="Target connection selection dropdown" width="2034" height="690" data-path="images/connectivity-and-security/image-236.webp" />
  </Frame>
* **Destination properties** - Fill in the values for target schema and table, select an operation type, pre or post-action SQL, and advanced options.
* **Schema mapping** - Click **Auto-fill** to bring in all of the fields. If you've selected a Merge operation type, click the **Key** box next to the merge key field(s). Click **Save.**
  <Frame>
    <img src="https://mintcdn.com/integrateio/V1Ns1A4dfxUcZVN3/images/connectivity-and-security/image-237.webp?fit=max&auto=format&n=V1Ns1A4dfxUcZVN3&q=85&s=4df553dc081f62cb1da0adc024260067" alt="Schema mapping with auto-filled fields and merge key selection" width="2170" height="1314" data-path="images/connectivity-and-security/image-237.webp" />
  </Frame>
