Virtual Accounts (BETA-CLOSED)

Sila’s Virtual Accounts feature allows customers to open a virtual account for their end users and provide them with an account and routing number that can be used for incoming "external" ACH transactions. "External" means that these ACH transactions are originated from a bank outside of Sila, and we receive those ACH transactions to the virtual account. Those incoming external ACH transactions can be credits or debits.

🚧

Incompatible with Virtual Accounts

  • Incoming external WIRE transactions are not supported at this time.

📘

Getting Access to Virtual Accounts

Sila needs to ensure you are prepared to support vAccounts for your users. Before contacting your Sila Sales Executive please review and ensure you will be able to meet the following requirements:

Eligibility Requirements:

  • Customer must have at least 3 full-time staff
  • Customer needs to establish and provide Sila hours of operation for end user support
  • Customer needs to establish an end user support policy with designated service level targets and measures
  • Customer needs to have a Complaints Management Program
  • Customer needs to have a Dispute and Error Handling Procedure that provides for intake, response and appropriate resolution of end user disputes in compliance with Regulation E
  • Customers must provide a sample volume report, service level report, and service quality scorecard.
  • Virtual Account Disclosures
  • Virtual Account Marketing and Advertising Content

To start the qualification process you will need to reach out to your Sila Sales Executive.

Sandbox - Virtual Accounts are disabled by default. Sandbox access will be turned on after approval.

Virtual Accounts End User Requirements

This end user entity must have passed full KYC/KYB in order to open a virtual account.

Usage

Open a Virtual Account

https://docs.silamoney.com/docs/open_virtual_account

To create a virtual account, use the /open_virtual_account API. The virtual account created will be associated with the end user entity provided in the authentication header.

The virtual account and routing number are provided in the response. A virtual account number is sixteen digit number. The first six digits of that number are a bin that is assigned to the customers app and will be static for all of that apps virtual accounts.

Example: [static bin][dynamic digits]
9710001234567890

Sample request/response - for SDK examples, refer to the link above for the full documentation.

POST /0.2/open_virtual_account HTTP/1.1
{
  "header": {
    "created": 1234567890, 
    "auth_handle": "handle.silamoney.eth", 
    "user_handle":"user.silamoney.eth", 
    "version": "0.2", 
    "reference": "<your unique id>"
  },
  "virtual_account_name": "My Virtual Account",
}

***
HTTP/1.1 200 OK

{
  "success": true,
  "status": "SUCCESS",
  "reference": "ref",
  "message": "Virtual account successfully opened.",
  "virtual_account": {
    "virtual_account_id": "d8bcfb75-b521-4230-b433-e453f43f668b",
    "virtual_account_name": "My Virtual Account",
    "account_number": "9710001234567890",
    "routing_number": "084106768",
    "account_type": "VIRTUAL_ACCOUNT",
    "active": true,
    "closed": false,
    "created_epoch": 1644525019,
    "closed_epoch": null,
    "ach_credit_enabled": true,
    "ach_debit_enabled": false
  }
}

View a Virtual Account

https://docs.silamoney.com/docs/get_virtual_account

To view the information about a virtual account including its balance, use the /get_virtual_account API.

Sample request/response - for SDK examples, refer to the link above for the full documentation.

POST /0.2/get_virtual_account HTTP/1.1
Host: sandbox.silamoney.com
authsignature: [GENERATED AUTHSIGNATURE HEX STRING HERE]
usersignature: [GENERATED USERSIGNATURE HEX STRING HERE]
Content-Type: application/json

{
  "header": {
    "created": 1234567890, 
    "app_handle": "handle.silamoney.eth", 
    "user_handle":"user.silamoney.eth", 
    "version": "0.2",
    "reference": "<your unique id>"
  },
  "virtual_account_id": "d8bcfb75-b521-4230-b433-e453f43f668b"
}

***

HTTP/1.1 200 OK

{
  "success": true,
  "status": "SUCCESS",
  "virtual_account": {
    "virtual_account_id": "UUID",
    "virtual_account_name": "myvaccount",
    "account_number": "9710001234567890",
    "routing_number": "084106768",
    "account_type": "VIRTUAL_ACCOUNT",
    "active": true,
    "closed": false,
    "created_epoch": 1644525019,
    "closed_epoch": null,
    "ach_credit_enabled": true,
    "ach_debit_enabled": false
  },
  "balance": {
    "pending_sila_balance": 120,
    "available_sila_balance": 120
  }
}

View All Virtual Accounts

https://docs.silamoney.com/docs/get_virtual_accounts

To view a list of virtual accounts for an entity, use the /get_virtual_accounts API.

Sample request/response - for SDK examples, refer to the link above for the full documentation.

POST /0.2/get_virtual_accounts HTTP/1.1
Host: sandbox.silamoney.com
authsignature: [GENERATED AUTHSIGNATURE HEX STRING HERE]
usersignature: [GENERATED USERSIGNATURE HEX STRING HERE]
Content-Type: application/json

{
  "header": {
    "created": 1234567890, 
    "app_handle": "handle.silamoney.eth", 
    "user_handle":"user.silamoney.eth", 
    "version": "0.2",
    "crypto": "ETH", 
    "reference": "<your unique id>"
  }
}

***

HTTP/1.1 200 OK

