MCPcopy Create free account
hub / github.com/dfinity/orbit / cancel_request

Method cancel_request

core/station/impl/src/controllers/request.rs:173–184  ·  view source on GitHub ↗
(&self, input: CancelRequestInput)

Source from the content-addressed store, hash-verified

171 #[with_middleware(guard = authorize(&call_context(), &[Resource::from(&input)]))]
172 #[with_middleware(tail = use_canister_call_metric("cancel_request", &result))]
173 async fn cancel_request(&self, input: CancelRequestInput) -> ApiResult<CancelRequestResponse> {
174 let ctx = &call_context();
175 let request = self.request_service.cancel_request(
176 HelperMapper::to_uuid(input.request_id)?.as_bytes(),
177 input.reason,
178 ctx,
179 )?;
180
181 Ok(CancelRequestResponse {
182 request: request.to_dto(),
183 })
184 }
185
186 #[with_middleware(guard = authorize(&call_context(), &[Resource::from(&input)]))]
187 async fn get_request(&self, input: GetRequestInput) -> ApiResult<GetRequestResponse> {

Callers 1

cancel_requestFunction · 0.45

Calls 2

call_contextFunction · 0.50
to_dtoMethod · 0.45

Tested by

no test coverage detected