doAuthorizedReq does a http request to the given path in the api endpoint as a user, with the appropriate headers. The given path should include the preceding slash.
(ctx context.DnoteCtx, method, path, body string, options *requestOptions)
| 197 | // doAuthorizedReq does a http request to the given path in the api endpoint as a user, |
| 198 | // with the appropriate headers. The given path should include the preceding slash. |
| 199 | func doAuthorizedReq(ctx context.DnoteCtx, method, path, body string, options *requestOptions) (*http.Response, error) { |
| 200 | if ctx.SessionKey == "" { |
| 201 | return nil, errors.New("no session key found") |
| 202 | } |
| 203 | |
| 204 | return doReq(ctx, method, path, body, options) |
| 205 | } |
| 206 | |
| 207 | // GetSyncStateResp is the response get sync state endpoint |
| 208 | type GetSyncStateResp struct { |
no test coverage detected