Migrating from SqPaymentForm to Web Payments SDK - do I need new application credentials?

When I use the same application credentials, I get this error: “The Payment ‘applicationId’ option is not in the correct format”

Do I need to create a new set of application credentials?

:wave: No you can definitely use the same application as before. Would you mind providing the code for the page that you’re getting with? :slightly_smiling_face:

Sure I had just copied and then slightly adapted the code from the docs

var cardProcessor = (function() {
return {
mount: async function() {
const payments = Square.payments(gon.square_application_id, gon.square_location_id);
////// ABOVE LINE TRIGGERING ERROR

  card = await payments.card();
  await card.attach('#card-container');
},

}

Hard to tell what’s up. It seems like the credentials aren’t being passed in correctly. Would you be able to provide all the js the app is using to render the Web Payments SDK? Also I take it you’re following the migration guide too?

I’m an idiot and made a typo. Feel free to delete this as it’s not helpful to anyone

I have created a WPF application and integrate checkout-api successfully for payment via payment-url. Now I want to integrate POS device so can access card payment also at same application. Please guide, suggest a proper way to integrate it

Is your application web or mobile based? Either way you can integrate with Terminal API to accept in-person payments. :slightly_smiling_face:

1 Like