Library Content Create
POST
/library/createThis Endpoint To Create Content in Library
Request
Body Params application/json
title
string
required
Title of content
type
string
required
type of content [Post,Hashtag]
currentActiveTab
enum<string>
optional
It is a active screen when request for draft post
Allowed values:
originalinstagrampinterestfacebooktwitterlinkedingmbyoutubetumblrtiktok
tags
array
optional
tags For This Content
posts
array [object {23}]
required
It contains post related fields like post content, post image,post title
type
string
optional
social media item type
postDesc
string
optional
post description
instagramPostType
string
optional
instagram post type default POST
comment
string
optional
It is comment on post
mediaId
array[string]
optional
altTexts
array [object {2}]
optional
carousel
array [object {3}]
optional
fbAudianceTargeting
object
optional
place
object
optional
linkedinAudianceTargeting
object
optional
action
object
optional
youtubePrivacy
string
optional
youtubeTags
array[string]
optional
videoCategory
string
optional
youtubeAllowEmbedding
boolean
optional
youtubeNotifySubscriber
boolean
optional
youtubeMadeForKids
boolean
optional
youtubeLicense
string
optional
adDetails
object
optional
previewImgUrl
string
optional
removeCarousel
boolean
optional
pinTitle
string
optional
destinationUrl
string
optional
Example
{
"enableShortUrl": true,
"posts": [
{
"type": "original",
"postDesc": "This is a draft Post",
"instagramPostType": "post",
"place": null,
"previewImgUrl": ""
},
{
"type": "facebook",
"postDesc": "This is a draft Post For FB ",
"instagramPostType": "post",
"place": null,
"comment": "",
"carousel": [
{
"mediaId": "6ebd8a60-6339-4425-b32b-682f83ecaf97",
"title": "img1",
"link": "https://www.socialpilot.co/",
"fbAction": ""
},
{
"mediaId": "e4fde3e2-9d72-4d1b-b4e2-f8185541a81f",
"title": "Img2",
"link": "https://www.socialpilot.co/",
"fbAction": ""
}
],
"mediaId": [
"6ebd8a60-6339-4425-b32b-682f83ecaf97",
"e4fde3e2-9d72-4d1b-b4e2-f8185541a81f"
],
"fbAudianceTargeting": {
"limitAudiance": null
},
"previewImgUrl": "https://awsstage-test.s3.amazonaws.com/103953/7315f4b4-7264-4f98-88a3-fc8d9ee4370d.jpeg"
},
{
"type": "twitter",
"postDesc": "This is a draft Post Twitter",
"instagramPostType": "post",
"place": {
"name": "London, England",
"id": "457b4814b4240d87"
},
"previewImgUrl": ""
},
{
"type": "linkedin",
"postDesc": "This is a draft Post Linkedin",
"instagramPostType": "post",
"place": null,
"comment": "",
"linkedinAudianceTargeting": null,
"previewImgUrl": ""
},
{
"type": "gmb",
"postDesc": "This is a draft Post for GBP",
"instagramPostType": "post",
"place": null,
"action": {
"cta": "",
"link": ""
},
"previewImgUrl": ""
},
{
"type": "instagram",
"postDesc": "This is a draft Post For IG",
"instagramPostType": "post",
"place": {
"name": "Rajkot, Gujarat",
"id": "110832712274056"
},
"comment": "",
"mediaId": [
"ab17d2fe-0bde-4314-818e-380ad72d4d67"
],
"removeCarousel": true,
"taggedPeople": {
"https://awsstage-test.s3.amazonaws.com/103953/43a3b0f8-29c7-4566-a8f0-fd653b7de9a0.gif": []
},
"previewImgUrl": "https://awsstage-test.s3.amazonaws.com/103953/43a3b0f8-29c7-4566-a8f0-fd653b7de9a0.gif"
},
{
"type": "youtube",
"postDesc": "This is a draft Post For YT",
"instagramPostType": "post",
"mediaId": [
"6b51d262-524e-4f82-8ec3-da12c0e78933"
],
"youtubePrivacy": "public",
"youtubeTags": [],
"postTitle": "Jules",
"videoCategory": "",
"youtubeAllowEmbedding": false,
"youtubeNotifySubscriber": false,
"youtubeMadeForKids": false,
"youtubeLicense": "youtube",
"previewImgUrl": ""
},
{
"type": "pinterest",
"postDesc": "This is a draft Post For Printerest",
"instagramPostType": "post",
"place": null,
"mediaId": [
"1a28579d-be4f-4dc8-a132-22ee4595008d"
],
"altTexts": [],
"removeCarousel": true,
"pinTitle": "Social Media Scheduling, Marketing and Analytics Tool | SocialPilotst",
"destinationUrl": "https://www.socialpilot.co/",
"previewImgUrl": "https://www.socialpilot.co/wp-content/uploads/2021/07/preview-image-new.png"
}
],
"currentActiveTab": "original"
}
Request samples
Responses
OK(200)
Bad Request(400)
Unauthorized(401)
Server Error(500)
HTTP Code: 200
Content Type : JSONapplication/json
Post created successfully.
Data Schema
message
string
optional
Your post has been saved as draft.
response
object
optional
id
string
optional
it's id of content geerated time of Content create
post
optional
Example
{
"message": "Post created successfully.",
"response": {
"id": "44432615-1626-4257-900e-c90ed2d1658d",
"post": {
"id": "44432615-1626-4257-900e-c90ed2d1658d",
"title": "Indian Cricket",
"content": {
"postDesc": "Post on India Cricket ",
"postTitle": "",
"postImage": [],
"postUrl": "",
"longPostDesc": "",
"postVideo": "",
"companyId": 103953,
"postType": "T",
"createdOn": "2023-07-04T05:41:06.794Z",
"extraData": {
"place": null,
"enableShortUrl": false,
"currentActiveTab": "original",
"original": {
"postDesc": "Post on India Cricket ",
"postTitle": "",
"postImage": [],
"postUrl": "",
"longPostDesc": "",
"postVideo": "",
"companyId": 103953,
"postType": "T",
"createdOn": "2023-07-04T05:41:06.794Z",
"extraData": {
"place": null,
"enableShortUrl": false
},
"ownerId": 103953,
"taggedPeople": {},
"utmSetId": "",
"utmParameters": {}
}
},
"ownerId": 103953,
"taggedPeople": {},
"utmSetId": "",
"utmParameters": {},
"boostExtraParams": {}
},
"type": "post",
"tags": [
"ckicket"
],
"accountId": [
0
],
"ownerId": 103953,
"createdBy": 103953,
"createdOn": "2023-07-04T05:41:06.794Z",
"lastEditedBy": 103953,
"lastEditedOn": "2023-07-04T05:41:06.794Z",
"lastUsed": "2023-07-04T05:41:06.794Z",
"totalUsed": 0,
"_id": "64a3b0f26f5d4d2c07eb6d04"
}
}
}
Last modified: 18 days ago