Manage external data for products. GET retrieves data with filtering. POST performs UPSERT using (dataid, name) as composite key: if record exists → UPDATE with new value, if not → INSERT new record. PUT updates by record ID.
HTTP: GET | POST | PUT /external-data
| Name | Type | Required | Description | Example |
|---|---|---|---|---|
| limit | integer | no | Maximum rows per page (default 100). | 50 |
| page | integer | no | 1-indexed page when limit is provided. | 1 |
| offset | integer | no | Explicit row offset. | 0 |
| dataid | string | no | Filter by product ID. Required for POST/PUT. | 24 |
| name | string | no | Filter by or specify data name. Required for POST/PUT. | competitor_price |
| val | string | no | Data value. Required for POST/PUT. | 299.90 |
| datum | string | no | Timestamp for the data (defaults to now for POST). | 2025-10-16 12:00:00 |
| id | integer | no | ID of specific record to update (PUT only). | 123 |
| sort | string | no | Sort column (id, datum, dataid, name). | datum |
| direction | string | no | Sort direction asc or desc. | desc |
curl -H "Authorization: ApiKey YOUR_API_KEY" "https://admin.elpricing.com/api/external-data"
Tasks are persisted to var/api_queue/tasks.json. Process them with:
php go.php cron:list\nphp go.php cron:go
Logs are written to var/api_queue/logs/{task_id}.log.