Skip to content
Switch branches/tags

Name already in use

A tag already exists with the provided branch name. Many Git commands accept both tag and branch names, so creating this branch may cause unexpected behavior. Are you sure you want to create this branch?
Go to file
Cannot retrieve contributors at this time

Custom Connector

It's very easy to add your own connector. In fact there are two services, two configuration classes and two form classes to define. To get started, you need register them first:

    ## Post Builder
    App\SocialData\Connector\MyConnectorType\Builder\SocialPostBuilder: ~

    ## Definition
            - {
                name: social_data.connector_definition,
                identifier: my_connector_type,
                socialPostBuilder: App\SocialData\Connector\MyConnectorType\Builder\SocialPostBuilder

Now you need to add them to the global register:

    social_post_data_class: SocialPost
        -   connector_name: my_connector_type

After that you're already able to add your connector in the configuration panel in backend.

Service Classes

Connector Definition

The Connector Definition presents all connector configuration. This class needs to implement the ConnectorDefinitionInterface.

Method Description
isOnline TBD
beforeEnable TBD
beforeDisable TBD
isAutoConnected TBD
isConnected TBD
connect TBD
disconnect TBD
needsEngineConfiguration TBD
getEngineConfigurationClass TBD
getFeedConfigurationClass TBD
getEngineConfiguration TBD

Configuration Classes

The Configuration Classes presents all connector configuration. You need two of them: The Engine configuration and Feed configuration class.

Engine Configuration

The engine configuration class needs to implement the ConnectorEngineConfigurationInterface.

Required Methods Description
static function getFormClass Returns the configuration form type
Feed Configuration

THe feed configuration class needs to implement the ConnectorFeedConfigurationInterface.

Required Methods Description
static function getFormClass Returns the configuration form type

Social Post Builder

The social post builder class needs to implement the SocialPostBuilderInterface.

Method Description
configureFetch TBD
fetch TBD
configureFilter TBD
filter TBD
configureTransform TBD
transform TBD