{
  "success": true,
  "status": "SUCCESS",
  "response_time_ms": "171",
  "virtual_accounts": [
    {
      "virtual_account_id": "UUID",
      "virtual_account_name": "myvaccount",
      "account_number": "9710001234567890",
      "routing_number": "084106768",
      "account_type": "VIRTUAL_ACCOUNT",
      "active": true,
      "closed": false,
      "created_epoch": 1644525019,
      "closed_epoch": null,
      "ach_credit_enabled": true,
      "ach_debit_enabled": false
    }
  ],
  "pagination": {
    "returned_count": 1,
    "total_count": 1,
    "current_page": 1,
    "total_pages": 1
  }
}

View All Payment Methods

https://docs.silamoney.com/docs/get_payment_methods

To view a list of payment methods for an entity, which would include virtual accounts, use the /get_payment_methods API.

Sample request/response - for SDK examples, refer to the link above for the full documentation.

POST /0.2/get_payment_methods HTTP/1.1
Host: sandbox.silamoney.com
authsignature: [GENERATED AUTHSIGNATURE HEX STRING HERE]
usersignature: [GENERATED USERSIGNATURE HEX STRING HERE]
Content-Type: application/json

{
  "header": {
    "created": 1234567890, 
    "auth_handle": "handle.silamoney.eth", 
    "user_handle":"user.silamoney.eth", 
    "reference": "<your unique id>"
  }
}

***

HTTP/1.1 200 OK

{
    "success": true,
    "payment_methods": [
        {
            "payment_method_type": "blockchain_address",
            "blockchain_address_id": "79e1154a-4a78-4ea9-971b-54a8b17dxxxx",
            "blockchain_address": "0x3999A8eb9B6CD5a3646497A354D2d9f90D42Ea8e",
            "blockchain_network": "ETH",
            "nickname": "My Wallet",
            "frozen": false,
            "default": true
        },
        {
            "payment_method_type": "bank_account",
            "bank_account_id": "db0be7e5-cd90-444c-9145-a9f64c3xxxxx",
            "account_number": "*9999",
            "routing_number": "044000000",
            "account_name": "Chase",
            "account_type": "CHECKING",
            "active": true,
            "account_status": "active",
            "account_link_status": "instantly_verified",
            "match_score": 0.95,
            "entity_name": "Sally Mander",
            "account_owner_name": "SALLY D MANDER",
            "web_debit_verified": true
        },
        {
            "payment_method_type": "card",
            "card_id": "17135ec1-607e-49bf-9bcd-28dcc46xxxxx",
            "card_name": "My Card",
            "card_last_4": 9999,
            "expiration": "202505",
            "card_type": "Debit",
            "pull_enabled": true,
            "push_enabled": true,
            "push_availability": "Immediate",
            "active": true,
            "country": "US",
            "currency": "USD"
        },
    {
            "payment_method_type": "virtual_account",
            "virtual_account_id": "UUID",
            "virtual_account_name": "myvaccount",
            "account_number": "9710001234567890",
            "routing_number": "084106768",
            "account_type": "VIRTUAL_ACCOUNT",
            "active": true,
            "closed": false,
            "created_epoch": 1644525019,
            "closed_epoch": null,
            "ach_credit_enabled": true,
            "ach_debit_enabled": false
        }      
    ],
    "pagination": {
        "returned_count": 4,
        "total_count": 4,
        "current_page": 1,
        "total_pages": 1
    },
    "status": "SUCCESS", 
    "response_time_ms": "171",
    "reference": "<your unique id>"
}

Incoming External ACH Transactions

Virtual accounts can receive incoming external ACH transactions that can be debits or credits. A credit transaction will appear as an "issue" transaction, and a debit transaction will appear as a "redeem" transaction.

Transaction Status Update webhooks will fire when these transactions occur based on the effective date of the transaction. If the effective date is not in the future (most common scenario), then you will receive a webhook with the "complete" status within an hour of when the transaction is received. If the transaction has an effective date in the future, you will first receive a webhook with the "queued" status within an hour of when the transaction is received, and then another webhook with the "complete" status on the morning of effective date.

📘

Sandbox Mocking

Since virtual accounts support incoming external ACH transactions, we created a special sandbox-only API that simulates these incoming external ACH transactions. By calling this API, you can observe the activity on the virtual account that is the result of these incoming external ACH transactions.

Creating Test Incoming External ACH Transactions in Sandbox

https://docs.silamoney.com/docs/testing_vaccount_transactions_in_sandbox

To simulate an external incoming ACH transaction to a virtual account, use the /create_test_virtual_account_ach_transaction API

Once you call this API, you can observe the transaction in /get_transactions. There may be a slight delay while the transaction is processing.

Valid Transaction Codes:
22: Automated deposit (checking credit)
23: Prenote of checking credit
27: Automated payment (checking debit)
28: Prenote of checking debit
32: Automated deposit (savings credit)
33: Prenote of savings credit
37: Automated payment (savings debit)
38: Prenote of savings debit

📘

Prenotes

A Prenote is a zero dollar transaction that can be sent to a virtual account as a debit or credit. Financial institutions often send a prenote transaction to an account for verification purposes prior to sending actual debits and credits.
Prenotes will trigger transaction webhooks and will appear in the /get_transactions API results.
Prenotes will not appear on statements.

Sample request/response - for SDK examples, refer to the link above for the full documentation.

