On-Ramp use case
Phase 1: Integration & Debugging (Test Environment)
At this phase, set up a test environment for debugging.
- Process — contact the manager to get the Sandbox API Keys.
Phase 2: User On-Ramp Purchase Flow (Runtime)
This is the main flow, which occurs first in a test environment with the Sandbox API keys, and then in production.
- API — get the list of available countries with the /v1/available-countries method and
buyvalue insupportedFlowaway. - GUI — display available countries in your interface.
- API — get the list of currently available fiat currencies and cryptocurrencies with the /v1/currencies method and
buyvalue insupportedFlowaway. - GUI — ask the user for the currency pair to exchange: fiat as a payin currency and crypto as a payout. For example, it can be USD to ETH (Ethereum).
- GUI — ask the user for the amount to pay.
- API — call the /v1/offers method to get purchase offers from providers with an estimated ETH amount after purchase.
- API — call the /v1/providers method to get info about On-Ramp providers.
- GUI — show the offers with an estimated amount to the user and display info about providers who made the offers.
- GUI — ask the user to specify the wallet address where coins will be sent after purchase.
- API — call the /v1/validate-address method to validate the user's wallet address for a given currency.
- GUI — ask the user to choose the offer.
- GUI — ask the user to accept KYC/AML Policy and confirm the purchase.
- API — call POST /v1/orders to create a purchase order. For the order made with Sandbox API keys, the method returns a redirect URL to the Changelly purchase page. Otherwise, returns a redirect URL to the provider's purchase page.
- API — (for debugging of test orders only) call POST /v1/sandbox/order/id to change the order status and other properties.
- API — (for debugging of test orders only) call POST /v1/sandbox/order/id/resend-callback to check callback sending.
- GUI — redirect the user to the purchase page.
- API — call GET /v1/orders to get the full list of orders.
- API — get status updates in real-time via /Webhooks.
Phase 3: Go-Live (Production Environment)
After successful debugging of the Sandbox On-Ramp purchase flow from Phase 2, set up a production environment.
- System — replace the Sandbox Keys with the Production ones.