Gateway API
  1. Transfer Contracts
Gateway API
  • Gateway
    • Payments
      • Payment Contract
        • Generate a Payment Contract
        • Get Payment Contract
        • Cancel a Payment Contract
      • Webhook receiver for payment events
    • Fund Transfers
      • Transfer Contracts
        • Generate a Transfer Contract
          POST
        • Update Transfer Contract
          PATCH
        • Issue the Transfer Contract
          PUT
        • Get Transfer Contract
          GET
        • Pay a Transfer Contract
          PUT
        • Cancel a Transfer Contract
          DELETE
        • Contract Event Webhook
    • Schemas
      • Response
  • Schemas
    • Schemas
      • Response
        • Accounts
          • ResetAPIKeysResponse
          • GetAccountResponse
          • GetAccountActivitiesResponse
        • Wallets
          • CreateWalletResponse
          • CreateDebitEntryResponse
        • Profiles
        • Gateway
          • Transfers
            • GetTransferContractResponse
          • Payments
            • GetPaymentContractResponse
        • SuccessResponse
        • ErrorResponse
      • Models
        • Activities
          • Activity Types
            • PaymentActivityModel
          • SubActivityModel
          • ActivityModel
        • Profiles
          • ProfileModel
          • PersonalProfileModel
          • VerifiedPersonalProfileModel
          • EconomicProfileModel
          • BusinessProfileModel
          • GeographicProfileModel
          • TransactionRecordsModel
          • BehavioralProfileModel
          • DocumentaryProfileModel
          • RiskProfileModel
          • NetworkProfileModel
          • IndustryProfileModel
        • Accounts
          • APIKeysModel
          • AccountModel
          • AccountProxyModel
        • Wallets
          • WalletModel
          • WalletKeysModel
          • LedgerEntryModel
          • TransactionPayloadModel
        • Command
          • Parameters
            • TransferAmountParameters
          • CommandModel
          • CommandContextModel
          • CommandSignerModel
        • Policies
          • Service Policies
            • Accounts Policy
              • Constraints
              • Roles
              • AccountsPolicyModel
          • Policy Templates
            • ServicePolicyModel
            • ServiceRoleModel
            • ServiceConstraintModel
        • Verifiers
          • VerifierModel
          • VerificationModel
        • JWTs
          • ContractToken
        • Resources
        • Gateway
          • Transfers
            • TransferContractModel
            • TransferChannelModel
            • TransferRecipientModel
          • Payments
            • PaymentContractModel
            • PaymentChannelModel
            • PaymentRecipientModel
          • Contracts
            • ContractConstraintModel
            • ContractPreviewModel
            • ContractPaymentModel
            • ContractRecipientModel
            • ChannelModel
            • ContractDeliverableModel
          • Events
            • WebhookEvent
          • Channels
            • ChannelFeesModel
            • ChannelPolicyModel
          • ContractModel
      • RequestBodies
        • Commands
          • ExecuteCommandPayload
        • Accounts
          • CreateAccountPayload
          • RegisterAccountDevicePayload
          • RegisterAccountRecoveryMethodPayload
          • AccountPersonalProfilePayload
          • AttachAccountProfilePayload
        • Wallets
          • CreateWalletPayload
          • CreateDebitEntryPayload
          • DeleteWalletPayload
        • Verifier
          • StartVerificationPayload
          • CompleteVerificationPayload
        • Policies
          • AttachPolicyPayload
        • Resources
          • RegisterResourcePayload
          • RegisterResourceVerifiersPayload
        • Profiles
          • RequestProfileAccessTokenPayload
        • Gateway
          • Transfers
            • GenerateTransferContractPayload
            • UpdateTransferContractPayload
          • Payments
            • GeneratePaymentContractPayload
            • CryptoPaymentPayload
            • MayaPaymentPayload
            • GCashPaymentPayload
            • WalletPaymentPayload
            • QRPHPaymentPayload
            • CardPaymentPayload
  1. Transfer Contracts

Generate a Transfer Contract

Designing
POST
/contracts/transfer
Generate a transfer contract that can initiate a fund transfer to a recipient. Once issued, the contract becomes immutable. A contract can be paid by executing a gateway::paycontract command. Contract can be issued right away if all requirements had been submitted upon posting.

Request

Authorization
API Key
Add parameter in header
X-Api-Key
Example:
X-Api-Key: ********************
or
Body Params application/json

