Eliminar Método de Pago

Elimina un método de pago existente.

Argumentos

Tipo

Descripción

índice

índice

Índice del método de pago.

customer = Conekta::Customer.find("cus_zzmjKsnM9oacyCwV3")
source   = customer.payment_sources.first.delete
curl -H "Accept: application/vnd.conekta-v2.0.0+json" \
     -H "Content-type: application/json" \
     -u key_eYvWV7gSDkNYXsmr: \
     -X DELETE  https://api.conekta.io/customers/cus_zzmjKsnM9oacyCwV3/payment_sources/src_2ghVL83uWtPmcs58S
$customer = \Conekta\Customer::find("cus_zzmjKsnM9oacyCwV3");
$source   = $customer->payment_sources[0]->delete();
conekta.Customer.find('cus_zzmjKsnM9oacyCwV3', function(err, customer) {
  customer.payment_sources.get(0).delete(function(err, resp) {
    console.log(resp.toObject());
    })
});
customer = conekta.Customer.find("cus_zzmjKsnM9oacyCwV3")
source = customer.payment_sources[0].delete()
Customer customer = Customer.find("cus_zzmjKsnM9oacyCwV3");
PaymentSource paymentSourceDeleted = (PaymentSource) customer.payment_sources.get(0);

paymentSourceDeleted.delete();
conekta.Customer customer = new conekta.Customer().find("cus_zzmjKsnM9oacyCwV3");
PaymentSource payment_source = (PaymentSource)customer.payment_sources[0];

payment_source.destroy();
import  (
    conekta "github.com/conekta/conekta-go"
    "github.com/conekta/conekta-go/paymentsource"
)

paymentsource.Delete("cus_zzmjKsnM9oacyCwV3", "src_2nBWrvGYtJCc9184v")