删除批处理配置
删除你客户账户拥有的 BatchConfiguration。此接口会移除该配置文档,并在 data 中返回被删除的文档。
如果 {id} 不存在或属于另一个客户账户,接口将返回 404(not_found)。删除配置不会执行查询,也不会消耗积分。
接口
DELETE https://api.verifik.co/v2/batch-configurations/{id}
也可以通过 Smart-Agent 代理 https://ai.verifik.co/v2/batch-configurations/{id} 访问,并使用你自己的客户专属 Authorization: Bearer <VERIFIK_JWT> 请求头。共享 x402 执行会被拒绝并返回 403 Forbidden。
请求头
| 名称 | 值 |
|---|---|
| Content-Type | application/json |
| Authorization | Bearer <VERIFIK_JWT> |
令牌必须是客户 JWT。缺少凭证或凭证无效将返回 401 Unauthorized。
参数
| 名称 | 类型 | 必填 | 描述 |
|---|---|---|---|
id | string | 是 | 要删除的 BatchConfiguration ObjectId。 |
请求示例
- Node.js
- PHP
- Python
- Go
- cURL
const fetch = require("node-fetch");
async function run() {
const id = "67d1b4a0e4f5a60718293b12";
const res = await fetch(`https://api.verifik.co/v2/batch-configurations/${id}`, {
method: "DELETE",
headers: {
"Content-Type": "application/json",
Authorization: `Bearer ${process.env.VERIFIK_JWT}`,
},
});
console.log(await res.json());
}
run();
<?php
$id = "67d1b4a0e4f5a60718293b12";
$ch = curl_init("https://api.verifik.co/v2/batch-configurations/" . $id);
curl_setopt($ch, CURLOPT_CUSTOMREQUEST, "DELETE");
curl_setopt($ch, CURLOPT_HTTPHEADER, [
"Content-Type: application/json",
"Authorization: Bearer " . getenv("VERIFIK_JWT")
]);
curl_setopt($ch, CURLOPT_RETURNTRANSFER, true);
$response = curl_exec($ch);
curl_close($ch);
echo $response;
import os
import requests
config_id = "67d1b4a0e4f5a60718293b12"
url = f"https://api.verifik.co/v2/batch-configurations/{config_id}"
headers = {
"Content-Type": "application/json",
"Authorization": f"Bearer {os.getenv('VERIFIK_JWT')}",
}
r = requests.delete(url, headers=headers)
print(r.json())
package main
import (
"encoding/json"
"fmt"
"net/http"
"os"
)
func main() {
id := "67d1b4a0e4f5a60718293b12"
req, _ := http.NewRequest("DELETE", "https://api.verifik.co/v2/batch-configurations/"+id, nil)
req.Header.Set("Content-Type", "application/json")
req.Header.Set("Authorization", "Bearer "+os.Getenv("VERIFIK_JWT"))
resp, _ := http.DefaultClient.Do(req)
defer resp.Body.Close()
var out map[string]interface{}
json.NewDecoder(resp.Body).Decode(&out)
fmt.Println(out)
}
curl -sS -X DELETE "https://api.verifik.co/v2/batch-configurations/67d1b4a0e4f5a60718293b12" \
-H "Content-Type: application/json" \
-H "Authorization: Bearer $VERIFIK_JWT"
响应示例
- 200
- 401
- 403
- 404
{
"data": {
"_id": "67d1b4a0e4f5a60718293b12",
"name": "Colombia Citizen Essential",
"description": "Core Colombian identity and registry verification for citizens.",
"country": "CO",
"executor": "browser",
"inputFormat": "csv",
"outputFormat": "csv",
"mergeStrategy": "sequential",
"preferredReportTemplate": "67d1b4a1e4f5a60718293b15",
"isActive": true,
"steps": [
{
"_id": "67d1b4a0e4f5a60718293b13",
"appFeature": "65f0a1b2c3d4e5f607182901",
"sequence": 1,
"enabled": true,
"parameterDefaults": {},
"queryMode": "byDocument",
"inputFieldMapping": {},
"outputFieldsToKeep": [],
"maxRetries": 3,
"retryDelayBaseSeconds": 4,
"timeoutSeconds": 30
}
],
"createdAt": "2026-10-15T14:20:00.000Z",
"updatedAt": "2026-10-15T14:20:00.000Z"
}
}
{
"message": "Unauthorized",
"code": "Unauthorized"
}
{
"message": "Access forbidden",
"code": "Forbidden"
}
{
"message": "not_found",
"code": "NotFound"
}
注意事项
- 删除配置会在
data中返回被删除的文档。随后使用同一{id}发起的GET、PUT或DELETE请求将不再找到该记录(GET返回data: null;GET /input-schema、PUT和DELETE返回404not_found)。 - 删除配置不会消耗积分。