4 min read

Documentation for getCampaigns

Overview

This node in the Vantage analytics platform is designed to fetch advertising campaign details from a specified ad account. Utilizing integrations with advertising APIs, this function collects information about the campaigns, such as their identifiers, statuses, budgets, and timing, allowing users to analyze and manage their advertising strategies effectively. The flexibility provided by the customizable input parameters enables tailored API requests to suit various business needs.

Settings

This node has several settings that dictate its behavior and output. Below are detailed descriptions of each setting:

1. Ad Account ID (adAccountId)

2. Fields (fields)

3. Limit (limit)

4. Effective Status (effectiveStatus)

How It Works

The node begins by inspecting the input parameters and using them to ascertain relevant configurations. If the adAccountId isn't provided, it immediately returns an error, ensuring that necessary identification is always supplied.

Once the inputs are confirmed, the function utilizes the integration connection to establish a connection with the Meta Marketing API through context provided by the user. The core of the function is making the getCampaigns API call, where it sends the specified adAccountId, selected fields, limit, and effectiveStatus. The retrieved data is processed and returned as output.

In cases of an error, whether during connection establishment or the API call, an appropriate error message is returned, allowing for easier troubleshooting.

Data Expectations

Use Cases & Examples

Use Cases

  1. Campaign Performance Monitoring: A marketing team may need to regularly track the status and performance of their advertising campaigns to make data-driven adjustments to their strategies.

  2. Budget Management: An analyst requires information on the daily and lifetime budgets of various campaigns to ensure that spending aligns with budget forecasts and strategy.

  3. Campaign Lifecycle Management: A product manager wants to analyze campaigns that are not performing well by identifying those that are paused or inactive, allowing for timely decisions regarding campaign adjustments.

Example Configuration

Use Case – Campaign Performance Monitoring: Suppose a digital marketing agency wants to monitor all active campaigns within a specific ad account to evaluate their performance.

Configured Settings:

javascript
{
    inputs: {
        adAccountId: 'act_123456789',
        fields: 'id,name,status,daily_budget,lifetime_budget,start_time,stop_time',
        limit: 100,
        effectiveStatus: 'ACTIVE'
    },
    config: {},
    context: userContext
}

In this configuration:

This setup ensures that the marketing agency can receive detailed insights into their active campaigns swiftly and effectively for ongoing performance evaluations.