#10410 means the Express Checkout token is invalid. #10412 means PayPal already has a payment for that invoice ID. Retrying the same request will not cure either one. Read the short message in the log before you change API credentials.

Magento records these as PayPal NVP gateway errors in var/log/exception.log, often with a correlation id. The correlation id is for PayPal support. It is not a token you can reuse.
PayPal’s error table says 10410, short message “Invalid token”, applies to SetExpressCheckout, GetExpressCheckoutDetails, DoExpressCheckoutPayment, and the billing-agreement calls. The token is not a token this merchant can use. Typical causes:
DoExpressCheckoutPayment is not the TOKEN from SetExpressCheckout.#10411 is the neighbor: the Express session expired. PayPal tells you to start again and not to send the expired token back into SetExpressCheckout. Treat 10410 the same way. Send the shopper through checkout again so Magento requests a new token.
What does not fix it: copying an old token out of a log, or switching the button to “check / money order” and calling that a PayPal repair. A missing offline payment method is a separate admin setting under Stores → Configuration → Sales → Payment Methods.
PayPal’s help page for 10412 says the invoice ID was already paid on this account. Merchants send INVNUM (NVP) or InvoiceID (SOAP) so PayPal can block a second capture for the same number. Magento’s PayPal module sends the order increment id. You get 10412 when:
Generate a new order. Do not keep posting the failed order’s PayPal request. If duplicate blocking is on in the PayPal profile, that is working as designed. Turn it off only if you accept duplicate captures. Prefer unique ids.
PayPal NVP gateway errors: Invalid token (#10410: Invalid token). Correlation ID: ...
The number in parentheses is the code. 10410: new checkout. 10412: new invoice id. 10411: the session timed out, also a new checkout.
Then look at the order in Magento admin. An order in pending_payment with 10410 never captured. An order that PayPal already shows as completed, with 10412 on the retry, must not be captured a second time. Compare the PayPal transaction search for that correlation id before you click anything that takes money.
localhost return URL will not work for a live buyer, and a mismatched host drops the token query parameter.There is no Magento patch in this article. The gateway already said which rule fired.
A new checkout that fails with the same number is still that number. 10410 after a fresh start means the new token was not the one Magento sent. 10412 after a fresh start means the new order still reused an invoice ID PayPal has already seen.
A new sandbox buyer completes checkout once. The order becomes processing (or your configured state) and the log has no new 10410 or 10412 for that increment id. A second click on the same order does not create a second capture.
No. 10411 means the Express session expired. Both need a new checkout. Neither should resend the old token.
No. 10412 is the invoice ID, not the token. Start a new order so the increment ID has not already been paid.
Only if you accept two captures for one number. The safer fix is a unique invoice ID.