Migration Guide

How to migrate from 2026-01-01 to 2026-01-25

Migration from 2026-01-01 to 2026-01-25

This guide will help you migrate your integration from API version 2026-01-01 to 2026-01-25.

Breaking Changes

  1. Response Structure: Responses now use structured objects with explicit types
  2. Amount Format: Money values changed from scalar to {value, currency} objects
  3. Settlement Info: Fees grouped into {gross, fees, net} structure
  4. Webhook Format: Events now use envelope structure with data wrapper

Step-by-Step Migration

Step 1: Update Amount Parsing

// Before (2026-01-01)
const amount = response.amount; // 50000
const currency = response.currency; // "TZS"

// After (2026-01-25)
const amount = response.amount.value; // 50000
const currency = response.amount.currency; // "TZS"

Step 2: Update Fee Handling

// Before (2026-01-01)
const fee = response.fee_amount;
const net = response.net_amount;

// After (2026-01-25)
const fee = response.settlement.fees.value;
const net = response.settlement.net.value;

Step 3: Update Webhook Handlers

// Before (2026-01-01)
const event = req.body.event;
const reference = req.body.reference;

// After (2026-01-25)
const eventType = req.body.type;
const eventId = req.body.id;
const data = req.body.data;

On this page