From c2ca26a918b7054199234e8459d84ee2fd260759 Mon Sep 17 00:00:00 2001 From: Rose Hogenson Date: Tue, 30 Sep 2025 21:50:36 -0700 Subject: Allow appending to notes Right now it's n^2 which is a big problem (to be fixed later) --- internal/api/api.go | 9 ++++++--- 1 file changed, 6 insertions(+), 3 deletions(-) (limited to 'internal/api/api.go') diff --git a/internal/api/api.go b/internal/api/api.go index 7c8472a..b925a7a 100644 --- a/internal/api/api.go +++ b/internal/api/api.go @@ -11,6 +11,7 @@ const ( Unauthenticated // missing credentials PermissionDenied // invalid credentials, or login required BadRequest // incorrect request format (try gob) + InvalidArgument // one or more arguments was invalid NotFound // requested resource was not found Internal // server encountered an unexpected error ) @@ -35,12 +36,14 @@ type ListNotesResponse struct { Notes []string } -type CreateNoteRequestStream struct { - Chunk []byte +type CreateNoteRequest struct { + ContinuationToken []byte + Chunk []byte } type CreateNoteResponse struct { - Name string + Name string + ContinuationToken []byte } type ReadNoteRequest struct { -- cgit v1.3.1