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

# Get Bitfinex Margin Long/Short

Retrieves Bitfinex margin long/short position data showing leveraged long vs short positioning on Bitfinex. Higher long positions indicate bullish sentiment, higher shorts indicate bearish. Ideal for: sentiment analysis, margin positioning trends, identifying crowded trades, contrarian signals.

![Get Bitfinex Margin Long/Short logo](https://ai-icon.b3.fun/logo/coinglass)
Catalog action Blockchain Data

Retrieves Bitfinex margin long/short position data showing leveraged long vs short positioning on Bitfinex. Higher long positions indicate bullish sentiment, higher shorts indicate bearish. Ideal for: sentiment analysis, margin positioning trends, identifying crowded trades, contrarian signals.


## At a Glance

| Field | Value |
| --- | --- |
| Action ID | `coinglass-indicator-get-bitfinex-margin` |
| Category | Blockchain Data |
| Connector | Not required |
| Requires gas | No |
| Funds movement | None declared |
| Tags | `coinglass`, `indicator`, `bitfinex`, `margin`, `long-short`, `spot`, `read` |

## Payload Schema

| Field | Type | Required | Description |
| --- | --- | --- | --- |
| `symbol` | `string` | Yes | Coin symbol \(e.g., 'BTC', 'ETH'\). |
| `interval` | `string` | Yes | Time interval for data aggregation. |
| `limit` | `number` | No | Maximum number of results \(default: 1000\). |
| `startTime` | `number` | No | Start timestamp in seconds. |
| `endTime` | `number` | No | End timestamp in seconds. |

## Result Schema

| Field | Type | Required | Description |
| --- | --- | --- | --- |
| `symbol` | `string` | Yes | Coin symbol. |
| `interval` | `string` | Yes | Time interval. |
| `dataPoints` | `array` | Yes | Array of Bitfinex margin long/short data points. |

## Examples

**Workflow node**

```json
{
  "type": "coinglass-indicator-get-bitfinex-margin",
  "payload": {
    "symbol": "ETH",
    "interval": "1m"
  },
  "children": []
}
```
  **Test with API**

```bash
curl -X POST "https://api.b3os.org/v1/actions/coinglass-indicator-get-bitfinex-margin/test" \
  -H "Authorization: Bearer YOUR_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{
  "inputs": {
    "symbol": "ETH",
    "interval": "1m"
  }
}'
```

**Use expressions for dynamic values**

Payload fields can use workflow expressions such as `{{$trigger.body.amount}}`, `{{$nodes.fetch.result.price}}`, and `{{$props.asset}}` when the value should come from a trigger, prior node, or reusable workflow prop.