E_VALIDATION_ERROR | 422 | Missing or out-of-bounds field; price not found, inactive, not recurring or on an archived product. errors[].field names the field. | Yes: fix the request. |
E_SUBSCRIPTION_NOT_FOUND | 404 | The subscription does not exist or belongs to another account — both return the same body, byte for byte. | Check the identifier and the key. |
E_SUBSCRIPTION_ALREADY_CANCELLED | 400 | cancel on an already canceled subscription. | No. |
E_INVALID_SUBSCRIPTION_TRANSITION | 422 | The state machine refuses (pause outside active, resume outside paused, …). The body carries fromState and toState. | Re-read the lifecycle. |
E_SUBSCRIPTION_CONCURRENCY | 409 | Two simultaneous modifications of the same subscription. | Read again, then retry. |
E_INTERNAL_SERVER_ERROR | 500 | Generic message. On POST /v1/subscriptions: lines in different currencies. On PUT /quantity: status other than active/trialing, or an itemId foreign to the subscription. | Yes, but the body does not say so: check these two cases first. |
E_UNAUTHORIZED | 401 | Missing, invalid, or wrong-mode key. | — |
TEST_CLOCK_NOT_AVAILABLE | 403 | Test clock with an sk_live_ key. | Use a test key. |
TEST_CLOCK_COMPLETED | 400 | Completed clock: it no longer advances. | Create another one. |