Back to top

Social Post

Overview

Resource Group

Get Social posts of brand

Get Social posts of brand
GET/brands/:brand/social-posts

brand (uuid) ID of the brand

user (uuid) ID of the user (optional)

status (‘executed’ | ‘scheduled’ | ‘draft’ | ‘any’) string (optional)

start (number) number of rows to skip before starting to return rows

limit (number) limited number of records

video (boolean) if the template was video

mediums (Email’ | ‘Social’ | ‘CrmOpenHouse’ | ‘FacebookCover’ | ‘InstagramStory’ | ‘LinkedInCover’ | ‘Letter’ | ‘Website’ | ‘RealtorCover’ | ‘YouTubeCover’ | ‘TwitterCover’)[] array of medium

order (string) eg: -created_at (optional)

Example URI

GET /brands/:brand/social-posts
URI Parameters
HideShow
brand
string (required) Example: 0a46d74e-8d57-43f7-97c2-dde461be9cc3
status
string (required) Example: executed
associations
string (required) Example: social_post.template_instance,social_post.asset,social_post.owner
Response  200
HideShow
Body
{
  "code": "OK",
  "data": [
    {
      "id": "6e78ee47-1982-46a8-b4e2-879cfd0262cb",
      "brand": "0a46d74e-8d57-43f7-97c2-dde461be9cc3",
      "created_by": "80a227b2-29a0-11e7-b636-e4a7a08e15d4",
      "caption": "test",
      "facebook_page": "a35882c3-343d-470e-a38c-d753893e2cf5",
      "template_instance": {
        "id": "69920a37-6d20-4636-99ba-273c998cdf86",
        "created_at": 1778872313.569376,
        "html": "<div>fakeTemplateInstance</div>",
        "file": {
          "id": "d3eea496-eb5d-4da2-a117-0b7052cedffb",
          "created_at": 1778872314.636994,
          "updated_at": 1778872314.636994,
          "deleted_at": null,
          "created_by": "80a227b2-29a0-11e7-b636-e4a7a08e15d4",
          "path": "templates/instances/efa676a0-5091-11f1-8248-cf8ab660e2ca.png",
          "name": "image.png",
          "public": true,
          "type": "file",
          "url": "https://test.cloudfront.net/templates/instances/efa676a0-5091-11f1-8248-cf8ab660e2ca.png",
          "preview_url": "https://test.cloudfront.net/templates/instances/efa676a0-5091-11f1-8248-cf8ab660e2ca.png",
          "mime": "image/png"
        },
        "created_by": "80a227b2-29a0-11e7-b636-e4a7a08e15d4",
        "branch": "http://mock-branch-url",
        "updated_at": 1778872313.569376,
        "deleted_at": null,
        "type": "template_instance"
      },
      "asset": null,
      "post_link": "http://test.com",
      "failed_at": null,
      "failure": null,
      "media_container_id": "test",
      "type": "social_post",
      "created_at": 1778872314.752521,
      "updated_at": 1778872314.752521,
      "deleted_at": null,
      "due_at": 1778871714.703,
      "executed_at": 1778872313.569376,
      "owner": {
        "type": "user",
        "username": null,
        "first_name": "Unit",
        "last_name": "Test",
        "email": "[email protected]",
        "phone_number": "+4368120265807",
        "created_at": 1493115498.770362,
        "id": "80a227b2-29a0-11e7-b636-e4a7a08e15d4",
        "address_id": null,
        "cover_image_url": null,
        "profile_image_url": null,
        "updated_at": 1493115498.770744,
        "user_status": "Active",
        "profile_image_thumbnail_url": null,
        "cover_image_thumbnail_url": null,
        "email_confirmed": true,
        "timezone": "America/Chicago",
        "user_type": "Admin",
        "deleted_at": null,
        "phone_confirmed": false,
        "is_shadow": false,
        "personal_room": null,
        "brand": null,
        "fake_email": false,
        "features": [
          "Deals"
        ],
        "last_seen_at": null,
        "email_signature": null,
        "daily_enabled": false,
        "email_quota": 30000,
        "website": null,
        "instagram": null,
        "twitter": null,
        "linkedin": null,
        "youtube": null,
        "facebook": null,
        "designation": null,
        "tiktok": null,
        "mfa_enabled": false,
        "xpressdocs_user_id": "80a227b2-29a0-11e7-b636-e4a7a08e15d4",
        "current_time": "2:11 PM - Friday May 15, 2026",
        "push_allowed": true,
        "agents": null,
        "last_seen_type": null,
        "active_brand": "0a46d74e-8d57-43f7-97c2-dde461be9cc3",
        "display_name": "Unit Test",
        "abbreviated_display_name": "Unit",
        "online_state": "Offline",
        "has_password": true
      }
    },
    {
      "id": "f879263f-d018-4b2f-8194-c2519163ae30",
      "brand": "0a46d74e-8d57-43f7-97c2-dde461be9cc3",
      "created_by": "80a227b2-29a0-11e7-b636-e4a7a08e15d4",
      "caption": "testAsset",
      "facebook_page": "a35882c3-343d-470e-a38c-d753893e2cf5",
      "template_instance": null,
      "asset": {
        "id": "0a5bcedf-4e86-4fac-b4b2-1d29ee91133b",
        "created_at": 1778872314.059355,
        "updated_at": null,
        "deleted_at": null,
        "created_by": "80a227b2-29a0-11e7-b636-e4a7a08e15d4",
        "brand": "0a46d74e-8d57-43f7-97c2-dde461be9cc3",
        "file": {
          "id": "8467985d-8ab4-43b1-8219-8dad665a6e93",
          "created_at": 1778872314.052983,
          "updated_at": 1778872314.052983,
          "deleted_at": null,
          "created_by": "80a227b2-29a0-11e7-b636-e4a7a08e15d4",
          "path": "brands/assets/ef4d3310-5091-11f1-8248-cf8ab660e2ca.png",
          "name": "logo.png",
          "public": true,
          "type": "file",
          "url": "https://test.cloudfront.net/brands/assets/ef4d3310-5091-11f1-8248-cf8ab660e2ca.png",
          "preview_url": "https://test.cloudfront.net/brands/assets/ef4d3310-5091-11f1-8248-cf8ab660e2ca.png",
          "mime": "image/png"
        },
        "label": "Asset Label",
        "template_type": "Christmas",
        "medium": "Email",
        "branch": null,
        "type": "brand_asset"
      },
      "post_link": "http://test.com",
      "failed_at": null,
      "failure": null,
      "media_container_id": "test",
      "type": "social_post",
      "created_at": 1778872314.878779,
      "updated_at": 1778872314.878779,
      "deleted_at": null,
      "due_at": 1778871714.827,
      "executed_at": 1778872313.569376,
      "owner": {
        "type": "user",
        "username": null,
        "first_name": "Unit",
        "last_name": "Test",
        "email": "[email protected]",
        "phone_number": "+4368120265807",
        "created_at": 1493115498.770362,
        "id": "80a227b2-29a0-11e7-b636-e4a7a08e15d4",
        "address_id": null,
        "cover_image_url": null,
        "profile_image_url": null,
        "updated_at": 1493115498.770744,
        "user_status": "Active",
        "profile_image_thumbnail_url": null,
        "cover_image_thumbnail_url": null,
        "email_confirmed": true,
        "timezone": "America/Chicago",
        "user_type": "Admin",
        "deleted_at": null,
        "phone_confirmed": false,
        "is_shadow": false,
        "personal_room": null,
        "brand": null,
        "fake_email": false,
        "features": [
          "Deals"
        ],
        "last_seen_at": null,
        "email_signature": null,
        "daily_enabled": false,
        "email_quota": 30000,
        "website": null,
        "instagram": null,
        "twitter": null,
        "linkedin": null,
        "youtube": null,
        "facebook": null,
        "designation": null,
        "tiktok": null,
        "mfa_enabled": false,
        "xpressdocs_user_id": "80a227b2-29a0-11e7-b636-e4a7a08e15d4",
        "current_time": "2:11 PM - Friday May 15, 2026",
        "push_allowed": true,
        "agents": null,
        "last_seen_type": null,
        "active_brand": "0a46d74e-8d57-43f7-97c2-dde461be9cc3",
        "display_name": "Unit Test",
        "abbreviated_display_name": "Unit",
        "online_state": "Offline",
        "has_password": true
      }
    },
    {
      "id": "51861951-b930-416e-8220-c03c471cf796",
      "brand": "0a46d74e-8d57-43f7-97c2-dde461be9cc3",
      "created_by": "80a227b2-29a0-11e7-b636-e4a7a08e15d4",
      "caption": "this post should be failed in job",
      "facebook_page": "41c229c9-8edf-4183-8ea5-cb3f34fc0b89",
      "template_instance": {
        "id": "69920a37-6d20-4636-99ba-273c998cdf86",
        "created_at": 1778872313.569376,
        "html": "<div>fakeTemplateInstance</div>",
        "file": {
          "id": "d3eea496-eb5d-4da2-a117-0b7052cedffb",
          "created_at": 1778872314.636994,
          "updated_at": 1778872314.636994,
          "deleted_at": null,
          "created_by": "80a227b2-29a0-11e7-b636-e4a7a08e15d4",
          "path": "templates/instances/efa676a0-5091-11f1-8248-cf8ab660e2ca.png",
          "name": "image.png",
          "public": true,
          "type": "file",
          "url": "https://test.cloudfront.net/templates/instances/efa676a0-5091-11f1-8248-cf8ab660e2ca.png",
          "preview_url": "https://test.cloudfront.net/templates/instances/efa676a0-5091-11f1-8248-cf8ab660e2ca.png",
          "mime": "image/png"
        },
        "created_by": "80a227b2-29a0-11e7-b636-e4a7a08e15d4",
        "branch": "http://mock-branch-url",
        "updated_at": 1778872313.569376,
        "deleted_at": null,
        "type": "template_instance"
      },
      "asset": null,
      "post_link": null,
      "failed_at": "2026-05-15T19:11:53.569Z",
      "failure": "Internal Server Error",
      "media_container_id": "test",
      "type": "social_post",
      "created_at": 1778872314.93218,
      "updated_at": 1778872314.93218,
      "deleted_at": null,
      "due_at": 1778871714.89,
      "executed_at": 1778872313.569376,
      "owner": {
        "type": "user",
        "username": null,
        "first_name": "Unit",
        "last_name": "Test",
        "email": "[email protected]",
        "phone_number": "+4368120265807",
        "created_at": 1493115498.770362,
        "id": "80a227b2-29a0-11e7-b636-e4a7a08e15d4",
        "address_id": null,
        "cover_image_url": null,
        "profile_image_url": null,
        "updated_at": 1493115498.770744,
        "user_status": "Active",
        "profile_image_thumbnail_url": null,
        "cover_image_thumbnail_url": null,
        "email_confirmed": true,
        "timezone": "America/Chicago",
        "user_type": "Admin",
        "deleted_at": null,
        "phone_confirmed": false,
        "is_shadow": false,
        "personal_room": null,
        "brand": null,
        "fake_email": false,
        "features": [
          "Deals"
        ],
        "last_seen_at": null,
        "email_signature": null,
        "daily_enabled": false,
        "email_quota": 30000,
        "website": null,
        "instagram": null,
        "twitter": null,
        "linkedin": null,
        "youtube": null,
        "facebook": null,
        "designation": null,
        "tiktok": null,
        "mfa_enabled": false,
        "xpressdocs_user_id": "80a227b2-29a0-11e7-b636-e4a7a08e15d4",
        "current_time": "2:11 PM - Friday May 15, 2026",
        "push_allowed": true,
        "agents": null,
        "last_seen_type": null,
        "active_brand": "0a46d74e-8d57-43f7-97c2-dde461be9cc3",
        "display_name": "Unit Test",
        "abbreviated_display_name": "Unit",
        "online_state": "Offline",
        "has_password": true
      }
    }
  ],
  "info": {
    "count": 3,
    "total": 3
  }
}

