> ## Documentation Index
> Fetch the complete documentation index at: https://docs.scanova.io/llms.txt
> Use this file to discover all available pages before exploring further.

# 列出用户设计模板

> GET /qr-assets/design-template/

在 **Management API** 主机（`api.scanova.io`）上列出账户自己针对某个 QR 分类或表单的设计模板，使用您的原始 Management API 密钥进行身份验证。

```
GET https://api.scanova.io/qr-assets/design-template/
Authorization: 401f7ac837da42b97f613d789819ff93537bee6a
```

<ParamField query="resource_type" type="string" default="qr_category">
  `qr_category` 或 `form`。
</ParamField>

<ParamField query="category_id" type="integer">
  当 `resource_type` 为 `qr_category`（默认值）时**必填**。当 `resource_type` 为 `form` 时**必须省略**。
</ParamField>

<RequestExample>
  ```bash cURL theme={null}
  curl "https://api.scanova.io/qr-assets/design-template/?resource_type=qr_category&category_id=3" \
    -H "Authorization: 401f7ac837da42b97f613d789819ff93537bee6a"
  ```
</RequestExample>

<ResponseExample>
  ```json 200 theme={null}
  {
    "count": 1,
    "next": null,
    "previous": null,
    "results": [
      {
        "id": 9,
        "name": "Blue Gradient",
        "resource_type": "qr_category",
        "category": 3,
        "design_info": { "bg": "#0033ff" },
        "gradient_type": "linear",
        "color_palette": "[\"#000\",\"#fff\"]",
        "font_styles": null,
        "is_template": true,
        "info": null,
        "template_id": "abc123"
      }
    ]
  }
  ```
</ResponseExample>

如果 `resource_type=qr_category` 时缺少 `category_id`、`resource_type=form` 时存在 `category_id`，或 `resource_type` 既不是 `qr_category` 也不是 `form`，则返回 `400`。

## 相关内容

* [创建用户设计模板](/zh/api-reference/management-api/qr-assets/design-template-create)——保存一个新模板。
* [更新用户设计模板](/zh/api-reference/management-api/qr-assets/design-template-update)——编辑现有模板。
* [删除用户设计模板](/zh/api-reference/management-api/qr-assets/design-template-delete)——删除一个模板。
* [Management API 概览](/zh/api-reference/management-api/overview)——适用于此端点的身份验证方案和配额规则。


## OpenAPI

````yaml api-reference/openapi/management-api.json GET /qr-assets/design-template/
openapi: 3.1.0
info:
  title: Scanova Management API (v2)
  description: >-
    The complete Scanova Management API — every endpoint available at
    api.scanova.io (QR codes, folders, tags, leads, forms, analytics, plans,
    shared users & roles), plus the token-creation and usage-stats endpoints
    used to authenticate against it. Every path and request/response shape below
    was verified live against a real API key and the actual running backend
    (Phase 7, 2026-08-16) — not guessed from reading urls.py alone.
  version: 2.0.0
servers:
  - url: https://api.scanova.io
    description: Management API — QR/folder/tag/lead/form/analytics/plans endpoints
security:
  - apiKeyAuth: []
paths:
  /qr-assets/design-template/:
    get:
      summary: List user design templates
      description: >-
        `resource_type` defaults to `qr_category`, in which case `category_id`
        is required. For `resource_type=form`, `category_id` must be omitted.
      operationId: listUserDesignTemplates
      parameters:
        - name: resource_type
          in: query
          required: false
          schema:
            type: string
            enum:
              - qr_category
              - form
            default: qr_category
        - name: category_id
          in: query
          required: false
          schema:
            type: integer
          description: >-
            Required when resource_type=qr_category; forbidden when
            resource_type=form.
      responses:
        '200':
          description: Paginated list of design templates.
          content:
            application/json:
              example:
                count: 1
                next: null
                previous: null
                results:
                  - id: 9
                    name: Blue Gradient
                    resource_type: qr_category
                    category: 3
                    design_info:
                      bg: '#0033ff'
                    gradient_type: linear
                    color_palette: '["#000","#fff"]'
                    font_styles: null
                    is_template: true
                    info: null
                    template_id: abc123
        '400':
          description: >-
            Missing category_id for resource_type=qr_category, category_id
            present for resource_type=form, or an invalid resource_type value.
components:
  securitySchemes:
    apiKeyAuth:
      type: apiKey
      in: header
      name: Authorization
      description: >-
        Send your Management API key as the raw value of the Authorization
        header — no "Bearer " or "Token " prefix, and no other characters.
        Example: `Authorization: 401f7ac837da42b97f613d789819ff93537bee6a`. A
        header containing more than one space-separated part is rejected
        outright. Requests also require the request's Host header to be the
        management API host (e.g. api.scanova.io) — the same key sent to the
        regular API host will not authenticate.

````