Skip to main content
Drupal is a registered trademark of Dries Buytaert
Release: Drupal 11.3.18 — Update released for Drupal core (11.3.18)! Release: Menu Item Extras 3.1.3 — Minor update available for module menu_item_extras (3.1.3). Release: Media Alias Display 3.0.1 — Minor update available for module media_alias_display (3.0.1). Release: Geolocation Field 4.1.0-rc1 — First release candidate for module geolocation (4.1.0-rc1). Release: TMGMT DeepL Integration 2.3.2 — Minor update available for module tmgmt_deepl (2.3.2). Release: TMGMT DeepL Integration 2.2.19 — Minor update available for module tmgmt_deepl (2.2.19). Release: Webtheme 12.0.3 — Minor update available for theme webtheme (12.0.3). Release: UI Suite UIkit 1.0.4 — Minor update available for theme ui_suite_uikit (1.0.4). Module Revived: Url Redirect 4.0.1 — Module url_redirect updated after 7 months of inactivity (4.0.1). Security Coverage: LLM Offramp — Module llm_offramp now has official Drupal security advisory coverage.

Social Media Post

No security coverage Drupal 10–11 PHP >=8.1

Part of the Social ecosystem · 36 projects

View on drupal.org
Social Media Post

Compose social posts in Drupal and publish them to LinkedIn, Facebook, Twitter/X, and Bluesky without copying text into each network by hand.

Problem this module solves

Newsrooms and marketing teams often write an article in Drupal, then paste the same story into LinkedIn, Facebook, Twitter/X, and Bluesky. That work is slow, easy to get wrong, and hard to track: there is no single place in Drupal that shows which networks were posted, with which text, or with the live post URL.

Social Media Post keeps that workflow inside Drupal:

  • Editors write (or load) the post once, then adjust text per network.
  • Image, video, or PDF is attached on the same form.
  • A preview shows how the post will look before it goes out.
  • Publishing is either automated through n8n or sent directly from Drupal.
  • Each networks public URL is saved back on the Drupal node so staff can open the live post later.
  • The Drupal site keeps all social media posts in one place. Those nodes can also be used in the frontend (lists, blocks, or views) just like any other content.

Features

  • Social Post content type (social_post)
  • Per-network text: LinkedIn, Facebook, Twitter/X, Bluesky
  • Load title, text, CTA URL, and media from existing content
  • Image, video (library, URL, or upload), and PDF
  • Optional Social Media Posts tab on chosen content types
  • Compose preview with configurable account name and handles
  • Live embed of the published post on edit
  • Two posting engines: n8n webhooks or the Social Media Auto Post API submodule
  • Incoming webhook stores LinkedIn / Facebook / Twitter / Bluesky URLs
  • Send-once lock so one save does not post the same network twice
  • Social posts are normal Drupal nodes, so they can be listed or displayed on the frontend

Future work

  • A single dashboard of all social posts across networks
  • Engagement stats in that same place (likes, comments, shares, and similar metrics pulled from each platform)

Requirements

Drupal core (required)

These are declared in social_media_post.info.yml:

  • Drupal 10 or 11
  • Node, Media, File, Image, Options, REST, Serialization

Also used by the form and listing (core modules, enable them):

  • Media Library image and video widgets
  • Views listing of social posts on the source-content tab

Optional core modules

  • Content Moderation and Workflows if your site already has an editorial workflow, Social Post can be added to it

Optional contrib modules

Module Project Why Scheduler drupal/scheduler Schedule when a social post is published Dynamic Image Generator drupal/dynamic_image_generator Generate instant poster based on template

Optional submodule (included)

Social Media Auto Post API (social_media_auto_post_api) ships with this project. Enable it only if you want Drupal to call LinkedIn, Facebook, Twitter, Instagram, and Bluesky APIs without n8n. It depends only on Social Media Post.

External tools (n8n engine)

