# MobilePay in Repejo

With Vipps MobilePay, Finnish donors give in the MobilePay app. They can give
once or sign up for a recurring gift. The donor approves the payment or the
agreement in the app.

Human docs page: https://macbook-air-som-tillhr-daniel.tail570149.ts.net/docs/mobile-pay

## Where donors see MobilePay

- Only on checkouts with the country Finland and the currency EUR.
- Never on face-to-face checkouts, because the app would open on the
  recruiter's tablet.
- Only an organisation in Finland can add MobilePay numbers.

## What to order from Vipps MobilePay

Your organisation needs a sales unit at Vipps MobilePay. The sales unit needs
ePayment for one-time gifts and Recurring for recurring gifts. It must take EUR.
The sales unit's MSN is the number that you add in Repejo.

## Add a MobilePay number

A MobilePay number is the MSN (Merchant Serial Number) of the sales unit that
receives the gifts. You find it in the Vipps MobilePay portal. The back office
is in Swedish, so the labels below are the Swedish ones.

1. Go to **Inställningar → Betalmetoder**.
2. Under the heading **MobilePay**, click **Nytt MobilePay-nummer**.
3. Enter the number in **MSN**.
4. Enter a name in **Namn**.
5. Tick **Förvald** for your main number. It comes first in the list when you
   pick a number for a checkout.
6. Click **Spara**.

When you save, Repejo connects the number to Vipps MobilePay. If Vipps
MobilePay refuses the number, Repejo saves nothing and shows the error. You
cannot change the MSN later. To use another MSN, add a new number.

## Use MobilePay on a checkout

1. Open the checkout and click **Ändra**.
2. Pick **Finland** under **Land**.
3. Pick **EUR** under **Valuta**.
4. Click **Nästa**.
5. Pick your number under **MobilePay**.
6. Click **Spara**.

If you later change **Land** to another country, the checkout loses its
MobilePay number when you save.

## One-time and recurring gifts

A checkout with MobilePay can offer a one-time gift and these periods:
monthly, quarterly, half-yearly, yearly, weekly and daily. You pick them under
**Betalningsperioder**.

For a recurring gift, the donor approves an agreement in the app. The donor
pays the first period when they approve the agreement. If that payment fails,
the agreement does not start and the donor can try again. Repejo charges each
later period on the dates of the gift. The second charge is
at least two days after the signup. The signup sends a paid
`receivable.created` and a `transaction.created` dated the signup day.

## The donor manages the agreement in the app

The donor sees the agreement in the MobilePay app and can stop it there. If
your donor portal is on, the agreement in the app links to the donor's page in
the portal.

When the donor stops the agreement, Repejo ends the gift. If the donor has no
other active gift, Repejo also ends the donor.

When a MobilePay gift ends in Repejo, in the donor portal or by you, Repejo
also stops the agreement in the MobilePay app. Repejo cancels a charge that it
already asked for and that is not paid yet.

You cannot reactivate an ended MobilePay gift in Repejo.

## Pay back a gift

You can pay back a paid MobilePay gift with **Kreditera** under
**Transaktioner**. Repejo pays back the full amount.

To see what happened to a one-time MobilePay gift in Vipps MobilePay, click the
**Händelselogg** icon on the gift's row under **Transaktioner** or on the donor's
page.

## Questions and answers

**How long does the donor have to approve the payment?** 10 minutes. After
that, the payment expires.

**What does the donor see after they cancel in the app?** The checkout says
that the payment was cancelled, or the agreement declined, in the MobilePay
app. The donor can try again at once.

**When does Repejo ask for a recurring charge?** The day before its due date.
If the charge fails, Vipps MobilePay tries again every day for 5 days.
