coder / coder/acp-go-sdk

An async version of RequestPermission?

Open
#12 0 comments 2 reactions 0 assignees View on GitHub
Dominant language
Go
Stars
230
Forks
37
PR merge metrics
No merged PRs in 30d

Description

### Problem

Currently, the method `RequestPermission` of struct `acp.Client` has to return the user choice, or it must be synchronous. This makes it very hard to implement an UI for this (not CLI), because the UI must not block so that users can select their choice. And I'm not even sure if the SDK allows that method to run in another goroutine.

### Solution

I think there should be a `AsyncRequestPermission` that
- has request ID in its params
- Doesn't return user choice

And a function `SendPermissionChoice` that send user choice with request ID to the ACP server

@ThomasK33

Contributor guide

No contributing guide indexed for this repository

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.