Skip to main content

OriginMcpServer

Struct OriginMcpServer 

Source
pub struct OriginMcpServer { /* private fields */ }

Implementations§

Source§

impl OriginMcpServer

Source

pub async fn capture_impl( &self, params: CaptureParams, ) -> Result<CallToolResult, McpError>

Source

pub async fn recall_impl( &self, params: RecallParams, ) -> Result<CallToolResult, McpError>

Source

pub async fn context_impl( &self, params: ContextParams, ) -> Result<CallToolResult, McpError>

Source

pub async fn doctor_impl(&self) -> Result<CallToolResult, McpError>

Source

pub async fn forget_impl( &self, memory_id: &str, ) -> Result<CallToolResult, McpError>

Source

pub async fn distill_impl( &self, params: DistillParams, ) -> Result<CallToolResult, McpError>

Source

pub async fn list_pending_impl( &self, params: ListPendingParams, ) -> Result<CallToolResult, McpError>

Source

pub async fn confirm_memory_impl( &self, memory_id: &str, ) -> Result<CallToolResult, McpError>

Source

pub async fn create_entity_impl( &self, params: CreateEntityParams, ) -> Result<CallToolResult, McpError>

Source

pub async fn create_relation_impl( &self, params: CreateRelationParams, ) -> Result<CallToolResult, McpError>

Source

pub async fn create_observation_impl( &self, params: CreateObservationParams, ) -> Result<CallToolResult, McpError>

Source

pub async fn confirm_entity_impl( &self, params: ConfirmEntityParams, ) -> Result<CallToolResult, McpError>

Source

pub async fn update_observation_impl( &self, params: UpdateObservationParams, ) -> Result<CallToolResult, McpError>

Source

pub async fn confirm_observation_impl( &self, params: ConfirmObservationParams, ) -> Result<CallToolResult, McpError>

Source

pub async fn delete_observation_impl( &self, params: DeleteObservationParams, ) -> Result<CallToolResult, McpError>

Source

pub async fn create_page_impl( &self, params: CreatePageParams, ) -> Result<CallToolResult, McpError>

Source

pub async fn update_page_impl( &self, params: UpdatePageParams, ) -> Result<CallToolResult, McpError>

Source

pub async fn delete_page_impl( &self, page_id: &str, ) -> Result<CallToolResult, McpError>

Source

pub async fn get_page_impl( &self, page_id: &str, ) -> Result<CallToolResult, McpError>

Source

pub async fn get_page_sources_impl( &self, page_id: &str, ) -> Result<CallToolResult, McpError>

Source

pub async fn get_memory_revisions_impl( &self, memory_id: &str, ) -> Result<CallToolResult, McpError>

Source

pub async fn get_page_revisions_impl( &self, page_id: &str, ) -> Result<CallToolResult, McpError>

Source

pub async fn list_memories_impl( &self, params: ListMemoriesParams, ) -> Result<CallToolResult, McpError>

Source

pub async fn search_pages_impl( &self, params: SearchPagesParams, ) -> Result<CallToolResult, McpError>

Source

pub async fn list_pages_recent_impl( &self, params: ListPagesRecentParams, ) -> Result<CallToolResult, McpError>

Source

pub async fn list_spaces_impl( &self, _params: ListSpacesParams, ) -> Result<CallToolResult, McpError>

Source

pub async fn list_refinements_impl( &self, params: ListRefinementsParams, ) -> Result<CallToolResult, McpError>

Source

pub async fn reject_refinement_impl( &self, params: RejectRefinementParams, ) -> Result<CallToolResult, McpError>

Source

pub async fn accept_refinement_impl( &self, params: AcceptRefinementParams, ) -> Result<CallToolResult, McpError>

Source

pub async fn list_nurture_impl( &self, params: ListNurtureParams, ) -> Result<CallToolResult, McpError>

Source

pub async fn list_entity_suggestions_impl( &self, _params: ListEntitySuggestionsParams, ) -> Result<CallToolResult, McpError>

Source

pub async fn accept_revision_impl( &self, req: AcceptRevisionRequest, ) -> Result<CallToolResult, McpError>

Source

pub async fn dismiss_revision_impl( &self, req: DismissRevisionRequest, ) -> Result<CallToolResult, McpError>

Source

pub async fn dismiss_contradiction_impl( &self, req: DismissContradictionRequest, ) -> Result<CallToolResult, McpError>

Source

pub async fn list_pending_imports_impl( &self, _params: ListPendingImportsParams, ) -> Result<CallToolResult, McpError>

Source

pub async fn list_rejections_impl( &self, params: ListRejectionsParams, ) -> Result<CallToolResult, McpError>

Source