Get Social posts stats of brand

Get Social posts stats of brand
GET/brands/:brand/social-posts/stats{?status}

brand (uuid) ID of the brand

user (uuid) ID of the user (optional)

status (‘executed’ | ‘scheduled’ | ‘draft’ | ‘any’) string (optional)

Example URI

GET /brands/:brand/social-posts/stats?status=executed
URI Parameters
HideShow
brand
string (required) Example: 0a46d74e-8d57-43f7-97c2-dde461be9cc3
status
string (required) Example: executed
Response  200
HideShow
Body
{
  "type": "social_post_stats",
  "Email": "1",
  "Social": "2"
}

Create a social post with templateInstance

Create a social post with templateInstance
POST/brands/:brand/social-posts

Example URI

POST /brands/:brand/social-posts
URI Parameters
HideShow
brand
string (required) Example: 0a46d74e-8d57-43f7-97c2-dde461be9cc3
associations
string (required) Example: social_post.template_instance,social_post.owner
Request
HideShow
Body
{
  "facebook_page": "a35882c3-343d-470e-a38c-d753893e2cf5",
  "template_instance": "69920a37-6d20-4636-99ba-273c998cdf86",
  "due_at": 1778871714.703,
  "caption": "test"
}
Response  200
HideShow
Body
{
  "code": "OK",
  "data": {
    "id": "6e78ee47-1982-46a8-b4e2-879cfd0262cb",
    "brand": "0a46d74e-8d57-43f7-97c2-dde461be9cc3",
    "created_by": "80a227b2-29a0-11e7-b636-e4a7a08e15d4",
    "caption": "test",
    "facebook_page": "a35882c3-343d-470e-a38c-d753893e2cf5",
    "template_instance": {
      "id": "69920a37-6d20-4636-99ba-273c998cdf86",
      "created_at": 1778872313.569376,
      "html": "<div>fakeTemplateInstance</div>",
      "file": {
        "id": "d3eea496-eb5d-4da2-a117-0b7052cedffb",
        "created_at": 1778872314.636994,
        "updated_at": 1778872314.636994,
        "deleted_at": null,
        "created_by": "80a227b2-29a0-11e7-b636-e4a7a08e15d4",
        "path": "templates/instances/efa676a0-5091-11f1-8248-cf8ab660e2ca.png",
        "name": "image.png",
        "public": true,
        "type": "file",
        "url": "https://test.cloudfront.net/templates/instances/efa676a0-5091-11f1-8248-cf8ab660e2ca.png",
        "preview_url": "https://test.cloudfront.net/templates/instances/efa676a0-5091-11f1-8248-cf8ab660e2ca.png",
        "mime": "image/png"
      },
      "created_by": "80a227b2-29a0-11e7-b636-e4a7a08e15d4",
      "branch": "http://mock-branch-url",
      "updated_at": 1778872313.569376,
      "deleted_at": null,
      "type": "template_instance"
    },
    "post_link": null,
    "failed_at": null,
    "failure": null,
    "media_container_id": null,
    "type": "social_post",
    "created_at": 1778872314.752521,
    "updated_at": 1778872314.752521,
    "deleted_at": null,
    "due_at": 1778871714.703,
    "executed_at": null,
    "owner": {
      "type": "user",
      "username": null,
      "first_name": "Unit",
      "last_name": "Test",
      "email": "[email protected]",
      "phone_number": "+4368120265807",
      "created_at": 1493115498.770362,
      "id": "80a227b2-29a0-11e7-b636-e4a7a08e15d4",
      "address_id": null,
      "cover_image_url": null,
      "profile_image_url": null,
      "updated_at": 1493115498.770744,
      "user_status": "Active",
      "profile_image_thumbnail_url": null,
      "cover_image_thumbnail_url": null,
      "email_confirmed": true,
      "timezone": "America/Chicago",
      "user_type": "Admin",
      "deleted_at": null,
      "phone_confirmed": false,
      "is_shadow": false,
      "personal_room": null,
      "brand": null,
      "fake_email": false,
      "features": [
        "Deals"
      ],
      "last_seen_at": null,
      "email_signature": null,
      "daily_enabled": false,
      "email_quota": 30000,
      "website": null,
      "instagram": null,
      "twitter": null,
      "linkedin": null,
      "youtube": null,
      "facebook": null,
      "designation": null,
      "tiktok": null,
      "mfa_enabled": false,
      "xpressdocs_user_id": "80a227b2-29a0-11e7-b636-e4a7a08e15d4",
      "current_time": "2:11 PM - Friday May 15, 2026",
      "push_allowed": true,
      "agents": null,
      "last_seen_type": null,
      "active_brand": "0a46d74e-8d57-43f7-97c2-dde461be9cc3",
      "display_name": "Unit Test",
      "abbreviated_display_name": "Unit",
      "online_state": "Offline",
      "has_password": true
    }
  }
}

