Skip to content

Create Customer Deposit

POST /api-access/transactions/client/sessions/customer-deposit

Create a new customer deposit transaction (A deposit made by a customer into your wallet).

Authentication

Required Headers:

Authorization: HMAC-SHA256 PUBLIC_KEY:PRIVATE_KEY
X-Origin: third-party-api.mara.boo
X-Timestamp: 2025-10-12T14:30:00.000Z
Content-Type: application/json

Request

Body Parameters:

ParameterTypeRequiredDescription
descriptionstringNoDescription of the deposit
wallet_idstringYesWallet ID to deposit into
transactionobjectYesTransaction details object
transaction.amountnumberYesAmount to deposit
transaction.payin_countrystringYesCountry code (e.g., ci)
transaction.bank_namestringYesName of the bank
transaction.sending_account_namestringYesName on the bank account the money is sent from
customerobjectYesCustomer details object
customer.namestringYesCustomer's full name
customer.emailstringYesCustomer's email address
customer.phonestringYesCustomer's phone number
metadataobjectNoAdditional metadata

Response

Success Response (200):

json
{
  "data": {
    "success": false,
    "transaction_id": "string",
    "transaction_reference": "string",
    "message": "string",
    "payment_link": "string",
    "status": "string",
    "http_status": 0,
    "session_id": "string",
    "extra": {}
  },
  "success": true,
  "message": "string",
  "detail": {}
}

Examples

bash
curl -X POST "https://sandbox-gateway.mara.boo/api-access/transactions/client/sessions/customer-deposit" \
  -H "Authorization: HMAC-SHA256 YOUR_PUBLIC_KEY:YOUR_PRIVATE_KEY" \
  -H "X-Origin: third-party-api.mara.boo" \
  -H "X-Timestamp: 2025-10-12T14:30:00.000Z" \
  -H "Content-Type: application/json" \
  -d '{
    "description": "Customer deposit",
    "wallet_id": "wallet-456",
    "transaction": {
      "amount": 1000,
      "payin_country": "ca",
      "bank_name": "TD Bank",
      "sending_account_name": "John Doe"
    },
    "customer": {
      "name": "John Doe",
      "email": "john.doe@example.com",
      "phone": "+1234567890"
    },
    "metadata": {}
  }'
javascript
const response = await fetch('https://sandbox-gateway.mara.boo/api-access/transactions/client/sessions/customer-deposit', {
  method: 'POST',
  headers: {
    'Authorization': 'HMAC-SHA256 YOUR_PUBLIC_KEY:YOUR_PRIVATE_KEY',
    'X-Origin': 'third-party-api.mara.boo',
    'X-Timestamp': '2025-10-12T14:30:00.000Z',
    'Content-Type': 'application/json'
  },
  body: JSON.stringify({
    description: "Customer deposit",
    wallet_id: "wallet-456",
    transaction: {
      amount: 1000,
      payin_country: "ca",
      bank_name: "TD Bank",
      sending_account_name: "John Doe"
    },
    customer: {
      name: "John Doe",
      email: "john.doe@example.com",
      phone: "+1234567890"
    },
    metadata: {}
  })
});

const data = await response.json();
python
import requests

response = requests.post(
    'https://sandbox-gateway.mara.boo/api-access/transactions/client/sessions/customer-deposit',
    headers={
        'Authorization': 'HMAC-SHA256 YOUR_PUBLIC_KEY:YOUR_PRIVATE_KEY',
        'X-Origin': 'third-party-api.mara.boo',
        'X-Timestamp': '2025-10-12T14:30:00.000Z',
        'Content-Type': 'application/json'
    },
    json={
        "description": "Customer deposit",
        "wallet_id": "wallet-456",
        "transaction": {
            "amount": 1000,
            "payin_country": "ca",
            "bank_name": "TD Bank",
            "sending_account_name": "John Doe"
        },
        "customer": {
            "name": "John Doe",
            "email": "john.doe@example.com",
            "phone": "+1234567890"
        },
        "metadata": {}
    }
)

data = response.json()
go
package main

