ActionCtx depreciated?
Tell me if I've got the wrong approach. Should I just be using an internalAction for this?
I'm separating out functions that aren't direct mutations, queries or actions into a lib folder.
Here I've just got a function that replies in JSON from openAi.
I'm passing in "ctx: ActionCtx" because I want to charge a user credits for the usage.
This all works fine but I notice that ActionCtx is depreciated?
I tried to use GenericActionCtx but it's not working out for me (I'm calling this from an Action)
2 Replies
Just that particular ActionCtx is deorecated, imported from convex/server. There's another one in convex/_generated/server you should use instead.
ah okay, easy 😄 . I'm guessing it'll be removed in some future version?