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

feat: onboard linkedin audience destination #1758

Merged
merged 6 commits into from
Nov 18, 2024
Merged

Conversation

ItsSudip
Copy link
Member

@ItsSudip ItsSudip commented Oct 22, 2024

What are the changes introduced in this PR?

We are onboarding a new destination named LinkedIn Audience

What is the related Linear task?

Resolves INT-45

Screenshot 2024-11-18 at 2 00 20 PM

Please explain the objectives of your changes below

Put down any required details on the broader aspect of your changes. If there are any dependent changes, mandatorily mention them here

Any changes to existing capabilities/behaviour, mention the reason & what are the changes ?

N/A

Any new dependencies introduced with this change?

N/A

Any new checks got introduced or modified in test suites. Please explain the changes.

N/A


Developer checklist

  • My code follows the style guidelines of this project

  • No breaking changes are being introduced.

  • All related docs linked with the PR?

  • All changes manually tested?

  • Any documentation changes needed with this change?

  • I have executed schemaGenerator tests and updated schema if needed

  • Are sensitive fields marked as secret in definition config?

  • My test cases and placeholders use only masked/sample values for sensitive fields

  • Is the PR limited to 10 file changes & one task?

Reviewer checklist

  • Is the type of change in the PR title appropriate as per the changes?

  • Verified that there are no credentials or confidential data exposed with the changes.

Summary by CodeRabbit

  • New Features

    • Introduced configuration files for LinkedIn Audience integration, enhancing user setup and connection options.
    • Added user interface configurations to guide users in updating connection settings with helpful notes and documentation links.
    • Implemented a schema for validating cookie categories and consent purposes, ensuring proper configuration adherence.
  • Documentation

    • Improved user guidance through structured templates and notes in the new configuration files.

Copy link

coderabbitai bot commented Oct 22, 2024

Walkthrough

Three new JSON configuration files have been added for the LinkedIn Audience destination. The db-config.json file specifies properties for integration, including authentication methods, supported source types, and connection modes. The ui-config.json file outlines the user interface configuration, detailing the initial setup and user guidance for connection settings. Additionally, the schema.json file defines the structure for cookie categories and consent purposes, ensuring data validation. Together, these configurations facilitate the integration of LinkedIn's audience features.

Changes

File Path Change Summary
src/configurations/destinations/linkedin_audience/db-config.json New configuration file defining properties for LinkedIn Audience integration, including authentication and connection settings.
src/configurations/destinations/linkedin_audience/ui-config.json New configuration file for user interface setup, providing guidance for connection settings and event routing.
src/configurations/destinations/linkedin_audience/schema.json New JSON schema defining the structure for cookie categories and consent purposes, ensuring data validation.

Possibly related PRs

  • feat: onboarding intercom v2 destination #1655: The changes in this PR involve a new configuration file for the Intercom V2 destination, which also includes OAuth authentication details similar to the LinkedIn Audience configuration in the main PR.
  • feat: onboard Amazon Audience #1667: This PR introduces a new configuration for the Amazon Audience destination, which includes OAuth authentication and similar properties for source types and connection modes as seen in the LinkedIn Audience configuration.
  • feat(garl): move GARL destination to new form builder #1715: This PR modifies the db-config.json for Google Ads Remarketing Lists, adding an audienceId field, which relates to the audience management aspect present in the LinkedIn Audience configuration.
  • chore: adding salesforce oauth sandbox support for closed testing #1732: The Salesforce OAuth Sandbox configuration includes OAuth authentication and audience support, similar to the LinkedIn Audience configuration's focus on OAuth and audience features.
  • feat: onboard tune destination #1744: The TUNE destination configuration introduces a comprehensive setup for managing destination behavior, including OAuth and audience-related properties, which aligns with the changes made in the LinkedIn Audience configuration.
  • feat: gaec migration #1783: This PR focuses on Google Ads Enhanced Conversions, which includes modifications to the configuration structure and validation rules, similar to the structured approach taken in the LinkedIn Audience configuration.
  • fix: gaec schema #1787: This PR updates the schema for Google Ads Enhanced Conversions, allowing for additional properties, which reflects the flexible configuration approach seen in the LinkedIn Audience configuration.

Suggested reviewers

  • lvrach
  • am6010
  • AchuthaSourabhC
  • krishna2020
  • ssbeefeater
  • debanjan97
  • cisse21
  • ruchiramoitra
  • sandeepdsvs
  • shrouti1507
  • 1abhishekpandey