Create a social post with asset

Create a social post with asset
POST/brands/:brand/social-posts

Example URI

POST /brands/:brand/social-posts
URI Parameters
HideShow
brand
string (required) Example: 0a46d74e-8d57-43f7-97c2-dde461be9cc3
Request
HideShow
Body
{
  "facebook_page": "a35882c3-343d-470e-a38c-d753893e2cf5",
  "asset": "0a5bcedf-4e86-4fac-b4b2-1d29ee91133b",
  "due_at": 1778871714.827,
  "caption": "testAsset"
}
Response  200
HideShow
Body
{
  "code": "OK",
  "data": {
    "id": "f879263f-d018-4b2f-8194-c2519163ae30",
    "brand": "0a46d74e-8d57-43f7-97c2-dde461be9cc3",
    "created_by": "80a227b2-29a0-11e7-b636-e4a7a08e15d4",
    "caption": "testAsset",
    "facebook_page": "a35882c3-343d-470e-a38c-d753893e2cf5",
    "post_link": null,
    "failed_at": null,
    "failure": null,
    "media_container_id": null,
    "type": "social_post",
    "created_at": 1778872314.878779,
    "updated_at": 1778872314.878779,
    "deleted_at": null,
    "due_at": 1778871714.827,
    "executed_at": null
  }
}

