The error object for the mutation, if an error was encountered.
null.A boolean variable derived from status.
true if the last mutation attempt resulted in an error.A boolean variable derived from status.
true if the mutation is in its initial state prior to executing.A boolean variable derived from status.
true if the mutation is currently executing.A boolean variable derived from status.
true if the last mutation attempt was successful.The mutation function you can call with variables to trigger the mutation and optionally hooks on additional callback options.
The variables object to pass to the mutationFn.
This function will fire when the mutation is successful and will be passed the mutation's result.
This function will fire if the mutation encounters an error and will be passed the error.
This function will fire when the mutation is either successfully fetched or encounters an error and be passed either the data or error.
onSuccess will fire only after the latest call you've made.onSuccess, onError, onSettled) are void functions, and the returned value will be ignored.A function to clean the mutation internal state (i.e., it resets the mutation to its initial state).
The status of the mutation.
idle initial status prior to the mutation function executing.pending if the mutation is currently executing.error if the last mutation attempt resulted in an error.success if the last mutation attempt was successful.The variables object passed to the mutationFn.
The last successfully resolved data for the mutation.