LangChain Reference home pageLangChain ReferenceLangChain Reference
  • GitHub
  • Main Docs
Deep Agents
LangChain
LangGraph
Integrations
LangSmith
  • Overview
  • Agent
  • Middleware
  • Backends
  • Sandboxes
  • Skills
  • Subagents
  • Types
Modal
Daytona
Deno
Node VFS
Sandbox Standard Tests
  • Vitest
⌘I

Chat LangChain

What can I help with?

Enter to send·Shift+Enter new line

Menu

OverviewAgentMiddlewareBackendsSandboxesSkillsSubagentsTypes
Modal
Daytona
Deno
Node VFS
Sandbox Standard Tests
Vitest
Language
Theme
JavaScriptdeepagentsprofilesserializeProfile
Function●Since v1.16

serializeProfile

Serialize a HarnessProfile to a JSON-compatible object.

Omits undefined fields and extraMiddleware (runtime-only). Throws if extraMiddleware contains instances — callers should strip it before serializing if they've set it.

Copy
serializeProfile(profile: HarnessProfile): __type

Parameters

NameTypeDescription
profile*HarnessProfile

The profile to serialize.

View source on GitHub