1. Changelog

Version Date Description

1.0

2018-06-25

First release of documentation.

1.1

2018-11-22

Documentation updated. Added information about errors related to incompatible country codes of User and User’s card for USA or CAN transaction in: 3.1.2. Response→ 200 OK - Error validation, 3.2.2. Response → 200 OK - Error validation.

1.2

2018-11-27

Documentation updated. Change description about response field "prefix" in: 9.5. Get countries

1.3

2019-01-02

Added new transaction error status: ERROR_MPI_STATUS_TO_LOW: 3.2.3 Response→ 500 INTERNAL SERVER ERROR

1.4

2019-01-10

Tutorial and FAQ pages added:
14. FAQ
Tutorial

1.5

2019-03-21

Added new method to check deposit state for CASH_CARD Merchants
7. Check deposit state

1.6

2019-04-26

Datacenter migration.
Removed fields from here: 9.1 Add user
-acceptMarketing
-acceptTos
-dailyLimit

1.7

2019-07-10

ISO-8583 statuses updated

1.8

2019-07-17

Regexp for Postal code properties in each occurrences was changed

1.9

2019-09-06

New response code added
3.1.3 Check status
3.2.3 Check status 3ds

2.0

2019-09-16

New response code added
3.1.3 Check status
3.2.3 Check status 3ds

2.1

2019-09-26

New response code from Monitoring service added
3.1.3 Check status
3.2.3 Check status 3ds

2.2

2019-10-11

Regular expression added to models
13. Models

2.3

2020-01-31

Information about certification process added

2.4

2020-03-05

New response code from Monitoring service added: ERROR_FUNDING_BANK_IS_BLOCKED, ERROR_PAYMENT_BANK_IS_BLOCKED
3.1.3 Check status
3.2.3 Check status 3ds

2.5

2020-03-17

Add information about card bin to responses of methods: Get Card List, Get Friend Card List
10.3. Get card list
11.4. Get friend card list

2.6

2020-05-21

User blocking for entire system operations feature added, new response for login method added.
8.1. Login

2.7

2020-06-03

Documentation updated. Change value and description about field "md" in Initialize and Finalize methods:
5.2. Initialize
5.3. Finalize

2.8

2020-07-03

Documentation updated. Error ERROR_WHILE_GETTING_COUNTRY_CODE added for Calculate commission method.

2.9

2020-07-09

Description of check card’s provided added.

3.0

2020-10-05

Documentation updated. Error CURRENCY_RATES_NOT_FOUND added for send money error statuses.

3.1

2020-10-14

Add new VISA response code value 80

3.2

2020-11-17

3DS 2.x method introduced in Send money
3.3 Send money outside 3DS 1.0/2.X

3.3

2020-12-02

New status: CARD_LIMIT_REACHED for Add Card and Add Friend Card methods. Default limits are 5 cards per user and 5 friend cards per user. These values are configured for the merchant, please contact us if you need changes

3.4

2020-12-03

Add new Delayed Payment methods.
4. Delayed payment

3.5

2020-12-16

Modify personal data validation for send money methods, especially sender and receiver - firstName, lastName, email. Set minimum length 2 for firstName and lastName. FirstName and lastName cannot be the same and cannot consist of the same characters. One email address cannot be the same within sender and receiver for 2 different personal data.

3.6

2021-01-05

Updates for 3DS 2.X

3.7

2021-01-13

New merchant cumulative limits added: daily and monthly with distinction between Mastercard and VISA.
New Statuses added: ERROR_MERCHANT_MASTERCARD_DAILY_CUMULATIVE_LIMIT, ERROR_MERCHANT_MASTERCARD_MONTHLY_CUMULATIVE_LIMIT, ERROR_MERCHANT_VISA_DAILY_CUMULATIVE_LIMIT, ERROR_MERCHANT_VISA_MONTHLY_CUMULATIVE_LIMIT
Old status to remove: ERROR_MERCHANT_MONTHLY_CUMULATIVE_LIMIT
3.1.3 Check status
3.2.3 Check status 3ds

3.8

2021-01-18

New fields 'merchantUrl' and 'addressIp' in Send Money request added. Both fields are optional now, but it is recommended to include it in your request body. From 2021-05-03 the fields will be required.

3.9

2021-02-02

Added new fields '3DS', 'amountInUsDollar', 'provider', 'bankName' on thw response body for Check status and Transaction history methods.

4.0

2021-02-02

Added method Currency rate by provider which also allows you to download historical rates.

4.1

2021-02-17

New status: CARD_MODIFY_LIMIT_REACHED for Add/Delete Card and Add/Delete Friend Card methods. Default limits are set to 3 cards modifications e.g. Add/Delete card per user during 24h also 3 modifications for friend cards. These values could be modified for the merchant, please contact us if you need changes.

4.2

2021-03-01

Introduction of a new webhook functionality. Now it is possible to handle information about transaction status without polling API.
5. Webhooks

4.3

2021-04-22

Exclusion of deprecated currencies. Validation will reject these currencies: BYR, LTL, MRO, RUR, STD

4.4

2021-04-26

Introducing a service that validates the personal information of transaction users and Add User method data. In case of positive verification, the transaction/Add User is rejected with the status: ERROR_USER_VERIFICATION

4.5

2021-05-05

An implementation of CODE_65 transaction rejection logic for MASTERCARD and VISA. More details can be found here: 3. Send money 4. Delayed payment

2. Introduction

Document describes technical scope of the "Fenige Transfer HUB REST API" i.e. services, which is financial institution that processes credit or debit card payments.

Quick tutorial that may helps you in works with API you can find here: Tutorial

Implementation of Fenige Transfer HUB REST API

Documentation has been prepared for external partners that are willing to cooperate with Fenige and offer MoneySend card-to-card P2P transactions inside their mobile or web applications. The roles of Fenige and Partner in such project are the following:

Partner:

  • can act as Payment Institution in front of MasterCard and Financial Regulators in the country

  • operates mobile or web application via which customers can initiate MoneySend transactions

  • collects customer data during transaction and transfers it to Fenige via Rest API for transaction authorization and clearing

  • decides on consumer fees per transaction that are charged by Fenige during transaction

  • receives agreed fees for MoneySend transactions from Fenige

Fenige:

  • can act as Payment Institution in front of MasterCard and Financial Regulators in the country

  • operates transaction processing system that enables authorization and clearing of MoneySend transactions initiated at partner application

  • process transaction and necessary customer data

  • provides Rest API to partner so that partner is able to initiate transaction

  • is reponsible for settlement of transactions with issuers of cards provided by customers

  • transfers agreed fees to Partner one per month

High Level Architecture:

High Level Architecture
Figure 1. High Level Architecture

Transaction process:

  1. Consumer registers at partner mobile or web application

  2. Partner collects consumer and card data that are necessary to process transaction

  3. Fenige MoneySend Hub receives transaction data from Partner system

  4. Fenige transfers transaction data to MasterCard network and process responses

  5. Fenige settles transaction with MasterCard

  6. Fenige transfer agreed transaction fees to Partner

Partner can initiate a few optional methods via Fenige hub that enable processing of MoneySend transaction:

  1. Check limits

  2. Calculate comission

  3. Send money

SM PLAIN PLAIN

There are also optional methods that can be used by partners which store card data at Fenige or uPaid systems:

  1. Log user

  2. Verify 3DS

2.1. Certification

In order to access the Moneysend API, you must successfully pass the certification process in our dedicated application. The application is available at https://certification.fenige.pl/
The new partner will receive login data from the Fenige employee, who is responsible for introducing new customers. After a positive result, the partner receives access to the production environment. Be adviced that the entire process takes place in a staging environment.

2.2. Endpoints

Environment Endpoint (base url)

Staging

https://java-staging.fenige.pl:8181/

2.3. HTTP verbs

RESTful notes tries to adhere as closely as possible to standard HTTP and REST conventions in its use of HTTP verbs.

Verb Usage

GET

Used to retrieve a resource

POST

Used to create a new resource

PUT

Used to update specific resource

DELETE

Used to delete a resource

2.4. User authentication

Authentication in HUB API is done by basic authentication and two token mechanism.

  1. API-TOKEN - we can use this authentication method when client is integrated only with HUB application.

  2. X-Request-Token, X-Device-ID - this authentication method is using by mobile devices which are in communication with different server.

User authentication

2.5. Language

If you want to select your language, add Accept-Language header to request JSON and set its value to, for example, pl, en, cs or sk. In case of a successful transaction for the send money method you will receive a email confirmation in the language which you set.

Accept-Language

en

2.6. General methods

All api methods require the delivery of appropriate headers.

List of methods headers used in Fenige REST API:

Key Value Validation Description

Content-Type

application/json

Required

Used to indicate the media type of the resource

Content-Type

application/vnd.sendmoney.v2+json

Optional

Used for send-money with multi-currency purpose

Content-Type

application/vnd.sendmoney3ds.v2+json

Optional

Used for send-money-3ds with multi-currency purpose

Content-Type

application/vnd.determine-currencies.v2+json

Optional

Used for determine currencies with multi-currency purpose

Content-Type

application/vnd.calculate-commission.v2+json

Optional

Used for calculate commission with multi-currency purpose

Authorization

Basic dGVzdDp0ZXN0

Required

Used to resolve merchant context of user. Basic Auth from merchant data (merchant name and password). Consist of keyword Basic and string obtained from Base64 coding method for merchant name and password parameter

API-TOKEN

BMT4wKduNftnN3AUkkKnm4BJEqiMKZlcdLiKRtJH9ac=

Optional

Some of the methods require additional authentication. The API-TOKEN is obtained by calling the logUser method. API-TOKEN is valid for 30 minutes

2.7. HTTP status codes

RESTful notes tries to adhere as closely as possible to standard HTTP and REST conventions in its use of HTTP status codes.

Status code Usage

200 OK

The request completed successfully

202 Accepted

The request has been accepted for processing, but the processing has not been completed. The request might or might not eventually be acted upon, as it might be disallowed when processing actually takes place

203 NON-AUTHORITATIVE INFORMATION

The request with 3ds has been registered for processing. Check status in a while

400 Bad Request

The request was malformed. The response body will include an error providing further information

404 Not Found

The requested resource did not exist

500 Internal Server Error

Message occur when an unexpected condition was encountered

2.8. Mastercard/VISA response code (ISO 8583):

Status code Usage

CODE_00

Approved or completed successfully

CODE_01

Refer to card issuer

CODE_02

Refer to card issuer, special condition

CODE_03

Invalid merchant or service provider

CODE_04

Capture card/Pick up card (no fraud)

CODE_05

Do not honor

CODE_06

General error

CODE_07

Pickup card, special condition (other than lost/stolen card)

CODE_08

Honor with ID

CODE_10

Partial approval

CODE_11

Approved (V.I.P)

CODE_12

Invalid transaction

CODE_13

Invalid amount or currency conversion field overflow

CODE_14

Invalid account number (no such number)

CODE_15

Invalid issuer/No such issuer

CODE_19

Re-enter transaction

CODE_21

No action taken

CODE_25

Unable to locate record in file

CODE_28

File temporarily not available for update or inquiry

CODE_30

Format error

CODE_39

No credit account

CODE_41

Lost card, pick up (fraud account)

CODE_43

Stolen card, pick up (fraud account)

CODE_44

No investment account

CODE_46

Closed account

CODE_51

Insufficient funds/over credit limit

CODE_52

No checking account

CODE_53

No savings account

CODE_54

Expired card or expiration date is missing

CODE_55

Incorrect PIN or PIN missing

CODE_57

Transaction not permitted to issuer/cardholder

CODE_58

Transaction not permitted to acquirer/terminal

CODE_59

Suspected fraud

CODE_61

Exceeds withdrawal amount limit/Exceeds approval amount limit

CODE_62

Restricted card (card invalid in this region or country)

CODE_63

Security violation (source is not correct issuer)

CODE_64

Transaction does not fulfill AML requirement

CODE_65

Exceeds withdrawal frequency limit

CODE_68

Response received too late

CODE_70

Contact Card Issuer

CODE_71

PIN Not Changed

CODE_75

Allowable number of PIN tries exceeded

CODE_76

Invalid/nonexistent “To Account” specified

CODE_77

Invalid/nonexistent “From Account” specified

CODE_78

Invalid/nonexistent account specified(general)/Blocked, first used—transaction from new cardholder, and card not properly unblocked (Visa)

CODE_79

Already reversed (by Switch)

CODE_80

No financial impact

CODE_81

Domestic Debit Transaction Not Allowed (Regional use only)/Cryptographic error found in PIN(Visa)

CODE_82

Negative CAM, dCVV, iCVV, or CVV results/Offline PIN authentication interrupted

CODE_84

Invalid Authorization Life Cycle

CODE_85

No reason to decline a request for address verification, CVV2 verification, or a credit voucher or merchandise return

CODE_86

PIN Validation not possible

CODE_87

Purchase Amount Only, No Cash Back

CODE_88

Cryptographic failure

CODE_89

Card verification value (CVV) verification failed (no pickup)/Ineligible to receive financial position information (GIV)

CODE_91

Authorization Platform or issuer system inoperative

CODE_92

Unable to route transaction

CODE_93

Transaction cannot be completed - violation of law

CODE_94

Duplicate transmission detected

CODE_95

Reconcile error

CODE_96

System malfunction or certain field error conditions

CODE_B1

Surcharge amount not permitted on Visa cards (U.S. acquirers only)

CODE_B2

Surcharge amount not supported by debit network issuer.

CODE_N0

Force STIP

CODE_N3

Cash service not available

CODE_N4

Cashback request exceeds issuer limit

CODE_N5

Ineligible for resubmission

CODE_N7

Decline for CVV2 failure

CODE_N8

Transaction amount exceeds preauthorized approval amount

CODE_P2

Invalid biller information

CODE_P5

PIN Change/Unblock request declined

CODE_P6

Unsafe PIN

CODE_Q1

Card Authentication failed

CODE_R0

Stop Payment Order

CODE_R1

Revocation of authorization order

CODE_R3

Revocation of all authorizations order

CODE_XA

Forward to issuer

CODE_XD

Forward to issuer

CODE_Z3

Unable to go online

CODE_TBA

Customer ID verification failed")

3. Send money

See a diagrams bellow and notice that CARD-CARD and CASH-CARD flow are not the same.

Mastercard and Visa requires for intra-European Economic Area (EEA), plus United Kingdom, for which EMV 3DS must be used subsequent to a valid authorization soft decline DE39=65. To perform a transaction for which the card has previously received CODE_65, the transaction must be processed with full EMV 3DS (3DS 2.x) and the authentication status must be 'Y'.

Correct flow:

  • 3DS 2.x → Challenge → Authentication status Y → Transaction (Recommended)

  • 3DS 2.x → Card number not Enrolled in 3DS v2 → 3DS 1.0 → Transaction (Recommended)

  • 3DS 1.0 → Authentication status Y/A → Transaction → CODE_65 → 3DS 2.x → Challenge → Authentication status Y → Transaction (Not recommended)

  • non3DS → Transaction → CODE_65 → 3DS 2.x → Challenge → Authentication status Y → Transaction (Available only to selected merchants)

soft decline Code 65 EMV 3DS
CARD - CARD

Is apply for: PLAIN-PLAIN, PLAIN-PLAIN USA/CAN, DATACORE-PLAIN, DATACORE-DATACORE, DATACORE-PHONE

SM PLAIN PLAIN
CASH - CARD

Is apply for: CASH-PLAIN, CASH-PHONE

SM CASH CARD

3.1. Send money

POST /api/v2/client/send-money Content-Type: application/vnd.sendmoney.v2+json, Authorization: Basic Auth, API-TOKEN*
This method is used to full MoneySend transaction (funding and payment). To enable users to make transfers in any currency, Fenige introduces the send-money method for
multicurrency.
1 - User by selecting type = SENDER defines amount of funding in given currency. This amount is collected from sender card in selected currency.
2 - User by selecting type = RECEIVER defines amount of payment in given currency. This amount is transferred to receiver card in selected currency.
In case there's need revaluation from one currency to another, system uses lowerRate for situation 1 and higherRate for situation 2.
For more details about specific rates please refer to Currency Rate method.
*API-TOKEN is required for methods: DATACORE-PLAIN, DATACORE-DATACORE, DATACORE-CASH, DATACORE-PHONE, CASH-PHONE
Please notice that you can choose language of email confirmation of this transaction. It is able by attach proper header to request.
SM MULTI CURRENCY
The success of the multicurrency send-money transaction depends primarily on the correctness of the merchant's currency configuration which is done by the admin. To make transactions in a currency other than the currency of the card, contact the admin.
In order to provide users with the ability to safely retry transaction (for example to request for an undelivered response), the v2 of API supports idempotent send money multi-currency operation.

From January 2021, there is an internal functionality to restrict access for the Merchant to specific method. The Fenige employee can disable access to a given endpoint, then the HTTP status 403 FORBIDDEN will be returned. The Merchant will be informed about each access restriction action.

3.1.1. Request

Request fields

Table 1. Multicurrency
Path Type Validation Rule Description

amount

Number

Required

@NotNull, positive

The total transfer amount (in pennies)

cvc2

String

Required

@Length(min = 3, max = 3)

Sender card cvc2/cvv2

merchantUrl

String

Optional, mandatory from 2021-05-03

@Optional

Merchant identifier such as the business website URL or reverse domain name as presented to the consumer during checkout

addressIp

String

Optional mandatory from 2021-05-03, @Must match the regular expression ^([0-9]{1,3}.){3}[0-9]{1,3}$

@Optional

The IP address of the order of transaction

type

String

Required

@NotNull

Transaction in 'SENDER' or 'RECEIVER' currency

requestId

String

Required

@NotNull

128 bit number generated by the user, used to identify single transaction. Ensures that the transaction with the given parameter is processed only once.

sender

Object

Required

@NotNull

Sender PLAIN Sender CASH Sender DATACORE

receiver

Object

Required

@NotNull

Receiver PLAIN Receiver CASH Receiver DATACORE Receiver PHONE

Example HTTP Request
PLAIN-PLAIN
POST /api/v2/client/send-money HTTP/1.1
Content-Type: application/vnd.sendmoney.v2+json
Authorization: Basic bWVyY2hhbnQ6cGFzc3dvcmQ=
Host: java-staging.fenige.pl:8181
Content-Length: 745

{
  "amount" : 1000,
  "cvc2" : "123",
  "merchantUrl" : "https://fenige.pl/payments",
  "addressIp" : "192.168.0.1",
  "type" : "SENDER",
  "requestId" : "99d41ea5-a24f-490b-be36-8a2122cf1043",
  "sender" : {
    "type" : "PLAIN",
    "firstName" : "Mark",
    "lastName" : "Smith",
    "street" : "Olszewskiego",
    "houseNumber" : "17A",
    "city" : "Lublin",
    "postalCode" : "20-400",
    "flatNumber" : "2",
    "email" : "senderEmail@fenige.pl",
    "currency" : "PLN",
    "cardNumber" : "5117964247989169",
    "expirationDate" : "03/23",
    "personalId" : "AGC688910"
  },
  "receiver" : {
    "type" : "PLAIN",
    "firstName" : "Rob",
    "lastName" : "Wring",
    "currency" : "PLN",
    "cardNumber" : "5117964247989169"
  }
}
PLAIN-PLAIN USA/CAN
POST /api/v2/client/send-money HTTP/1.1
Content-Type: application/vnd.sendmoney.v2+json
Authorization: Basic bWVyY2hhbnQ6cGFzc3dvcmQ=
Host: java-staging.fenige.pl:8181
Content-Length: 788

{
  "amount" : 1000,
  "cvc2" : "123",
  "merchantUrl" : "https://fenige.pl/payments",
  "addressIp" : "192.168.0.1",
  "type" : "SENDER",
  "requestId" : "05ad5c21-e216-4f82-b0bb-9ff9b85caae2",
  "sender" : {
    "type" : "PLAIN",
    "firstName" : "Mark",
    "lastName" : "Smith",
    "street" : "Gates Court",
    "houseNumber" : "82",
    "city" : "Brooklyn",
    "postalCode" : "11211",
    "flatNumber" : "2",
    "email" : "senderdocs@fenige.pl",
    "currency" : "USD",
    "cardNumber" : "5448424719416233",
    "expirationDate" : "03/23",
    "personalId" : "AGC688910",
    "country" : "US",
    "province" : "NY"
  },
  "receiver" : {
    "type" : "PLAIN",
    "firstName" : "Rob",
    "lastName" : "Wring",
    "currency" : "PLN",
    "cardNumber" : "5117964247989169"
  }
}
PLAIN-CASH
POST /api/v2/client/send-money HTTP/1.1
Content-Type: application/vnd.sendmoney.v2+json
Authorization: Basic bWVyY2hhbnQ6cGFzc3dvcmQ=
Host: java-staging.fenige.pl:8181
Content-Length: 879

{
  "amount" : 1000,
  "cvc2" : "123",
  "merchantUrl" : "https://fenige.pl/payments",
  "addressIp" : "192.168.0.1",
  "type" : "SENDER",
  "requestId" : "d032dd49-3814-49c5-9d7d-22570f054417",
  "sender" : {
    "type" : "PLAIN",
    "firstName" : "Mark",
    "lastName" : "Smith",
    "street" : "Olszewskiego",
    "houseNumber" : "17A",
    "city" : "Lublin",
    "postalCode" : "20-400",
    "flatNumber" : "2",
    "email" : "senderEmail@fenige.pl",
    "currency" : "PLN",
    "cardNumber" : "5117964247989169",
    "expirationDate" : "03/23",
    "personalId" : "AGC688910"
  },
  "receiver" : {
    "type" : "CASH",
    "firstName" : "Rob",
    "lastName" : "Wring",
    "street" : "Lubelska",
    "houseNumber" : "17A",
    "city" : "Lubartów",
    "postalCode" : "21-100",
    "flatNumber" : "2",
    "email" : "receiverEmail@fenige.pl",
    "currency" : "PLN"
  }
}
PLAIN-CASH USA/CAN
POST /api/v2/client/send-money HTTP/1.1
Content-Type: application/vnd.sendmoney.v2+json
Authorization: Basic bWVyY2hhbnQ6cGFzc3dvcmQ=
Host: java-staging.fenige.pl:8181
Content-Length: 922

{
  "amount" : 1000,
  "cvc2" : "123",
  "merchantUrl" : "https://fenige.pl/payments",
  "addressIp" : "192.168.0.1",
  "type" : "SENDER",
  "requestId" : "baae8938-d71d-48fa-b24e-0f24b4125271",
  "sender" : {
    "type" : "PLAIN",
    "firstName" : "Mark",
    "lastName" : "Smith",
    "street" : "Gates Court",
    "houseNumber" : "82",
    "city" : "Brooklyn",
    "postalCode" : "11211",
    "flatNumber" : "2",
    "email" : "senderdocs@fenige.pl",
    "currency" : "USD",
    "cardNumber" : "5448424719416233",
    "expirationDate" : "03/23",
    "personalId" : "AGC688910",
    "country" : "US",
    "province" : "NY"
  },
  "receiver" : {
    "type" : "CASH",
    "firstName" : "Rob",
    "lastName" : "Wring",
    "street" : "Lubelska",
    "houseNumber" : "17A",
    "city" : "Lubartów",
    "postalCode" : "21-100",
    "flatNumber" : "2",
    "email" : "receiverEmail@fenige.pl",
    "currency" : "PLN"
  }
}
DATACORE-PLAIN
POST /api/v2/client/send-money HTTP/1.1
Content-Type: application/vnd.sendmoney.v2+json
Authorization: Basic bWVyY2hhbnQ6cGFzc3dvcmQ=
API-TOKEN: d94NYa+xqRrazUPzSgYeJ6qR/MzIOb3IzePb7t9sWds=
Host: java-staging.fenige.pl:8181
Content-Length: 666

{
  "amount" : 1000,
  "cvc2" : "123",
  "merchantUrl" : "https://fenige.pl/payments",
  "addressIp" : "192.168.0.1",
  "type" : "SENDER",
  "requestId" : "76101ed8-9996-4df3-9a5d-fd4c88d2060f",
  "sender" : {
    "type" : "DATACORE",
    "firstName" : "Mark",
    "lastName" : "Smith",
    "street" : "Olszewskiego",
    "houseNumber" : "17A",
    "city" : "Lublin",
    "postalCode" : "20-400",
    "flatNumber" : "2",
    "email" : "senderEmail@fenige.pl",
    "currency" : "PLN",
    "cardId" : 1234
  },
  "receiver" : {
    "type" : "PLAIN",
    "firstName" : "Rob",
    "lastName" : "Wring",
    "currency" : "PLN",
    "cardNumber" : "5117964247989169"
  }
}
DATACORE-DATACORE
POST /api/v2/client/send-money HTTP/1.1
Content-Type: application/vnd.sendmoney.v2+json
Authorization: Basic bWVyY2hhbnQ6cGFzc3dvcmQ=
API-TOKEN: d94NYa+xqRrazUPzSgYeJ6qR/MzIOb3IzePb7t9sWds=
Host: java-staging.fenige.pl:8181
Content-Length: 692

{
  "amount" : 1000,
  "cvc2" : "123",
  "merchantUrl" : "https://fenige.pl/payments",
  "addressIp" : "192.168.0.1",
  "type" : "SENDER",
  "requestId" : "6ae419f4-3789-4821-a73f-df8b8a66da79",
  "sender" : {
    "type" : "DATACORE",
    "firstName" : "Mark",
    "lastName" : "Smith",
    "street" : "Olszewskiego",
    "houseNumber" : "17A",
    "city" : "Lublin",
    "postalCode" : "20-400",
    "flatNumber" : "2",
    "email" : "senderEmail@fenige.pl",
    "currency" : "PLN",
    "cardId" : 1234
  },
  "receiver" : {
    "type" : "DATACORE",
    "firstName" : "Rob",
    "lastName" : "Wring",
    "email" : "receiverEmail@fenige.pl",
    "currency" : "PLN",
    "cardId" : 1234
  }
}
DATACORE-CASH
POST /api/v2/client/send-money HTTP/1.1
Content-Type: application/vnd.sendmoney.v2+json
Authorization: Basic bWVyY2hhbnQ6cGFzc3dvcmQ=
API-TOKEN: d94NYa+xqRrazUPzSgYeJ6qR/MzIOb3IzePb7t9sWds=
Host: java-staging.fenige.pl:8181
Content-Length: 800

{
  "amount" : 1000,
  "cvc2" : "123",
  "merchantUrl" : "https://fenige.pl/payments",
  "addressIp" : "192.168.0.1",
  "type" : "SENDER",
  "requestId" : "04cc0e09-6c79-4077-bd64-ce63cee16b38",
  "sender" : {
    "type" : "DATACORE",
    "firstName" : "Mark",
    "lastName" : "Smith",
    "street" : "Olszewskiego",
    "houseNumber" : "17A",
    "city" : "Lublin",
    "postalCode" : "20-400",
    "flatNumber" : "2",
    "email" : "senderEmail@fenige.pl",
    "currency" : "PLN",
    "cardId" : 1234
  },
  "receiver" : {
    "type" : "CASH",
    "firstName" : "Rob",
    "lastName" : "Wring",
    "street" : "Lubelska",
    "houseNumber" : "17A",
    "city" : "Lubartów",
    "postalCode" : "21-100",
    "flatNumber" : "2",
    "email" : "receiverEmail@fenige.pl",
    "currency" : "PLN"
  }
}
DATACORE-PHONE
POST /api/v2/client/send-money HTTP/1.1
Content-Type: application/vnd.sendmoney.v2+json
Authorization: Basic bWVyY2hhbnQ6cGFzc3dvcmQ=
API-TOKEN: d94NYa+xqRrazUPzSgYeJ6qR/MzIOb3IzePb7t9sWds=
Host: java-staging.fenige.pl:8181
Content-Length: 662

{
  "amount" : 1000,
  "cvc2" : "123",
  "merchantUrl" : "https://fenige.pl/payments",
  "addressIp" : "192.168.0.1",
  "type" : "SENDER",
  "requestId" : "9bebf8fc-efcd-4e40-be68-31aba0e1cb31",
  "sender" : {
    "type" : "DATACORE",
    "firstName" : "Mark",
    "lastName" : "Smith",
    "street" : "Olszewskiego",
    "houseNumber" : "17A",
    "city" : "Lublin",
    "postalCode" : "20-400",
    "flatNumber" : "2",
    "email" : "senderEmail@fenige.pl",
    "currency" : "PLN",
    "cardId" : 1234
  },
  "receiver" : {
    "type" : "PHONE",
    "firstName" : "Rob",
    "lastName" : "Wring",
    "currency" : "PLN",
    "phoneNumber" : "48123777619"
  }
}
SM DATACORE PHONE
CASH-PLAIN
POST /api/v2/client/send-money HTTP/1.1
Content-Type: application/vnd.sendmoney.v2+json
Authorization: Basic bWVyY2hhbnQ6cGFzc3dvcmQ=
Host: java-staging.fenige.pl:8181
Content-Length: 598

{
  "amount" : 1000,
  "type" : "SENDER",
  "requestId" : "80419f34-a7eb-4a48-902f-04a7bf732bcb",
  "sender" : {
    "type" : "CASH",
    "firstName" : "Mark",
    "lastName" : "Smith",
    "street" : "Olszewskiego",
    "houseNumber" : "17A",
    "city" : "Lublin",
    "postalCode" : "20-400",
    "flatNumber" : "2",
    "email" : "senderEmail@fenige.pl",
    "currency" : "PLN",
    "personalId" : "AGC688910",
    "country" : "PL"
  },
  "receiver" : {
    "type" : "PLAIN",
    "firstName" : "Rob",
    "lastName" : "Wring",
    "currency" : "PLN",
    "cardNumber" : "5117964247989169"
  }
}
CASH-PHONE
POST /api/v2/client/send-money HTTP/1.1
Content-Type: application/vnd.sendmoney.v2+json
Authorization: Basic bWVyY2hhbnQ6cGFzc3dvcmQ=
API-TOKEN: d94NYa+xqRrazUPzSgYeJ6qR/MzIOb3IzePb7t9sWds=
Host: java-staging.fenige.pl:8181
Content-Length: 594

{
  "amount" : 1000,
  "type" : "SENDER",
  "requestId" : "f3397ac4-d015-4e89-a52c-42ac208cf0a8",
  "sender" : {
    "type" : "CASH",
    "firstName" : "Mark",
    "lastName" : "Smith",
    "street" : "Olszewskiego",
    "houseNumber" : "17A",
    "city" : "Lublin",
    "postalCode" : "20-400",
    "flatNumber" : "2",
    "email" : "senderEmail@fenige.pl",
    "currency" : "PLN",
    "personalId" : "AGC688910",
    "country" : "PL"
  },
  "receiver" : {
    "type" : "PHONE",
    "firstName" : "Rob",
    "lastName" : "Wring",
    "currency" : "PLN",
    "phoneNumber" : "48123777619"
  }
}

3.1.2. Response

Response status
Status Description

200 OK - Error validation

Returned list of field name which has validation errors.

202 Accepted

- Returned when the transaction with the provided requestId has been registered in the system, but has not yet been completed. The user can retry in a few seconds to get the transaction result. Response body: Empty
or
- Returned order-id when transaction will be processed.

400 Bad Request

Returned e.g. when a different transaction with the provided requestId has already been registered in the system.

Example HTTP Response
202 Accepted
HTTP/1.1 202 Accepted
Content-Type: application/json;charset=ISO-8859-1
Content-Length: 56

{
  "orderId" : "0090e301-3f95-4b35-b549-1b746f1478fd"
}

Response fields

Path Type Description

orderId

String

Unique transaction identifier

400 Bad request
HTTP/1.1 400 Bad Request
Content-Type: application/json;charset=ISO-8859-1
Content-Length: 104

{
  "error" : {
    "message" : "Another transaction with the same id has already been processed."
  }
}
200 OK - Error validation
HTTP/1.1 200 OK
Content-Type: application/json;charset=ISO-8859-1

{
	"status": "ERROR_VALIDATION",
	"error": {
		"message": "Some information is missing or incorrect.",
		"errors": [{
				"field": "requestId",
				"message": [
					"may not be null"
				]
			},
			{
				"field": "cvc2",
				"message": [
					"may not be null",
					"length must be 3"
				]
			},
			{
				"field": "type",
				"message": [
					"may not be null"
				]
			},
			{
				"field": "amount",
				"message": [
					"may not be null"
				]
			},
			{
				"field": "sender",
				"message": [
					"may not be null"
				]
			},
			{
				"field": "sender.cardNumber",
				"message": [
					"may not be null",
					"may not be empty",
					"card number length must be 16"
				]
			},
			{
				"field": "sender.expirationDate",
				"message": [
					"invalid card expiration date",
					"may not be null",
					"may not be empty"
				]
			},
			{
				"field": "sender.city",
				"message": [
					"may not be empty",
					"may not be null",
					"length must be between 1 and 25"
				]
			},
			{
				"field": "sender.street",
				"message": [
					"may not be null",
					"may not be empty",
					"length must be between 1 and 50"
				]
			},
            {
				"field": "sender.postalCode",
				"message": [
					"may not be empty",
					"may not be null",
					"length must be between 1 and 10"
				]
			},
            {
                "field": "sender.flatNumber",
                "message": [
                    "must be null",
                    "length must be between 0 and 5"
                ]
            },
			{
				"field": "sender.lastName",
				"message": [
					"may not be empty",
					"may not be null",
					"length must be between 2 and 35"
				]
			},
			{
				"field": "sender.houseNumber",
				"message": [
					"may not be empty",
					"may not be null",
					"length must be between 1 and 10"
				]
			},
			{
				"field": "sender.firstName",
				"message": [
					"may not be empty",
					"may not be null",
					"length must be between 2 and 35"
				]
			},
            {
				"field": "sender.email",
				"message": [
					"may not be empty",
					"may not be null",
					"not a well-formed email address",
					"lenght must be beetween 1 and 128"
				]
			},
			{
				"field": "receiver",
				"message": [
					"may not be null"
				]
			},
			{
				"field": "receiver.firstName",
				"message": [
					"may not be empty",
					"may not be null",
					"length must be between 2 and 35"
				]
			},
			{
				"field": "receiver.lastName",
				"message": [
					"may not be empty",
					"may not be null",
					"length must be between 2 and 35"
				]
			},
			{
				"field": "receiver.currency",
				"message": [
					"may not be null"
				]
			},
			{
				"field": "receiver.cardNumber",
				"message": [
					"may not be null",
					"may not be empty",
					"card number length must be 16"
				]
			},
			{
                "field": "sender",
                "message": [
                     "province is mandatory only if country code is US or CA"
                ]
            },
            {
                "field": "sender.province",
                "message": [
                      "is not correct province code for country code US",
                      "may not be null"
                ]
            },
            {
                "field": "sender.province",
                 "message": [
                       "may not be null",
                       "is not correct province code for country code CA"
                 ]
            },
            {
                 "field": "sender.province",
                 "message": [
                        "must match ^[A-Z]{2}$",
                        "is not correct province code for country code US"
                 ]
            },
            {
                 "field": "sender.currency",
                 "message": [
                       "Currency is not supported"
                ]
            },
            {
                 "field": "receiver.currency",
                 "message": [
                       "Currency is not supported"
                ]
            }
		]
	}
}
Errors mentioned below may occur if card’s country is other than user’s country for USA or CAN transaction
HTTP/1.1 200 OK
Content-Type: application/json

{
    "status": "ERROR_WHILE_VALIDATING_CARD_COUNTRY_CODE_AND_USER_COUNTRY_CODE_FOR_PLAIN",
    "error": {
        "message": "Card country code not compatible with user country code.
                    Please update country in request."
    }
}
HTTP/1.1 200 OK
Content-Type: application/json

{
    "status": "ERROR_WHILE_VALIDATING_CARD_COUNTRY_CODE_AND_USER_COUNTRY_CODE",
    "error": {
        "message": "Card country code not compatible with user country code.
                    Please update user profile."
    }
}
HTTP/1.1 200 OK
Content-Type: application/json

{
    "status": "ERROR_WHILE_GETTING_COUNTRY_CODE",
    "error": {
        "message": "Could not get card country code"
    }
}
HTTP/1.1 200 OK
Content-Type: application/json

{
    "status": "ERROR_WHILE_VALIDATING_PROVINCE_NOT_CORRECT_PROVINCE_CODE",
    "error": {
        "message": "Province code is not valid province code.
                    Please update user profile"
    }
}
Error described bellow may occur when merchant tries to make transaction in other model than assigned primarily. For example, if merchant’s model is set as Card-Card and then merchant will try to make transaction in Cash-Card model, will receive error as bellow.
HTTP/1.1 200 OK
Content-Type: application/json;charset=ISO-8859-1

{
    "status": "ERROR_VALIDATION",
    "error": {
        "message": "Some information is missing or incorrect.",
        "errors": [
            {
                "field": "sender.type",
                "message": [
                    "Sender type violates merchant model"
                ]
            }
        ]
    }
}
Errors below may occur when a merchant uses a sender card or a receiver card issued in a country that is on the list of countries High Risk excluded from the Fenige API transactions. The transaction is treated as high risk and rejected. Please contact support.
HTTP/1.1 200 OK
Content-Type: application/json;charset=ISO-8859-1

{
    "status": "ERROR_MERCHANT_FUNDING_CARD_COUNTRY_RESTRICTED",
    "error": {
        "message": "Restricted funding card country was used."
    }
}
HTTP/1.1 200 OK
Content-Type: application/json;charset=ISO-8859-1

{
    "status": "ERROR_MERCHANT_PAYMENT_CARD_COUNTRY_RESTRICTED",
    "error": {
        "message": "Restricted payment card country was used."
    }
}
403 FORBIDDEN
HTTP Response - Error
{
    "timestamp": 1610464313387,
    "status": 403,
    "error": "Forbidden",
    "message": "No message available",
    "path": "/client/send-money-3ds"
}

3.1.3. Check status

GET /client/send-money/{orderId}, Authentication: Basic Auth
The method allows obtaining a status of multi-currency transaction specified by order-id. Parameter order-id was returned in the previous step (Send money multicurrency).
Request
Table 2. /client/send-money/{orderId}
Parameter Description

orderId

Unique transaction identifier.

GET /client/send-money/b943a9f5-xtr6f-4000-8b39-cb37ecb4a1c9 HTTP/1.1
Authorization: Basic bWVyY2hhbnQ6cGFzc3dvcmQ=
Host: java-staging.fenige.pl:8181
Response
Response status
Status Description

200 OK

Returned if the transaction completes successfully.

203 NON-AUTHORITATIVE INFORMATION

Returned when transaction was registered for processing. Check status in a while.

500 INTERNAL SERVER ERROR

Returned when user provides wrong order-id or transaction was failed or was Declined.

Example HTTP Response
200 OK
HTTP/1.1 200 OK
Content-Type: application/json
Content-Length: 1089

{
  "amount" : 1000,
  "amountInUsDollar" : 268,
  "bigDecimalAmount" : 10.0,
  "commission" : 200,
  "bigDecimalCommission" : 2.0,
  "orderId" : "a943a9f5-xtr6f-4000-8b39-cb37ecb4a1c9",
  "createdDate" : "03-04-2018, 14:01",
  "fundingRrn" : "014011103023",
  "paymentRrn" : "014011103024",
  "arn" : "05411640143500000019325",
  "revaluationResult" : {
    "revaluationFundingAmount" : 1000,
    "bigDecimalRevaluationFundingAmount" : 10.0,
    "fundingCurrency" : "PLN",
    "revaluationPaymentAmount" : 1000,
    "bigDecimalRevaluationPaymentAmount" : 10.0,
    "paymentCurrency" : "PLN",
    "determineCurrencyRate" : {
      "from" : "PLN",
      "to" : "PLN",
      "currencyRate" : "1"
    }
  },
  "receiver" : {
    "firstName" : "John",
    "lastName" : "Novak",
    "provider" : "MASTERCARD",
    "hiddenCardNumber" : "557455******1623",
    "bankName" : "Alior Bank SA"
  },
  "sender" : {
    "firstName" : "Caroline",
    "lastName" : "Novak",
    "provider" : "MASTERCARD",
    "hiddenCardNumber" : "511796******9169",
    "bankName" : "Alior Bank SA"
  },
  "3DS" : true
}

Response fields

Path Type Description

amount

Number

Field informing about the amount of cash transferred in one hundredth of the currency. [1PLN = 100]

amountInUsDollar

Number

Field informing about the amount of cash transferred in one hundredth of the USD currency. [1USD = 100]

bigDecimalAmount

Number

Field informing about the amount of cash transferred with decimal precision.

commission

Number

This is the amount of commission that has been added to the transaction in hundredths. [1 PLN = 100]

bigDecimalCommission

Number

This is the amount of commission that was added to the transaction at 0.01 currency.

orderId

String

Unique transaction identifier.

createdDate

String

Date of transaction.

fundingRrn

String

Funding Retrieval Reference Number.

paymentRrn

String

Payment Retrieval Reference Number.

arn

String

Acquirer Reference Number

3DS

Boolean

Value: true/false determines if transaction was processed with 3ds

revaluationResult

Object (RevaluationResult)

Detailed information about revaluation between currency sendera and receivera.

receiver

Object

Personal data of the person to whom the transfer is addressed.

sender

Object

Personal data of the person who performs the transfer of cash.

RevaluationResult

Path Type Description

revaluationFundingAmount

Long

Amount (in pennies) of funding transaction in fundingCurrency

bigDecimalRevaluationFundingAmount

BigDecimal

Amount of funding transaction in fundingCurrency

fundingCurrency

String

Currency code the same as sender’s card currency

revaluationPaymentAmount

Long

Amount (in pennies) of payment transaction in paymentCurrency

bigDecimalRevaluationPaymentAmount

BigDecimal

Amount of payment transaction in paymentCurrency

paymentCurrency

String

Currency code the same as receiver’s card currency

determineCurrencyRate

Object (DetermineCurrencyRate)

Details about conversion

DetermineCurrencyRate

Path Type Description

from

Long

Currency which was conversion from

to

Long

Resulted currency

masterCardCurrencyRate

BigDecimal

Currency rate

203 NON-AUTHORITATIVE INFORMATION
HTTP/1.1 203 Non-Authoritative Information

After you get 203 you need to check status in a while because we processing this transaction and if you don’t get a response (200 - succeeded or 500 - declined) within 15 seconds then please contact us.

500 INTERNAL SERVER ERROR
HTTP/1.1 500 Internal Server Error
Content-Type: text/plain;charset=ISO-8859-1

PAYMENT_TRANSACTION_DECLINED:CODE_05

After receiving these statuses, the transaction was rejected

Error statuses

Name Description

FUNDING_TRANSACTION_DECLINED:CODE_XX, PAYMENT_TRANSACTION_DECLINED:CODE_XX

CODE_XX - is MasterCard response code (ISO 8583)

ISSUER_NOT_SUPPORTED

This card is not supported

ERROR_CARD_IS_BLOCKED

Card is blocked for 1 hour in Fenige

ERROR_USER_IS_BLOCKED

User is blocked in Fenige

ERROR_BIN_IS_BLOCKED

Bin is blocked for 1 hour in Fenige

ERROR_FUNDING_BANK_IS_BLOCKED

Funding bank is blocked in Fenige

ERROR_PAYMENT_BANK_IS_BLOCKED

Payment bank is blocked in Fenige

FUNDING_TRANSACTION_DECLINED:ACQ_ERROR [only for CARD-CARD]

Funding transaction was declined and payment not send

PAYMENT_TRANSACTION_DECLINED:ACQ_ERROR

Payment transaction was declined and funding was reversed

ERROR_ACQ_CONNECTION

A connection error occurred to Acquirer service

AML_ERROR

User was found on the stop list

NETWORK_ERROR

Acceptance network is unavailable

CURRENCY_RATES_NOT_FOUND

No currently effective rates found in the database

CURRENCY_NOT_SUPPORTED

Currency is not supported

MERCHANT_CURRENCY_NOT_SUPPORTED

Currency is not supported by Merchant

ERROR_DAILY_CUMULATIVE_LIMIT

Daily cumulative limit per card was exceeded

ERROR_MONTHLY_CUMULATIVE_LIMIT

Monthly cumulative limit per card was exceeded

ERROR_MERCHANT_MASTERCARD_DAILY_CUMULATIVE_LIMIT

Daily cumulative limit per merchant transactions using mastercard cards was exceeded

ERROR_MERCHANT_MASTERCARD_MONTHLY_CUMULATIVE_LIMIT

Monthly cumulative limit per merchant transactions using mastercard cards was exceeded

ERROR_MERCHANT_VISA_DAILY_CUMULATIVE_LIMIT

Daily cumulative limit per merchant transactions using visa cards was exceeded

ERROR_MERCHANT_VISA_MONTHLY_CUMULATIVE_LIMIT

Monthly cumulative limit per merchant transactions using visa cards was exceeded

ERROR_SENDER_CARD_IS_BLOCKED [only for CARD-CARD]

Sender’s card is blocked

ERROR_RECEIVER_CARD_IS_BLOCKED

Receiver’s card is blocked

ERROR_SENDER_USER_IS_BLOCKED [only for CARD-CARD]

User acting as sender is blocked

ERROR_RECEIVER_USER_IS_BLOCKED

User acting as receiver is blocked

ERROR_SENDER_BIN_IS_BLOCKED [only for CARD-CARD]

BIN of sender’s card is blocked

ERROR_RECEIVER_BIN_IS_BLOCKED

BIN of receiver’s card is blocked

ERROR_AMOUNT_IS_BLOCKED

Amount is higher than acceptable limit

ERROR_MONITORING_CONNECTION

Couldn’t established connection to Monitoring service

ERROR_MONITORING_UNAUTHORIZED

Error with service authorization occurred

ERROR_MONITORING

Some unrecognized error occurred

ERROR_USER_VERIFICATION

The transaction user’s personal data verified as incorrect on the verification service. Transaction rejected.

FUNDING_TRANSACTION_DECLINED:MIP_RESPONSE_TIMEOUT [only for CARD-CARD]

Funding transaction declined - mip response timeout

PAYMENT_TRANSACTION_DECLINED:MIP_RESPONSE_TIMEOUT

Payment transaction declined - mip response timeout

FUNDING_TRANSACTION_DECLINED:NEED_MANUAL_VERIFICATION [only for CARD-CARD]

Funding process failed and it is need to manual verification of transaction

PAYMENT_TRANSACTION_DECLINED:NEED_MANUAL_VERIFICATION

Payment process failed and it is need to manual verification of transaction

FUNDING_TRANSACTION_DECLINED:MIP_PROXY_RESPONSE_TIMEOUT [only for CARD-CARD]

Funding transaction declined - mip_proxy response timeout

PAYMENT_TRANSACTION_DECLINED:MIP_PROXY_RESPONSE_TIMEOUT

Payment transaction declined - mip_proxy response timeout

REJECTED [only for CASH-CARD]

Amount exceeds current merchant deposit limit

ERROR_TRANSACTION_NOT_FOUND

Error transaction not exists

ERROR_VALIDATION

Some validation error occurred

ERROR_SOMETHING_WRONG

An unrecognized error occurred

3.2. Send money internal 3DS 1.0

POST /api/v2/client/send-money-3ds Content-Type: application/vnd.sendmoney3ds.v2+json, Authorization: Basic Auth, API-TOKEN*
The method allows executing transactions with additional protection i.e. verification by the 3DS (3D-Secure). The response of method contains based HTML form which merchant should display for the user. HTML represents user bank account login page. The method returns also order-id parameter which is required to check a status of the transaction.
*API-TOKEN is required for methods: DATACORE-PLAIN, DATACORE-DATACORE, DATACORE-CASH, DATACORE-PHONE
Please notice that you can choose language of email confirmation of this transaction. It is able by attach proper header to request.
SM 3DS
When a user authenticates successfully within 15 minutes then:
- Bank returns special parameters needed to continue the transaction.
- Fenige redirects to Merchant termUrl with requestParam order-id. Merchant can check transaction status using order-id.
When all data are correct then transaction succeeds.
Fenige will set transaction status as Declined when:
- User doesn't authenticate (then bank doesn't return special parameters).
- User authenticates successfully but after 15 minutes.
In order to provide users with the ability to safely retry transaction (for example to request for an undelivered response), the v2 of API supports idempotent send money 3ds multi-currency operation.

From January 2021, there is an internal functionality to restrict access for the Merchant to specific method. The Fenige employee can disable access to a given endpoint, then the HTTP status 403 FORBIDDEN will be returned. The Merchant will be informed about each access restriction action.

3.2.1. Request

Request fields

Table 3. Multicurrency-3DS
Path Type Validation Rule Description

amount

Number

Required

@NotNull, positive

The total transfer amount (in pennies).

cvc2

String

Required

@Length(min = 3, max = 4).

Sender Card cvc2/cvv2

type

String

Required

@NotNull

Transaction in 'SENDER' or 'RECEIVER' currency.

termUrl

String

Required

@NotEmpty

Merchant URL to be redirected from Fenige after user login in the bank. This URL must accept order-id parameter, that tells which transaction is begin processed.

merchantUrl

String

Optional, mandatory from 2021-05-03

@Optional

Merchant identifier such as the business website URL or reverse domain name as presented to the consumer during checkout

addressIp

String

Optional mandatory from 2021-05-03, @Must match the regular expression ^([0-9]{1,3}.){3}[0-9]{1,3}$

@Optional

The IP address of the order of transaction

requestId

String

Required

@NotNull

128 bit number generated by the user, used to identify single transaction. Ensures that the transaction with the given parameter is processed only once.

sender

Object

Required

@NotNull

Sender PLAIN Sender DATACORE

receiver

Object

Required

@NotNull

Receiver PLAIN Receiver CASH Receiver DATACORE Receiver PHONE

Example HTTP Request
PLAIN-PLAIN
POST /api/v2/client/send-money-3ds HTTP/1.1
Content-Type: application/vnd.sendmoney3ds.v2+json
Authorization: Basic bWVyY2hhbnQ6cGFzc3dvcmQ=
Host: java-staging.fenige.pl:8181
Content-Length: 778

{
  "amount" : 1000,
  "cvc2" : "123",
  "termUrl" : "https://termUrl",
  "merchantUrl" : "https://fenige.pl/payments",
  "addressIp" : "192.168.0.1",
  "type" : "SENDER",
  "requestId" : "c5cf78b5-f1e7-429d-aa09-9c19d42c6c06",
  "sender" : {
    "type" : "PLAIN",
    "firstName" : "Mark",
    "lastName" : "Smith",
    "street" : "Olszewskiego",
    "houseNumber" : "17A",
    "city" : "Lublin",
    "postalCode" : "20-400",
    "flatNumber" : "2",
    "email" : "senderEmail@fenige.pl",
    "currency" : "PLN",
    "cardNumber" : "5117964247989169",
    "expirationDate" : "03/23",
    "personalId" : "AGC688910"
  },
  "receiver" : {
    "type" : "PLAIN",
    "firstName" : "Rob",
    "lastName" : "Wring",
    "currency" : "PLN",
    "cardNumber" : "5117964247989169"
  }
}
PLAIN-PLAIN USA/CAN
POST /api/v2/client/send-money-3ds HTTP/1.1
Content-Type: application/vnd.sendmoney3ds.v2+json
Authorization: Basic bWVyY2hhbnQ6cGFzc3dvcmQ=
Host: java-staging.fenige.pl:8181
Content-Length: 821

{
  "amount" : 1000,
  "cvc2" : "123",
  "termUrl" : "https://termUrl",
  "merchantUrl" : "https://fenige.pl/payments",
  "addressIp" : "192.168.0.1",
  "type" : "SENDER",
  "requestId" : "2ed83b2c-66a2-4cd1-a6ed-28449e435f11",
  "sender" : {
    "type" : "PLAIN",
    "firstName" : "Mark",
    "lastName" : "Smith",
    "street" : "Gates Court",
    "houseNumber" : "82",
    "city" : "Brooklyn",
    "postalCode" : "11211",
    "flatNumber" : "2",
    "email" : "senderdocs@fenige.pl",
    "currency" : "USD",
    "cardNumber" : "5448424719416233",
    "expirationDate" : "03/23",
    "personalId" : "AGC688910",
    "country" : "US",
    "province" : "NY"
  },
  "receiver" : {
    "type" : "PLAIN",
    "firstName" : "Rob",
    "lastName" : "Wring",
    "currency" : "PLN",
    "cardNumber" : "5117964247989169"
  }
}
PLAIN-CASH
POST /api/v2/client/send-money-3ds HTTP/1.1
Content-Type: application/vnd.sendmoney3ds.v2+json
Authorization: Basic bWVyY2hhbnQ6cGFzc3dvcmQ=
Host: java-staging.fenige.pl:8181
Content-Length: 912

{
  "amount" : 1000,
  "cvc2" : "123",
  "termUrl" : "https://termUrl",
  "merchantUrl" : "https://fenige.pl/payments",
  "addressIp" : "192.168.0.1",
  "type" : "SENDER",
  "requestId" : "9aea0ba0-00c0-4e11-a42a-2418c017c520",
  "sender" : {
    "type" : "PLAIN",
    "firstName" : "Mark",
    "lastName" : "Smith",
    "street" : "Olszewskiego",
    "houseNumber" : "17A",
    "city" : "Lublin",
    "postalCode" : "20-400",
    "flatNumber" : "2",
    "email" : "senderEmail@fenige.pl",
    "currency" : "PLN",
    "cardNumber" : "5117964247989169",
    "expirationDate" : "03/23",
    "personalId" : "AGC688910"
  },
  "receiver" : {
    "type" : "CASH",
    "firstName" : "Rob",
    "lastName" : "Wring",
    "street" : "Lubelska",
    "houseNumber" : "17A",
    "city" : "Lubartów",
    "postalCode" : "21-100",
    "flatNumber" : "2",
    "email" : "receiverEmail@fenige.pl",
    "currency" : "PLN"
  }
}
PLAIN-CASH USA/CAN
POST /api/v2/client/send-money-3ds HTTP/1.1
Content-Type: application/vnd.sendmoney3ds.v2+json
Authorization: Basic bWVyY2hhbnQ6cGFzc3dvcmQ=
Host: java-staging.fenige.pl:8181
Content-Length: 955

{
  "amount" : 1000,
  "cvc2" : "123",
  "termUrl" : "https://termUrl",
  "merchantUrl" : "https://fenige.pl/payments",
  "addressIp" : "192.168.0.1",
  "type" : "SENDER",
  "requestId" : "45f1fbe1-b7d0-43d9-9912-258078f961ab",
  "sender" : {
    "type" : "PLAIN",
    "firstName" : "Mark",
    "lastName" : "Smith",
    "street" : "Gates Court",
    "houseNumber" : "82",
    "city" : "Brooklyn",
    "postalCode" : "11211",
    "flatNumber" : "2",
    "email" : "senderdocs@fenige.pl",
    "currency" : "USD",
    "cardNumber" : "5448424719416233",
    "expirationDate" : "03/23",
    "personalId" : "AGC688910",
    "country" : "US",
    "province" : "NY"
  },
  "receiver" : {
    "type" : "CASH",
    "firstName" : "Rob",
    "lastName" : "Wring",
    "street" : "Lubelska",
    "houseNumber" : "17A",
    "city" : "Lubartów",
    "postalCode" : "21-100",
    "flatNumber" : "2",
    "email" : "receiverEmail@fenige.pl",
    "currency" : "PLN"
  }
}
DATACORE-PLAIN
POST /api/v2/client/send-money-3ds HTTP/1.1
Content-Type: application/vnd.sendmoney3ds.v2+json
Authorization: Basic bWVyY2hhbnQ6cGFzc3dvcmQ=
API-TOKEN: d94NYa+xqRrazUPzSgYeJ6qR/MzIOb3IzePb7t9sWds=
Host: java-staging.fenige.pl:8181
Content-Length: 699

{
  "amount" : 1000,
  "cvc2" : "123",
  "termUrl" : "https://termUrl",
  "merchantUrl" : "https://fenige.pl/payments",
  "addressIp" : "192.168.0.1",
  "type" : "SENDER",
  "requestId" : "456052b1-4170-4832-bbb8-b7dad1d9872a",
  "sender" : {
    "type" : "DATACORE",
    "firstName" : "Mark",
    "lastName" : "Smith",
    "street" : "Olszewskiego",
    "houseNumber" : "17A",
    "city" : "Lublin",
    "postalCode" : "20-400",
    "flatNumber" : "2",
    "email" : "senderEmail@fenige.pl",
    "currency" : "PLN",
    "cardId" : 1234
  },
  "receiver" : {
    "type" : "PLAIN",
    "firstName" : "Rob",
    "lastName" : "Wring",
    "currency" : "PLN",
    "cardNumber" : "5117964247989169"
  }
}
DATACORE-DATACORE
POST /api/v2/client/send-money-3ds HTTP/1.1
Content-Type: application/vnd.sendmoney3ds.v2+json
Authorization: Basic bWVyY2hhbnQ6cGFzc3dvcmQ=
API-TOKEN: d94NYa+xqRrazUPzSgYeJ6qR/MzIOb3IzePb7t9sWds=
Host: java-staging.fenige.pl:8181
Content-Length: 725

{
  "amount" : 1000,
  "cvc2" : "123",
  "termUrl" : "https://termUrl",
  "merchantUrl" : "https://fenige.pl/payments",
  "addressIp" : "192.168.0.1",
  "type" : "SENDER",
  "requestId" : "bc1afa17-996c-453d-b809-9d565367f53a",
  "sender" : {
    "type" : "DATACORE",
    "firstName" : "Mark",
    "lastName" : "Smith",
    "street" : "Olszewskiego",
    "houseNumber" : "17A",
    "city" : "Lublin",
    "postalCode" : "20-400",
    "flatNumber" : "2",
    "email" : "senderEmail@fenige.pl",
    "currency" : "PLN",
    "cardId" : 1234
  },
  "receiver" : {
    "type" : "DATACORE",
    "firstName" : "Rob",
    "lastName" : "Wring",
    "email" : "receiverEmail@fenige.pl",
    "currency" : "PLN",
    "cardId" : 1234
  }
}
DATACORE-CASH
POST /api/v2/client/send-money-3ds HTTP/1.1
Content-Type: application/vnd.sendmoney3ds.v2+json
Authorization: Basic bWVyY2hhbnQ6cGFzc3dvcmQ=
API-TOKEN: d94NYa+xqRrazUPzSgYeJ6qR/MzIOb3IzePb7t9sWds=
Host: java-staging.fenige.pl:8181
Content-Length: 833

{
  "amount" : 1000,
  "cvc2" : "123",
  "termUrl" : "https://termUrl",
  "merchantUrl" : "https://fenige.pl/payments",
  "addressIp" : "192.168.0.1",
  "type" : "SENDER",
  "requestId" : "8d96f853-fc79-4634-a24d-f5ee0ff952fb",
  "sender" : {
    "type" : "DATACORE",
    "firstName" : "Mark",
    "lastName" : "Smith",
    "street" : "Olszewskiego",
    "houseNumber" : "17A",
    "city" : "Lublin",
    "postalCode" : "20-400",
    "flatNumber" : "2",
    "email" : "senderEmail@fenige.pl",
    "currency" : "PLN",
    "cardId" : 1234
  },
  "receiver" : {
    "type" : "CASH",
    "firstName" : "Rob",
    "lastName" : "Wring",
    "street" : "Lubelska",
    "houseNumber" : "17A",
    "city" : "Lubartów",
    "postalCode" : "21-100",
    "flatNumber" : "2",
    "email" : "receiverEmail@fenige.pl",
    "currency" : "PLN"
  }
}
DATACORE-PHONE
POST /api/v2/client/send-money-3ds HTTP/1.1
Content-Type: application/vnd.sendmoney3ds.v2+json
Authorization: Basic bWVyY2hhbnQ6cGFzc3dvcmQ=
API-TOKEN: d94NYa+xqRrazUPzSgYeJ6qR/MzIOb3IzePb7t9sWds=
Host: java-staging.fenige.pl:8181
Content-Length: 695

{
  "amount" : 1000,
  "cvc2" : "123",
  "termUrl" : "https://termUrl",
  "merchantUrl" : "https://fenige.pl/payments",
  "addressIp" : "192.168.0.1",
  "type" : "SENDER",
  "requestId" : "c6ebc675-faf7-472c-a039-a91b606e69cc",
  "sender" : {
    "type" : "DATACORE",
    "firstName" : "Mark",
    "lastName" : "Smith",
    "street" : "Olszewskiego",
    "houseNumber" : "17A",
    "city" : "Lublin",
    "postalCode" : "20-400",
    "flatNumber" : "2",
    "email" : "senderEmail@fenige.pl",
    "currency" : "PLN",
    "cardId" : 1234
  },
  "receiver" : {
    "type" : "PHONE",
    "firstName" : "Rob",
    "lastName" : "Wring",
    "currency" : "PLN",
    "phoneNumber" : "48123777619"
  }
}
SM 3DS DATACORE PHONE

3.2.2. Response

Response status
Status Description

200 OK

Returned if the transaction completes successfully.

200 OK - Error validation

Returned list of field name which has validation errors.

202 Accepted

- Returned when the transaction with the provided requestId has been registered in the system, but has not yet been completed. The user can retry in a few seconds to get the transaction result. Response body: Empty
or
- Returned order-id when transaction will be processed.

400 Bad Request

Returned e.g. when a different transaction with the provided requestId has already been registered in the system.

Example HTTP Response
200 OK
HTTP/1.1 200 OK
Content-Type: application/json;charset=ISO-8859-1
Content-Length: 2009

{
	"pareq": "eJxtUt1uskAQfRXjvSxr0Q/JdBOKJpJ8KBV60SuzganSKOCy+PP2nUWtbVKSSeacHWbOnllItwpx\r\nmmDWKhQQYdPIDfaK/Lk/dnlfQOyv8CDgiKopqlJwy7aGwO6QflDZVpZagMwOL+FCjBzOxw6wG4Q9\r\nqnAqbPoGFBzYlYBS7lG8xX44XUdxuE5nSbqOZqtg7i9SYN0pZFVbanURYz4GdgfQqp3Yal03HmOf\r\n8igHOR5xx622lkVu1TvPdZwnlu0KLDUwUw3sITNuTdZQ93ORizDwN3/EcJm+PQMzFZBLjWJo83/2\r\nhI96nHuO63GyoONB7o0sEf9f9Mgam+59JaA2c/wr4ObgJwHktsIyu4iJO6Kr3RHgua5K0i1owHcO\r\n7CE6mBunM00WTqbaD+z0PTkns+hULT8uQbXyX8OX04a034pMx4Jc46791LU0AJhpw26rJXO6pVP2\r\n6zF8ATVEsHg=",
	"acsUrl": "https://test.cap.attempts.securecode.com/acspage/cap?RID=1&VAA=B",
	"md": "M2YzYjliMGQtMjYwOC00YTVlLThlMTgtMmViMGFkYWQ4MGM5",
	"formBase64": "PGh0bWw+PFNDUklQVCBMQU5HVUFHRT0iSmF2YXNjcmlwdCI+ZnVuY3Rpb24gT25Mb2FkRXZlbnQoKXsgZG9jdW1lbnQuZG93bmxvYWRGb3JtLnN1Ym1pdCgpOyB9PC9TQ1JJUFQ+PGJvZHkgT25Mb2FkPSJPbkxvYWRFdmVudCgpOyI+PGZvcm0gbmFtZT0iZG93bmxvYWRGb3JtIiBhY3Rpb249Imh0dHBzOi8vdGVzdC5jYXAuYXR0ZW1wdHMuc2VjdXJlY29kZS5jb20vYWNzcGFnZS9jYXA/UklEPTEmVkFBPUIiIG1ldGhvZD0iUE9TVCI+PElOUFVUIHR5cGU9ImhpZGRlbiIgbmFtZT0iUGFSZXEiIHZhbHVlPSJlSnh0VXQxdXNrQVFmUlhqdlN4cjBRL0pkQk9LSnBKOEtCVjYwU3V6Z2FuU0tPQ3krUFAyblVXdGJWS1NTZWFjSFdiT25sbEl0d3B4DQptbURXS2hRUVlkUElEZmFLL0xrL2RubGZRT3l2OENEZ2lLb3BxbEp3eTdhR3dPNlFmbERaVnBaYWdNd09MK0ZDakJ6T3h3NndHNFE5DQpxbkFxYlBvR0ZCellsWUJTN2xHOHhYNDRYVWR4dUU1blNicU9acXRnN2k5U1lOMHBaRlZiYW5VUll6NEdkZ2ZRcXAzWWFsMDNIbU9mDQo4aWdIT1I1eHg2MjJsa1Z1MVR2UGRad25sdTBLTERVd1V3M3NJVE51VGRaUTkzT1JpekR3TjMvRWNKbStQUU16RlpCTGpXSm84My8yDQpoSTk2bkh1TzYzR3lvT05CN28wc0VmOWY5TWdhbSs1OUphQTJjL3dyNE9iZ0p3SGt0c0l5dTRpSk82S3IzUkhndWE1SzBpMW93SGNPDQo3Q0U2bUJ1bk0wMFdUcWJhRCt6MFBUa25zK2hVTFQ4dVFiWHlYOE9YMDRhMDM0cE14NEpjNDY3OTFMVTBBSmhwdzI2ckpYTzZwVlAyDQo2ekY4QVRWRXNIZz0iPjxpbnB1dCB0eXBlPSJoaWRkZW4iIG5hbWU9IlRlcm1VcmwiIHZhbHVlPSJodHRwczovL3JlcXVlc3RiLmluLzFlYTlzZWoxIj48aW5wdXQgdHlwZT0iaGlkZGVuIiBuYW1lPSJNRCIgdmFsdWU9Ik0yWXpZamxpTUdRdE1qWXdPQzAwWVRWbExUaGxNVGd0TW1WaU1HRmtZV1E0TUdNNSI+PC9mb3JtPjwvYm9keT48L2h0bWw+",
	"enrolledStatus": "Y",
	"orderId": "234abf25-c35f-a263-a402-cbaf874f137a"
}

Response fields

Path Type Description

pareq

String

Payer Authentication Request

acsUrl

String

Fully qualified URL of an Access Control Server

orderId

String

Transaction order-id

md

String

Correlation id in base64 format

formBase64

String

Html form of the document in base64 format

enrolledStatus

String

Authentication status indicator

200 OK - Error validation
HTTP/1.1 200 OK
Content-Type: application/json;charset=ISO-8859-1

{
	"status": "ERROR_VALIDATION",
	"error": {
		"message": "Some information is missing or incorrect.",
		"errors": [{
				"field": "requestId",
				"message": [
					"may not be null"
				]
			},
			{
				"field": "cvc2",
				"message": [
					"may not be null",
					"length must be 3"
				]
			},
			{
				"field": "eci",
				"message": [
					"may not be null",
					"length must be 2"
				]
			},
			{
				"field": "cavv",
				"message": [
					"may not be null",
					"length must be 28"
				]
			},
			{
				"field": "transactionXId",
				"message": [
					"must not be null",
					"length must be 36"
				]
			},
			{
				"field": "amount",
				"message": [
					"may not be null"
				]
			},
			{
				"field": "type",
				"message": [
					"may not be null"
				]
			},
			{
				"field": "termUrl",
				"message": [
					"may not be null"
				]
			},
			{
				"field": "sender",
				"message": [
					"may not be null"
				]
			},
			{
				"field": "sender.houseNumber",
				"message": [
					"may not be null",
					"may not be empty",
					"length must be between 1 and 10"
				]
			},
            {
				"field": "sender.street",
				"message": [
					"may not be null",
					"may not be empty",
					"length must be between 1 and 50"
				]
			},
			{
				"field": "sender.firstName",
				"message": [
					"may not be null",
					"may not be empty",
					"length must be between 2 and 35"
				]
			},
			{
				"field": "sender.lastName",
				"message": [
					"may not be empty",
					"may not be null",
					"length must be between 2 and 35"
				]
			},
			{
				"field": "sender.postalCode",
				"message": [
					"may not be empty",
					"may not be null",
					"length must be between 1 and 10"
				]
			},
            {
				"field": "sender.city",
				"message": [
					"may not be empty",
					"may not be null",
					"length must be between 1 and 25"
				]
			},
            {
                "field": "sender.flatNumber",
                "message": [
                    "must be null",
                    "length must be between 0 and 5"
                ]
            },
			{
				"field": "sender.cardNumber",
				"message": [
					"may not be null",
					"may not be empty",
					"card number length must be 16"
				]
			},
			{
				"field": "sender.email",
				"message": [
					"may not be empty",
					"may not be null",
					"not a well-formed email address",
					"lenght must be beetween 1 and 128"
				]
			},
			{
				"field": "sender.expirationDate",
				"message": [
					"invalid card expiration date",
					"may not be null",
					"may not be empty"
				]
			},
			{
				"field": "receiver",
				"message": [
					"may not be null"
				]
			},
			{
				"field": "receiver.firstName",
				"message": [
					"may not be null",
					"may not be empty",
					"length must be between 2 and 35"
				]
			},
			{
				"field": "receiver.lastName",
				"message": [
					"may not be empty",
					"may not be null",
					"length must be between 2 and 35"
				]
			},
			{
				"field": "receiver.currency",
				"message": [
					"may not be null"
				]
			},
			{
				"field": "receiver.cardNumber",
				"message": [
					"may not be null",
					"may not be empty",
				    "card number length must be 16"
				]
			},
			{
                "field": "sender",
                "message": [
                     "province is mandatory only if country code is US or CA"
                ]
            },
            {
                 "field": "sender.province",
                 "message": [
                      "is not correct province code for country code US",
                      "may not be null"
                 ]
            },
            {
                 "field": "sender.province",
                 "message": [
                       "may not be null",
                       "is not correct province code for country code CA"
                 ]
            },
            {
                 "field": "sender.province",
                 "message": [
                        "must match ^[A-Z]{2}$",
                        "is not correct province code for country code US"
                 ]
            },
            {
                  "field": "sender.currency",
                  "message": [
                        "Currency is not supported"
                 ]
            },
            {
                  "field": "receiver.currency",
                  "message": [
                        "Currency is not supported"
                 ]
            }
        ]
    }
}
Errors mentioned below may occur if card’s country is other than user’s country for USA or CAN transaction
HTTP/1.1 200 OK
Content-Type: application/json

{
    "status": "ERROR_WHILE_VALIDATING_CARD_COUNTRY_CODE_AND_USER_COUNTRY_CODE_FOR_PLAIN",
    "error": {
        "message": "Card country code not compatible with user country code.
                    Please update country in request."
    }
}
HTTP/1.1 200 OK
Content-Type: application/json

{
    "status": "ERROR_WHILE_VALIDATING_CARD_COUNTRY_CODE_AND_USER_COUNTRY_CODE",
    "error": {
        "message": "Card country code not compatible with user country code.
                    Please update user profile."
    }
}
HTTP/1.1 200 OK
Content-Type: application/json

{
    "status": "ERROR_WHILE_GETTING_COUNTRY_CODE",
    "error": {
        "message": "Could not get card country code"
    }
}
HTTP/1.1 200 OK
Content-Type: application/json

{
    "status": "ERROR_WHILE_VALIDATING_PROVINCE_NOT_CORRECT_PROVINCE_CODE",
    "error": {
        "message": "Province code is not valid province code.
                    Please update user profile"
    }
}
Error described bellow may occur when merchant tries to make transaction in other model than assigned primarily. For example, if merchant’s model is set as Card-Card and then merchant will try to make transaction in Cash-Card model, will receive error as bellow.
HTTP/1.1 200 OK
Content-Type: application/json;charset=ISO-8859-1

{
    "status": "ERROR_VALIDATION",
    "error": {
        "message": "Some information is missing or incorrect.",
        "errors": [
            {
                "field": "sender.type",
                "message": [
                    "Sender type violates merchant model"
                ]
            }
        ]
    }
}
202 Accepted
HTTP/1.1 202 Accepted
Content-Type: application/json;charset=ISO-8859-1
Content-Length: 56

{
  "orderId" : "1514ae4f-7ff4-4463-890b-15645f5ab5c0"
}

Response fields

Path Type Description

orderId

String

Transaction order-id

400 Bad request
HTTP/1.1 400 Bad Request
Content-Type: application/json;charset=ISO-8859-1
Content-Length: 104

{
  "error" : {
    "message" : "Another transaction with the same id has already been processed."
  }
}
403 FORBIDDEN
HTTP Response - Error
{
    "timestamp": 1610464313387,
    "status": 403,
    "error": "Forbidden",
    "message": "No message available",
    "path": "/client/send-money-3ds"
}

3.2.3. Check status 3ds

GET /client/send-money-3ds/{orderId}, Authentication: Basic Auth
The method allows obtaining a status of 3ds transaction specified by order-id. Parameter order-id was returned in the previous step (Send money multicurrency 3DS).
Request
Table 4. /client/send-money-3ds/{orderId}
Parameter Description

orderId

Unique transaction identifier.

GET /client/send-money-3ds/a943a9f5-xtr6f-4000-8b39-cb37ecb4a1c9 HTTP/1.1
Authorization: Basic bWVyY2hhbnQ6cGFzc3dvcmQ=
Host: java-staging.fenige.pl:8181
Response
Response status
Status Description

200 OK

Returned if the transaction completes successfully.

203 NON-AUTHORITATIVE INFORMATION

Returned when transaction was registered for processing. Check status in a while.

500 INTERNAL SERVER ERROR

Returned when user provides wrong order-id or transaction was failed or was Declined.

Example HTTP Response
200 OK
HTTP/1.1 200 OK
Content-Type: application/json
Content-Length: 987

{
  "amount" : 1000,
  "amountInUsDollar" : 268,
  "bigDecimalAmount" : 10.0,
  "commission" : 200,
  "bigDecimalCommission" : 2.0,
  "orderId" : "a943a9f5-xtr6f-4000-8b39-cb37ecb4a1c9",
  "createdDate" : "03-04-2018, 14:01",
  "revaluationResult" : {
    "revaluationFundingAmount" : 1000,
    "bigDecimalRevaluationFundingAmount" : 10.0,
    "fundingCurrency" : "PLN",
    "revaluationPaymentAmount" : 1000,
    "bigDecimalRevaluationPaymentAmount" : 10.0,
    "paymentCurrency" : "PLN",
    "determineCurrencyRate" : {
      "from" : "PLN",
      "to" : "PLN",
      "currencyRate" : "1"
    }
  },
  "receiver" : {
    "firstName" : "John",
    "lastName" : "Novak",
    "provider" : "MASTERCARD",
    "hiddenCardNumber" : "557455******1623",
    "bankName" : "Alior Bank SA"
  },
  "sender" : {
    "firstName" : "Caroline",
    "lastName" : "Novak",
    "provider" : "MASTERCARD",
    "hiddenCardNumber" : "511796******9169",
    "bankName" : "Alior Bank SA"
  },
  "3DS" : false
}

Response fields

Path Type Description

amount

Number

Field informing about the amount of cash transferred in one hundredth of the currency. [1PLN = 100]

amountInUsDollar

Number

Field informing about the amount of cash transferred in one hundredth of the USD currency. [1USD = 100]

bigDecimalAmount

Number

Field informing about the amount of cash transferred with decimal precision.

commission

Number

This is the amount of commission that has been added to the transaction in hundredths. [1 PLN = 100]

bigDecimalCommission

Number

This is the amount of commission that was added to the transaction at 0.01 currency.

orderId

String

Unique transaction identifier.

createdDate

String

Date of transaction.

3DS

Boolean

Value: true/false determines if transaction was processed with 3ds

revaluationResult

Object (RevaluationResult)

Detailed information about revaluation between sender and receiver currency.

receiver

Object

Personal data of the person to whom the transfer is addressed.

sender

Object

Personal data of the person who performs the transfer of cash.

RevaluationResult

Path Type Description

revaluationFundingAmount

Long

Amount (in pennies) of funding transaction in fundingCurrency

bigDecimalRevaluationFundingAmount

BigDecimal

Amount of funding transaction in fundingCurrency

fundingCurrency

String

Currency code the same as sender’s card currency

revaluationPaymentAmount

Long

Amount (in pennies) of payment transaction in paymentCurrency

bigDecimalRevaluationPaymentAmount

BigDecimal

Amount of payment transaction in paymentCurrency

paymentCurrency

String

Currency code the same as receiver’s card currency

determineCurrencyRate

Object (DetermineCurrencyRate)

Details about conversion

DetermineCurrencyRate

Path Type Description

from

Long

Currency which was conversion from

to

Long

Resulted currency

masterCardCurrencyRate

BigDecimal

Currency rate

203 NON-AUTHORITATIVE INFORMATION
HTTP/1.1 203 Non-Authoritative Information

After you get 203 you need to check status in a while because we processing this transaction and if you don’t get a response (200 - succeeded or 500 - declined) within 15 seconds then please contact us.

500 INTERNAL SERVER ERROR
HTTP/1.1 500 Internal Server Error
Content-Type: text/plain;charset=ISO-8859-1

PAYMENT_TRANSACTION_DECLINED:CODE_05

After receiving these statuses, the transaction was rejected

Error statuses

Name Description

FUNDING_TRANSACTION_DECLINED:CODE_XX, PAYMENT_TRANSACTION_DECLINED:CODE_XX

CODE_XX - is MasterCard response code (ISO 8583)

ISSUER_NOT_SUPPORTED

This card is not supported

ERROR_CARD_IS_BLOCKED

Card is blocked for 1 hour in Fenige

ERROR_USER_IS_BLOCKED

User is blocked in Fenige

ERROR_BIN_IS_BLOCKED

Bin is blocked for 1 hour in Fenige

ERROR_FUNDING_BANK_IS_BLOCKED

Funding bank is blocked in Fenige

ERROR_PAYMENT_BANK_IS_BLOCKED

Payment bank is blocked in Fenige

FUNDING_TRANSACTION_DECLINED:ACQ_ERROR [only for CARD-CARD]

Funding transaction was declined and payment not send

PAYMENT_TRANSACTION_DECLINED:ACQ_ERROR

Payment transaction was declined and funding was reversed

ERROR_ACQ_CONNECTION

A connection error occurred to Acquirer service

AML_ERROR

User was found on the stop list

NETWORK_ERROR

Acceptance network is unavailable

CURRENCY_RATES_NOT_FOUND

No currently effective rates found in the database

CURRENCY_NOT_SUPPORTED

Currency is not supported

MERCHANT_CURRENCY_NOT_SUPPORTED

Currency is not supported by Merchant

ERROR_DAILY_CUMULATIVE_LIMIT

Daily cumulative limit per card was exceeded

ERROR_MONTHLY_CUMULATIVE_LIMIT

Monthly cumulative limit per card was exceeded

ERROR_MERCHANT_MASTERCARD_DAILY_CUMULATIVE_LIMIT

Daily cumulative limit per merchant transactions using mastercard cards was exceeded

ERROR_MERCHANT_MASTERCARD_MONTHLY_CUMULATIVE_LIMIT

Monthly cumulative limit per merchant transactions using mastercard cards was exceeded

ERROR_MERCHANT_VISA_DAILY_CUMULATIVE_LIMIT

Daily cumulative limit per merchant transactions using visa cards was exceeded

ERROR_MERCHANT_VISA_MONTHLY_CUMULATIVE_LIMIT

Monthly cumulative limit per merchant transactions using visa cards was exceeded

ERROR_SENDER_CARD_IS_BLOCKED [only for CARD-CARD]

Sender’s card is blocked

ERROR_RECEIVER_CARD_IS_BLOCKED

Receiver’s card is blocked

ERROR_SENDER_USER_IS_BLOCKED [only for CARD-CARD]

User acting as sender is blocked

ERROR_RECEIVER_USER_IS_BLOCKED

User acting as receiver is blocked

ERROR_SENDER_BIN_IS_BLOCKED [only for CARD-CARD]

BIN of sender’s card is blocked

ERROR_RECEIVER_BIN_IS_BLOCKED

BIN of receiver’s card is blocked

ERROR_AMOUNT_IS_BLOCKED

Amount is higher than acceptable limit

ERROR_MONITORING_CONNECTION

Couldn’t established connection to Monitoring service

ERROR_MONITORING_UNAUTHORIZED

Error with service authorization occurred

ERROR_MONITORING

Some unrecognized error occurred

ERROR_USER_VERIFICATION

The transaction user’s personal data verified as incorrect on the verification service. Transaction rejected.

FUNDING_TRANSACTION_DECLINED:MIP_RESPONSE_TIMEOUT [only for CARD-CARD]

Funding transaction declined - mip response timeout

PAYMENT_TRANSACTION_DECLINED:MIP_RESPONSE_TIMEOUT

Payment transaction declined - mip response timeout

FUNDING_TRANSACTION_DECLINED:NEED_MANUAL_VERIFICATION [only for CARD-CARD]

Funding process failed and it is need to manual verification of transaction

PAYMENT_TRANSACTION_DECLINED:NEED_MANUAL_VERIFICATION

Payment process failed and it is need to manual verification of transaction

FUNDING_TRANSACTION_DECLINED:MIP_PROXY_RESPONSE_TIMEOUT [only for CARD-CARD]

Funding transaction declined - mip_proxy response timeout

PAYMENT_TRANSACTION_DECLINED:MIP_PROXY_RESPONSE_TIMEOUT

Payment transaction declined - mip_proxy response timeout

ERROR_FINALIZE_3DS_NOT_AUTHENTICATED

Error finalize 3ds not authenticated. MPI return one of statuses:

N -The customer failed authentication, and the transaction is denied.
U - Authentication could not be performed due to technical or other problems.

ERROR_NO_3DS_AUTHORIZATION

Error no 3ds authorization, when User authenticates successfully but after 15 minutes or User doesn’t authenticate.

ERROR_MPI_STATUS_TO_LOW: Initialize/Finalize: U/N

Error occurs, when merchant configuration allows only for attempted or full authenticated 3DS transactions with mpi status 'A' or 'Y' but mpi service has returned other status e.g. 'N' or 'U' at any stage of the transaction.

ERROR_3DS_INITIALIZE_FAILED

An error occurred while processing initialize 3DS method caused by an error returned by the service provider

ERROR_3DS_FINALIZE_FAILED

An error occurred while processing finalize 3DS method caused by an error returned by the service provider

ERROR_3DS_VERIFY_FAILED

An error occurred while processing verify 3DS method caused by an error returned by the service provider

REJECTED [only for CASH-CARD]

Amount exceeds current merchant deposit limit

ERROR_3DS_VERSION_NOT_ENROLLED

Merchant has configured a different version of 3DS than specified in the request

ERROR_MPI2_INTERNAL_ERROR

Some unrecognized, internal error occurred in MPI2 service

ERROR_3DS_2_0_REQUIRED_DATA_NOT_COMPLETE

Required configuration data of Merchant are not complete to finish 3DS 2.X process

ERROR_3DS_2_0_FAILED

Error 3DS 2.X processing failed

ERROR_TRANSACTION_NOT_FOUND

Error transaction not exists

ERROR_VALIDATION

Some validation error occurred

ERROR_SOMETHING_WRONG

An unrecognized error occurred

3.3. Send money outside 3DS 1.0/2.X

POST /api/v2/client/send-money-3ds Content-Type: application/vnd.sendmoney3ds.v2+json, Authorization: Basic Auth, API-TOKEN*
The method allows executing transactions with additional protection i.e. verification by the 3DS (3D-Secure) in new 2.X standard and old 3DS 1.0.
*API-TOKEN is required for methods: DATACORE-PLAIN, DATACORE-DATACORE, DATACORE-CASH, DATACORE-PHONE
3DS 2.X/3DS 1.0 transaction requires additional parameters, but the flow of transaction is the same as transaction without 3DS.
Please notice that you can choose language of email confirmation of this transaction. It is able by attach proper header to request.

From January 2021, there is an internal functionality to restrict access for the Merchant to specific method. The Fenige employee can disable access to a given endpoint, then the HTTP status 403 FORBIDDEN will be returned. The Merchant will be informed about each access restriction action.

Send money with outside 3DS flow
sendmoney trx outside3ds flow
Send money with outside 3DS and DataCenter flow
sendmoney trx outside3ds datacenter flow

3.3.1. Request

Request fields

Table 5. Multicurrency-3DS
Path Type Validation Rule Description

amount

Number

Required

@NotNull, positive

The total transfer amount (in pennies).

cvc2

String

Required

@Length(min = 3, max = 4)

Sender Card cvc2/cvv2.

merchantUrl

String

Optional, mandatory from 2021-05-03

@Optional

Merchant identifier such as the business website URL or reverse domain name as presented to the consumer during checkout

addressIp

String

Optional mandatory from 2021-05-03, @Must match the regular expression ^([0-9]{1,3}.){3}[0-9]{1,3}$

@Optional

The IP address of the order of transaction

type

String

Required

@NotNull

Transaction in 'SENDER' or 'RECEIVER' currency.

requestId

String

Required

@NotNull

128 bit number generated by the user, used to identify single transaction. Ensures that the transaction with the given parameter is processed only once.

sender

Object

Required

@NotNull

Sender PLAIN Sender DATACORE

receiver

Object

Required

@NotNull

Receiver PLAIN Receiver CASH Receiver DATACORE Receiver PHONE

outside3ds.cavv

String

Required

@NotNull

Server transaction Id generated by DS. Required for 3DS 2.X version

outside3ds.cavvAlgorithm

String

Optional

@NotNull

Indicates the algorithm used to generate the AuthenticationCAVV value 0 - HMAC 1 - CVV 2 - CVV with ATN 3 - MasterCard SPA algorithm.

outside3ds.eci

String

Required

@NotNull

Electronic Commerce Indicator: 5 (Visa) or 2 (SecureCode) - The cardholder was successfully authenticated. 6 (Visa) or 1 (SecureCode) - Authentication was attempted, but the cardholder was not enrolled. Chargeback protection applies.

outside3ds.authenticationStatus

String

Required

@NotNull

Authentication status. If AuthenticationStatus is "Y" or "A" then outside 3ds flow will be execute.

outside3ds.transactionXId

String

Required

@NotNull

Cardholder Authentication Verification Value. Cardholder Authentication Verification Value. The transactionXId is the field that defines the 3DS version. The presence of this field in the HTTP request specifies that the transaction will be processed with 3DS 2.x.TransactionXId can be obtained by executing the /authentication method.

Example HTTP Request
PLAIN-PLAIN
POST /api/v2/client/send-money-3ds HTTP/1.1
Content-Type: application/vnd.sendmoney3ds.v2+json
Authorization: Basic bWVyY2hhbnQ6cGFzc3dvcmQ=
Host: java-staging.fenige.pl:8181
Content-Length: 956

{
  "amount" : 1000,
  "cvc2" : "123",
  "merchantUrl" : "https://fenige.pl/payments",
  "addressIp" : "192.168.0.1",
  "type" : "SENDER",
  "outside3ds" : {
    "cavv" : "jEu04WZns7pbARAApU4qgNdJTag=",
    "cavvAlgorithm" : "01",
    "authenticationStatus" : "Y",
    "eci" : "01",
    "transactionXId" : "0a6c7984-cb5f-48fb-a089-7a1f2fd5aec0"
  },
  "requestId" : "7e7f6977-45b3-477e-a644-27fcfccfc322",
  "sender" : {
    "type" : "PLAIN",
    "firstName" : "Mark",
    "lastName" : "Smith",
    "street" : "Olszewskiego",
    "houseNumber" : "17A",
    "city" : "Lublin",
    "postalCode" : "20-400",
    "flatNumber" : "2",
    "email" : "senderEmail@fenige.pl",
    "currency" : "PLN",
    "cardNumber" : "5117964247989169",
    "expirationDate" : "03/23",
    "personalId" : "AGC688910"
  },
  "receiver" : {
    "type" : "PLAIN",
    "firstName" : "Rob",
    "lastName" : "Wring",
    "currency" : "PLN",
    "cardNumber" : "5117964247989169"
  }
}
PLAIN-PLAIN USA/CAN
POST /api/v2/client/send-money-3ds HTTP/1.1
Content-Type: application/vnd.sendmoney3ds.v2+json
Authorization: Basic bWVyY2hhbnQ6cGFzc3dvcmQ=
Host: java-staging.fenige.pl:8181
Content-Length: 999

{
  "amount" : 1000,
  "cvc2" : "123",
  "merchantUrl" : "https://fenige.pl/payments",
  "addressIp" : "192.168.0.1",
  "type" : "SENDER",
  "outside3ds" : {
    "cavv" : "jEu04WZns7pbARAApU4qgNdJTag=",
    "cavvAlgorithm" : "01",
    "authenticationStatus" : "Y",
    "eci" : "01",
    "transactionXId" : "b7669ac2-a1db-4733-a361-7505caf35ca2"
  },
  "requestId" : "d9b4473a-9c63-40ea-a3a3-16b519f3521c",
  "sender" : {
    "type" : "PLAIN",
    "firstName" : "Mark",
    "lastName" : "Smith",
    "street" : "Gates Court",
    "houseNumber" : "82",
    "city" : "Brooklyn",
    "postalCode" : "11211",
    "flatNumber" : "2",
    "email" : "senderdocs@fenige.pl",
    "currency" : "USD",
    "cardNumber" : "5448424719416233",
    "expirationDate" : "03/23",
    "personalId" : "AGC688910",
    "country" : "US",
    "province" : "NY"
  },
  "receiver" : {
    "type" : "PLAIN",
    "firstName" : "Rob",
    "lastName" : "Wring",
    "currency" : "PLN",
    "cardNumber" : "5117964247989169"
  }
}
PLAIN-CASH
POST /api/v2/client/send-money-3ds HTTP/1.1
Content-Type: application/vnd.sendmoney3ds.v2+json
Authorization: Basic bWVyY2hhbnQ6cGFzc3dvcmQ=
Host: java-staging.fenige.pl:8181
Content-Length: 1090

{
  "amount" : 1000,
  "cvc2" : "123",
  "merchantUrl" : "https://fenige.pl/payments",
  "addressIp" : "192.168.0.1",
  "type" : "SENDER",
  "outside3ds" : {
    "cavv" : "jEu04WZns7pbARAApU4qgNdJTag=",
    "cavvAlgorithm" : "01",
    "authenticationStatus" : "Y",
    "eci" : "01",
    "transactionXId" : "7e46cfac-bad1-415f-8fa4-648d214c1697"
  },
  "requestId" : "e60e4dfc-b798-4abf-81d8-706547eb2672",
  "sender" : {
    "type" : "PLAIN",
    "firstName" : "Mark",
    "lastName" : "Smith",
    "street" : "Olszewskiego",
    "houseNumber" : "17A",
    "city" : "Lublin",
    "postalCode" : "20-400",
    "flatNumber" : "2",
    "email" : "senderEmail@fenige.pl",
    "currency" : "PLN",
    "cardNumber" : "5117964247989169",
    "expirationDate" : "03/23",
    "personalId" : "AGC688910"
  },
  "receiver" : {
    "type" : "CASH",
    "firstName" : "Rob",
    "lastName" : "Wring",
    "street" : "Lubelska",
    "houseNumber" : "17A",
    "city" : "Lubartów",
    "postalCode" : "21-100",
    "flatNumber" : "2",
    "email" : "receiverEmail@fenige.pl",
    "currency" : "PLN"
  }
}
PLAIN-CASH USA/CAN
POST /api/v2/client/send-money-3ds HTTP/1.1
Content-Type: application/vnd.sendmoney3ds.v2+json
Authorization: Basic bWVyY2hhbnQ6cGFzc3dvcmQ=
Host: java-staging.fenige.pl:8181
Content-Length: 1133

{
  "amount" : 1000,
  "cvc2" : "123",
  "merchantUrl" : "https://fenige.pl/payments",
  "addressIp" : "192.168.0.1",
  "type" : "SENDER",
  "outside3ds" : {
    "cavv" : "jEu04WZns7pbARAApU4qgNdJTag=",
    "cavvAlgorithm" : "01",
    "authenticationStatus" : "Y",
    "eci" : "01",
    "transactionXId" : "00c5c7b3-170f-47b7-b57d-354f45504dd3"
  },
  "requestId" : "84de12fb-259d-42bf-8370-affdd673dd2a",
  "sender" : {
    "type" : "PLAIN",
    "firstName" : "Mark",
    "lastName" : "Smith",
    "street" : "Gates Court",
    "houseNumber" : "82",
    "city" : "Brooklyn",
    "postalCode" : "11211",
    "flatNumber" : "2",
    "email" : "senderdocs@fenige.pl",
    "currency" : "USD",
    "cardNumber" : "5448424719416233",
    "expirationDate" : "03/23",
    "personalId" : "AGC688910",
    "country" : "US",
    "province" : "NY"
  },
  "receiver" : {
    "type" : "CASH",
    "firstName" : "Rob",
    "lastName" : "Wring",
    "street" : "Lubelska",
    "houseNumber" : "17A",
    "city" : "Lubartów",
    "postalCode" : "21-100",
    "flatNumber" : "2",
    "email" : "receiverEmail@fenige.pl",
    "currency" : "PLN"
  }
}
DATACORE-PLAIN
POST /api/v2/client/send-money-3ds HTTP/1.1
Content-Type: application/vnd.sendmoney3ds.v2+json
Authorization: Basic bWVyY2hhbnQ6cGFzc3dvcmQ=
API-TOKEN: d94NYa+xqRrazUPzSgYeJ6qR/MzIOb3IzePb7t9sWds=
Host: java-staging.fenige.pl:8181
Content-Length: 877

{
  "amount" : 1000,
  "cvc2" : "123",
  "merchantUrl" : "https://fenige.pl/payments",
  "addressIp" : "192.168.0.1",
  "type" : "SENDER",
  "outside3ds" : {
    "cavv" : "jEu04WZns7pbARAApU4qgNdJTag=",
    "cavvAlgorithm" : "01",
    "authenticationStatus" : "Y",
    "eci" : "01",
    "transactionXId" : "ba516158-29d1-4b6f-9fde-ad6e1e0c7b31"
  },
  "requestId" : "cea6cf80-8df0-4cbd-a571-f9ac36274246",
  "sender" : {
    "type" : "DATACORE",
    "firstName" : "Mark",
    "lastName" : "Smith",
    "street" : "Olszewskiego",
    "houseNumber" : "17A",
    "city" : "Lublin",
    "postalCode" : "20-400",
    "flatNumber" : "2",
    "email" : "senderEmail@fenige.pl",
    "currency" : "PLN",
    "cardId" : 1234
  },
  "receiver" : {
    "type" : "PLAIN",
    "firstName" : "Rob",
    "lastName" : "Wring",
    "currency" : "PLN",
    "cardNumber" : "5117964247989169"
  }
}
DATACORE-DATACORE
POST /api/v2/client/send-money-3ds HTTP/1.1
Content-Type: application/vnd.sendmoney3ds.v2+json
Authorization: Basic bWVyY2hhbnQ6cGFzc3dvcmQ=
API-TOKEN: d94NYa+xqRrazUPzSgYeJ6qR/MzIOb3IzePb7t9sWds=
Host: java-staging.fenige.pl:8181
Content-Length: 903

{
  "amount" : 1000,
  "cvc2" : "123",
  "merchantUrl" : "https://fenige.pl/payments",
  "addressIp" : "192.168.0.1",
  "type" : "SENDER",
  "outside3ds" : {
    "cavv" : "jEu04WZns7pbARAApU4qgNdJTag=",
    "cavvAlgorithm" : "01",
    "authenticationStatus" : "Y",
    "eci" : "01",
    "transactionXId" : "d01fd130-d921-4b71-9d49-ef5266c77f1d"
  },
  "requestId" : "aae6567a-6ea6-4521-9785-9513663eaa2a",
  "sender" : {
    "type" : "DATACORE",
    "firstName" : "Mark",
    "lastName" : "Smith",
    "street" : "Olszewskiego",
    "houseNumber" : "17A",
    "city" : "Lublin",
    "postalCode" : "20-400",
    "flatNumber" : "2",
    "email" : "senderEmail@fenige.pl",
    "currency" : "PLN",
    "cardId" : 1234
  },
  "receiver" : {
    "type" : "DATACORE",
    "firstName" : "Rob",
    "lastName" : "Wring",
    "email" : "receiverEmail@fenige.pl",
    "currency" : "PLN",
    "cardId" : 1234
  }
}
DATACORE-CASH
POST /api/v2/client/send-money-3ds HTTP/1.1
Content-Type: application/vnd.sendmoney3ds.v2+json
Authorization: Basic bWVyY2hhbnQ6cGFzc3dvcmQ=
API-TOKEN: d94NYa+xqRrazUPzSgYeJ6qR/MzIOb3IzePb7t9sWds=
Host: java-staging.fenige.pl:8181
Content-Length: 1011

{
  "amount" : 1000,
  "cvc2" : "123",
  "merchantUrl" : "https://fenige.pl/payments",
  "addressIp" : "192.168.0.1",
  "type" : "SENDER",
  "outside3ds" : {
    "cavv" : "jEu04WZns7pbARAApU4qgNdJTag=",
    "cavvAlgorithm" : "01",
    "authenticationStatus" : "Y",
    "eci" : "01",
    "transactionXId" : "06289ea3-da3a-4964-8674-c56354e7d772"
  },
  "requestId" : "400037c0-ade1-4056-a85d-7b0b8f582cac",
  "sender" : {
    "type" : "DATACORE",
    "firstName" : "Mark",
    "lastName" : "Smith",
    "street" : "Olszewskiego",
    "houseNumber" : "17A",
    "city" : "Lublin",
    "postalCode" : "20-400",
    "flatNumber" : "2",
    "email" : "senderEmail@fenige.pl",
    "currency" : "PLN",
    "cardId" : 1234
  },
  "receiver" : {
    "type" : "CASH",
    "firstName" : "Rob",
    "lastName" : "Wring",
    "street" : "Lubelska",
    "houseNumber" : "17A",
    "city" : "Lubartów",
    "postalCode" : "21-100",
    "flatNumber" : "2",
    "email" : "receiverEmail@fenige.pl",
    "currency" : "PLN"
  }
}
DATACORE-PHONE
POST /api/v2/client/send-money-3ds HTTP/1.1
Content-Type: application/vnd.sendmoney3ds.v2+json
Authorization: Basic bWVyY2hhbnQ6cGFzc3dvcmQ=
API-TOKEN: d94NYa+xqRrazUPzSgYeJ6qR/MzIOb3IzePb7t9sWds=
Host: java-staging.fenige.pl:8181
Content-Length: 873

{
  "amount" : 1000,
  "cvc2" : "123",
  "merchantUrl" : "https://fenige.pl/payments",
  "addressIp" : "192.168.0.1",
  "type" : "SENDER",
  "outside3ds" : {
    "cavv" : "jEu04WZns7pbARAApU4qgNdJTag=",
    "cavvAlgorithm" : "01",
    "authenticationStatus" : "Y",
    "eci" : "01",
    "transactionXId" : "1b73749a-9317-4cb5-9402-5b759a03934d"
  },
  "requestId" : "59778ca0-ef30-4bd6-834a-a2d2e9f6b3dc",
  "sender" : {
    "type" : "DATACORE",
    "firstName" : "Mark",
    "lastName" : "Smith",
    "street" : "Olszewskiego",
    "houseNumber" : "17A",
    "city" : "Lublin",
    "postalCode" : "20-400",
    "flatNumber" : "2",
    "email" : "senderEmail@fenige.pl",
    "currency" : "PLN",
    "cardId" : 1234
  },
  "receiver" : {
    "type" : "PHONE",
    "firstName" : "Rob",
    "lastName" : "Wring",
    "currency" : "PLN",
    "phoneNumber" : "48123777619"
  }
}
SM 3DS DATACORE PHONE

3.3.2. Response

Response status
Status Description

200 OK

Returned if the transaction completes successfully.

200 OK - Error validation

Returned list of field name which has validation errors.

202 Accepted

Returned when the transaction with the provided requestId has been registered in the system, but has not yet been completed. The user can retry in a few seconds to get the transaction result.

400 Bad Request

Returned e.g. when a different transaction with the provided requestId has already been registered in the system.

Example HTTP Response
200 OK
HTTP/1.1 200 OK
Content-Type: application/json;charset=ISO-8859-1
Content-Length: 54

{
	"orderId": "234abf25-c35f-a263-a402-cbaf874f137a"
}

Response fields

Path Type Description

orderId

String

OrderId

200 OK - Error validation
HTTP/1.1 200 OK
Content-Type: application/json;charset=ISO-8859-1

{
	"status": "ERROR_VALIDATION",
	"error": {
		"message": "Some information is missing or incorrect.",
		"errors": [{
				"field": "requestId",
				"message": [
					"may not be null"
				]
			},
			{
				"field": "cvc2",
				"message": [
					"may not be null",
					"length must be 3"
				]
			},
			{
				"field": "amount",
				"message": [
					"may not be null"
				]
			},
			{
				"field": "type",
				"message": [
					"may not be null"
				]
			},
			{
				"field": "termUrl",
				"message": [
					"may not be null"
				]
			},
			{
				"field": "sender",
				"message": [
					"may not be null"
				]
			},
			{
				"field": "sender.houseNumber",
				"message": [
					"may not be null",
					"may not be empty",
					"length must be between 1 and 10"
				]
			},
            {
				"field": "sender.street",
				"message": [
					"may not be null",
					"may not be empty",
					"length must be between 1 and 50"
				]
			},
			{
				"field": "sender.firstName",
				"message": [
					"may not be null",
					"may not be empty",
					"length must be between 2 and 35"
				]
			},
			{
				"field": "sender.lastName",
				"message": [
					"may not be empty",
					"may not be null",
					"length must be between 2 and 35"
				]
			},
			{
				"field": "sender.postalCode",
				"message": [
					"may not be empty",
					"may not be null",
					"length must be between 1 and 10"
				]
			},
            {
				"field": "sender.city",
				"message": [
					"may not be empty",
					"may not be null",
					"length must be between 1 and 25"
				]
			},
            {
                "field": "sender.flatNumber",
                "message": [
                    "must be null",
                    "length must be between 0 and 5"
                ]
            },
			{
				"field": "sender.cardNumber",
				"message": [
					"may not be null",
					"may not be empty",
					"card number length must be 16"
				]
			},
			{
				"field": "sender.email",
				"message": [
					"may not be empty",
					"may not be null",
					"not a well-formed email address",
					"lenght must be beetween 1 and 128"
				]
			},
			{
				"field": "sender.expirationDate",
				"message": [
					"invalid card expiration date",
					"may not be null",
					"may not be empty"
				]
			},
			{
				"field": "receiver",
				"message": [
					"may not be null"
				]
			},
			{
				"field": "receiver.firstName",
				"message": [
					"may not be null",
					"may not be empty",
					"length must be between 2 and 35"
				]
			},
			{
				"field": "receiver.lastName",
				"message": [
					"may not be empty",
					"may not be null",
					"length must be between 2 and 35"
				]
			},
			{
				"field": "receiver.currency",
				"message": [
					"may not be null"
				]
			},
			{
				"field": "receiver.cardNumber",
				"message": [
					"may not be null",
					"may not be empty",
				    "card number length must be 16"
				]
			},
			{
                "field": "sender",
                "message": [
                     "province is mandatory only if country code is US or CA"
                ]
            },
            {
                 "field": "sender.province",
                 "message": [
                      "is not correct province code for country code US",
                      "may not be null"
                 ]
            },
            {
                 "field": "sender.province",
                 "message": [
                       "may not be null",
                       "is not correct province code for country code CA"
                 ]
            },
            {
                 "field": "sender.province",
                 "message": [
                        "must match ^[A-Z]{2}$",
                        "is not correct province code for country code US"
                 ]
            },
            {
                 "field": "sender.currency",
                 "message": [
                       "Currency is not supported"
                ]
            },
            {
                 "field": "receiver.currency",
                 "message": [
                       "Currency is not supported"
                ]
            }
        ]
    }
}
Errors mentioned below may occur if card’s country is other than user’s country for USA or CAN transaction
HTTP/1.1 200 OK
Content-Type: application/json

{
    "status": "ERROR_WHILE_VALIDATING_CARD_COUNTRY_CODE_AND_USER_COUNTRY_CODE_FOR_PLAIN",
    "error": {
        "message": "Card country code not compatible with user country code.
                    Please update country in request."
    }
}
HTTP/1.1 200 OK
Content-Type: application/json

{
    "status": "ERROR_WHILE_VALIDATING_CARD_COUNTRY_CODE_AND_USER_COUNTRY_CODE",
    "error": {
        "message": "Card country code not compatible with user country code.
                    Please update user profile."
    }
}
HTTP/1.1 200 OK
Content-Type: application/json

{
    "status": "ERROR_WHILE_GETTING_COUNTRY_CODE",
    "error": {
        "message": "Could not get card country code"
    }
}
HTTP/1.1 200 OK
Content-Type: application/json

{
    "status": "ERROR_WHILE_VALIDATING_PROVINCE_NOT_CORRECT_PROVINCE_CODE",
    "error": {
        "message": "Province code is not valid province code.
                    Please update user profile"
    }
}
Error described bellow may occur when merchant tries to make transaction in other model than assigned primarily. For example, if merchant’s model is set as Card-Card and then merchant will try to make transaction in Cash-Card model, will receive error as bellow.
HTTP/1.1 200 OK
Content-Type: application/json;charset=ISO-8859-1

{
    "status": "ERROR_VALIDATION",
    "error": {
        "message": "Some information is missing or incorrect.",
        "errors": [
            {
                "field": "sender.type",
                "message": [
                    "Sender type violates merchant model"
                ]
            }
        ]
    }
}
Errors below may occur when a merchant uses a sender card or a receiver card issued in a country that is on the list of countries High Risk excluded from the Fenige API transactions. The transaction is treated as high risk and rejected. Please contact support.
HTTP/1.1 200 OK
Content-Type: application/json;charset=ISO-8859-1

{
    "status": "ERROR_MERCHANT_FUNDING_CARD_COUNTRY_RESTRICTED",
    "error": {
        "message": "Restricted funding card country was used."
    }
}
HTTP/1.1 200 OK
Content-Type: application/json;charset=ISO-8859-1

{
    "status": "ERROR_MERCHANT_PAYMENT_CARD_COUNTRY_RESTRICTED",
    "error": {
        "message": "Restricted payment card country was used."
    }
}
202 Accepted
HTTP/1.1 202 Accepted
Content-Type: application/json;charset=ISO-8859-1
Content-Length: 56

{
  "orderId" : "e6c9108a-d741-4b36-b3b6-94383d53b6a6"
}

Response fields

Path Type Description

orderId

String

Transaction order-id

400 Bad request
HTTP/1.1 400 Bad Request
Content-Type: application/json;charset=ISO-8859-1
Content-Length: 104

{
  "error" : {
    "message" : "Another transaction with the same id has already been processed."
  }
}
403 FORBIDDEN
HTTP Response - Error
{
    "timestamp": 1610464313387,
    "status": 403,
    "error": "Forbidden",
    "message": "No message available",
    "path": "/client/send-money-3ds"
}

3.3.3. Check status multicurrency-3ds

GET /client/send-money-3ds/{orderId}, Authentication: Basic Auth
The method allows obtaining a status of 3ds transaction specified by order-id. Parameter order-id was returned in the previous step (Send money multicurrency 3DS).
Request
Table 6. /client/send-money-3ds/{orderId}
Parameter Description

orderId

Unique transaction identifier.

GET /client/send-money-3ds/a943a9f5-xtr6f-4000-8b39-cb37ecb4a1c9 HTTP/1.1
Authorization: Basic bWVyY2hhbnQ6cGFzc3dvcmQ=
Host: java-staging.fenige.pl:8181
Response
Response status
Status Description

200 OK

Returned if the transaction completes successfully.

203 NON-AUTHORITATIVE INFORMATION

Returned when transaction was registered for processing. Check status in a while.

500 INTERNAL SERVER ERROR

Returned when user provides wrong order-id or transaction was failed or was Declined.

Example HTTP Response
200 OK
HTTP/1.1 200 OK
Content-Type: application/json
Content-Length: 987

{
  "amount" : 1000,
  "amountInUsDollar" : 268,
  "bigDecimalAmount" : 10.0,
  "commission" : 200,
  "bigDecimalCommission" : 2.0,
  "orderId" : "a943a9f5-xtr6f-4000-8b39-cb37ecb4a1c9",
  "createdDate" : "03-04-2018, 14:01",
  "revaluationResult" : {
    "revaluationFundingAmount" : 1000,
    "bigDecimalRevaluationFundingAmount" : 10.0,
    "fundingCurrency" : "PLN",
    "revaluationPaymentAmount" : 1000,
    "bigDecimalRevaluationPaymentAmount" : 10.0,
    "paymentCurrency" : "PLN",
    "determineCurrencyRate" : {
      "from" : "PLN",
      "to" : "PLN",
      "currencyRate" : "1"
    }
  },
  "receiver" : {
    "firstName" : "John",
    "lastName" : "Novak",
    "provider" : "MASTERCARD",
    "hiddenCardNumber" : "557455******1623",
    "bankName" : "Alior Bank SA"
  },
  "sender" : {
    "firstName" : "Caroline",
    "lastName" : "Novak",
    "provider" : "MASTERCARD",
    "hiddenCardNumber" : "511796******9169",
    "bankName" : "Alior Bank SA"
  },
  "3DS" : false
}

Response fields

Path Type Description

amount

Number

Field informing about the amount of cash transferred in one hundredth of the currency. [1PLN = 100]

amountInUsDollar

Number

Field informing about the amount of cash transferred in one hundredth of the USD currency. [1USD = 100]

bigDecimalAmount

Number

Field informing about the amount of cash transferred with decimal precision.

commission

Number

This is the amount of commission that has been added to the transaction in hundredths. [1 PLN = 100]

bigDecimalCommission

Number

This is the amount of commission that was added to the transaction at 0.01 currency.

orderId

String

Unique transaction identifier.

createdDate

String

Date of transaction.

3DS

Boolean

Value: true/false determines if transaction was processed with 3ds

revaluationResult

Object (RevaluationResult)

Detailed information about revaluation between sender and receiver currency.

receiver

Object

Personal data of the person to whom the transfer is addressed.

sender

Object

Personal data of the person who performs the transfer of cash.

RevaluationResult

Path Type Description

revaluationFundingAmount

Long

Amount (in pennies) of funding transaction in fundingCurrency

bigDecimalRevaluationFundingAmount

BigDecimal

Amount of funding transaction in fundingCurrency

fundingCurrency

String

Currency code the same as sender’s card currency

revaluationPaymentAmount

Long

Amount (in pennies) of payment transaction in paymentCurrency

bigDecimalRevaluationPaymentAmount

BigDecimal

Amount of payment transaction in paymentCurrency

paymentCurrency

String

Currency code the same as receiver’s card currency

determineCurrencyRate

Object (DetermineCurrencyRate)

Details about conversion

DetermineCurrencyRate

Path Type Description

from

Long

Currency which was conversion from

to

Long

Resulted currency

masterCardCurrencyRate

BigDecimal

Currency rate

203 NON-AUTHORITATIVE INFORMATION
HTTP/1.1 203 Non-Authoritative Information

After you get 203 you need to check status in a while because we processing this transaction and if you don’t get a response (200 - succeeded or 500 - declined) within 15 seconds then please contact us.

500 INTERNAL SERVER ERROR
HTTP/1.1 500 Internal Server Error
Content-Type: text/plain;charset=ISO-8859-1

PAYMENT_TRANSACTION_DECLINED:CODE_05

After receiving these statuses, the transaction was rejected

Error statuses

Name Description

FUNDING_TRANSACTION_DECLINED:CODE_XX, PAYMENT_TRANSACTION_DECLINED:CODE_XX

CODE_XX - is MasterCard response code (ISO 8583)

ISSUER_NOT_SUPPORTED

This card is not supported

ERROR_CARD_IS_BLOCKED

Card is blocked for 1 hour in Fenige

ERROR_USER_IS_BLOCKED

User is blocked in Fenige

ERROR_BIN_IS_BLOCKED

Bin is blocked for 1 hour in Fenige

ERROR_FUNDING_BANK_IS_BLOCKED

Funding bank is blocked in Fenige

ERROR_PAYMENT_BANK_IS_BLOCKED

Payment bank is blocked in Fenige

FUNDING_TRANSACTION_DECLINED:ACQ_ERROR [only for CARD-CARD]

Funding transaction was declined and payment not send

PAYMENT_TRANSACTION_DECLINED:ACQ_ERROR

Payment transaction was declined and funding was reversed

ERROR_ACQ_CONNECTION

A connection error occurred to Acquirer service

AML_ERROR

User was found on the stop list

NETWORK_ERROR

Acceptance network is unavailable

CURRENCY_RATES_NOT_FOUND

No currently effective rates found in the database

CURRENCY_NOT_SUPPORTED

Currency is not supported

MERCHANT_CURRENCY_NOT_SUPPORTED

Currency is not supported by Merchant

ERROR_DAILY_CUMULATIVE_LIMIT

Daily cumulative limit per card was exceeded

ERROR_MONTHLY_CUMULATIVE_LIMIT

Monthly cumulative limit per card was exceeded

ERROR_MERCHANT_MASTERCARD_DAILY_CUMULATIVE_LIMIT

Daily cumulative limit per merchant transactions using mastercard cards was exceeded

ERROR_MERCHANT_MASTERCARD_MONTHLY_CUMULATIVE_LIMIT

Monthly cumulative limit per merchant transactions using mastercard cards was exceeded

ERROR_MERCHANT_VISA_DAILY_CUMULATIVE_LIMIT

Daily cumulative limit per merchant transactions using visa cards was exceeded

ERROR_MERCHANT_VISA_MONTHLY_CUMULATIVE_LIMIT

Monthly cumulative limit per merchant transactions using visa cards was exceeded

ERROR_SENDER_CARD_IS_BLOCKED [only for CARD-CARD]

Sender’s card is blocked

ERROR_RECEIVER_CARD_IS_BLOCKED

Receiver’s card is blocked

ERROR_SENDER_USER_IS_BLOCKED [only for CARD-CARD]

User acting as sender is blocked

ERROR_RECEIVER_USER_IS_BLOCKED

User acting as receiver is blocked

ERROR_SENDER_BIN_IS_BLOCKED [only for CARD-CARD]

BIN of sender’s card is blocked

ERROR_RECEIVER_BIN_IS_BLOCKED

BIN of receiver’s card is blocked

ERROR_AMOUNT_IS_BLOCKED

Amount is higher than acceptable limit

ERROR_MONITORING_CONNECTION

Couldn’t established connection to Monitoring service

ERROR_MONITORING_UNAUTHORIZED

Error with service authorization occurred

ERROR_MONITORING

Some unrecognized error occurred

ERROR_USER_VERIFICATION

The transaction user’s personal data verified as incorrect on the verification service. Transaction rejected.

FUNDING_TRANSACTION_DECLINED:MIP_RESPONSE_TIMEOUT [only for CARD-CARD]

Funding transaction declined - mip response timeout

PAYMENT_TRANSACTION_DECLINED:MIP_RESPONSE_TIMEOUT

Payment transaction declined - mip response timeout

FUNDING_TRANSACTION_DECLINED:NEED_MANUAL_VERIFICATION [only for CARD-CARD]

Funding process failed and it is need to manual verification of transaction

PAYMENT_TRANSACTION_DECLINED:NEED_MANUAL_VERIFICATION

Payment process failed and it is need to manual verification of transaction

FUNDING_TRANSACTION_DECLINED:MIP_PROXY_RESPONSE_TIMEOUT [only for CARD-CARD]

Funding transaction declined - mip_proxy response timeout

PAYMENT_TRANSACTION_DECLINED:MIP_PROXY_RESPONSE_TIMEOUT

Payment transaction declined - mip_proxy response timeout

ERROR_FINALIZE_3DS_NOT_AUTHENTICATED

Error finalize 3ds not authenticated. MPI return one of statuses:

N -The customer failed authentication, and the transaction is denied.
U - Authentication could not be performed due to technical or other problems.

ERROR_NO_3DS_AUTHORIZATION

Error no 3ds authorization, when User authenticates successfully but after 15 minutes or User doesn’t authenticate.

ERROR_MPI_STATUS_TO_LOW: Initialize/Finalize: U/N

Error occurs, when merchant configuration allows only for attempted or full authenticated 3DS transactions with mpi status 'A' or 'Y' but mpi service has returned other status e.g. 'N' or 'U' at any stage of the transaction.

ERROR_3DS_INITIALIZE_FAILED

An error occurred while processing initialize 3DS method caused by an error returned by the service provider

ERROR_3DS_FINALIZE_FAILED

An error occurred while processing finalize 3DS method caused by an error returned by the service provider

ERROR_3DS_VERIFY_FAILED

An error occurred while processing verify 3DS method caused by an error returned by the service provider

REJECTED [only for CASH-CARD]

Amount exceeds current merchant deposit limit

ERROR_3DS_VERSION_NOT_ENROLLED

Merchant has configured a different version of 3DS than specified in the request

ERROR_MPI2_INTERNAL_ERROR

Some unrecognized, internal error occurred in MPI2 service

ERROR_3DS_2_0_REQUIRED_DATA_NOT_COMPLETE

Required configuration data of Merchant are not complete to finish 3DS 2.X process

ERROR_3DS_2_0_FAILED

Error 3DS 2.X processing failed

ERROR_TRANSACTION_NOT_FOUND

Error transaction not exists

ERROR_VALIDATION

Some validation error occurred

ERROR_SOMETHING_WRONG

An unrecognized error occurred

3.4. Transaction history

GET /client/{clientId}/transactions?page=0&size=100 Content Type: application/json, Authorization: Basic Auth
Method return page with list of user transactions. Transactions are filtered by clientId provided in GET parameter.
User can send additional optional parameters (page, size) to obtain given page with defined size.

3.4.1. Request

GET /client/0/transactions?fromDate=2018-03-06&toDate=2018-03-08&page=0&size=100 HTTP/1.1
Content-Type: application/json
Authorization: Basic bWVyY2hhbnQ6cGFzc3dvcmQ=
Host: java-staging.fenige.pl:8181

3.4.2. Response

Response status
Status Description

200 OK

Returned list of transactions history.

404 NOT FOUND

Returning the list failed.

Example Response
200 OK
HTTP/1.1 200 OK
Content-Type: application/json;charset=UTF-8
Content-Length: 1038

{
  "content" : [ {
    "correlationId" : "661206b0-49f9-4534-b47c-789444f42e0c",
    "createdDate" : "2018-03-15T10:24:52.149Z",
    "amount" : 15000,
    "amountInUsDollar" : 4024,
    "textAmount" : "150.00 PLN",
    "currency" : "PLN",
    "cardId" : 3574,
    "receiverFirstName" : "Patrick",
    "receiverLastName" : "Evans",
    "receiverHiddenCardNumber" : "511123******1234",
    "receiverProvider" : "MASTERCARD",
    "receiverBankName" : "Bank Polska Kasa Opieki Spółka Akcyjna",
    "receiverEmail" : "receiver@fenige.pl",
    "receiverPhone" : "600300200",
    "senderFirstName" : "Rob",
    "senderLastName" : "Wring",
    "senderHiddenCardNumber" : "522212******4321",
    "senderProvider" : "MASTERCARD",
    "senderBankName" : "Alior Bank SA",
    "status" : "approved",
    "3DS" : false
  } ],
  "pageable" : "INSTANCE",
  "last" : true,
  "totalPages" : 1,
  "totalElements" : 1,
  "first" : true,
  "sort" : {
    "sorted" : false,
    "unsorted" : true
  },
  "numberOfElements" : 1,
  "size" : 0,
  "number" : 0
}

Response fields

Path Type Description

content.[].correlationId

String

Unique UUID describing single transaction in system

content.[].createdDate

String

Date of transaction processing

content.[].amount

Number

Transaction amount in pennies

content.[].amountInUsDollar

Number

Transaction amount in USD currency in pennies.

content.[].textAmount

String

Transaction amount with currency

content.[].currency

String

Transaction currency

content.[].cardId

Number

Datacore card id used in transaction (sender card)

content.[].3DS

Boolean

Value: true/false determines if transaction was processed with 3ds

content.[].receiverFirstName

String

Transaction receiver first name

content.[].receiverLastName

String

Transaction receiver last name

content.[].receiverHiddenCardNumber

String

Transaction receiver hidden card number

content.[].receiverProvider

String

VISA or MASTERCARD or MAESTRO

content.[].receiverBankName

String

Transaction receiver card bank name.

content.[].senderFirstName

String

Transaction sender first name.

content.[].senderLastName

String

Transaction sender last name.

content.[].senderHiddenCardNumber

String

Transaction sender hidden card numbe.

content.[].senderProvider

String

VISA or MASTERCARD or MAESTRO

content.[].senderBankName

String

Transaction sender card bank name.

content.[].receiverPhone

String

Transaction receiver phone number

content.[].receiverEmail

String

Transaction receiver email

content.[].status

String

Status of the transaction (approved, reversed)

last

Boolean

Describes whether the page is last (true ot false)

totalPages

Number

Total number of all pages

totalElements

Number

Total number of all transactions

numberOfElements

Number

Number of transactions on page

first

Boolean

Describes whether the page is first (true ot false)

sort

Object

Details of sort

size

Number

Max number of transactions on page

number

Number

Page number

pageable

String

Page number

404 NOT FOUND
HTTP/1.1 404 Not Found

3.5. Transaction details

GET /client/transaction/{correlationId} Content Type: application/json, Authorization: Basic Auth
Method return transaction details for single transaction given in method parameter correlationId

3.5.1. Request

GET /client/transactions/fae3ee90-6f88-4aa6-aff5-7d9f6a5645d3 HTTP/1.1
Content-Type: application/json
Authorization: Basic bWVyY2hhbnQ6cGFzc3dvcmQ=
Host: java-staging.fenige.pl:8181

3.5.2. Response

Response status
Status Description

200 OK

Returned details of transaction.

Example Response
200 OK
HTTP/1.1 200 OK
Content-Type: application/json;charset=UTF-8
Content-Length: 246

{
  "fundingAmount" : "2.00 PLN",
  "chargedAmount" : "2.04 PLN",
  "commission" : "0.04 PLN",
  "paymentAmount" : "0.54 USD",
  "exchange" : "1.00 PLN = 0.27 USD",
  "transactionTime" : "2018-07-26T17:01:56.364Z",
  "cardIssuer" : "Mastercard"
}

Response fields

Path Type Description

fundingAmount

String

Funding amount in transaction currency

chargedAmount

String

Charged amount in transaction currency

commission

String

Transaction commission with currency

paymentAmount

String

Payment amount in receiver currency

exchange

String

Revaluation amount from sender to receiver currency

transactionTime

String

Date of the transaction

cardIssuer

String

Card issuer (Mastercard)

4. Delayed payment

Mastercard and Visa requires for intra-European Economic Area (EEA), plus United Kingdom, for which EMV 3DS must be used subsequent to a valid authorization soft decline DE39=65. To perform a transaction for which the card has previously received CODE_65, the transaction must be processed with full EMV 3DS (3DS 2.x) and the authentication status must be 'Y'.

Correct flow:

  • 3DS 2.x → Challenge → Authentication status Y → Transaction (Recommended)

  • 3DS 2.x → Card number not Enrolled in 3DS v2 → 3DS 1.0 → Transaction (Recommended)

  • 3DS 1.0 → Authentication status Y/A → Transaction → CODE_65 → 3DS 2.x → Challenge → Authentication status Y → Transaction (Not recommended)

  • non3DS → Transaction → CODE_65 → 3DS 2.x → Challenge → Authentication status Y → Transaction (Available only to selected merchants)

soft decline Code 65 EMV 3DS

4.1. Delayed Send Money

POST /client/delayed/send-money Content-Type: application/json, Authorization: Basic Auth, API-TOKEN*
The Delayed Send Money functionality provides the ability to perform transactions, where recipient is not known at the time of funding execution.
Transaction in the Send Money system consists of Funding and Payment.
In order to perform the method that request is described below, we can execute Funding (with Payment for some cases**).
Money specified in the request ('amount' field) will be charged from the Sender's card, but these money will be transferred to the Receiver's card when Receiver is known (After Delayed Payment method execution).
In order to make the full flow of the transaction, the Delayed Payment method must be executed. In Delayed Payment methods you should define Receiver of Funding - then transaction will be processed.
*API-TOKEN is required for model when sender is DATACORE type.
**See table below with Delayed Send Money models. You can find there information which model executes only Funding or Funding with Payment at the same time.
The maximum time for the execution of Delayed Payment after earlier calling Delayed Send Money is 12 hours. After 12 hours after Funding without Payment, it will be reversed.
There is 3 attempts to execute Delayed Payment after earlier call Delayed Send Money.

From January 2021, there is an internal functionality to restrict access for the Merchant to specific method. The Fenige employee can disable access to a given endpoint, then the HTTP status 403 FORBIDDEN will be returned. The Merchant will be informed about each access restriction action.

4.1.1. Quick tour of Delayed Send Money models

Model Sender Receiver Description Transaction Type

DATACORE_SENDER - DELAYED_RECEIVER

DATACORE

DELAYED

For transactions in this model, we provide the full Sender’s data in the request without card number but with the 'cardId' (card is stored in Fenige Datacenter). The user must get API-TOKEN in the /client/login method. The Receiver’s details are unknown yet, so we are waiting for a Delayed Payment to be made.

Funding or Funding & Payment

PLAIN_SENDER - DELAYED_RECEIVER

PLAIN

DELAYED

For transactions in this model, user must provide all the full Sender data in the request. The Receiver’s details are unknown yet, so we are waiting for a Delayed Payment to be made.

Funding or Funding & Payment

4.1.2. Delayed Send Money Examples

DATACORE_SENDER-DELAYED_RECEIVER_EXISTS_IN_DATABASE
DP DATACORE DELAYED SENDER DELAYED RECEIVER EXISTS
DATACORE_SENDER-DELAYED_RECEIVER_NOT_EXISTS_IN_DATABASE
DP DATACORE DELAYED SENDER DELAYED RECEIVER NOT EXISTS
PLAIN_SENDER-DELAYED_RECEIVER_EXISTS_IN_DATABASE
DP PLAIN DELAYED SENDER DELAYED RECEIVER EXISTS
PLAIN_SENDER-DELAYED_RECEIVER_NOT_EXISTS_IN_DATABASE
DP PLAIN DELAYED SENDER DELAYED RECEIVER NOT EXISTS

4.1.3. Requests

DATACORE_SENDER-DELAYED_RECEIVER(Phone)
POST /client/delayed/send-money HTTP/1.1
Content-Type: application/json
Authorization: Basic bWVyY2hhbnQ6cGFzc3dvcmQ=
API-TOKEN: d94NYa+xqRrazUPzSgYeJ6qR/MzIOb3IzePb7t9sWds=
Host: java-staging.fenige.pl:8181
Content-Length: 860

{
  "amount" : 1000,
  "cvc2" : "123",
  "termUrl" : "https://termurl.pl",
  "merchantUrl" : "https://fenige.pl/payments",
  "addressIp" : "192.168.0.1",
  "type" : "SENDER",
  "outside3ds" : {
    "cavv" : "jEu04WZns7pbARAApU4qgNdJTag=",
    "cavvAlgorithm" : "02",
    "authenticationStatus" : "Y",
    "eci" : "02",
    "transactionXId" : "3c1b483d-ff9d-43e0-8bee-0dd19117c0f7"
  },
  "requestId" : "53eaf549-504d-4b96-ae25-5292a2edaefc",
  "sender" : {
    "type" : "DATACORE",
    "firstName" : "Mark",
    "lastName" : "Smith",
    "street" : "Olszewskiego",
    "houseNumber" : "17A",
    "city" : "Lublin",
    "postalCode" : "20-400",
    "flatNumber" : "2",
    "email" : "senderEmail@fenige.pl",
    "currency" : "PLN",
    "cardId" : 1234
  },
  "receiver" : {
    "type" : "DELAYED",
    "currency" : "USD",
    "phoneNumber" : "48600300200"
  }
}
Table 7. Delayed Send Money Request Fields
Path Type Validation Rule Description

amount

Number

Required

@NotNull, positive

The total transfer amount (in pennies).

cvc2

String

Required

@Length(min = 3, max = 3)

Sender card cvc2/cvv2.

type

String

Required

@NotNull

Transaction in 'SENDER' or 'RECEIVER' currency.

merchantUrl

String

Optional, mandatory from 2021-05-03

@Optional

Merchant identifier such as the business website URL or reverse domain name as presented to the consumer during checkout

addressIp

String

Optional mandatory from 2021-05-03, @Must match the regular expression ^([0-9]{1,3}.){3}[0-9]{1,3}$

@Optional

The IP address of the order of transaction

termUrl

String

Optional

@NotEmpty

Merchant URL to be redirected from Fenige after user login in the bank. This URL must accept order-id parameter, that tells which transaction is begin processed. The presence of this field in the HTTP request specifies that the transaction will be processed with 3DS 1.0.

requestId

String

Optional

@NotNull

128 bit number generated by the user, used to identify single transaction. Ensures that the transaction with the given parameter is processed only once.

sender

Object

Required

@NotNull

Personal data of Sender.

receiver

Object

Required

@NotNull

Personal data of Receiver.

outside3ds.cavv

String

Required

@NotNull

Cardholder Authentication Verification Value.

outside3ds.cavvAlgorithm

String

Optional

@NotNull

Indicates the algorithm used to generate the AuthenticationCAVV value 0 - HMAC 1 - CVV 2 - CVV with ATN 3 - MasterCard SPA algorithm.

outside3ds.eci

String

Required

@NotNull

Electronic Commerce Indicator: 5 (Visa) or 2 (SecureCode) - The cardholder was successfully authenticated. 6 (Visa) or 1 (SecureCode) - Authentication was attempted, but the cardholder was not enrolled. Chargeback protection applies.

outside3ds.authenticationStatus

String

Required

@NotNull

Authentication status. If AuthenticationStatus is "Y" or "A" then outside 3ds flow will be execute.

outside3ds.transactionXId

String

Optional

@NotNull

Cardholder Authentication Verification Value. The transactionXId is the field that defines the 3DS version. The presence of this field in the HTTP request specifies that the transaction will be processed with 3DS 2.X. TransactionXId can be obtained by executing the /authentication method.

DATACORE_SENDER-DELAYED_RECEIVER(Email)
POST /client/delayed/send-money HTTP/1.1
Content-Type: application/json
Authorization: Basic bWVyY2hhbnQ6cGFzc3dvcmQ=
API-TOKEN: d94NYa+xqRrazUPzSgYeJ6qR/MzIOb3IzePb7t9sWds=
Host: java-staging.fenige.pl:8181
Content-Length: 866

{
  "amount" : 1000,
  "cvc2" : "123",
  "termUrl" : "https://termurl.pl",
  "merchantUrl" : "https://fenige.pl/payments",
  "addressIp" : "192.168.0.1",
  "type" : "SENDER",
  "outside3ds" : {
    "cavv" : "jEu04WZns7pbARAApU4qgNdJTag=",
    "cavvAlgorithm" : "02",
    "authenticationStatus" : "Y",
    "eci" : "02",
    "transactionXId" : "4f6f2291-51a5-46d9-9913-4a9a5a53ab94"
  },
  "requestId" : "55c6c689-595b-4cb3-bb79-51b28919f90f",
  "sender" : {
    "type" : "DATACORE",
    "firstName" : "Mark",
    "lastName" : "Smith",
    "street" : "Olszewskiego",
    "houseNumber" : "17A",
    "city" : "Lublin",
    "postalCode" : "20-400",
    "flatNumber" : "2",
    "email" : "senderEmail@fenige.pl",
    "currency" : "PLN",
    "cardId" : 1234
  },
  "receiver" : {
    "type" : "DELAYED",
    "email" : "receiverEmail@fenige.pl",
    "currency" : "USD"
  }
}
Table 8. Delayed Send Money Request Fields
Path Type Validation Rule Description

amount

Number

Required

@NotNull, positive

The total transfer amount (in pennies).

cvc2

String

Required

@Length(min = 3, max = 3)

Sender card cvc2/cvv2.

type

String

Required

@NotNull

Transaction in 'SENDER' or 'RECEIVER' currency.

merchantUrl

String

Optional, mandatory from 2021-05-03

@Optional

Merchant identifier such as the business website URL or reverse domain name as presented to the consumer during checkout

addressIp

String

Optional mandatory from 2021-05-03, @Must match the regular expression ^([0-9]{1,3}.){3}[0-9]{1,3}$

@Optional

The IP address of the order of transaction

termUrl

String

Optional

@NotEmpty

Merchant URL to be redirected from Fenige after user login in the bank. This URL must accept order-id parameter, that tells which transaction is begin processed. The presence of this field in the HTTP request specifies that the transaction will be processed with 3DS 1.0.

requestId

String

Optional

@NotNull

128 bit number generated by the user, used to identify single transaction. Ensures that the transaction with the given parameter is processed only once.

sender

Object

Required

@NotNull

Personal data of Sender.

receiver

Object

Required

@NotNull

Personal data of Receiver.

outside3ds.cavv

String

Required

@NotNull

Cardholder Authentication Verification Value.

outside3ds.cavvAlgorithm

String

Optional

@NotNull

Indicates the algorithm used to generate the AuthenticationCAVV value 0 - HMAC 1 - CVV 2 - CVV with ATN 3 - MasterCard SPA algorithm.

outside3ds.eci

String

Required

@NotNull

Electronic Commerce Indicator: 5 (Visa) or 2 (SecureCode) - The cardholder was successfully authenticated. 6 (Visa) or 1 (SecureCode) - Authentication was attempted, but the cardholder was not enrolled. Chargeback protection applies.

outside3ds.authenticationStatus

String

Required

@NotNull

Authentication status. If AuthenticationStatus is "Y" or "A" then outside 3ds flow will be execute.

outside3ds.transactionXId

String

Optional

@NotNull

Cardholder Authentication Verification Value. The transactionXId is the field that defines the 3DS version. The presence of this field in the HTTP request specifies that the transaction will be processed with 3DS 2.X. TransactionXId can be obtained by executing the /authentication method.

PLAIN_SENDER-DELAYED_RECEIVER(Phone)
POST /client/delayed/send-money HTTP/1.1
Content-Type: application/json
Authorization: Basic bWVyY2hhbnQ6cGFzc3dvcmQ=
Host: java-staging.fenige.pl:8181
Content-Length: 939

{
  "amount" : 1000,
  "cvc2" : "123",
  "termUrl" : "https://termurl.pl",
  "merchantUrl" : "https://fenige.pl/payments",
  "addressIp" : "192.168.0.1",
  "type" : "SENDER",
  "outside3ds" : {
    "cavv" : "jEu04WZns7pbARAApU4qgNdJTag=",
    "cavvAlgorithm" : "02",
    "authenticationStatus" : "Y",
    "eci" : "02",
    "transactionXId" : "67db6b37-9ce3-4ac2-a98d-f3e1be3307b9"
  },
  "requestId" : "49464e2e-13fa-4a61-a2c8-82cd920bfc13",
  "sender" : {
    "type" : "PLAIN",
    "firstName" : "Mark",
    "lastName" : "Smith",
    "street" : "Olszewskiego",
    "houseNumber" : "17A",
    "city" : "Lublin",
    "postalCode" : "20-400",
    "flatNumber" : "2",
    "email" : "senderEmail@fenige.pl",
    "currency" : "PLN",
    "cardNumber" : "5117964247989169",
    "expirationDate" : "03/23",
    "personalId" : "AGC688910"
  },
  "receiver" : {
    "type" : "DELAYED",
    "currency" : "USD",
    "phoneNumber" : "48600300200"
  }
}
Table 9. Delayed Send Money Request Fields
Path Type Validation Rule Description

amount

Number

Required

@NotNull, positive

The total transfer amount (in pennies).

cvc2

String

Required

@Length(min = 3, max = 3)

Sender card cvc2/cvv2.

type

String

Required

@NotNull

Transaction in 'SENDER' or 'RECEIVER' currency.

merchantUrl

String

Optional, mandatory from 2021-05-03

@Optional

Merchant identifier such as the business website URL or reverse domain name as presented to the consumer during checkout

addressIp

String

Optional mandatory from 2021-05-03, @Must match the regular expression ^([0-9]{1,3}.){3}[0-9]{1,3}$

@Optional

The IP address of the order of transaction

termUrl

String

Optional

@NotEmpty

Merchant URL to be redirected from Fenige after user login in the bank. This URL must accept order-id parameter, that tells which transaction is begin processed. The presence of this field in the HTTP request specifies that the transaction will be processed with 3DS 1.0.

requestId

String

Optional

@NotNull

128 bit number generated by the user, used to identify single transaction. Ensures that the transaction with the given parameter is processed only once.

sender

Object

Required

@NotNull

Personal data of Sender.

receiver

Object

Required

@NotNull

Personal data of Receiver.

outside3ds.cavv

String

Required

@NotNull

Cardholder Authentication Verification Value.

outside3ds.cavvAlgorithm

String

Optional

@NotNull

Indicates the algorithm used to generate the AuthenticationCAVV value 0 - HMAC 1 - CVV 2 - CVV with ATN 3 - MasterCard SPA algorithm.

outside3ds.eci

String

Required

@NotNull

Electronic Commerce Indicator: 5 (Visa) or 2 (SecureCode) - The cardholder was successfully authenticated. 6 (Visa) or 1 (SecureCode) - Authentication was attempted, but the cardholder was not enrolled. Chargeback protection applies.

outside3ds.authenticationStatus

String

Required

@NotNull

Authentication status. If AuthenticationStatus is "Y" or "A" then outside 3ds flow will be execute.

outside3ds.transactionXId

String

Optional

@NotNull

Cardholder Authentication Verification Value. The transactionXId is the field that defines the 3DS version. The presence of this field in the HTTP request specifies that the transaction will be processed with 3DS 2.X. TransactionXId can be obtained by executing the /authentication method.

PLAIN_SENDER-DELAYED_RECEIVER(Email)
POST /client/delayed/send-money HTTP/1.1
Content-Type: application/json
Authorization: Basic bWVyY2hhbnQ6cGFzc3dvcmQ=
Host: java-staging.fenige.pl:8181
Content-Length: 945

{
  "amount" : 1000,
  "cvc2" : "123",
  "termUrl" : "https://termurl.pl",
  "merchantUrl" : "https://fenige.pl/payments",
  "addressIp" : "192.168.0.1",
  "type" : "SENDER",
  "outside3ds" : {
    "cavv" : "jEu04WZns7pbARAApU4qgNdJTag=",
    "cavvAlgorithm" : "02",
    "authenticationStatus" : "Y",
    "eci" : "02",
    "transactionXId" : "92166782-3731-4063-baad-914bc0bac337"
  },
  "requestId" : "38491db4-5d11-4328-bbe1-4f3c7545b563",
  "sender" : {
    "type" : "PLAIN",
    "firstName" : "Mark",
    "lastName" : "Smith",
    "street" : "Olszewskiego",
    "houseNumber" : "17A",
    "city" : "Lublin",
    "postalCode" : "20-400",
    "flatNumber" : "2",
    "email" : "senderEmail@fenige.pl",
    "currency" : "PLN",
    "cardNumber" : "5117964247989169",
    "expirationDate" : "03/23",
    "personalId" : "AGC688910"
  },
  "receiver" : {
    "type" : "DELAYED",
    "email" : "receiverEmail@fenige.pl",
    "currency" : "USD"
  }
}
Table 10. Delayed Send Money Request Fields
Path Type Validation Rule Description

amount

Number

Required

@NotNull, positive

The total transfer amount (in pennies).

cvc2

String

Required

@Length(min = 3, max = 3)

Sender card cvc2/cvv2.

type

String

Required

@NotNull

Transaction in 'SENDER' or 'RECEIVER' currency.

merchantUrl

String

Optional, mandatory from 2021-05-03

@Optional

Merchant identifier such as the business website URL or reverse domain name as presented to the consumer during checkout

addressIp

String

Optional mandatory from 2021-05-03, @Must match the regular expression ^([0-9]{1,3}.){3}[0-9]{1,3}$

@Optional

The IP address of the order of transaction

termUrl

String

Optional

@NotEmpty

Merchant URL to be redirected from Fenige after user login in the bank. This URL must accept order-id parameter, that tells which transaction is begin processed. The presence of this field in the HTTP request specifies that the transaction will be processed with 3DS 1.0.

requestId

String

Optional

@NotNull

128 bit number generated by the user, used to identify single transaction. Ensures that the transaction with the given parameter is processed only once.

sender

Object

Required

@NotNull

Personal data of Sender.

receiver

Object

Required

@NotNull

Personal data of Receiver.

outside3ds.cavv

String

Required

@NotNull

Cardholder Authentication Verification Value.

outside3ds.cavvAlgorithm

String

Optional

@NotNull

Indicates the algorithm used to generate the AuthenticationCAVV value 0 - HMAC 1 - CVV 2 - CVV with ATN 3 - MasterCard SPA algorithm.

outside3ds.eci

String

Required

@NotNull

Electronic Commerce Indicator: 5 (Visa) or 2 (SecureCode) - The cardholder was successfully authenticated. 6 (Visa) or 1 (SecureCode) - Authentication was attempted, but the cardholder was not enrolled. Chargeback protection applies.

outside3ds.authenticationStatus

String

Required

@NotNull

Authentication status. If AuthenticationStatus is "Y" or "A" then outside 3ds flow will be execute.

outside3ds.transactionXId

String

Optional

@NotNull

Cardholder Authentication Verification Value. The transactionXId is the field that defines the 3DS version. The presence of this field in the HTTP request specifies that the transaction will be processed with 3DS 2.X. TransactionXId can be obtained by executing the /authentication method.

4.1.4. Response

Response status
Status Description

200 OK

Delayed Send Money approved for processing and transaction details returned.

200 OK - Error validation

Returned list of field name which has validation errors.

202 Accepted

- Returned when the transaction with the provided requestId has been registered in the system, but has not yet been completed. The user can retry in a few seconds to get the transaction result. Response body: Empty
or
- Returned order-id when transaction will be processed.

400 Bad Request

Returned when request is incorrect, required fields are missing or the values are not valid.

500 Internal Server Error

Returned when user provides wrong order-id or transaction was failed or was Declined.

Example HTTP Response
200 OK When receiver is in database
HTTP/1.1 200 OK
Content-Type: application/json;charset=ISO-8859-1
Content-Length: 1080

{
  "amount" : 2000,
  "bigDecimalAmount" : 20.0,
  "commission" : 0,
  "bigDecimalCommission" : 0,
  "orderId" : "11b852df-8bd7-43f3-88ab-7369730780a3",
  "createdDate" : "09-11-2020, 21:12",
  "fundingRrn" : "031420000725",
  "paymentRrn" : "031420000725",
  "transactionStatus" : "APPROVED",
  "responseCode" : "CODE_00",
  "revaluationResult" : {
    "revaluationFundingAmount" : 2000,
    "bigDecimalRevaluationFundingAmount" : 20.0,
    "fundingCurrency" : "PLN",
    "revaluationPaymentAmount" : 2000,
    "bigDecimalRevaluationPaymentAmount" : 20.0,
    "paymentCurrency" : "PLN",
    "determineCurrencyRate" : {
      "from" : "PLN",
      "to" : "PLN",
      "currencyRate" : "1"
    }
  },
  "receiver" : {
    "firstName" : "Rob",
    "lastName" : "Wring",
    "hiddenCardNumber" : "511796******9169",
    "provider" : "MASTERCARD",
    "bankName" : "Alior Bank SA"
  },
  "sender" : {
    "firstName" : "Mark",
    "lastName" : "Smith",
    "hiddenCardNumber" : "511796******9169",
    "provider" : "MASTERCARD",
    "bankName" : "Alior Bank SA"
  },
  "3DS" : true
}

Response fields

Path Type Description

orderId

String

Unique transaction identifier.

transactionStatus

String

Transaction status.

responseCode

String

Response code.

amount

Number

Field informing about the amount of cash transferred in one hundredth of the currency. [1PLN = 100].

bigDecimalAmount

Number

Field informing about the amount of cash transferred with decimal precision.

commission

Number

This is the amount of commission that has been added to the transaction in hundredths. [1 PLN = 100].

bigDecimalCommission

Number

This is the amount of commission that was added to the transaction at 0.01 currency.

createdDate

String

Date of transaction.

fundingRrn

String

Funding Retrieval Reference Number.

paymentRrn

String

Payment Retrieval Reference Number.

revaluationResult.revaluationFundingAmount

Number

Amount (in pennies) of funding transaction in fundingCurrency.

revaluationResult.bigDecimalRevaluationFundingAmount

Number

Amount of funding transaction in fundingCurrency.

revaluationResult.fundingCurrency

String

Currency code the same as sender’s card currency.

revaluationResult.revaluationPaymentAmount

Number

Amount (in pennies) of payment transaction in paymentCurrency.

revaluationResult.bigDecimalRevaluationPaymentAmount

Number

Amount of payment transaction in paymentCurrency.

revaluationResult.paymentCurrency

String

Currency code the same as receiver’s card currency.

revaluationResult.determineCurrencyRate.from

String

Currency which was conversion from.

revaluationResult.determineCurrencyRate.to

String

Resulted currency.

revaluationResult.determineCurrencyRate.currencyRate

String

Currency rate.

3DS

Boolean

Value: true/false determines if transaction was processed with 3ds

receiver

Object

Personal data of the person to whom the transfer is addressed.

sender

Object

Personal data of the person who performs the transfer of cash.

200 OK When receiver is unknown
HTTP/1.1 200 OK
Content-Type: application/json;charset=ISO-8859-1
Content-Length: 943

{
  "amount" : 2000,
  "bigDecimalAmount" : 20.0,
  "commission" : 0,
  "bigDecimalCommission" : 0,
  "orderId" : "84a543cf-baf2-4cf2-9dc6-8ab39178ffac",
  "createdDate" : "09-11-2020, 21:12",
  "fundingRrn" : "031420000725",
  "transactionStatus" : "APPROVED_WAITING_FOR_RECEIVER",
  "responseCode" : "CODE_00",
  "revaluationResult" : {
    "revaluationFundingAmount" : 2000,
    "bigDecimalRevaluationFundingAmount" : 20.0,
    "fundingCurrency" : "PLN",
    "revaluationPaymentAmount" : 2000,
    "bigDecimalRevaluationPaymentAmount" : 20.0,
    "paymentCurrency" : "PLN",
    "determineCurrencyRate" : {
      "from" : "PLN",
      "to" : "PLN",
      "currencyRate" : "1"
    }
  },
  "receiver" : {
    "email" : "receiver@fenige.pl"
  },
  "sender" : {
    "firstName" : "Mark",
    "lastName" : "Smith",
    "hiddenCardNumber" : "511796******9169",
    "provider" : "MASTERCARD",
    "bankName" : "Alior Bank SA"
  },
  "3DS" : true
}

Response fields

Path Type Description

orderId

String

Unique transaction identifier.

transactionStatus

String

Transaction status.

responseCode

String

Response code.

amount

Number

Field informing about the amount of cash transferred in one hundredth of the currency. [1PLN = 100].

bigDecimalAmount

Number

Field informing about the amount of cash transferred with decimal precision.

commission

Number

This is the amount of commission that has been added to the transaction in hundredths. [1 PLN = 100].

bigDecimalCommission

Number

This is the amount of commission that was added to the transaction at 0.01 currency.

createdDate

String

Date of transaction.

fundingRrn

String

Funding Retrieval Reference Number.

revaluationResult.revaluationFundingAmount

Number

Amount (in pennies) of funding transaction in fundingCurrency.

revaluationResult.bigDecimalRevaluationFundingAmount

Number

Amount of funding transaction in fundingCurrency.

revaluationResult.fundingCurrency

String

Currency code the same as sender’s card currency.

revaluationResult.revaluationPaymentAmount

Number

Amount (in pennies) of payment transaction in paymentCurrency.

revaluationResult.bigDecimalRevaluationPaymentAmount

Number

Amount of payment transaction in paymentCurrency.

revaluationResult.paymentCurrency

String

Currency code the same as receiver’s card currency.

revaluationResult.determineCurrencyRate.from

String

Currency which was conversion from.

revaluationResult.determineCurrencyRate.to

String

Resulted currency.

revaluationResult.determineCurrencyRate.currencyRate

String

Currency rate.

3DS

Boolean

Value: true/false determines if transaction was processed with 3ds

receiver

Object

Personal data of the person to whom the transfer is addressed.

sender

Object

Personal data of the person who performs the transfer of cash.

400 Bad request
HTTP/1.1 400 Bad Request
Content-Type: application/json;charset=ISO-8859-1
Content-Length: 104

{
  "error" : {
    "status" : "ERROR_INVALID_JSON",
    "message" : "Some properties are invalid"
  }
}
500 Internal Server Error
HTTP/1.1 500 Internal Server Error
Content-Type: text/plain;charset=ISO-8859-1
{
    “status”: “ERROR_FUNDING_FAILED”,
    “error”: {
        “message”: “FUNDING_TRANSACTION_DECLINED:CODE_05”
    }
}

After receiving these statuses, the transaction was rejected

Error statuses

Name Description

FUNDING_TRANSACTION_DECLINED:CODE_XX, PAYMENT_TRANSACTION_DECLINED:CODE_XX

CODE_XX - is MasterCard response code (ISO 8583)

ISSUER_NOT_SUPPORTED

This card is not supported

ERROR_CARD_IS_BLOCKED

Card is blocked for 1 hour in Fenige

ERROR_USER_IS_BLOCKED

User is blocked in Fenige

ERROR_BIN_IS_BLOCKED

Bin is blocked for 1 hour in Fenige

ERROR_FUNDING_BANK_IS_BLOCKED

Funding bank is blocked in Fenige

ERROR_PAYMENT_BANK_IS_BLOCKED

Payment bank is blocked in Fenige

FUNDING_TRANSACTION_DECLINED:ACQ_ERROR

Funding transaction was declined and payment not send

PAYMENT_TRANSACTION_DECLINED:ACQ_ERROR

Payment transaction was declined and funding was reversed

ERROR_ACQ_CONNECTION

A connection error occurred to Acquirer service

AML_ERROR

User was found on the stop list

NETWORK_ERROR

Acceptance network is unavailable

CURRENCY_RATES_NOT_FOUND

No currently effective rates found in the database

CURRENCY_NOT_SUPPORTED

Currency is not supported

MERCHANT_CURRENCY_NOT_SUPPORTED

Currency is not supported by Merchant

ERROR_DAILY_CUMULATIVE_LIMIT

Daily cumulative limit per card was exceeded

ERROR_MONTHLY_CUMULATIVE_LIMIT

Monthly cumulative limit per card was exceeded

ERROR_MERCHANT_MASTERCARD_DAILY_CUMULATIVE_LIMIT

Daily cumulative limit per merchant transactions using mastercard cards was exceeded

ERROR_MERCHANT_MASTERCARD_MONTHLY_CUMULATIVE_LIMIT

Monthly cumulative limit per merchant transactions using mastercard cards was exceeded

ERROR_MERCHANT_VISA_DAILY_CUMULATIVE_LIMIT

Daily cumulative limit per merchant transactions using visa cards was exceeded

ERROR_MERCHANT_VISA_MONTHLY_CUMULATIVE_LIMIT

Monthly cumulative limit per merchant transactions using visa cards was exceeded

ERROR_SENDER_CARD_IS_BLOCKED

Sender’s card is blocked

ERROR_RECEIVER_CARD_IS_BLOCKED

Receiver’s card is blocked

ERROR_SENDER_USER_IS_BLOCKED

User acting as sender is blocked

ERROR_RECEIVER_USER_IS_BLOCKED

User acting as receiver is blocked

ERROR_SENDER_BIN_IS_BLOCKED

BIN of sender’s card is blocked

ERROR_RECEIVER_BIN_IS_BLOCKED

BIN of receiver’s card is blocked

ERROR_AMOUNT_IS_BLOCKED

Amount is higher than acceptable limit

ERROR_MONITORING_CONNECTION

Couldn’t established connection to Monitoring service

ERROR_MONITORING_UNAUTHORIZED

Error with service authorization occurred

ERROR_MONITORING

Some unrecognized error occurred

ERROR_MPI_CONNECTION

Couldn’t established connection to MPI service

FUNDING_TRANSACTION_DECLINED:MIP_RESPONSE_TIMEOUT

Funding transaction declined - mip response timeout

PAYMENT_TRANSACTION_DECLINED:MIP_RESPONSE_TIMEOUT

Payment transaction declined - mip response timeout

FUNDING_TRANSACTION_DECLINED:NEED_MANUAL_VERIFICATION

Funding process failed and it is need to manual verification of transaction

PAYMENT_TRANSACTION_DECLINED:NEED_MANUAL_VERIFICATION

Payment process failed and it is need to manual verification of transaction

FUNDING_TRANSACTION_DECLINED:MIP_PROXY_RESPONSE_TIMEOUT

Funding transaction declined - mip_proxy response timeout

PAYMENT_TRANSACTION_DECLINED:MIP_PROXY_RESPONSE_TIMEOUT

Payment transaction declined - mip_proxy response timeout

ERROR_NO_3DS_AUTHORIZATION

Error no 3ds authorization, when User authenticates successfully but after 15 minutes or User doesn’t authenticate.

ERROR_MPI_STATUS_TO_LOW: Initialize/Finalize: U/N

Error occurs, when merchant configuration allows only for attempted or full authenticated 3DS transactions with mpi status 'A' or 'Y' but mpi service has returned other status e.g. 'N' or 'U' at any stage of the transaction.

ERROR_TRANSACTION_NOT_FOUND

Error transaction not exists

ERROR_VALIDATION

Some validation error occurred

ERROR_SOMETHING_WRONG

An unrecognized error occurred

200 OK - Error validation
HTTP/1.1 200 OK
Content-Type: application/json;charset=ISO-8859-1

{
	"status" : "ERROR_VALIDATION",
	"error" : {
		"message": "Some information is missing or incorrect.",
		"errors": [{
				"field": "requestId",
				"message": [
					"may not be null"
				]
			},
			{
				"field": "cvc2",
				"message": [
					"may not be null",
					"length must be 3"
				]
			},
			{
				"field": "type",
				"message": [
					"may not be null"
				]
			},
			{
				"field": "amount",
				"message": [
					"may not be null"
				]
			},
			{
				"field": "sender",
				"message": [
					"may not be null"
				]
			},
			{
				"field": "sender.cardNumber",
				"message": [
					"may not be null",
					"may not be empty",
					"card number length must be 16"
				]
			},
			{
				"field": "sender.expirationDate",
				"message": [
					"invalid card expiration date",
					"may not be null",
					"may not be empty"
				]
			},
			{
				"field": "sender.city",
				"message": [
					"may not be empty",
					"may not be null",
					"length must be between 1 and 25"
				]
			},
			{
				"field": "sender.street",
				"message": [
					"may not be null",
					"may not be empty",
					"length must be between 1 and 50"
				]
			},
            {
				"field": "sender.postalCode",
				"message": [
					"may not be empty",
					"may not be null",
					"length must be between 1 and 10"
				]
			},
            {
                "field": "sender.flatNumber",
                "message": [
                    "must be null",
                    "length must be between 0 and 5"
                ]
            },
			{
				"field": "sender.lastName",
				"message": [
					"may not be empty",
					"may not be null",
					"length must be between 2 and 35"
				]
			},
			{
				"field": "sender.houseNumber",
				"message": [
					"may not be empty",
					"may not be null",
					"length must be between 1 and 10"
				]
			},
			{
				"field": "sender.firstName",
				"message": [
					"may not be empty",
					"may not be null",
					"length must be between 2 and 35"
				]
			},
            {
				"field": "sender.email",
				"message": [
					"may not be empty",
					"may not be null",
					"not a well-formed email address",
					"lenght must be beetween 1 and 128"
				]
			},
			{
				"field": "receiver",
				"message": [
					"may not be null"
				]
			},

			{
				"field": "receiver.currency",
				"message": [
					"may not be null"
				]
			},
			{
				"field": "receiver.phoneNumber",
				"message": [
					"may not be null",
					"may not be empty"
				]
			},
            {
				"field": "receiver.email",
				"message": [
					"may not be null",
					"may not be empty"
				]
			},
            {
                "field": "receiver",
                "message": [
                    "Phone number or email must be present"
                ]
            },
			{
                "field": "sender",
                "message": [
                     "province is mandatory only if country code is US or CA"
                ]
            },
            {
                "field": "sender.province",
                "message": [
                      "is not correct province code for country code US",
                      "may not be null"
                ]
            },
            {
                "field": "sender.province",
                 "message": [
                       "may not be null",
                       "is not correct province code for country code CA"
                 ]
            },
            {
                 "field": "sender.province",
                 "message": [
                        "must match ^[A-Z]{2}$",
                        "is not correct province code for country code US"
                 ]
            },
            {
                 "field": "sender.currency",
                 "message": [
                       "Currency is not supported"
                ]
            },
            {
                 "field": "receiver.currency",
                 "message": [
                       "Currency is not supported"
                ]
            }
		]
	}
}
Errors mentioned below may occur if card’s country is other than user’s country for USA or CAN transaction
HTTP/1.1 200 OK
Content-Type: application/json

{
    "status": "ERROR_WHILE_VALIDATING_CARD_COUNTRY_CODE_AND_USER_COUNTRY_CODE_FOR_PLAIN",
    "error": {
        "message": "Card country code not compatible with user country code. Please update country in request."
    }
}
HTTP/1.1 200 OK
Content-Type: application/json

{
    "status": "ERROR_WHILE_VALIDATING_CARD_COUNTRY_CODE_AND_USER_COUNTRY_CODE",
    "error": {
        "message": "Card country code not compatible with user country code. Please update user profile."
    }
}
HTTP/1.1 200 OK
Content-Type: application/json

{
    "status": "ERROR_WHILE_GETTING_COUNTRY_CODE",
    "error": {
        "message": "Could not get card country code"
    }
}
HTTP/1.1 200 OK
Content-Type: application/json

{
    "status": "ERROR_WHILE_VALIDATING_PROVINCE_NOT_CORRECT_PROVINCE_CODE",
    "error": {
        "message": "Province code is not valid province code. Please update user profile"
    }
}
Error described bellow may occur when merchant tries to make transaction in other model than assigned primarily. For example, if merchant’s model is set as Card-Card and then merchant will try to make transaction in Cash-Card model, will receive error as bellow.
HTTP/1.1 200 OK
Content-Type: application/json;charset=ISO-8859-1

{
    "status": "ERROR_VALIDATION",
    "error": {
        "message": "Some information is missing or incorrect.",
        "errors": [
            {
                "field": "sender.type",
                "message": [
                    "Sender type violates merchant model"
                ]
            }
        ]
    }
}
Errors below may occur when a merchant uses a sender card or a receiver card issued in a country that is on the list of countries High Risk excluded from the Fenige API transactions. The transaction is treated as high risk and rejected. Please contact support.
HTTP/1.1 200 OK
Content-Type: application/json;charset=ISO-8859-1

{
    "status": "ERROR_MERCHANT_FUNDING_CARD_COUNTRY_RESTRICTED",
    "error": {
        "message": "Restricted funding card country was used."
    }
}
HTTP/1.1 200 OK
Content-Type: application/json;charset=ISO-8859-1

{
    "status": "ERROR_MERCHANT_PAYMENT_CARD_COUNTRY_RESTRICTED",
    "error": {
        "message": "Restricted payment card country was used."
    }
}
Errors mentioned below may occur if sender firstName and lastName are the same
HTTP/1.1 200 OK
Content-Type: application/json

{
    "status": "ERROR_VALIDATION",
    "error": {
        "message": "Some information is missing or incorrect.",
        "errors": [
            {
                "field": "sender.firstName",
                "message": [
                    "invalid sender firstName and lastName the same"
                ]
            }
        ]
    }
}
Errors mentioned below may occur if sender firstName or lastName contains all the same characters
HTTP/1.1 200 OK
Content-Type: application/json

{
    "status": "ERROR_VALIDATION",
    "error": {
        "message": "Some information is missing or incorrect.",
        "errors": [
            {
                "field": "sender.firstName",
                "message": [
                    "invalid sender firstName contains all the same characters"
                ]
            }
        ]
    }
}
{
    "status": "ERROR_VALIDATION",
    "error": {
        "message": "Some information is missing or incorrect.",
        "errors": [
            {
                "field": "sender.lastName",
                "message": [
                    "invalid sender lastName contains all the same characters"
                ]
            }
        ]
    }
}
403 FORBIDDEN
HTTP Response - Error
{
    "timestamp": 1610464313387,
    "status": 403,
    "error": "Forbidden",
    "message": "No message available",
    "path": "/client/delayed/send-money"
}

4.2. Delayed Payment

POST /client/delayed/payment Content-Type: application/json, Authorization: Basic Auth, API-TOKEN*
The Delayed Payment method is used to send the Receiver's data and finalize the transaction flow. In order to make this Payment, user must do Funding firstly.
In response to Funding, we get an 'orderId' field, which we must use in the Delayed Payment request's body.
If the Funding has not been completed or if the Funding has already been completed (with success or with failure), Payment will not be processed.
The maximum time for the execution of Delayed Payment after earlier calling Delayed Send Money is 12 hours. After 12 hours after Funding without Payment, it will be reversed and sender will get their funds back. Your server will receive Webhook Event after Reversal Funding if webhook is enabled in your merchant configuration.
There is 3 attempts to execute Delayed Payment after earlier call Delayed Send Money.

4.2.1. Delayed Payment Examples

DELAYED_PAYMENT_REMEMBER_RECEIVER
DP PAYMENT DELAYED RECEIVER REMEMBER
DELAYED_PAYMENT_NOT_REMEMBER_RECEIVER
DP PAYMENT DELAYED RECEIVER NOT REMEMBER
Example HTTP Request
VISA(Phone)
POST /client/delayed/payment HTTP/1.1
Content-Type: application/json
Authorization: Basic bWVyY2hhbnQ6cGFzc3dvcmQ=
Host: java-staging.fenige.pl:8181
Content-Length: 370

{
  "orderId" : "1cd73a3c-26e9-4d92-8e76-1c883b4bdaae",
  "receiver" : {
    "type" : "DELAYED",
    "firstName" : "Rob",
    "lastName" : "Wring",
    "cardNumber" : "4485909148265810",
    "currency" : "PLN",
    "rememberReceiver" : false,
    "phoneNumber" : "48560740349",
    "expirationDate" : "10/24"
  },
  "requestId" : "1cd73a3c-26e9-4d92-8e76-1c883b4bdaae"
}
Table 11. Delayed Payment Request Fields
Path Type Validation Rule Description

orderId

String

Required

@NotNull

Unique transaction identifier.

requestId

String

Optional

@Uuid

128 bit number generated by the user, used to identify single transaction. Ensures that the transaction with the given parameter is processed only once.

receiver.type

String

Required

@NotNull

For this configuration the value of this field must be "DELAYED", otherwise request will be declined.

receiver.firstName

String

Required

@NotNull

Receiver first name.

receiver.lastName

String

Required

@NotNull

Receiver last name.

receiver.cardNumber

String

Required

@NotNull

Receiver card number.

receiver.currency

String

Required

@NotNull

Currency for transaction. Example: PLN.

receiver.phoneNumber

String

Required

@NotNull

Receiver phone number.

receiver.expirationDate

String

Required

@NotNull

Receiver card expiration date. Example: 11/21.

receiver.rememberReceiver

Boolean

Required

@NotNull

By sending this field as 'true' value you can save receiver.

MASTERCARD(Phone)
POST /client/delayed/payment HTTP/1.1
Content-Type: application/json
Authorization: Basic bWVyY2hhbnQ6cGFzc3dvcmQ=
Host: java-staging.fenige.pl:8181
Content-Length: 338

{
  "orderId" : "cdac5f31-d1eb-4dc8-b029-c99bdec5bcb1",
  "receiver" : {
    "type" : "DELAYED",
    "firstName" : "Rob",
    "lastName" : "Wring",
    "cardNumber" : "5117964247989169",
    "currency" : "PLN",
    "rememberReceiver" : false,
    "phoneNumber" : "48560740349"
  },
  "requestId" : "cdac5f31-d1eb-4dc8-b029-c99bdec5bcb1"
}
Table 12. Delayed Payment Request Fields
Path Type Validation Rule Description

orderId

String

Required

@NotNull

Unique transaction identifier.

requestId

String

Optional

@Uuid

128 bit number generated by the user, used to identify single transaction. Ensures that the transaction with the given parameter is processed only once.

receiver.type

String

Required

@NotNull

For this configuration the value of this field must be "DELAYED", otherwise request will be declined.

receiver.firstName

String

Required

@NotNull

Receiver first name.

receiver.lastName

String

Required

@NotNull

Receiver last name.

receiver.cardNumber

String

Required

@NotNull

Receiver card number.

receiver.currency

String

Required

@NotNull

Currency for transaction. Example: PLN.

receiver.phoneNumber

String

Required

@NotNull

Receiver phone number.

receiver.rememberReceiver

Boolean

Required

@NotNull

By sending this field as 'true' value you can save receiver.

VISA(Email)
POST /client/delayed/payment HTTP/1.1
Content-Type: application/json
Authorization: Basic bWVyY2hhbnQ6cGFzc3dvcmQ=
Host: java-staging.fenige.pl:8181
Content-Length: 372

{
  "orderId" : "c349b308-8b08-4535-83fd-2970252bab2c",
  "receiver" : {
    "type" : "DELAYED",
    "firstName" : "Rob",
    "lastName" : "Wring",
    "email" : "rob.wring@fenige.pl",
    "cardNumber" : "4485909148265810",
    "currency" : "PLN",
    "rememberReceiver" : false,
    "expirationDate" : "10/24"
  },
  "requestId" : "c349b308-8b08-4535-83fd-2970252bab2c"
}
Table 13. Delayed Payment Request Fields
Path Type Validation Rule Description

orderId

String

Required

@NotNull

Unique transaction identifier.

requestId

String

Optional

@Uuid

128 bit number generated by the user, used to identify single transaction. Ensures that the transaction with the given parameter is processed only once.

receiver.type

String

Required

@NotNull

For this configuration the value of this field must be "DELAYED", otherwise request will be declined.

receiver.firstName

String

Required

@NotNull

Receiver first name.

receiver.lastName

String

Required

@NotNull

Receiver last name.

receiver.email

String

Required

@NotNull

Receiver email.

receiver.cardNumber

String

Required

@NotNull

Receiver card number.

receiver.currency

String

Required

@NotNull

Currency for transaction. Example: PLN.

receiver.expirationDate

String

Required

@NotNull

Receiver card expiration date. Example: 11/21.

receiver.rememberReceiver

Boolean

Required

@NotNull

By sending this field as 'true' value you can save receiver.

MASTERCARD(Email)
POST /client/delayed/payment HTTP/1.1
Content-Type: application/json
Authorization: Basic bWVyY2hhbnQ6cGFzc3dvcmQ=
Host: java-staging.fenige.pl:8181
Content-Length: 340

{
  "orderId" : "5d98f282-0624-417a-9c1e-95a6967a5404",
  "receiver" : {
    "type" : "DELAYED",
    "firstName" : "Rob",
    "lastName" : "Wring",
    "email" : "rob.wring@fenige.pl",
    "cardNumber" : "5117964247989169",
    "currency" : "PLN",
    "rememberReceiver" : false
  },
  "requestId" : "5d98f282-0624-417a-9c1e-95a6967a5404"
}
Table 14. Delayed Payment Request Fields
Path Type Validation Rule Description

orderId

String

Required

@NotNull

Unique transaction identifier.

requestId

String

Optional

@Uuid

128 bit number generated by the user, used to identify single transaction. Ensures that the transaction with the given parameter is processed only once.

receiver.type

String

Required

@NotNull

For this configuration the value of this field must be "DELAYED", otherwise request will be declined.

receiver.firstName

String

Required

@NotNull

Receiver first name.

receiver.lastName

String

Required

@NotNull

Receiver last name.

receiver.email

String

Required

@NotNull

Receiver email.

receiver.cardNumber

String

Required

@NotNull

Receiver card number.

receiver.currency

String

Required

@NotNull

Currency for transaction. Example: PLN.

receiver.rememberReceiver

Boolean

Required

@NotNull

By sending this field as 'true' value you can save receiver.

4.2.2. Response

Response status

Status

Description

200 OK

Delayed Send Money approved for processing and transaction details returned.

400 Bad Request

Returned when request is incorrect, required fields are missing or the values are not valid.

500 Internal Server Error

Returned when user provides wrong order-id or transaction was failed or was Declined.

Example HTTP Response
200 OK
HTTP/1.1 200 OK
Content-Type: application/json;charset=UTF-8
Content-Length: 1069

{
  "amount" : 2000,
  "amountInUsDollar" : 537,
  "bigDecimalAmount" : 20.0,
  "commission" : 0,
  "bigDecimalCommission" : 0,
  "orderId" : "a29de4fa-aa6d-4358-b583-dfef6e56ad26",
  "fundingRrn" : "031420000725",
  "paymentRrn" : "031420000726",
  "revaluationResult" : {
    "revaluationFundingAmount" : 2000,
    "bigDecimalRevaluationFundingAmount" : 20.0,
    "fundingCurrency" : "PLN",
    "revaluationPaymentAmount" : 2000,
    "bigDecimalRevaluationPaymentAmount" : 20.0,
    "paymentCurrency" : "PLN",
    "determineCurrencyRate" : {
      "from" : "PLN",
      "to" : "PLN",
      "currencyRate" : "1"
    }
  },
  "receiver" : {
    "firstName" : "Rob",
    "lastName" : "Wring",
    "provider" : "MASTERCARD",
    "hiddenCardNumber" : "511796******9169",
    "bankName" : "Alior Bank SA"
  },
  "sender" : {
    "firstName" : "Mark",
    "lastName" : "Smith",
    "provider" : "MASTERCARD",
    "hiddenCardNumber" : "511796******9169",
    "bankName" : "Alior Bank SA"
  },
  "transactionStatus" : "approved",
  "responseCode" : "CODE_00",
  "3DS" : true
}

Response fields

Path Type Description

orderId

String

Unique transaction identifier.

transactionStatus

String

Transaction status.

responseCode

String

Response code.

amount

Number

Field informing about the amount of cash transferred in one hundredth of the currency. [1PLN = 100]

amountInUsDollar

Number

Field informing about the amount of cash transferred in one hundredth of the USD currency. [1USD = 100]

bigDecimalAmount

Number

Field informing about the amount of cash transferred with decimal precision.

commission

Number

This is the amount of commission that has been added to the transaction in hundredths. [1 PLN = 100]

bigDecimalCommission

Number

This is the amount of commission that was added to the transaction at 0.01 currency.

fundingRrn

String

Funding Retrieval Reference Number.

paymentRrn

String

Payment Retrieval Reference Number.

3DS

Boolean

Value: true/false determines if transaction was processed with 3ds

revaluationResult.revaluationFundingAmount

Number

Amount (in pennies) of funding transaction in fundingCurrency.

revaluationResult.bigDecimalRevaluationFundingAmount

Number

Amount of funding transaction in fundingCurrency.

revaluationResult.fundingCurrency

String

Currency code the same as sender’s card currency

revaluationResult.revaluationPaymentAmount

Number

Amount (in pennies) of payment transaction in paymentCurrency.

revaluationResult.bigDecimalRevaluationPaymentAmount

Number

Amount of payment transaction in paymentCurrency.

revaluationResult.paymentCurrency

String

Currency code the same as receiver’s card currency.

revaluationResult.determineCurrencyRate.from

String

Currency which was conversion from.

revaluationResult.determineCurrencyRate.to

String

Resulted currency.

revaluationResult.determineCurrencyRate.currencyRate

String

Currency rate.

receiver

Object

Personal data of the person to whom the transfer is addressed.

sender

Object

Personal data of the person who performs the transfer of cash.

400 Bad request
HTTP/1.1 400 BAD REQUEST
Content-Type: application/json;charset=ISO-8859-1
Content-Length: 104

{
  "error" : {
    "status" : "ERROR_INVALID_JSON",
    "message" : "Some properties are invalid"
  }
}
Errors mentioned below may occur if receiver firstName and lastName are the same
HTTP/1.1 400 BAD REQUEST
Content-Type: application/json
{
    "status": "ERROR_VALIDATION",
    "error": {
        "message": "Some information is missing or incorrect.",
        "errors": [
            {
                "field": "receiver.firstName",
                "message": [
                    "invalid receiver firstName and lastName the same"
                ]
            }
        ]
    }
}
Errors mentioned below may occur if receiver firstName or lastName contains all the same characters
HTTP/1.1 400 BAD REQUEST
Content-Type: application/json
{
    "status": "ERROR_VALIDATION",
    "error": {
        "message": "Some information is missing or incorrect.",
        "errors": [
            {
                "field": "receiver.firstName",
                "message": [
                    "invalid receiver firstName contains all the same characters"
                ]
            }
        ]
    }
}
HTTP/1.1 400 BAD REQUEST
Content-Type: application/json
{
    "status": "ERROR_VALIDATION",
    "error": {
        "message": "Some information is missing or incorrect.",
        "errors": [
            {
                "field": "receiver.lastName",
                "message": [
                    "invalid receiver lastName contains all the same characters"
                ]
            }
        ]
    }
}
Errors mentioned below may occur if sender email is equal to receiver email, but firstName and lastName data are different
HTTP/1.1 400 BAD REQUEST
Content-Type: application/json
{
    "status": "ERROR_VALIDATION",
    "error": {
        "message": "Some information is missing or incorrect.",
        "errors": [
            {
                "field": "sender.email",
                "message": [
                    "invalid sender and receiver email the same for different person"
                ]
            }
        ]
    }
}
500 Internal Server Error
HTTP/1.1 500 Internal Server Error
Content-Type: text/plain;charset=ISO-8859-1
{
"status" : "PAYMENT_TRANSACTION_DECLINED:CODE_05"
}

After receiving these statuses, the transaction was rejected

Error statuses

Name Description Allow to try again

WAITING_FOR_RECEIVER_TIMEOUT

The time of 12 hours has been exceeded

No

ERROR_DELAYED_PAYMENT_ATTEMPTS_EXCEEDED

The number of 3 payment attempts has been exceeded

No

ERROR_DELAYED_PAYMENT_TRX_NOT_REGISTERED_FOR_DELAYED_PROCESSING

Payment of transaction was not registered for delayed processing. Cannot process payment

No

ERROR_DELAYED_PAYMENT_NOT_FOUND

There is no Delayed Payment with given orderId

No

ERROR_DELAYED_PAYMENT_RECEIVER_NOT_PRESENT

There is no receiver with given phone or email.

Yes

PAYMENT_TRANSACTION_DECLINED:CODE_XX

CODE_XX - is MasterCard response code (ISO 8583)

Yes

ISSUER_NOT_SUPPORTED

This card is not supported

Yes

ERROR_CARD_IS_BLOCKED

Card is blocked for 1 hour in Fenige

Yes

ERROR_USER_IS_BLOCKED

User is blocked in Fenige

Yes

ERROR_BIN_IS_BLOCKED

Bin is blocked for 1 hour in Fenige

Yes

ERROR_PAYMENT_BANK_IS_BLOCKED

Payment bank is blocked in Fenige

Yes

PAYMENT_TRANSACTION_DECLINED:ACQ_ERROR

Payment transaction was declined and funding was reversed

Yes

ERROR_ACQ_CONNECTION

A connection error occurred to Acquirer service

Yes

AML_ERROR

User was found on the stop list

Yes

NETWORK_ERROR

Acceptance network is unavailable

Yes

CURRENCY_RATES_NOT_FOUND

No currently effective rates found in the database

Yes

CURRENCY_NOT_SUPPORTED

Currency is not supported

Yes

MERCHANT_CURRENCY_NOT_SUPPORTED

Currency is not supported by Merchant

Yes

ERROR_RECEIVER_CARD_IS_BLOCKED

Receiver’s card is blocked

Yes

ERROR_RECEIVER_USER_IS_BLOCKED

User acting as receiver is blocked

Yes

ERROR_RECEIVER_BIN_IS_BLOCKED

BIN of receiver’s card is blocked

Yes

ERROR_AMOUNT_IS_BLOCKED

Amount is higher than acceptable limit

Yes

ERROR_MONITORING_CONNECTION

Couldn’t established connection to Monitoring service

Yes

ERROR_MONITORING_UNAUTHORIZED

Error with service authorization occurred

Yes

ERROR_MONITORING

Some unrecognized error occurred

Yes

ERROR_USER_VERIFICATION

The transaction user’s personal data verified as incorrect on the verification service. Transaction rejected.

No

ERROR_MPI_CONNECTION

Couldn’t established connection to MPI service

Yes

PAYMENT_TRANSACTION_DECLINED:MIP_RESPONSE_TIMEOUT

Payment transaction declined - mip response timeout

Yes

PAYMENT_TRANSACTION_DECLINED:NEED_MANUAL_VERIFICATION

Payment process failed and it is need to manual verification of transaction

Yes

PAYMENT_TRANSACTION_DECLINED:MIP_PROXY_RESPONSE_TIMEOUT

Payment transaction declined - mip_proxy response timeout

Yes

ERROR_TRANSACTION_NOT_FOUND

Error transaction not exists

Yes

ERROR_VALIDATION

Some validation error occurred

Yes

ERROR_SOMETHING_WRONG

An unrecognized error occurred

Yes

4.3. Transaction history

GET /client/{clientId}/transactions?page=0&size=100 Content Type: application/json, Authorization: Basic Auth
Method return page with list of user transactions. Transactions are filtered by clientId provided in GET parameter.
User can send additional optional parameters (page, size) to obtain given page with defined size.

4.3.1. Request

GET /client/0/transactions?fromDate=2018-03-06&toDate=2018-03-08&page=0&size=100 HTTP/1.1
Content-Type: application/json
Authorization: Basic bWVyY2hhbnQ6cGFzc3dvcmQ=
Host: java-staging.fenige.pl:8181

4.3.2. Response

Response status
Status Description

200 OK

Returned list of transactions history.

404 NOT FOUND

Returning the list failed.

Example Response
200 OK - phone receiver
HTTP/1.1 200 OK
Content-Type: application/json;charset=UTF-8
Content-Length: 994

{
  "content" : [ {
    "correlationId" : "2c73f2b2-aaa2-40b5-ad1a-b73171dcacf8",
    "createdDate" : "2018-03-15T10:24:52.149Z",
    "amount" : 15000,
    "amountInUsDollar" : 4024,
    "textAmount" : "150.00 PLN",
    "currency" : "PLN",
    "cardId" : 3574,
    "receiverFirstName" : "Patrick",
    "receiverLastName" : "Evans",
    "receiverHiddenCardNumber" : "511123******1234",
    "receiverProvider" : "MASTERCARD",
    "receiverBankName" : "Bank Polska Kasa Opieki Spółka Akcyjna",
    "receiverPhone" : "600300200",
    "senderFirstName" : "Rob",
    "senderLastName" : "Wring",
    "senderHiddenCardNumber" : "522212******4321",
    "senderProvider" : "MASTERCARD",
    "senderBankName" : "Alior Bank SA",
    "status" : "approved",
    "3DS" : false
  } ],
  "pageable" : "INSTANCE",
  "last" : true,
  "totalPages" : 1,
  "totalElements" : 1,
  "first" : true,
  "sort" : {
    "sorted" : false,
    "unsorted" : true
  },
  "numberOfElements" : 1,
  "size" : 0,
  "number" : 0
}

Response fields

Path Type Description

content.[].correlationId

String

Unique UUID describing single transaction in system.

content.[].createdDate

String

Date of transaction processing.

content.[].amount

Number

Transaction amount in pennies.

content.[].amountInUsDollar

Number

Transaction amount in USD currency in pennies.

content.[].textAmount

String

Transaction amount with currency.

content.[].currency

String

Transaction currency.

content.[].cardId

Number

Datacore card id used in transaction (sender card).

content.[].3DS

Boolean

Value: true/false determines if transaction was processed with 3ds

content.[].receiverFirstName

String

Transaction receiver first name.

content.[].receiverLastName

String

Transaction receiver last name.

content.[].receiverHiddenCardNumber

String

Transaction receiver hidden card number.

content.[].receiverProvider

String

VISA or MASTERCARD or MAESTRO

content.[].receiverBankName

String

Transaction receiver card bank name.

content.[].senderFirstName

String

Transaction sender first name.

content.[].senderLastName

String

Transaction sender last name.

content.[].senderHiddenCardNumber

String

Transaction sender hidden card numbe.

content.[].senderProvider

String

VISA or MASTERCARD or MAESTRO

content.[].senderBankName

String

Transaction sender card bank name.

content.[].receiverPhone

String

Transaction receiver phone number.

content.[].status

String

Status of the transaction (approved, reversed, rejected).

last

Boolean

Describes whether the page is last (true ot false).

totalPages

Number

Total number of all pages.

totalElements

Number

Total number of all transactions.

numberOfElements

Number

Number of transactions on page.

first

Boolean

Describes whether the page is first (true ot false).

sort

Object

Details of sort.

size

Number

Max number of transactions on page.

number

Number

Page number.

pageable

String

Requested page information.

200 OK - email receiver
HTTP/1.1 200 OK
Content-Type: application/json;charset=UTF-8
Content-Length: 1002

{
  "content" : [ {
    "correlationId" : "7493029a-780c-4bee-a1d4-f286a6f005e9",
    "createdDate" : "2018-03-15T10:24:52.149Z",
    "amount" : 15000,
    "amountInUsDollar" : 4024,
    "textAmount" : "150.00 PLN",
    "currency" : "PLN",
    "cardId" : 3574,
    "receiverFirstName" : "Patrick",
    "receiverLastName" : "Evans",
    "receiverHiddenCardNumber" : "511123******1234",
    "receiverProvider" : "MASTERCARD",
    "receiverBankName" : "Bank Polska Kasa Opieki Spółka Akcyjna",
    "receiverEmail" : "receiver@fenige.pl",
    "senderFirstName" : "Rob",
    "senderLastName" : "Wring",
    "senderHiddenCardNumber" : "522212******4321",
    "senderProvider" : "MASTERCARD",
    "senderBankName" : "Alior Bank SA",
    "status" : "approved",
    "3DS" : true
  } ],
  "pageable" : "INSTANCE",
  "last" : true,
  "totalPages" : 1,
  "totalElements" : 1,
  "first" : true,
  "sort" : {
    "sorted" : false,
    "unsorted" : true
  },
  "numberOfElements" : 1,
  "size" : 0,
  "number" : 0
}

Response fields

Path Type Description

content.[].correlationId

String

Unique UUID describing single transaction in system.

content.[].createdDate

String

Date of transaction processing.

content.[].amount

Number

Transaction amount in pennies.

content.[].amountInUsDollar

Number

Transaction amount in USD currency in pennies.

content.[].textAmount

String

Transaction amount with currency.

content.[].currency

String

Transaction currency.

content.[].cardId

Number

Datacore card id used in transaction (sender card).

content.[].3DS

Boolean

Value: true/false determines if transaction was processed with 3ds

content.[].receiverFirstName

String

Transaction receiver first name.

content.[].receiverLastName

String

Transaction receiver last name.

content.[].receiverHiddenCardNumber

String

Transaction receiver hidden card number.

content.[].receiverProvider

String

VISA or MASTERCARD or MAESTRO

content.[].receiverBankName

String

Transaction receiver card bank name.

content.[].senderFirstName

String

Transaction sender first name.

content.[].senderLastName

String

Transaction sender last name.

content.[].senderHiddenCardNumber

String

Transaction sender hidden card number.

content.[].senderProvider

String

VISA or MASTERCARD or MAESTRO

content.[].senderBankName

String

Transaction sender card bank name.

content.[].receiverEmail

String

Transaction receiver email.

content.[].status

String

Status of the transaction (approved, reversed, rejected).

last

Boolean

Describes whether the page is last (true ot false).

totalPages

Number

Total number of all pages.

totalElements

Number

Total number of all transactions.

numberOfElements

Number

Number of transactions on page.

first

Boolean

Describes whether the page is first (true ot false).

sort

Object

Details of sort.

size

Number

Max number of transactions on page.

number

Number

Page number.

pageable

String

Requested page information.

200 OK - phone receiver (funding only)
HTTP/1.1 200 OK
Content-Type: application/json;charset=UTF-8
Content-Length: 762

{
  "content" : [ {
    "correlationId" : "b4797c03-e7da-4e9f-b685-cf3304e953c2",
    "createdDate" : "2018-03-15T10:24:52.149Z",
    "amount" : 15000,
    "amountInUsDollar" : 4024,
    "textAmount" : "150.00 PLN",
    "currency" : "PLN",
    "cardId" : 3574,
    "receiverPhone" : "600300200",
    "senderFirstName" : "Rob",
    "senderLastName" : "Wring",
    "senderHiddenCardNumber" : "522212******4321",
    "senderProvider" : "MASTERCARD",
    "senderBankName" : "Alior Bank SA",
    "status" : "approved",
    "3DS" : false
  } ],
  "pageable" : "INSTANCE",
  "last" : true,
  "totalPages" : 1,
  "totalElements" : 1,
  "first" : true,
  "sort" : {
    "sorted" : false,
    "unsorted" : true
  },
  "numberOfElements" : 1,
  "size" : 0,
  "number" : 0
}

Response fields

Path Type Description

content.[].correlationId

String

Unique UUID describing single transaction in system.

content.[].createdDate

String

Date of transaction processing.

content.[].amount

Number

Transaction amount in pennies.

content.[].amountInUsDollar

Number

Transaction amount in USD currency in pennies.

content.[].textAmount

String

Transaction amount with currency.

content.[].currency

String

Transaction currency.

content.[].cardId

Number

Datacore card id used in transaction (sender card).

content.[].3DS

Boolean

Value: true/false determines if transaction was processed with 3ds

content.[].senderFirstName

String

Transaction sender first name.

content.[].senderLastName

String

Transaction sender last name.

content.[].senderHiddenCardNumber

String

Transaction sender hidden card number.

content.[].senderProvider

String

VISA or MASTERCARD or MAESTRO

content.[].senderBankName

String

Transaction sender card bank name.

content.[].receiverPhone

String

Transaction receiver phone number.

content.[].status

String

Status of the transaction (approved, reversed, rejected).

last

Boolean

Describes whether the page is last (true ot false).

totalPages

Number

Total number of all pages.

totalElements

Number

Total number of all transactions.

numberOfElements

Number

Number of transactions on page.

first

Boolean

Describes whether the page is first (true ot false).

sort

Object

Details of sort.

size

Number

Max number of transactions on page.

number

Number

Page number.

pageable

String

Requested page information.

200 OK - email receiver (funding only)
HTTP/1.1 200 OK
Content-Type: application/json;charset=UTF-8
Content-Length: 771

{
  "content" : [ {
    "correlationId" : "0d593739-d22e-49ee-b5bc-c41f203abbb4",
    "createdDate" : "2018-03-15T10:24:52.149Z",
    "amount" : 15000,
    "amountInUsDollar" : 4024,
    "textAmount" : "150.00 PLN",
    "currency" : "PLN",
    "cardId" : 3574,
    "receiverEmail" : "receiver@fenige.pl",
    "senderFirstName" : "Rob",
    "senderLastName" : "Wring",
    "senderHiddenCardNumber" : "522212******4321",
    "senderProvider" : "MASTERCARD",
    "senderBankName" : "Alior Bank SA",
    "status" : "approved",
    "3DS" : false
  } ],
  "pageable" : "INSTANCE",
  "last" : true,
  "totalPages" : 1,
  "totalElements" : 1,
  "first" : true,
  "sort" : {
    "sorted" : false,
    "unsorted" : true
  },
  "numberOfElements" : 1,
  "size" : 0,
  "number" : 0
}

Response fields

Path Type Description

content.[].correlationId

String

Unique UUID describing single transaction in system.

content.[].createdDate

String

Date of transaction processing.

content.[].amount

Number

Transaction amount in pennies.

content.[].amountInUsDollar

Number

Transaction amount in USD currency in pennies.

content.[].textAmount

String

Transaction amount with currency.

content.[].currency

String

Transaction currency.

content.[].cardId

Number

Datacore card id used in transaction (sender card).

content.[].3DS

Boolean

Value: true/false determines if transaction was processed with 3ds

content.[].senderFirstName

String

Transaction sender first name.

content.[].senderLastName

String

Transaction sender last name.

content.[].senderHiddenCardNumber

String

Transaction sender hidden card number.

content.[].senderProvider

String

VISA or MASTERCARD or MAESTRO

content.[].senderBankName

String

Transaction sender card bank name.

content.[].receiverEmail

String

Transaction receiver email.

content.[].status

String

Status of the transaction (approved, reversed, rejected).

last

Boolean

Describes whether the page is last (true ot false).

totalPages

Number

Total number of all pages.

totalElements

Number

Total number of all transactions.

numberOfElements

Number

Number of transactions on page.

first

Boolean

Describes whether the page is first (true ot false).

sort

Object

Details of sort.

size

Number

Max number of transactions on page.

number

Number

Page number.

pageable

String

Requested page information.

404 NOT FOUND
HTTP/1.1 404 Not Found

5. Webhooks

General information
To use the webhooks functionality, you must notify Fenige Sales Department by email. Then an URL address and a secret token will be configured, thanks to which communication between the Fenige side and the client side will be more secure. After configuring the above-mentioned properties, you will receive Secret Token and then you can handle webhooks from the Fenige system. The URL must be specified by the client, requests from the Fenige system will be directed to this address. The Secret Token will be set by the Fenige employee and sent to the client.

5.1. Transaction status

Method: HTTP POST
The client user can be notified immediately as soon as the transaction changes its state. After handling the request from the Fenige system, the client side will be notified of the current status of the transaction. Then you can be sure that the transaction processing was finished and you can get the transaction details if you want to.

webhook
Figure 2. In the picture above you can see basic idea of this webhook/event
Your server after receiving Webhook Event must return HTTP status 200 OK. Otherwise, the Fenige server will retry the request. There is 3 attempts for requesting your API. Repeated requests will be executing in 5 seconds intervals excluding timeout from client server.
In order to protect client API by polling or other undesirable actions, the Fenige system uses headers. If you want to use Transaction status webhook, you need to do the header handling on your side.
To build 'X-MERCHANT-SECRET' header:
1. Concatenate secret token established by you and Fenige’s employee with orderId of transaction
2. Hash with SHA256 function result of above operation
Example of 'X-MERCHANT-SECRET' building
import hashlib

# secret token established by client with fenige employee
secret = 'mNaU9TaK4m9myYYFBJgKu8slNH2fCKutJyzXwI'
# orderId received from webhook's request
order_id = 'c168a885-acfa-4a91-a1ad-ed7a042b7238'

# concatenate strings in correct order
concatenated = secret + order_id

# use SHA256 hashing function
hashed = hashlib.sha256(concatenated.encode('utf-8')).hexdigest()

# then compare 'hashed' variable with content of 'X-MERCHANT-SECRET' header

5.1.1. Transaction status webhook request body

When transaction was approved
Content-Type: application/json
X-MERCHANT-SECRET: 3cbd17f561150a1394cabbe2b6031fd83f3f3081abe28c32b7fed16f32aebc4a
X-MERCHANT-TIMESTAMP: 1614800720

{
    "orderId": "c168a885-acfa-4a91-a1ad-ed7a042b7238",
    "status": "APPROVED",
    "responseCode": "CODE_00"
}
When transaction was declined
Content-Type: application/json
X-MERCHANT-SECRET: 3cbd17f561150a1394cabbe2b6031fd83f3f3081abe28c32b7fed16f32aebc4a
X-MERCHANT-TIMESTAMP: 1614800720

{
    "orderId": "ef83e9c0-2a79-48a9-a992-59c9ee6c8cd0",
    "status": "DECLINED",
    "responseCode": "CODE_05",
    "errorMessage": "FUNDING_TRANSACTION_DECLINED:CODE_05"
}
When Delayed Payment was reversed
Content-Type: application/json
X-MERCHANT-SECRET: 3cbd17f561150a1394cabbe2b6031fd83f3f3081abe28c32b7fed16f32aebc4a
X-MERCHANT-TIMESTAMP: 1614800720

{
    "orderId": "ef83e9c0-2a79-48a9-a992-59c9ee6c8cd0",
    "status": "REVERSED"
}
Table 15. Headers description
Path Type Rule Description

X-MERCHANT-SECRET

String

Always present

SHA256 Hash string composed from secret token and orderId placed in request body of this webhook

X-MERCHANT-TIMESTAMP

Numeric string

Always present

Timestamp of server response in UNIX format for instance: 1614023731

Table 16. Request fields description
Path Type Rule Description

orderId

String/UUID

Always present

Unique identifier of transaction. You can fetch details of transaction by this parameter.

status

String

Always present

Internal transaction status in Fenige system.

responseCode

String

Optional

Mastercard/Visa ISO response code.

errorMessage

String

Optional

Optional error message content

6. 3DS 1.0 verification methods

The 3ds method provides the opportunity for additional verification of the card holder. The goal  is to increase security and confidence in online payment. Verification is performed by sending a special security token to the address specified by the user (initialize 3DS method). Verification require by the user to log in bank system. Finalization of the 3DS process require passing received in initialize step parameters.
3DS Flow

Mastercard and Visa requires for intra-European Economic Area (EEA), plus United Kingdom, for which EMV 3DS must be used subsequent to a valid authorization soft decline DE39=65. To perform a transaction for which the card has previously received CODE_65, the transaction must be processed with full EMV 3DS (3DS 2.x) and the authentication status must be 'Y'.

Correct flow:

  • 3DS 2.x → Challenge → Authentication status Y → Transaction (Recommended)

  • 3DS 2.x → Card number not Enrolled in 3DS v2 → 3DS 1.0 → Transaction (Recommended)

  • 3DS 1.0 → Authentication status Y/A → Transaction → CODE_65 → 3DS 2.x → Challenge → Authentication status Y → Transaction (Not recommended)

  • non3DS → Transaction → CODE_65 → 3DS 2.x → Challenge → Authentication status Y → Transaction (Available only to selected merchants)

soft decline Code 65 EMV 3DS

6.1. Verify

POST /client/3ds/verify Content Type: application/json, Authorization: Basic Auth, API-TOKEN*
Method may be used obtain status of the transaction verification.
Success verify enrollment response. MPI return one of statuses:
Y (Card Enrolled) - Cardholder is enrolled, activation is supported, or proof of attempted authentication available.

Error verify enrollment response. MPI return one of statuses:
N (Card Not Enrolled) - Cardholder not participating – cardholder is not enrolled.
U (Card Enrolled Status Unavailable) - Unable to authenticate or card not eligible for attempts.
*API-TOKEN is required for method: DATACORE when the cardId field is sent.

6.1.1. Request

PLAIN
POST /client/3ds/verify HTTP/1.1
Content-Type: application/json
Accept: application/json
Authorization: Basic dXNlcjpwYXNzd29yZA==
Host: java-staging.fenige.pl:8181
Content-Length: 39

{
  "cardNumber" : "5453010000095141"
}
Table 17. VERIFY 3DS REQUEST FIELDS
Path Type Validation Rule Description

cardNumber

String

Required

must be a number and length must be 13 or 16 or 19

Transaction card number used in verification process

DATACORE
POST /client/3ds/verify HTTP/1.1
Content-Type: application/json
Authorization: Basic bWVyY2hhbnQ6cGFzc3dvcmQ=
API-TOKEN: d94NYa+xqRrazUPzSgYeJ6qR/MzIOb3IzePb7t9sWds=
Host: java-staging.fenige.pl:8181
Content-Length: 22

{
  "cardId" : 46242
}
Table 18. VERIFY 3DS REQUEST FIELDS
Path Type Validation Rule Description

cardId

Number

Required

@Must not be null, @Numeric

DataCenter card id. Required to obtain card information data from DataCenter such as (cardNumber, expiryDate)

6.1.2. Response

Response status
Status Description

200 OK

Returned verification status.

200 OK - Error validation

Returned list of field name which has validation error.

Example HTTP Response
200 OK
HTTP/1.1 200 OK
Content-Type: application/json;charset=UTF-8
Content-Length: 28

{
  "enrolledStatus" : "Y"
}
Path Type Description

enrolledStatus

String

Authentication status indicator

200 OK - Error validation
HTTP/1.1 200 OK
Content-Type: application/json

{
    "status": "ERROR_VALIDATION",
    "error": {
        "message": "Some information is missing or incorrect.",
        "errors": [
            {
                "field": "cardNumber",
                "message": [
                    "may not be null"
                ]
            },
            {
                "field": "cardNumber",
                "message": [
                    "must be a number and length must be 13 or 16 or 19"
                ]
            }
        ]
    }
}

6.2. Initialize

POST /client/3ds/initialize Content Type: application/json, Authorization: Basic Auth, API-TOKEN*
Method initialize verification process by sending required transaction data and generate special form for user to log in.
*API-TOKEN is required for method: DATACORE when the cardId field is sent.

6.2.1. Request

PLAIN
POST /client/3ds/initialize HTTP/1.1
Content-Type: application/json
Accept: application/json
Authorization: Basic dXNlcjpwYXNzd29yZA==
Host: java-staging.fenige.pl:8181
Content-Length: 385

{
  "merchantName" : "TestMerchant",
  "cardNumber" : "5453010000095141",
  "cardExpMonth" : "12",
  "cardExpYear" : "18",
  "transactionAmount" : "200",
  "transactionDescription" : "Transaction description",
  "transactionDisplayAmount" : "2,00 PLN",
  "currencyCode" : "840",
  "currencyExponent" : "2",
  "termUrl" : "https://url",
  "md" : "fdee83d4-a57e-11ea-bb37-0242ac130002"
}
Table 19. INITIALIZE 3DS REQUEST FIELDS
Path Type Validation Rule Description

merchantName

String

Required

Length must be between 0 and 25 inclusive, Must not be null

Merchant name visible on the 3ds confirmation form from the bank

cardNumber

String

Required

Must not be null

Sender card number of the transaction

cardExpMonth

String

Required

Sender card expiry month mm

cardExpYear

String

Required

Sender card expiry year yy

transactionAmount

String

Required

Must match the regular expression \d+, Must not be null

Transaction amount (in pennies)

transactionDescription

String

Required

Must not be blank

Transaction description

transactionDisplayAmount

String

Required

Must not be null

Amount displayed in mpi form

currencyCode

String

Required

Must match the regular expression \d+, Must not be null

Numeric currency code of transaction currency

currencyExponent

String

Required

Must match the regular expression \d+, Must not be null

Number places of the amount precision for transaction currency

termUrl

String

Required

Must not be null

The url to which the parameters Pares and md will be sent. They will be need in Finalize method

md

String

Required

Must not be blank

Merchant Data unique uuid needed to complete transaction

DATACORE
POST /client/3ds/initialize HTTP/1.1
Content-Type: application/json
Authorization: Basic bWVyY2hhbnQ6cGFzc3dvcmQ=
API-TOKEN: d94NYa+xqRrazUPzSgYeJ6qR/MzIOb3IzePb7t9sWds=
Host: java-staging.fenige.pl:8181
Content-Length: 319

{
  "merchantName" : "TestMerchant",
  "cardId" : 23145,
  "transactionAmount" : "200",
  "transactionDescription" : "Transaction description",
  "transactionDisplayAmount" : "2,00 PLN",
  "currencyCode" : "840",
  "currencyExponent" : "2",
  "termUrl" : "https://url",
  "md" : "fdee83d4-a57e-11ea-bb37-0242ac130002"
}
Table 20. INITIALIZE 3DS REQUEST FIELDS
Path Type Validation Rule Description

merchantName

String

Required

Length must be between 0 and 25 inclusive, Must not be null

Merchant name visible on the 3ds confirmation form from the bank

cardId

Number

Required

@Must not be null, @Numeric

DataCenter card id. Required to obtain card information data from DataCenter such as (cardNumber, expiryDate)

transactionAmount

String

Required

Must match the regular expression \d+, Must not be null

Transaction amount (in pennies)

transactionDescription

String

Required

Must not be blank

Transaction description

transactionDisplayAmount

String

Required

Must not be null

Amount displayed in mpi form

currencyCode

String

Required

Must match the regular expression \d+, Must not be null

Numeric currency code of transaction currency

currencyExponent

String

Required

Must match the regular expression \d+, Must not be null

Number places of the amount precision for transaction currency

termUrl

String

Required

Must not be null

The url to which the parameters Pares and md will be sent. They will be need in Finalize method

md

String

Required

Must not be blank

Merchant Data unique uuid needed to complete transaction

6.2.2. Response

Response status
Status Description

200 OK

Returned when form for user to log in was successfully generate.

200 OK - Error validation

Returned list of field name which has validation error.

200 OK
HTTP/1.1 200 OK
Content-Type: application/json;charset=UTF-8
Content-Length: 1733

{
  "pareq" : "eJxlkltvwjAMhf8K4p3m0qRUlYnE4GHVxMQuT3uLWguK2lDSFsG/n8NlbFqkSD6Oe+p8DnxuPeLyA4vBo4EVdp3d4KgqZ2M5lWpsYD1/x4OBI/qu2jsjIh5JYHdJX/hia11vwBaHp/zVaCVEooDdJDTo86XhtCa0BbBrApxt0HToStUgsIuCYj+43p9NIhJgdwGDr82279suY2xnj3ZS4hFrEQ2trcqorbNUqZgVdYWuBxaqgT3aWg8h6sj9VJUmX8w3//Yyj1e7txmwUAGl7dFILlIeSz4SOlM60ymwSx5sE9oyi6+XUax5xDnd9JqCNvxpfhV0Fo5+p4AQe3TFmcxjut5dAZ7avaPeDXH9iYE9Gl88B7pFT9jiADIsRSxpQKlKtNRqmsiUkN2KgmNF5CTn+mIZBLBgw27jJECXSVP05wV8A1/aqWQ=",
  "acsUrl" : "https://java-devel.fenige.pl:8181/fenige-mpi",
  "md" : "ZmRlZTgzZDQtYTU3ZS0xMWVhLWJiMzctMDI0MmFjMTMwMDAy",
  "formBase64" : "PGh0bWw+PFNDUklQVCBMQU5HVUFHRT0iSmF2YXNjcmlwdCI+ZnVuY3Rpb24gT25Mb2FkRXZlbnQoKXsgZG9jdW1lbnQuZG93bmxvYWRGb3JtLnN1Ym1pdCgpOyB9PC9TQ1JJUFQ+PGJvZHkgT25Mb2FkPSJPbkxvYWRFdmVudCgpOyI+PGZvcm0gbmFtZT0iZG93bmxvYWRGb3JtIiBhY3Rpb249Imh0dHBzOi8vamF2YS1kZXZlbC5mZW5pZ2UucGw6ODE4MS9mZW5pZ2UtbXBpIiBtZXRob2Q9IlBPU1QiPjxJTlBVVCB0eXBlPSJoaWRkZW4iIG5hbWU9IlBhUmVxIiB2YWx1ZT0iZUp4bGtsdHZ3akFNaGY4SzRwM20wcVJVbFluRTRHSFZ4TVF1VDN1TFdndUsybERTRnNHL244TmxiRnFrU0Q2T2UrcDhEbnh1UGVMeUE0dkJvNEVWZHAzZDRLZ3FaMk01bFdwc1lEMS94NE9CSS9xdTJqc2pJaDVKWUhkSlgvaGlhMTF2d0JhSHAvelZhQ1ZFb29EZEpEVG84NlhodENhMEJiQnJBcHh0MEhUb1N0VWdzSXVDWWorNDNwOU5JaEpnZHdHRHI4MjI3OXN1WTJ4bmozWlM0aEZyRVEydHJjcW9yYk5VcVpnVmRZV3VCeGFxZ1QzYVdnOGg2c2o5VkpVbVg4dzMvL1l5ajFlN3R4bXdVQUdsN2RGSUxsSWVTejRTT2xNNjB5bXdTeDVzRTlveWk2K1hVYXg1eERuZDlKcUNOdnhwZmhWMEZvNStwNEFRZTNURm1jeGp1dDVkQVo3YXZhUGVEWEg5aVlFOUdsODhCN3BGVDlqaUFESXNSU3hwUUtsS3ROUnFtc2lVa04yS2dtTkY1Q1RuK21JWkJMQmd3MjdqSkVDWFNWUDA1d1Y4QTEvYXFXUT0iPjxpbnB1dCB0eXBlPSJoaWRkZW4iIG5hbWU9IlRlcm1VcmwiIHZhbHVlPSJodHRwczovL3VybCI+PGlucHV0IHR5cGU9ImhpZGRlbiIgbmFtZT0iTUQiIHZhbHVlPSJiV1E9Ij42Zvcm0+PC9ib2R5PjwvaHRtbD4=",
  "enrolledStatus" : "Y"
}
Path Type Description

pareq

String

The url to which the mpi parameters will be sent

acsUrl

String

The url to which the mpi parameters will be sent

md

String

Merchant data unique udid in base64 format

formBase64

String

Html form of the document in base64 format

enrolledStatus

String

Authentication status indicator

200 OK - Error validation
HTTP/1.1 200 OK
Content-Type: application/json

{
    "status": "ERROR_VALIDATION",
    "error": {
        "message": "Some information is missing or incorrect.",
        "errors": [
            {
                "field": "cardExpMonth",
                "message": [
                    "must not be null"
                ]
            },
            {
                "field": "transactionDescription",
                "message": [
                    "may not be empty"
                ]
            },
            {
                "field": "currencyExponent",
                "message": [
                    "must not be null"
                ]
            },
            {
                "field": "transactionAmount",
                "message": [
                    "must not be null"
                ]
            },
            {
                "field": "cardExpYear",
                "message": [
                    "must not be null"
                ]
            },
            {
                "field": "cardNumber",
                "message": [
                    "must not be null"
                ]
            },
            {
                "field": "transactionDisplayAmount",
                "message": [
                    "must not be null"
                ]
            },
            {
                "field": "md",
                "message": [
                    "must not be empty"
                ]
            },
            {
                "field": "currencyCode",
                "message": [
                    "must not be null"
                ]
            },
            {
                "field": "merchantName",
                "message": [
                    "must not be null"
                ]
            },
            {
                "field": "termUrl",
                "message": [
                    "must not be null"
                ]
            }

        ]
    }
}

6.3. Finalize

POST /client/3ds/finalize Content Type: application/json, Authorization: Basic Auth
The success of the verification depends on the correctness of the uploaded parameters pares and md received in initialize step.
Success 3-D Secure Authentication. MPI return status:
Y (Full Authentication) - The customer was successfully authenticated.

Attempt 3-D Secure Authentication. MPI return status:
A (Successful Attempted Authentication) - Authentication was not available, but functionality was available to generate a proof of authentication attempt.

Error 3-D Secure Authentication results. MPI return one of statuses:
N (Authentication Failed) - The customer failed authentication, and the transaction is denied. The cardholder’s password (or other authentication information) failed validation, thus, the issuer is not able to authenticate the cardholder.
U (Unable to Complete Authentication) - Authentication could not be performed due to technical or other problems.

6.3.1. Request

POST /client/3ds/finalize HTTP/1.1
Content-Type: application/json
Accept: application/json
Authorization: Basic dXNlcjpwYXNzd29yZA==
Host: java-staging.fenige.pl:8181
Content-Length: 135

{
  "pares" : "VGhpcyBpcyBhIHRlc3QgUGFSZXMgdGhhdCByZXR1cm5zIHN1Y2Nlc3M=",
  "md" : "ZmRlZTgzZDQtYTU3ZS0xMWVhLWJiMzctMDI0MmFjMTMwMDAy"
}
Table 21. FINALIZE 3DS REQUEST FIELDS
Path Type Validation Rule Description

pares

String

Required

Must not be null

Payer Authentication Response

md

String

Required

Must not be null

Merchant Data unique uuid in base64 format from Initialize response body needed to complete transaction

6.3.2. Response

Response status
Status Description

200 OK

Returned when customer was successfully authenticated.

200 OK - Error validation

Returned list of field name which has validation error.

200 OK - status Y
HTTP/1.1 200 OK
Content-Type: application/json;charset=UTF-8
Content-Length: 164

{
  "authenticationStatus" : "Y",
  "cavv" : "jEu04WZns7pbARAApU4qgNdJTag=",
  "eci" : "02",
  "authenticationTime" : "20180703 16:55:28",
  "cavvAlgorithm" : "3"
}
Path Type Description

authenticationStatus

String

Authentication status indicator

cavv

String

Cardholder Authentication Verification Value

eci

String

Electronic Commerce Indicator: 5 (Visa) or 2 (SecureCode) - The cardholder was successfully authenticated. 6 (Visa) or 1 (SecureCode) - Authentication was attempted, but the cardholder was not enrolled. Chargeback protection applies.

authenticationTime

String

Date and time of authentication

cavvAlgorithm

String

Indicates the algorithm used to generate the AuthenticationCAVV value

0 - HMAC

1 - CVV

2 - CVV with ATN

3 - MasterCard SPA algorithm

200 OK - status A
HTTP/1.1 200 OK
Content-Type: application/json;charset=UTF-8
Content-Length: 164

{
  "authenticationStatus" : "A",
  "cavv" : "hMKElVc7gh0wCAEAAA/4BgMAAAA=",
  "eci" : "02",
  "authenticationTime" : "20180703 15:46:00",
  "cavvAlgorithm" : "3"
}
Path Type Description

authenticationStatus

String

Authentication status indicator

cavv

String

Cardholder Authentication Verification Value

eci

String

Electronic Commerce Indicator: 5 (Visa) or 2 (SecureCode) - The cardholder was successfully authenticated. 6 (Visa) or 1 (SecureCode) - Authentication was attempted, but the cardholder was not enrolled. Chargeback protection applies.

authenticationTime

String

Date and time of authentication

cavvAlgorithm

String

Indicates the algorithm used to generate the AuthenticationCAVV value

0 - HMAC

1 - CVV

2 - CVV with ATN

3 - MasterCard SPA algorithm

200 OK - Error validation
HTTP/1.1 200 OK
Content-Type: application/json

{
    "status": "ERROR_VALIDATION",
    "error": {
        "message": "Some information is missing or incorrect.",
        "errors": [
            {
                "field": "md",
                "message": [
                    "may not be null"
                ]
            },
            {
                "field": "pares",
                "message": [
                    "may not be null"
                ]
            }
        ]
    }
}

7. 3DS 2.X verification methods

The methods described in this section provide the ability to execute 3DS 2.X process. You can use the data received from authentication method to perform transactions with 3DS 2.X.

Mastercard and Visa requires for intra-European Economic Area (EEA), plus United Kingdom, for which EMV 3DS must be used subsequent to a valid authorization soft decline DE39=65. To perform a transaction for which the card has previously received CODE_65, the transaction must be processed with full EMV 3DS (3DS 2.x) and the authentication status must be 'Y'.

Correct flow:

  • 3DS 2.x → Challenge → Authentication status Y → Transaction (Recommended)

  • 3DS 2.x → Card number not Enrolled in 3DS v2 → 3DS 1.0 → Transaction (Recommended)

  • 3DS 1.0 → Authentication status Y/A → Transaction → CODE_65 → 3DS 2.x → Challenge → Authentication status Y → Transaction (Not recommended)

  • non3DS → Transaction → CODE_65 → 3DS 2.x → Challenge → Authentication status Y → Transaction (Available only to selected merchants)

soft decline Code 65 EMV 3DS
3ds 2.0 and 3ds 1.0 flow
3ds 2.X flow

7.1. Pre Authentication

POST /client/3ds/preAuthentication Content Type: application/json, Authorization: Basic Auth, API-TOKEN*
Method to initiate 3ds authentication.
If the card is in 3ds 2.X, you can proceed to the first stage of authentication. If 'threeDSMethodURL' is returned, make a hidden iframe and post form with field name
'threeDSMethodData' on address from 'threeDSMethodURL'. Insert 'threeDSMethodData' from response to form. You should receive a response on your endpoint 'methodNotificationUrl' with 'threeDSMethodData' too. Measure the response time, the time and response are required at the 'Authentication' method, based on the response time, set the field 'methodCompletionIndicator'.

'threeDSMethodData ' is Base64 encoded string json with fields 'threeDSMethodNotificationURL' and 'threeDSServerTransID'.

The range of card BINs that support 3DS 2.X for Mastercard is: 500000-549999. Use the following BINs below to generate cards for testing:
- 5430146432688349
- 5117962099480048
- 5117963095204135
- 5218572540397762
- 5132786349436752

If the card is not in 3DS 2.X use version 1.0.
*API-TOKEN is required for method: DATACORE when the cardId field is sent.

7.1.1. Request

PLAIN
POST /client/3ds/preAuthentication HTTP/1.1
Content-Type: application/json
Authorization: Basic bWVyY2hhbnQ6cGFzc3dvcmQ=
Host: java-staging.fenige.pl:8181
Content-Length: 96

{
  "cardNumber" : "5117964247989169",
  "methodNotificationUrl" : "methodNotificationUrl.com"
}
Table 22. PRE AUTHENTICATION 3DS 2.X REQUEST FIELDS
Path Type Validation Rule Description

cardNumber

String

Required

@NotNull

Card number to 3DS 2.X pre authentication

methodNotificationUrl

String

Required

@NotNull

This field specifies the URL to which the ACS will post threeDSMethodData when the hidden iframe post form from browse

DATACORE
POST /client/3ds/preAuthentication HTTP/1.1
Content-Type: application/json
Content-Type: application/json
Authorization: Basic bWVyY2hhbnQ6cGFzc3dvcmQ=
API-TOKEN: d94NYa+xqRrazUPzSgYeJ6qR/MzIOb3IzePb7t9sWds=
Host: java-staging.fenige.pl:8181
Content-Length: 78

{
  "cardId" : 1732,
  "methodNotificationUrl" : "methodNotificationUrl.com"
}
Table 23. PRE AUTHENTICATION 3DS 2.X REQUEST FIELDS
Path Type Validation Rule Description

cardId

Number

Required

@Must not be null, @Numeric

DataCenter card id. Required to obtain card information data from DataCenter such as (cardNumber, expiryDate)

methodNotificationUrl

String

Required

@NotNull

This field specifies the URL to which the ACS will post threeDSMethodData when the hidden iframe post form from browse

7.1.2. Response

200 OK
HTTP/1.1 200 OK
Content-Type: application/json;charset=UTF-8
Content-Length: 462

{
  "cardAuthenticationId" : "71c5030b-59c2-4495-b146-868f517a4d69",
  "threeDSMethodData" : "eyJ0aHJlZURTTWV0aG9kTm90aWZpY2F0aW9uVVJMIjoiaHR0cHM6Ly93ZWJob29rLnNpdGUvZDMyZTlkZTgtMGFiOC00ODZjLWJjNzEtMGU2Mzg2MmY4MDNhM2I1YTkzZTUtMjI1Ni00NGQ0LTg2YjItNWFkM2FhMDEyYTJhIiwidGhyZWVEU1NlcnZlclRyYW5zSUQiOiIxNjNiZWMzOC1kOTM1LTQ0MGItYWYwYy01OWM3NDI3OTk2MGMifQ",
  "threeDSMethodURL" : "https:/acs.com",
  "protocolVersionStart" : "2.1.0",
  "protocolVersionEnd" : "2.2.0"
}
Path Type Description

cardAuthenticationId

String

Unique identifier for 3ds verification

threeDSMethodData

String

Encoded data used for request to ACS

threeDSMethodURL

String

ACS endpoint for hidden request. If endpoint is not present then request is not required

protocolVersionStart

String

Protocol version start range

protocolVersionEnd

String

Protocol version end range

200 OK without threeDSMethodURL
HTTP/1.1 200 OK
Content-Type: application/json;charset=UTF-8
Content-Length: 421

{
  "cardAuthenticationId" : "8dcccd60-a801-4c42-905d-83e9bfef5f4d",
  "threeDSMethodData" : "eyJ0aHJlZURTTWV0aG9kTm90aWZpY2F0aW9uVVJMIjoiaHR0cHM6Ly93ZWJob29rLnNpdGUvZDMyZTlkZTgtMGFiOC00ODZjLWJjNzEtMGU2Mzg2MmY4MDNhM2I1YTkzZTUtMjI1Ni00NGQ0LTg2YjItNWFkM2FhMDEyYTJhIiwidGhyZWVEU1NlcnZlclRyYW5zSUQiOiIxNjNiZWMzOC1kOTM1LTQ0MGItYWYwYy01OWM3NDI3OTk2MGMifQ",
  "protocolVersionStart" : "2.1.0",
  "protocolVersionEnd" : "2.2.0"
}
Path Type Description

cardAuthenticationId

String

Unique identifier for 3ds verification

threeDSMethodData

String

Encoded data used for request to ACS

protocolVersionStart

String

Protocol version start range

protocolVersionEnd

String

Protocol version end range

422 UNPROCESSABLE ENTITY Card number not Enrolled in 3DS v2
HTTP/1.1 422 Unprocessable Entity
Content-Type: application/json;charset=UTF-8
Content-Length: 130

{
  "status" : "ERROR_3DS_2_X_CARD_NUMBER_NOT_ENROLLED",
  "error" : {
    "message" : "Card number not Enrolled in 3DS v2."
  }
}
Path Type Description

status

String

Api status

error.message

String

Api status description

7.2. Authentication

POST /client/3ds/authentication Content Type: application/json, Authorization: Basic Auth, API-TOKEN*
Method initialize authentication process by sending required transaction data. Method can return final data like cavv, transactionXId, eci or challenge flow (shown in the diagram).
After challenge end your app get notification on 'notificationUrl'. This is a POST request with "cres" and "threeDSSessionData".

"threeDSSessionData" is a encoded in base64 "cardAuthenticationId". You must use it in 'Authentication Details' method to get authentication value cavv, transactionXId and eci.

'cres' is Base64 encoded string json with fields: 'threeDSServerTransID', 'acsTransID', 'challengeCompletionInd', 'messageVersion', 'transStatus'.
'threeDSServerTransID' - is same like in 'threeDSMethodData'.
'transStatus' - is same like 'transactionStatus' in response from 'Authentication' method.
In the test environment, you have the option of calling different transactionStatus, depending on the purchaseAmount field. Eg.
     (1, 1000) - Y,
     (1001, 2000) - A,
     (2001, 3000) - C,
     (3001, 4000) - N,
     (4001, 5000) - U,
     (5001, 6000) - I.
*API-TOKEN is required for method: DATACORE when the cardId field is sent.

7.2.1. Request

PLAIN
POST /client/3ds/authentication HTTP/1.1
Content-Type: application/json
Authorization: Basic bWVyY2hhbnQ6cGFzc3dvcmQ=
Host: java-staging.fenige.pl:8181
Content-Length: 1189

{
  "cardAuthenticationId" : "88436993-c7d3-47c6-b83f-e636f196f239",
  "threeDSMethodData" : "eyJ0aHJlZURTTWV0aG9kTm90aWZpY2F0aW9uVVJMIjoiSFRUUDQwYjgyNDQ3LTE0ODUtNDUwZi04ZGYxLTdhNGQwYmRiMWMzYiIsInRocmVlRFNTZXJ2ZXJUcmFuc0lEIjoiNDE1MDQzY2UtYTNhMC00ODBjLTk0YTYtNzk2NGEzYTcxNWI2In0",
  "methodCompletionIndicator" : "Y",
  "cardNumber" : "5117964247989169",
  "cardExpirationDate" : "12/22",
  "cardholderName" : "John Doe",
  "purchaseAmount" : "123",
  "purchaseCurrency" : "PLN",
  "browserAcceptHeader" : "Accept: application/json",
  "browserLanguage" : "PL",
  "browserScreenHeight" : "1500",
  "browserScreenWidth" : "1500",
  "browserTimeZone" : "60",
  "browserUserAgent" : "Mozilla/5.0",
  "browserScreenColorDepth" : "100",
  "cardholderEmail" : "john.doe@example.com",
  "cardholderHomePhone" : "654734523",
  "cardholderMobilePhone" : "654734523",
  "cardholderWorkPhone" : "654734523",
  "browserIPAddress" : "77.55.135.220",
  "browserJavaEnabledVal" : "ENABLED",
  "browserJavaScriptEnabled" : "ENABLED",
  "notificationUrl" : "notification-url.com",
  "requestorChallengeInd" : "CHALLENGE_REQUESTED_MANDATE",
  "authenticationType" : "PAYMENT",
  "protocolVersion" : "2.2.0"
}
Table 24. AUTHENTICATION 3DS REQUEST FIELDS
Path Type Validation Rule Description

cardAuthenticationId

String

Required

@Must not be empty

Unique identifier for 3ds verification from preAuthentication request.

cardNumber

String

Required

Card number length must be 13 or 16 or 19, @Must not be blank, @Must not be null or card id must be present

Card number.

cardExpirationDate

String

Required

Card number length must be 13 or 16 or 19, @Must not be blank, @Must not be null or card id must be present

Expiration date of card mm/yy.

cardholderName

String

Required

@Length must be between 2 and 45 inclusive, @Must not be empty

This property contains the name of the cardholder. Name of the Cardholder. Must be ASCII characters. This is required to be set unless market or regional mandates restricts sending this information.

purchaseAmount

String

Required

@Must not be empty

This field contains the purchase amount to be authorized. The transaction amount is to be presented with an implied decimal point. For example, US $10.00 must be represented as 1000, and $0.10 is likewise simply 10. The allowable number of significant digits as well as the positioning of any implied decimal point is dictated by the designated PurchaseExponent. This field may not contain a negative number.

purchaseCurrency

String

Required

@Must not be null

Currency for transaction (in accordance with 3-digit ISO-4217), example: USD.

threeDSMethodData

String

Required

@Must not be empty

Response data from a hidden form from the Pre Authentication. If threeDSMethodURL is empty set encodedData.

methodCompletionIndicator

String

Required

@Must not be null

Y if response from hidden form from Pre Authentication is under 10s, N if response from hidden form from Pre Authentication is over 10s, U if threeDSMethodURL is empty.

protocolVersion

String

Required

@Must not be null

This field indicates the protocol version. Now there are two versions: 2.1.0 and 2.2.0. It is recommended to use 2.2.0 if the card supports it. You will get it from the Pre Authentication method. Some configurations are only available for 2.2.0.

notificationUrl

String

Required

@Must not be null

This property specifies the URL to which the final challenge response is POSTed.

authenticationType

String

Optional

If null then value equals PAYMENT

Authentication Type configuration prepared for specific type. Possible values are:

Non payment authentication - Identity verification and account confirmation:

ADD_CARD

VERIFY_CARDHOLDER

Payment authentication - Cardholder authentication during an e-commerce transaction:

PAYMENT

requestorChallengeInd

String

Required

@Must not be null

Indicates whether a challenge is requested for this transaction. Possible values are:

NO_PREFERENCE,

NO_CHALLENGE_REQUESTED,

CHALLENGE_REQUESTED_3DS_REQUESTOR_PREFERENCE,

CHALLENGE_REQUESTED_MANDATE.

browserAcceptHeader

String

Required

@Must not be null, Max length: 2048

This field contains the exact content of the HTTP accept header as sent to the merchant from the cardholder’s user agent. This field is required only if the cardholder’s user agent supplied a value. e.g Accept: application/json.

browserLanguage

String

Required

@Must not be null, Min length: 1, Max length: 8

This field contains the cardholder’s browser language as defined in IETF BCP 47.

browserScreenHeight

String

Required

@Must not be null, Regexp: ^[0-9]{1,6}$

This field contains the total height of the cardholder’s screen in pixels.

browserScreenWidth

String

Required

@Must not be null, Regexp: ^[0-9]{1,6}$

This field contains the total width of the cardholder’s screen in pixels.

browserTimeZone

String

Required

@Must not be null, Regexp: ^[+-]?[0-9]{1,4}$

This field contains the difference between UTC time and the cardholder’s browser local time in minutes.

browserUserAgent

String

Required

@Must not be null, Max length: 2048

This field contains the exact content of the HTTP User-Agent header.

browserJavaEnabledVal

String

Required

@Must not be null,

This field contains a value representing the ability of the cardholder’s browser to execute Java. Enumerated values: NOT_PRESENT, ENABLED, DISABLED.

Required if browserJavascriptEnabled is true

cardholderEmail

String

Optional

This field contains the cardholder email address.

cardholderHomePhone

String

Optional

Must match regex \d{1,3}-[1-9]\d{1,14}$

This field contains the home phone number provided by the cardholder. Phone numbers must be specified in the following format: CountryCode-Subscriber (e.g. 1-1234567899)

cardholderMobilePhone

String

Optional

Must match regex \d{1,3}-[1-9]\d{1,14}$

This field contains the mobile phone number provided by the cardholder. Phone numbers must be specified in the following format: CountryCode-Subscriber (e.g. 1-1234567899)

cardholderWorkPhone

String

Optional

Must match regex \d{1,3}-[1-9]\d{1,14}$

This field contains the work phone number provided by the cardholder. Phone numbers must be specified in the following format: CountryCode-Subscriber (e.g. 1-1234567899)

browserIPAddress

String

Required

@Must not be null

This field contains the IP address of the cardholder’s browser as returned by the HTTP headers.

browserJavaScriptEnabled

String

Required

@Must not be null

This field contains a value representing the ability of the cardholder’s browser to execute JavaScript. Enumerated values: ENABLED, DISABLED.

browserScreenColorDepth

String

Required

@Must not be null

This field contains a value representing the bit depth of the color palette, in bits per pixel, for displaying images. Obtained from Cardholder browser using the screen.colorDepth property. Values accepted:

1 = 1 bit,

4 = 4 bits,

8 = 8 bits,

15 = 15 bits,

16 = 16 bits,

24 = 24 bits,

32 = 32 bits,

48 = 48 bits

For ProtocolVersion 2.1.0, this field is required. If BrowserJavaEnabledVal is False, a value of 1 can be used. When using ProtocolVersion of 2.2.0 and both BrowserJavaEnabledVal and BrowserJavaScriptEnabled are False, no value is required.

DATACORE
POST /client/3ds/authentication HTTP/1.1
Content-Type: application/json
Content-Type: application/json
Authorization: Basic bWVyY2hhbnQ6cGFzc3dvcmQ=
API-TOKEN: d94NYa+xqRrazUPzSgYeJ6qR/MzIOb3IzePb7t9sWds=
Host: java-staging.fenige.pl:8181
Content-Length: 1101

{
  "cardAuthenticationId" : "e3a2c458-14db-422d-83dc-d02bef40d03d",
  "threeDSMethodData" : "eyJ0aHJlZURTTWV0aG9kTm90aWZpY2F0aW9uVVJMIjoiSFRUUDQwYjgyNDQ3LTE0ODUtNDUwZi04ZGYxLTdhNGQwYmRiMWMzYiIsInRocmVlRFNTZXJ2ZXJUcmFuc0lEIjoiNDE1MDQzY2UtYTNhMC00ODBjLTk0YTYtNzk2NGEzYTcxNWI2In0",
  "methodCompletionIndicator" : "Y",
  "cardId" : 1732,
  "cardholderName" : "John Doe",
  "purchaseAmount" : "123",
  "purchaseCurrency" : "PLN",
  "browserAcceptHeader" : "Accept: application/json",
  "browserLanguage" : "PL",
  "browserScreenHeight" : "1500",
  "browserScreenWidth" : "1500",
  "browserTimeZone" : "60",
  "browserUserAgent" : "Mozilla/5.0",
  "browserScreenColorDepth" : "100",
  "cardholderEmail" : "john.doe@example.com",
  "cardholderHomePhone" : "654734523",
  "cardholderMobilePhone" : "654734523",
  "cardholderWorkPhone" : "654734523",
  "browserIPAddress" : "77.55.135.220",
  "browserJavaEnabledVal" : "ENABLED",
  "browserJavaScriptEnabled" : "ENABLED",
  "notificationUrl" : "notification-url.com",
  "requestorChallengeInd" : "CHALLENGE_REQUESTED_MANDATE",
  "protocolVersion" : "2.2.0"
}
Table 25. AUTHENTICATION 3DS REQUEST FIELDS
Path Type Validation Rule Description

cardAuthenticationId

String

Required

@Must not be empty

Unique identifier for 3ds verification from preAuthentication request.

cardId

Number

Required

@Must not be null, @Numeric

DataCenter card id. Required to obtain card information data from DataCenter such as (cardNumber, expiryDate)

cardholderName

String

Required

@Length must be between 2 and 45 inclusive, @Must not be empty

This property contains the name of the cardholder. Name of the Cardholder. Must be ASCII characters. This is required to be set unless market or regional mandates restricts sending this information.

purchaseAmount

String

Required

@Must not be empty

This field contains the purchase amount to be authorized. The transaction amount is to be presented with an implied decimal point. For example, US $10.00 must be represented as 1000, and $0.10 is likewise simply 10. The allowable number of significant digits as well as the positioning of any implied decimal point is dictated by the designated PurchaseExponent. This field may not contain a negative number.

purchaseCurrency

String

Required

@Must not be null

Currency for transaction (in accordance with 3-digit ISO-4217), example: USD.

threeDSMethodData

String

Required

@Must not be empty

Response data from a hidden form from the Pre Authentication. If threeDSMethodURL is empty set encodedData.

methodCompletionIndicator

String

Required

@Must not be null

Y if response from hidden form from Pre Authentication is under 10s, N if response from hidden form from Pre Authentication is over 10s, U if threeDSMethodURL is empty.

protocolVersion

String

Required

@Must not be null

This field indicates the protocol version. Now there are two versions: 2.1.0 and 2.2.0. It is recommended to use 2.2.0 if the card supports it. You will get it from the Pre Authentication method. Some configurations are only available for 2.2.0.

notificationUrl

String

Required

@Must not be null

This property specifies the URL to which the final challenge response is POSTed.

requestorChallengeInd

String

Required

@Must not be null

Indicates whether a challenge is requested for this transaction. Possible values are:

NO_PREFERENCE,

NO_CHALLENGE_REQUESTED,

CHALLENGE_REQUESTED_3DS_REQUESTOR_PREFERENCE,

CHALLENGE_REQUESTED_MANDATE.

browserAcceptHeader

String

Required

@Must not be null, Max length: 2048

This field contains the exact content of the HTTP accept header as sent to the merchant from the cardholder’s user agent. This field is required only if the cardholder’s user agent supplied a value. e.g Accept: application/json.

browserLanguage

String

Required

@Must not be null, Min length: 1, Max length: 8

This field contains the cardholder’s browser language as defined in IETF BCP 47.

browserScreenHeight

String

Required

@Must not be null, Regexp: ^[0-9]{1,6}$

This field contains the total height of the cardholder’s screen in pixels.

browserScreenWidth

String

Required

@Must not be null, Regexp: ^[0-9]{1,6}$

This field contains the total width of the cardholder’s screen in pixels.

browserTimeZone

String

Required

@Must not be null, Regexp: ^[+-]?[0-9]{1,4}$

This field contains the difference between UTC time and the cardholder’s browser local time in minutes.

browserUserAgent

String

Required

@Must not be null, Max length: 2048

This field contains the exact content of the HTTP User-Agent header.

browserJavaEnabledVal

String

Required

@Must not be null

This field contains a value representing the ability of the cardholder’s browser to execute Java. Enumerated values: NOT_PRESENT, ENABLED, DISABLED.

Required if browserJavascriptEnabled is true

cardholderEmail

String

Optional

This field contains the cardholder email address.

cardholderHomePhone

String

Optional

Must match regex \d{1,3}-[1-9]\d{1,14}$

This field contains the home phone number provided by the cardholder. Phone numbers must be specified in the following format: CountryCode-Subscriber (e.g. 1-1234567899)

cardholderMobilePhone

String

Optional

Must match regex \d{1,3}-[1-9]\d{1,14}$

This field contains the mobile phone number provided by the cardholder. Phone numbers must be specified in the following format: CountryCode-Subscriber (e.g. 1-1234567899)

cardholderWorkPhone

String

Optional

Must match regex \d{1,3}-[1-9]\d{1,14}$

This field contains the work phone number provided by the cardholder. Phone numbers must be specified in the following format: CountryCode-Subscriber (e.g. 1-1234567899)

browserIPAddress

String

Required

@Must not be null

This field contains the IP address of the cardholder’s browser as returned by the HTTP headers.

browserJavaScriptEnabled

String

Required

@Must not be null

This field contains a value representing the ability of the cardholder’s browser to execute JavaScript. Enumerated values: ENABLED, DISABLED.

browserScreenColorDepth

String

Required

@Must not be null

This field contains a value representing the bit depth of the color palette, in bits per pixel, for displaying images. Obtained from Cardholder browser using the screen.colorDepth property. Values accepted:

1 = 1 bit,

4 = 4 bits,

8 = 8 bits,

15 = 15 bits,

16 = 16 bits,

24 = 24 bits,

32 = 32 bits,

48 = 48 bits

For ProtocolVersion 2.1.0, this field is required. If BrowserJavaEnabledVal is False, a value of 1 can be used. When using ProtocolVersion of 2.2.0 and both BrowserJavaEnabledVal and BrowserJavaScriptEnabled are False, no value is required.

7.2.2. Response

200 OK without challenge
HTTP/1.1 200 OK
Content-Type: application/json;charset=UTF-8
Content-Length: 151

{
  "transactionStatus" : "A",
  "transactionXId" : "5e5c9cc9-057a-4c00-ab61-a14d3fd25c21",
  "cavv" : "B5gQCElHgQAAAAAKmFNEdQAAAAA=",
  "eci" : "06"
}
Path Type Description

transactionStatus

String

Indicates whether a transaction qualifies as an authenticated transaction or account verification. Possible values are:

Y Authentication/account verification successful. N Not authenticated/account not verified; transaction denied. U Authentication/account verification could not be performed; technical or other problem as indicated in ARes or RReq. A Attempts processing performed; not authenticated/verified, but a proof of attempted authentication/verification is provided. C Challenge required; additional authentication is required using the CReq/CRes. R Authentication/account verification rejected; issuer is rejecting authentication/verification and request that authorization not be attempted. D Challenge required; decoupled authentication confirmed. I Informational only; 3DS Requestor challenge preference acknowledged. Note: The CRes message can contain only a value of Y or N. Values of D and I are only applicable for 3DS version 2.2.0.

transactionXId

String

Server transaction Id generated by DS

cavv

String

This property is determined by the Access Control Server (ACS), and is filled after the call to SendAuthRequest (for a frictionless flow), or when the Results Request Message (RReq) is parsed using CheckResponse (for a challenge flow).

This property will be valid if the TransactionStatus is "Y" or "A". The value may be used to provide proof of authentication.

eci

String

This property is determined by the Access Control Server (ACS), and is filled after the call to SendAuthRequest (for a frictionless flow), or when the Results Request Message (RReq) is parsed using CheckResponse (for a challenge flow).

This property contains the two digit Electronic Commerce Indicator (ECI) value, which is to be submitted in a credit card authorization message. This value indicates to the processor that the customer data in the authorization message has been authenticated. The data contained within this property is only valid if the TransactionStatus is "Y" or "A".

200 OK with challenge
HTTP/1.1 200 OK
Content-Type: application/json;charset=UTF-8
Content-Length: 648

{
  "transactionStatus" : "C",
  "acsurl" : "acsurl.com",
  "creq" : "c29tZSBjcmVx",
  "challengeHtmlFormBase64" : "PGh0bWw+PFNDUklQVCBMQU5HVUFHRT0iSmF2YXNjcmlwdCI+ZnVuY3Rpb24gT25Mb2FkRXZlbnQoKXsgZG9jdW1lbnQuZG93bmxvYWRGb3JtLnN1Ym1pdCgpOyB9PC9TQ1JJUFQ+PGJvZHkgT25Mb2FkPSJPbkxvYWRFdmVudCgpOyI+PGZvcm0gbmFtZT0iZG93bmxvYWRGb3JtIiBhY3Rpb249Imh0dHBzOi8vYWNzdGVzdC5jb20iIG1ldGhvZD0iUE9TVCI+PElOUFVUIHR5cGU9ImhpZGRlbiIgbmFtZT0iY3JlcSIgdmFsdWU9ImNyZXEiPjxJTlBVVCB0eXBlPSJoaWRkZW4iIG5hbWU9InRocmVlRFNTZXNzaW9uRGF0YSIgdmFsdWU9InNvbWVFbmNvZGVkRGF0ZSI+PC9mb3JtPjwvYm9keT48L2h0bWw+",
  "threeDSSessionData" : "ZGY0NDJhODQtOGJkZS00MmQ3LWExMTUtMzUyNjNlZGY1MGFk"
}
Path Type Description

transactionStatus

String

Indicates whether a transaction qualifies as an authenticated transaction or account verification. Possible values are:

Y Authentication/account verification successful. N Not authenticated/account not verified; transaction denied. U Authentication/account verification could not be performed; technical or other problem as indicated in ARes or RReq. A Attempts processing performed; not authenticated/verified, but a proof of attempted authentication/verification is provided. C Challenge required; additional authentication is required using the CReq/CRes. R Authentication/account verification rejected; issuer is rejecting authentication/verification and request that authorization not be attempted. D Challenge required; decoupled authentication confirmed. I Informational only; 3DS Requestor challenge preference acknowledged. Note: The CRes message can contain only a value of Y or N. Values of D and I are only applicable for 3DS version 2.2.0.

acsurl

String

ACS Url - if challenge is required, data for building a form such as challengeHtmlFormBase64

creq

String

creq - if challenge is required, data for building a form such as challengeHtmlFormBase64

threeDSSessionData

String

creq - if challenge is required, data for building a form such as challengeHtmlFormBase64

challengeHtmlFormBase64

String

This field is a BASE64 encrypted html source file containing the challenge 3-D Secure frame

7.3. Authentication Details

GET /client/3ds/details/{uuid} Content Type: application/json, Authorization: Basic Auth
Method return details for authentication.
Success 3-D Secure Authentication. MPI return status:
Y (Full Authentication) - The customer was successfully authenticated.

Attempt 3-D Secure Authentication. MPI return status:
A (Successful Attempted Authentication) - Authentication was not available, but functionality was available to generate a proof of authentication attempt.

Challenge required
C Cardholder challenge required.
D Challenge required; decoupled authentication confirmed.

Information only
I Informational only; 3DS Requestor challenge preference acknowledged.

Error 3-D Secure Authentication results. MPI return one of statuses:
N (Authentication Failed) - The customer failed authentication, and the transaction is denied. The cardholder’s password (or other authentication information) failed validation, thus, the issuer is not able to authenticate the cardholder.
U (Unable to Complete Authentication) - Authentication could not be performed due to technical or other problems.
R Not authenticated because the issuer is rejecting authentication.

7.3.1. Request

GET /client/3ds/details/ee71d45e-840d-4c5c-99cd-5d8f06210fcd HTTP/1.1
Content-Type: application/json
Authorization: Basic bWVyY2hhbnQ6cGFzc3dvcmQ=
Host: java-staging.fenige.pl:8181
Table 26. /client/3ds/details/{cardAuthenticationId}
Parameter Description

cardAuthenticationId

Unique identifier for 3ds verification

7.3.2. Response

HTTP/1.1 200 OK
Content-Type: application/json;charset=UTF-8
Content-Length: 340

{
  "cardAuthenticationId" : "9ff7b620-1bce-4fb6-919b-e22eeac8ce06",
  "provider" : "MASTERCARD",
  "transactionStatus" : "Y",
  "cardAuthenticationStatus" : "AUTHENTICATION_FINISHED",
  "transactionXId" : "ef7c2605-78b0-4496-8ece-52b680e8a5c6",
  "cavv" : "jEu04WZns7pbARAApU4qgNdJTag",
  "eci" : "01",
  "transactionStatusReason" : "04"
}
Path Type Description

cardAuthenticationId

String

Unique identifier for 3ds verification

provider

String

Card’s provider

transactionStatus

String

Indicates whether a transaction qualifies as an authenticated transaction or account verification. Possible values are: Y Authentication/account verification successful. N Not authenticated/account not verified; transaction denied. U Authentication/account verification could not be performed; technical or other problem as indicated in ARes or RReq. A Attempts processing performed; not authenticated/verified, but a proof of attempted authentication/verification is provided. C Challenge required; additional authentication is required using the CReq/CRes. R Authentication/account verification rejected; issuer is rejecting authentication/verification and request that authorization not be attempted. D Challenge required; decoupled authentication confirmed. I Informational only; 3DS Requestor challenge preference acknowledged. Note: The CRes message can contain only a value of Y or N. Values of D and I are only applicable for 3DS version 2.2.0.

cardAuthenticationStatus

String

Card authentication status, possible values are: INITIALIZED, PREAUTHENTICATION_INITIATED, PREAUTHENTICATION_CONFIRMED, AUTHENTICATION_REJECTED, AUTHENTICATION, AUTHENTICATION_FINISHED

transactionXId

String

Server transaction Id generated by DS

cavv

String

This property is determined by the Access Control Server. This property will be valid if the TransactionStatus is "Y" or "A". The value may be used to provide proof of authentication.

eci

String

This property is determined by the Access Control Server. This property contains the two digit Electronic Commerce Indicator (ECI) value, which is to be submitted in a credit card authorization message. This value indicates to the processor that the customer data in the authorization message has been authenticated. The data contained within this property is only valid if the TransactionStatus is "Y" or "A".Please notice that ECI must be compatible with card provider.

transactionStatusReason

String

Provides information on why the Transaction Status field has the specified value. For MessageCategory 01 (PA), always included when TransactionStatus = N, U, or R. For MessageCategory 02 (NPA), as defined by the DS.

Possible values are:

01 - Card authentication failed, 02 - Unknown device, 03 - Unsupported device, 04 - Exceeds authentication frequency limit, 05 - Expired card, 06 - Invalid card number, 07 - Invalid transaction, 08 - No Card record, 09 - Security failure, 10 - Stolen card, 11 - Suspected fraud, 12 - Transaction not permitted to cardholder, 13 - Cardholder not enrolled in service, 14 - Transaction timed out at the ACS, 15 - Low confidence, 16 - Medium confidence, 17 - High confidence, 18 - Very high confidence, 19 - Exceeds ACS maximum challenges, 20 - Non-Payment transaction non supported, 21 - 3RI transaction not supported, 22 - ACS technical issue, 23 - Decoupled Authentication required by ACS but not requested by 3DS Requestor, 24 - 3DS Requestor Decoupled Max Expiry Time exceeded, 25 - Decoupled Authentication was provided insufficient time to authenticate cardholder. ACS will not make attempt, 26 - Authentication attempted but not performed by the cardholder, 27-79 - Reserved for future EMVCo use (values invalid until defined by EMVCo), 80-99 - Reserved for DS use

7.4. Status codes for 3DS 2.X verification methods

Code Messages HTTP Code HTTP STATUS

ERROR_3DS_2_X_FAILED

3DS 2.X method failed

500

INTERNAL_SERVER_ERROR

ERROR_MPI2_INTERNAL_ERROR

Some internal error occurred while trying to process 3DS 2.X request in MPI2

500

INTERNAL_SERVER_ERROR

ERROR_3DS_2_X_REQUIRED_DATA_NOT_COMPLETE

Required data for processing 3DS 2.X methods are not complete

422

UNPROCESSABLE_ENTITY

ERROR_3DS_2_X_DATA_MISMATCH

Three DS Method Data mismatch

422

UNPROCESSABLE_ENTITY

ERROR_3DS_2_X_DATA_PARSING

Error on parsing Three DS Method Data

422

UNPROCESSABLE_ENTITY

ERROR_3DS_2_X_CARD_NUMBER_NOT_ENROLLED

Card number not Enrolled in 3DS v2

422

UNPROCESSABLE_ENTITY

ERROR_3DS_2_X_INVALID_CARD_AUTH_ID

Invalid card authentication id

422

UNPROCESSABLE_ENTITY

ERROR_3DS_2_X_ISSUER_CARD_NOT_SUPPORTED

Issuer card is not supported

422

UNPROCESSABLE_ENTITY

ERROR_3DS_2_X_INVALID_CARD_NUMBER

Invalid card number

422

UNPROCESSABLE_ENTITY

ERROR_3DS_2_X_CARD_AUTH_NOT_EXISTS

Card Authentication not exists

404

NOT_FOUND

ERROR_3DS_2_X_PROTOCOL_VERSION_IS_NOT_SUPPORTED

Protocol version is not supported for card

422

UNPROCESSABLE_ENTITY

8. Determine currencies methods

8.1. Determine currency

POST /client/determine-currencies Content Type: application/vnd.determine-currencies.v2+json, Authorization: Basic Auth, API-TOKEN*
Method is used to determine currencies applied for given cards which are supported based on provided currencyType value.
*API-TOKEN is required for methods: DATACORE-PLAIN, DATACORE-DATACORE, DATACORE-PHONE

8.1.1. Request

PLAIN-PLAIN
POST /client/determine-currencies HTTP/1.1
Content-Type: application/vnd.determine-currencies.v2+json
Authorization: Basic bWVyY2hhbnQ6cGFzc3dvcmQ=
Host: java-staging.fenige.pl:8181
Content-Length: 195

{
  "currencyType" : "STANDARD",
  "sender" : {
    "type" : "PLAIN",
    "cardNumber" : "5575168861324712"
  },
  "receiver" : {
    "type" : "PLAIN",
    "cardNumber" : "5319838121111668"
  }
}
Table 27. Determine currencies
Path Type Validation Rule Description

currencyType

String

Required

@NotNull

Consist values: STANDARD, DEFAULT, CUSTOM, ALL

sender

Object

Required

@NotNull

Required configuration per request (PLAIN SENDER or DATACORE SENDER)

receiver

Object

Required

@NotNull

Required configuration per request (PLAIN RECEIVER, PHONE RECEIVER, DATACORE RECEIVER)

DATACORE-PLAIN
POST /client/determine-currencies HTTP/1.1
Content-Type: application/vnd.determine-currencies.v2+json
Authorization: Basic bWVyY2hhbnQ6cGFzc3dvcmQ=
API-TOKEN: d94NYa+xqRrazUPzSgYeJ6qR/MzIOb3IzePb7t9sWds=
Host: java-staging.fenige.pl:8181
Content-Length: 181

{
  "currencyType" : "STANDARD",
  "sender" : {
    "type" : "DATACORE",
    "cardId" : 99999
  },
  "receiver" : {
    "type" : "PLAIN",
    "cardNumber" : "5319838121111668"
  }
}
Table 28. Determine currencies
Path Type Validation Rule Description

currencyType

String

Required

@NotNull

Consist values: STANDARD, DEFAULT, CUSTOM, ALL

sender

Object

Required

@NotNull

Required configuration per request (PLAIN SENDER or DATACORE SENDER)

receiver

Object

Required

@NotNull

Required configuration per request (PLAIN RECEIVER, PHONE RECEIVER, DATACORE RECEIVER)

DATACORE-PHONE
POST /client/determine-currencies HTTP/1.1
Content-Type: application/vnd.determine-currencies.v2+json
Authorization: Basic bWVyY2hhbnQ6cGFzc3dvcmQ=
API-TOKEN: d94NYa+xqRrazUPzSgYeJ6qR/MzIOb3IzePb7t9sWds=
Host: java-staging.fenige.pl:8181
Content-Length: 177

{
  "currencyType" : "STANDARD",
  "sender" : {
    "type" : "DATACORE",
    "cardId" : 99999
  },
  "receiver" : {
    "type" : "PHONE",
    "phoneNumber" : "48123321123"
  }
}
Table 29. Determine currencies
Path Type Validation Rule Description

currencyType

String

Required

@NotNull

Consist values: STANDARD, DEFAULT, CUSTOM, ALL

sender

Object

Required

@NotNull

Required configuration per request (PLAIN SENDER or DATACORE SENDER)

receiver

Object

Required

@NotNull

Required configuration per request (PLAIN RECEIVER, PHONE RECEIVER, DATACORE RECEIVER)

DATACORE-DATACORE
POST /client/determine-currencies HTTP/1.1
Content-Type: application/vnd.determine-currencies.v2+json
Authorization: Basic bWVyY2hhbnQ6cGFzc3dvcmQ=
API-TOKEN: d94NYa+xqRrazUPzSgYeJ6qR/MzIOb3IzePb7t9sWds=
Host: java-staging.fenige.pl:8181
Content-Length: 167

{
  "currencyType" : "STANDARD",
  "sender" : {
    "type" : "DATACORE",
    "cardId" : 99999
  },
  "receiver" : {
    "type" : "DATACORE",
    "cardId" : 88888
  }
}
Table 30. Determine currencies
Path Type Validation Rule Description

currencyType

String

Required

@NotNull

Consist values: STANDARD, DEFAULT, CUSTOM, ALL

sender

Object

Required

@NotNull

Required configuration per request (PLAIN SENDER or DATACORE SENDER)

receiver

Object

Required

@NotNull

Required configuration per request (PLAIN RECEIVER, PHONE RECEIVER, DATACORE RECEIVER)

8.1.2. Response

Response status
Status Description

200 OK

Returned list of currency for sender and reciver.

200 OK - Error validation

Returned list of field name which has validation error.

Example HTTP Response
200 STANDARD
HTTP/1.1 200 OK
Content-Type: application/json;charset=UTF-8
Content-Length: 207

{
  "status" : "SUCCESS",
  "success" : {
    "senderDefaultCurrencies" : "PLN",
    "receiverDefaultCurrencies" : "GBP",
    "senderCurrencies" : [ "PLN", "EUR" ],
    "receiverCurrencies" : [ "GBP" ]
  }
}

Response fields

Path Type Description

status

String

Status

success.senderDefaultCurrencies

String

Default currency code for sender card

success.receiverDefaultCurrencies

String

Default currency code for receiver card

success.senderCurrencies

Array

Currencies supported by sender’s card

success.receiverCurrencies

Array

Currencies supported by receiver’s card

200 DEFAULT
HTTP/1.1 200 OK
Content-Type: application/json;charset=UTF-8
Content-Length: 120

{
  "status" : "SUCCESS",
  "success" : {
    "senderCurrencies" : [ "PLN" ],
    "receiverCurrencies" : [ "GBP" ]
  }
}

Response fields

Path Type Description

status

String

Status

success.senderCurrencies

Array

Currencies supported by sender’s card

success.receiverCurrencies

Array

Currencies supported by receiver’s card

200 CUSTOM
HTTP/1.1 200 OK
Content-Type: application/json;charset=UTF-8
Content-Length: 176

{
  "status" : "SUCCESS",
  "success" : {
    "senderCurrencies" : [ "EUR", "PLN", "CZK", "RUB", "UAH" ],
    "receiverCurrencies" : [ "EUR", "PLN", "CZK", "RUB", "UAH" ]
  }
}

Response fields

Path Type Description

status

String

Status

success.senderCurrencies

Array

Currencies supported by sender’s card

success.receiverCurrencies

Array

Currencies supported by receiver’s card

200 ALL
HTTP/1.1 200 OK
Content-Type: application/json;charset=UTF-8
Content-Length: 2458

{
  "status" : "SUCCESS",
  "success" : {
    "senderCurrencies" : [ "AED", "AFN", "ALL", "AMD", "ANG", "AOA", "ARS", "AUD", "AWG", "AZN", "BAM", "BBD", "BDT", "BGN", "BHD", "BIF", "BMD", "BND", "BOB", "BOV", "BRL", "BSD", "BTN", "BWP", "BYN", "BYR", "BZD", "CAD", "CDF", "CHE", "CHF", "CHW", "CLF", "CLP", "CNY", "COP", "COU", "CRC", "CUC", "CUP", "CVE", "CZK", "DJF", "DKK", "DOP", "DZD", "EGP", "ERN", "ETB", "EUR", "FJD", "FKP", "GBP", "GEL", "GHS", "GIP", "GMD", "GNF", "GTQ", "GYD", "HKD", "HNL", "HRK", "HTG", "HUF", "IDR", "ILS", "INR", "IQD", "IRR", "ISK", "JMD", "JOD", "JPY", "KES", "KGS", "KHR", "KMF", "KPW", "KRW", "KWD", "KYD", "KZT", "LAK", "LBP", "LKR", "LRD", "LSL", "LTL", "LYD", "MAD", "MDL", "MGA", "MKD", "MMK", "MNT", "MOP", "MRO", "MRU", "MUR", "MVR", "MWK", "MXN", "MXV", "MYR", "MZN", "NAD", "NGN", "NIO", "NOK", "NPR", "NZD", "OMR", "PAB", "PEN", "PGK", "PHP", "PKR", "PLN", "PYG", "QAR", "RON", "RSD", "RUB", "RUR", "RWF", "SAR", "SBD", "SCR", "SDG", "SEK", "SGD", "SHP", "SLL", "SOS", "SRD", "SSP", "STD", "STN", "SVC", "SYP", "SZL", "THB", "TJS", "TMT", "TND", "TOP", "TRY", "TTD", "TWD", "TZS", "UAH", "UGX", "USD", "USN", "USS", "UYI", "UYU", "UZS", "VEF", "VES", "VND", "VUV", "WST", "YER", "ZAR", "ZMW", "ZWL" ],
    "receiverCurrencies" : [ "AED", "AFN", "ALL", "AMD", "ANG", "AOA", "ARS", "AUD", "AWG", "AZN", "BAM", "BBD", "BDT", "BGN", "BHD", "BIF", "BMD", "BND", "BOB", "BOV", "BRL", "BSD", "BTN", "BWP", "BYN", "BYR", "BZD", "CAD", "CDF", "CHE", "CHF", "CHW", "CLF", "CLP", "CNY", "COP", "COU", "CRC", "CUC", "CUP", "CVE", "CZK", "DJF", "DKK", "DOP", "DZD", "EGP", "ERN", "ETB", "EUR", "FJD", "FKP", "GBP", "GEL", "GHS", "GIP", "GMD", "GNF", "GTQ", "GYD", "HKD", "HNL", "HRK", "HTG", "HUF", "IDR", "ILS", "INR", "IQD", "IRR", "ISK", "JMD", "JOD", "JPY", "KES", "KGS", "KHR", "KMF", "KPW", "KRW", "KWD", "KYD", "KZT", "LAK", "LBP", "LKR", "LRD", "LSL", "LTL", "LYD", "MAD", "MDL", "MGA", "MKD", "MMK", "MNT", "MOP", "MRO", "MRU", "MUR", "MVR", "MWK", "MXN", "MXV", "MYR", "MZN", "NAD", "NGN", "NIO", "NOK", "NPR", "NZD", "OMR", "PAB", "PEN", "PGK", "PHP", "PKR", "PLN", "PYG", "QAR", "RON", "RSD", "RUB", "RUR", "RWF", "SAR", "SBD", "SCR", "SDG", "SEK", "SGD", "SHP", "SLL", "SOS", "SRD", "SSP", "STD", "STN", "SVC", "SYP", "SZL", "THB", "TJS", "TMT", "TND", "TOP", "TRY", "TTD", "TWD", "TZS", "UAH", "UGX", "USD", "USN", "USS", "UYI", "UYU", "UZS", "VEF", "VES", "VND", "VUV", "WST", "YER", "ZAR", "ZMW", "ZWL" ]
  }
}

Response fields

Path Type Description

status

String

Status

success.senderCurrencies

Array

Currencies supported by sender’s card

success.receiverCurrencies

Array

Currencies supported by receiver’s card

200 OK - Error validation
HTTP/1.1 200 OK
Content-Type: application/json;charset=UTF-8

{
    "status": "ERROR_VALIDATION",
    "error": {
        "message": "Some information is missing or incorrect.",
        "errors": [
            {
                "field": "sender.cardNumber",
                "message": [
                    "may not be null"
                ]
            },
            {
                 "field": "sender.cardNumber",
                 "message": [
                  "invalid card number"
                 ]
            },
            {
                "field": "receiver.cardNumber",
                "message": [
                    "may not be null"
                ]
            },
            {
                 "field": "sender.cardNumber",
                  "message": [
                  "invalid card number"
                 ]
            }

        ]
    }
}
HTTP/1.1 200 OK
Content-Type: application/json;charset=UTF-8

{
    "status": "ERROR_INVALID_JSON",
    "error": {
        "message": "Some properties are invalid."
    }
}
HTTP/1.1 200 OK
Content-Type: application/json;charset=UTF-8

{
    "status": "SUCCESS",
    "success": {
        "senderCurrencies": [
            "UNDEFINED"
        ],
        "receiverCurrencies": [
            "UNDEFINED"
        ]
    }
}
Returned UNDEFINED when Merchant configuration doesn’t allow sent type or card number isn’t support.

8.2. Currency rate

GET /client/currency-rate/{from}/{to} Content Type: application/json, Authorization: Basic Auth
Method is used for determine currency rate for revaluation from funding to payment (lowerRate) and payment to funding (higherRate).
Notice that `lowerRate` is used to transaction processing.
Api Send-money allows users to select the direction of revaluation by providing specify type value in send-money request.
 1 - User by selecting type = SENDER defines amount of funding in given currency. This amount is collected from sender card in selected currency.
 2 - User by selecting type = RECEIVER defines amount of payment in given currency. This amount is transferred to receiver card in selected currency.
 In case there's need revaluation from one currency to another, system uses lowerRate for situation 1 and higherRate for situation 2.

8.2.1. Request

GET /client/currency-rate/USD/PLN HTTP/1.1
Content-Type: application/json
Authorization: Basic bWVyY2hhbnQ6cGFzc3dvcmQ=
Host: java-staging.fenige.pl:8181

8.2.2. Response

Response status
Status Description

200 OK

Returned currency rate.

200 OK - Error

200 Currency Invalid - Returned when currency is invalid.

200 Currency Rates Invalid - Returned when can’t calculate the rates to the given currencies.

200 Error something wrong - Returned currency rate error.

Example HTTP Response
200 OK
HTTP/1.1 200 OK
Content-Type: application/json;charset=UTF-8
Content-Length: 104

{
  "status" : "SUCCESS",
  "success" : {
    "lowerRate" : 3.735908,
    "higherRate" : 3.8522295
  }
}

Response fields

Path Type Description

status

String

Status of the revaluation

success

Object (Success)

Rate for revaluation

Object (Success)

Name Type Description

lowerRate

Decimal

Rate for revaluation from funding to payment

higherRate

Decimal

Rate for revaluation from payment to funding

200 OK - Error
HTTP/1.1 200 OK
Content-Type: application/json;charset=UTF-8

{
    "status": "CURRENCY_INVALID",
    "error": {
        "message": "Invalid currency."
    }
}
HTTP/1.1 200 OK
Content-Type: application/json;charset=UTF-8

{
    "status": "ERROR_VALIDATION",
    "error": {
        "message": "Some information is missing or incorrect.",
        "errors": [
            {
                "field": "sender.currency",
                "message": [
                    "Currency is not supported"
                ]
            },
            {
                "field": "receiver.currency",
                "message": [
                    "Currency is not supported"
                ]
            }
        ]
    }
}
HTTP Response - Currency Rates Invalid
HTTP/1.1 200 OK
Content-Type: application/json;charset=UTF-8

{
    "status": "CURRENCY_RATES_INVALID",
    "error": {
        "message": "Invalid currency rates."
    }
}
HTTP Response - Error something wrong
HTTP/1.1 200 OK
Content-Type: application/json;charset=UTF-8

{
    "status": "ERROR_SOMETHING_WRONG",
    "error": {
        "message": "Something went wrong."
    }
}

8.3. Currency rate by Provider

POST /client/currency-rate Content Type: application/json, Authorization: Basic Auth
Method is used for determine currency rate for revaluation from funding to payment (lowerRate) and payment to funding (higherRate).
Notice that `lowerRate` is used to transaction processing.

8.3.1. Request

POST /client/currency-rate HTTP/1.1
Content-Type: application/json
Authorization: Basic bWVyY2hhbnQ6cGFzc3dvcmQ=
Host: java-staging.fenige.pl:8181
Content-Length: 108

{
  "provider" : "MASTERCARD",
  "from" : "USD",
  "to" : "PLN",
  "effectiveDate" : "2017-06-05 12:00:00"
}
Table 31. Currency rate
Path Type Validation Rule Description

provider

String

Required

@NotNull

VISA or MASTERCARD or MAESTRO

from

String

Required

@NotNull

Source revaluation currency

to

String

Required

@NotNull

Destination revaluation currency

effectiveDate

String

Optional

Format: yyyy-MM-ddHH:mm:ss

Date from which the currency rate is needed. This is optional field. When there is no effectiveDate field, then currency rate is getting from request date. (Format "yyyy-MM-ddHH:mm:ss")

8.3.2. Response

Response status
Status Description

200 OK

Returned currency rate.

200 OK - Error

200 Currency Invalid - Returned when currency is invalid.

200 Currency Rates Invalid - Returned when can’t calculate the rates to the given currencies.

200 Error something wrong - Returned currency rate error.

Example HTTP Response
200 OK
HTTP/1.1 200 OK
Content-Type: application/json;charset=UTF-8
Content-Length: 104

{
  "status" : "SUCCESS",
  "success" : {
    "lowerRate" : 3.735908,
    "higherRate" : 3.8522295
  }
}

Response fields

Path Type Description

status

String

Status of the revaluation

success

Object (Success)

Rate for revaluation

Object (Success)

Name Type Description

lowerRate

Decimal

Rate for revaluation from funding to payment

higherRate

Decimal

Rate for revaluation from payment to funding

200 OK - Error
HTTP/1.1 200 OK
Content-Type: application/json;charset=UTF-8

{
    "status": "CURRENCY_INVALID",
    "error": {
        "message": "Invalid currency."
    }
}
HTTP/1.1 200 OK
Content-Type: application/json;charset=UTF-8

{
    "status": "ERROR_VALIDATION",
    "error": {
        "message": "Some information is missing or incorrect.",
        "errors": [
            {
                "field": "sender.currency",
                "message": [
                    "Currency is not supported"
                ]
            },
            {
                "field": "receiver.currency",
                "message": [
                    "Currency is not supported"
                ]
            }
        ]
    }
}
HTTP Response - Currency Rates Invalid
HTTP/1.1 200 OK
Content-Type: application/json;charset=UTF-8

{
    "status": "CURRENCY_RATES_INVALID",
    "error": {
        "message": "Invalid currency rates."
    }
}
HTTP Response - Error something wrong
HTTP/1.1 200 OK
Content-Type: application/json;charset=UTF-8

{
    "status": "ERROR_SOMETHING_WRONG",
    "error": {
        "message": "Something went wrong."
    }
}

8.4. Currency for card

POST /client/currency-for-card Content Type: application/json, Authorization: Basic Auth
Method is used to determine currencies applied for given card which are supported based on provided type value.

8.4.1. Request

STANDARD
Table 32. Determine currency
Path Type Validation Rule Description

type

String

Required

@NotNull

Consist values: STANDARD, DEFAULT, CUSTOM, ALL

cardNumber

String

Required

@NotNull

Card number

POST /client/currency-for-card HTTP/1.1
Content-Type: application/json
Authorization: Basic bWVyY2hhbnQ6cGFzc3dvcmQ=
Host: java-staging.fenige.pl:8181
Content-Length: 62

{
  "type" : "STANDARD",
  "cardNumber" : "5575168861324712"
}
DEFAULT
Table 33. Determine currency
Path Type Validation Rule Description

type

String

Required

@NotNull

Consist values: STANDARD, DEFAULT, CUSTOM, ALL

cardNumber

String

Required

@NotNull

Card number

POST /client/currency-for-card HTTP/1.1
Content-Type: application/json
Authorization: Basic bWVyY2hhbnQ6cGFzc3dvcmQ=
Host: java-staging.fenige.pl:8181
Content-Length: 61

{
  "type" : "DEFAULT",
  "cardNumber" : "5575168861324712"
}
CUSTOM
Table 34. Determine currency
Path Type Validation Rule Description

type

String

Required

@NotNull

Consist values: STANDARD, DEFAULT, CUSTOM, ALL

cardNumber

String

Required

@NotNull

Card number

POST /client/currency-for-card HTTP/1.1
Content-Type: application/json
Authorization: Basic bWVyY2hhbnQ6cGFzc3dvcmQ=
Host: java-staging.fenige.pl:8181
Content-Length: 60

{
  "type" : "CUSTOM",
  "cardNumber" : "5575168861324712"
}
ALL
Table 35. Determine currency
Path Type Validation Rule Description

type

String

Required

@NotNull

Consist values: STANDARD, DEFAULT, CUSTOM, ALL

cardNumber

String

Required

@NotNull

Card number

POST /client/currency-for-card HTTP/1.1
Content-Type: application/json
Authorization: Basic bWVyY2hhbnQ6cGFzc3dvcmQ=
Host: java-staging.fenige.pl:8181
Content-Length: 57

{
  "type" : "ALL",
  "cardNumber" : "5575168861324712"
}

8.4.2. Response

Response status
Status Description

200 OK

Returned list of currency for the given card.

200 OK - Error validation

Returned list of field name which has validation error.

Example HTTP Response
200 OK - STANDARD
HTTP/1.1 200 OK
Content-Type: application/json;charset=UTF-8
Content-Length: 83

{
  "defaultCurrency" : "EUR",
  "currencyCodes" : [ "EUR", "PLN", "CHF", "CZK" ]
}

Response fields

Path Type Description

currencyCodes

Array

Currencies supported by card

defaultCurrency

String

Default currency code for card

200 OK - DEFAULT
HTTP/1.1 200 OK
Content-Type: application/json;charset=UTF-8
Content-Length: 33

{
  "currencyCodes" : [ "EUR" ]
}

Response fields

Path Type Description

currencyCodes

Array

Currencies supported by card

200 OK - CUSTOM
HTTP/1.1 200 OK
Content-Type: application/json;charset=UTF-8
Content-Length: 82

{
  "currencyCodes" : [ "EUR", "PLN", "JOD", "CZK", "RUB", "UAH", "CHF", "JMD" ]
}

Response fields

Path Type Description

currencyCodes

Array

Currencies supported by card

200 OK - ALL
HTTP/1.1 200 OK
Content-Type: application/json;charset=UTF-8
Content-Length: 1202

{
  "currencyCodes" : [ "AED", "AFN", "ALL", "AMD", "ANG", "AOA", "ARS", "AUD", "AWG", "AZN", "BAM", "BBD", "BDT", "BGN", "BHD", "BIF", "BMD", "BND", "BOB", "BOV", "BRL", "BSD", "BTN", "BWP", "BYN", "BYR", "BZD", "CAD", "CDF", "CHE", "CHF", "CHW", "CLF", "CLP", "CNY", "COP", "COU", "CRC", "CUC", "CUP", "CVE", "CZK", "DJF", "DKK", "DOP", "DZD", "EGP", "ERN", "ETB", "EUR", "FJD", "FKP", "GBP", "GEL", "GHS", "GIP", "GMD", "GNF", "GTQ", "GYD", "HKD", "HNL", "HRK", "HTG", "HUF", "IDR", "ILS", "INR", "IQD", "IRR", "ISK", "JMD", "JOD", "JPY", "KES", "KGS", "KHR", "KMF", "KPW", "KRW", "KWD", "KYD", "KZT", "LAK", "LBP", "LKR", "LRD", "LSL", "LTL", "LYD", "MAD", "MDL", "MGA", "MKD", "MMK", "MNT", "MOP", "MRO", "MRU", "MUR", "MVR", "MWK", "MXN", "MXV", "MYR", "MZN", "NAD", "NGN", "NIO", "NOK", "NPR", "NZD", "OMR", "PAB", "PEN", "PGK", "PHP", "PKR", "PLN", "PYG", "QAR", "RON", "RSD", "RUB", "RUR", "RWF", "SAR", "SBD", "SCR", "SDG", "SEK", "SGD", "SHP", "SLL", "SOS", "SRD", "SSP", "STD", "STN", "SVC", "SYP", "SZL", "THB", "TJS", "TMT", "TND", "TOP", "TRY", "TTD", "TWD", "TZS", "UAH", "UGX", "USD", "USN", "USS", "UYI", "UYU", "UZS", "VEF", "VES", "VND", "VUV", "WST", "YER", "ZAR", "ZMW", "ZWL" ]
}

Response fields

Path Type Description

currencyCodes

Array

Currencies supported by card

200 OK - Error validation
HTTP/1.1 200 OK
Content-Type: application/json;charset=UTF-8

{
	"status": "ERROR_VALIDATION",
	"error": {
		"message": "Some information is missing or incorrect.",
		"errors": [{
				"field": "type",
				"message": [
					"may not be null"
				]
		    }
		]
	}
}
HTTP/1.1 200 OK
Content-Type: application/json;charset=UTF-8

{
    "status": "ERROR_INVALID_JSON",
    "error": {
        "message": "Some properties are invalid."
    }
}
HTTP/1.1 200 OK
Content-Type: application/json;charset=UTF-8

{
	"status": "INVALID_CARD_NO",
	"error": {
	       "message": "Card number is required."
	}
}
HTTP/1.1 200 OK
Content-Type: application/json;charset=UTF-8

{
    "currencyCodes": [
        "UNDEFINED"
    ]
}
Returned UNDEFINED when Merchant configuration doesn’t allow sent type or card number isn’t support.

8.5. Merchant currency configuration

Merchant can have 4 types of configuration:

  • STANDARD - user can only perform transactions in the currencies assigned to the card and that is currency default and currency primary from 1 to 4. Some cards have more than one currency assigned.

  • DEFAULT - user can only perform transactions in the one single currency assigned to the card and that is default card currency.

  • CUSTOM - user may perform transactions in custom currencies selected by your administrator.

  • ALL - all currencies are allowed for transactions.

9. Calculate commission

POST /client/calculate-commission Content Type: application/vnd.calculate-commission.v2+json, Authentication: Basic Auth, API-TOKEN*
This method is used to receive information about the commission that will be charged for the transaction.
Additional description:
- If value the field: "reconciliationType" is "PLUS", the commission during the transaction will be added to the amount sent (the amount charged from the sender will be increased by a commission).
- If value the field: "reconciliationType" is "MINUS", then the commission during the transaction will be deducted from the amount received (the amount that will be received by the receiver will be reduced by the commission).
- If value the field: "reconciliationType" is "DEPOSITED", the commission during the transaction will neither be subtracted nor added (the amount to be received by the receiver is the same as the amount sent).
In addition, the merchant may specify in the field: type two values (SENDER OR RECEIVER). After selecting the value: "SENDER", the transaction will be sent in the amount indicated in the field: amount. Whereas after choosing the value: "RECEIVER", the transaction will be received in the amount indicated in the field: amount.
The method allows merchant to calculate commissions for the currencies that have been entered.
*API-TOKEN is required for methods: PLAIN-CASH, DATACORE-PLAIN, DATACORE-PHONE, DATACORE-CASH, DATACORE-DATACORE

9.1. Request

PLAIN-PLAIN
POST /client/calculate-commission HTTP/1.1
Content-Type: application/vnd.calculate-commission.v2+json
Authorization: Basic bWVyY2hhbnQ6cGFzc3dvcmQ=
Host: java-staging.fenige.pl:8181
Content-Length: 251

{
  "amount" : 100,
  "type" : "SENDER",
  "sender" : {
    "type" : "PLAIN",
    "currency" : "PLN",
    "cardNumber" : "5117964247989169"
  },
  "receiver" : {
    "type" : "PLAIN",
    "currency" : "PLN",
    "cardNumber" : "5575167825713507"
  }
}
Table 36. Calculate commission
Path Type Validation Rule Description

amount

Number

Required

@NotNull, @Min(100)

The total transfer amount (in pennies)

type

String

Required

@NotNull

Value of (SENDER or RECEIVER)

sender

Object

Required

@NotNull

Required configuration per request (PLAIN SENDER, DATACORE SENDER, CASH SENDER)

receiver

Object

Required

@NotNull

Required configuration per request (PLAIN RECEIVER, PHONE RECEIVER, DATACORE RECEIVER, CASH RECEIVER)

PLAIN-CASH
POST /client/calculate-commission HTTP/1.1
Content-Type: application/vnd.calculate-commission.v2+json
Authorization: Basic bWVyY2hhbnQ6cGFzc3dvcmQ=
API-TOKEN: d94NYa+xqRrazUPzSgYeJ6qR/MzIOb3IzePb7t9sWds=
Host: java-staging.fenige.pl:8181
Content-Length: 211

{
  "amount" : 100,
  "type" : "SENDER",
  "sender" : {
    "type" : "PLAIN",
    "currency" : "PLN",
    "cardNumber" : "5117964247989169"
  },
  "receiver" : {
    "type" : "CASH",
    "currency" : "PLN"
  }
}
Table 37. Calculate commission
Path Type Validation Rule Description

amount

Number

Required

@NotNull, @Min(100)

The total transfer amount (in pennies)

type

String

Required

@NotNull

Value of (SENDER or RECEIVER)

sender

Object

Required

@NotNull

Required configuration per request (PLAIN SENDER, DATACORE SENDER, CASH SENDER)

receiver

Object

Required

@NotNull

Required configuration per request (PLAIN RECEIVER, PHONE RECEIVER, DATACORE RECEIVER, CASH RECEIVER)

DATACORE-PLAIN
POST /client/calculate-commission HTTP/1.1
Content-Type: application/vnd.calculate-commission.v2+json
Authorization: Basic bWVyY2hhbnQ6cGFzc3dvcmQ=
API-TOKEN: d94NYa+xqRrazUPzSgYeJ6qR/MzIOb3IzePb7t9sWds=
Host: java-staging.fenige.pl:8181
Content-Length: 236

{
  "amount" : 100,
  "type" : "SENDER",
  "sender" : {
    "type" : "DATACORE",
    "currency" : "PLN",
    "cardId" : 8888
  },
  "receiver" : {
    "type" : "PLAIN",
    "currency" : "PLN",
    "cardNumber" : "5575167825713507"
  }
}
Table 38. Calculate commission
Path Type Validation Rule Description

amount

Number

Required

@NotNull, @Min(100)

The total transfer amount (in pennies)

type

String

Required

@NotNull

Value of (SENDER or RECEIVER)

sender

Object

Required

@NotNull

Required configuration per request (PLAIN SENDER, DATACORE SENDER, CASH SENDER)

receiver

Object

Required

@NotNull

Required configuration per request (PLAIN RECEIVER, PHONE RECEIVER, DATACORE RECEIVER, CASH RECEIVER)

DATACORE-PHONE
POST /client/calculate-commission HTTP/1.1
Content-Type: application/vnd.calculate-commission.v2+json
Authorization: Basic bWVyY2hhbnQ6cGFzc3dvcmQ=
API-TOKEN: d94NYa+xqRrazUPzSgYeJ6qR/MzIOb3IzePb7t9sWds=
Host: java-staging.fenige.pl:8181
Content-Length: 232

{
  "amount" : 100,
  "type" : "SENDER",
  "sender" : {
    "type" : "DATACORE",
    "currency" : "PLN",
    "cardId" : 8888
  },
  "receiver" : {
    "type" : "PHONE",
    "currency" : "PLN",
    "phoneNumber" : "48123123123"
  }
}
Table 39. Calculate commission
Path Type Validation Rule Description

amount

Number

Required

@NotNull, @Min(100)

The total transfer amount (in pennies)

type

String

Required

@NotNull

Value of (SENDER or RECEIVER)

sender

Object

Required

@NotNull

Required configuration per request (PLAIN SENDER, DATACORE SENDER, CASH SENDER)

receiver

Object

Required

@NotNull

Required configuration per request (PLAIN RECEIVER, PHONE RECEIVER, DATACORE RECEIVER, CASH RECEIVER)

DATACORE-CASH
POST /client/calculate-commission HTTP/1.1
Content-Type: application/vnd.calculate-commission.v2+json
Authorization: Basic bWVyY2hhbnQ6cGFzc3dvcmQ=
API-TOKEN: d94NYa+xqRrazUPzSgYeJ6qR/MzIOb3IzePb7t9sWds=
Host: java-staging.fenige.pl:8181
Content-Length: 196

{
  "amount" : 100,
  "type" : "SENDER",
  "sender" : {
    "type" : "DATACORE",
    "currency" : "PLN",
    "cardId" : 8888
  },
  "receiver" : {
    "type" : "CASH",
    "currency" : "PLN"
  }
}
Table 40. Calculate commission
Path Type Validation Rule Description

amount

Number

Required

@NotNull, @Min(100)

The total transfer amount (in pennies)

type

String

Required

@NotNull

Value of (SENDER or RECEIVER)

sender

Object

Required

@NotNull

Required configuration per request (PLAIN SENDER, DATACORE SENDER, CASH SENDER)

receiver

Object

Required

@NotNull

Required configuration per request (PLAIN RECEIVER, PHONE RECEIVER, DATACORE RECEIVER, CASH RECEIVER)

DATACORE-DATACORE
POST /client/calculate-commission HTTP/1.1
Content-Type: application/vnd.calculate-commission.v2+json
Authorization: Basic bWVyY2hhbnQ6cGFzc3dvcmQ=
API-TOKEN: d94NYa+xqRrazUPzSgYeJ6qR/MzIOb3IzePb7t9sWds=
Host: java-staging.fenige.pl:8181
Content-Length: 221

{
  "amount" : 100,
  "type" : "SENDER",
  "sender" : {
    "type" : "DATACORE",
    "currency" : "PLN",
    "cardId" : 8888
  },
  "receiver" : {
    "type" : "DATACORE",
    "currency" : "PLN",
    "cardId" : 9999
  }
}
Table 41. Calculate commission
Path Type Validation Rule Description

amount

Number

Required

@NotNull, @Min(100)

The total transfer amount (in pennies)

type

String

Required

@NotNull

Value of (SENDER or RECEIVER)

sender

Object

Required

@NotNull

Required configuration per request (PLAIN SENDER, DATACORE SENDER, CASH SENDER)

receiver

Object

Required

@NotNull

Required configuration per request (PLAIN RECEIVER, PHONE RECEIVER, DATACORE RECEIVER, CASH RECEIVER)

CASH-PLAIN
POST /client/calculate-commission HTTP/1.1
Content-Type: application/vnd.calculate-commission.v2+json
Authorization: Basic bWVyY2hhbnQ6cGFzc3dvcmQ=
Host: java-staging.fenige.pl:8181
Content-Length: 211

{
  "amount" : 100,
  "type" : "SENDER",
  "sender" : {
    "type" : "CASH",
    "currency" : "PLN"
  },
  "receiver" : {
    "type" : "PLAIN",
    "currency" : "PLN",
    "cardNumber" : "5575167825713507"
  }
}
Table 42. Calculate commission
Path Type Validation Rule Description

amount

Number

Required

@NotNull, @Min(100)

The total transfer amount (in pennies)

type

String

Required

@NotNull

Value of (SENDER or RECEIVER)

sender

Object

Required

@NotNull

Required configuration per request (PLAIN SENDER, DATACORE SENDER, CASH SENDER)

receiver

Object

Required

@NotNull

Required configuration per request (PLAIN RECEIVER, PHONE RECEIVER, DATACORE RECEIVER, CASH RECEIVER)

CASH-PHONE
POST /client/calculate-commission HTTP/1.1
Content-Type: application/vnd.calculate-commission.v2+json
Authorization: Basic bWVyY2hhbnQ6cGFzc3dvcmQ=
Host: java-staging.fenige.pl:8181
Content-Length: 207

{
  "amount" : 100,
  "type" : "SENDER",
  "sender" : {
    "type" : "CASH",
    "currency" : "PLN"
  },
  "receiver" : {
    "type" : "PHONE",
    "currency" : "PLN",
    "phoneNumber" : "48123123123"
  }
}
Table 43. Calculate commission
Path Type Validation Rule Description

amount

Number

Required

@NotNull, @Min(100)

The total transfer amount (in pennies)

type

String

Required

@NotNull

Value of (SENDER or RECEIVER)

sender

Object

Required

@NotNull

Required configuration per request (PLAIN SENDER, DATACORE SENDER, CASH SENDER)

receiver

Object

Required

@NotNull

Required configuration per request (PLAIN RECEIVER, PHONE RECEIVER, DATACORE RECEIVER, CASH RECEIVER)

9.2. Response

9.2.1. Response status

Status

Description

200 OK

Returned if the calculate commision completes successfully.

200 OK - Error validation

Returned list of field name which has validation error.

9.2.2. Example HTTP Response

200 OK
HTTP/1.1 200 OK
Content-Type: application/json;charset=UTF-8
Content-Length: 911

{
  "status" : "SUCCESS",
  "success" : {
    "commission" : 5,
    "transactionCommissions" : [ {
      "value" : 50,
      "bigDecimalValue" : 0.5,
      "currencyExponent" : 2,
      "currency" : "PLN",
      "commissionConfiguration" : {
        "currency" : "PLN",
        "commissionType" : "PROVISION",
        "reconciliationType" : "PLUS",
        "geographicScope" : "DOMESTIC",
        "transactionType" : {
          "id" : "funding",
          "name" : "MoneySend Funding"
        }
      }
    } ],
    "revaluationResult" : {
      "revaluationFundingAmount" : 100,
      "bigDecimalRevaluationFundingAmount" : 1,
      "fundingCurrency" : "PLN",
      "revaluationPaymentAmount" : 100,
      "bigDecimalRevaluationPaymentAmount" : 1,
      "paymentCurrency" : "PLN",
      "determineCurrencyRate" : {
        "from" : "PLN",
        "to" : "PLN",
        "currencyRate" : "1"
      }
    }
  }
}

Response fields

Path Type Description

status

String

Status

success.commission

Number

Currencies supported by sender’s card

success.transactionCommissions

Array

Currencies supported by sender’s card

success.revaluationResult

Object

Currencies supported by receiver’s card

TransactionCommissions

Path Type Description

value

Long

Value of calculated commission (in pennies) depends on the above parameters

bigDecimalValue

BigDecimal

Value of calculated commission depends on the above parameters

currencyExponent

Long

Decimal places in currency

currency

String

Commission value currency code the same as sender’s card currency when commission

is for Funding or the same as receiver’s card currency when commission is for Payment

commissionConfiguration

Object (CommissionConfiguration)

Configuration for commission

CommissionConfiguration

Path Type Description

currency

String

Partner/Merchant currency

commissionType

String

Commission type (PARTNER, FENIGE, ACCEPTANCE NETWORK)

reconciliationType

String

PLUS - means that the commission will be added to the amount sent (the amount charged from the sender will be increased by a commission).,

MINUS - means that the commission will be deducted from the amount received (the amount that will be received by the receiver will be reduced by the commission),

DEPOSITED - means that the commission during the transaction will neither be subtracted nor added (the amount to be received by the receiver is the same as the amount sent).

geographicScope

String

Type of transaction scope (DOMESTIC, CROSSBORDER)

transactionType

Object (TransactionType)

Transaction type for MoneySend Funding or MoneySend Payment

TransactionType

Path Type Description

id

String

Id of transaction: funding or payment

name

String

Name of transaction’s type: MoneySend Funding or MoneySend Payment

RevaluationResult

Path Type Description

revaluationFundingAmount

Long

Amount (in pennies) of funding transaction in fundingCurrency

bigDecimalRevaluationFundingAmount

BigDecimal

Amount of funding transaction in fundingCurrency

fundingCurrency

String

Currency code the same as sender’s card currency

revaluationPaymentAmount

Long

Amount (in pennies) of payment transaction in paymentCurrency

bigDecimalRevaluationPaymentAmount

BigDecimal

Amount of payment transaction in paymentCurrency

paymentCurrency

String

Currency code the same as receiver’s card currency

determineCurrencyRate

Object (DetermineCurrencyRate)

Details about conversion

DetermineCurrencyRate

Path Type Description

from

Long

Currency which was conversion from

to

Long

Resulted currency

masterCardCurrencyRate

BigDecimal

Currency rate

200 OK - Error validation
HTTP/1.1 200 OK
Content-Type: application/json;charset=UTF-8

{
    "status": "ERROR_VALIDATION",
    "error": {
        "message": "Some information is missing or incorrect.",
        "errors": [
            {
                "field": "amount",
                "message": [
                    "may not be null"
                ]
            },
            {
                "field": "type",
                "message": [
                    "may not be null"
            },
            {
                "field": "receiver.cardNumber",
                "message": [
                    "may not be null"
                ]
            },
            {
                "field": "receiver.currency",
                "message": [
                    "may not be null"
                ]
            },
            {
                "field": "sender.cardNumber",
                "message": [
                    "may not be null"
                ]
            },
            {
                "field": "sender.currency",
                "message": [
                    "may not be null"
                ]
            }
        ]
    }
}
HTTP/1.1 200 OK
Content-Type: application/json;charset=UTF-8

{
    "status": "ERROR_INVALID_JSON",
    "error": {
        "message": "Some properties are invalid."
    }
}
200 OK - Error
HTTP/1.1 200 OK
Content-Type: application/json;charset=UTF-8

{
    "status": "ERROR_WHILE_GETTING_COUNTRY_CODE",
    "error": {
        "message": "Could not get card country code."
    }
}

10. Check card’s provider

POST /client/card/provider Content Type: application/json, Authorization: Basic Auth
This method is used to check the card provider, for example: VISA or MASTERCARD.

10.1. Request

POST /client/card/provider HTTP/1.1
Content-Type: application/json
Authorization: Basic bWVyY2hhbnQ6cGFzc3dvcmQ=
Host: java-staging.fenige.pl:8181
Content-Length: 39

{
  "cardNumber" : "5117964247989169"
}

10.2. Response

Response status
Status Description

200 OK

Returned card’s provider.

Example Response
200 OK
HTTP/1.1 200 OK
Content-Type: application/json;charset=UTF-8
Content-Length: 31

{
  "provider" : "MASTERCARD"
}

Response fields

Path Type Description

provider

String

Card’s provider

11. Check deposit state

11.1. Check deposit state

GET /client/merchant/deposit Content Type: application/json, Authorization: Basic Auth
This method is appropriate only for CASH-CARD transaction model.
By use this endpoint it is possible to retrieve current deposit state in settlement currency.

11.1.1. Request

GET /client/merchant/deposit HTTP/1.1
Authorization: Basic bWVyY2hhbnQ6cGFzc3dvcmQ=
Host: java-staging.fenige.pl:8181

11.1.2. Response

Response status
Status Description

200 OK

Returned state of deposit.

Example Response
200 OK
HTTP/1.1 200 OK
Content-Type: application/json;charset=UTF-8
Content-Length: 33

{
  "remainingDeposit" : 150.99
}

Response fields

Path Type Description

remainingDeposit

Number

The amount remaining on deposit (in settlement currency)

12. User authentication

12.1. Login

POST /client/login Content-Type: application/json
This method can be use to login to Datacenter by user's credentials. The user can be blocked in the system.
Before using the login method, you must call 12.1 Add user which adds user to datacenter database.
Flow Log User

From January 2021, there is an internal functionality to restrict access for the Merchant to specific method. The Fenige employee can disable access to a given endpoint, then the HTTP status 403 FORBIDDEN will be returned. The Merchant will be informed about each access restriction action.

12.1.1. Request

HTTP Request
POST /client/login HTTP/1.1
Content-Type: application/json
Content-Length: 62
Host: java-staging.fenige.pl:8181

{
  "id" : "mark.smith@fenige.pl",
  "password" : "aaiHyF2b"
}
Table 44. Login request fields
Path Type Constraints Description

id

String

@Length must be between 1 and 128 inclusive, @Must not be blank, @Must not be null

User id

password

String

@Length must be between 1 and 128 inclusive, @Must not be blank, @Must not be null

User’s password

12.1.2. Response

200 OK
HTTP Response
HTTP/1.1 200 OK
Set-Cookie: JSESSIONID=8AA95CBD31F73F4630FD64C325BFCC5A; Path=/; HttpOnly
X-Content-Type-Options: nosniff
X-XSS-Protection: 1; mode=block
Cache-Control: no-cache, no-store, max-age=0, must-revalidate
Pragma: no-cache
Expires: 0
X-Frame-Options: DENY
Content-Type: application/json;charset=UTF-8
Transfer-Encoding: chunked
Date: Thu, 06 May 2021 13:57:37 GMT
Content-Length: 365

{
  "status" : "SUCCESS",
  "success" : {
    "user" : {
      "id" : 6366,
      "firstName" : "Mark",
      "lastName" : "Smith",
      "phone" : "48570100200",
      "email" : "mark.smith@fenige.pl",
      "personalId" : "ADFR34453",
      "gender" : "M",
      "birthDate" : "1990-11-24"
    },
    "token" : "d94NYa+xqRrazUPzSgYeJ6qR/MzIOb3IzePb7t9sWds="
  }
}
Table 45. Response fields
Path Type Description

success.user.id

Number

Unique user’s id

success.user.firstName

String

User’s first name

success.user.lastName

String

User’s last name

success.user.phone

String

User’s phone number

success.user.email

String

User’s e-mail address

success.user.personalId

String

User personal id (e.g. identity document number)

success.user.gender

String

User gender

success.user.birthDate

String

User birthDate

success.token

String

Unique generated token that allows user to make other requests

status

String

Status from Fenige system

200 OK - Error
HTTP Response
HTTP/1.1 200 OK
Content-Type: application/json

{
    "status": "ERROR_USER_NOTFOUND",
    "error": {
        "message": "Some information is missing or incorrect."
    }
}
HTTP/1.1 200 OK
Set-Cookie: JSESSIONID=8776934BB6CF9A132057C38F80AD6A20; Path=/; HttpOnly
X-Content-Type-Options: nosniff
X-XSS-Protection: 1; mode=block
Cache-Control: no-cache, no-store, max-age=0, must-revalidate
Pragma: no-cache
Expires: 0
X-Frame-Options: DENY
Content-Type: application/json;charset=UTF-8
Transfer-Encoding: chunked
Date: Thu, 06 May 2021 13:57:38 GMT
Content-Length: 124

{
  "status" : "USER_BLOCKED_IN_DATACENTER",
  "error" : {
    "message" : "Some information is missing or incorrect."
  }
}
200 OK - Error Validation
HTTP Response
HTTP/1.1 200 OK
Content-Type: application/json

{
    "status": "ERROR_VALIDATION",
    "error": {
        "message": "Some information is missing or incorrect.",
        "errors": [
            {
                "field": "userPasswordIn.id",
                "message": [
                    "may not be null",
                    "may not be empty"
                ]
            },
            {
                "field": "userPasswordIn.password",
                "message": [
                    "may not be null",
                    "may not be empty"
                ]
            },
            {
                "field": "userPasswordIn.id",
                "message": [
                    "length must be between 1 and 128"
                ]
            },
            {
                 "field": "userPasswordIn.password",
                 "message": [
                 "length must be between 1 and 128"
                 ]
            }
        ]
    }
}

12.2. Logout

POST /client/logout Content-Type: application/json, Authorization: Basic Auth, API-TOKEN
This method can be use to logout from Datacenter by user's credentials.
This request must have header calling "API-TOKEN" and his value must be the same as token from the Log User method.

12.2.1. Request

HTTP Request
POST /client/logout HTTP/1.1
Authorization: Basic dGVzdF9tZXJjaGFudDpwYXNzd29yZA==
API-TOKEN: d94NYa+xqRrazUPzSgYeJ6qR/MzIOb3IzePb7t9sWds=
Content-Type: application/json
Host: java-staging.fenige.pl:8181
Table 46. Request headers
Name Description

Authorization

Basic auth credentials

API-TOKEN

User’s token to authenticate in service

12.2.2. Response

Response status
Table 47. Response status
Status Description

200 OK

Returned when user successfully logout.

200 OK - Error

Returned when API-TOKEN was missing.

401 - Unauthorized

Returned when API-TOKEN was broken.

200 OK
HTTP Response
HTTP/1.1 200 OK
Set-Cookie: JSESSIONID=D412DD751E506B7E426963DC782E0297; Path=/; HttpOnly
X-Content-Type-Options: nosniff
X-XSS-Protection: 1; mode=block
Cache-Control: no-cache, no-store, max-age=0, must-revalidate
Pragma: no-cache
Expires: 0
X-Frame-Options: DENY
Content-Type: application/json;charset=UTF-8
Transfer-Encoding: chunked
Date: Thu, 06 May 2021 13:57:39 GMT
Content-Length: 46

{
  "status" : "SUCCESS",
  "success" : true
}
200 OK - Error
HTTP Response
HTTP/1.1 200 OK
Content-Type: application/json

{
    "status": "ERROR_SOMETHING_WRONG",
    "error": {
        "message": "Something went wrong."
    }
}
401 Unauthorized
HTTP Response
HTTP/1.1 401 Unauthorized
Content-Type: application/json

{
    "timestamp": 1531722486423,
    "status": 401,
    "error": "Unauthorized",
    "message": "ERROR_USER_NOTFOUND",
    "path": "/client/logout"
}

13. User management

13.1. Add user

POST /client/users Content-Type: application/json, Authorization: Basic Auth
This method can be use to add new user in Datacenter.
Notice that if 'verified' field is set as `true`, KYC_3 level will set for each transaction of this user (only for DATACENTER transactions).
Flow Add User

From January 2021, there is an internal functionality to restrict access for the Merchant to specific method. The Fenige employee can disable access to a given endpoint, then the HTTP status 403 FORBIDDEN will be returned. The Merchant will be informed about each access restriction action.

13.1.1. Request

STANDARD
HTTP Request
POST /client/users HTTP/1.1
Authorization: Basic dGVzdF9tZXJjaGFudDpwYXNzd29yZA==
Content-Type: application/json
Content-Length: 381
Host: java-staging.fenige.pl:8181

{
  "firstName" : "Mark",
  "lastName" : "Smith",
  "phone" : "48500600800",
  "email" : "mark.smith@fenige.pl",
  "password" : "LxTSuVPJ",
  "birthDate" : "10021994",
  "gender" : "M",
  "street" : "Olszewskiego",
  "flatNumber" : "93",
  "houseNumber" : "283",
  "postalCode" : "21-023",
  "city" : "Lublin",
  "country" : "PL",
  "personalId" : "AAA00000",
  "verified" : true
}
Table 48. Request headers
Name Description

Authorization

Basic auth credentials

Table 49. Add user request fields
Path Type Constraints Description

firstName

String

Required

User’s first name

lastName

String

Required

User’s last name

phone

String

Required

User’s phone number

email

String

Required

User’s email used to log in system

password

String

Required

User’s password

birthDate

String

Optional

Birth date in format ddmmyyyy

gender

String

Optional

Gender M/F

street

String

Required

User’s street

flatNumber

String

Optional

User’s flat number

houseNumber

String

Required

User’s house number

postalCode

String

Required

User’s postal code

city

String

Required

User’s city

country

String

Optional

User country code in accordance with ISO 3166-1

personalId

String

@Optional

User personal id (e.g. identity document number)

verified

Boolean

@Optional

Is user verified or not. If field is empty or missing 'verified' field is set as 'false'

USA/CAN TRANSACTIONS
HTTP Request
POST /client/users HTTP/1.1
Authorization: Basic dGVzdF9tZXJjaGFudDpwYXNzd29yZA==
Content-Type: application/json
Content-Length: 401
Host: java-staging.fenige.pl:8181

{
  "firstName" : "Mark",
  "lastName" : "Smith",
  "phone" : "48500600800",
  "email" : "mark.smith@fenige.pl",
  "password" : "LxTSuVPJ",
  "birthDate" : "10021994",
  "gender" : "M",
  "street" : "Wallstreet",
  "flatNumber" : "93",
  "houseNumber" : "283",
  "postalCode" : "01922",
  "city" : "New York",
  "country" : "US",
  "province" : "NY",
  "personalId" : "AAA00000",
  "verified" : true
}
Table 50. Request headers
Name Description

Authorization

Basic auth credentials

Table 51. Add user request fields
Path Type Constraints Description

firstName

String

User’s first name

lastName

String

User’s last name

phone

String

User’s phone number

email

String

User’s email used to log in system

password

String

User’s password

birthDate

String

Birth date in format ddmmyyyy

gender

String

Gender M/F

street

String

User’s street

flatNumber

String

User’s flat number

houseNumber

String

User’s house number

postalCode

String

User’s postal code

city

String

User’s city

country

String

@Optional

User country code in accordance with ISO 3166-1

province

String

@Optional

User’s province

personalId

String

@Optional

User’s personalId

verified

Boolean

@Optional

Is user verified or not. If field is empty or missing 'verified' field is set as 'false'

13.1.2. Response

200 OK
HTTP Response
HTTP/1.1 200 OK
Set-Cookie: JSESSIONID=6DDCA4BBE063195509271531B18326F1; Path=/; HttpOnly
X-Content-Type-Options: nosniff
X-XSS-Protection: 1; mode=block
Cache-Control: no-cache, no-store, max-age=0, must-revalidate
Pragma: no-cache
Expires: 0
X-Frame-Options: DENY
Content-Type: application/json;charset=UTF-8
Transfer-Encoding: chunked
Date: Thu, 06 May 2021 13:57:54 GMT
Content-Length: 41

{
  "status" : "SUCCESS",
  "id" : 1761
}
Table 52. Response fields
Path Type Description

status

String

Response status

id

Number

User’s id

200 OK - Errors

HTTP/1.1 200 OK
Content-Type: application/json

{
    "status": "USER_ALREADY_EXISTS",
    "id": 2602
}
HTTP/1.1 200 OK
Content-Type: application/json

{
    "status": "INVALID_FIRST_NAME",
    "id": null
}
HTTP/1.1 200 OK
Content-Type: application/json

{
    "status": "INVALID_LAST_NAME",
    "id": null
}
HTTP/1.1 200 OK
Content-Type: application/json

{
    "status": "INVALID_PHONE",
    "id": null
}
HTTP/1.1 200 OK
Content-Type: application/json

{
    "status": "INVALID_EMAIL",
    "id": null
}
HTTP/1.1 200 OK
Content-Type: application/json

{
    "status": "INVALID_PASSWORD",
    "id": null
}
HTTP/1.1 200 OK
Content-Type: application/json

{
     "status": "ERROR_INVALID_JSON",
     "error": {
         "message": "Some properties are invalid."
    }
}
HTTP/1.1 200 OK
Content-Type: application/json

{
     "status": "ERROR_USER_VERIFICATION",
     "error": {
        "message": "Some information is missing or incorrect."
    }
}

200 OK - Validation Errors
HTTP Response
HTTP/1.1 200 OK
Content-Type: application/json

{
    "status": "ERROR_VALIDATION",
    "error": {
        "message": "Some information is missing or incorrect.",
        "errors": [
            {
                "field": "addUserIn.province",
                "message": [
                    "may not be null",
                    "is not correct province code for country code US"
                ]
            },
            {
                "field": "addUserIn.province",
                "message": [
                    "may not be null",
                    "is not correct province code for country code CA"
                ]
            },
            {
                "field": "addUserIn.province",
                "message": [
                    "is not correct country code for province NY"
                ]
            },
            {
                "field": "addUserIn.province",
                "message": [
                    "province is mandatory only if country code is US or CA"
                ]
            },
            {
                "field": "addUserIn.province",
                "message": [
                    "must match ^[A-Z]{2}$",
                    "may not be empty",
                    "is not correct province code for country code US",
                    "length must be 2"
                ]
            },
            {
                "field": "addUserIn.province",
                "message": [
                    "must match ^[A-Z]{2}$",
                    "may not be empty",
                    "is not correct province code for country code CA",
                    "length must be 2"
                ]
            }
        ]
    }
}

13.2. Update user

PUT /client/users Content-Type: application/json, Authorization: Basic Auth, API-TOKEN
Method allow to update user profile data. This request must have header calling "API-TOKEN" and his value must be the same as token from the Log User method.
Notice that if 'verified' field is set as `true`, KYC_3 level will set for each transaction of this user (only for DATACENTER transactions).

From January 2021, there is an internal functionality to restrict access for the Merchant to specific method. The Fenige employee can disable access to a given endpoint, then the HTTP status 403 FORBIDDEN will be returned. The Merchant will be informed about each access restriction action.

13.2.1. Request

HTTP Request
PUT /client/users HTTP/1.1
Authorization: Basic dGVzdF9tZXJjaGFudDpwYXNzd29yZA==
API-TOKEN: d94NYa+xqRrazUPzSgYeJ6qR/MzIOb3IzePb7t9sWds=
Content-Type: application/json;charset=UTF-8
Content-Length: 572
Host: java-staging.fenige.pl:8181

{
  "id" : "6366",
  "personalData" : {
    "firstName" : "Mark",
    "lastName" : "Smith",
    "email" : "mark.smith@fenige.pl",
    "phone" : "48570100200",
    "personalId" : "ADFR34453",
    "verified" : true
  },
  "address" : {
    "id" : "4123",
    "street" : "Olszewskiego",
    "flatNumber" : "17A",
    "houseNumber" : "153",
    "postalCode" : "20-400",
    "city" : "Lublin",
    "countryId" : 616,
    "province" : null
  },
  "password" : {
    "oldPassword" : "aaiHyF2b",
    "newPassword" : "UFVVvspZrD_ro",
    "newPasswordRepeat" : "UFVVvspZrD_ro"
  }
}
Table 53. Request headers
Name Description

Authorization

Basic auth credentials

API-TOKEN

User’s token to authenticate in service

Table 54. Update user request fields
Path Type Constraints Description

id

String

Required

User identifier, received from addUser

personalData.firstName

String

Required

User first name to update

personalData.lastName

String

Required

User last name to update

personalData.email

String

Required

User email to update

personalData.phone

String

Required

User phone to update

personalData.personalId

String

Optional

User personal id

personalData.verified

Boolean

Optional

Is user verified

address.id

String

Required

User address identifier

address.street

String

Optional

User street to update

address.flatNumber

String

Optional

User flat number to update

address.houseNumber

String

Optional

User house number to update

address.postalCode

String

Optional

User postal code to update

address.city

String

Optional

User city to update

address.countryId

Number

Required

User country id to update in accordance with ISO 3166-1

address.province

Null

Optional

User country province

password.oldPassword

String

Required

User old password

password.newPassword

String

Required

User new password

password.newPasswordRepeat

String

Required

User new password repeated

13.2.2. Response

200 OK
HTTP Response
HTTP/1.1 200 OK
Set-Cookie: JSESSIONID=1E00C3ECF824A32A587041B7C5868502; Path=/; HttpOnly
X-Content-Type-Options: nosniff
X-XSS-Protection: 1; mode=block
Cache-Control: no-cache, no-store, max-age=0, must-revalidate
Pragma: no-cache
Expires: 0
X-Frame-Options: DENY
Content-Type: application/json;charset=UTF-8
Transfer-Encoding: chunked
Date: Thu, 06 May 2021 13:57:53 GMT
Content-Length: 26

{
  "status" : "SUCCESS"
}
Table 55. Response fields
Path Type Description

status

String

Response status

200 OK - Error
HTTP Response
HTTP/1.1 200 OK
Content-Type: application/json

{
    "status": "ALREADY_UNSET"
}
200 OK - Error validation
HTTP Response
HTTP/1.1 200 OK
Content-Type: application/json

{
    "status": "ERROR_VALIDATION",
    "error": {
        "message": "Some information is missing or incorrect.",
        "errors": [
            {
                "field": "updateUserIn.password",
                "message": [
                    "newPassword and newPasswordRepeat fields must be the same"
                ]
            },
             {
                 "field": "updateUserIn.password.newPasswordRepeat",
                 "message": [
                     "may not be empty"
                 ]
            },
            {
                  "field": "updateUserIn.personalData.phone",
                  "message": [
                      "may not be null",
                      "may not be empty"
                 ]
            },
            {
                   "field": "updateUserIn.address.id",
                   "message": [
                       "may not be empty",
                        "may not be null"
                 ]
            },
            {
                "field": "updateUserIn.address.province",
                "message": [
                    "is not correct province code for country code CA"
                ]
            },
            {
                "field": "updateUserIn.address.province",
                "message": [
                    "is not correct province code for country code US",
                    "may not be null"
                ]
            },
            {
                "field": "updateUserIn.address.province",
                "message": [
                    "province is mandatory only if country code is US or CA"
                ]
            },
            {
                "field": "updateUserIn.address.province",
                "message": [
                    "length must be 2",
                    "may not be empty",
                    "must match ^[A-Z]{2}$",
                    "is not correct province code for country code US"
                ]
            },
            {
                "field": "updateUserIn.address.province",
                "message": [
                    "length must be 2",
                    "may not be empty",
                    "must match ^[A-Z]{2}$",
                    "is not correct province code for country code CA"
                ]
            }
        ]
    }
}

13.3. Delete user

DELETE /client/users Content Type: application/json, Authorization: Basic Auth
This method can be use to delete user from database. In field 'id' you can type user's phone number or email.

From January 2021, there is an internal functionality to restrict access for the Merchant to specific method. The Fenige employee can disable access to a given endpoint, then the HTTP status 403 FORBIDDEN will be returned. The Merchant will be informed about each access restriction action.

13.3.1. Request

HTTP Request
DELETE /client/users HTTP/1.1
Authorization: Basic dGVzdF9tZXJjaGFudDpwYXNzd29yZA==
Content-Type: application/json
Content-Length: 17
Host: java-staging.fenige.pl:8181

{
  "id" : 9796
}
Table 56. Request headers
Name Description

Authorization

Basic auth credentials

Table 57. Delete user request fields
Path Type Constraints Description

id

Number

@Only digits allowed

Unique user id

13.3.2. Response

200 OK
HTTP Response
HTTP/1.1 200 OK
Set-Cookie: JSESSIONID=DEE0502C59B413909720AC6275064A1F; Path=/; HttpOnly
X-Content-Type-Options: nosniff
X-XSS-Protection: 1; mode=block
Cache-Control: no-cache, no-store, max-age=0, must-revalidate
Pragma: no-cache
Expires: 0
X-Frame-Options: DENY
Content-Type: application/json;charset=UTF-8
Transfer-Encoding: chunked
Date: Thu, 06 May 2021 13:57:50 GMT
Content-Length: 26

{
  "status" : "SUCCESS"
}
Table 58. Response fields
Path Type Description

status

String

Response status

200 OK - Error

HTTP/1.1 200 OK
Content-Type: application/json

{
    "status": "CANT_FIND_USER"
}
HTTP/1.1 200 OK
Content-Type: application/json

{
    "status": "UNKNOWN_ERROR"
}

13.4. Get user address

POST /client/users/address Content-Type: application/json
This method can be use to receive address details of user.

13.4.1. Request

HTTP Request
POST /client/users/address HTTP/1.1
Authorization: Basic dGVzdF9tZXJjaGFudDpwYXNzd29yZA==
Content-Type: application/json;charset=UTF-8
Content-Length: 19
Host: java-staging.fenige.pl:8181

{
  "id" : "4123"
}
Table 59. Request headers
Name Description

Authorization

Basic auth credentials

Table 60. Get user address request fields
Path Type Constraints Description

id

String

@Only digits allowed

Id number of address

13.4.2. Response

200 OK
HTTP Response
HTTP/1.1 200 OK
Set-Cookie: JSESSIONID=ADBA74632307E4E17399FA4585454012; Path=/; HttpOnly
X-Content-Type-Options: nosniff
X-XSS-Protection: 1; mode=block
Cache-Control: no-cache, no-store, max-age=0, must-revalidate
Pragma: no-cache
Expires: 0
X-Frame-Options: DENY
Content-Type: application/json;charset=UTF-8
Transfer-Encoding: chunked
Date: Thu, 06 May 2021 13:57:49 GMT
Content-Length: 207

{
  "id" : "4123",
  "street" : "Olszewskiego",
  "city" : "Lublin",
  "flatNumber" : "17A",
  "houseNumber" : "153",
  "postalCode" : "20-400",
  "countryId" : 616,
  "country" : "PL",
  "province" : null
}
Table 61. Response fields
Path Type Description

id

String

Address’s id

street

String

User’s street

city

String

User’s city

flatNumber

String

User’s flat number

houseNumber

String

User’s house number

postalCode

String

User’s postal code

countryId

Number

User’s numeric country code

country

String

User country code in accordance with ISO 3166-1

province

Null

User’s province

200 OK - Error

HTTP/1.1 200 OK
Content-Type: application/json

{
    "status": "ERROR_WHILE_GETTING_ADDRESS",
    "error": {
        "message": "Some information is missing or incorrect."
    }
}
HTTP/1.1 200 OK
Content-Type: application/json

{
    "status": "ERROR_INVALID_JSON",
    "error": {
         "message": "Some properties are invalid."
    }
}
HTTP/1.1 200 OK
Content-Type: application/json

{
    "status": "ERROR_SOMETHING_WRONG",
    "error": {
        "message": "Something went wrong."
    }
}

13.5. Get countries

GET /client/countries Content Type: application/json, Authorization: Basic Auth
Method returns list of countries with specified country code alphabetic and numeric phone prefix for each country.

13.5.1. Request

GET /client/countries HTTP/1.1
Content-Type: application/json
Authorization: Basic eW91cl9tZXJjaGFudDp5b3VyX3Bhc3N3b3Jk
HOST: java-staging.fenige.pl:8181

13.5.2. Response

Response status
Status Description

200 OK

Returned phone number prefix with country code for countries.

Example HTTP Response
200 OK
HTTP/1.1 200 OK
Content-Type: application/json

[
    {
        "countryCode": "AF",
        "prefix": "93"
    },
    {
        "countryCode": "AL",
        "prefix": "355"
    },
    {
        "countryCode": "AQ",
        "prefix": "672"
    },
    {
        "countryCode": "DZ",
        "prefix": "213"
    },
...
]

Response fields

Name Type Description

countryCode

String

Alphabetic two letters country unique code identifier in accordance with ISO 3166-1

prefix

String

Prefix phone number for country

14. Card management

14.1. Add card

PUT /client/card Content-Type: application/json, Authorization: Basic Auth
This method can be use to add new card for existing user. In default limit per user is 5 cards, Fenige can configure it per merchant.

From January 2021, there is an internal functionality to restrict access for the Merchant to specific method. The Fenige employee can disable access to a given endpoint, then the HTTP status 403 FORBIDDEN will be returned. The Merchant will be informed about each access restriction action.

Flow Card Add

14.1.1. Request

Add card HTTP Request
PUT /client/card HTTP/1.1
Authorization: Basic dGVzdF9tZXJjaGFudDpwYXNzd29yZA==
Content-Type: application/json
Content-Length: 192
Host: java-staging.fenige.pl:8181

{
  "userIdentifier" : "mark.smith@fenige.pl",
  "card" : {
    "expDate" : "10/22",
    "cardNo" : "5442016597039990",
    "defaultValue" : false,
    "description" : "Test card number"
  }
}
Table 62. Request headers
Name Description

Authorization

Basic auth credentials

Table 63. Add card request fields
Path Type Constraints Description

userIdentifier

String

@Own constraint

Sender email address

card

Object

@NotNull

Card detail information

card.expDate

String

@NotNull, @NotEmpty, @ExpDate

Expiration date of card mm/yy

card.cardNo

String

@NotNull, @NotEmpty, @CardNumber, @Length(min=16, max=19)

Full 16-digits or 19-digits sender card number

card.description

String

@NotNull, @NotEmpty

Description of the card

card.defaultValue

Boolean

@NotEmpty

Is card default

14.1.2. Response

200 OK
HTTP Response
HTTP/1.1 200 OK
Set-Cookie: JSESSIONID=2F7206A9A1724E174C9ED297F6B7F8BD; Path=/; HttpOnly
X-Content-Type-Options: nosniff
X-XSS-Protection: 1; mode=block
Cache-Control: no-cache, no-store, max-age=0, must-revalidate
Pragma: no-cache
Expires: 0
X-Frame-Options: DENY
Content-Type: application/json;charset=UTF-8
Transfer-Encoding: chunked
Date: Thu, 06 May 2021 13:57:43 GMT
Content-Length: 46

{
  "status" : "SUCCESS",
  "card_id" : 3697
}
Table 64. Response fields
Path Type Description

status

String

Response status

card_id

Number

Unique card identifier

200 OK - Error

HTTP/1.1 200 OK
Content-Type: application/json

{
    "status": "CARD_ALREADY_EXISTS",
    "card_id": 4368
}
HTTP/1.1 200 OK
Content-Type: application/json

{
    "status": "INVALID_CARD_NO",
    "error": {
        "message": "Some information is missing or incorrect."
    }
}
HTTP/1.1 200 OK
Content-Type: application/json

{
    "status": "CARD_DESC_REQUIRED",
    "error": {
        "message": "Some information is missing or incorrect."
    }
}
HTTP/1.1 200 OK
Content-Type: application/json

{
    "status": "CARD_DESC_INVALID",
    "error": {
        "message": "Some information is missing or incorrect."
    }
}
HTTP/1.1 200 OK
Content-Type: application/json

{
    "status": "CARD_LIMIT_REACHED",
    "card_id": null
}
HTTP/1.1 200 OK
Content-Type: application/json

{
    "status": "CARD_MODIFY_LIMIT_REACHED",
    "card_id": null
}
HTTP/1.1 200 OK
Content-Type: application/json

{
    "status": "INVALID_CARD_EXP",
    "error": {
        "message": "Some information is missing or incorrect."
    }
}
HTTP/1.1 200 OK
Content-Type: application/json

{
    "status": "UNKNOWN_ERROR",
    "card_id": null
}
Returned UNKNOWN_ERROR when user email was invalid or missing.

403 FORBIDDEN
HTTP Response - Error
HTTP/1.1 403 Forbidden
Set-Cookie: JSESSIONID=0C6A410A9AB1769A331446A38E816995; Path=/; HttpOnly
X-Content-Type-Options: nosniff
X-XSS-Protection: 1; mode=block
Cache-Control: no-cache, no-store, max-age=0, must-revalidate
Pragma: no-cache
Expires: 0
X-Frame-Options: DENY
Content-Type: application/json;charset=UTF-8
Transfer-Encoding: chunked
Date: Thu, 06 May 2021 13:57:43 GMT
Content-Length: 141

{
  "timestamp" : 1620309463980,
  "status" : 403,
  "error" : "Forbidden",
  "message" : "No message available",
  "path" : "/client/card"
}

14.2. Update card

PUT /client/cards Content-Type: application/json, Authorization: Basic Auth, API-TOKEN
This method can be used to update card's data for user. This request must have header calling "API-TOKEN" and his value must be the same as token from the Log User method.

From January 2021, there is an internal functionality to restrict access for the Merchant to specific method. The Fenige employee can disable access to a given endpoint, then the HTTP status 403 FORBIDDEN will be returned. The Merchant will be informed about each access restriction action.

14.2.1. Request

HTTP Request
PUT /client/cards HTTP/1.1
Authorization: Basic dGVzdF9tZXJjaGFudDpwYXNzd29yZA==
API-TOKEN: d94NYa+xqRrazUPzSgYeJ6qR/MzIOb3IzePb7t9sWds=
Content-Type: application/json
Content-Length: 42
Host: java-staging.fenige.pl:8181

{
  "id" : 5346,
  "defaultValue" : true
}
Table 65. Request headers
Name Description

Authorization

Basic auth credentials

API-TOKEN

User’s token to authenticate in service

Table 66. Edit card request fields
Path Type Constraints Description

id

Number

@Not null

Card id

defaultValue

Boolean

@Not Null

Is this card default

14.2.2. Response

200 OK
HTTP Response
HTTP/1.1 200 OK
Set-Cookie: JSESSIONID=10F0A1FDFC50FB6C46A5762862D94CD1; Path=/; HttpOnly
X-Content-Type-Options: nosniff
X-XSS-Protection: 1; mode=block
Cache-Control: no-cache, no-store, max-age=0, must-revalidate
Pragma: no-cache
Expires: 0
X-Frame-Options: DENY
Content-Type: application/json;charset=UTF-8
Transfer-Encoding: chunked
Date: Thu, 06 May 2021 13:57:44 GMT
Content-Length: 43

{
  "id" : "5346",
  "status" : "SUCCESS"
}
Table 67. Response fields
Path Type Description

status

String

Response status

id

String

Unique card identifier

200 OK - Error
HTTP Response
HTTP/1.1 200 OK
Content-Type: application/json

{
    "id": "43",
    "status": "CANT_FIND_CARD"
}
HTTP/1.1 200 OK
Content-Type: application/json

{
    "status": "ERROR_INVALID_JSON",
    "error": {
        "message": "Some properties are invalid."
    }
}
HTTP/1.1 200 OK
Content-Type: application/json

{
    "status": "ERROR_SOMETHING_WRONG",
    "error": {
        "message": "Something went wrong."
    }
}
401 Unauthorized
HTTP Response
HTTP/1.1 401 Unauthorized
Content-Type: application/json

{
    "timestamp": 1532327775503,
    "status": 401,
    "error": "Unauthorized",
    "message": "ERROR_USER_NOTFOUND",
    "path": "/client/cards"
}
403 FORBIDDEN
HTTP Response - Error
HTTP/1.1 403 Forbidden
Set-Cookie: JSESSIONID=0C6A410A9AB1769A331446A38E816995; Path=/; HttpOnly
X-Content-Type-Options: nosniff
X-XSS-Protection: 1; mode=block
Cache-Control: no-cache, no-store, max-age=0, must-revalidate
Pragma: no-cache
Expires: 0
X-Frame-Options: DENY
Content-Type: application/json;charset=UTF-8
Transfer-Encoding: chunked
Date: Thu, 06 May 2021 13:57:43 GMT
Content-Length: 141

{
  "timestamp" : 1620309463980,
  "status" : 403,
  "error" : "Forbidden",
  "message" : "No message available",
  "path" : "/client/card"
}

14.3. Get card list

GET /client/cards Content Type: application/json, Authorization: Basic Auth, API-TOKEN
This method can be use to receive list of cards for user. This request must have header calling "API-TOKEN" and his value must be the same as token from the Log User method.

From January 2021, there is an internal functionality to restrict access for the Merchant to specific method. The Fenige employee can disable access to a given endpoint, then the HTTP status 403 FORBIDDEN will be returned. The Merchant will be informed about each access restriction action.

14.3.1. Request

HTTP Request
GET /client/cards HTTP/1.1
Authorization: Basic dGVzdF9tZXJjaGFudDpwYXNzd29yZA==
API-TOKEN: d94NYa+xqRrazUPzSgYeJ6qR/MzIOb3IzePb7t9sWds=
Host: java-staging.fenige.pl:8181
Table 68. Request headers
Name Description

Authorization

Basic auth credentials

API-TOKEN

User’s token to authenticate in service

14.3.2. Response

200 OK
HTTP Response
HTTP/1.1 200 OK
Set-Cookie: JSESSIONID=2F9B35E7FD6DF703BCE5B6A6FE0D832F; Path=/; HttpOnly
X-Content-Type-Options: nosniff
X-XSS-Protection: 1; mode=block
Cache-Control: no-cache, no-store, max-age=0, must-revalidate
Pragma: no-cache
Expires: 0
X-Frame-Options: DENY
Content-Type: application/json;charset=UTF-8
Transfer-Encoding: chunked
Date: Thu, 06 May 2021 13:57:44 GMT
Content-Length: 419

{
  "status" : "SUCCESS",
  "success" : [ {
    "id" : 24,
    "cardNo" : "0463",
    "bin" : "535167",
    "description" : "Basic debit card",
    "defaultValue" : true,
    "strongVerified" : true,
    "expDate" : "1022"
  }, {
    "id" : 3252,
    "cardNo" : "9169",
    "bin" : "511796",
    "description" : "Basic debit card",
    "defaultValue" : false,
    "strongVerified" : true,
    "expDate" : "0324"
  } ]
}
Table 69. Response fields
Path Type Description

status

String

Response status

success[].id

Number

Card id

success[].cardNo

String

Card number

success[].bin

String

Card bin

success[].description

String

Card description

success[].defaultValue

Boolean

Is card default value

success[].strongVerified

Boolean

Is card string verified

success[].expDate

String

Card expiration date

401 Unauthorized
HTTP Response
HTTP/1.1 401 Unauthorized
Content-Type: application/json

{
    "timestamp": 1532333748187,
    "status": 401,
    "error": "Unauthorized",
    "message": "ERROR_USER_NOTFOUND",
    "path": "/client/cards"
}
403 FORBIDDEN
HTTP Response - Error
HTTP/1.1 403 Forbidden
Set-Cookie: JSESSIONID=0C6A410A9AB1769A331446A38E816995; Path=/; HttpOnly
X-Content-Type-Options: nosniff
X-XSS-Protection: 1; mode=block
Cache-Control: no-cache, no-store, max-age=0, must-revalidate
Pragma: no-cache
Expires: 0
X-Frame-Options: DENY
Content-Type: application/json;charset=UTF-8
Transfer-Encoding: chunked
Date: Thu, 06 May 2021 13:57:43 GMT
Content-Length: 141

{
  "timestamp" : 1620309463980,
  "status" : 403,
  "error" : "Forbidden",
  "message" : "No message available",
  "path" : "/client/card"
}

14.4. Delete card

DELETE /client/cards/{cardId} Content Type: application/json, Authorization: Basic Auth, API-TOKEN
This method can be use to delete card of some user.

From January 2021, there is an internal functionality to restrict access for the Merchant to specific method. The Fenige employee can disable access to a given endpoint, then the HTTP status 403 FORBIDDEN will be returned. The Merchant will be informed about each access restriction action.

14.4.1. Request

HTTP Request
DELETE /client/cards/7991 HTTP/1.1
Authorization: Basic dGVzdF9tZXJjaGFudDpwYXNzd29yZA==
API-TOKEN: d94NYa+xqRrazUPzSgYeJ6qR/MzIOb3IzePb7t9sWds=
Host: java-staging.fenige.pl:8181
Table 70. Request headers
Name Description

Authorization

Basic auth credentials

API-TOKEN

User’s token to authenticate in service

14.4.2. Response

200 OK
HTTP Response
HTTP/1.1 200 OK
Set-Cookie: JSESSIONID=EA9EF13ED6FD527BC53DD6E616FF8199; Path=/; HttpOnly
X-Content-Type-Options: nosniff
X-XSS-Protection: 1; mode=block
Cache-Control: no-cache, no-store, max-age=0, must-revalidate
Pragma: no-cache
Expires: 0
X-Frame-Options: DENY
Content-Type: application/json;charset=UTF-8
Transfer-Encoding: chunked
Date: Thu, 06 May 2021 13:57:45 GMT
Content-Length: 26

{
  "status" : "SUCCESS"
}
Table 71. Response fields
Path Type Description

status

String

Response status

200 OK - Error
HTTP Response
HTTP/1.1 200 OK
Content-Type: application/json

{
    "status": "ERROR_CARD_NOT_FOUND",
    "error": {
        "message": "Some information is missing or incorrect."
    }
}
HTTP/1.1 200 OK
Content-Type: application/json

{
    "status": "CARD_MODIFY_LIMIT_REACHED"
}
401 Unauthorized
HTTP/1.1 401 Unauthorized
Content-Type: application/json

{
    "timestamp": 1532344315546,
    "status": 401,
    "error": "Unauthorized",
    "message": "ERROR_USER_NOTFOUND",
    "path": "/client/cards/1234"
}
403 FORBIDDEN
HTTP Response - Error
HTTP/1.1 403 Forbidden
Set-Cookie: JSESSIONID=0C6A410A9AB1769A331446A38E816995; Path=/; HttpOnly
X-Content-Type-Options: nosniff
X-XSS-Protection: 1; mode=block
Cache-Control: no-cache, no-store, max-age=0, must-revalidate
Pragma: no-cache
Expires: 0
X-Frame-Options: DENY
Content-Type: application/json;charset=UTF-8
Transfer-Encoding: chunked
Date: Thu, 06 May 2021 13:57:43 GMT
Content-Length: 141

{
  "timestamp" : 1620309463980,
  "status" : 403,
  "error" : "Forbidden",
  "message" : "No message available",
  "path" : "/client/card"
}

14.5. Get country for card

POST /client/card/country Content Type: application/json, Authorization: Basic Auth
Method returns country code from which the card is issued.
Received country code is in accordance with ISO 3166-1

14.5.1. Request

Name Type Validation Description

cardNumber

String

Required

Number of card to verify country

POST /client/card/country HTTP/1.1
Content-Type: application/json
Authorization: Basic eW91cl9tZXJjaGFudDp5b3VyX3Bhc3N3b3Jk
Host: java-staging.fenige.pl:8181

{
  "cardNumber" : "5351672923040463"
}

14.5.2. Response

Response status
Status Description

200 OK

Returned country code from which the card was issued.

400 - Bad Request

Returned when card number is invalid or missing.

Example HTTP Response
200 OK
HTTP/1.1 200 OK
Content-Type: application/json

{
  "country" : "PL"
}
Name Type Description

country

CountryCode

Code of country from which the card is issued in accordance with ISO 3166-1

400 Bad Request
HTTP/1.1 400 Bad Request

{
    "timestamp": 1532339149084,
    "status": 400,
    "error": "Bad Request",
    "exception": "org.springframework.web.bind.MethodArgumentNotValidException",
    "errors": [
        {
            "codes": [
                "NotBlank.cardCountryRequest.cardNumber",
                "NotBlank.cardNumber",
                "NotBlank.java.lang.String",
                "NotBlank"
            ],
            "arguments": [
                {
                    "codes": [
                        "cardCountryRequest.cardNumber",
                        "cardNumber"
                    ],
                    "arguments": null,
                    "defaultMessage": "cardNumber",
                    "code": "cardNumber"
                }
            ],
            "defaultMessage": "may not be empty",
            "objectName": "cardCountryRequest",
            "field": "cardNumber",
            "rejectedValue": "",
            "bindingFailure": false,
            "code": "NotBlank"
        },
        {
            "codes": [
                "NotNull.cardCountryRequest.cardNumber",
                "NotNull.cardNumber",
                "NotNull.java.lang.String",
                "NotNull"
            ],
            "arguments": [
                {
                    "codes": [
                        "cardCountryRequest.cardNumber",
                        "cardNumber"
                    ],
                    "arguments": null,
                    "defaultMessage": "cardNumber",
                    "code": "cardNumber"
                }
            ],
            "defaultMessage": "may not be null",
            "objectName": "cardCountryRequest",
            "field": "cardNumber",
            "rejectedValue": null,
            "bindingFailure": false,
            "code": "NotNull"
        },
        {
            "codes": [
                "LuhnCheck.cardCountryRequest.cardNumber",
                "LuhnCheck.cardNumber",
                "LuhnCheck.java.lang.String",
                "LuhnCheck"
            ],
            "arguments": [
                {
                    "codes": [
                        "cardCountryRequest.cardNumber",
                        "cardNumber"
                    ],
                    "arguments": null,
                    "defaultMessage": "cardNumber",
                    "code": "cardNumber"
                },
                -1,
                2147483647,
                true,
                0
            ],
            "defaultMessage": "invalid card number",
            "objectName": "cardCountryRequest",
            "field": "cardNumber",
            "rejectedValue": "",
            "bindingFailure": false,
            "code": "LuhnCheck"
        },
        {
            "codes": [
                "Size.cardCountryRequest.cardNumber",
                "Size.cardNumber",
                "Size.java.lang.String",
                "Size"
            ],
            "arguments": [
                {
                    "codes": [
                        "cardCountryRequest.cardNumber",
                        "cardNumber"
                    ],
                    "arguments": null,
                    "defaultMessage": "cardNumber",
                    "code": "cardNumber"
                },
                16,
                16
            ],
            "defaultMessage": "card number length must be 16",
            "objectName": "cardCountryRequest",
            "field": "cardNumber",
            "rejectedValue": "",
            "bindingFailure": false,
            "code": "Size"
        }
    ],
    "message": "Validation failed for object='cardCountryRequest'. Error count: 3",
    "path": "/client/card/country"
}

15. Friendly receiver cards

15.1. Add friend card

POST /client/friend-card Content-Type: application/json, Authorization: Basic Auth, API-TOKEN
    Method allows you to register favourite receiver card number and phone number to enable mobile-2-mobile MoneySend transactions. This request must have header calling
"API-TOKEN" and his value must be the same as token from the Log User method. In default limit per user is 5 friend cards, Fenige can configure it per merchant.

From January 2021, there is an internal functionality to restrict access for the Merchant to specific method. The Fenige employee can disable access to a given endpoint, then the HTTP status 403 FORBIDDEN will be returned. The Merchant will be informed about each access restriction action.

15.1.1. Request

HTTP Request
POST /client/friend-card HTTP/1.1
Authorization: Basic dGVzdF9tZXJjaGFudDpwYXNzd29yZA==
API-TOKEN: d94NYa+xqRrazUPzSgYeJ6qR/MzIOb3IzePb7t9sWds=
Content-Type: application/json
Content-Length: 185
Host: java-staging.fenige.pl:8181

{
  "cardNumber" : "5442013217661428",
  "phoneNumber" : "48570100200",
  "friendData" : {
    "firstName" : "Mark",
    "lastName" : "Smith",
    "email" : "mark.smith@fenige.pl"
  }
}
Table 72. Request headers
Name Description

Authorization

Basic auth credentials

API-TOKEN

User’s token to authenticate in service

Table 73. Add friend card request fields
Path Type Constraints Description

cardNumber

String

@NotNull, @NotEmpty, @CardNumber, @Length(min=16, max=19), @LuhnCheck

Full 16-digits or 19-digits sender card number

phoneNumber

String

Phone number of friendcard’s holder

friendData.firstName

String

@NotNull, @NotBlank, @Pattern(regexp = "[0-9]+$")

Friendcard’s holder first name

friendData.lastName

String

@NotNull, @NotBlank, @Pattern(regexp = "[0-9]+$")

Friendcard’s holder last name

friendData.email

String

@Email

Sender email address

15.1.2. Response

200 OK
HTTP Response
HTTP/1.1 200 OK
Set-Cookie: JSESSIONID=4C5F45176821DB9A36DF5A1144BA0466; Path=/; HttpOnly
X-Content-Type-Options: nosniff
X-XSS-Protection: 1; mode=block
Cache-Control: no-cache, no-store, max-age=0, must-revalidate
Pragma: no-cache
Expires: 0
X-Frame-Options: DENY
Content-Type: application/json;charset=UTF-8
Transfer-Encoding: chunked
Date: Thu, 06 May 2021 13:57:41 GMT
Content-Length: 62

{
  "status" : "SUCCESS",
  "success" : {
    "id" : 968
  }
}
Table 74. Response fields
Path Type Description

status

String

Response status from Fenige system

success.id

Number

Friendcard’s id

200 OK - Error validation
HTTP Response
HTTP/1.1 200 OK
Content-Type: application/json

{
    "status": "ERROR_VALIDATION",
    "error": {
        "message": "Some information is missing or incorrect.",
        "errors": [
            {
                "field": "friendCardIn.cardNumber",
                "message": [
                    "may not be empty",
                    "invalid card number",
                    "may not be null"
                ]
            },
            {
                "field": "friendCardIn.friendData",
                "message": [
                    "may not be null"
                ]
            },
            {
                "field": "friendCardIn.cardNumber",
                "message": [
                    "card number length must be 16",
                    "card failed luhn check",
                    "invalid card number"
                ]
            }.
            {
                "field": "friendCardIn.friendData.firstName",
                "message": [
                    "must match \"^[^0-9]+$\""
                ]
            },
            {
                "field": "friendCardIn.friendData.lastName",
                "message": [
                    "must match \"^[^0-9]+$\""
                ]
            },
            {
                "field": "friendCardIn.friendData.firstName",
                "message": [
                    "may not be empty"
                ]
            },
            {
                "field": "friendCardIn.friendData.lastName",
                "message": [
                    "may not be empty"
                ]

        ]
    }
}
200 OK - Error

HTTP/1.1 200 OK
Content-Type: application/json

{
    "status": "ERROR_PHONE_ALREADY_EXISTS",
    "card_id": null
}
HTTP/1.1 200 OK
Content-Type: application/json

{
    "status": "ERROR_WHILE_ADDING_CARD",
    "card_id": null
}
HTTP/1.1 200 OK
Content-Type: application/json

{
    "status": "ERROR_CARD_ALREADY_EXISTS",
    "card_id": null
}
HTTP/1.1 200 OK
Content-Type: application/json

{
    "status": "CARD_LIMIT_REACHED",
    "card_id": null
}
HTTP/1.1 200 OK
Content-Type: application/json

{
    "status": "CARD_MODIFY_LIMIT_REACHED",
    "card_id": null
}
HTTP/1.1 200 OK
Content-Type: application/json

{
    "status": "ERROR_VALIDATION",
    "card_id": null
}
HTTP/1.1 200 OK
Content-Type: application/json

{
    "status": "UNKNOWN_ERROR",
    "card_id": null
}

15.2. Update friend card

PUT /client/friend-cards/{id} Content Type: application/json, Authorization: Basic Auth, API-TOKEN
This method allows you to edit the friendly receiver phone number and additional card data. This request must have header calling "API-TOKEN" and his value must be the same
as token from the Log User method.

From January 2021, there is an internal functionality to restrict access for the Merchant to specific method. The Fenige employee can disable access to a given endpoint, then the HTTP status 403 FORBIDDEN will be returned. The Merchant will be informed about each access restriction action.

15.2.1. Request

HTTP Request
PUT /client/friend-card/2948 HTTP/1.1
Authorization: Basic dGVzdF9tZXJjaGFudDpwYXNzd29yZA==
API-TOKEN: d94NYa+xqRrazUPzSgYeJ6qR/MzIOb3IzePb7t9sWds=
Content-Type: application/json
Content-Length: 150
Host: java-staging.fenige.pl:8181

{
  "phoneNumber" : "48570100200",
  "friendData" : {
    "firstName" : "Mike",
    "lastName" : "Dawson",
    "email" : "dawson.mike@fenige.pl"
  }
}
Table 75. Request headers
Name Description

Authorization

Basic auth credentials

API-TOKEN

User’s token to authenticate in service

Table 76. Add friend card request fields
Path Type Constraints Description

phoneNumber

String

Phone number of friendcard’s holder

friendData.firstName

String

@NotNull, @NotBlank, @Pattern(regexp = "[0-9]+$")

Friendcard’s holder first name

friendData.lastName

String

@NotNull, @NotBlank, @Pattern(regexp = "[0-9]+$")

Friendcard’s holder last name

friendData.email

String

@Email

Sender email address

15.2.2. Response

200 OK
HTTP Response
HTTP/1.1 200 OK
Set-Cookie: JSESSIONID=CAC8C588BEE1A9241CD9C5276BD35C19; Path=/; HttpOnly
X-Content-Type-Options: nosniff
X-XSS-Protection: 1; mode=block
Cache-Control: no-cache, no-store, max-age=0, must-revalidate
Pragma: no-cache
Expires: 0
X-Frame-Options: DENY
Content-Type: application/json;charset=UTF-8
Transfer-Encoding: chunked
Date: Thu, 06 May 2021 13:57:42 GMT
Content-Length: 62

{
  "status" : "SUCCESS",
  "success" : {
    "id" : 368
  }
}
Table 77. Response fields
Path Type Description

status

String

Response status from Fenige system

success.id

Number

Friendcard’s id

15.3. Delete friend card

DELETE /client/friend-cards/{id} Content Type: application/json, Authorization: Basic Auth, API-TOKEN
This method can be use to delete friend card of some user. This request must have header calling "API-TOKEN" and his value must be the same as token from the Log User method.

From January 2021, there is an internal functionality to restrict access for the Merchant to specific method. The Fenige employee can disable access to a given endpoint, then the HTTP status 403 FORBIDDEN will be returned. The Merchant will be informed about each access restriction action.

15.3.1. Request

HTTP Request
DELETE /client/friend-card/1906 HTTP/1.1
Authorization: Basic dGVzdF9tZXJjaGFudDpwYXNzd29yZA==
API-TOKEN: d94NYa+xqRrazUPzSgYeJ6qR/MzIOb3IzePb7t9sWds=
Host: java-staging.fenige.pl:8181
Table 78. Request headers
Name Description

Authorization

Basic auth credentials

API-TOKEN

User’s token to authenticate in service

15.3.2. Response

200 OK
HTTP Response
HTTP/1.1 200 OK
Set-Cookie: JSESSIONID=4863B001A33FE657895F68930221DDEC; Path=/; HttpOnly
X-Content-Type-Options: nosniff
X-XSS-Protection: 1; mode=block
Cache-Control: no-cache, no-store, max-age=0, must-revalidate
Pragma: no-cache
Expires: 0
X-Frame-Options: DENY
Content-Type: application/json;charset=UTF-8
Transfer-Encoding: chunked
Date: Thu, 06 May 2021 13:57:41 GMT
Content-Length: 26

{
  "status" : "SUCCESS"
}
Table 79. Response fields
Path Type Description

status

String

Response status

200 OK - Error

HTTP/1.1 200 OK
Content-Type: application/json

{
    "status": "CARD_MODIFY_LIMIT_REACHED"
}
HTTP/1.1 200 OK
Content-Type: application/json

{
    "status": "ERROR_CARD_NOT_FOUND",
    "error": {
        "message": "Some information is missing or incorrect."
    }
}

401 - Unauthorized
HTTP Response
HTTP/1.1 401 Unauthorized
Content-Type: application/json

{
    "timestamp": 1532605174810,
    "status": 401,
    "error": "Unauthorized",
    "message": "ERROR_USER_NOTFOUND",
    "path": "/client/friend-card/28"
}

15.4. Get friend card list

GET /client/friend-cards Content Type: application/json, Authorization: Basic Auth, API-TOKEN
This method can be use to receive list of friend cards for user.

From January 2021, there is an internal functionality to restrict access for the Merchant to specific method. The Fenige employee can disable access to a given endpoint, then the HTTP status 403 FORBIDDEN will be returned. The Merchant will be informed about each access restriction action.

15.4.1. Request

HTTP Request
GET /client/friend-card HTTP/1.1
Authorization: Basic dGVzdF9tZXJjaGFudDpwYXNzd29yZA==
API-TOKEN: d94NYa+xqRrazUPzSgYeJ6qR/MzIOb3IzePb7t9sWds=
Host: java-staging.fenige.pl:8181
Table 80. Request headers
Name Description

Authorization

Basic auth credentials

API-TOKEN

User’s token to authenticate in service

15.4.2. Response

200 OK
HTTP Response
HTTP/1.1 200 OK
Set-Cookie: JSESSIONID=632C34E4903316CA782E9BEB8173688E; Path=/; HttpOnly
X-Content-Type-Options: nosniff
X-XSS-Protection: 1; mode=block
Cache-Control: no-cache, no-store, max-age=0, must-revalidate
Pragma: no-cache
Expires: 0
X-Frame-Options: DENY
Content-Type: application/json;charset=UTF-8
Transfer-Encoding: chunked
Date: Thu, 06 May 2021 13:57:42 GMT
Content-Length: 530

{
  "status" : "SUCCESS",
  "success" : [ {
    "id" : 7869,
    "cardNumber" : "XXXX-XXXX-XXXX-9538",
    "bin" : "473000",
    "phoneNumber" : "48680419133",
    "data" : {
      "firstName" : "Emily",
      "lastName" : "Parker",
      "email" : "emily.parker@fenige.pl"
    }
  }, {
    "id" : 6893,
    "cardNumber" : "XXXX-XXXX-XXXX-6204",
    "bin" : "756055",
    "phoneNumber" : "48787821093",
    "data" : {
      "firstName" : "Emily",
      "lastName" : "Parker",
      "email" : "emily.parker@fenige.pl"
    }
  } ]
}
Table 81. Response fields
Path Type Description

status

String

Response status from Fenige system

success[].id

Number

ID in Fenige system

success[].phoneNumber

String

Friendcard holder’s phone number

success[].data.firstName

String

Friendcard holder’s first name

success[].data.lastName

String

Friendcard holder’s last name

success[].data.email

String

Friendcard holder’s email address

success[].cardNumber

String

Full 16-digits or 19-digits friendcard’s number

success[].bin

String

Six-digits bin of friendcard’s number

401 - Unauthorized
HTTP Response
HTTP/1.1 401 Unauthorized
Content-Type: application/json

{
    "timestamp": 1532606583290,
    "status": 401,
    "error": "Unauthorized",
    "message": "Unable to authorize merchant",
    "path": "/client/friend-card"
}

16. Global Delayed receivers

16.1. Add Global Delayed Receiver

POST /client/delayed-receiver Content-Type: application/json, Authorization: Basic Auth
Method allows you to store favorite delayed receivers users identified by e-mail address or phone numbers and use them as DATACORE transaction receivers.

16.1.1. Request

Mastercard
POST /client/delayed-receiver HTTP/1.1
Content-Type: application/json
Authorization: Basic dXNlcjpwYXNzd29yZA==
Host: java-staging.fenige.pl:8181

{
    "firstName" : "John",
    "lastName": "Parker",
    "phoneNumber": "48123456788",
    "email": "test@fenige.pl",
    "cardNumber" : "5117964247989167"
}
Table 82. Request fields
Name Type Validation Description

firstName

String

Required
Cannot be the same as lastName
Cannot contains all the same characters

First name of delayed receiver

lastName

String

Required
Cannot be the same as firstName
Cannot contains all the same characters

Last name of delayed receiver

phoneNumber

String

Optional alternately with email

Delayed receiver phone identifier

email

String

Optional alternately with phone

Delayed receiver email identifier

cardNumber

String

Required

Delayed receiver card number

Visa
POST /client/delayed-receiver HTTP/1.1
Content-Type: application/json
Authorization: Basic dXNlcjpwYXNzd29yZA==
Host: java-staging.fenige.pl:8181

{
    "firstName" : "John",
    "lastName": "Parker",
    "phoneNumber": "48123456788",
    "email": "test@fenige.pl",
    "cardNumber" : "4762969630023394",
    "expirationDate" : "10/23"
}
Table 83. Request fields
Name Type Validation Description

firstName

String

Required
Cannot be the same as lastName
Cannot contains all the same characters

First name of delayed receiver

lastName

String

Required
Cannot be the same as firstName
Cannot contains all the same characters

Last name of delayed receiver

phoneNumber

String

Optional alternately with email

Delayed receiver phone identifier

email

String

Optional alternately with phone

Delayed receiver email identifier

cardNumber

String

Required

Delayed receiver card number

expirationDate

String

Required

Delayed receiver card expiration date

16.1.2. Response

Response status
Status Description

200 OK

Returned when delayed receiver was successfully added.

200 OK - Error validation

Returned list of field name which has validation errors.

409 CONFLICT

Returned when delayed receiver already exists.

Example HTTP Response
200 OK
HTTP Response
HTTP/1.1 200 OK
Content-Type: application/json;charset=UTF-8
Transfer-Encoding: Mon, 09 Nov 2020 13:14:29 GMT
Date: Mon, 09 Nov 2020 13:14:29 GMT

{
    "status": "S0000",
    "message": "SUCCESS",
    "httpStatus": "OK",
    "id": 1
}
Table 84. Response fields
Name Type Description

id

Long

Added delayed receiver id

200 OK - Error validation
HTTP Response
HTTP/1.1 200 OK
Content-Type: application/json;charset=UTF-8
Transfer-Encoding: Mon, 09 Nov 2020 13:14:29 GMT
Date: Mon, 09 Nov 2020 13:14:29 GMT

{
    "status": "ERROR_VALIDATION",
    "error": {
        "message": "Some information is missing or incorrect.",
        "errors": [
            {
                "field": "addGlobalDelayedReceiverRequest.email",
                "message": [
                    "length must be between 1 and 128",
                    "must be null",
                    "must be a well-formed email address",
                    "must not be blank"
                ]
            },
             {
                "field": "addGlobalDelayedReceiverRequest.phoneNumber",
                "message": [
                    "must not be null",
                    "must not be empty"
                ]
            },
            {
                "field": "addGlobalDelayedReceiverRequest.cardNumber",
                "message": [
                    "card number must be numeric",
                    "card number length must be 13 or 16 or 19",
                    "must not be blank",
                    "invalid card number"
                ]
            },
            {
                "field": "addGlobalDelayedReceiverRequest.lastName",
                "message": [
                    "length must be between 2 and 20",
                    "must not be blank",
                    "must match \"^[^0-9]+$\"",
                    "invalid lastName contains all the same characters",
                    "invalid firstName and lastName the same"
                ]
            },
            {
                "field": "addGlobalDelayedReceiverRequest.expirationDate",
                "message": [
                    "must not be blank"
                ]
            },
            {
                "field": "addGlobalDelayedReceiverRequest.firstName",
                "message": [
                    "must match \"^[^0-9]+$\"",
                    "length must be between 2 and 12",
                    "must not be blank",
                    "invalid firstName contains all the same characters",
                    "invalid firstName and lastName the same"
                ]
            }
        ]
    }
HTTP Response
HTTP/1.1 200 OK
Content-Type: application/json;charset=UTF-8
Transfer-Encoding: Mon, 09 Nov 2020 13:14:29 GMT
Date: Mon, 09 Nov 2020 13:14:29 GMT

{
    "status": "ERROR_VALIDATION",
    "error": {
        "message": "Some information is missing or incorrect.",
        "errors": [
            {
                "field": "addGlobalDelayedReceiverRequest.email",
                "message": [
                    "Phone number or email must be present"
                ]
            },
            {
                "field": "addGlobalDelayedReceiverRequest.phoneNumber",
                "message": [
                    "Phone number or email must be present"
                ]
            }
        ]
    }
}
409 CONFLICT
HTTP Response
HTTP/1.1 E0202
Content-Type: application/json;charset=UTF-8
Transfer-Encoding: Mon, 09 Nov 2020 13:14:29 GMT
Date: Mon, 09 Nov 2020 13:14:29 GMT

{
    "status": "E0202",
    "message": "Delayed receiver already exists",
    "httpStatus": "CONFLICT"
}

16.2. Get Global Delayed receiver

GET /client/delayed-receiver/?phoneNumber=48123456789 or /client/delayed-receiver/?email=email@fenige.pl Content-Type: application/json, Authorization: Basic Auth
Method allows you to get your stored favorite receivers and their cards identified by e-mail address or phone numbers and use them as DELAYED transaction receivers.

16.2.1. Request

/client/delayed-receiver/?phoneNumber=48123456789
GET /client/delayed-receiver/?phoneNumber=48123456789 HTTP/1.1
Content-Type: application/json
Authorization: Basic dXNlcjpwYXNzd29yZA==
Host: java-staging.fenige.pl:8181
Name Type Validation Description

phoneNumber

String

Required when email is empty

Delayed receiver phone identifier

email

String

Required when phoneNumber is empty

Delayed receiver email identifier

16.2.2. Response

Response status
Status Description

200 OK

Returned when delayed receiver was successfully checked out.

404 NOT FOUND

Returned when delayed receiver was not found.

Example HTTP Response
200 OK
HTTP Response
HTTP/1.1 200 OK
Content-Type: application/json;charset=UTF-8
Transfer-Encoding: Mon, 09 Nov 2020 13:14:29 GMT
Date: Mon, 09 Nov 2020 13:14:29 GMT

{
    "status": "S0000",
    "message": "SUCCESS",
    "httpStatus": "OK",
    "firstName": "John",
    "lastName": "Parker",
    "phoneNumber": "48123456788",
    "email": "test@fenige.pl",
    "receiverUuid": "c70d4a62-7e2c-49fb-a856-738207dd7735",
    "delayedReceiverCard": "511796******9167"
}
Table 85. Response fields
Name Type Description

status

String

Response status from Fenige system

message

String

Description of status from Fenige system

httpStatus

String

Http status of response

firstName

String

Delayed receiver first name

lastName

String

Delayed receiver last name

phoneNumber

String

Delayed receiver phone number

email

String

Delayed receiver email

receiverUuid

String

Delayed receiver Uuid

delayedReceiverCard

String

Delayed receiver card

404 NOT FOUND
HTTP Response
HTTP/1.1 E0201
Content-Type: application/json;charset=UTF-8
Transfer-Encoding: Mon, 09 Nov 2020 13:14:29 GMT
Date: Mon, 09 Nov 2020 13:14:29 GMT

{
    "status": "E0201",
    "message": "Can't find delayed receiver",
    "httpStatus": "NOT_FOUND"
}

16.3. Delete Global Delayed receiver

DELETE /client/delayed-receiver/?phoneNumber=48123456789 or /client/delayed-receiver/?email=email@fenige.pl Content-Type: application/json, Authorization: Basic Auth
Method allows you to remove your stored favorite receiver from Global Receivers Database and their cards identified by e-mail address or phone numbers.

16.3.1. Request

/client/delayed-receiver/?phoneNumber=48123456789
DELETE /client/delayed-receiver/?phoneNumber=48123456788 HTTP/1.1
Content-Type: application/json
Authorization: Basic dXNlcjpwYXNzd29yZA==
Host: java-staging.fenige.pl:8181
Name Type Validation Description

phoneNumber

String

Required when email is empty

Delayed receiver phone identifier

email

String

Required when phoneNumber is empty

Delayed receiver email identifier

16.3.2. Response

Response status
Status Description

200 OK

Returned when delayed receiver was successfully removed.

404 NOT FOUND

Returned when delayed receiver was not found.

Example HTTP Response
200 OK
HTTP Response
HTTP/1.1 200 OK
Content-Type: application/json;charset=UTF-8
Transfer-Encoding: Mon, 09 Nov 2020 13:14:29 GMT
Date: Mon, 09 Nov 2020 13:14:29 GMT

{
    "status": "S0000",
    "message": "SUCCESS",
    "httpStatus": "OK"
}
Table 86. Response fields
Name Type Description

status

String

Status of delete operation

message

String

Description of status

404 NOT FOUND
HTTP Response
HTTP/1.1 E0201
Content-Type: application/json;charset=UTF-8
Transfer-Encoding: Mon, 09 Nov 2020 13:14:29 GMT
Date: Mon, 09 Nov 2020 13:14:29 GMT

{
    "status": "E0201",
    "message": "Can't find delayed receiver",
    "httpStatus": "NOT_FOUND"
}

17. Models

17.1. Senders

17.1.1. SENDER PLAIN

Path Type Validation Rule Description

type

String

Required

@NotNull

For this configuration the value of this field must be "PLAIN", otherwise request will be declined

firstName

String

Required

@NotNull
@NotBlank
@Length(min = 2, max = 35)
@Pattern(regexp = "^[^0-9]+$")
FirstName cannot be the same as lastName
FirstName cannot contains all the same characters

Sender first name

lastName

String

Required

@NotNull
@NotBlank
@Length(min = 2, max = 35)
@Pattern(regexp = "^[^0-9]+$")
LastName cannot be the same as firstName
LastName cannot contains all the same characters

Sender last name

street

String

Required

@NotNull
@NotBlank
@Length(min = 1, max = 55)
@Pattern(regexp = "^[^\\s\](\\s[^\\s]+)*$")

Sender street

houseNumber

String

Required

@NotNull
@NotBlank
@Length(min = 1, max = 10)
@Pattern(regexp = "^[0-9]{1,5}[A-z]?(?:/[0-9]{1,5}[A-z]?)?$")

Sender house number

city

String

Required

@NotNull
@NotBlank
@Length(min = 1, max = 55)

Sender city

postalCode

String

Required

@NotNull
@NotBlank
@Length(min = 1, max = 10)
@Pattern(regexp = "^(?=.*\d)(?=.*[1-9,a-zA-Z]).{1,10}$"

Sender postal code

flatNumber

String

Optional

@Length(min = 1, max = 5) @Pattern(regexp = "^[a-zA-Z0-9 ]*$")

Sender flat number

email

String

Required

@NotNull
@NotBlank
@Length(min = 1, max = 128)
@Pattern(regexp = "^(?:[A-Za-z0-9]{1,}[\\.!#$%&'*/=?`{|}~^\\-_]?){1,}[A-Za-z0-9]{1,}@((?:[a-zA-Z0-9](?:-[a-zA-Z0-9]+)*\\.){1,}[a-zA-Z]{2,})$")
Email cannot be the same for 2 different persons sender and receiver

Sender email

personalId

String

Optional

Sender identification number

cardNumber

String

Required

@NotNull
@NotBlank
@Length(min = 16, max = 16)
@LuhnCheck

Sender card number

expirationDate

String

Required

@NotNull
@NotBlank

Sender card expiration date. Example: 11/18

currency

String

Required

@NotNull
@Length(min = 3, max =3)

Currency for transaction (in accordance with ISO-4217). Example: PLN

country

String

Optional or Required for USA/CAN card

@Length(min = 2, max = 2)

Country code in accordance with ISO 3166-1

province

String

Optional or Required for USA/CAN card

@NotNull
@NotBlank
@Length(min = 2, max = 2)

USA state or CAN province code. Field is required when card country is USA or CAN.

STANDARD
"sender" : {
    "type" : "PLAIN",
    "firstName" : "Mark",
    "lastName" : "Smith",
    "street" : "Olszewskiego",
    "houseNumber" : "10",
    "city" : "Lublin",
    "postalCode" : "20-400",
    "email" : "senderdocs@fenige.pl",
    "cardNumber" : "5117964247989169",
    "expirationDate" : "09/21",
    "currency" : "PLN"
}
USA/CAN TRANSACTIONS
"sender" : {
    "type" : "PLAIN",
    "firstName" : "Mark",
    "lastName" : "Smith",
    "street" : "Gates Court",
    "houseNumber" : "82",
    "city" : "Brooklyn",
    "postalCode" : "11211",
    "email" : "senderdocs@fenige.pl",
    "cardNumber" : "5448424719416233",
    "expirationDate" : "09/21",
    "currency" : "USD",
    "country": "US",
    "province": "NY"
}

17.1.2. SENDER CASH

Path Type Validation Rule Description

type

String

Required

@NotNull
@NotBlank

For this configuration the value of this field must be "CASH", otherwise request will be declined

firstName

String

Required

@NotNull
@NotBlank
@Length(min = 2, max = 35)
@Pattern(regexp = "^[^0-9]+$")
FirstName cannot be the same as lastName
FirstName cannot contains all the same characters

Sender first name

lastName

String

Required

@NotNull
@NotBlank
@Length(min = 2, max = 35)
@Pattern(regexp = "^[^0-9]+$")
LastName cannot be the same as firstName
LastName cannot contains all the same characters

Sender last name

street

String

Required

@NotNull
@NotBlank
@Length(min = 1, max = 55)
@Pattern(regexp = "^[^\\s\](\\s[^\\s]+)*$")

Sender street

houseNumber

String

Required

@NotNull
@NotBlank
@Length(min = 1, max = 10)
@Pattern(regexp = "^[0-9]{1,5}[A-z]?(?:/[0-9]{1,5}[A-z]?)?$")

Sender house number

city

String

Required

@NotNull
@NotBlank
@Length(min = 1, max = 55)

Sender city

postalCode

String

Required

@NotNull
@NotBlank
@Length(min = 1, max = 10)
@Pattern(regexp = "^(?=.*\d)(?=.*[1-9,a-zA-Z]).{1,10}$")

Sender postal code

country

String

Required

@NotNull
@NotBlank
@Length(min = 2, max = 2)

Sender country code in accordance with ISO 3166-1

flatNumber

String

Optional

@Length(min = 1, max = 5)

Sender flat number

email

String

Optional

@Length(min = 1, max = 128)
@Pattern(regexp = "^(?:[A-Za-z0-9]{1,}[\\.!#$%&'*/=?`{|}~^\\-_]?){1,}[A-Za-z0-9]{1,}@((?:[a-zA-Z0-9](?:-[a-zA-Z0-9]+)*\\.){1,}[a-zA-Z]{2,})$")
Email cannot be the same for 2 different persons sender and receiver

Sender email

personalId

String

Optional

Sender identification number

currency

String

Required

@NotNull
@Length(min = 3, max = 3)

Currency for transaction. Example: PLN

"sender": {
    "type": "CASH",
    "firstName": "Mark",
    "lastName": "Smith",
    "street": "Olszewskiego",
    "houseNumber": "10",
    "city": "Lublin",
    "postalCode": "20-481",
    "country": "PL",
    "currency": "PLN"
}

17.1.3. SENDER DATACORE

Path Type Validation Rule Description

type

String

Required

@NotNull
@NotBlank

For this configuration the value of this field must be "DATACORE", otherwise request will be declined

firstName

String

Required

@NotNull
@NotBlank
@Length(min = 2, max = 35)
@Pattern(regexp = "^[^0-9]+$")
FirstName cannot be the same as lastName
FirstName cannot contains all the same characters

Sender first name

lastName

String

Required

@NotNull
@NotBlank
@Length(min = 2, max = 35)
@Pattern(regexp = "^[^0-9]+$")
LastName cannot be the same as firstName
LastName cannot contains all the same characters

Sender last name

street

String

Required

@NotNull
@NotBlank
@Length(min = 1, max = 55)
@Pattern(regexp = "^[^\\s\](\\s[^\\s]+)*$")

Sender street

houseNumber

String

Required

@NotNull
@NotBlank
@Length(min = 1, max = 10)
@Pattern(regexp = "^[0-9]{1,5}[A-z]?(?:/[0-9]{1,5}[A-z]?)?$")

Sender house number

city

String

Required

@NotNull
@NotBlank
@Length(min = 1, max = 55)

Sender city

postalCode

String

Required

@NotNull
@NotBlank
@Length(min = 1, max = 10)
@Pattern(regexp = "^(?=.*\d)(?=.*[1-9,a-zA-Z]).{1,10}$"

Sender postal code

flatNumber

String

Optional

@Length(min = 1, max = 5)

Sender flat number

cardId

Long

Required

@NotNull

Sender card id

email

String

Optional

@Length(min = 1, max = 128)
@Pattern(regexp = "^(?:[A-Za-z0-9]{1,}[\\.!#$%&'*/=?`{|}~^\\-_]?){1,}[A-Za-z0-9]{1,}@((?:[a-zA-Z0-9](?:-[a-zA-Z0-9]+)*\\.){1,}[a-zA-Z]{2,})$")
Email cannot be the same for 2 different persons sender and receiver

Sender email

personalId

String

Optional

Sender identification number

currency

String

Required

@Length(min = 3, max = 3)

Currency for transaction. Example: PLN

"sender": {
    "type": "DATACORE",
    "firstName": "Mark",
    "lastName": "Smith",
    "street": "Olszewskiego",
    "houseNumber": "10",
    "city": "Lublin",
    "postalCode": "20-481",
    "cardId":3574,
    "email": "senderdocs@fenige.pl",
    "currency": "PLN"
}

17.2. Receivers

17.2.1. RECEIVER PLAIN

Path Type Validation Rule Description

type

String

Required

@NotNull
@NotBlank

For this configuration the value of this field must be "PLAIN", otherwise request will be declined

firstName

String

Required

@NotNull
@NotBlank
@Length(min = 2, max = 35)
@Pattern(regexp = "^[^0-9]+$")
FirstName cannot be the same as lastName
FirstName cannot contains all the same characters

Receiver first name

lastName

String

Required

@NotNull
@NotBlank
@Length(min = 2, max = 35)
@Pattern(regexp = "^[^0-9]+$")
LastName cannot be the same as firstName
LastName cannot contains all the same characters

Receiver last name

cardNumber

String

Required

@NotNull
@NotBlank,
@Length(min = 16, max = 16)
@LuhnCheck

Receiver card number

street

String

Optional

@Length(min = 1, max = 55)
@Pattern(regexp = "^[^\\s\](\\s[^\\s]+)*$")

Receiver street

houseNumber

String

Optional

@Length(min = 1, max = 10)
@Pattern(regexp = "^[0-9]{1,5}[A-z]?(?:/[0-9]{1,5}[A-z]?)?$")

Receiver house number

city

String

Optional

@Length(min = 1, max = 55)

Receiver city

postalCode

String

Optional

@Length(min = 1, max = 10)
@Pattern(regexp = "^(?=.*\d)(?=.*[1-9,a-zA-Z]).{1,10}$"

Receiver postal code

flatNumber

String

Optional

@Length(min = 1, max = 5)
@Pattern(regexp = "^[a-zA-Z0-9 ]*$")

Receiver flat number

email

String

Optional

@Length(min = 1, max = 128)
@Pattern(regexp = "^(?:[A-Za-z0-9]{1,}[\\.!#$%&'*/=?`{|}~^\\-_]?){1,}[A-Za-z0-9]{1,}@((?:[a-zA-Z0-9](?:-[a-zA-Z0-9]+)*\\.){1,}[a-zA-Z]{2,})$")
Email cannot be the same for 2 different persons sender and receiver

Receiver email

currency

String

Required

@Length(min = 3, max = 3)

Currency for transaction. Example: PLN

"receiver" : {
    "type" : "PLAIN",
    "firstName" : "Rob",
    "lastName" : "Jackson",
    "cardNumber" : "5117964247989169",
    "currency" : "PLN"
}

17.2.2. RECEIVER CASH

Path Type Validation Rule Description

type

String

Required

@NotNull
@NotBlank

For this configuration the value of this field must be "CASH", otherwise request will be declined

firstName

String

Required

@NotNull
@NotBlank
@Length(min = 2, max = 35)
@Pattern(regexp = "^[^0-9]+$")
FirstName cannot be the same as lastName
FirstName cannot contains all the same characters

Receiver first name

lastName

String

Required

@NotNull
@NotBlank
@Length(min = 2, max = 35)
@Pattern(regexp = "^[^0-9]+$")
LastName cannot be the same as firstName
LastName cannot contains all the same characters

Receiver last name

country

String

Required

@NotNull

Receiver country code in accordance with ISO 3166-1

street

String

Optional

@Length(min = 1, max = 55)
@Pattern(regexp = "^[^\\s\](\\s[^\\s]+)*$")

Receiver street

houseNumber

String

Optional

@Length(min = 1, max = 10)
@Pattern(regexp = "^[0-9]{1,5}[A-z]?(?:/[0-9]{1,5}[A-z]?)?$")

Receiver house number

city

String

Optional

@Length(min = 1, max = 55)

Receiver city

postalCode

String

Optional

@Length(min = 1, max = 10)
@Pattern(regexp = "^(?=.*\d)(?=.*[1-9,a-zA-Z]).{1,10}$"

Receiver postal code

flatNumber

String

Optional

@Length(min = 1, max = 5)
@Pattern(regexp = "^[a-zA-Z0-9 ]*$")

Receiver flat number

email

String

Optional

@Length(min = 1, max = 128)
@Pattern(regexp = "^(?:[A-Za-z0-9]{1,}[\\.!#$%&'*/=?`{|}~^\\-_]?){1,}[A-Za-z0-9]{1,}@((?:[a-zA-Z0-9](?:-[a-zA-Z0-9]+)*\\.){1,}[a-zA-Z]{2,})$")
Email cannot be the same for 2 different persons sender and receiver

Receiver email

currency

String

Required

@NotNull @Length(min = 3, max = 3)

Currency for transaction. Example: PLN

"receiver" : {
    "type" : "CASH",
    "firstName" : "Rob",
    "lastName" : "Jackson",
    "country": "PL",
    "currency" : "PLN"
}

17.2.3. RECEIVER DATACORE

Path Type Validation Rule Description

type

String

Required

@NotNull
@NotBlank

For this configuration the value of this field must be "DATACORE", otherwise request will be declined

firstName

String

Required

@NotNull
@NotBlank
@Length(min = 2, max = 35)
@Pattern(regexp = "^[^0-9]+$")
FirstName cannot be the same as lastName
FirstName cannot contains all the same characters

Receiver first name

lastName

String

Required

@NotNull
@NotBlank
@Length(min = 2, max = 35)
@Pattern(regexp = "^[^0-9]+$")
LastName cannot be the same as firstName
LastName cannot contains all the same characters

Receiver last name

cardId

Long

Required

@NotNull
@NotBlank

Receiver id

email

String

Reqiured

@NotNull
@NotBlank
@Length(min = 1, max = 128)
@Pattern(regexp = "^(?:[A-Za-z0-9]{1,}[\\.!#$%&'*/=?`{|}~^\\-_]?){1,}[A-Za-z0-9]{1,}@((?:[a-zA-Z0-9](?:-[a-zA-Z0-9]+)*\\.){1,}[a-zA-Z]{2,})$")
Email cannot be the same for 2 different persons sender and receiver

Receiver email

currency

String

Required

@Length(min = 3, max = 3)

Currency for transaction. Example: PLN

"receiver" : {
    "type" : "DATACORE",
    "firstName" : "Rob",
    "lastName" : "Jackson",
    "cardId": 1234,
    "email" : "senderdocs@fenige.pl",
    "currency" : "PLN"
}

17.2.4. RECEIVER PHONE

Path Type Validation Rule Description

type

String

Required

@NotNull
@NotBlank

For this configuration the value of this field must be "PHONE" otherwise request will be declined

firstName

String

Required

@NotNull
@NotBlank
@Length(min = 2, max = 35)
@Pattern(regexp = "^[^0-9]+$")
FirstName cannot be the same as lastName
FirstName cannot contains all the same characters

Receiver first name

lastName

String

Required

@NotNull
@NotBlank
@Length(min = 2, max = 35)
@Pattern(regexp = "^[^0-9]+$")
LastName cannot be the same as firstName
LastName cannot contains all the same characters

Receiver last name

phoneNumber

String

Required

@NotNull
@NotBlank
must match "[0-9]+"

Receiver phone number

street

String

Optional

@Length(min = 1, max = 55)
@Pattern(regexp = "^[^\\s\](\\s[^\\s]+)*$")

Receiver street

houseNumber

String

Optional

@Length(min = 1, max = 10)
@Pattern(regexp = "^[0-9]{1,5}[A-z]?(?:/[0-9]{1,5}[A-z]?)?$")

Receiver house number

city

String

Optional

@Length(min = 1, max = 55)

Receiver city

postalCode

String

Optional

@Length(min = 1, max = 10)
@Pattern(regexp = "^(?=.*\d)(?=.*[1-9,a-zA-Z]).{1,10}$"

Receiver postal code

flatNumber

String

Optional

@Length(min = 1, max = 5)
@Pattern(regexp = "^[a-zA-Z0-9 ]*$")

Receiver flat number

email

String

Optional

@Length(min = 1, max = 128)
@Pattern(regexp = "^(?:[A-Za-z0-9]{1,}[\\.!#$%&'*/=?`{|}~^\\-_]?){1,}[A-Za-z0-9]{1,}@((?:[a-zA-Z0-9](?:-[a-zA-Z0-9]+)*\\.){1,}[a-zA-Z]{2,})$")
Email cannot be the same for 2 different persons sender and receiver

Receiver email

currency

String

Required

@NotNull @Length(min = 3, max = 3)

Currency for transaction. Example: PLN

"receiver" : {
    "type" : "PHONE",
    "firstName" : "Rob",
    "lastName" : "Jackson",
    "phoneNumber": "48123777619",
    "currency" : "PLN"
}

17.2.5. RECEIVER DELAYED

Delayed Send Money method
Path Type Validation Rule Description

type

String

Required

@NotNull
@NotBlank

For this configuration the value of this field must be "DELAYED", otherwise request will be declined

email

String

Required when phone is not present

@Length(min = 1, max = 128)
@Pattern(regexp = "^(?:[A-Za-z0-9]{1,}[\\.!#$%&'*/=?`{|}~^\\-_]?){1,}[A-Za-z0-9]{1,}@((?:[a-zA-Z0-9](?:-[a-zA-Z0-9]+)*\\.){1,}[a-zA-Z]{2,})$")

Receiver email

phoneNumber

String

Required when email is not present

@NotNull
@NotBlank
must match "[0-9]+"

Receiver phone number

currency

String

Required

@Length(min = 3, max = 3)

Currency for transaction. Example: PLN

"receiver" : {
    "type" : "DELAYED",
    "email" : "email@fenige.pl",
    "currency" : "PLN"
}
Delayed Payment method
Path Type Validation Rule Description

type

String

Required

@NotNull
@NotBlank

For this configuration the value of this field must be "DELAYED", otherwise request will be declined

firstName

String

Required

@NotNull
@NotBlank
@Length(min = 2, max = 35)
@Pattern(regexp = "^[^0-9]+$")
FirstName cannot be the same as lastName
FirstName cannot contains all the same characters

Receiver first name

lastName

String

Required

@NotNull
@NotBlank
@Length(min = 2, max = 35)
@Pattern(regexp = "^[^0-9]+$")
LastName cannot be the same as firstName
LastName cannot contains all the same characters

Receiver last name

cardNumber

String

Required

@NotNull @LuhnCheck

Receiver card number

email

String

Required when phone is not present

@Length(min = 1, max = 128)
@Pattern(regexp = "^(?:[A-Za-z0-9]{1,}[\\.!#$%&'*/=?`{|}~^\\-_]?){1,}[A-Za-z0-9]{1,}@((?:[a-zA-Z0-9](?:-[a-zA-Z0-9]+)*\\.){1,}[a-zA-Z]{2,})$")

Receiver email

phoneNumber

String

Required when email is not present

@NotNull
@NotBlank
must match "[0-9]+"

Receiver phone number

currency

String

Required

@Length(min = 3, max = 3)

Currency for transaction. Example: PLN

rememberReceiver

Boolean

Optional

true or false

By sending this field as 'true' value you can save receiver

"receiver" : {
    "type" : "DELAYED",
    "firstName" : "Rob",
    "lastName" : "Wring",
    "email" : "rob.wring@fenige.pl",
    "phoneNumber" : "600300200",
    "cardNumber" : "5117964247989169",
    "currency" : "PLN",
    "rememberReceiver" : true
  }

18. FAQ

Here you can find most frequency asked questions about Fenige Moneysend API