Integration guidelines
This guide outlines integration approaches for property developers and platforms enabling international property payments through Redpin’s APIs.
Common use cases
This guide is designed for property developers, real estate platforms, and fintech companies facilitating cross-border property transactions.
Integration approaches
Redpin offers two distinct integration methods. The following comparison helps property developers select the optimal approach:
Decision framework
When to choose:
- Fast time to market is priority
- Limited development resources available
- Standard payment flows meet requirements
- Minimal ongoing maintenance preferred
When to choose:
- Custom user experience requirements
- Existing payment workflows to integrate
- Full control over customer journey needed
- Advanced customization and branding required
Hosted integration workflow
The hosted approach simplifies implementation by redirecting customers to Redpin’s hosted payment interface.
Step 1: Submit third-party customer data
Submit compliance data for the customer who will be making the payment:
Step 2: Session creation
Step 3: Customer interaction
The session creation response provides options for customer interaction:
- Web applications: Redirect customers to the returned session URL
- Embedded iframe: Embed the session URL within your application for integrated experiences
- Native mobile apps: Open the URL inside an “out of process” WebView, such as
ASWebAuthenticationSession
in iOS or Android Custom Tab, making the process feel seamless within your application
Customers complete their payment journey within Redpin’s hosted environment, including any required verification steps.
Step 4: Custom Theme Integration (optional)
You can theme the hosted experience to match your brand by sending a theme payload to the hosted session via postMessage
.
Why Custom Theme Integration?
Custom theming allows you to:
- Brand Consistency: Maintain your visual identity across the payment flow
- User Experience: Provide a seamless, familiar interface for your customers
- Trust Building: Reduce cognitive load by keeping users in your brand environment
- Conversion Optimization: Familiar UI elements can improve payment completion rates
Important Limitations
While custom themes allow branding and color/font customization, note:
- Core payment flow layout and structure cannot be modified
- Compliance and security elements are non-editable
- Theming is client-side only and should be optimized for mobile
See below for full theming limitations and supported properties.
Supported Theme Properties:
You can customize the following properties in your theme payload:
- fontFamily - Font family for all text (e.g.,
"CircularXX, sans-serif"
,"System"
)- Supported fonts: CircularXX, Helvetica, Roboto, Arial, sans-serif
- baseFontSize - Base font size in pixels (e.g.,
16
) - primaryColor - Primary brand color (hex code)
- background - Main background color (hex code)
- textPrimary - Primary text color (hex code)
- textDanger - Error/danger text color (hex code)
- buttonPrimary.bg - Primary button background color (hex code)
- buttonPrimary.text - Primary button text color (hex code)
- borderRadius - Border radius in pixels (e.g.,
10
,12
)
Additional theme properties may be added in future updates based on partner feedback and requirements.
How Theme Integration Works
Theme integration is a simple, flexible process that works the same way for any frontend application:
- Create Your Theme - Define colors, fonts, and styling that match your brand
- Send Theme to Hosted Page - Use postMessage (web) or JavaScript injection (mobile) to apply your theme when the payment page loads
- Listen for Updates - Handle communication between your app and the hosted payment page for real-time theme mode switches.
Key Benefits for Property Developers:
- Universal Structure: Same theme configuration works for web (iframe) and mobile (WebView) implementations
- Quick Setup: Minimal code changes required to implement theming
- Brand Control: Maintain visual consistency across your entire user journey
Implementation Elements:
Theme Configuration: Your theme configuration uses the same structure regardless of platform:
Message Communication: Your app communicates with the hosted page using the same message format:
Dynamic Theme Generation: Create themes based on user preferences or system settings:
Platform-Specific Implementation
Choose your platform below to see the specific implementation details:
React (Web)
React Native
What You’ll Build: An iframe-based integration that embeds the hosted payment page and applies your theme
Implementation Steps:
- Embed hosted session in iframe - Display the payment page within your app
- Set up message communication - Listen for when the hosted page is ready
- Apply theme via postMessage - Send your theme configuration to the hosted page
Validate event.origin
and use the exact origin from the hosted session URL when calling postMessage
for security.
For two-way communication, the hosted page can post updates back using window.postMessage
(web) or window.ReactNativeWebView.postMessage
(React Native). Ensure you validate messages and origins for security.
Best Practices:
- Performance: Send theme payload when the hosted page loads and when theme changes occur
- Fallbacks: Provide fallback values for required theme properties
- Validation: Validate theme payload structure before sending
- Testing: Test theme integration in both light and dark modes
- Accessibility: Ensure theme colors maintain sufficient contrast ratios
Important Notes:
- Fallback Theme: If no theme is provided, the hosted page will use a default theme to ensure consistent appearance
- Theme Updates: You can send updated themes when user preferences change (e.g., switching between light/dark mode)
Step 5: Callback handling
Implement callback URLs to handle successful and failed payment scenarios.
Step 6: Session expiration
Monitor session expiration times and create new sessions as needed for incomplete payments.
API integration workflow
The following workflow demonstrates complete payment lifecycle management through direct API calls.
Step 1: Payment method validation
Before initiating any payment flow, determine if Redpin should be presented as a payment option.
Display Redpin as the recommended payment method when:
- User needs to send cross-border multi-currency transfers, and
- User’s preferred currency is supported by Redpin, and
- User resides in a country supported by Redpin
Step 2: Submit third-party customer data
Step 3: Customer verification status
If customer verification passes, continue with the payment flow. If additional verification is required, handle it before proceeding.
Check customer status: Monitor the customer status to determine if you can proceed with payment creation:
If verification is complete:
- Customer status is “success”
- Continue to quote generation (Step 4)
If additional verification needed:
- Customer status is “pending” or “failure”
- Webhook will provide required documents
- Handle document collection in your UI
- Monitor status until customer verification succeeds
Step 4: Quote generation
Quotes typically expire after 30 minutes, so ensure timely customer decision-making.
Currency selection: Allow customers to select their source currency, destination currency, amount, and BUY/SELL operation.
Quote request:
The system returns a quoted amount, quote_id, and expiry time. Monitor quote expiration and regenerate as needed.
Step 5: Payment execution
Step 6: Payment instruction display
Step 7: Payment status monitoring
Real-time webhook notifications ensure customers stay informed throughout the payment process.
Webhook notifications: Receive real-time updates on conversion and payment status changes for customer service and reconciliation purposes.
Payment status examples:
Awaiting funds:
Payment completed:
Implementation considerations
Authentication requirements
Both integration approaches require OAuth 2.0 authentication using Client Credentials flow.
Reference the Authentication documentation for implementation details.
Webhook configuration
Implement webhook endpoints to receive real-time status updates for:
- Customer verification status changes
- Payment status transitions
- Conversion execution confirmations
Error handling
Implement comprehensive error handling for:
- Quote expiration scenarios
- Customer verification failures
- Payment processing delays
- Session timeout events
See the Error handling guide for detailed implementation.
Compliance requirements
Partners must ensure regulatory compliance for cross-border payment facilitation.
Required implementations:
- Display of Redpin’s Terms and Conditions
- Customer consent collection for data sharing
- Fraud prevention message presentation based on customer jurisdiction
- Regulatory compliance for cross-border payment facilitation
Testing environment
Utilize Redpin’s sandbox environment for comprehensive integration testing before production deployment.
For complete environment details, see the Environments guide.
Support and resources
- API documentation: Complete endpoint specifications available in the API Reference section
- Integration support: Contact the Partner Integrations Team
- Webhook testing: Use sandbox webhooks for development validation