Set Up Fiat Reserve - Go Network Transfer

Transfer fiat between Go Accounts on the Go Network to fund your fiat reserve. See the Guide.

  1. Build a transaction from the source Go Account to the destination Go Account. Pass the destination Go Account wallet ID as the value of the address field in the recipient object.

    API Reference

  2. Use your Go Account passphrase to authenticate the transaction. To ensure your passphrase isn't passed over the Internet, you must use BitGo Express in external-signing mode or the JavaScript SDK.

  3. Using the payload and the signature from the prior step, send the half-signed transaction to BitGo.

    API Reference

  4. If you configure an approval requirement for transfers, you can't approve your own transactions — another admin must approve them.

    API Reference

// 1. Build Transaction
export COIN="<CRYPTO_ASSET_ID>" # Asset IDs in Go Accounts start with 'ofc' (e.g. ofctusd)
export WALLET_ID="<SOURCE_GO_ACCOUNT_WALLET_ID>"
export SERVICE_USER_TOKEN="<SERVICE_USER_ACCESS_TOKEN>"
export AMOUNT="<AMOUNT_IN_BASE_UNITS>" # Must be $25,000 or more
export DESTINATION_WALLET_ID="<DESTINATION_GO_ACCOUNT_WALLET_ID>"

curl -X POST \
  https://app.bitgo-test.com/api/v2/$COIN/wallet/$WALLET_ID/tx/build \
  -H 'Content-Type: application/json' \
  -H "Authorization: Bearer $SERVICE_USER_TOKEN" \
  -d '{
    "recipients": [
      {
        "amount": "'"$AMOUNT"'",
        "address": "'"$DESTINATION_WALLET_ID"'"
      }
    ]
}'
// 2. Authenticate Transaction
export BITGO_EXPRESS_HOST="<YOUR_LOCAL_HOST>"
export SERVICE_USER_TOKEN="<SERVICE_USER_ACCESS_TOKEN>"
export WALLET_ID="<SOURCE_GO_ACCOUNT_WALLET_ID>"
export WALLET_PASSPHRASE="<YOUR_GO_ACCOUNT_PASSPHRASE>"

curl -X POST \
  http://$BITGO_EXPRESS_HOST/api/v2/ofc/signPayload \
  -H 'Content-Type: application/json' \
  -H "Authorization: Bearer $SERVICE_USER_TOKEN" \
  -d '{
   "walletId": "'"$WALLET_ID"'",
   "walletPassphrase": "'"$WALLET_PASSPHRASE"'",
   "payload": "{\"coin\":\"ofctusd\",\"recipients\":[{\"address\":\"2NDBpypweakRZzgbWqxEK42pnxgfYzd5iuY\",\"amount\":\"250000000\"}],\"fromAccount\":\"63ff43c474598902272894f328452ad7\",\"nonce\":\"80bc93b5-eeec-4c11-afca-f6dae4bba2f2\",\"timestamp\":\"2023-09-28T10:55:39.135Z\",\"feeString\":\"0\",\"shortCircuitBlockchainTransfer\":true,\"isIntraJXTransfer\":true}"
}'
// 3. Send Transaction
export COIN="<FIAT_CURRENCY_ASSET_ID>"
export WALLET_ID="<SOURCE_GO_ACCOUNT_WALLET_ID>"
export SERVICE_USER_TOKEN="<SERVICE_USER_ACCESS_TOKEN>"
export PAYLOAD="<PAYLOAD_FROM_STEP_2>"
export SIGNATURE="<SIGNATURE_FROM_STEP_2>"

curl -X POST \
  https://app.bitgo-test.com/api/v2/$COIN/wallet/$WALLET_ID/tx/send \
  -H 'Content-Type: application/json' \
  -H "Authorization: Bearer $SERVICE_USER_TOKEN" \
  -d '{
    "halfSigned": {
      "payload": "'"$PAYLOAD"'",
      "signature": "'"$SIGNATURE"'"
    }
  }'
