Step 1. Seeders Configuration
Step 1: Configure Seeders
Section titled “Step 1: Configure Seeders”The first step in creating a new integration is defining its metadata, parameters, and resources in the database seeders. This registration allows the Gateway to recognize the integration and render its configuration UI dynamically.
1. Register Service
Section titled “1. Register Service”Add your new integration to database/seeders/ServicesSeeder.php. This defines the integration platform itself.
File: database/seeders/ServicesSeeder.php
[ 'name' => 'My E-com Platform', // Display name 'type' => 'myplatform', // Internal unique identifier (lowercase) 'logo' => 'logos/myplatform.png', // Logo path in storage 'oauth_required' => true, // Does it need OAuth flow? 'active' => true, 'description' => 'Connect your store to sync orders and inventory.', 'params' => [ // Configuration fields shown to the user [ 'name' => 'shop_url', 'type' => 'text', 'label' => 'Shop URL', 'placeholder' => 'https://your-shop.com', 'required' => true ], [ 'name' => 'api_key', 'type' => 'password', 'label' => 'API Key', 'required' => true ] ]]Parameter Types
Section titled “Parameter Types”The type field determines the UI component rendered in the frontend:
| Type | Description |
|---|---|
text | Standard text input |
password | Masked input for secrets |
number | Numeric input |
boolean | Checkbox toggle |
select | Dropdown (requires items array) |
multiselect | Multi-select dropdown (requires items array) |
2. Define Resources
Section titled “2. Define Resources”Register the actions available for your integration in database/seeders/AppServicesSeeder.php. These are the actual operations the integration can perform.
File: database/seeders/AppServicesSeeder.php
[ 'service_type' => 'myplatform', // Must match 'type' from ServicesSeeder 'resources' => [ [ 'name' => 'get_orders', 'label' => 'Import Orders', 'classes' => null, // Optional CSS classes 'schedulable' => true, // Can be run on a schedule? 'params' => [ [ 'name' => 'order_status', 'type' => 'multiselect', 'label' => 'Order Status to Import', 'default' => ['processing'], 'items' => [ ['value' => 'processing', 'label' => 'Processing'], ['value' => 'completed', 'label' => 'Completed'], ['value' => 'on-hold', 'label' => 'On Hold'] ] ] ] ], [ 'name' => 'update_tracking', 'label' => 'Update Tracking', 'schedulable' => true ], [ 'name' => 'sync_inventory', 'label' => 'Sync Inventory', 'schedulable' => true ] ]]Common Resources
Section titled “Common Resources”Standard resource names used across integrations:
get_orders: Fetch new ordersget_products: Import product catalogsync_inventory: Push stock levels to platformupdate_tracking: Push shipment tracking infoacknowledge_orders: specialized resource for some platforms
3. Apply Changes
Section titled “3. Apply Changes”After modifying the seeders, you must run them to update the database:
php artisan db:seed --class=ServicesSeederphp artisan db:seed --class=AppServicesSeeder[!WARNING] Seeders are idempotent (they update if exists, create if not), but be careful not to delete existing configurations if you modify the seeder logic itself.
Next Steps
Section titled “Next Steps”If your integration requires OAuth2 authentication (redirecting the user to approve access), proceed to Step 2: OAuth2 Setup. Otherwise, you can jump to Step 3: Integration Classes.