diff --git a/core/request_option.go b/core/request_option.go index 78174f5..222aad4 100644 --- a/core/request_option.go +++ b/core/request_option.go @@ -71,7 +71,7 @@ func (r *RequestOptions) cloneHeader() http.Header { headers := r.HTTPHeader.Clone() headers.Set("X-Fern-Language", "Go") headers.Set("X-Fern-SDK-Name", "github.com/vellum-ai/vellum-client-go") - headers.Set("X-Fern-SDK-Version", "v1.13.7") + headers.Set("X-Fern-SDK-Version", "v1.13.8") return headers } diff --git a/deployments.go b/deployments.go index 0a46974..89cadf8 100644 --- a/deployments.go +++ b/deployments.go @@ -497,6 +497,7 @@ type SlimDeploymentRead struct { // // * `ACTIVE` - Active // * `ARCHIVED` - Archived + // * `PENDING_DELETION` - Pending Deletion Status *EntityStatus `json:"status,omitempty" url:"status,omitempty"` // Deprecated. The value returned will always be 'PRODUCTION'. Environment *EnvironmentEnum `json:"environment,omitempty" url:"environment,omitempty"` @@ -568,8 +569,9 @@ func (s *SlimDeploymentRead) String() string { type DeploymentsListRequestStatus string const ( - DeploymentsListRequestStatusActive DeploymentsListRequestStatus = "ACTIVE" - DeploymentsListRequestStatusArchived DeploymentsListRequestStatus = "ARCHIVED" + DeploymentsListRequestStatusActive DeploymentsListRequestStatus = "ACTIVE" + DeploymentsListRequestStatusArchived DeploymentsListRequestStatus = "ARCHIVED" + DeploymentsListRequestStatusPendingDeletion DeploymentsListRequestStatus = "PENDING_DELETION" ) func NewDeploymentsListRequestStatusFromString(s string) (DeploymentsListRequestStatus, error) { @@ -578,6 +580,8 @@ func NewDeploymentsListRequestStatusFromString(s string) (DeploymentsListRequest return DeploymentsListRequestStatusActive, nil case "ARCHIVED": return DeploymentsListRequestStatusArchived, nil + case "PENDING_DELETION": + return DeploymentsListRequestStatusPendingDeletion, nil } var t DeploymentsListRequestStatus return "", fmt.Errorf("%s is not a valid %T", s, t) diff --git a/document_indexes.go b/document_indexes.go index ab6aaad..36e464a 100644 --- a/document_indexes.go +++ b/document_indexes.go @@ -18,6 +18,7 @@ type DocumentIndexCreateRequest struct { // // * `ACTIVE` - Active // * `ARCHIVED` - Archived + // * `PENDING_DELETION` - Pending Deletion Status *EntityStatus `json:"status,omitempty" url:"-"` IndexingConfig *DocumentIndexIndexingConfigRequest `json:"indexing_config,omitempty" url:"-"` // Optionally specify the id of a document index from which you'd like to copy and re-index its documents into this newly created index @@ -37,6 +38,7 @@ type DocumentIndexesListRequest struct { // // * `ACTIVE` - Active // * `ARCHIVED` - Archived + // * `PENDING_DELETION` - Pending Deletion Status *DocumentIndexesListRequestStatus `json:"-" url:"status,omitempty"` } @@ -47,6 +49,7 @@ type PatchedDocumentIndexUpdateRequest struct { // // * `ACTIVE` - Active // * `ARCHIVED` - Archived + // * `PENDING_DELETION` - Pending Deletion Status *EntityStatus `json:"status,omitempty" url:"-"` } @@ -491,6 +494,7 @@ type DocumentIndexRead struct { // // * `ACTIVE` - Active // * `ARCHIVED` - Archived + // * `PENDING_DELETION` - Pending Deletion Status *EntityStatus `json:"status,omitempty" url:"status,omitempty"` IndexingConfig *DocumentIndexIndexingConfig `json:"indexing_config" url:"indexing_config"` @@ -1838,8 +1842,9 @@ func (t *TokenOverlappingWindowChunkingRequest) String() string { type DocumentIndexesListRequestStatus string const ( - DocumentIndexesListRequestStatusActive DocumentIndexesListRequestStatus = "ACTIVE" - DocumentIndexesListRequestStatusArchived DocumentIndexesListRequestStatus = "ARCHIVED" + DocumentIndexesListRequestStatusActive DocumentIndexesListRequestStatus = "ACTIVE" + DocumentIndexesListRequestStatusArchived DocumentIndexesListRequestStatus = "ARCHIVED" + DocumentIndexesListRequestStatusPendingDeletion DocumentIndexesListRequestStatus = "PENDING_DELETION" ) func NewDocumentIndexesListRequestStatusFromString(s string) (DocumentIndexesListRequestStatus, error) { @@ -1848,6 +1853,8 @@ func NewDocumentIndexesListRequestStatusFromString(s string) (DocumentIndexesLis return DocumentIndexesListRequestStatusActive, nil case "ARCHIVED": return DocumentIndexesListRequestStatusArchived, nil + case "PENDING_DELETION": + return DocumentIndexesListRequestStatusPendingDeletion, nil } var t DocumentIndexesListRequestStatus return "", fmt.Errorf("%s is not a valid %T", s, t) @@ -1864,5 +1871,6 @@ type DocumentIndexUpdateRequest struct { // // * `ACTIVE` - Active // * `ARCHIVED` - Archived + // * `PENDING_DELETION` - Pending Deletion Status *EntityStatus `json:"status,omitempty" url:"-"` } diff --git a/folder_entities.go b/folder_entities.go index 77e5a5e..03b7c94 100644 --- a/folder_entities.go +++ b/folder_entities.go @@ -19,6 +19,7 @@ type FolderEntitiesListRequest struct { // // * `ACTIVE` - Active // * `ARCHIVED` - Archived + // * `PENDING_DELETION` - Pending Deletion EntityStatus *FolderEntitiesListRequestEntityStatus `json:"-" url:"entity_status,omitempty"` // Number of results to return per page. Limit *int `json:"-" url:"limit,omitempty"` @@ -1054,8 +1055,9 @@ func (w *WorkflowSandboxDisplayData) String() string { type FolderEntitiesListRequestEntityStatus string const ( - FolderEntitiesListRequestEntityStatusActive FolderEntitiesListRequestEntityStatus = "ACTIVE" - FolderEntitiesListRequestEntityStatusArchived FolderEntitiesListRequestEntityStatus = "ARCHIVED" + FolderEntitiesListRequestEntityStatusActive FolderEntitiesListRequestEntityStatus = "ACTIVE" + FolderEntitiesListRequestEntityStatusArchived FolderEntitiesListRequestEntityStatus = "ARCHIVED" + FolderEntitiesListRequestEntityStatusPendingDeletion FolderEntitiesListRequestEntityStatus = "PENDING_DELETION" ) func NewFolderEntitiesListRequestEntityStatusFromString(s string) (FolderEntitiesListRequestEntityStatus, error) { @@ -1064,6 +1066,8 @@ func NewFolderEntitiesListRequestEntityStatusFromString(s string) (FolderEntitie return FolderEntitiesListRequestEntityStatusActive, nil case "ARCHIVED": return FolderEntitiesListRequestEntityStatusArchived, nil + case "PENDING_DELETION": + return FolderEntitiesListRequestEntityStatusPendingDeletion, nil } var t FolderEntitiesListRequestEntityStatus return "", fmt.Errorf("%s is not a valid %T", s, t) diff --git a/go.mod b/go.mod index 742a9ef..d75fdbb 100644 --- a/go.mod +++ b/go.mod @@ -1,6 +1,6 @@ module github.com/vellum-ai/vellum-client-go -// Version: v1.13.7 +// Version: v1.13.8 go 1.18 diff --git a/types.go b/types.go index f11674b..2e2029f 100644 --- a/types.go +++ b/types.go @@ -3904,6 +3904,7 @@ type DeploymentRead struct { // // * `ACTIVE` - Active // * `ARCHIVED` - Archived + // * `PENDING_DELETION` - Pending Deletion Status *EntityStatus `json:"status,omitempty" url:"status,omitempty"` // Deprecated. The value returned will always be 'PRODUCTION'. Environment *EnvironmentEnum `json:"environment,omitempty" url:"environment,omitempty"` @@ -4633,11 +4634,13 @@ func (e *EnrichedNormalizedCompletion) String() string { // * `ACTIVE` - Active // * `ARCHIVED` - Archived +// * `PENDING_DELETION` - Pending Deletion type EntityStatus string const ( - EntityStatusActive EntityStatus = "ACTIVE" - EntityStatusArchived EntityStatus = "ARCHIVED" + EntityStatusActive EntityStatus = "ACTIVE" + EntityStatusArchived EntityStatus = "ARCHIVED" + EntityStatusPendingDeletion EntityStatus = "PENDING_DELETION" ) func NewEntityStatusFromString(s string) (EntityStatus, error) { @@ -4646,6 +4649,8 @@ func NewEntityStatusFromString(s string) (EntityStatus, error) { return EntityStatusActive, nil case "ARCHIVED": return EntityStatusArchived, nil + case "PENDING_DELETION": + return EntityStatusPendingDeletion, nil } var t EntityStatus return "", fmt.Errorf("%s is not a valid %T", s, t) @@ -9430,6 +9435,7 @@ func (i *Integration) String() string { // * `SUPABASE` - Supabase // * `TAVILY` - Tavily // * `TELEGRAM` - Telegram +// * `TIKTOK` - TikTok // * `TODOIST` - Todoist // * `WEBFLOW` - Webflow // * `YOUSEARCH` - You Search @@ -9534,6 +9540,7 @@ const ( IntegrationNameSupabase IntegrationName = "SUPABASE" IntegrationNameTavily IntegrationName = "TAVILY" IntegrationNameTelegram IntegrationName = "TELEGRAM" + IntegrationNameTiktok IntegrationName = "TIKTOK" IntegrationNameTodoist IntegrationName = "TODOIST" IntegrationNameWebflow IntegrationName = "WEBFLOW" IntegrationNameYousearch IntegrationName = "YOUSEARCH" @@ -9722,6 +9729,8 @@ func NewIntegrationNameFromString(s string) (IntegrationName, error) { return IntegrationNameTavily, nil case "TELEGRAM": return IntegrationNameTelegram, nil + case "TIKTOK": + return IntegrationNameTiktok, nil case "TODOIST": return IntegrationNameTodoist, nil case "WEBFLOW": @@ -22734,8 +22743,8 @@ func (v *VellumNodeExecutionEvent) Accept(visitor VellumNodeExecutionEventVisito type VellumSdkError struct { Message string `json:"message" url:"message"` + RawData *VellumSdkErrorRawData `json:"raw_data,omitempty" url:"raw_data,omitempty"` Code VellumSdkErrorCodeEnum `json:"code" url:"code"` - RawData map[string]interface{} `json:"raw_data,omitempty" url:"raw_data,omitempty"` extraProperties map[string]interface{} _rawJSON json.RawMessage @@ -22859,6 +22868,50 @@ func (v VellumSdkErrorCodeEnum) Ptr() *VellumSdkErrorCodeEnum { return &v } +type VellumSdkErrorRawData struct { + StringUnknownMap map[string]interface{} + String string +} + +func (v *VellumSdkErrorRawData) UnmarshalJSON(data []byte) error { + var valueStringUnknownMap map[string]interface{} + if err := json.Unmarshal(data, &valueStringUnknownMap); err == nil { + v.StringUnknownMap = valueStringUnknownMap + return nil + } + var valueString string + if err := json.Unmarshal(data, &valueString); err == nil { + v.String = valueString + return nil + } + return fmt.Errorf("%s cannot be deserialized as a %T", data, v) +} + +func (v VellumSdkErrorRawData) MarshalJSON() ([]byte, error) { + if v.StringUnknownMap != nil { + return json.Marshal(v.StringUnknownMap) + } + if v.String != "" { + return json.Marshal(v.String) + } + return nil, fmt.Errorf("type %T does not include a non-empty union type", v) +} + +type VellumSdkErrorRawDataVisitor interface { + VisitStringUnknownMap(map[string]interface{}) error + VisitString(string) error +} + +func (v *VellumSdkErrorRawData) Accept(visitor VellumSdkErrorRawDataVisitor) error { + if v.StringUnknownMap != nil { + return visitor.VisitStringUnknownMap(v.StringUnknownMap) + } + if v.String != "" { + return visitor.VisitString(v.String) + } + return fmt.Errorf("type %T does not include a non-empty union type", v) +} + type VellumSecret struct { Name string `json:"name" url:"name"` @@ -24487,6 +24540,7 @@ type WorkflowDeploymentRead struct { // // * `ACTIVE` - Active // * `ARCHIVED` - Archived + // * `PENDING_DELETION` - Pending Deletion Status *EntityStatus `json:"status,omitempty" url:"status,omitempty"` // Deprecated. The value returned will always be 'PRODUCTION'. Environment *EnvironmentEnum `json:"environment,omitempty" url:"environment,omitempty"` @@ -24852,8 +24906,8 @@ func (w *WorkflowEvent) Accept(visitor WorkflowEventVisitor) error { type WorkflowEventError struct { Message string `json:"message" url:"message"` + RawData *WorkflowEventErrorRawData `json:"raw_data,omitempty" url:"raw_data,omitempty"` Code WorkflowExecutionEventErrorCode `json:"code" url:"code"` - RawData map[string]interface{} `json:"raw_data,omitempty" url:"raw_data,omitempty"` Stacktrace *string `json:"stacktrace,omitempty" url:"stacktrace,omitempty"` extraProperties map[string]interface{} @@ -24894,6 +24948,50 @@ func (w *WorkflowEventError) String() string { return fmt.Sprintf("%#v", w) } +type WorkflowEventErrorRawData struct { + StringUnknownMap map[string]interface{} + String string +} + +func (w *WorkflowEventErrorRawData) UnmarshalJSON(data []byte) error { + var valueStringUnknownMap map[string]interface{} + if err := json.Unmarshal(data, &valueStringUnknownMap); err == nil { + w.StringUnknownMap = valueStringUnknownMap + return nil + } + var valueString string + if err := json.Unmarshal(data, &valueString); err == nil { + w.String = valueString + return nil + } + return fmt.Errorf("%s cannot be deserialized as a %T", data, w) +} + +func (w WorkflowEventErrorRawData) MarshalJSON() ([]byte, error) { + if w.StringUnknownMap != nil { + return json.Marshal(w.StringUnknownMap) + } + if w.String != "" { + return json.Marshal(w.String) + } + return nil, fmt.Errorf("type %T does not include a non-empty union type", w) +} + +type WorkflowEventErrorRawDataVisitor interface { + VisitStringUnknownMap(map[string]interface{}) error + VisitString(string) error +} + +func (w *WorkflowEventErrorRawData) Accept(visitor WorkflowEventErrorRawDataVisitor) error { + if w.StringUnknownMap != nil { + return visitor.VisitStringUnknownMap(w.StringUnknownMap) + } + if w.String != "" { + return visitor.VisitString(w.String) + } + return fmt.Errorf("type %T does not include a non-empty union type", w) +} + type WorkflowExecutionActualChatHistoryRequest struct { // The Vellum-generated ID of a workflow output. Must provide either this or output_key. output_key is typically preferred. OutputId *string `json:"output_id,omitempty" url:"output_id,omitempty"` diff --git a/workflow_deployments.go b/workflow_deployments.go index 257a90f..94f1ada 100644 --- a/workflow_deployments.go +++ b/workflow_deployments.go @@ -206,6 +206,7 @@ type SlimWorkflowDeployment struct { // // * `ACTIVE` - Active // * `ARCHIVED` - Archived + // * `PENDING_DELETION` - Pending Deletion Status *EntityStatus `json:"status,omitempty" url:"status,omitempty"` // Deprecated. The value returned will always be 'PRODUCTION'. Environment *EnvironmentEnum `json:"environment,omitempty" url:"environment,omitempty"` @@ -928,8 +929,9 @@ func (l ListWorkflowReleaseTagsRequestSource) Ptr() *ListWorkflowReleaseTagsRequ type WorkflowDeploymentsListRequestStatus string const ( - WorkflowDeploymentsListRequestStatusActive WorkflowDeploymentsListRequestStatus = "ACTIVE" - WorkflowDeploymentsListRequestStatusArchived WorkflowDeploymentsListRequestStatus = "ARCHIVED" + WorkflowDeploymentsListRequestStatusActive WorkflowDeploymentsListRequestStatus = "ACTIVE" + WorkflowDeploymentsListRequestStatusArchived WorkflowDeploymentsListRequestStatus = "ARCHIVED" + WorkflowDeploymentsListRequestStatusPendingDeletion WorkflowDeploymentsListRequestStatus = "PENDING_DELETION" ) func NewWorkflowDeploymentsListRequestStatusFromString(s string) (WorkflowDeploymentsListRequestStatus, error) { @@ -938,6 +940,8 @@ func NewWorkflowDeploymentsListRequestStatusFromString(s string) (WorkflowDeploy return WorkflowDeploymentsListRequestStatusActive, nil case "ARCHIVED": return WorkflowDeploymentsListRequestStatusArchived, nil + case "PENDING_DELETION": + return WorkflowDeploymentsListRequestStatusPendingDeletion, nil } var t WorkflowDeploymentsListRequestStatus return "", fmt.Errorf("%s is not a valid %T", s, t)