pub async fn list_pending_revisions_impl( &self, params: ListPendingRevisionsParams, ) -> Result<CallToolResult, McpError>

Source§

impl OriginMcpServer

Source

pub fn new( client: OriginClient, transport: TransportMode, agent_name: String, user_id: Option<String>, ) -> Self

Source

pub fn capture_tool_attr() -> Tool

Generated tool metadata function for capture

Source

pub fn recall_tool_attr() -> Tool

Generated tool metadata function for recall

Source

pub fn context_tool_attr() -> Tool

Generated tool metadata function for context

Source

pub fn doctor_tool_attr() -> Tool

Generated tool metadata function for doctor

Source

pub fn forget_tool_attr() -> Tool

Generated tool metadata function for forget

Source

pub fn distill_tool_attr() -> Tool

Generated tool metadata function for distill

Source

pub fn list_pending_tool_attr() -> Tool

Generated tool metadata function for list_pending

Source

pub fn confirm_memory_tool_attr() -> Tool

Generated tool metadata function for confirm_memory

Source

pub fn create_entity_tool_attr() -> Tool

Generated tool metadata function for create_entity

Source

pub fn create_relation_tool_attr() -> Tool

Generated tool metadata function for create_relation

Source

pub fn create_observation_tool_attr() -> Tool

Generated tool metadata function for create_observation

Source

pub fn confirm_entity_tool_attr() -> Tool

Generated tool metadata function for confirm_entity

Source

pub fn update_observation_tool_attr() -> Tool

Generated tool metadata function for update_observation

Source

pub fn confirm_observation_tool_attr() -> Tool

Generated tool metadata function for confirm_observation

Source

pub fn delete_observation_tool_attr() -> Tool

Generated tool metadata function for delete_observation

Source

pub fn create_page_tool_attr() -> Tool

Generated tool metadata function for create_page

Source

pub fn update_page_tool_attr() -> Tool

Generated tool metadata function for update_page

Source

pub fn delete_page_tool_attr() -> Tool

Generated tool metadata function for delete_page

Source

pub fn get_page_tool_attr() -> Tool

Generated tool metadata function for get_page

Generated tool metadata function for get_page_links

Source

pub fn get_page_sources_tool_attr() -> Tool

Generated tool metadata function for get_page_sources

Source

pub fn get_memory_revisions_tool_attr() -> Tool

Generated tool metadata function for get_memory_revisions

Source

pub fn get_page_revisions_tool_attr() -> Tool

Generated tool metadata function for get_page_revisions

Source

pub fn list_memories_tool_attr() -> Tool

Generated tool metadata function for list_memories

Source

pub fn search_pages_tool_attr() -> Tool

Generated tool metadata function for search_pages

Source

pub fn list_pages_recent_tool_attr() -> Tool

Generated tool metadata function for list_pages_recent

Source

pub fn list_spaces_tool_attr() -> Tool

Generated tool metadata function for list_spaces

Source

pub fn list_refinements_tool_attr() -> Tool

Generated tool metadata function for list_refinements

Source

pub fn reject_refinement_tool_attr() -> Tool

Generated tool metadata function for reject_refinement

Source

pub fn accept_refinement_tool_attr() -> Tool

Generated tool metadata function for accept_refinement

Source

pub fn list_nurture_tool_attr() -> Tool

Generated tool metadata function for list_nurture

Source

pub fn list_entity_suggestions_tool_attr() -> Tool

Generated tool metadata function for list_entity_suggestions

Source

pub fn accept_revision_tool_attr() -> Tool

Generated tool metadata function for accept_revision

Source

pub fn dismiss_revision_tool_attr() -> Tool

Generated tool metadata function for dismiss_revision

Source

pub fn dismiss_contradiction_tool_attr() -> Tool

Generated tool metadata function for dismiss_contradiction

Source

pub fn list_pending_imports_tool_attr() -> Tool

Generated tool metadata function for list_pending_imports

Source

pub fn list_rejections_tool_attr() -> Tool

Generated tool metadata function for list_rejections

Source

pub fn list_pending_revisions_tool_attr() -> Tool

Generated tool metadata function for list_pending_revisions

Generated tool metadata function for list_orphan_links

Trait Implementations§

Source§

impl Clone for OriginMcpServer

Source§

fn clone(&self) -> OriginMcpServer

Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§

fn clone_from(&mut self, source: &Self)

Performs copy-assignment from source. Read more
Source§

impl ServerHandler for OriginMcpServer

Source§

async fn list_tools( &self, _request: Option<PaginatedRequestParams>, _context: RequestContext<RoleServer>, ) -> Result<ListToolsResult, McpError>

Source§

async fn on_initialized(&self, context: NotificationContext<RoleServer>)