POST /0.2/create_test_virtual_account_transaction HTTP/1.1
{
  "header": {
    "created": 1234567890, 
    "app_handle": "handle.silamoney.eth", 
    "user_handle":"user.silamoney.eth", 
    "version": "0.2",
    "reference": "ref"
  },
    "amount": 20000,
    "virtual_account_number": 9710001234567890,
    "tran_code": 22,
    "entity_name": "SALLY SMITH",
    "ced": "PAYROLL",
    "ach_name": "ACME INC"
}

***

HTTP/1.1 200 OK

{
  "success": true,
  "status": "SUCCESS",
  "reference": "ref",
  "message": "Transaction submitted to the processing queue."
}

Sila Transactions

Virtual account behave similarly to wallets, where you can use Sila APIs issue/transfer/redeem for moving funds in and out.

Creating Sila transactions involving virtual accounts requires the use of the virtual_account_id as the identifier of the virtual account, and using the new source_id and destination_id parameters in the issue/transfer/redeem APIs.

The virtual_account_id can be viewed using one of these APIs:
https://docs.silamoney.com/docs/get_virtual_accounts
https://docs.silamoney.com/docs/get_payment_methods

Below are some examples of how you can transact with a virtual account.

Issue Sila

https://docs.silamoney.com/docs/issue_sila

To add funds to a virtual account via a linked bank account, call /issue_sila, providing the account_name of the linked bank account as the source, and the destination_id as the virtual_account_id . Please note, descriptor is an optional parameter, and the use of a descriptor will incur an additional fee per transaction.
Also note for our instant products where virtual accounts are the destination, processing_type = "INSTANT_ACH" is supported, but processing_type = "INSTANT_SETTLEMENT" currently is not.

Sample request - linked bank account to virtual account

POST /0.2/issue_sila HTTP/1.1
{
  "header": {
    "created": 1234567890, 
    "app_handle": "handle.silamoney.eth", 
    "user_handle":"user.silamoney.eth", 
    "version": "0.2", 
    "reference": "ref"
  }, 
  "amount": 2000,
  "descriptor": "my transaction",
  "account_name": "My Chase", -- source is the linked bank account
  "destination_id": "d8bcfb75-b521-4230-b433-e453f43f668b", -- virtual_account_id of virtual account
  "business_uuid": "<your business UUID>",
  "processing_type": "STANDARD_ACH"
}
let userHandle = "<user Handle>";
let walletPrivateKey = "<user Wallet Private key>";
let amount = 200;
let accountName = "My Chase", //source is the linked bank account
let descriptor = "descriptor text" // optional
let businessUuid = "<your business UUID>"
let processingType = "STANDARD_ACH";
let cardName = "your card name" // Used in card transactions or NULL
let sourceId = "<linked bank account id>", //source is the linked bank account
let destinationId = "d8bcfb75-b521-4230-b433-e453f43f668b", //virtual_account_id of virtual account

// Also can used only one field : accountName or sourceID

const res = await Sila.issueSila(amount, userHandle, walletPrivateKey,accountName,descriptor,businessUuid,processingType,cardName,sourceId,destinationId);
payload = {
        "user_handle": user_handle,
        "amount": 2000,
        "descriptor": "my transaction",
        "account_name": "custom_account_name",          # source is the linked bank account
        "destination_id": "<destination_v_id>",         # virtual_account_id of virtual account     
        "business_uuid": "<your business UUID>",
        "processing_type": "STANDARD_ACH"       
      }

Transaction.issue_sila(app, payload, eth_private_key)

# Success
{
   "success":true,
   "message":"Transaction submitted to processing queue.",
   "reference":"046dcffd-a46a-4da9-b6dc-8057e36cbf5f",
   "transaction_id":"d6cb3adc-e14b-4c3b-ba2c-128df94f252a",
   "descriptor":"my transaction",
   "warning":"None",
   "status":"SUCCESS",
   "response_time_ms":"306",
   "status_code":200,
}
AccountTransactionMessage issueMsg = AccountTransactionMessage.builder()
      .userHandle("user_handle")
      .userPrivateKey("user_private_key")
      .amount(100)
      .accountName("your_account_name")  //  linked bank account name
      .descriptor("your custom descriptor") // Optional
      .businessUuid("some-business-uuid") // Optional
      .processingType(ProcessingTypeEnum.STANDARD) // Optional
      .destinationId("destination account id") // virtual_account_id of virtual account
      .build();
ApiResponse response = api.issueSila(issueMsg);

// Success response
System.out.println(response.getStatusCode()); // 200

TransactionResponse parsedResponse = (TransactionResponse) response.getData();
System.out.println(parsedResponse.getSuccess());
System.out.println(parsedResponse.getReference()); // Random reference number
System.out.println(parsedResponse.getStatus()); // SUCCESS
System.out.println(parsedResponse.getMessage()); // Transaction submitted to processing queue.
System.out.println(parsedResponse.getTransactionId()); // Transaction id
System.out.println(parsedResponse.getDescriptor()); // The transaction descriptor (if was set)
$userHandle = "user.silamoney.eth";
$amount = 2000;
$accountName = "your_account_name";
$userPrivateKey = "0x...";
$descriptor = "optional transaction descriptor"; // Optional.
$businessUuid = "some-business-uuid"; // Optional.
$processingType = AchType::STANDARD(); // Optional - Default is STANDARD
$cardName = null; // Optional
$sourceId = null; // virtual_account_id of virtual account
$destinationId = "destination account id"; // blockchain_address_id of walle

