< All Topics
Print

How to connect Shopify with Mypay

It’s easy to connect Mypay with Shopify and requires absolutely zero coding experience. You have only to follow the instructions you will find below:

Add Mypay Payment provider:

First of all navigate to Shopify Settings -> Payment providers (https://YOUR_SHOPIFY_SUBDOMAIN.myshopify.com/admin/settings/payments).

From this screen disable “Express Checkout”, “Accept credit cards” and “Alternative payments”. Go to Manual payments -> Create custom payment method and create Mypay using the info below:

  • Name: External payment via Mypay Billing Platform
  • Additional details: You will be redirected to Mypay payment page in order to complete your purchase securely.

Add Checkout Additional scripts:

Navigate to Shopify settings -> Checkout (https://YOUR_SHOPIFY_SUBDOMAIN.myshopify.com/admin/settings/checkout). 

From this screen Go to “Order processing” -> “Additional scripts” and enter the code below:

<script src="https://api.mypay.gr/Content/js/v1/mypay.js"></script>
<script>    
    Mypay.Checkout({
        merchantUniqueID: {{ order.id }},
        publicCheckoutPageID: YOUR_CHECKOUT_PAGE_ID_FROM_MYPAY,
        currency: "{{ shop.currency }}",
        amount: {{ order.total_price }} / 100,
        tax: 0,
        firstName: "{{ order.customer.first_name }}",
        lastName: "{{ order.customer.last_name }}",
        email: "{{ order.customer.email }}",
        company: "{{ order.billing_address.company }}",
        phone: "{{ order.billing_address.phone }}",
        billingAddress1: "{{ order.billing_address.address1 }}",
        billingAddress2: "{{ order.billing_address.address2 }}",
        billingCountry: "{{ order.billing_address.country_code }}",
        billingCity: "{{ order.billing_address.city }}",
	billingState: "{{ order.billing_address.province_code }}",
        billingZip: "{{ order.billing_address.zip }}"
    });
</script>

Obtain your store’s keys:

The next step is to Navigate to “Apps” -> “Manage private apps” (https://YOUR_SHOPIFY_SUBDOMAIN.myshopify.com/admin/apps/private)

Click “Create a new private app” and enter your desired Name and email. Assign “Read” and “Write” to all permissions and click “Save”.

Enable Shopify in your Mypay project:

Navigate to Mypay Settings -> Plugin Settings and enable Shopify.

Enter your shopify store subdomain and password (as obtained before from your store keys).

Table of Contents
< All Topics
Print

How to connect Shopify with Mypay

It’s easy to connect Mypay with Shopify and requires absolutely zero coding experience. You have only to follow the instructions you will find below:

Add Mypay Payment provider:

First of all navigate to Shopify Settings -> Payment providers (https://YOUR_SHOPIFY_SUBDOMAIN.myshopify.com/admin/settings/payments).

From this screen disable “Express Checkout”, “Accept credit cards” and “Alternative payments”. Go to Manual payments -> Create custom payment method and create Mypay using the info below:

  • Name: External payment via Mypay Billing Platform
  • Additional details: You will be redirected to Mypay payment page in order to complete your purchase securely.

Add Checkout Additional scripts:

Navigate to Shopify settings -> Checkout (https://YOUR_SHOPIFY_SUBDOMAIN.myshopify.com/admin/settings/checkout). 

From this screen Go to “Order processing” -> “Additional scripts” and enter the code below:

<script src="https://api.mypay.gr/Content/js/v1/mypay.js"></script>
<script>    
    Mypay.Checkout({
        merchantUniqueID: {{ order.id }},
        publicCheckoutPageID: YOUR_CHECKOUT_PAGE_ID_FROM_MYPAY,
        currency: "{{ shop.currency }}",
        amount: {{ order.total_price }} / 100,
        tax: 0,
        firstName: "{{ order.customer.first_name }}",
        lastName: "{{ order.customer.last_name }}",
        email: "{{ order.customer.email }}",
        company: "{{ order.billing_address.company }}",
        phone: "{{ order.billing_address.phone }}",
        billingAddress1: "{{ order.billing_address.address1 }}",
        billingAddress2: "{{ order.billing_address.address2 }}",
        billingCountry: "{{ order.billing_address.country_code }}",
        billingCity: "{{ order.billing_address.city }}",
	billingState: "{{ order.billing_address.province_code }}",
        billingZip: "{{ order.billing_address.zip }}"
    });
</script>

Obtain your store’s keys:

The next step is to Navigate to “Apps” -> “Manage private apps” (https://YOUR_SHOPIFY_SUBDOMAIN.myshopify.com/admin/apps/private)

Click “Create a new private app” and enter your desired Name and email. Assign “Read” and “Write” to all permissions and click “Save”.

Enable Shopify in your Mypay project:

Navigate to Mypay Settings -> Plugin Settings and enable Shopify.

Enter your shopify store subdomain and password (as obtained before from your store keys).

Table of Contents
@media only screen and (min-width:768px){#eckb-article-page-container-v2 #eckb-article-body #eckb-article-content #eckb-article-content-header-v2 #eckb-article-content-header-row-1,#eckb-article-page-container-v2 #eckb-article-body #eckb-article-content #eckb-article-content-header-v2 #eckb-article-content-header-row-2,#eckb-article-page-container-v2 #eckb-article-body #eckb-article-content #eckb-article-content-header-v2 #eckb-article-content-header-row-3,#eckb-article-page-container-v2 #eckb-article-body #eckb-article-content #eckb-article-content-header-v2 #eckb-article-content-header-row-4,#eckb-article-page-container-v2 #eckb-article-body #eckb-article-content #eckb-article-content-header-v2 #eckb-article-content-header-row-5{flex-direction:row;}}#eckb-article-content-header-row-1{margin-bottom:8px;}#eckb-article-content-header-row-1 .eckb-article-content-header-row-left-group,#eckb-article-content-header-row-1 .eckb-article-content-header-row-right-group{align-items:center;}.eckb-article-content-toolbar-button-container{background-color:#ffffff;padding:10px 10px 10px 10px;margin:0px 0px 0px 0px;border-radius:0px;border-width:0px;border-color:#ffffff;border-style:solid;}.eckb-article-content-toolbar-button-container .eckb-toolbar-button-text{color:#000000;font-size:15px;}.eckb-article-content-toolbar-button-container .eckb-toolbar-button-icon{color:#000000;font-size:20px;}.eckb-article-content-toolbar-button-container:hover{background-color:#ffffff;}.eckb-article-content-toolbar-button-container:hover .eckb-toolbar-button-text{color:#000000;}.eckb-article-content-toolbar-button-container:hover .eckb-toolbar-button-icon{color:#000000;}#eckb-article-content-header-row-2{margin-bottom:0px;}#eckb-article-content-header-row-2 .eckb-article-content-header-row-left-group,#eckb-article-content-header-row-2 .eckb-article-content-header-row-right-group{align-items:flex-end;}#eckb-article-content-footer .epkb-article-navigation-container a{background-color:#f7f7f7;color:#1e73be;}#eckb-article-content-footer .epkb-article-navigation-container a:hover{background-color:#dee3e5;color:#6d6d6d;}#eckb-article-body .eckb-article-toc ul a.active{background-color:#1e73be;color:#ffffff;}#eckb-article-body .eckb-article-toc ul a:hover{background-color:#e1ecf7;color:#000000;}#eckb-article-body .eckb-article-toc__inner{border-color:#2b98e5;font-size:14px !important;background-color:#fcfcfc;}#eckb-article-body .eckb-article-toc__inner a{color:#2b98e5;font-size:14px !important;}#eckb-article-body .eckb-article-toc__title{color:#2b98e5;font-size:15px !important;}