LaraPost icon LARAPOST
Laravel Package MIT v1.0.0

Social publishing for Laravel, built for Facebook Pages, Twitter / X, and LinkedIn.

LaraPost gives your Laravel app one publishing workflow for Facebook Pages, Twitter / X, and LinkedIn.

Package: prateekbhujel/larapost Laravel: 10 / 11 / 12 / 13 PHP: 8.1+
LaraPost banner

Overview

What you get

  • One fluent API via SocialSync\Facades\SocialMedia
  • Built-in dashboard at /larapost/dashboard
  • OAuth connect flow for Facebook, Twitter / X, and LinkedIn
  • Bulk composer for different content across different connected accounts
  • Scheduled publishing with retry processing
  • CI for PHP 8.1 through 8.5

Support Matrix

Platform Connect Publish Notes
Facebook OAuth login Page text, image URL, video URL Pages only. Personal Facebook profile posting is not supported.
Twitter / X OAuth 2.0 Text posts Requires provider write access plus billing or credits. Dashboard media upload is not implemented.
LinkedIn OAuth 2.0 Member profile text posts Organization pages are not supported. Image upload expects a readable local file path in code.

Install

Get the package into your app

composer require prateekbhujel/larapost
php artisan larapost:install

The installer publishes config, migrations, and views, then prepares the package storage path.

Configure

Set provider credentials

FACEBOOK_APP_ID=
FACEBOOK_APP_SECRET=
FACEBOOK_API_VERSION=v20.0

TWITTER_CLIENT_ID=
TWITTER_CLIENT_SECRET=

LINKEDIN_CLIENT_ID=
LINKEDIN_CLIENT_SECRET=

You can keep these in .env or save them from the dashboard. Dashboard-saved credentials override config values.

Dashboard

Built for operators, not screenshots

  • Login popups for Facebook Pages, Twitter / X, and LinkedIn profiles
  • Exact account selection instead of only broad platform blasts
  • Bulk composer for different copy per Page or account
  • Scheduling in your Laravel app timezone
  • Recent post history plus account toggles
GET /larapost/dashboard

API

Publish or schedule from code

use SocialSync\Facades\SocialMedia;

SocialMedia::post()
    ->content('Release update from LaraPost')
    ->platforms(['facebook', 'twitter'])
    ->publish();
SocialMedia::post()
    ->content('Tomorrow morning post')
    ->platforms(['facebook'])
    ->scheduleFor(now()->addHours(12))
    ->publish();

Operations

Run the scheduler every minute

* * * * * php /path/to/artisan larapost:run-scheduled >> /dev/null 2>&1

Bulk scheduled posts, retries, and delayed publishing all depend on the scheduled runner being active.

Commands

Core command surface

  • php artisan larapost:install
  • php artisan larapost:add-account facebook
  • php artisan larapost:add-account twitter
  • php artisan larapost:add-account linkedin
  • php artisan larapost:test
  • php artisan larapost:run-scheduled

Project Docs