I have an endpoint that generates and return a url for making payment online, it accepts only two arguments amount and currency.
initializeCardDeposit: builder.query({
query: ({ amount, currency }) => ({
url: "/initialize/card/deposit",
method: "POST",
body: {
amount,
currency,
},
}),
transformResponse: ({ data }) => data,
providesTags: ["cardDepositUrl"],
})
I want to get a new url anytime the the query is called with the same amount and currency, instead it returns a cached data.
I have tried dispatching invalidateTags("cardDepositUrl") and it didn't work.