If Posting engine is set to n8n:

  • An n8n instance (self-hosted or cloud)
  • Platform credentials stored in n8n, not in this Git repository:
    • LinkedIn OAuth2
    • Facebook Graph API (Page token)
    • Twitter/X OAuth2
    • Bluesky handle + App Password (in the n8n Config node after import)

Installation

composer require drupal/social_media_post
drush en social_media_post -y
drush cr

Or copy the project into modules/contrib/social_media_post and enable it.

On enable, the module creates the Social Post type, fields, and form display.

Configuration

Go to Configuration Web services Social Media Post (/admin/config/services/social-media-post).

  1. Show Social Media Posts tab on content types that get the tab (for example Article). Leave empty to hide the tab.
  2. Compose preview identity page name, LinkedIn name/headline, Twitter handle, Bluesky handle.
  3. Posting engine
    • n8n automation (webhooks) Drupal POSTs JSON to n8n
    • Built-in Social Media Auto Post API enable the submodule first, then add tokens at /admin/config/services/social-media-auto-post-api
  4. Webhook secret key Basic Auth password for n8n Drupal callbacks (username is webhook)
  5. Outgoing webhook URLs one per network, or the same URL for all; n8n routes on platform
  6. Delete newly uploaded videos after a successful post — on by default

Only networks that are configured (webhook URL, or Auto Post API credentials) appear as Post to … checkboxes.

n8n example JSON (no credentials)

The foldern8n_without_cred/ contains a full workflow you can import. It has no tokens, App Passwords, page IDs, or callback secrets.

File:n8n_without_cred/social_media_post.json

What the workflow does

  • One webhook receives Drupals JSON (platform: linkedin, facebook, twitter, bluesky)
  • LinkedIn: image, PDF (Documents API), or video
  • Facebook: photo, link (PDF), or feed post
  • Twitter/X: text plus a media/article URL
  • Bluesky: 300-character text, link facets so URLs are clickable, image via uploadBlob
  • After success, n8n POSTs the public URL back to Drupal

After import

  1. Fill the Config node: linkedin_org_id, facebook_page_id, Bluesky handle/App Password, drupal_callback_url, drupal_callback_secret
  2. Attach your LinkedIn, Facebook, and Twitter credentials on the HTTP/Twitter nodes
  3. Activate the workflow and paste the webhook URL into Drupal

Do not commit real credentials into git.

Drupal → n8n body

{
  "name": "Post title",
  "title": "Post title",
  "content": "Post text for this network",
  "url": "https://example.com/node/123",
  "social_post_id": "123",
  "pdf_url": "",
  "image_url": "https://example.com/image.jpg",
  "video_url": "",
  "platform": "linkedin"
}

Unused media URLs are empty strings. Only one of pdf_url / image_url / video_url is set (PDF first).

n8n Drupal body

POST /api/social-media-post/n8n-response
Auth: Basic webhook + webhook secret

[{"urn": "urn:li:share:123", "social_post_id": "123"}]
[{"facebook_url": "https://www.facebook.com/123_456", "social_post_id": "123"}]
[{"twitter_url": "https://x.com/i/web/status/123", "social_post_id": "123"}]
[{"bluesky_url": "https://bsky.app/profile/handle/post/abc", "social_post_id": "123"}]

Permissions

  • Administer social media post settings and webhooks
  • Create / edit / delete social post content editorial work
  • Administer Social Media Auto Post API platform API tokens (submodule)

Maintainers

See the project page.

Depends on

Dependencies of the latest stable release

  • file Drupal core
  • image Drupal core
  • media Drupal core
  • node Drupal core
  • options Drupal core
  • rest Drupal core
  • serialization Drupal core

Required by

Tracked projects that depend on this one

No tracked projects depend on this one yet.

Activity

Tracked releases
2
Tracked since
Sep 2026
Latest release
3 hours ago
Releases (12 mo)
2 ▲ from 0
Maintenance
Active

Releases

Version Type Core Release date
1.0.0 Stable 10–11 Sep 28, 2026
1.0.x-dev Dev 10–11 Sep 28, 2026