MCPcopy Index your code
hub / github.com/codeaashu/claude-code / sendPermissionResponseEvent

Function sendPermissionResponseEvent

src/bridge/bridgeApi.ts:419–450  ·  view source on GitHub ↗
(
      sessionId: string,
      event: PermissionResponseEvent,
      sessionToken: string,
    )

Source from the content-addressed store, hash-verified

417 },
418
419 async sendPermissionResponseEvent(
420 sessionId: string,
421 event: PermissionResponseEvent,
422 sessionToken: string,
423 ): Promise<void> {
424 validateBridgeId(sessionId, 'sessionId')
425
426 debug(
427 `[bridge:api] POST /v1/sessions/${sessionId}/events type=${event.type}`,
428 )
429
430 const response = await axios.post(
431 `${deps.baseUrl}/v1/sessions/${sessionId}/events`,
432 { events: [event] },
433 {
434 headers: getHeaders(sessionToken),
435 timeout: 10_000,
436 validateStatus: s => s < 500,
437 },
438 )
439
440 handleErrorStatus(
441 response.status,
442 response.data,
443 'SendPermissionResponseEvent',
444 )
445 debug(
446 `[bridge:api] POST /v1/sessions/${sessionId}/events -> ${response.status}`,
447 )
448 debug(`[bridge:api] >>> ${debugBody({ events: [event] })}`)
449 debug(`[bridge:api] <<< ${debugBody(response.data)}`)
450 },
451 }
452}
453

Callers

nothing calls this directly

Calls 6

validateBridgeIdFunction · 0.85
getHeadersFunction · 0.85
handleErrorStatusFunction · 0.85
debugBodyFunction · 0.85
postMethod · 0.80
debugFunction · 0.70

Tested by

no test coverage detected