Files
2026-09-15 10:35:56 +08:00

31 lines
1.1 KiB
PHP

<?php
declare(strict_types=1);
namespace Esun\LingxingErp\Model\Api;
class Endpoint
{
public const STORE_LIST = '/pb/mp/shop/v2/getSellerList';
public const ORDER_CREATE = '/pb/mp/order/v2/create';
public const ORDER_LIST = '/pb/mp/order/v2/list';
public const PAIR_LIST = '/pb/mp/listing/v2/getPairList';
public const WMS_ORDER_LIST = '/erp/sc/routing/wms/order/wmsOrderList';
public const WAREHOUSE_LIST = '/erp/sc/data/local_inventory/warehouse';
public const INVENTORY_DETAILS = '/erp/sc/routing/data/local_inventory/inventoryDetails';
private const BY_OPERATION = [
'store_sync' => self::STORE_LIST,
'order_create' => self::ORDER_CREATE,
'sku_pair_lookup' => self::PAIR_LIST,
'shipment_pull' => self::WMS_ORDER_LIST,
'warehouse_sync' => self::WAREHOUSE_LIST,
'inventory_pull' => self::INVENTORY_DETAILS,
'inventory_sync' => self::INVENTORY_DETAILS,
];
public static function forOperation(string $operation): string
{
return self::BY_OPERATION[$operation] ?? '';
}
}