Skip to content

chelala/langgraphgo

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

9 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Go API client for langgraphgo

No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator)

Overview

This API client was generated by the OpenAPI Generator project. By using the OpenAPI-spec from a remote server, you can easily generate an API client.

  • API version: 0.1.0
  • Package version: 1.0.0
  • Generator version: 7.11.0
  • Build package: org.openapitools.codegen.languages.GoClientCodegen

Command

openapi-generator generate -i http://127.0.0.1:2024/openapi.json -g go --skip-validate-spec --additional-properties=disallowAdditionalPropertiesIfNotPresent=false,packageName=langgraphgo,prependFormOrBodyParameters=true,useDefaultValuesForRequiredVars=true,useOneOfDiscriminatorLookup=true

Installation

Install the following dependencies:

go get github.com/stretchr/testify/assert
go get golang.org/x/net/context

Put the package under your project folder and add the following in import:

import langgraphgo "github.com/chelala/langgraphgo"

To use a proxy, set the environment variable HTTP_PROXY:

os.Setenv("HTTP_PROXY", "http://proxy_name:proxy_port")

Configuration of Server URL

Default configuration comes with Servers field that contains server objects as defined in the OpenAPI specification.

Select Server Configuration

For using other server than the one defined on index 0 set context value langgraphgo.ContextServerIndex of type int.

ctx := context.WithValue(context.Background(), langgraphgo.ContextServerIndex, 1)

Templated Server URL

Templated server URL is formatted using default variables from configuration or from context value langgraphgo.ContextServerVariables of type map[string]string.

ctx := context.WithValue(context.Background(), langgraphgo.ContextServerVariables, map[string]string{
	"basePath": "v2",
})

Note, enum values are always validated and all unused variables are silently ignored.

URLs Configuration per Operation

Each operation can use different server URL defined using OperationServers map in the Configuration. An operation is uniquely identified by "{classname}Service.{nickname}" string. Similar rules for overriding default operation server index and variables applies by using langgraphgo.ContextOperationServerIndices and langgraphgo.ContextOperationServerVariables context maps.

ctx := context.WithValue(context.Background(), langgraphgo.ContextOperationServerIndices, map[string]int{
	"{classname}Service.{nickname}": 2,
})
ctx = context.WithValue(context.Background(), langgraphgo.ContextOperationServerVariables, map[string]map[string]string{
	"{classname}Service.{nickname}": {
		"port": "8443",
	},
})

Documentation for API Endpoints

All URIs are relative to http://localhost

