title: Is there built-in support for handling race conditions?
body: <p>Does the Stripe API have built-in support for handling race conditions?</p>
  <p>For example, if a subscription is <code>past_due</code> and thus I decide to cancel it, how do I handle the race condition where the invoice gets paid right before the cancellation happens?</p>
  <p>I can think of several such race conditions. Is there a standard way to prevent or handle them? Or is the only way to detect them by checking the state after the change is made and make the necessary adjustments if a race condition is detected?</p>