MCPcopy Create free account
hub / github.com/ChrisFeldmeier/OpenCodeRust / list_permissions

Function list_permissions

crates/opencode-server/src/routes.rs:3206–3211  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

3204 Lazy::new(|| RwLock::new(HashMap::new()));
3205
3206async fn list_permissions() -> Json<Vec<PermissionRequestInfo>> {
3207 let pending = PERMISSION_REQUESTS.read().await;
3208 let mut result: Vec<_> = pending.values().cloned().collect();
3209 result.sort_by(|a, b| a.id.cmp(&b.id));
3210 Json(result)
3211}
3212
3213#[derive(Debug, Deserialize)]
3214pub struct ReplyPermissionRequest {

Callers

nothing calls this directly

Calls 1

readMethod · 0.80

Tested by

no test coverage detected