From d3f3a94e3acdc2190ecb54dc4a4e51ef49ec3057 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Sabri=20Onur=20T=C3=BCz=C3=BCn?= Date: Fri, 19 Aug 2016 16:35:07 +0300 Subject: [PATCH] samples updated --- README.md | 50 +++++++++++++++++++++++++------------------------- 1 file changed, 25 insertions(+), 25 deletions(-) diff --git a/README.md b/README.md index eed7304..965967d 100644 --- a/README.md +++ b/README.md @@ -50,82 +50,82 @@ var iyzipay = new Iyzipay({ uri: 'https://sandbox-api.iyzipay.com' }); -var paymentAuth = { +var payment = { locale: Iyzipay.LOCALE.TR, conversationId: '123456789', - price: '1.0', + price: '1', paidPrice: '1.1', currency: Iyzipay.CURRENCY.TRY, - installment: 1, - paymentChannel: Iyzipay.PAYMENT_CHANNEL.WEB, + installment: '1', basketId: 'B67832', paymentGroup: Iyzipay.PAYMENT_GROUP.PRODUCT, + paymentChannel: Iyzipay.PAYMENT_CHANNEL.WEB, paymentCard: { cardHolderName: 'John Doe', cardNumber: '5528790000000008', - expireYear: '2030', expireMonth: '12', + expireYear: '2030', cvc: '123', - registerCard: 0 + registerCard: '0' }, buyer: { id: 'BY789', name: 'John', surname: 'Doe', - identityNumber: '74300864791', - email: 'email@email.com', gsmNumber: '+905350000000', - registrationDate: '2013-04-21 15:12:09', + email: 'email@email.com', + identityNumber: '74300864791', lastLoginDate: '2015-10-05 12:43:35', - registrationAddress: 'Address', + registrationDate: '2013-04-21 15:12:09', + registrationAddress: 'Nidakule Göztepe, Merdivenköy Mah. Bora Sok. No:1', + ip: '85.34.78.112', city: 'Istanbul', country: 'Turkey', - zipCode: '34732', - ip: '85.34.78.112' + zipCode: '34732' }, shippingAddress: { - address: 'Address', - zipCode: '34742', contactName: 'Jane Doe', city: 'Istanbul', - country: 'Turkey' + country: 'Turkey', + address: 'Nidakule Göztepe, Merdivenköy Mah. Bora Sok. No:1', + zipCode: '34742' }, billingAddress: { - address: 'Address', - zipCode: '34742', contactName: 'Jane Doe', city: 'Istanbul', - country: 'Turkey' + country: 'Turkey', + address: 'Nidakule Göztepe, Merdivenköy Mah. Bora Sok. No:1', + zipCode: '34742' }, basketItems: [ { id: 'BI101', - price: '0.3', name: 'Binocular', category1: 'Collectibles', category2: 'Accessories', - itemType: Iyzipay.BASKET_ITEM_TYPE.PHYSICAL + itemType: Iyzipay.BASKET_ITEM_TYPE.PHYSICAL, + price: '0.3' }, { id: 'BI102', - price: '0.5', name: 'Game code', category1: 'Game', category2: 'Online Game Items', - itemType: Iyzipay.BASKET_ITEM_TYPE.VIRTUAL + itemType: Iyzipay.BASKET_ITEM_TYPE.VIRTUAL, + price: '0.5' }, { id: 'BI103', - price: '0.2', name: 'Usb', category1: 'Electronics', category2: 'Usb / Cable', - itemType: Iyzipay.BASKET_ITEM_TYPE.PHYSICAL + itemType: Iyzipay.BASKET_ITEM_TYPE.PHYSICAL, + price: '0.2' } ] }; -iyzipay.payment.create(paymentAuth, function (err, result) { +iyzipay.payment.create(payment, function (err, result) { console.log(err, result); done(); });