Fund Transfer and Cash on Delivery

Manage your Fund Transfer and Cash on Delivery payments in Craftgate via this service.

URL

The endpoint and http method information to make a payment with APM are stated below.

HTTP Method URL
POST /payment/v1/apm-payments

Payment initiation request parameters

Parameter Name Type Required Description
apmType string Yes See: Offline Alternative Payment Methods Alternative Payment Method type
price decimal Yes Total basket price. The sum of the item prices in the basket must be equal to total basket price.
paidPrice decimal Yes The final amount to be paid by calculating differences all the commissions and discounts.
currency Currency Yes See: Currencies
paymentGroup PaymentGroup Yes See: Payment Groups
paymentChannel string No It is generally used to keep information specific to the payment channel on the merchant side. You can search with this value later by using reporting services.
conversationId string No "boomerang" value that can be sent with the request and received with the response. It can be used to associate different requests with each other. Usually, the order number is used that is stored in merchant own system.
externalId string No It is generally used as a payment order number or basket number on the merchant side. You can search with this value later by using reporting services.
buyerMemberId number No ID of the buyer that is returned from member creation.
apmOrderId string No Order id parameter to be transmitted to the APM when receiving the payment. Since it is optional, it is recommended not to send it and the orderId value is generated by Craftgate.
clientIp string No IP of the buyer.
items PaymentItem[] Yes (See. Payment Item Information) Payment items related to payment. You must send at least one payment item and the sum of prices must be equal to the price field.

Response Parameters

Parameters returned as a result of payment are also subject to the rules specified in the Response Formats section of the API documentation home page. In the absence of a systematic or fictional error, the sub-parameters of the object returned in the data parameter are as follows:

Parameter Name Type Description
id number ID of the payment.
createdDate date The date that payment is created
apmType string See: Offline Alternative Payment Methods Alternative Payment Method type
price decimal Basket price of the payment
paidPrice decimal Paid price of the payment
walletPrice decimal Wallet price of the payment
currency Currency See: Currencies
buyerMemberId number Buyer member ID of the payment
conversationId string Value of theconversationId parameter sent in the payment request
externalId string externalId value that sent in payment request by merchant
paymentType PaymentType See: Payment Types
paymentGroup PaymentGroup See: Payment Groups
paymentSource PaymentSource See: Payment Sources
paymentStatus PaymentStatus See: Payment Status
paymentPhase PaymentPhase See: Payment Phases
paymentChannel string paymentChannel value sent by the merchant in the payment request
orderId string orderId value retrieved from bank related to the payment
paymentTransactions PaymentTransaction[] See: Payment Transactions Response Information

Payment Transactions Response Information

It includes the transaction information sent when making the payment request, and the pricing and money transfer information of the payment based on these transactions.

Parameter Name Type Description
id number ID of the payment transaction
externalId string External ID of the payment item that is sent in the request
name string Name of the payment item that is sent in the request
price decimal Basket price of the payment item
paidPrice decimal Paid price of the payment item
walletPrice decimal Wallet price of the payment item
merchantCommissionRate decimal Merchant's interest rate of the payment transaction
merchantCommissionRateAmount decimal Merchant's interest rate amount of the payment transaction
merchantPayoutAmount decimal Merchant's payout amount of the payment transaction
subMerchantMemberId number ID of the sub-merchant
subMerchantMemberPrice decimal Sub-merchant requested payout amount for the payment item.
subMerchantMemberPayoutRate decimal Sub-merchant payout rate for the payment item.
subMerchantMemberPayoutAmount decimal Sub-merchant payout amount for the payment item.
transactionStatus TransactionStatus See: Payment Item Confirmation Status Status of payment transaction confirmation
blockageResolvedDate date Date that the blockage will be resolved
payout Payout (ee: Payment Transactions Distribution of Payout

Payment Transactions Distribution of Payout

It includes the distribution of the money transfer to be made in relation to the payment, in a transaction specific, between the merchant, the sub-merchant and Craftgate.

The currency of the money distribution is always TRY.

Parameter Name Type Description
paidPrice decimal Total paid price of the payment transaction
parity decimal Foreign currency rate, for TRY payment it would be 1.
currency Currency See: Currencies
merchantPayoutAmount decimal Payout amount of the merchant
subMerchantMemberPayoutAmount decimal Payout amount of the sub-merchant

Sample Codes