// 4. Approve Transaction (Optional)
export APPROVAL_ID="<APPROVAL_ID>"
export SERVICE_USER_TOKEN="<SERVICE_USER_ACCESS_TOKEN>"
export OTP="<OTP>"

curl -X PUT \
  https://app.bitgo-test.com/api/v2/pendingApprovals/$APPROVAL_ID \
  -H 'Content-Type: application/json' \
  -H "Authorization: Bearer $SERVICE_USER_TOKEN" \
  -d '{
    "state": "approved",
    "otp": "'"$OTP"'"
}'
Response
// 1. Build Transaction Response
{
  "payload": "{\"coin\":\"ofctusd\",\"recipients\":[{\"address\":\"2NDBpypweakRZzgbWqxEK42pnxgfYzd5iuY\",\"amount\":\"250000000\"}],\"fromAccount\":\"63ff43c474598902272894f328452ad7\",\"nonce\":\"80bc93b5-eeec-4c11-afca-f6dae4bba2f2\",\"timestamp\":\"2023-09-28T10:55:39.135Z\",\"feeString\":\"0\",\"shortCircuitBlockchainTransfer\":true,\"isIntraJXTransfer\":true}",
  "feeInfo": { "feeString": "0" },
  "coin": "ofc",
  "token": "ofctusd"
}

// 2. Authenticate Transaction Response
{
  "payload": "{\"coin\":\"ofctusd\",\"recipients\":[{\"address\":\"2NDBpypweakRZzgbWqxEK42pnxgfYzd5iuY\",\"amount\":\"250000000\"}],\"fromAccount\":\"63ff43c474598902272894f328452ad7\",\"nonce\":\"80bc93b5-eeec-4c11-afca-f6dae4bba2f2\",\"timestamp\":\"2023-09-28T10:55:39.135Z\",\"feeString\":\"0\",\"shortCircuitBlockchainTransfer\":true,\"isIntraJXTransfer\":true}",
  "signature": "1f989926e3fc8ed0138bd0e188e90e2c5321ef86734896886c004005740a005dfd2008142dbc48aee68d1f576c4a9ac558e5b7b4acbd5aa765710ea636aca9d032"
}

// 3. Send Transaction Response
{
  "transfer": {
    "id": "65155c4a72fddb000774edbee5fa75fd",
    "coin": "ofctusd",
    "wallet": "63ff43c474598902272894f328452ad7",
    "walletType": "trading",
    "enterprise": "63f31592e277e50837712300495902c7",
    "txid": "ddd6875812fa59f899a68059ff303bfa6d39fc350ee687c407383d0444b43d2b",
    "height": 999999999,
    "heightId": "999999999-65155c4a72fddb000774edbe",
    "date": "2023-09-28T10:58:18.272Z",
    "type": "send",
    "value": -250000000,
    "valueString": "-250000000",
    "baseValue": -250000000,
    "baseValueString": "-250000000",
    "feeString": "0",
    "payGoFee": 0,
    "payGoFeeString": "0",
    "state": "signed",
    "instant": false,
    "isReward": false,
    "isFee": false,
    "tags": [
      "63ff43c474598902272894f328452ad7",
      "63f31592e277e50837712300495902c7"
    ],
    "history": [
      {
        "date": "2023-09-28T10:58:18.340Z",
        "action": "signed"
      },
      {
        "date": "2023-09-28T10:58:18.272Z",
        "user": "628ca09d1b78a6022750254f0777561a",
        "action": "created"
      }
    ],
    "signedDate": "2023-09-28T10:58:18.340Z",
    "entries": [
      {
        "address": "63ff43c474598902272894f328452ad7",
        "wallet": "63ff43c474598902272894f328452ad7",
        "value": -250000000,
        "valueString": "-250000000"
      },
      {
        "address": "2NDBpypweakRZzgbWqxEK42pnxgfYzd5iuY",
        "value": 250000000,
        "valueString": "250000000"
      }
    ],
    "signedTime": "2023-09-28T10:58:18.340Z",
    "createdTime": "2023-09-28T10:58:18.272Z"
  },
  "txid": "ddd6875812fa59f899a68059ff303bfa6d39fc350ee687c407383d0444b43d2b",
  "tx": {
    "transaction": {
      "coin": "ofctusd",
      "recipients": [
        {
          "address": "2NDBpypweakRZzgbWqxEK42pnxgfYzd5iuY",
          "amount": "250000000"
        }
      ],
      "fromAccount": "63ff43c474598902272894f328452ad7",
      "nonce": "80bc93b5-eeec-4c11-afca-f6dae4bba2f2",
      "timestamp": "2023-09-28T10:55:39.135Z",
      "idfSignedTimestamp": "2023-09-28T10:55:38.732Z",
      "idfVersion": 1,
      "idfUserId": "628ca09d1b78a6022750254f0777561a",
      "feeString": "0",
      "shortCircuitBlockchainTransfer": true,
      "isIntraJXTransfer": true
    },
    "signature": "1f989926e3fc8ed0138bd0e188e90e2c5321ef86734896886c004005740a005dfd2008142dbc48aee68d1f576c4a9ac558e5b7b4acbd5aa765710ea636aca9d032",
    "transactionType": "BOOK_TRANSFER"
  },
  "status": "signed"
}