Source§

fn get_info(&self) -> InitializeResult

Source§

async fn call_tool( &self, request: CallToolRequestParams, context: RequestContext<RoleServer>, ) -> Result<CallToolResult, ErrorData>

Source§

fn get_tool(&self, name: &str) -> Option<Tool>

Get a tool definition by name. Read more
Source§

fn enqueue_task( &self, _request: CallToolRequestParams, _context: RequestContext<RoleServer>, ) -> impl Future<Output = Result<CreateTaskResult, ErrorData>> + MaybeSendFuture

Source§

fn ping( &self, context: RequestContext<RoleServer>, ) -> impl Future<Output = Result<(), ErrorData>> + MaybeSendFuture

Source§

fn initialize( &self, request: InitializeRequestParams, context: RequestContext<RoleServer>, ) -> impl Future<Output = Result<InitializeResult, ErrorData>> + MaybeSendFuture

Source§

fn complete( &self, request: CompleteRequestParams, context: RequestContext<RoleServer>, ) -> impl Future<Output = Result<CompleteResult, ErrorData>> + MaybeSendFuture

Source§

fn set_level( &self, request: SetLevelRequestParams, context: RequestContext<RoleServer>, ) -> impl Future<Output = Result<(), ErrorData>> + MaybeSendFuture

Source§

fn get_prompt( &self, request: GetPromptRequestParams, context: RequestContext<RoleServer>, ) -> impl Future<Output = Result<GetPromptResult, ErrorData>> + MaybeSendFuture

Source§

fn list_prompts( &self, request: Option<PaginatedRequestParams>, context: RequestContext<RoleServer>, ) -> impl Future<Output = Result<ListPromptsResult, ErrorData>> + MaybeSendFuture

Source§

fn list_resources( &self, request: Option<PaginatedRequestParams>, context: RequestContext<RoleServer>, ) -> impl Future<Output = Result<ListResourcesResult, ErrorData>> + MaybeSendFuture

Source§

fn list_resource_templates( &self, request: Option<PaginatedRequestParams>, context: RequestContext<RoleServer>, ) -> impl Future<Output = Result<ListResourceTemplatesResult, ErrorData>> + MaybeSendFuture

Source§

fn read_resource( &self, request: ReadResourceRequestParams, context: RequestContext<RoleServer>, ) -> impl Future<Output = Result<ReadResourceResult, ErrorData>> + MaybeSendFuture

Source§

fn subscribe( &self, request: SubscribeRequestParams, context: RequestContext<RoleServer>, ) -> impl Future<Output = Result<(), ErrorData>> + MaybeSendFuture

Source§

fn unsubscribe( &self, request: UnsubscribeRequestParams, context: RequestContext<RoleServer>, ) -> impl Future<Output = Result<(), ErrorData>> + MaybeSendFuture

Source§

fn on_custom_request( &self, request: CustomRequest, context: RequestContext<RoleServer>, ) -> impl Future<Output = Result<CustomResult, ErrorData>> + MaybeSendFuture

Source§

fn on_cancelled( &self, notification: CancelledNotificationParam, context: NotificationContext<RoleServer>, ) -> impl Future<Output = ()> + MaybeSendFuture

Source§

fn on_progress( &self, notification: ProgressNotificationParam, context: NotificationContext<RoleServer>, ) -> impl Future<Output = ()> + MaybeSendFuture

Source§

fn on_roots_list_changed( &self, context: NotificationContext<RoleServer>, ) -> impl Future<Output = ()> + MaybeSendFuture

Source§

fn on_custom_notification( &self, notification: CustomNotification, context: NotificationContext<RoleServer>, ) -> impl Future<Output = ()> + MaybeSendFuture

Source§

fn list_tasks( &self, request: Option<PaginatedRequestParams>, context: RequestContext<RoleServer>, ) -> impl Future<Output = Result<ListTasksResult, ErrorData>> + MaybeSendFuture

Source§

fn get_task_info( &self, request: GetTaskInfoParams, context: RequestContext<RoleServer>, ) -> impl Future<Output = Result<GetTaskResult, ErrorData>> + MaybeSendFuture

Source§

fn get_task_result( &self, request: GetTaskResultParams, context: RequestContext<RoleServer>, ) -> impl Future<Output = Result<GetTaskPayloadResult, ErrorData>> + MaybeSendFuture

Source§

fn cancel_task( &self, request: CancelTaskParams, context: RequestContext<RoleServer>, ) -> impl Future<Output = Result<CancelTaskResult, ErrorData>> + MaybeSendFuture

Auto Trait Implementations§

Blanket Implementations§

Source§

impl<T> Any for T
where T: 'static + ?Sized,

Source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
Source§