//Request
$response = $client->issueSila($userHandle, $amount, $accountName, $userPrivateKey, $descriptor, $businessUuid, $processingType, $cardName, $sourceId, $destinationId);

//Response - Success 200
echo $response->getStatusCode(); // 200
echo $response->getData()->getReference(); // Random reference number
echo $response->getData()->getStatus(); // SUCCESS
echo $response->getData()->getMessage(); // Transaction submitted to processing queue.
echo $response->getData()->getDescriptor(); // Transaction Descriptor.
echo $response->getData()->getTransactionId(); // The transaction id
string userHandle = "your-user-handle";
string userPrivateKey = "0x...";
int amount = 2000;
string descriptor = "optional transaction descriptor"; // optional
string accountName = "your_account_nickname"; // source is the linked bank account
string destinationId = "d8bcfb75-b521-4230-b433-e453f43f668b"; // virtual_account_id of virtual account
string businessUuid = "UUID of a business with an approved ACH name"; // your business UUID
ProcessingType processingType = ProcessingType.Standard;

ApiResponse<object> response = api.IssueSila(userHandle, amount, userPrivateKey, accountName, descriptor, businessUuid, processingType, destinationId);

// Success Object Response

Console.WriteLine(response.StatusCode); // 200
Console.WriteLine(((TransactionResponse)response.Data).Reference); // Random reference number
Console.WriteLine(((TransactionResponse)response.Data).Status); // SUCCESS
Console.WriteLine(((TransactionResponse)response.Data).Message); // Transaction submitted to processing queue.
Console.WriteLine(((TransactionResponse)response.Data).Descriptor); // optional transaction descriptor
Console.WriteLine(((TransactionResponse)response.Data).TransactionId); // UUID of the submitted transaction

Redeem Sila

https://docs.silamoney.com/docs/redeem_sila

To redeem funds from a virtual account to a linked bank account, call /redeem_sila, providing the source_id of the virtual account as the source, and the account_name of the linked bank account as the destination. Please note, descriptor is an optional parameter, and the use of a descriptor will incur an additional fee per transaction.

Sample request - virtual account to linked bank account

POST /0.2/redeem_sila HTTP/1.1
{
  "header": {
    "created": 1234567890, 
    "app_handle": "handle.silamoney.eth", 
    "user_handle":"sally_handle", 
    "version": "0.2", 
    "reference": "ref"
  }, 
  "amount": 2000,
  "source_id": "d8bcfb75-b521-4230-b433-e453f43f668b", -- virtual_account_id of virtual account
  "account_name": "My Chase", -- destination is the linked bank account
  "descriptor": "my transaction",
  "business_uuid": "<your business UUID>",
  "processing_type": "STANDARD_ACH"
}
let userHandle = "<user Handle>";
let walletPrivateKey = "<user Wallet Private key>";
let amount = 200;
let accountName = "My Chase", //source is the linked bank account
let descriptor = "descriptor text" // optional
let businessUuid = "<your business UUID>"
let processingType = "STANDARD_ACH";
let cardName = "your card name" //Used in card transactions or NULL
let sourceId = "d8bcfb75-b521-4230-b433-e453f43f668b", //virtual_account_id of virtual account
let destinationId = "<linked bank account id>", //source is the linked bank account

// Also can used only one field : accountName or destinationId

const res = await Sila.redeemSila(amount, userHandle, walletPrivateKey,accountName,descriptor,businessUuid,processingType,cardName,sourceId,destinationId);
payload = {
        "user_handle": user_handle,
        "amount": 2000,
        "descriptor": "my transaction",
        "account_name": "Custom Account Name",
        "source_id": "<source_id>",                         # virtual_account_id of virtual account
        "business_uuid": "<your business UUID>",            # destination is the linked bank account
        "processing_type": "STANDARD_ACH"       
      }
      
Transaction.redeemSila(app, payload, eth_private_key)     

# Success

{
   "success":true,
   "message":"Transaction submitted to processing queue.",
   "reference":"874c928f-b959-42c6-b4ce-67ed6fd61fc9",
   "transaction_id":"51dd8c9c-9f76-477c-b19f-38aa10b46b8d",
   "descriptor":"my transaction",
   "status":"SUCCESS",
   "response_time_ms":"640",
   "status_code":200,
}
AccountTransactionMessage redeemMsg = AccountTransactionMessage.builder()
    .userHandle("user_handle")
    .userPrivateKey("user_private_key")
    .amount(100)
    .descriptor("your custom descriptor") // Optional
    .businessUuid("some-business-uuid") // Optional
    .processingType(ProcessingTypeEnum.STANDARD) // Optional
    .sourceId("source account id") // virtual_account_id of virtual account
    .accountName("your_account_name") // destination is the linked bank account name
    .build();
ApiResponse response = api.RedeemSila(redeemMsg);

// Success response
System.out.println(response.getStatusCode()); // 200

TransactionResponse parsedResponse = (TransactionResponse) response.getData();
System.out.println(parsedResponse.getReference()); // Random reference number
System.out.println(parsedResponse.getSuccess()); // true
System.out.println(parsedResponse.getStatus()); // SUCCESS
System.out.println(parsedResponse.getMessage()); // Transaction submitted to processing queue.
System.out.println(parsedResponse.getTransactionId()); // Transaction id
System.out.println(parsedResponse.getDescriptor()); // The transaction descriptor (if was set)
$userHandle = "your-user-handle";
$userPrivateKey = "0x...";
$amount = 2000;
$accountName = "your_account_nickname"; // destination is the linked bank account
$descriptor = "optional transaction descriptor"; // optional
$businessUuid = "UUID of a business with an approved ACH name"; // your business UUID
$processingType = AchType::STANDARD(); // Optional - Default is STANDARD
$cardName = null; // Optional
$sourceId = "virtual account ID";  // virtual_account_id of the source virtual account

