API Integration & Architecture

Multi-Tenant LinkedIn Publishing Engine

Overcoming strict LinkedIn API limitations with a robust dual-app architecture.

Multi-Tenant LinkedIn Publishing Engine

The Problem

Digital Craft Edge required a social media management module capable of publishing to both personal LinkedIn profiles and official Company Pages. However, LinkedIn enforces strict product isolation: the "Share on LinkedIn" product (for profiles) cannot coexist on the same developer application as the "Community Management API" (required for Company Pages).

Because of these legal and security constraints on LinkedIn\'s side, a standard single-app OAuth integration was impossible, blocking a core feature of the platform.

The Approach

To bypass this limitation seamlessly for the end user, I designed a "Two-App Strategy". The backend was refactored to manage two entirely distinct sets of API credentials simultaneously.

Key architectural components included:

  • Dual OAuth Flows: Created separate callback handlers (`linkedin_oauth_callback.php` and `linkedin_pages_oauth_callback.php`) to route tokens correctly based on the target entity.
  • Entity Tagging: Implemented a robust URN resolution system that correctly distinguishes between `urn:li:person:` and `urn:li:organization:` when pushing payloads to the LinkedIn Post API.
  • Unified UI: Built a dynamic settings interface that merges the configuration of both apps into a single, cohesive user experience, preventing configuration overwrites.

The Result

The platform can now successfully authenticate and publish to both personal profiles and company pages without violating LinkedIn's strict app scoping rules. The underlying complexity is completely abstracted away from the end user, resulting in a smooth, frictionless social publishing experience.

← Previous Project Next Project →