🐰 In the fields of code, we hop and play,
New configs for LinkedIn brighten the day!
With OAuth and routing, we set the scene,
For audience magic, sleek and keen.
So let's celebrate, with a joyful cheer,
Integration's here, let’s spread the cheer! 🎉


Thank you for using CodeRabbit. We offer it for free to the OSS community and would appreciate your support in helping us grow. If you find it useful, would you consider giving us a shout-out on your favorite social media?

❤️ Share
🪧 Tips

Chat

There are 3 ways to chat with CodeRabbit:

  • Review comments: Directly reply to a review comment made by CodeRabbit. Example:
    • I pushed a fix in commit <commit_id>, please review it.
    • Generate unit testing code for this file.
    • Open a follow-up GitHub issue for this discussion.
  • Files and specific lines of code (under the "Files changed" tab): Tag @coderabbitai in a new review comment at the desired location with your query. Examples:
    • @coderabbitai generate unit testing code for this file.
    • @coderabbitai modularize this function.
  • PR comments: Tag @coderabbitai in a new PR comment to ask questions about the PR branch. For the best results, please provide a very specific query, as very limited context is provided in this mode. Examples:
    • @coderabbitai gather interesting stats about this repository and render them as a table. Additionally, render a pie chart showing the language distribution in the codebase.
    • @coderabbitai read src/utils.ts and generate unit testing code.
    • @coderabbitai read the files in the src/scheduler package and generate a class diagram using mermaid and a README in the markdown format.
    • @coderabbitai help me debug CodeRabbit configuration file.

Note: Be mindful of the bot's finite context window. It's strongly recommended to break down tasks such as reading entire modules into smaller chunks. For a focused discussion, use review comments to chat about specific files and their changes, instead of using the PR comments.

CodeRabbit Commands (Invoked using PR comments)

  • @coderabbitai pause to pause the reviews on a PR.
  • @coderabbitai resume to resume the paused reviews.
  • @coderabbitai review to trigger an incremental review. This is useful when automatic reviews are disabled for the repository.
  • @coderabbitai full review to do a full review from scratch and review all the files again.
  • @coderabbitai summary to regenerate the summary of the PR.
  • @coderabbitai resolve resolve all the CodeRabbit review comments.
  • @coderabbitai configuration to show the current CodeRabbit configuration for the repository.
  • @coderabbitai help to get help.

Other keywords and placeholders

  • Add @coderabbitai ignore anywhere in the PR description to prevent this PR from being reviewed.
  • Add @coderabbitai summary to generate the high-level summary at a specific location in the PR description.
  • Add @coderabbitai anywhere in the PR title to generate the title automatically.

CodeRabbit Configuration File (.coderabbit.yaml)

  • You can programmatically configure CodeRabbit by adding a .coderabbit.yaml file to the root of your repository.
  • Please see the configuration documentation for more information.
  • If your editor has YAML language server enabled, you can add the path at the top of this file to enable auto-completion and validation: # yaml-language-server: $schema=https://coderabbit.ai/integrations/schema.v2.json

Documentation and Community

  • Visit our Documentation for detailed information on how to use CodeRabbit.
  • Join our Discord Community to get help, request features, and share feedback.
  • Follow us on X/Twitter for updates and announcements.

Copy link

@coderabbitai coderabbitai bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Actionable comments posted: 1

🧹 Outside diff range and nitpick comments (2)
src/configurations/destinations/linkedin_audience/db-config.json (2)

1-3: Correct the capitalization in the display name.

The display name "Linkedin Audience" should have consistent capitalization.

Apply this change:

-  "displayName": "Linkedin Audience",
+  "displayName": "LinkedIn Audience",

28-30: Consider adding more details about the beta status.

The configuration correctly indicates that the LinkedIn Audience integration is in beta. Consider adding more information about the beta status, such as known limitations or an expected timeline for full release, to help users understand what to expect.

For example, you could expand the options section like this:

"options": {
  "isBeta": true,
  "betaInfo": "This integration is in beta. Some features may be limited or subject to change. Expected full release: Q4 2024."
}
📜 Review details

Configuration used: CodeRabbit UI
Review profile: CHILL

📥 Commits

Files that changed from the base of the PR and between 2565f39 and 6930e91.

📒 Files selected for processing (2)
  • src/configurations/destinations/linkedin_audience/db-config.json (1 hunks)
  • src/configurations/destinations/linkedin_audience/ui-config.json (1 hunks)
🧰 Additional context used
🔇 Additional comments (6)
src/configurations/destinations/linkedin_audience/db-config.json (2)

21-26: Verify the empty "secretKeys" array.

The "secretKeys" array is currently empty. Please confirm if this is intentional or if there are any secret keys that should be included for the LinkedIn Audience integration.

