Signal source guide

TradingView webhook alerts: JSON format and examples

The JSON fields Copygram reads from TradingView alerts, the signal_id rule for modify and close, and ready-to-copy examples for every order type.

Updated Oct 26, 2026

AI-powered alerts, no schema

Copygram reads your TradingView alerts with AI: there is no strict JSON schema. Send the fields you have and Copygram works out the intent. The more context you include, the more reliable execution becomes.

TradingView alert
{
  "action": "sell",
  "symbol": "GBPJPY",
  "volume": 0.01
}

Read by Copygram AI

Action
SELL
Symbol
GBPJPY
Volume
0.01
Type
Market

Recommended fields

No field is strictly required

Field

Purpose

Example

Status

actionWhat to do: open, modify, close, close half, move SL to BE"buy"Recommended
order_typeOrder direction and type"BUY LIMIT"Recommended
symbolInstrument to trade"GBPJPY"Recommended
volumeLot size of the order0.01Recommended
entryEntry price (mostly for pending orders)185.250Optional
slStop loss price184.800Optional
tpTake profit price186.500Optional
signal_idUnique trade ID, required to modify or close a specific trade later"qt_102938"If modifying

Supported order types

BUY

Market buy, fills at the current ask

BUY LIMIT

Pending buy below the current price

BUY STOP

Pending buy above the current price

SELL

Market sell, fills at the current bid

SELL LIMIT

Pending sell above the current price

SELL STOP

Pending sell below the current price

The signal_id rule

You only need a signal_id when you plan to modify SL/TP, close a specific trade or manage a position from a later alert.

  • The original open alert defines the signal_id.
  • Every later modify or close alert for that trade must reuse the same id.
  • Best practice: have your TradingView strategy generate a random or sequential id and reuse it.

Examples

The bare minimum: Copygram infers the rest.

TradingView alert
{
  "action": "sell",
  "symbol": "GBPJPY",
  "volume": 0.01
}

Read by Copygram AI

Action
SELL
Symbol
GBPJPY
Volume
0.01
Type
Market

Recommended for trades you'll modify or close later.

TradingView alert
{
  "action": "buy",
  "order_type": "BUY",
  "symbol": "GBPJPY",
  "volume": 0.01,
  "sl": 185.000,
  "tp": 186.500,
  "signal_id": "qt_102938"
}

Read by Copygram AI

Action
BUY
Symbol
GBPJPY
Volume
0.01
SL
185.000
TP
186.500
Signal ID
qt_102938

Reuses the signal_id of the open alert.

TradingView alert
{
  "action": "modify",
  "symbol": "GBPJPY",
  "sl": 185.400,
  "signal_id": "qt_102938"
}

Read by Copygram AI

Action
MODIFY
Symbol
GBPJPY
New SL
185.400
Signal ID
qt_102938

Two actions on the same trade.

Close half
{
  "action": "close half",
  "signal_id": "qt_102938"
}
Move SL to BE
{
  "action": "move SL to BE",
  "signal_id": "qt_102938"
}

Use entry for the pending price.

TradingView alert
{
  "action": "open",
  "order_type": "BUY LIMIT",
  "symbol": "EURUSD",
  "entry": 1.07500,
  "volume": 0.05,
  "sl": 1.07200,
  "tp": 1.08100,
  "signal_id": "qt_102939"
}

Read by Copygram AI

Type
BUY LIMIT
Symbol
EURUSD
Entry
1.07500
Volume
0.05
SL
1.07200
TP
1.08100

Quick close by symbol, no JSON needed.

Alert message
close EURUSD

Read by Copygram AI

Action
CLOSE
Symbol
EURUSD
Scope
All receivers
Match
All open EURUSD

"Close opposite positions" is not a webhook field

If a new BUY signal should close any open SELL on the same symbol (and the other way round), turn on Close opposite positions in the receiver's settings (Entries and exits), not in your alert payload.

Go to receiver settings

Tips and best practices

  • Include as many fields as you can: execution gets more reliable.
  • Generate a random signal_id per trade in your strategy.
  • Reuse the same signal_id on later modify and close alerts.
  • Plain text commands like close EURUSD work for quick actions.
  • Create your webhook URL under Signal sources → TradingView.
  • Test with a small volume before scaling up.

Want to copy TradingView alerts to your broker? See how Copygram does it.

TradingView trade copier

Next steps

Related guides