Class Method HTTP request Description
AssistantsAPI CreateAssistantAssistantsPost Post /assistants Create Assistant
AssistantsAPI DeleteAssistantAssistantsAssistantIdDelete Delete /assistants/{assistant_id} Delete Assistant
AssistantsAPI GetAssistantAssistantsAssistantIdGet Get /assistants/{assistant_id} Get Assistant
AssistantsAPI GetAssistantGraphAssistantsAssistantIdGraphGet Get /assistants/{assistant_id}/graph Get Assistant Graph
AssistantsAPI GetAssistantSchemasAssistantsAssistantIdSchemasGet Get /assistants/{assistant_id}/schemas Get Assistant Schemas
AssistantsAPI GetAssistantSubgraphsAssistantsAssistantIdSubgraphsGet Get /assistants/{assistant_id}/subgraphs Get Assistant Subgraphs
AssistantsAPI GetAssistantSubgraphsAssistantsAssistantIdSubgraphsNamespaceGet Get /assistants/{assistant_id}/subgraphs/{namespace} Get Assistant Subgraphs by Namespace
AssistantsAPI GetAssistantVersionsAssistantsAssistantIdVersionsGet Post /assistants/{assistant_id}/versions Get Assistant Versions
AssistantsAPI PatchAssistantAssistantsAssistantIdPatch Patch /assistants/{assistant_id} Patch Assistant
AssistantsAPI SearchAssistantsAssistantsSearchPost Post /assistants/search Search Assistants
AssistantsAPI SetLatestAssistantVersionAssistantsAssistantIdVersionsPost Post /assistants/{assistant_id}/latest Set Latest Assistant Version
CronsPlusTierAPI CreateCronRunsCronsPost Post /runs/crons Create Cron
CronsPlusTierAPI CreateThreadCronThreadsThreadIdRunsCronsPost Post /threads/{thread_id}/runs/crons Create Thread Cron
CronsPlusTierAPI DeleteCronRunsCronsCronIdDelete Delete /runs/crons/{cron_id} Delete Cron
CronsPlusTierAPI SearchCronsRunsCronsPost Post /runs/crons/search Search Crons
StatelessRunsAPI RunBatchStatelessRunsPost Post /runs/batch Create Run Batch
StatelessRunsAPI RunStatelessRunsPost Post /runs Create Background Run
StatelessRunsAPI StreamRunStatelessRunsStreamPost Post /runs/stream Create Run, Stream Output
StatelessRunsAPI WaitRunStatelessRunsWaitPost Post /runs/wait Create Run, Wait for Output
StoreAPI DeleteItem Delete /store/items Delete an item.
StoreAPI GetItem Get /store/items Retrieve a single item.
StoreAPI ListNamespaces Post /store/namespaces List namespaces with optional match conditions.
StoreAPI PutItem Put /store/items Store or update an item.
StoreAPI SearchItems Post /store/items/search Search for items within a namespace prefix.
ThreadRunsAPI CancelRunHttpThreadsThreadIdRunsRunIdCancelPost Post /threads/{thread_id}/runs/{run_id}/cancel Cancel Run
ThreadRunsAPI CreateRunThreadsThreadIdRunsPost Post /threads/{thread_id}/runs Create Background Run
ThreadRunsAPI DeleteRunThreadsThreadIdRunsRunIdDelete Delete /threads/{thread_id}/runs/{run_id} Delete Run
ThreadRunsAPI GetRunHttpThreadsThreadIdRunsRunIdGet Get /threads/{thread_id}/runs/{run_id} Get Run
ThreadRunsAPI JoinRunHttpThreadsThreadIdRunsRunIdJoinGet Get /threads/{thread_id}/runs/{run_id}/join Join Run
ThreadRunsAPI ListRunsHttpThreadsThreadIdRunsGet Get /threads/{thread_id}/runs List Runs
ThreadRunsAPI StreamRunHttpThreadsThreadIdRunsRunIdJoinGet Get /threads/{thread_id}/runs/{run_id}/stream Join Run Stream
ThreadRunsAPI StreamRunThreadsThreadIdRunsStreamPost Post /threads/{thread_id}/runs/stream Create Run, Stream Output
ThreadRunsAPI WaitRunThreadsThreadIdRunsWaitPost Post /threads/{thread_id}/runs/wait Create Run, Wait for Output
ThreadsAPI CopyThreadPostThreadsThreadIdCopyPost Post /threads/{thread_id}/copy Copy Thread
ThreadsAPI CreateThreadThreadsPost Post /threads Create Thread
ThreadsAPI DeleteThreadThreadsThreadIdDelete Delete /threads/{thread_id} Delete Thread
ThreadsAPI GetLatestThreadStateThreadsThreadIdStateGet Get /threads/{thread_id}/state Get Thread State
ThreadsAPI GetThreadHistoryPostThreadsThreadIdHistoryPost Post /threads/{thread_id}/history Get Thread History Post
ThreadsAPI GetThreadHistoryThreadsThreadIdHistoryGet Get /threads/{thread_id}/history Get Thread History
ThreadsAPI GetThreadThreadsThreadIdGet Get /threads/{thread_id} Get Thread
ThreadsAPI PatchThreadThreadsThreadIdPatch Patch /threads/{thread_id} Patch Thread
ThreadsAPI PostThreadStateAtCheckpointThreadsThreadIdStateCheckpointIdGet Post /threads/{thread_id}/state/checkpoint Get Thread State At Checkpoint
ThreadsAPI SearchThreadsThreadsSearchPost Post /threads/search Search Threads
ThreadsAPI UpdateThreadStateThreadsThreadIdStatePost Post /threads/{thread_id}/state Update Thread State

Documentation For Models

Documentation For Authorization

Endpoints do not require authorization.

Documentation for Utility Methods

Due to the fact that model structure members are all pointers, this package contains a number of utility functions to easily obtain pointers to values of basic types. Each of these functions takes a value of the given basic type and returns a pointer to it:

  • PtrBool
  • PtrInt
  • PtrInt32
  • PtrInt64
  • PtrFloat
  • PtrFloat32
  • PtrFloat64
  • PtrString
  • PtrTime

Author

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published