Social Accounts

Add a social account

This API gives you access to adding a social account to your workspace.

Steps of filling credentials object:

  1. Make an API call to this.

  2. You'll get a list of all authVariables, every object in that array will contain keyname

  3. You'll use the value of name key, as a key in credentials object, then credentials object will look like this

"credentials": {
    "csrf-token": "<value>"
}

Steps of filling platform object:

  1. Use platformId for the value of id, use this for getting platformId

  2. userId will be the unique identifier of the user for that platform

  3. picture will be the profile picture URL

post
Authorizations
Header parameters
X-TexAu-ContextstringRequired

Pass orgUserId and workspaceId as ‘{"orgUserId":"123","workspaceId":"123"}’

Body
namestringRequired
latitudestringOptional
longitudestringOptional
variablesobjectRequired
credentialsobjectRequired
Responses
201
Account connected successfully
application/json
post
POST /api/v1/public/social-accounts HTTP/1.1
Host: 
Authorization: Bearer JWT
X-TexAu-Context: text
Content-Type: application/json
Accept: */*
Content-Length: 174

{
  "name": "text",
  "platform": {
    "id": "text",
    "userId": "text",
    "picture": "text",
    "location": "text",
    "metadata": {}
  },
  "latitude": "text",
  "longitude": "text",
  "variables": {},
  "credentials": {}
}
{
  "success": true,
  "message": "Account connected successfully",
  "data": {
    "id": "The social account ID",
    "name": "The social account name",
    "readyToUse": true
  }
}

Get All social accounts

This API will return all social accounts of a workspace

Get social account by ID

This API will give you social account details by its ID

get
Authorizations
Path parameters
accountIdstringRequired
Header parameters
X-TexAu-ContextstringRequired

Pass orgUserId and workspaceId as ‘{"orgUserId":"123","workspaceId":"123"}’

Responses
200
Account fetched successfully
application/json
get
GET /api/v1/public/social-accounts/{accountId} HTTP/1.1
Host: 
Authorization: Bearer JWT
X-TexAu-Context: text
Accept: */*
{
  "success": true,
  "message": "Account fetched successfully",
  "data": {
    "id": "Social Account ID",
    "socialAccountName": "Alex Jordan",
    "platformName": "Linkedin",
    "platformId": "6745retfderty6",
    "credentials": {},
    "proxyId": "6745retfderty6",
    "variables": {
      "key": "value"
    },
    "limits": {
      "platformOperationsId": [
        {
          "limit": "100",
          "interval": "daily | hourly"
        }
      ]
    },
    "credentialsIsExpired": false,
    "proxyIsExpired": false,
    "platformUserId": "https://www.linkedin.com/in/prathmesh-kumar-saini/",
    "readyToUse": false
  }
}

Update a social account

This API will be used for updating the credential or proxy

put
Authorizations
Path parameters
accountIdstringRequired
Header parameters
X-TexAu-ContextstringRequired

Pass orgUserId and workspaceId as ‘{"orgUserId":"123","workspaceId":"123"}’

Body
credentialsobjectOptional
variablesobjectOptional
namestringOptional
proxyIdstringOptional
latitudestringOptional
longitudestringOptional
Responses
200
Account updated successfully
application/json
put
PUT /api/v1/public/social-accounts/{accountId} HTTP/1.1
Host: 
Authorization: Bearer JWT
X-TexAu-Context: text
Content-Type: application/json
Accept: */*
Content-Length: 101

{
  "credentials": {},
  "variables": {},
  "name": "text",
  "proxyId": "text",
  "latitude": "text",
  "longitude": "text"
}
{
  "success": true,
  "message": "Account updated successfully",
  "data": {
    "id": "The social account ID",
    "name": "The social account name",
    "readyToUse": true
  }
}

Assign proxy to a social account

Use this API to assign a proxy to a social account and get proxyId from this API.

Always use a proxy with a social account.

put
Authorizations
Path parameters
accountIdstringRequired
Header parameters
X-TexAu-ContextstringRequired

Pass orgUserId and workspaceId as ‘{"orgUserId":"123","workspaceId":"123"}’

Body
proxyIdstringRequired
Responses
200
Proxy assigned successfully
application/json
put
PUT /api/v1/public/social-accounts/{accountId}/proxy HTTP/1.1
Host: 
Authorization: Bearer JWT
X-TexAu-Context: text
Content-Type: application/json
Accept: */*
Content-Length: 18

