Branch from the latest message
POST
/conversation/fork
const url = 'https://api.harperharbor.com/open/v1/conversation/fork';const options = { method: 'POST', headers: {Authorization: 'Bearer <token>', 'Content-Type': 'application/json'}, body: '{"conversationId":"example","title":"example"}'};
try { const response = await fetch(url, options); const data = await response.json(); console.log(data);} catch (error) { console.error(error);}curl --request POST \ --url https://api.harperharbor.com/open/v1/conversation/fork \ --header 'Authorization: Bearer <token>' \ --header 'Content-Type: application/json' \ --data '{ "conversationId": "example", "title": "example" }'Authorizations
Section titled “Authorizations”Request Body
Section titled “Request Body”Media typeapplication/json
object
conversationId
required
string
title
string
Examplegenerated
{ "conversationId": "example", "title": "example"}Responses
Section titled “Responses”The source stays as a save; the new conversation carries the same messages (summaries and memory start fresh).
Media typeapplication/json
object
conversationId
string
sourceConversationId
string
messageCount
integer
Examplegenerated
{ "conversationId": "example", "sourceConversationId": "example", "messageCount": 1}conversation_limit_reached at 20 saves.
Media typeapplication/json
object
error
required
Machine-readable code. unauthorized means authentication failed. Refresh the token; if refresh fails, request authorization again.
string
message
required
One English sentence a client may show verbatim.
string
retryable
boolean
detail
Present on some 4xx errors with the offending part.
object
key
additional properties
any
Example
{ "error": "unauthorized"}