How to cache api response using curl, based on returned etag?
问题 This is a quick question that might help other too. I have a rest service that will return a proper ETAG header for each GET query on it's endpoints. Now, i also need to create a curl http client to query these endpoints and make use of the etags. From my understanding, after making the first request with curl, i need to save the returned etag for later use, so that on all subsequent requests (till the etag invalidates on server) i use the cached version because the server will return a 304