Installing the Mirakl Connector

    Requirements

    Installing and running the application requires the following:

    • PHP 7.1+
    • An SQL database, PostgreSQL recommended
    • A web server, Nginx recommended
    • A valid SSL/TLS certificate
    • Supervisord or equivalent to start the workers
    • Crontab or equivalent to run the jobs
    • Optional: a queuing mechanism, RabbitMQ recommended

    Install using Docker

    You can build and start the application by embedding it in a container. See our Docker sample for more information.

    Install manually

    1. Install Composer.
    2. Clone or download the Mirakl Connector from Github.
    3. Move the content to your web server directory, e.g. /var/www.
    4. Download dependencies:
    composer install --prefer-dist --no-dev
    1. Set environment variables using the file you created during the configuration.
    1. Run the migrations to set up the database:
    bin/console doctrine:migration:migrate --no-interaction

    If you encounter any errors at this stage, check that your environment variables are correctly set.

    1. Update your supervisor to automatically start and restart the workers.

    A configuration example is available in our Docker sample. You can skip this step in a development environment and start the workers manually when needed, for example:

    php bin/console messenger:consume operator_http_notification update_login_link process_transfers process_payouts process_refunds --time-limit=3600 --env=prod
    1. Add the following CRON commands using crontab -e (adapt the paths if needed):
    * * * * * php bin/console connector:sync:onboarding 5 2>&1 */5 * * * * php bin/console connector:dispatch:process-transfer 2>&1 0 1 * * * php bin/console connector:dispatch:process-payout 2>&1 0 8 * * * php bin/console connector:notify:failed-operation 2>&1
    1. Make sure that your web server is configured to use the public directory as document root.

    Check your installation

    Open your terminal and run the following command to confirm that your application is up and running correctly:

    curl -X GET "https://connector-url/api/mappings" \ -H "accept: application/json" \ -H "X-AUTH-TOKEN: <OPERATOR_PASSWORD>"

    You should get a 200 response code along with an empty payload.

    Security

    On your server, restrict all inbound traffic to the connector except for the following endpoints:

    /api/public/onboarding/create_mapping

    Stripe redirects the seller to this URL at the end of the onboarding to create the mapping between the Mirakl seller ID and their Stripe account ID within the connector.

    /api/public/webhook

    Stripe notifies this endpoint when Stripe Accounts are updated to synchronize the seller's status within the connector.

    These two endpoints are safe to expose, they each have an internal protection mechanism.
    Other endpoints are not safe to expose unless protected by a strong OPERATOR_PASSWORD.

    Next steps

    Was this page helpful?

    Feedback about this page?

    Thank you for helping improve Stripe's documentation. If you need help or have any questions, please consider contacting support.

    On this page