Documentation
¶
Index ¶
- func Bool(value bool) param.Field[bool]
- func DefaultClientOptions() []option.RequestOption
- func F[T any](value T) param.Field[T]
- func FileParam(reader io.Reader, filename string, contentType string) param.Field[io.Reader]
- func Float(value float64) param.Field[float64]
- func Int(value int64) param.Field[int64]
- func Null[T any]() param.Field[T]
- func Raw[T any](value any) param.Field[T]
- func String(value string) param.Field[string]
- type AgentService
- type AgentV1AgentDeleteResponse
- type AgentV1AgentGetResponse
- type AgentV1AgentListParams
- type AgentV1AgentListResponse
- type AgentV1AgentListResponseAgent
- type AgentV1AgentNewParams
- type AgentV1AgentNewParamsSandbox
- type AgentV1AgentNewResponse
- type AgentV1AgentService
- func (r *AgentV1AgentService) Delete(ctx context.Context, id string, opts ...option.RequestOption) (res *AgentV1AgentDeleteResponse, err error)
- func (r *AgentV1AgentService) Get(ctx context.Context, id string, opts ...option.RequestOption) (res *AgentV1AgentGetResponse, err error)
- func (r *AgentV1AgentService) List(ctx context.Context, query AgentV1AgentListParams, ...) (res *AgentV1AgentListResponse, err error)
- func (r *AgentV1AgentService) New(ctx context.Context, body AgentV1AgentNewParams, opts ...option.RequestOption) (res *AgentV1AgentNewResponse, err error)
- func (r *AgentV1AgentService) Update(ctx context.Context, id string, body AgentV1AgentUpdateParams, ...) (res *AgentV1AgentUpdateResponse, err error)
- type AgentV1AgentUpdateParams
- type AgentV1AgentUpdateResponse
- type AgentV1ChatCancelResponse
- type AgentV1ChatDeleteResponse
- type AgentV1ChatFileListResponse
- type AgentV1ChatFileListResponseFile
- type AgentV1ChatFileService
- type AgentV1ChatNewParams
- type AgentV1ChatNewResponse
- type AgentV1ChatReplyToQuestionParams
- type AgentV1ChatRespondParams
- type AgentV1ChatRespondParamsPart
- type AgentV1ChatRespondParamsPartsType
- type AgentV1ChatSendMessageParams
- type AgentV1ChatSendMessageParamsPart
- type AgentV1ChatSendMessageParamsPartsType
- type AgentV1ChatService
- func (r *AgentV1ChatService) Cancel(ctx context.Context, id string, opts ...option.RequestOption) (res *AgentV1ChatCancelResponse, err error)
- func (r *AgentV1ChatService) Delete(ctx context.Context, id string, opts ...option.RequestOption) (res *AgentV1ChatDeleteResponse, err error)
- func (r *AgentV1ChatService) New(ctx context.Context, body AgentV1ChatNewParams, opts ...option.RequestOption) (res *AgentV1ChatNewResponse, err error)
- func (r *AgentV1ChatService) ReplyToQuestion(ctx context.Context, id string, requestID string, ...) (err error)
- func (r *AgentV1ChatService) RespondStreaming(ctx context.Context, id string, body AgentV1ChatRespondParams, ...) (stream *ssestream.Stream[string])
- func (r *AgentV1ChatService) SendMessage(ctx context.Context, id string, body AgentV1ChatSendMessageParams, ...) (err error)
- func (r *AgentV1ChatService) StreamStreaming(ctx context.Context, id string, query AgentV1ChatStreamParams, ...) (stream *ssestream.Stream[string])
- type AgentV1ChatStreamParams
- type AgentV1ExecuteNewParams
- type AgentV1ExecuteNewParamsSandbox
- type AgentV1ExecuteNewResponse
- type AgentV1ExecuteNewResponseStatus
- type AgentV1ExecuteService
- type AgentV1RunCancelResponse
- type AgentV1RunCancelResponseStatus
- type AgentV1RunEventsParams
- type AgentV1RunExecResponse
- type AgentV1RunExecResponseStatus
- type AgentV1RunGetDetailsResponse
- type AgentV1RunGetDetailsResponseProvider
- type AgentV1RunGetDetailsResponseResult
- type AgentV1RunGetDetailsResponseResultFinalResponse
- type AgentV1RunGetDetailsResponseResultLogs
- type AgentV1RunGetDetailsResponseRuntimeState
- type AgentV1RunGetDetailsResponseStatus
- type AgentV1RunGetDetailsResponseStep
- type AgentV1RunGetDetailsResponseStepsType
- type AgentV1RunGetDetailsResponseUsage
- type AgentV1RunGetDetailsResponseUsageEntriesKind
- type AgentV1RunGetDetailsResponseUsageEntry
- type AgentV1RunGetDetailsResponseUsageSummary
- type AgentV1RunGetStatusResponse
- type AgentV1RunGetStatusResponseStatus
- type AgentV1RunListParams
- type AgentV1RunListParamsStatus
- type AgentV1RunListResponse
- type AgentV1RunListResponseRun
- type AgentV1RunListResponseRunsStatus
- type AgentV1RunNewParams
- type AgentV1RunNewResponse
- type AgentV1RunNewResponseStatus
- type AgentV1RunService
- func (r *AgentV1RunService) Cancel(ctx context.Context, id string, opts ...option.RequestOption) (res *AgentV1RunCancelResponse, err error)
- func (r *AgentV1RunService) EventsStreaming(ctx context.Context, id string, query AgentV1RunEventsParams, ...) (stream *ssestream.Stream[string])
- func (r *AgentV1RunService) Exec(ctx context.Context, id string, opts ...option.RequestOption) (res *AgentV1RunExecResponse, err error)
- func (r *AgentV1RunService) GetDetails(ctx context.Context, id string, opts ...option.RequestOption) (res *AgentV1RunGetDetailsResponse, err error)
- func (r *AgentV1RunService) GetStatus(ctx context.Context, id string, opts ...option.RequestOption) (res *AgentV1RunGetStatusResponse, err error)
- func (r *AgentV1RunService) List(ctx context.Context, query AgentV1RunListParams, opts ...option.RequestOption) (res *AgentV1RunListResponse, err error)
- func (r *AgentV1RunService) New(ctx context.Context, body AgentV1RunNewParams, opts ...option.RequestOption) (res *AgentV1RunNewResponse, err error)
- func (r *AgentV1RunService) Watch(ctx context.Context, id string, body AgentV1RunWatchParams, ...) (res *AgentV1RunWatchResponse, err error)
- type AgentV1RunWatchParams
- type AgentV1RunWatchResponse
- type AgentV1Service
- type Client
- func (r *Client) Delete(ctx context.Context, path string, params interface{}, res interface{}, ...) error
- func (r *Client) Execute(ctx context.Context, method string, path string, params interface{}, ...) error
- func (r *Client) Get(ctx context.Context, path string, params interface{}, res interface{}, ...) error
- func (r *Client) Patch(ctx context.Context, path string, params interface{}, res interface{}, ...) error
- func (r *Client) Post(ctx context.Context, path string, params interface{}, res interface{}, ...) error
- func (r *Client) Put(ctx context.Context, path string, params interface{}, res interface{}, ...) error
- type ComputeService
- type ComputeV1EnvironmentDeleteResponse
- type ComputeV1EnvironmentGetResponse
- type ComputeV1EnvironmentListResponse
- type ComputeV1EnvironmentListResponseEnvironment
- type ComputeV1EnvironmentNewParams
- type ComputeV1EnvironmentNewResponse
- type ComputeV1EnvironmentNewResponseStatus
- type ComputeV1EnvironmentService
- func (r *ComputeV1EnvironmentService) Delete(ctx context.Context, name string, opts ...option.RequestOption) (res *ComputeV1EnvironmentDeleteResponse, err error)
- func (r *ComputeV1EnvironmentService) Get(ctx context.Context, name string, opts ...option.RequestOption) (res *ComputeV1EnvironmentGetResponse, err error)
- func (r *ComputeV1EnvironmentService) List(ctx context.Context, opts ...option.RequestOption) (res *ComputeV1EnvironmentListResponse, err error)
- func (r *ComputeV1EnvironmentService) New(ctx context.Context, body ComputeV1EnvironmentNewParams, ...) (res *ComputeV1EnvironmentNewResponse, err error)
- func (r *ComputeV1EnvironmentService) SetDefault(ctx context.Context, name string, opts ...option.RequestOption) (res *ComputeV1EnvironmentSetDefaultResponse, err error)
- type ComputeV1EnvironmentSetDefaultResponse
- type ComputeV1GetUsageParams
- type ComputeV1GetUsageResponse
- type ComputeV1GetUsageResponseByEnvironment
- type ComputeV1GetUsageResponsePeriod
- type ComputeV1GetUsageResponseSummary
- type ComputeV1InstanceDeleteResponse
- type ComputeV1InstanceGetResponse
- type ComputeV1InstanceGetResponseSSH
- type ComputeV1InstanceListResponse
- type ComputeV1InstanceListResponseInstance
- type ComputeV1InstanceListResponseInstancesStatus
- type ComputeV1InstanceNewParams
- type ComputeV1InstanceNewResponse
- type ComputeV1InstanceService
- func (r *ComputeV1InstanceService) Delete(ctx context.Context, id string, opts ...option.RequestOption) (res *ComputeV1InstanceDeleteResponse, err error)
- func (r *ComputeV1InstanceService) Get(ctx context.Context, id string, opts ...option.RequestOption) (res *ComputeV1InstanceGetResponse, err error)
- func (r *ComputeV1InstanceService) List(ctx context.Context, opts ...option.RequestOption) (res *ComputeV1InstanceListResponse, err error)
- func (r *ComputeV1InstanceService) New(ctx context.Context, body ComputeV1InstanceNewParams, ...) (res *ComputeV1InstanceNewResponse, err error)
- type ComputeV1InstanceTypeListResponse
- type ComputeV1InstanceTypeListResponseInstanceType
- type ComputeV1InstanceTypeListResponseInstanceTypesSpecs
- type ComputeV1InstanceTypeService
- type ComputeV1SecretDeleteGroupParams
- type ComputeV1SecretDeleteGroupResponse
- type ComputeV1SecretGetGroupParams
- type ComputeV1SecretGetGroupResponse
- type ComputeV1SecretGetGroupResponseGroup
- type ComputeV1SecretGetGroupResponseKey
- type ComputeV1SecretListParams
- type ComputeV1SecretListResponse
- type ComputeV1SecretListResponseGroup
- type ComputeV1SecretNewParams
- type ComputeV1SecretNewResponse
- type ComputeV1SecretService
- func (r *ComputeV1SecretService) DeleteGroup(ctx context.Context, group string, body ComputeV1SecretDeleteGroupParams, ...) (res *ComputeV1SecretDeleteGroupResponse, err error)
- func (r *ComputeV1SecretService) GetGroup(ctx context.Context, group string, query ComputeV1SecretGetGroupParams, ...) (res *ComputeV1SecretGetGroupResponse, err error)
- func (r *ComputeV1SecretService) List(ctx context.Context, query ComputeV1SecretListParams, ...) (res *ComputeV1SecretListResponse, err error)
- func (r *ComputeV1SecretService) New(ctx context.Context, body ComputeV1SecretNewParams, ...) (res *ComputeV1SecretNewResponse, err error)
- func (r *ComputeV1SecretService) UpdateGroup(ctx context.Context, group string, body ComputeV1SecretUpdateGroupParams, ...) (res *ComputeV1SecretUpdateGroupResponse, err error)
- type ComputeV1SecretUpdateGroupParams
- type ComputeV1SecretUpdateGroupResponse
- type ComputeV1Service
- type DatabaseService
- type DatabaseV1GetUsageResponse
- type DatabaseV1GetUsageResponsePeriod
- type DatabaseV1GetUsageResponsePricing
- type DatabaseV1GetUsageResponseProject
- type DatabaseV1GetUsageResponseProjectsCosts
- type DatabaseV1GetUsageResponseTotals
- type DatabaseV1ProjectDeleteResponse
- type DatabaseV1ProjectGetConnectionParams
- type DatabaseV1ProjectGetConnectionResponse
- type DatabaseV1ProjectGetResponse
- type DatabaseV1ProjectGetResponseBranch
- type DatabaseV1ProjectGetResponseDatabase
- type DatabaseV1ProjectGetResponseLinkedDeployment
- type DatabaseV1ProjectGetResponseLinkedDeploymentsType
- type DatabaseV1ProjectGetResponseStatus
- type DatabaseV1ProjectListBranchesResponse
- type DatabaseV1ProjectListBranchesResponseBranch
- type DatabaseV1ProjectListResponse
- type DatabaseV1ProjectListResponseProject
- type DatabaseV1ProjectListResponseProjectsLinkedDeployment
- type DatabaseV1ProjectListResponseProjectsLinkedDeploymentsType
- type DatabaseV1ProjectListResponseProjectsStatus
- type DatabaseV1ProjectNewBranchParams
- type DatabaseV1ProjectNewBranchResponse
- type DatabaseV1ProjectNewParams
- type DatabaseV1ProjectNewParamsRegion
- type DatabaseV1ProjectNewResponse
- type DatabaseV1ProjectNewResponseDefaultBranch
- type DatabaseV1ProjectNewResponseStatus
- type DatabaseV1ProjectService
- func (r *DatabaseV1ProjectService) Delete(ctx context.Context, id string, opts ...option.RequestOption) (res *DatabaseV1ProjectDeleteResponse, err error)
- func (r *DatabaseV1ProjectService) Get(ctx context.Context, id string, opts ...option.RequestOption) (res *DatabaseV1ProjectGetResponse, err error)
- func (r *DatabaseV1ProjectService) GetConnection(ctx context.Context, id string, query DatabaseV1ProjectGetConnectionParams, ...) (res *DatabaseV1ProjectGetConnectionResponse, err error)
- func (r *DatabaseV1ProjectService) List(ctx context.Context, opts ...option.RequestOption) (res *DatabaseV1ProjectListResponse, err error)
- func (r *DatabaseV1ProjectService) ListBranches(ctx context.Context, id string, opts ...option.RequestOption) (res *DatabaseV1ProjectListBranchesResponse, err error)
- func (r *DatabaseV1ProjectService) New(ctx context.Context, body DatabaseV1ProjectNewParams, ...) (res *DatabaseV1ProjectNewResponse, err error)
- func (r *DatabaseV1ProjectService) NewBranch(ctx context.Context, id string, body DatabaseV1ProjectNewBranchParams, ...) (res *DatabaseV1ProjectNewBranchResponse, err error)
- type DatabaseV1Service
- type DocketDetail
- type DocketSearchResult
- type Error
- type FormatService
- type FormatV1NewDocumentParams
- type FormatV1NewDocumentParamsInputFormat
- type FormatV1NewDocumentParamsOptions
- type FormatV1NewDocumentParamsOptionsComponent
- type FormatV1NewDocumentParamsOutputFormat
- type FormatV1Service
- type FormatV1TemplateGetResponse
- type FormatV1TemplateListParams
- type FormatV1TemplateListResponse
- type FormatV1TemplateListResponseTemplate
- type FormatV1TemplateNewParams
- type FormatV1TemplateNewParamsType
- type FormatV1TemplateNewResponse
- type FormatV1TemplateService
- func (r *FormatV1TemplateService) Get(ctx context.Context, id string, opts ...option.RequestOption) (res *FormatV1TemplateGetResponse, err error)
- func (r *FormatV1TemplateService) List(ctx context.Context, query FormatV1TemplateListParams, ...) (res *FormatV1TemplateListResponse, err error)
- func (r *FormatV1TemplateService) New(ctx context.Context, body FormatV1TemplateNewParams, ...) (res *FormatV1TemplateNewResponse, err error)
- type LegalService
- type LegalV1DocketParams
- type LegalV1DocketParamsType
- type LegalV1DocketResponse
- type LegalV1DocketResponseEntriesDocument
- type LegalV1DocketResponseEntry
- type LegalV1DocketResponsePacerFees
- type LegalV1DocketResponsePacerFeesCurrency
- type LegalV1DocketResponsePagination
- type LegalV1DocketResponseType
- type LegalV1DraftParams
- type LegalV1DraftParamsLength
- type LegalV1DraftParamsLengthUnit
- type LegalV1DraftParamsOutputType
- type LegalV1DraftResponse
- type LegalV1DraftResponseStatus
- type LegalV1FindParams
- type LegalV1FindResponse
- type LegalV1FindResponseCandidate
- type LegalV1GetCitationsFromURLParams
- type LegalV1GetCitationsFromURLResponse
- type LegalV1GetCitationsFromURLResponseCitations
- type LegalV1GetCitationsFromURLResponseCitationsCase
- type LegalV1GetCitationsFromURLResponseCitationsRegulation
- type LegalV1GetCitationsFromURLResponseCitationsStatute
- type LegalV1GetCitationsParams
- type LegalV1GetCitationsResponse
- type LegalV1GetCitationsResponseCitation
- type LegalV1GetCitationsResponseCitationsComponents
- type LegalV1GetCitationsResponseCitationsSpan
- type LegalV1GetFullTextParams
- type LegalV1GetFullTextResponse
- type LegalV1ListCourtsParams
- type LegalV1ListCourtsResponse
- type LegalV1ListCourtsResponseCourt
- type LegalV1ListJurisdictionsParams
- type LegalV1ListJurisdictionsResponse
- type LegalV1ListJurisdictionsResponseJurisdiction
- type LegalV1ListJurisdictionsResponseJurisdictionsLevel
- type LegalV1PatentSearchParams
- type LegalV1PatentSearchParamsApplicationType
- type LegalV1PatentSearchParamsSortBy
- type LegalV1PatentSearchParamsSortOrder
- type LegalV1PatentSearchResponse
- type LegalV1PatentSearchResponseResult
- type LegalV1ResearchParams
- type LegalV1ResearchResponse
- type LegalV1ResearchResponseCandidate
- type LegalV1SecFilingParams
- type LegalV1SecFilingParamsType
- type LegalV1SecFilingResponse
- type LegalV1SecFilingResponseFiling
- type LegalV1SecFilingResponseFilingsDocument
- type LegalV1SecFilingResponseFilingsEntity
- type LegalV1SecFilingResponseType
- type LegalV1Service
- func (r *LegalV1Service) Docket(ctx context.Context, body LegalV1DocketParams, opts ...option.RequestOption) (res *LegalV1DocketResponse, err error)
- func (r *LegalV1Service) Draft(ctx context.Context, body LegalV1DraftParams, opts ...option.RequestOption) (res *LegalV1DraftResponse, err error)
- func (r *LegalV1Service) Find(ctx context.Context, body LegalV1FindParams, opts ...option.RequestOption) (res *LegalV1FindResponse, err error)
- func (r *LegalV1Service) GetCitations(ctx context.Context, body LegalV1GetCitationsParams, ...) (res *LegalV1GetCitationsResponse, err error)
- func (r *LegalV1Service) GetCitationsFromURL(ctx context.Context, body LegalV1GetCitationsFromURLParams, ...) (res *LegalV1GetCitationsFromURLResponse, err error)
- func (r *LegalV1Service) GetFullText(ctx context.Context, body LegalV1GetFullTextParams, ...) (res *LegalV1GetFullTextResponse, err error)
- func (r *LegalV1Service) ListCourts(ctx context.Context, body LegalV1ListCourtsParams, ...) (res *LegalV1ListCourtsResponse, err error)
- func (r *LegalV1Service) ListJurisdictions(ctx context.Context, body LegalV1ListJurisdictionsParams, ...) (res *LegalV1ListJurisdictionsResponse, err error)
- func (r *LegalV1Service) PatentSearch(ctx context.Context, body LegalV1PatentSearchParams, ...) (res *LegalV1PatentSearchResponse, err error)
- func (r *LegalV1Service) Research(ctx context.Context, body LegalV1ResearchParams, opts ...option.RequestOption) (res *LegalV1ResearchResponse, err error)
- func (r *LegalV1Service) SecFiling(ctx context.Context, body LegalV1SecFilingParams, opts ...option.RequestOption) (res *LegalV1SecFilingResponse, err error)
- func (r *LegalV1Service) Similar(ctx context.Context, body LegalV1SimilarParams, opts ...option.RequestOption) (res *LegalV1SimilarResponse, err error)
- func (r *LegalV1Service) TrademarkSearch(ctx context.Context, body LegalV1TrademarkSearchParams, ...) (res *LegalV1TrademarkSearchResponse, err error)
- func (r *LegalV1Service) Verify(ctx context.Context, body LegalV1VerifyParams, opts ...option.RequestOption) (res *LegalV1VerifyResponse, err error)
- type LegalV1SimilarParams
- type LegalV1SimilarResponse
- type LegalV1SimilarResponseSimilarSource
- type LegalV1TrademarkSearchParams
- type LegalV1TrademarkSearchResponse
- type LegalV1TrademarkSearchResponseGoodsAndService
- type LegalV1TrademarkSearchResponseOwner
- type LegalV1VerifyParams
- type LegalV1VerifyResponse
- type LegalV1VerifyResponseCitation
- type LegalV1VerifyResponseCitationsCandidate
- type LegalV1VerifyResponseCitationsCase
- type LegalV1VerifyResponseCitationsSpan
- type LegalV1VerifyResponseCitationsStatus
- type LegalV1VerifyResponseCitationsVerificationSource
- type LegalV1VerifyResponseSummary
- type LlmGetConfigResponse
- type LlmGetConfigResponseModel
- type LlmService
- type LlmV1ChatNewCompletionParams
- type LlmV1ChatNewCompletionParamsMessage
- type LlmV1ChatNewCompletionParamsMessagesRole
- type LlmV1ChatNewCompletionResponse
- type LlmV1ChatNewCompletionResponseChoice
- type LlmV1ChatNewCompletionResponseChoicesMessage
- type LlmV1ChatNewCompletionResponseUsage
- type LlmV1ChatService
- type LlmV1ListModelsResponse
- type LlmV1ListModelsResponseData
- type LlmV1ListModelsResponseDataPricing
- type LlmV1NewEmbeddingParams
- type LlmV1NewEmbeddingParamsEncodingFormat
- type LlmV1NewEmbeddingParamsInputArray
- type LlmV1NewEmbeddingParamsInputUnion
- type LlmV1NewEmbeddingResponse
- type LlmV1NewEmbeddingResponseData
- type LlmV1NewEmbeddingResponseUsage
- type LlmV1Service
- type MailService
- type MailV1InboxNewParams
- type MailV1InboxService
- func (r *MailV1InboxService) Delete(ctx context.Context, inboxID string, opts ...option.RequestOption) (err error)
- func (r *MailV1InboxService) Get(ctx context.Context, inboxID string, opts ...option.RequestOption) (err error)
- func (r *MailV1InboxService) GetAttachment(ctx context.Context, inboxID string, messageID string, attachmentID string, ...) (err error)
- func (r *MailV1InboxService) GetMessage(ctx context.Context, inboxID string, messageID string, ...) (err error)
- func (r *MailV1InboxService) GetPolicy(ctx context.Context, inboxID string, opts ...option.RequestOption) (err error)
- func (r *MailV1InboxService) List(ctx context.Context, opts ...option.RequestOption) (err error)
- func (r *MailV1InboxService) ListMessages(ctx context.Context, inboxID string, opts ...option.RequestOption) (err error)
- func (r *MailV1InboxService) New(ctx context.Context, body MailV1InboxNewParams, opts ...option.RequestOption) (err error)
- func (r *MailV1InboxService) Reply(ctx context.Context, inboxID string, messageID string, ...) (err error)
- func (r *MailV1InboxService) Send(ctx context.Context, inboxID string, opts ...option.RequestOption) (err error)
- func (r *MailV1InboxService) SetPolicy(ctx context.Context, inboxID string, body MailV1InboxSetPolicyParams, ...) (err error)
- type MailV1InboxSetPolicyParams
- type MailV1Service
- type MatterService
- type MatterV1AgentTypeListParams
- type MatterV1AgentTypeNewParams
- type MatterV1AgentTypeService
- type MatterV1EventService
- type MatterV1EventSubscriptionNewParams
- type MatterV1EventSubscriptionService
- func (r *MatterV1EventSubscriptionService) Delete(ctx context.Context, id string, subscriptionID string, ...) (err error)
- func (r *MatterV1EventSubscriptionService) List(ctx context.Context, id string, opts ...option.RequestOption) (err error)
- func (r *MatterV1EventSubscriptionService) New(ctx context.Context, id string, body MatterV1EventSubscriptionNewParams, ...) (err error)
- type MatterV1ListParams
- type MatterV1LogExportParams
- type MatterV1LogExportParamsFormat
- type MatterV1LogExportParamsScopeArray
- type MatterV1LogExportParamsScopeUnion
- type MatterV1LogExportResponse
- type MatterV1LogListParams
- type MatterV1LogListParamsScopeArray
- type MatterV1LogListParamsScopeUnion
- type MatterV1LogNewParams
- type MatterV1LogService
- func (r *MatterV1LogService) Export(ctx context.Context, id string, body MatterV1LogExportParams, ...) (res *MatterV1LogExportResponse, err error)
- func (r *MatterV1LogService) List(ctx context.Context, id string, query MatterV1LogListParams, ...) (err error)
- func (r *MatterV1LogService) New(ctx context.Context, id string, body MatterV1LogNewParams, ...) (err error)
- type MatterV1MatterPartyNewParams
- type MatterV1MatterPartyNewParamsRole
- type MatterV1MatterPartyService
- type MatterV1NewParams
- type MatterV1NewParamsStatus
- type MatterV1NewParamsVault
- type MatterV1PartyListParams
- type MatterV1PartyListParamsType
- type MatterV1PartyNewParams
- type MatterV1PartyNewParamsType
- type MatterV1PartyService
- func (r *MatterV1PartyService) Get(ctx context.Context, partyID string, opts ...option.RequestOption) (err error)
- func (r *MatterV1PartyService) List(ctx context.Context, query MatterV1PartyListParams, ...) (err error)
- func (r *MatterV1PartyService) New(ctx context.Context, body MatterV1PartyNewParams, opts ...option.RequestOption) (err error)
- func (r *MatterV1PartyService) Update(ctx context.Context, partyID string, opts ...option.RequestOption) (err error)
- type MatterV1Service
- func (r *MatterV1Service) Get(ctx context.Context, id string, opts ...option.RequestOption) (err error)
- func (r *MatterV1Service) List(ctx context.Context, query MatterV1ListParams, opts ...option.RequestOption) (err error)
- func (r *MatterV1Service) New(ctx context.Context, body MatterV1NewParams, opts ...option.RequestOption) (err error)
- func (r *MatterV1Service) Update(ctx context.Context, id string, body MatterV1UpdateParams, ...) (err error)
- type MatterV1ShareNewParams
- type MatterV1ShareNewParamsPermission
- type MatterV1ShareService
- func (r *MatterV1ShareService) Delete(ctx context.Context, id string, shareID string, opts ...option.RequestOption) (err error)
- func (r *MatterV1ShareService) List(ctx context.Context, id string, opts ...option.RequestOption) (err error)
- func (r *MatterV1ShareService) New(ctx context.Context, id string, body MatterV1ShareNewParams, ...) (err error)
- type MatterV1TypeListParams
- type MatterV1TypeNewParams
- type MatterV1TypeNewParamsOrchestrationMode
- type MatterV1TypeService
- func (r *MatterV1TypeService) Get(ctx context.Context, id string, opts ...option.RequestOption) (err error)
- func (r *MatterV1TypeService) List(ctx context.Context, query MatterV1TypeListParams, ...) (err error)
- func (r *MatterV1TypeService) New(ctx context.Context, body MatterV1TypeNewParams, opts ...option.RequestOption) (err error)
- func (r *MatterV1TypeService) Update(ctx context.Context, id string, body MatterV1TypeUpdateParams, ...) (err error)
- type MatterV1TypeUpdateParams
- type MatterV1TypeUpdateParamsOrchestrationMode
- type MatterV1UpdateParams
- type MatterV1UpdateParamsStatus
- type MatterV1WorkItemDecideParams
- type MatterV1WorkItemDecideParamsDecision
- type MatterV1WorkItemListParams
- type MatterV1WorkItemNewParams
- type MatterV1WorkItemNewParamsPriority
- type MatterV1WorkItemNewParamsType
- type MatterV1WorkItemService
- func (r *MatterV1WorkItemService) Decide(ctx context.Context, id string, workItemID string, ...) (err error)
- func (r *MatterV1WorkItemService) Get(ctx context.Context, id string, workItemID string, ...) (err error)
- func (r *MatterV1WorkItemService) List(ctx context.Context, id string, query MatterV1WorkItemListParams, ...) (err error)
- func (r *MatterV1WorkItemService) ListExecutions(ctx context.Context, id string, workItemID string, ...) (err error)
- func (r *MatterV1WorkItemService) New(ctx context.Context, id string, body MatterV1WorkItemNewParams, ...) (err error)
- func (r *MatterV1WorkItemService) Update(ctx context.Context, id string, workItemID string, ...) (err error)
- type MatterV1WorkItemUpdateParams
- type MatterV1WorkItemUpdateParamsPriority
- type MatterV1WorkItemUpdateParamsStatus
- type MatterV1WorkItemUpdateParamsType
- type MemoryService
- type MemoryV1DeleteAllParams
- type MemoryV1DeleteAllResponse
- type MemoryV1DeleteResponse
- type MemoryV1GetResponse
- type MemoryV1ListParams
- type MemoryV1ListResponse
- type MemoryV1ListResponseResult
- type MemoryV1NewParams
- type MemoryV1NewParamsMessage
- type MemoryV1NewParamsMessagesRole
- type MemoryV1NewResponse
- type MemoryV1NewResponseResult
- type MemoryV1NewResponseResultsEvent
- type MemoryV1SearchParams
- type MemoryV1SearchResponse
- type MemoryV1SearchResponseResult
- type MemoryV1SearchResponseResultsTags
- type MemoryV1Service
- func (r *MemoryV1Service) Delete(ctx context.Context, id string, opts ...option.RequestOption) (res *MemoryV1DeleteResponse, err error)
- func (r *MemoryV1Service) DeleteAll(ctx context.Context, body MemoryV1DeleteAllParams, ...) (res *MemoryV1DeleteAllResponse, err error)
- func (r *MemoryV1Service) Get(ctx context.Context, id string, opts ...option.RequestOption) (res *MemoryV1GetResponse, err error)
- func (r *MemoryV1Service) List(ctx context.Context, query MemoryV1ListParams, opts ...option.RequestOption) (res *MemoryV1ListResponse, err error)
- func (r *MemoryV1Service) New(ctx context.Context, body MemoryV1NewParams, opts ...option.RequestOption) (res *MemoryV1NewResponse, err error)
- func (r *MemoryV1Service) Search(ctx context.Context, body MemoryV1SearchParams, opts ...option.RequestOption) (res *MemoryV1SearchResponse, err error)
- type OcrService
- type OcrV1DownloadParamsType
- type OcrV1GetParams
- type OcrV1GetParamsIncludeText
- type OcrV1GetResponse
- type OcrV1GetResponseStatus
- type OcrV1ProcessParams
- type OcrV1ProcessParamsEngine
- type OcrV1ProcessParamsFeatures
- type OcrV1ProcessParamsFeaturesTables
- type OcrV1ProcessParamsFeaturesTablesFormat
- type OcrV1ProcessResponse
- type OcrV1ProcessResponseStatus
- type OcrV1Service
- func (r *OcrV1Service) Download(ctx context.Context, id string, type_ OcrV1DownloadParamsType, ...) (res *http.Response, err error)
- func (r *OcrV1Service) Get(ctx context.Context, id string, query OcrV1GetParams, ...) (res *OcrV1GetResponse, err error)
- func (r *OcrV1Service) Process(ctx context.Context, body OcrV1ProcessParams, opts ...option.RequestOption) (res *OcrV1ProcessResponse, err error)
- type PrivilegeService
- type PrivilegeV1DetectParams
- type PrivilegeV1DetectParamsCategory
- type PrivilegeV1DetectParamsJurisdiction
- type PrivilegeV1DetectResponse
- type PrivilegeV1DetectResponseCategory
- type PrivilegeV1DetectResponseRecommendation
- type PrivilegeV1Service
- type SearchService
- type SearchV1AnswerParams
- type SearchV1AnswerParamsSearchType
- type SearchV1AnswerResponse
- type SearchV1AnswerResponseCitation
- type SearchV1ContentsParams
- type SearchV1ContentsResponse
- type SearchV1ContentsResponseResult
- type SearchV1GetResearchParams
- type SearchV1GetResearchResponse
- type SearchV1GetResearchResponseModel
- type SearchV1GetResearchResponseResults
- type SearchV1GetResearchResponseResultsSection
- type SearchV1GetResearchResponseResultsSectionsSource
- type SearchV1GetResearchResponseResultsSource
- type SearchV1GetResearchResponseStatus
- type SearchV1ResearchParams
- type SearchV1ResearchParamsModel
- type SearchV1ResearchResponse
- type SearchV1SearchParams
- type SearchV1SearchParamsType
- type SearchV1SearchResponse
- type SearchV1SearchResponseResult
- type SearchV1Service
- func (r *SearchV1Service) Answer(ctx context.Context, body SearchV1AnswerParams, opts ...option.RequestOption) (res *SearchV1AnswerResponse, err error)
- func (r *SearchV1Service) Contents(ctx context.Context, body SearchV1ContentsParams, opts ...option.RequestOption) (res *SearchV1ContentsResponse, err error)
- func (r *SearchV1Service) GetResearch(ctx context.Context, id string, query SearchV1GetResearchParams, ...) (res *SearchV1GetResearchResponse, err error)
- func (r *SearchV1Service) Research(ctx context.Context, body SearchV1ResearchParams, opts ...option.RequestOption) (res *SearchV1ResearchResponse, err error)
- func (r *SearchV1Service) Search(ctx context.Context, body SearchV1SearchParams, opts ...option.RequestOption) (res *SearchV1SearchResponse, err error)
- func (r *SearchV1Service) Similar(ctx context.Context, body SearchV1SimilarParams, opts ...option.RequestOption) (res *SearchV1SimilarResponse, err error)
- type SearchV1SimilarParams
- type SearchV1SimilarResponse
- type SearchV1SimilarResponseResult
- type SkillCustomListParams
- type SkillCustomListResponse
- type SkillCustomListResponseSkill
- type SkillCustomService
- type SkillDeleteResponse
- type SkillNewParams
- type SkillNewResponse
- type SkillReadResponse
- type SkillReadResponseBundle
- type SkillReadResponseBundleObject
- type SkillReadResponseBundleObjectFile
- type SkillReadResponseBundleObjectRole
- type SkillReadResponseBundleRole
- type SkillReadResponseBundleUnion
- type SkillReadResponseSource
- type SkillResolveParams
- type SkillResolveResponse
- type SkillResolveResponseResult
- type SkillResolveResponseResultsSource
- type SkillService
- func (r *SkillService) Delete(ctx context.Context, slug string, opts ...option.RequestOption) (res *SkillDeleteResponse, err error)
- func (r *SkillService) New(ctx context.Context, body SkillNewParams, opts ...option.RequestOption) (res *SkillNewResponse, err error)
- func (r *SkillService) Read(ctx context.Context, slug string, opts ...option.RequestOption) (res *SkillReadResponse, err error)
- func (r *SkillService) Resolve(ctx context.Context, query SkillResolveParams, opts ...option.RequestOption) (res *SkillResolveResponse, err error)
- func (r *SkillService) Update(ctx context.Context, slug string, body SkillUpdateParams, ...) (res *SkillUpdateResponse, err error)
- type SkillUpdateParams
- type SkillUpdateResponse
- type SuperdocService
- type SuperdocV1AnnotateParams
- type SuperdocV1AnnotateParamsDocument
- type SuperdocV1AnnotateParamsField
- type SuperdocV1AnnotateParamsFieldsOptions
- type SuperdocV1AnnotateParamsFieldsType
- type SuperdocV1AnnotateParamsFieldsValueUnion
- type SuperdocV1AnnotateParamsOutputFormat
- type SuperdocV1ConvertParams
- type SuperdocV1ConvertParamsFrom
- type SuperdocV1ConvertParamsTo
- type SuperdocV1Service
- type SystemListServicesResponse
- type SystemListServicesResponseService
- type SystemService
- type TranslateService
- type TranslateV1DetectParams
- type TranslateV1DetectParamsQArray
- type TranslateV1DetectParamsQUnion
- type TranslateV1DetectResponse
- type TranslateV1DetectResponseData
- type TranslateV1DetectResponseDataDetection
- type TranslateV1ListLanguagesParams
- type TranslateV1ListLanguagesParamsModel
- type TranslateV1ListLanguagesResponse
- type TranslateV1ListLanguagesResponseData
- type TranslateV1ListLanguagesResponseDataLanguage
- type TranslateV1Service
- func (r *TranslateV1Service) Detect(ctx context.Context, body TranslateV1DetectParams, ...) (res *TranslateV1DetectResponse, err error)
- func (r *TranslateV1Service) ListLanguages(ctx context.Context, query TranslateV1ListLanguagesParams, ...) (res *TranslateV1ListLanguagesResponse, err error)
- func (r *TranslateV1Service) Translate(ctx context.Context, body TranslateV1TranslateParams, ...) (res *TranslateV1TranslateResponse, err error)
- type TranslateV1TranslateParams
- type TranslateV1TranslateParamsFormat
- type TranslateV1TranslateParamsModel
- type TranslateV1TranslateParamsQArray
- type TranslateV1TranslateParamsQUnion
- type TranslateV1TranslateResponse
- type TranslateV1TranslateResponseData
- type TranslateV1TranslateResponseDataTranslation
- type UsageService
- type UsageV1GetParams
- type UsageV1GetParamsGranularity
- type UsageV1Service
- type UsageV1SubscriptionNewParams
- type UsageV1SubscriptionService
- func (r *UsageV1SubscriptionService) Delete(ctx context.Context, subscriptionID string, opts ...option.RequestOption) (err error)
- func (r *UsageV1SubscriptionService) List(ctx context.Context, opts ...option.RequestOption) (err error)
- func (r *UsageV1SubscriptionService) New(ctx context.Context, body UsageV1SubscriptionNewParams, ...) (err error)
- func (r *UsageV1SubscriptionService) Test(ctx context.Context, subscriptionID string, body UsageV1SubscriptionTestParams, ...) (err error)
- func (r *UsageV1SubscriptionService) Update(ctx context.Context, subscriptionID string, ...) (err error)
- type UsageV1SubscriptionTestParams
- type UsageV1SubscriptionUpdateParams
- type VaultConfirmUploadParams
- type VaultConfirmUploadParamsBody
- type VaultConfirmUploadParamsBodySuccess
- type VaultConfirmUploadParamsBodyUnion
- type VaultConfirmUploadParamsBodyVaultConfirmUploadFailure
- type VaultConfirmUploadParamsBodyVaultConfirmUploadFailureSuccess
- type VaultConfirmUploadParamsBodyVaultConfirmUploadSuccess
- type VaultConfirmUploadParamsBodyVaultConfirmUploadSuccessSuccess
- type VaultConfirmUploadResponse
- type VaultConfirmUploadResponseStatus
- type VaultDeleteParams
- type VaultDeleteResponse
- type VaultDeleteResponseDeletedVault
- type VaultEventService
- type VaultEventSubscriptionNewParams
- type VaultEventSubscriptionService
- func (r *VaultEventSubscriptionService) Delete(ctx context.Context, id string, subscriptionID string, ...) (err error)
- func (r *VaultEventSubscriptionService) List(ctx context.Context, id string, opts ...option.RequestOption) (err error)
- func (r *VaultEventSubscriptionService) New(ctx context.Context, id string, body VaultEventSubscriptionNewParams, ...) (err error)
- func (r *VaultEventSubscriptionService) Test(ctx context.Context, id string, subscriptionID string, ...) (err error)
- func (r *VaultEventSubscriptionService) Update(ctx context.Context, id string, subscriptionID string, ...) (err error)
- type VaultEventSubscriptionTestParams
- type VaultEventSubscriptionUpdateParams
- type VaultGetResponse
- type VaultGetResponseChunkStrategy
- type VaultGraphragGetStatsResponse
- type VaultGraphragGetStatsResponseStatus
- type VaultGraphragInitResponse
- type VaultGraphragProcessObjectResponse
- type VaultGraphragProcessObjectResponseStats
- type VaultGraphragService
- func (r *VaultGraphragService) GetStats(ctx context.Context, id string, opts ...option.RequestOption) (res *VaultGraphragGetStatsResponse, err error)
- func (r *VaultGraphragService) Init(ctx context.Context, id string, opts ...option.RequestOption) (res *VaultGraphragInitResponse, err error)
- func (r *VaultGraphragService) ProcessObject(ctx context.Context, id string, objectID string, opts ...option.RequestOption) (res *VaultGraphragProcessObjectResponse, err error)
- type VaultGroupNewParams
- type VaultGroupService
- func (r *VaultGroupService) Delete(ctx context.Context, groupID string, opts ...option.RequestOption) (err error)
- func (r *VaultGroupService) List(ctx context.Context, opts ...option.RequestOption) (err error)
- func (r *VaultGroupService) New(ctx context.Context, body VaultGroupNewParams, opts ...option.RequestOption) (err error)
- func (r *VaultGroupService) Update(ctx context.Context, groupID string, body VaultGroupUpdateParams, ...) (err error)
- type VaultGroupUpdateParams
- type VaultIngestResponse
- type VaultIngestResponseStatus
- type VaultListResponse
- type VaultListResponseVault
- type VaultMemoryListResponse
- type VaultMemoryListResponseEntry
- type VaultMemoryListResponseMeta
- type VaultMemoryNewParams
- type VaultMemoryNewParamsType
- type VaultMemoryNewResponse
- type VaultMemoryNewResponseEntry
- type VaultMemorySearchParams
- type VaultMemorySearchResponse
- type VaultMemorySearchResponseResult
- type VaultMemoryService
- func (r *VaultMemoryService) Delete(ctx context.Context, id string, entryID string, opts ...option.RequestOption) (err error)
- func (r *VaultMemoryService) List(ctx context.Context, id string, opts ...option.RequestOption) (res *VaultMemoryListResponse, err error)
- func (r *VaultMemoryService) New(ctx context.Context, id string, body VaultMemoryNewParams, ...) (res *VaultMemoryNewResponse, err error)
- func (r *VaultMemoryService) Search(ctx context.Context, id string, body VaultMemorySearchParams, ...) (res *VaultMemorySearchResponse, err error)
- func (r *VaultMemoryService) Update(ctx context.Context, id string, entryID string, body VaultMemoryUpdateParams, ...) (err error)
- type VaultMemoryUpdateParams
- type VaultMultipartAbortParams
- type VaultMultipartGetPartURLsParams
- type VaultMultipartGetPartURLsParamsPart
- type VaultMultipartGetPartURLsResponse
- type VaultMultipartGetPartURLsResponseURL
- type VaultMultipartService
- type VaultNewParams
- type VaultNewParamsEmbeddingModel
- type VaultNewResponse
- type VaultNewResponseEmbeddingProfile
- type VaultObjectDeleteParams
- type VaultObjectDeleteParamsForce
- type VaultObjectDeleteResponse
- type VaultObjectDeleteResponseDeletedObject
- type VaultObjectGetChunksParams
- type VaultObjectGetChunksResponse
- type VaultObjectGetChunksResponseChunk
- type VaultObjectGetOcrWordsParams
- type VaultObjectGetOcrWordsResponse
- type VaultObjectGetOcrWordsResponsePage
- type VaultObjectGetOcrWordsResponsePagesWord
- type VaultObjectGetPagesParams
- type VaultObjectGetPagesResponse
- type VaultObjectGetPagesResponseMetadata
- type VaultObjectGetPagesResponseMetadataSource
- type VaultObjectGetPagesResponsePage
- type VaultObjectGetResponse
- type VaultObjectGetSummarizeJobResponse
- type VaultObjectGetSummarizeJobResponseStatus
- type VaultObjectGetTextResponse
- type VaultObjectGetTextResponseMetadata
- type VaultObjectListResponse
- type VaultObjectListResponseObject
- type VaultObjectNewPresignedURLParams
- type VaultObjectNewPresignedURLParamsOperation
- type VaultObjectNewPresignedURLResponse
- type VaultObjectNewPresignedURLResponseMetadata
- type VaultObjectService
- func (r *VaultObjectService) Delete(ctx context.Context, id string, objectID string, body VaultObjectDeleteParams, ...) (res *VaultObjectDeleteResponse, err error)
- func (r *VaultObjectService) Download(ctx context.Context, id string, objectID string, opts ...option.RequestOption) (res *http.Response, err error)
- func (r *VaultObjectService) Get(ctx context.Context, id string, objectID string, opts ...option.RequestOption) (res *VaultObjectGetResponse, err error)
- func (r *VaultObjectService) GetChunks(ctx context.Context, id string, objectID string, ...) (res *VaultObjectGetChunksResponse, err error)
- func (r *VaultObjectService) GetOcrWords(ctx context.Context, id string, objectID string, ...) (res *VaultObjectGetOcrWordsResponse, err error)
- func (r *VaultObjectService) GetPages(ctx context.Context, id string, objectID string, ...) (res *VaultObjectGetPagesResponse, err error)
- func (r *VaultObjectService) GetSummarizeJob(ctx context.Context, id string, objectID string, jobID string, ...) (res *VaultObjectGetSummarizeJobResponse, err error)
- func (r *VaultObjectService) GetText(ctx context.Context, id string, objectID string, opts ...option.RequestOption) (res *VaultObjectGetTextResponse, err error)
- func (r *VaultObjectService) List(ctx context.Context, id string, opts ...option.RequestOption) (res *VaultObjectListResponse, err error)
- func (r *VaultObjectService) NewPresignedURL(ctx context.Context, id string, objectID string, ...) (res *VaultObjectNewPresignedURLResponse, err error)
- func (r *VaultObjectService) Update(ctx context.Context, id string, objectID string, body VaultObjectUpdateParams, ...) (res *VaultObjectUpdateResponse, err error)
- type VaultObjectUpdateParams
- type VaultObjectUpdateResponse
- type VaultSearchParams
- type VaultSearchParamsFilters
- type VaultSearchParamsFiltersObjectIDArray
- type VaultSearchParamsFiltersObjectIDUnion
- type VaultSearchParamsMethod
- type VaultSearchResponse
- type VaultSearchResponseChunk
- type VaultSearchResponseSource
- type VaultService
- func (r *VaultService) ConfirmUpload(ctx context.Context, id string, objectID string, body VaultConfirmUploadParams, ...) (res *VaultConfirmUploadResponse, err error)
- func (r *VaultService) Delete(ctx context.Context, id string, body VaultDeleteParams, ...) (res *VaultDeleteResponse, err error)
- func (r *VaultService) Get(ctx context.Context, id string, opts ...option.RequestOption) (res *VaultGetResponse, err error)
- func (r *VaultService) Ingest(ctx context.Context, id string, objectID string, opts ...option.RequestOption) (res *VaultIngestResponse, err error)
- func (r *VaultService) List(ctx context.Context, opts ...option.RequestOption) (res *VaultListResponse, err error)
- func (r *VaultService) New(ctx context.Context, body VaultNewParams, opts ...option.RequestOption) (res *VaultNewResponse, err error)
- func (r *VaultService) Search(ctx context.Context, id string, body VaultSearchParams, ...) (res *VaultSearchResponse, err error)
- func (r *VaultService) Update(ctx context.Context, id string, body VaultUpdateParams, ...) (res *VaultUpdateResponse, err error)
- func (r *VaultService) Upload(ctx context.Context, id string, body VaultUploadParams, ...) (res *VaultUploadResponse, err error)
- type VaultUpdateParams
- type VaultUpdateResponse
- type VaultUploadParams
- type VaultUploadResponse
- type VaultUploadResponseInstructions
- type VoiceBoostListExtractParams
- type VoiceBoostListExtractParamsCategory
- type VoiceBoostListExtractResponse
- type VoiceBoostListExtractResponseItem
- type VoiceBoostListExtractResponseItemsBoostParam
- type VoiceBoostListExtractResponseSource
- type VoiceBoostListGenerateParams
- type VoiceBoostListGenerateParamsCategory
- type VoiceBoostListGenerateResponse
- type VoiceBoostListGenerateResponseItem
- type VoiceBoostListGenerateResponseItemsBoostParam
- type VoiceBoostListGenerateResponseSource
- type VoiceBoostListService
- type VoiceService
- type VoiceStreamingGetURLResponse
- type VoiceStreamingGetURLResponseAudioFormat
- type VoiceStreamingGetURLResponsePricing
- type VoiceStreamingService
- type VoiceTranscriptionGetParams
- type VoiceTranscriptionGetParamsIncludeText
- type VoiceTranscriptionGetResponse
- type VoiceTranscriptionGetResponseStatus
- type VoiceTranscriptionNewParams
- type VoiceTranscriptionNewParamsBoostParam
- type VoiceTranscriptionNewParamsFormat
- type VoiceTranscriptionNewResponse
- type VoiceTranscriptionNewResponseStatus
- type VoiceTranscriptionService
- func (r *VoiceTranscriptionService) Delete(ctx context.Context, id string, opts ...option.RequestOption) (err error)
- func (r *VoiceTranscriptionService) Get(ctx context.Context, id string, query VoiceTranscriptionGetParams, ...) (res *VoiceTranscriptionGetResponse, err error)
- func (r *VoiceTranscriptionService) New(ctx context.Context, body VoiceTranscriptionNewParams, ...) (res *VoiceTranscriptionNewResponse, err error)
- type VoiceV1ListVoicesParams
- type VoiceV1ListVoicesParamsSort
- type VoiceV1ListVoicesParamsSortDirection
- type VoiceV1ListVoicesParamsVoiceType
- type VoiceV1ListVoicesResponse
- type VoiceV1ListVoicesResponseVoice
- type VoiceV1Service
- type VoiceV1SpeakNewParams
- type VoiceV1SpeakNewParamsModelID
- type VoiceV1SpeakNewParamsOutputFormat
- type VoiceV1SpeakNewParamsVoiceSettings
- type VoiceV1SpeakService
- type WebhookService
- type WebhookV1DeliveryListParams
- type WebhookV1DeliveryListParamsStatus
- type WebhookV1DeliveryReplayParams
- type WebhookV1DeliveryService
- func (r *WebhookV1DeliveryService) Get(ctx context.Context, id string, opts ...option.RequestOption) (err error)
- func (r *WebhookV1DeliveryService) List(ctx context.Context, query WebhookV1DeliveryListParams, ...) (err error)
- func (r *WebhookV1DeliveryService) Replay(ctx context.Context, id string, body WebhookV1DeliveryReplayParams, ...) (err error)
- type WebhookV1EndpointListParams
- type WebhookV1EndpointListParamsStatus
- type WebhookV1EndpointNewParams
- type WebhookV1EndpointNewParamsResourceScopes
- type WebhookV1EndpointRotateSecretParams
- type WebhookV1EndpointService
- func (r *WebhookV1EndpointService) Delete(ctx context.Context, id string, opts ...option.RequestOption) (err error)
- func (r *WebhookV1EndpointService) Get(ctx context.Context, id string, opts ...option.RequestOption) (err error)
- func (r *WebhookV1EndpointService) List(ctx context.Context, query WebhookV1EndpointListParams, ...) (err error)
- func (r *WebhookV1EndpointService) New(ctx context.Context, body WebhookV1EndpointNewParams, ...) (err error)
- func (r *WebhookV1EndpointService) RotateSecret(ctx context.Context, id string, body WebhookV1EndpointRotateSecretParams, ...) (err error)
- func (r *WebhookV1EndpointService) Test(ctx context.Context, id string, body WebhookV1EndpointTestParams, ...) (err error)
- func (r *WebhookV1EndpointService) Update(ctx context.Context, id string, body WebhookV1EndpointUpdateParams, ...) (err error)
- type WebhookV1EndpointTestParams
- type WebhookV1EndpointUpdateParams
- type WebhookV1EndpointUpdateParamsResourceScopes
- type WebhookV1EndpointUpdateParamsStatus
- type WebhookV1EventTypeService
- type WebhookV1Service
- type WorkerService
- type WorkerV1Service
- func (r *WorkerV1Service) Boot(ctx context.Context, id string, opts ...option.RequestOption) (err error)
- func (r *WorkerV1Service) Delete(ctx context.Context, id string, opts ...option.RequestOption) (err error)
- func (r *WorkerV1Service) Get(ctx context.Context, id string, opts ...option.RequestOption) (err error)
- func (r *WorkerV1Service) New(ctx context.Context, opts ...option.RequestOption) (err error)
- func (r *WorkerV1Service) ProxyDelete(ctx context.Context, id string, workerPath string, ...) (err error)
- func (r *WorkerV1Service) ProxyGet(ctx context.Context, id string, workerPath string, ...) (err error)
- func (r *WorkerV1Service) ProxyPatch(ctx context.Context, id string, workerPath string, ...) (err error)
- func (r *WorkerV1Service) ProxyPost(ctx context.Context, id string, workerPath string, ...) (err error)
- func (r *WorkerV1Service) ProxyPut(ctx context.Context, id string, workerPath string, ...) (err error)
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func DefaultClientOptions ¶
func DefaultClientOptions() []option.RequestOption
DefaultClientOptions read from the environment (CASEDEV_API_KEY, CASEDEV_BASE_URL). This should be used to initialize new clients.
func F ¶
F is a param field helper used to initialize a param.Field generic struct. This helps specify null, zero values, and overrides, as well as normal values. You can read more about this in our README.
func Int ¶
Int is a param field helper which helps specify integers. This is particularly helpful when specifying integer constants for fields.
func Raw ¶
Raw is a param field helper for specifying values for fields when the type you are looking to send is different from the type that is specified in the SDK. For example, if the type of the field is an integer, but you want to send a float, you could do that by setting the corresponding field with Raw[int](0.5).
Types ¶
type AgentService ¶ added in v0.2.0
type AgentService struct {
Options []option.RequestOption
V1 *AgentV1Service
}
AgentService contains methods and other services that help with interacting with the casedev API.
Note, unlike clients, this service does not read variables from the environment automatically. You should not instantiate this service directly, and instead use the NewAgentService method instead.
func NewAgentService ¶ added in v0.2.0
func NewAgentService(opts ...option.RequestOption) (r *AgentService)
NewAgentService generates a new service that applies the given options to each request. These options are applied after the parent client's options (if there is one), and before any request-specific options.
type AgentV1AgentDeleteResponse ¶ added in v0.2.0
type AgentV1AgentDeleteResponse struct {
Ok bool `json:"ok"`
JSON agentV1AgentDeleteResponseJSON `json:"-"`
}
func (*AgentV1AgentDeleteResponse) UnmarshalJSON ¶ added in v0.2.0
func (r *AgentV1AgentDeleteResponse) UnmarshalJSON(data []byte) (err error)
type AgentV1AgentGetResponse ¶ added in v0.2.0
type AgentV1AgentGetResponse struct {
ID string `json:"id"`
CreatedAt time.Time `json:"createdAt" format:"date-time"`
Description string `json:"description" api:"nullable"`
DisabledTools []string `json:"disabledTools" api:"nullable"`
EnabledTools []string `json:"enabledTools" api:"nullable"`
Instructions string `json:"instructions"`
IsActive bool `json:"isActive"`
Model string `json:"model"`
Name string `json:"name"`
Sandbox interface{} `json:"sandbox" api:"nullable"`
UpdatedAt time.Time `json:"updatedAt" format:"date-time"`
VaultIDs []string `json:"vaultIds" api:"nullable"`
JSON agentV1AgentGetResponseJSON `json:"-"`
}
func (*AgentV1AgentGetResponse) UnmarshalJSON ¶ added in v0.2.0
func (r *AgentV1AgentGetResponse) UnmarshalJSON(data []byte) (err error)
type AgentV1AgentListParams ¶ added in v0.13.0
type AgentV1AgentListParams struct {
// Pagination cursor (agent ID from previous page). Returns agents created before
// this agent.
Cursor param.Field[string] `query:"cursor"`
// Maximum number of agents to return (default 50, max 250)
Limit param.Field[int64] `query:"limit"`
}
func (AgentV1AgentListParams) URLQuery ¶ added in v0.13.0
func (r AgentV1AgentListParams) URLQuery() (v url.Values)
URLQuery serializes AgentV1AgentListParams's query parameters as `url.Values`.
type AgentV1AgentListResponse ¶ added in v0.2.0
type AgentV1AgentListResponse struct {
Agents []AgentV1AgentListResponseAgent `json:"agents"`
HasMore bool `json:"hasMore"`
// Pass as cursor to fetch the next page
NextCursor string `json:"nextCursor" api:"nullable"`
JSON agentV1AgentListResponseJSON `json:"-"`
}
func (*AgentV1AgentListResponse) UnmarshalJSON ¶ added in v0.2.0
func (r *AgentV1AgentListResponse) UnmarshalJSON(data []byte) (err error)
type AgentV1AgentListResponseAgent ¶ added in v0.2.0
type AgentV1AgentListResponseAgent struct {
ID string `json:"id"`
CreatedAt time.Time `json:"createdAt" format:"date-time"`
Description string `json:"description" api:"nullable"`
IsActive bool `json:"isActive"`
Model string `json:"model"`
Name string `json:"name"`
UpdatedAt time.Time `json:"updatedAt" format:"date-time"`
VaultIDs []string `json:"vaultIds" api:"nullable"`
JSON agentV1AgentListResponseAgentJSON `json:"-"`
}
func (*AgentV1AgentListResponseAgent) UnmarshalJSON ¶ added in v0.2.0
func (r *AgentV1AgentListResponseAgent) UnmarshalJSON(data []byte) (err error)
type AgentV1AgentNewParams ¶ added in v0.2.0
type AgentV1AgentNewParams struct {
// System instructions that define agent behavior
Instructions param.Field[string] `json:"instructions" api:"required"`
// Display name for the agent
Name param.Field[string] `json:"name" api:"required"`
// Optional description of the agent
Description param.Field[string] `json:"description"`
// Denylist of tools the agent cannot use. Mutually exclusive with enabledTools —
// set one or the other, not both.
DisabledTools param.Field[[]string] `json:"disabledTools"`
// Allowlist of tools the agent can use. Mutually exclusive with disabledTools —
// set one or the other, not both.
EnabledTools param.Field[[]string] `json:"enabledTools"`
// LLM model identifier (e.g. anthropic/claude-sonnet-4.6). Defaults to
// anthropic/claude-sonnet-4.6
Model param.Field[string] `json:"model"`
// Custom sandbox configuration (cpu, memoryMiB)
Sandbox param.Field[AgentV1AgentNewParamsSandbox] `json:"sandbox"`
// Restrict agent to vaults within specific vault group IDs
VaultGroups param.Field[[]string] `json:"vaultGroups"`
// Restrict agent to specific vault IDs
VaultIDs param.Field[[]string] `json:"vaultIds"`
}
func (AgentV1AgentNewParams) MarshalJSON ¶ added in v0.2.0
func (r AgentV1AgentNewParams) MarshalJSON() (data []byte, err error)
type AgentV1AgentNewParamsSandbox ¶ added in v0.2.0
type AgentV1AgentNewParamsSandbox struct {
// Number of CPUs
CPU param.Field[int64] `json:"cpu"`
// Memory in MiB
MemoryMiB param.Field[int64] `json:"memoryMiB"`
}
Custom sandbox configuration (cpu, memoryMiB)
func (AgentV1AgentNewParamsSandbox) MarshalJSON ¶ added in v0.2.0
func (r AgentV1AgentNewParamsSandbox) MarshalJSON() (data []byte, err error)
type AgentV1AgentNewResponse ¶ added in v0.2.0
type AgentV1AgentNewResponse struct {
ID string `json:"id"`
CreatedAt time.Time `json:"createdAt" format:"date-time"`
Description string `json:"description" api:"nullable"`
DisabledTools []string `json:"disabledTools" api:"nullable"`
EnabledTools []string `json:"enabledTools" api:"nullable"`
Instructions string `json:"instructions"`
Model string `json:"model"`
Name string `json:"name"`
Sandbox interface{} `json:"sandbox" api:"nullable"`
UpdatedAt time.Time `json:"updatedAt" format:"date-time"`
VaultIDs []string `json:"vaultIds" api:"nullable"`
JSON agentV1AgentNewResponseJSON `json:"-"`
}
func (*AgentV1AgentNewResponse) UnmarshalJSON ¶ added in v0.2.0
func (r *AgentV1AgentNewResponse) UnmarshalJSON(data []byte) (err error)
type AgentV1AgentService ¶ added in v0.2.0
type AgentV1AgentService struct {
Options []option.RequestOption
}
Create, manage, and execute AI agents with tool access, sandbox environments, and async run workflows
AgentV1AgentService contains methods and other services that help with interacting with the casedev API.
Note, unlike clients, this service does not read variables from the environment automatically. You should not instantiate this service directly, and instead use the NewAgentV1AgentService method instead.
func NewAgentV1AgentService ¶ added in v0.2.0
func NewAgentV1AgentService(opts ...option.RequestOption) (r *AgentV1AgentService)
NewAgentV1AgentService generates a new service that applies the given options to each request. These options are applied after the parent client's options (if there is one), and before any request-specific options.
func (*AgentV1AgentService) Delete ¶ added in v0.2.0
func (r *AgentV1AgentService) Delete(ctx context.Context, id string, opts ...option.RequestOption) (res *AgentV1AgentDeleteResponse, err error)
Soft-deletes an agent and revokes its scoped API key.
func (*AgentV1AgentService) Get ¶ added in v0.2.0
func (r *AgentV1AgentService) Get(ctx context.Context, id string, opts ...option.RequestOption) (res *AgentV1AgentGetResponse, err error)
Retrieves a single agent definition by ID.
func (*AgentV1AgentService) List ¶ added in v0.2.0
func (r *AgentV1AgentService) List(ctx context.Context, query AgentV1AgentListParams, opts ...option.RequestOption) (res *AgentV1AgentListResponse, err error)
Lists all active agents for the authenticated organization.
func (*AgentV1AgentService) New ¶ added in v0.2.0
func (r *AgentV1AgentService) New(ctx context.Context, body AgentV1AgentNewParams, opts ...option.RequestOption) (res *AgentV1AgentNewResponse, err error)
Creates a new agent definition with a scoped API key. The agent can then be used to create and execute runs.
func (*AgentV1AgentService) Update ¶ added in v0.2.0
func (r *AgentV1AgentService) Update(ctx context.Context, id string, body AgentV1AgentUpdateParams, opts ...option.RequestOption) (res *AgentV1AgentUpdateResponse, err error)
Updates an agent definition. Only provided fields are changed.
type AgentV1AgentUpdateParams ¶ added in v0.2.0
type AgentV1AgentUpdateParams struct {
// Updated agent description. Pass null to clear if supported by the client.
Description param.Field[string] `json:"description"`
// Denylist of tools the agent cannot use. Mutually exclusive with enabledTools —
// set one or the other, not both. Pass null to clear.
DisabledTools param.Field[[]string] `json:"disabledTools"`
// Allowlist of tools the agent can use. Mutually exclusive with disabledTools —
// set one or the other, not both. Pass null to clear.
EnabledTools param.Field[[]string] `json:"enabledTools"`
// Updated system instructions that guide agent behavior
Instructions param.Field[string] `json:"instructions"`
// Model identifier the agent should use for future runs
Model param.Field[string] `json:"model"`
// Updated agent display name
Name param.Field[string] `json:"name"`
// Sandbox configuration override for future agent runs. Pass null to clear.
Sandbox param.Field[interface{}] `json:"sandbox"`
// Vault group IDs the agent can access. Pass null to clear.
VaultGroups param.Field[[]string] `json:"vaultGroups"`
// Vault IDs the agent can access directly. Pass null to clear.
VaultIDs param.Field[[]string] `json:"vaultIds"`
}
func (AgentV1AgentUpdateParams) MarshalJSON ¶ added in v0.2.0
func (r AgentV1AgentUpdateParams) MarshalJSON() (data []byte, err error)
type AgentV1AgentUpdateResponse ¶ added in v0.2.0
type AgentV1AgentUpdateResponse struct {
ID string `json:"id"`
CreatedAt time.Time `json:"createdAt" format:"date-time"`
Description string `json:"description" api:"nullable"`
DisabledTools []string `json:"disabledTools" api:"nullable"`
EnabledTools []string `json:"enabledTools" api:"nullable"`
Instructions string `json:"instructions"`
IsActive bool `json:"isActive"`
Model string `json:"model"`
Name string `json:"name"`
Sandbox interface{} `json:"sandbox" api:"nullable"`
UpdatedAt time.Time `json:"updatedAt" format:"date-time"`
VaultGroups []string `json:"vaultGroups" api:"nullable"`
VaultIDs []string `json:"vaultIds" api:"nullable"`
JSON agentV1AgentUpdateResponseJSON `json:"-"`
}
func (*AgentV1AgentUpdateResponse) UnmarshalJSON ¶ added in v0.2.0
func (r *AgentV1AgentUpdateResponse) UnmarshalJSON(data []byte) (err error)
type AgentV1ChatCancelResponse ¶ added in v0.6.0
type AgentV1ChatCancelResponse struct {
ID string `json:"id"`
Ok bool `json:"ok"`
JSON agentV1ChatCancelResponseJSON `json:"-"`
}
func (*AgentV1ChatCancelResponse) UnmarshalJSON ¶ added in v0.6.0
func (r *AgentV1ChatCancelResponse) UnmarshalJSON(data []byte) (err error)
type AgentV1ChatDeleteResponse ¶ added in v0.6.0
type AgentV1ChatDeleteResponse struct {
ID string `json:"id"`
Cost float64 `json:"cost"`
RuntimeMs int64 `json:"runtimeMs"`
SnapshotImageID string `json:"snapshotImageId" api:"nullable"`
Status string `json:"status"`
JSON agentV1ChatDeleteResponseJSON `json:"-"`
}
func (*AgentV1ChatDeleteResponse) UnmarshalJSON ¶ added in v0.6.0
func (r *AgentV1ChatDeleteResponse) UnmarshalJSON(data []byte) (err error)
type AgentV1ChatFileListResponse ¶ added in v0.16.0
type AgentV1ChatFileListResponse struct {
ChatID string `json:"chatId"`
Files []AgentV1ChatFileListResponseFile `json:"files"`
JSON agentV1ChatFileListResponseJSON `json:"-"`
}
func (*AgentV1ChatFileListResponse) UnmarshalJSON ¶ added in v0.16.0
func (r *AgentV1ChatFileListResponse) UnmarshalJSON(data []byte) (err error)
type AgentV1ChatFileListResponseFile ¶ added in v0.16.0
type AgentV1ChatFileListResponseFile struct {
Name string `json:"name"`
// Relative path from /workspace
Path string `json:"path"`
SizeBytes int64 `json:"sizeBytes"`
JSON agentV1ChatFileListResponseFileJSON `json:"-"`
}
func (*AgentV1ChatFileListResponseFile) UnmarshalJSON ¶ added in v0.16.0
func (r *AgentV1ChatFileListResponseFile) UnmarshalJSON(data []byte) (err error)
type AgentV1ChatFileService ¶ added in v0.16.0
type AgentV1ChatFileService struct {
Options []option.RequestOption
}
Create, manage, and execute AI agents with tool access, sandbox environments, and async run workflows
AgentV1ChatFileService contains methods and other services that help with interacting with the casedev API.
Note, unlike clients, this service does not read variables from the environment automatically. You should not instantiate this service directly, and instead use the NewAgentV1ChatFileService method instead.
func NewAgentV1ChatFileService ¶ added in v0.16.0
func NewAgentV1ChatFileService(opts ...option.RequestOption) (r *AgentV1ChatFileService)
NewAgentV1ChatFileService generates a new service that applies the given options to each request. These options are applied after the parent client's options (if there is one), and before any request-specific options.
func (*AgentV1ChatFileService) Download ¶ added in v0.16.0
func (r *AgentV1ChatFileService) Download(ctx context.Context, id string, filePath string, opts ...option.RequestOption) (res *http.Response, err error)
Downloads a file from the sandbox workspace by path. Only available while the sandbox is running.
func (*AgentV1ChatFileService) List ¶ added in v0.16.0
func (r *AgentV1ChatFileService) List(ctx context.Context, id string, opts ...option.RequestOption) (res *AgentV1ChatFileListResponse, err error)
Lists files created by the agent in the sandbox workspace. Only available while the sandbox is running.
type AgentV1ChatNewParams ¶ added in v0.6.0
type AgentV1ChatNewParams struct {
// Idle timeout before session is eligible for snapshot/termination. Defaults to 15
// minutes.
IdleTimeoutMs param.Field[int64] `json:"idleTimeoutMs"`
// Optional model override for the chat runtime session
Model param.Field[string] `json:"model"`
// Optional human-readable session title
Title param.Field[string] `json:"title"`
// Restrict the chat session to specific vault IDs
VaultIDs param.Field[[]string] `json:"vaultIds"`
}
func (AgentV1ChatNewParams) MarshalJSON ¶ added in v0.6.0
func (r AgentV1ChatNewParams) MarshalJSON() (data []byte, err error)
type AgentV1ChatNewResponse ¶ added in v0.6.0
type AgentV1ChatNewResponse struct {
ID string `json:"id"`
CreatedAt time.Time `json:"createdAt" format:"date-time"`
IdleTimeoutMs int64 `json:"idleTimeoutMs"`
Status string `json:"status"`
JSON agentV1ChatNewResponseJSON `json:"-"`
}
func (*AgentV1ChatNewResponse) UnmarshalJSON ¶ added in v0.6.0
func (r *AgentV1ChatNewResponse) UnmarshalJSON(data []byte) (err error)
type AgentV1ChatReplyToQuestionParams ¶ added in v0.12.0
type AgentV1ChatReplyToQuestionParams struct {
// Answer selections for each prompt element in the pending question
Answers param.Field[[][]string] `json:"answers" api:"required"`
}
func (AgentV1ChatReplyToQuestionParams) MarshalJSON ¶ added in v0.12.0
func (r AgentV1ChatReplyToQuestionParams) MarshalJSON() (data []byte, err error)
type AgentV1ChatRespondParams ¶ added in v0.9.0
type AgentV1ChatRespondParams struct {
// Message content parts. Currently only "text" type is supported. Additional types
// (e.g. file, image) may be added in future versions.
Parts param.Field[[]AgentV1ChatRespondParamsPart] `json:"parts"`
}
func (AgentV1ChatRespondParams) MarshalJSON ¶ added in v0.9.0
func (r AgentV1ChatRespondParams) MarshalJSON() (data []byte, err error)
type AgentV1ChatRespondParamsPart ¶ added in v0.13.0
type AgentV1ChatRespondParamsPart struct {
// The message text content
Text param.Field[string] `json:"text" api:"required"`
// Part type. Currently only "text" is supported.
Type param.Field[AgentV1ChatRespondParamsPartsType] `json:"type" api:"required"`
}
func (AgentV1ChatRespondParamsPart) MarshalJSON ¶ added in v0.13.0
func (r AgentV1ChatRespondParamsPart) MarshalJSON() (data []byte, err error)
type AgentV1ChatRespondParamsPartsType ¶ added in v0.13.0
type AgentV1ChatRespondParamsPartsType string
Part type. Currently only "text" is supported.
const (
AgentV1ChatRespondParamsPartsTypeText AgentV1ChatRespondParamsPartsType = "text"
)
func (AgentV1ChatRespondParamsPartsType) IsKnown ¶ added in v0.13.0
func (r AgentV1ChatRespondParamsPartsType) IsKnown() bool
type AgentV1ChatSendMessageParams ¶ added in v0.6.0
type AgentV1ChatSendMessageParams struct {
// Message content parts. Currently only "text" type is supported. Additional types
// (e.g. file, image) may be added in future versions.
Parts param.Field[[]AgentV1ChatSendMessageParamsPart] `json:"parts"`
}
func (AgentV1ChatSendMessageParams) MarshalJSON ¶ added in v0.6.0
func (r AgentV1ChatSendMessageParams) MarshalJSON() (data []byte, err error)
type AgentV1ChatSendMessageParamsPart ¶ added in v0.13.0
type AgentV1ChatSendMessageParamsPart struct {
// The message text content
Text param.Field[string] `json:"text" api:"required"`
// Part type. Currently only "text" is supported.
Type param.Field[AgentV1ChatSendMessageParamsPartsType] `json:"type" api:"required"`
}
func (AgentV1ChatSendMessageParamsPart) MarshalJSON ¶ added in v0.13.0
func (r AgentV1ChatSendMessageParamsPart) MarshalJSON() (data []byte, err error)
type AgentV1ChatSendMessageParamsPartsType ¶ added in v0.13.0
type AgentV1ChatSendMessageParamsPartsType string
Part type. Currently only "text" is supported.
const (
AgentV1ChatSendMessageParamsPartsTypeText AgentV1ChatSendMessageParamsPartsType = "text"
)
func (AgentV1ChatSendMessageParamsPartsType) IsKnown ¶ added in v0.13.0
func (r AgentV1ChatSendMessageParamsPartsType) IsKnown() bool
type AgentV1ChatService ¶ added in v0.6.0
type AgentV1ChatService struct {
Options []option.RequestOption
// Create, manage, and execute AI agents with tool access, sandbox environments,
// and async run workflows
Files *AgentV1ChatFileService
}
Create, manage, and execute AI agents with tool access, sandbox environments, and async run workflows
AgentV1ChatService contains methods and other services that help with interacting with the casedev API.
Note, unlike clients, this service does not read variables from the environment automatically. You should not instantiate this service directly, and instead use the NewAgentV1ChatService method instead.
func NewAgentV1ChatService ¶ added in v0.6.0
func NewAgentV1ChatService(opts ...option.RequestOption) (r *AgentV1ChatService)
NewAgentV1ChatService generates a new service that applies the given options to each request. These options are applied after the parent client's options (if there is one), and before any request-specific options.
func (*AgentV1ChatService) Cancel ¶ added in v0.6.0
func (r *AgentV1ChatService) Cancel(ctx context.Context, id string, opts ...option.RequestOption) (res *AgentV1ChatCancelResponse, err error)
Aborts the active generation for this chat session.
func (*AgentV1ChatService) Delete ¶ added in v0.6.0
func (r *AgentV1ChatService) Delete(ctx context.Context, id string, opts ...option.RequestOption) (res *AgentV1ChatDeleteResponse, err error)
Snapshots and terminates the active sandbox (if any), then marks the chat as ended.
func (*AgentV1ChatService) New ¶ added in v0.6.0
func (r *AgentV1ChatService) New(ctx context.Context, body AgentV1ChatNewParams, opts ...option.RequestOption) (res *AgentV1ChatNewResponse, err error)
Creates a persistent chat session backed by a Daytona or Vercel runtime. Session state is retained and can be resumed or recovered across requests.
func (*AgentV1ChatService) ReplyToQuestion ¶ added in v0.12.0
func (r *AgentV1ChatService) ReplyToQuestion(ctx context.Context, id string, requestID string, body AgentV1ChatReplyToQuestionParams, opts ...option.RequestOption) (err error)
Answers a pending runtime question for the chat session bound to this agent chat.
func (*AgentV1ChatService) RespondStreaming ¶ added in v0.9.0
func (r *AgentV1ChatService) RespondStreaming(ctx context.Context, id string, body AgentV1ChatRespondParams, opts ...option.RequestOption) (stream *ssestream.Stream[string])
Streams a single assistant turn as normalized SSE events with stable turn, message, and part IDs. Emits events: `turn.started`, `turn.status`, `message.created`, `message.part.updated`, `message.completed`, `session.usage`, `turn.completed`.
**When to use this endpoint:** Recommended for building custom chat UIs that need real-time streaming progress. This is the primary streaming endpoint for new integrations.
**Alternatives:**
- `POST /chat/:id/message` — synchronous, returns complete response as JSON (best for server-to-server)
func (*AgentV1ChatService) SendMessage ¶ added in v0.6.0
func (r *AgentV1ChatService) SendMessage(ctx context.Context, id string, body AgentV1ChatSendMessageParams, opts ...option.RequestOption) (err error)
Sends a message and returns the complete response as a single JSON body. Blocks until the agent turn completes.
**When to use this endpoint:** Best for server-to-server integrations, background processing, or any context where you want the full response in one call without managing an SSE stream.
**Alternatives:**
- `POST /chat/:id/respond` — streaming SSE with normalized events (recommended for custom chat UIs)
func (*AgentV1ChatService) StreamStreaming ¶ added in v0.6.0
func (r *AgentV1ChatService) StreamStreaming(ctx context.Context, id string, query AgentV1ChatStreamParams, opts ...option.RequestOption) (stream *ssestream.Stream[string])
Relays runtime SSE events for this chat. Supports replay from buffered events using Last-Event-ID.
type AgentV1ChatStreamParams ¶ added in v0.6.0
type AgentV1ChatStreamParams struct {
// Replay events after this sequence number
LastEventID param.Field[int64] `query:"lastEventId"`
}
func (AgentV1ChatStreamParams) URLQuery ¶ added in v0.6.0
func (r AgentV1ChatStreamParams) URLQuery() (v url.Values)
URLQuery serializes AgentV1ChatStreamParams's query parameters as `url.Values`.
type AgentV1ExecuteNewParams ¶ added in v0.4.0
type AgentV1ExecuteNewParams struct {
// Task prompt for the agent
Prompt param.Field[string] `json:"prompt" api:"required"`
// Denylist of tools the agent cannot use. Mutually exclusive with enabledTools —
// set one or the other, not both.
DisabledTools param.Field[[]string] `json:"disabledTools"`
// Allowlist of tools the agent can use. Mutually exclusive with disabledTools —
// set one or the other, not both.
EnabledTools param.Field[[]string] `json:"enabledTools"`
// Additional context or constraints for this run
Guidance param.Field[string] `json:"guidance"`
// System instructions. Defaults to a general-purpose legal assistant prompt if not
// provided.
Instructions param.Field[string] `json:"instructions"`
// LLM model identifier. Defaults to anthropic/claude-sonnet-4.6
Model param.Field[string] `json:"model"`
// Scope this run to specific vault object IDs. The agent will only access these
// objects.
ObjectIDs param.Field[[]string] `json:"objectIds"`
// Custom sandbox resources (cpu, memoryMiB)
Sandbox param.Field[AgentV1ExecuteNewParamsSandbox] `json:"sandbox"`
// Restrict agent to specific vault IDs
VaultIDs param.Field[[]string] `json:"vaultIds"`
}
func (AgentV1ExecuteNewParams) MarshalJSON ¶ added in v0.4.0
func (r AgentV1ExecuteNewParams) MarshalJSON() (data []byte, err error)
type AgentV1ExecuteNewParamsSandbox ¶ added in v0.4.0
type AgentV1ExecuteNewParamsSandbox struct {
// Number of CPUs
CPU param.Field[int64] `json:"cpu"`
// Memory in MiB
MemoryMiB param.Field[int64] `json:"memoryMiB"`
}
Custom sandbox resources (cpu, memoryMiB)
func (AgentV1ExecuteNewParamsSandbox) MarshalJSON ¶ added in v0.4.0
func (r AgentV1ExecuteNewParamsSandbox) MarshalJSON() (data []byte, err error)
type AgentV1ExecuteNewResponse ¶ added in v0.4.0
type AgentV1ExecuteNewResponse struct {
// Ephemeral agent ID (auto-created). This agent is soft-deleted when the run
// completes and should not be stored for reuse.
AgentID string `json:"agentId"`
Message string `json:"message"`
// Run ID — poll /agent/v1/run/:id/status
RunID string `json:"runId"`
Status AgentV1ExecuteNewResponseStatus `json:"status"`
JSON agentV1ExecuteNewResponseJSON `json:"-"`
}
func (*AgentV1ExecuteNewResponse) UnmarshalJSON ¶ added in v0.4.0
func (r *AgentV1ExecuteNewResponse) UnmarshalJSON(data []byte) (err error)
type AgentV1ExecuteNewResponseStatus ¶ added in v0.4.0
type AgentV1ExecuteNewResponseStatus string
const (
AgentV1ExecuteNewResponseStatusRunning AgentV1ExecuteNewResponseStatus = "running"
)
func (AgentV1ExecuteNewResponseStatus) IsKnown ¶ added in v0.4.0
func (r AgentV1ExecuteNewResponseStatus) IsKnown() bool
type AgentV1ExecuteService ¶ added in v0.4.0
type AgentV1ExecuteService struct {
Options []option.RequestOption
}
Create, manage, and execute AI agents with tool access, sandbox environments, and async run workflows
AgentV1ExecuteService contains methods and other services that help with interacting with the casedev API.
Note, unlike clients, this service does not read variables from the environment automatically. You should not instantiate this service directly, and instead use the NewAgentV1ExecuteService method instead.
func NewAgentV1ExecuteService ¶ added in v0.4.0
func NewAgentV1ExecuteService(opts ...option.RequestOption) (r *AgentV1ExecuteService)
NewAgentV1ExecuteService generates a new service that applies the given options to each request. These options are applied after the parent client's options (if there is one), and before any request-specific options.
func (*AgentV1ExecuteService) New ¶ added in v0.4.0
func (r *AgentV1ExecuteService) New(ctx context.Context, body AgentV1ExecuteNewParams, opts ...option.RequestOption) (res *AgentV1ExecuteNewResponse, err error)
Creates an ephemeral agent and immediately executes a run. Returns the run ID for polling status and results. This is the fastest way to run an agent without managing agent lifecycle.
**Ephemeral agent lifecycle:** The agent created by this endpoint is automatically soft-deleted and its scoped API key revoked when the run completes (whether it succeeds, fails, or times out). Ephemeral agents do not appear in GET /agent/v1/agents listings. The returned agentId is valid only for the duration of the run — do not store it for reuse. For persistent, reusable agents, use POST /agent/v1/agents instead.
type AgentV1RunCancelResponse ¶ added in v0.2.0
type AgentV1RunCancelResponse struct {
ID string `json:"id"`
// Present if run was already finished
Message string `json:"message"`
Status AgentV1RunCancelResponseStatus `json:"status"`
JSON agentV1RunCancelResponseJSON `json:"-"`
}
func (*AgentV1RunCancelResponse) UnmarshalJSON ¶ added in v0.2.0
func (r *AgentV1RunCancelResponse) UnmarshalJSON(data []byte) (err error)
type AgentV1RunCancelResponseStatus ¶ added in v0.2.0
type AgentV1RunCancelResponseStatus string
const ( AgentV1RunCancelResponseStatusCancelled AgentV1RunCancelResponseStatus = "cancelled" AgentV1RunCancelResponseStatusCompleted AgentV1RunCancelResponseStatus = "completed" AgentV1RunCancelResponseStatusFailed AgentV1RunCancelResponseStatus = "failed" )
func (AgentV1RunCancelResponseStatus) IsKnown ¶ added in v0.2.0
func (r AgentV1RunCancelResponseStatus) IsKnown() bool
type AgentV1RunEventsParams ¶ added in v0.9.0
type AgentV1RunEventsParams struct {
// Replay events after this sequence number
LastEventID param.Field[int64] `query:"lastEventId"`
}
func (AgentV1RunEventsParams) URLQuery ¶ added in v0.9.0
func (r AgentV1RunEventsParams) URLQuery() (v url.Values)
URLQuery serializes AgentV1RunEventsParams's query parameters as `url.Values`.
type AgentV1RunExecResponse ¶ added in v0.2.0
type AgentV1RunExecResponse struct {
ID string `json:"id"`
Message string `json:"message"`
Status AgentV1RunExecResponseStatus `json:"status"`
// Durable workflow run ID
WorkflowID string `json:"workflowId"`
JSON agentV1RunExecResponseJSON `json:"-"`
}
func (*AgentV1RunExecResponse) UnmarshalJSON ¶ added in v0.2.0
func (r *AgentV1RunExecResponse) UnmarshalJSON(data []byte) (err error)
type AgentV1RunExecResponseStatus ¶ added in v0.2.0
type AgentV1RunExecResponseStatus string
const (
AgentV1RunExecResponseStatusRunning AgentV1RunExecResponseStatus = "running"
)
func (AgentV1RunExecResponseStatus) IsKnown ¶ added in v0.2.0
func (r AgentV1RunExecResponseStatus) IsKnown() bool
type AgentV1RunGetDetailsResponse ¶ added in v0.2.0
type AgentV1RunGetDetailsResponse struct {
ID string `json:"id"`
AgentID string `json:"agentId"`
CompletedAt time.Time `json:"completedAt" api:"nullable" format:"date-time"`
CreatedAt time.Time `json:"createdAt" format:"date-time"`
Guidance string `json:"guidance" api:"nullable"`
// Deprecated legacy Modal sandbox ID. Prefer `provider` and `runtimeId`.
//
// Deprecated: deprecated
ModalSandboxID string `json:"modalSandboxId" api:"nullable"`
Model string `json:"model" api:"nullable"`
Prompt string `json:"prompt"`
// Runtime provider for this run
Provider AgentV1RunGetDetailsResponseProvider `json:"provider" api:"nullable"`
// Final output from the agent
Result AgentV1RunGetDetailsResponseResult `json:"result" api:"nullable"`
// Provider-specific runtime identifier
RuntimeID string `json:"runtimeId" api:"nullable"`
// Current runtime state, when available
RuntimeState AgentV1RunGetDetailsResponseRuntimeState `json:"runtimeState" api:"nullable"`
StartedAt time.Time `json:"startedAt" api:"nullable" format:"date-time"`
Status AgentV1RunGetDetailsResponseStatus `json:"status"`
Steps []AgentV1RunGetDetailsResponseStep `json:"steps"`
// Token usage statistics
Usage AgentV1RunGetDetailsResponseUsage `json:"usage" api:"nullable"`
// Durable workflow run ID
WorkflowID string `json:"workflowId" api:"nullable"`
JSON agentV1RunGetDetailsResponseJSON `json:"-"`
}
func (*AgentV1RunGetDetailsResponse) UnmarshalJSON ¶ added in v0.2.0
func (r *AgentV1RunGetDetailsResponse) UnmarshalJSON(data []byte) (err error)
type AgentV1RunGetDetailsResponseProvider ¶ added in v0.35.0
type AgentV1RunGetDetailsResponseProvider string
Runtime provider for this run
const ( AgentV1RunGetDetailsResponseProviderDaytona AgentV1RunGetDetailsResponseProvider = "daytona" AgentV1RunGetDetailsResponseProviderVercel AgentV1RunGetDetailsResponseProvider = "vercel" )
func (AgentV1RunGetDetailsResponseProvider) IsKnown ¶ added in v0.35.0
func (r AgentV1RunGetDetailsResponseProvider) IsKnown() bool
type AgentV1RunGetDetailsResponseResult ¶ added in v0.2.0
type AgentV1RunGetDetailsResponseResult struct {
// Compact agent-facing result summary and execution issues
FinalResponse AgentV1RunGetDetailsResponseResultFinalResponse `json:"finalResponse" api:"nullable"`
// Sandbox execution logs (runtime server + runner script)
Logs AgentV1RunGetDetailsResponseResultLogs `json:"logs" api:"nullable"`
Output string `json:"output"`
OutputObjectIDs []string `json:"outputObjectIds"`
JSON agentV1RunGetDetailsResponseResultJSON `json:"-"`
}
Final output from the agent
func (*AgentV1RunGetDetailsResponseResult) UnmarshalJSON ¶ added in v0.2.0
func (r *AgentV1RunGetDetailsResponseResult) UnmarshalJSON(data []byte) (err error)
type AgentV1RunGetDetailsResponseResultFinalResponse ¶ added in v0.10.0
type AgentV1RunGetDetailsResponseResultFinalResponse struct {
CreatedObjectIDs []string `json:"createdObjectIds"`
Issues []string `json:"issues"`
Summary string `json:"summary"`
JSON agentV1RunGetDetailsResponseResultFinalResponseJSON `json:"-"`
}
Compact agent-facing result summary and execution issues
func (*AgentV1RunGetDetailsResponseResultFinalResponse) UnmarshalJSON ¶ added in v0.10.0
func (r *AgentV1RunGetDetailsResponseResultFinalResponse) UnmarshalJSON(data []byte) (err error)
type AgentV1RunGetDetailsResponseResultLogs ¶ added in v0.2.0
type AgentV1RunGetDetailsResponseResultLogs struct {
// Legacy runtime server stdout/stderr
Opencode string `json:"opencode"`
// Runner script stdout/stderr
Runner string `json:"runner"`
// Runtime server stdout/stderr
Runtime string `json:"runtime"`
JSON agentV1RunGetDetailsResponseResultLogsJSON `json:"-"`
}
Sandbox execution logs (runtime server + runner script)
func (*AgentV1RunGetDetailsResponseResultLogs) UnmarshalJSON ¶ added in v0.2.0
func (r *AgentV1RunGetDetailsResponseResultLogs) UnmarshalJSON(data []byte) (err error)
type AgentV1RunGetDetailsResponseRuntimeState ¶ added in v0.35.0
type AgentV1RunGetDetailsResponseRuntimeState string
Current runtime state, when available
const ( AgentV1RunGetDetailsResponseRuntimeStateRunning AgentV1RunGetDetailsResponseRuntimeState = "running" AgentV1RunGetDetailsResponseRuntimeStateStopped AgentV1RunGetDetailsResponseRuntimeState = "stopped" AgentV1RunGetDetailsResponseRuntimeStateArchived AgentV1RunGetDetailsResponseRuntimeState = "archived" AgentV1RunGetDetailsResponseRuntimeStateEnded AgentV1RunGetDetailsResponseRuntimeState = "ended" AgentV1RunGetDetailsResponseRuntimeStateError AgentV1RunGetDetailsResponseRuntimeState = "error" )
func (AgentV1RunGetDetailsResponseRuntimeState) IsKnown ¶ added in v0.35.0
func (r AgentV1RunGetDetailsResponseRuntimeState) IsKnown() bool
type AgentV1RunGetDetailsResponseStatus ¶ added in v0.2.0
type AgentV1RunGetDetailsResponseStatus string
const ( AgentV1RunGetDetailsResponseStatusQueued AgentV1RunGetDetailsResponseStatus = "queued" AgentV1RunGetDetailsResponseStatusRunning AgentV1RunGetDetailsResponseStatus = "running" AgentV1RunGetDetailsResponseStatusCompleted AgentV1RunGetDetailsResponseStatus = "completed" AgentV1RunGetDetailsResponseStatusFailed AgentV1RunGetDetailsResponseStatus = "failed" AgentV1RunGetDetailsResponseStatusCancelled AgentV1RunGetDetailsResponseStatus = "cancelled" )
func (AgentV1RunGetDetailsResponseStatus) IsKnown ¶ added in v0.2.0
func (r AgentV1RunGetDetailsResponseStatus) IsKnown() bool
type AgentV1RunGetDetailsResponseStep ¶ added in v0.2.0
type AgentV1RunGetDetailsResponseStep struct {
ID string `json:"id"`
Content string `json:"content" api:"nullable"`
DurationMs int64 `json:"durationMs" api:"nullable"`
Timestamp time.Time `json:"timestamp" format:"date-time"`
ToolInput interface{} `json:"toolInput"`
ToolName string `json:"toolName" api:"nullable"`
ToolOutput interface{} `json:"toolOutput"`
Type AgentV1RunGetDetailsResponseStepsType `json:"type"`
JSON agentV1RunGetDetailsResponseStepJSON `json:"-"`
}
func (*AgentV1RunGetDetailsResponseStep) UnmarshalJSON ¶ added in v0.2.0
func (r *AgentV1RunGetDetailsResponseStep) UnmarshalJSON(data []byte) (err error)
type AgentV1RunGetDetailsResponseStepsType ¶ added in v0.2.0
type AgentV1RunGetDetailsResponseStepsType string
const ( AgentV1RunGetDetailsResponseStepsTypeOutput AgentV1RunGetDetailsResponseStepsType = "output" AgentV1RunGetDetailsResponseStepsTypeThinking AgentV1RunGetDetailsResponseStepsType = "thinking" AgentV1RunGetDetailsResponseStepsTypeToolCall AgentV1RunGetDetailsResponseStepsType = "tool_call" AgentV1RunGetDetailsResponseStepsTypeToolResult AgentV1RunGetDetailsResponseStepsType = "tool_result" )
func (AgentV1RunGetDetailsResponseStepsType) IsKnown ¶ added in v0.2.0
func (r AgentV1RunGetDetailsResponseStepsType) IsKnown() bool
type AgentV1RunGetDetailsResponseUsage ¶ added in v0.2.0
type AgentV1RunGetDetailsResponseUsage struct {
DurationMs int64 `json:"durationMs"`
Entries []AgentV1RunGetDetailsResponseUsageEntry `json:"entries"`
InputTokens int64 `json:"inputTokens"`
Model string `json:"model"`
OutputTokens int64 `json:"outputTokens"`
Summary AgentV1RunGetDetailsResponseUsageSummary `json:"summary" api:"nullable"`
ToolCalls int64 `json:"toolCalls"`
JSON agentV1RunGetDetailsResponseUsageJSON `json:"-"`
}
Token usage statistics
func (*AgentV1RunGetDetailsResponseUsage) UnmarshalJSON ¶ added in v0.2.0
func (r *AgentV1RunGetDetailsResponseUsage) UnmarshalJSON(data []byte) (err error)
type AgentV1RunGetDetailsResponseUsageEntriesKind ¶ added in v0.12.0
type AgentV1RunGetDetailsResponseUsageEntriesKind string
const ( AgentV1RunGetDetailsResponseUsageEntriesKindLlm AgentV1RunGetDetailsResponseUsageEntriesKind = "llm" AgentV1RunGetDetailsResponseUsageEntriesKindAPI AgentV1RunGetDetailsResponseUsageEntriesKind = "api" )
func (AgentV1RunGetDetailsResponseUsageEntriesKind) IsKnown ¶ added in v0.12.0
func (r AgentV1RunGetDetailsResponseUsageEntriesKind) IsKnown() bool
type AgentV1RunGetDetailsResponseUsageEntry ¶ added in v0.12.0
type AgentV1RunGetDetailsResponseUsageEntry struct {
ID string `json:"id"`
CompletionTokens int64 `json:"completionTokens" api:"nullable"`
CostMicros int64 `json:"costMicros"`
Endpoint string `json:"endpoint" api:"nullable"`
Kind AgentV1RunGetDetailsResponseUsageEntriesKind `json:"kind"`
Metadata interface{} `json:"metadata"`
Method string `json:"method" api:"nullable"`
Model string `json:"model" api:"nullable"`
PromptTokens int64 `json:"promptTokens" api:"nullable"`
Service string `json:"service"`
StatusCode int64 `json:"statusCode" api:"nullable"`
Timestamp time.Time `json:"timestamp" format:"date-time"`
TotalTokens int64 `json:"totalTokens" api:"nullable"`
JSON agentV1RunGetDetailsResponseUsageEntryJSON `json:"-"`
}
func (*AgentV1RunGetDetailsResponseUsageEntry) UnmarshalJSON ¶ added in v0.12.0
func (r *AgentV1RunGetDetailsResponseUsageEntry) UnmarshalJSON(data []byte) (err error)
type AgentV1RunGetDetailsResponseUsageSummary ¶ added in v0.12.0
type AgentV1RunGetDetailsResponseUsageSummary struct {
CostMicros int64 `json:"costMicros"`
TotalInputTokens int64 `json:"totalInputTokens"`
TotalOutputTokens int64 `json:"totalOutputTokens"`
TotalTokens int64 `json:"totalTokens"`
JSON agentV1RunGetDetailsResponseUsageSummaryJSON `json:"-"`
}
func (*AgentV1RunGetDetailsResponseUsageSummary) UnmarshalJSON ¶ added in v0.12.0
func (r *AgentV1RunGetDetailsResponseUsageSummary) UnmarshalJSON(data []byte) (err error)
type AgentV1RunGetStatusResponse ¶ added in v0.2.0
type AgentV1RunGetStatusResponse struct {
ID string `json:"id"`
CompletedAt time.Time `json:"completedAt" api:"nullable" format:"date-time"`
// Elapsed time in milliseconds
DurationMs int64 `json:"durationMs" api:"nullable"`
StartedAt time.Time `json:"startedAt" api:"nullable" format:"date-time"`
Status AgentV1RunGetStatusResponseStatus `json:"status"`
JSON agentV1RunGetStatusResponseJSON `json:"-"`
}
func (*AgentV1RunGetStatusResponse) UnmarshalJSON ¶ added in v0.2.0
func (r *AgentV1RunGetStatusResponse) UnmarshalJSON(data []byte) (err error)
type AgentV1RunGetStatusResponseStatus ¶ added in v0.2.0
type AgentV1RunGetStatusResponseStatus string
const ( AgentV1RunGetStatusResponseStatusQueued AgentV1RunGetStatusResponseStatus = "queued" AgentV1RunGetStatusResponseStatusRunning AgentV1RunGetStatusResponseStatus = "running" AgentV1RunGetStatusResponseStatusCompleted AgentV1RunGetStatusResponseStatus = "completed" AgentV1RunGetStatusResponseStatusFailed AgentV1RunGetStatusResponseStatus = "failed" AgentV1RunGetStatusResponseStatusCancelled AgentV1RunGetStatusResponseStatus = "cancelled" )
func (AgentV1RunGetStatusResponseStatus) IsKnown ¶ added in v0.2.0
func (r AgentV1RunGetStatusResponseStatus) IsKnown() bool
type AgentV1RunListParams ¶ added in v0.13.0
type AgentV1RunListParams struct {
// Filter by agent ID
AgentID param.Field[string] `query:"agentId"`
// Pagination cursor (run ID from previous page). Returns runs created before this
// run.
Cursor param.Field[string] `query:"cursor"`
// Maximum number of runs to return (default 50, max 250)
Limit param.Field[int64] `query:"limit"`
// Filter by run status
Status param.Field[AgentV1RunListParamsStatus] `query:"status"`
}
func (AgentV1RunListParams) URLQuery ¶ added in v0.13.0
func (r AgentV1RunListParams) URLQuery() (v url.Values)
URLQuery serializes AgentV1RunListParams's query parameters as `url.Values`.
type AgentV1RunListParamsStatus ¶ added in v0.13.0
type AgentV1RunListParamsStatus string
Filter by run status
const ( AgentV1RunListParamsStatusQueued AgentV1RunListParamsStatus = "queued" AgentV1RunListParamsStatusRunning AgentV1RunListParamsStatus = "running" AgentV1RunListParamsStatusCompleted AgentV1RunListParamsStatus = "completed" AgentV1RunListParamsStatusFailed AgentV1RunListParamsStatus = "failed" AgentV1RunListParamsStatusCancelled AgentV1RunListParamsStatus = "cancelled" )
func (AgentV1RunListParamsStatus) IsKnown ¶ added in v0.13.0
func (r AgentV1RunListParamsStatus) IsKnown() bool
type AgentV1RunListResponse ¶ added in v0.13.0
type AgentV1RunListResponse struct {
HasMore bool `json:"hasMore"`
// Pass as cursor to fetch the next page
NextCursor string `json:"nextCursor" api:"nullable"`
Runs []AgentV1RunListResponseRun `json:"runs"`
JSON agentV1RunListResponseJSON `json:"-"`
}
func (*AgentV1RunListResponse) UnmarshalJSON ¶ added in v0.13.0
func (r *AgentV1RunListResponse) UnmarshalJSON(data []byte) (err error)
type AgentV1RunListResponseRun ¶ added in v0.13.0
type AgentV1RunListResponseRun struct {
ID string `json:"id"`
AgentID string `json:"agentId"`
CompletedAt time.Time `json:"completedAt" api:"nullable" format:"date-time"`
CreatedAt time.Time `json:"createdAt" format:"date-time"`
Model string `json:"model" api:"nullable"`
// Truncated to first 200 characters
Prompt string `json:"prompt"`
StartedAt time.Time `json:"startedAt" api:"nullable" format:"date-time"`
Status AgentV1RunListResponseRunsStatus `json:"status"`
JSON agentV1RunListResponseRunJSON `json:"-"`
}
func (*AgentV1RunListResponseRun) UnmarshalJSON ¶ added in v0.13.0
func (r *AgentV1RunListResponseRun) UnmarshalJSON(data []byte) (err error)
type AgentV1RunListResponseRunsStatus ¶ added in v0.13.0
type AgentV1RunListResponseRunsStatus string
const ( AgentV1RunListResponseRunsStatusQueued AgentV1RunListResponseRunsStatus = "queued" AgentV1RunListResponseRunsStatusRunning AgentV1RunListResponseRunsStatus = "running" AgentV1RunListResponseRunsStatusCompleted AgentV1RunListResponseRunsStatus = "completed" AgentV1RunListResponseRunsStatusFailed AgentV1RunListResponseRunsStatus = "failed" AgentV1RunListResponseRunsStatusCancelled AgentV1RunListResponseRunsStatus = "cancelled" )
func (AgentV1RunListResponseRunsStatus) IsKnown ¶ added in v0.13.0
func (r AgentV1RunListResponseRunsStatus) IsKnown() bool
type AgentV1RunNewParams ¶ added in v0.2.0
type AgentV1RunNewParams struct {
// ID of the agent to run
AgentID param.Field[string] `json:"agentId" api:"required"`
// Task prompt for the agent
Prompt param.Field[string] `json:"prompt" api:"required"`
// HTTPS callback URL to receive a notification when the run completes. Registered
// atomically with the run — eliminates the race condition of calling /watch after
// /exec. Additional watchers can still be added via POST /run/:id/watch.
CallbackURL param.Field[string] `json:"callbackUrl" format:"uri"`
// Additional guidance for this run
Guidance param.Field[string] `json:"guidance"`
// Override the agent default model for this run
Model param.Field[string] `json:"model"`
// Scope this run to specific vault object IDs. The agent will only be able to
// access these objects during execution.
ObjectIDs param.Field[[]string] `json:"objectIds"`
}
func (AgentV1RunNewParams) MarshalJSON ¶ added in v0.2.0
func (r AgentV1RunNewParams) MarshalJSON() (data []byte, err error)
type AgentV1RunNewResponse ¶ added in v0.2.0
type AgentV1RunNewResponse struct {
ID string `json:"id"`
AgentID string `json:"agentId"`
CreatedAt time.Time `json:"createdAt" format:"date-time"`
ObjectIDs []string `json:"objectIds" api:"nullable"`
Status AgentV1RunNewResponseStatus `json:"status"`
JSON agentV1RunNewResponseJSON `json:"-"`
}
func (*AgentV1RunNewResponse) UnmarshalJSON ¶ added in v0.2.0
func (r *AgentV1RunNewResponse) UnmarshalJSON(data []byte) (err error)
type AgentV1RunNewResponseStatus ¶ added in v0.2.0
type AgentV1RunNewResponseStatus string
const (
AgentV1RunNewResponseStatusQueued AgentV1RunNewResponseStatus = "queued"
)
func (AgentV1RunNewResponseStatus) IsKnown ¶ added in v0.2.0
func (r AgentV1RunNewResponseStatus) IsKnown() bool
type AgentV1RunService ¶ added in v0.2.0
type AgentV1RunService struct {
Options []option.RequestOption
}
Create, manage, and execute AI agents with tool access, sandbox environments, and async run workflows
AgentV1RunService contains methods and other services that help with interacting with the casedev API.
Note, unlike clients, this service does not read variables from the environment automatically. You should not instantiate this service directly, and instead use the NewAgentV1RunService method instead.
func NewAgentV1RunService ¶ added in v0.2.0
func NewAgentV1RunService(opts ...option.RequestOption) (r *AgentV1RunService)
NewAgentV1RunService generates a new service that applies the given options to each request. These options are applied after the parent client's options (if there is one), and before any request-specific options.
func (*AgentV1RunService) Cancel ¶ added in v0.2.0
func (r *AgentV1RunService) Cancel(ctx context.Context, id string, opts ...option.RequestOption) (res *AgentV1RunCancelResponse, err error)
Cancels a running or queued run. Idempotent — cancelling a finished run returns its current status.
func (*AgentV1RunService) EventsStreaming ¶ added in v0.9.0
func (r *AgentV1RunService) EventsStreaming(ctx context.Context, id string, query AgentV1RunEventsParams, opts ...option.RequestOption) (stream *ssestream.Stream[string])
Streams real-time run events over SSE. Supports replay using Last-Event-ID.
func (*AgentV1RunService) Exec ¶ added in v0.2.0
func (r *AgentV1RunService) Exec(ctx context.Context, id string, opts ...option.RequestOption) (res *AgentV1RunExecResponse, err error)
Starts execution of a queued run. The agent runs in a durable workflow — poll /run/:id/status for progress.
func (*AgentV1RunService) GetDetails ¶ added in v0.2.0
func (r *AgentV1RunService) GetDetails(ctx context.Context, id string, opts ...option.RequestOption) (res *AgentV1RunGetDetailsResponse, err error)
Full audit trail for a run including output, steps (tool calls, text), and token usage.
func (*AgentV1RunService) GetStatus ¶ added in v0.2.0
func (r *AgentV1RunService) GetStatus(ctx context.Context, id string, opts ...option.RequestOption) (res *AgentV1RunGetStatusResponse, err error)
Lightweight status poll for a run. Use /run/:id/details for the full audit trail.
func (*AgentV1RunService) List ¶ added in v0.13.0
func (r *AgentV1RunService) List(ctx context.Context, query AgentV1RunListParams, opts ...option.RequestOption) (res *AgentV1RunListResponse, err error)
Lists agent runs for the authenticated organization. Supports filtering by agent, status, and cursor-based pagination.
func (*AgentV1RunService) New ¶ added in v0.2.0
func (r *AgentV1RunService) New(ctx context.Context, body AgentV1RunNewParams, opts ...option.RequestOption) (res *AgentV1RunNewResponse, err error)
Creates a run in queued state. Call POST /agent/v1/run/:id/exec to start execution.
func (*AgentV1RunService) Watch ¶ added in v0.2.0
func (r *AgentV1RunService) Watch(ctx context.Context, id string, body AgentV1RunWatchParams, opts ...option.RequestOption) (res *AgentV1RunWatchResponse, err error)
Register a callback URL to receive notifications when the run completes. URL must use https and must not point to a private network.
type AgentV1RunWatchParams ¶ added in v0.2.0
type AgentV1RunWatchParams struct {
// HTTPS URL to receive completion callback
CallbackURL param.Field[string] `json:"callbackUrl" api:"required" format:"uri"`
}
func (AgentV1RunWatchParams) MarshalJSON ¶ added in v0.2.0
func (r AgentV1RunWatchParams) MarshalJSON() (data []byte, err error)
type AgentV1RunWatchResponse ¶ added in v0.2.0
type AgentV1RunWatchResponse struct {
CallbackURL string `json:"callbackUrl"`
Ok bool `json:"ok"`
JSON agentV1RunWatchResponseJSON `json:"-"`
}
func (*AgentV1RunWatchResponse) UnmarshalJSON ¶ added in v0.2.0
func (r *AgentV1RunWatchResponse) UnmarshalJSON(data []byte) (err error)
type AgentV1Service ¶ added in v0.2.0
type AgentV1Service struct {
Options []option.RequestOption
// Create, manage, and execute AI agents with tool access, sandbox environments,
// and async run workflows
Agents *AgentV1AgentService
// Create, manage, and execute AI agents with tool access, sandbox environments,
// and async run workflows
Run *AgentV1RunService
// Create, manage, and execute AI agents with tool access, sandbox environments,
// and async run workflows
Execute *AgentV1ExecuteService
// Create, manage, and execute AI agents with tool access, sandbox environments,
// and async run workflows
Chat *AgentV1ChatService
}
AgentV1Service contains methods and other services that help with interacting with the casedev API.
Note, unlike clients, this service does not read variables from the environment automatically. You should not instantiate this service directly, and instead use the NewAgentV1Service method instead.
func NewAgentV1Service ¶ added in v0.2.0
func NewAgentV1Service(opts ...option.RequestOption) (r *AgentV1Service)
NewAgentV1Service generates a new service that applies the given options to each request. These options are applied after the parent client's options (if there is one), and before any request-specific options.
type Client ¶
type Client struct {
Options []option.RequestOption
Agent *AgentService
// Public system metadata and discovery endpoints
System *SystemService
Worker *WorkerService
Compute *ComputeService
Database *DatabaseService
Format *FormatService
Legal *LegalService
Matters *MatterService
// Access 40+ language models through a unified API
Llm *LlmService
Memory *MemoryService
Ocr *OcrService
Privilege *PrivilegeService
Mail *MailService
// Search and read legal AI skills for agents
Skills *SkillService
Search *SearchService
Superdoc *SuperdocService
Translate *TranslateService
Usage *UsageService
// Secure document storage with semantic search and GraphRAG
Vault *VaultService
Voice *VoiceService
Webhooks *WebhookService
}
Client creates a struct with services and top level methods that help with interacting with the casedev API. You should not instantiate this client directly, and instead use the NewClient method instead.
func NewClient ¶
func NewClient(opts ...option.RequestOption) (r *Client)
NewClient generates a new client with the default option read from the environment (CASEDEV_API_KEY, CASEDEV_BASE_URL). The option passed in as arguments are applied after these default arguments, and all option will be passed down to the services and requests that this client makes.
func (*Client) Delete ¶
func (r *Client) Delete(ctx context.Context, path string, params interface{}, res interface{}, opts ...option.RequestOption) error
Delete makes a DELETE request with the given URL, params, and optionally deserializes to a response. See [Execute] documentation on the params and response.
func (*Client) Execute ¶
func (r *Client) Execute(ctx context.Context, method string, path string, params interface{}, res interface{}, opts ...option.RequestOption) error
Execute makes a request with the given context, method, URL, request params, response, and request options. This is useful for hitting undocumented endpoints while retaining the base URL, auth, retries, and other options from the client.
If a byte slice or an io.Reader is supplied to params, it will be used as-is for the request body.
The params is by default serialized into the body using encoding/json. If your type implements a MarshalJSON function, it will be used instead to serialize the request. If a URLQuery method is implemented, the returned url.Values will be used as query strings to the url.
If your params struct uses param.Field, you must provide either [MarshalJSON], [URLQuery], and/or [MarshalForm] functions. It is undefined behavior to use a struct uses param.Field without specifying how it is serialized.
Any "…Params" object defined in this library can be used as the request argument. Note that 'path' arguments will not be forwarded into the url.
The response body will be deserialized into the res variable, depending on its type:
- A pointer to a *http.Response is populated by the raw response.
- A pointer to a byte array will be populated with the contents of the request body.
- A pointer to any other type uses this library's default JSON decoding, which respects UnmarshalJSON if it is defined on the type.
- A nil value will not read the response body.
For even greater flexibility, see option.WithResponseInto and option.WithResponseBodyInto.
func (*Client) Get ¶
func (r *Client) Get(ctx context.Context, path string, params interface{}, res interface{}, opts ...option.RequestOption) error
Get makes a GET request with the given URL, params, and optionally deserializes to a response. See [Execute] documentation on the params and response.
func (*Client) Patch ¶
func (r *Client) Patch(ctx context.Context, path string, params interface{}, res interface{}, opts ...option.RequestOption) error
Patch makes a PATCH request with the given URL, params, and optionally deserializes to a response. See [Execute] documentation on the params and response.
func (*Client) Post ¶
func (r *Client) Post(ctx context.Context, path string, params interface{}, res interface{}, opts ...option.RequestOption) error
Post makes a POST request with the given URL, params, and optionally deserializes to a response. See [Execute] documentation on the params and response.
type ComputeService ¶
type ComputeService struct {
Options []option.RequestOption
// Serverless GPU and CPU infrastructure
V1 *ComputeV1Service
}
ComputeService contains methods and other services that help with interacting with the casedev API.
Note, unlike clients, this service does not read variables from the environment automatically. You should not instantiate this service directly, and instead use the NewComputeService method instead.
func NewComputeService ¶
func NewComputeService(opts ...option.RequestOption) (r *ComputeService)
NewComputeService generates a new service that applies the given options to each request. These options are applied after the parent client's options (if there is one), and before any request-specific options.
type ComputeV1EnvironmentDeleteResponse ¶
type ComputeV1EnvironmentDeleteResponse struct {
Message string `json:"message" api:"required"`
Success bool `json:"success" api:"required"`
JSON computeV1EnvironmentDeleteResponseJSON `json:"-"`
}
func (*ComputeV1EnvironmentDeleteResponse) UnmarshalJSON ¶
func (r *ComputeV1EnvironmentDeleteResponse) UnmarshalJSON(data []byte) (err error)
type ComputeV1EnvironmentGetResponse ¶
type ComputeV1EnvironmentGetResponse struct {
// Unique environment identifier
ID string `json:"id"`
// Environment creation timestamp
CreatedAt time.Time `json:"createdAt" format:"date-time"`
// Environment domain URL
Domain string `json:"domain"`
// Whether this is the default environment
IsDefault bool `json:"isDefault"`
// Environment name
Name string `json:"name"`
// URL-safe environment slug
Slug string `json:"slug"`
// Environment status (active, inactive, etc.)
Status string `json:"status"`
// Environment last update timestamp
UpdatedAt time.Time `json:"updatedAt" format:"date-time"`
JSON computeV1EnvironmentGetResponseJSON `json:"-"`
}
func (*ComputeV1EnvironmentGetResponse) UnmarshalJSON ¶
func (r *ComputeV1EnvironmentGetResponse) UnmarshalJSON(data []byte) (err error)
type ComputeV1EnvironmentListResponse ¶
type ComputeV1EnvironmentListResponse struct {
Environments []ComputeV1EnvironmentListResponseEnvironment `json:"environments"`
JSON computeV1EnvironmentListResponseJSON `json:"-"`
}
func (*ComputeV1EnvironmentListResponse) UnmarshalJSON ¶
func (r *ComputeV1EnvironmentListResponse) UnmarshalJSON(data []byte) (err error)
type ComputeV1EnvironmentListResponseEnvironment ¶
type ComputeV1EnvironmentListResponseEnvironment struct {
// Unique environment identifier
ID string `json:"id"`
// Environment creation timestamp
CreatedAt time.Time `json:"createdAt" format:"date-time"`
// Environment domain
Domain string `json:"domain"`
// Whether this is the default environment
IsDefault bool `json:"isDefault"`
// Human-readable environment name
Name string `json:"name"`
// URL-safe environment identifier
Slug string `json:"slug"`
// Environment status
Status string `json:"status"`
// Last update timestamp
UpdatedAt time.Time `json:"updatedAt" format:"date-time"`
JSON computeV1EnvironmentListResponseEnvironmentJSON `json:"-"`
}
func (*ComputeV1EnvironmentListResponseEnvironment) UnmarshalJSON ¶
func (r *ComputeV1EnvironmentListResponseEnvironment) UnmarshalJSON(data []byte) (err error)
type ComputeV1EnvironmentNewParams ¶
type ComputeV1EnvironmentNewParams struct {
// Environment name (alphanumeric, hyphens, and underscores only)
Name param.Field[string] `json:"name" api:"required"`
}
func (ComputeV1EnvironmentNewParams) MarshalJSON ¶
func (r ComputeV1EnvironmentNewParams) MarshalJSON() (data []byte, err error)
type ComputeV1EnvironmentNewResponse ¶
type ComputeV1EnvironmentNewResponse struct {
// Unique environment identifier
ID string `json:"id"`
// Environment creation timestamp
CreatedAt time.Time `json:"createdAt" format:"date-time"`
// Unique domain for this environment
Domain string `json:"domain"`
// Whether this is the default environment
IsDefault bool `json:"isDefault"`
// Environment name
Name string `json:"name"`
// URL-friendly slug derived from name
Slug string `json:"slug"`
// Environment status
Status ComputeV1EnvironmentNewResponseStatus `json:"status"`
JSON computeV1EnvironmentNewResponseJSON `json:"-"`
}
func (*ComputeV1EnvironmentNewResponse) UnmarshalJSON ¶
func (r *ComputeV1EnvironmentNewResponse) UnmarshalJSON(data []byte) (err error)
type ComputeV1EnvironmentNewResponseStatus ¶
type ComputeV1EnvironmentNewResponseStatus string
Environment status
const ( ComputeV1EnvironmentNewResponseStatusActive ComputeV1EnvironmentNewResponseStatus = "active" ComputeV1EnvironmentNewResponseStatusInactive ComputeV1EnvironmentNewResponseStatus = "inactive" )
func (ComputeV1EnvironmentNewResponseStatus) IsKnown ¶
func (r ComputeV1EnvironmentNewResponseStatus) IsKnown() bool
type ComputeV1EnvironmentService ¶
type ComputeV1EnvironmentService struct {
Options []option.RequestOption
}
Serverless GPU and CPU infrastructure
ComputeV1EnvironmentService contains methods and other services that help with interacting with the casedev API.
Note, unlike clients, this service does not read variables from the environment automatically. You should not instantiate this service directly, and instead use the NewComputeV1EnvironmentService method instead.
func NewComputeV1EnvironmentService ¶
func NewComputeV1EnvironmentService(opts ...option.RequestOption) (r *ComputeV1EnvironmentService)
NewComputeV1EnvironmentService generates a new service that applies the given options to each request. These options are applied after the parent client's options (if there is one), and before any request-specific options.
func (*ComputeV1EnvironmentService) Delete ¶
func (r *ComputeV1EnvironmentService) Delete(ctx context.Context, name string, opts ...option.RequestOption) (res *ComputeV1EnvironmentDeleteResponse, err error)
Permanently delete a compute environment and all its associated resources. This will stop all running deployments and clean up related configurations. The default environment cannot be deleted if other environments exist.
func (*ComputeV1EnvironmentService) Get ¶
func (r *ComputeV1EnvironmentService) Get(ctx context.Context, name string, opts ...option.RequestOption) (res *ComputeV1EnvironmentGetResponse, err error)
Retrieve a specific compute environment by name. Returns environment configuration including status, domain, and metadata for your serverless compute infrastructure.
func (*ComputeV1EnvironmentService) List ¶
func (r *ComputeV1EnvironmentService) List(ctx context.Context, opts ...option.RequestOption) (res *ComputeV1EnvironmentListResponse, err error)
Retrieve all compute environments for your organization. Environments provide isolated execution contexts for running code and workflows.
func (*ComputeV1EnvironmentService) New ¶
func (r *ComputeV1EnvironmentService) New(ctx context.Context, body ComputeV1EnvironmentNewParams, opts ...option.RequestOption) (res *ComputeV1EnvironmentNewResponse, err error)
Creates a new compute environment for running serverless workloads. Each environment gets its own isolated namespace with a unique domain for hosting applications and APIs. The first environment created becomes the default environment for the organization.
func (*ComputeV1EnvironmentService) SetDefault ¶
func (r *ComputeV1EnvironmentService) SetDefault(ctx context.Context, name string, opts ...option.RequestOption) (res *ComputeV1EnvironmentSetDefaultResponse, err error)
Sets a compute environment as the default for the organization. Only one environment can be default at a time - setting a new default will automatically unset the previous one.
type ComputeV1EnvironmentSetDefaultResponse ¶
type ComputeV1EnvironmentSetDefaultResponse struct {
// Unique environment identifier
ID string `json:"id"`
// Environment creation timestamp
CreatedAt time.Time `json:"createdAt" format:"date-time"`
// Environment domain
Domain string `json:"domain"`
// Whether this is the default environment
IsDefault bool `json:"isDefault"`
// Environment name
Name string `json:"name"`
// URL-friendly environment identifier
Slug string `json:"slug"`
// Current environment status
Status string `json:"status"`
// Last update timestamp
UpdatedAt time.Time `json:"updatedAt" format:"date-time"`
JSON computeV1EnvironmentSetDefaultResponseJSON `json:"-"`
}
func (*ComputeV1EnvironmentSetDefaultResponse) UnmarshalJSON ¶
func (r *ComputeV1EnvironmentSetDefaultResponse) UnmarshalJSON(data []byte) (err error)
type ComputeV1GetUsageParams ¶
type ComputeV1GetUsageParams struct {
// Month to filter usage data (1-12, defaults to current month)
Month param.Field[int64] `query:"month"`
// Year to filter usage data (defaults to current year)
Year param.Field[int64] `query:"year"`
}
func (ComputeV1GetUsageParams) URLQuery ¶
func (r ComputeV1GetUsageParams) URLQuery() (v url.Values)
URLQuery serializes ComputeV1GetUsageParams's query parameters as `url.Values`.
type ComputeV1GetUsageResponse ¶
type ComputeV1GetUsageResponse struct {
ByEnvironment []ComputeV1GetUsageResponseByEnvironment `json:"byEnvironment"`
Period ComputeV1GetUsageResponsePeriod `json:"period"`
Summary ComputeV1GetUsageResponseSummary `json:"summary"`
JSON computeV1GetUsageResponseJSON `json:"-"`
}
func (*ComputeV1GetUsageResponse) UnmarshalJSON ¶
func (r *ComputeV1GetUsageResponse) UnmarshalJSON(data []byte) (err error)
type ComputeV1GetUsageResponseByEnvironment ¶
type ComputeV1GetUsageResponseByEnvironment struct {
Environment string `json:"environment"`
TotalCostCents int64 `json:"totalCostCents"`
TotalCostFormatted string `json:"totalCostFormatted"`
TotalCPUSeconds int64 `json:"totalCpuSeconds"`
TotalGPUSeconds int64 `json:"totalGpuSeconds"`
TotalRuns int64 `json:"totalRuns"`
JSON computeV1GetUsageResponseByEnvironmentJSON `json:"-"`
}
func (*ComputeV1GetUsageResponseByEnvironment) UnmarshalJSON ¶
func (r *ComputeV1GetUsageResponseByEnvironment) UnmarshalJSON(data []byte) (err error)
type ComputeV1GetUsageResponsePeriod ¶
type ComputeV1GetUsageResponsePeriod struct {
Month int64 `json:"month"`
MonthName string `json:"monthName"`
Year int64 `json:"year"`
JSON computeV1GetUsageResponsePeriodJSON `json:"-"`
}
func (*ComputeV1GetUsageResponsePeriod) UnmarshalJSON ¶
func (r *ComputeV1GetUsageResponsePeriod) UnmarshalJSON(data []byte) (err error)
type ComputeV1GetUsageResponseSummary ¶
type ComputeV1GetUsageResponseSummary struct {
TotalCostCents int64 `json:"totalCostCents"`
TotalCostFormatted string `json:"totalCostFormatted"`
TotalCPUHours float64 `json:"totalCpuHours"`
TotalGPUHours float64 `json:"totalGpuHours"`
TotalRuns int64 `json:"totalRuns"`
JSON computeV1GetUsageResponseSummaryJSON `json:"-"`
}
func (*ComputeV1GetUsageResponseSummary) UnmarshalJSON ¶
func (r *ComputeV1GetUsageResponseSummary) UnmarshalJSON(data []byte) (err error)
type ComputeV1InstanceDeleteResponse ¶
type ComputeV1InstanceDeleteResponse struct {
ID string `json:"id"`
Message string `json:"message"`
Name string `json:"name"`
Status string `json:"status"`
TotalCost string `json:"totalCost"`
TotalRuntimeSeconds int64 `json:"totalRuntimeSeconds"`
JSON computeV1InstanceDeleteResponseJSON `json:"-"`
}
func (*ComputeV1InstanceDeleteResponse) UnmarshalJSON ¶
func (r *ComputeV1InstanceDeleteResponse) UnmarshalJSON(data []byte) (err error)
type ComputeV1InstanceGetResponse ¶
type ComputeV1InstanceGetResponse struct {
ID string `json:"id"`
AutoShutdownMinutes int64 `json:"autoShutdownMinutes" api:"nullable"`
CreatedAt string `json:"createdAt"`
CurrentCost string `json:"currentCost"`
CurrentRuntimeSeconds int64 `json:"currentRuntimeSeconds"`
GPU string `json:"gpu"`
InstanceType string `json:"instanceType"`
IP string `json:"ip" api:"nullable"`
Name string `json:"name"`
PricePerHour string `json:"pricePerHour"`
Region string `json:"region"`
Specs interface{} `json:"specs"`
SSH ComputeV1InstanceGetResponseSSH `json:"ssh" api:"nullable"`
StartedAt string `json:"startedAt" api:"nullable"`
Status string `json:"status"`
VaultMounts interface{} `json:"vaultMounts" api:"nullable"`
JSON computeV1InstanceGetResponseJSON `json:"-"`
}
func (*ComputeV1InstanceGetResponse) UnmarshalJSON ¶
func (r *ComputeV1InstanceGetResponse) UnmarshalJSON(data []byte) (err error)
type ComputeV1InstanceGetResponseSSH ¶
type ComputeV1InstanceGetResponseSSH struct {
Command string `json:"command"`
Host string `json:"host"`
Instructions []interface{} `json:"instructions"`
PrivateKey string `json:"privateKey"`
User string `json:"user"`
JSON computeV1InstanceGetResponseSSHJSON `json:"-"`
}
func (*ComputeV1InstanceGetResponseSSH) UnmarshalJSON ¶
func (r *ComputeV1InstanceGetResponseSSH) UnmarshalJSON(data []byte) (err error)
type ComputeV1InstanceListResponse ¶
type ComputeV1InstanceListResponse struct {
Count int64 `json:"count"`
Instances []ComputeV1InstanceListResponseInstance `json:"instances"`
JSON computeV1InstanceListResponseJSON `json:"-"`
}
func (*ComputeV1InstanceListResponse) UnmarshalJSON ¶
func (r *ComputeV1InstanceListResponse) UnmarshalJSON(data []byte) (err error)
type ComputeV1InstanceListResponseInstance ¶
type ComputeV1InstanceListResponseInstance struct {
ID string `json:"id"`
AutoShutdownMinutes int64 `json:"autoShutdownMinutes" api:"nullable"`
CreatedAt time.Time `json:"createdAt" format:"date-time"`
GPU string `json:"gpu"`
InstanceType string `json:"instanceType"`
IP string `json:"ip" api:"nullable"`
Name string `json:"name"`
PricePerHour string `json:"pricePerHour"`
Region string `json:"region"`
StartedAt time.Time `json:"startedAt" api:"nullable" format:"date-time"`
Status ComputeV1InstanceListResponseInstancesStatus `json:"status"`
TotalCost string `json:"totalCost"`
TotalRuntimeSeconds int64 `json:"totalRuntimeSeconds"`
JSON computeV1InstanceListResponseInstanceJSON `json:"-"`
}
func (*ComputeV1InstanceListResponseInstance) UnmarshalJSON ¶
func (r *ComputeV1InstanceListResponseInstance) UnmarshalJSON(data []byte) (err error)
type ComputeV1InstanceListResponseInstancesStatus ¶
type ComputeV1InstanceListResponseInstancesStatus string
const ( ComputeV1InstanceListResponseInstancesStatusBooting ComputeV1InstanceListResponseInstancesStatus = "booting" ComputeV1InstanceListResponseInstancesStatusRunning ComputeV1InstanceListResponseInstancesStatus = "running" ComputeV1InstanceListResponseInstancesStatusStopping ComputeV1InstanceListResponseInstancesStatus = "stopping" ComputeV1InstanceListResponseInstancesStatusStopped ComputeV1InstanceListResponseInstancesStatus = "stopped" ComputeV1InstanceListResponseInstancesStatusTerminated ComputeV1InstanceListResponseInstancesStatus = "terminated" ComputeV1InstanceListResponseInstancesStatusFailed ComputeV1InstanceListResponseInstancesStatus = "failed" )
func (ComputeV1InstanceListResponseInstancesStatus) IsKnown ¶
func (r ComputeV1InstanceListResponseInstancesStatus) IsKnown() bool
type ComputeV1InstanceNewParams ¶
type ComputeV1InstanceNewParams struct {
// GPU type (e.g., 'gpu_1x_h100_sxm5')
InstanceType param.Field[string] `json:"instanceType" api:"required"`
// Instance name
Name param.Field[string] `json:"name" api:"required"`
// Region (e.g., 'us-west-1')
Region param.Field[string] `json:"region" api:"required"`
// Auto-shutdown timer (null = never)
AutoShutdownMinutes param.Field[int64] `json:"autoShutdownMinutes"`
// Vault IDs to mount
VaultIDs param.Field[[]string] `json:"vaultIds"`
}
func (ComputeV1InstanceNewParams) MarshalJSON ¶
func (r ComputeV1InstanceNewParams) MarshalJSON() (data []byte, err error)
type ComputeV1InstanceNewResponse ¶
type ComputeV1InstanceNewResponse struct {
ID string `json:"id"`
AutoShutdownMinutes int64 `json:"autoShutdownMinutes" api:"nullable"`
CreatedAt string `json:"createdAt"`
GPU string `json:"gpu"`
InstanceType string `json:"instanceType"`
Message string `json:"message"`
Name string `json:"name"`
PricePerHour string `json:"pricePerHour"`
Region string `json:"region"`
Specs interface{} `json:"specs"`
Status string `json:"status"`
Vaults []interface{} `json:"vaults"`
JSON computeV1InstanceNewResponseJSON `json:"-"`
}
func (*ComputeV1InstanceNewResponse) UnmarshalJSON ¶
func (r *ComputeV1InstanceNewResponse) UnmarshalJSON(data []byte) (err error)
type ComputeV1InstanceService ¶
type ComputeV1InstanceService struct {
Options []option.RequestOption
}
Serverless GPU and CPU infrastructure
ComputeV1InstanceService contains methods and other services that help with interacting with the casedev API.
Note, unlike clients, this service does not read variables from the environment automatically. You should not instantiate this service directly, and instead use the NewComputeV1InstanceService method instead.
func NewComputeV1InstanceService ¶
func NewComputeV1InstanceService(opts ...option.RequestOption) (r *ComputeV1InstanceService)
NewComputeV1InstanceService generates a new service that applies the given options to each request. These options are applied after the parent client's options (if there is one), and before any request-specific options.
func (*ComputeV1InstanceService) Delete ¶
func (r *ComputeV1InstanceService) Delete(ctx context.Context, id string, opts ...option.RequestOption) (res *ComputeV1InstanceDeleteResponse, err error)
Terminates a running GPU instance, calculates final cost, and cleans up SSH keys. This action is permanent and cannot be undone. All data on the instance will be lost.
func (*ComputeV1InstanceService) Get ¶
func (r *ComputeV1InstanceService) Get(ctx context.Context, id string, opts ...option.RequestOption) (res *ComputeV1InstanceGetResponse, err error)
Retrieves detailed information about a GPU instance including SSH connection details, vault mount scripts, real-time cost tracking, and current status. SSH private key included for secure access.
func (*ComputeV1InstanceService) List ¶
func (r *ComputeV1InstanceService) List(ctx context.Context, opts ...option.RequestOption) (res *ComputeV1InstanceListResponse, err error)
Retrieves all GPU compute instances for your organization with real-time status updates from Lambda Labs. Includes pricing, runtime metrics, and auto-shutdown configuration. Perfect for monitoring AI workloads, document processing jobs, and cost tracking.
func (*ComputeV1InstanceService) New ¶
func (r *ComputeV1InstanceService) New(ctx context.Context, body ComputeV1InstanceNewParams, opts ...option.RequestOption) (res *ComputeV1InstanceNewResponse, err error)
Launches a new GPU compute instance with automatic SSH key generation. Supports mounting Case.dev Vaults as filesystems and configurable auto-shutdown. Instance boots in ~2-5 minutes. Perfect for batch OCR processing, AI model training, and intensive document analysis workloads.
type ComputeV1InstanceTypeListResponse ¶
type ComputeV1InstanceTypeListResponse struct {
// Total number of instance types
Count int64 `json:"count" api:"required"`
InstanceTypes []ComputeV1InstanceTypeListResponseInstanceType `json:"instanceTypes" api:"required"`
JSON computeV1InstanceTypeListResponseJSON `json:"-"`
}
func (*ComputeV1InstanceTypeListResponse) UnmarshalJSON ¶
func (r *ComputeV1InstanceTypeListResponse) UnmarshalJSON(data []byte) (err error)
type ComputeV1InstanceTypeListResponseInstanceType ¶
type ComputeV1InstanceTypeListResponseInstanceType struct {
// Instance description
Description string `json:"description"`
// GPU model and count
GPU string `json:"gpu"`
// Instance type identifier
Name string `json:"name"`
// Price per hour (e.g. '$1.20')
PricePerHour string `json:"pricePerHour"`
// Available regions
RegionsAvailable []string `json:"regionsAvailable"`
Specs ComputeV1InstanceTypeListResponseInstanceTypesSpecs `json:"specs"`
JSON computeV1InstanceTypeListResponseInstanceTypeJSON `json:"-"`
}
func (*ComputeV1InstanceTypeListResponseInstanceType) UnmarshalJSON ¶
func (r *ComputeV1InstanceTypeListResponseInstanceType) UnmarshalJSON(data []byte) (err error)
type ComputeV1InstanceTypeListResponseInstanceTypesSpecs ¶
type ComputeV1InstanceTypeListResponseInstanceTypesSpecs struct {
// RAM in GiB
MemoryGib int64 `json:"memoryGib"`
// Storage in GiB
StorageGib int64 `json:"storageGib"`
// Number of vCPUs
Vcpus int64 `json:"vcpus"`
JSON computeV1InstanceTypeListResponseInstanceTypesSpecsJSON `json:"-"`
}
func (*ComputeV1InstanceTypeListResponseInstanceTypesSpecs) UnmarshalJSON ¶
func (r *ComputeV1InstanceTypeListResponseInstanceTypesSpecs) UnmarshalJSON(data []byte) (err error)
type ComputeV1InstanceTypeService ¶
type ComputeV1InstanceTypeService struct {
Options []option.RequestOption
}
Serverless GPU and CPU infrastructure
ComputeV1InstanceTypeService contains methods and other services that help with interacting with the casedev API.
Note, unlike clients, this service does not read variables from the environment automatically. You should not instantiate this service directly, and instead use the NewComputeV1InstanceTypeService method instead.
func NewComputeV1InstanceTypeService ¶
func NewComputeV1InstanceTypeService(opts ...option.RequestOption) (r *ComputeV1InstanceTypeService)
NewComputeV1InstanceTypeService generates a new service that applies the given options to each request. These options are applied after the parent client's options (if there is one), and before any request-specific options.
func (*ComputeV1InstanceTypeService) List ¶
func (r *ComputeV1InstanceTypeService) List(ctx context.Context, opts ...option.RequestOption) (res *ComputeV1InstanceTypeListResponse, err error)
Retrieves all available GPU instance types with pricing, specifications, and regional availability. Includes T4, A10, A100, H100, and H200 GPUs powered by Lambda Labs. Perfect for AI model training, inference workloads, and legal document OCR processing at scale.
type ComputeV1SecretDeleteGroupParams ¶
type ComputeV1SecretDeleteGroupParams struct {
// Environment name. If not provided, uses the default environment
Env param.Field[string] `query:"env"`
// Specific key to delete within the group. If not provided, the entire group is
// deleted
Key param.Field[string] `query:"key"`
}
func (ComputeV1SecretDeleteGroupParams) URLQuery ¶
func (r ComputeV1SecretDeleteGroupParams) URLQuery() (v url.Values)
URLQuery serializes ComputeV1SecretDeleteGroupParams's query parameters as `url.Values`.
type ComputeV1SecretDeleteGroupResponse ¶
type ComputeV1SecretDeleteGroupResponse struct {
Message string `json:"message"`
Success bool `json:"success"`
JSON computeV1SecretDeleteGroupResponseJSON `json:"-"`
}
func (*ComputeV1SecretDeleteGroupResponse) UnmarshalJSON ¶
func (r *ComputeV1SecretDeleteGroupResponse) UnmarshalJSON(data []byte) (err error)
type ComputeV1SecretGetGroupParams ¶
type ComputeV1SecretGetGroupParams struct {
// Environment name. If not specified, uses the default environment
Env param.Field[string] `query:"env"`
}
func (ComputeV1SecretGetGroupParams) URLQuery ¶
func (r ComputeV1SecretGetGroupParams) URLQuery() (v url.Values)
URLQuery serializes ComputeV1SecretGetGroupParams's query parameters as `url.Values`.
type ComputeV1SecretGetGroupResponse ¶
type ComputeV1SecretGetGroupResponse struct {
Group ComputeV1SecretGetGroupResponseGroup `json:"group"`
Keys []ComputeV1SecretGetGroupResponseKey `json:"keys"`
JSON computeV1SecretGetGroupResponseJSON `json:"-"`
}
func (*ComputeV1SecretGetGroupResponse) UnmarshalJSON ¶
func (r *ComputeV1SecretGetGroupResponse) UnmarshalJSON(data []byte) (err error)
type ComputeV1SecretGetGroupResponseGroup ¶
type ComputeV1SecretGetGroupResponseGroup struct {
// Unique identifier of the secret group
ID string `json:"id"`
// Description of the secret group
Description string `json:"description"`
// Name of the secret group
Name string `json:"name"`
JSON computeV1SecretGetGroupResponseGroupJSON `json:"-"`
}
func (*ComputeV1SecretGetGroupResponseGroup) UnmarshalJSON ¶
func (r *ComputeV1SecretGetGroupResponseGroup) UnmarshalJSON(data []byte) (err error)
type ComputeV1SecretGetGroupResponseKey ¶
type ComputeV1SecretGetGroupResponseKey struct {
// When the secret was created
CreatedAt time.Time `json:"createdAt" format:"date-time"`
// Name of the secret key
Key string `json:"key"`
// When the secret was last updated
UpdatedAt time.Time `json:"updatedAt" format:"date-time"`
JSON computeV1SecretGetGroupResponseKeyJSON `json:"-"`
}
func (*ComputeV1SecretGetGroupResponseKey) UnmarshalJSON ¶
func (r *ComputeV1SecretGetGroupResponseKey) UnmarshalJSON(data []byte) (err error)
type ComputeV1SecretListParams ¶
type ComputeV1SecretListParams struct {
// Environment name to list secret groups for. If not specified, uses the default
// environment.
Env param.Field[string] `query:"env"`
}
func (ComputeV1SecretListParams) URLQuery ¶
func (r ComputeV1SecretListParams) URLQuery() (v url.Values)
URLQuery serializes ComputeV1SecretListParams's query parameters as `url.Values`.
type ComputeV1SecretListResponse ¶
type ComputeV1SecretListResponse struct {
Groups []ComputeV1SecretListResponseGroup `json:"groups"`
JSON computeV1SecretListResponseJSON `json:"-"`
}
func (*ComputeV1SecretListResponse) UnmarshalJSON ¶
func (r *ComputeV1SecretListResponse) UnmarshalJSON(data []byte) (err error)
type ComputeV1SecretListResponseGroup ¶
type ComputeV1SecretListResponseGroup struct {
// Unique identifier for the secret group
ID string `json:"id"`
// When the secret group was created
CreatedAt time.Time `json:"createdAt" format:"date-time"`
// Description of the secret group
Description string `json:"description"`
// Name of the secret group
Name string `json:"name"`
// When the secret group was last updated
UpdatedAt time.Time `json:"updatedAt" format:"date-time"`
JSON computeV1SecretListResponseGroupJSON `json:"-"`
}
func (*ComputeV1SecretListResponseGroup) UnmarshalJSON ¶
func (r *ComputeV1SecretListResponseGroup) UnmarshalJSON(data []byte) (err error)
type ComputeV1SecretNewParams ¶
type ComputeV1SecretNewParams struct {
// Unique name for the secret group. Must contain only letters, numbers, hyphens,
// and underscores.
Name param.Field[string] `json:"name" api:"required"`
// Optional description of the secret group's purpose
Description param.Field[string] `json:"description"`
// Environment name where the secret group will be created. Uses default
// environment if not specified.
Env param.Field[string] `json:"env"`
}
func (ComputeV1SecretNewParams) MarshalJSON ¶
func (r ComputeV1SecretNewParams) MarshalJSON() (data []byte, err error)
type ComputeV1SecretNewResponse ¶
type ComputeV1SecretNewResponse struct {
// Unique identifier for the secret group
ID string `json:"id"`
// Creation timestamp
CreatedAt time.Time `json:"createdAt" format:"date-time"`
// Description of the secret group
Description string `json:"description"`
// Name of the secret group
Name string `json:"name"`
JSON computeV1SecretNewResponseJSON `json:"-"`
}
func (*ComputeV1SecretNewResponse) UnmarshalJSON ¶
func (r *ComputeV1SecretNewResponse) UnmarshalJSON(data []byte) (err error)
type ComputeV1SecretService ¶
type ComputeV1SecretService struct {
Options []option.RequestOption
}
Serverless GPU and CPU infrastructure
ComputeV1SecretService contains methods and other services that help with interacting with the casedev API.
Note, unlike clients, this service does not read variables from the environment automatically. You should not instantiate this service directly, and instead use the NewComputeV1SecretService method instead.
func NewComputeV1SecretService ¶
func NewComputeV1SecretService(opts ...option.RequestOption) (r *ComputeV1SecretService)
NewComputeV1SecretService generates a new service that applies the given options to each request. These options are applied after the parent client's options (if there is one), and before any request-specific options.
func (*ComputeV1SecretService) DeleteGroup ¶
func (r *ComputeV1SecretService) DeleteGroup(ctx context.Context, group string, body ComputeV1SecretDeleteGroupParams, opts ...option.RequestOption) (res *ComputeV1SecretDeleteGroupResponse, err error)
Delete an entire secret group or a specific key within a secret group. When deleting a specific key, the remaining secrets in the group are preserved. When deleting the entire group, all secrets and the group itself are removed.
func (*ComputeV1SecretService) GetGroup ¶
func (r *ComputeV1SecretService) GetGroup(ctx context.Context, group string, query ComputeV1SecretGetGroupParams, opts ...option.RequestOption) (res *ComputeV1SecretGetGroupResponse, err error)
Retrieve the keys (names) of secrets in a specified group within a compute environment. For security reasons, actual secret values are not returned - only the keys and metadata.
func (*ComputeV1SecretService) List ¶
func (r *ComputeV1SecretService) List(ctx context.Context, query ComputeV1SecretListParams, opts ...option.RequestOption) (res *ComputeV1SecretListResponse, err error)
Retrieve all secret groups for a compute environment. Secret groups organize related secrets (API keys, credentials, etc.) that can be securely accessed by compute jobs during execution.
func (*ComputeV1SecretService) New ¶
func (r *ComputeV1SecretService) New(ctx context.Context, body ComputeV1SecretNewParams, opts ...option.RequestOption) (res *ComputeV1SecretNewResponse, err error)
Creates a new secret group in a compute environment. Secret groups organize related secrets for use in serverless functions and workflows. If no environment is specified, the group is created in the default environment.
**Features:**
- Organize secrets by logical groups (e.g., database, APIs, third-party services)
- Environment-based isolation
- Validation of group names
- Conflict detection for existing groups
func (*ComputeV1SecretService) UpdateGroup ¶
func (r *ComputeV1SecretService) UpdateGroup(ctx context.Context, group string, body ComputeV1SecretUpdateGroupParams, opts ...option.RequestOption) (res *ComputeV1SecretUpdateGroupResponse, err error)
Set or update secrets in a compute secret group. Secrets are encrypted with AES-256-GCM. Use this to manage environment variables and API keys for your compute workloads.
type ComputeV1SecretUpdateGroupParams ¶
type ComputeV1SecretUpdateGroupParams struct {
// Key-value pairs of secrets to set
Secrets param.Field[map[string]string] `json:"secrets" api:"required"`
// Environment name (optional, uses default if not specified)
Env param.Field[string] `json:"env"`
}
func (ComputeV1SecretUpdateGroupParams) MarshalJSON ¶
func (r ComputeV1SecretUpdateGroupParams) MarshalJSON() (data []byte, err error)
type ComputeV1SecretUpdateGroupResponse ¶
type ComputeV1SecretUpdateGroupResponse struct {
// Number of new secrets created
Created float64 `json:"created"`
// Name of the secret group
Group string `json:"group"`
Message string `json:"message"`
Success bool `json:"success"`
// Number of existing secrets updated
Updated float64 `json:"updated"`
JSON computeV1SecretUpdateGroupResponseJSON `json:"-"`
}
func (*ComputeV1SecretUpdateGroupResponse) UnmarshalJSON ¶
func (r *ComputeV1SecretUpdateGroupResponse) UnmarshalJSON(data []byte) (err error)
type ComputeV1Service ¶
type ComputeV1Service struct {
Options []option.RequestOption
// Serverless GPU and CPU infrastructure
Environments *ComputeV1EnvironmentService
// Serverless GPU and CPU infrastructure
InstanceTypes *ComputeV1InstanceTypeService
// Serverless GPU and CPU infrastructure
Instances *ComputeV1InstanceService
// Serverless GPU and CPU infrastructure
Secrets *ComputeV1SecretService
}
Serverless GPU and CPU infrastructure
ComputeV1Service contains methods and other services that help with interacting with the casedev API.
Note, unlike clients, this service does not read variables from the environment automatically. You should not instantiate this service directly, and instead use the NewComputeV1Service method instead.
func NewComputeV1Service ¶
func NewComputeV1Service(opts ...option.RequestOption) (r *ComputeV1Service)
NewComputeV1Service generates a new service that applies the given options to each request. These options are applied after the parent client's options (if there is one), and before any request-specific options.
func (*ComputeV1Service) GetPricing ¶
func (r *ComputeV1Service) GetPricing(ctx context.Context, opts ...option.RequestOption) (err error)
Returns current pricing for GPU instances. Prices are fetched in real-time and include a 20% platform fee. For detailed instance types and availability, use GET /compute/v1/instance-types.
func (*ComputeV1Service) GetUsage ¶
func (r *ComputeV1Service) GetUsage(ctx context.Context, query ComputeV1GetUsageParams, opts ...option.RequestOption) (res *ComputeV1GetUsageResponse, err error)
Returns detailed compute usage statistics and billing information for your organization. Includes GPU and CPU hours, total runs, costs, and breakdowns by environment. Use optional query parameters to filter by specific year and month.
type DatabaseService ¶
type DatabaseService struct {
Options []option.RequestOption
// Serverless PostgreSQL databases with instant branching
V1 *DatabaseV1Service
}
DatabaseService contains methods and other services that help with interacting with the casedev API.
Note, unlike clients, this service does not read variables from the environment automatically. You should not instantiate this service directly, and instead use the NewDatabaseService method instead.
func NewDatabaseService ¶
func NewDatabaseService(opts ...option.RequestOption) (r *DatabaseService)
NewDatabaseService generates a new service that applies the given options to each request. These options are applied after the parent client's options (if there is one), and before any request-specific options.
type DatabaseV1GetUsageResponse ¶
type DatabaseV1GetUsageResponse struct {
Period DatabaseV1GetUsageResponsePeriod `json:"period"`
// Current pricing rates
Pricing DatabaseV1GetUsageResponsePricing `json:"pricing"`
// Total number of projects with usage
ProjectCount int64 `json:"projectCount"`
// Usage breakdown by project
Projects []DatabaseV1GetUsageResponseProject `json:"projects"`
// Aggregated totals across all projects
Totals DatabaseV1GetUsageResponseTotals `json:"totals"`
JSON databaseV1GetUsageResponseJSON `json:"-"`
}
func (*DatabaseV1GetUsageResponse) UnmarshalJSON ¶
func (r *DatabaseV1GetUsageResponse) UnmarshalJSON(data []byte) (err error)
type DatabaseV1GetUsageResponsePeriod ¶
type DatabaseV1GetUsageResponsePeriod struct {
// End of the billing period
End time.Time `json:"end" format:"date-time"`
// Start of the billing period
Start time.Time `json:"start" format:"date-time"`
JSON databaseV1GetUsageResponsePeriodJSON `json:"-"`
}
func (*DatabaseV1GetUsageResponsePeriod) UnmarshalJSON ¶
func (r *DatabaseV1GetUsageResponsePeriod) UnmarshalJSON(data []byte) (err error)
type DatabaseV1GetUsageResponsePricing ¶
type DatabaseV1GetUsageResponsePricing struct {
// Cost per branch per month in dollars
BranchPerMonth float64 `json:"branchPerMonth"`
// Cost per compute unit hour in dollars
ComputePerCuHour float64 `json:"computePerCuHour"`
// Number of free branches included
FreeBranches int64 `json:"freeBranches"`
// Cost per GB of storage per month in dollars
StoragePerGBMonth float64 `json:"storagePerGbMonth"`
// Cost per GB of data transfer in dollars
TransferPerGB float64 `json:"transferPerGb"`
JSON databaseV1GetUsageResponsePricingJSON `json:"-"`
}
Current pricing rates
func (*DatabaseV1GetUsageResponsePricing) UnmarshalJSON ¶
func (r *DatabaseV1GetUsageResponsePricing) UnmarshalJSON(data []byte) (err error)
type DatabaseV1GetUsageResponseProject ¶
type DatabaseV1GetUsageResponseProject struct {
ID string `json:"id"`
BranchCount int64 `json:"branchCount"`
ComputeCuHours float64 `json:"computeCuHours"`
Costs DatabaseV1GetUsageResponseProjectsCosts `json:"costs"`
LastUpdated time.Time `json:"lastUpdated" format:"date-time"`
ProjectID string `json:"projectId"`
ProjectName string `json:"projectName" api:"nullable"`
StorageGBMonths float64 `json:"storageGbMonths"`
TransferGB float64 `json:"transferGb"`
JSON databaseV1GetUsageResponseProjectJSON `json:"-"`
}
func (*DatabaseV1GetUsageResponseProject) UnmarshalJSON ¶
func (r *DatabaseV1GetUsageResponseProject) UnmarshalJSON(data []byte) (err error)
type DatabaseV1GetUsageResponseProjectsCosts ¶
type DatabaseV1GetUsageResponseProjectsCosts struct {
Branches string `json:"branches"`
Compute string `json:"compute"`
Storage string `json:"storage"`
Total string `json:"total"`
Transfer string `json:"transfer"`
JSON databaseV1GetUsageResponseProjectsCostsJSON `json:"-"`
}
func (*DatabaseV1GetUsageResponseProjectsCosts) UnmarshalJSON ¶
func (r *DatabaseV1GetUsageResponseProjectsCosts) UnmarshalJSON(data []byte) (err error)
type DatabaseV1GetUsageResponseTotals ¶
type DatabaseV1GetUsageResponseTotals struct {
// Total branch cost formatted as dollars
BranchCostDollars string `json:"branchCostDollars"`
// Total compute cost formatted as dollars
ComputeCostDollars string `json:"computeCostDollars"`
// Total compute unit hours
ComputeCuHours float64 `json:"computeCuHours"`
// Total storage cost formatted as dollars
StorageCostDollars string `json:"storageCostDollars"`
// Total storage in GB-months
StorageGBMonths float64 `json:"storageGbMonths"`
// Total number of branches
TotalBranches int64 `json:"totalBranches"`
// Total cost formatted as dollars
TotalCostDollars string `json:"totalCostDollars"`
// Total transfer cost formatted as dollars
TransferCostDollars string `json:"transferCostDollars"`
// Total data transfer in GB
TransferGB float64 `json:"transferGb"`
JSON databaseV1GetUsageResponseTotalsJSON `json:"-"`
}
Aggregated totals across all projects
func (*DatabaseV1GetUsageResponseTotals) UnmarshalJSON ¶
func (r *DatabaseV1GetUsageResponseTotals) UnmarshalJSON(data []byte) (err error)
type DatabaseV1ProjectDeleteResponse ¶
type DatabaseV1ProjectDeleteResponse struct {
// Confirmation message
Message string `json:"message" api:"required"`
// Deletion success indicator
Success bool `json:"success" api:"required"`
JSON databaseV1ProjectDeleteResponseJSON `json:"-"`
}
func (*DatabaseV1ProjectDeleteResponse) UnmarshalJSON ¶
func (r *DatabaseV1ProjectDeleteResponse) UnmarshalJSON(data []byte) (err error)
type DatabaseV1ProjectGetConnectionParams ¶
type DatabaseV1ProjectGetConnectionParams struct {
// Branch name (defaults to 'main')
Branch param.Field[string] `query:"branch"`
// Use pooled connection (PgBouncer)
Pooled param.Field[bool] `query:"pooled"`
}
func (DatabaseV1ProjectGetConnectionParams) URLQuery ¶
func (r DatabaseV1ProjectGetConnectionParams) URLQuery() (v url.Values)
URLQuery serializes DatabaseV1ProjectGetConnectionParams's query parameters as `url.Values`.
type DatabaseV1ProjectGetConnectionResponse ¶
type DatabaseV1ProjectGetConnectionResponse struct {
// Branch name for this connection
Branch string `json:"branch" api:"required"`
// PostgreSQL connection string (includes credentials)
ConnectionUri string `json:"connectionUri" api:"required" format:"uri"`
// Whether this is a pooled connection
Pooled bool `json:"pooled" api:"required"`
JSON databaseV1ProjectGetConnectionResponseJSON `json:"-"`
}
func (*DatabaseV1ProjectGetConnectionResponse) UnmarshalJSON ¶
func (r *DatabaseV1ProjectGetConnectionResponse) UnmarshalJSON(data []byte) (err error)
type DatabaseV1ProjectGetResponse ¶
type DatabaseV1ProjectGetResponse struct {
// Project ID
ID string `json:"id" api:"required"`
// All branches in this project
Branches []DatabaseV1ProjectGetResponseBranch `json:"branches" api:"required"`
// Total compute time consumed in seconds
ComputeTimeSeconds float64 `json:"computeTimeSeconds" api:"required"`
// Database connection hostname (masked for security)
ConnectionHost string `json:"connectionHost" api:"required"`
// Project creation timestamp
CreatedAt time.Time `json:"createdAt" api:"required" format:"date-time"`
// Databases in the default branch
Databases []DatabaseV1ProjectGetResponseDatabase `json:"databases" api:"required"`
// Linked deployments using this database
LinkedDeployments []DatabaseV1ProjectGetResponseLinkedDeployment `json:"linkedDeployments" api:"required"`
// Project name
Name string `json:"name" api:"required"`
// PostgreSQL major version
PgVersion int64 `json:"pgVersion" api:"required"`
// AWS region
Region string `json:"region" api:"required"`
// Project status
Status DatabaseV1ProjectGetResponseStatus `json:"status" api:"required"`
// Current storage usage in bytes
StorageSizeBytes float64 `json:"storageSizeBytes" api:"required"`
// Project last update timestamp
UpdatedAt time.Time `json:"updatedAt" api:"required" format:"date-time"`
// Project description
Description string `json:"description" api:"nullable"`
JSON databaseV1ProjectGetResponseJSON `json:"-"`
}
func (*DatabaseV1ProjectGetResponse) UnmarshalJSON ¶
func (r *DatabaseV1ProjectGetResponse) UnmarshalJSON(data []byte) (err error)
type DatabaseV1ProjectGetResponseBranch ¶
type DatabaseV1ProjectGetResponseBranch struct {
// Branch ID
ID string `json:"id"`
// Branch creation timestamp
CreatedAt time.Time `json:"createdAt" format:"date-time"`
// Whether this is the default branch
IsDefault bool `json:"isDefault"`
// Branch name
Name string `json:"name"`
// Branch status
Status string `json:"status"`
JSON databaseV1ProjectGetResponseBranchJSON `json:"-"`
}
func (*DatabaseV1ProjectGetResponseBranch) UnmarshalJSON ¶
func (r *DatabaseV1ProjectGetResponseBranch) UnmarshalJSON(data []byte) (err error)
type DatabaseV1ProjectGetResponseDatabase ¶
type DatabaseV1ProjectGetResponseDatabase struct {
// Database ID
ID string `json:"id"`
// Database name
Name string `json:"name"`
// Database owner role name
OwnerName string `json:"ownerName"`
JSON databaseV1ProjectGetResponseDatabaseJSON `json:"-"`
}
func (*DatabaseV1ProjectGetResponseDatabase) UnmarshalJSON ¶
func (r *DatabaseV1ProjectGetResponseDatabase) UnmarshalJSON(data []byte) (err error)
type DatabaseV1ProjectGetResponseLinkedDeployment ¶
type DatabaseV1ProjectGetResponseLinkedDeployment struct {
// Deployment ID
ID string `json:"id"`
// Environment variable name for connection string
EnvVarName string `json:"envVarName"`
// Deployment name
Name string `json:"name"`
// Deployment type
Type DatabaseV1ProjectGetResponseLinkedDeploymentsType `json:"type"`
// Deployment URL
URL string `json:"url"`
JSON databaseV1ProjectGetResponseLinkedDeploymentJSON `json:"-"`
}
func (*DatabaseV1ProjectGetResponseLinkedDeployment) UnmarshalJSON ¶
func (r *DatabaseV1ProjectGetResponseLinkedDeployment) UnmarshalJSON(data []byte) (err error)
type DatabaseV1ProjectGetResponseLinkedDeploymentsType ¶
type DatabaseV1ProjectGetResponseLinkedDeploymentsType string
Deployment type
const (
DatabaseV1ProjectGetResponseLinkedDeploymentsTypeCompute DatabaseV1ProjectGetResponseLinkedDeploymentsType = "compute"
)
func (DatabaseV1ProjectGetResponseLinkedDeploymentsType) IsKnown ¶
func (r DatabaseV1ProjectGetResponseLinkedDeploymentsType) IsKnown() bool
type DatabaseV1ProjectGetResponseStatus ¶
type DatabaseV1ProjectGetResponseStatus string
Project status
const ( DatabaseV1ProjectGetResponseStatusActive DatabaseV1ProjectGetResponseStatus = "active" DatabaseV1ProjectGetResponseStatusSuspended DatabaseV1ProjectGetResponseStatus = "suspended" DatabaseV1ProjectGetResponseStatusDeleted DatabaseV1ProjectGetResponseStatus = "deleted" )
func (DatabaseV1ProjectGetResponseStatus) IsKnown ¶
func (r DatabaseV1ProjectGetResponseStatus) IsKnown() bool
type DatabaseV1ProjectListBranchesResponse ¶
type DatabaseV1ProjectListBranchesResponse struct {
Branches []DatabaseV1ProjectListBranchesResponseBranch `json:"branches" api:"required"`
JSON databaseV1ProjectListBranchesResponseJSON `json:"-"`
}
func (*DatabaseV1ProjectListBranchesResponse) UnmarshalJSON ¶
func (r *DatabaseV1ProjectListBranchesResponse) UnmarshalJSON(data []byte) (err error)
type DatabaseV1ProjectListBranchesResponseBranch ¶
type DatabaseV1ProjectListBranchesResponseBranch struct {
// Branch ID
ID string `json:"id"`
// Branch creation timestamp
CreatedAt time.Time `json:"createdAt" format:"date-time"`
// Whether this is the default branch
IsDefault bool `json:"isDefault"`
// Branch name
Name string `json:"name"`
// Parent branch ID (null for default branch)
ParentBranchID string `json:"parentBranchId" api:"nullable"`
// Branch status
Status string `json:"status"`
// Branch last update timestamp
UpdatedAt time.Time `json:"updatedAt" format:"date-time"`
JSON databaseV1ProjectListBranchesResponseBranchJSON `json:"-"`
}
func (*DatabaseV1ProjectListBranchesResponseBranch) UnmarshalJSON ¶
func (r *DatabaseV1ProjectListBranchesResponseBranch) UnmarshalJSON(data []byte) (err error)
type DatabaseV1ProjectListResponse ¶
type DatabaseV1ProjectListResponse struct {
Projects []DatabaseV1ProjectListResponseProject `json:"projects" api:"required"`
JSON databaseV1ProjectListResponseJSON `json:"-"`
}
func (*DatabaseV1ProjectListResponse) UnmarshalJSON ¶
func (r *DatabaseV1ProjectListResponse) UnmarshalJSON(data []byte) (err error)
type DatabaseV1ProjectListResponseProject ¶
type DatabaseV1ProjectListResponseProject struct {
// Project ID
ID string `json:"id"`
// Total compute time consumed in seconds
ComputeTimeSeconds float64 `json:"computeTimeSeconds"`
// Project creation timestamp
CreatedAt time.Time `json:"createdAt" format:"date-time"`
// Project description
Description string `json:"description" api:"nullable"`
// Linked application deployments using this database
LinkedDeployments []DatabaseV1ProjectListResponseProjectsLinkedDeployment `json:"linkedDeployments"`
// Project name
Name string `json:"name"`
// PostgreSQL major version
PgVersion int64 `json:"pgVersion"`
// AWS region where database is deployed
Region string `json:"region"`
// Current project status
Status DatabaseV1ProjectListResponseProjectsStatus `json:"status"`
// Current storage usage in bytes
StorageSizeBytes float64 `json:"storageSizeBytes"`
// Project last update timestamp
UpdatedAt time.Time `json:"updatedAt" format:"date-time"`
JSON databaseV1ProjectListResponseProjectJSON `json:"-"`
}
func (*DatabaseV1ProjectListResponseProject) UnmarshalJSON ¶
func (r *DatabaseV1ProjectListResponseProject) UnmarshalJSON(data []byte) (err error)
type DatabaseV1ProjectListResponseProjectsLinkedDeployment ¶
type DatabaseV1ProjectListResponseProjectsLinkedDeployment struct {
// Deployment ID
ID string `json:"id"`
// Deployment name
Name string `json:"name"`
// Type of deployment
Type DatabaseV1ProjectListResponseProjectsLinkedDeploymentsType `json:"type"`
// Deployment URL
URL string `json:"url"`
JSON databaseV1ProjectListResponseProjectsLinkedDeploymentJSON `json:"-"`
}
func (*DatabaseV1ProjectListResponseProjectsLinkedDeployment) UnmarshalJSON ¶
func (r *DatabaseV1ProjectListResponseProjectsLinkedDeployment) UnmarshalJSON(data []byte) (err error)
type DatabaseV1ProjectListResponseProjectsLinkedDeploymentsType ¶
type DatabaseV1ProjectListResponseProjectsLinkedDeploymentsType string
Type of deployment
const (
DatabaseV1ProjectListResponseProjectsLinkedDeploymentsTypeCompute DatabaseV1ProjectListResponseProjectsLinkedDeploymentsType = "compute"
)
func (DatabaseV1ProjectListResponseProjectsLinkedDeploymentsType) IsKnown ¶
func (r DatabaseV1ProjectListResponseProjectsLinkedDeploymentsType) IsKnown() bool
type DatabaseV1ProjectListResponseProjectsStatus ¶
type DatabaseV1ProjectListResponseProjectsStatus string
Current project status
const ( DatabaseV1ProjectListResponseProjectsStatusActive DatabaseV1ProjectListResponseProjectsStatus = "active" DatabaseV1ProjectListResponseProjectsStatusSuspended DatabaseV1ProjectListResponseProjectsStatus = "suspended" DatabaseV1ProjectListResponseProjectsStatusDeleted DatabaseV1ProjectListResponseProjectsStatus = "deleted" )
func (DatabaseV1ProjectListResponseProjectsStatus) IsKnown ¶
func (r DatabaseV1ProjectListResponseProjectsStatus) IsKnown() bool
type DatabaseV1ProjectNewBranchParams ¶
type DatabaseV1ProjectNewBranchParams struct {
// Branch name (letters, numbers, hyphens, underscores only)
Name param.Field[string] `json:"name" api:"required"`
// Parent branch ID to clone from (defaults to main branch)
ParentBranchID param.Field[string] `json:"parentBranchId"`
}
func (DatabaseV1ProjectNewBranchParams) MarshalJSON ¶
func (r DatabaseV1ProjectNewBranchParams) MarshalJSON() (data []byte, err error)
type DatabaseV1ProjectNewBranchResponse ¶
type DatabaseV1ProjectNewBranchResponse struct {
// Branch ID
ID string `json:"id" api:"required"`
// Branch creation timestamp
CreatedAt time.Time `json:"createdAt" api:"required" format:"date-time"`
// Whether this is the default branch (always false for new branches)
IsDefault bool `json:"isDefault" api:"required"`
// Branch name
Name string `json:"name" api:"required"`
// Parent branch ID
ParentBranchID string `json:"parentBranchId" api:"required,nullable"`
// Branch status
Status string `json:"status" api:"required"`
JSON databaseV1ProjectNewBranchResponseJSON `json:"-"`
}
func (*DatabaseV1ProjectNewBranchResponse) UnmarshalJSON ¶
func (r *DatabaseV1ProjectNewBranchResponse) UnmarshalJSON(data []byte) (err error)
type DatabaseV1ProjectNewParams ¶
type DatabaseV1ProjectNewParams struct {
// Project name (letters, numbers, hyphens, underscores only)
Name param.Field[string] `json:"name" api:"required"`
// Optional project description
Description param.Field[string] `json:"description"`
// AWS region for database deployment
Region param.Field[DatabaseV1ProjectNewParamsRegion] `json:"region"`
}
func (DatabaseV1ProjectNewParams) MarshalJSON ¶
func (r DatabaseV1ProjectNewParams) MarshalJSON() (data []byte, err error)
type DatabaseV1ProjectNewParamsRegion ¶
type DatabaseV1ProjectNewParamsRegion string
AWS region for database deployment
const ( DatabaseV1ProjectNewParamsRegionAwsUsEast1 DatabaseV1ProjectNewParamsRegion = "aws-us-east-1" DatabaseV1ProjectNewParamsRegionAwsUsEast2 DatabaseV1ProjectNewParamsRegion = "aws-us-east-2" DatabaseV1ProjectNewParamsRegionAwsUsWest2 DatabaseV1ProjectNewParamsRegion = "aws-us-west-2" DatabaseV1ProjectNewParamsRegionAwsEuCentral1 DatabaseV1ProjectNewParamsRegion = "aws-eu-central-1" DatabaseV1ProjectNewParamsRegionAwsEuWest1 DatabaseV1ProjectNewParamsRegion = "aws-eu-west-1" DatabaseV1ProjectNewParamsRegionAwsEuWest2 DatabaseV1ProjectNewParamsRegion = "aws-eu-west-2" DatabaseV1ProjectNewParamsRegionAwsApSoutheast1 DatabaseV1ProjectNewParamsRegion = "aws-ap-southeast-1" DatabaseV1ProjectNewParamsRegionAwsApSoutheast2 DatabaseV1ProjectNewParamsRegion = "aws-ap-southeast-2" )
func (DatabaseV1ProjectNewParamsRegion) IsKnown ¶
func (r DatabaseV1ProjectNewParamsRegion) IsKnown() bool
type DatabaseV1ProjectNewResponse ¶
type DatabaseV1ProjectNewResponse struct {
// Project ID
ID string `json:"id" api:"required"`
// Project creation timestamp
CreatedAt time.Time `json:"createdAt" api:"required" format:"date-time"`
// Default 'main' branch details
DefaultBranch DatabaseV1ProjectNewResponseDefaultBranch `json:"defaultBranch" api:"required"`
// Project name
Name string `json:"name" api:"required"`
// PostgreSQL major version
PgVersion int64 `json:"pgVersion" api:"required"`
// AWS region
Region string `json:"region" api:"required"`
// Project status
Status DatabaseV1ProjectNewResponseStatus `json:"status" api:"required"`
// Project description
Description string `json:"description" api:"nullable"`
JSON databaseV1ProjectNewResponseJSON `json:"-"`
}
func (*DatabaseV1ProjectNewResponse) UnmarshalJSON ¶
func (r *DatabaseV1ProjectNewResponse) UnmarshalJSON(data []byte) (err error)
type DatabaseV1ProjectNewResponseDefaultBranch ¶
type DatabaseV1ProjectNewResponseDefaultBranch struct {
// Branch ID
ID string `json:"id"`
// Branch name
Name string `json:"name"`
JSON databaseV1ProjectNewResponseDefaultBranchJSON `json:"-"`
}
Default 'main' branch details
func (*DatabaseV1ProjectNewResponseDefaultBranch) UnmarshalJSON ¶
func (r *DatabaseV1ProjectNewResponseDefaultBranch) UnmarshalJSON(data []byte) (err error)
type DatabaseV1ProjectNewResponseStatus ¶
type DatabaseV1ProjectNewResponseStatus string
Project status
const ( DatabaseV1ProjectNewResponseStatusActive DatabaseV1ProjectNewResponseStatus = "active" DatabaseV1ProjectNewResponseStatusSuspended DatabaseV1ProjectNewResponseStatus = "suspended" DatabaseV1ProjectNewResponseStatusDeleted DatabaseV1ProjectNewResponseStatus = "deleted" )
func (DatabaseV1ProjectNewResponseStatus) IsKnown ¶
func (r DatabaseV1ProjectNewResponseStatus) IsKnown() bool
type DatabaseV1ProjectService ¶
type DatabaseV1ProjectService struct {
Options []option.RequestOption
}
Serverless PostgreSQL databases with instant branching
DatabaseV1ProjectService contains methods and other services that help with interacting with the casedev API.
Note, unlike clients, this service does not read variables from the environment automatically. You should not instantiate this service directly, and instead use the NewDatabaseV1ProjectService method instead.
func NewDatabaseV1ProjectService ¶
func NewDatabaseV1ProjectService(opts ...option.RequestOption) (r *DatabaseV1ProjectService)
NewDatabaseV1ProjectService generates a new service that applies the given options to each request. These options are applied after the parent client's options (if there is one), and before any request-specific options.
func (*DatabaseV1ProjectService) Delete ¶
func (r *DatabaseV1ProjectService) Delete(ctx context.Context, id string, opts ...option.RequestOption) (res *DatabaseV1ProjectDeleteResponse, err error)
Permanently deletes a database project from Neon and marks it as deleted in Case.dev. This action cannot be undone and will destroy all data including branches and databases. Use with caution.
func (*DatabaseV1ProjectService) Get ¶
func (r *DatabaseV1ProjectService) Get(ctx context.Context, id string, opts ...option.RequestOption) (res *DatabaseV1ProjectGetResponse, err error)
Retrieves detailed information about a specific database project including branches, databases, storage/compute metrics, connection host, and linked deployments. Fetches live usage statistics from Neon API.
func (*DatabaseV1ProjectService) GetConnection ¶
func (r *DatabaseV1ProjectService) GetConnection(ctx context.Context, id string, query DatabaseV1ProjectGetConnectionParams, opts ...option.RequestOption) (res *DatabaseV1ProjectGetConnectionResponse, err error)
Retrieves the PostgreSQL connection URI for a database project. Supports selecting specific branches and pooled vs direct connections. Connection strings include credentials and should be stored securely. Use for configuring applications and deployment environments.
func (*DatabaseV1ProjectService) List ¶
func (r *DatabaseV1ProjectService) List(ctx context.Context, opts ...option.RequestOption) (res *DatabaseV1ProjectListResponse, err error)
Retrieves all serverless Postgres database projects for the authenticated organization. Includes storage and compute metrics, plus linked application deployments and Compute instances.
func (*DatabaseV1ProjectService) ListBranches ¶
func (r *DatabaseV1ProjectService) ListBranches(ctx context.Context, id string, opts ...option.RequestOption) (res *DatabaseV1ProjectListBranchesResponse, err error)
Retrieves all branches for a database project. Branches enable isolated development and testing environments with instant point-in-time cloning. Each branch includes the default branch and any custom branches created for staging, testing, or feature development.
func (*DatabaseV1ProjectService) New ¶
func (r *DatabaseV1ProjectService) New(ctx context.Context, body DatabaseV1ProjectNewParams, opts ...option.RequestOption) (res *DatabaseV1ProjectNewResponse, err error)
Creates a new serverless Postgres database project powered by Neon. Includes automatic scaling, connection pooling, and a default 'main' branch with 'neondb' database. Supports branching for isolated dev/staging environments. Perfect for case management applications, document workflows, and litigation support systems.
func (*DatabaseV1ProjectService) NewBranch ¶
func (r *DatabaseV1ProjectService) NewBranch(ctx context.Context, id string, body DatabaseV1ProjectNewBranchParams, opts ...option.RequestOption) (res *DatabaseV1ProjectNewBranchResponse, err error)
Creates a new branch from the specified parent branch (or default 'main' branch). Branches provide instant point-in-time clones of your database for isolated development, staging, testing, or feature work. Perfect for testing schema changes, running migrations safely, or creating ephemeral preview environments.
type DatabaseV1Service ¶
type DatabaseV1Service struct {
Options []option.RequestOption
// Serverless PostgreSQL databases with instant branching
Projects *DatabaseV1ProjectService
}
Serverless PostgreSQL databases with instant branching
DatabaseV1Service contains methods and other services that help with interacting with the casedev API.
Note, unlike clients, this service does not read variables from the environment automatically. You should not instantiate this service directly, and instead use the NewDatabaseV1Service method instead.
func NewDatabaseV1Service ¶
func NewDatabaseV1Service(opts ...option.RequestOption) (r *DatabaseV1Service)
NewDatabaseV1Service generates a new service that applies the given options to each request. These options are applied after the parent client's options (if there is one), and before any request-specific options.
func (*DatabaseV1Service) GetUsage ¶
func (r *DatabaseV1Service) GetUsage(ctx context.Context, opts ...option.RequestOption) (res *DatabaseV1GetUsageResponse, err error)
Returns detailed database usage statistics and billing information for the current billing period. Includes compute hours, storage, data transfer, and branch counts with associated costs broken down by project.
type DocketDetail ¶ added in v0.8.0
type DocketDetail struct {
ID string `json:"id"`
AssignedTo string `json:"assignedTo" api:"nullable"`
CaseName string `json:"caseName" api:"nullable"`
Cause string `json:"cause" api:"nullable"`
Court string `json:"court" api:"nullable"`
CourtID string `json:"courtId" api:"nullable"`
DateFiled time.Time `json:"dateFiled" api:"nullable" format:"date"`
DateTerminated time.Time `json:"dateTerminated" api:"nullable" format:"date"`
DocketNumber string `json:"docketNumber" api:"nullable"`
NatureOfSuit string `json:"natureOfSuit" api:"nullable"`
PacerCaseID string `json:"pacerCaseId" api:"nullable"`
Parties []string `json:"parties"`
URL string `json:"url"`
JSON docketDetailJSON `json:"-"`
}
Full docket record (lookup mode)
func (*DocketDetail) UnmarshalJSON ¶ added in v0.8.0
func (r *DocketDetail) UnmarshalJSON(data []byte) (err error)
type DocketSearchResult ¶ added in v0.8.0
type DocketSearchResult struct {
ID string `json:"id"`
AssignedTo string `json:"assignedTo" api:"nullable"`
CaseName string `json:"caseName" api:"nullable"`
Cause string `json:"cause" api:"nullable"`
Court string `json:"court" api:"nullable"`
CourtID string `json:"courtId" api:"nullable"`
DateFiled time.Time `json:"dateFiled" api:"nullable" format:"date"`
DateTerminated time.Time `json:"dateTerminated" api:"nullable" format:"date"`
DocketNumber string `json:"docketNumber" api:"nullable"`
NatureOfSuit string `json:"natureOfSuit" api:"nullable"`
PacerCaseID string `json:"pacerCaseId" api:"nullable"`
Parties []string `json:"parties"`
URL string `json:"url"`
JSON docketSearchResultJSON `json:"-"`
}
func (*DocketSearchResult) UnmarshalJSON ¶ added in v0.8.0
func (r *DocketSearchResult) UnmarshalJSON(data []byte) (err error)
type FormatService ¶
type FormatService struct {
Options []option.RequestOption
// Document formatting and template rendering (MD/JSON to PDF/DOCX)
V1 *FormatV1Service
}
FormatService contains methods and other services that help with interacting with the casedev API.
Note, unlike clients, this service does not read variables from the environment automatically. You should not instantiate this service directly, and instead use the NewFormatService method instead.
func NewFormatService ¶
func NewFormatService(opts ...option.RequestOption) (r *FormatService)
NewFormatService generates a new service that applies the given options to each request. These options are applied after the parent client's options (if there is one), and before any request-specific options.
type FormatV1NewDocumentParams ¶
type FormatV1NewDocumentParams struct {
// The source content to format
Content param.Field[string] `json:"content" api:"required"`
// Desired output format
OutputFormat param.Field[FormatV1NewDocumentParamsOutputFormat] `json:"output_format" api:"required"`
// Format of the input content
InputFormat param.Field[FormatV1NewDocumentParamsInputFormat] `json:"input_format"`
// Optional template composition and styling settings used during document
// generation
Options param.Field[FormatV1NewDocumentParamsOptions] `json:"options"`
}
func (FormatV1NewDocumentParams) MarshalJSON ¶
func (r FormatV1NewDocumentParams) MarshalJSON() (data []byte, err error)
type FormatV1NewDocumentParamsInputFormat ¶
type FormatV1NewDocumentParamsInputFormat string
Format of the input content
const ( FormatV1NewDocumentParamsInputFormatMd FormatV1NewDocumentParamsInputFormat = "md" FormatV1NewDocumentParamsInputFormatJson FormatV1NewDocumentParamsInputFormat = "json" FormatV1NewDocumentParamsInputFormatText FormatV1NewDocumentParamsInputFormat = "text" )
func (FormatV1NewDocumentParamsInputFormat) IsKnown ¶
func (r FormatV1NewDocumentParamsInputFormat) IsKnown() bool
type FormatV1NewDocumentParamsOptions ¶
type FormatV1NewDocumentParamsOptions struct {
// Template components with variables
Components param.Field[[]FormatV1NewDocumentParamsOptionsComponent] `json:"components"`
}
Optional template composition and styling settings used during document generation
func (FormatV1NewDocumentParamsOptions) MarshalJSON ¶
func (r FormatV1NewDocumentParamsOptions) MarshalJSON() (data []byte, err error)
type FormatV1NewDocumentParamsOptionsComponent ¶
type FormatV1NewDocumentParamsOptionsComponent struct {
// Inline template content
Content param.Field[string] `json:"content"`
// Custom styling options
Styles param.Field[interface{}] `json:"styles"`
// ID of saved template component
TemplateID param.Field[string] `json:"templateId"`
// Variables for template interpolation
Variables param.Field[interface{}] `json:"variables"`
}
func (FormatV1NewDocumentParamsOptionsComponent) MarshalJSON ¶
func (r FormatV1NewDocumentParamsOptionsComponent) MarshalJSON() (data []byte, err error)
type FormatV1NewDocumentParamsOutputFormat ¶
type FormatV1NewDocumentParamsOutputFormat string
Desired output format
const ( FormatV1NewDocumentParamsOutputFormatPdf FormatV1NewDocumentParamsOutputFormat = "pdf" FormatV1NewDocumentParamsOutputFormatDocx FormatV1NewDocumentParamsOutputFormat = "docx" FormatV1NewDocumentParamsOutputFormatHTMLPreview FormatV1NewDocumentParamsOutputFormat = "html_preview" )
func (FormatV1NewDocumentParamsOutputFormat) IsKnown ¶
func (r FormatV1NewDocumentParamsOutputFormat) IsKnown() bool
type FormatV1Service ¶
type FormatV1Service struct {
Options []option.RequestOption
// Document formatting and template rendering (MD/JSON to PDF/DOCX)
Templates *FormatV1TemplateService
}
Document formatting and template rendering (MD/JSON to PDF/DOCX)
FormatV1Service contains methods and other services that help with interacting with the casedev API.
Note, unlike clients, this service does not read variables from the environment automatically. You should not instantiate this service directly, and instead use the NewFormatV1Service method instead.
func NewFormatV1Service ¶
func NewFormatV1Service(opts ...option.RequestOption) (r *FormatV1Service)
NewFormatV1Service generates a new service that applies the given options to each request. These options are applied after the parent client's options (if there is one), and before any request-specific options.
func (*FormatV1Service) NewDocument ¶
func (r *FormatV1Service) NewDocument(ctx context.Context, body FormatV1NewDocumentParams, opts ...option.RequestOption) (res *http.Response, err error)
Convert Markdown, JSON, or text content to professionally formatted PDF, DOCX, or HTML documents. Supports template components with variable interpolation for creating consistent legal documents like contracts, briefs, and reports.
type FormatV1TemplateGetResponse ¶
type FormatV1TemplateGetResponse struct {
// Unique template identifier
ID string `json:"id"`
// Template formatting rules and structure
Content interface{} `json:"content"`
// Template creation timestamp
CreatedAt time.Time `json:"createdAt" format:"date-time"`
// Template description
Description string `json:"description"`
// Template name
Name string `json:"name"`
// Organization ID that owns the template
OrganizationID string `json:"organizationId"`
// Template last modification timestamp
UpdatedAt time.Time `json:"updatedAt" format:"date-time"`
JSON formatV1TemplateGetResponseJSON `json:"-"`
}
func (*FormatV1TemplateGetResponse) UnmarshalJSON ¶
func (r *FormatV1TemplateGetResponse) UnmarshalJSON(data []byte) (err error)
type FormatV1TemplateListParams ¶
type FormatV1TemplateListParams struct {
// Filter templates by type (e.g., contract, pleading, letter)
Type param.Field[string] `query:"type"`
}
func (FormatV1TemplateListParams) URLQuery ¶
func (r FormatV1TemplateListParams) URLQuery() (v url.Values)
URLQuery serializes FormatV1TemplateListParams's query parameters as `url.Values`.
type FormatV1TemplateListResponse ¶
type FormatV1TemplateListResponse struct {
Templates []FormatV1TemplateListResponseTemplate `json:"templates"`
JSON formatV1TemplateListResponseJSON `json:"-"`
}
func (*FormatV1TemplateListResponse) UnmarshalJSON ¶
func (r *FormatV1TemplateListResponse) UnmarshalJSON(data []byte) (err error)
type FormatV1TemplateListResponseTemplate ¶
type FormatV1TemplateListResponseTemplate struct {
// Unique template identifier
ID string `json:"id"`
// Template creation timestamp
CreatedAt time.Time `json:"createdAt" format:"date-time"`
// Template description
Description string `json:"description"`
// Template name
Name string `json:"name"`
// Template tags for organization
Tags []interface{} `json:"tags"`
// Template type/category
Type string `json:"type"`
// Number of times template has been used
UsageCount int64 `json:"usageCount"`
// Template variables for customization
Variables []interface{} `json:"variables"`
JSON formatV1TemplateListResponseTemplateJSON `json:"-"`
}
func (*FormatV1TemplateListResponseTemplate) UnmarshalJSON ¶
func (r *FormatV1TemplateListResponseTemplate) UnmarshalJSON(data []byte) (err error)
type FormatV1TemplateNewParams ¶
type FormatV1TemplateNewParams struct {
// Template content with {{variable}} placeholders
Content param.Field[string] `json:"content" api:"required"`
// Template name
Name param.Field[string] `json:"name" api:"required"`
// Template type
Type param.Field[FormatV1TemplateNewParamsType] `json:"type" api:"required"`
// Template description
Description param.Field[string] `json:"description"`
// CSS styles for the template
Styles param.Field[interface{}] `json:"styles"`
// Template tags for organization
Tags param.Field[[]string] `json:"tags"`
// Template variables (auto-detected if not provided)
Variables param.Field[[]string] `json:"variables"`
}
func (FormatV1TemplateNewParams) MarshalJSON ¶
func (r FormatV1TemplateNewParams) MarshalJSON() (data []byte, err error)
type FormatV1TemplateNewParamsType ¶
type FormatV1TemplateNewParamsType string
Template type
const ( FormatV1TemplateNewParamsTypeCaption FormatV1TemplateNewParamsType = "caption" FormatV1TemplateNewParamsTypeSignature FormatV1TemplateNewParamsType = "signature" FormatV1TemplateNewParamsTypeLetterhead FormatV1TemplateNewParamsType = "letterhead" FormatV1TemplateNewParamsTypeCertificate FormatV1TemplateNewParamsType = "certificate" FormatV1TemplateNewParamsTypeCustom FormatV1TemplateNewParamsType = "custom" )
func (FormatV1TemplateNewParamsType) IsKnown ¶
func (r FormatV1TemplateNewParamsType) IsKnown() bool
type FormatV1TemplateNewResponse ¶
type FormatV1TemplateNewResponse struct {
// Template ID
ID string `json:"id"`
// Creation timestamp
CreatedAt time.Time `json:"createdAt" format:"date-time"`
// Template name
Name string `json:"name"`
// Template type
Type string `json:"type"`
// Detected template variables
Variables []string `json:"variables"`
JSON formatV1TemplateNewResponseJSON `json:"-"`
}
func (*FormatV1TemplateNewResponse) UnmarshalJSON ¶
func (r *FormatV1TemplateNewResponse) UnmarshalJSON(data []byte) (err error)
type FormatV1TemplateService ¶
type FormatV1TemplateService struct {
Options []option.RequestOption
}
Document formatting and template rendering (MD/JSON to PDF/DOCX)
FormatV1TemplateService contains methods and other services that help with interacting with the casedev API.
Note, unlike clients, this service does not read variables from the environment automatically. You should not instantiate this service directly, and instead use the NewFormatV1TemplateService method instead.
func NewFormatV1TemplateService ¶
func NewFormatV1TemplateService(opts ...option.RequestOption) (r *FormatV1TemplateService)
NewFormatV1TemplateService generates a new service that applies the given options to each request. These options are applied after the parent client's options (if there is one), and before any request-specific options.
func (*FormatV1TemplateService) Get ¶
func (r *FormatV1TemplateService) Get(ctx context.Context, id string, opts ...option.RequestOption) (res *FormatV1TemplateGetResponse, err error)
Retrieve a specific document format template by ID. Format templates define how documents should be structured and formatted for specific legal use cases such as contracts, briefs, or pleadings.
func (*FormatV1TemplateService) List ¶
func (r *FormatV1TemplateService) List(ctx context.Context, query FormatV1TemplateListParams, opts ...option.RequestOption) (res *FormatV1TemplateListResponse, err error)
Retrieve all format templates for the organization. Templates define reusable document formatting patterns with customizable variables for consistent legal document generation.
Filter by type to get specific template categories like contracts, pleadings, or correspondence.
func (*FormatV1TemplateService) New ¶
func (r *FormatV1TemplateService) New(ctx context.Context, body FormatV1TemplateNewParams, opts ...option.RequestOption) (res *FormatV1TemplateNewResponse, err error)
Create a new format template for document formatting. Templates support variables using `{{variable}}` syntax and can be used for captions, signatures, letterheads, certificates, footers, or custom formatting needs.
type LegalService ¶
type LegalService struct {
Options []option.RequestOption
// Legal research tools including citation verification
V1 *LegalV1Service
}
LegalService contains methods and other services that help with interacting with the casedev API.
Note, unlike clients, this service does not read variables from the environment automatically. You should not instantiate this service directly, and instead use the NewLegalService method instead.
func NewLegalService ¶
func NewLegalService(opts ...option.RequestOption) (r *LegalService)
NewLegalService generates a new service that applies the given options to each request. These options are applied after the parent client's options (if there is one), and before any request-specific options.
type LegalV1DocketParams ¶ added in v0.5.0
type LegalV1DocketParams struct {
// Search dockets or look up a docket by ID
Type param.Field[LegalV1DocketParamsType] `json:"type" api:"required"`
// Required when live: true. Acknowledges that PACER fees (up to $3.00 per docket)
// plus a $0.05 service fee will be charged to your account.
AcknowledgePacerFees param.Field[bool] `json:"acknowledgePacerFees"`
// Optional court slug for filtering (e.g. "nysd", "ca9", "cafc"). Use
// legal.listCourts() to find slugs.
Court param.Field[string] `json:"court"`
// Optional lower bound for filing date (YYYY-MM-DD)
DateFiledAfter param.Field[time.Time] `json:"dateFiledAfter" format:"date"`
// Optional upper bound for filing date (YYYY-MM-DD)
DateFiledBefore param.Field[time.Time] `json:"dateFiledBefore" format:"date"`
// Docket ID (required for lookup)
DocketID param.Field[string] `json:"docketId"`
// Include docket entries/filings in lookup responses. Coming soon — currently
// returns 501. The parameter is accepted for forward compatibility.
IncludeEntries param.Field[bool] `json:"includeEntries"`
// Page size for search results or entry list (default 25 for search, 50 for
// lookup)
Limit param.Field[int64] `json:"limit"`
// Trigger a live PACER fetch for dockets not yet in the RECAP archive. Requires
// acknowledgePacerFees: true. PACER charges up to $3.00 per docket sheet plus a
// $0.05 service fee. Only valid with type: "lookup".
Live param.Field[bool] `json:"live"`
// Offset for search results or entry list
Offset param.Field[int64] `json:"offset"`
// Case name or party name search query (required for search)
Query param.Field[string] `json:"query"`
}
func (LegalV1DocketParams) MarshalJSON ¶ added in v0.5.0
func (r LegalV1DocketParams) MarshalJSON() (data []byte, err error)
type LegalV1DocketParamsType ¶ added in v0.5.0
type LegalV1DocketParamsType string
Search dockets or look up a docket by ID
const ( LegalV1DocketParamsTypeSearch LegalV1DocketParamsType = "search" LegalV1DocketParamsTypeLookup LegalV1DocketParamsType = "lookup" )
func (LegalV1DocketParamsType) IsKnown ¶ added in v0.5.0
func (r LegalV1DocketParamsType) IsKnown() bool
type LegalV1DocketResponse ¶ added in v0.5.0
type LegalV1DocketResponse struct {
// Echo of court filter (search mode only)
Court string `json:"court" api:"nullable"`
// Echo of date filter
DateFiledAfter time.Time `json:"dateFiledAfter" api:"nullable" format:"date"`
// Echo of date filter
DateFiledBefore time.Time `json:"dateFiledBefore" api:"nullable" format:"date"`
// Full docket record (lookup mode)
Docket DocketDetail `json:"docket" api:"nullable"`
// Search results (search mode)
Dockets []DocketSearchResult `json:"dockets"`
// Docket entries/filings (lookup mode with includeEntries)
Entries []LegalV1DocketResponseEntry `json:"entries" api:"nullable"`
Found int64 `json:"found"`
// Whether entries were requested (lookup mode only)
IncludeEntries bool `json:"includeEntries"`
// Whether this was a live PACER fetch (lookup mode only)
Live bool `json:"live"`
// PACER fee information (present when live: true)
PacerFees LegalV1DocketResponsePacerFees `json:"pacerFees" api:"nullable"`
// Pagination info for entry list (lookup mode with includeEntries)
Pagination LegalV1DocketResponsePagination `json:"pagination" api:"nullable"`
// Echo of search query (search mode only)
Query string `json:"query" api:"nullable"`
Type LegalV1DocketResponseType `json:"type"`
JSON legalV1DocketResponseJSON `json:"-"`
}
func (*LegalV1DocketResponse) UnmarshalJSON ¶ added in v0.5.0
func (r *LegalV1DocketResponse) UnmarshalJSON(data []byte) (err error)
type LegalV1DocketResponseEntriesDocument ¶ added in v0.5.0
type LegalV1DocketResponseEntriesDocument struct {
ID string `json:"id"`
AttachmentNumber int64 `json:"attachmentNumber" api:"nullable"`
Description string `json:"description" api:"nullable"`
DocumentNumber string `json:"documentNumber" api:"nullable"`
IsAvailable bool `json:"isAvailable"`
PageCount int64 `json:"pageCount" api:"nullable"`
PdfURL string `json:"pdfUrl" api:"nullable"`
JSON legalV1DocketResponseEntriesDocumentJSON `json:"-"`
}
func (*LegalV1DocketResponseEntriesDocument) UnmarshalJSON ¶ added in v0.5.0
func (r *LegalV1DocketResponseEntriesDocument) UnmarshalJSON(data []byte) (err error)
type LegalV1DocketResponseEntry ¶ added in v0.5.0
type LegalV1DocketResponseEntry struct {
Date time.Time `json:"date" api:"nullable" format:"date"`
Description string `json:"description" api:"nullable"`
Documents []LegalV1DocketResponseEntriesDocument `json:"documents"`
EntryNumber int64 `json:"entryNumber" api:"nullable"`
JSON legalV1DocketResponseEntryJSON `json:"-"`
}
func (*LegalV1DocketResponseEntry) UnmarshalJSON ¶ added in v0.5.0
func (r *LegalV1DocketResponseEntry) UnmarshalJSON(data []byte) (err error)
type LegalV1DocketResponsePacerFees ¶ added in v0.15.0
type LegalV1DocketResponsePacerFees struct {
Currency LegalV1DocketResponsePacerFeesCurrency `json:"currency"`
// Time taken for PACER fetch in milliseconds
FetchDurationMs int64 `json:"fetchDurationMs"`
// Maximum PACER charge per docket in USD
MaxPacerCost float64 `json:"maxPacerCost"`
// CaseMark service fee in USD
ServiceFee float64 `json:"serviceFee"`
JSON legalV1DocketResponsePacerFeesJSON `json:"-"`
}
PACER fee information (present when live: true)
func (*LegalV1DocketResponsePacerFees) UnmarshalJSON ¶ added in v0.15.0
func (r *LegalV1DocketResponsePacerFees) UnmarshalJSON(data []byte) (err error)
type LegalV1DocketResponsePacerFeesCurrency ¶ added in v0.15.0
type LegalV1DocketResponsePacerFeesCurrency string
const (
LegalV1DocketResponsePacerFeesCurrencyUsd LegalV1DocketResponsePacerFeesCurrency = "USD"
)
func (LegalV1DocketResponsePacerFeesCurrency) IsKnown ¶ added in v0.15.0
func (r LegalV1DocketResponsePacerFeesCurrency) IsKnown() bool
type LegalV1DocketResponsePagination ¶ added in v0.5.0
type LegalV1DocketResponsePagination struct {
Limit int64 `json:"limit"`
Offset int64 `json:"offset"`
Returned int64 `json:"returned"`
JSON legalV1DocketResponsePaginationJSON `json:"-"`
}
Pagination info for entry list (lookup mode with includeEntries)
func (*LegalV1DocketResponsePagination) UnmarshalJSON ¶ added in v0.5.0
func (r *LegalV1DocketResponsePagination) UnmarshalJSON(data []byte) (err error)
type LegalV1DocketResponseType ¶ added in v0.5.0
type LegalV1DocketResponseType string
const ( LegalV1DocketResponseTypeSearch LegalV1DocketResponseType = "search" LegalV1DocketResponseTypeLookup LegalV1DocketResponseType = "lookup" )
func (LegalV1DocketResponseType) IsKnown ¶ added in v0.5.0
func (r LegalV1DocketResponseType) IsKnown() bool
type LegalV1DraftParams ¶ added in v0.10.0
type LegalV1DraftParams struct {
// What to draft — the core task. E.g., "Motion to compel defendant to produce
// discovery responses"
Instructions param.Field[string] `json:"instructions" api:"required"`
// Vault ID where the final document will be uploaded
VaultID param.Field[string] `json:"vault_id" api:"required"`
// Research and include legal citations
Citations param.Field[bool] `json:"citations"`
// Court or jurisdiction formatting hint. Triggers a legal-skills search. E.g.,
// "California Superior Court", "SDNY", "federal pleading"
Format param.Field[string] `json:"format"`
// Target document length
Length param.Field[LegalV1DraftParamsLength] `json:"length"`
// LLM model override. Defaults to anthropic/claude-sonnet-4.6
Model param.Field[string] `json:"model"`
// Vault object IDs to use as source/reference documents
ObjectIDs param.Field[[]string] `json:"object_ids"`
// Filename for the output document. Auto-generated if omitted.
OutputName param.Field[string] `json:"output_name"`
// Output file format
OutputType param.Field[LegalV1DraftParamsOutputType] `json:"output_type"`
// Verify all citations in a loop — re-run verification and repair bad citations
// until they pass
Verified param.Field[bool] `json:"verified"`
}
func (LegalV1DraftParams) MarshalJSON ¶ added in v0.10.0
func (r LegalV1DraftParams) MarshalJSON() (data []byte, err error)
type LegalV1DraftParamsLength ¶ added in v0.10.0
type LegalV1DraftParamsLength struct {
// Target value (e.g., 2000 words or 5 pages)
Target param.Field[float64] `json:"target"`
// Whether the target length is measured in words or pages
Unit param.Field[LegalV1DraftParamsLengthUnit] `json:"unit"`
}
Target document length
func (LegalV1DraftParamsLength) MarshalJSON ¶ added in v0.10.0
func (r LegalV1DraftParamsLength) MarshalJSON() (data []byte, err error)
type LegalV1DraftParamsLengthUnit ¶ added in v0.10.0
type LegalV1DraftParamsLengthUnit string
Whether the target length is measured in words or pages
const ( LegalV1DraftParamsLengthUnitWords LegalV1DraftParamsLengthUnit = "words" LegalV1DraftParamsLengthUnitPages LegalV1DraftParamsLengthUnit = "pages" )
func (LegalV1DraftParamsLengthUnit) IsKnown ¶ added in v0.10.0
func (r LegalV1DraftParamsLengthUnit) IsKnown() bool
type LegalV1DraftParamsOutputType ¶ added in v0.10.0
type LegalV1DraftParamsOutputType string
Output file format
const ( LegalV1DraftParamsOutputTypePdf LegalV1DraftParamsOutputType = "pdf" LegalV1DraftParamsOutputTypeDocx LegalV1DraftParamsOutputType = "docx" LegalV1DraftParamsOutputTypeXlsx LegalV1DraftParamsOutputType = "xlsx" LegalV1DraftParamsOutputTypePptx LegalV1DraftParamsOutputType = "pptx" LegalV1DraftParamsOutputTypeMd LegalV1DraftParamsOutputType = "md" )
func (LegalV1DraftParamsOutputType) IsKnown ¶ added in v0.10.0
func (r LegalV1DraftParamsOutputType) IsKnown() bool
type LegalV1DraftResponse ¶ added in v0.10.0
type LegalV1DraftResponse struct {
// Ephemeral agent ID
AgentID string `json:"agent_id"`
Message string `json:"message"`
// Run ID — poll /agent/v1/run/:id/status for progress
RunID string `json:"run_id"`
Status LegalV1DraftResponseStatus `json:"status"`
JSON legalV1DraftResponseJSON `json:"-"`
}
func (*LegalV1DraftResponse) UnmarshalJSON ¶ added in v0.10.0
func (r *LegalV1DraftResponse) UnmarshalJSON(data []byte) (err error)
type LegalV1DraftResponseStatus ¶ added in v0.10.0
type LegalV1DraftResponseStatus string
const (
LegalV1DraftResponseStatusRunning LegalV1DraftResponseStatus = "running"
)
func (LegalV1DraftResponseStatus) IsKnown ¶ added in v0.10.0
func (r LegalV1DraftResponseStatus) IsKnown() bool
type LegalV1FindParams ¶
type LegalV1FindParams struct {
// Search query (e.g., "fair use copyright", "Miranda rights")
Query param.Field[string] `json:"query" api:"required"`
// Optional jurisdiction ID from resolveJurisdiction (e.g., "california",
// "us-federal")
Jurisdiction param.Field[string] `json:"jurisdiction"`
// Number of results 1-25 (default: 10)
NumResults param.Field[int64] `json:"numResults"`
}
func (LegalV1FindParams) MarshalJSON ¶
func (r LegalV1FindParams) MarshalJSON() (data []byte, err error)
type LegalV1FindResponse ¶
type LegalV1FindResponse struct {
Candidates []LegalV1FindResponseCandidate `json:"candidates"`
// Number of candidates found
Found int64 `json:"found"`
// Usage guidance
Hint string `json:"hint"`
// Jurisdiction filter applied
Jurisdiction string `json:"jurisdiction"`
// Original search query
Query string `json:"query"`
JSON legalV1FindResponseJSON `json:"-"`
}
func (*LegalV1FindResponse) UnmarshalJSON ¶
func (r *LegalV1FindResponse) UnmarshalJSON(data []byte) (err error)
type LegalV1FindResponseCandidate ¶
type LegalV1FindResponseCandidate struct {
// Text excerpt from the document
Snippet string `json:"snippet"`
// Domain of the source
Source string `json:"source"`
// Title of the document
Title string `json:"title"`
// URL of the legal source
URL string `json:"url"`
JSON legalV1FindResponseCandidateJSON `json:"-"`
}
func (*LegalV1FindResponseCandidate) UnmarshalJSON ¶
func (r *LegalV1FindResponseCandidate) UnmarshalJSON(data []byte) (err error)
type LegalV1GetCitationsFromURLParams ¶
type LegalV1GetCitationsFromURLParams struct {
// URL of the legal document to extract citations from
URL param.Field[string] `json:"url" api:"required" format:"uri"`
}
func (LegalV1GetCitationsFromURLParams) MarshalJSON ¶
func (r LegalV1GetCitationsFromURLParams) MarshalJSON() (data []byte, err error)
type LegalV1GetCitationsFromURLResponse ¶
type LegalV1GetCitationsFromURLResponse struct {
Citations LegalV1GetCitationsFromURLResponseCitations `json:"citations"`
// External links found in the document
ExternalLinks []string `json:"externalLinks"`
// Usage guidance
Hint string `json:"hint"`
// Document title
Title string `json:"title"`
// Total citations found
TotalCitations int64 `json:"totalCitations"`
// Source document URL
URL string `json:"url"`
JSON legalV1GetCitationsFromURLResponseJSON `json:"-"`
}
func (*LegalV1GetCitationsFromURLResponse) UnmarshalJSON ¶
func (r *LegalV1GetCitationsFromURLResponse) UnmarshalJSON(data []byte) (err error)
type LegalV1GetCitationsFromURLResponseCitations ¶
type LegalV1GetCitationsFromURLResponseCitations struct {
Cases []LegalV1GetCitationsFromURLResponseCitationsCase `json:"cases"`
Regulations []LegalV1GetCitationsFromURLResponseCitationsRegulation `json:"regulations"`
Statutes []LegalV1GetCitationsFromURLResponseCitationsStatute `json:"statutes"`
JSON legalV1GetCitationsFromURLResponseCitationsJSON `json:"-"`
}
func (*LegalV1GetCitationsFromURLResponseCitations) UnmarshalJSON ¶
func (r *LegalV1GetCitationsFromURLResponseCitations) UnmarshalJSON(data []byte) (err error)
type LegalV1GetCitationsFromURLResponseCitationsCase ¶
type LegalV1GetCitationsFromURLResponseCitationsCase struct {
// The citation string
Citation string `json:"citation"`
// Number of occurrences
Count int64 `json:"count"`
// Citation type (usReporter, federalReporter, etc.)
Type string `json:"type"`
JSON legalV1GetCitationsFromURLResponseCitationsCaseJSON `json:"-"`
}
func (*LegalV1GetCitationsFromURLResponseCitationsCase) UnmarshalJSON ¶
func (r *LegalV1GetCitationsFromURLResponseCitationsCase) UnmarshalJSON(data []byte) (err error)
type LegalV1GetCitationsFromURLResponseCitationsRegulation ¶
type LegalV1GetCitationsFromURLResponseCitationsRegulation struct {
// The citation string
Citation string `json:"citation"`
// Number of occurrences
Count int64 `json:"count"`
// Citation type (cfr)
Type string `json:"type"`
JSON legalV1GetCitationsFromURLResponseCitationsRegulationJSON `json:"-"`
}
func (*LegalV1GetCitationsFromURLResponseCitationsRegulation) UnmarshalJSON ¶
func (r *LegalV1GetCitationsFromURLResponseCitationsRegulation) UnmarshalJSON(data []byte) (err error)
type LegalV1GetCitationsFromURLResponseCitationsStatute ¶
type LegalV1GetCitationsFromURLResponseCitationsStatute struct {
// The citation string
Citation string `json:"citation"`
// Number of occurrences
Count int64 `json:"count"`
// Citation type (usc)
Type string `json:"type"`
JSON legalV1GetCitationsFromURLResponseCitationsStatuteJSON `json:"-"`
}
func (*LegalV1GetCitationsFromURLResponseCitationsStatute) UnmarshalJSON ¶
func (r *LegalV1GetCitationsFromURLResponseCitationsStatute) UnmarshalJSON(data []byte) (err error)
type LegalV1GetCitationsParams ¶
type LegalV1GetCitationsParams struct {
// Text containing citations to extract. Can be a single citation (e.g., "531 U.S.
// 98") or a full document with multiple citations.
Text param.Field[string] `json:"text" api:"required"`
}
func (LegalV1GetCitationsParams) MarshalJSON ¶
func (r LegalV1GetCitationsParams) MarshalJSON() (data []byte, err error)
type LegalV1GetCitationsResponse ¶
type LegalV1GetCitationsResponse struct {
Citations []LegalV1GetCitationsResponseCitation `json:"citations"`
JSON legalV1GetCitationsResponseJSON `json:"-"`
}
func (*LegalV1GetCitationsResponse) UnmarshalJSON ¶
func (r *LegalV1GetCitationsResponse) UnmarshalJSON(data []byte) (err error)
type LegalV1GetCitationsResponseCitation ¶
type LegalV1GetCitationsResponseCitation struct {
// Structured Bluebook components. Null if citation format is not recognized.
Components LegalV1GetCitationsResponseCitationsComponents `json:"components" api:"nullable"`
// Whether citation was found in CourtListener database
Found bool `json:"found"`
// Normalized citation string
Normalized string `json:"normalized"`
// Original citation as found in text
Original string `json:"original"`
Span LegalV1GetCitationsResponseCitationsSpan `json:"span"`
JSON legalV1GetCitationsResponseCitationJSON `json:"-"`
}
func (*LegalV1GetCitationsResponseCitation) UnmarshalJSON ¶
func (r *LegalV1GetCitationsResponseCitation) UnmarshalJSON(data []byte) (err error)
type LegalV1GetCitationsResponseCitationsComponents ¶
type LegalV1GetCitationsResponseCitationsComponents struct {
// Case name, e.g., "Bush v. Gore"
CaseName string `json:"caseName"`
// Court identifier
Court string `json:"court"`
// Starting page number
Page int64 `json:"page"`
// Pin cite (specific page)
PinCite int64 `json:"pinCite"`
// Reporter abbreviation, e.g., "U.S."
Reporter string `json:"reporter"`
// Volume number
Volume int64 `json:"volume"`
// Decision year
Year int64 `json:"year"`
JSON legalV1GetCitationsResponseCitationsComponentsJSON `json:"-"`
}
Structured Bluebook components. Null if citation format is not recognized.
func (*LegalV1GetCitationsResponseCitationsComponents) UnmarshalJSON ¶
func (r *LegalV1GetCitationsResponseCitationsComponents) UnmarshalJSON(data []byte) (err error)
type LegalV1GetCitationsResponseCitationsSpan ¶
type LegalV1GetCitationsResponseCitationsSpan struct {
End int64 `json:"end"`
Start int64 `json:"start"`
JSON legalV1GetCitationsResponseCitationsSpanJSON `json:"-"`
}
func (*LegalV1GetCitationsResponseCitationsSpan) UnmarshalJSON ¶
func (r *LegalV1GetCitationsResponseCitationsSpan) UnmarshalJSON(data []byte) (err error)
type LegalV1GetFullTextParams ¶
type LegalV1GetFullTextParams struct {
// URL of the verified legal document
URL param.Field[string] `json:"url" api:"required" format:"uri"`
// Optional query to extract relevant highlights (e.g., "What is the holding?")
HighlightQuery param.Field[string] `json:"highlightQuery"`
// Maximum characters to return (default: 10000, max: 50000)
MaxCharacters param.Field[int64] `json:"maxCharacters"`
// Optional query for generating a summary (e.g., "Summarize the key ruling")
SummaryQuery param.Field[string] `json:"summaryQuery"`
}
func (LegalV1GetFullTextParams) MarshalJSON ¶
func (r LegalV1GetFullTextParams) MarshalJSON() (data []byte, err error)
type LegalV1GetFullTextResponse ¶
type LegalV1GetFullTextResponse struct {
// Author or court
Author string `json:"author" api:"nullable"`
// Total characters in text
CharacterCount int64 `json:"characterCount"`
// Highlighted relevant passages
Highlights []string `json:"highlights"`
// Publication date
PublishedDate string `json:"publishedDate" api:"nullable"`
// AI-generated summary
Summary string `json:"summary" api:"nullable"`
// Full document text
Text string `json:"text"`
// Document title
Title string `json:"title"`
// Document URL
URL string `json:"url"`
JSON legalV1GetFullTextResponseJSON `json:"-"`
}
func (*LegalV1GetFullTextResponse) UnmarshalJSON ¶
func (r *LegalV1GetFullTextResponse) UnmarshalJSON(data []byte) (err error)
type LegalV1ListCourtsParams ¶ added in v0.5.0
type LegalV1ListCourtsParams struct {
// Only return courts with available docket data
InUseOnly param.Field[bool] `json:"inUseOnly"`
// Optional jurisdiction code filter (e.g. FD for Federal District, F for all
// Federal, S for State)
Jurisdiction param.Field[string] `json:"jurisdiction"`
// Maximum number of courts to return
Limit param.Field[int64] `json:"limit"`
// Number of courts to skip before returning results
Offset param.Field[int64] `json:"offset"`
// Search by court name or slug (e.g. "Northern District", "nysd", "ca9")
Query param.Field[string] `json:"query"`
}
func (LegalV1ListCourtsParams) MarshalJSON ¶ added in v0.5.0
func (r LegalV1ListCourtsParams) MarshalJSON() (data []byte, err error)
type LegalV1ListCourtsResponse ¶ added in v0.5.0
type LegalV1ListCourtsResponse struct {
Courts []LegalV1ListCourtsResponseCourt `json:"courts"`
Found int64 `json:"found"`
// Whether results are filtered to in-use courts only
InUseOnly bool `json:"inUseOnly"`
Jurisdiction string `json:"jurisdiction" api:"nullable"`
Query string `json:"query" api:"nullable"`
JSON legalV1ListCourtsResponseJSON `json:"-"`
}
func (*LegalV1ListCourtsResponse) UnmarshalJSON ¶ added in v0.5.0
func (r *LegalV1ListCourtsResponse) UnmarshalJSON(data []byte) (err error)
type LegalV1ListCourtsResponseCourt ¶ added in v0.5.0
type LegalV1ListCourtsResponseCourt struct {
// Court slug (use as the court parameter in legal.docket())
ID string `json:"id"`
FullName string `json:"fullName" api:"nullable"`
Jurisdiction string `json:"jurisdiction" api:"nullable"`
PacerCourtID int64 `json:"pacerCourtId" api:"nullable"`
ShortName string `json:"shortName" api:"nullable"`
JSON legalV1ListCourtsResponseCourtJSON `json:"-"`
}
func (*LegalV1ListCourtsResponseCourt) UnmarshalJSON ¶ added in v0.5.0
func (r *LegalV1ListCourtsResponseCourt) UnmarshalJSON(data []byte) (err error)
type LegalV1ListJurisdictionsParams ¶
type LegalV1ListJurisdictionsParams struct {
// Jurisdiction name (e.g., "California", "US Federal", "NY")
Name param.Field[string] `json:"name" api:"required"`
}
func (LegalV1ListJurisdictionsParams) MarshalJSON ¶
func (r LegalV1ListJurisdictionsParams) MarshalJSON() (data []byte, err error)
type LegalV1ListJurisdictionsResponse ¶
type LegalV1ListJurisdictionsResponse struct {
// Number of matching jurisdictions
Found int64 `json:"found"`
// Usage guidance
Hint string `json:"hint"`
Jurisdictions []LegalV1ListJurisdictionsResponseJurisdiction `json:"jurisdictions"`
// Original search query
Query string `json:"query"`
JSON legalV1ListJurisdictionsResponseJSON `json:"-"`
}
func (*LegalV1ListJurisdictionsResponse) UnmarshalJSON ¶
func (r *LegalV1ListJurisdictionsResponse) UnmarshalJSON(data []byte) (err error)
type LegalV1ListJurisdictionsResponseJurisdiction ¶
type LegalV1ListJurisdictionsResponseJurisdiction struct {
// Jurisdiction ID to use in other endpoints
ID string `json:"id"`
// Jurisdiction level
Level LegalV1ListJurisdictionsResponseJurisdictionsLevel `json:"level"`
// Full jurisdiction name
Name string `json:"name"`
// State abbreviation (if applicable)
State string `json:"state" api:"nullable"`
JSON legalV1ListJurisdictionsResponseJurisdictionJSON `json:"-"`
}
func (*LegalV1ListJurisdictionsResponseJurisdiction) UnmarshalJSON ¶
func (r *LegalV1ListJurisdictionsResponseJurisdiction) UnmarshalJSON(data []byte) (err error)
type LegalV1ListJurisdictionsResponseJurisdictionsLevel ¶
type LegalV1ListJurisdictionsResponseJurisdictionsLevel string
Jurisdiction level
const ( LegalV1ListJurisdictionsResponseJurisdictionsLevelFederal LegalV1ListJurisdictionsResponseJurisdictionsLevel = "federal" LegalV1ListJurisdictionsResponseJurisdictionsLevelState LegalV1ListJurisdictionsResponseJurisdictionsLevel = "state" LegalV1ListJurisdictionsResponseJurisdictionsLevelCounty LegalV1ListJurisdictionsResponseJurisdictionsLevel = "county" LegalV1ListJurisdictionsResponseJurisdictionsLevelMunicipal LegalV1ListJurisdictionsResponseJurisdictionsLevel = "municipal" )
func (LegalV1ListJurisdictionsResponseJurisdictionsLevel) IsKnown ¶
func (r LegalV1ListJurisdictionsResponseJurisdictionsLevel) IsKnown() bool
type LegalV1PatentSearchParams ¶
type LegalV1PatentSearchParams struct {
// Free-text search across all patent fields, or field-specific query (e.g.
// "applicationMetaData.patentNumber:11234567"). Supports AND, OR, NOT operators.
Query param.Field[string] `json:"query" api:"required"`
// Filter by application status (e.g. "Patented Case", "Abandoned", "Pending")
ApplicationStatus param.Field[string] `json:"applicationStatus"`
// Filter by application type
ApplicationType param.Field[LegalV1PatentSearchParamsApplicationType] `json:"applicationType"`
// Filter by assignee/owner name (e.g. "Google LLC")
Assignee param.Field[string] `json:"assignee"`
// Start of filing date range (YYYY-MM-DD)
FilingDateFrom param.Field[time.Time] `json:"filingDateFrom" format:"date"`
// End of filing date range (YYYY-MM-DD)
FilingDateTo param.Field[time.Time] `json:"filingDateTo" format:"date"`
// Start of grant date range (YYYY-MM-DD)
GrantDateFrom param.Field[time.Time] `json:"grantDateFrom" format:"date"`
// End of grant date range (YYYY-MM-DD)
GrantDateTo param.Field[time.Time] `json:"grantDateTo" format:"date"`
// Filter by inventor name
Inventor param.Field[string] `json:"inventor"`
// Number of results to return (default 25, max 100)
Limit param.Field[int64] `json:"limit"`
// Starting position for pagination
Offset param.Field[int64] `json:"offset"`
// Field to sort results by
SortBy param.Field[LegalV1PatentSearchParamsSortBy] `json:"sortBy"`
// Sort order (default desc, newest first)
SortOrder param.Field[LegalV1PatentSearchParamsSortOrder] `json:"sortOrder"`
}
func (LegalV1PatentSearchParams) MarshalJSON ¶
func (r LegalV1PatentSearchParams) MarshalJSON() (data []byte, err error)
type LegalV1PatentSearchParamsApplicationType ¶
type LegalV1PatentSearchParamsApplicationType string
Filter by application type
const ( LegalV1PatentSearchParamsApplicationTypeUtility LegalV1PatentSearchParamsApplicationType = "Utility" LegalV1PatentSearchParamsApplicationTypeDesign LegalV1PatentSearchParamsApplicationType = "Design" LegalV1PatentSearchParamsApplicationTypePlant LegalV1PatentSearchParamsApplicationType = "Plant" LegalV1PatentSearchParamsApplicationTypeProvisional LegalV1PatentSearchParamsApplicationType = "Provisional" LegalV1PatentSearchParamsApplicationTypeReissue LegalV1PatentSearchParamsApplicationType = "Reissue" )
func (LegalV1PatentSearchParamsApplicationType) IsKnown ¶
func (r LegalV1PatentSearchParamsApplicationType) IsKnown() bool
type LegalV1PatentSearchParamsSortBy ¶
type LegalV1PatentSearchParamsSortBy string
Field to sort results by
const ( LegalV1PatentSearchParamsSortByFilingDate LegalV1PatentSearchParamsSortBy = "filingDate" LegalV1PatentSearchParamsSortByGrantDate LegalV1PatentSearchParamsSortBy = "grantDate" )
func (LegalV1PatentSearchParamsSortBy) IsKnown ¶
func (r LegalV1PatentSearchParamsSortBy) IsKnown() bool
type LegalV1PatentSearchParamsSortOrder ¶
type LegalV1PatentSearchParamsSortOrder string
Sort order (default desc, newest first)
const ( LegalV1PatentSearchParamsSortOrderAsc LegalV1PatentSearchParamsSortOrder = "asc" LegalV1PatentSearchParamsSortOrderDesc LegalV1PatentSearchParamsSortOrder = "desc" )
func (LegalV1PatentSearchParamsSortOrder) IsKnown ¶
func (r LegalV1PatentSearchParamsSortOrder) IsKnown() bool
type LegalV1PatentSearchResponse ¶
type LegalV1PatentSearchResponse struct {
// Number of results returned
Limit int64 `json:"limit"`
// Current pagination offset
Offset int64 `json:"offset"`
// Original search query
Query string `json:"query"`
// Array of matching patent applications
Results []LegalV1PatentSearchResponseResult `json:"results"`
// Total number of matching patent applications
TotalResults int64 `json:"totalResults"`
JSON legalV1PatentSearchResponseJSON `json:"-"`
}
func (*LegalV1PatentSearchResponse) UnmarshalJSON ¶
func (r *LegalV1PatentSearchResponse) UnmarshalJSON(data []byte) (err error)
type LegalV1PatentSearchResponseResult ¶
type LegalV1PatentSearchResponseResult struct {
// Patent application serial number
ApplicationNumber string `json:"applicationNumber"`
// Application type (Utility, Design, Plant, etc.)
ApplicationType string `json:"applicationType"`
// List of assignee/owner names
Assignees []string `json:"assignees"`
// Entity status (e.g. "Small Entity", "Micro Entity")
EntityStatus string `json:"entityStatus" api:"nullable"`
// Date the application was filed
FilingDate time.Time `json:"filingDate" api:"nullable" format:"date"`
// Date the patent was granted
GrantDate time.Time `json:"grantDate" api:"nullable" format:"date"`
// List of inventor names
Inventors []string `json:"inventors"`
// Granted patent number (if granted)
PatentNumber string `json:"patentNumber" api:"nullable"`
// Current application status (e.g. "Patented Case", "Pending")
Status string `json:"status"`
// Invention title
Title string `json:"title"`
JSON legalV1PatentSearchResponseResultJSON `json:"-"`
}
func (*LegalV1PatentSearchResponseResult) UnmarshalJSON ¶
func (r *LegalV1PatentSearchResponseResult) UnmarshalJSON(data []byte) (err error)
type LegalV1ResearchParams ¶
type LegalV1ResearchParams struct {
// Primary search query
Query param.Field[string] `json:"query" api:"required"`
// Additional query variations to search (e.g., different phrasings of the legal
// issue)
AdditionalQueries param.Field[[]string] `json:"additionalQueries"`
// Optional jurisdiction ID from resolveJurisdiction
Jurisdiction param.Field[string] `json:"jurisdiction"`
// Number of results 1-25 (default: 10)
NumResults param.Field[int64] `json:"numResults"`
}
func (LegalV1ResearchParams) MarshalJSON ¶
func (r LegalV1ResearchParams) MarshalJSON() (data []byte, err error)
type LegalV1ResearchResponse ¶
type LegalV1ResearchResponse struct {
// Additional queries used
AdditionalQueries []string `json:"additionalQueries" api:"nullable"`
Candidates []LegalV1ResearchResponseCandidate `json:"candidates"`
// Number of candidates found
Found int64 `json:"found"`
// Usage guidance
Hint string `json:"hint"`
// Jurisdiction filter applied
Jurisdiction string `json:"jurisdiction"`
// Primary search query
Query string `json:"query"`
// Search type used (deep)
SearchType string `json:"searchType"`
JSON legalV1ResearchResponseJSON `json:"-"`
}
func (*LegalV1ResearchResponse) UnmarshalJSON ¶
func (r *LegalV1ResearchResponse) UnmarshalJSON(data []byte) (err error)
type LegalV1ResearchResponseCandidate ¶
type LegalV1ResearchResponseCandidate struct {
// Highlighted relevant passages
Highlights []string `json:"highlights"`
// Publication date
PublishedDate string `json:"publishedDate" api:"nullable"`
// Text excerpt from the document
Snippet string `json:"snippet"`
// Domain of the source
Source string `json:"source"`
// Title of the document
Title string `json:"title"`
// URL of the legal source
URL string `json:"url"`
JSON legalV1ResearchResponseCandidateJSON `json:"-"`
}
func (*LegalV1ResearchResponseCandidate) UnmarshalJSON ¶
func (r *LegalV1ResearchResponseCandidate) UnmarshalJSON(data []byte) (err error)
type LegalV1SecFilingParams ¶ added in v0.19.0
type LegalV1SecFilingParams struct {
// Run a full-text search or fetch a single entity filing history
Type param.Field[LegalV1SecFilingParamsType] `json:"type" api:"required"`
// CIK for entity lookups. Accepts padded or unpadded digits.
Cik param.Field[string] `json:"cik"`
// Optional lower filing date bound (YYYY-MM-DD)
DateAfter param.Field[time.Time] `json:"dateAfter" format:"date"`
// Optional upper filing date bound (YYYY-MM-DD)
DateBefore param.Field[time.Time] `json:"dateBefore" format:"date"`
// Optional entity filter passed through to EDGAR full-text search
Entity param.Field[string] `json:"entity"`
// Optional SEC form type filter such as 10-K, 10-Q, 8-K, or 4
FormTypes param.Field[[]string] `json:"formTypes"`
// Maximum filings to return
Limit param.Field[int64] `json:"limit"`
// Result offset for pagination
Offset param.Field[int64] `json:"offset"`
// Full-text SEC search query (required for type: search)
Query param.Field[string] `json:"query"`
// Optional company ticker. Valid for both search and entity lookups.
Ticker param.Field[string] `json:"ticker"`
}
func (LegalV1SecFilingParams) MarshalJSON ¶ added in v0.19.0
func (r LegalV1SecFilingParams) MarshalJSON() (data []byte, err error)
type LegalV1SecFilingParamsType ¶ added in v0.19.0
type LegalV1SecFilingParamsType string
Run a full-text search or fetch a single entity filing history
const ( LegalV1SecFilingParamsTypeSearch LegalV1SecFilingParamsType = "search" LegalV1SecFilingParamsTypeEntity LegalV1SecFilingParamsType = "entity" )
func (LegalV1SecFilingParamsType) IsKnown ¶ added in v0.19.0
func (r LegalV1SecFilingParamsType) IsKnown() bool
type LegalV1SecFilingResponse ¶ added in v0.19.0
type LegalV1SecFilingResponse struct {
Cik string `json:"cik" api:"nullable"`
DateAfter time.Time `json:"dateAfter" api:"nullable" format:"date"`
DateBefore time.Time `json:"dateBefore" api:"nullable" format:"date"`
Entity string `json:"entity" api:"nullable"`
Filings []LegalV1SecFilingResponseFiling `json:"filings"`
FormTypes []string `json:"formTypes"`
Limit int64 `json:"limit"`
Offset int64 `json:"offset"`
Query string `json:"query" api:"nullable"`
Ticker string `json:"ticker" api:"nullable"`
Total int64 `json:"total"`
Type LegalV1SecFilingResponseType `json:"type"`
JSON legalV1SecFilingResponseJSON `json:"-"`
}
func (*LegalV1SecFilingResponse) UnmarshalJSON ¶ added in v0.19.0
func (r *LegalV1SecFilingResponse) UnmarshalJSON(data []byte) (err error)
type LegalV1SecFilingResponseFiling ¶ added in v0.19.0
type LegalV1SecFilingResponseFiling struct {
AccessionNumber string `json:"accessionNumber"`
Description string `json:"description" api:"nullable"`
Documents []LegalV1SecFilingResponseFilingsDocument `json:"documents"`
Entity LegalV1SecFilingResponseFilingsEntity `json:"entity"`
FiledAt time.Time `json:"filedAt" format:"date"`
FormType string `json:"formType"`
PeriodOfReport time.Time `json:"periodOfReport" api:"nullable" format:"date"`
SecURL string `json:"secUrl"`
Snippet string `json:"snippet" api:"nullable"`
JSON legalV1SecFilingResponseFilingJSON `json:"-"`
}
func (*LegalV1SecFilingResponseFiling) UnmarshalJSON ¶ added in v0.19.0
func (r *LegalV1SecFilingResponseFiling) UnmarshalJSON(data []byte) (err error)
type LegalV1SecFilingResponseFilingsDocument ¶ added in v0.19.0
type LegalV1SecFilingResponseFilingsDocument struct {
Description string `json:"description"`
Type string `json:"type"`
URL string `json:"url"`
JSON legalV1SecFilingResponseFilingsDocumentJSON `json:"-"`
}
func (*LegalV1SecFilingResponseFilingsDocument) UnmarshalJSON ¶ added in v0.19.0
func (r *LegalV1SecFilingResponseFilingsDocument) UnmarshalJSON(data []byte) (err error)
type LegalV1SecFilingResponseFilingsEntity ¶ added in v0.19.0
type LegalV1SecFilingResponseFilingsEntity struct {
Cik string `json:"cik"`
EntityType string `json:"entityType" api:"nullable"`
Name string `json:"name" api:"nullable"`
Sic string `json:"sic" api:"nullable"`
SicDescription string `json:"sicDescription" api:"nullable"`
StateOfIncorporation string `json:"stateOfIncorporation" api:"nullable"`
Ticker string `json:"ticker" api:"nullable"`
JSON legalV1SecFilingResponseFilingsEntityJSON `json:"-"`
}
func (*LegalV1SecFilingResponseFilingsEntity) UnmarshalJSON ¶ added in v0.19.0
func (r *LegalV1SecFilingResponseFilingsEntity) UnmarshalJSON(data []byte) (err error)
type LegalV1SecFilingResponseType ¶ added in v0.19.0
type LegalV1SecFilingResponseType string
const ( LegalV1SecFilingResponseTypeSearch LegalV1SecFilingResponseType = "search" LegalV1SecFilingResponseTypeEntity LegalV1SecFilingResponseType = "entity" )
func (LegalV1SecFilingResponseType) IsKnown ¶ added in v0.19.0
func (r LegalV1SecFilingResponseType) IsKnown() bool
type LegalV1Service ¶
type LegalV1Service struct {
Options []option.RequestOption
}
Legal research tools including citation verification
LegalV1Service contains methods and other services that help with interacting with the casedev API.
Note, unlike clients, this service does not read variables from the environment automatically. You should not instantiate this service directly, and instead use the NewLegalV1Service method instead.
func NewLegalV1Service ¶
func NewLegalV1Service(opts ...option.RequestOption) (r *LegalV1Service)
NewLegalV1Service generates a new service that applies the given options to each request. These options are applied after the parent client's options (if there is one), and before any request-specific options.
func (*LegalV1Service) Docket ¶ added in v0.5.0
func (r *LegalV1Service) Docket(ctx context.Context, body LegalV1DocketParams, opts ...option.RequestOption) (res *LegalV1DocketResponse, err error)
Search federal court dockets or retrieve a specific docket with optional filing entries. Use legal.listCourts() to resolve court slugs for filtering.
func (*LegalV1Service) Draft ¶ added in v0.10.0
func (r *LegalV1Service) Draft(ctx context.Context, body LegalV1DraftParams, opts ...option.RequestOption) (res *LegalV1DraftResponse, err error)
Generate a legal document with structured inputs. Powered by an agent that handles research, formatting, citation verification, and vault upload. Returns a run ID for polling.
func (*LegalV1Service) Find ¶
func (r *LegalV1Service) Find(ctx context.Context, body LegalV1FindParams, opts ...option.RequestOption) (res *LegalV1FindResponse, err error)
Search for legal sources including cases, statutes, and regulations from authoritative legal databases. Returns ranked candidates. Always verify with legal.verify() before citing.
func (*LegalV1Service) GetCitations ¶
func (r *LegalV1Service) GetCitations(ctx context.Context, body LegalV1GetCitationsParams, opts ...option.RequestOption) (res *LegalV1GetCitationsResponse, err error)
Parses legal citations from text and returns structured Bluebook components (case name, reporter, volume, page, year, court). Accepts either a single citation or a full text block.
func (*LegalV1Service) GetCitationsFromURL ¶
func (r *LegalV1Service) GetCitationsFromURL(ctx context.Context, body LegalV1GetCitationsFromURLParams, opts ...option.RequestOption) (res *LegalV1GetCitationsFromURLResponse, err error)
Extract all legal citations and references from a document URL. Returns structured citation data including case citations, statute references, and regulatory citations.
func (*LegalV1Service) GetFullText ¶
func (r *LegalV1Service) GetFullText(ctx context.Context, body LegalV1GetFullTextParams, opts ...option.RequestOption) (res *LegalV1GetFullTextResponse, err error)
Retrieve the full text content of a legal document. Use after verifying the source with legal.verify(). Returns complete text with optional highlights and AI summary.
func (*LegalV1Service) ListCourts ¶ added in v0.5.0
func (r *LegalV1Service) ListCourts(ctx context.Context, body LegalV1ListCourtsParams, opts ...option.RequestOption) (res *LegalV1ListCourtsResponse, err error)
Returns court IDs (slugs) and names for use with the docket search endpoint. Use the returned court ID as the `court` parameter in legal.docket().
func (*LegalV1Service) ListJurisdictions ¶
func (r *LegalV1Service) ListJurisdictions(ctx context.Context, body LegalV1ListJurisdictionsParams, opts ...option.RequestOption) (res *LegalV1ListJurisdictionsResponse, err error)
Search for a jurisdiction by name. Returns matching jurisdictions with their IDs for use in legal.find() and other legal research endpoints.
func (*LegalV1Service) PatentSearch ¶
func (r *LegalV1Service) PatentSearch(ctx context.Context, body LegalV1PatentSearchParams, opts ...option.RequestOption) (res *LegalV1PatentSearchResponse, err error)
Search the USPTO Open Data Portal for US patent applications and granted patents. Supports free-text queries, field-specific search, filters by assignee/inventor/status/type, date ranges, and pagination. Covers applications filed on or after January 1, 2001. Data is refreshed daily.
func (*LegalV1Service) Research ¶
func (r *LegalV1Service) Research(ctx context.Context, body LegalV1ResearchParams, opts ...option.RequestOption) (res *LegalV1ResearchResponse, err error)
Perform comprehensive legal research with multiple query variations. Uses advanced deep search to find relevant sources across different phrasings of the legal issue.
func (*LegalV1Service) SecFiling ¶ added in v0.19.0
func (r *LegalV1Service) SecFiling(ctx context.Context, body LegalV1SecFilingParams, opts ...option.RequestOption) (res *LegalV1SecFilingResponse, err error)
Search SEC EDGAR full-text filings via efts.sec.gov or fetch a filer's structured filing history via data.sec.gov. Returns direct SEC archive URLs with filing metadata and match snippets when available.
func (*LegalV1Service) Similar ¶
func (r *LegalV1Service) Similar(ctx context.Context, body LegalV1SimilarParams, opts ...option.RequestOption) (res *LegalV1SimilarResponse, err error)
Find cases and documents similar to a given legal source. Useful for finding citing cases, related precedents, or similar statutes.
func (*LegalV1Service) TrademarkSearch ¶ added in v0.3.0
func (r *LegalV1Service) TrademarkSearch(ctx context.Context, body LegalV1TrademarkSearchParams, opts ...option.RequestOption) (res *LegalV1TrademarkSearchResponse, err error)
Look up trademark status and details from the USPTO Trademark Status & Document Retrieval (TSDR) system. Supports lookup by serial number or registration number. Returns mark text, status, owner, goods/services, Nice classification, filing/registration dates, and more.
func (*LegalV1Service) Verify ¶
func (r *LegalV1Service) Verify(ctx context.Context, body LegalV1VerifyParams, opts ...option.RequestOption) (res *LegalV1VerifyResponse, err error)
Validates legal citations against authoritative case law sources (CourtListener database of ~10M cases). Returns verification status and case metadata for each citation found in the input text. Accepts either a single citation or a full text block containing multiple citations.
type LegalV1SimilarParams ¶
type LegalV1SimilarParams struct {
// URL of a legal document to find similar sources for
URL param.Field[string] `json:"url" api:"required" format:"uri"`
// Optional jurisdiction ID to filter results
Jurisdiction param.Field[string] `json:"jurisdiction"`
// Number of results 1-25 (default: 10)
NumResults param.Field[int64] `json:"numResults"`
// Optional ISO date to find only newer documents (e.g., "2020-01-01")
StartPublishedDate param.Field[time.Time] `json:"startPublishedDate" format:"date"`
}
func (LegalV1SimilarParams) MarshalJSON ¶
func (r LegalV1SimilarParams) MarshalJSON() (data []byte, err error)
type LegalV1SimilarResponse ¶
type LegalV1SimilarResponse struct {
// Number of similar sources found
Found int64 `json:"found"`
// Usage guidance
Hint string `json:"hint"`
// Jurisdiction filter applied
Jurisdiction string `json:"jurisdiction"`
SimilarSources []LegalV1SimilarResponseSimilarSource `json:"similarSources"`
// Original source URL
SourceURL string `json:"sourceUrl"`
JSON legalV1SimilarResponseJSON `json:"-"`
}
func (*LegalV1SimilarResponse) UnmarshalJSON ¶
func (r *LegalV1SimilarResponse) UnmarshalJSON(data []byte) (err error)
type LegalV1SimilarResponseSimilarSource ¶
type LegalV1SimilarResponseSimilarSource struct {
// Publication date
PublishedDate string `json:"publishedDate" api:"nullable"`
// Text excerpt from the document
Snippet string `json:"snippet"`
// Domain of the source
Source string `json:"source"`
// Title of the document
Title string `json:"title"`
// URL of the similar source
URL string `json:"url"`
JSON legalV1SimilarResponseSimilarSourceJSON `json:"-"`
}
func (*LegalV1SimilarResponseSimilarSource) UnmarshalJSON ¶
func (r *LegalV1SimilarResponseSimilarSource) UnmarshalJSON(data []byte) (err error)
type LegalV1TrademarkSearchParams ¶ added in v0.3.0
type LegalV1TrademarkSearchParams struct {
// USPTO registration number (e.g. "6123456"). Provide either serialNumber or
// registrationNumber.
RegistrationNumber param.Field[string] `json:"registrationNumber"`
// USPTO serial number (e.g. "97123456"). Provide either serialNumber or
// registrationNumber.
SerialNumber param.Field[string] `json:"serialNumber"`
}
func (LegalV1TrademarkSearchParams) MarshalJSON ¶ added in v0.3.0
func (r LegalV1TrademarkSearchParams) MarshalJSON() (data []byte, err error)
type LegalV1TrademarkSearchResponse ¶ added in v0.3.0
type LegalV1TrademarkSearchResponse struct {
// Attorney of record
Attorney string `json:"attorney" api:"nullable"`
// Date the application was filed
FilingDate time.Time `json:"filingDate" api:"nullable" format:"date"`
// Goods and services descriptions with class numbers
GoodsAndServices []LegalV1TrademarkSearchResponseGoodsAndService `json:"goodsAndServices"`
// URL to the mark image on USPTO CDN
ImageURL string `json:"imageUrl" api:"nullable"`
// The text of the trademark
MarkText string `json:"markText" api:"nullable"`
// Type of mark (e.g. "Standard Character Mark", "Design Mark")
MarkType string `json:"markType" api:"nullable"`
// Nice classification class numbers
NiceClasses []int64 `json:"niceClasses"`
// Current owner/applicant information
Owner LegalV1TrademarkSearchResponseOwner `json:"owner" api:"nullable"`
// Date the mark was registered
RegistrationDate time.Time `json:"registrationDate" api:"nullable" format:"date"`
// USPTO registration number (if registered)
RegistrationNumber string `json:"registrationNumber" api:"nullable"`
// USPTO serial number
SerialNumber string `json:"serialNumber"`
// Current status (e.g. "Registered", "Pending", "Abandoned", "Cancelled")
Status string `json:"status" api:"nullable"`
// Date of most recent status update
StatusDate time.Time `json:"statusDate" api:"nullable" format:"date"`
// Canonical TSDR link for this mark
UsptoURL string `json:"usptoUrl"`
JSON legalV1TrademarkSearchResponseJSON `json:"-"`
}
func (*LegalV1TrademarkSearchResponse) UnmarshalJSON ¶ added in v0.3.0
func (r *LegalV1TrademarkSearchResponse) UnmarshalJSON(data []byte) (err error)
type LegalV1TrademarkSearchResponseGoodsAndService ¶ added in v0.3.0
type LegalV1TrademarkSearchResponseGoodsAndService struct {
ClassNumber string `json:"classNumber" api:"nullable"`
Description string `json:"description" api:"nullable"`
JSON legalV1TrademarkSearchResponseGoodsAndServiceJSON `json:"-"`
}
func (*LegalV1TrademarkSearchResponseGoodsAndService) UnmarshalJSON ¶ added in v0.3.0
func (r *LegalV1TrademarkSearchResponseGoodsAndService) UnmarshalJSON(data []byte) (err error)
type LegalV1TrademarkSearchResponseOwner ¶ added in v0.3.0
type LegalV1TrademarkSearchResponseOwner struct {
Address string `json:"address" api:"nullable"`
EntityType string `json:"entityType" api:"nullable"`
Name string `json:"name" api:"nullable"`
JSON legalV1TrademarkSearchResponseOwnerJSON `json:"-"`
}
Current owner/applicant information
func (*LegalV1TrademarkSearchResponseOwner) UnmarshalJSON ¶ added in v0.3.0
func (r *LegalV1TrademarkSearchResponseOwner) UnmarshalJSON(data []byte) (err error)
type LegalV1VerifyParams ¶
type LegalV1VerifyParams struct {
// Text containing citations to verify. Can be a single citation (e.g., "531 U.S.
// 98") or a full document with multiple citations.
Text param.Field[string] `json:"text" api:"required"`
}
func (LegalV1VerifyParams) MarshalJSON ¶
func (r LegalV1VerifyParams) MarshalJSON() (data []byte, err error)
type LegalV1VerifyResponse ¶
type LegalV1VerifyResponse struct {
Citations []LegalV1VerifyResponseCitation `json:"citations"`
Summary LegalV1VerifyResponseSummary `json:"summary"`
JSON legalV1VerifyResponseJSON `json:"-"`
}
func (*LegalV1VerifyResponse) UnmarshalJSON ¶
func (r *LegalV1VerifyResponse) UnmarshalJSON(data []byte) (err error)
type LegalV1VerifyResponseCitation ¶
type LegalV1VerifyResponseCitation struct {
// Multiple candidates (when multiple_matches or heuristic verification)
Candidates []LegalV1VerifyResponseCitationsCandidate `json:"candidates"`
// Case metadata (when verified)
Case LegalV1VerifyResponseCitationsCase `json:"case"`
// Confidence score (1.0 for CourtListener, heuristic score for fallback).
Confidence float64 `json:"confidence"`
// Normalized citation string
Normalized string `json:"normalized"`
// Original citation as found in text
Original string `json:"original"`
Span LegalV1VerifyResponseCitationsSpan `json:"span"`
Status LegalV1VerifyResponseCitationsStatus `json:"status"`
// Source of verification result (heuristic for fallback matches).
VerificationSource LegalV1VerifyResponseCitationsVerificationSource `json:"verificationSource"`
JSON legalV1VerifyResponseCitationJSON `json:"-"`
}
func (*LegalV1VerifyResponseCitation) UnmarshalJSON ¶
func (r *LegalV1VerifyResponseCitation) UnmarshalJSON(data []byte) (err error)
type LegalV1VerifyResponseCitationsCandidate ¶
type LegalV1VerifyResponseCitationsCandidate struct {
Court string `json:"court"`
DateDecided string `json:"dateDecided"`
Name string `json:"name"`
URL string `json:"url"`
JSON legalV1VerifyResponseCitationsCandidateJSON `json:"-"`
}
func (*LegalV1VerifyResponseCitationsCandidate) UnmarshalJSON ¶
func (r *LegalV1VerifyResponseCitationsCandidate) UnmarshalJSON(data []byte) (err error)
type LegalV1VerifyResponseCitationsCase ¶
type LegalV1VerifyResponseCitationsCase struct {
ID int64 `json:"id"`
Court string `json:"court"`
DateDecided string `json:"dateDecided"`
DocketNumber string `json:"docketNumber"`
Name string `json:"name"`
ParallelCitations []string `json:"parallelCitations"`
ShortName string `json:"shortName"`
URL string `json:"url"`
JSON legalV1VerifyResponseCitationsCaseJSON `json:"-"`
}
Case metadata (when verified)
func (*LegalV1VerifyResponseCitationsCase) UnmarshalJSON ¶
func (r *LegalV1VerifyResponseCitationsCase) UnmarshalJSON(data []byte) (err error)
type LegalV1VerifyResponseCitationsSpan ¶
type LegalV1VerifyResponseCitationsSpan struct {
End int64 `json:"end"`
Start int64 `json:"start"`
JSON legalV1VerifyResponseCitationsSpanJSON `json:"-"`
}
func (*LegalV1VerifyResponseCitationsSpan) UnmarshalJSON ¶
func (r *LegalV1VerifyResponseCitationsSpan) UnmarshalJSON(data []byte) (err error)
type LegalV1VerifyResponseCitationsStatus ¶
type LegalV1VerifyResponseCitationsStatus string
const ( LegalV1VerifyResponseCitationsStatusVerified LegalV1VerifyResponseCitationsStatus = "verified" LegalV1VerifyResponseCitationsStatusNotFound LegalV1VerifyResponseCitationsStatus = "not_found" LegalV1VerifyResponseCitationsStatusMultipleMatches LegalV1VerifyResponseCitationsStatus = "multiple_matches" )
func (LegalV1VerifyResponseCitationsStatus) IsKnown ¶
func (r LegalV1VerifyResponseCitationsStatus) IsKnown() bool
type LegalV1VerifyResponseCitationsVerificationSource ¶
type LegalV1VerifyResponseCitationsVerificationSource string
Source of verification result (heuristic for fallback matches).
const ( LegalV1VerifyResponseCitationsVerificationSourceCourtlistener LegalV1VerifyResponseCitationsVerificationSource = "courtlistener" LegalV1VerifyResponseCitationsVerificationSourceHeuristic LegalV1VerifyResponseCitationsVerificationSource = "heuristic" )
func (LegalV1VerifyResponseCitationsVerificationSource) IsKnown ¶
func (r LegalV1VerifyResponseCitationsVerificationSource) IsKnown() bool
type LegalV1VerifyResponseSummary ¶
type LegalV1VerifyResponseSummary struct {
// Citations with multiple possible matches
MultipleMatches int64 `json:"multipleMatches"`
// Citations not found in database
NotFound int64 `json:"notFound"`
// Total citations found
Total int64 `json:"total"`
// Citations verified against real cases
Verified int64 `json:"verified"`
JSON legalV1VerifyResponseSummaryJSON `json:"-"`
}
func (*LegalV1VerifyResponseSummary) UnmarshalJSON ¶
func (r *LegalV1VerifyResponseSummary) UnmarshalJSON(data []byte) (err error)
type LlmGetConfigResponse ¶
type LlmGetConfigResponse struct {
Models []LlmGetConfigResponseModel `json:"models" api:"required"`
JSON llmGetConfigResponseJSON `json:"-"`
}
func (*LlmGetConfigResponse) UnmarshalJSON ¶
func (r *LlmGetConfigResponse) UnmarshalJSON(data []byte) (err error)
type LlmGetConfigResponseModel ¶
type LlmGetConfigResponseModel struct {
// Unique model identifier
ID string `json:"id" api:"required"`
// Type of model (e.g., language, embedding)
ModelType string `json:"modelType" api:"required"`
// Human-readable model name
Name string `json:"name" api:"required"`
// Model description and capabilities
Description string `json:"description"`
// Pricing information for the model
Pricing interface{} `json:"pricing"`
// Technical specifications and limits
Specification interface{} `json:"specification"`
JSON llmGetConfigResponseModelJSON `json:"-"`
}
func (*LlmGetConfigResponseModel) UnmarshalJSON ¶
func (r *LlmGetConfigResponseModel) UnmarshalJSON(data []byte) (err error)
type LlmService ¶
type LlmService struct {
Options []option.RequestOption
// Access 40+ language models through a unified API
V1 *LlmV1Service
}
Access 40+ language models through a unified API
LlmService contains methods and other services that help with interacting with the casedev API.
Note, unlike clients, this service does not read variables from the environment automatically. You should not instantiate this service directly, and instead use the NewLlmService method instead.
func NewLlmService ¶
func NewLlmService(opts ...option.RequestOption) (r *LlmService)
NewLlmService generates a new service that applies the given options to each request. These options are applied after the parent client's options (if there is one), and before any request-specific options.
func (*LlmService) GetConfig ¶
func (r *LlmService) GetConfig(ctx context.Context, opts ...option.RequestOption) (res *LlmGetConfigResponse, err error)
Retrieves the AI Gateway configuration including all available language models and their specifications. This endpoint returns model information compatible with the Vercel AI SDK Gateway format, making it easy to integrate with existing AI applications.
Use this endpoint to:
- Discover available language models - Get model specifications and pricing - Configure AI SDK clients - Build model selection interfaces
type LlmV1ChatNewCompletionParams ¶
type LlmV1ChatNewCompletionParams struct {
// List of messages comprising the conversation
Messages param.Field[[]LlmV1ChatNewCompletionParamsMessage] `json:"messages" api:"required"`
// CaseMark-only: when true, allows reasoning fields in responses. Defaults to
// false (reasoning is suppressed).
CasemarkShowReasoning param.Field[bool] `json:"casemark_show_reasoning"`
// Frequency penalty parameter
FrequencyPenalty param.Field[float64] `json:"frequency_penalty"`
// Maximum number of tokens to generate
MaxTokens param.Field[int64] `json:"max_tokens"`
// Model to use for completion. Defaults to casemark/core-large if not specified
Model param.Field[string] `json:"model"`
// Presence penalty parameter
PresencePenalty param.Field[float64] `json:"presence_penalty"`
// Whether to stream back partial progress
Stream param.Field[bool] `json:"stream"`
// Sampling temperature between 0 and 2
Temperature param.Field[float64] `json:"temperature"`
// Nucleus sampling parameter
TopP param.Field[float64] `json:"top_p"`
}
func (LlmV1ChatNewCompletionParams) MarshalJSON ¶
func (r LlmV1ChatNewCompletionParams) MarshalJSON() (data []byte, err error)
type LlmV1ChatNewCompletionParamsMessage ¶
type LlmV1ChatNewCompletionParamsMessage struct {
// The contents of the message
Content param.Field[string] `json:"content"`
// The role of the message author
Role param.Field[LlmV1ChatNewCompletionParamsMessagesRole] `json:"role"`
}
func (LlmV1ChatNewCompletionParamsMessage) MarshalJSON ¶
func (r LlmV1ChatNewCompletionParamsMessage) MarshalJSON() (data []byte, err error)
type LlmV1ChatNewCompletionParamsMessagesRole ¶
type LlmV1ChatNewCompletionParamsMessagesRole string
The role of the message author
const ( LlmV1ChatNewCompletionParamsMessagesRoleSystem LlmV1ChatNewCompletionParamsMessagesRole = "system" LlmV1ChatNewCompletionParamsMessagesRoleUser LlmV1ChatNewCompletionParamsMessagesRole = "user" LlmV1ChatNewCompletionParamsMessagesRoleAssistant LlmV1ChatNewCompletionParamsMessagesRole = "assistant" )
func (LlmV1ChatNewCompletionParamsMessagesRole) IsKnown ¶
func (r LlmV1ChatNewCompletionParamsMessagesRole) IsKnown() bool
type LlmV1ChatNewCompletionResponse ¶
type LlmV1ChatNewCompletionResponse struct {
// Unique identifier for the completion
ID string `json:"id"`
Choices []LlmV1ChatNewCompletionResponseChoice `json:"choices"`
// Unix timestamp of completion creation
Created int64 `json:"created"`
// Model used for completion
Model string `json:"model"`
Object string `json:"object"`
Usage LlmV1ChatNewCompletionResponseUsage `json:"usage"`
JSON llmV1ChatNewCompletionResponseJSON `json:"-"`
}
func (*LlmV1ChatNewCompletionResponse) UnmarshalJSON ¶
func (r *LlmV1ChatNewCompletionResponse) UnmarshalJSON(data []byte) (err error)
type LlmV1ChatNewCompletionResponseChoice ¶
type LlmV1ChatNewCompletionResponseChoice struct {
FinishReason string `json:"finish_reason"`
Index int64 `json:"index"`
Message LlmV1ChatNewCompletionResponseChoicesMessage `json:"message"`
JSON llmV1ChatNewCompletionResponseChoiceJSON `json:"-"`
}
func (*LlmV1ChatNewCompletionResponseChoice) UnmarshalJSON ¶
func (r *LlmV1ChatNewCompletionResponseChoice) UnmarshalJSON(data []byte) (err error)
type LlmV1ChatNewCompletionResponseChoicesMessage ¶
type LlmV1ChatNewCompletionResponseChoicesMessage struct {
Content string `json:"content"`
Role string `json:"role"`
JSON llmV1ChatNewCompletionResponseChoicesMessageJSON `json:"-"`
}
func (*LlmV1ChatNewCompletionResponseChoicesMessage) UnmarshalJSON ¶
func (r *LlmV1ChatNewCompletionResponseChoicesMessage) UnmarshalJSON(data []byte) (err error)
type LlmV1ChatNewCompletionResponseUsage ¶
type LlmV1ChatNewCompletionResponseUsage struct {
CompletionTokens int64 `json:"completion_tokens"`
// Cost in USD
Cost float64 `json:"cost"`
PromptTokens int64 `json:"prompt_tokens"`
TotalTokens int64 `json:"total_tokens"`
JSON llmV1ChatNewCompletionResponseUsageJSON `json:"-"`
}
func (*LlmV1ChatNewCompletionResponseUsage) UnmarshalJSON ¶
func (r *LlmV1ChatNewCompletionResponseUsage) UnmarshalJSON(data []byte) (err error)
type LlmV1ChatService ¶
type LlmV1ChatService struct {
Options []option.RequestOption
}
Access 40+ language models through a unified API
LlmV1ChatService contains methods and other services that help with interacting with the casedev API.
Note, unlike clients, this service does not read variables from the environment automatically. You should not instantiate this service directly, and instead use the NewLlmV1ChatService method instead.
func NewLlmV1ChatService ¶
func NewLlmV1ChatService(opts ...option.RequestOption) (r *LlmV1ChatService)
NewLlmV1ChatService generates a new service that applies the given options to each request. These options are applied after the parent client's options (if there is one), and before any request-specific options.
func (*LlmV1ChatService) NewCompletion ¶
func (r *LlmV1ChatService) NewCompletion(ctx context.Context, body LlmV1ChatNewCompletionParams, opts ...option.RequestOption) (res *LlmV1ChatNewCompletionResponse, err error)
Create a completion for the provided prompt and parameters. Compatible with OpenAI's chat completions API. Supports 40+ models including GPT-4, Claude, Gemini, and CaseMark legal AI models. Includes streaming support, token counting, and usage tracking.
type LlmV1ListModelsResponse ¶
type LlmV1ListModelsResponse struct {
Data []LlmV1ListModelsResponseData `json:"data"`
// Response object type, always 'list'
Object string `json:"object"`
JSON llmV1ListModelsResponseJSON `json:"-"`
}
func (*LlmV1ListModelsResponse) UnmarshalJSON ¶
func (r *LlmV1ListModelsResponse) UnmarshalJSON(data []byte) (err error)
type LlmV1ListModelsResponseData ¶
type LlmV1ListModelsResponseData struct {
// Unique model identifier
ID string `json:"id"`
// Unix timestamp of model creation
Created int64 `json:"created"`
// Object type, always 'model'
Object string `json:"object"`
// Model provider (openai, anthropic, google, casemark, etc.)
OwnedBy string `json:"owned_by"`
Pricing LlmV1ListModelsResponseDataPricing `json:"pricing"`
JSON llmV1ListModelsResponseDataJSON `json:"-"`
}
func (*LlmV1ListModelsResponseData) UnmarshalJSON ¶
func (r *LlmV1ListModelsResponseData) UnmarshalJSON(data []byte) (err error)
type LlmV1ListModelsResponseDataPricing ¶
type LlmV1ListModelsResponseDataPricing struct {
// Input token price per token
Input string `json:"input"`
// Cache read price per token (if supported)
InputCacheRead string `json:"input_cache_read"`
// Output token price per token
Output string `json:"output"`
JSON llmV1ListModelsResponseDataPricingJSON `json:"-"`
}
func (*LlmV1ListModelsResponseDataPricing) UnmarshalJSON ¶
func (r *LlmV1ListModelsResponseDataPricing) UnmarshalJSON(data []byte) (err error)
type LlmV1NewEmbeddingParams ¶
type LlmV1NewEmbeddingParams struct {
// Text or array of texts to create embeddings for
Input param.Field[LlmV1NewEmbeddingParamsInputUnion] `json:"input" api:"required"`
// Embedding model to use (e.g., text-embedding-ada-002, text-embedding-3-small)
Model param.Field[string] `json:"model" api:"required"`
// Number of dimensions for the embeddings (model-specific)
Dimensions param.Field[int64] `json:"dimensions"`
// Format for returned embeddings
EncodingFormat param.Field[LlmV1NewEmbeddingParamsEncodingFormat] `json:"encoding_format"`
// Unique identifier for the end-user
User param.Field[string] `json:"user"`
}
func (LlmV1NewEmbeddingParams) MarshalJSON ¶
func (r LlmV1NewEmbeddingParams) MarshalJSON() (data []byte, err error)
type LlmV1NewEmbeddingParamsEncodingFormat ¶
type LlmV1NewEmbeddingParamsEncodingFormat string
Format for returned embeddings
const ( LlmV1NewEmbeddingParamsEncodingFormatFloat LlmV1NewEmbeddingParamsEncodingFormat = "float" LlmV1NewEmbeddingParamsEncodingFormatBase64 LlmV1NewEmbeddingParamsEncodingFormat = "base64" )
func (LlmV1NewEmbeddingParamsEncodingFormat) IsKnown ¶
func (r LlmV1NewEmbeddingParamsEncodingFormat) IsKnown() bool
type LlmV1NewEmbeddingParamsInputArray ¶
type LlmV1NewEmbeddingParamsInputArray []string
func (LlmV1NewEmbeddingParamsInputArray) ImplementsLlmV1NewEmbeddingParamsInputUnion ¶
func (r LlmV1NewEmbeddingParamsInputArray) ImplementsLlmV1NewEmbeddingParamsInputUnion()
type LlmV1NewEmbeddingParamsInputUnion ¶
type LlmV1NewEmbeddingParamsInputUnion interface {
ImplementsLlmV1NewEmbeddingParamsInputUnion()
}
Text or array of texts to create embeddings for
Satisfied by [shared.UnionString], LlmV1NewEmbeddingParamsInputArray.
type LlmV1NewEmbeddingResponse ¶
type LlmV1NewEmbeddingResponse struct {
Data []LlmV1NewEmbeddingResponseData `json:"data"`
Model string `json:"model"`
Object string `json:"object"`
Usage LlmV1NewEmbeddingResponseUsage `json:"usage"`
JSON llmV1NewEmbeddingResponseJSON `json:"-"`
}
func (*LlmV1NewEmbeddingResponse) UnmarshalJSON ¶
func (r *LlmV1NewEmbeddingResponse) UnmarshalJSON(data []byte) (err error)
type LlmV1NewEmbeddingResponseData ¶
type LlmV1NewEmbeddingResponseData struct {
Embedding []float64 `json:"embedding"`
Index int64 `json:"index"`
Object string `json:"object"`
JSON llmV1NewEmbeddingResponseDataJSON `json:"-"`
}
func (*LlmV1NewEmbeddingResponseData) UnmarshalJSON ¶
func (r *LlmV1NewEmbeddingResponseData) UnmarshalJSON(data []byte) (err error)
type LlmV1NewEmbeddingResponseUsage ¶
type LlmV1NewEmbeddingResponseUsage struct {
PromptTokens int64 `json:"prompt_tokens"`
TotalTokens int64 `json:"total_tokens"`
JSON llmV1NewEmbeddingResponseUsageJSON `json:"-"`
}
func (*LlmV1NewEmbeddingResponseUsage) UnmarshalJSON ¶
func (r *LlmV1NewEmbeddingResponseUsage) UnmarshalJSON(data []byte) (err error)
type LlmV1Service ¶
type LlmV1Service struct {
Options []option.RequestOption
// Access 40+ language models through a unified API
Chat *LlmV1ChatService
}
Access 40+ language models through a unified API
LlmV1Service contains methods and other services that help with interacting with the casedev API.
Note, unlike clients, this service does not read variables from the environment automatically. You should not instantiate this service directly, and instead use the NewLlmV1Service method instead.
func NewLlmV1Service ¶
func NewLlmV1Service(opts ...option.RequestOption) (r *LlmV1Service)
NewLlmV1Service generates a new service that applies the given options to each request. These options are applied after the parent client's options (if there is one), and before any request-specific options.
func (*LlmV1Service) ListModels ¶
func (r *LlmV1Service) ListModels(ctx context.Context, opts ...option.RequestOption) (res *LlmV1ListModelsResponse, err error)
Retrieve a list of all available language models from 40+ providers including OpenAI, Anthropic, Google, and Case.dev's specialized legal models. Returns OpenAI-compatible model metadata with pricing information.
This endpoint is compatible with OpenAI's models API format, making it easy to integrate with existing applications.
func (*LlmV1Service) NewEmbedding ¶
func (r *LlmV1Service) NewEmbedding(ctx context.Context, body LlmV1NewEmbeddingParams, opts ...option.RequestOption) (res *LlmV1NewEmbeddingResponse, err error)
Create vector embeddings from text using OpenAI-compatible models. Perfect for semantic search, document similarity, and building RAG systems for legal documents.
type MailService ¶ added in v0.18.0
type MailService struct {
Options []option.RequestOption
V1 *MailV1Service
}
MailService contains methods and other services that help with interacting with the casedev API.
Note, unlike clients, this service does not read variables from the environment automatically. You should not instantiate this service directly, and instead use the NewMailService method instead.
func NewMailService ¶ added in v0.18.0
func NewMailService(opts ...option.RequestOption) (r *MailService)
NewMailService generates a new service that applies the given options to each request. These options are applied after the parent client's options (if there is one), and before any request-specific options.
type MailV1InboxNewParams ¶ added in v0.18.0
type MailV1InboxNewParams struct {
Address param.Field[string] `json:"address"`
DisplayName param.Field[string] `json:"displayName"`
}
func (MailV1InboxNewParams) MarshalJSON ¶ added in v0.18.0
func (r MailV1InboxNewParams) MarshalJSON() (data []byte, err error)
type MailV1InboxService ¶ added in v0.18.0
type MailV1InboxService struct {
Options []option.RequestOption
}
Create, manage, and execute AI agents with tool access, sandbox environments, and async run workflows
MailV1InboxService contains methods and other services that help with interacting with the casedev API.
Note, unlike clients, this service does not read variables from the environment automatically. You should not instantiate this service directly, and instead use the NewMailV1InboxService method instead.
func NewMailV1InboxService ¶ added in v0.18.0
func NewMailV1InboxService(opts ...option.RequestOption) (r *MailV1InboxService)
NewMailV1InboxService generates a new service that applies the given options to each request. These options are applied after the parent client's options (if there is one), and before any request-specific options.
func (*MailV1InboxService) Delete ¶ added in v0.18.0
func (r *MailV1InboxService) Delete(ctx context.Context, inboxID string, opts ...option.RequestOption) (err error)
Delete an inbox owned by the authenticated organization.
func (*MailV1InboxService) Get ¶ added in v0.18.0
func (r *MailV1InboxService) Get(ctx context.Context, inboxID string, opts ...option.RequestOption) (err error)
Get an inbox owned by the authenticated organization.
func (*MailV1InboxService) GetAttachment ¶ added in v0.18.0
func (r *MailV1InboxService) GetAttachment(ctx context.Context, inboxID string, messageID string, attachmentID string, opts ...option.RequestOption) (err error)
Get attachment metadata for a message in an inbox owned by the authenticated organization.
func (*MailV1InboxService) GetMessage ¶ added in v0.18.0
func (r *MailV1InboxService) GetMessage(ctx context.Context, inboxID string, messageID string, opts ...option.RequestOption) (err error)
Get a message for an inbox owned by the authenticated organization.
func (*MailV1InboxService) GetPolicy ¶ added in v0.20.0
func (r *MailV1InboxService) GetPolicy(ctx context.Context, inboxID string, opts ...option.RequestOption) (err error)
Get the sender allowlist and send/reply/read access rules for an inbox owned by the authenticated organization.
func (*MailV1InboxService) List ¶ added in v0.18.0
func (r *MailV1InboxService) List(ctx context.Context, opts ...option.RequestOption) (err error)
List inboxes owned by the authenticated organization.
func (*MailV1InboxService) ListMessages ¶ added in v0.18.0
func (r *MailV1InboxService) ListMessages(ctx context.Context, inboxID string, opts ...option.RequestOption) (err error)
List messages for an inbox owned by the authenticated organization.
func (*MailV1InboxService) New ¶ added in v0.18.0
func (r *MailV1InboxService) New(ctx context.Context, body MailV1InboxNewParams, opts ...option.RequestOption) (err error)
Create an inbox owned by the authenticated organization.
func (*MailV1InboxService) Reply ¶ added in v0.18.0
func (r *MailV1InboxService) Reply(ctx context.Context, inboxID string, messageID string, opts ...option.RequestOption) (err error)
Reply to a message in an inbox owned by the authenticated organization.
func (*MailV1InboxService) Send ¶ added in v0.18.0
func (r *MailV1InboxService) Send(ctx context.Context, inboxID string, opts ...option.RequestOption) (err error)
Send a message from an inbox owned by the authenticated organization.
func (*MailV1InboxService) SetPolicy ¶ added in v0.20.0
func (r *MailV1InboxService) SetPolicy(ctx context.Context, inboxID string, body MailV1InboxSetPolicyParams, opts ...option.RequestOption) (err error)
Set the sender allowlist and send/reply/read access rules for an inbox owned by the authenticated organization.
type MailV1InboxSetPolicyParams ¶ added in v0.20.0
type MailV1InboxSetPolicyParams struct {
// Exact emails, @domain rules, or \*
AllowedSenderPatterns param.Field[[]string] `json:"allowedSenderPatterns"`
EnforceSenderAllowlist param.Field[bool] `json:"enforceSenderAllowlist"`
// Rules like organization, operator, user:<id>, api_key, api_key:<id>,
// clerk_session, or \*
ReadAccessRules param.Field[[]string] `json:"readAccessRules"`
// Rules like organization, operator, user:<id>, api_key, api_key:<id>,
// clerk_session, or \*
ReplyAccessRules param.Field[[]string] `json:"replyAccessRules"`
// Rules like organization, user:<id>, api_key, api_key:<id>, clerk_session, or \*
SendAccessRules param.Field[[]string] `json:"sendAccessRules"`
}
func (MailV1InboxSetPolicyParams) MarshalJSON ¶ added in v0.20.0
func (r MailV1InboxSetPolicyParams) MarshalJSON() (data []byte, err error)
type MailV1Service ¶ added in v0.18.0
type MailV1Service struct {
Options []option.RequestOption
// Create, manage, and execute AI agents with tool access, sandbox environments,
// and async run workflows
Inboxes *MailV1InboxService
}
MailV1Service contains methods and other services that help with interacting with the casedev API.
Note, unlike clients, this service does not read variables from the environment automatically. You should not instantiate this service directly, and instead use the NewMailV1Service method instead.
func NewMailV1Service ¶ added in v0.18.0
func NewMailV1Service(opts ...option.RequestOption) (r *MailV1Service)
NewMailV1Service generates a new service that applies the given options to each request. These options are applied after the parent client's options (if there is one), and before any request-specific options.
type MatterService ¶ added in v0.21.0
type MatterService struct {
Options []option.RequestOption
// Matter-native legal workspaces and orchestration primitives
V1 *MatterV1Service
}
MatterService contains methods and other services that help with interacting with the casedev API.
Note, unlike clients, this service does not read variables from the environment automatically. You should not instantiate this service directly, and instead use the NewMatterService method instead.
func NewMatterService ¶ added in v0.21.0
func NewMatterService(opts ...option.RequestOption) (r *MatterService)
NewMatterService generates a new service that applies the given options to each request. These options are applied after the parent client's options (if there is one), and before any request-specific options.
type MatterV1AgentTypeListParams ¶ added in v0.21.0
func (MatterV1AgentTypeListParams) URLQuery ¶ added in v0.21.0
func (r MatterV1AgentTypeListParams) URLQuery() (v url.Values)
URLQuery serializes MatterV1AgentTypeListParams's query parameters as `url.Values`.
type MatterV1AgentTypeNewParams ¶ added in v0.21.0
type MatterV1AgentTypeNewParams struct {
Instructions param.Field[string] `json:"instructions" api:"required"`
Name param.Field[string] `json:"name" api:"required"`
Description param.Field[string] `json:"description"`
DisabledTools param.Field[[]string] `json:"disabled_tools"`
EnabledTools param.Field[[]string] `json:"enabled_tools"`
IsActive param.Field[bool] `json:"is_active"`
IsDefault param.Field[bool] `json:"is_default"`
Metadata param.Field[map[string]interface{}] `json:"metadata"`
Model param.Field[string] `json:"model"`
SkillRefs param.Field[[]string] `json:"skill_refs"`
Slug param.Field[string] `json:"slug"`
}
func (MatterV1AgentTypeNewParams) MarshalJSON ¶ added in v0.21.0
func (r MatterV1AgentTypeNewParams) MarshalJSON() (data []byte, err error)
type MatterV1AgentTypeService ¶ added in v0.21.0
type MatterV1AgentTypeService struct {
Options []option.RequestOption
}
Matter-native legal workspaces and orchestration primitives
MatterV1AgentTypeService contains methods and other services that help with interacting with the casedev API.
Note, unlike clients, this service does not read variables from the environment automatically. You should not instantiate this service directly, and instead use the NewMatterV1AgentTypeService method instead.
func NewMatterV1AgentTypeService ¶ added in v0.21.0
func NewMatterV1AgentTypeService(opts ...option.RequestOption) (r *MatterV1AgentTypeService)
NewMatterV1AgentTypeService generates a new service that applies the given options to each request. These options are applied after the parent client's options (if there is one), and before any request-specific options.
func (*MatterV1AgentTypeService) List ¶ added in v0.21.0
func (r *MatterV1AgentTypeService) List(ctx context.Context, query MatterV1AgentTypeListParams, opts ...option.RequestOption) (err error)
List reusable agent roles for the authenticated organization.
func (*MatterV1AgentTypeService) New ¶ added in v0.21.0
func (r *MatterV1AgentTypeService) New(ctx context.Context, body MatterV1AgentTypeNewParams, opts ...option.RequestOption) (err error)
Create a reusable agent role for legal matter orchestration.
type MatterV1EventService ¶ added in v0.21.0
type MatterV1EventService struct {
Options []option.RequestOption
// Matter-native legal workspaces and orchestration primitives
Subscriptions *MatterV1EventSubscriptionService
}
MatterV1EventService contains methods and other services that help with interacting with the casedev API.
Note, unlike clients, this service does not read variables from the environment automatically. You should not instantiate this service directly, and instead use the NewMatterV1EventService method instead.
func NewMatterV1EventService ¶ added in v0.21.0
func NewMatterV1EventService(opts ...option.RequestOption) (r *MatterV1EventService)
NewMatterV1EventService generates a new service that applies the given options to each request. These options are applied after the parent client's options (if there is one), and before any request-specific options.
type MatterV1EventSubscriptionNewParams ¶ added in v0.21.0
type MatterV1EventSubscriptionNewParams struct {
CallbackURL param.Field[string] `json:"callbackUrl" api:"required" format:"uri"`
EventTypes param.Field[[]string] `json:"eventTypes"`
SigningSecret param.Field[string] `json:"signingSecret"`
}
func (MatterV1EventSubscriptionNewParams) MarshalJSON ¶ added in v0.21.0
func (r MatterV1EventSubscriptionNewParams) MarshalJSON() (data []byte, err error)
type MatterV1EventSubscriptionService ¶ added in v0.21.0
type MatterV1EventSubscriptionService struct {
Options []option.RequestOption
}
Matter-native legal workspaces and orchestration primitives
MatterV1EventSubscriptionService contains methods and other services that help with interacting with the casedev API.
Note, unlike clients, this service does not read variables from the environment automatically. You should not instantiate this service directly, and instead use the NewMatterV1EventSubscriptionService method instead.
func NewMatterV1EventSubscriptionService ¶ added in v0.21.0
func NewMatterV1EventSubscriptionService(opts ...option.RequestOption) (r *MatterV1EventSubscriptionService)
NewMatterV1EventSubscriptionService generates a new service that applies the given options to each request. These options are applied after the parent client's options (if there is one), and before any request-specific options.
func (*MatterV1EventSubscriptionService) Delete ¶ added in v0.21.0
func (r *MatterV1EventSubscriptionService) Delete(ctx context.Context, id string, subscriptionID string, opts ...option.RequestOption) (err error)
Deactivates a matter webhook subscription.
func (*MatterV1EventSubscriptionService) List ¶ added in v0.21.0
func (r *MatterV1EventSubscriptionService) List(ctx context.Context, id string, opts ...option.RequestOption) (err error)
Lists webhook subscriptions configured for a matter.
func (*MatterV1EventSubscriptionService) New ¶ added in v0.21.0
func (r *MatterV1EventSubscriptionService) New(ctx context.Context, id string, body MatterV1EventSubscriptionNewParams, opts ...option.RequestOption) (err error)
Creates a webhook subscription for matter and work-item events.
type MatterV1ListParams ¶ added in v0.21.0
type MatterV1ListParams struct {
MatterType param.Field[string] `query:"matter_type"`
PracticeArea param.Field[string] `query:"practice_area"`
Query param.Field[string] `query:"query"`
Status param.Field[string] `query:"status"`
}
func (MatterV1ListParams) URLQuery ¶ added in v0.21.0
func (r MatterV1ListParams) URLQuery() (v url.Values)
URLQuery serializes MatterV1ListParams's query parameters as `url.Values`.
type MatterV1LogExportParams ¶ added in v0.21.0
type MatterV1LogExportParams struct {
// Filter by actor ID
ActorID param.Field[string] `json:"actor_id"`
// Filter by actor type
ActorType param.Field[string] `json:"actor_type"`
// End of time range (ISO 8601)
EndTime param.Field[time.Time] `json:"end_time" format:"date-time"`
// Filter by exact event type
EventType param.Field[string] `json:"event_type"`
// Export format. Defaults to jsonl.
Format param.Field[MatterV1LogExportParamsFormat] `json:"format"`
// Filter by scope: matter, work_item, execution, sharing, all
Scope param.Field[MatterV1LogExportParamsScopeUnion] `json:"scope"`
// Start of time range (ISO 8601)
StartTime param.Field[time.Time] `json:"start_time" format:"date-time"`
// Filter by work item ID
WorkItemID param.Field[string] `json:"work_item_id"`
}
func (MatterV1LogExportParams) MarshalJSON ¶ added in v0.21.0
func (r MatterV1LogExportParams) MarshalJSON() (data []byte, err error)
type MatterV1LogExportParamsFormat ¶ added in v0.21.0
type MatterV1LogExportParamsFormat string
Export format. Defaults to jsonl.
const ( MatterV1LogExportParamsFormatJson MatterV1LogExportParamsFormat = "json" MatterV1LogExportParamsFormatJSONL MatterV1LogExportParamsFormat = "jsonl" MatterV1LogExportParamsFormatCsv MatterV1LogExportParamsFormat = "csv" MatterV1LogExportParamsFormatTsv MatterV1LogExportParamsFormat = "tsv" )
func (MatterV1LogExportParamsFormat) IsKnown ¶ added in v0.21.0
func (r MatterV1LogExportParamsFormat) IsKnown() bool
type MatterV1LogExportParamsScopeArray ¶ added in v0.21.0
type MatterV1LogExportParamsScopeArray []string
func (MatterV1LogExportParamsScopeArray) ImplementsMatterV1LogExportParamsScopeUnion ¶ added in v0.21.0
func (r MatterV1LogExportParamsScopeArray) ImplementsMatterV1LogExportParamsScopeUnion()
type MatterV1LogExportParamsScopeUnion ¶ added in v0.21.0
type MatterV1LogExportParamsScopeUnion interface {
ImplementsMatterV1LogExportParamsScopeUnion()
}
Filter by scope: matter, work_item, execution, sharing, all
Satisfied by [shared.UnionString], MatterV1LogExportParamsScopeArray.
type MatterV1LogExportResponse ¶ added in v0.21.0
type MatterV1LogExportResponse struct {
Data []map[string]interface{} `json:"data"`
JSON matterV1LogExportResponseJSON `json:"-"`
}
func (*MatterV1LogExportResponse) UnmarshalJSON ¶ added in v0.21.0
func (r *MatterV1LogExportResponse) UnmarshalJSON(data []byte) (err error)
type MatterV1LogListParams ¶ added in v0.21.0
type MatterV1LogListParams struct {
// Filter by actor ID
ActorID param.Field[string] `query:"actor_id"`
// Filter by actor type
ActorType param.Field[string] `query:"actor_type"`
// End of time range (ISO 8601)
EndTime param.Field[time.Time] `query:"end_time" format:"date-time"`
// Filter by exact event type
EventType param.Field[string] `query:"event_type"`
// Maximum number of log entries to return (max 200)
Limit param.Field[int64] `query:"limit"`
// Number of log entries to skip for pagination
Offset param.Field[int64] `query:"offset"`
// Filter by scope: matter, work_item, execution, sharing, all
Scope param.Field[MatterV1LogListParamsScopeUnion] `query:"scope"`
// Start of time range (ISO 8601)
StartTime param.Field[time.Time] `query:"start_time" format:"date-time"`
// Filter by work item ID
WorkItemID param.Field[string] `query:"work_item_id"`
}
func (MatterV1LogListParams) URLQuery ¶ added in v0.21.0
func (r MatterV1LogListParams) URLQuery() (v url.Values)
URLQuery serializes MatterV1LogListParams's query parameters as `url.Values`.
type MatterV1LogListParamsScopeArray ¶ added in v0.21.0
type MatterV1LogListParamsScopeArray []string
func (MatterV1LogListParamsScopeArray) ImplementsMatterV1LogListParamsScopeUnion ¶ added in v0.21.0
func (r MatterV1LogListParamsScopeArray) ImplementsMatterV1LogListParamsScopeUnion()
type MatterV1LogListParamsScopeUnion ¶ added in v0.21.0
type MatterV1LogListParamsScopeUnion interface {
ImplementsMatterV1LogListParamsScopeUnion()
}
Filter by scope: matter, work_item, execution, sharing, all
Satisfied by [shared.UnionString], MatterV1LogListParamsScopeArray.
type MatterV1LogNewParams ¶ added in v0.21.0
type MatterV1LogNewParams struct {
Summary param.Field[string] `json:"summary" api:"required"`
Details param.Field[map[string]interface{}] `json:"details"`
EventType param.Field[string] `json:"event_type"`
WorkItemID param.Field[string] `json:"work_item_id"`
}
func (MatterV1LogNewParams) MarshalJSON ¶ added in v0.21.0
func (r MatterV1LogNewParams) MarshalJSON() (data []byte, err error)
type MatterV1LogService ¶ added in v0.21.0
type MatterV1LogService struct {
Options []option.RequestOption
}
Matter-native legal workspaces and orchestration primitives
MatterV1LogService contains methods and other services that help with interacting with the casedev API.
Note, unlike clients, this service does not read variables from the environment automatically. You should not instantiate this service directly, and instead use the NewMatterV1LogService method instead.
func NewMatterV1LogService ¶ added in v0.21.0
func NewMatterV1LogService(opts ...option.RequestOption) (r *MatterV1LogService)
NewMatterV1LogService generates a new service that applies the given options to each request. These options are applied after the parent client's options (if there is one), and before any request-specific options.
func (*MatterV1LogService) Export ¶ added in v0.21.0
func (r *MatterV1LogService) Export(ctx context.Context, id string, body MatterV1LogExportParams, opts ...option.RequestOption) (res *MatterV1LogExportResponse, err error)
Bulk export matter log entries for audits, visibility, and eval pipelines. Supports json, csv, tsv, and jsonl. Limited to 10,000 entries per request.
func (*MatterV1LogService) List ¶ added in v0.21.0
func (r *MatterV1LogService) List(ctx context.Context, id string, query MatterV1LogListParams, opts ...option.RequestOption) (err error)
List the operational history for a matter.
func (*MatterV1LogService) New ¶ added in v0.21.0
func (r *MatterV1LogService) New(ctx context.Context, id string, body MatterV1LogNewParams, opts ...option.RequestOption) (err error)
Append a manual operational note or event to a matter log.
type MatterV1MatterPartyNewParams ¶ added in v0.21.0
type MatterV1MatterPartyNewParams struct {
PartyID param.Field[string] `json:"party_id" api:"required"`
Role param.Field[MatterV1MatterPartyNewParamsRole] `json:"role" api:"required"`
CustomFields param.Field[map[string]interface{}] `json:"custom_fields"`
IsPrimary param.Field[bool] `json:"is_primary"`
Metadata param.Field[map[string]interface{}] `json:"metadata"`
Notes param.Field[string] `json:"notes"`
SetAsClient param.Field[bool] `json:"set_as_client"`
}
func (MatterV1MatterPartyNewParams) MarshalJSON ¶ added in v0.21.0
func (r MatterV1MatterPartyNewParams) MarshalJSON() (data []byte, err error)
type MatterV1MatterPartyNewParamsRole ¶ added in v0.21.0
type MatterV1MatterPartyNewParamsRole string
const ( MatterV1MatterPartyNewParamsRoleClient MatterV1MatterPartyNewParamsRole = "client" MatterV1MatterPartyNewParamsRoleProspect MatterV1MatterPartyNewParamsRole = "prospect" MatterV1MatterPartyNewParamsRoleOpposingParty MatterV1MatterPartyNewParamsRole = "opposing_party" MatterV1MatterPartyNewParamsRoleOpposingCounsel MatterV1MatterPartyNewParamsRole = "opposing_counsel" MatterV1MatterPartyNewParamsRoleCoCounsel MatterV1MatterPartyNewParamsRole = "co_counsel" MatterV1MatterPartyNewParamsRoleJudge MatterV1MatterPartyNewParamsRole = "judge" MatterV1MatterPartyNewParamsRoleExpert MatterV1MatterPartyNewParamsRole = "expert" MatterV1MatterPartyNewParamsRoleWitness MatterV1MatterPartyNewParamsRole = "witness" MatterV1MatterPartyNewParamsRoleVendor MatterV1MatterPartyNewParamsRole = "vendor" MatterV1MatterPartyNewParamsRoleInsurer MatterV1MatterPartyNewParamsRole = "insurer" MatterV1MatterPartyNewParamsRoleOther MatterV1MatterPartyNewParamsRole = "other" )
func (MatterV1MatterPartyNewParamsRole) IsKnown ¶ added in v0.21.0
func (r MatterV1MatterPartyNewParamsRole) IsKnown() bool
type MatterV1MatterPartyService ¶ added in v0.21.0
type MatterV1MatterPartyService struct {
Options []option.RequestOption
}
Matter-native legal workspaces and orchestration primitives
MatterV1MatterPartyService contains methods and other services that help with interacting with the casedev API.
Note, unlike clients, this service does not read variables from the environment automatically. You should not instantiate this service directly, and instead use the NewMatterV1MatterPartyService method instead.
func NewMatterV1MatterPartyService ¶ added in v0.21.0
func NewMatterV1MatterPartyService(opts ...option.RequestOption) (r *MatterV1MatterPartyService)
NewMatterV1MatterPartyService generates a new service that applies the given options to each request. These options are applied after the parent client's options (if there is one), and before any request-specific options.
func (*MatterV1MatterPartyService) List ¶ added in v0.21.0
func (r *MatterV1MatterPartyService) List(ctx context.Context, id string, opts ...option.RequestOption) (err error)
List parties attached to a matter.
func (*MatterV1MatterPartyService) New ¶ added in v0.21.0
func (r *MatterV1MatterPartyService) New(ctx context.Context, id string, body MatterV1MatterPartyNewParams, opts ...option.RequestOption) (err error)
Attach a reusable party to a matter with a matter-specific role.
type MatterV1NewParams ¶ added in v0.21.0
type MatterV1NewParams struct {
Title param.Field[string] `json:"title" api:"required"`
Billing param.Field[map[string]interface{}] `json:"billing"`
ClientName param.Field[string] `json:"client_name"`
ClientPartyID param.Field[string] `json:"client_party_id"`
CustomFields param.Field[map[string]interface{}] `json:"custom_fields"`
Description param.Field[string] `json:"description"`
DisplayID param.Field[string] `json:"display_id"`
ImportantDates param.Field[map[string]interface{}] `json:"important_dates"`
Jurisdiction param.Field[map[string]interface{}] `json:"jurisdiction"`
MatterType param.Field[string] `json:"matter_type"`
Metadata param.Field[map[string]interface{}] `json:"metadata"`
PracticeArea param.Field[string] `json:"practice_area"`
ResponsibleAttorneyID param.Field[string] `json:"responsible_attorney_id"`
Status param.Field[MatterV1NewParamsStatus] `json:"status"`
Subtype param.Field[string] `json:"subtype"`
Vault param.Field[MatterV1NewParamsVault] `json:"vault"`
VaultID param.Field[string] `json:"vault_id"`
}
func (MatterV1NewParams) MarshalJSON ¶ added in v0.21.0
func (r MatterV1NewParams) MarshalJSON() (data []byte, err error)
type MatterV1NewParamsStatus ¶ added in v0.21.0
type MatterV1NewParamsStatus string
const ( MatterV1NewParamsStatusIntake MatterV1NewParamsStatus = "intake" MatterV1NewParamsStatusOpen MatterV1NewParamsStatus = "open" MatterV1NewParamsStatusPending MatterV1NewParamsStatus = "pending" MatterV1NewParamsStatusClosed MatterV1NewParamsStatus = "closed" MatterV1NewParamsStatusArchived MatterV1NewParamsStatus = "archived" )
func (MatterV1NewParamsStatus) IsKnown ¶ added in v0.21.0
func (r MatterV1NewParamsStatus) IsKnown() bool
type MatterV1NewParamsVault ¶ added in v0.21.0
type MatterV1NewParamsVault struct {
Description param.Field[string] `json:"description"`
EnableGraph param.Field[bool] `json:"enableGraph"`
EnableIndexing param.Field[bool] `json:"enableIndexing"`
Metadata param.Field[map[string]interface{}] `json:"metadata"`
}
func (MatterV1NewParamsVault) MarshalJSON ¶ added in v0.21.0
func (r MatterV1NewParamsVault) MarshalJSON() (data []byte, err error)
type MatterV1PartyListParams ¶ added in v0.21.0
type MatterV1PartyListParams struct {
Email param.Field[string] `query:"email"`
Query param.Field[string] `query:"query"`
Type param.Field[MatterV1PartyListParamsType] `query:"type"`
}
func (MatterV1PartyListParams) URLQuery ¶ added in v0.21.0
func (r MatterV1PartyListParams) URLQuery() (v url.Values)
URLQuery serializes MatterV1PartyListParams's query parameters as `url.Values`.
type MatterV1PartyListParamsType ¶ added in v0.21.0
type MatterV1PartyListParamsType string
const ( MatterV1PartyListParamsTypePerson MatterV1PartyListParamsType = "person" MatterV1PartyListParamsTypeOrganization MatterV1PartyListParamsType = "organization" )
func (MatterV1PartyListParamsType) IsKnown ¶ added in v0.21.0
func (r MatterV1PartyListParamsType) IsKnown() bool
type MatterV1PartyNewParams ¶ added in v0.21.0
type MatterV1PartyNewParams struct {
Name param.Field[string] `json:"name" api:"required"`
Addresses param.Field[[]map[string]interface{}] `json:"addresses"`
CustomFields param.Field[map[string]interface{}] `json:"custom_fields"`
Email param.Field[string] `json:"email"`
Metadata param.Field[map[string]interface{}] `json:"metadata"`
Notes param.Field[string] `json:"notes"`
Phone param.Field[string] `json:"phone"`
Type param.Field[MatterV1PartyNewParamsType] `json:"type"`
}
func (MatterV1PartyNewParams) MarshalJSON ¶ added in v0.21.0
func (r MatterV1PartyNewParams) MarshalJSON() (data []byte, err error)
type MatterV1PartyNewParamsType ¶ added in v0.21.0
type MatterV1PartyNewParamsType string
const ( MatterV1PartyNewParamsTypePerson MatterV1PartyNewParamsType = "person" MatterV1PartyNewParamsTypeOrganization MatterV1PartyNewParamsType = "organization" )
func (MatterV1PartyNewParamsType) IsKnown ¶ added in v0.21.0
func (r MatterV1PartyNewParamsType) IsKnown() bool
type MatterV1PartyService ¶ added in v0.21.0
type MatterV1PartyService struct {
Options []option.RequestOption
}
Matter-native legal workspaces and orchestration primitives
MatterV1PartyService contains methods and other services that help with interacting with the casedev API.
Note, unlike clients, this service does not read variables from the environment automatically. You should not instantiate this service directly, and instead use the NewMatterV1PartyService method instead.
func NewMatterV1PartyService ¶ added in v0.21.0
func NewMatterV1PartyService(opts ...option.RequestOption) (r *MatterV1PartyService)
NewMatterV1PartyService generates a new service that applies the given options to each request. These options are applied after the parent client's options (if there is one), and before any request-specific options.
func (*MatterV1PartyService) Get ¶ added in v0.21.0
func (r *MatterV1PartyService) Get(ctx context.Context, partyID string, opts ...option.RequestOption) (err error)
Get a reusable legal party by ID.
func (*MatterV1PartyService) List ¶ added in v0.21.0
func (r *MatterV1PartyService) List(ctx context.Context, query MatterV1PartyListParams, opts ...option.RequestOption) (err error)
List reusable legal parties for the authenticated organization.
func (*MatterV1PartyService) New ¶ added in v0.21.0
func (r *MatterV1PartyService) New(ctx context.Context, body MatterV1PartyNewParams, opts ...option.RequestOption) (err error)
Create a reusable legal party for the authenticated organization.
func (*MatterV1PartyService) Update ¶ added in v0.21.0
func (r *MatterV1PartyService) Update(ctx context.Context, partyID string, opts ...option.RequestOption) (err error)
Update a reusable legal party.
type MatterV1Service ¶ added in v0.21.0
type MatterV1Service struct {
Options []option.RequestOption
// Matter-native legal workspaces and orchestration primitives
AgentTypes *MatterV1AgentTypeService
// Matter-native legal workspaces and orchestration primitives
Parties *MatterV1PartyService
// Matter-native legal workspaces and orchestration primitives
Types *MatterV1TypeService
Events *MatterV1EventService
// Matter-native legal workspaces and orchestration primitives
Log *MatterV1LogService
// Matter-native legal workspaces and orchestration primitives
MatterParties *MatterV1MatterPartyService
Shares *MatterV1ShareService
// Matter-native legal workspaces and orchestration primitives
WorkItems *MatterV1WorkItemService
}
Matter-native legal workspaces and orchestration primitives
MatterV1Service contains methods and other services that help with interacting with the casedev API.
Note, unlike clients, this service does not read variables from the environment automatically. You should not instantiate this service directly, and instead use the NewMatterV1Service method instead.
func NewMatterV1Service ¶ added in v0.21.0
func NewMatterV1Service(opts ...option.RequestOption) (r *MatterV1Service)
NewMatterV1Service generates a new service that applies the given options to each request. These options are applied after the parent client's options (if there is one), and before any request-specific options.
func (*MatterV1Service) Get ¶ added in v0.21.0
func (r *MatterV1Service) Get(ctx context.Context, id string, opts ...option.RequestOption) (err error)
Get a single matter by ID.
func (*MatterV1Service) List ¶ added in v0.21.0
func (r *MatterV1Service) List(ctx context.Context, query MatterV1ListParams, opts ...option.RequestOption) (err error)
List matters for the authenticated organization.
func (*MatterV1Service) New ¶ added in v0.21.0
func (r *MatterV1Service) New(ctx context.Context, body MatterV1NewParams, opts ...option.RequestOption) (err error)
Create a new legal matter and optionally link an existing primary vault.
func (*MatterV1Service) Update ¶ added in v0.21.0
func (r *MatterV1Service) Update(ctx context.Context, id string, body MatterV1UpdateParams, opts ...option.RequestOption) (err error)
Update mutable matter fields.
type MatterV1ShareNewParams ¶ added in v0.21.0
type MatterV1ShareNewParams struct {
}
func (MatterV1ShareNewParams) MarshalJSON ¶ added in v0.21.0
func (r MatterV1ShareNewParams) MarshalJSON() (data []byte, err error)
type MatterV1ShareNewParamsPermission ¶ added in v0.21.0
type MatterV1ShareNewParamsPermission string
const ( )
func (MatterV1ShareNewParamsPermission) IsKnown ¶ added in v0.21.0
func (r MatterV1ShareNewParamsPermission) IsKnown() bool
type MatterV1ShareService ¶ added in v0.21.0
type MatterV1ShareService struct {
}
Matter-native legal workspaces and orchestration primitives
MatterV1ShareService contains methods and other services that help with interacting with the casedev API.
Note, unlike clients, this service does not read variables from the environment automatically. You should not instantiate this service directly, and instead use the NewMatterV1ShareService method instead.
func NewMatterV1ShareService ¶ added in v0.21.0
func NewMatterV1ShareService(opts ...option.RequestOption) (r *MatterV1ShareService)
NewMatterV1ShareService generates a new service that applies the given options to each request. These options are applied after the parent client's options (if there is one), and before any request-specific options.
func (*MatterV1ShareService) Delete ¶ added in v0.21.0
func (r *MatterV1ShareService) Delete(ctx context.Context, id string, shareID string, opts ...option.RequestOption) (err error)
Revoke a matter share and its linked vault share.
func (*MatterV1ShareService) List ¶ added in v0.21.0
func (r *MatterV1ShareService) List(ctx context.Context, id string, opts ...option.RequestOption) (err error)
List cross-org shares for a matter. Owner only.
func (*MatterV1ShareService) New ¶ added in v0.21.0
func (r *MatterV1ShareService) New(ctx context.Context, id string, body MatterV1ShareNewParams, opts ...option.RequestOption) (err error)
Grant another organization scoped access to this matter and its primary vault.
type MatterV1TypeListParams ¶ added in v0.21.0
func (MatterV1TypeListParams) URLQuery ¶ added in v0.21.0
func (r MatterV1TypeListParams) URLQuery() (v url.Values)
URLQuery serializes MatterV1TypeListParams's query parameters as `url.Values`.
type MatterV1TypeNewParams ¶ added in v0.21.0
type MatterV1TypeNewParams struct {
Name param.Field[string] `json:"name" api:"required"`
DefaultAgentTypeID param.Field[string] `json:"default_agent_type_id"`
DefaultMetadata param.Field[map[string]interface{}] `json:"default_metadata"`
DefaultWorkItems param.Field[[]map[string]interface{}] `json:"default_work_items"`
Description param.Field[string] `json:"description"`
ExitCriteria param.Field[[]string] `json:"exit_criteria"`
Instructions param.Field[string] `json:"instructions"`
IntakeRequirements param.Field[[]string] `json:"intake_requirements"`
IsActive param.Field[bool] `json:"is_active"`
OrchestrationMode param.Field[MatterV1TypeNewParamsOrchestrationMode] `json:"orchestration_mode"`
ReviewAgentTypeID param.Field[string] `json:"review_agent_type_id"`
ReviewCriteria param.Field[[]string] `json:"review_criteria"`
SkillRefs param.Field[[]string] `json:"skill_refs"`
Slug param.Field[string] `json:"slug"`
}
func (MatterV1TypeNewParams) MarshalJSON ¶ added in v0.21.0
func (r MatterV1TypeNewParams) MarshalJSON() (data []byte, err error)
type MatterV1TypeNewParamsOrchestrationMode ¶ added in v0.21.0
type MatterV1TypeNewParamsOrchestrationMode string
const ( MatterV1TypeNewParamsOrchestrationModeAuto MatterV1TypeNewParamsOrchestrationMode = "auto" MatterV1TypeNewParamsOrchestrationModeHuman MatterV1TypeNewParamsOrchestrationMode = "human" )
func (MatterV1TypeNewParamsOrchestrationMode) IsKnown ¶ added in v0.21.0
func (r MatterV1TypeNewParamsOrchestrationMode) IsKnown() bool
type MatterV1TypeService ¶ added in v0.21.0
type MatterV1TypeService struct {
Options []option.RequestOption
}
Matter-native legal workspaces and orchestration primitives
MatterV1TypeService contains methods and other services that help with interacting with the casedev API.
Note, unlike clients, this service does not read variables from the environment automatically. You should not instantiate this service directly, and instead use the NewMatterV1TypeService method instead.
func NewMatterV1TypeService ¶ added in v0.21.0
func NewMatterV1TypeService(opts ...option.RequestOption) (r *MatterV1TypeService)
NewMatterV1TypeService generates a new service that applies the given options to each request. These options are applied after the parent client's options (if there is one), and before any request-specific options.
func (*MatterV1TypeService) Get ¶ added in v0.21.0
func (r *MatterV1TypeService) Get(ctx context.Context, id string, opts ...option.RequestOption) (err error)
Get a single matter type.
func (*MatterV1TypeService) List ¶ added in v0.21.0
func (r *MatterV1TypeService) List(ctx context.Context, query MatterV1TypeListParams, opts ...option.RequestOption) (err error)
List matter types for the authenticated organization.
func (*MatterV1TypeService) New ¶ added in v0.21.0
func (r *MatterV1TypeService) New(ctx context.Context, body MatterV1TypeNewParams, opts ...option.RequestOption) (err error)
Create a matter type with plain-English operating instructions and seeded work.
func (*MatterV1TypeService) Update ¶ added in v0.21.0
func (r *MatterV1TypeService) Update(ctx context.Context, id string, body MatterV1TypeUpdateParams, opts ...option.RequestOption) (err error)
Update a matter type.
type MatterV1TypeUpdateParams ¶ added in v0.21.0
type MatterV1TypeUpdateParams struct {
DefaultAgentTypeID param.Field[string] `json:"default_agent_type_id"`
DefaultMetadata param.Field[map[string]interface{}] `json:"default_metadata"`
DefaultWorkItems param.Field[[]map[string]interface{}] `json:"default_work_items"`
Description param.Field[string] `json:"description"`
ExitCriteria param.Field[[]string] `json:"exit_criteria"`
Instructions param.Field[string] `json:"instructions"`
IntakeRequirements param.Field[[]string] `json:"intake_requirements"`
IsActive param.Field[bool] `json:"is_active"`
Name param.Field[string] `json:"name"`
OrchestrationMode param.Field[MatterV1TypeUpdateParamsOrchestrationMode] `json:"orchestration_mode"`
ReviewAgentTypeID param.Field[string] `json:"review_agent_type_id"`
ReviewCriteria param.Field[[]string] `json:"review_criteria"`
SkillRefs param.Field[[]string] `json:"skill_refs"`
Slug param.Field[string] `json:"slug"`
}
func (MatterV1TypeUpdateParams) MarshalJSON ¶ added in v0.21.0
func (r MatterV1TypeUpdateParams) MarshalJSON() (data []byte, err error)
type MatterV1TypeUpdateParamsOrchestrationMode ¶ added in v0.21.0
type MatterV1TypeUpdateParamsOrchestrationMode string
const ( MatterV1TypeUpdateParamsOrchestrationModeAuto MatterV1TypeUpdateParamsOrchestrationMode = "auto" MatterV1TypeUpdateParamsOrchestrationModeHuman MatterV1TypeUpdateParamsOrchestrationMode = "human" )
func (MatterV1TypeUpdateParamsOrchestrationMode) IsKnown ¶ added in v0.21.0
func (r MatterV1TypeUpdateParamsOrchestrationMode) IsKnown() bool
type MatterV1UpdateParams ¶ added in v0.21.0
type MatterV1UpdateParams struct {
ArchivedAt param.Field[time.Time] `json:"archived_at" format:"date-time"`
Billing param.Field[map[string]interface{}] `json:"billing"`
ClientName param.Field[string] `json:"client_name"`
ClientPartyID param.Field[string] `json:"client_party_id"`
CustomFields param.Field[map[string]interface{}] `json:"custom_fields"`
Description param.Field[string] `json:"description"`
DisplayID param.Field[string] `json:"display_id"`
ImportantDates param.Field[map[string]interface{}] `json:"important_dates"`
Jurisdiction param.Field[map[string]interface{}] `json:"jurisdiction"`
MatterType param.Field[string] `json:"matter_type"`
Metadata param.Field[map[string]interface{}] `json:"metadata"`
PracticeArea param.Field[string] `json:"practice_area"`
ResponsibleAttorneyID param.Field[string] `json:"responsible_attorney_id"`
Status param.Field[MatterV1UpdateParamsStatus] `json:"status"`
Subtype param.Field[string] `json:"subtype"`
Title param.Field[string] `json:"title"`
}
func (MatterV1UpdateParams) MarshalJSON ¶ added in v0.21.0
func (r MatterV1UpdateParams) MarshalJSON() (data []byte, err error)
type MatterV1UpdateParamsStatus ¶ added in v0.21.0
type MatterV1UpdateParamsStatus string
const ( MatterV1UpdateParamsStatusIntake MatterV1UpdateParamsStatus = "intake" MatterV1UpdateParamsStatusOpen MatterV1UpdateParamsStatus = "open" MatterV1UpdateParamsStatusPending MatterV1UpdateParamsStatus = "pending" MatterV1UpdateParamsStatusClosed MatterV1UpdateParamsStatus = "closed" MatterV1UpdateParamsStatusArchived MatterV1UpdateParamsStatus = "archived" )
func (MatterV1UpdateParamsStatus) IsKnown ¶ added in v0.21.0
func (r MatterV1UpdateParamsStatus) IsKnown() bool
type MatterV1WorkItemDecideParams ¶ added in v0.21.0
type MatterV1WorkItemDecideParams struct {
Decision param.Field[MatterV1WorkItemDecideParamsDecision] `json:"decision" api:"required"`
AgentTypeID param.Field[string] `json:"agent_type_id"`
Metadata param.Field[map[string]interface{}] `json:"metadata"`
Reason param.Field[string] `json:"reason"`
}
func (MatterV1WorkItemDecideParams) MarshalJSON ¶ added in v0.21.0
func (r MatterV1WorkItemDecideParams) MarshalJSON() (data []byte, err error)
type MatterV1WorkItemDecideParamsDecision ¶ added in v0.21.0
type MatterV1WorkItemDecideParamsDecision string
const ( MatterV1WorkItemDecideParamsDecisionApprove MatterV1WorkItemDecideParamsDecision = "approve" MatterV1WorkItemDecideParamsDecisionRevise MatterV1WorkItemDecideParamsDecision = "revise" MatterV1WorkItemDecideParamsDecisionBlock MatterV1WorkItemDecideParamsDecision = "block" MatterV1WorkItemDecideParamsDecisionReassign MatterV1WorkItemDecideParamsDecision = "reassign" )
func (MatterV1WorkItemDecideParamsDecision) IsKnown ¶ added in v0.21.0
func (r MatterV1WorkItemDecideParamsDecision) IsKnown() bool
type MatterV1WorkItemListParams ¶ added in v0.21.0
type MatterV1WorkItemListParams struct {
AssigneeID param.Field[string] `query:"assignee_id"`
Status param.Field[string] `query:"status"`
}
func (MatterV1WorkItemListParams) URLQuery ¶ added in v0.21.0
func (r MatterV1WorkItemListParams) URLQuery() (v url.Values)
URLQuery serializes MatterV1WorkItemListParams's query parameters as `url.Values`.
type MatterV1WorkItemNewParams ¶ added in v0.21.0
type MatterV1WorkItemNewParams struct {
Title param.Field[string] `json:"title" api:"required"`
AssigneeID param.Field[string] `json:"assignee_id"`
Description param.Field[string] `json:"description"`
DueAt param.Field[time.Time] `json:"due_at" format:"date-time"`
ExitCriteria param.Field[[]string] `json:"exit_criteria"`
Instructions param.Field[string] `json:"instructions"`
Metadata param.Field[map[string]interface{}] `json:"metadata"`
Priority param.Field[MatterV1WorkItemNewParamsPriority] `json:"priority"`
Type param.Field[MatterV1WorkItemNewParamsType] `json:"type"`
}
func (MatterV1WorkItemNewParams) MarshalJSON ¶ added in v0.21.0
func (r MatterV1WorkItemNewParams) MarshalJSON() (data []byte, err error)
type MatterV1WorkItemNewParamsPriority ¶ added in v0.21.0
type MatterV1WorkItemNewParamsPriority string
const ( MatterV1WorkItemNewParamsPriorityLow MatterV1WorkItemNewParamsPriority = "low" MatterV1WorkItemNewParamsPriorityNormal MatterV1WorkItemNewParamsPriority = "normal" MatterV1WorkItemNewParamsPriorityHigh MatterV1WorkItemNewParamsPriority = "high" MatterV1WorkItemNewParamsPriorityUrgent MatterV1WorkItemNewParamsPriority = "urgent" )
func (MatterV1WorkItemNewParamsPriority) IsKnown ¶ added in v0.21.0
func (r MatterV1WorkItemNewParamsPriority) IsKnown() bool
type MatterV1WorkItemNewParamsType ¶ added in v0.21.0
type MatterV1WorkItemNewParamsType string
const ( MatterV1WorkItemNewParamsTypeTask MatterV1WorkItemNewParamsType = "task" MatterV1WorkItemNewParamsTypeDeadline MatterV1WorkItemNewParamsType = "deadline" MatterV1WorkItemNewParamsTypeReview MatterV1WorkItemNewParamsType = "review" MatterV1WorkItemNewParamsTypeFiling MatterV1WorkItemNewParamsType = "filing" MatterV1WorkItemNewParamsTypeCommunication MatterV1WorkItemNewParamsType = "communication" MatterV1WorkItemNewParamsTypeResearch MatterV1WorkItemNewParamsType = "research" MatterV1WorkItemNewParamsTypeDrafting MatterV1WorkItemNewParamsType = "drafting" MatterV1WorkItemNewParamsTypeCollection MatterV1WorkItemNewParamsType = "collection" MatterV1WorkItemNewParamsTypeIntake MatterV1WorkItemNewParamsType = "intake" )
func (MatterV1WorkItemNewParamsType) IsKnown ¶ added in v0.21.0
func (r MatterV1WorkItemNewParamsType) IsKnown() bool
type MatterV1WorkItemService ¶ added in v0.21.0
type MatterV1WorkItemService struct {
Options []option.RequestOption
}
Matter-native legal workspaces and orchestration primitives
MatterV1WorkItemService contains methods and other services that help with interacting with the casedev API.
Note, unlike clients, this service does not read variables from the environment automatically. You should not instantiate this service directly, and instead use the NewMatterV1WorkItemService method instead.
func NewMatterV1WorkItemService ¶ added in v0.21.0
func NewMatterV1WorkItemService(opts ...option.RequestOption) (r *MatterV1WorkItemService)
NewMatterV1WorkItemService generates a new service that applies the given options to each request. These options are applied after the parent client's options (if there is one), and before any request-specific options.
func (*MatterV1WorkItemService) Decide ¶ added in v0.21.0
func (r *MatterV1WorkItemService) Decide(ctx context.Context, id string, workItemID string, body MatterV1WorkItemDecideParams, opts ...option.RequestOption) (err error)
Approve, revise, block, or reassign a work item. Used by humans or agents to move work items through their lifecycle.
func (*MatterV1WorkItemService) Get ¶ added in v0.21.0
func (r *MatterV1WorkItemService) Get(ctx context.Context, id string, workItemID string, opts ...option.RequestOption) (err error)
Get a single work item for a matter.
func (*MatterV1WorkItemService) List ¶ added in v0.21.0
func (r *MatterV1WorkItemService) List(ctx context.Context, id string, query MatterV1WorkItemListParams, opts ...option.RequestOption) (err error)
List active work items for a matter.
func (*MatterV1WorkItemService) ListExecutions ¶ added in v0.21.0
func (r *MatterV1WorkItemService) ListExecutions(ctx context.Context, id string, workItemID string, opts ...option.RequestOption) (err error)
List execution attempts for a work item, including agent and run linkage.
func (*MatterV1WorkItemService) New ¶ added in v0.21.0
func (r *MatterV1WorkItemService) New(ctx context.Context, id string, body MatterV1WorkItemNewParams, opts ...option.RequestOption) (err error)
Create an active work item on a matter.
func (*MatterV1WorkItemService) Update ¶ added in v0.21.0
func (r *MatterV1WorkItemService) Update(ctx context.Context, id string, workItemID string, body MatterV1WorkItemUpdateParams, opts ...option.RequestOption) (err error)
Update a matter work item.
type MatterV1WorkItemUpdateParams ¶ added in v0.21.0
type MatterV1WorkItemUpdateParams struct {
AssigneeID param.Field[string] `json:"assignee_id"`
CompletedAt param.Field[time.Time] `json:"completed_at" format:"date-time"`
Description param.Field[string] `json:"description"`
DueAt param.Field[time.Time] `json:"due_at" format:"date-time"`
ExitCriteria param.Field[[]string] `json:"exit_criteria"`
Instructions param.Field[string] `json:"instructions"`
Metadata param.Field[map[string]interface{}] `json:"metadata"`
Priority param.Field[MatterV1WorkItemUpdateParamsPriority] `json:"priority"`
StartedAt param.Field[time.Time] `json:"started_at" format:"date-time"`
Status param.Field[MatterV1WorkItemUpdateParamsStatus] `json:"status"`
Title param.Field[string] `json:"title"`
Type param.Field[MatterV1WorkItemUpdateParamsType] `json:"type"`
}
func (MatterV1WorkItemUpdateParams) MarshalJSON ¶ added in v0.21.0
func (r MatterV1WorkItemUpdateParams) MarshalJSON() (data []byte, err error)
type MatterV1WorkItemUpdateParamsPriority ¶ added in v0.21.0
type MatterV1WorkItemUpdateParamsPriority string
const ( MatterV1WorkItemUpdateParamsPriorityLow MatterV1WorkItemUpdateParamsPriority = "low" MatterV1WorkItemUpdateParamsPriorityNormal MatterV1WorkItemUpdateParamsPriority = "normal" MatterV1WorkItemUpdateParamsPriorityHigh MatterV1WorkItemUpdateParamsPriority = "high" MatterV1WorkItemUpdateParamsPriorityUrgent MatterV1WorkItemUpdateParamsPriority = "urgent" )
func (MatterV1WorkItemUpdateParamsPriority) IsKnown ¶ added in v0.21.0
func (r MatterV1WorkItemUpdateParamsPriority) IsKnown() bool
type MatterV1WorkItemUpdateParamsStatus ¶ added in v0.21.0
type MatterV1WorkItemUpdateParamsStatus string
const ( MatterV1WorkItemUpdateParamsStatusDraft MatterV1WorkItemUpdateParamsStatus = "draft" MatterV1WorkItemUpdateParamsStatusQueued MatterV1WorkItemUpdateParamsStatus = "queued" MatterV1WorkItemUpdateParamsStatusInProgress MatterV1WorkItemUpdateParamsStatus = "in_progress" MatterV1WorkItemUpdateParamsStatusBlocked MatterV1WorkItemUpdateParamsStatus = "blocked" MatterV1WorkItemUpdateParamsStatusInReview MatterV1WorkItemUpdateParamsStatus = "in_review" MatterV1WorkItemUpdateParamsStatusAwaitingHuman MatterV1WorkItemUpdateParamsStatus = "awaiting_human" MatterV1WorkItemUpdateParamsStatusDone MatterV1WorkItemUpdateParamsStatus = "done" MatterV1WorkItemUpdateParamsStatusCanceled MatterV1WorkItemUpdateParamsStatus = "canceled" )
func (MatterV1WorkItemUpdateParamsStatus) IsKnown ¶ added in v0.21.0
func (r MatterV1WorkItemUpdateParamsStatus) IsKnown() bool
type MatterV1WorkItemUpdateParamsType ¶ added in v0.21.0
type MatterV1WorkItemUpdateParamsType string
const ( MatterV1WorkItemUpdateParamsTypeTask MatterV1WorkItemUpdateParamsType = "task" MatterV1WorkItemUpdateParamsTypeDeadline MatterV1WorkItemUpdateParamsType = "deadline" MatterV1WorkItemUpdateParamsTypeReview MatterV1WorkItemUpdateParamsType = "review" MatterV1WorkItemUpdateParamsTypeFiling MatterV1WorkItemUpdateParamsType = "filing" MatterV1WorkItemUpdateParamsTypeCommunication MatterV1WorkItemUpdateParamsType = "communication" MatterV1WorkItemUpdateParamsTypeResearch MatterV1WorkItemUpdateParamsType = "research" MatterV1WorkItemUpdateParamsTypeDrafting MatterV1WorkItemUpdateParamsType = "drafting" MatterV1WorkItemUpdateParamsTypeCollection MatterV1WorkItemUpdateParamsType = "collection" MatterV1WorkItemUpdateParamsTypeIntake MatterV1WorkItemUpdateParamsType = "intake" )
func (MatterV1WorkItemUpdateParamsType) IsKnown ¶ added in v0.21.0
func (r MatterV1WorkItemUpdateParamsType) IsKnown() bool
type MemoryService ¶
type MemoryService struct {
Options []option.RequestOption
// Persistent memory for AI agents with semantic search and 12 generic indexed tag
// fields
V1 *MemoryV1Service
}
MemoryService contains methods and other services that help with interacting with the casedev API.
Note, unlike clients, this service does not read variables from the environment automatically. You should not instantiate this service directly, and instead use the NewMemoryService method instead.
func NewMemoryService ¶
func NewMemoryService(opts ...option.RequestOption) (r *MemoryService)
NewMemoryService generates a new service that applies the given options to each request. These options are applied after the parent client's options (if there is one), and before any request-specific options.
type MemoryV1DeleteAllParams ¶
type MemoryV1DeleteAllParams struct {
// Filter by tag_1
Tag1 param.Field[string] `query:"tag_1"`
// Filter by tag_10
Tag10 param.Field[string] `query:"tag_10"`
// Filter by tag_11
Tag11 param.Field[string] `query:"tag_11"`
// Filter by tag_12
Tag12 param.Field[string] `query:"tag_12"`
// Filter by tag_2
Tag2 param.Field[string] `query:"tag_2"`
// Filter by tag_3
Tag3 param.Field[string] `query:"tag_3"`
// Filter by tag_4
Tag4 param.Field[string] `query:"tag_4"`
// Filter by tag_5
Tag5 param.Field[string] `query:"tag_5"`
// Filter by tag_6
Tag6 param.Field[string] `query:"tag_6"`
// Filter by tag_7
Tag7 param.Field[string] `query:"tag_7"`
// Filter by tag_8
Tag8 param.Field[string] `query:"tag_8"`
// Filter by tag_9
Tag9 param.Field[string] `query:"tag_9"`
}
func (MemoryV1DeleteAllParams) URLQuery ¶
func (r MemoryV1DeleteAllParams) URLQuery() (v url.Values)
URLQuery serializes MemoryV1DeleteAllParams's query parameters as `url.Values`.
type MemoryV1DeleteAllResponse ¶
type MemoryV1DeleteAllResponse struct {
// Number of memories deleted
Deleted int64 `json:"deleted"`
JSON memoryV1DeleteAllResponseJSON `json:"-"`
}
func (*MemoryV1DeleteAllResponse) UnmarshalJSON ¶
func (r *MemoryV1DeleteAllResponse) UnmarshalJSON(data []byte) (err error)
type MemoryV1DeleteResponse ¶
type MemoryV1DeleteResponse struct {
Message string `json:"message"`
Success bool `json:"success"`
JSON memoryV1DeleteResponseJSON `json:"-"`
}
func (*MemoryV1DeleteResponse) UnmarshalJSON ¶
func (r *MemoryV1DeleteResponse) UnmarshalJSON(data []byte) (err error)
type MemoryV1GetResponse ¶
type MemoryV1GetResponse struct {
// Memory ID
ID string `json:"id"`
CreatedAt time.Time `json:"created_at" format:"date-time"`
// Memory content
Memory string `json:"memory"`
// Memory metadata
Metadata interface{} `json:"metadata"`
UpdatedAt time.Time `json:"updated_at" format:"date-time"`
JSON memoryV1GetResponseJSON `json:"-"`
}
func (*MemoryV1GetResponse) UnmarshalJSON ¶
func (r *MemoryV1GetResponse) UnmarshalJSON(data []byte) (err error)
type MemoryV1ListParams ¶
type MemoryV1ListParams struct {
// Filter by category
Category param.Field[string] `query:"category"`
// Number of results
Limit param.Field[int64] `query:"limit"`
// Pagination offset
Offset param.Field[int64] `query:"offset"`
// Filter by tag_1
Tag1 param.Field[string] `query:"tag_1"`
// Filter by tag_10
Tag10 param.Field[string] `query:"tag_10"`
// Filter by tag_11
Tag11 param.Field[string] `query:"tag_11"`
// Filter by tag_12
Tag12 param.Field[string] `query:"tag_12"`
// Filter by tag_2
Tag2 param.Field[string] `query:"tag_2"`
// Filter by tag_3
Tag3 param.Field[string] `query:"tag_3"`
// Filter by tag_4
Tag4 param.Field[string] `query:"tag_4"`
// Filter by tag_5
Tag5 param.Field[string] `query:"tag_5"`
// Filter by tag_6
Tag6 param.Field[string] `query:"tag_6"`
// Filter by tag_7
Tag7 param.Field[string] `query:"tag_7"`
// Filter by tag_8
Tag8 param.Field[string] `query:"tag_8"`
// Filter by tag_9
Tag9 param.Field[string] `query:"tag_9"`
}
func (MemoryV1ListParams) URLQuery ¶
func (r MemoryV1ListParams) URLQuery() (v url.Values)
URLQuery serializes MemoryV1ListParams's query parameters as `url.Values`.
type MemoryV1ListResponse ¶
type MemoryV1ListResponse struct {
// Total count matching filters
Count int64 `json:"count"`
Results []MemoryV1ListResponseResult `json:"results"`
JSON memoryV1ListResponseJSON `json:"-"`
}
func (*MemoryV1ListResponse) UnmarshalJSON ¶
func (r *MemoryV1ListResponse) UnmarshalJSON(data []byte) (err error)
type MemoryV1ListResponseResult ¶
type MemoryV1ListResponseResult struct {
ID string `json:"id"`
CreatedAt time.Time `json:"created_at" format:"date-time"`
Memory string `json:"memory"`
Metadata interface{} `json:"metadata"`
Tags interface{} `json:"tags"`
UpdatedAt time.Time `json:"updated_at" format:"date-time"`
JSON memoryV1ListResponseResultJSON `json:"-"`
}
func (*MemoryV1ListResponseResult) UnmarshalJSON ¶
func (r *MemoryV1ListResponseResult) UnmarshalJSON(data []byte) (err error)
type MemoryV1NewParams ¶
type MemoryV1NewParams struct {
// Conversation messages to extract memories from
Messages param.Field[[]MemoryV1NewParamsMessage] `json:"messages" api:"required"`
// Custom category (e.g., "fact", "preference", "deadline")
Category param.Field[string] `json:"category"`
// Optional custom prompt for fact extraction
ExtractionPrompt param.Field[string] `json:"extraction_prompt"`
// Whether to extract facts from messages (default: true)
Infer param.Field[bool] `json:"infer"`
// Additional metadata (not indexed)
Metadata param.Field[map[string]interface{}] `json:"metadata"`
// Generic indexed filter field 1 (you decide what it means)
Tag1 param.Field[string] `json:"tag_1"`
// Generic indexed filter field 10
Tag10 param.Field[string] `json:"tag_10"`
// Generic indexed filter field 11
Tag11 param.Field[string] `json:"tag_11"`
// Generic indexed filter field 12
Tag12 param.Field[string] `json:"tag_12"`
// Generic indexed filter field 2
Tag2 param.Field[string] `json:"tag_2"`
// Generic indexed filter field 3
Tag3 param.Field[string] `json:"tag_3"`
// Generic indexed filter field 4
Tag4 param.Field[string] `json:"tag_4"`
// Generic indexed filter field 5
Tag5 param.Field[string] `json:"tag_5"`
// Generic indexed filter field 6
Tag6 param.Field[string] `json:"tag_6"`
// Generic indexed filter field 7
Tag7 param.Field[string] `json:"tag_7"`
// Generic indexed filter field 8
Tag8 param.Field[string] `json:"tag_8"`
// Generic indexed filter field 9
Tag9 param.Field[string] `json:"tag_9"`
}
func (MemoryV1NewParams) MarshalJSON ¶
func (r MemoryV1NewParams) MarshalJSON() (data []byte, err error)
type MemoryV1NewParamsMessage ¶
type MemoryV1NewParamsMessage struct {
// Message content
Content param.Field[string] `json:"content" api:"required"`
// Message role
Role param.Field[MemoryV1NewParamsMessagesRole] `json:"role" api:"required"`
}
func (MemoryV1NewParamsMessage) MarshalJSON ¶
func (r MemoryV1NewParamsMessage) MarshalJSON() (data []byte, err error)
type MemoryV1NewParamsMessagesRole ¶
type MemoryV1NewParamsMessagesRole string
Message role
const ( MemoryV1NewParamsMessagesRoleUser MemoryV1NewParamsMessagesRole = "user" MemoryV1NewParamsMessagesRoleAssistant MemoryV1NewParamsMessagesRole = "assistant" MemoryV1NewParamsMessagesRoleSystem MemoryV1NewParamsMessagesRole = "system" )
func (MemoryV1NewParamsMessagesRole) IsKnown ¶
func (r MemoryV1NewParamsMessagesRole) IsKnown() bool
type MemoryV1NewResponse ¶
type MemoryV1NewResponse struct {
Results []MemoryV1NewResponseResult `json:"results"`
JSON memoryV1NewResponseJSON `json:"-"`
}
func (*MemoryV1NewResponse) UnmarshalJSON ¶
func (r *MemoryV1NewResponse) UnmarshalJSON(data []byte) (err error)
type MemoryV1NewResponseResult ¶
type MemoryV1NewResponseResult struct {
// Memory ID
ID string `json:"id"`
// What happened to this memory
Event MemoryV1NewResponseResultsEvent `json:"event"`
// Extracted memory text
Memory string `json:"memory"`
JSON memoryV1NewResponseResultJSON `json:"-"`
}
func (*MemoryV1NewResponseResult) UnmarshalJSON ¶
func (r *MemoryV1NewResponseResult) UnmarshalJSON(data []byte) (err error)
type MemoryV1NewResponseResultsEvent ¶
type MemoryV1NewResponseResultsEvent string
What happened to this memory
const ( MemoryV1NewResponseResultsEventAdd MemoryV1NewResponseResultsEvent = "ADD" MemoryV1NewResponseResultsEventUpdate MemoryV1NewResponseResultsEvent = "UPDATE" MemoryV1NewResponseResultsEventDelete MemoryV1NewResponseResultsEvent = "DELETE" MemoryV1NewResponseResultsEventNone MemoryV1NewResponseResultsEvent = "NONE" )
func (MemoryV1NewResponseResultsEvent) IsKnown ¶
func (r MemoryV1NewResponseResultsEvent) IsKnown() bool
type MemoryV1SearchParams ¶
type MemoryV1SearchParams struct {
// Search query for semantic matching
Query param.Field[string] `json:"query" api:"required"`
// Filter by category
Category param.Field[string] `json:"category"`
// Filter by tag_1
Tag1 param.Field[string] `json:"tag_1"`
// Filter by tag_10
Tag10 param.Field[string] `json:"tag_10"`
// Filter by tag_11
Tag11 param.Field[string] `json:"tag_11"`
// Filter by tag_12
Tag12 param.Field[string] `json:"tag_12"`
// Filter by tag_2
Tag2 param.Field[string] `json:"tag_2"`
// Filter by tag_3
Tag3 param.Field[string] `json:"tag_3"`
// Filter by tag_4
Tag4 param.Field[string] `json:"tag_4"`
// Filter by tag_5
Tag5 param.Field[string] `json:"tag_5"`
// Filter by tag_6
Tag6 param.Field[string] `json:"tag_6"`
// Filter by tag_7
Tag7 param.Field[string] `json:"tag_7"`
// Filter by tag_8
Tag8 param.Field[string] `json:"tag_8"`
// Filter by tag_9
Tag9 param.Field[string] `json:"tag_9"`
// Maximum number of results to return
TopK param.Field[int64] `json:"top_k"`
}
func (MemoryV1SearchParams) MarshalJSON ¶
func (r MemoryV1SearchParams) MarshalJSON() (data []byte, err error)
type MemoryV1SearchResponse ¶
type MemoryV1SearchResponse struct {
Results []MemoryV1SearchResponseResult `json:"results"`
JSON memoryV1SearchResponseJSON `json:"-"`
}
func (*MemoryV1SearchResponse) UnmarshalJSON ¶
func (r *MemoryV1SearchResponse) UnmarshalJSON(data []byte) (err error)
type MemoryV1SearchResponseResult ¶
type MemoryV1SearchResponseResult struct {
// Memory ID
ID string `json:"id"`
CreatedAt time.Time `json:"created_at" format:"date-time"`
// Memory content
Memory string `json:"memory"`
// Additional metadata
Metadata interface{} `json:"metadata"`
// Similarity score (0-1)
Score float64 `json:"score"`
// Tag values for this memory
Tags MemoryV1SearchResponseResultsTags `json:"tags"`
UpdatedAt time.Time `json:"updated_at" format:"date-time"`
JSON memoryV1SearchResponseResultJSON `json:"-"`
}
func (*MemoryV1SearchResponseResult) UnmarshalJSON ¶
func (r *MemoryV1SearchResponseResult) UnmarshalJSON(data []byte) (err error)
type MemoryV1SearchResponseResultsTags ¶
type MemoryV1SearchResponseResultsTags struct {
Tag1 string `json:"tag_1"`
Tag10 string `json:"tag_10"`
Tag11 string `json:"tag_11"`
Tag12 string `json:"tag_12"`
Tag2 string `json:"tag_2"`
Tag3 string `json:"tag_3"`
Tag4 string `json:"tag_4"`
Tag5 string `json:"tag_5"`
Tag6 string `json:"tag_6"`
Tag7 string `json:"tag_7"`
Tag8 string `json:"tag_8"`
Tag9 string `json:"tag_9"`
JSON memoryV1SearchResponseResultsTagsJSON `json:"-"`
}
Tag values for this memory
func (*MemoryV1SearchResponseResultsTags) UnmarshalJSON ¶
func (r *MemoryV1SearchResponseResultsTags) UnmarshalJSON(data []byte) (err error)
type MemoryV1Service ¶
type MemoryV1Service struct {
Options []option.RequestOption
}
Persistent memory for AI agents with semantic search and 12 generic indexed tag fields
MemoryV1Service contains methods and other services that help with interacting with the casedev API.
Note, unlike clients, this service does not read variables from the environment automatically. You should not instantiate this service directly, and instead use the NewMemoryV1Service method instead.
func NewMemoryV1Service ¶
func NewMemoryV1Service(opts ...option.RequestOption) (r *MemoryV1Service)
NewMemoryV1Service generates a new service that applies the given options to each request. These options are applied after the parent client's options (if there is one), and before any request-specific options.
func (*MemoryV1Service) Delete ¶
func (r *MemoryV1Service) Delete(ctx context.Context, id string, opts ...option.RequestOption) (res *MemoryV1DeleteResponse, err error)
Delete a single memory by its ID.
func (*MemoryV1Service) DeleteAll ¶
func (r *MemoryV1Service) DeleteAll(ctx context.Context, body MemoryV1DeleteAllParams, opts ...option.RequestOption) (res *MemoryV1DeleteAllResponse, err error)
Delete multiple memories matching tag filter criteria. CAUTION: This will delete all matching memories for your organization.
func (*MemoryV1Service) Get ¶
func (r *MemoryV1Service) Get(ctx context.Context, id string, opts ...option.RequestOption) (res *MemoryV1GetResponse, err error)
Retrieve a single memory by its ID.
func (*MemoryV1Service) List ¶
func (r *MemoryV1Service) List(ctx context.Context, query MemoryV1ListParams, opts ...option.RequestOption) (res *MemoryV1ListResponse, err error)
List all memories with optional filtering by tags and category.
func (*MemoryV1Service) New ¶
func (r *MemoryV1Service) New(ctx context.Context, body MemoryV1NewParams, opts ...option.RequestOption) (res *MemoryV1NewResponse, err error)
Store memories from conversation messages. Automatically extracts facts and handles deduplication.
Use tag_1 through tag_12 for filtering - these are generic indexed fields you can use for any purpose:
- Legal app: tag_1=client_id, tag_2=matter_id - Healthcare: tag_1=patient_id, tag_2=encounter_id - E-commerce: tag_1=customer_id, tag_2=order_id
func (*MemoryV1Service) Search ¶
func (r *MemoryV1Service) Search(ctx context.Context, body MemoryV1SearchParams, opts ...option.RequestOption) (res *MemoryV1SearchResponse, err error)
Search memories using semantic similarity. Filter by tag fields to narrow results.
Use tag_1 through tag_12 for filtering - these are generic indexed fields you define:
- Legal app: tag_1=client_id, tag_2=matter_id - Healthcare: tag_1=patient_id, tag_2=encounter_id
type OcrService ¶
type OcrService struct {
Options []option.RequestOption
// Extract text from PDFs, images, and scanned documents
V1 *OcrV1Service
}
OcrService contains methods and other services that help with interacting with the casedev API.
Note, unlike clients, this service does not read variables from the environment automatically. You should not instantiate this service directly, and instead use the NewOcrService method instead.
func NewOcrService ¶
func NewOcrService(opts ...option.RequestOption) (r *OcrService)
NewOcrService generates a new service that applies the given options to each request. These options are applied after the parent client's options (if there is one), and before any request-specific options.
type OcrV1DownloadParamsType ¶
type OcrV1DownloadParamsType string
const ( OcrV1DownloadParamsTypeText OcrV1DownloadParamsType = "text" OcrV1DownloadParamsTypeJson OcrV1DownloadParamsType = "json" OcrV1DownloadParamsTypePdf OcrV1DownloadParamsType = "pdf" OcrV1DownloadParamsTypeOriginal OcrV1DownloadParamsType = "original" )
func (OcrV1DownloadParamsType) IsKnown ¶
func (r OcrV1DownloadParamsType) IsKnown() bool
type OcrV1GetParams ¶ added in v0.35.0
type OcrV1GetParams struct {
// Include full OCR text in completed responses (default: true)
IncludeText param.Field[OcrV1GetParamsIncludeText] `query:"include_text"`
}
func (OcrV1GetParams) URLQuery ¶ added in v0.35.0
func (r OcrV1GetParams) URLQuery() (v url.Values)
URLQuery serializes OcrV1GetParams's query parameters as `url.Values`.
type OcrV1GetParamsIncludeText ¶ added in v0.35.0
type OcrV1GetParamsIncludeText string
Include full OCR text in completed responses (default: true)
const ( OcrV1GetParamsIncludeTextTrue OcrV1GetParamsIncludeText = "true" OcrV1GetParamsIncludeTextFalse OcrV1GetParamsIncludeText = "false" )
func (OcrV1GetParamsIncludeText) IsKnown ¶ added in v0.35.0
func (r OcrV1GetParamsIncludeText) IsKnown() bool
type OcrV1GetResponse ¶
type OcrV1GetResponse struct {
// OCR job ID
ID string `json:"id" api:"required"`
// Job creation timestamp
CreatedAt time.Time `json:"created_at" api:"required" format:"date-time"`
// Current job status
Status OcrV1GetResponseStatus `json:"status" api:"required"`
// Job completion timestamp
CompletedAt time.Time `json:"completed_at" format:"date-time"`
// Additional processing metadata
Metadata interface{} `json:"metadata"`
// Number of pages processed
PageCount int64 `json:"page_count"`
// Extracted text content (when completed)
Text string `json:"text"`
JSON ocrV1GetResponseJSON `json:"-"`
}
func (*OcrV1GetResponse) UnmarshalJSON ¶
func (r *OcrV1GetResponse) UnmarshalJSON(data []byte) (err error)
type OcrV1GetResponseStatus ¶
type OcrV1GetResponseStatus string
Current job status
const ( OcrV1GetResponseStatusPending OcrV1GetResponseStatus = "pending" OcrV1GetResponseStatusProcessing OcrV1GetResponseStatus = "processing" OcrV1GetResponseStatusCompleted OcrV1GetResponseStatus = "completed" OcrV1GetResponseStatusFailed OcrV1GetResponseStatus = "failed" )
func (OcrV1GetResponseStatus) IsKnown ¶
func (r OcrV1GetResponseStatus) IsKnown() bool
type OcrV1ProcessParams ¶
type OcrV1ProcessParams struct {
// URL or S3 path to the document to process
DocumentURL param.Field[string] `json:"document_url" api:"required"`
// URL to receive completion webhook
CallbackURL param.Field[string] `json:"callback_url"`
// Optional custom document identifier
DocumentID param.Field[string] `json:"document_id"`
// OCR engine to use
Engine param.Field[OcrV1ProcessParamsEngine] `json:"engine"`
// Additional processing options
Features param.Field[OcrV1ProcessParamsFeatures] `json:"features"`
// S3 bucket to store results
ResultBucket param.Field[string] `json:"result_bucket"`
// S3 key prefix for results
ResultPrefix param.Field[string] `json:"result_prefix"`
}
func (OcrV1ProcessParams) MarshalJSON ¶
func (r OcrV1ProcessParams) MarshalJSON() (data []byte, err error)
type OcrV1ProcessParamsEngine ¶
type OcrV1ProcessParamsEngine string
OCR engine to use
const ( OcrV1ProcessParamsEngineDoctr OcrV1ProcessParamsEngine = "doctr" OcrV1ProcessParamsEnginePaddleocr OcrV1ProcessParamsEngine = "paddleocr" )
func (OcrV1ProcessParamsEngine) IsKnown ¶
func (r OcrV1ProcessParamsEngine) IsKnown() bool
type OcrV1ProcessParamsFeatures ¶
type OcrV1ProcessParamsFeatures struct {
// Generate searchable PDF with text layer
Embed param.Field[map[string]interface{}] `json:"embed"`
// Detect and extract form fields
Forms param.Field[map[string]interface{}] `json:"forms"`
// Extract tables as structured data
Tables param.Field[OcrV1ProcessParamsFeaturesTables] `json:"tables"`
}
Additional processing options
func (OcrV1ProcessParamsFeatures) MarshalJSON ¶
func (r OcrV1ProcessParamsFeatures) MarshalJSON() (data []byte, err error)
type OcrV1ProcessParamsFeaturesTables ¶
type OcrV1ProcessParamsFeaturesTables struct {
// Output format for extracted tables
Format param.Field[OcrV1ProcessParamsFeaturesTablesFormat] `json:"format"`
ExtraFields map[string]interface{} `json:"-,extras"`
}
Extract tables as structured data
func (OcrV1ProcessParamsFeaturesTables) MarshalJSON ¶
func (r OcrV1ProcessParamsFeaturesTables) MarshalJSON() (data []byte, err error)
type OcrV1ProcessParamsFeaturesTablesFormat ¶
type OcrV1ProcessParamsFeaturesTablesFormat string
Output format for extracted tables
const ( OcrV1ProcessParamsFeaturesTablesFormatCsv OcrV1ProcessParamsFeaturesTablesFormat = "csv" OcrV1ProcessParamsFeaturesTablesFormatJson OcrV1ProcessParamsFeaturesTablesFormat = "json" )
func (OcrV1ProcessParamsFeaturesTablesFormat) IsKnown ¶
func (r OcrV1ProcessParamsFeaturesTablesFormat) IsKnown() bool
type OcrV1ProcessResponse ¶
type OcrV1ProcessResponse struct {
// Unique job identifier
ID string `json:"id"`
// Job creation timestamp
CreatedAt time.Time `json:"created_at" format:"date-time"`
// Document identifier
DocumentID string `json:"document_id"`
// OCR engine used
Engine string `json:"engine"`
// Estimated completion time
EstimatedCompletion time.Time `json:"estimated_completion" format:"date-time"`
// Number of pages detected
PageCount int64 `json:"page_count"`
// Current job status
Status OcrV1ProcessResponseStatus `json:"status"`
JSON ocrV1ProcessResponseJSON `json:"-"`
}
func (*OcrV1ProcessResponse) UnmarshalJSON ¶
func (r *OcrV1ProcessResponse) UnmarshalJSON(data []byte) (err error)
type OcrV1ProcessResponseStatus ¶
type OcrV1ProcessResponseStatus string
Current job status
const ( OcrV1ProcessResponseStatusQueued OcrV1ProcessResponseStatus = "queued" OcrV1ProcessResponseStatusProcessing OcrV1ProcessResponseStatus = "processing" OcrV1ProcessResponseStatusCompleted OcrV1ProcessResponseStatus = "completed" OcrV1ProcessResponseStatusFailed OcrV1ProcessResponseStatus = "failed" )
func (OcrV1ProcessResponseStatus) IsKnown ¶
func (r OcrV1ProcessResponseStatus) IsKnown() bool
type OcrV1Service ¶
type OcrV1Service struct {
Options []option.RequestOption
}
Extract text from PDFs, images, and scanned documents
OcrV1Service contains methods and other services that help with interacting with the casedev API.
Note, unlike clients, this service does not read variables from the environment automatically. You should not instantiate this service directly, and instead use the NewOcrV1Service method instead.
func NewOcrV1Service ¶
func NewOcrV1Service(opts ...option.RequestOption) (r *OcrV1Service)
NewOcrV1Service generates a new service that applies the given options to each request. These options are applied after the parent client's options (if there is one), and before any request-specific options.
func (*OcrV1Service) Download ¶
func (r *OcrV1Service) Download(ctx context.Context, id string, type_ OcrV1DownloadParamsType, opts ...option.RequestOption) (res *http.Response, err error)
Download OCR processing results in various formats. Returns the processed document as text extraction, structured JSON with coordinates, searchable PDF with text layer, or the original uploaded document.
func (*OcrV1Service) Get ¶
func (r *OcrV1Service) Get(ctx context.Context, id string, query OcrV1GetParams, opts ...option.RequestOption) (res *OcrV1GetResponse, err error)
Retrieve the status and results of an OCR job. Returns job progress, extracted text, and metadata when processing is complete.
func (*OcrV1Service) Process ¶
func (r *OcrV1Service) Process(ctx context.Context, body OcrV1ProcessParams, opts ...option.RequestOption) (res *OcrV1ProcessResponse, err error)
Submit a document for OCR processing to extract text, detect tables, forms, and other features. Supports PDFs, images, and scanned documents. Returns a job ID that can be used to track processing status.
type PrivilegeService ¶
type PrivilegeService struct {
Options []option.RequestOption
// Privilege detection for e-discovery and litigation workflows
V1 *PrivilegeV1Service
}
PrivilegeService contains methods and other services that help with interacting with the casedev API.
Note, unlike clients, this service does not read variables from the environment automatically. You should not instantiate this service directly, and instead use the NewPrivilegeService method instead.
func NewPrivilegeService ¶
func NewPrivilegeService(opts ...option.RequestOption) (r *PrivilegeService)
NewPrivilegeService generates a new service that applies the given options to each request. These options are applied after the parent client's options (if there is one), and before any request-specific options.
type PrivilegeV1DetectParams ¶
type PrivilegeV1DetectParams struct {
// Privilege categories to check. Defaults to all: attorney_client, work_product,
// common_interest
Categories param.Field[[]PrivilegeV1DetectParamsCategory] `json:"categories"`
// Text content to analyze (required if document_id not provided)
Content param.Field[string] `json:"content"`
// Vault object ID to analyze (required if content not provided)
DocumentID param.Field[string] `json:"document_id"`
// Include detailed rationale for each category
IncludeRationale param.Field[bool] `json:"include_rationale"`
// Jurisdiction for privilege rules
Jurisdiction param.Field[PrivilegeV1DetectParamsJurisdiction] `json:"jurisdiction"`
// LLM model to use for analysis
Model param.Field[string] `json:"model"`
// Vault ID (required when using document_id)
VaultID param.Field[string] `json:"vault_id"`
}
func (PrivilegeV1DetectParams) MarshalJSON ¶
func (r PrivilegeV1DetectParams) MarshalJSON() (data []byte, err error)
type PrivilegeV1DetectParamsCategory ¶
type PrivilegeV1DetectParamsCategory string
const ( PrivilegeV1DetectParamsCategoryAttorneyClient PrivilegeV1DetectParamsCategory = "attorney_client" PrivilegeV1DetectParamsCategoryWorkProduct PrivilegeV1DetectParamsCategory = "work_product" PrivilegeV1DetectParamsCategoryCommonInterest PrivilegeV1DetectParamsCategory = "common_interest" )
func (PrivilegeV1DetectParamsCategory) IsKnown ¶
func (r PrivilegeV1DetectParamsCategory) IsKnown() bool
type PrivilegeV1DetectParamsJurisdiction ¶
type PrivilegeV1DetectParamsJurisdiction string
Jurisdiction for privilege rules
const (
PrivilegeV1DetectParamsJurisdictionUsFederal PrivilegeV1DetectParamsJurisdiction = "US-Federal"
)
func (PrivilegeV1DetectParamsJurisdiction) IsKnown ¶
func (r PrivilegeV1DetectParamsJurisdiction) IsKnown() bool
type PrivilegeV1DetectResponse ¶
type PrivilegeV1DetectResponse struct {
Categories []PrivilegeV1DetectResponseCategory `json:"categories" api:"required"`
// Overall confidence score (0-1)
Confidence float64 `json:"confidence" api:"required"`
// Policy-friendly explanation for privilege log
PolicyRationale string `json:"policy_rationale" api:"required"`
// Whether any privilege was detected
Privileged bool `json:"privileged" api:"required"`
// Recommended action for discovery
Recommendation PrivilegeV1DetectResponseRecommendation `json:"recommendation" api:"required"`
JSON privilegeV1DetectResponseJSON `json:"-"`
}
func (*PrivilegeV1DetectResponse) UnmarshalJSON ¶
func (r *PrivilegeV1DetectResponse) UnmarshalJSON(data []byte) (err error)
type PrivilegeV1DetectResponseCategory ¶
type PrivilegeV1DetectResponseCategory struct {
// Confidence for this category (0-1)
Confidence float64 `json:"confidence"`
// Whether this privilege type was detected
Detected bool `json:"detected"`
// Specific phrases or patterns found
Indicators []string `json:"indicators"`
// Explanation of detection result
Rationale string `json:"rationale"`
// Privilege category
Type string `json:"type"`
JSON privilegeV1DetectResponseCategoryJSON `json:"-"`
}
func (*PrivilegeV1DetectResponseCategory) UnmarshalJSON ¶
func (r *PrivilegeV1DetectResponseCategory) UnmarshalJSON(data []byte) (err error)
type PrivilegeV1DetectResponseRecommendation ¶
type PrivilegeV1DetectResponseRecommendation string
Recommended action for discovery
const ( PrivilegeV1DetectResponseRecommendationWithhold PrivilegeV1DetectResponseRecommendation = "withhold" PrivilegeV1DetectResponseRecommendationRedact PrivilegeV1DetectResponseRecommendation = "redact" PrivilegeV1DetectResponseRecommendationProduce PrivilegeV1DetectResponseRecommendation = "produce" PrivilegeV1DetectResponseRecommendationReview PrivilegeV1DetectResponseRecommendation = "review" )
func (PrivilegeV1DetectResponseRecommendation) IsKnown ¶
func (r PrivilegeV1DetectResponseRecommendation) IsKnown() bool
type PrivilegeV1Service ¶
type PrivilegeV1Service struct {
Options []option.RequestOption
}
Privilege detection for e-discovery and litigation workflows
PrivilegeV1Service contains methods and other services that help with interacting with the casedev API.
Note, unlike clients, this service does not read variables from the environment automatically. You should not instantiate this service directly, and instead use the NewPrivilegeV1Service method instead.
func NewPrivilegeV1Service ¶
func NewPrivilegeV1Service(opts ...option.RequestOption) (r *PrivilegeV1Service)
NewPrivilegeV1Service generates a new service that applies the given options to each request. These options are applied after the parent client's options (if there is one), and before any request-specific options.
func (*PrivilegeV1Service) Detect ¶
func (r *PrivilegeV1Service) Detect(ctx context.Context, body PrivilegeV1DetectParams, opts ...option.RequestOption) (res *PrivilegeV1DetectResponse, err error)
Analyzes text or vault documents for legal privilege review. Detects attorney-client privilege, work product doctrine, and common interest privilege.
Returns structured review flags with confidence scores and policy-friendly rationale suitable for discovery workflows and privilege logs. This endpoint is an AI-assisted triage tool and does not replace attorney judgment.
**Size Limit:** Maximum 200,000 characters (larger documents rejected).
**Permissions:** Requires `chat` permission. When using `document_id`, also requires `vault` permission.
**Note:** When analyzing vault documents, results are automatically stored in the document's `privilege_analysis` metadata field.
type SearchService ¶
type SearchService struct {
Options []option.RequestOption
// Web search, AI answers, and deep research
V1 *SearchV1Service
}
SearchService contains methods and other services that help with interacting with the casedev API.
Note, unlike clients, this service does not read variables from the environment automatically. You should not instantiate this service directly, and instead use the NewSearchService method instead.
func NewSearchService ¶
func NewSearchService(opts ...option.RequestOption) (r *SearchService)
NewSearchService generates a new service that applies the given options to each request. These options are applied after the parent client's options (if there is one), and before any request-specific options.
type SearchV1AnswerParams ¶
type SearchV1AnswerParams struct {
// The question or topic to research and answer
Query param.Field[string] `json:"query" api:"required"`
// Exclude these domains from search
ExcludeDomains param.Field[[]string] `json:"excludeDomains"`
// Only search within these domains
IncludeDomains param.Field[[]string] `json:"includeDomains"`
// Maximum tokens for LLM response
MaxTokens param.Field[int64] `json:"maxTokens"`
// LLM model to use when useCustomLLM is true
Model param.Field[string] `json:"model"`
// Number of search results to consider
NumResults param.Field[int64] `json:"numResults"`
// Type of search to perform
SearchType param.Field[SearchV1AnswerParamsSearchType] `json:"searchType"`
// Stream the response (only for native provider answers)
Stream param.Field[bool] `json:"stream"`
// LLM temperature for answer generation
Temperature param.Field[float64] `json:"temperature"`
// Include text content in response
Text param.Field[bool] `json:"text"`
// Use Case.dev LLM for answer generation instead of provider's native answer
UseCustomLlm param.Field[bool] `json:"useCustomLLM"`
}
func (SearchV1AnswerParams) MarshalJSON ¶
func (r SearchV1AnswerParams) MarshalJSON() (data []byte, err error)
type SearchV1AnswerParamsSearchType ¶
type SearchV1AnswerParamsSearchType string
Type of search to perform
const ( SearchV1AnswerParamsSearchTypeAuto SearchV1AnswerParamsSearchType = "auto" SearchV1AnswerParamsSearchTypeWeb SearchV1AnswerParamsSearchType = "web" SearchV1AnswerParamsSearchTypeNews SearchV1AnswerParamsSearchType = "news" SearchV1AnswerParamsSearchTypeAcademic SearchV1AnswerParamsSearchType = "academic" )
func (SearchV1AnswerParamsSearchType) IsKnown ¶
func (r SearchV1AnswerParamsSearchType) IsKnown() bool
type SearchV1AnswerResponse ¶
type SearchV1AnswerResponse struct {
// The generated answer with citations
Answer string `json:"answer"`
// Sources used to generate the answer
Citations []SearchV1AnswerResponseCitation `json:"citations"`
// Model used for answer generation
Model string `json:"model"`
// Type of search performed
SearchType string `json:"searchType"`
JSON searchV1AnswerResponseJSON `json:"-"`
}
func (*SearchV1AnswerResponse) UnmarshalJSON ¶
func (r *SearchV1AnswerResponse) UnmarshalJSON(data []byte) (err error)
type SearchV1AnswerResponseCitation ¶
type SearchV1AnswerResponseCitation struct {
ID string `json:"id"`
PublishedDate string `json:"publishedDate"`
Text string `json:"text"`
Title string `json:"title"`
URL string `json:"url"`
JSON searchV1AnswerResponseCitationJSON `json:"-"`
}
func (*SearchV1AnswerResponseCitation) UnmarshalJSON ¶
func (r *SearchV1AnswerResponseCitation) UnmarshalJSON(data []byte) (err error)
type SearchV1ContentsParams ¶
type SearchV1ContentsParams struct {
// Array of URLs to scrape and extract content from
URLs param.Field[[]string] `json:"urls" api:"required" format:"uri"`
// Context to guide content extraction and summarization
Context param.Field[string] `json:"context"`
// Additional extraction options
Extras param.Field[interface{}] `json:"extras"`
// Whether to include content highlights
Highlights param.Field[bool] `json:"highlights"`
// Whether to perform live crawling for dynamic content
Livecrawl param.Field[bool] `json:"livecrawl"`
// Timeout in seconds for live crawling
LivecrawlTimeout param.Field[int64] `json:"livecrawlTimeout"`
// Whether to extract content from linked subpages
Subpages param.Field[bool] `json:"subpages"`
// Maximum number of subpages to crawl
SubpageTarget param.Field[int64] `json:"subpageTarget"`
// Whether to generate content summaries
Summary param.Field[bool] `json:"summary"`
// Whether to extract text content
Text param.Field[bool] `json:"text"`
}
func (SearchV1ContentsParams) MarshalJSON ¶
func (r SearchV1ContentsParams) MarshalJSON() (data []byte, err error)
type SearchV1ContentsResponse ¶
type SearchV1ContentsResponse struct {
Results []SearchV1ContentsResponseResult `json:"results"`
JSON searchV1ContentsResponseJSON `json:"-"`
}
func (*SearchV1ContentsResponse) UnmarshalJSON ¶
func (r *SearchV1ContentsResponse) UnmarshalJSON(data []byte) (err error)
type SearchV1ContentsResponseResult ¶
type SearchV1ContentsResponseResult struct {
// Content highlights if requested
Highlights []string `json:"highlights"`
// Additional metadata about the content
Metadata interface{} `json:"metadata"`
// Content summary if requested
Summary string `json:"summary"`
// Extracted text content
Text string `json:"text"`
// Page title
Title string `json:"title"`
// Source URL
URL string `json:"url"`
JSON searchV1ContentsResponseResultJSON `json:"-"`
}
func (*SearchV1ContentsResponseResult) UnmarshalJSON ¶
func (r *SearchV1ContentsResponseResult) UnmarshalJSON(data []byte) (err error)
type SearchV1GetResearchParams ¶
type SearchV1GetResearchParams struct {
// Filter specific event types for streaming
Events param.Field[string] `query:"events"`
// Enable streaming for real-time updates
Stream param.Field[bool] `query:"stream"`
}
func (SearchV1GetResearchParams) URLQuery ¶
func (r SearchV1GetResearchParams) URLQuery() (v url.Values)
URLQuery serializes SearchV1GetResearchParams's query parameters as `url.Values`.
type SearchV1GetResearchResponse ¶
type SearchV1GetResearchResponse struct {
// Research task ID
ID string `json:"id"`
// Task completion timestamp
CompletedAt time.Time `json:"completedAt" format:"date-time"`
// Task creation timestamp
CreatedAt time.Time `json:"createdAt" format:"date-time"`
// Research model used
Model SearchV1GetResearchResponseModel `json:"model"`
// Completion percentage (0-100)
Progress float64 `json:"progress"`
// Original research query
Query string `json:"query"`
// Research findings and analysis
Results SearchV1GetResearchResponseResults `json:"results"`
// Current status of the research task
Status SearchV1GetResearchResponseStatus `json:"status"`
JSON searchV1GetResearchResponseJSON `json:"-"`
}
func (*SearchV1GetResearchResponse) UnmarshalJSON ¶
func (r *SearchV1GetResearchResponse) UnmarshalJSON(data []byte) (err error)
type SearchV1GetResearchResponseModel ¶
type SearchV1GetResearchResponseModel string
Research model used
const ( SearchV1GetResearchResponseModelFast SearchV1GetResearchResponseModel = "fast" SearchV1GetResearchResponseModelNormal SearchV1GetResearchResponseModel = "normal" SearchV1GetResearchResponseModelPro SearchV1GetResearchResponseModel = "pro" )
func (SearchV1GetResearchResponseModel) IsKnown ¶
func (r SearchV1GetResearchResponseModel) IsKnown() bool
type SearchV1GetResearchResponseResults ¶
type SearchV1GetResearchResponseResults struct {
// Detailed research sections
Sections []SearchV1GetResearchResponseResultsSection `json:"sections"`
// All sources referenced in research
Sources []SearchV1GetResearchResponseResultsSource `json:"sources"`
// Executive summary of research findings
Summary string `json:"summary"`
JSON searchV1GetResearchResponseResultsJSON `json:"-"`
}
Research findings and analysis
func (*SearchV1GetResearchResponseResults) UnmarshalJSON ¶
func (r *SearchV1GetResearchResponseResults) UnmarshalJSON(data []byte) (err error)
type SearchV1GetResearchResponseResultsSection ¶
type SearchV1GetResearchResponseResultsSection struct {
Content string `json:"content"`
Sources []SearchV1GetResearchResponseResultsSectionsSource `json:"sources"`
Title string `json:"title"`
JSON searchV1GetResearchResponseResultsSectionJSON `json:"-"`
}
func (*SearchV1GetResearchResponseResultsSection) UnmarshalJSON ¶
func (r *SearchV1GetResearchResponseResultsSection) UnmarshalJSON(data []byte) (err error)
type SearchV1GetResearchResponseResultsSectionsSource ¶
type SearchV1GetResearchResponseResultsSectionsSource struct {
Snippet string `json:"snippet"`
Title string `json:"title"`
URL string `json:"url"`
JSON searchV1GetResearchResponseResultsSectionsSourceJSON `json:"-"`
}
func (*SearchV1GetResearchResponseResultsSectionsSource) UnmarshalJSON ¶
func (r *SearchV1GetResearchResponseResultsSectionsSource) UnmarshalJSON(data []byte) (err error)
type SearchV1GetResearchResponseResultsSource ¶
type SearchV1GetResearchResponseResultsSource struct {
Snippet string `json:"snippet"`
Title string `json:"title"`
URL string `json:"url"`
JSON searchV1GetResearchResponseResultsSourceJSON `json:"-"`
}
func (*SearchV1GetResearchResponseResultsSource) UnmarshalJSON ¶
func (r *SearchV1GetResearchResponseResultsSource) UnmarshalJSON(data []byte) (err error)
type SearchV1GetResearchResponseStatus ¶
type SearchV1GetResearchResponseStatus string
Current status of the research task
const ( SearchV1GetResearchResponseStatusPending SearchV1GetResearchResponseStatus = "pending" SearchV1GetResearchResponseStatusRunning SearchV1GetResearchResponseStatus = "running" SearchV1GetResearchResponseStatusCompleted SearchV1GetResearchResponseStatus = "completed" SearchV1GetResearchResponseStatusFailed SearchV1GetResearchResponseStatus = "failed" )
func (SearchV1GetResearchResponseStatus) IsKnown ¶
func (r SearchV1GetResearchResponseStatus) IsKnown() bool
type SearchV1ResearchParams ¶
type SearchV1ResearchParams struct {
// Research instructions or query
Instructions param.Field[string] `json:"instructions" api:"required"`
// Research quality level - fast (quick), normal (balanced), pro (comprehensive)
Model param.Field[SearchV1ResearchParamsModel] `json:"model"`
// Optional JSON schema to structure the research output
OutputSchema param.Field[interface{}] `json:"outputSchema"`
// Alias for instructions (for convenience)
Query param.Field[string] `json:"query"`
}
func (SearchV1ResearchParams) MarshalJSON ¶
func (r SearchV1ResearchParams) MarshalJSON() (data []byte, err error)
type SearchV1ResearchParamsModel ¶
type SearchV1ResearchParamsModel string
Research quality level - fast (quick), normal (balanced), pro (comprehensive)
const ( SearchV1ResearchParamsModelFast SearchV1ResearchParamsModel = "fast" SearchV1ResearchParamsModelNormal SearchV1ResearchParamsModel = "normal" SearchV1ResearchParamsModelPro SearchV1ResearchParamsModel = "pro" )
func (SearchV1ResearchParamsModel) IsKnown ¶
func (r SearchV1ResearchParamsModel) IsKnown() bool
type SearchV1ResearchResponse ¶
type SearchV1ResearchResponse struct {
// Model used for research
Model string `json:"model"`
// Unique identifier for this research
ResearchID string `json:"researchId"`
// Research findings and analysis
Results interface{} `json:"results"`
JSON searchV1ResearchResponseJSON `json:"-"`
}
func (*SearchV1ResearchResponse) UnmarshalJSON ¶
func (r *SearchV1ResearchResponse) UnmarshalJSON(data []byte) (err error)
type SearchV1SearchParams ¶
type SearchV1SearchParams struct {
// Primary search query
Query param.Field[string] `json:"query" api:"required"`
// Additional related search queries to enhance results
AdditionalQueries param.Field[[]string] `json:"additionalQueries"`
// Category filter for search results
Category param.Field[string] `json:"category"`
// Specific content type to search for
Contents param.Field[string] `json:"contents"`
// End date for crawl date filtering
EndCrawlDate param.Field[time.Time] `json:"endCrawlDate" format:"date"`
// End date for published date filtering
EndPublishedDate param.Field[time.Time] `json:"endPublishedDate" format:"date"`
// Domains to exclude from search results
ExcludeDomains param.Field[[]string] `json:"excludeDomains"`
// Domains to include in search results
IncludeDomains param.Field[[]string] `json:"includeDomains"`
// Whether to include full text content in results
IncludeText param.Field[bool] `json:"includeText"`
// Number of search results to return
NumResults param.Field[int64] `json:"numResults"`
// Start date for crawl date filtering
StartCrawlDate param.Field[time.Time] `json:"startCrawlDate" format:"date"`
// Start date for published date filtering
StartPublishedDate param.Field[time.Time] `json:"startPublishedDate" format:"date"`
// Type of search to perform
Type param.Field[SearchV1SearchParamsType] `json:"type"`
// Geographic location for localized results
UserLocation param.Field[string] `json:"userLocation"`
}
func (SearchV1SearchParams) MarshalJSON ¶
func (r SearchV1SearchParams) MarshalJSON() (data []byte, err error)
type SearchV1SearchParamsType ¶
type SearchV1SearchParamsType string
Type of search to perform
const ( SearchV1SearchParamsTypeAuto SearchV1SearchParamsType = "auto" SearchV1SearchParamsTypeSearch SearchV1SearchParamsType = "search" SearchV1SearchParamsTypeNews SearchV1SearchParamsType = "news" )
func (SearchV1SearchParamsType) IsKnown ¶
func (r SearchV1SearchParamsType) IsKnown() bool
type SearchV1SearchResponse ¶
type SearchV1SearchResponse struct {
// Original search query
Query string `json:"query"`
// Array of search results
Results []SearchV1SearchResponseResult `json:"results"`
// Total number of results found
TotalResults int64 `json:"totalResults"`
JSON searchV1SearchResponseJSON `json:"-"`
}
func (*SearchV1SearchResponse) UnmarshalJSON ¶
func (r *SearchV1SearchResponse) UnmarshalJSON(data []byte) (err error)
type SearchV1SearchResponseResult ¶
type SearchV1SearchResponseResult struct {
// Domain of the source
Domain string `json:"domain"`
// Publication date of the content
PublishedDate time.Time `json:"publishedDate" format:"date-time"`
// Brief excerpt from the content
Snippet string `json:"snippet"`
// Title of the search result
Title string `json:"title"`
// URL of the search result
URL string `json:"url"`
JSON searchV1SearchResponseResultJSON `json:"-"`
}
func (*SearchV1SearchResponseResult) UnmarshalJSON ¶
func (r *SearchV1SearchResponseResult) UnmarshalJSON(data []byte) (err error)
type SearchV1Service ¶
type SearchV1Service struct {
Options []option.RequestOption
}
Web search, AI answers, and deep research
SearchV1Service contains methods and other services that help with interacting with the casedev API.
Note, unlike clients, this service does not read variables from the environment automatically. You should not instantiate this service directly, and instead use the NewSearchV1Service method instead.
func NewSearchV1Service ¶
func NewSearchV1Service(opts ...option.RequestOption) (r *SearchV1Service)
NewSearchV1Service generates a new service that applies the given options to each request. These options are applied after the parent client's options (if there is one), and before any request-specific options.
func (*SearchV1Service) Answer ¶
func (r *SearchV1Service) Answer(ctx context.Context, body SearchV1AnswerParams, opts ...option.RequestOption) (res *SearchV1AnswerResponse, err error)
Generate comprehensive answers to questions using web search results. Supports two modes: native provider answers or custom LLM-powered answers using Case.dev's AI gateway. Perfect for legal research, fact-checking, and gathering supporting evidence for cases.
func (*SearchV1Service) Contents ¶
func (r *SearchV1Service) Contents(ctx context.Context, body SearchV1ContentsParams, opts ...option.RequestOption) (res *SearchV1ContentsResponse, err error)
Scrapes and extracts text content from web pages, PDFs, and documents. Useful for legal research, evidence collection, and document analysis. Supports live crawling, subpage extraction, and content summarization.
func (*SearchV1Service) GetResearch ¶
func (r *SearchV1Service) GetResearch(ctx context.Context, id string, query SearchV1GetResearchParams, opts ...option.RequestOption) (res *SearchV1GetResearchResponse, err error)
Retrieve the status and results of a deep research task by ID. Supports both standard JSON responses and streaming for real-time updates as the research progresses. Research tasks analyze topics comprehensively using web search and AI synthesis.
func (*SearchV1Service) Research ¶
func (r *SearchV1Service) Research(ctx context.Context, body SearchV1ResearchParams, opts ...option.RequestOption) (res *SearchV1ResearchResponse, err error)
Performs deep research by conducting multi-step analysis, gathering information from multiple sources, and providing comprehensive insights. Ideal for legal research, case analysis, and due diligence investigations.
func (*SearchV1Service) Search ¶
func (r *SearchV1Service) Search(ctx context.Context, body SearchV1SearchParams, opts ...option.RequestOption) (res *SearchV1SearchResponse, err error)
Executes intelligent web search queries with advanced filtering and customization options. Ideal for legal research, case law discovery, and gathering supporting documentation for litigation or compliance matters.
func (*SearchV1Service) Similar ¶
func (r *SearchV1Service) Similar(ctx context.Context, body SearchV1SimilarParams, opts ...option.RequestOption) (res *SearchV1SimilarResponse, err error)
Find web pages and documents similar to a given URL. Useful for legal research to discover related case law, statutes, or legal commentary that shares similar themes or content structure.
type SearchV1SimilarParams ¶
type SearchV1SimilarParams struct {
// The URL to find similar content for
URL param.Field[string] `json:"url" api:"required" format:"uri"`
// Additional content to consider for similarity matching
Contents param.Field[string] `json:"contents"`
// Only include pages crawled before this date
EndCrawlDate param.Field[time.Time] `json:"endCrawlDate" format:"date"`
// Only include pages published before this date
EndPublishedDate param.Field[time.Time] `json:"endPublishedDate" format:"date"`
// Exclude results from these domains
ExcludeDomains param.Field[[]string] `json:"excludeDomains"`
// Only search within these domains
IncludeDomains param.Field[[]string] `json:"includeDomains"`
// Whether to include extracted text content in results
IncludeText param.Field[bool] `json:"includeText"`
// Number of similar results to return
NumResults param.Field[int64] `json:"numResults"`
// Only include pages crawled after this date
StartCrawlDate param.Field[time.Time] `json:"startCrawlDate" format:"date"`
// Only include pages published after this date
StartPublishedDate param.Field[time.Time] `json:"startPublishedDate" format:"date"`
}
func (SearchV1SimilarParams) MarshalJSON ¶
func (r SearchV1SimilarParams) MarshalJSON() (data []byte, err error)
type SearchV1SimilarResponse ¶
type SearchV1SimilarResponse struct {
ProcessingTime float64 `json:"processingTime"`
Results []SearchV1SimilarResponseResult `json:"results"`
TotalResults int64 `json:"totalResults"`
JSON searchV1SimilarResponseJSON `json:"-"`
}
func (*SearchV1SimilarResponse) UnmarshalJSON ¶
func (r *SearchV1SimilarResponse) UnmarshalJSON(data []byte) (err error)
type SearchV1SimilarResponseResult ¶
type SearchV1SimilarResponseResult struct {
Domain string `json:"domain"`
PublishedDate string `json:"publishedDate"`
SimilarityScore float64 `json:"similarityScore"`
Snippet string `json:"snippet"`
Text string `json:"text"`
Title string `json:"title"`
URL string `json:"url"`
JSON searchV1SimilarResponseResultJSON `json:"-"`
}
func (*SearchV1SimilarResponseResult) UnmarshalJSON ¶
func (r *SearchV1SimilarResponseResult) UnmarshalJSON(data []byte) (err error)
type SkillCustomListParams ¶ added in v0.18.0
type SkillCustomListParams struct {
// Cursor for pagination (skill ID from previous page)
Cursor param.Field[string] `query:"cursor"`
// Maximum number of results (1-100)
Limit param.Field[int64] `query:"limit"`
// Filter by tag
Tag param.Field[string] `query:"tag"`
}
func (SkillCustomListParams) URLQuery ¶ added in v0.18.0
func (r SkillCustomListParams) URLQuery() (v url.Values)
URLQuery serializes SkillCustomListParams's query parameters as `url.Values`.
type SkillCustomListResponse ¶ added in v0.18.0
type SkillCustomListResponse struct {
HasMore bool `json:"has_more"`
NextCursor string `json:"next_cursor" api:"nullable"`
Skills []SkillCustomListResponseSkill `json:"skills"`
JSON skillCustomListResponseJSON `json:"-"`
}
func (*SkillCustomListResponse) UnmarshalJSON ¶ added in v0.18.0
func (r *SkillCustomListResponse) UnmarshalJSON(data []byte) (err error)
type SkillCustomListResponseSkill ¶ added in v0.18.0
type SkillCustomListResponseSkill struct {
CreatedAt time.Time `json:"created_at" format:"date-time"`
Metadata interface{} `json:"metadata"`
Name string `json:"name"`
Slug string `json:"slug"`
Summary string `json:"summary" api:"nullable"`
Tags []string `json:"tags"`
UpdatedAt time.Time `json:"updated_at" format:"date-time"`
Version int64 `json:"version"`
JSON skillCustomListResponseSkillJSON `json:"-"`
}
func (*SkillCustomListResponseSkill) UnmarshalJSON ¶ added in v0.18.0
func (r *SkillCustomListResponseSkill) UnmarshalJSON(data []byte) (err error)
type SkillCustomService ¶ added in v0.18.0
type SkillCustomService struct {
Options []option.RequestOption
}
Search and read legal AI skills for agents
SkillCustomService contains methods and other services that help with interacting with the casedev API.
Note, unlike clients, this service does not read variables from the environment automatically. You should not instantiate this service directly, and instead use the NewSkillCustomService method instead.
func NewSkillCustomService ¶ added in v0.18.0
func NewSkillCustomService(opts ...option.RequestOption) (r *SkillCustomService)
NewSkillCustomService generates a new service that applies the given options to each request. These options are applied after the parent client's options (if there is one), and before any request-specific options.
func (*SkillCustomService) List ¶ added in v0.18.0
func (r *SkillCustomService) List(ctx context.Context, query SkillCustomListParams, opts ...option.RequestOption) (res *SkillCustomListResponse, err error)
List all custom skills for the authenticated organization. Supports cursor-based pagination.
type SkillDeleteResponse ¶ added in v0.18.0
type SkillDeleteResponse struct {
Deleted bool `json:"deleted"`
Slug string `json:"slug"`
JSON skillDeleteResponseJSON `json:"-"`
}
func (*SkillDeleteResponse) UnmarshalJSON ¶ added in v0.18.0
func (r *SkillDeleteResponse) UnmarshalJSON(data []byte) (err error)
type SkillNewParams ¶ added in v0.18.0
type SkillNewParams struct {
// Full skill content in markdown
Content param.Field[string] `json:"content" api:"required"`
// Skill name
Name param.Field[string] `json:"name" api:"required"`
// Arbitrary metadata (author, license, etc.)
Metadata param.Field[interface{}] `json:"metadata"`
// URL-safe slug. Auto-generated from name if omitted.
Slug param.Field[string] `json:"slug"`
// Brief description (1-2 sentences)
Summary param.Field[string] `json:"summary"`
// Tags for categorization and search boosting
Tags param.Field[[]string] `json:"tags"`
}
func (SkillNewParams) MarshalJSON ¶ added in v0.18.0
func (r SkillNewParams) MarshalJSON() (data []byte, err error)
type SkillNewResponse ¶ added in v0.18.0
type SkillNewResponse struct {
Content string `json:"content"`
CreatedAt time.Time `json:"created_at" format:"date-time"`
Metadata interface{} `json:"metadata"`
Name string `json:"name"`
Slug string `json:"slug"`
Summary string `json:"summary" api:"nullable"`
Tags []string `json:"tags"`
Version int64 `json:"version"`
JSON skillNewResponseJSON `json:"-"`
}
func (*SkillNewResponse) UnmarshalJSON ¶ added in v0.18.0
func (r *SkillNewResponse) UnmarshalJSON(data []byte) (err error)
type SkillReadResponse ¶ added in v0.5.0
type SkillReadResponse struct {
// Skill author
AuthorName string `json:"author_name"`
// Skill bundle metadata for root skills and companion file rows
Bundle SkillReadResponseBundle `json:"bundle" api:"nullable"`
// Full skill content in markdown
Content string `json:"content"`
// Skill license
License string `json:"license"`
// Custom metadata (custom skills only)
Metadata interface{} `json:"metadata"`
// Skill name
Name string `json:"name"`
// Unique skill identifier
Slug string `json:"slug"`
// Skill source (authenticated requests only)
Source SkillReadResponseSource `json:"source"`
// Brief skill description
Summary string `json:"summary"`
// Skill tags
Tags []string `json:"tags"`
// Skill version
Version string `json:"version"`
JSON skillReadResponseJSON `json:"-"`
}
func (*SkillReadResponse) UnmarshalJSON ¶ added in v0.5.0
func (r *SkillReadResponse) UnmarshalJSON(data []byte) (err error)
type SkillReadResponseBundle ¶ added in v0.48.0
type SkillReadResponseBundle struct {
Role SkillReadResponseBundleRole `json:"role" api:"required"`
ContentType string `json:"content_type" api:"nullable"`
// This field can have the runtime type of [[]SkillReadResponseBundleObjectFile].
Files interface{} `json:"files"`
Path string `json:"path"`
RootSlug string `json:"root_slug"`
JSON skillReadResponseBundleJSON `json:"-"`
// contains filtered or unexported fields
}
Skill bundle metadata for root skills and companion file rows
func (SkillReadResponseBundle) AsUnion ¶ added in v0.48.0
func (r SkillReadResponseBundle) AsUnion() SkillReadResponseBundleUnion
AsUnion returns a SkillReadResponseBundleUnion interface which you can cast to the specific types for more type safety.
Possible runtime types of the union are SkillReadResponseBundleObject, SkillReadResponseBundleObject.
func (*SkillReadResponseBundle) UnmarshalJSON ¶ added in v0.48.0
func (r *SkillReadResponseBundle) UnmarshalJSON(data []byte) (err error)
type SkillReadResponseBundleObject ¶ added in v0.48.0
type SkillReadResponseBundleObject struct {
Files []SkillReadResponseBundleObjectFile `json:"files" api:"required"`
Role SkillReadResponseBundleObjectRole `json:"role" api:"required"`
JSON skillReadResponseBundleObjectJSON `json:"-"`
}
func (*SkillReadResponseBundleObject) UnmarshalJSON ¶ added in v0.48.0
func (r *SkillReadResponseBundleObject) UnmarshalJSON(data []byte) (err error)
type SkillReadResponseBundleObjectFile ¶ added in v0.48.0
type SkillReadResponseBundleObjectFile struct {
Path string `json:"path" api:"required"`
Slug string `json:"slug" api:"required"`
ContentType string `json:"content_type" api:"nullable"`
Name string `json:"name" api:"nullable"`
JSON skillReadResponseBundleObjectFileJSON `json:"-"`
}
func (*SkillReadResponseBundleObjectFile) UnmarshalJSON ¶ added in v0.48.0
func (r *SkillReadResponseBundleObjectFile) UnmarshalJSON(data []byte) (err error)
type SkillReadResponseBundleObjectRole ¶ added in v0.48.0
type SkillReadResponseBundleObjectRole string
const (
SkillReadResponseBundleObjectRoleRoot SkillReadResponseBundleObjectRole = "root"
)
func (SkillReadResponseBundleObjectRole) IsKnown ¶ added in v0.48.0
func (r SkillReadResponseBundleObjectRole) IsKnown() bool
type SkillReadResponseBundleRole ¶ added in v0.48.0
type SkillReadResponseBundleRole string
const ( SkillReadResponseBundleRoleRoot SkillReadResponseBundleRole = "root" SkillReadResponseBundleRoleFile SkillReadResponseBundleRole = "file" )
func (SkillReadResponseBundleRole) IsKnown ¶ added in v0.48.0
func (r SkillReadResponseBundleRole) IsKnown() bool
type SkillReadResponseBundleUnion ¶ added in v0.48.0
type SkillReadResponseBundleUnion interface {
// contains filtered or unexported methods
}
Skill bundle metadata for root skills and companion file rows
Union satisfied by SkillReadResponseBundleObject or SkillReadResponseBundleObject.
type SkillReadResponseSource ¶ added in v0.18.0
type SkillReadResponseSource string
Skill source (authenticated requests only)
const ( SkillReadResponseSourceCurated SkillReadResponseSource = "curated" SkillReadResponseSourceCustom SkillReadResponseSource = "custom" )
func (SkillReadResponseSource) IsKnown ¶ added in v0.18.0
func (r SkillReadResponseSource) IsKnown() bool
type SkillResolveParams ¶ added in v0.5.0
type SkillResolveParams struct {
// Search query string
Q param.Field[string] `query:"q" api:"required"`
// Maximum number of results to return (1-20)
Limit param.Field[int64] `query:"limit"`
}
func (SkillResolveParams) URLQuery ¶ added in v0.5.0
func (r SkillResolveParams) URLQuery() (v url.Values)
URLQuery serializes SkillResolveParams's query parameters as `url.Values`.
type SkillResolveResponse ¶ added in v0.5.0
type SkillResolveResponse struct {
// Search methods used (text, tag, semantic)
MethodsUsed []string `json:"methods_used"`
Results []SkillResolveResponseResult `json:"results"`
JSON skillResolveResponseJSON `json:"-"`
}
func (*SkillResolveResponse) UnmarshalJSON ¶ added in v0.5.0
func (r *SkillResolveResponse) UnmarshalJSON(data []byte) (err error)
type SkillResolveResponseResult ¶ added in v0.5.0
type SkillResolveResponseResult struct {
// Skill name
Name string `json:"name"`
// Relevance score
Score float64 `json:"score"`
// Unique skill identifier
Slug string `json:"slug"`
// Whether the skill is curated or org-custom
Source SkillResolveResponseResultsSource `json:"source"`
// Brief skill description
Summary string `json:"summary"`
// Skill tags
Tags []string `json:"tags"`
JSON skillResolveResponseResultJSON `json:"-"`
}
func (*SkillResolveResponseResult) UnmarshalJSON ¶ added in v0.5.0
func (r *SkillResolveResponseResult) UnmarshalJSON(data []byte) (err error)
type SkillResolveResponseResultsSource ¶ added in v0.18.0
type SkillResolveResponseResultsSource string
Whether the skill is curated or org-custom
const ( SkillResolveResponseResultsSourceCurated SkillResolveResponseResultsSource = "curated" SkillResolveResponseResultsSourceCustom SkillResolveResponseResultsSource = "custom" )
func (SkillResolveResponseResultsSource) IsKnown ¶ added in v0.18.0
func (r SkillResolveResponseResultsSource) IsKnown() bool
type SkillService ¶ added in v0.5.0
type SkillService struct {
Options []option.RequestOption
// Search and read legal AI skills for agents
Custom *SkillCustomService
}
Search and read legal AI skills for agents
SkillService contains methods and other services that help with interacting with the casedev API.
Note, unlike clients, this service does not read variables from the environment automatically. You should not instantiate this service directly, and instead use the NewSkillService method instead.
func NewSkillService ¶ added in v0.5.0
func NewSkillService(opts ...option.RequestOption) (r *SkillService)
NewSkillService generates a new service that applies the given options to each request. These options are applied after the parent client's options (if there is one), and before any request-specific options.
func (*SkillService) Delete ¶ added in v0.18.0
func (r *SkillService) Delete(ctx context.Context, slug string, opts ...option.RequestOption) (res *SkillDeleteResponse, err error)
Soft-delete an org-scoped custom skill by slug. The skill will no longer appear in search results.
func (*SkillService) New ¶ added in v0.18.0
func (r *SkillService) New(ctx context.Context, body SkillNewParams, opts ...option.RequestOption) (res *SkillNewResponse, err error)
Create an org-scoped custom skill. The skill will be searchable via /skills/resolve alongside curated skills.
func (*SkillService) Read ¶ added in v0.5.0
func (r *SkillService) Read(ctx context.Context, slug string, opts ...option.RequestOption) (res *SkillReadResponse, err error)
Read the full content of a legal skill by its slug. Returns markdown content, tags, and metadata.
func (*SkillService) Resolve ¶ added in v0.5.0
func (r *SkillService) Resolve(ctx context.Context, query SkillResolveParams, opts ...option.RequestOption) (res *SkillResolveResponse, err error)
Search the Legal Skills Store using hybrid search (text + tag + semantic). Returns ranked results with relevance scores.
func (*SkillService) Update ¶ added in v0.18.0
func (r *SkillService) Update(ctx context.Context, slug string, body SkillUpdateParams, opts ...option.RequestOption) (res *SkillUpdateResponse, err error)
Update an org-scoped custom skill by slug. Only provided fields are updated. Version is auto-incremented.
type SkillUpdateParams ¶ added in v0.18.0
type SkillUpdateParams struct {
Content param.Field[string] `json:"content"`
Metadata param.Field[interface{}] `json:"metadata"`
Name param.Field[string] `json:"name"`
// New slug (renames the skill)
Slug param.Field[string] `json:"slug"`
Summary param.Field[string] `json:"summary"`
Tags param.Field[[]string] `json:"tags"`
}
func (SkillUpdateParams) MarshalJSON ¶ added in v0.18.0
func (r SkillUpdateParams) MarshalJSON() (data []byte, err error)
type SkillUpdateResponse ¶ added in v0.18.0
type SkillUpdateResponse struct {
Content string `json:"content"`
Metadata interface{} `json:"metadata"`
Name string `json:"name"`
Slug string `json:"slug"`
Summary string `json:"summary" api:"nullable"`
Tags []string `json:"tags"`
UpdatedAt time.Time `json:"updated_at" format:"date-time"`
Version int64 `json:"version"`
JSON skillUpdateResponseJSON `json:"-"`
}
func (*SkillUpdateResponse) UnmarshalJSON ¶ added in v0.18.0
func (r *SkillUpdateResponse) UnmarshalJSON(data []byte) (err error)
type SuperdocService ¶
type SuperdocService struct {
Options []option.RequestOption
// Document conversion and template automation
V1 *SuperdocV1Service
}
SuperdocService contains methods and other services that help with interacting with the casedev API.
Note, unlike clients, this service does not read variables from the environment automatically. You should not instantiate this service directly, and instead use the NewSuperdocService method instead.
func NewSuperdocService ¶
func NewSuperdocService(opts ...option.RequestOption) (r *SuperdocService)
NewSuperdocService generates a new service that applies the given options to each request. These options are applied after the parent client's options (if there is one), and before any request-specific options.
type SuperdocV1AnnotateParams ¶
type SuperdocV1AnnotateParams struct {
// Document source - provide either URL or base64
Document param.Field[SuperdocV1AnnotateParamsDocument] `json:"document" api:"required"`
// Fields to populate in the template
Fields param.Field[[]SuperdocV1AnnotateParamsField] `json:"fields" api:"required"`
// Output format for the annotated document
OutputFormat param.Field[SuperdocV1AnnotateParamsOutputFormat] `json:"output_format"`
}
func (SuperdocV1AnnotateParams) MarshalJSON ¶
func (r SuperdocV1AnnotateParams) MarshalJSON() (data []byte, err error)
type SuperdocV1AnnotateParamsDocument ¶
type SuperdocV1AnnotateParamsDocument struct {
// Base64-encoded DOCX template
Base64 param.Field[string] `json:"base64"`
// URL to the DOCX template
URL param.Field[string] `json:"url"`
}
Document source - provide either URL or base64
func (SuperdocV1AnnotateParamsDocument) MarshalJSON ¶
func (r SuperdocV1AnnotateParamsDocument) MarshalJSON() (data []byte, err error)
type SuperdocV1AnnotateParamsField ¶
type SuperdocV1AnnotateParamsField struct {
// Field data type
Type param.Field[SuperdocV1AnnotateParamsFieldsType] `json:"type" api:"required"`
// Value to populate
Value param.Field[SuperdocV1AnnotateParamsFieldsValueUnion] `json:"value" api:"required"`
// Target field ID (for single field)
ID param.Field[string] `json:"id"`
// Target field group (for multiple fields with same tag)
Group param.Field[string] `json:"group"`
// Optional configuration (e.g., image dimensions)
Options param.Field[SuperdocV1AnnotateParamsFieldsOptions] `json:"options"`
}
func (SuperdocV1AnnotateParamsField) MarshalJSON ¶
func (r SuperdocV1AnnotateParamsField) MarshalJSON() (data []byte, err error)
type SuperdocV1AnnotateParamsFieldsOptions ¶
type SuperdocV1AnnotateParamsFieldsOptions struct {
// Image height in pixels
Height param.Field[float64] `json:"height"`
// Image width in pixels
Width param.Field[float64] `json:"width"`
}
Optional configuration (e.g., image dimensions)
func (SuperdocV1AnnotateParamsFieldsOptions) MarshalJSON ¶
func (r SuperdocV1AnnotateParamsFieldsOptions) MarshalJSON() (data []byte, err error)
type SuperdocV1AnnotateParamsFieldsType ¶
type SuperdocV1AnnotateParamsFieldsType string
Field data type
const ( SuperdocV1AnnotateParamsFieldsTypeText SuperdocV1AnnotateParamsFieldsType = "text" SuperdocV1AnnotateParamsFieldsTypeImage SuperdocV1AnnotateParamsFieldsType = "image" SuperdocV1AnnotateParamsFieldsTypeDate SuperdocV1AnnotateParamsFieldsType = "date" SuperdocV1AnnotateParamsFieldsTypeNumber SuperdocV1AnnotateParamsFieldsType = "number" )
func (SuperdocV1AnnotateParamsFieldsType) IsKnown ¶
func (r SuperdocV1AnnotateParamsFieldsType) IsKnown() bool
type SuperdocV1AnnotateParamsFieldsValueUnion ¶
type SuperdocV1AnnotateParamsFieldsValueUnion interface {
ImplementsSuperdocV1AnnotateParamsFieldsValueUnion()
}
Value to populate
Satisfied by [shared.UnionString], [shared.UnionFloat].
type SuperdocV1AnnotateParamsOutputFormat ¶
type SuperdocV1AnnotateParamsOutputFormat string
Output format for the annotated document
const ( SuperdocV1AnnotateParamsOutputFormatDocx SuperdocV1AnnotateParamsOutputFormat = "docx" SuperdocV1AnnotateParamsOutputFormatPdf SuperdocV1AnnotateParamsOutputFormat = "pdf" )
func (SuperdocV1AnnotateParamsOutputFormat) IsKnown ¶
func (r SuperdocV1AnnotateParamsOutputFormat) IsKnown() bool
type SuperdocV1ConvertParams ¶
type SuperdocV1ConvertParams struct {
// Source format of the document
From param.Field[SuperdocV1ConvertParamsFrom] `json:"from" api:"required"`
// Base64-encoded document content
DocumentBase64 param.Field[string] `json:"document_base64"`
// URL to the document to convert
DocumentURL param.Field[string] `json:"document_url"`
// Target format for conversion
To param.Field[SuperdocV1ConvertParamsTo] `json:"to"`
}
func (SuperdocV1ConvertParams) MarshalJSON ¶
func (r SuperdocV1ConvertParams) MarshalJSON() (data []byte, err error)
type SuperdocV1ConvertParamsFrom ¶
type SuperdocV1ConvertParamsFrom string
Source format of the document
const ( SuperdocV1ConvertParamsFromDocx SuperdocV1ConvertParamsFrom = "docx" SuperdocV1ConvertParamsFromMd SuperdocV1ConvertParamsFrom = "md" SuperdocV1ConvertParamsFromHTML SuperdocV1ConvertParamsFrom = "html" )
func (SuperdocV1ConvertParamsFrom) IsKnown ¶
func (r SuperdocV1ConvertParamsFrom) IsKnown() bool
type SuperdocV1ConvertParamsTo ¶
type SuperdocV1ConvertParamsTo string
Target format for conversion
const ( SuperdocV1ConvertParamsToPdf SuperdocV1ConvertParamsTo = "pdf" SuperdocV1ConvertParamsToDocx SuperdocV1ConvertParamsTo = "docx" )
func (SuperdocV1ConvertParamsTo) IsKnown ¶
func (r SuperdocV1ConvertParamsTo) IsKnown() bool
type SuperdocV1Service ¶
type SuperdocV1Service struct {
Options []option.RequestOption
}
Document conversion and template automation
SuperdocV1Service contains methods and other services that help with interacting with the casedev API.
Note, unlike clients, this service does not read variables from the environment automatically. You should not instantiate this service directly, and instead use the NewSuperdocV1Service method instead.
func NewSuperdocV1Service ¶
func NewSuperdocV1Service(opts ...option.RequestOption) (r *SuperdocV1Service)
NewSuperdocV1Service generates a new service that applies the given options to each request. These options are applied after the parent client's options (if there is one), and before any request-specific options.
func (*SuperdocV1Service) Annotate ¶
func (r *SuperdocV1Service) Annotate(ctx context.Context, body SuperdocV1AnnotateParams, opts ...option.RequestOption) (res *http.Response, err error)
Populate fields inside a DOCX template using SuperDoc annotations. Supports text, images, dates, and numbers. Can target individual fields by ID or multiple fields by group.
func (*SuperdocV1Service) Convert ¶
func (r *SuperdocV1Service) Convert(ctx context.Context, body SuperdocV1ConvertParams, opts ...option.RequestOption) (res *http.Response, err error)
Convert documents between formats using SuperDoc. Supports DOCX to PDF, Markdown to DOCX, and HTML to DOCX conversions.
type SystemListServicesResponse ¶
type SystemListServicesResponse struct {
Services []SystemListServicesResponseService `json:"services" api:"required"`
JSON systemListServicesResponseJSON `json:"-"`
}
func (*SystemListServicesResponse) UnmarshalJSON ¶
func (r *SystemListServicesResponse) UnmarshalJSON(data []byte) (err error)
type SystemListServicesResponseService ¶
type SystemListServicesResponseService struct {
ID string `json:"id" api:"required"`
Description string `json:"description" api:"required"`
Href string `json:"href" api:"required"`
Icon string `json:"icon" api:"required"`
Name string `json:"name" api:"required"`
Order int64 `json:"order" api:"required"`
JSON systemListServicesResponseServiceJSON `json:"-"`
}
func (*SystemListServicesResponseService) UnmarshalJSON ¶
func (r *SystemListServicesResponseService) UnmarshalJSON(data []byte) (err error)
type SystemService ¶
type SystemService struct {
Options []option.RequestOption
}
Public system metadata and discovery endpoints
SystemService contains methods and other services that help with interacting with the casedev API.
Note, unlike clients, this service does not read variables from the environment automatically. You should not instantiate this service directly, and instead use the NewSystemService method instead.
func NewSystemService ¶
func NewSystemService(opts ...option.RequestOption) (r *SystemService)
NewSystemService generates a new service that applies the given options to each request. These options are applied after the parent client's options (if there is one), and before any request-specific options.
func (*SystemService) ListServices ¶
func (r *SystemService) ListServices(ctx context.Context, opts ...option.RequestOption) (res *SystemListServicesResponse, err error)
Returns the public Case.dev services catalog derived from docs.case.dev/services. This endpoint is unauthenticated and intended for discovery surfaces such as the case.dev homepage.
type TranslateService ¶
type TranslateService struct {
Options []option.RequestOption
V1 *TranslateV1Service
}
TranslateService contains methods and other services that help with interacting with the casedev API.
Note, unlike clients, this service does not read variables from the environment automatically. You should not instantiate this service directly, and instead use the NewTranslateService method instead.
func NewTranslateService ¶
func NewTranslateService(opts ...option.RequestOption) (r *TranslateService)
NewTranslateService generates a new service that applies the given options to each request. These options are applied after the parent client's options (if there is one), and before any request-specific options.
type TranslateV1DetectParams ¶
type TranslateV1DetectParams struct {
// Text to detect language for. Can be a single string or an array for batch
// detection.
Q param.Field[TranslateV1DetectParamsQUnion] `json:"q" api:"required"`
}
func (TranslateV1DetectParams) MarshalJSON ¶
func (r TranslateV1DetectParams) MarshalJSON() (data []byte, err error)
type TranslateV1DetectParamsQArray ¶
type TranslateV1DetectParamsQArray []string
func (TranslateV1DetectParamsQArray) ImplementsTranslateV1DetectParamsQUnion ¶
func (r TranslateV1DetectParamsQArray) ImplementsTranslateV1DetectParamsQUnion()
type TranslateV1DetectParamsQUnion ¶
type TranslateV1DetectParamsQUnion interface {
ImplementsTranslateV1DetectParamsQUnion()
}
Text to detect language for. Can be a single string or an array for batch detection.
Satisfied by [shared.UnionString], TranslateV1DetectParamsQArray.
type TranslateV1DetectResponse ¶
type TranslateV1DetectResponse struct {
Data TranslateV1DetectResponseData `json:"data"`
JSON translateV1DetectResponseJSON `json:"-"`
}
func (*TranslateV1DetectResponse) UnmarshalJSON ¶
func (r *TranslateV1DetectResponse) UnmarshalJSON(data []byte) (err error)
type TranslateV1DetectResponseData ¶
type TranslateV1DetectResponseData struct {
Detections [][]TranslateV1DetectResponseDataDetection `json:"detections"`
JSON translateV1DetectResponseDataJSON `json:"-"`
}
func (*TranslateV1DetectResponseData) UnmarshalJSON ¶
func (r *TranslateV1DetectResponseData) UnmarshalJSON(data []byte) (err error)
type TranslateV1DetectResponseDataDetection ¶
type TranslateV1DetectResponseDataDetection struct {
// Confidence score (0-1)
Confidence float64 `json:"confidence"`
// Whether the detection is reliable
IsReliable bool `json:"isReliable"`
// Detected language code (ISO 639-1)
Language string `json:"language"`
JSON translateV1DetectResponseDataDetectionJSON `json:"-"`
}
func (*TranslateV1DetectResponseDataDetection) UnmarshalJSON ¶
func (r *TranslateV1DetectResponseDataDetection) UnmarshalJSON(data []byte) (err error)
type TranslateV1ListLanguagesParams ¶
type TranslateV1ListLanguagesParams struct {
// Translation model to check language support for
Model param.Field[TranslateV1ListLanguagesParamsModel] `query:"model"`
// Target language code for translating language names (e.g., 'es' for Spanish
// names)
Target param.Field[string] `query:"target"`
}
func (TranslateV1ListLanguagesParams) URLQuery ¶
func (r TranslateV1ListLanguagesParams) URLQuery() (v url.Values)
URLQuery serializes TranslateV1ListLanguagesParams's query parameters as `url.Values`.
type TranslateV1ListLanguagesParamsModel ¶
type TranslateV1ListLanguagesParamsModel string
Translation model to check language support for
const ( TranslateV1ListLanguagesParamsModelNmt TranslateV1ListLanguagesParamsModel = "nmt" TranslateV1ListLanguagesParamsModelBase TranslateV1ListLanguagesParamsModel = "base" )
func (TranslateV1ListLanguagesParamsModel) IsKnown ¶
func (r TranslateV1ListLanguagesParamsModel) IsKnown() bool
type TranslateV1ListLanguagesResponse ¶
type TranslateV1ListLanguagesResponse struct {
Data TranslateV1ListLanguagesResponseData `json:"data"`
JSON translateV1ListLanguagesResponseJSON `json:"-"`
}
func (*TranslateV1ListLanguagesResponse) UnmarshalJSON ¶
func (r *TranslateV1ListLanguagesResponse) UnmarshalJSON(data []byte) (err error)
type TranslateV1ListLanguagesResponseData ¶
type TranslateV1ListLanguagesResponseData struct {
Languages []TranslateV1ListLanguagesResponseDataLanguage `json:"languages"`
JSON translateV1ListLanguagesResponseDataJSON `json:"-"`
}
func (*TranslateV1ListLanguagesResponseData) UnmarshalJSON ¶
func (r *TranslateV1ListLanguagesResponseData) UnmarshalJSON(data []byte) (err error)
type TranslateV1ListLanguagesResponseDataLanguage ¶
type TranslateV1ListLanguagesResponseDataLanguage struct {
// Language code (ISO 639-1)
Language string `json:"language"`
// Language name (if target specified)
Name string `json:"name"`
JSON translateV1ListLanguagesResponseDataLanguageJSON `json:"-"`
}
func (*TranslateV1ListLanguagesResponseDataLanguage) UnmarshalJSON ¶
func (r *TranslateV1ListLanguagesResponseDataLanguage) UnmarshalJSON(data []byte) (err error)
type TranslateV1Service ¶
type TranslateV1Service struct {
Options []option.RequestOption
}
TranslateV1Service contains methods and other services that help with interacting with the casedev API.
Note, unlike clients, this service does not read variables from the environment automatically. You should not instantiate this service directly, and instead use the NewTranslateV1Service method instead.
func NewTranslateV1Service ¶
func NewTranslateV1Service(opts ...option.RequestOption) (r *TranslateV1Service)
NewTranslateV1Service generates a new service that applies the given options to each request. These options are applied after the parent client's options (if there is one), and before any request-specific options.
func (*TranslateV1Service) Detect ¶
func (r *TranslateV1Service) Detect(ctx context.Context, body TranslateV1DetectParams, opts ...option.RequestOption) (res *TranslateV1DetectResponse, err error)
Detect the language of text. Returns the most likely language code and confidence score. Supports batch detection for multiple texts.
func (*TranslateV1Service) ListLanguages ¶
func (r *TranslateV1Service) ListLanguages(ctx context.Context, query TranslateV1ListLanguagesParams, opts ...option.RequestOption) (res *TranslateV1ListLanguagesResponse, err error)
Get the list of languages supported for translation. Optionally specify a target language to get translated language names.
func (*TranslateV1Service) Translate ¶
func (r *TranslateV1Service) Translate(ctx context.Context, body TranslateV1TranslateParams, opts ...option.RequestOption) (res *TranslateV1TranslateResponse, err error)
Translate text between languages using Google Cloud Translation API. Supports 100+ languages, automatic language detection, HTML preservation, and batch translation.
type TranslateV1TranslateParams ¶
type TranslateV1TranslateParams struct {
// Text to translate. Can be a single string or an array for batch translation.
Q param.Field[TranslateV1TranslateParamsQUnion] `json:"q" api:"required"`
// Target language code (ISO 639-1)
Target param.Field[string] `json:"target" api:"required"`
// Format of the source text. Use 'html' to preserve HTML tags.
Format param.Field[TranslateV1TranslateParamsFormat] `json:"format"`
// Translation model. 'nmt' (Neural Machine Translation) is recommended for
// quality.
Model param.Field[TranslateV1TranslateParamsModel] `json:"model"`
// Source language code (ISO 639-1). If not specified, language is auto-detected.
Source param.Field[string] `json:"source"`
}
func (TranslateV1TranslateParams) MarshalJSON ¶
func (r TranslateV1TranslateParams) MarshalJSON() (data []byte, err error)
type TranslateV1TranslateParamsFormat ¶
type TranslateV1TranslateParamsFormat string
Format of the source text. Use 'html' to preserve HTML tags.
const ( TranslateV1TranslateParamsFormatText TranslateV1TranslateParamsFormat = "text" TranslateV1TranslateParamsFormatHTML TranslateV1TranslateParamsFormat = "html" )
func (TranslateV1TranslateParamsFormat) IsKnown ¶
func (r TranslateV1TranslateParamsFormat) IsKnown() bool
type TranslateV1TranslateParamsModel ¶
type TranslateV1TranslateParamsModel string
Translation model. 'nmt' (Neural Machine Translation) is recommended for quality.
const ( TranslateV1TranslateParamsModelNmt TranslateV1TranslateParamsModel = "nmt" TranslateV1TranslateParamsModelBase TranslateV1TranslateParamsModel = "base" )
func (TranslateV1TranslateParamsModel) IsKnown ¶
func (r TranslateV1TranslateParamsModel) IsKnown() bool
type TranslateV1TranslateParamsQArray ¶
type TranslateV1TranslateParamsQArray []string
func (TranslateV1TranslateParamsQArray) ImplementsTranslateV1TranslateParamsQUnion ¶
func (r TranslateV1TranslateParamsQArray) ImplementsTranslateV1TranslateParamsQUnion()
type TranslateV1TranslateParamsQUnion ¶
type TranslateV1TranslateParamsQUnion interface {
ImplementsTranslateV1TranslateParamsQUnion()
}
Text to translate. Can be a single string or an array for batch translation.
Satisfied by [shared.UnionString], TranslateV1TranslateParamsQArray.
type TranslateV1TranslateResponse ¶
type TranslateV1TranslateResponse struct {
Data TranslateV1TranslateResponseData `json:"data"`
JSON translateV1TranslateResponseJSON `json:"-"`
}
func (*TranslateV1TranslateResponse) UnmarshalJSON ¶
func (r *TranslateV1TranslateResponse) UnmarshalJSON(data []byte) (err error)
type TranslateV1TranslateResponseData ¶
type TranslateV1TranslateResponseData struct {
Translations []TranslateV1TranslateResponseDataTranslation `json:"translations"`
JSON translateV1TranslateResponseDataJSON `json:"-"`
}
func (*TranslateV1TranslateResponseData) UnmarshalJSON ¶
func (r *TranslateV1TranslateResponseData) UnmarshalJSON(data []byte) (err error)
type TranslateV1TranslateResponseDataTranslation ¶
type TranslateV1TranslateResponseDataTranslation struct {
// Detected source language (if source not specified)
DetectedSourceLanguage string `json:"detectedSourceLanguage"`
// Model used for translation
Model string `json:"model"`
// Translated text
TranslatedText string `json:"translatedText"`
JSON translateV1TranslateResponseDataTranslationJSON `json:"-"`
}
func (*TranslateV1TranslateResponseDataTranslation) UnmarshalJSON ¶
func (r *TranslateV1TranslateResponseDataTranslation) UnmarshalJSON(data []byte) (err error)
type UsageService ¶ added in v0.29.0
type UsageService struct {
Options []option.RequestOption
// Usage reporting and webhook subscriptions
V1 *UsageV1Service
}
UsageService contains methods and other services that help with interacting with the casedev API.
Note, unlike clients, this service does not read variables from the environment automatically. You should not instantiate this service directly, and instead use the NewUsageService method instead.
func NewUsageService ¶ added in v0.29.0
func NewUsageService(opts ...option.RequestOption) (r *UsageService)
NewUsageService generates a new service that applies the given options to each request. These options are applied after the parent client's options (if there is one), and before any request-specific options.
type UsageV1GetParams ¶ added in v0.29.0
type UsageV1GetParams struct {
// Whether to return period totals only or include daily buckets.
Granularity param.Field[UsageV1GetParamsGranularity] `query:"granularity"`
// Period end date. Defaults to now.
PeriodEnd param.Field[time.Time] `query:"periodEnd" format:"date-time"`
// Period start date. Defaults to the start of the current calendar month.
PeriodStart param.Field[time.Time] `query:"periodStart" format:"date-time"`
}
func (UsageV1GetParams) URLQuery ¶ added in v0.29.0
func (r UsageV1GetParams) URLQuery() (v url.Values)
URLQuery serializes UsageV1GetParams's query parameters as `url.Values`.
type UsageV1GetParamsGranularity ¶ added in v0.29.0
type UsageV1GetParamsGranularity string
Whether to return period totals only or include daily buckets.
const ( UsageV1GetParamsGranularitySummary UsageV1GetParamsGranularity = "summary" UsageV1GetParamsGranularityDaily UsageV1GetParamsGranularity = "daily" )
func (UsageV1GetParamsGranularity) IsKnown ¶ added in v0.29.0
func (r UsageV1GetParamsGranularity) IsKnown() bool
type UsageV1Service ¶ added in v0.29.0
type UsageV1Service struct {
Options []option.RequestOption
// Usage reporting and webhook subscriptions
Subscriptions *UsageV1SubscriptionService
}
Usage reporting and webhook subscriptions
UsageV1Service contains methods and other services that help with interacting with the casedev API.
Note, unlike clients, this service does not read variables from the environment automatically. You should not instantiate this service directly, and instead use the NewUsageV1Service method instead.
func NewUsageV1Service ¶ added in v0.29.0
func NewUsageV1Service(opts ...option.RequestOption) (r *UsageV1Service)
NewUsageV1Service generates a new service that applies the given options to each request. These options are applied after the parent client's options (if there is one), and before any request-specific options.
func (*UsageV1Service) Get ¶ added in v0.29.0
func (r *UsageV1Service) Get(ctx context.Context, query UsageV1GetParams, opts ...option.RequestOption) (err error)
Returns customer-facing usage metrics and costs for the requested period. Supports summary totals and daily buckets for timestamped usage sources. Vault storage is intentionally omitted from totals because it is not yet periodized for arbitrary windows.
type UsageV1SubscriptionNewParams ¶ added in v0.29.0
type UsageV1SubscriptionNewParams struct {
CallbackURL param.Field[string] `json:"callbackUrl" api:"required" format:"uri"`
EventTypes param.Field[[]string] `json:"eventTypes"`
SigningSecret param.Field[string] `json:"signingSecret"`
}
func (UsageV1SubscriptionNewParams) MarshalJSON ¶ added in v0.29.0
func (r UsageV1SubscriptionNewParams) MarshalJSON() (data []byte, err error)
type UsageV1SubscriptionService ¶ added in v0.29.0
type UsageV1SubscriptionService struct {
Options []option.RequestOption
}
Usage reporting and webhook subscriptions
UsageV1SubscriptionService contains methods and other services that help with interacting with the casedev API.
Note, unlike clients, this service does not read variables from the environment automatically. You should not instantiate this service directly, and instead use the NewUsageV1SubscriptionService method instead.
func NewUsageV1SubscriptionService ¶ added in v0.29.0
func NewUsageV1SubscriptionService(opts ...option.RequestOption) (r *UsageV1SubscriptionService)
NewUsageV1SubscriptionService generates a new service that applies the given options to each request. These options are applied after the parent client's options (if there is one), and before any request-specific options.
func (*UsageV1SubscriptionService) Delete ¶ added in v0.29.0
func (r *UsageV1SubscriptionService) Delete(ctx context.Context, subscriptionID string, opts ...option.RequestOption) (err error)
Deactivates a usage webhook subscription.
func (*UsageV1SubscriptionService) List ¶ added in v0.29.0
func (r *UsageV1SubscriptionService) List(ctx context.Context, opts ...option.RequestOption) (err error)
Lists webhook subscriptions configured for usage and billing events.
func (*UsageV1SubscriptionService) New ¶ added in v0.29.0
func (r *UsageV1SubscriptionService) New(ctx context.Context, body UsageV1SubscriptionNewParams, opts ...option.RequestOption) (err error)
Creates a webhook subscription for usage, balance, and billing events.
func (*UsageV1SubscriptionService) Test ¶ added in v0.29.0
func (r *UsageV1SubscriptionService) Test(ctx context.Context, subscriptionID string, body UsageV1SubscriptionTestParams, opts ...option.RequestOption) (err error)
Delivers a test event to a single usage webhook subscription using the same payload shape and signing behavior as production delivery.
func (*UsageV1SubscriptionService) Update ¶ added in v0.29.0
func (r *UsageV1SubscriptionService) Update(ctx context.Context, subscriptionID string, body UsageV1SubscriptionUpdateParams, opts ...option.RequestOption) (err error)
Updates callback URL, event filters, active state, or signing secret.
type UsageV1SubscriptionTestParams ¶ added in v0.29.0
type UsageV1SubscriptionTestParams struct {
EventType param.Field[string] `json:"eventType"`
Payload param.Field[map[string]interface{}] `json:"payload"`
}
func (UsageV1SubscriptionTestParams) MarshalJSON ¶ added in v0.29.0
func (r UsageV1SubscriptionTestParams) MarshalJSON() (data []byte, err error)
type UsageV1SubscriptionUpdateParams ¶ added in v0.29.0
type UsageV1SubscriptionUpdateParams struct {
CallbackURL param.Field[string] `json:"callbackUrl" format:"uri"`
ClearSigningSecret param.Field[bool] `json:"clearSigningSecret"`
EventTypes param.Field[[]string] `json:"eventTypes"`
IsActive param.Field[bool] `json:"isActive"`
SigningSecret param.Field[string] `json:"signingSecret"`
}
func (UsageV1SubscriptionUpdateParams) MarshalJSON ¶ added in v0.29.0
func (r UsageV1SubscriptionUpdateParams) MarshalJSON() (data []byte, err error)
type VaultConfirmUploadParams ¶
type VaultConfirmUploadParams struct {
Body VaultConfirmUploadParamsBodyUnion `json:"body" api:"required"`
}
func (VaultConfirmUploadParams) MarshalJSON ¶
func (r VaultConfirmUploadParams) MarshalJSON() (data []byte, err error)
type VaultConfirmUploadParamsBody ¶
type VaultConfirmUploadParamsBody struct {
// Whether the upload succeeded
Success param.Field[VaultConfirmUploadParamsBodySuccess] `json:"success" api:"required"`
// Client-side error code
ErrorCode param.Field[string] `json:"errorCode"`
// Client-side error message
ErrorMessage param.Field[string] `json:"errorMessage"`
// S3 ETag for the uploaded object (optional if client cannot access ETag header)
Etag param.Field[string] `json:"etag"`
// Uploaded file size in bytes
SizeBytes param.Field[int64] `json:"sizeBytes"`
}
func (VaultConfirmUploadParamsBody) MarshalJSON ¶
func (r VaultConfirmUploadParamsBody) MarshalJSON() (data []byte, err error)
type VaultConfirmUploadParamsBodySuccess ¶
type VaultConfirmUploadParamsBodySuccess bool
Whether the upload succeeded
const ( VaultConfirmUploadParamsBodySuccessTrue VaultConfirmUploadParamsBodySuccess = true VaultConfirmUploadParamsBodySuccessFalse VaultConfirmUploadParamsBodySuccess = false )
func (VaultConfirmUploadParamsBodySuccess) IsKnown ¶
func (r VaultConfirmUploadParamsBodySuccess) IsKnown() bool
type VaultConfirmUploadParamsBodyUnion ¶
type VaultConfirmUploadParamsBodyUnion interface {
// contains filtered or unexported methods
}
Satisfied by VaultConfirmUploadParamsBodyVaultConfirmUploadSuccess, VaultConfirmUploadParamsBodyVaultConfirmUploadFailure, VaultConfirmUploadParamsBody.
type VaultConfirmUploadParamsBodyVaultConfirmUploadFailure ¶
type VaultConfirmUploadParamsBodyVaultConfirmUploadFailure struct {
// Client-side error code
ErrorCode param.Field[string] `json:"errorCode" api:"required"`
// Client-side error message
ErrorMessage param.Field[string] `json:"errorMessage" api:"required"`
// Whether the upload succeeded
Success param.Field[VaultConfirmUploadParamsBodyVaultConfirmUploadFailureSuccess] `json:"success" api:"required"`
}
func (VaultConfirmUploadParamsBodyVaultConfirmUploadFailure) MarshalJSON ¶
func (r VaultConfirmUploadParamsBodyVaultConfirmUploadFailure) MarshalJSON() (data []byte, err error)
type VaultConfirmUploadParamsBodyVaultConfirmUploadFailureSuccess ¶
type VaultConfirmUploadParamsBodyVaultConfirmUploadFailureSuccess bool
Whether the upload succeeded
const (
VaultConfirmUploadParamsBodyVaultConfirmUploadFailureSuccessFalse VaultConfirmUploadParamsBodyVaultConfirmUploadFailureSuccess = false
)
func (VaultConfirmUploadParamsBodyVaultConfirmUploadFailureSuccess) IsKnown ¶
func (r VaultConfirmUploadParamsBodyVaultConfirmUploadFailureSuccess) IsKnown() bool
type VaultConfirmUploadParamsBodyVaultConfirmUploadSuccess ¶
type VaultConfirmUploadParamsBodyVaultConfirmUploadSuccess struct {
// Uploaded file size in bytes
SizeBytes param.Field[int64] `json:"sizeBytes" api:"required"`
// Whether the upload succeeded
Success param.Field[VaultConfirmUploadParamsBodyVaultConfirmUploadSuccessSuccess] `json:"success" api:"required"`
// S3 ETag for the uploaded object (optional if client cannot access ETag header)
Etag param.Field[string] `json:"etag"`
}
func (VaultConfirmUploadParamsBodyVaultConfirmUploadSuccess) MarshalJSON ¶
func (r VaultConfirmUploadParamsBodyVaultConfirmUploadSuccess) MarshalJSON() (data []byte, err error)
type VaultConfirmUploadParamsBodyVaultConfirmUploadSuccessSuccess ¶
type VaultConfirmUploadParamsBodyVaultConfirmUploadSuccessSuccess bool
Whether the upload succeeded
const (
VaultConfirmUploadParamsBodyVaultConfirmUploadSuccessSuccessTrue VaultConfirmUploadParamsBodyVaultConfirmUploadSuccessSuccess = true
)
func (VaultConfirmUploadParamsBodyVaultConfirmUploadSuccessSuccess) IsKnown ¶
func (r VaultConfirmUploadParamsBodyVaultConfirmUploadSuccessSuccess) IsKnown() bool
type VaultConfirmUploadResponse ¶
type VaultConfirmUploadResponse struct {
AlreadyConfirmed bool `json:"alreadyConfirmed"`
ObjectID string `json:"objectId"`
Status VaultConfirmUploadResponseStatus `json:"status"`
VaultID string `json:"vaultId"`
JSON vaultConfirmUploadResponseJSON `json:"-"`
}
func (*VaultConfirmUploadResponse) UnmarshalJSON ¶
func (r *VaultConfirmUploadResponse) UnmarshalJSON(data []byte) (err error)
type VaultConfirmUploadResponseStatus ¶
type VaultConfirmUploadResponseStatus string
const ( VaultConfirmUploadResponseStatusCompleted VaultConfirmUploadResponseStatus = "completed" VaultConfirmUploadResponseStatusFailed VaultConfirmUploadResponseStatus = "failed" )
func (VaultConfirmUploadResponseStatus) IsKnown ¶
func (r VaultConfirmUploadResponseStatus) IsKnown() bool
type VaultDeleteParams ¶
type VaultDeleteParams struct {
// If true and vault has many objects, queue deletion in background and return
// immediately
Async param.Field[bool] `query:"async"`
}
func (VaultDeleteParams) URLQuery ¶
func (r VaultDeleteParams) URLQuery() (v url.Values)
URLQuery serializes VaultDeleteParams's query parameters as `url.Values`.
type VaultDeleteResponse ¶
type VaultDeleteResponse struct {
DeletedVault VaultDeleteResponseDeletedVault `json:"deletedVault"`
// Either 'deleted' or 'deletion_queued'
Status string `json:"status"`
Success bool `json:"success"`
JSON vaultDeleteResponseJSON `json:"-"`
}
func (*VaultDeleteResponse) UnmarshalJSON ¶
func (r *VaultDeleteResponse) UnmarshalJSON(data []byte) (err error)
type VaultDeleteResponseDeletedVault ¶
type VaultDeleteResponseDeletedVault struct {
ID string `json:"id"`
BytesFreed int64 `json:"bytesFreed"`
Name string `json:"name"`
ObjectsDeleted int64 `json:"objectsDeleted"`
VectorsDeleted int64 `json:"vectorsDeleted"`
JSON vaultDeleteResponseDeletedVaultJSON `json:"-"`
}
func (*VaultDeleteResponseDeletedVault) UnmarshalJSON ¶
func (r *VaultDeleteResponseDeletedVault) UnmarshalJSON(data []byte) (err error)
type VaultEventService ¶
type VaultEventService struct {
Options []option.RequestOption
// Secure document storage with semantic search and GraphRAG
Subscriptions *VaultEventSubscriptionService
}
VaultEventService contains methods and other services that help with interacting with the casedev API.
Note, unlike clients, this service does not read variables from the environment automatically. You should not instantiate this service directly, and instead use the NewVaultEventService method instead.
func NewVaultEventService ¶
func NewVaultEventService(opts ...option.RequestOption) (r *VaultEventService)
NewVaultEventService generates a new service that applies the given options to each request. These options are applied after the parent client's options (if there is one), and before any request-specific options.
type VaultEventSubscriptionNewParams ¶
type VaultEventSubscriptionNewParams struct {
// Webhook endpoint URL that will receive vault event deliveries
CallbackURL param.Field[string] `json:"callbackUrl" api:"required" format:"uri"`
// Vault event types to deliver. Omit to receive the default supported set.
EventTypes param.Field[[]string] `json:"eventTypes"`
// Vault object IDs to limit notifications to. Omit to receive events for all
// objects in the vault.
ObjectIDs param.Field[[]string] `json:"objectIds"`
// Optional secret used to sign outbound webhook deliveries
SigningSecret param.Field[string] `json:"signingSecret"`
}
func (VaultEventSubscriptionNewParams) MarshalJSON ¶
func (r VaultEventSubscriptionNewParams) MarshalJSON() (data []byte, err error)
type VaultEventSubscriptionService ¶
type VaultEventSubscriptionService struct {
Options []option.RequestOption
}
Secure document storage with semantic search and GraphRAG
VaultEventSubscriptionService contains methods and other services that help with interacting with the casedev API.
Note, unlike clients, this service does not read variables from the environment automatically. You should not instantiate this service directly, and instead use the NewVaultEventSubscriptionService method instead.
func NewVaultEventSubscriptionService ¶
func NewVaultEventSubscriptionService(opts ...option.RequestOption) (r *VaultEventSubscriptionService)
NewVaultEventSubscriptionService generates a new service that applies the given options to each request. These options are applied after the parent client's options (if there is one), and before any request-specific options.
func (*VaultEventSubscriptionService) Delete ¶
func (r *VaultEventSubscriptionService) Delete(ctx context.Context, id string, subscriptionID string, opts ...option.RequestOption) (err error)
Deactivates a vault webhook subscription.
func (*VaultEventSubscriptionService) List ¶
func (r *VaultEventSubscriptionService) List(ctx context.Context, id string, opts ...option.RequestOption) (err error)
Lists webhook subscriptions configured for a vault.
func (*VaultEventSubscriptionService) New ¶
func (r *VaultEventSubscriptionService) New(ctx context.Context, id string, body VaultEventSubscriptionNewParams, opts ...option.RequestOption) (err error)
Creates a webhook subscription for vault lifecycle events. Optional object filters can limit notifications to specific vault objects.
func (*VaultEventSubscriptionService) Test ¶
func (r *VaultEventSubscriptionService) Test(ctx context.Context, id string, subscriptionID string, body VaultEventSubscriptionTestParams, opts ...option.RequestOption) (err error)
Delivers a test event to a single vault webhook subscription. Uses the same payload shape, signature, and retry behavior as production event delivery.
func (*VaultEventSubscriptionService) Update ¶
func (r *VaultEventSubscriptionService) Update(ctx context.Context, id string, subscriptionID string, body VaultEventSubscriptionUpdateParams, opts ...option.RequestOption) (err error)
Updates callback URL, filters, active state, or signing secret for a vault webhook subscription.
type VaultEventSubscriptionTestParams ¶
type VaultEventSubscriptionTestParams struct {
// Optional event type override for this test
EventType param.Field[string] `json:"eventType"`
// Optional object ID for object-scoped payload testing
ObjectID param.Field[string] `json:"objectId"`
// Optional additional fields merged into payload.data
Payload param.Field[map[string]interface{}] `json:"payload"`
}
func (VaultEventSubscriptionTestParams) MarshalJSON ¶
func (r VaultEventSubscriptionTestParams) MarshalJSON() (data []byte, err error)
type VaultEventSubscriptionUpdateParams ¶
type VaultEventSubscriptionUpdateParams struct {
// Updated webhook endpoint URL for deliveries
CallbackURL param.Field[string] `json:"callbackUrl" format:"uri"`
// Whether to remove the existing signing secret
ClearSigningSecret param.Field[bool] `json:"clearSigningSecret"`
// Updated event types to deliver for this subscription
EventTypes param.Field[[]string] `json:"eventTypes"`
// Whether the subscription should continue delivering events
IsActive param.Field[bool] `json:"isActive"`
// Updated vault object IDs to limit notifications to. Pass an empty array to
// remove the filter.
ObjectIDs param.Field[[]string] `json:"objectIds"`
// Replacement secret used to sign webhook deliveries
SigningSecret param.Field[string] `json:"signingSecret"`
}
func (VaultEventSubscriptionUpdateParams) MarshalJSON ¶
func (r VaultEventSubscriptionUpdateParams) MarshalJSON() (data []byte, err error)
type VaultGetResponse ¶
type VaultGetResponse struct {
// Vault identifier
ID string `json:"id" api:"required"`
// Vault creation timestamp
CreatedAt time.Time `json:"createdAt" api:"required" format:"date-time"`
// S3 bucket for document storage
FilesBucket string `json:"filesBucket" api:"required"`
// Vault name
Name string `json:"name" api:"required"`
// AWS region
Region string `json:"region" api:"required"`
// Document chunking strategy configuration
ChunkStrategy VaultGetResponseChunkStrategy `json:"chunkStrategy"`
// Vault description
Description string `json:"description"`
// Whether GraphRAG is enabled
EnableGraph bool `json:"enableGraph"`
// Search index name
IndexName string `json:"indexName"`
// KMS key for encryption
KmsKeyID string `json:"kmsKeyId"`
// Additional vault metadata
Metadata interface{} `json:"metadata"`
// Total storage size in bytes
TotalBytes int64 `json:"totalBytes"`
// Number of stored documents
TotalObjects int64 `json:"totalObjects"`
// Number of vector embeddings
TotalVectors int64 `json:"totalVectors"`
// Last update timestamp
UpdatedAt time.Time `json:"updatedAt" format:"date-time"`
// S3 bucket for vector embeddings
VectorBucket string `json:"vectorBucket" api:"nullable"`
JSON vaultGetResponseJSON `json:"-"`
}
func (*VaultGetResponse) UnmarshalJSON ¶
func (r *VaultGetResponse) UnmarshalJSON(data []byte) (err error)
type VaultGetResponseChunkStrategy ¶
type VaultGetResponseChunkStrategy struct {
// Target size for each chunk in tokens
ChunkSize int64 `json:"chunkSize"`
// Chunking method (e.g., 'semantic', 'fixed')
Method string `json:"method"`
// Minimum chunk size in tokens
MinChunkSize int64 `json:"minChunkSize"`
// Number of overlapping tokens between chunks
Overlap int64 `json:"overlap"`
JSON vaultGetResponseChunkStrategyJSON `json:"-"`
}
Document chunking strategy configuration
func (*VaultGetResponseChunkStrategy) UnmarshalJSON ¶
func (r *VaultGetResponseChunkStrategy) UnmarshalJSON(data []byte) (err error)
type VaultGraphragGetStatsResponse ¶
type VaultGraphragGetStatsResponse struct {
// Number of entity communities identified
Communities int64 `json:"communities"`
// Number of processed documents
Documents int64 `json:"documents"`
// Total number of entities extracted from documents
Entities int64 `json:"entities"`
// Timestamp of last GraphRAG processing
LastProcessed time.Time `json:"lastProcessed" format:"date-time"`
// Total number of relationships between entities
Relationships int64 `json:"relationships"`
// Current processing status
Status VaultGraphragGetStatsResponseStatus `json:"status"`
JSON vaultGraphragGetStatsResponseJSON `json:"-"`
}
func (*VaultGraphragGetStatsResponse) UnmarshalJSON ¶
func (r *VaultGraphragGetStatsResponse) UnmarshalJSON(data []byte) (err error)
type VaultGraphragGetStatsResponseStatus ¶
type VaultGraphragGetStatsResponseStatus string
Current processing status
const ( VaultGraphragGetStatsResponseStatusProcessing VaultGraphragGetStatsResponseStatus = "processing" VaultGraphragGetStatsResponseStatusCompleted VaultGraphragGetStatsResponseStatus = "completed" VaultGraphragGetStatsResponseStatusError VaultGraphragGetStatsResponseStatus = "error" )
func (VaultGraphragGetStatsResponseStatus) IsKnown ¶
func (r VaultGraphragGetStatsResponseStatus) IsKnown() bool
type VaultGraphragInitResponse ¶
type VaultGraphragInitResponse struct {
Message string `json:"message"`
Status string `json:"status"`
Success bool `json:"success"`
VaultID string `json:"vault_id"`
JSON vaultGraphragInitResponseJSON `json:"-"`
}
func (*VaultGraphragInitResponse) UnmarshalJSON ¶
func (r *VaultGraphragInitResponse) UnmarshalJSON(data []byte) (err error)
type VaultGraphragProcessObjectResponse ¶
type VaultGraphragProcessObjectResponse struct {
// Number of communities detected
Communities int64 `json:"communities" api:"required"`
// Number of entities extracted
Entities int64 `json:"entities" api:"required"`
// ID of the indexed object
ObjectID string `json:"objectId" api:"required"`
// Number of relationships extracted
Relationships int64 `json:"relationships" api:"required"`
// Extraction statistics
Stats VaultGraphragProcessObjectResponseStats `json:"stats" api:"required"`
// Status from GraphRAG service
Status string `json:"status" api:"required"`
// Whether indexing completed successfully
Success bool `json:"success" api:"required"`
// ID of the vault
VaultID string `json:"vaultId" api:"required"`
JSON vaultGraphragProcessObjectResponseJSON `json:"-"`
}
func (*VaultGraphragProcessObjectResponse) UnmarshalJSON ¶
func (r *VaultGraphragProcessObjectResponse) UnmarshalJSON(data []byte) (err error)
type VaultGraphragProcessObjectResponseStats ¶
type VaultGraphragProcessObjectResponseStats struct {
CommunityCount int64 `json:"community_count"`
EntityCount int64 `json:"entity_count"`
RelationshipCount int64 `json:"relationship_count"`
JSON vaultGraphragProcessObjectResponseStatsJSON `json:"-"`
}
Extraction statistics
func (*VaultGraphragProcessObjectResponseStats) UnmarshalJSON ¶
func (r *VaultGraphragProcessObjectResponseStats) UnmarshalJSON(data []byte) (err error)
type VaultGraphragService ¶
type VaultGraphragService struct {
Options []option.RequestOption
}
Secure document storage with semantic search and GraphRAG
VaultGraphragService contains methods and other services that help with interacting with the casedev API.
Note, unlike clients, this service does not read variables from the environment automatically. You should not instantiate this service directly, and instead use the NewVaultGraphragService method instead.
func NewVaultGraphragService ¶
func NewVaultGraphragService(opts ...option.RequestOption) (r *VaultGraphragService)
NewVaultGraphragService generates a new service that applies the given options to each request. These options are applied after the parent client's options (if there is one), and before any request-specific options.
func (*VaultGraphragService) GetStats ¶
func (r *VaultGraphragService) GetStats(ctx context.Context, id string, opts ...option.RequestOption) (res *VaultGraphragGetStatsResponse, err error)
Retrieve GraphRAG (Graph Retrieval-Augmented Generation) statistics for a specific vault. This includes metrics about the knowledge graph structure, entity relationships, and processing status that enable advanced semantic search and AI-powered document analysis.
func (*VaultGraphragService) Init ¶
func (r *VaultGraphragService) Init(ctx context.Context, id string, opts ...option.RequestOption) (res *VaultGraphragInitResponse, err error)
Initialize a GraphRAG workspace for a vault to enable advanced knowledge graph and retrieval-augmented generation capabilities. This creates the necessary infrastructure for semantic document analysis and graph-based querying within the vault.
func (*VaultGraphragService) ProcessObject ¶
func (r *VaultGraphragService) ProcessObject(ctx context.Context, id string, objectID string, opts ...option.RequestOption) (res *VaultGraphragProcessObjectResponse, err error)
Manually trigger GraphRAG indexing for a vault object. The object must already be ingested (completed status). This extracts entities, relationships, and communities from the document for advanced knowledge graph queries.
type VaultGroupNewParams ¶ added in v0.14.0
type VaultGroupNewParams struct {
// Human-readable name for the vault group
Name param.Field[string] `json:"name" api:"required"`
// Optional description of the vault group purpose
Description param.Field[string] `json:"description"`
}
func (VaultGroupNewParams) MarshalJSON ¶ added in v0.14.0
func (r VaultGroupNewParams) MarshalJSON() (data []byte, err error)
type VaultGroupService ¶
type VaultGroupService struct {
Options []option.RequestOption
}
Secure document storage with semantic search and GraphRAG
VaultGroupService contains methods and other services that help with interacting with the casedev API.
Note, unlike clients, this service does not read variables from the environment automatically. You should not instantiate this service directly, and instead use the NewVaultGroupService method instead.
func NewVaultGroupService ¶
func NewVaultGroupService(opts ...option.RequestOption) (r *VaultGroupService)
NewVaultGroupService generates a new service that applies the given options to each request. These options are applied after the parent client's options (if there is one), and before any request-specific options.
func (*VaultGroupService) Delete ¶
func (r *VaultGroupService) Delete(ctx context.Context, groupID string, opts ...option.RequestOption) (err error)
Soft-deletes a vault group that no longer has any active vaults assigned. This operation is blocked when the group still contains vaults.
func (*VaultGroupService) List ¶
func (r *VaultGroupService) List(ctx context.Context, opts ...option.RequestOption) (err error)
Lists vault groups visible to the authenticated organization. Group-scoped API keys only receive groups within their allowed scope.
func (*VaultGroupService) New ¶
func (r *VaultGroupService) New(ctx context.Context, body VaultGroupNewParams, opts ...option.RequestOption) (err error)
Creates a vault group for organizing vaults and applying group-scoped access controls. Group-scoped API keys cannot create or manage vault groups.
func (*VaultGroupService) Update ¶
func (r *VaultGroupService) Update(ctx context.Context, groupID string, body VaultGroupUpdateParams, opts ...option.RequestOption) (err error)
Updates a vault group for the authenticated organization. Only provided fields are changed, and setting description to null removes the current description.
type VaultGroupUpdateParams ¶ added in v0.14.0
type VaultGroupUpdateParams struct {
// Updated vault group description. Pass null to remove the current description.
Description param.Field[string] `json:"description"`
// New human-readable name for the vault group
Name param.Field[string] `json:"name"`
}
func (VaultGroupUpdateParams) MarshalJSON ¶ added in v0.14.0
func (r VaultGroupUpdateParams) MarshalJSON() (data []byte, err error)
type VaultIngestResponse ¶
type VaultIngestResponse struct {
// Always false - GraphRAG must be triggered separately via POST
// /vault/:id/graphrag/:objectId
EnableGraphRag bool `json:"enableGraphRAG" api:"required"`
// Human-readable status message
Message string `json:"message" api:"required"`
// ID of the vault object being processed
ObjectID string `json:"objectId" api:"required"`
// Current ingestion status. 'stored' for file types without text extraction (no
// chunks/vectors created).
Status VaultIngestResponseStatus `json:"status" api:"required"`
// Workflow run ID for tracking progress. Null for file types that skip processing.
WorkflowID string `json:"workflowId" api:"required,nullable"`
JSON vaultIngestResponseJSON `json:"-"`
}
func (*VaultIngestResponse) UnmarshalJSON ¶
func (r *VaultIngestResponse) UnmarshalJSON(data []byte) (err error)
type VaultIngestResponseStatus ¶
type VaultIngestResponseStatus string
Current ingestion status. 'stored' for file types without text extraction (no chunks/vectors created).
const ( VaultIngestResponseStatusProcessing VaultIngestResponseStatus = "processing" VaultIngestResponseStatusStored VaultIngestResponseStatus = "stored" )
func (VaultIngestResponseStatus) IsKnown ¶
func (r VaultIngestResponseStatus) IsKnown() bool
type VaultListResponse ¶
type VaultListResponse struct {
// Total number of vaults
Total int64 `json:"total"`
Vaults []VaultListResponseVault `json:"vaults"`
JSON vaultListResponseJSON `json:"-"`
}
func (*VaultListResponse) UnmarshalJSON ¶
func (r *VaultListResponse) UnmarshalJSON(data []byte) (err error)
type VaultListResponseVault ¶
type VaultListResponseVault struct {
// Vault identifier
ID string `json:"id"`
// Vault creation timestamp
CreatedAt time.Time `json:"createdAt" format:"date-time"`
// Vault description
Description string `json:"description"`
// Whether GraphRAG is enabled
EnableGraph bool `json:"enableGraph"`
// Vault name
Name string `json:"name"`
// Total storage size in bytes
TotalBytes int64 `json:"totalBytes"`
// Number of stored documents
TotalObjects int64 `json:"totalObjects"`
JSON vaultListResponseVaultJSON `json:"-"`
}
func (*VaultListResponseVault) UnmarshalJSON ¶
func (r *VaultListResponseVault) UnmarshalJSON(data []byte) (err error)
type VaultMemoryListResponse ¶ added in v0.25.0
type VaultMemoryListResponse struct {
Entries []VaultMemoryListResponseEntry `json:"entries"`
Meta VaultMemoryListResponseMeta `json:"meta"`
JSON vaultMemoryListResponseJSON `json:"-"`
}
func (*VaultMemoryListResponse) UnmarshalJSON ¶ added in v0.25.0
func (r *VaultMemoryListResponse) UnmarshalJSON(data []byte) (err error)
type VaultMemoryListResponseEntry ¶ added in v0.25.0
type VaultMemoryListResponseEntry struct {
ID string `json:"id"`
Content string `json:"content"`
CreatedAt time.Time `json:"created_at" format:"date-time"`
CreatedBy string `json:"created_by" api:"nullable"`
Source string `json:"source" api:"nullable"`
Tags []string `json:"tags"`
Type string `json:"type"`
UpdatedAt time.Time `json:"updated_at" format:"date-time"`
JSON vaultMemoryListResponseEntryJSON `json:"-"`
}
func (*VaultMemoryListResponseEntry) UnmarshalJSON ¶ added in v0.25.0
func (r *VaultMemoryListResponseEntry) UnmarshalJSON(data []byte) (err error)
type VaultMemoryListResponseMeta ¶ added in v0.25.0
type VaultMemoryListResponseMeta struct {
Chars int64 `json:"chars"`
Count int64 `json:"count"`
MaxChars int64 `json:"max_chars"`
UpdatedAt time.Time `json:"updated_at" api:"nullable" format:"date-time"`
JSON vaultMemoryListResponseMetaJSON `json:"-"`
}
func (*VaultMemoryListResponseMeta) UnmarshalJSON ¶ added in v0.25.0
func (r *VaultMemoryListResponseMeta) UnmarshalJSON(data []byte) (err error)
type VaultMemoryNewParams ¶ added in v0.25.0
type VaultMemoryNewParams struct {
Content param.Field[string] `json:"content" api:"required"`
Type param.Field[VaultMemoryNewParamsType] `json:"type" api:"required"`
Source param.Field[string] `json:"source"`
Tags param.Field[[]string] `json:"tags"`
}
func (VaultMemoryNewParams) MarshalJSON ¶ added in v0.25.0
func (r VaultMemoryNewParams) MarshalJSON() (data []byte, err error)
type VaultMemoryNewParamsType ¶ added in v0.25.0
type VaultMemoryNewParamsType string
const ( VaultMemoryNewParamsTypeFact VaultMemoryNewParamsType = "fact" VaultMemoryNewParamsTypeParty VaultMemoryNewParamsType = "party" VaultMemoryNewParamsTypeIssue VaultMemoryNewParamsType = "issue" VaultMemoryNewParamsTypeDeadline VaultMemoryNewParamsType = "deadline" VaultMemoryNewParamsTypeDiscovery VaultMemoryNewParamsType = "discovery" VaultMemoryNewParamsTypeCorrection VaultMemoryNewParamsType = "correction" VaultMemoryNewParamsTypePreference VaultMemoryNewParamsType = "preference" )
func (VaultMemoryNewParamsType) IsKnown ¶ added in v0.25.0
func (r VaultMemoryNewParamsType) IsKnown() bool
type VaultMemoryNewResponse ¶ added in v0.25.0
type VaultMemoryNewResponse struct {
Entry VaultMemoryNewResponseEntry `json:"entry"`
JSON vaultMemoryNewResponseJSON `json:"-"`
}
func (*VaultMemoryNewResponse) UnmarshalJSON ¶ added in v0.25.0
func (r *VaultMemoryNewResponse) UnmarshalJSON(data []byte) (err error)
type VaultMemoryNewResponseEntry ¶ added in v0.25.0
type VaultMemoryNewResponseEntry struct {
ID string `json:"id"`
Content string `json:"content"`
CreatedAt time.Time `json:"created_at" format:"date-time"`
CreatedBy string `json:"created_by" api:"nullable"`
Source string `json:"source" api:"nullable"`
Tags []string `json:"tags"`
Type string `json:"type"`
UpdatedAt time.Time `json:"updated_at" format:"date-time"`
JSON vaultMemoryNewResponseEntryJSON `json:"-"`
}
func (*VaultMemoryNewResponseEntry) UnmarshalJSON ¶ added in v0.25.0
func (r *VaultMemoryNewResponseEntry) UnmarshalJSON(data []byte) (err error)
type VaultMemorySearchParams ¶ added in v0.25.0
type VaultMemorySearchParams struct {
Query param.Field[string] `json:"query" api:"required"`
Limit param.Field[int64] `json:"limit"`
Tags param.Field[[]string] `json:"tags"`
Types param.Field[[]string] `json:"types"`
}
func (VaultMemorySearchParams) MarshalJSON ¶ added in v0.25.0
func (r VaultMemorySearchParams) MarshalJSON() (data []byte, err error)
type VaultMemorySearchResponse ¶ added in v0.25.0
type VaultMemorySearchResponse struct {
Results []VaultMemorySearchResponseResult `json:"results"`
JSON vaultMemorySearchResponseJSON `json:"-"`
}
func (*VaultMemorySearchResponse) UnmarshalJSON ¶ added in v0.25.0
func (r *VaultMemorySearchResponse) UnmarshalJSON(data []byte) (err error)
type VaultMemorySearchResponseResult ¶ added in v0.25.0
type VaultMemorySearchResponseResult struct {
ID string `json:"id"`
Content string `json:"content"`
CreatedAt time.Time `json:"created_at" format:"date-time"`
CreatedBy string `json:"created_by" api:"nullable"`
Source string `json:"source" api:"nullable"`
Tags []string `json:"tags"`
Type string `json:"type"`
UpdatedAt time.Time `json:"updated_at" format:"date-time"`
JSON vaultMemorySearchResponseResultJSON `json:"-"`
}
func (*VaultMemorySearchResponseResult) UnmarshalJSON ¶ added in v0.25.0
func (r *VaultMemorySearchResponseResult) UnmarshalJSON(data []byte) (err error)
type VaultMemoryService ¶ added in v0.25.0
type VaultMemoryService struct {
Options []option.RequestOption
}
Secure document storage with semantic search and GraphRAG
VaultMemoryService contains methods and other services that help with interacting with the casedev API.
Note, unlike clients, this service does not read variables from the environment automatically. You should not instantiate this service directly, and instead use the NewVaultMemoryService method instead.
func NewVaultMemoryService ¶ added in v0.25.0
func NewVaultMemoryService(opts ...option.RequestOption) (r *VaultMemoryService)
NewVaultMemoryService generates a new service that applies the given options to each request. These options are applied after the parent client's options (if there is one), and before any request-specific options.
func (*VaultMemoryService) Delete ¶ added in v0.25.0
func (r *VaultMemoryService) Delete(ctx context.Context, id string, entryID string, opts ...option.RequestOption) (err error)
Remove a file-backed memory entry from a vault.
func (*VaultMemoryService) List ¶ added in v0.25.0
func (r *VaultMemoryService) List(ctx context.Context, id string, opts ...option.RequestOption) (res *VaultMemoryListResponse, err error)
Retrieve file-backed memory entries stored in a vault.
func (*VaultMemoryService) New ¶ added in v0.25.0
func (r *VaultMemoryService) New(ctx context.Context, id string, body VaultMemoryNewParams, opts ...option.RequestOption) (res *VaultMemoryNewResponse, err error)
Append a new file-backed memory entry to a vault.
func (*VaultMemoryService) Search ¶ added in v0.25.0
func (r *VaultMemoryService) Search(ctx context.Context, id string, body VaultMemorySearchParams, opts ...option.RequestOption) (res *VaultMemorySearchResponse, err error)
Search file-backed vault memory using simple full-text matching over content and tags.
func (*VaultMemoryService) Update ¶ added in v0.25.0
func (r *VaultMemoryService) Update(ctx context.Context, id string, entryID string, body VaultMemoryUpdateParams, opts ...option.RequestOption) (err error)
Rewrite a file-backed vault memory entry with updated content, source, or tags.
type VaultMemoryUpdateParams ¶ added in v0.25.0
type VaultMemoryUpdateParams struct {
Content param.Field[string] `json:"content"`
Source param.Field[string] `json:"source"`
Tags param.Field[[]string] `json:"tags"`
}
func (VaultMemoryUpdateParams) MarshalJSON ¶ added in v0.25.0
func (r VaultMemoryUpdateParams) MarshalJSON() (data []byte, err error)
type VaultMultipartAbortParams ¶
type VaultMultipartAbortParams struct {
// Vault object ID associated with the multipart upload
ObjectID param.Field[string] `json:"objectId" api:"required"`
// Multipart upload ID returned when the upload was initialized
UploadID param.Field[string] `json:"uploadId" api:"required"`
}
func (VaultMultipartAbortParams) MarshalJSON ¶
func (r VaultMultipartAbortParams) MarshalJSON() (data []byte, err error)
type VaultMultipartGetPartURLsParams ¶
type VaultMultipartGetPartURLsParams struct {
// Vault object ID associated with the multipart upload
ObjectID param.Field[string] `json:"objectId" api:"required"`
// Multipart parts that need presigned upload URLs
Parts param.Field[[]VaultMultipartGetPartURLsParamsPart] `json:"parts" api:"required"`
// Multipart upload ID returned when the upload was initialized
UploadID param.Field[string] `json:"uploadId" api:"required"`
}
func (VaultMultipartGetPartURLsParams) MarshalJSON ¶
func (r VaultMultipartGetPartURLsParams) MarshalJSON() (data []byte, err error)
type VaultMultipartGetPartURLsParamsPart ¶
type VaultMultipartGetPartURLsParamsPart struct {
// 1-based multipart part number
PartNumber param.Field[int64] `json:"partNumber" api:"required"`
// Part size in bytes (min 5MB except final part, max 5GB).
SizeBytes param.Field[int64] `json:"sizeBytes" api:"required"`
}
func (VaultMultipartGetPartURLsParamsPart) MarshalJSON ¶
func (r VaultMultipartGetPartURLsParamsPart) MarshalJSON() (data []byte, err error)
type VaultMultipartGetPartURLsResponse ¶
type VaultMultipartGetPartURLsResponse struct {
URLs []VaultMultipartGetPartURLsResponseURL `json:"urls"`
JSON vaultMultipartGetPartURLsResponseJSON `json:"-"`
}
func (*VaultMultipartGetPartURLsResponse) UnmarshalJSON ¶
func (r *VaultMultipartGetPartURLsResponse) UnmarshalJSON(data []byte) (err error)
type VaultMultipartGetPartURLsResponseURL ¶
type VaultMultipartGetPartURLsResponseURL struct {
PartNumber int64 `json:"partNumber"`
URL string `json:"url"`
JSON vaultMultipartGetPartURLsResponseURLJSON `json:"-"`
}
func (*VaultMultipartGetPartURLsResponseURL) UnmarshalJSON ¶
func (r *VaultMultipartGetPartURLsResponseURL) UnmarshalJSON(data []byte) (err error)
type VaultMultipartService ¶
type VaultMultipartService struct {
Options []option.RequestOption
}
Secure document storage with semantic search and GraphRAG
VaultMultipartService contains methods and other services that help with interacting with the casedev API.
Note, unlike clients, this service does not read variables from the environment automatically. You should not instantiate this service directly, and instead use the NewVaultMultipartService method instead.
func NewVaultMultipartService ¶
func NewVaultMultipartService(opts ...option.RequestOption) (r *VaultMultipartService)
NewVaultMultipartService generates a new service that applies the given options to each request. These options are applied after the parent client's options (if there is one), and before any request-specific options.
func (*VaultMultipartService) Abort ¶
func (r *VaultMultipartService) Abort(ctx context.Context, id string, body VaultMultipartAbortParams, opts ...option.RequestOption) (err error)
Abort a multipart upload and discard uploaded parts (live).
func (*VaultMultipartService) GetPartURLs ¶
func (r *VaultMultipartService) GetPartURLs(ctx context.Context, id string, body VaultMultipartGetPartURLsParams, opts ...option.RequestOption) (res *VaultMultipartGetPartURLsResponse, err error)
Generate presigned URLs for individual multipart upload parts (live).
type VaultNewParams ¶
type VaultNewParams struct {
// Display name for the vault
Name param.Field[string] `json:"name" api:"required"`
// Optional description of the vault's purpose
Description param.Field[string] `json:"description"`
// Optional embedding model for this vault. Defaults to casemark/embed-v1.
// Determines the S3 Vectors index dimension and which model is used at both ingest
// and search time. The vault is locked to this model after creation — use a
// re-embed flow to change later. Ignored when enableIndexing is false. Note:
// `casemark/llama-nemotron-embed-vl-1b-v2` is a deprecated alias for
// `casemark/embed-v1` (retained for SDK backward compatibility); new integrations
// should use `casemark/embed-v1` directly.
EmbeddingModel param.Field[VaultNewParamsEmbeddingModel] `json:"embeddingModel"`
// Enable knowledge graph for entity relationship mapping. Only applies when
// enableIndexing is true.
EnableGraph param.Field[bool] `json:"enableGraph"`
// Enable vector indexing and search capabilities. Set to false for storage-only
// vaults.
EnableIndexing param.Field[bool] `json:"enableIndexing"`
// Assign the vault to a vault group for access control. Required when using a
// group-scoped API key.
GroupID param.Field[string] `json:"groupId"`
// Optional metadata to attach to the vault (e.g., { containsPHI: true } for HIPAA
// compliance tracking)
Metadata param.Field[interface{}] `json:"metadata"`
}
func (VaultNewParams) MarshalJSON ¶
func (r VaultNewParams) MarshalJSON() (data []byte, err error)
type VaultNewParamsEmbeddingModel ¶ added in v0.38.0
type VaultNewParamsEmbeddingModel string
Optional embedding model for this vault. Defaults to casemark/embed-v1. Determines the S3 Vectors index dimension and which model is used at both ingest and search time. The vault is locked to this model after creation — use a re-embed flow to change later. Ignored when enableIndexing is false. Note: `casemark/llama-nemotron-embed-vl-1b-v2` is a deprecated alias for `casemark/embed-v1` (retained for SDK backward compatibility); new integrations should use `casemark/embed-v1` directly.
const ( VaultNewParamsEmbeddingModelOpenAITextEmbedding3Small VaultNewParamsEmbeddingModel = "openai/text-embedding-3-small" VaultNewParamsEmbeddingModelOpenAITextEmbedding3Large VaultNewParamsEmbeddingModel = "openai/text-embedding-3-large" VaultNewParamsEmbeddingModelVoyageVoyage3_5 VaultNewParamsEmbeddingModel = "voyage/voyage-3.5" VaultNewParamsEmbeddingModelVoyageVoyageLaw2 VaultNewParamsEmbeddingModel = "voyage/voyage-law-2" VaultNewParamsEmbeddingModelCohereEmbedV4_0 VaultNewParamsEmbeddingModel = "cohere/embed-v4.0" VaultNewParamsEmbeddingModelGoogleGeminiEmbedding2 VaultNewParamsEmbeddingModel = "google/gemini-embedding-2" VaultNewParamsEmbeddingModelCasemarkEmbedV1 VaultNewParamsEmbeddingModel = "casemark/embed-v1" VaultNewParamsEmbeddingModelCasemarkLlamaNemotronEmbedVl1bV2 VaultNewParamsEmbeddingModel = "casemark/llama-nemotron-embed-vl-1b-v2" )
func (VaultNewParamsEmbeddingModel) IsKnown ¶ added in v0.38.0
func (r VaultNewParamsEmbeddingModel) IsKnown() bool
type VaultNewResponse ¶
type VaultNewResponse struct {
// Unique vault identifier
ID string `json:"id"`
// Vault creation timestamp
CreatedAt time.Time `json:"createdAt" format:"date-time"`
// Vault description
Description string `json:"description"`
// The resolved embedding profile for this vault. Null for storage-only vaults.
EmbeddingProfile VaultNewResponseEmbeddingProfile `json:"embeddingProfile" api:"nullable"`
// Whether vector indexing is enabled for this vault
EnableIndexing bool `json:"enableIndexing"`
// S3 bucket name for document storage
FilesBucket string `json:"filesBucket"`
// Vector search index name. Null for storage-only vaults.
IndexName string `json:"indexName" api:"nullable"`
// Vault display name
Name string `json:"name"`
// AWS region for storage
Region string `json:"region"`
// S3 bucket name for vector embeddings. Null for storage-only vaults.
VectorBucket string `json:"vectorBucket" api:"nullable"`
JSON vaultNewResponseJSON `json:"-"`
}
func (*VaultNewResponse) UnmarshalJSON ¶
func (r *VaultNewResponse) UnmarshalJSON(data []byte) (err error)
type VaultNewResponseEmbeddingProfile ¶ added in v0.38.0
type VaultNewResponseEmbeddingProfile struct {
// Vector dimension used by this vault
Dimensions int64 `json:"dimensions"`
// Embedding model catalog key
Model string `json:"model"`
// Embedding provider
Provider string `json:"provider"`
JSON vaultNewResponseEmbeddingProfileJSON `json:"-"`
}
The resolved embedding profile for this vault. Null for storage-only vaults.
func (*VaultNewResponseEmbeddingProfile) UnmarshalJSON ¶ added in v0.38.0
func (r *VaultNewResponseEmbeddingProfile) UnmarshalJSON(data []byte) (err error)
type VaultObjectDeleteParams ¶
type VaultObjectDeleteParams struct {
// Force delete a stuck document that is still in 'processing' state. Use this if a
// document got stuck during ingestion (e.g., OCR timeout).
Force param.Field[VaultObjectDeleteParamsForce] `query:"force"`
}
func (VaultObjectDeleteParams) URLQuery ¶
func (r VaultObjectDeleteParams) URLQuery() (v url.Values)
URLQuery serializes VaultObjectDeleteParams's query parameters as `url.Values`.
type VaultObjectDeleteParamsForce ¶
type VaultObjectDeleteParamsForce string
Force delete a stuck document that is still in 'processing' state. Use this if a document got stuck during ingestion (e.g., OCR timeout).
const (
VaultObjectDeleteParamsForceTrue VaultObjectDeleteParamsForce = "true"
)
func (VaultObjectDeleteParamsForce) IsKnown ¶
func (r VaultObjectDeleteParamsForce) IsKnown() bool
type VaultObjectDeleteResponse ¶
type VaultObjectDeleteResponse struct {
DeletedObject VaultObjectDeleteResponseDeletedObject `json:"deletedObject"`
Success bool `json:"success"`
JSON vaultObjectDeleteResponseJSON `json:"-"`
}
func (*VaultObjectDeleteResponse) UnmarshalJSON ¶
func (r *VaultObjectDeleteResponse) UnmarshalJSON(data []byte) (err error)
type VaultObjectDeleteResponseDeletedObject ¶
type VaultObjectDeleteResponseDeletedObject struct {
// Deleted object ID
ID string `json:"id"`
// Original filename
Filename string `json:"filename"`
// Size of deleted file in bytes
SizeBytes int64 `json:"sizeBytes"`
// Number of vectors deleted
VectorsDeleted int64 `json:"vectorsDeleted"`
JSON vaultObjectDeleteResponseDeletedObjectJSON `json:"-"`
}
func (*VaultObjectDeleteResponseDeletedObject) UnmarshalJSON ¶
func (r *VaultObjectDeleteResponseDeletedObject) UnmarshalJSON(data []byte) (err error)
type VaultObjectGetChunksParams ¶ added in v0.36.0
type VaultObjectGetChunksParams struct {
// The last chunk index to return (inclusive). If omitted, only the `start` chunk
// is returned. Ranges are limited to 10 chunks.
End param.Field[int64] `query:"end"`
// The first chunk index to return (0-based). Defaults to 0.
Start param.Field[int64] `query:"start"`
}
func (VaultObjectGetChunksParams) URLQuery ¶ added in v0.36.0
func (r VaultObjectGetChunksParams) URLQuery() (v url.Values)
URLQuery serializes VaultObjectGetChunksParams's query parameters as `url.Values`.
type VaultObjectGetChunksResponse ¶ added in v0.36.0
type VaultObjectGetChunksResponse struct {
// Full chunk objects for the requested range
Chunks []VaultObjectGetChunksResponseChunk `json:"chunks" api:"required"`
// The object ID
ObjectID string `json:"object_id" api:"required"`
// Total number of chunks stored for the object
TotalChunks int64 `json:"total_chunks" api:"required"`
// The vault ID
VaultID string `json:"vault_id" api:"required"`
JSON vaultObjectGetChunksResponseJSON `json:"-"`
}
func (*VaultObjectGetChunksResponse) UnmarshalJSON ¶ added in v0.36.0
func (r *VaultObjectGetChunksResponse) UnmarshalJSON(data []byte) (err error)
type VaultObjectGetChunksResponseChunk ¶ added in v0.36.0
type VaultObjectGetChunksResponseChunk struct {
// Chunk index within the document
Index int64 `json:"index" api:"required"`
// Last page covered by the chunk, if page mapping is available
PageEnd int64 `json:"page_end" api:"required,nullable"`
// First page covered by the chunk, if page mapping is available
PageStart int64 `json:"page_start" api:"required,nullable"`
// Full text for the chunk
Text string `json:"text" api:"required"`
// Last OCR word index covered by the chunk, if available
WordEndIndex int64 `json:"word_end_index" api:"required,nullable"`
// First OCR word index covered by the chunk, if available
WordStartIndex int64 `json:"word_start_index" api:"required,nullable"`
JSON vaultObjectGetChunksResponseChunkJSON `json:"-"`
}
func (*VaultObjectGetChunksResponseChunk) UnmarshalJSON ¶ added in v0.36.0
func (r *VaultObjectGetChunksResponseChunk) UnmarshalJSON(data []byte) (err error)
type VaultObjectGetOcrWordsParams ¶
type VaultObjectGetOcrWordsParams struct {
// Filter to a specific page number (1-indexed). If omitted, returns all pages.
Page param.Field[int64] `query:"page"`
// Filter to words ending at this index (inclusive). Useful for retrieving words
// for a specific chunk.
WordEnd param.Field[int64] `query:"wordEnd"`
// Filter to words starting at this index (inclusive). Useful for retrieving words
// for a specific chunk.
WordStart param.Field[int64] `query:"wordStart"`
}
func (VaultObjectGetOcrWordsParams) URLQuery ¶
func (r VaultObjectGetOcrWordsParams) URLQuery() (v url.Values)
URLQuery serializes VaultObjectGetOcrWordsParams's query parameters as `url.Values`.
type VaultObjectGetOcrWordsResponse ¶
type VaultObjectGetOcrWordsResponse struct {
// When the OCR data was extracted
CreatedAt time.Time `json:"createdAt" format:"date-time"`
// The object ID
ObjectID string `json:"objectId"`
// Total number of pages in the document
PageCount int64 `json:"pageCount"`
// Per-page word data with bounding boxes
Pages []VaultObjectGetOcrWordsResponsePage `json:"pages"`
// Total number of words extracted from the document
TotalWords int64 `json:"totalWords"`
JSON vaultObjectGetOcrWordsResponseJSON `json:"-"`
}
func (*VaultObjectGetOcrWordsResponse) UnmarshalJSON ¶
func (r *VaultObjectGetOcrWordsResponse) UnmarshalJSON(data []byte) (err error)
type VaultObjectGetOcrWordsResponsePage ¶
type VaultObjectGetOcrWordsResponsePage struct {
// Page number (1-indexed)
Page int64 `json:"page"`
Words []VaultObjectGetOcrWordsResponsePagesWord `json:"words"`
JSON vaultObjectGetOcrWordsResponsePageJSON `json:"-"`
}
func (*VaultObjectGetOcrWordsResponsePage) UnmarshalJSON ¶
func (r *VaultObjectGetOcrWordsResponsePage) UnmarshalJSON(data []byte) (err error)
type VaultObjectGetOcrWordsResponsePagesWord ¶
type VaultObjectGetOcrWordsResponsePagesWord struct {
// Bounding box [x0, y0, x1, y1] normalized to 0-1 range
Bbox []float64 `json:"bbox"`
// OCR confidence score (0-1)
Confidence float64 `json:"confidence" api:"nullable"`
// The word text
Text string `json:"text"`
// Global word index across the entire document (0-based)
WordIndex int64 `json:"wordIndex"`
JSON vaultObjectGetOcrWordsResponsePagesWordJSON `json:"-"`
}
func (*VaultObjectGetOcrWordsResponsePagesWord) UnmarshalJSON ¶
func (r *VaultObjectGetOcrWordsResponsePagesWord) UnmarshalJSON(data []byte) (err error)
type VaultObjectGetPagesParams ¶ added in v0.49.0
type VaultObjectGetPagesParams struct {
// Last page to return (inclusive, 1-indexed). If omitted, returns through the last
// page with text.
End param.Field[int64] `query:"end"`
// First page to return (inclusive, 1-indexed). If omitted, starts at the first
// page with text.
Start param.Field[int64] `query:"start"`
}
func (VaultObjectGetPagesParams) URLQuery ¶ added in v0.49.0
func (r VaultObjectGetPagesParams) URLQuery() (v url.Values)
URLQuery serializes VaultObjectGetPagesParams's query parameters as `url.Values`.
type VaultObjectGetPagesResponse ¶ added in v0.49.0
type VaultObjectGetPagesResponse struct {
Metadata VaultObjectGetPagesResponseMetadata `json:"metadata" api:"required"`
// Per-page OCR text in ascending page order
Pages []VaultObjectGetPagesResponsePage `json:"pages" api:"required"`
JSON vaultObjectGetPagesResponseJSON `json:"-"`
}
func (*VaultObjectGetPagesResponse) UnmarshalJSON ¶ added in v0.49.0
func (r *VaultObjectGetPagesResponse) UnmarshalJSON(data []byte) (err error)
type VaultObjectGetPagesResponseMetadata ¶ added in v0.49.0
type VaultObjectGetPagesResponseMetadata struct {
Filename string `json:"filename" api:"required"`
ObjectID string `json:"object_id" api:"required"`
// Total number of pages with extracted text in the document
PageCount int64 `json:"page_count" api:"required"`
// Number of pages returned after applying the range filter
ReturnedPages int64 `json:"returned_pages" api:"required"`
// Where the page text came from. `ocr` for PDFs (per-page OCR sidecar). `txt` for
// plain-text files split on form-feed (\f) characters.
Source VaultObjectGetPagesResponseMetadataSource `json:"source" api:"required"`
VaultID string `json:"vault_id" api:"required"`
// Echoes the end query param if provided
End int64 `json:"end" api:"nullable"`
// Echoes the start query param if provided
Start int64 `json:"start" api:"nullable"`
JSON vaultObjectGetPagesResponseMetadataJSON `json:"-"`
}
func (*VaultObjectGetPagesResponseMetadata) UnmarshalJSON ¶ added in v0.49.0
func (r *VaultObjectGetPagesResponseMetadata) UnmarshalJSON(data []byte) (err error)
type VaultObjectGetPagesResponseMetadataSource ¶ added in v0.49.0
type VaultObjectGetPagesResponseMetadataSource string
Where the page text came from. `ocr` for PDFs (per-page OCR sidecar). `txt` for plain-text files split on form-feed (\f) characters.
const ( VaultObjectGetPagesResponseMetadataSourceOcr VaultObjectGetPagesResponseMetadataSource = "ocr" VaultObjectGetPagesResponseMetadataSourceTxt VaultObjectGetPagesResponseMetadataSource = "txt" )
func (VaultObjectGetPagesResponseMetadataSource) IsKnown ¶ added in v0.49.0
func (r VaultObjectGetPagesResponseMetadataSource) IsKnown() bool
type VaultObjectGetPagesResponsePage ¶ added in v0.49.0
type VaultObjectGetPagesResponsePage struct {
// Page number (1-indexed)
Page int64 `json:"page" api:"required"`
// OCR text for this page
Text string `json:"text" api:"required"`
JSON vaultObjectGetPagesResponsePageJSON `json:"-"`
}
func (*VaultObjectGetPagesResponsePage) UnmarshalJSON ¶ added in v0.49.0
func (r *VaultObjectGetPagesResponsePage) UnmarshalJSON(data []byte) (err error)
type VaultObjectGetResponse ¶
type VaultObjectGetResponse struct {
// Object ID
ID string `json:"id" api:"required"`
// MIME type
ContentType string `json:"contentType" api:"required"`
// Upload timestamp
CreatedAt time.Time `json:"createdAt" api:"required" format:"date-time"`
// Presigned S3 download URL
DownloadURL string `json:"downloadUrl" api:"required"`
// URL expiration time in seconds
ExpiresIn int64 `json:"expiresIn" api:"required"`
// Original filename
Filename string `json:"filename" api:"required"`
// Processing status (pending, processing, completed, failed)
IngestionStatus string `json:"ingestionStatus" api:"required"`
// Vault ID
VaultID string `json:"vaultId" api:"required"`
// Number of text chunks created
ChunkCount int64 `json:"chunkCount"`
// Error details when ingestion fails
IngestionError string `json:"ingestionError" api:"nullable"`
// Additional metadata
Metadata interface{} `json:"metadata"`
// Number of pages (for documents)
PageCount int64 `json:"pageCount"`
// Optional folder path for hierarchy preservation
Path string `json:"path" api:"nullable"`
// File size in bytes
SizeBytes int64 `json:"sizeBytes"`
// Length of extracted text
TextLength int64 `json:"textLength"`
// Object ID of the completed transcript (if available)
TranscriptObjectID string `json:"transcript_object_id" api:"nullable"`
// Number of embedding vectors generated
VectorCount int64 `json:"vectorCount"`
JSON vaultObjectGetResponseJSON `json:"-"`
}
func (*VaultObjectGetResponse) UnmarshalJSON ¶
func (r *VaultObjectGetResponse) UnmarshalJSON(data []byte) (err error)
type VaultObjectGetSummarizeJobResponse ¶
type VaultObjectGetSummarizeJobResponse struct {
// When the job completed
CompletedAt time.Time `json:"completedAt" api:"nullable" format:"date-time"`
// When the job was created
CreatedAt time.Time `json:"createdAt" format:"date-time"`
// Error message (if failed)
Error string `json:"error" api:"nullable"`
// Case.dev job ID
JobID string `json:"jobId"`
// Filename of the result document (if completed)
ResultFilename string `json:"resultFilename" api:"nullable"`
// ID of the result document (if completed)
ResultObjectID string `json:"resultObjectId" api:"nullable"`
// ID of the source document
SourceObjectID string `json:"sourceObjectId"`
// Current job status
Status VaultObjectGetSummarizeJobResponseStatus `json:"status"`
// Type of workflow being executed
WorkflowType string `json:"workflowType"`
JSON vaultObjectGetSummarizeJobResponseJSON `json:"-"`
}
func (*VaultObjectGetSummarizeJobResponse) UnmarshalJSON ¶
func (r *VaultObjectGetSummarizeJobResponse) UnmarshalJSON(data []byte) (err error)
type VaultObjectGetSummarizeJobResponseStatus ¶
type VaultObjectGetSummarizeJobResponseStatus string
Current job status
const ( VaultObjectGetSummarizeJobResponseStatusPending VaultObjectGetSummarizeJobResponseStatus = "pending" VaultObjectGetSummarizeJobResponseStatusProcessing VaultObjectGetSummarizeJobResponseStatus = "processing" VaultObjectGetSummarizeJobResponseStatusCompleted VaultObjectGetSummarizeJobResponseStatus = "completed" VaultObjectGetSummarizeJobResponseStatusFailed VaultObjectGetSummarizeJobResponseStatus = "failed" )
func (VaultObjectGetSummarizeJobResponseStatus) IsKnown ¶
func (r VaultObjectGetSummarizeJobResponseStatus) IsKnown() bool
type VaultObjectGetTextResponse ¶
type VaultObjectGetTextResponse struct {
Metadata VaultObjectGetTextResponseMetadata `json:"metadata" api:"required"`
// Full concatenated text content from all chunks
Text string `json:"text" api:"required"`
JSON vaultObjectGetTextResponseJSON `json:"-"`
}
func (*VaultObjectGetTextResponse) UnmarshalJSON ¶
func (r *VaultObjectGetTextResponse) UnmarshalJSON(data []byte) (err error)
type VaultObjectGetTextResponseMetadata ¶
type VaultObjectGetTextResponseMetadata struct {
// Number of text chunks the document was split into
ChunkCount int64 `json:"chunk_count" api:"required"`
// Original filename of the document
Filename string `json:"filename" api:"required"`
// Total character count of the extracted text
Length int64 `json:"length" api:"required"`
// The object ID
ObjectID string `json:"object_id" api:"required"`
// The vault ID
VaultID string `json:"vault_id" api:"required"`
// When the document processing completed
IngestionCompletedAt time.Time `json:"ingestion_completed_at" format:"date-time"`
JSON vaultObjectGetTextResponseMetadataJSON `json:"-"`
}
func (*VaultObjectGetTextResponseMetadata) UnmarshalJSON ¶
func (r *VaultObjectGetTextResponseMetadata) UnmarshalJSON(data []byte) (err error)
type VaultObjectListResponse ¶
type VaultObjectListResponse struct {
// Total number of objects in the vault
Count float64 `json:"count" api:"required"`
Objects []VaultObjectListResponseObject `json:"objects" api:"required"`
// The ID of the vault
VaultID string `json:"vaultId" api:"required"`
JSON vaultObjectListResponseJSON `json:"-"`
}
func (*VaultObjectListResponse) UnmarshalJSON ¶
func (r *VaultObjectListResponse) UnmarshalJSON(data []byte) (err error)
type VaultObjectListResponseObject ¶
type VaultObjectListResponseObject struct {
// Unique object identifier
ID string `json:"id" api:"required"`
// MIME type of the document
ContentType string `json:"contentType" api:"required"`
// Document upload timestamp
CreatedAt time.Time `json:"createdAt" api:"required" format:"date-time"`
// Original filename of the uploaded document
Filename string `json:"filename" api:"required"`
// Processing status of the document
IngestionStatus string `json:"ingestionStatus" api:"required"`
// Number of text chunks created for vectorization
ChunkCount float64 `json:"chunkCount"`
// Processing completion timestamp
IngestionCompletedAt time.Time `json:"ingestionCompletedAt" format:"date-time"`
// Failure reason when ingestion status is a failed state
IngestionError string `json:"ingestionError" api:"nullable"`
// When ingestion processing began
IngestionStartedAt time.Time `json:"ingestionStartedAt" api:"nullable" format:"date-time"`
// Durable workflow run ID for the active or last ingestion attempt
IngestionWorkflowID string `json:"ingestionWorkflowId" api:"nullable"`
// Custom metadata associated with the document
Metadata interface{} `json:"metadata"`
// Number of pages in the document
PageCount float64 `json:"pageCount"`
// Optional folder path for hierarchy preservation from source systems
Path string `json:"path" api:"nullable"`
// File size in bytes
SizeBytes float64 `json:"sizeBytes"`
// Custom tags associated with the document
Tags []string `json:"tags"`
// Total character count of extracted text
TextLength float64 `json:"textLength"`
// Number of vectors generated for semantic search
VectorCount float64 `json:"vectorCount"`
JSON vaultObjectListResponseObjectJSON `json:"-"`
}
func (*VaultObjectListResponseObject) UnmarshalJSON ¶
func (r *VaultObjectListResponseObject) UnmarshalJSON(data []byte) (err error)
type VaultObjectNewPresignedURLParams ¶
type VaultObjectNewPresignedURLParams struct {
// Content type for PUT operations (optional, defaults to object's content type)
ContentType param.Field[string] `json:"contentType"`
// URL expiration time in seconds (1 minute to 7 days)
ExpiresIn param.Field[int64] `json:"expiresIn"`
// The S3 operation to generate URL for
Operation param.Field[VaultObjectNewPresignedURLParamsOperation] `json:"operation"`
// File size in bytes (optional, max 5GB for single PUT uploads). When provided for
// PUT operations, enforces exact file size at S3 level.
SizeBytes param.Field[int64] `json:"sizeBytes"`
}
func (VaultObjectNewPresignedURLParams) MarshalJSON ¶
func (r VaultObjectNewPresignedURLParams) MarshalJSON() (data []byte, err error)
type VaultObjectNewPresignedURLParamsOperation ¶
type VaultObjectNewPresignedURLParamsOperation string
The S3 operation to generate URL for
const ( VaultObjectNewPresignedURLParamsOperationGet VaultObjectNewPresignedURLParamsOperation = "GET" VaultObjectNewPresignedURLParamsOperationPut VaultObjectNewPresignedURLParamsOperation = "PUT" VaultObjectNewPresignedURLParamsOperationDelete VaultObjectNewPresignedURLParamsOperation = "DELETE" VaultObjectNewPresignedURLParamsOperationHead VaultObjectNewPresignedURLParamsOperation = "HEAD" )
func (VaultObjectNewPresignedURLParamsOperation) IsKnown ¶
func (r VaultObjectNewPresignedURLParamsOperation) IsKnown() bool
type VaultObjectNewPresignedURLResponse ¶
type VaultObjectNewPresignedURLResponse struct {
// URL expiration timestamp
ExpiresAt time.Time `json:"expiresAt" format:"date-time"`
// URL expiration time in seconds
ExpiresIn int64 `json:"expiresIn"`
// Original filename
Filename string `json:"filename"`
// Usage instructions and examples
Instructions interface{} `json:"instructions"`
Metadata VaultObjectNewPresignedURLResponseMetadata `json:"metadata"`
// The object identifier
ObjectID string `json:"objectId"`
// The operation type
Operation string `json:"operation"`
// The presigned URL for direct S3 access
PresignedURL string `json:"presignedUrl"`
// S3 object key
S3Key string `json:"s3Key"`
// The vault identifier
VaultID string `json:"vaultId"`
JSON vaultObjectNewPresignedURLResponseJSON `json:"-"`
}
func (*VaultObjectNewPresignedURLResponse) UnmarshalJSON ¶
func (r *VaultObjectNewPresignedURLResponse) UnmarshalJSON(data []byte) (err error)
type VaultObjectNewPresignedURLResponseMetadata ¶
type VaultObjectNewPresignedURLResponseMetadata struct {
Bucket string `json:"bucket"`
ContentType string `json:"contentType"`
Region string `json:"region"`
SizeBytes int64 `json:"sizeBytes"`
JSON vaultObjectNewPresignedURLResponseMetadataJSON `json:"-"`
}
func (*VaultObjectNewPresignedURLResponseMetadata) UnmarshalJSON ¶
func (r *VaultObjectNewPresignedURLResponseMetadata) UnmarshalJSON(data []byte) (err error)
type VaultObjectService ¶
type VaultObjectService struct {
Options []option.RequestOption
}
Secure document storage with semantic search and GraphRAG
VaultObjectService contains methods and other services that help with interacting with the casedev API.
Note, unlike clients, this service does not read variables from the environment automatically. You should not instantiate this service directly, and instead use the NewVaultObjectService method instead.
func NewVaultObjectService ¶
func NewVaultObjectService(opts ...option.RequestOption) (r *VaultObjectService)
NewVaultObjectService generates a new service that applies the given options to each request. These options are applied after the parent client's options (if there is one), and before any request-specific options.
func (*VaultObjectService) Delete ¶
func (r *VaultObjectService) Delete(ctx context.Context, id string, objectID string, body VaultObjectDeleteParams, opts ...option.RequestOption) (res *VaultObjectDeleteResponse, err error)
Permanently deletes a document from the vault including all associated vectors, chunks, graph data, and the original file. This operation cannot be undone.
func (*VaultObjectService) Download ¶
func (r *VaultObjectService) Download(ctx context.Context, id string, objectID string, opts ...option.RequestOption) (res *http.Response, err error)
Downloads a file from a vault. Returns the actual file content as a binary stream with appropriate headers for file download. Useful for retrieving contracts, depositions, case files, and other legal documents stored in your vault.
func (*VaultObjectService) Get ¶
func (r *VaultObjectService) Get(ctx context.Context, id string, objectID string, opts ...option.RequestOption) (res *VaultObjectGetResponse, err error)
Retrieves metadata for a specific document in a vault and generates a temporary download URL. The download URL expires after 1 hour for security. This endpoint also updates the file size if it wasn't previously calculated.
func (*VaultObjectService) GetChunks ¶ added in v0.36.0
func (r *VaultObjectService) GetChunks(ctx context.Context, id string, objectID string, query VaultObjectGetChunksParams, opts ...option.RequestOption) (res *VaultObjectGetChunksResponse, err error)
Retrieves full extracted chunk text for a processed vault object. Use this after search when a truncated preview is not enough and you need the exact chunk text or adjacent chunks for surrounding context such as tables, exhibit lists, or multi-part passages.
func (*VaultObjectService) GetOcrWords ¶
func (r *VaultObjectService) GetOcrWords(ctx context.Context, id string, objectID string, query VaultObjectGetOcrWordsParams, opts ...option.RequestOption) (res *VaultObjectGetOcrWordsResponse, err error)
Retrieves word-level OCR bounding box data for a processed PDF document. Each word includes its text, normalized bounding box coordinates (0-1 range), confidence score, and global word index. Use this data to highlight specific text ranges in a PDF viewer based on word indices from search results.
func (*VaultObjectService) GetPages ¶ added in v0.49.0
func (r *VaultObjectService) GetPages(ctx context.Context, id string, objectID string, query VaultObjectGetPagesParams, opts ...option.RequestOption) (res *VaultObjectGetPagesResponse, err error)
Retrieves the raw text of a processed vault object split by page. The object must have completed ingestion before pages can be retrieved — for PDFs this requires the OCR pipeline to have finished writing the per-page sidecar, so freshly uploaded PDFs return 400 with the current `ingestionStatus` until processing completes. For PDFs this returns the per-page OCR text. For plain text files (txt, md, source code, court reporter transcripts) the text is split using right-aligned page-number markers when present (preserving the original document numbering, including continuations like Volume 2 starting at page 234), falling back to form-feed (\f) page-break characters, and finally a single page if neither signal is present. Use the optional `start` and `end` query parameters to fetch a specific inclusive page range. Pages with no text are omitted.
func (*VaultObjectService) GetSummarizeJob ¶
func (r *VaultObjectService) GetSummarizeJob(ctx context.Context, id string, objectID string, jobID string, opts ...option.RequestOption) (res *VaultObjectGetSummarizeJobResponse, err error)
Get the status of a CaseMark summary workflow job.
func (*VaultObjectService) GetText ¶
func (r *VaultObjectService) GetText(ctx context.Context, id string, objectID string, opts ...option.RequestOption) (res *VaultObjectGetTextResponse, err error)
Retrieves the full extracted text content from a processed vault object. Returns the concatenated text from all chunks, useful for document review, analysis, or export. The object must have completed processing before text can be retrieved.
func (*VaultObjectService) List ¶
func (r *VaultObjectService) List(ctx context.Context, id string, opts ...option.RequestOption) (res *VaultObjectListResponse, err error)
Retrieve all objects stored in a specific vault, including document metadata, ingestion status, and processing statistics.
func (*VaultObjectService) NewPresignedURL ¶
func (r *VaultObjectService) NewPresignedURL(ctx context.Context, id string, objectID string, body VaultObjectNewPresignedURLParams, opts ...option.RequestOption) (res *VaultObjectNewPresignedURLResponse, err error)
Generate presigned URLs for direct S3 operations (GET, PUT, DELETE, HEAD) on vault objects. This allows secure, time-limited access to files without proxying through the API. Essential for large document uploads/downloads in legal workflows.
func (*VaultObjectService) Update ¶
func (r *VaultObjectService) Update(ctx context.Context, id string, objectID string, body VaultObjectUpdateParams, opts ...option.RequestOption) (res *VaultObjectUpdateResponse, err error)
Update a document's filename, path, or metadata. Use this to rename files or organize them into virtual folders. The path is stored in metadata.path and can be used to build folder hierarchies in your application.
type VaultObjectUpdateParams ¶
type VaultObjectUpdateParams struct {
// New filename for the document (affects display name and downloads)
Filename param.Field[string] `json:"filename"`
// Additional metadata to merge with existing metadata
Metadata param.Field[interface{}] `json:"metadata"`
// Folder path for hierarchy preservation (e.g., '/Discovery/Depositions'). Set to
// null or empty string to remove.
Path param.Field[string] `json:"path"`
}
func (VaultObjectUpdateParams) MarshalJSON ¶
func (r VaultObjectUpdateParams) MarshalJSON() (data []byte, err error)
type VaultObjectUpdateResponse ¶
type VaultObjectUpdateResponse struct {
// Object ID
ID string `json:"id"`
// MIME type
ContentType string `json:"contentType"`
// Updated filename
Filename string `json:"filename"`
// Processing status
IngestionStatus string `json:"ingestionStatus"`
// Full metadata object
Metadata interface{} `json:"metadata"`
// Folder path for hierarchy preservation
Path string `json:"path" api:"nullable"`
// File size in bytes
SizeBytes int64 `json:"sizeBytes"`
// Last update timestamp
UpdatedAt time.Time `json:"updatedAt" format:"date-time"`
// Vault ID
VaultID string `json:"vaultId"`
JSON vaultObjectUpdateResponseJSON `json:"-"`
}
func (*VaultObjectUpdateResponse) UnmarshalJSON ¶
func (r *VaultObjectUpdateResponse) UnmarshalJSON(data []byte) (err error)
type VaultSearchParams ¶
type VaultSearchParams struct {
// Search query or question to find relevant documents
Query param.Field[string] `json:"query" api:"required"`
// Filters to narrow search results to specific documents
Filters param.Field[VaultSearchParamsFilters] `json:"filters"`
// Search method: 'global' for comprehensive questions, 'entity' for specific
// entities, 'fast' for quick similarity search, 'hybrid' for combined approach
Method param.Field[VaultSearchParamsMethod] `json:"method"`
// Maximum number of results to return
TopK param.Field[int64] `json:"topK"`
}
func (VaultSearchParams) MarshalJSON ¶
func (r VaultSearchParams) MarshalJSON() (data []byte, err error)
type VaultSearchParamsFilters ¶
type VaultSearchParamsFilters struct {
// Filter to specific document(s) by object ID. Accepts a single ID or array of
// IDs.
ObjectID param.Field[VaultSearchParamsFiltersObjectIDUnion] `json:"object_id"`
ExtraFields map[string]interface{} `json:"-,extras"`
}
Filters to narrow search results to specific documents
func (VaultSearchParamsFilters) MarshalJSON ¶
func (r VaultSearchParamsFilters) MarshalJSON() (data []byte, err error)
type VaultSearchParamsFiltersObjectIDArray ¶
type VaultSearchParamsFiltersObjectIDArray []string
func (VaultSearchParamsFiltersObjectIDArray) ImplementsVaultSearchParamsFiltersObjectIDUnion ¶
func (r VaultSearchParamsFiltersObjectIDArray) ImplementsVaultSearchParamsFiltersObjectIDUnion()
type VaultSearchParamsFiltersObjectIDUnion ¶
type VaultSearchParamsFiltersObjectIDUnion interface {
ImplementsVaultSearchParamsFiltersObjectIDUnion()
}
Filter to specific document(s) by object ID. Accepts a single ID or array of IDs.
Satisfied by [shared.UnionString], VaultSearchParamsFiltersObjectIDArray.
type VaultSearchParamsMethod ¶
type VaultSearchParamsMethod string
Search method: 'global' for comprehensive questions, 'entity' for specific entities, 'fast' for quick similarity search, 'hybrid' for combined approach
const ( VaultSearchParamsMethodVector VaultSearchParamsMethod = "vector" VaultSearchParamsMethodGraph VaultSearchParamsMethod = "graph" VaultSearchParamsMethodHybrid VaultSearchParamsMethod = "hybrid" VaultSearchParamsMethodGlobal VaultSearchParamsMethod = "global" VaultSearchParamsMethodLocal VaultSearchParamsMethod = "local" VaultSearchParamsMethodFast VaultSearchParamsMethod = "fast" VaultSearchParamsMethodEntity VaultSearchParamsMethod = "entity" )
func (VaultSearchParamsMethod) IsKnown ¶
func (r VaultSearchParamsMethod) IsKnown() bool
type VaultSearchResponse ¶
type VaultSearchResponse struct {
// Relevant text chunks with similarity scores and page locations
Chunks []VaultSearchResponseChunk `json:"chunks"`
// Search method used
Method string `json:"method"`
// Original search query
Query string `json:"query"`
// AI-generated answer based on search results (for global/entity methods)
Response string `json:"response"`
Sources []VaultSearchResponseSource `json:"sources"`
// ID of the searched vault
VaultID string `json:"vault_id"`
JSON vaultSearchResponseJSON `json:"-"`
}
func (*VaultSearchResponse) UnmarshalJSON ¶
func (r *VaultSearchResponse) UnmarshalJSON(data []byte) (err error)
type VaultSearchResponseChunk ¶
type VaultSearchResponseChunk struct {
// Index of the chunk within the document (0-based)
ChunkIndex int64 `json:"chunk_index"`
// Vector similarity distance (lower is more similar)
Distance float64 `json:"distance"`
// ID of the source document
ObjectID string `json:"object_id"`
// PDF page number where the chunk ends (1-indexed). Null for non-PDF documents or
// documents ingested before page tracking was added.
PageEnd int64 `json:"page_end" api:"nullable"`
// PDF page number where the chunk begins (1-indexed). Null for non-PDF documents
// or documents ingested before page tracking was added.
PageStart int64 `json:"page_start" api:"nullable"`
// Relevance score (deprecated, use distance or hybridScore)
Score float64 `json:"score"`
// Source identifier (deprecated, use object_id)
Source string `json:"source"`
// Preview of the chunk text (up to 500 characters)
Text string `json:"text"`
// Ending word index (0-based) in the OCR word list. Use with GET
// /vault/:id/objects/:objectId/ocr-words to retrieve bounding boxes for
// highlighting.
WordEndIndex int64 `json:"word_end_index" api:"nullable"`
// Starting word index (0-based) in the OCR word list. Use with GET
// /vault/:id/objects/:objectId/ocr-words to retrieve bounding boxes for
// highlighting.
WordStartIndex int64 `json:"word_start_index" api:"nullable"`
JSON vaultSearchResponseChunkJSON `json:"-"`
}
func (*VaultSearchResponseChunk) UnmarshalJSON ¶
func (r *VaultSearchResponseChunk) UnmarshalJSON(data []byte) (err error)
type VaultSearchResponseSource ¶
type VaultSearchResponseSource struct {
ID string `json:"id"`
ChunkCount int64 `json:"chunkCount"`
CreatedAt time.Time `json:"createdAt" format:"date-time"`
Filename string `json:"filename"`
IngestionCompletedAt time.Time `json:"ingestionCompletedAt" format:"date-time"`
PageCount int64 `json:"pageCount"`
TextLength int64 `json:"textLength"`
JSON vaultSearchResponseSourceJSON `json:"-"`
}
func (*VaultSearchResponseSource) UnmarshalJSON ¶
func (r *VaultSearchResponseSource) UnmarshalJSON(data []byte) (err error)
type VaultService ¶
type VaultService struct {
Options []option.RequestOption
Events *VaultEventService
// Secure document storage with semantic search and GraphRAG
Graphrag *VaultGraphragService
// Secure document storage with semantic search and GraphRAG
Groups *VaultGroupService
// Secure document storage with semantic search and GraphRAG
Multipart *VaultMultipartService
// Secure document storage with semantic search and GraphRAG
Objects *VaultObjectService
// Secure document storage with semantic search and GraphRAG
Memory *VaultMemoryService
}
Secure document storage with semantic search and GraphRAG
VaultService contains methods and other services that help with interacting with the casedev API.
Note, unlike clients, this service does not read variables from the environment automatically. You should not instantiate this service directly, and instead use the NewVaultService method instead.
func NewVaultService ¶
func NewVaultService(opts ...option.RequestOption) (r *VaultService)
NewVaultService generates a new service that applies the given options to each request. These options are applied after the parent client's options (if there is one), and before any request-specific options.
func (*VaultService) ConfirmUpload ¶
func (r *VaultService) ConfirmUpload(ctx context.Context, id string, objectID string, body VaultConfirmUploadParams, opts ...option.RequestOption) (res *VaultConfirmUploadResponse, err error)
Confirm whether a direct-to-S3 vault upload succeeded or failed. This endpoint emits vault.upload.completed or vault.upload.failed events and is idempotent for repeated confirmations.
func (*VaultService) Delete ¶
func (r *VaultService) Delete(ctx context.Context, id string, body VaultDeleteParams, opts ...option.RequestOption) (res *VaultDeleteResponse, err error)
Permanently deletes a vault and all its contents including documents, vectors, graph data, and S3 buckets. This operation cannot be undone. For large vaults, use the async=true query parameter to queue deletion in the background.
func (*VaultService) Get ¶
func (r *VaultService) Get(ctx context.Context, id string, opts ...option.RequestOption) (res *VaultGetResponse, err error)
Retrieve detailed information about a specific vault, including storage configuration, chunking strategy, and usage statistics. Returns vault metadata, bucket information, and vector storage details.
func (*VaultService) Ingest ¶
func (r *VaultService) Ingest(ctx context.Context, id string, objectID string, opts ...option.RequestOption) (res *VaultIngestResponse, err error)
Triggers ingestion workflow for a vault object to extract text, generate chunks, and create embeddings. For supported file types (PDF, DOCX, PPTX, TXT, RTF, XML, HTML, Markdown, CSV/TSV, JSON/YAML/TOML, common source code files, ZIP, audio, video), processing happens asynchronously. ZIP archives are unpacked recursively up to 5 levels, and each extracted file is created as an independent vault object and ingested via the normal pipeline. For unsupported types (images, etc.), the file is marked as completed immediately without text extraction. GraphRAG indexing must be triggered separately via POST /vault/:id/graphrag/:objectId.
func (*VaultService) List ¶
func (r *VaultService) List(ctx context.Context, opts ...option.RequestOption) (res *VaultListResponse, err error)
List all vaults for the authenticated organization. Returns vault metadata including name, description, storage configuration, and usage statistics.
func (*VaultService) New ¶
func (r *VaultService) New(ctx context.Context, body VaultNewParams, opts ...option.RequestOption) (res *VaultNewResponse, err error)
Creates a new secure vault with dedicated S3 storage and vector search capabilities. Each vault provides isolated document storage with semantic search, OCR processing, and optional GraphRAG knowledge graph features for legal document analysis and discovery.
func (*VaultService) Search ¶
func (r *VaultService) Search(ctx context.Context, id string, body VaultSearchParams, opts ...option.RequestOption) (res *VaultSearchResponse, err error)
Search across vault documents using multiple methods including hybrid vector + graph search, GraphRAG global search, entity-based search, and fast similarity search. Returns relevant documents and contextual answers based on the search method.
func (*VaultService) Update ¶
func (r *VaultService) Update(ctx context.Context, id string, body VaultUpdateParams, opts ...option.RequestOption) (res *VaultUpdateResponse, err error)
Update vault settings including name, description, and enableGraph. Changing enableGraph only affects future document uploads - existing documents retain their current graph/non-graph state.
func (*VaultService) Upload ¶
func (r *VaultService) Upload(ctx context.Context, id string, body VaultUploadParams, opts ...option.RequestOption) (res *VaultUploadResponse, err error)
Generate a presigned URL for uploading files directly to a vault's S3 storage. After uploading to S3, confirm the upload result via POST /vault/:vaultId/upload/:objectId/confirm before triggering ingestion.
type VaultUpdateParams ¶
type VaultUpdateParams struct {
// New description for the vault. Set to null to remove.
Description param.Field[string] `json:"description"`
// Whether to enable GraphRAG for future document uploads
EnableGraph param.Field[bool] `json:"enableGraph"`
// Move the vault to a different group, or set to null to remove from its current
// group.
GroupID param.Field[string] `json:"groupId"`
// New name for the vault
Name param.Field[string] `json:"name"`
}
func (VaultUpdateParams) MarshalJSON ¶
func (r VaultUpdateParams) MarshalJSON() (data []byte, err error)
type VaultUpdateResponse ¶
type VaultUpdateResponse struct {
// Vault identifier
ID string `json:"id"`
// Document chunking strategy configuration
ChunkStrategy interface{} `json:"chunkStrategy"`
// Vault creation timestamp
CreatedAt time.Time `json:"createdAt" format:"date-time"`
// Vault description
Description string `json:"description" api:"nullable"`
// Whether GraphRAG is enabled for future uploads
EnableGraph bool `json:"enableGraph"`
// S3 bucket for document storage
FilesBucket string `json:"filesBucket"`
// Search index name
IndexName string `json:"indexName"`
// KMS key for encryption
KmsKeyID string `json:"kmsKeyId"`
// Additional vault metadata
Metadata interface{} `json:"metadata"`
// Vault name
Name string `json:"name"`
// AWS region
Region string `json:"region"`
// Total storage size in bytes
TotalBytes int64 `json:"totalBytes"`
// Number of stored documents
TotalObjects int64 `json:"totalObjects"`
// Number of vector embeddings
TotalVectors int64 `json:"totalVectors"`
// Last update timestamp
UpdatedAt time.Time `json:"updatedAt" format:"date-time"`
// S3 bucket for vector embeddings
VectorBucket string `json:"vectorBucket" api:"nullable"`
JSON vaultUpdateResponseJSON `json:"-"`
}
func (*VaultUpdateResponse) UnmarshalJSON ¶
func (r *VaultUpdateResponse) UnmarshalJSON(data []byte) (err error)
type VaultUploadParams ¶
type VaultUploadParams struct {
// MIME type of the file (e.g., application/pdf, image/jpeg)
ContentType param.Field[string] `json:"contentType" api:"required"`
// Name of the file to upload
Filename param.Field[string] `json:"filename" api:"required"`
// Whether to automatically process and index the file for search
AutoIndex param.Field[bool] `json:"auto_index"`
// Additional metadata to associate with the file
Metadata param.Field[interface{}] `json:"metadata"`
// Optional folder path for hierarchy preservation. Allows integrations to maintain
// source folder structure from systems like NetDocs, Clio, or Smokeball. Example:
// '/Discovery/Depositions/2024'
Path param.Field[string] `json:"path"`
// File size in bytes (optional, max 5GB for single PUT uploads). When provided,
// enforces exact file size at S3 level.
SizeBytes param.Field[int64] `json:"sizeBytes"`
}
func (VaultUploadParams) MarshalJSON ¶
func (r VaultUploadParams) MarshalJSON() (data []byte, err error)
type VaultUploadResponse ¶
type VaultUploadResponse struct {
// Whether the file will be automatically indexed
AutoIndex bool `json:"auto_index"`
// Whether the vault supports indexing. False for storage-only vaults.
EnableIndexing bool `json:"enableIndexing"`
// URL expiration time in seconds
ExpiresIn float64 `json:"expiresIn"`
Instructions VaultUploadResponseInstructions `json:"instructions"`
// Next API endpoint to call for processing
NextStep string `json:"next_step" api:"nullable"`
// Unique identifier for the uploaded object
ObjectID string `json:"objectId"`
// Folder path for hierarchy if provided
Path string `json:"path" api:"nullable"`
// S3 object key for the file
S3Key string `json:"s3Key"`
// Presigned URL for uploading the file
UploadURL string `json:"uploadUrl"`
JSON vaultUploadResponseJSON `json:"-"`
}
func (*VaultUploadResponse) UnmarshalJSON ¶
func (r *VaultUploadResponse) UnmarshalJSON(data []byte) (err error)
type VaultUploadResponseInstructions ¶
type VaultUploadResponseInstructions struct {
Headers interface{} `json:"headers"`
Method string `json:"method"`
Note string `json:"note"`
JSON vaultUploadResponseInstructionsJSON `json:"-"`
}
func (*VaultUploadResponseInstructions) UnmarshalJSON ¶
func (r *VaultUploadResponseInstructions) UnmarshalJSON(data []byte) (err error)
type VoiceBoostListExtractParams ¶ added in v0.14.0
type VoiceBoostListExtractParams struct {
// Optional filter for entity categories to extract
Categories param.Field[[]VoiceBoostListExtractParamsCategory] `json:"categories"`
// Object IDs of documents to extract entities from (PDFs, text files)
ObjectIDs param.Field[[]string] `json:"object_ids"`
// Raw text input for entity extraction (alternative to vault documents)
Text param.Field[string] `json:"text"`
// Vault ID containing the source documents (use with object_ids)
VaultID param.Field[string] `json:"vault_id"`
}
func (VoiceBoostListExtractParams) MarshalJSON ¶ added in v0.14.0
func (r VoiceBoostListExtractParams) MarshalJSON() (data []byte, err error)
type VoiceBoostListExtractParamsCategory ¶ added in v0.14.0
type VoiceBoostListExtractParamsCategory string
const ( VoiceBoostListExtractParamsCategoryPerson VoiceBoostListExtractParamsCategory = "person" VoiceBoostListExtractParamsCategoryOrganization VoiceBoostListExtractParamsCategory = "organization" VoiceBoostListExtractParamsCategoryLegalTerm VoiceBoostListExtractParamsCategory = "legal_term" VoiceBoostListExtractParamsCategoryMedical VoiceBoostListExtractParamsCategory = "medical" VoiceBoostListExtractParamsCategoryCitation VoiceBoostListExtractParamsCategory = "citation" VoiceBoostListExtractParamsCategoryEmail VoiceBoostListExtractParamsCategory = "email" )
func (VoiceBoostListExtractParamsCategory) IsKnown ¶ added in v0.14.0
func (r VoiceBoostListExtractParamsCategory) IsKnown() bool
type VoiceBoostListExtractResponse ¶ added in v0.14.0
type VoiceBoostListExtractResponse struct {
Items []VoiceBoostListExtractResponseItem `json:"items"`
Source VoiceBoostListExtractResponseSource `json:"source"`
SourceIDs []string `json:"source_ids"`
JSON voiceBoostListExtractResponseJSON `json:"-"`
}
func (*VoiceBoostListExtractResponse) UnmarshalJSON ¶ added in v0.14.0
func (r *VoiceBoostListExtractResponse) UnmarshalJSON(data []byte) (err error)
type VoiceBoostListExtractResponseItem ¶ added in v0.14.0
type VoiceBoostListExtractResponseItem struct {
BoostParam VoiceBoostListExtractResponseItemsBoostParam `json:"boost_param"`
Category string `json:"category"`
Word string `json:"word"`
JSON voiceBoostListExtractResponseItemJSON `json:"-"`
}
func (*VoiceBoostListExtractResponseItem) UnmarshalJSON ¶ added in v0.14.0
func (r *VoiceBoostListExtractResponseItem) UnmarshalJSON(data []byte) (err error)
type VoiceBoostListExtractResponseItemsBoostParam ¶ added in v0.14.0
type VoiceBoostListExtractResponseItemsBoostParam string
const ( VoiceBoostListExtractResponseItemsBoostParamLow VoiceBoostListExtractResponseItemsBoostParam = "low" VoiceBoostListExtractResponseItemsBoostParamDefault VoiceBoostListExtractResponseItemsBoostParam = "default" VoiceBoostListExtractResponseItemsBoostParamHigh VoiceBoostListExtractResponseItemsBoostParam = "high" )
func (VoiceBoostListExtractResponseItemsBoostParam) IsKnown ¶ added in v0.14.0
func (r VoiceBoostListExtractResponseItemsBoostParam) IsKnown() bool
type VoiceBoostListExtractResponseSource ¶ added in v0.14.0
type VoiceBoostListExtractResponseSource string
const ( VoiceBoostListExtractResponseSourceDocument VoiceBoostListExtractResponseSource = "document" VoiceBoostListExtractResponseSourceText VoiceBoostListExtractResponseSource = "text" )
func (VoiceBoostListExtractResponseSource) IsKnown ¶ added in v0.14.0
func (r VoiceBoostListExtractResponseSource) IsKnown() bool
type VoiceBoostListGenerateParams ¶ added in v0.14.0
type VoiceBoostListGenerateParams struct {
// Completed pass-1 transcription job ID (tr\_...)
TranscriptionJobID param.Field[string] `json:"transcription_job_id" api:"required"`
// Optional filter for entity categories to extract
Categories param.Field[[]VoiceBoostListGenerateParamsCategory] `json:"categories"`
}
func (VoiceBoostListGenerateParams) MarshalJSON ¶ added in v0.14.0
func (r VoiceBoostListGenerateParams) MarshalJSON() (data []byte, err error)
type VoiceBoostListGenerateParamsCategory ¶ added in v0.14.0
type VoiceBoostListGenerateParamsCategory string
const ( VoiceBoostListGenerateParamsCategoryPerson VoiceBoostListGenerateParamsCategory = "person" VoiceBoostListGenerateParamsCategoryOrganization VoiceBoostListGenerateParamsCategory = "organization" VoiceBoostListGenerateParamsCategoryLegalTerm VoiceBoostListGenerateParamsCategory = "legal_term" VoiceBoostListGenerateParamsCategoryMedical VoiceBoostListGenerateParamsCategory = "medical" VoiceBoostListGenerateParamsCategoryCitation VoiceBoostListGenerateParamsCategory = "citation" VoiceBoostListGenerateParamsCategoryEmail VoiceBoostListGenerateParamsCategory = "email" )
func (VoiceBoostListGenerateParamsCategory) IsKnown ¶ added in v0.14.0
func (r VoiceBoostListGenerateParamsCategory) IsKnown() bool
type VoiceBoostListGenerateResponse ¶ added in v0.14.0
type VoiceBoostListGenerateResponse struct {
Items []VoiceBoostListGenerateResponseItem `json:"items"`
Source VoiceBoostListGenerateResponseSource `json:"source"`
SourceIDs []string `json:"source_ids"`
JSON voiceBoostListGenerateResponseJSON `json:"-"`
}
func (*VoiceBoostListGenerateResponse) UnmarshalJSON ¶ added in v0.14.0
func (r *VoiceBoostListGenerateResponse) UnmarshalJSON(data []byte) (err error)
type VoiceBoostListGenerateResponseItem ¶ added in v0.14.0
type VoiceBoostListGenerateResponseItem struct {
BoostParam VoiceBoostListGenerateResponseItemsBoostParam `json:"boost_param"`
Category string `json:"category"`
Word string `json:"word"`
JSON voiceBoostListGenerateResponseItemJSON `json:"-"`
}
func (*VoiceBoostListGenerateResponseItem) UnmarshalJSON ¶ added in v0.14.0
func (r *VoiceBoostListGenerateResponseItem) UnmarshalJSON(data []byte) (err error)
type VoiceBoostListGenerateResponseItemsBoostParam ¶ added in v0.14.0
type VoiceBoostListGenerateResponseItemsBoostParam string
const ( VoiceBoostListGenerateResponseItemsBoostParamLow VoiceBoostListGenerateResponseItemsBoostParam = "low" VoiceBoostListGenerateResponseItemsBoostParamDefault VoiceBoostListGenerateResponseItemsBoostParam = "default" VoiceBoostListGenerateResponseItemsBoostParamHigh VoiceBoostListGenerateResponseItemsBoostParam = "high" )
func (VoiceBoostListGenerateResponseItemsBoostParam) IsKnown ¶ added in v0.14.0
func (r VoiceBoostListGenerateResponseItemsBoostParam) IsKnown() bool
type VoiceBoostListGenerateResponseSource ¶ added in v0.14.0
type VoiceBoostListGenerateResponseSource string
const (
VoiceBoostListGenerateResponseSourceTranscript VoiceBoostListGenerateResponseSource = "transcript"
)
func (VoiceBoostListGenerateResponseSource) IsKnown ¶ added in v0.14.0
func (r VoiceBoostListGenerateResponseSource) IsKnown() bool
type VoiceBoostListService ¶ added in v0.14.0
type VoiceBoostListService struct {
Options []option.RequestOption
}
Audio transcription and text-to-speech
VoiceBoostListService contains methods and other services that help with interacting with the casedev API.
Note, unlike clients, this service does not read variables from the environment automatically. You should not instantiate this service directly, and instead use the NewVoiceBoostListService method instead.
func NewVoiceBoostListService ¶ added in v0.14.0
func NewVoiceBoostListService(opts ...option.RequestOption) (r *VoiceBoostListService)
NewVoiceBoostListService generates a new service that applies the given options to each request. These options are applied after the parent client's options (if there is one), and before any request-specific options.
func (*VoiceBoostListService) Extract ¶ added in v0.14.0
func (r *VoiceBoostListService) Extract(ctx context.Context, body VoiceBoostListExtractParams, opts ...option.RequestOption) (res *VoiceBoostListExtractResponse, err error)
Extracts a categorized word boost list from vault documents or raw text using LLM entity extraction. The resulting list can be passed as `word_boost` to the transcription endpoint for improved accuracy.
func (*VoiceBoostListService) Generate ¶ added in v0.14.0
func (r *VoiceBoostListService) Generate(ctx context.Context, body VoiceBoostListGenerateParams, opts ...option.RequestOption) (res *VoiceBoostListGenerateResponse, err error)
Generates a categorized word boost list from a completed transcription job. Extracts entities from the pass-1 transcript for use as `word_boost` in a second transcription pass.
type VoiceService ¶
type VoiceService struct {
Options []option.RequestOption
// Audio transcription and text-to-speech
Streaming *VoiceStreamingService
// Audio transcription and text-to-speech
BoostList *VoiceBoostListService
// Audio transcription and text-to-speech
Transcription *VoiceTranscriptionService
// Audio transcription and text-to-speech
V1 *VoiceV1Service
}
VoiceService contains methods and other services that help with interacting with the casedev API.
Note, unlike clients, this service does not read variables from the environment automatically. You should not instantiate this service directly, and instead use the NewVoiceService method instead.
func NewVoiceService ¶
func NewVoiceService(opts ...option.RequestOption) (r *VoiceService)
NewVoiceService generates a new service that applies the given options to each request. These options are applied after the parent client's options (if there is one), and before any request-specific options.
type VoiceStreamingGetURLResponse ¶
type VoiceStreamingGetURLResponse struct {
AudioFormat VoiceStreamingGetURLResponseAudioFormat `json:"audio_format"`
// Complete WebSocket URL with authentication token
ConnectURL string `json:"connect_url"`
Pricing VoiceStreamingGetURLResponsePricing `json:"pricing"`
// Connection protocol
Protocol string `json:"protocol"`
// Base WebSocket URL for streaming transcription
URL string `json:"url"`
JSON voiceStreamingGetURLResponseJSON `json:"-"`
}
func (*VoiceStreamingGetURLResponse) UnmarshalJSON ¶
func (r *VoiceStreamingGetURLResponse) UnmarshalJSON(data []byte) (err error)
type VoiceStreamingGetURLResponseAudioFormat ¶
type VoiceStreamingGetURLResponseAudioFormat struct {
// Number of audio channels
Channels int64 `json:"channels"`
// Required audio encoding format
Encoding string `json:"encoding"`
// Required audio sample rate in Hz
SampleRate int64 `json:"sample_rate"`
JSON voiceStreamingGetURLResponseAudioFormatJSON `json:"-"`
}
func (*VoiceStreamingGetURLResponseAudioFormat) UnmarshalJSON ¶
func (r *VoiceStreamingGetURLResponseAudioFormat) UnmarshalJSON(data []byte) (err error)
type VoiceStreamingGetURLResponsePricing ¶
type VoiceStreamingGetURLResponsePricing struct {
// Currency for pricing
Currency string `json:"currency"`
// Cost per hour of transcription
PerHour float64 `json:"per_hour"`
// Cost per minute of transcription
PerMinute float64 `json:"per_minute"`
JSON voiceStreamingGetURLResponsePricingJSON `json:"-"`
}
func (*VoiceStreamingGetURLResponsePricing) UnmarshalJSON ¶
func (r *VoiceStreamingGetURLResponsePricing) UnmarshalJSON(data []byte) (err error)
type VoiceStreamingService ¶
type VoiceStreamingService struct {
Options []option.RequestOption
}
Audio transcription and text-to-speech
VoiceStreamingService contains methods and other services that help with interacting with the casedev API.
Note, unlike clients, this service does not read variables from the environment automatically. You should not instantiate this service directly, and instead use the NewVoiceStreamingService method instead.
func NewVoiceStreamingService ¶
func NewVoiceStreamingService(opts ...option.RequestOption) (r *VoiceStreamingService)
NewVoiceStreamingService generates a new service that applies the given options to each request. These options are applied after the parent client's options (if there is one), and before any request-specific options.
func (*VoiceStreamingService) GetURL ¶
func (r *VoiceStreamingService) GetURL(ctx context.Context, opts ...option.RequestOption) (res *VoiceStreamingGetURLResponse, err error)
Returns the WebSocket URL and connection details for real-time audio transcription. The returned URL can be used to establish a WebSocket connection for streaming audio data and receiving transcribed text in real-time.
**Audio Requirements:**
- Sample Rate: 16kHz - Encoding: PCM 16-bit little-endian - Channels: Mono (1 channel)
**Pricing:** $0.01 per minute ($0.60 per hour)
type VoiceTranscriptionGetParams ¶ added in v0.28.0
type VoiceTranscriptionGetParams struct {
// Include full transcript text in response for vault-based jobs (default: false)
IncludeText param.Field[VoiceTranscriptionGetParamsIncludeText] `query:"include_text"`
}
func (VoiceTranscriptionGetParams) URLQuery ¶ added in v0.28.0
func (r VoiceTranscriptionGetParams) URLQuery() (v url.Values)
URLQuery serializes VoiceTranscriptionGetParams's query parameters as `url.Values`.
type VoiceTranscriptionGetParamsIncludeText ¶ added in v0.28.0
type VoiceTranscriptionGetParamsIncludeText string
Include full transcript text in response for vault-based jobs (default: false)
const ( VoiceTranscriptionGetParamsIncludeTextTrue VoiceTranscriptionGetParamsIncludeText = "true" VoiceTranscriptionGetParamsIncludeTextFalse VoiceTranscriptionGetParamsIncludeText = "false" )
func (VoiceTranscriptionGetParamsIncludeText) IsKnown ¶ added in v0.28.0
func (r VoiceTranscriptionGetParamsIncludeText) IsKnown() bool
type VoiceTranscriptionGetResponse ¶
type VoiceTranscriptionGetResponse struct {
// Unique transcription job ID
ID string `json:"id" api:"required"`
// Current status of the transcription job
Status VoiceTranscriptionGetResponseStatus `json:"status" api:"required"`
// Duration of the audio file in seconds
AudioDuration float64 `json:"audio_duration"`
// Overall confidence score (0-100)
Confidence float64 `json:"confidence"`
// Error message (only present when status is failed)
Error string `json:"error"`
// Result transcript object ID (vault-based jobs, when completed)
ResultObjectID string `json:"result_object_id"`
// Source audio object ID (vault-based jobs only)
SourceObjectID string `json:"source_object_id"`
// Full transcription text (only included when include_text=true for vault-based
// jobs, or for legacy direct URL jobs)
Text string `json:"text"`
// Vault ID (vault-based jobs only)
VaultID string `json:"vault_id"`
// Number of words in the transcript
WordCount int64 `json:"word_count"`
// Word-level timestamps (legacy direct URL jobs only)
Words []interface{} `json:"words"`
JSON voiceTranscriptionGetResponseJSON `json:"-"`
}
func (*VoiceTranscriptionGetResponse) UnmarshalJSON ¶
func (r *VoiceTranscriptionGetResponse) UnmarshalJSON(data []byte) (err error)
type VoiceTranscriptionGetResponseStatus ¶
type VoiceTranscriptionGetResponseStatus string
Current status of the transcription job
const ( VoiceTranscriptionGetResponseStatusQueued VoiceTranscriptionGetResponseStatus = "queued" VoiceTranscriptionGetResponseStatusProcessing VoiceTranscriptionGetResponseStatus = "processing" VoiceTranscriptionGetResponseStatusCompleted VoiceTranscriptionGetResponseStatus = "completed" VoiceTranscriptionGetResponseStatusFailed VoiceTranscriptionGetResponseStatus = "failed" )
func (VoiceTranscriptionGetResponseStatus) IsKnown ¶
func (r VoiceTranscriptionGetResponseStatus) IsKnown() bool
type VoiceTranscriptionNewParams ¶
type VoiceTranscriptionNewParams struct {
// URL of the audio file to transcribe (legacy mode, no auto-storage)
AudioURL param.Field[string] `json:"audio_url"`
// Automatically extract key phrases and topics
AutoHighlights param.Field[bool] `json:"auto_highlights"`
// How much to boost custom vocabulary
BoostParam param.Field[VoiceTranscriptionNewParamsBoostParam] `json:"boost_param"`
// Enable content moderation and safety labeling
ContentSafety param.Field[bool] `json:"content_safety"`
// Output format for the transcript when using vault mode
Format param.Field[VoiceTranscriptionNewParamsFormat] `json:"format"`
// Format text with proper capitalization
FormatText param.Field[bool] `json:"format_text"`
// Language code (e.g., 'en_us', 'es', 'fr'). If not specified, language will be
// auto-detected
LanguageCode param.Field[string] `json:"language_code"`
// Enable automatic language detection
LanguageDetection param.Field[bool] `json:"language_detection"`
// Object ID of the audio file in the vault (use with vault_id)
ObjectID param.Field[string] `json:"object_id"`
// Add punctuation to the transcript
Punctuate param.Field[bool] `json:"punctuate"`
// Enable speaker identification and labeling
SpeakerLabels param.Field[bool] `json:"speaker_labels"`
// Expected number of speakers (improves accuracy when known)
SpeakersExpected param.Field[int64] `json:"speakers_expected"`
// Priority-ordered speech models to use
SpeechModels param.Field[[]string] `json:"speech_models"`
// Vault ID containing the audio file (use with object_id)
VaultID param.Field[string] `json:"vault_id"`
// Custom vocabulary words to boost (e.g., legal terms)
WordBoost param.Field[[]string] `json:"word_boost"`
}
func (VoiceTranscriptionNewParams) MarshalJSON ¶
func (r VoiceTranscriptionNewParams) MarshalJSON() (data []byte, err error)
type VoiceTranscriptionNewParamsBoostParam ¶
type VoiceTranscriptionNewParamsBoostParam string
How much to boost custom vocabulary
const ( VoiceTranscriptionNewParamsBoostParamLow VoiceTranscriptionNewParamsBoostParam = "low" VoiceTranscriptionNewParamsBoostParamDefault VoiceTranscriptionNewParamsBoostParam = "default" VoiceTranscriptionNewParamsBoostParamHigh VoiceTranscriptionNewParamsBoostParam = "high" )
func (VoiceTranscriptionNewParamsBoostParam) IsKnown ¶
func (r VoiceTranscriptionNewParamsBoostParam) IsKnown() bool
type VoiceTranscriptionNewParamsFormat ¶
type VoiceTranscriptionNewParamsFormat string
Output format for the transcript when using vault mode
const ( VoiceTranscriptionNewParamsFormatJson VoiceTranscriptionNewParamsFormat = "json" VoiceTranscriptionNewParamsFormatText VoiceTranscriptionNewParamsFormat = "text" )
func (VoiceTranscriptionNewParamsFormat) IsKnown ¶
func (r VoiceTranscriptionNewParamsFormat) IsKnown() bool
type VoiceTranscriptionNewResponse ¶
type VoiceTranscriptionNewResponse struct {
// Unique transcription job ID
ID string `json:"id"`
// Source audio object ID (only for vault-based transcription)
SourceObjectID string `json:"source_object_id"`
// Current status of the transcription job
Status VoiceTranscriptionNewResponseStatus `json:"status"`
// Vault ID (only for vault-based transcription)
VaultID string `json:"vault_id"`
JSON voiceTranscriptionNewResponseJSON `json:"-"`
}
func (*VoiceTranscriptionNewResponse) UnmarshalJSON ¶
func (r *VoiceTranscriptionNewResponse) UnmarshalJSON(data []byte) (err error)
type VoiceTranscriptionNewResponseStatus ¶
type VoiceTranscriptionNewResponseStatus string
Current status of the transcription job
const ( VoiceTranscriptionNewResponseStatusQueued VoiceTranscriptionNewResponseStatus = "queued" VoiceTranscriptionNewResponseStatusProcessing VoiceTranscriptionNewResponseStatus = "processing" VoiceTranscriptionNewResponseStatusCompleted VoiceTranscriptionNewResponseStatus = "completed" VoiceTranscriptionNewResponseStatusError VoiceTranscriptionNewResponseStatus = "error" )
func (VoiceTranscriptionNewResponseStatus) IsKnown ¶
func (r VoiceTranscriptionNewResponseStatus) IsKnown() bool
type VoiceTranscriptionService ¶
type VoiceTranscriptionService struct {
Options []option.RequestOption
}
Audio transcription and text-to-speech
VoiceTranscriptionService contains methods and other services that help with interacting with the casedev API.
Note, unlike clients, this service does not read variables from the environment automatically. You should not instantiate this service directly, and instead use the NewVoiceTranscriptionService method instead.
func NewVoiceTranscriptionService ¶
func NewVoiceTranscriptionService(opts ...option.RequestOption) (r *VoiceTranscriptionService)
NewVoiceTranscriptionService generates a new service that applies the given options to each request. These options are applied after the parent client's options (if there is one), and before any request-specific options.
func (*VoiceTranscriptionService) Delete ¶
func (r *VoiceTranscriptionService) Delete(ctx context.Context, id string, opts ...option.RequestOption) (err error)
Deletes a transcription job. For managed vault jobs (tr\_\*), also removes local job records and managed transcript result objects. Idempotent: returns success if already deleted.
func (*VoiceTranscriptionService) Get ¶
func (r *VoiceTranscriptionService) Get(ctx context.Context, id string, query VoiceTranscriptionGetParams, opts ...option.RequestOption) (res *VoiceTranscriptionGetResponse, err error)
Retrieve the status and result of an audio transcription job. For vault-based jobs, returns status and result_object_id when complete. For legacy direct URL jobs, returns the full transcription data.
func (*VoiceTranscriptionService) New ¶
func (r *VoiceTranscriptionService) New(ctx context.Context, body VoiceTranscriptionNewParams, opts ...option.RequestOption) (res *VoiceTranscriptionNewResponse, err error)
Creates an asynchronous transcription job for audio files. Supports two modes:
**Vault-based (recommended)**: Pass `vault_id` and `object_id` to transcribe audio from your vault. The transcript will automatically be saved back to the vault when complete.
**Direct URL (legacy)**: Pass `audio_url` for direct transcription without automatic storage.
type VoiceV1ListVoicesParams ¶
type VoiceV1ListVoicesParams struct {
// Filter by voice category
Category param.Field[string] `query:"category"`
// Filter by voice collection ID
CollectionID param.Field[string] `query:"collection_id"`
// Whether to include total count in response
IncludeTotalCount param.Field[bool] `query:"include_total_count"`
// Token for retrieving the next page of results
NextPageToken param.Field[string] `query:"next_page_token"`
// Number of voices to return per page (max 100)
PageSize param.Field[int64] `query:"page_size"`
// Search term to filter voices by name or description
Search param.Field[string] `query:"search"`
// Field to sort by
Sort param.Field[VoiceV1ListVoicesParamsSort] `query:"sort"`
// Sort direction
SortDirection param.Field[VoiceV1ListVoicesParamsSortDirection] `query:"sort_direction"`
// Filter by voice type
VoiceType param.Field[VoiceV1ListVoicesParamsVoiceType] `query:"voice_type"`
}
func (VoiceV1ListVoicesParams) URLQuery ¶
func (r VoiceV1ListVoicesParams) URLQuery() (v url.Values)
URLQuery serializes VoiceV1ListVoicesParams's query parameters as `url.Values`.
type VoiceV1ListVoicesParamsSort ¶
type VoiceV1ListVoicesParamsSort string
Field to sort by
const ( VoiceV1ListVoicesParamsSortName VoiceV1ListVoicesParamsSort = "name" VoiceV1ListVoicesParamsSortCreatedAt VoiceV1ListVoicesParamsSort = "created_at" VoiceV1ListVoicesParamsSortUpdatedAt VoiceV1ListVoicesParamsSort = "updated_at" )
func (VoiceV1ListVoicesParamsSort) IsKnown ¶
func (r VoiceV1ListVoicesParamsSort) IsKnown() bool
type VoiceV1ListVoicesParamsSortDirection ¶
type VoiceV1ListVoicesParamsSortDirection string
Sort direction
const ( VoiceV1ListVoicesParamsSortDirectionAsc VoiceV1ListVoicesParamsSortDirection = "asc" VoiceV1ListVoicesParamsSortDirectionDesc VoiceV1ListVoicesParamsSortDirection = "desc" )
func (VoiceV1ListVoicesParamsSortDirection) IsKnown ¶
func (r VoiceV1ListVoicesParamsSortDirection) IsKnown() bool
type VoiceV1ListVoicesParamsVoiceType ¶
type VoiceV1ListVoicesParamsVoiceType string
Filter by voice type
const ( VoiceV1ListVoicesParamsVoiceTypePremade VoiceV1ListVoicesParamsVoiceType = "premade" VoiceV1ListVoicesParamsVoiceTypeCloned VoiceV1ListVoicesParamsVoiceType = "cloned" VoiceV1ListVoicesParamsVoiceTypeProfessional VoiceV1ListVoicesParamsVoiceType = "professional" )
func (VoiceV1ListVoicesParamsVoiceType) IsKnown ¶
func (r VoiceV1ListVoicesParamsVoiceType) IsKnown() bool
type VoiceV1ListVoicesResponse ¶
type VoiceV1ListVoicesResponse struct {
// Token for next page of results
NextPageToken string `json:"next_page_token"`
// Total number of voices (if requested)
TotalCount int64 `json:"total_count"`
Voices []VoiceV1ListVoicesResponseVoice `json:"voices"`
JSON voiceV1ListVoicesResponseJSON `json:"-"`
}
func (*VoiceV1ListVoicesResponse) UnmarshalJSON ¶
func (r *VoiceV1ListVoicesResponse) UnmarshalJSON(data []byte) (err error)
type VoiceV1ListVoicesResponseVoice ¶
type VoiceV1ListVoicesResponseVoice struct {
// Available subscription tiers
AvailableForTiers []string `json:"available_for_tiers"`
// Voice category
Category string `json:"category"`
// Voice description
Description string `json:"description"`
// Voice characteristics and metadata
Labels interface{} `json:"labels"`
// Voice name
Name string `json:"name"`
// URL to preview audio sample
PreviewURL string `json:"preview_url"`
// Unique voice identifier
VoiceID string `json:"voice_id"`
JSON voiceV1ListVoicesResponseVoiceJSON `json:"-"`
}
func (*VoiceV1ListVoicesResponseVoice) UnmarshalJSON ¶
func (r *VoiceV1ListVoicesResponseVoice) UnmarshalJSON(data []byte) (err error)
type VoiceV1Service ¶
type VoiceV1Service struct {
Options []option.RequestOption
// Audio transcription and text-to-speech
Speak *VoiceV1SpeakService
}
Audio transcription and text-to-speech
VoiceV1Service contains methods and other services that help with interacting with the casedev API.
Note, unlike clients, this service does not read variables from the environment automatically. You should not instantiate this service directly, and instead use the NewVoiceV1Service method instead.
func NewVoiceV1Service ¶
func NewVoiceV1Service(opts ...option.RequestOption) (r *VoiceV1Service)
NewVoiceV1Service generates a new service that applies the given options to each request. These options are applied after the parent client's options (if there is one), and before any request-specific options.
func (*VoiceV1Service) ListVoices ¶
func (r *VoiceV1Service) ListVoices(ctx context.Context, query VoiceV1ListVoicesParams, opts ...option.RequestOption) (res *VoiceV1ListVoicesResponse, err error)
Retrieve a list of available voices for text-to-speech synthesis. This endpoint provides access to a comprehensive catalog of voices with various characteristics, languages, and styles suitable for legal document narration, client presentations, and accessibility purposes.
type VoiceV1SpeakNewParams ¶
type VoiceV1SpeakNewParams struct {
// Text to convert to speech
Text param.Field[string] `json:"text" api:"required"`
// Apply automatic text normalization
ApplyTextNormalization param.Field[bool] `json:"apply_text_normalization"`
// Enable request logging
EnableLogging param.Field[bool] `json:"enable_logging"`
// Language code for multilingual models
LanguageCode param.Field[string] `json:"language_code"`
// ElevenLabs model ID
ModelID param.Field[VoiceV1SpeakNewParamsModelID] `json:"model_id"`
// Next context for better pronunciation
NextText param.Field[string] `json:"next_text"`
// Optimize for streaming latency (0-4)
OptimizeStreamingLatency param.Field[int64] `json:"optimize_streaming_latency"`
// Audio output format
OutputFormat param.Field[VoiceV1SpeakNewParamsOutputFormat] `json:"output_format"`
// Previous context for better pronunciation
PreviousText param.Field[string] `json:"previous_text"`
// Seed for reproducible generation
Seed param.Field[int64] `json:"seed"`
// ElevenLabs voice ID (defaults to Rachel - professional, clear)
VoiceID param.Field[string] `json:"voice_id"`
// Voice customization settings
VoiceSettings param.Field[VoiceV1SpeakNewParamsVoiceSettings] `json:"voice_settings"`
}
func (VoiceV1SpeakNewParams) MarshalJSON ¶
func (r VoiceV1SpeakNewParams) MarshalJSON() (data []byte, err error)
type VoiceV1SpeakNewParamsModelID ¶
type VoiceV1SpeakNewParamsModelID string
ElevenLabs model ID
const ( VoiceV1SpeakNewParamsModelIDElevenMultilingualV2 VoiceV1SpeakNewParamsModelID = "eleven_multilingual_v2" VoiceV1SpeakNewParamsModelIDElevenTurboV2 VoiceV1SpeakNewParamsModelID = "eleven_turbo_v2" VoiceV1SpeakNewParamsModelIDElevenMonolingualV1 VoiceV1SpeakNewParamsModelID = "eleven_monolingual_v1" )
func (VoiceV1SpeakNewParamsModelID) IsKnown ¶
func (r VoiceV1SpeakNewParamsModelID) IsKnown() bool
type VoiceV1SpeakNewParamsOutputFormat ¶
type VoiceV1SpeakNewParamsOutputFormat string
Audio output format
const ( VoiceV1SpeakNewParamsOutputFormatMP3_44100_128 VoiceV1SpeakNewParamsOutputFormat = "mp3_44100_128" VoiceV1SpeakNewParamsOutputFormatMP3_44100_192 VoiceV1SpeakNewParamsOutputFormat = "mp3_44100_192" VoiceV1SpeakNewParamsOutputFormatPcm16000 VoiceV1SpeakNewParamsOutputFormat = "pcm_16000" VoiceV1SpeakNewParamsOutputFormatPcm22050 VoiceV1SpeakNewParamsOutputFormat = "pcm_22050" VoiceV1SpeakNewParamsOutputFormatPcm24000 VoiceV1SpeakNewParamsOutputFormat = "pcm_24000" VoiceV1SpeakNewParamsOutputFormatPcm44100 VoiceV1SpeakNewParamsOutputFormat = "pcm_44100" )
func (VoiceV1SpeakNewParamsOutputFormat) IsKnown ¶
func (r VoiceV1SpeakNewParamsOutputFormat) IsKnown() bool
type VoiceV1SpeakNewParamsVoiceSettings ¶
type VoiceV1SpeakNewParamsVoiceSettings struct {
// Similarity boost (0-1)
SimilarityBoost param.Field[float64] `json:"similarity_boost"`
// Voice stability (0-1)
Stability param.Field[float64] `json:"stability"`
// Style exaggeration (0-1)
Style param.Field[float64] `json:"style"`
// Enable speaker boost
UseSpeakerBoost param.Field[bool] `json:"use_speaker_boost"`
}
Voice customization settings
func (VoiceV1SpeakNewParamsVoiceSettings) MarshalJSON ¶
func (r VoiceV1SpeakNewParamsVoiceSettings) MarshalJSON() (data []byte, err error)
type VoiceV1SpeakService ¶
type VoiceV1SpeakService struct {
Options []option.RequestOption
}
Audio transcription and text-to-speech
VoiceV1SpeakService contains methods and other services that help with interacting with the casedev API.
Note, unlike clients, this service does not read variables from the environment automatically. You should not instantiate this service directly, and instead use the NewVoiceV1SpeakService method instead.
func NewVoiceV1SpeakService ¶
func NewVoiceV1SpeakService(opts ...option.RequestOption) (r *VoiceV1SpeakService)
NewVoiceV1SpeakService generates a new service that applies the given options to each request. These options are applied after the parent client's options (if there is one), and before any request-specific options.
func (*VoiceV1SpeakService) New ¶
func (r *VoiceV1SpeakService) New(ctx context.Context, body VoiceV1SpeakNewParams, opts ...option.RequestOption) (res *http.Response, err error)
Convert text to natural-sounding audio using ElevenLabs voices. Ideal for creating audio summaries of legal documents, client presentations, or accessibility features. Supports multiple languages and voice customization.
type WebhookService ¶ added in v0.42.0
type WebhookService struct {
Options []option.RequestOption
V1 *WebhookV1Service
}
WebhookService contains methods and other services that help with interacting with the casedev API.
Note, unlike clients, this service does not read variables from the environment automatically. You should not instantiate this service directly, and instead use the NewWebhookService method instead.
func NewWebhookService ¶ added in v0.42.0
func NewWebhookService(opts ...option.RequestOption) (r *WebhookService)
NewWebhookService generates a new service that applies the given options to each request. These options are applied after the parent client's options (if there is one), and before any request-specific options.
type WebhookV1DeliveryListParams ¶ added in v0.42.0
type WebhookV1DeliveryListParams struct {
EndpointID param.Field[string] `query:"endpoint_id"`
Limit param.Field[int64] `query:"limit"`
Status param.Field[WebhookV1DeliveryListParamsStatus] `query:"status"`
}
func (WebhookV1DeliveryListParams) URLQuery ¶ added in v0.42.0
func (r WebhookV1DeliveryListParams) URLQuery() (v url.Values)
URLQuery serializes WebhookV1DeliveryListParams's query parameters as `url.Values`.
type WebhookV1DeliveryListParamsStatus ¶ added in v0.42.0
type WebhookV1DeliveryListParamsStatus string
const ( WebhookV1DeliveryListParamsStatusPending WebhookV1DeliveryListParamsStatus = "pending" WebhookV1DeliveryListParamsStatusDelivered WebhookV1DeliveryListParamsStatus = "delivered" WebhookV1DeliveryListParamsStatusFailed WebhookV1DeliveryListParamsStatus = "failed" )
func (WebhookV1DeliveryListParamsStatus) IsKnown ¶ added in v0.42.0
func (r WebhookV1DeliveryListParamsStatus) IsKnown() bool
type WebhookV1DeliveryReplayParams ¶ added in v0.42.0
type WebhookV1DeliveryReplayParams struct {
// Override payload to deliver. Must only be supplied when the delivery record
// lacks enough context to reconstruct the original event (rare). Defaults to an
// empty data envelope.
Payload param.Field[interface{}] `json:"payload"`
}
func (WebhookV1DeliveryReplayParams) MarshalJSON ¶ added in v0.42.0
func (r WebhookV1DeliveryReplayParams) MarshalJSON() (data []byte, err error)
type WebhookV1DeliveryService ¶ added in v0.42.0
type WebhookV1DeliveryService struct {
Options []option.RequestOption
}
Webhook endpoint management
WebhookV1DeliveryService contains methods and other services that help with interacting with the casedev API.
Note, unlike clients, this service does not read variables from the environment automatically. You should not instantiate this service directly, and instead use the NewWebhookV1DeliveryService method instead.
func NewWebhookV1DeliveryService ¶ added in v0.42.0
func NewWebhookV1DeliveryService(opts ...option.RequestOption) (r *WebhookV1DeliveryService)
NewWebhookV1DeliveryService generates a new service that applies the given options to each request. These options are applied after the parent client's options (if there is one), and before any request-specific options.
func (*WebhookV1DeliveryService) Get ¶ added in v0.42.0
func (r *WebhookV1DeliveryService) Get(ctx context.Context, id string, opts ...option.RequestOption) (err error)
Get webhook delivery
func (*WebhookV1DeliveryService) List ¶ added in v0.42.0
func (r *WebhookV1DeliveryService) List(ctx context.Context, query WebhookV1DeliveryListParams, opts ...option.RequestOption) (err error)
Returns delivery attempts for the organization, newest first. Filter by endpoint_id or status to narrow results.
func (*WebhookV1DeliveryService) Replay ¶ added in v0.42.0
func (r *WebhookV1DeliveryService) Replay(ctx context.Context, id string, body WebhookV1DeliveryReplayParams, opts ...option.RequestOption) (err error)
Re-sends the original event to its endpoint. The payload is reconstructed from the delivery record (same eventId, eventType, and occurred_at). Replay deliveries include a Case.dev replay marker header so receivers can distinguish replays from first-time deliveries. Uses the endpoint's current signing secret — not the one in force at the original delivery time.
type WebhookV1EndpointListParams ¶ added in v0.42.0
type WebhookV1EndpointListParams struct {
Limit param.Field[int64] `query:"limit"`
// Filter by endpoint status
Status param.Field[WebhookV1EndpointListParamsStatus] `query:"status"`
}
func (WebhookV1EndpointListParams) URLQuery ¶ added in v0.42.0
func (r WebhookV1EndpointListParams) URLQuery() (v url.Values)
URLQuery serializes WebhookV1EndpointListParams's query parameters as `url.Values`.
type WebhookV1EndpointListParamsStatus ¶ added in v0.42.0
type WebhookV1EndpointListParamsStatus string
Filter by endpoint status
const ( WebhookV1EndpointListParamsStatusActive WebhookV1EndpointListParamsStatus = "active" WebhookV1EndpointListParamsStatusDisabled WebhookV1EndpointListParamsStatus = "disabled" WebhookV1EndpointListParamsStatusAutoDisabled WebhookV1EndpointListParamsStatus = "auto_disabled" )
func (WebhookV1EndpointListParamsStatus) IsKnown ¶ added in v0.42.0
func (r WebhookV1EndpointListParamsStatus) IsKnown() bool
type WebhookV1EndpointNewParams ¶ added in v0.42.0
type WebhookV1EndpointNewParams struct {
// Glob patterns of event types to deliver (e.g. "vault._", "ocr.job.completed",
// "_")
EventTypeFilters param.Field[[]string] `json:"eventTypeFilters" api:"required"`
// HTTPS callback URL that will receive event deliveries
URL param.Field[string] `json:"url" api:"required" format:"uri"`
// Human-readable label for this endpoint
Description param.Field[string] `json:"description"`
// Optional per-resource allowlists. If vaultIds is set, only events for those
// vaults are delivered. Same for matterIds.
ResourceScopes param.Field[WebhookV1EndpointNewParamsResourceScopes] `json:"resourceScopes"`
}
func (WebhookV1EndpointNewParams) MarshalJSON ¶ added in v0.42.0
func (r WebhookV1EndpointNewParams) MarshalJSON() (data []byte, err error)
type WebhookV1EndpointNewParamsResourceScopes ¶ added in v0.42.0
type WebhookV1EndpointNewParamsResourceScopes struct {
MatterIDs param.Field[[]string] `json:"matterIds"`
VaultIDs param.Field[[]string] `json:"vaultIds"`
}
Optional per-resource allowlists. If vaultIds is set, only events for those vaults are delivered. Same for matterIds.
func (WebhookV1EndpointNewParamsResourceScopes) MarshalJSON ¶ added in v0.42.0
func (r WebhookV1EndpointNewParamsResourceScopes) MarshalJSON() (data []byte, err error)
type WebhookV1EndpointRotateSecretParams ¶ added in v0.42.0
type WebhookV1EndpointRotateSecretParams struct {
// How long (seconds) the old secret continues to be accepted. 0 invalidates
// immediately. Default: 86400 (24h).
PreviousSecretExpiresInSec param.Field[int64] `json:"previousSecretExpiresInSec"`
}
func (WebhookV1EndpointRotateSecretParams) MarshalJSON ¶ added in v0.42.0
func (r WebhookV1EndpointRotateSecretParams) MarshalJSON() (data []byte, err error)
type WebhookV1EndpointService ¶ added in v0.42.0
type WebhookV1EndpointService struct {
Options []option.RequestOption
}
Webhook endpoint management
WebhookV1EndpointService contains methods and other services that help with interacting with the casedev API.
Note, unlike clients, this service does not read variables from the environment automatically. You should not instantiate this service directly, and instead use the NewWebhookV1EndpointService method instead.
func NewWebhookV1EndpointService ¶ added in v0.42.0
func NewWebhookV1EndpointService(opts ...option.RequestOption) (r *WebhookV1EndpointService)
NewWebhookV1EndpointService generates a new service that applies the given options to each request. These options are applied after the parent client's options (if there is one), and before any request-specific options.
func (*WebhookV1EndpointService) Delete ¶ added in v0.42.0
func (r *WebhookV1EndpointService) Delete(ctx context.Context, id string, opts ...option.RequestOption) (err error)
Soft-deletes a webhook endpoint. Delivery stops immediately and the endpoint no longer appears in list results. Delivery history is preserved (and can be fetched via GET /deliveries with the endpoint_id filter) so audit trails and post-mortem debugging remain possible.
func (*WebhookV1EndpointService) Get ¶ added in v0.42.0
func (r *WebhookV1EndpointService) Get(ctx context.Context, id string, opts ...option.RequestOption) (err error)
Get webhook endpoint
func (*WebhookV1EndpointService) List ¶ added in v0.42.0
func (r *WebhookV1EndpointService) List(ctx context.Context, query WebhookV1EndpointListParams, opts ...option.RequestOption) (err error)
Returns the organization's webhook endpoints, newest first. Signing secrets are never included.
func (*WebhookV1EndpointService) New ¶ added in v0.42.0
func (r *WebhookV1EndpointService) New(ctx context.Context, body WebhookV1EndpointNewParams, opts ...option.RequestOption) (err error)
Creates a webhook endpoint that receives platform events matching the supplied event-type filters. Returns the generated signing secret ONCE — the response is the only time it is shown in plaintext.
func (*WebhookV1EndpointService) RotateSecret ¶ added in v0.42.0
func (r *WebhookV1EndpointService) RotateSecret(ctx context.Context, id string, body WebhookV1EndpointRotateSecretParams, opts ...option.RequestOption) (err error)
Generates a new signing secret for the endpoint. The previous secret remains valid until `previousSecretExpiresInSec` elapses (default 24h, max 30 days). During the grace window deliveries are signed with both secrets so receivers can migrate without downtime. Returns the new secret — this is the only time it is shown in plaintext.
func (*WebhookV1EndpointService) Test ¶ added in v0.42.0
func (r *WebhookV1EndpointService) Test(ctx context.Context, id string, body WebhookV1EndpointTestParams, opts ...option.RequestOption) (err error)
Synchronously delivers a synthetic `webhook.test` event to the endpoint and returns the HTTP result. No retries. Useful for validating that a new endpoint is reachable and its signature verifier works. The delivery is not persisted in the delivery history.
func (*WebhookV1EndpointService) Update ¶ added in v0.42.0
func (r *WebhookV1EndpointService) Update(ctx context.Context, id string, body WebhookV1EndpointUpdateParams, opts ...option.RequestOption) (err error)
Partially updates a webhook endpoint. Any omitted field is left unchanged. Signing secrets are rotated via the separate /rotate_secret endpoint.
type WebhookV1EndpointTestParams ¶ added in v0.42.0
type WebhookV1EndpointTestParams struct {
// Event type to simulate. Defaults to "webhook.test".
EventType param.Field[string] `json:"eventType"`
// Custom `data` payload. Defaults to a small placeholder.
Payload param.Field[interface{}] `json:"payload"`
}
func (WebhookV1EndpointTestParams) MarshalJSON ¶ added in v0.42.0
func (r WebhookV1EndpointTestParams) MarshalJSON() (data []byte, err error)
type WebhookV1EndpointUpdateParams ¶ added in v0.42.0
type WebhookV1EndpointUpdateParams struct {
Description param.Field[string] `json:"description"`
EventTypeFilters param.Field[[]string] `json:"eventTypeFilters"`
ResourceScopes param.Field[WebhookV1EndpointUpdateParamsResourceScopes] `json:"resourceScopes"`
Status param.Field[WebhookV1EndpointUpdateParamsStatus] `json:"status"`
URL param.Field[string] `json:"url" format:"uri"`
}
func (WebhookV1EndpointUpdateParams) MarshalJSON ¶ added in v0.42.0
func (r WebhookV1EndpointUpdateParams) MarshalJSON() (data []byte, err error)
type WebhookV1EndpointUpdateParamsResourceScopes ¶ added in v0.42.0
type WebhookV1EndpointUpdateParamsResourceScopes struct {
MatterIDs param.Field[[]string] `json:"matterIds"`
VaultIDs param.Field[[]string] `json:"vaultIds"`
}
func (WebhookV1EndpointUpdateParamsResourceScopes) MarshalJSON ¶ added in v0.42.0
func (r WebhookV1EndpointUpdateParamsResourceScopes) MarshalJSON() (data []byte, err error)
type WebhookV1EndpointUpdateParamsStatus ¶ added in v0.42.0
type WebhookV1EndpointUpdateParamsStatus string
const ( WebhookV1EndpointUpdateParamsStatusActive WebhookV1EndpointUpdateParamsStatus = "active" WebhookV1EndpointUpdateParamsStatusDisabled WebhookV1EndpointUpdateParamsStatus = "disabled" )
func (WebhookV1EndpointUpdateParamsStatus) IsKnown ¶ added in v0.42.0
func (r WebhookV1EndpointUpdateParamsStatus) IsKnown() bool
type WebhookV1EventTypeService ¶ added in v0.42.0
type WebhookV1EventTypeService struct {
Options []option.RequestOption
}
Webhook endpoint management
WebhookV1EventTypeService contains methods and other services that help with interacting with the casedev API.
Note, unlike clients, this service does not read variables from the environment automatically. You should not instantiate this service directly, and instead use the NewWebhookV1EventTypeService method instead.
func NewWebhookV1EventTypeService ¶ added in v0.42.0
func NewWebhookV1EventTypeService(opts ...option.RequestOption) (r *WebhookV1EventTypeService)
NewWebhookV1EventTypeService generates a new service that applies the given options to each request. These options are applied after the parent client's options (if there is one), and before any request-specific options.
func (*WebhookV1EventTypeService) List ¶ added in v0.42.0
func (r *WebhookV1EventTypeService) List(ctx context.Context, opts ...option.RequestOption) (err error)
Returns the catalog of event types that can be subscribed to via webhook endpoints. Each entry lists the required service scope the API key must carry to subscribe, plus the stability level.
type WebhookV1Service ¶ added in v0.42.0
type WebhookV1Service struct {
Options []option.RequestOption
// Webhook endpoint management
Endpoints *WebhookV1EndpointService
// Webhook endpoint management
Deliveries *WebhookV1DeliveryService
// Webhook endpoint management
EventTypes *WebhookV1EventTypeService
}
WebhookV1Service contains methods and other services that help with interacting with the casedev API.
Note, unlike clients, this service does not read variables from the environment automatically. You should not instantiate this service directly, and instead use the NewWebhookV1Service method instead.
func NewWebhookV1Service ¶ added in v0.42.0
func NewWebhookV1Service(opts ...option.RequestOption) (r *WebhookV1Service)
NewWebhookV1Service generates a new service that applies the given options to each request. These options are applied after the parent client's options (if there is one), and before any request-specific options.
type WorkerService ¶ added in v0.46.0
type WorkerService struct {
Options []option.RequestOption
V1 *WorkerV1Service
}
WorkerService contains methods and other services that help with interacting with the casedev API.
Note, unlike clients, this service does not read variables from the environment automatically. You should not instantiate this service directly, and instead use the NewWorkerService method instead.
func NewWorkerService ¶ added in v0.46.0
func NewWorkerService(opts ...option.RequestOption) (r *WorkerService)
NewWorkerService generates a new service that applies the given options to each request. These options are applied after the parent client's options (if there is one), and before any request-specific options.
type WorkerV1Service ¶ added in v0.46.0
type WorkerV1Service struct {
Options []option.RequestOption
}
WorkerV1Service contains methods and other services that help with interacting with the casedev API.
Note, unlike clients, this service does not read variables from the environment automatically. You should not instantiate this service directly, and instead use the NewWorkerV1Service method instead.
func NewWorkerV1Service ¶ added in v0.46.0
func NewWorkerV1Service(opts ...option.RequestOption) (r *WorkerV1Service)
NewWorkerV1Service generates a new service that applies the given options to each request. These options are applied after the parent client's options (if there is one), and before any request-specific options.
func (*WorkerV1Service) Boot ¶ added in v0.47.0
func (r *WorkerV1Service) Boot(ctx context.Context, id string, opts ...option.RequestOption) (err error)
Starts or resumes the worker sandbox and OpenCode server. Native /worker/v1/:id/\* proxy routes require this lifecycle primitive to have completed first.
func (*WorkerV1Service) Delete ¶ added in v0.46.0
func (r *WorkerV1Service) Delete(ctx context.Context, id string, opts ...option.RequestOption) (err error)
End worker
func (*WorkerV1Service) Get ¶ added in v0.46.0
func (r *WorkerV1Service) Get(ctx context.Context, id string, opts ...option.RequestOption) (err error)
Get worker
func (*WorkerV1Service) New ¶ added in v0.46.0
func (r *WorkerV1Service) New(ctx context.Context, opts ...option.RequestOption) (err error)
Creates a Daytona-backed worker runtime. The worker exposes its native runtime API through /worker/v1/:id/\* without reshaping payloads or events.
func (*WorkerV1Service) ProxyDelete ¶ added in v0.46.0
func (r *WorkerV1Service) ProxyDelete(ctx context.Context, id string, workerPath string, opts ...option.RequestOption) (err error)
Forwards a DELETE request to the worker runtime without translating response shapes.
func (*WorkerV1Service) ProxyGet ¶ added in v0.46.0
func (r *WorkerV1Service) ProxyGet(ctx context.Context, id string, workerPath string, opts ...option.RequestOption) (err error)
Forwards a GET request to the worker runtime without translating response or SSE event shapes.
func (*WorkerV1Service) ProxyPatch ¶ added in v0.46.0
func (r *WorkerV1Service) ProxyPatch(ctx context.Context, id string, workerPath string, opts ...option.RequestOption) (err error)
Forwards a PATCH request to the worker runtime without translating request or response shapes.
func (*WorkerV1Service) ProxyPost ¶ added in v0.46.0
func (r *WorkerV1Service) ProxyPost(ctx context.Context, id string, workerPath string, opts ...option.RequestOption) (err error)
Forwards a POST request to the worker runtime without translating request, response, or SSE event shapes.
func (*WorkerV1Service) ProxyPut ¶ added in v0.46.0
func (r *WorkerV1Service) ProxyPut(ctx context.Context, id string, workerPath string, opts ...option.RequestOption) (err error)
Forwards a PUT request to the worker runtime without translating request or response shapes.
Source Files
¶
- agent.go
- agentv1.go
- agentv1agent.go
- agentv1chat.go
- agentv1chatfile.go
- agentv1execute.go
- agentv1run.go
- aliases.go
- client.go
- compute.go
- computev1.go
- computev1environment.go
- computev1instance.go
- computev1instancetype.go
- computev1secret.go
- database.go
- databasev1.go
- databasev1project.go
- default_http_client.go
- field.go
- format.go
- formatv1.go
- formatv1template.go
- legal.go
- legalv1.go
- llm.go
- llmv1.go
- llmv1chat.go
- mail.go
- mailv1.go
- mailv1inbox.go
- matter.go
- matterv1.go
- matterv1agenttype.go
- matterv1event.go
- matterv1eventsubscription.go
- matterv1log.go
- matterv1matterparty.go
- matterv1party.go
- matterv1share.go
- matterv1type.go
- matterv1workitem.go
- memory.go
- memoryv1.go
- ocr.go
- ocrv1.go
- privilege.go
- privilegev1.go
- search.go
- searchv1.go
- skill.go
- skillcustom.go
- superdoc.go
- superdocv1.go
- system.go
- translate.go
- translatev1.go
- usage.go
- usagev1.go
- usagev1subscription.go
- vault.go
- vaultevent.go
- vaulteventsubscription.go
- vaultgraphrag.go
- vaultgroup.go
- vaultmemory.go
- vaultmultipart.go
- vaultobject.go
- voice.go
- voiceboostlist.go
- voicestreaming.go
- voicetranscription.go
- voicev1.go
- voicev1speak.go
- webhook.go
- webhookv1.go
- webhookv1delivery.go
- webhookv1endpoint.go
- webhookv1eventtype.go
- worker.go
- workerv1.go