Update social post

Update social post
PUT/brands/:brand/social-posts/:socialPostId

Example URI

PUT /brands/:brand/social-posts/:socialPostId
URI Parameters
HideShow
brand
string (required) Example: 0a46d74e-8d57-43f7-97c2-dde461be9cc3
socialPostId
string (required) Example: e3998b6e-9b6e-42dc-b73b-71fd68c9dee0
Request
HideShow
Body
{
  "due_at": 1778872914.942,
  "template_instance": "69920a37-6d20-4636-99ba-273c998cdf86",
  "facebook_page": "41c229c9-8edf-4183-8ea5-cb3f34fc0b89",
  "asset": null,
  "caption": "test"
}
Response  200
HideShow
Body
{
  "code": "OK",
  "data": {
    "id": "e3998b6e-9b6e-42dc-b73b-71fd68c9dee0",
    "brand": "0a46d74e-8d57-43f7-97c2-dde461be9cc3",
    "created_by": "80a227b2-29a0-11e7-b636-e4a7a08e15d4",
    "caption": "test",
    "facebook_page": "41c229c9-8edf-4183-8ea5-cb3f34fc0b89",
    "post_link": null,
    "failed_at": null,
    "failure": null,
    "media_container_id": null,
    "type": "social_post",
    "created_at": 1778872314.821061,
    "updated_at": 1778872313.569376,
    "deleted_at": null,
    "due_at": 1778872914.942,
    "executed_at": null
  }
}

Delete a social post

Delete a social post
DELETE/brands/:brand/social-posts/:socialPostId

Example URI

DELETE /brands/:brand/social-posts/:socialPostId
URI Parameters
HideShow
brand
string (required) Example: 0a46d74e-8d57-43f7-97c2-dde461be9cc3
socialPostId
string (required) Example: 4577c77b-dbd2-4ad6-9828-b0bd1f2bf14b
Response  204

Generated by aglio on 15 May 2026