IncSilence

WebhookJsonMsg

IncSilence Aggiornato   
Library "WebhookJsonMsg"
This webhook json message library provides convenient functions for building JSON messages
Used to manage automatic transaction orders and positions

method buildWebhookJson(msg)
  Builds the final JSON payload from a WebhookMessage type.
  Namespace types: WebhookMessage
  Parameters:
    msg (WebhookMessage)
  Returns: <string> A JSON Payload.

Dict
  Define some constant values
  Fields:
    OPEN_LONG (series string)
    OPEN_SHORT (series string)
    CLOSE_LONG (series string)
    CLOSE_SHORT (series string)
    LIMIT (series string)
    MARKET (series string)
    U_MARGIN (series string)
    C_MARGIN (series string)
    SPOT (series string)

WebhookMessage
  Webhook message structure.
  Fields:
    strategyId (series string)
    signalNo (series string)
    symbol (series string)
    symbolType (series string)
    orderSide (series string)
    price (series string)
    orderType (series string)
    takeProfitPrice (series string)
    stopLossPrice (series string)
    timestamp (series string)
    accessKey (series string)
Note di rilascio:
v2
fix: json without comma symbol
Note di rilascio:
v3

Updated:
WebhookMessage
  Webhook message structure.
  Fields:
    strategyId (series string)
    signalNo (series string)
    relatedSignalNo (series string)
    symbol (series string)
    symbolType (series string)
    orderSide (series string)
    price (series string)
    orderType (series string)
    takeProfitPrice (series string)
    stopLossPrice (series string)
    timestamp (series string)
    accessKey (series string)
    positionRatio (series string)
Note di rilascio:
v4
- modify timestamp value, replace fixed value with custom value
Libreria Pine

Nello spirito di condivisione promosso da TradingView, l'autore (al quale vanno i nostri ringraziamenti) ha deciso di pubblicare questo script in modalità open-source, così che chiunque possa comprenderlo e testarlo. Puoi utilizzare questa libreria in privato o all'interno di altre pubblicazioni open-source, ma il riutilizzo del codice è subordinato al rispetto del Regolamento.

Declinazione di responsabilità

Le informazioni ed i contenuti pubblicati non costituiscono in alcun modo una sollecitazione ad investire o ad operare nei mercati finanziari. Non sono inoltre fornite o supportate da TradingView. Maggiori dettagli nelle Condizioni d'uso.

Vuoi usare questa libreria?

Copia il testo ed incollalo nel tuo script.