(ctx context.Context, id string, suffix string)
| 2728 | } |
| 2729 | |
| 2730 | func (c *unixSocketClient) sessionScopedPath(ctx context.Context, id string, suffix string) (string, error) { |
| 2731 | sessionID, err := requireNetworkPathValue("session_id", id) |
| 2732 | if err != nil { |
| 2733 | return "", err |
| 2734 | } |
| 2735 | workspaceRef, err := c.sessionWorkspaceRef(ctx, sessionID) |
| 2736 | if err != nil { |
| 2737 | return "", err |
| 2738 | } |
| 2739 | return "/api/workspaces/" + url.PathEscape(workspaceRef) + "/sessions/" + |
| 2740 | url.PathEscape(sessionID) + suffix, nil |
| 2741 | } |
| 2742 | |
| 2743 | func (c *unixSocketClient) sessionWorkspaceRef(ctx context.Context, sessionID string) (string, error) { |
| 2744 | sessions, err := c.ListSessions(ctx, SessionListQuery{}) |
no test coverage detected