---
updatedAt: 2026-08-07T02:26:04.000Z
agentTools:
  projectIndex: https://developer.qbitnetwork.com/llms.txt
---

# 批量创建预打印卡

# OpenAPI definition

```json
{
  "openapi": "3.0.1",
  "info": {
    "title": "量子卡",
    "description": "接口开发者文档",
    "version": "v3"
  },
  "externalDocs": {
    "description": "接口开发者",
    "url": "https://developer.qbitnetwork.com/"
  },
  "servers": [
    {
      "url": "https://api-sandbox.qbitnetwork.com",
      "description": "沙箱环境"
    }
  ],
  "paths": {
    "/open-api/v3/preprint-cards": {
      "post": {
        "tags": [
          "卡"
        ],
        "summary": "批量创建预打印卡",
        "operationId": "batchCreatePrePrintCard",
        "parameters": [
          {
            "name": "Idempotency-Key",
            "in": "header",
            "description": "幂等键（UUID），用于保证变更类请求精准一次执行。",
            "required": true,
            "schema": {
              "type": "string"
            }
          }
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/CreatePerPrintCardReqDTO"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/BatchCardRespDTO"
                },
                "example": {
                  "code": "000000",
                  "message": "success",
                  "data": {
                    "batchNumber": "3e7f9d2b-4a5c-8e1b-2d5f-7a9b4c6d1e3f",
                    "taskId": "4874986465454854985f"
                  }
                }
              }
            }
          },
          "400": {
            "description": "Bad Request",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ErrorResult"
                },
                "example": {
                  "code": "40001",
                  "message": "Invalid parameter"
                }
              }
            }
          }
        },
        "security": [
          {
            "ApiKeyAuth": []
          }
        ]
      }
    }
  },
  "components": {
    "schemas": {
      "ErrorResult": {
        "type": "object",
        "properties": {
          "code": {
            "type": "string",
            "description": "错误码",
            "example": "400001"
          },
          "message": {
            "type": "string",
            "description": "错误信息",
            "example": "参数无效"
          }
        }
      },
      "BatchCard": {
        "required": [
          "batchNumber",
          "taskId"
        ],
        "type": "object",
        "properties": {
          "batchNumber": {
            "type": "string",
            "description": "批次号"
          },
          "taskId": {
            "type": "string",
            "description": "任务Id"
          }
        }
      },
      "BatchCardRespDTO": {
        "required": [
          "data"
        ],
        "type": "object",
        "properties": {
          "code": {
            "type": "string",
            "description": "错误码",
            "example": "400001"
          },
          "message": {
            "type": "string",
            "description": "错误信息",
            "example": "参数无效"
          },
          "data": {
            "$ref": "#/components/schemas/BatchCard"
          }
        }
      },
      "CreatePerPrintCardReqDTO": {
        "title": "创建预打印卡",
        "required": [
          "accountId",
          "binId",
          "cardMode",
          "quantity"
        ],
        "type": "object",
        "properties": {
          "accountId": {
            "type": "string",
            "description": "账户UUID",
            "format": "uuid"
          },
          "binId": {
            "type": "string",
            "description": "卡BIN的ID"
          },
          "cardMode": {
            "type": "string",
            "description": "卡模式。默认: PHYSICAL_CARD",
            "enum": [
              "PHYSICAL_CARD",
              "VIRTUAL_CARD"
            ]
          },
          "quantity": {
            "minimum": 1,
            "type": "integer",
            "description": "创建卡片数量。最小: 1",
            "format": "int32"
          },
          "label": {
            "type": "string",
            "description": "自定义卡标签或备注"
          },
          "physicalCardDesignId": {
            "type": "string",
            "description": "实体卡设计ID"
          },
          "budgetId": {
            "type": "string",
            "description": "预算UUID"
          }
        },
        "description": "创建预打印卡"
      }
    },
    "securitySchemes": {
      "ApiKeyAuth": {
        "type": "apiKey",
        "description": "API密钥",
        "name": "x-access-token",
        "in": "header"
      }
    }
  }
}
```