Skip to main content

Documentation

Update Wallet

Change or modify a Rapyd Wallet.

Note

This endpoint replaces the deprecated endpoint - PUT /v1/user

  • HTTP method updated.

  • ewallet body parameter updated to path parameter.

Rapyd will continue to support the deprecated endpoint until December 31, 2024.

    • ewallet

    • ID of the Rapyd Wallet. String starting with ewallet_.

    • ewallet_reference_id

    • Rapyd Wallet ID defined by the customer or end user. Must be unique.

    • first_name

    • First name of the Rapyd Wallet owner. For a person wallet type, alphabetic characters and spaces.

    • last_name

    • Family name of the Rapyd Wallet owner. For a person wallet type, alphabetic characters and spaces.

    • .NET

      • using System;
        using System.Text.Json;
        
        namespace RapydApiRequestSample
        {
            class Program
            {
                static void Main(string[] args)
                {
                    try
                    {
                        var metadata = new
                        {
                            merchant_defined = "updated"
                        };
        
                        var requestObj = new
                        {
                            ewallet = "ewallet_72b4ff39ca50dccc73c0ee65d85e124e",
                            ewallet_reference_id = "4-star-pro-02212021",
                            metadata,
                        };
        
                        string request = JsonSerializer.Serialize(requestObj);
        
                        string result = RapydApiRequestSample.Utilities.MakeRequest("PUT", "/v1/user", request);
        
                        Console.WriteLine(result);
                    }
                    catch (Exception e)
                    {
                        Console.WriteLine("Error completing request: " + e.Message);
                    }
                }
            }
        }
    • JavaScript

      • const makeRequest = require('<path-to-your-utility-file>/utilities').makeRequest;
        
        async function main() {
          try {
            const body = {
              ewallet: 'ewallet_72b4ff39ca50dccc73c0ee65d85e124e',
              ewallet_reference_id: '4-star-pro-02212021',
              metadata: {
                merchant_defined: 'updated'
              }
            };
            const result = await makeRequest('PUT', '/v1/user', body);
        
            console.log(result);
          } catch (error) {
            console.error('Error completing request', error);
          }
        }
    • PHP

      • <?php
        $path = $_SERVER['DOCUMENT_ROOT'];
        $path .= "/<path-to-your-utility-file>/utilities.php";
        include($path);
        $body = [
            'ewallet' => 'ewallet_72b4ff39ca50dccc73c0ee65d85e124e',
            'ewallet_reference_id' => '4-star-pro-02212021',
            'metadata' => [
                'merchant_defined' => "updated"
            ]
          ];
        
        try {
            $object = make_request('put', '/v1/user', $body);
            var_dump($object);
        } catch(Exception $e) {
            echo "Error: $e";
        }
        ?>
    • Python

      • from pprint import pprint
        
        from utilities import make_request
        
        body = {
            "ewallet": "ewallet_72b4ff39ca50dccc73c0ee65d85e124e",
            "ewallet_reference_id": "4-star-pro-02212021",
            "metadata": {
                "merchant_defined": "updated"
            }
        }
        
        results = make_request(method='put', path='/v1/user', body=body)
        pprint(results)
  • /v1/ewallets/:ewallet

  • Update Wallet - Reference ID

  • curl -X post
    https://sandboxapi.rapyd.net/v1/ewallets/ewallet_ebad83012c3ffbb980d894cffc229f32
    -H 'access_key: your-access-key-here'
    -H 'Content-Type: application/json'
    -H 'idempotency: your-idempotency-parameter-here'
    -H 'salt: your-random-string-here'
    -H 'signature: your-calculated-signature-here'
    -H 'timestamp: your-unix-timestamp-here'
    -d '{
        "ewallet_reference_id": "4-star-pro-02212021"
    }
    '
    
  • {
        "status": {
            "error_code": "",
            "status": "SUCCESS",
            "message": "",
            "response_code": "",
            "operation_id": "ac196637-187a-4138-9387-abf0d0ce61dc"
        },
        "data": {
            "phone_number": null,
            "email": null,
            "first_name": null,
            "last_name": null,
            "id": "ewallet_ebad83012c3ffbb980d894cffc229f32",
            "status": "ACT",
            "accounts": [],
            "verification_status": "not verified",
            "type": "person",
            "metadata": {
                "merchant_defined": true
            },
            "ewallet_reference_id": "4-star-pro-02212021",
            "category": null,
            "contacts": {
                "data": [
                    {
                        "id": "cont_7ec26354caf45779d466adcded88ae67",
                        "first_name": "",
                        "last_name": "",
                        "middle_name": "",
                        "second_last_name": "",
                        "gender": "not_applicable",
                        "marital_status": "not_applicable",
                        "house_type": "",
                        "contact_type": "personal",
                        "phone_number": "",
                        "email": "",
                        "identification_type": "",
                        "identification_number": "",
                        "issued_card_data": {
                            "preferred_name": "",
                            "transaction_permissions": "",
                            "role_in_company": ""
                        },
                        "date_of_birth": null,
                        "country": "",
                        "nationality": null,
                        "address": null,
                        "ewallet": "ewallet_ebad83012c3ffbb980d894cffc229f32",
                        "created_at": 1625580563,
                        "metadata": {},
                        "business_details": null,
                        "compliance_profile": 0,
                        "verification_status": "not verified",
                        "send_notifications": false,
                        "mothers_name": ""
                    }
                ],
                "has_more": false,
                "total_count": 1,
                "url": "/v1/ewallets/ewallet_ebad83012c3ffbb980d894cffc229f32/contacts"
            },
            "parent_ewallet": null
        }
    }
  • Update Wallet - Associated Parent Wallet

  • curl -X post
    https://sandboxapi.rapyd.net/v1/ewallets/ewallet_b08cf1e48efa135b85142b2d332e2a49
    -H 'access_key: your-access-key-here'
    -H 'Content-Type: application/json'
    -H 'idempotency: your-idempotency-parameter-here'
    -H 'salt: your-random-string-here'
    -H 'signature: your-calculated-signature-here'
    -H 'timestamp: your-unix-timestamp-here'
    -d '{
        "parent_ewallet": "ewallet_fddc5585dbf751d36ac83b71b3e2863f"
    }
    '
    
  • {
        "status": {
            "error_code": "",
            "status": "SUCCESS",
            "message": "",
            "response_code": "",
            "operation_id": "819bee54-7fe9-4cd0-b390-7744d3e20187"
        },
        "data": {
            "phone_number": null,
            "email": null,
            "first_name": "John",
            "last_name": "Doe",
            "id": "ewallet_b08cf1e48efa135b85142b2d332e2a49",
            "status": "ACT",
            "accounts": [],
            "verification_status": "not verified",
            "type": "person",
            "metadata": {},
            "ewallet_reference_id": "2083-06-13395",
            "category": null,
            "contacts": {
                "data": [
                    {
                        "id": "cont_e7919a29d330e7ecb348aff296438e66",
                        "first_name": "John",
                        "last_name": "Doe",
                        "middle_name": "",
                        "second_last_name": "",
                        "gender": "not_applicable",
                        "marital_status": "not_applicable",
                        "house_type": "",
                        "contact_type": "personal",
                        "phone_number": "+3547267375",
                        "email": "johndoe@rapyd.net",
                        "identification_type": "DL",
                        "identification_number": "1234567890",
                        "issued_card_data": {
                            "preferred_name": "",
                            "transaction_permissions": "",
                            "role_in_company": ""
                        },
                        "date_of_birth": "2000-11-22",
                        "country": "IS",
                        "nationality": "IS",
                        "address": {
                            "id": "address_6b7b0e40231f713d89b037b59d9c37c2",
                            "name": "John Doe",
                            "line_1": "123 Main Street",
                            "line_2": "",
                            "line_3": "",
                            "city": "Anytown",
                            "state": "NY",
                            "country": "US",
                            "zip": "12345",
                            "phone_number": "+14155551611",
                            "metadata": {},
                            "canton": "",
                            "district": "",
                            "created_at": 1727356455
                        },
                        "ewallet": "ewallet_b08cf1e48efa135b85142b2d332e2a49",
                        "created_at": 1727356455,
                        "metadata": {
                            "merchant_defined": true
                        },
                        "business_details": null,
                        "compliance_profile": -1,
                        "verification_status": "not verified",
                        "send_notifications": false,
                        "mothers_name": "Jane Smith",
                        "contact_reference_id": null
                    }
                ],
                "has_more": false,
                "total_count": 1,
                "url": "/v1/ewallets/ewallet_b08cf1e48efa135b85142b2d332e2a49/contacts"
            },
            "parent_ewallet": "ewallet_fddc5585dbf751d36ac83b71b3e2863f"
        }
    }
  • Update Wallet - Metadata

  • curl -X post
    https://sandboxapi.rapyd.net/v1/ewallets/ewallet_49765d975b781eb6ef86af4b7259e6e4
    -H 'access_key: your-access-key-here'
    -H 'Content-Type: application/json'
    -H 'idempotency: your-idempotency-parameter-here'
    -H 'salt: your-random-string-here'
    -H 'signature: your-calculated-signature-here'
    -H 'timestamp: your-unix-timestamp-here'
    -d '{
        "metadata": {
            "merchant_defined": "updated data"
        }
    }
    '
    
  • {
        "status": {
            "error_code": "",
            "status": "SUCCESS",
            "message": "",
            "response_code": "",
            "operation_id": "2beecaf9-ca59-46ea-8169-9e4f04920840"
        },
        "data": {
            "phone_number": null,
            "email": null,
            "first_name": null,
            "last_name": null,
            "id": "ewallet_49765d975b781eb6ef86af4b7259e6e4",
            "status": "ACT",
            "accounts": [],
            "verification_status": "not verified",
            "type": "person",
            "metadata": {
                "merchant_defined": "updated data"
            },
            "ewallet_reference_id": null,
            "category": null,
            "contacts": {
                "data": [
                    {
                        "id": "cont_22a4a185f9933224895ab734c0d2735c",
                        "first_name": "",
                        "last_name": "",
                        "middle_name": "",
                        "second_last_name": "",
                        "gender": "not_applicable",
                        "marital_status": "not_applicable",
                        "house_type": "",
                        "contact_type": "personal",
                        "phone_number": "",
                        "email": "",
                        "identification_type": "",
                        "identification_number": "",
                        "issued_card_data": {
                            "preferred_name": "",
                            "transaction_permissions": "",
                            "role_in_company": ""
                        },
                        "date_of_birth": null,
                        "country": "",
                        "nationality": null,
                        "address": null,
                        "ewallet": "ewallet_49765d975b781eb6ef86af4b7259e6e4",
                        "created_at": 1669799087,
                        "metadata": {},
                        "business_details": null,
                        "compliance_profile": 0,
                        "verification_status": "not verified",
                        "send_notifications": false,
                        "mothers_name": ""
                    }
                ],
                "has_more": false,
                "total_count": 1,
                "url": "/v1/ewallets/ewallet_49765d975b781eb6ef86af4b7259e6e4/contacts"
            },
            "parent_ewallet": null
        }
    }
  • Update Wallet - First & Last Name

  • curl -X post
    https://sandboxapi.rapyd.net/v1/ewallets/ewallet_49765d975b781eb6ef86af4b7259e6e4
    -H 'access_key: your-access-key-here'
    -H 'Content-Type: application/json'
    -H 'idempotency: your-idempotency-parameter-here'
    -H 'salt: your-random-string-here'
    -H 'signature: your-calculated-signature-here'
    -H 'timestamp: your-unix-timestamp-here'
    -d '{
        "last_name": "Doe",
        "first_name": "John"
    }
    '
    
  • {
        "status": {
            "error_code": "",
            "status": "SUCCESS",
            "message": "",
            "response_code": "",
            "operation_id": "e726349f-1ee8-418a-8944-668ccaeda12b"
        },
        "data": {
            "phone_number": null,
            "email": null,
            "first_name": "John",
            "last_name": "Doe",
            "id": "ewallet_49765d975b781eb6ef86af4b7259e6e4",
            "status": "ACT",
            "accounts": [],
            "verification_status": "not verified",
            "type": "person",
            "metadata": {
                "merchant_defined": true
            },
            "ewallet_reference_id": null,
            "category": null,
            "contacts": {
                "data": [
                    {
                        "id": "cont_22a4a185f9933224895ab734c0d2735c",
                        "first_name": "",
                        "last_name": "",
                        "middle_name": "",
                        "second_last_name": "",
                        "gender": "not_applicable",
                        "marital_status": "not_applicable",
                        "house_type": "",
                        "contact_type": "personal",
                        "phone_number": "",
                        "email": "",
                        "identification_type": "",
                        "identification_number": "",
                        "issued_card_data": {
                            "preferred_name": "",
                            "transaction_permissions": "",
                            "role_in_company": ""
                        },
                        "date_of_birth": null,
                        "country": "",
                        "nationality": null,
                        "address": null,
                        "ewallet": "ewallet_49765d975b781eb6ef86af4b7259e6e4",
                        "created_at": 1669799087,
                        "metadata": {},
                        "business_details": null,
                        "compliance_profile": 0,
                        "verification_status": "not verified",
                        "send_notifications": false,
                        "mothers_name": ""
                    }
                ],
                "has_more": false,
                "total_count": 1,
                "url": "/v1/ewallets/ewallet_49765d975b781eb6ef86af4b7259e6e4/contacts"
            },
            "parent_ewallet": null
        }
    }