包信息
| 属性 | 值 |
|---|---|
| NuGet 包 | Bitzsoft.Integrations.Express.Kuaidi100 |
| Provider ID | kuaidi100 |
| 鉴权 | 授权码(Key)+ 顾客编码(Customer) |
| 能力 | 物流轨迹查询 + 订阅推送 |
配置字段(Kuaidi100Options)
| 字段 | 类型 | 必填 | 默认值 | 说明 |
|---|---|---|---|---|
Key | string | 是 | — | 授权码 |
Customer | string | 是 | — | 顾客编码 |
BaseUrl | string | 否 | https://poll.kuaidi100.com | API 基地址 |
HttpClientName | string | 否 | Kuaidi100Express | 命名 HttpClient |
配置示例
{ "Express": { "Kuaidi100": { "Key": "your-authorization-key", "Customer": "your-customer-code" } }}DI 注册
builder.Services.AddBitzsoftKuaidi100Express(builder.Configuration.GetSection("Express:Kuaidi100"));使用示例
public class Kuaidi100Service(IExpressProvider express){ public async Task<IReadOnlyList<ExpressTrackingInfo>> BatchTrackAsync(List<string> numbers) { return await express.BatchTrackAsync(numbers); }}已知限制
- 快递100的实时查询和订阅推送是不同的 API 端点,
Customer仅订阅接口需要。 - 面单生成等高级能力需快递100企业版授权。