For me personally, I would keep track of it away from writing to a Shopify API call (i.e writing into any of the fields on the Shopify Store orders themself). This is because if anything happens and you write into the wrong the orders filed, you could potentially mess with your customer's orders data.
Even though it would be heavy, I would probably keep track of it in the database instead just to be on the safe side.
Although I don't understand what you're doing exactly, so it might not be a viable solution.