Index: trunk/TODO
===================================================================
--- trunk/TODO	(revision 81)
+++ trunk/TODO	(revision 82)
@@ -17,2 +17,30 @@
     $ bkmk stop
     # stops the running server
+
+Deleting bookmarks
+
+    sub delete {
+	my $self = shift;
+	my $bookmark = shift;
+
+	my $sth_insert = $self->dbh->prepare('insert into deleted_bookmarks (id, dtime) values (?, ?)');
+	$sth_insert->execute($bookmark->id, time);
+	my $sth_delete = $self->dbh->prepare('delete from bookmarks where id = ?');
+	$sth_delete->execute($bookmark->id);
+    }
+
+Paging of results (will require counting bookmark total)
+
+    sub get_count {
+	my $self = shift;
+	my $search = shift;
+
+	my ($sql, @bind) = sql_interp(
+	    'select count(*) from resources join bookmarks on resources.uri = bookmarks.uri',
+	    $self->_sql_where_clause($search),
+	);
+	my $sth = $self->dbh->prepare($sql);
+	$sth->execute(@bind);
+	my ($count) = $sth->fetchrow_array;
+	return $count;
+    }
Index: trunk/api
===================================================================
--- trunk/api	(revision 81)
+++ trunk/api	(revision 82)
@@ -34,4 +34,15 @@
   Delete a bookmark
 
+  -- bookmarks that have been deleted
+  create table deleted_bookmarks (
+      id integer,
+      dtime integer
+  );
+
+  insert into deleted_bookmarks (id) values (?)  <-- {id}
+  delete from bookmarks where id = ? <-- {id}
+
+  then a request to /{id} checks the deleted_bookmarks table and issues a 410 (cacheable) if it is in there
+
 PUT /{id}/{field}
   Set a single field of a bookmark