$response = self::$config->api->redeemSila($userHandle, $amount, $accountName, $userPrivateKey, $descriptor, $businessUuid, $processingType, $cardName, $sourceId);

//Response - Success 200
echo $response->getStatusCode(); // 200
echo $response->getData()->getReference(); // Random reference number
echo $response->getData()->getStatus(); // SUCCESS
echo $response->getData()->getMessage(); // Transaction submitted to processing queue.
echo $response->getData()->getDescriptor(); // Transaction Descriptor.
echo $response->getData()->getTransactionId(); // The transaction id.
string userHandle = "your-user-handle";
string userPrivateKey = "0x...";
int amount = 2000;
string sourceId = "UUID of virtual account - represents the source - NEW!";  // virtual_account_id of virtual account
string accountName = "your_account_nickname"; // destination is the linked bank account
string descriptor = "optional transaction descriptor"; // optional
string businessUuid = "UUID of a business with an approved ACH name"; // your business UUID
ProcessingType processingType = ProcessingType.Standard;

ApiResponse<object> response = api.RedeemSila(userHandle, amount, userPrivateKey, accountName, descriptor, businessUuid, processingType, sourceId);

// Success Object Response

Console.WriteLine(response.StatusCode); // 200
Console.WriteLine(((TransactionResponse)response.Data).Reference); // Random reference number
Console.WriteLine(((TransactionResponse)response.Data).Status); // SUCCESS
Console.WriteLine(((TransactionResponse)response.Data).Message); // Transaction submitted to processing queue.
Console.WriteLine(((TransactionResponse)response.Data).Descriptor); // Transaction descriptor.
Console.WriteLine(((TransactionResponse)response.Data).TransactionId); // Transaction id.
Console.WriteLine(((TransactionResponse)response.Data).Success); // Success.

Transfer Sila

https://docs.silamoney.com/docs/transfer_sila

To transfer funds to a virtual account from a wallet, call /transfer_sila, providing the source_id of the wallet as the source, and the destination_id as the virtual_account_id . The source_id of the wallet will be the blockchain_address_id of the wallet, which can be viewed using the /get_payment_methods API. You can also transfer funds to a virtual account from another virtual account, or transfer funds from a wallet to a virtual account.

Sample request - wallet to virtual account

POST /0.2/transfer_sila HTTP/1.1
{
  "header": {
    "created": 1234567890, 
    "app_handle": "handle.silamoney.eth", 
    "user_handle":"user.silamoney.eth", 
    "version": "0.2", 
    "reference": "ref"
  }, 
  "amount": 2000,
  "descriptor": "my transaction",
  "source_id": "6c18a1a5-70c1-4872-9cf2-559b59708d3e", -- blockchain_address_id of wallet --
  "destination_id": "d8bcfb75-b521-4230-b433-e453f43f668b", -- virtual_account_id of virtual account
  "destination_handle": "user.silamoney.eth" -- user handle of the destination
}
let userHandle = "<user Handle>";
let walletPrivateKey = "<user Wallet Private key>";
let amount = 200;
let descriptor = "descriptor text" // optional
let businessUuid = "<your business UUID>"
let destinationHandle = "user.silamoney.eth" //user handle of the destination
let sourceId = "6c18a1a5-70c1-4872-9cf2-559b59708d3e", //blockchain_address_id of wallet
let destinationId = "d8bcfb75-b521-4230-b433-e453f43f668b", //virtual_account_id of virtual account
let walletNickname = ''; // NULL
let walletAddress = ''; // NULL

const res = await Sila.transferSila(amount, userHandle, walletPrivateKey,destinationHandle,walletNickname,walletAddress,descriptor,businessUuid,sourceId,destinationId);
payload = {
        "user_handle": user_handle,
         "amount": 2000,
        "descriptor": "my transaction",
        "account_name": "Custom Account Name",
        "source_id": "<blockchain ID>",                 # blockchain_address_id of wallet
        "destination_id": "<destination_v_id>",         # virtual_account_id of virtual account
        "destination_handle": "user_handle"             # user handle of the destination
      }
      
Transaction.transferSila(app, payload, eth_private_key)  

# Success

{
   "success":true,
   "message":"Transaction submitted to processing queue.",
   "reference":"bc12bcd9-0f8c-4b3b-a2fa-a799a2290ca1",
   "transaction_id":"32b4e034-82fa-4ef6-b7dc-890ec7678f34",
   "source_id":"b284dcf9-ab0f-401f-a39b-77aee69c61fb",              
   "destination_id":"dc7f63c6-f10e-4e0f-8b4b-8d4b00468fe0",         
   "descriptor":"test descriptor",
   "status":"SUCCESS",
   "response_time_ms":"531",
   "status_code":200,
}
String destinationHandle="user.silamoney.eth"; // user handle of the destination
String sourceId="6c18a1a5-70c1-4872-9cf2-559b59708d3e"; // blockchain_address_id of wallet
String destinationId="d8bcfb75-b521-4230-b433-e453f43f668b"; // virtual_account_id of virtual account

String destinationAddress="0x1234567890abcdef1234567890abcdef12345678"; // Optional
String descriptor ="your custom descriptor" // Optional
String businessUuid = "some-business-uuid"; // Optional


ApiResponse response = api.transferSila(userHandle, amount, destinationHandle,destinationAddress, descriptor, businessUuid, userPrivateKey, sourceId, destinationId);
TransferSilaResponse parsedResponse = (TransferSilaResponse) response.getData();

// Success Object Response
System.out.println(response.getStatusCode()); // 200
System.out.println(parsedResponse.getReference()); // Random reference number
System.out.println(parsedResponse.getSuccess());
System.out.println(parsedResponse.getStatus()); // SUCCESS
System.out.println(parsedResponse.getMessage()); // Transaction submitted to processing queue.
System.out.println(parsedResponse.getDescriptor()); // Descriptor added in request.queue.
System.out.println(parsedResponse.getTransactionId());
System.out.println(parsedResponse.getDestinationAddress());
$userHandle = "your-user-handle";
$destinationHandle = "user.silamoney.eth"; // user handle of the destination
$amount = 2000;    
$userPrivateKey = "0x...";
$destinationAddress = "0x1234567890abcdef1234567890abcdef12345678"; // Optional
$destinationWalletName = null;// Optional
$descriptor = "your custom descriptor" // Optional
$businessUuid = "some-business-uuid"; // Optional
$sourceId = "6c18a1a5-70c1-4872-9cf2-559b59708d3e"; // blockchain_address_id of wallet
$destinationId = "virtual_account_id of virtual account"; // virtual_account_id of virtual account

$response = self::$config->api->transferSila($userHandle, $destinationHandle, $amount, $userPrivateKey, $destinationAddress, $destinationWalletName, $descriptor, $businessUuid, $sourceId, $destinationId);

//Response - Success 200
echo $response->getStatusCode(): // 200
echo $response->getData()->getReference(); // Random reference number
echo $response->getData()->getStatus(); // SUCCESS
echo $response->getData()->getMessage(); // Transaction submitted to processing queue.
echo $response->getData()->getDescriptor(); // Transaction Descriptor.
echo $response->getData()->getTransactionId(); // The transaction id.
echo $response->getData()->getDestinationAddress(); // The destination wallet address.
string userHandle = "user.silamoney.eth";
string userPrivateKey = "0x...";
int amount = 2000;
string descriptor = "optional transaction descriptor"; // Optional.
string sourceId = "6c18a1a5-70c1-4872-9cf2-559b59708d3e", // blockchain_address_id of wallet
string destinationId = "d8bcfb75-b521-4230-b433-e453f43f668b", // virtual_account_id of virtual account
string destinationHandle = "user2.silamoney.eth";

ApiResponse<object> response = api.TransferSila(userHandle, amount, destinationHandle, userPrivateKey, descriptor, sourceId, destinationId);

// Success Object Response

Console.WriteLine(response.StatusCode); // 200
Console.WriteLine(((TransferResponse)response.Data).Success); // Success.
Console.WriteLine(((TransferResponse)response.Data).Reference); // Random reference number
Console.WriteLine(((TransferResponse)response.Data).Status); // SUCCESS
Console.WriteLine(((TransferResponse)response.Data).Message); // Transaction submitted to processing queue.
Console.WriteLine(((TransferResponse)response.Data).Descriptor); // transaction descriptor
Console.WriteLine(((TransferResponse)response.Data).TransactionId); // UUID of the submitted transaction
Console.WriteLine(((TransferResponse)response.Data).DestinationAddress); // Destination Address

Sample request - virtual account to virtual account

POST /0.2/transfer_sila HTTP/1.1
{
  "header": {
    "created": 1234567890, 
    "app_handle": "handle.silamoney.eth", 
    "user_handle":"user.silamoney.eth", 
    "version": "0.2", 
    "reference": "ref"
  }, 
  "amount": 2000,
  "descriptor": "my transaction",
  "source_id": "6c18a1a5-70c1-4872-9cf2-559b59708d3e", -- virtual_account_id of virtual account 1
  "destination_id": "d8bcfb75-b521-4230-b433-e453f43f668b", -- virtual_account_id of virtual account 2
  "destination_handle": "user.silamoney.eth" -- user handle of the destination
}
let userHandle = "<user Handle>";
let walletPrivateKey = "<user Wallet Private key>";
let amount = 200;
let descriptor = "descriptor text" // optional
let businessUuid = "<your business UUID>"
let destinationHandle = "user.silamoney.eth" //user handle of the destination
let sourceId = "6c18a1a5-70c1-4872-9cf2-559b59708d3e", //virtual_account_id of virtual account 1
let destinationId = "d8bcfb75-b521-4230-b433-e453f43f668b", //virtual_account_id of virtual account 2
let walletNickname = ''; // NULL
let walletAddress = ''; // NULL

const res = await Sila.transferSila(amount, userHandle, walletPrivateKey,destinationHandle,walletNickname,walletAddress,descriptor,businessUuid,sourceId,destinationId);
payload = {

            "user_handle": "user_handle",
            "source_id": "<source_v_id>",                   # virtual_account_id of virtual account 1
            "destination_id": "<destination_v_id>",         # virtual_account_id of virtual account 2
            "destination_handle": "user_handle",            # user handle of the destination
            "amount": 100            
        }
 
 Transaction.transferSila(app, payload, eth_private_key)
 
 # Success

{
   "success":true,
   "message":"Transaction submitted to processing queue.",
   "reference":"35e369b7-aef3-4077-b4ef-9b7d783c8a94",
   "transaction_id":"a9401463-ff2b-4cd7-8cbe-1f4cdbeaa585",
   "source_id":"3b4a89f7-ec98-40c4-b476-9b0de3a8a033",
   "destination_id":"70ada6d6-f1cb-4771-bfa2-626225dd6201",
   "descriptor":"test descriptor",
   "status":"SUCCESS",
   "response_time_ms":"624",
   "status_code":200,
}
String destinationHandle="user.silamoney.eth"; // user handle of the destination
String sourceId="6c18a1a5-70c1-4872-9cf2-559b59708d3e"; // virtual_account_id of virtual account 1
String destinationId="d8bcfb75-b521-4230-b433-e453f43f668b"; // virtual_account_id of virtual account 2

String destinationAddress="0x1234567890abcdef1234567890abcdef12345678"; // Optional
String descriptor ="your custom descriptor" // Optional
String businessUuid = "some-business-uuid"; // Optional

ApiResponse response = api.transferSila(userHandle, amount, destinationHandle,destinationAddress, descriptor, businessUuid, userPrivateKey, sourceId, destinationId);
TransferSilaResponse parsedResponse = (TransferSilaResponse) response.getData();

// Success Object Response
System.out.println(response.getStatusCode()); // 200
System.out.println(parsedResponse.getReference()); // Random reference number
System.out.println(parsedResponse.getSuccess());
System.out.println(parsedResponse.getStatus()); // SUCCESS
System.out.println(parsedResponse.getMessage()); // Transaction submitted to processing queue.
System.out.println(parsedResponse.getDescriptor()); // Descriptor added in request.queue.
System.out.println(parsedResponse.getTransactionId());
System.out.println(parsedResponse.getDestinationAddress());
$userHandle = "your-user-handle";
$destinationHandle = "user.silamoney.eth"; // user handle of the destination
$amount = 2000;    
$userPrivateKey = "0x...";
$destinationAddress = null; // Optional
$destinationWalletName = null;// Optional
$descriptor = "your custom descriptor" // Optional
$businessUuid = "some-business-uuid"; // Optional
$sourceId = "source virtual_account_id "; // virtual_account_id of source virtual account
$destinationId = "destination virtual_account_id"; // virtual_account_id of destination virtual account

$response = self::$config->api->transferSila($userHandle, $destinationHandle, $amount, $userPrivateKey, $destinationAddress, $destinationWalletName, $descriptor, $businessUuid, $sourceId, $destinationId);

//Response - Success 200
echo $response->getStatusCode(): // 200
echo $response->getData()->getReference(); // Random reference number
echo $response->getData()->getStatus(); // SUCCESS
echo $response->getData()->getMessage(); // Transaction submitted to processing queue.
echo $response->getData()->getDescriptor(); // Transaction Descriptor.
echo $response->getData()->getTransactionId(); // The transaction id.
echo $response->getData()->getDestinationAddress(); // The destination wallet address.
string userHandle = "user.silamoney.eth";
string userPrivateKey = "0x...";
int amount = 2000;
string descriptor = "optional transaction descriptor"; // Optional.
string sourceId = "6c18a1a5-70c1-4872-9cf2-559b59708d3e", // virtual_account_id of virtual account 1
string destinationId = "d8bcfb75-b521-4230-b433-e453f43f668b", // virtual_account_id of virtual account 2
string destinationHandle = "user2.silamoney.eth";

ApiResponse<object> response = api.TransferSila(userHandle, amount, destinationHandle, userPrivateKey, descriptor, sourceId, destinationId);

// Success Object Response

Console.WriteLine(response.StatusCode); // 200
Console.WriteLine(((TransferResponse)response.Data).Success); // Success.
Console.WriteLine(((TransferResponse)response.Data).Reference); // Random reference number
Console.WriteLine(((TransferResponse)response.Data).Status); // SUCCESS
Console.WriteLine(((TransferResponse)response.Data).Message); // Transaction submitted to processing queue.
Console.WriteLine(((TransferResponse)response.Data).Descriptor); // transaction descriptor
Console.WriteLine(((TransferResponse)response.Data).TransactionId); // UUID of the submitted transaction
Console.WriteLine(((TransferResponse)response.Data).DestinationAddress); // Destination Address

Sample request - virtual account to wallet

POST /0.2/transfer_sila HTTP/1.1
{
  "header": {
    "created": 1234567890, 
    "app_handle": "handle.silamoney.eth", 
    "user_handle":"user.silamoney.eth", 
    "version": "0.2", 
    "reference": "ref"
  }, 
  "amount": 2000,
  "descriptor": "my transaction",
  "source_id": "d8bcfb75-b521-4230-b433-e453f43f668b", -- virtual_account_id of virtual account
  "destination_id": "6c18a1a5-70c1-4872-9cf2-559b59708d3e", -- blockchain_address_id of wallet
  "destination_handle": "user.silamoney.eth" -- user handle of the destination
}
let userHandle = "<user Handle>";
let walletPrivateKey = "<user Wallet Private key>";
let amount = 200;
let descriptor = "descriptor text" // optional
let businessUuid = "<your business UUID>"
let destinationHandle = "user.silamoney.eth" //user handle of the destination
let sourceId = "6c18a1a5-70c1-4872-9cf2-559b59708d3e", //virtual_account_id of virtual account
let destinationId = "d8bcfb75-b521-4230-b433-e453f43f668b", //blockchain_address_id of wallet
let walletNickname = ''; // NULL
let walletAddress = ''; // NULL

const res = await Sila.transferSila(amount, userHandle, walletPrivateKey,destinationHandle,walletNickname,walletAddress,descriptor,businessUuid,sourceId,destinationId);
payload = {
          "user_handle": "user_handle",
          "amount": 2000,
          "descriptor": "my transaction",
          "source_id": "<source_v_id>",                 # virtual_account_id of virtual account
          "destination_id": "<Blockchain id>",          # blockchain_address_id of wallet
          "destination_handle": "user_handle"           # user handle of the destination
        }
        
Transaction.transferSila(app, payload, eth_private_key)

# Success   
{
   "success":true,
   "message":"Transaction submitted to processing queue.",
   "reference":"bc12bcd9-0f8c-4b3b-a2fa-a799a2290ca1",
   "transaction_id":"32b4e034-82fa-4ef6-b7dc-890ec7678f34",
   "source_id":"b284dcf9-ab0f-401f-a39b-77aee69c61fb",
   "destination_id":"dc7f63c6-f10e-4e0f-8b4b-8d4b00468fe0",
   "descriptor":"test descriptor",
   "status":"SUCCESS",
   "response_time_ms":"531",
   "status_code":200,
}
String destinationHandle="user.silamoney.eth"; // user handle of the destination
String sourceId="6c18a1a5-70c1-4872-9cf2-559b59708d3e"; // virtual_account_id of virtual account 
String destinationId="d8bcfb75-b521-4230-b433-e453f43f668b"; // blockchain_address_id of wallet

String destinationAddress="0x1234567890abcdef1234567890abcdef12345678"; // Optional
String descriptor ="your custom descriptor" // Optional
String businessUuid = "some-business-uuid"; // Optional

ApiResponse response = api.transferSila(userHandle, amount, destinationHandle,destinationAddress, descriptor, businessUuid, userPrivateKey, sourceId, destinationId);
TransferSilaResponse parsedResponse = (TransferSilaResponse) response.getData();

// Success Object Response
System.out.println(response.getStatusCode()); // 200
System.out.println(parsedResponse.getReference()); // Random reference number
System.out.println(parsedResponse.getSuccess());
System.out.println(parsedResponse.getStatus()); // SUCCESS
System.out.println(parsedResponse.getMessage()); // Transaction submitted to processing queue.
System.out.println(parsedResponse.getDescriptor()); // Descriptor added in request.queue.
System.out.println(parsedResponse.getTransactionId());
System.out.println(parsedResponse.getDestinationAddress());
$userHandle = "your-user-handle";
$destinationHandle = "user.silamoney.eth"; // user handle of the destination
$amount = 2000;    
$userPrivateKey = "0x...";
$destinationAddress = null; // Optional
$destinationWalletName = null;// Optional
$descriptor = "your custom descriptor" // Optional
$businessUuid = "some-business-uuid"; // Optional
$sourceId = "source virtual_account_id "; // virtual_account_id of source virtual account
$destinationId = "wallet_id"; // blockchain_address_id of the destination wallet

$response = self::$config->api->transferSila($userHandle, $destinationHandle, $amount, $userPrivateKey, $destinationAddress, $destinationWalletName, $descriptor, $businessUuid, $sourceId, $destinationId);

//Response - Success 200
echo $response->getStatusCode(): // 200
echo $response->getData()->getReference(); // Random reference number
echo $response->getData()->getStatus(); // SUCCESS
echo $response->getData()->getMessage(); // Transaction submitted to processing queue.
echo $response->getData()->getDescriptor(); // Transaction Descriptor.
echo $response->getData()->getTransactionId(); // The transaction id.
echo $response->getData()->getDestinationAddress(); // The destination wallet address.
string userHandle = "user.silamoney.eth";
string userPrivateKey = "0x...";
int amount = 2000;
string descriptor = "optional transaction descriptor"; // Optional.
string sourceId = "d8bcfb75-b521-4230-b433-e453f43f668b"; // virtual_account_id of virtual account
string destinationId = "6c18a1a5-70c1-4872-9cf2-559b59708d3e"; // blockchain_address_id of walle
string destinationHandle = "user2.silamoney.eth";

ApiResponse<object> response = api.TransferSila(userHandle, amount, destinationHandle, userPrivateKey, descriptor, sourceId, destinationId);

// Success Object Response

Console.WriteLine(response.StatusCode); // 200
Console.WriteLine(((TransferResponse)response.Data).Success); // Success.
Console.WriteLine(((TransferResponse)response.Data).Reference); // Random reference number
Console.WriteLine(((TransferResponse)response.Data).Status); // SUCCESS
Console.WriteLine(((TransferResponse)response.Data).Message); // Transaction submitted to processing queue.
Console.WriteLine(((TransferResponse)response.Data).Descriptor); // transaction descriptor
Console.WriteLine(((TransferResponse)response.Data).TransactionId); // UUID of the submitted transaction
Console.WriteLine(((TransferResponse)response.Data).DestinationAddress); // Destination Address

Did this page help you?