5 min lesen | Aktualisiert 05 Jul 2023 | Kategorie Services | User AvatarAlin Ionut

Payment Gateway - Expense

MoneyNS Gateway provide a way for your platform users to purchase expense services from your platform and make the payment in crypto, via our Checkout or API solutions. In order to gain access, you will need to have a valid platform enrolled in MoneyNS.

Service attributes in payload are mandatory in order to purchase desired Expense. Also, service beneficiary can be customized as desired and is also mandatory.

The service will be confirmed/rejected by the beneficiary, and on order approval, creator balance will be supplied with specified amount from beneficiary balance.

1. Checkout

Checkout solution represent a hybrid way of implementation, where your platform handle the checkout payload generation, with specific attributes, and our Checkout flow will handle the rest for you.

Make sure you first check Checkout Implementation Flow documentation, for information on how Checkout URL generation.

a. Crypto Expense Payment as second operation

Bellow it's a payload example for a buy operation of ETH with 100 EUR, payment done with Credit Card, and then use the crypto amount resulted in order to purchase your platform expense service, as a second operation.

{
  "link": {
	"id": "1",
	"username": "username",
	"email": "email@domain.com"
  },
  "user": {
	"email": "email@domain.com",
	"phone": "40730000000",
	"type": "personal"
  },
  "payment": {
	"operation": "buy_with_fiat",
	"symbol": "ETH",
	"secondAmount": "100",
	"secondSymbol": "EUR",
	"orderPaymentType": "card",
	"second_order_type": "payment",
	"secondService": "ea69d0c9-8370-4aca-942d-ebcc50d2adac",
	"secondServiceBeneficiary": "7aab8efc-12ba-4371-bc7e-bc42a26984ab",
	"attempts": "3"
  },
 "request_id": "1",
 "redirect_url": "https://www.google.com",
 "ping_url": "https://www.google.com/ping",
 "ip": "86.123.31.5",
 "expire": 1571848640
}

b. Crypto Expense Payment as main operation

Payment Gateway solution can be implemented as direct operation as well, as long as the user have in balance the payment amount (it will be prompted to deposit in a checkout step).

Bellow it's a payload example for a direct crypto payment, in order to purchase your platform products.

{
  "link": {
	"id": "1",
	"username": "username",
	"email": "email@domain.com"
  },
  "user": {
	"email": "email@domain.com",
	"phone": "40730000000",
	"type": "personal"
  },
  "payment": {
	"operation": "payment",
	"service": "ea69d0c9-8370-4aca-942d-ebcc50d2adac",
	"serviceBeneficiary": "7aab8efc-12ba-4371-bc7e-bc42a26984ab",
	"symbol": "ETH",
	"secondAmount": "0.1"
	"attempts": "3"
  },
 "request_id": "1",
 "redirect_url": "https://www.google.com",
 "ping_url": "https://www.google.com/ping",
 "ip": "86.123.31.5",
 "expire": 1571848640
}

2. API

API solution provide a flexible way of implementation on your platform, where you are in control of every aspects regarding user buy/sell flows. You just have to respect couple of thinks based on your particular platform settings.

Make sure you first check API documentation, for information on how API works.

a. Crypto Payment as second operation

Bellow we have the same example, where your customer request a API Quote for ETH of 100 EUR, and payment with Credit Card, and use the crypto resulted to pay for a specific platform expense service.

{
	"orderType": "buy_with_fiat",
	"orderSymbol": "ETH",
	"orderAmountPayment": "100",
	"orderPaymentSymbol": "EUR",
	"orderPaymentType": "card",
	"secondOrderType": "payment",
	"service": "ea69d0c9-8370-4aca-942d-ebcc50d2adac",
	"serviceBeneficiary": "7aab8efc-12ba-4371-bc7e-bc42a26984ab"
}

And in conclusion, a API Quote payload for a payment of 0.1 ETH, to pay for a specific platform expense service.

b. Crypto Payment as main operation

{
	"orderType": "payment",
	"orderSymbol": "ETH",
	"orderAmountPayment": "0.1",
	"service": "ea69d0c9-8370-4aca-942d-ebcc50d2adac",
	"serviceBeneficiary": "7aab8efc-12ba-4371-bc7e-bc42a26984ab"
}

Meta fields can be fully customized as desired, and we can add as many as you desired.


If this do not answer your questions, please do not hesitate to contact us at contact@cryptocoin.pro.

zum Seitenanfang