Use LinkedIn self-service ads to reach more than 900+ million users worldwide.
Go to siteimport { axios } from "@pipedream/platform"
export default defineComponent({
props: {
linkedin_ads: {
type: "app",
app: "linkedin_ads",
}
},
async run({steps, $}) {
return await axios($, {
url: `https://api.linkedin.com/v2/me`,
headers: {
Authorization: `Bearer ${this.linkedin_ads.$auth.oauth_access_token}`,
},
})
},
})
Queries the Analytics Finder to get analytics for the specified entity i.e company, account, campaign. See the docs here
Sample query using analytics finder that gets analytics for a particular account for date range starting in a given year. See the docs here
Sample query using analytics finder that gets analytics for a particular campaign in a date range starting in a given year. See the docs here
LinkedIn Ads uses OAuth authentication. When you connect your LinkedIn Ads account, Pipedream will open a popup window where you can sign into LinkedIn Ads and grant Pipedream permission to connect to your account. Pipedream securely stores and automatically refreshes the OAuth tokens so you can easily authenticate any LinkedIn Ads API.
Pipedream requests the following authorization scopes when you connect your account:
r_ads_reporting
rw_ads
r_ads
r_basicprofile
GET
https://www.linkedin.com/oauth/v2/authorization
?
client_id={{oauth.client_id}}
&
redirect_uri={{oauth.redirect_uri}}
&
state={{oauth.state}}
&
response_type=code
&
scope={{oauth.space_separated_scopes}}
POST
https://www.linkedin.com/oauth/v2/accessToken
content-type: application/x-www-form-urlencoded
accept: application/json
client_id={{oauth.client_id}}
&
client_secret={{oauth.client_secret}}
&
redirect_uri={{oauth.redirect_uri}}
&
grant_type=authorization_code
&
code={{oauth.code}}
POST
https://www.linkedin.com/oauth/v2/accessToken
content-type: application/x-www-form-urlencoded
accept: application/json
client_id={{oauth.client_id}}
&
client_secret={{oauth.client_secret}}
&
grant_type=refresh_token
&
redirect_uri={{oauth.redirect_uri}}
&
refresh_token={{oauth.refresh_token}}