1

I'm attempting to add orders through the soap api. I am wondering about how to fill in the payment method array

The docs gives this as a sample

$paymentMethod =  array(
        'po_number' => null,
        'method' => 'checkmo',
        'cc_cid' => null,
        'cc_owner' => null,
        'cc_number' => null,
        'cc_type' => null,
        'cc_exp_year' => null,
        'cc_exp_month' => null
    );

How about when the payment is not CC.. How do we put external transaction numbers in here? For instance when the order was entered via paypal, I'd like to include the PayPal transaction information (client name, or at least transaction number)

Am I missing something?

2 Answers 2

3

To enter the payment as paypal (standard) use:

$paymentMethod = array(
         'method' => 'paypal_standard',
         'last_trans_id' => 'xxxxxxxxxxxx'
     );

Where xxxxxxxxxxxx is your transaction id. You also need to invoice the order after you created it with the API salesOrderInvoiceCreate.

2
  • Given the standard approach, where does this fit into the api calls?
    – baash05
    Commented Aug 25, 2013 at 23:30
  • Ah.. now I see.. though the WSDL indicates the fields in my question are all I can add, I can in fact add more. Thanks Vlad...
    – baash05
    Commented Aug 26, 2013 at 0:04
2

there is a table in magento database which name is "sales_flat_quote_payment", I think those fields below could help: payment_id Payment Id quote_id Quote Id created_at Created At updated_at Updated At method Method cc_type Cc Type cc_number_enc Cc Number Enc cc_last4 Cc Last4 cc_cid_enc Cc Cid Enc cc_owner Cc Owner cc_exp_month Cc Exp Month cc_exp_year Cc Exp Year cc_ss_owner Cc Ss Owner cc_ss_start_month Cc Ss Start Month cc_ss_start_year Cc Ss Start Year cybersource_token paypal_correlation_id Paypal Correlation Id paypal_payer_id Paypal Payer Id paypal_payer_status Paypal Payer Status po_number Po Number additional_data Additional Data cc_ss_issue Cc Ss Issue ideal_issuer_id ideal_issuer_list additional_information

2
  • In the context of the API. How would I engage these fields? I don't see where they fit in.
    – baash05
    Commented Aug 25, 2013 at 23:43
  • I see what you mean, now... With your answer and Vlad's answer I think I see. I can put any of the fields in the table, into the paymentMethod array.
    – baash05
    Commented Aug 26, 2013 at 0:05

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.