Calculate.json and apply.json on post purchase returning 500

The app in I am getting this error is public app and has post purchase permission. Shopify redirects me to the /post-purchase page. So, post purchase should work. But, requesting API throws

{
    "errors": [
        {
            "code": "server_error",
            "message": "Error adding variant XXXXXX to purchase"
        }
    ],
    "status": "unprocessed"
}

on /checkouts/unstable/changesets/apply.json. I know post purchase is still in beta. But, it’s been ages. I am not getting anything useful from this error.