Every wholesale data source in API-HUB is represented by a supplier record. Creating one takes less than five minutes if you have the supplier’s credentials ready. This guide covers the full flow from initial form entry through your first catalog import, using both the admin UI and the REST API.Documentation Index
Fetch the complete documentation index at: https://mintlify.com/VisualGraphxLLC/API-HUB/llms.txt
Use this file to discover all available pages before exploring further.
Prerequisites
Before you start, have the following at hand:- The supplier’s protocol (
promostandardsorrest_hmac) - For PromoStandards suppliers: the supplier’s PS code (e.g.
SANMAR,PCNA) - For REST suppliers: the base URL and API credentials (
api_key/private_key) - The correct adapter class name (see Adapter overview)
Step-by-step guide
Open the Suppliers page
Navigate to Suppliers in the left sidebar. Click Add Supplier in the top-right corner. A form panel slides open.
Fill in the supplier fields
Complete each field:
| Field | What to enter |
|---|---|
| Name | Display name shown throughout the UI (e.g. SanMar) |
| Slug | URL-safe unique key, auto-generated from the name |
| Protocol | promostandards for SOAP suppliers; rest_hmac for 4Over-style |
| PromoStandards code | The supplier’s PS directory code (PS suppliers only) |
| Base URL | Root endpoint for REST suppliers; leave blank for PS suppliers |
| Adapter class | Registry key: PromoStandardsAdapter, SanMarAdapter, FourOverAdapter, or OPSAdapter |
The slug must be unique across all suppliers. If you try to create a second record with the same slug, the API performs an upsert — updating credentials and setting
is_active: true on the existing record instead of raising a conflict error.Enter credentials
Expand the Auth config section. Credentials are stored as encrypted JSON (AES-128 via Fernet) and never appear in plaintext in the database.
- PromoStandards
- 4Over (REST + HMAC)
- SanMar (extended auth)
Set protocol config (optional)
Use This field is stored as plain JSONB (not encrypted), so do not put credentials here.
protocol_config for non-sensitive settings that the adapter reads at runtime. For example, to pin an explicit list of product IDs for a FILTERED_SAMPLE import:Test the connection
Click Test connection before saving. The UI calls What the test does:A failure returns:
POST /api/suppliers/test with the form data you have entered.- For
promostandardssuppliers: looks up the PS code in the live PS directory (994+ registered companies). Returnsok: trueif the code is found. - For
rest_hmacsuppliers: validates thatauth_config.idandauth_config.passwordare present in the payload.
Create the supplier
Click Save. The UI posts to Response (
POST /api/suppliers. The server returns HTTP 201 with the new supplier record including its generated UUID.You can also create a supplier directly from the API:201 Created):Activate the supplier
New suppliers are active by default when You can use either the UUID or the slug in the path. Only patchable fields are accepted:
is_active: true is passed at creation. If you created the record as inactive, patch it:name, protocol, promostandards_code, base_url, adapter_class, auth_config, field_mappings, is_active, protocol_config.Trigger a first import
Before scheduling a full sync, run a small test import to verify credentials and data shape. Use The endpoint returns Track progress by polling the sync jobs list:
mode=first_n with limit=5 to fetch only the first five products:HTTP 202 Accepted immediately. The import runs in a background task.Updating an existing supplier
UsePATCH /api/suppliers/{id_or_slug} to change any patchable field without affecting others. Partial updates are safe — only the keys you include are modified.
Deactivating and deleting
Deactivating a supplier
Deactivating a supplier
Set
is_active: false to suspend all scheduled sync jobs without removing any data. The supplier record and its full catalog remain intact. Reactivate by patching is_active: true.Deleting a supplier
Deleting a supplier
DELETE /api/suppliers/{id_or_slug} removes the supplier record and permanently deletes all associated products, variants, images, categories, and sync job history. There is no soft-delete or undo.