Skip to main content
Templates

Archive a template

Archives a Forward template so that it is excluded from the active template list.

Request headers

HeaderRequiredDescription
AuthorizationYesBearer <PAT>
Idempotency-KeyNoAn optional idempotency key for requests that have side effects.

Path parameters

ParameterTypeRequiredDescription
template_idstringYesForward Template ID.

Example request

curl -s -X POST 'https://api.qoder.com.cn/api/v1/forward/templates/tmpl_support/archive' \
  -H "Authorization: Bearer $QODER_PAT"

Example response

HTTP 200 OK
{
  "type": "template",
  "id": "tmpl_support",
  "name": "Support assistant",
  "description": "Handles pre-sales and after-sales support",
  "status": "archived",
  "model": "ultimate",
  "system": "You are a helpful support assistant.",
  "tools": [],
  "mcp_servers": [],
  "skills": [],
  "multiagent": null,
  "environment_id": "env_support",
  "vault_ids": ["vault_crm"],
  "files": {},
  "environment_variables": {
    "BASE_MODE": "support"
  },
  "metadata": {},
  "created_at": "2026-06-18T10:00:00Z",
  "updated_at": "2026-06-18T10:30:00Z"
}

Response fields

Returns the archived template object with the status field set to archived.

Errors

HTTPTypeTrigger
401authentication_errorThe PAT is invalid or has expired.
404not_found_errorThe specified template does not exist or is not accessible to the caller.
409conflict_errorThe current template state does not allow archiving.

Notes

  • Archived templates are excluded from the active list by default.
  • Archiving does not delete historical sessions or configuration data.
Guides
Tutorials
API Reference