#!/bin/bash
# Description: Check other LinkedIn configurations for secret keys patterns.

# Test: Search for LinkedIn configurations with non-empty secretKeys
rg -g '*.json' -C 5 '"secretKeys":\s*\[(?!\s*\])' src/configurations/destinations/linkedin*

13-20: Verify supported message types for warehouse sources.

The configuration specifies supported message types for cloud sources but not for warehouse sources. Please confirm if this is intentional or if warehouse sources should also support certain message types.

src/configurations/destinations/linkedin_audience/ui-config.json (4)

1-35: LGTM: Overall structure is well-organized.

The JSON structure is valid and follows a logical organization for UI configuration. The use of a "baseTemplate" array allows for potential future expansion if needed.


4-14: Verify the purpose of the empty fields array in the initial setup.

The initial setup section is well-structured with a clear title and guidance note. However, there's an empty fields array that might be intended for future use.

Could you confirm if the empty fields array is intentional? If so, consider adding a comment explaining its future purpose. If not, you may want to remove it to keep the configuration concise.


15-30: Verify the purpose of the empty fields array in the connection mode section.

The connection mode section is well-structured with a clear title, informative note, and helpful link. The use of an icon enhances the user interface. However, there's an empty fields array that might be intended for future use.

Could you confirm if the empty fields array is intentional? If so, consider adding a comment explaining its future purpose. If not, you may want to remove it to keep the configuration concise.


11-11: Clarify the absence of field definitions in the configuration.

The configuration currently lacks any field definitions, which is unusual for a UI configuration. This might indicate that the configuration is incomplete or that fields are defined elsewhere.

Could you please clarify:

  1. Are field definitions intentionally omitted from this file?
  2. If so, where are the actual field definitions located?
  3. If not, should we add the necessary field definitions to complete the configuration?

Also applies to: 27-27

@devops-github-rudderstack
Copy link
Contributor

This PR is considered to be stale. It has been open for 20 days with no further activity thus it is going to be closed in 7 days. To avoid such a case please consider removing the stale label manually or add a comment to the PR.

Copy link

@coderabbitai coderabbitai bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Actionable comments posted: 0

🧹 Outside diff range and nitpick comments (1)
src/configurations/destinations/linkedin_audience/ui-config.json (1)

5-6: Enhance setup guidance note

The current note "Update your connection setting here" is too generic. Consider providing more specific guidance about what settings users need to configure for LinkedIn Audience integration.

-        "note": "Update your connection setting here",
+        "note": "Configure your LinkedIn Audience connection settings, including authentication and data mapping preferences",
📜 Review details

Configuration used: CodeRabbit UI
Review profile: CHILL

📥 Commits

Reviewing files that changed from the base of the PR and between 6930e91 and 5c526e5.

📒 Files selected for processing (2)
  • src/configurations/destinations/linkedin_audience/db-config.json (1 hunks)
  • src/configurations/destinations/linkedin_audience/ui-config.json (1 hunks)
🚧 Files skipped from review as they are similar to previous changes (1)
  • src/configurations/destinations/linkedin_audience/db-config.json
🔇 Additional comments (3)
src/configurations/destinations/linkedin_audience/ui-config.json (3)

1-40: Security review passed

The configuration file:

  • Contains no exposed credentials or sensitive information
  • Uses only public documentation URLs
  • Follows secure configuration practices

34-38: Clarify the purpose of non-visible SDK template

The SDK template section is marked as "not visible in the ui". This raises a few questions:

  1. If it's not visible, what's the purpose of this section?
  2. Should this configuration be moved to a different file if it's not UI-related?
  3. Are there any specific SDK settings required for LinkedIn Audience integration?

1-40: Verify if empty field configurations are intentional

The configuration contains multiple empty field arrays (fields: [] or fields: [{}]). This might indicate incomplete configuration for:

  • Initial setup fields (line 11)
  • Connection mode fields (line 27)
  • SDK settings fields (line 37)

Please confirm if this is intentional or if these sections need to be populated with specific field configurations.

Copy link

codecov bot commented Nov 13, 2024

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 100.00%. Comparing base (c70c6b0) to head (7cb92f2).
Report is 1 commits behind head on develop.

Additional details and impacted files
@@            Coverage Diff            @@
##           develop     #1758   +/-   ##
=========================================
  Coverage   100.00%   100.00%           
=========================================
  Files            2         2           
  Lines           53        53           
  Branches         7         7           
=========================================
  Hits            53        53           

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

Copy link

@coderabbitai coderabbitai bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Actionable comments posted: 3

