Skip to content

armgit / letta

Public Imported from GitHub
0

Platform for stateful agents: AI with advanced memory that can learn and self-improve over time.

feat: add saveTemplateVersionNoProject endpoint (#9465)

Shubham Naik6579f9b906df
diff --git a/fern/openapi.json b/fern/openapi.json
index dc2e0072d..ec9fb6fc0 100644
--- a/fern/openapi.json
+++ b/fern/openapi.json
@@ -18517,6 +18517,129 @@
}
}
},
+ "/v1/templates/{template_name}/save": {
+ "post": {
+ "description": "Saves the current version of the template as a new version",
+ "summary": "Save template version (Cloud-only)",
+ "tags": ["templates"],
+ "parameters": [
+ {
+ "name": "template_name",
+ "in": "path",
+ "required": true,
+ "schema": {
+ "type": "string"
+ },
+ "description": "The template version, formatted as {template-name}, any version appended will be ignored"
+ }
+ ],
+ "operationId": "templates.saveTemplateVersionNoProject",
+ "requestBody": {
+ "description": "Body",
+ "content": {
+ "application/json": {
+ "schema": {
+ "type": "object",
+ "properties": {
+ "preserve_environment_variables_on_migration": {
+ "type": "boolean",
+ "description": "If true, the environment variables will be preserved in the template version when migrating agents"
+ },
+ "preserve_core_memories_on_migration": {
+ "type": "boolean",
+ "description": "If true, the core memories will be preserved in the template version when migrating agents"
+ },
+ "preserve_sources_on_migration": {
+ "type": "boolean",
+ "description": "If true, existing agent folders/sources will be preserved and merged with template sources during migration. If false, agent sources will be replaced with template sources."
+ },
+ "block_reconciliation_strategy": {
+ "type": "string",
+ "enum": ["reconcile-all", "preserve-deleted"],
+ "description": "Strategy for reconciling memory blocks during migration: \"reconcile-all\" deletes blocks not in the template, \"preserve-deleted\" keeps them. Defaults to \"preserve-deleted\"."
+ },
+ "migrate_agents": {
+ "type": "boolean",
+ "description": "If true, existing agents attached to this template will be migrated to the new template version"
+ },
+ "message": {
+ "type": "string",
+ "description": "A message to describe the changes made in this template version"
+ }
+ }
+ }
+ }
+ }
+ },
+ "responses": {
+ "200": {
+ "description": "200",
+ "content": {
+ "application/json": {
+ "schema": {
+ "type": "object",
+ "properties": {
+ "name": {
+ "type": "string",
+ "description": "The exact name of the template"
+ },
+ "id": {
+ "type": "string"
+ },
+ "project_id": {
+ "type": "string"
+ },
+ "project_slug": {
+ "type": "string"
+ },
+ "latest_version": {
+ "type": "string",
+ "description": "The latest version of the template"
+ },
+ "description": {
+ "type": "string"
+ },
+ "template_deployment_slug": {
+ "type": "string",
+ "description": "The full name of the template, including version and project slug"
+ },
+ "updated_at": {
+ "type": "string",
+ "description": "When the template was last updated"
+ }
+ },
+ "required": [
+ "name",
+ "id",
+ "project_id",
+ "project_slug",
+ "latest_version",
+ "template_deployment_slug",
+ "updated_at"
+ ]
+ }
+ }
+ }
+ },
+ "400": {
+ "description": "400",
+ "content": {
+ "application/json": {
+ "schema": {
+ "type": "object",
+ "properties": {
+ "message": {
+ "type": "string"
+ }
+ },
+ "required": ["message"]
+ }
+ }
+ }
+ }
+ }
+ }
+ },
"/v1/templates/{project_id}/{template_name}": {
"post": {
"description": "Saves the current version of the template as a new version",