| 2194 | } |
| 2195 | |
| 2196 | func (c *unixSocketClient) NetworkInbox( |
| 2197 | ctx context.Context, |
| 2198 | workspaceRef string, |
| 2199 | sessionID string, |
| 2200 | ) ([]NetworkEnvelopeRecord, error) { |
| 2201 | var response struct { |
| 2202 | Messages []NetworkEnvelopeRecord `json:"messages"` |
| 2203 | } |
| 2204 | path, err := networkBasePath(workspaceRef) |
| 2205 | if err != nil { |
| 2206 | return nil, err |
| 2207 | } |
| 2208 | if err := c.doJSON( |
| 2209 | ctx, |
| 2210 | http.MethodGet, |
| 2211 | path+"/inbox", |
| 2212 | networkInboxValues(sessionID), |
| 2213 | nil, |
| 2214 | &response, |
| 2215 | ); err != nil { |
| 2216 | return nil, err |
| 2217 | } |
| 2218 | return response.Messages, nil |
| 2219 | } |
| 2220 | |
| 2221 | func (c *unixSocketClient) PromoteNetworkThreadTask( |
| 2222 | ctx context.Context, |