{
  "proxyId": "text"
}
{
  "success": true,
  "message": "Proxy assigned successfully",
  "data": {
    "socialAccountId": "The social account ID",
    "proxyId": "The proxy ID"
  }
}

Remove proxy from a social account

Use this API to remove the proxy from the social account.

delete
Authorizations
Path parameters
accountIdstringRequired
Header parameters
X-TexAu-ContextstringRequired

Pass orgUserId and workspaceId as ‘{"orgUserId":"123","workspaceId":"123"}’

Responses
200
Proxy removed successfully from this account
application/json
delete
DELETE /api/v1/public/social-accounts/{accountId}/proxy HTTP/1.1
Host: 
Authorization: Bearer JWT
X-TexAu-Context: text
Accept: */*
{
  "success": true,
  "message": "Proxy removed successfully from this account"
}

Reset proxy of a social account.

This API will reset only the factory proxy not the user proxy of a social account.

Set limit

Use this API to set automation limits for the specific social account

put
Authorizations
Path parameters
accountIdstringRequired
Header parameters
X-TexAu-ContextstringRequired

Pass orgUserId and workspaceId as ‘{"orgUserId":"123","workspaceId":"123"}’

Body
operationIdstringRequired
Responses
200
Account limit updated successfully
application/json
put
PUT /api/v1/public/social-accounts/{accountId}/limit HTTP/1.1
Host: 
Authorization: Bearer JWT
X-TexAu-Context: text
Content-Type: application/json
Accept: */*
Content-Length: 78

{
  "operationId": "text",
  "executionLimit": [
    {
      "limit": "1000",
      "interval": "hourly"
    }
  ]
}
{
  "success": true,
  "message": "message",
  "data": {
    "socialAccountId": "The social account ID"
  }
}

Reset Limit to default (Delete limit)

Use this API to reset the limit of automation to default one (delete the limit at the account level)

delete
Authorizations
Path parameters
accountIdstringRequired
Header parameters
X-TexAu-ContextstringRequired

Pass orgUserId and workspaceId as ‘{"orgUserId":"123","workspaceId":"123"}’

Body
operationIdstringRequired
Responses
200
Account limit deleted successfully
application/json
delete
DELETE /api/v1/public/social-accounts/{accountId}/limit HTTP/1.1
Host: 
Authorization: Bearer JWT
X-TexAu-Context: text
Content-Type: application/json
Accept: */*
Content-Length: 22

{
  "operationId": "text"
}
{
  "success": true,
  "message": "message",
  "data": {
    "socialAccountId": "The social account ID"
  }
}

Delete a social account

delete
Authorizations
Path parameters
accountIdstringRequired
Header parameters
X-TexAu-ContextstringRequired

Pass orgUserId and workspaceId as ‘{"orgUserId":"123","workspaceId":"123"}’

Responses
200
Account deleted successfully
application/json
delete
DELETE /api/v1/public/social-accounts/{accountId} HTTP/1.1
Host: 
Authorization: Bearer JWT
X-TexAu-Context: text
Accept: */*
{
  "success": true,
  "message": "Account deleted successfully",
  "data": {
    "id": "The social account ID",
    "name": "The social account name",
    "readyToUse": true
  }
}

Force Delete a social account

This endpoint is being used when a social account is used in running workflow, and user wish to force delete it.

delete
Authorizations
Path parameters
accountIdstringRequired
Header parameters
X-TexAu-ContextstringRequired

Pass orgUserId and workspaceId as ‘{"orgUserId":"123","workspaceId":"123"}’

Responses
200
Account deleted successfully
application/json
delete
DELETE /api/v1/public/social-accounts/{accountId}/force HTTP/1.1
Host: 
Authorization: Bearer JWT
X-TexAu-Context: text
Accept: */*
{
  "success": true,
  "message": "Account deleted successfully",
  "data": {
    "id": "The social account ID",
    "name": "The social account name",
    "readyToUse": true
  }
}

Last updated