Connector - Email to Post

"Email to post" functionality provides the ability to post in HiveSocial automatically. Emails that needs to be posted, are sent to a predefined mailbox. The system checks them, if they are sent from emails that belong to registered accounts and if they have the permission to post. If this is the case, the email subject is posted as post title, the email body - as post content.

Method: get

Authorization is required.

Request

HTTP request

GET https://<YOUR_DOMAIN>/api/v1/en_US/connector/email-to-post/{groupId}

Parameters

property value description
groupId guid The group ID for which you want to review the Email to Post settings.

Request body

Do not supply a request body with this method.

Response

If successful, this method returns a response JSON with the following structure:

{
  "success": true,
  "message": "Nisi proident tempor cillum sint duis eu elit dolor Lorem amet qui officia occaecat.",
  "timestamp": "2014-03-03T23:20:23Z",
  "errors": [],
  "object": {
    "type": "connectorEmailToPost",
    "group": {
      "id": "e532e792-4101-4ef5-8cd7-68380bbbc703",
      "name": "home",
      "slug": "Home",
      "thumbUrl": "http://demo.hivesocialnow.com/logo/72_635267855582630000.png",
      "url": "http://demo.hivesocialnow.com/Home/"
    },
    "serverName": "pop.mydomain.com",
    "serverPort": 25,
    "serverUsername": "joe@joe.com",
    "serverPassword": "password",
    "isEnabled": true,
    "isSSL": false,
    "deleteProcessed": true,
    "lastProcessed": "2014-03-03T23:20:23Z",
    "accessWarnings": []
  }
}

The general response properties are described on the Response format page. Here are the list of the specific properties for this method.

property value description
group object some common properties of the group in which the record was created: id, name, slug, thumbUrl, url (of the group home page)
serverName string URL and address of the POP3 server
serverPort integer The pop3 server post
serverUsername string the pop3 access account username
serverPassword string the pop3 access account password
isEnabled boolean is this connector enabled
isSSL boolean whether the use of SSL protocol is required by the email server.
deleteProcessed boolean whether to clear the processed emails from the mailbox
lastProcessed date when the operation was last run by the system in UTC time zone

Method: update

Authorization is required.

Request

HTTP request

PUT https://<YOUR_DOMAIN>/api/v1/en_US/connector/email-to-post/{groupId}

Parameters

property value description
groupId guid The group ID for which you want to review the Email to Post settings.

Request body

property value description
serverName string URL and address of the POP3 server
serverPort integer The pop3 server post
serverUsername string the pop3 access account username
serverPassword string the pop3 access account password
isEnabled boolean is this connector enabled
isSSL boolean whether the use of SSL protocol is required by the email server.
deleteProcessed boolean whether to clear the processed emails from the mailbox

Response

If successful, this method returns a response JSON with the following structure:

{
  "timestamp": "2014-03-03T23:20:23Z",
  "success": true,
  "message": "Aliqua anim consequat amet cupidatat proident amet amet.",
  "errors": [
    {
      "key": "serverName",
      "value": "",
      "message": "Name cannot be blank"
    }
  ],
  "object": {
    "type": "connectorEmailToPost",
    "group": {
      "id": "e532e792-4101-4ef5-8cd7-68380bbbc703",
      "name": "home",
      "slug": "Home",
      "thumbUrl": "http://demo.hivesocialnow.com/logo/72_635267855582630000.png",
      "url": "http://demo.hivesocialnow.com/Home/"
    },
    "serverName": "pop.mydomain.com11",
    "serverPort": 25,
    "serverUsername": "joe@joe.com",
    "serverPassword": "password",
    "isEnabled": false,
    "isSSL": false,
    "deleteProcessed": true,
    "lastProcessed": "2014-03-03T23:20:23Z",
    "accessWarnings": []
  }
}

The general response properties are described on the Response format page. Here are the list of the specific properties for this method.

property value description
success Boolean Whether the requested operation is successful or not
message String Human readable error information
errors List (object) List of validation errors, if any. The "key" property value is matched to one of the record's fields
object object The object that caused the validation errors or that was updated. Have in mind that, if the server requires string trimming or data manipulation after the user submission, it is applied in this object. In this way the returned object can differe from the posted one.