handle objects not present
added id generation endpoint
added test for id generation