impl<T> Borrow<T> for T
where T: ?Sized,

Source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
Source§

impl<T> BorrowMut<T> for T
where T: ?Sized,

Source§

fn borrow_mut(&mut self) -> &mut T

Mutably borrows from an owned value. Read more
Source§

impl<T> CloneToUninit for T
where T: Clone,

Source§

unsafe fn clone_to_uninit(&self, dest: *mut u8)

🔬This is a nightly-only experimental API. (clone_to_uninit)
Performs copy-assignment from self to dest. Read more
Source§

impl<T> DynClone for T
where T: Clone,

Source§

fn __clone_box(&self, _: Private) -> *mut ()

Source§

impl<R, S> DynService<R> for S
where R: ServiceRole, S: Service<R>,

Source§

fn handle_request( &self, request: <R as ServiceRole>::PeerReq, context: RequestContext<R>, ) -> Pin<Box<dyn Future<Output = Result<<R as ServiceRole>::Resp, ErrorData>> + Send + '_>>

Source§

fn handle_notification( &self, notification: <R as ServiceRole>::PeerNot, context: NotificationContext<R>, ) -> Pin<Box<dyn Future<Output = Result<(), ErrorData>> + Send + '_>>

Source§

fn get_info(&self) -> <R as ServiceRole>::Info

Source§

impl<T> From<T> for T

Source§

fn from(t: T) -> T

Returns the argument unchanged.

Source§

impl<T> FromRef<T> for T
where T: Clone,

Source§

fn from_ref(input: &T) -> T

Converts to this type from a reference to the input type.
Source§

impl<A, B, T> HttpServerConnExec<A, B> for T
where B: Body,

Source§

impl<T> Instrument for T

Source§

fn instrument(self, span: Span) -> Instrumented<Self>

Instruments this type with the provided Span, returning an Instrumented wrapper. Read more
Source§

fn in_current_span(self) -> Instrumented<Self>

Instruments this type with the current Span, returning an Instrumented wrapper. Read more
Source§

impl<T, U> Into<U> for T
where U: From<T>,

Source§

fn into(self) -> U

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

Source§

impl<T> PolicyExt for T
where T: ?Sized,

Source§

fn and<P, B, E>(self, other: P) -> And<T, P>
where T: Sized + Policy<B, E>, P: Policy<B, E>,

Create a new Policy that returns Action::Follow only if self and other return Action::Follow. Read more
Source§

fn or<P, B, E>(self, other: P) -> Or<T, P>
where T: Sized + Policy<B, E>, P: Policy<B, E>,

Create a new Policy that returns Action::Follow if either self or other returns Action::Follow. Read more
Source§

impl<H> Service<RoleServer> for H
where H: ServerHandler,

Source§

impl<S> ServiceExt<RoleServer> for S
where S: Service<RoleServer>,

Source§

fn serve_with_ct<T, E, A>( self, transport: T, ct: CancellationToken, ) -> impl Future<Output = Result<RunningService<RoleServer, S>, ServerInitializeError>> + MaybeSendFuture
where T: IntoTransport<RoleServer, E, A>, E: Error + Send + Sync + 'static, S: Sized,

Source§

fn into_dyn(self) -> Box<dyn DynService<R>>

Convert this service to a dynamic boxed service Read more
Source§

fn serve<T, E, A>( self, transport: T, ) -> impl Future<Output = Result<RunningService<R, Self>, <R as ServiceRole>::InitializeError>> + MaybeSendFuture
where T: IntoTransport<R, E, A>, E: Error + Send + Sync + 'static, Self: Sized,

Source§

impl<T> ToOwned for T
where T: Clone,

Source§

type Owned = T

The resulting type after obtaining ownership.
Source§

fn to_owned(&self) -> T

Creates owned data from borrowed data, usually by cloning. Read more
Source§

fn clone_into(&self, target: &mut T)

Uses borrowed data to replace owned data, usually by cloning. Read more
Source§

impl<T, U> TryFrom<U> for T
where U: Into<T>,

Source§

type Error = Infallible

The type returned in the event of a conversion error.
Source§

fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>

Performs the conversion.
Source§

impl<T, U> TryInto<U> for T
where U: TryFrom<T>,

Source§

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.
Source§

fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>

Performs the conversion.
Source§

impl<T> WithSubscriber for T

Source§

fn with_subscriber<S>(self, subscriber: S) -> WithDispatch<Self>
where S: Into<Dispatch>,

Attaches the provided Subscriber to this type, returning a WithDispatch wrapper. Read more
Source§

fn with_current_subscriber(self) -> WithDispatch<Self>

Attaches the current default Subscriber to this type, returning a WithDispatch wrapper. Read more