how to get customer payment method id ?

RitikaThakur
New Member
6 0 0

I had already gone through the "customerPaymentMethod " QueryRoot , and it specifics to get the customerPaymentMethod we need to pass the id & customerPaymentMethod Id is the main thing that I am looking for to pass in Create Subscription Draft Contract  , to crack the way for shopify draft order subscription line item limitations for now. This is the order object I get in order create webhook & it didn't have anything that I can pass in any of the shopify customer API's .

In fact I also tried to do customerPaymentMethodCreditCardCreate   but quite unclear to use it as didn't get the enough material/documentation to read on it . If you can clarify , will this particular mutation create the customerPaymentMethod id if I have customer billing address and customer id ? if yes then order object in order create webhook provide me both but then what about "sessionId" what exactly session id is ? Also , at what point this customerPaymentMethodCreditCardCreate  need to be fired or hit ? If you can explain the  proper understanding of customerPaymentMethodCreditCardCreate  , it  may be great help . 

Also , I am in doubt what if some customers don't user credit card at checkout then how will I proceed to get customerPaymentMethod Id ?

0 Likes