Closed VisargD closed 8 months ago
🤖
It's great to see that you've identified an issue and a potential solution for the SDK. Your contribution to adding the cacheForceRefresh
setting and passing it as a header would be valuable. We encourage you to create a pull request with your proposed changes to the repository. Thank you for your willingness to improve the SDK!
Problem:
x-portkey-cache-force-refresh
header allows user to refresh the cache record for the call. But SDK does not accept and pass any cacheForceRefresh setting. For TS projects, this gives an error as cacheForceRefresh is not a part ofApiClientInterface
. And this setting is also not getting considered while calling createHeaders method with input settings.https://github.com/Portkey-AI/portkey-node-sdk/blob/f4629f569b945cd0dfe8403a7b9cb0218c82a84b/src/_types/generalTypes.ts#L3-L12
https://github.com/Portkey-AI/portkey-node-sdk/blob/f4629f569b945cd0dfe8403a7b9cb0218c82a84b/src/baseClient.ts#L122-L128