// 4. Approve Transaction (Optional) Response
{
  "id": "65155c4a72fddb000774edbee5fa75fd",
  "coin": "ofctusd",
  "wallet": "63ff43c474598902272894f328452ad7",
  "enterprise": "63f31592e277e50837712300495902c7",
  "creator": "628ca09d1b78a6022750254f0777561a",
  "createDate": "2023-09-28T10:58:18.272Z",
  "info": {
    "type": "transactionRequest",
    "transactionRequest": {
      "coinSpecific": {
        "ofctusd": {
          "payload": {
            "coin": "ofctusd",
            "recipients": [
              {
                "address": "2NDBpypweakRZzgbWqxEK42pnxgfYzd5iuY",
                "amount": "250000000"
              }
            ],
            "fromAccount": "63ff43c474598902272894f328452ad7",
            "nonce": "80bc93b5-eeec-4c11-afca-f6dae4bba2f2",
            "timestamp": "2023-09-28T10:55:39.135Z",
            "idfSignedTimestamp": "2023-09-28T10:55:38.732Z",
            "idfVersion": 1,
            "idfUserId": "628ca09d1b78a6022750254f0777561a",
            "feeString": "0",
            "shortCircuitBlockchainTransfer": true,
            "isIntraJXTransfer": true
          },
          "signature": "1f989926e3fc8ed0138bd0e188e90e2c5321ef86734896886c004005740a005dfd2008142dbc48aee68d1f576c4a9ac558e5b7b4acbd5aa765710ea636aca9d032",
          "transactionType": "BOOK_TRANSFER"
        }
      },
      "verificationItems": ["2NDBpypweakRZzgbWqxEK42pnxgfYzd5iuY"],
      "videoApprovers": [],
      "requestedAmount": "250000000",
      "fee": 0,
      "sourceWallet": "63ff43c474598902272894f328452ad7",
      "recipients": [
        {
          "_id": "65155c4a68fddb000865edbf",
          "address": "2NDBpypweakRZzgbWqxEK42pnxgfYzd5iuY",
          "amount": "250000000"
        }
      ]
    }
  },
  "state": "approved",
  "scope": "wallet",
  "userIds": [
    "628ca09d1b78a6022750254f0777561a",
    "5bd8bdb0925d7c9823d4fc823e9e2fd3"
  ],
  "approvalsRequired": 1,
  "resolvers": [
    {
      "user": "5bd8bdb0925d7c9823d4fc823e9e2fd3",
      "date": "2023-09-28T11:15:24.644Z",
      "resolutionType": "pending"
    }
  ]
}