Skip to content

Instantly share code, notes, and snippets.

@guayosr
Created August 29, 2019 21:31
Show Gist options
  • Save guayosr/c3f8f40836e8e8f41dae050dbe28e623 to your computer and use it in GitHub Desktop.
Save guayosr/c3f8f40836e8e8f41dae050dbe28e623 to your computer and use it in GitHub Desktop.
{
"error": {
"message": "The amount specified (1099) does not match the amount on the source (9999999). A payment can only be created for the exact amount of the corresponding source.",
"payment_intent": {
"id": "pi_1FCv9uI3eKmwQ40ETl72XPDY",
"object": "payment_intent",
"allowed_source_types": [
"oxxo"
],
"amount": 1099,
"amount_capturable": 0,
"amount_received": 0,
"application": null,
"application_fee_amount": null,
"canceled_at": null,
"cancellation_reason": null,
"capture_method": "automatic",
"charges": {
"object": "list",
"data": [
],
"has_more": false,
"total_count": 0,
"url": "/v1/charges?payment_intent=pi_1FCv9uI3eKmwQ40ETl72XPDY"
},
"client_secret": "pi_1FCv9uI3eKmwQ40ETl72XPDY_secret_xaxpEdka3qvN96wAc3OVwGqZx",
"confirmation_method": "automatic",
"created": 1567114078,
"currency": "mxn",
"customer": "cus_FiLhJTbeIeKcMZ",
"description": null,
"invoice": null,
"last_payment_error": {
"message": "The amount specified (1099) does not match the amount on the source (9999999). A payment can only be created for the exact amount of the corresponding source.",
"source": {
"id": "src_1FCuruI3eKmwQ40ETZ8xezt0",
"object": "source",
"amount": 9999999,
"client_secret": "src_client_secret_FiLZW818jj8snRcOaXNMDYzA",
"created": 1567112962,
"currency": "mxn",
"customer": "cus_FiLhJTbeIeKcMZ",
"flow": "receiver",
"livemode": false,
"metadata": {
},
"owner": {
"address": null,
"email": "guayosr@test.com",
"name": "pepe",
"phone": null,
"verified_address": null,
"verified_email": null,
"verified_name": null,
"verified_phone": null
},
"oxxo": {
"number": "123456789",
"expires_after": 1567400399
},
"receiver": {
"address": "999999999-12345",
"amount_charged": 0,
"amount_received": 9999999,
"amount_returned": 0,
"refund_attributes_method": "none",
"refund_attributes_status": "available"
},
"statement_descriptor": null,
"status": "canceled",
"type": "oxxo",
"usage": "single_use"
},
"type": "invalid_request_error"
},
"livemode": false,
"metadata": {
},
"next_action": null,
"next_source_action": null,
"on_behalf_of": null,
"payment_method": null,
"payment_method_options": {
},
"payment_method_types": [
"oxxo"
],
"receipt_email": null,
"review": null,
"setup_future_usage": null,
"shipping": null,
"source": null,
"statement_descriptor": null,
"statement_descriptor_suffix": null,
"status": "requires_source",
"transfer_data": null,
"transfer_group": null
},
"source": {
"id": "src_1FCuruI3eKmwQ40ETZ8xezt0",
"object": "source",
"amount": 9999999,
"client_secret": "src_client_secret_FiLZW818jj8snRcOaXNMDYzA",
"created": 1567112962,
"currency": "mxn",
"customer": "cus_FiLhJTbeIeKcMZ",
"flow": "receiver",
"livemode": false,
"metadata": {
},
"owner": {
"address": null,
"email": "guayosr@test.com",
"name": "pepe",
"phone": null,
"verified_address": null,
"verified_email": null,
"verified_name": null,
"verified_phone": null
},
"oxxo": {
"number": "123456789",
"expires_after": 1567400399
},
"receiver": {
"address": "999999999-12345",
"amount_charged": 0,
"amount_received": 9999999,
"amount_returned": 0,
"refund_attributes_method": "none",
"refund_attributes_status": "available"
},
"statement_descriptor": null,
"status": "canceled",
"type": "oxxo",
"usage": "single_use"
},
"type": "invalid_request_error"
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment