Social Post CRUD Setup
Create, read, update, and delete social media posts across Facebook, Instagram, Twitter, LinkedIn, Google Business Profile, and TikTok. This quick-start walks you through authentication, your first post, and verifying everything works end to end.
Prerequisites
Before making your first Social Post CRUD call, confirm you have:
- A GoHighLevel sub-account with at least one connected social media account (Facebook page, Instagram business account, LinkedIn company page, etc.)
- Access to Settings > Integrations > Private Integrations in your sub-account
- A REST client such as Postman, Insomnia, or
curlin your terminal - Your sub-account’s
locationId(found in Settings > Business Profile) - At least one social platform authorized through the GHL social media settings
Set Up Authentication
All Social Post CRUD endpoints require a Private Integration Token (PIT) with the social-media-posting scope.
Navigate to Settings > Integrations > Private Integrations in your sub-account. Click Create New Integration and name it something descriptive like “Social Media API.” Under Scopes, enable social-media-posting. This grants read and write access to social posts, accounts, tags, and categories.
Click Save and copy the generated token. Store it securely. Pass this token in the Authorization header of every request as a Bearer token. Set your base URL to https://services.leadconnectorhq.com.
Make Your First Call
Start by creating a new social post. Send a POST request to /social-media-posting/post:
POST /social-media-posting/post
Authorization: Bearer {your-pit-token}
Content-Type: application/json
{
"locationId": "your-location-id",
"accountIds": ["connected-account-id"],
"post": "Testing the GHL social posting API!",
"mediaUrls": [],
"scheduleDate": "2026-03-10T14:00:00Z",
"status": "scheduled"
}
Key fields: accountIds specifies which connected accounts to post to, post is your caption or text, mediaUrls accepts image or video URLs, and scheduleDate sets the publish time. Set status to "draft" to save without scheduling.
To retrieve a post, call GET /social-media-posting/post/{id}. To update it, use PUT /social-media-posting/post/{id} with the fields you want to change. To delete, send DELETE /social-media-posting/post/{id}.
Handle the Response
A successful POST returns a 200 status with the post object including a unique id, platform-specific metadata, and the current status. Save the id for subsequent read, update, or delete operations.
Common error codes: 400 means a required field is missing or the accountIds array is empty. 401 indicates an invalid or expired token. 404 on GET, PUT, or DELETE means the post ID does not exist. If a post fails to publish on a specific platform, the response includes platform-level error details in the platformErrors array.
Test Your Setup
Run through this checklist to confirm everything works:
- Create a draft post with
POST /social-media-posting/postand verify the response contains anid - Read it back with
GET /social-media-posting/post/{id} - Update the caption with
PUT /social-media-posting/post/{id} - Verify the post appears in Marketing > Social Planner in the GHL dashboard
- Delete the test post with
DELETE /social-media-posting/post/{id}and confirm removal
If posts fail to publish, check that your connected accounts have valid OAuth tokens in Settings > Social Media. Expired tokens require re-authorization.
Next Steps
Read the full Social Post CRUD Guide for advanced patterns including multi-platform scheduling, media handling, and post analytics. From here, explore Social Post Search for filtering published content and Social Accounts for managing connected platforms.