Integration instructions This manual is published for reference purposes to help developers who integrate “manually”.
Allpay does not support this integration and is not responsible for errors in its operation! If you're having trouble, ask GetCourse to create an official integration. Setup steps <span class="u-richtext-counter">1</span> Sign up for getcourse.io . If your account was created on getcourse.ru , you may need to write to GetCourse support asking you to provide access to payment systems.
<span class="u-richtext-counter">2</span> In Allpay, go to <span class="u-richtext-element">Settings</span> ➙ <span class="u-richtext-element">API Integrations</span> and create a new integration.
<span class="u-richtext-counter">3</span> Go to https://YOUR-GETCOURSE-USERNAME.getcourse.io/saas/account/api and create an API key for reading and writing.
<span class="u-richtext-counter">4</span> Send Allpay Support an API key created in GetCourse and an API login created in Allpay. Get confirmation that they've been synced.
<span class="u-richtext-counter">5</span> In GetCourse, go to <span class="u-richtext-element">Pages</span> ➙ <span class="u-richtext-element">System pages</span> ➙ <span class="u-richtext-element">Checkout</span>, add a new JavaScript block and paste the following code into it. In this case, replace the <span class="u-richtext-element">allpay_login</span> variable with yours.
<script>
function allpay_start_payment ( ) {
let allpay_login = "pp1004455" ;
let page_url = window .location.href;
let hash = page_url.substring(
page_url.indexOf( "dealPay/id/" ) + "dealPay/id/" .length
);
let order_id = document .title.split( "#" )[ 1 ];
let pay_url =
"https://allpay.to/services/getcourse.php?act=pay&login=" +
allpay_login +
"&hash=" +
encodeURIComponent (hash) +
"&host=" +
encodeURIComponent ( window .location.hostname) +
"&order_id=" +
order_id;
location.href = pay_url;
}
</script>
< div
style = "
max-width: 46ch;
margin-top: 16px;
margin-bottom: 32px;
padding: 20px;
border-style: solid;
border-width: 1px;
border-color: #c9cccf;
border-radius: 8px;
font-size: 15px;
line-height: 1.4;
"
wfd-invisible = "true"
title = "Оплата банковской картой через Allpay"
onclick = "allpay_start_payment();return false;"
>
< div style = "font-weight: 600; padding-bottom: 12px" >
Оплата банковской картой
</ div >
< div style = "padding-bottom: 16px" >
Безопасная оплата через платежную систему Allpay
</ div >
< button
type = "submit"
name = "submit-button"
class = "btn btn-info"
style = "
margin-bottom: 16px;
padding: 16px;
border-radius: 8px;
background-color: #7a74c8;
color: hsla(0, 0%, 100%, 1);
line-height: 1;
font-weight: 600;
text-align: center;
letter-spacing: 0.2px;
text-decoration: none;
width: 100%;
"
>
Оплатить
</ button >
< div
style = "
display: flex;
flex-direction: row;
justify-content: space-between;
flex-wrap: wrap;
grid-column-gap: 8px;
"
>
< img
style = "width: auto; height: 32px"
src = "https://cdn.prod.website-files.com/661942235d57990d3bc8e63c/661e443837d6e7aa809f07c7_visa.svg"
/> < img
style = "width: auto; height: 32px"
src = "https://cdn.prod.website-files.com/661942235d57990d3bc8e63c/661e4445970c1e63625ece09_mastercard.svg"
/>
< img
style = "width: auto; height: 32px"
src = "https://cdn.prod.website-files.com/661942235d57990d3bc8e63c/661e446a8dffc6a9ca888440_card-amex.svg"
/>
< img
style = "width: auto; height: 32px"
src = "https://cdn.prod.website-files.com/661942235d57990d3bc8e63c/661e442d3c63738ee86920f4_diners.svg"
/>
< img
style = "width: auto; height: 32px"
src = "https://cdn.prod.website-files.com/661942235d57990d3bc8e63c/661e4314d97d70039ab89abb_discover.svg"
/>
< img
style = "width: auto; height: 32px"
src = "https://cdn.prod.website-files.com/661942235d57990d3bc8e63c/661e4451d62760e8faab91c1_jcb.svg"
/>
</ div >
</ div >
Setup is complete and payments should work.
Setup video tutorial VIDEO
Currencies If GetCourse has a currency other than shekel as the base currency, it will be converted to shekel when you pay. An example of a payment process with the base currency is the ruble:
VIDEO
Known issues Reset product (product) settings
It is necessary that the product name and offer are exactly the same and do not contain spaces at the beginning and end. Otherwise, Getcourse resets the product settings after payment.