Skip to main content

Initiate A Deposit

In the deposit process, funds will be sent to Franklin Templeton, who will mint BENJI tokens corresponding with the amount of funds received.

Prerequisites

  • $env:BENJI_ACCESS_TOKEN is already set
  • you know your walletId
  • you know your productId
  • you know the amount you want to deposit
  • you know the wire or SWIFT reference you want to use
  • you know the userId that should be recorded as the creator

Step 1: Set your deposit inputs

This example uses a wire transfer reference. If you are using SWIFT instead, swap paymentMethodWire for paymentMethodSwift.

$walletId = "YOUR_WALLET_ID"
$productId = "YOUR_PRODUCT_ID"
$value = 12345.12
$fedWireRef = "YOUR_WIRE_REFERENCE"
$userId = "YOUR_CREATOR_USER_ID"

Step 2: Run depositCreate

$body = @{
query = @'
mutation (
$walletId: ID!,
$productId: ID!,
$value: BigDecimal!,
$fedWireRef: String!,
$userId: String!
) {
depositCreate(
institutionInput: {
walletId: $walletId
productId: $productId
value: $value
paymentMethodWire: {
fedWireRefNumber: $fedWireRef
}
buildSigningPackage: false
userId: $userId
}
) {
depositId
approvalsRequired
blockchainStatus
}
}
'@
variables = @{
walletId = $walletId
productId = $productId
value = $value
fedWireRef = $fedWireRef
userId = $userId
}
} | ConvertTo-Json -Depth 10

Invoke-RestMethod `
-Uri "https://api-uat.frk.com/tf/platform/bve/graphql" `
-Method POST `
-Headers @{ Authorization = "Bearer $env:BENJI_ACCESS_TOKEN" } `
-ContentType "application/json" `
-Body $body | ConvertTo-Json -Depth 10

Save these outputs

After the call succeeds, keep:

  • depositId
  • approvalsRequired
  • blockchainStatus

If you continue the full lifecycle, use depositId for the later approve, submit, and status-check steps.