Examples

Responses

🟢200Success
application/json
Body

Request Request Example
Shell
JavaScript
Java
Swift
curl --location --request POST '/contracts/transfer' \
--header 'X-Api-Key: <api-key>' \
--header 'Content-Type: application/json' \
--data-raw '{
    "amount": 0,
    "currency": "PHP",
    "status": "draft",
    "issued_to": "string",
    "description": "string",
    "deliverable": {
        "type": "order",
        "reference_id": "string",
        "description": "string",
        "details": "string"
    },
    "recipient": {
        "name": "string",
        "email": "user@example.com",
        "mobile": "string",
        "wallet": "string",
        "tag": "string",
        "address": "string",
        "country": "string"
    },
    "channel": "unionbank",
    "preview": {
        "amount": 0,
        "valid": false,
        "fees": {
            "total": 0,
            "covered": true,
            "breakdown": {
                "pct": 0,
                "add": 0,
                "min": 0,
                "max": 0,
                "fixed": 0
            }
        },
        "messages": [
            {
                "code": "string",
                "type": "error",
                "message": "string"
            }
        ]
    },
    "expires_in": 0
}'
Response Response Example
{
    "status": 201,
    "message": "string",
    "data": {
        "contract": {
            "id": "497f6eca-6276-4993-bfeb-53cbbbba6f08",
            "amount": 0,
            "currency": "PHP",
            "status": "draft",
            "issued_by": "string",
            "issued_to": "string",
            "issued_at": "2019-08-24T14:15:22Z",
            "paid_by": "389dc3b9-e8eb-4e38-981b-97cb5e189b11",
            "paid_at": "2019-08-24T14:15:22Z",
            "expires_at": "2019-08-24T14:15:22Z",
            "description": "string",
            "deliverable": {
                "type": "order",
                "reference_id": "string",
                "description": "string",
                "details": "string"
            },
            "recipient": {
                "name": "string",
                "email": "user@example.com",
                "mobile": "string",
                "wallet": "string",
                "tag": "string",
                "address": "string",
                "country": "string"
            },
            "channel": {
                "id": "string",
                "service": "payment",
                "name": "string",
                "description": "string",
                "policy": {
                    "uri": "http://example.com"
                },
                "fees": {
                    "covered": true,
                    "breakdown": {
                        "pct": 0,
                        "add": 0,
                        "min": 0,
                        "max": 0,
                        "fixed": 0
                    }
                }
            },
            "payment": {
                "paid_at": "2019-08-24T14:15:22Z",
                "details": {
                    "id": "497f6eca-6276-4993-bfeb-53cbbbba6f08",
                    "type": "paid",
                    "actor": "b4172a54-df0e-4918-8f0c-143e6e6d9830",
                    "proxy": "2df1c044-2b92-4b6e-a41c-a8bd9dc68c78",
                    "summary": "string",
                    "published_at": "2019-08-24T14:15:22Z",
                    "resource": {
                        "id": "497f6eca-6276-4993-bfeb-53cbbbba6f08",
                        "type": "string",
                        "data": {}
                    }
                }
            },
            "activities": [
                {
                    "parent": "42e2bc1b-6741-4e2e-b138-97b4a342c999",
                    "id": "497f6eca-6276-4993-bfeb-53cbbbba6f08",
                    "type": "paid",
                    "actor": "b4172a54-df0e-4918-8f0c-143e6e6d9830",
                    "proxy": "2df1c044-2b92-4b6e-a41c-a8bd9dc68c78",
                    "summary": "string",
                    "published_at": "2019-08-24T14:15:22Z",
                    "resource": {
                        "id": "497f6eca-6276-4993-bfeb-53cbbbba6f08",
                        "type": "string",
                        "data": {}
                    }
                }
            ],
            "preview": {
                "amount": 0,
                "valid": false,
                "fees": {
                    "total": 0,
                    "covered": true,
                    "breakdown": {
                        "pct": 0,
                        "add": 0,
                        "min": 0,
                        "max": 0,
                        "fixed": 0
                    }
                },
                "messages": [
                    {
                        "code": "string",
                        "type": "error",
                        "message": "string"
                    }
                ]
            }
        }
    }
}
Modified at 2025-09-19 00:39:26
Previous
Webhook receiver for payment events
Next
Update Transfer Contract
Built with