> ## Documentation Index
> Fetch the complete documentation index at: https://docs.rebelfi.io/docs/llms.txt
> Use this file to discover all available pages before exploring further.

# Org Accounts

> Create and manage on-ramp and off-ramp accounts for your organization

## Create On-Ramp Account

Creates a virtual bank account for your organization. Requires KYB approval.

```
POST /v1/ramp/org/onramp-accounts
```

### Request

<ParamField body="orgWalletId" type="number">
  OrgWallet ID where stablecoin will be delivered
</ParamField>

<ParamField body="walletAddress" type="string">
  Alternative to `orgWalletId`: specify a wallet address directly
</ParamField>

<ParamField body="blockchain" type="string">
  Alternative to `orgWalletId`: specify the blockchain name (used with `walletAddress`)
</ParamField>

<ParamField body="destinationAsset" type="string" required>
  Destination asset: `USDC` or `USDT`
</ParamField>

<ParamField body="rail" type="string" default="ach">
  Payment rail: `ach`, `fedwire`, or `swift`
</ParamField>

<CodeGroup>
  ```bash cURL theme={null}
  curl -X POST "https://api.rebelfi.io/v1/ramp/org/onramp-accounts" \
    -H "x-api-key: your_api_key" \
    -H "Content-Type: application/json" \
    -d '{
      "orgWalletId": 1,
      "destinationAsset": "USDC",
      "rail": "ach"
    }'
  ```

  ```typescript SDK theme={null}
  const account = await client.ramp.createOnrampAccount({
    destinationAsset: 'USDC',
    orgWalletId: 1,
  });
  ```
</CodeGroup>

### Response

```json theme={null}
{
  "id": 1,
  "bankAccountNumber": "12345678",
  "routingNumber": "987654321",
  "bankName": "Lead Bank",
  "capabilities": ["ach"],
  "status": "active",
  "destinationAsset": "USDC",
  "networkId": "solana-mainnet"
}
```

***

## Get On-Ramp Account

Returns the organization's on-ramp account, or `null` if none exists.

```
GET /v1/ramp/org/onramp-account
```

<CodeGroup>
  ```bash cURL theme={null}
  curl "https://api.rebelfi.io/v1/ramp/org/onramp-account" \
    -H "x-api-key: your_api_key"
  ```

  ```typescript SDK theme={null}
  const account = await client.ramp.getOnrampAccount();
  ```
</CodeGroup>

### Response

```json theme={null}
{
  "id": 1,
  "bankAccountNumber": "12345678",
  "routingNumber": "987654321",
  "bankName": "Lead Bank",
  "capabilities": ["ach"],
  "status": "active",
  "destinationAsset": "USDC",
  "networkId": "solana-mainnet"
}
```

***

## Create Off-Ramp Account

Creates a crypto deposit address linked to a bank account for off-ramping. Requires KYB approval.

```
POST /v1/ramp/org/offramp-accounts
```

### Request

<ParamField body="org_wallet_id" type="number" required>
  Source OrgWallet ID (where crypto is sent from)
</ParamField>

<ParamField body="source_asset" type="string" default="USDC">
  Source crypto asset
</ParamField>

<ParamField body="rail" type="string" default="ach">
  Payment rail: `ach`, `fedwire`, or `swift`
</ParamField>

<ParamField body="bank_details" type="object" required>
  Bank account where USD will be delivered
</ParamField>

<Expandable title="bank_details fields">
  <ParamField body="bank_details.routing_number" type="string" required>
    ABA routing number
  </ParamField>

  <ParamField body="bank_details.account_number" type="string" required>
    Bank account number
  </ParamField>

  <ParamField body="bank_details.account_type" type="string" required>
    `checking` or `savings`
  </ParamField>

  <ParamField body="bank_details.account_holder_name" type="string" required>
    Name on the bank account
  </ParamField>

  <ParamField body="bank_details.bank_name" type="string" required>
    Bank name
  </ParamField>
</Expandable>

<CodeGroup>
  ```bash cURL theme={null}
  curl -X POST "https://api.rebelfi.io/v1/ramp/org/offramp-accounts" \
    -H "x-api-key: your_api_key" \
    -H "Content-Type: application/json" \
    -d '{
      "org_wallet_id": 1,
      "source_asset": "USDC",
      "rail": "ach",
      "bank_details": {
        "routing_number": "021000021",
        "account_number": "987654321",
        "account_type": "checking",
        "account_holder_name": "Acme Corp",
        "bank_name": "Chase Bank"
      }
    }'
  ```

  ```typescript SDK theme={null}
  const account = await client.ramp.createOfframpAccount({
    orgWalletId: 1,
    bankDetails: {
      routingNumber: '021000021',
      accountNumber: '987654321',
      accountType: 'checking',
      accountHolderName: 'Acme Corp',
      bankName: 'Chase Bank',
    },
  });
  ```
</CodeGroup>

### Response

```json theme={null}
{
  "id": 1,
  "sourceCryptoAddress": "0xABC123...",
  "sourceAsset": "USDC",
  "destinationAsset": "USD",
  "networkId": "solana-mainnet",
  "rail": "ach",
  "fiatBankName": "Chase Bank",
  "fiatAccountType": "checking",
  "fiatAccountHolderName": "Acme Corp",
  "status": "active"
}
```

***

## List Off-Ramp Accounts

Returns all off-ramp accounts for the organization.

```
GET /v1/ramp/org/offramp-accounts
```

<CodeGroup>
  ```bash cURL theme={null}
  curl "https://api.rebelfi.io/v1/ramp/org/offramp-accounts" \
    -H "x-api-key: your_api_key"
  ```

  ```typescript SDK theme={null}
  const accounts = await client.ramp.listOfframpAccounts();
  ```
</CodeGroup>

### Response

```json theme={null}
[
  {
    "id": 1,
    "sourceCryptoAddress": "0xABC123...",
    "sourceAsset": "USDC",
    "destinationAsset": "USD",
    "rail": "ach",
    "fiatBankName": "Chase Bank",
    "status": "active"
  }
]
```

***

## Get Off-Ramp Status

Returns the organization's KYB status and all off-ramp accounts.

```
GET /v1/ramp/org/offramp-status
```

<CodeGroup>
  ```bash cURL theme={null}
  curl "https://api.rebelfi.io/v1/ramp/org/offramp-status" \
    -H "x-api-key: your_api_key"
  ```

  ```typescript SDK theme={null}
  const status = await client.ramp.getOfframpStatus();
  ```
</CodeGroup>

### Response

```json theme={null}
{
  "kybStatus": "approved",
  "offrampAccounts": [
    {
      "id": 1,
      "sourceCryptoAddress": "0xABC123...",
      "sourceAsset": "USDC",
      "destinationAsset": "USD",
      "rail": "ach",
      "fiatBankName": "Chase Bank",
      "status": "active"
    }
  ]
}
```

<ResponseField name="kybStatus" type="string">
  Current KYB status: `pending`, `submitted`, `approved`, or `declined`
</ResponseField>

<ResponseField name="offrampAccounts" type="array">
  All off-ramp accounts for the organization
</ResponseField>
