Update Trigger
When deploying OTA updates on devices, there are situations when your device state is not compatible with receiving new updates. If, for instance, your device is currently in use by the end-user, you would rather not deploy the new update at that time. Using the Update Trigger call, you can manage from within your application when you would like to receive updates, and when not to. After setting the update trigger, your device will not receive new updates until you unset the trigger.
post
https://api.connect.jfrog.io/v1/
set_update_trigger
Update Trigger

Example

Python
1
import json
2
import requests
3
4
5
#Upswift tokens
6
user_token = "<user token>"
7
device_token = "<device token>"
8
9
json_content = {'user_token': user_token,
10
'device_token': device_token,
11
'trigger_set': True}
12
13
call_request = requests.post("https://api.connect.jfrog.io/v1/set_update_trigger", json=json_content)
14
call_response = json.loads(call_request.text)
15
16
if call_request.status_code != 200:
17
if call_request.status_code == 429:
18
error = "API limit reached"
19
else:
20
error = call_response["error_message"]
21
print(error)
22
else:
23
response_message = call_response["message"]
24
Copied!
Copy link