Last updated
Last updated
Create a local development environment for your North Commerce integration
Create a folder /wp-content/plugins/north-commerce-integration-boilerplate/
Clone the boilerplate from
Remove .git and .gitignore or modify them to your own needs
Change info.json
Replace {variables} to your own values. E.g plugin Name, last_updated, description, etc.
In your browser visit your-domain.local/wp-content/plugins/north-commerce-integration- boilerplate/integration-boilerplate-generator.php
Once the generator has ran rename the plugin folder north-commerce-integration-boilerplate
to north-commerce-{slug}
Remove the generator file from the project now that it is no longer needed /wp-content/plugins/north-commerce-shipstation/integration-boilerplate- generator.php
Modify the README.txt file and modify the plugin code to suit your needs for an integration
In the boilerplate plugin you will notice a few folders and files.
admin
- This folder contains files for the plugin's admin panel in WordPress
assets
- This folder contains css, js and image files for your integration
includes
- This folder contains plugin functionality files or "the business logic"
includes/integrations
- This folder contains examples and code to integrate with a required service. You will see examples with Shipstation
integration-boilerplate-generator.php
- This file is used to modify the initial plugin code according to your parameters from the info.json. It is needed only once at the beginning of plugin creation. Please dont forget to delete after running the generator from your browser.
info.json
- This files is required to initalize the plugin generator. This file also is necessary to specify plugin version anmd to update your plugin from a server in the future.
README.txt
- The plugin requires a standard README.txt
file containing the plugin description and version history
File: includes/integrations/class-north-commerce-webhooks.php
Designed to create webhooks for required Events in the "north-commerce" plugin
Reference implementation available at: north-commerce-addon-boilerplate/includes/integrations/class-north-commerce-webhooks.php
File: includes/integrations/class-north-commerce-plugin-rest-api.php
Creates new REST API endpoints for Event-triggered functionality
Reference implementation available at: north-commerce-addon-boilerplate/includes/integrations/class-north-commerce-plugin-rest-api.php
File: includes/integrations/class-north-commerce-send-order.php
Contains the core service integration code
Access the server via FTP using "north-commerce" credentials
Navigate to /var/convesio/wordpress/addons
Create a new folder with naming convention: north-commerce-{your-plugin-name}
Copy the following files to the folder:
info.json
(from plugin folder)
screenshot-1.jpg
(plugin screenshot)
north-commerce-slug.zip
(plugin archive excluding .git
, .gitignore
, etc.)
Navigate to north-commerce/admin/core/integration/placeholders/
Create a new placeholder class file following existing patterns
Set OPTIONAL_KEY = '{slug}_service'
Match existing placeholder implementations
Open north-commerce/admin/class-north-commerce-integration.php
Add new integration code block in define_integration_placeholders()
:
Deploy updated "north-commerce" plugin to Github
Update version number in main plugin file header:
Update info.json
:
Update version
field
Update last_updated
timestamp (format: "YYYY-MM-DD HH:MM:SS")
Add changelog entry
Push updated plugin to Github
Create plugin archive (excluding .git
, .gitignore
, etc.)
Upload via FTP:
Archive to /var/convesio/wordpress/addons/your-plugin/
Updated info.json
to same directory
The plugin update process utilizes three hooks in the main plugin file. Reference implementation available at: north-commerce-shipstation/north-commerce-shipstation.php
Always prefix plugin folders with north-commerce-
Maintain clean archives (exclude development files)
Follow version numbering convention (increment by 0.0.1)
Keep changelog entries descriptive and dated
Use our Integration Boilerplate Plugin to create an integration for North Commerce. There may be some cases where you will need to verify your integration with the North Commerce team.