import (
    "bytes"
    "encoding/json"
    "net/http"
    "io/ioutil"
)

func main() {
    payload := map[string]interface{}{
        "description": "Customer deposit",
        "wallet_id": "wallet-456",
        "transaction": map[string]interface{}{
            "amount": 1000,
            "payin_country": "ca",
            "bank_name": "TD Bank",
            "sending_account_name": "John Doe",
        },
        "customer": map[string]interface{}{
            "name": "John Doe",
            "email": "john.doe@example.com",
            "phone": "+1234567890",
        },
        "metadata": map[string]interface{}{},
    }

    jsonData, _ := json.Marshal(payload)

    client := &http.Client{}
    req, _ := http.NewRequest("POST", "https://sandbox-gateway.mara.boo/api-access/transactions/client/sessions/customer-deposit", bytes.NewBuffer(jsonData))

    req.Header.Set("Authorization", "HMAC-SHA256 YOUR_PUBLIC_KEY:YOUR_PRIVATE_KEY")
    req.Header.Set("X-Origin", "third-party-api.mara.boo")
    req.Header.Set("X-Timestamp", "2025-10-12T14:30:00.000Z")
    req.Header.Set("Content-Type", "application/json")

    resp, _ := client.Do(req)
    defer resp.Body.Close()

    body, _ := ioutil.ReadAll(resp.Body)
}
java
import java.net.http.HttpClient;
import java.net.http.HttpRequest;
import java.net.http.HttpResponse;
import java.net.URI;

String jsonPayload = """
{
  "description": "Customer deposit",
  "wallet_id": "wallet-456",
  "transaction": {
    "amount": 1000,
    "payin_country": "ca",
    "bank_name": "TD Bank",
    "sending_account_name": "John Doe"
  },
  "customer": {
    "name": "John Doe",
    "email": "john.doe@example.com",
    "phone": "+1234567890"
  },
  "metadata": {}
}
""";

HttpClient client = HttpClient.newHttpClient();
HttpRequest request = HttpRequest.newBuilder()
    .uri(URI.create("https://sandbox-gateway.mara.boo/api-access/transactions/client/sessions/customer-deposit"))
    .header("Authorization", "HMAC-SHA256 YOUR_PUBLIC_KEY:YOUR_PRIVATE_KEY")
    .header("X-Origin", "third-party-api.mara.boo")
    .header("X-Timestamp", "2025-10-12T14:30:00.000Z")
    .header("Content-Type", "application/json")
    .POST(HttpRequest.BodyPublishers.ofString(jsonPayload))
    .build();

HttpResponse<String> response = client.send(request, HttpResponse.BodyHandlers.ofString());
csharp
using System.Net.Http;
using System.Text;
using System.Text.Json;

var payload = new
{
    description = "Customer deposit",
    wallet_id = "wallet-456",
    transaction = new
    {
        amount = 1000,
        payin_country = "ca",
        bank_name = "TD Bank",
        sending_account_name = "John Doe"
    },
    customer = new
    {
        name = "John Doe",
        email = "john.doe@example.com",
        phone = "+1234567890"
    },
    metadata = new { }
};

var client = new HttpClient();
var request = new HttpRequestMessage(HttpMethod.Post, "https://sandbox-gateway.mara.boo/api-access/transactions/client/sessions/customer-deposit");

request.Headers.Add("Authorization", "HMAC-SHA256 YOUR_PUBLIC_KEY:YOUR_PRIVATE_KEY");
request.Headers.Add("X-Origin", "third-party-api.mara.boo");
request.Headers.Add("X-Timestamp", "2025-10-12T14:30:00.000Z");

var jsonContent = JsonSerializer.Serialize(payload);
request.Content = new StringContent(jsonContent, Encoding.UTF8, "application/json");

var response = await client.SendAsync(request);
var content = await response.Content.ReadAsStringAsync();

Error Responses

Status CodeDescription
400Bad Request - Invalid parameters
401Unauthorized - Invalid authentication
403Forbidden - Missing required headers
422Validation Error - Field validation failed
500Internal Server Error