🧹 Outside diff range and nitpick comments (5)
src/configurations/destinations/linkedin_audience/schema.json (3)

1-5: Consider adding recommended JSON Schema attributes.

The schema could benefit from additional metadata attributes for better documentation and validation:

  • title: To provide a human-readable name
  • description: To document the purpose
  • additionalProperties: To control unknown properties
 {
   "configSchema": {
     "$schema": "http://json-schema.org/draft-07/schema#",
+    "title": "LinkedIn Audience Configuration Schema",
+    "description": "Schema for validating LinkedIn Audience destination configuration including OneTrust and Ketch consent settings",
     "type": "object",
+    "additionalProperties": false,
     "properties": {

15-17: Document the string pattern constraints.

The pattern (^\\{\\{.*\\|\\|(.*)\\}\\}$)|(^env[.].+)|^(.{0,100})$ is used multiple times but lacks documentation explaining the allowed formats:

  1. Handlebars templates with fallbacks: {{...||...}}
  2. Environment variables: env.*
  3. Regular strings (max 100 chars)

Add comments explaining the pattern:

                 "oneTrustCookieCategory": {
                   "type": "string",
+                  "description": "Accepts: 1) Handlebars templates with fallbacks {{template||fallback}}, 2) Environment variables env.*, or 3) Regular strings up to 100 characters",
+                  "examples": ["{{category||Marketing}}", "env.COOKIE_CATEGORY", "Marketing"],
                   "pattern": "(^\\{\\{.*\\|\\|(.*)\\}\\}$)|(^env[.].+)|^(.{0,100})$"
                 }

Also applies to: 26-29, 44-46, 55-58


1-66: Consider schema reusability across destinations.

Since consent management is likely a common requirement across destinations, consider:

  1. Moving common patterns to shared schema definitions
  2. Using $ref to reference these shared definitions
  3. Creating a base consent schema that destinations can extend

This would improve maintainability and ensure consistent validation across destinations.

src/configurations/destinations/linkedin_audience/ui-config.json (2)

11-11: Remove empty placeholder object from fields array

The empty object in the fields array serves no purpose and should be removed.

-"fields": [{}]
+"fields": []

146-146: Fix inconsistent apostrophe usage

Change "ID's" to "IDs" for consistency with other labels in the file.

-"label": "Enter consent category ID's",
+"label": "Enter consent category IDs",
📜 Review details

Configuration used: CodeRabbit UI
Review profile: CHILL

📥 Commits

Reviewing files that changed from the base of the PR and between 5c526e5 and fc13343.

📒 Files selected for processing (2)
  • src/configurations/destinations/linkedin_audience/schema.json (1 hunks)
  • src/configurations/destinations/linkedin_audience/ui-config.json (1 hunks)
🔇 Additional comments (4)
src/configurations/destinations/linkedin_audience/schema.json (1)

35-63: Apply the same validation improvements to Ketch consent purposes.

The structure mirrors OneTrust cookie categories and would benefit from the same validation enhancements.

src/configurations/destinations/linkedin_audience/ui-config.json (3)

116-116: Verify default consent provider setting

The default consent provider is set to "oneTrust". Please verify if this is the correct default for LinkedIn Audience integration.

Let's check default providers in other destinations:

#!/bin/bash
# Search for default consent provider configurations
rg -g "ui-config.json" -C 5 '"default": "oneTrust"' src/configurations/destinations/

34-38: Clarify the purpose of SDK Template section

The SDK template section is marked as "not visible in the ui" and contains no fields. Please clarify:

  1. Is this section needed for LinkedIn Audience integration?
  2. If needed, what fields should be configured here?

Let's check if other destinations use this template:

#!/bin/bash
# Search for SDK template usage in other destinations
rg -g "ui-config.json" -C 5 '"sdkTemplate"' src/configurations/destinations/

16-30: ⚠️ Potential issue

Connection mode section requires configuration fields

The connection mode section appears incomplete. It includes a title and documentation link but lacks the necessary configuration fields for LinkedIn Audience connection settings.

Let's verify if other destination configurations have similar connection mode fields:

@koladilip
Copy link
Collaborator

share screenshots

@ItsSudip ItsSudip merged commit a039627 into develop Nov 18, 2024
12 checks passed
@ItsSudip ItsSudip deleted the feat.linkedin_audience branch November 18, 2024 08:40
@coderabbitai coderabbitai bot mentioned this pull request Dec 2, 2024
11 tasks
@coderabbitai coderabbitai bot mentioned this pull request Dec 12, 2024
11 tasks
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants