Update Push Recommendation
π Overviewβ
The UpdatePushRecommendation API is used to update an existing recommendation and notify clients via push notification.
π Endpointβ
| Method | URL |
|---|---|
| POST | <protocol>://<host name>:<service port>/<service name>/<tenantid>/v1/UpdatePushRecommendation |
Requestβ
The request comprises the following parameters:
π¦ Request Parametersβ
| Parameter | Data Type | Mandatory / Optional | Description |
|---|---|---|---|
sessionKey | string | Mandatory | Session key from AuthenticateKeys API, passed as a Bearer Authorization header. |
parentRecoID | string | Mandatory | Recommendation ID of the parent recommendation. Returned from the SendPushRecommendation API. Used for all subsequent updates of the same recommendation. |
recoType | string | Mandatory | Value must be taken from Update Recommendation Types table. |
price | string | Optional | Updated recommended price (e.g., 27.55). "Mkt" if blank or zero. |
squareoffPrice | string | Optional | Updated squareβoff price. Must be > price for buy, < price for sell. "Mkt" if blank or zero. |
stoplossPrice | string | Optional | Updated stop-loss price. Must be < price for buy, > price for sell. "Mkt" if blank or zero. |
qtyPercentage | string | Optional | Updated recommended quantity percentage (where applicable). |
messageTitle | string | Optional | Push notification title. Default: "RESEARCH CALL MODIFIED". |
reportUrl | string | Optional | URL of updated analysis report. |
endTime | string | Optional | Updated validity date/time. Format: ddMMMyyyy HH:mm:ss (e.g., 31Jul2019 23:59:00). Defaults to todayβs date if not passed. |
uniqueID | string | Optional | Unique reference ID for your tracking. |
Example Requestβ
Headersβ
{
"Authorization": "Bearer eyBDyGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJDdXN0b21lcklkIjoiMTUyMyIsIm5Ob2RlTGljZW5zZUV4cGlyeSI6IjE4OTM2MDkwMDAiLCJpYXQiOjE1NjM2MDI2Nzd9.oRVgIlN3K_m5AXh_K1M88exzBg96CYJEVo_LQ-YZ6Yd"
}
Request Bodyβ
{
"parentRecoID": "245WAADOAA",
"recoType": "108",
"price": "50.95",
"squareoffPrice": "55.35",
"stoplossPrice": "46.55",
"qtyPercentage": "",
"messageTitle": "INTRADAY CALL UPDATE",
"reportUrl": "",
"endTime": "31Jul2019 23:59:00",
"uniqueID": "31072019121508"
}
Responseβ
The ResponseObject contains the following parameters in a JSON structure:
π§ͺ Response Parametersβ
| Parameter (Key) | Data Type | Description |
|---|---|---|
status | boolean | Indicates the status of the request. true if the response is successful, false if an error occurred. |
errorCode | string | Error code if any error occurred. |
errorString | string | Error description. |
recoID | string | Systemβgenerated recommendation ID used for further updates of this recommendation. |
Example Responseβ
{
"status": true,
"errorCode": "",
"errorString": "",
"recoID": "245WAADOAB"
}