particle-api-js 10.5.0 → 10.6.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/.circleci/config.yml +2 -4
- package/CHANGELOG.md +6 -0
- package/dist/particle.min.js +1 -1
- package/dist/particle.min.js.map +1 -1
- package/docs/api.md +171 -133
- package/package.json +1 -1
- package/src/Agent.js +4 -2
- package/src/Particle.js +54 -0
- package/test/Particle.spec.js +71 -0
package/docs/api.md
CHANGED
|
@@ -128,6 +128,8 @@
|
|
|
128
128
|
- [listLedgerInstances](#listledgerinstances)
|
|
129
129
|
- [listLedgerInstanceVersions](#listledgerinstanceversions)
|
|
130
130
|
- [getLedgerInstanceVersion](#getledgerinstanceversion)
|
|
131
|
+
- [listDeviceOsVersions](#listdeviceosversions)
|
|
132
|
+
- [getDeviceOsVersion](#getdeviceosversion)
|
|
131
133
|
- [setDefaultAuth](#setdefaultauth)
|
|
132
134
|
- [get](#get)
|
|
133
135
|
- [head](#head)
|
|
@@ -138,7 +140,7 @@
|
|
|
138
140
|
|
|
139
141
|
## Particle
|
|
140
142
|
|
|
141
|
-
[src/Particle.js:20-
|
|
143
|
+
[src/Particle.js:20-2853](https://github.com/spark/particle-api-js/blob/be140b28fba0636f389ec10a4fe492586de434c8/src/Particle.js#L20-L2853 "Source code on GitHub")
|
|
142
144
|
|
|
143
145
|
Particle Cloud API wrapper.
|
|
144
146
|
|
|
@@ -154,7 +156,7 @@ Most Particle methods take a single unnamed argument object documented as
|
|
|
154
156
|
|
|
155
157
|
### constructor
|
|
156
158
|
|
|
157
|
-
[src/Particle.js:33-42](https://github.com/
|
|
159
|
+
[src/Particle.js:33-42](https://github.com/spark/particle-api-js/blob/be140b28fba0636f389ec10a4fe492586de434c8/src/Particle.js#L33-L42 "Source code on GitHub")
|
|
158
160
|
|
|
159
161
|
Contructor for the Cloud API wrapper.
|
|
160
162
|
|
|
@@ -171,7 +173,7 @@ Create a new Particle object and call methods below on it.
|
|
|
171
173
|
|
|
172
174
|
### login
|
|
173
175
|
|
|
174
|
-
[src/Particle.js:79-96](https://github.com/
|
|
176
|
+
[src/Particle.js:79-96](https://github.com/spark/particle-api-js/blob/be140b28fba0636f389ec10a4fe492586de434c8/src/Particle.js#L79-L96 "Source code on GitHub")
|
|
175
177
|
|
|
176
178
|
Login to Particle Cloud using an existing Particle acccount.
|
|
177
179
|
|
|
@@ -188,7 +190,7 @@ Returns **[Promise](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Refe
|
|
|
188
190
|
|
|
189
191
|
### sendOtp
|
|
190
192
|
|
|
191
|
-
[src/Particle.js:107-123](https://github.com/
|
|
193
|
+
[src/Particle.js:107-123](https://github.com/spark/particle-api-js/blob/be140b28fba0636f389ec10a4fe492586de434c8/src/Particle.js#L107-L123 "Source code on GitHub")
|
|
192
194
|
|
|
193
195
|
If login failed with an 'mfa_required' error, this must be called with a valid OTP code to login
|
|
194
196
|
|
|
@@ -204,7 +206,7 @@ Returns **[Promise](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Refe
|
|
|
204
206
|
|
|
205
207
|
### enableMfa
|
|
206
208
|
|
|
207
|
-
[src/Particle.js:133-135](https://github.com/
|
|
209
|
+
[src/Particle.js:133-135](https://github.com/spark/particle-api-js/blob/be140b28fba0636f389ec10a4fe492586de434c8/src/Particle.js#L133-L135 "Source code on GitHub")
|
|
208
210
|
|
|
209
211
|
Enable MFA on the currently logged in user
|
|
210
212
|
|
|
@@ -219,7 +221,7 @@ Returns **[Promise](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Refe
|
|
|
219
221
|
|
|
220
222
|
### confirmMfa
|
|
221
223
|
|
|
222
|
-
[src/Particle.js:148-162](https://github.com/
|
|
224
|
+
[src/Particle.js:148-162](https://github.com/spark/particle-api-js/blob/be140b28fba0636f389ec10a4fe492586de434c8/src/Particle.js#L148-L162 "Source code on GitHub")
|
|
223
225
|
|
|
224
226
|
Confirm MFA for the user. This must be called with current TOTP code, determined from the results of enableMfa(). You will be prompted to enter an OTP code every time you login after enrollment is confirmed.
|
|
225
227
|
|
|
@@ -237,7 +239,7 @@ Returns **[Promise](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Refe
|
|
|
237
239
|
|
|
238
240
|
### disableMfa
|
|
239
241
|
|
|
240
|
-
[src/Particle.js:173-181](https://github.com/
|
|
242
|
+
[src/Particle.js:173-181](https://github.com/spark/particle-api-js/blob/be140b28fba0636f389ec10a4fe492586de434c8/src/Particle.js#L173-L181 "Source code on GitHub")
|
|
241
243
|
|
|
242
244
|
Disable MFA for the user.
|
|
243
245
|
|
|
@@ -253,7 +255,7 @@ Returns **[Promise](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Refe
|
|
|
253
255
|
|
|
254
256
|
### createCustomer
|
|
255
257
|
|
|
256
|
-
[src/Particle.js:193-209](https://github.com/
|
|
258
|
+
[src/Particle.js:193-209](https://github.com/spark/particle-api-js/blob/be140b28fba0636f389ec10a4fe492586de434c8/src/Particle.js#L193-L209 "Source code on GitHub")
|
|
257
259
|
|
|
258
260
|
Create Customer for Product.
|
|
259
261
|
|
|
@@ -270,7 +272,7 @@ Returns **[Promise](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Refe
|
|
|
270
272
|
|
|
271
273
|
### loginAsClientOwner
|
|
272
274
|
|
|
273
|
-
[src/Particle.js:218-232](https://github.com/
|
|
275
|
+
[src/Particle.js:218-232](https://github.com/spark/particle-api-js/blob/be140b28fba0636f389ec10a4fe492586de434c8/src/Particle.js#L218-L232 "Source code on GitHub")
|
|
274
276
|
|
|
275
277
|
Login to Particle Cloud using an OAuth client.
|
|
276
278
|
|
|
@@ -284,7 +286,7 @@ Returns **[Promise](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Refe
|
|
|
284
286
|
|
|
285
287
|
### createUser
|
|
286
288
|
|
|
287
|
-
[src/Particle.js:245-257](https://github.com/
|
|
289
|
+
[src/Particle.js:245-257](https://github.com/spark/particle-api-js/blob/be140b28fba0636f389ec10a4fe492586de434c8/src/Particle.js#L245-L257 "Source code on GitHub")
|
|
288
290
|
|
|
289
291
|
Create a user account for the Particle Cloud
|
|
290
292
|
|
|
@@ -302,7 +304,7 @@ Returns **[Promise](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Refe
|
|
|
302
304
|
|
|
303
305
|
### verifyUser
|
|
304
306
|
|
|
305
|
-
[src/Particle.js:267-274](https://github.com/
|
|
307
|
+
[src/Particle.js:267-274](https://github.com/spark/particle-api-js/blob/be140b28fba0636f389ec10a4fe492586de434c8/src/Particle.js#L267-L274 "Source code on GitHub")
|
|
306
308
|
|
|
307
309
|
Verify new user account via verification email
|
|
308
310
|
|
|
@@ -317,7 +319,7 @@ Returns **[Promise](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Refe
|
|
|
317
319
|
|
|
318
320
|
### resetPassword
|
|
319
321
|
|
|
320
|
-
[src/Particle.js:284-291](https://github.com/
|
|
322
|
+
[src/Particle.js:284-291](https://github.com/spark/particle-api-js/blob/be140b28fba0636f389ec10a4fe492586de434c8/src/Particle.js#L284-L291 "Source code on GitHub")
|
|
321
323
|
|
|
322
324
|
Send reset password email for a Particle Cloud user account
|
|
323
325
|
|
|
@@ -332,7 +334,7 @@ Returns **[Promise](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Refe
|
|
|
332
334
|
|
|
333
335
|
### deleteAccessToken
|
|
334
336
|
|
|
335
|
-
[src/Particle.js:303-311](https://github.com/
|
|
337
|
+
[src/Particle.js:303-311](https://github.com/spark/particle-api-js/blob/be140b28fba0636f389ec10a4fe492586de434c8/src/Particle.js#L303-L311 "Source code on GitHub")
|
|
336
338
|
|
|
337
339
|
Revoke an access token
|
|
338
340
|
|
|
@@ -349,7 +351,7 @@ Returns **[Promise](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Refe
|
|
|
349
351
|
|
|
350
352
|
### deleteCurrentAccessToken
|
|
351
353
|
|
|
352
|
-
[src/Particle.js:321-328](https://github.com/
|
|
354
|
+
[src/Particle.js:321-328](https://github.com/spark/particle-api-js/blob/be140b28fba0636f389ec10a4fe492586de434c8/src/Particle.js#L321-L328 "Source code on GitHub")
|
|
353
355
|
|
|
354
356
|
Revoke the current session access token
|
|
355
357
|
|
|
@@ -364,7 +366,7 @@ Returns **[Promise](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Refe
|
|
|
364
366
|
|
|
365
367
|
### deleteActiveAccessTokens
|
|
366
368
|
|
|
367
|
-
[src/Particle.js:338-345](https://github.com/
|
|
369
|
+
[src/Particle.js:338-345](https://github.com/spark/particle-api-js/blob/be140b28fba0636f389ec10a4fe492586de434c8/src/Particle.js#L338-L345 "Source code on GitHub")
|
|
368
370
|
|
|
369
371
|
Revoke all active access tokens
|
|
370
372
|
|
|
@@ -379,7 +381,7 @@ Returns **[Promise](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Refe
|
|
|
379
381
|
|
|
380
382
|
### deleteUser
|
|
381
383
|
|
|
382
|
-
[src/Particle.js:356-364](https://github.com/
|
|
384
|
+
[src/Particle.js:356-364](https://github.com/spark/particle-api-js/blob/be140b28fba0636f389ec10a4fe492586de434c8/src/Particle.js#L356-L364 "Source code on GitHub")
|
|
383
385
|
|
|
384
386
|
Delete the current user
|
|
385
387
|
|
|
@@ -395,7 +397,7 @@ Returns **[Promise](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Refe
|
|
|
395
397
|
|
|
396
398
|
### listAccessTokens
|
|
397
399
|
|
|
398
|
-
[src/Particle.js:376-384](https://github.com/
|
|
400
|
+
[src/Particle.js:376-384](https://github.com/spark/particle-api-js/blob/be140b28fba0636f389ec10a4fe492586de434c8/src/Particle.js#L376-L384 "Source code on GitHub")
|
|
399
401
|
|
|
400
402
|
List all valid access tokens for a Particle Cloud account
|
|
401
403
|
|
|
@@ -412,7 +414,7 @@ Returns **[Promise](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Refe
|
|
|
412
414
|
|
|
413
415
|
### trackingIdentity
|
|
414
416
|
|
|
415
|
-
[src/Particle.js:396-404](https://github.com/
|
|
417
|
+
[src/Particle.js:396-404](https://github.com/spark/particle-api-js/blob/be140b28fba0636f389ec10a4fe492586de434c8/src/Particle.js#L396-L404 "Source code on GitHub")
|
|
416
418
|
|
|
417
419
|
Retrieves the information that is used to identify the current login for tracking.
|
|
418
420
|
|
|
@@ -429,7 +431,7 @@ Returns **[Promise](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Refe
|
|
|
429
431
|
|
|
430
432
|
### listDevices
|
|
431
433
|
|
|
432
|
-
[src/Particle.js:422-441](https://github.com/
|
|
434
|
+
[src/Particle.js:422-441](https://github.com/spark/particle-api-js/blob/be140b28fba0636f389ec10a4fe492586de434c8/src/Particle.js#L422-L441 "Source code on GitHub")
|
|
433
435
|
|
|
434
436
|
List devices claimed to the account or product
|
|
435
437
|
|
|
@@ -452,7 +454,7 @@ Returns **[Promise](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Refe
|
|
|
452
454
|
|
|
453
455
|
### getDevice
|
|
454
456
|
|
|
455
|
-
[src/Particle.js:453-456](https://github.com/
|
|
457
|
+
[src/Particle.js:453-456](https://github.com/spark/particle-api-js/blob/be140b28fba0636f389ec10a4fe492586de434c8/src/Particle.js#L453-L456 "Source code on GitHub")
|
|
456
458
|
|
|
457
459
|
Get detailed informationa about a device
|
|
458
460
|
|
|
@@ -469,7 +471,7 @@ Returns **[Promise](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Refe
|
|
|
469
471
|
|
|
470
472
|
### claimDevice
|
|
471
473
|
|
|
472
|
-
[src/Particle.js:468-479](https://github.com/
|
|
474
|
+
[src/Particle.js:468-479](https://github.com/spark/particle-api-js/blob/be140b28fba0636f389ec10a4fe492586de434c8/src/Particle.js#L468-L479 "Source code on GitHub")
|
|
473
475
|
|
|
474
476
|
Claim a device to the account. The device must be online and unclaimed.
|
|
475
477
|
|
|
@@ -486,7 +488,7 @@ Returns **[Promise](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Refe
|
|
|
486
488
|
|
|
487
489
|
### addDeviceToProduct
|
|
488
490
|
|
|
489
|
-
[src/Particle.js:493-511](https://github.com/
|
|
491
|
+
[src/Particle.js:493-511](https://github.com/spark/particle-api-js/blob/be140b28fba0636f389ec10a4fe492586de434c8/src/Particle.js#L493-L511 "Source code on GitHub")
|
|
490
492
|
|
|
491
493
|
Add a device to a product or move device out of quarantine.
|
|
492
494
|
|
|
@@ -505,7 +507,7 @@ Returns **[Promise](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Refe
|
|
|
505
507
|
|
|
506
508
|
### removeDevice
|
|
507
509
|
|
|
508
|
-
[src/Particle.js:524-528](https://github.com/
|
|
510
|
+
[src/Particle.js:524-528](https://github.com/spark/particle-api-js/blob/be140b28fba0636f389ec10a4fe492586de434c8/src/Particle.js#L524-L528 "Source code on GitHub")
|
|
509
511
|
|
|
510
512
|
Unclaim / Remove a device from your account or product, or deny quarantine
|
|
511
513
|
|
|
@@ -523,7 +525,7 @@ Returns **[Promise](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Refe
|
|
|
523
525
|
|
|
524
526
|
### removeDeviceOwner
|
|
525
527
|
|
|
526
|
-
[src/Particle.js:540-543](https://github.com/
|
|
528
|
+
[src/Particle.js:540-543](https://github.com/spark/particle-api-js/blob/be140b28fba0636f389ec10a4fe492586de434c8/src/Particle.js#L540-L543 "Source code on GitHub")
|
|
527
529
|
|
|
528
530
|
Unclaim a product device its the owner, but keep it in the product
|
|
529
531
|
|
|
@@ -540,7 +542,7 @@ Returns **[Promise](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Refe
|
|
|
540
542
|
|
|
541
543
|
### renameDevice
|
|
542
544
|
|
|
543
|
-
[src/Particle.js:556-558](https://github.com/
|
|
545
|
+
[src/Particle.js:556-558](https://github.com/spark/particle-api-js/blob/be140b28fba0636f389ec10a4fe492586de434c8/src/Particle.js#L556-L558 "Source code on GitHub")
|
|
544
546
|
|
|
545
547
|
Rename a device
|
|
546
548
|
|
|
@@ -558,7 +560,7 @@ Returns **[Promise](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Refe
|
|
|
558
560
|
|
|
559
561
|
### signalDevice
|
|
560
562
|
|
|
561
|
-
[src/Particle.js:571-573](https://github.com/
|
|
563
|
+
[src/Particle.js:571-573](https://github.com/spark/particle-api-js/blob/be140b28fba0636f389ec10a4fe492586de434c8/src/Particle.js#L571-L573 "Source code on GitHub")
|
|
562
564
|
|
|
563
565
|
Instruct the device to turn on/off the LED in a rainbow pattern
|
|
564
566
|
|
|
@@ -576,7 +578,7 @@ Returns **[Promise](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Refe
|
|
|
576
578
|
|
|
577
579
|
### setDeviceNotes
|
|
578
580
|
|
|
579
|
-
[src/Particle.js:586-588](https://github.com/
|
|
581
|
+
[src/Particle.js:586-588](https://github.com/spark/particle-api-js/blob/be140b28fba0636f389ec10a4fe492586de434c8/src/Particle.js#L586-L588 "Source code on GitHub")
|
|
580
582
|
|
|
581
583
|
Store some notes about device
|
|
582
584
|
|
|
@@ -594,7 +596,7 @@ Returns **[Promise](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Refe
|
|
|
594
596
|
|
|
595
597
|
### markAsDevelopmentDevice
|
|
596
598
|
|
|
597
|
-
[src/Particle.js:601-603](https://github.com/
|
|
599
|
+
[src/Particle.js:601-603](https://github.com/spark/particle-api-js/blob/be140b28fba0636f389ec10a4fe492586de434c8/src/Particle.js#L601-L603 "Source code on GitHub")
|
|
598
600
|
|
|
599
601
|
Mark device as being used in development of a product so it opts out of automatic firmware updates
|
|
600
602
|
|
|
@@ -612,7 +614,7 @@ Returns **[Promise](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Refe
|
|
|
612
614
|
|
|
613
615
|
### lockDeviceProductFirmware
|
|
614
616
|
|
|
615
|
-
[src/Particle.js:617-619](https://github.com/
|
|
617
|
+
[src/Particle.js:617-619](https://github.com/spark/particle-api-js/blob/be140b28fba0636f389ec10a4fe492586de434c8/src/Particle.js#L617-L619 "Source code on GitHub")
|
|
616
618
|
|
|
617
619
|
Mark device as being used in development of a product, so it opts out of automatic firmware updates
|
|
618
620
|
|
|
@@ -631,7 +633,7 @@ Returns **[Promise](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Refe
|
|
|
631
633
|
|
|
632
634
|
### unlockDeviceProductFirmware
|
|
633
635
|
|
|
634
|
-
[src/Particle.js:631-633](https://github.com/
|
|
636
|
+
[src/Particle.js:631-633](https://github.com/spark/particle-api-js/blob/be140b28fba0636f389ec10a4fe492586de434c8/src/Particle.js#L631-L633 "Source code on GitHub")
|
|
635
637
|
|
|
636
638
|
Mark device as receiving automatic firmware updates
|
|
637
639
|
|
|
@@ -648,7 +650,7 @@ Returns **[Promise](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Refe
|
|
|
648
650
|
|
|
649
651
|
### updateDevice
|
|
650
652
|
|
|
651
|
-
[src/Particle.js:652-664](https://github.com/
|
|
653
|
+
[src/Particle.js:652-664](https://github.com/spark/particle-api-js/blob/be140b28fba0636f389ec10a4fe492586de434c8/src/Particle.js#L652-L664 "Source code on GitHub")
|
|
652
654
|
|
|
653
655
|
Update multiple device attributes at the same time
|
|
654
656
|
|
|
@@ -672,7 +674,7 @@ Returns **[Promise](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Refe
|
|
|
672
674
|
|
|
673
675
|
### unprotectDevice
|
|
674
676
|
|
|
675
|
-
[src/Particle.js:684-700](https://github.com/
|
|
677
|
+
[src/Particle.js:684-700](https://github.com/spark/particle-api-js/blob/be140b28fba0636f389ec10a4fe492586de434c8/src/Particle.js#L684-L700 "Source code on GitHub")
|
|
676
678
|
|
|
677
679
|
Disable device protection.
|
|
678
680
|
|
|
@@ -696,7 +698,7 @@ Returns **[Promise](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Refe
|
|
|
696
698
|
|
|
697
699
|
### provisionDevice
|
|
698
700
|
|
|
699
|
-
[src/Particle.js:711-719](https://github.com/
|
|
701
|
+
[src/Particle.js:711-719](https://github.com/spark/particle-api-js/blob/be140b28fba0636f389ec10a4fe492586de434c8/src/Particle.js#L711-L719 "Source code on GitHub")
|
|
700
702
|
|
|
701
703
|
Provision a new device for products that allow self-provisioning
|
|
702
704
|
|
|
@@ -712,7 +714,7 @@ Returns **[Promise](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Refe
|
|
|
712
714
|
|
|
713
715
|
### getClaimCode
|
|
714
716
|
|
|
715
|
-
[src/Particle.js:733-736](https://github.com/
|
|
717
|
+
[src/Particle.js:733-736](https://github.com/spark/particle-api-js/blob/be140b28fba0636f389ec10a4fe492586de434c8/src/Particle.js#L733-L736 "Source code on GitHub")
|
|
716
718
|
|
|
717
719
|
Generate a claim code to use in the device claiming process.
|
|
718
720
|
To generate a claim code for a product, the access token MUST belong to a
|
|
@@ -731,7 +733,7 @@ Returns **[Promise](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Refe
|
|
|
731
733
|
|
|
732
734
|
### getVariable
|
|
733
735
|
|
|
734
|
-
[src/Particle.js:758-764](https://github.com/
|
|
736
|
+
[src/Particle.js:758-764](https://github.com/spark/particle-api-js/blob/be140b28fba0636f389ec10a4fe492586de434c8/src/Particle.js#L758-L764 "Source code on GitHub")
|
|
735
737
|
|
|
736
738
|
Get the value of a device variable
|
|
737
739
|
|
|
@@ -749,7 +751,7 @@ Returns **[Promise](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Refe
|
|
|
749
751
|
|
|
750
752
|
### flashDevice
|
|
751
753
|
|
|
752
|
-
[src/Particle.js:778-789](https://github.com/
|
|
754
|
+
[src/Particle.js:778-789](https://github.com/spark/particle-api-js/blob/be140b28fba0636f389ec10a4fe492586de434c8/src/Particle.js#L778-L789 "Source code on GitHub")
|
|
753
755
|
|
|
754
756
|
Compile and flash application firmware to a device. Pass a pre-compiled binary to flash it directly to the device.
|
|
755
757
|
|
|
@@ -768,7 +770,7 @@ Returns **[Promise](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Refe
|
|
|
768
770
|
|
|
769
771
|
### flashTinker
|
|
770
772
|
|
|
771
|
-
[src/Particle.js:800-815](https://github.com/
|
|
773
|
+
[src/Particle.js:800-815](https://github.com/spark/particle-api-js/blob/be140b28fba0636f389ec10a4fe492586de434c8/src/Particle.js#L800-L815 "Source code on GitHub")
|
|
772
774
|
|
|
773
775
|
DEPRECATED: Flash the Tinker application to a device. Instead compile and flash the Tinker source code.
|
|
774
776
|
|
|
@@ -784,7 +786,7 @@ Returns **[Promise](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Refe
|
|
|
784
786
|
|
|
785
787
|
### compileCode
|
|
786
788
|
|
|
787
|
-
[src/Particle.js:828-846](https://github.com/
|
|
789
|
+
[src/Particle.js:828-846](https://github.com/spark/particle-api-js/blob/be140b28fba0636f389ec10a4fe492586de434c8/src/Particle.js#L828-L846 "Source code on GitHub")
|
|
788
790
|
|
|
789
791
|
Compile firmware using the Particle Cloud
|
|
790
792
|
|
|
@@ -802,7 +804,7 @@ Returns **[Promise](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Refe
|
|
|
802
804
|
|
|
803
805
|
### downloadFirmwareBinary
|
|
804
806
|
|
|
805
|
-
[src/Particle.js:857-866](https://github.com/
|
|
807
|
+
[src/Particle.js:857-866](https://github.com/spark/particle-api-js/blob/be140b28fba0636f389ec10a4fe492586de434c8/src/Particle.js#L857-L866 "Source code on GitHub")
|
|
806
808
|
|
|
807
809
|
Download a firmware binary
|
|
808
810
|
|
|
@@ -818,7 +820,7 @@ Returns **[Promise](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Refe
|
|
|
818
820
|
|
|
819
821
|
### sendPublicKey
|
|
820
822
|
|
|
821
|
-
[src/Particle.js:879-893](https://github.com/
|
|
823
|
+
[src/Particle.js:879-893](https://github.com/spark/particle-api-js/blob/be140b28fba0636f389ec10a4fe492586de434c8/src/Particle.js#L879-L893 "Source code on GitHub")
|
|
822
824
|
|
|
823
825
|
Send a new device public key to the Particle Cloud
|
|
824
826
|
|
|
@@ -836,7 +838,7 @@ Returns **[Promise](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Refe
|
|
|
836
838
|
|
|
837
839
|
### callFunction
|
|
838
840
|
|
|
839
|
-
[src/Particle.js:907-912](https://github.com/
|
|
841
|
+
[src/Particle.js:907-912](https://github.com/spark/particle-api-js/blob/be140b28fba0636f389ec10a4fe492586de434c8/src/Particle.js#L907-L912 "Source code on GitHub")
|
|
840
842
|
|
|
841
843
|
Call a device function
|
|
842
844
|
|
|
@@ -855,7 +857,7 @@ Returns **[Promise](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Refe
|
|
|
855
857
|
|
|
856
858
|
### getEventStream
|
|
857
859
|
|
|
858
|
-
[src/Particle.js:925-950](https://github.com/
|
|
860
|
+
[src/Particle.js:925-950](https://github.com/spark/particle-api-js/blob/be140b28fba0636f389ec10a4fe492586de434c8/src/Particle.js#L925-L950 "Source code on GitHub")
|
|
859
861
|
|
|
860
862
|
Get a stream of events
|
|
861
863
|
|
|
@@ -873,7 +875,7 @@ emit 'event' events.
|
|
|
873
875
|
|
|
874
876
|
### publishEvent
|
|
875
877
|
|
|
876
|
-
[src/Particle.js:964-968](https://github.com/
|
|
878
|
+
[src/Particle.js:964-968](https://github.com/spark/particle-api-js/blob/be140b28fba0636f389ec10a4fe492586de434c8/src/Particle.js#L964-L968 "Source code on GitHub")
|
|
877
879
|
|
|
878
880
|
Publish a event to the Particle Cloud
|
|
879
881
|
|
|
@@ -892,7 +894,7 @@ Returns **[Promise](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Refe
|
|
|
892
894
|
|
|
893
895
|
### Hook
|
|
894
896
|
|
|
895
|
-
[src/Particle.js:999-1021](https://github.com/
|
|
897
|
+
[src/Particle.js:999-1021](https://github.com/spark/particle-api-js/blob/be140b28fba0636f389ec10a4fe492586de434c8/src/Particle.js#L999-L1021 "Source code on GitHub")
|
|
896
898
|
|
|
897
899
|
Type: [Object](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Object)
|
|
898
900
|
|
|
@@ -925,7 +927,7 @@ Type: [Object](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference
|
|
|
925
927
|
|
|
926
928
|
### createWebhook
|
|
927
929
|
|
|
928
|
-
[src/Particle.js:999-1021](https://github.com/
|
|
930
|
+
[src/Particle.js:999-1021](https://github.com/spark/particle-api-js/blob/be140b28fba0636f389ec10a4fe492586de434c8/src/Particle.js#L999-L1021 "Source code on GitHub")
|
|
929
931
|
|
|
930
932
|
Create a webhook
|
|
931
933
|
|
|
@@ -947,7 +949,7 @@ Returns **[Promise](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Refe
|
|
|
947
949
|
|
|
948
950
|
### deleteWebhook
|
|
949
951
|
|
|
950
|
-
[src/Particle.js:1033-1036](https://github.com/
|
|
952
|
+
[src/Particle.js:1033-1036](https://github.com/spark/particle-api-js/blob/be140b28fba0636f389ec10a4fe492586de434c8/src/Particle.js#L1033-L1036 "Source code on GitHub")
|
|
951
953
|
|
|
952
954
|
Delete a webhook
|
|
953
955
|
|
|
@@ -964,7 +966,7 @@ Returns **[Promise](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Refe
|
|
|
964
966
|
|
|
965
967
|
### listWebhooks
|
|
966
968
|
|
|
967
|
-
[src/Particle.js:1047-1050](https://github.com/
|
|
969
|
+
[src/Particle.js:1047-1050](https://github.com/spark/particle-api-js/blob/be140b28fba0636f389ec10a4fe492586de434c8/src/Particle.js#L1047-L1050 "Source code on GitHub")
|
|
968
970
|
|
|
969
971
|
List all webhooks owned by the account or product
|
|
970
972
|
|
|
@@ -980,7 +982,7 @@ Returns **[Promise](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Refe
|
|
|
980
982
|
|
|
981
983
|
### createIntegration
|
|
982
984
|
|
|
983
|
-
[src/Particle.js:1067-1071](https://github.com/
|
|
985
|
+
[src/Particle.js:1067-1071](https://github.com/spark/particle-api-js/blob/be140b28fba0636f389ec10a4fe492586de434c8/src/Particle.js#L1067-L1071 "Source code on GitHub")
|
|
984
986
|
|
|
985
987
|
Create an integration to send events to an external service
|
|
986
988
|
|
|
@@ -1001,7 +1003,7 @@ Returns **[Promise](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Refe
|
|
|
1001
1003
|
|
|
1002
1004
|
### editIntegration
|
|
1003
1005
|
|
|
1004
|
-
[src/Particle.js:1089-1093](https://github.com/
|
|
1006
|
+
[src/Particle.js:1089-1093](https://github.com/spark/particle-api-js/blob/be140b28fba0636f389ec10a4fe492586de434c8/src/Particle.js#L1089-L1093 "Source code on GitHub")
|
|
1005
1007
|
|
|
1006
1008
|
Edit an integration to send events to an external service
|
|
1007
1009
|
|
|
@@ -1023,7 +1025,7 @@ Returns **[Promise](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Refe
|
|
|
1023
1025
|
|
|
1024
1026
|
### deleteIntegration
|
|
1025
1027
|
|
|
1026
|
-
[src/Particle.js:1106-1109](https://github.com/
|
|
1028
|
+
[src/Particle.js:1106-1109](https://github.com/spark/particle-api-js/blob/be140b28fba0636f389ec10a4fe492586de434c8/src/Particle.js#L1106-L1109 "Source code on GitHub")
|
|
1027
1029
|
|
|
1028
1030
|
Delete an integration to send events to an external service
|
|
1029
1031
|
|
|
@@ -1040,7 +1042,7 @@ Returns **[Promise](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Refe
|
|
|
1040
1042
|
|
|
1041
1043
|
### listIntegrations
|
|
1042
1044
|
|
|
1043
|
-
[src/Particle.js:1120-1123](https://github.com/
|
|
1045
|
+
[src/Particle.js:1120-1123](https://github.com/spark/particle-api-js/blob/be140b28fba0636f389ec10a4fe492586de434c8/src/Particle.js#L1120-L1123 "Source code on GitHub")
|
|
1044
1046
|
|
|
1045
1047
|
List all integrations owned by the account or product
|
|
1046
1048
|
|
|
@@ -1056,7 +1058,7 @@ Returns **[Promise](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Refe
|
|
|
1056
1058
|
|
|
1057
1059
|
### getUserInfo
|
|
1058
1060
|
|
|
1059
|
-
[src/Particle.js:1133-1135](https://github.com/
|
|
1061
|
+
[src/Particle.js:1133-1135](https://github.com/spark/particle-api-js/blob/be140b28fba0636f389ec10a4fe492586de434c8/src/Particle.js#L1133-L1135 "Source code on GitHub")
|
|
1060
1062
|
|
|
1061
1063
|
Get details about the current user
|
|
1062
1064
|
|
|
@@ -1071,7 +1073,7 @@ Returns **[Promise](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Refe
|
|
|
1071
1073
|
|
|
1072
1074
|
### setUserInfo
|
|
1073
1075
|
|
|
1074
|
-
[src/Particle.js:1146-1149](https://github.com/
|
|
1076
|
+
[src/Particle.js:1146-1149](https://github.com/spark/particle-api-js/blob/be140b28fba0636f389ec10a4fe492586de434c8/src/Particle.js#L1146-L1149 "Source code on GitHub")
|
|
1075
1077
|
|
|
1076
1078
|
Set details on the current user
|
|
1077
1079
|
|
|
@@ -1087,7 +1089,7 @@ Returns **[Promise](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Refe
|
|
|
1087
1089
|
|
|
1088
1090
|
### changeUsername
|
|
1089
1091
|
|
|
1090
|
-
[src/Particle.js:1162-1170](https://github.com/
|
|
1092
|
+
[src/Particle.js:1162-1170](https://github.com/spark/particle-api-js/blob/be140b28fba0636f389ec10a4fe492586de434c8/src/Particle.js#L1162-L1170 "Source code on GitHub")
|
|
1091
1093
|
|
|
1092
1094
|
Change username (i.e, email)
|
|
1093
1095
|
|
|
@@ -1105,7 +1107,7 @@ Returns **[Promise](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Refe
|
|
|
1105
1107
|
|
|
1106
1108
|
### changeUserPassword
|
|
1107
1109
|
|
|
1108
|
-
[src/Particle.js:1183-1191](https://github.com/
|
|
1110
|
+
[src/Particle.js:1183-1191](https://github.com/spark/particle-api-js/blob/be140b28fba0636f389ec10a4fe492586de434c8/src/Particle.js#L1183-L1191 "Source code on GitHub")
|
|
1109
1111
|
|
|
1110
1112
|
Change user's password
|
|
1111
1113
|
|
|
@@ -1123,7 +1125,7 @@ Returns **[Promise](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Refe
|
|
|
1123
1125
|
|
|
1124
1126
|
### listSIMs
|
|
1125
1127
|
|
|
1126
|
-
[src/Particle.js:1207-1211](https://github.com/
|
|
1128
|
+
[src/Particle.js:1207-1211](https://github.com/spark/particle-api-js/blob/be140b28fba0636f389ec10a4fe492586de434c8/src/Particle.js#L1207-L1211 "Source code on GitHub")
|
|
1127
1129
|
|
|
1128
1130
|
List SIM cards owned by a user or product
|
|
1129
1131
|
|
|
@@ -1144,7 +1146,7 @@ Returns **[Promise](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Refe
|
|
|
1144
1146
|
|
|
1145
1147
|
### getSIMDataUsage
|
|
1146
1148
|
|
|
1147
|
-
[src/Particle.js:1223-1229](https://github.com/
|
|
1149
|
+
[src/Particle.js:1223-1229](https://github.com/spark/particle-api-js/blob/be140b28fba0636f389ec10a4fe492586de434c8/src/Particle.js#L1223-L1229 "Source code on GitHub")
|
|
1148
1150
|
|
|
1149
1151
|
Get data usage for one SIM card for the current billing period
|
|
1150
1152
|
|
|
@@ -1161,7 +1163,7 @@ Returns **[Promise](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Refe
|
|
|
1161
1163
|
|
|
1162
1164
|
### getFleetDataUsage
|
|
1163
1165
|
|
|
1164
|
-
[src/Particle.js:1240-1247](https://github.com/
|
|
1166
|
+
[src/Particle.js:1240-1247](https://github.com/spark/particle-api-js/blob/be140b28fba0636f389ec10a4fe492586de434c8/src/Particle.js#L1240-L1247 "Source code on GitHub")
|
|
1165
1167
|
|
|
1166
1168
|
Get data usage for all SIM cards in a product the current billing period
|
|
1167
1169
|
|
|
@@ -1177,7 +1179,7 @@ Returns **[Promise](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Refe
|
|
|
1177
1179
|
|
|
1178
1180
|
### checkSIM
|
|
1179
1181
|
|
|
1180
|
-
[src/Particle.js:1258-1260](https://github.com/
|
|
1182
|
+
[src/Particle.js:1258-1260](https://github.com/spark/particle-api-js/blob/be140b28fba0636f389ec10a4fe492586de434c8/src/Particle.js#L1258-L1260 "Source code on GitHub")
|
|
1181
1183
|
|
|
1182
1184
|
Check SIM status
|
|
1183
1185
|
|
|
@@ -1193,7 +1195,7 @@ Returns **[Promise](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Refe
|
|
|
1193
1195
|
|
|
1194
1196
|
### activateSIM
|
|
1195
1197
|
|
|
1196
|
-
[src/Particle.js:1275-1285](https://github.com/
|
|
1198
|
+
[src/Particle.js:1275-1285](https://github.com/spark/particle-api-js/blob/be140b28fba0636f389ec10a4fe492586de434c8/src/Particle.js#L1275-L1285 "Source code on GitHub")
|
|
1197
1199
|
|
|
1198
1200
|
Activate and add SIM cards to an account or product
|
|
1199
1201
|
|
|
@@ -1213,7 +1215,7 @@ Returns **[Promise](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Refe
|
|
|
1213
1215
|
|
|
1214
1216
|
### deactivateSIM
|
|
1215
1217
|
|
|
1216
|
-
[src/Particle.js:1297-1301](https://github.com/
|
|
1218
|
+
[src/Particle.js:1297-1301](https://github.com/spark/particle-api-js/blob/be140b28fba0636f389ec10a4fe492586de434c8/src/Particle.js#L1297-L1301 "Source code on GitHub")
|
|
1217
1219
|
|
|
1218
1220
|
Deactivate a SIM card so it doesn't incur data usage in future months.
|
|
1219
1221
|
|
|
@@ -1230,7 +1232,7 @@ Returns **[Promise](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Refe
|
|
|
1230
1232
|
|
|
1231
1233
|
### reactivateSIM
|
|
1232
1234
|
|
|
1233
|
-
[src/Particle.js:1314-1318](https://github.com/
|
|
1235
|
+
[src/Particle.js:1314-1318](https://github.com/spark/particle-api-js/blob/be140b28fba0636f389ec10a4fe492586de434c8/src/Particle.js#L1314-L1318 "Source code on GitHub")
|
|
1234
1236
|
|
|
1235
1237
|
Reactivate a SIM card the was deactivated or unpause a SIM card that was automatically paused
|
|
1236
1238
|
|
|
@@ -1248,7 +1250,7 @@ Returns **[Promise](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Refe
|
|
|
1248
1250
|
|
|
1249
1251
|
### updateSIM
|
|
1250
1252
|
|
|
1251
|
-
[src/Particle.js:1331-1335](https://github.com/
|
|
1253
|
+
[src/Particle.js:1331-1335](https://github.com/spark/particle-api-js/blob/be140b28fba0636f389ec10a4fe492586de434c8/src/Particle.js#L1331-L1335 "Source code on GitHub")
|
|
1252
1254
|
|
|
1253
1255
|
Update SIM card data limit
|
|
1254
1256
|
|
|
@@ -1266,7 +1268,7 @@ Returns **[Promise](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Refe
|
|
|
1266
1268
|
|
|
1267
1269
|
### removeSIM
|
|
1268
1270
|
|
|
1269
|
-
[src/Particle.js:1347-1350](https://github.com/
|
|
1271
|
+
[src/Particle.js:1347-1350](https://github.com/spark/particle-api-js/blob/be140b28fba0636f389ec10a4fe492586de434c8/src/Particle.js#L1347-L1350 "Source code on GitHub")
|
|
1270
1272
|
|
|
1271
1273
|
Remove a SIM card from an account so it can be activated by a different account
|
|
1272
1274
|
|
|
@@ -1283,7 +1285,7 @@ Returns **[Promise](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Refe
|
|
|
1283
1285
|
|
|
1284
1286
|
### listBuildTargets
|
|
1285
1287
|
|
|
1286
|
-
[src/Particle.js:1361-1364](https://github.com/
|
|
1288
|
+
[src/Particle.js:1361-1364](https://github.com/spark/particle-api-js/blob/be140b28fba0636f389ec10a4fe492586de434c8/src/Particle.js#L1361-L1364 "Source code on GitHub")
|
|
1287
1289
|
|
|
1288
1290
|
List valid build targets to be used for compiling
|
|
1289
1291
|
|
|
@@ -1299,7 +1301,7 @@ Returns **[Promise](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Refe
|
|
|
1299
1301
|
|
|
1300
1302
|
### listLibraries
|
|
1301
1303
|
|
|
1302
|
-
[src/Particle.js:1390-1407](https://github.com/
|
|
1304
|
+
[src/Particle.js:1390-1407](https://github.com/spark/particle-api-js/blob/be140b28fba0636f389ec10a4fe492586de434c8/src/Particle.js#L1390-L1407 "Source code on GitHub")
|
|
1303
1305
|
|
|
1304
1306
|
List firmware libraries
|
|
1305
1307
|
|
|
@@ -1329,7 +1331,7 @@ Returns **[Promise](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Refe
|
|
|
1329
1331
|
|
|
1330
1332
|
### getLibrary
|
|
1331
1333
|
|
|
1332
|
-
[src/Particle.js:1423-1431](https://github.com/
|
|
1334
|
+
[src/Particle.js:1423-1431](https://github.com/spark/particle-api-js/blob/be140b28fba0636f389ec10a4fe492586de434c8/src/Particle.js#L1423-L1431 "Source code on GitHub")
|
|
1333
1335
|
|
|
1334
1336
|
Get firmware library details
|
|
1335
1337
|
|
|
@@ -1346,7 +1348,7 @@ Returns **[Promise](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Refe
|
|
|
1346
1348
|
|
|
1347
1349
|
### getLibraryVersions
|
|
1348
1350
|
|
|
1349
|
-
[src/Particle.js:1444-1452](https://github.com/
|
|
1351
|
+
[src/Particle.js:1444-1452](https://github.com/spark/particle-api-js/blob/be140b28fba0636f389ec10a4fe492586de434c8/src/Particle.js#L1444-L1452 "Source code on GitHub")
|
|
1350
1352
|
|
|
1351
1353
|
Firmware library details for each version
|
|
1352
1354
|
|
|
@@ -1364,7 +1366,7 @@ Returns **[Promise](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Refe
|
|
|
1364
1366
|
|
|
1365
1367
|
### contributeLibrary
|
|
1366
1368
|
|
|
1367
|
-
[src/Particle.js:1464-1477](https://github.com/
|
|
1369
|
+
[src/Particle.js:1464-1477](https://github.com/spark/particle-api-js/blob/be140b28fba0636f389ec10a4fe492586de434c8/src/Particle.js#L1464-L1477 "Source code on GitHub")
|
|
1368
1370
|
|
|
1369
1371
|
Contribute a new library version from a compressed archive
|
|
1370
1372
|
|
|
@@ -1381,7 +1383,7 @@ Returns **[Promise](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Refe
|
|
|
1381
1383
|
|
|
1382
1384
|
### publishLibrary
|
|
1383
1385
|
|
|
1384
|
-
[src/Particle.js:1488-1497](https://github.com/
|
|
1386
|
+
[src/Particle.js:1488-1497](https://github.com/spark/particle-api-js/blob/be140b28fba0636f389ec10a4fe492586de434c8/src/Particle.js#L1488-L1497 "Source code on GitHub")
|
|
1385
1387
|
|
|
1386
1388
|
Publish the latest version of a library to the public
|
|
1387
1389
|
|
|
@@ -1397,7 +1399,7 @@ Returns **[Promise](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Refe
|
|
|
1397
1399
|
|
|
1398
1400
|
### deleteLibrary
|
|
1399
1401
|
|
|
1400
|
-
[src/Particle.js:1509-1517](https://github.com/
|
|
1402
|
+
[src/Particle.js:1509-1517](https://github.com/spark/particle-api-js/blob/be140b28fba0636f389ec10a4fe492586de434c8/src/Particle.js#L1509-L1517 "Source code on GitHub")
|
|
1401
1403
|
|
|
1402
1404
|
Delete one version of a library or an entire private library
|
|
1403
1405
|
|
|
@@ -1414,7 +1416,7 @@ Returns **[Promise](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Refe
|
|
|
1414
1416
|
|
|
1415
1417
|
### downloadFile
|
|
1416
1418
|
|
|
1417
|
-
[src/Particle.js:1527-1529](https://github.com/
|
|
1419
|
+
[src/Particle.js:1527-1529](https://github.com/spark/particle-api-js/blob/be140b28fba0636f389ec10a4fe492586de434c8/src/Particle.js#L1527-L1529 "Source code on GitHub")
|
|
1418
1420
|
|
|
1419
1421
|
Download an external file that may not be on the API
|
|
1420
1422
|
|
|
@@ -1429,7 +1431,7 @@ Returns **[Promise](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Refe
|
|
|
1429
1431
|
|
|
1430
1432
|
### listOAuthClients
|
|
1431
1433
|
|
|
1432
|
-
[src/Particle.js:1540-1543](https://github.com/
|
|
1434
|
+
[src/Particle.js:1540-1543](https://github.com/spark/particle-api-js/blob/be140b28fba0636f389ec10a4fe492586de434c8/src/Particle.js#L1540-L1543 "Source code on GitHub")
|
|
1433
1435
|
|
|
1434
1436
|
List OAuth client created by the account
|
|
1435
1437
|
|
|
@@ -1445,7 +1447,7 @@ Returns **[Promise](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Refe
|
|
|
1445
1447
|
|
|
1446
1448
|
### createOAuthClient
|
|
1447
1449
|
|
|
1448
|
-
[src/Particle.js:1558-1562](https://github.com/
|
|
1450
|
+
[src/Particle.js:1558-1562](https://github.com/spark/particle-api-js/blob/be140b28fba0636f389ec10a4fe492586de434c8/src/Particle.js#L1558-L1562 "Source code on GitHub")
|
|
1449
1451
|
|
|
1450
1452
|
Create an OAuth client
|
|
1451
1453
|
|
|
@@ -1465,7 +1467,7 @@ Returns **[Promise](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Refe
|
|
|
1465
1467
|
|
|
1466
1468
|
### updateOAuthClient
|
|
1467
1469
|
|
|
1468
|
-
[src/Particle.js:1576-1580](https://github.com/
|
|
1470
|
+
[src/Particle.js:1576-1580](https://github.com/spark/particle-api-js/blob/be140b28fba0636f389ec10a4fe492586de434c8/src/Particle.js#L1576-L1580 "Source code on GitHub")
|
|
1469
1471
|
|
|
1470
1472
|
Update an OAuth client
|
|
1471
1473
|
|
|
@@ -1484,7 +1486,7 @@ Returns **[Promise](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Refe
|
|
|
1484
1486
|
|
|
1485
1487
|
### deleteOAuthClient
|
|
1486
1488
|
|
|
1487
|
-
[src/Particle.js:1592-1595](https://github.com/
|
|
1489
|
+
[src/Particle.js:1592-1595](https://github.com/spark/particle-api-js/blob/be140b28fba0636f389ec10a4fe492586de434c8/src/Particle.js#L1592-L1595 "Source code on GitHub")
|
|
1488
1490
|
|
|
1489
1491
|
Delete an OAuth client
|
|
1490
1492
|
|
|
@@ -1501,7 +1503,7 @@ Returns **[Promise](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Refe
|
|
|
1501
1503
|
|
|
1502
1504
|
### listProducts
|
|
1503
1505
|
|
|
1504
|
-
[src/Particle.js:1605-1607](https://github.com/
|
|
1506
|
+
[src/Particle.js:1605-1607](https://github.com/spark/particle-api-js/blob/be140b28fba0636f389ec10a4fe492586de434c8/src/Particle.js#L1605-L1607 "Source code on GitHub")
|
|
1505
1507
|
|
|
1506
1508
|
List products the account has access to
|
|
1507
1509
|
|
|
@@ -1516,7 +1518,7 @@ Returns **[Promise](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Refe
|
|
|
1516
1518
|
|
|
1517
1519
|
### getProduct
|
|
1518
1520
|
|
|
1519
|
-
[src/Particle.js:1618-1620](https://github.com/
|
|
1521
|
+
[src/Particle.js:1618-1620](https://github.com/spark/particle-api-js/blob/be140b28fba0636f389ec10a4fe492586de434c8/src/Particle.js#L1618-L1620 "Source code on GitHub")
|
|
1520
1522
|
|
|
1521
1523
|
Get detailed information about a product
|
|
1522
1524
|
|
|
@@ -1532,7 +1534,7 @@ Returns **[Promise](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Refe
|
|
|
1532
1534
|
|
|
1533
1535
|
### listProductFirmware
|
|
1534
1536
|
|
|
1535
|
-
[src/Particle.js:1631-1633](https://github.com/
|
|
1537
|
+
[src/Particle.js:1631-1633](https://github.com/spark/particle-api-js/blob/be140b28fba0636f389ec10a4fe492586de434c8/src/Particle.js#L1631-L1633 "Source code on GitHub")
|
|
1536
1538
|
|
|
1537
1539
|
List product firmware versions
|
|
1538
1540
|
|
|
@@ -1548,7 +1550,7 @@ Returns **[Promise](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Refe
|
|
|
1548
1550
|
|
|
1549
1551
|
### uploadProductFirmware
|
|
1550
1552
|
|
|
1551
|
-
[src/Particle.js:1649-1665](https://github.com/
|
|
1553
|
+
[src/Particle.js:1649-1665](https://github.com/spark/particle-api-js/blob/be140b28fba0636f389ec10a4fe492586de434c8/src/Particle.js#L1649-L1665 "Source code on GitHub")
|
|
1552
1554
|
|
|
1553
1555
|
List product firmware versions
|
|
1554
1556
|
|
|
@@ -1569,7 +1571,7 @@ Returns **[Promise](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Refe
|
|
|
1569
1571
|
|
|
1570
1572
|
### getProductFirmware
|
|
1571
1573
|
|
|
1572
|
-
[src/Particle.js:1677-1684](https://github.com/
|
|
1574
|
+
[src/Particle.js:1677-1684](https://github.com/spark/particle-api-js/blob/be140b28fba0636f389ec10a4fe492586de434c8/src/Particle.js#L1677-L1684 "Source code on GitHub")
|
|
1573
1575
|
|
|
1574
1576
|
Get information about a product firmware version
|
|
1575
1577
|
|
|
@@ -1586,7 +1588,7 @@ Returns **[Promise](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Refe
|
|
|
1586
1588
|
|
|
1587
1589
|
### updateProductFirmware
|
|
1588
1590
|
|
|
1589
|
-
[src/Particle.js:1698-1701](https://github.com/
|
|
1591
|
+
[src/Particle.js:1698-1701](https://github.com/spark/particle-api-js/blob/be140b28fba0636f389ec10a4fe492586de434c8/src/Particle.js#L1698-L1701 "Source code on GitHub")
|
|
1590
1592
|
|
|
1591
1593
|
Update information for a product firmware version
|
|
1592
1594
|
|
|
@@ -1605,7 +1607,7 @@ Returns **[Promise](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Refe
|
|
|
1605
1607
|
|
|
1606
1608
|
### downloadProductFirmware
|
|
1607
1609
|
|
|
1608
|
-
[src/Particle.js:1713-1722](https://github.com/
|
|
1610
|
+
[src/Particle.js:1713-1722](https://github.com/spark/particle-api-js/blob/be140b28fba0636f389ec10a4fe492586de434c8/src/Particle.js#L1713-L1722 "Source code on GitHub")
|
|
1609
1611
|
|
|
1610
1612
|
Download a product firmware binary
|
|
1611
1613
|
|
|
@@ -1622,7 +1624,7 @@ Returns **[Promise](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Refe
|
|
|
1622
1624
|
|
|
1623
1625
|
### releaseProductFirmware
|
|
1624
1626
|
|
|
1625
|
-
[src/Particle.js:1734-1737](https://github.com/
|
|
1627
|
+
[src/Particle.js:1734-1737](https://github.com/spark/particle-api-js/blob/be140b28fba0636f389ec10a4fe492586de434c8/src/Particle.js#L1734-L1737 "Source code on GitHub")
|
|
1626
1628
|
|
|
1627
1629
|
Release a product firmware version as the default version
|
|
1628
1630
|
|
|
@@ -1639,7 +1641,7 @@ Returns **[Promise](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Refe
|
|
|
1639
1641
|
|
|
1640
1642
|
### listTeamMembers
|
|
1641
1643
|
|
|
1642
|
-
[src/Particle.js:1748-1755](https://github.com/
|
|
1644
|
+
[src/Particle.js:1748-1755](https://github.com/spark/particle-api-js/blob/be140b28fba0636f389ec10a4fe492586de434c8/src/Particle.js#L1748-L1755 "Source code on GitHub")
|
|
1643
1645
|
|
|
1644
1646
|
List product team members
|
|
1645
1647
|
|
|
@@ -1655,7 +1657,7 @@ Returns **[Promise](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Refe
|
|
|
1655
1657
|
|
|
1656
1658
|
### inviteTeamMember
|
|
1657
1659
|
|
|
1658
|
-
[src/Particle.js:1767-1775](https://github.com/
|
|
1660
|
+
[src/Particle.js:1767-1775](https://github.com/spark/particle-api-js/blob/be140b28fba0636f389ec10a4fe492586de434c8/src/Particle.js#L1767-L1775 "Source code on GitHub")
|
|
1659
1661
|
|
|
1660
1662
|
Invite Particle user to a product team
|
|
1661
1663
|
|
|
@@ -1672,7 +1674,7 @@ Returns **[Promise](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Refe
|
|
|
1672
1674
|
|
|
1673
1675
|
### removeTeamMember
|
|
1674
1676
|
|
|
1675
|
-
[src/Particle.js:1787-1794](https://github.com/
|
|
1677
|
+
[src/Particle.js:1787-1794](https://github.com/spark/particle-api-js/blob/be140b28fba0636f389ec10a4fe492586de434c8/src/Particle.js#L1787-L1794 "Source code on GitHub")
|
|
1676
1678
|
|
|
1677
1679
|
Remove Particle user to a product team
|
|
1678
1680
|
|
|
@@ -1689,7 +1691,7 @@ Returns **[Promise](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Refe
|
|
|
1689
1691
|
|
|
1690
1692
|
### lookupSerialNumber
|
|
1691
1693
|
|
|
1692
|
-
[src/Particle.js:1805-1812](https://github.com/
|
|
1694
|
+
[src/Particle.js:1805-1812](https://github.com/spark/particle-api-js/blob/be140b28fba0636f389ec10a4fe492586de434c8/src/Particle.js#L1805-L1812 "Source code on GitHub")
|
|
1693
1695
|
|
|
1694
1696
|
Fetch details about a serial number
|
|
1695
1697
|
|
|
@@ -1705,7 +1707,7 @@ Returns **[Promise](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Refe
|
|
|
1705
1707
|
|
|
1706
1708
|
### createMeshNetwork
|
|
1707
1709
|
|
|
1708
|
-
[src/Particle.js:1825-1833](https://github.com/
|
|
1710
|
+
[src/Particle.js:1825-1833](https://github.com/spark/particle-api-js/blob/be140b28fba0636f389ec10a4fe492586de434c8/src/Particle.js#L1825-L1833 "Source code on GitHub")
|
|
1709
1711
|
|
|
1710
1712
|
Create a mesh network
|
|
1711
1713
|
|
|
@@ -1723,7 +1725,7 @@ Returns **[Promise](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Refe
|
|
|
1723
1725
|
|
|
1724
1726
|
### removeMeshNetwork
|
|
1725
1727
|
|
|
1726
|
-
[src/Particle.js:1844-1846](https://github.com/
|
|
1728
|
+
[src/Particle.js:1844-1846](https://github.com/spark/particle-api-js/blob/be140b28fba0636f389ec10a4fe492586de434c8/src/Particle.js#L1844-L1846 "Source code on GitHub")
|
|
1727
1729
|
|
|
1728
1730
|
Remove a mesh network.
|
|
1729
1731
|
|
|
@@ -1739,7 +1741,7 @@ Returns **[Promise](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Refe
|
|
|
1739
1741
|
|
|
1740
1742
|
### listMeshNetworks
|
|
1741
1743
|
|
|
1742
|
-
[src/Particle.js:1858-1861](https://github.com/
|
|
1744
|
+
[src/Particle.js:1858-1861](https://github.com/spark/particle-api-js/blob/be140b28fba0636f389ec10a4fe492586de434c8/src/Particle.js#L1858-L1861 "Source code on GitHub")
|
|
1743
1745
|
|
|
1744
1746
|
List all mesh networks
|
|
1745
1747
|
|
|
@@ -1756,7 +1758,7 @@ Returns **[Promise](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Refe
|
|
|
1756
1758
|
|
|
1757
1759
|
### getMeshNetwork
|
|
1758
1760
|
|
|
1759
|
-
[src/Particle.js:1872-1874](https://github.com/
|
|
1761
|
+
[src/Particle.js:1872-1874](https://github.com/spark/particle-api-js/blob/be140b28fba0636f389ec10a4fe492586de434c8/src/Particle.js#L1872-L1874 "Source code on GitHub")
|
|
1760
1762
|
|
|
1761
1763
|
Get information about a mesh network.
|
|
1762
1764
|
|
|
@@ -1772,7 +1774,7 @@ Returns **[Promise](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Refe
|
|
|
1772
1774
|
|
|
1773
1775
|
### updateMeshNetwork
|
|
1774
1776
|
|
|
1775
|
-
[src/Particle.js:1887-1895](https://github.com/
|
|
1777
|
+
[src/Particle.js:1887-1895](https://github.com/spark/particle-api-js/blob/be140b28fba0636f389ec10a4fe492586de434c8/src/Particle.js#L1887-L1895 "Source code on GitHub")
|
|
1776
1778
|
|
|
1777
1779
|
Modify a mesh network.
|
|
1778
1780
|
|
|
@@ -1790,7 +1792,7 @@ Returns **[Promise](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Refe
|
|
|
1790
1792
|
|
|
1791
1793
|
### addMeshNetworkDevice
|
|
1792
1794
|
|
|
1793
|
-
[src/Particle.js:1907-1916](https://github.com/
|
|
1795
|
+
[src/Particle.js:1907-1916](https://github.com/spark/particle-api-js/blob/be140b28fba0636f389ec10a4fe492586de434c8/src/Particle.js#L1907-L1916 "Source code on GitHub")
|
|
1794
1796
|
|
|
1795
1797
|
Add a device to a mesh network.
|
|
1796
1798
|
|
|
@@ -1807,7 +1809,7 @@ Returns **[Promise](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Refe
|
|
|
1807
1809
|
|
|
1808
1810
|
### removeMeshNetworkDevice
|
|
1809
1811
|
|
|
1810
|
-
[src/Particle.js:1928-1944](https://github.com/
|
|
1812
|
+
[src/Particle.js:1928-1944](https://github.com/spark/particle-api-js/blob/be140b28fba0636f389ec10a4fe492586de434c8/src/Particle.js#L1928-L1944 "Source code on GitHub")
|
|
1811
1813
|
|
|
1812
1814
|
Remove a device from a mesh network.
|
|
1813
1815
|
|
|
@@ -1824,7 +1826,7 @@ Returns **[Promise](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Refe
|
|
|
1824
1826
|
|
|
1825
1827
|
### listMeshNetworkDevices
|
|
1826
1828
|
|
|
1827
|
-
[src/Particle.js:1958-1967](https://github.com/
|
|
1829
|
+
[src/Particle.js:1958-1967](https://github.com/spark/particle-api-js/blob/be140b28fba0636f389ec10a4fe492586de434c8/src/Particle.js#L1958-L1967 "Source code on GitHub")
|
|
1828
1830
|
|
|
1829
1831
|
List all devices of a mesh network.
|
|
1830
1832
|
|
|
@@ -1843,7 +1845,7 @@ Returns **[Promise](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Refe
|
|
|
1843
1845
|
|
|
1844
1846
|
### getProductConfiguration
|
|
1845
1847
|
|
|
1846
|
-
[src/Particle.js:1978-1985](https://github.com/
|
|
1848
|
+
[src/Particle.js:1978-1985](https://github.com/spark/particle-api-js/blob/be140b28fba0636f389ec10a4fe492586de434c8/src/Particle.js#L1978-L1985 "Source code on GitHub")
|
|
1847
1849
|
|
|
1848
1850
|
Get product configuration
|
|
1849
1851
|
|
|
@@ -1859,7 +1861,7 @@ Returns **[Promise](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Refe
|
|
|
1859
1861
|
|
|
1860
1862
|
### getProductConfigurationSchema
|
|
1861
1863
|
|
|
1862
|
-
[src/Particle.js:1996-2004](https://github.com/
|
|
1864
|
+
[src/Particle.js:1996-2004](https://github.com/spark/particle-api-js/blob/be140b28fba0636f389ec10a4fe492586de434c8/src/Particle.js#L1996-L2004 "Source code on GitHub")
|
|
1863
1865
|
|
|
1864
1866
|
Get product configuration schema
|
|
1865
1867
|
|
|
@@ -1875,7 +1877,7 @@ Returns **[Promise](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Refe
|
|
|
1875
1877
|
|
|
1876
1878
|
### getProductDeviceConfiguration
|
|
1877
1879
|
|
|
1878
|
-
[src/Particle.js:2016-2023](https://github.com/
|
|
1880
|
+
[src/Particle.js:2016-2023](https://github.com/spark/particle-api-js/blob/be140b28fba0636f389ec10a4fe492586de434c8/src/Particle.js#L2016-L2023 "Source code on GitHub")
|
|
1879
1881
|
|
|
1880
1882
|
Get product device's configuration
|
|
1881
1883
|
|
|
@@ -1892,7 +1894,7 @@ Returns **[Promise](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Refe
|
|
|
1892
1894
|
|
|
1893
1895
|
### getProductDeviceConfigurationSchema
|
|
1894
1896
|
|
|
1895
|
-
[src/Particle.js:2035-2043](https://github.com/
|
|
1897
|
+
[src/Particle.js:2035-2043](https://github.com/spark/particle-api-js/blob/be140b28fba0636f389ec10a4fe492586de434c8/src/Particle.js#L2035-L2043 "Source code on GitHub")
|
|
1896
1898
|
|
|
1897
1899
|
Get product device's configuration schema
|
|
1898
1900
|
|
|
@@ -1909,7 +1911,7 @@ Returns **[Promise](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Refe
|
|
|
1909
1911
|
|
|
1910
1912
|
### setProductConfiguration
|
|
1911
1913
|
|
|
1912
|
-
[src/Particle.js:2055-2063](https://github.com/
|
|
1914
|
+
[src/Particle.js:2055-2063](https://github.com/spark/particle-api-js/blob/be140b28fba0636f389ec10a4fe492586de434c8/src/Particle.js#L2055-L2063 "Source code on GitHub")
|
|
1913
1915
|
|
|
1914
1916
|
Set product configuration
|
|
1915
1917
|
|
|
@@ -1926,7 +1928,7 @@ Returns **[Promise](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Refe
|
|
|
1926
1928
|
|
|
1927
1929
|
### setProductDeviceConfiguration
|
|
1928
1930
|
|
|
1929
|
-
[src/Particle.js:2076-2084](https://github.com/
|
|
1931
|
+
[src/Particle.js:2076-2084](https://github.com/spark/particle-api-js/blob/be140b28fba0636f389ec10a4fe492586de434c8/src/Particle.js#L2076-L2084 "Source code on GitHub")
|
|
1930
1932
|
|
|
1931
1933
|
Set product configuration for a specific device within the product
|
|
1932
1934
|
|
|
@@ -1944,7 +1946,7 @@ Returns **[Promise](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Refe
|
|
|
1944
1946
|
|
|
1945
1947
|
### getProductLocations
|
|
1946
1948
|
|
|
1947
|
-
[src/Particle.js:2103-2120](https://github.com/
|
|
1949
|
+
[src/Particle.js:2103-2120](https://github.com/spark/particle-api-js/blob/be140b28fba0636f389ec10a4fe492586de434c8/src/Particle.js#L2103-L2120 "Source code on GitHub")
|
|
1948
1950
|
|
|
1949
1951
|
Query location for devices within a product
|
|
1950
1952
|
|
|
@@ -1968,7 +1970,7 @@ Returns **[Promise](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Refe
|
|
|
1968
1970
|
|
|
1969
1971
|
### getProductDeviceLocations
|
|
1970
1972
|
|
|
1971
|
-
[src/Particle.js:2137-2149](https://github.com/
|
|
1973
|
+
[src/Particle.js:2137-2149](https://github.com/spark/particle-api-js/blob/be140b28fba0636f389ec10a4fe492586de434c8/src/Particle.js#L2137-L2149 "Source code on GitHub")
|
|
1972
1974
|
|
|
1973
1975
|
Query location for one device within a product
|
|
1974
1976
|
|
|
@@ -1988,7 +1990,7 @@ Returns **[Promise](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Refe
|
|
|
1988
1990
|
|
|
1989
1991
|
### executeLogic
|
|
1990
1992
|
|
|
1991
|
-
[src/Particle.js:2165-2173](https://github.com/
|
|
1993
|
+
[src/Particle.js:2165-2173](https://github.com/spark/particle-api-js/blob/be140b28fba0636f389ec10a4fe492586de434c8/src/Particle.js#L2165-L2173 "Source code on GitHub")
|
|
1992
1994
|
|
|
1993
1995
|
Executes the provided logic function once and returns the result. No logs, runs, etc are saved
|
|
1994
1996
|
|
|
@@ -2007,7 +2009,7 @@ Returns **[Promise](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Refe
|
|
|
2007
2009
|
|
|
2008
2010
|
### createLogicFunction
|
|
2009
2011
|
|
|
2010
|
-
[src/Particle.js:2193-2201](https://github.com/
|
|
2012
|
+
[src/Particle.js:2193-2201](https://github.com/spark/particle-api-js/blob/be140b28fba0636f389ec10a4fe492586de434c8/src/Particle.js#L2193-L2201 "Source code on GitHub")
|
|
2011
2013
|
|
|
2012
2014
|
Creates a new logic function in the specified organization or sandbox using the provided function data.
|
|
2013
2015
|
|
|
@@ -2030,7 +2032,7 @@ Returns **[Promise](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Refe
|
|
|
2030
2032
|
|
|
2031
2033
|
### getLogicFunction
|
|
2032
2034
|
|
|
2033
|
-
[src/Particle.js:2215-2222](https://github.com/
|
|
2035
|
+
[src/Particle.js:2215-2222](https://github.com/spark/particle-api-js/blob/be140b28fba0636f389ec10a4fe492586de434c8/src/Particle.js#L2215-L2222 "Source code on GitHub")
|
|
2034
2036
|
|
|
2035
2037
|
Get a logic function in the specified organization or sandbox by logic function ID.
|
|
2036
2038
|
|
|
@@ -2047,7 +2049,7 @@ Returns **[Promise](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Refe
|
|
|
2047
2049
|
|
|
2048
2050
|
### updateLogicFunction
|
|
2049
2051
|
|
|
2050
|
-
[src/Particle.js:2239-2247](https://github.com/
|
|
2052
|
+
[src/Particle.js:2239-2247](https://github.com/spark/particle-api-js/blob/be140b28fba0636f389ec10a4fe492586de434c8/src/Particle.js#L2239-L2247 "Source code on GitHub")
|
|
2051
2053
|
|
|
2052
2054
|
Updates an existing logic function in the specified organization or sandbox using the provided function data.
|
|
2053
2055
|
|
|
@@ -2067,7 +2069,7 @@ Returns **[Promise](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Refe
|
|
|
2067
2069
|
|
|
2068
2070
|
### deleteLogicFunction
|
|
2069
2071
|
|
|
2070
|
-
[src/Particle.js:2261-2268](https://github.com/
|
|
2072
|
+
[src/Particle.js:2261-2268](https://github.com/spark/particle-api-js/blob/be140b28fba0636f389ec10a4fe492586de434c8/src/Particle.js#L2261-L2268 "Source code on GitHub")
|
|
2071
2073
|
|
|
2072
2074
|
Deletes a logic function in the specified organization or sandbox by logic function ID.
|
|
2073
2075
|
|
|
@@ -2084,7 +2086,7 @@ Returns **[Promise](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Refe
|
|
|
2084
2086
|
|
|
2085
2087
|
### listLogicFunctions
|
|
2086
2088
|
|
|
2087
|
-
[src/Particle.js:2282-2292](https://github.com/
|
|
2089
|
+
[src/Particle.js:2282-2292](https://github.com/spark/particle-api-js/blob/be140b28fba0636f389ec10a4fe492586de434c8/src/Particle.js#L2282-L2292 "Source code on GitHub")
|
|
2088
2090
|
|
|
2089
2091
|
Lists all logic functions in the specified organization or sandbox.
|
|
2090
2092
|
|
|
@@ -2101,7 +2103,7 @@ Returns **[Promise](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Refe
|
|
|
2101
2103
|
|
|
2102
2104
|
### listLogicRuns
|
|
2103
2105
|
|
|
2104
|
-
[src/Particle.js:2306-2313](https://github.com/
|
|
2106
|
+
[src/Particle.js:2306-2313](https://github.com/spark/particle-api-js/blob/be140b28fba0636f389ec10a4fe492586de434c8/src/Particle.js#L2306-L2313 "Source code on GitHub")
|
|
2105
2107
|
|
|
2106
2108
|
Lists all logic runs for the specified logic function in the specified organization or sandbox.
|
|
2107
2109
|
|
|
@@ -2118,7 +2120,7 @@ Returns **[Promise](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Refe
|
|
|
2118
2120
|
|
|
2119
2121
|
### getLogicRun
|
|
2120
2122
|
|
|
2121
|
-
[src/Particle.js:2328-2335](https://github.com/
|
|
2123
|
+
[src/Particle.js:2328-2335](https://github.com/spark/particle-api-js/blob/be140b28fba0636f389ec10a4fe492586de434c8/src/Particle.js#L2328-L2335 "Source code on GitHub")
|
|
2122
2124
|
|
|
2123
2125
|
Retrieves a logic run by its ID for the specified logic function in the specified organization or sandbox.
|
|
2124
2126
|
|
|
@@ -2136,7 +2138,7 @@ Returns **[Promise](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Refe
|
|
|
2136
2138
|
|
|
2137
2139
|
### getLogicRunLogs
|
|
2138
2140
|
|
|
2139
|
-
[src/Particle.js:2350-2357](https://github.com/
|
|
2141
|
+
[src/Particle.js:2350-2357](https://github.com/spark/particle-api-js/blob/be140b28fba0636f389ec10a4fe492586de434c8/src/Particle.js#L2350-L2357 "Source code on GitHub")
|
|
2140
2142
|
|
|
2141
2143
|
Retrieves the logs for a logic run by its ID for the specified logic function in the specified organization or sandbox.
|
|
2142
2144
|
|
|
@@ -2154,7 +2156,7 @@ Returns **[Promise](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Refe
|
|
|
2154
2156
|
|
|
2155
2157
|
### createLedger
|
|
2156
2158
|
|
|
2157
|
-
[src/Particle.js:2371-2379](https://github.com/
|
|
2159
|
+
[src/Particle.js:2371-2379](https://github.com/spark/particle-api-js/blob/be140b28fba0636f389ec10a4fe492586de434c8/src/Particle.js#L2371-L2379 "Source code on GitHub")
|
|
2158
2160
|
|
|
2159
2161
|
Creates a new ledger definition in the specified organization or sandbox.
|
|
2160
2162
|
|
|
@@ -2171,7 +2173,7 @@ Returns **[Promise](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Refe
|
|
|
2171
2173
|
|
|
2172
2174
|
### getLedger
|
|
2173
2175
|
|
|
2174
|
-
[src/Particle.js:2393-2400](https://github.com/
|
|
2176
|
+
[src/Particle.js:2393-2400](https://github.com/spark/particle-api-js/blob/be140b28fba0636f389ec10a4fe492586de434c8/src/Particle.js#L2393-L2400 "Source code on GitHub")
|
|
2175
2177
|
|
|
2176
2178
|
Get a ledger definition in the specified organization or sandbox by ledger name.
|
|
2177
2179
|
|
|
@@ -2188,7 +2190,7 @@ Returns **[Promise](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Refe
|
|
|
2188
2190
|
|
|
2189
2191
|
### updateLedger
|
|
2190
2192
|
|
|
2191
|
-
[src/Particle.js:2415-2423](https://github.com/
|
|
2193
|
+
[src/Particle.js:2415-2423](https://github.com/spark/particle-api-js/blob/be140b28fba0636f389ec10a4fe492586de434c8/src/Particle.js#L2415-L2423 "Source code on GitHub")
|
|
2192
2194
|
|
|
2193
2195
|
Updates an existing ledger definition in the specified organization or sandbox.
|
|
2194
2196
|
|
|
@@ -2206,7 +2208,7 @@ Returns **[Promise](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Refe
|
|
|
2206
2208
|
|
|
2207
2209
|
### archiveLedger
|
|
2208
2210
|
|
|
2209
|
-
[src/Particle.js:2437-2444](https://github.com/
|
|
2211
|
+
[src/Particle.js:2437-2444](https://github.com/spark/particle-api-js/blob/be140b28fba0636f389ec10a4fe492586de434c8/src/Particle.js#L2437-L2444 "Source code on GitHub")
|
|
2210
2212
|
|
|
2211
2213
|
Archives a ledger definition in the specified organization or sandbox by ledger name.
|
|
2212
2214
|
|
|
@@ -2223,7 +2225,7 @@ Returns **[Promise](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Refe
|
|
|
2223
2225
|
|
|
2224
2226
|
### Scope
|
|
2225
2227
|
|
|
2226
|
-
[src/Particle.js:2465-2478](https://github.com/
|
|
2228
|
+
[src/Particle.js:2465-2478](https://github.com/spark/particle-api-js/blob/be140b28fba0636f389ec10a4fe492586de434c8/src/Particle.js#L2465-L2478 "Source code on GitHub")
|
|
2227
2229
|
|
|
2228
2230
|
Type: (`"Owner"` \| `"Product"` \| `"Device"`)
|
|
2229
2231
|
|
|
@@ -2241,7 +2243,7 @@ Type: (`"Owner"` \| `"Product"` \| `"Device"`)
|
|
|
2241
2243
|
|
|
2242
2244
|
### listLedgers
|
|
2243
2245
|
|
|
2244
|
-
[src/Particle.js:2465-2478](https://github.com/
|
|
2246
|
+
[src/Particle.js:2465-2478](https://github.com/spark/particle-api-js/blob/be140b28fba0636f389ec10a4fe492586de434c8/src/Particle.js#L2465-L2478 "Source code on GitHub")
|
|
2245
2247
|
|
|
2246
2248
|
Lists all ledger definitions in the specified organization or sandbox.
|
|
2247
2249
|
|
|
@@ -2261,7 +2263,7 @@ Returns **[Promise](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Refe
|
|
|
2261
2263
|
|
|
2262
2264
|
### getLedgerInstance
|
|
2263
2265
|
|
|
2264
|
-
[src/Particle.js:2493-2500](https://github.com/
|
|
2266
|
+
[src/Particle.js:2493-2500](https://github.com/spark/particle-api-js/blob/be140b28fba0636f389ec10a4fe492586de434c8/src/Particle.js#L2493-L2500 "Source code on GitHub")
|
|
2265
2267
|
|
|
2266
2268
|
Get ledger instance data.
|
|
2267
2269
|
|
|
@@ -2279,7 +2281,7 @@ Returns **[Promise](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Refe
|
|
|
2279
2281
|
|
|
2280
2282
|
### SetMode
|
|
2281
2283
|
|
|
2282
|
-
[src/Particle.js:2521-2532](https://github.com/
|
|
2284
|
+
[src/Particle.js:2521-2532](https://github.com/spark/particle-api-js/blob/be140b28fba0636f389ec10a4fe492586de434c8/src/Particle.js#L2521-L2532 "Source code on GitHub")
|
|
2283
2285
|
|
|
2284
2286
|
Type: (`"Replace"` \| `"Merge"`)
|
|
2285
2287
|
|
|
@@ -2297,7 +2299,7 @@ Type: (`"Replace"` \| `"Merge"`)
|
|
|
2297
2299
|
|
|
2298
2300
|
### setLedgerInstance
|
|
2299
2301
|
|
|
2300
|
-
[src/Particle.js:2521-2532](https://github.com/
|
|
2302
|
+
[src/Particle.js:2521-2532](https://github.com/spark/particle-api-js/blob/be140b28fba0636f389ec10a4fe492586de434c8/src/Particle.js#L2521-L2532 "Source code on GitHub")
|
|
2301
2303
|
|
|
2302
2304
|
Set ledger instance data.
|
|
2303
2305
|
|
|
@@ -2317,7 +2319,7 @@ Returns **[Promise](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Refe
|
|
|
2317
2319
|
|
|
2318
2320
|
### deleteLedgerInstance
|
|
2319
2321
|
|
|
2320
|
-
[src/Particle.js:2547-2554](https://github.com/
|
|
2322
|
+
[src/Particle.js:2547-2554](https://github.com/spark/particle-api-js/blob/be140b28fba0636f389ec10a4fe492586de434c8/src/Particle.js#L2547-L2554 "Source code on GitHub")
|
|
2321
2323
|
|
|
2322
2324
|
Delete a ledger instance in the specified organization or sandbox by ledger name.
|
|
2323
2325
|
|
|
@@ -2335,7 +2337,7 @@ Returns **[Promise](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Refe
|
|
|
2335
2337
|
|
|
2336
2338
|
### listLedgerInstances
|
|
2337
2339
|
|
|
2338
|
-
[src/Particle.js:2570-2581](https://github.com/
|
|
2340
|
+
[src/Particle.js:2570-2581](https://github.com/spark/particle-api-js/blob/be140b28fba0636f389ec10a4fe492586de434c8/src/Particle.js#L2570-L2581 "Source code on GitHub")
|
|
2339
2341
|
|
|
2340
2342
|
Lists ledger instances in the specified organization or sandbox.
|
|
2341
2343
|
|
|
@@ -2354,7 +2356,7 @@ Returns **[Promise](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Refe
|
|
|
2354
2356
|
|
|
2355
2357
|
### listLedgerInstanceVersions
|
|
2356
2358
|
|
|
2357
|
-
[src/Particle.js:2598-2609](https://github.com/
|
|
2359
|
+
[src/Particle.js:2598-2609](https://github.com/spark/particle-api-js/blob/be140b28fba0636f389ec10a4fe492586de434c8/src/Particle.js#L2598-L2609 "Source code on GitHub")
|
|
2358
2360
|
|
|
2359
2361
|
List ledger instance versions
|
|
2360
2362
|
|
|
@@ -2374,7 +2376,7 @@ Returns **[Promise](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Refe
|
|
|
2374
2376
|
|
|
2375
2377
|
### getLedgerInstanceVersion
|
|
2376
2378
|
|
|
2377
|
-
[src/Particle.js:2625-2632](https://github.com/
|
|
2379
|
+
[src/Particle.js:2625-2632](https://github.com/spark/particle-api-js/blob/be140b28fba0636f389ec10a4fe492586de434c8/src/Particle.js#L2625-L2632 "Source code on GitHub")
|
|
2378
2380
|
|
|
2379
2381
|
Get specific ledger instance version
|
|
2380
2382
|
|
|
@@ -2391,9 +2393,45 @@ Get specific ledger instance version
|
|
|
2391
2393
|
|
|
2392
2394
|
Returns **[Promise](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Promise)<RequestResponse>** A promise that resolves to the specified ledger instance data.
|
|
2393
2395
|
|
|
2396
|
+
### listDeviceOsVersions
|
|
2397
|
+
|
|
2398
|
+
[src/Particle.js:2648-2663](https://github.com/spark/particle-api-js/blob/be140b28fba0636f389ec10a4fe492586de434c8/src/Particle.js#L2648-L2663 "Source code on GitHub")
|
|
2399
|
+
|
|
2400
|
+
List Device OS versions
|
|
2401
|
+
|
|
2402
|
+
**Parameters**
|
|
2403
|
+
|
|
2404
|
+
- `options` **[Object](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Object)** Options for this API call
|
|
2405
|
+
- `options.platformId` **[Number](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Number)?** Platform ID to filter Device OS versions
|
|
2406
|
+
- `options.internalVersion` **[Number](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Number)?** Internal version number to filter Device OS versions
|
|
2407
|
+
- `options.page` **[Number](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Number)?** Page number for pagination
|
|
2408
|
+
- `options.perPage` **[Number](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Number)?** Number of items per page
|
|
2409
|
+
- `options.auth` **Auth?** The access token or basic auth object. Can be ignored if provided in constructor
|
|
2410
|
+
- `options.headers` **[Object](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Object)?** Key/Value pairs like `{ 'X-FOO': 'foo', X-BAR: 'bar' }` to send as headers.
|
|
2411
|
+
- `options.context` **[Object](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Object)?** Request context
|
|
2412
|
+
|
|
2413
|
+
Returns **[Promise](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Promise)<RequestResponse>** A promise that resolves to the list of Device OS versions.
|
|
2414
|
+
|
|
2415
|
+
### getDeviceOsVersion
|
|
2416
|
+
|
|
2417
|
+
[src/Particle.js:2677-2686](https://github.com/spark/particle-api-js/blob/be140b28fba0636f389ec10a4fe492586de434c8/src/Particle.js#L2677-L2686 "Source code on GitHub")
|
|
2418
|
+
|
|
2419
|
+
Get a specific Device OS version
|
|
2420
|
+
|
|
2421
|
+
**Parameters**
|
|
2422
|
+
|
|
2423
|
+
- `options` **[Object](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Object)** Options for this API call
|
|
2424
|
+
- `options.version` **[String](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/String)** Version of the Device OS
|
|
2425
|
+
- `options.platformId` **[Number](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Number)?** Optional platform ID to filter Device OS version
|
|
2426
|
+
- `options.auth` **Auth?** The access token or basic auth object. Can be ignored if provided in constructor
|
|
2427
|
+
- `options.headers` **[Object](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Object)?** Key/Value pairs like `{ 'X-FOO': 'foo', X-BAR: 'bar' }` to send as headers.
|
|
2428
|
+
- `options.context` **[Object](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Object)?** Request context
|
|
2429
|
+
|
|
2430
|
+
Returns **[Promise](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Promise)<RequestResponse>** A promise that resolves to the specified Device OS version data.
|
|
2431
|
+
|
|
2394
2432
|
### setDefaultAuth
|
|
2395
2433
|
|
|
2396
|
-
[src/Particle.js:
|
|
2434
|
+
[src/Particle.js:2693-2701](https://github.com/spark/particle-api-js/blob/be140b28fba0636f389ec10a4fe492586de434c8/src/Particle.js#L2693-L2701 "Source code on GitHub")
|
|
2397
2435
|
|
|
2398
2436
|
Set default auth token that will be used in each method if `auth` is not provided
|
|
2399
2437
|
|
|
@@ -2406,7 +2444,7 @@ Set default auth token that will be used in each method if `auth` is not provide
|
|
|
2406
2444
|
|
|
2407
2445
|
### get
|
|
2408
2446
|
|
|
2409
|
-
[src/Particle.js:
|
|
2447
|
+
[src/Particle.js:2751-2755](https://github.com/spark/particle-api-js/blob/be140b28fba0636f389ec10a4fe492586de434c8/src/Particle.js#L2751-L2755 "Source code on GitHub")
|
|
2410
2448
|
|
|
2411
2449
|
Make a GET request
|
|
2412
2450
|
|
|
@@ -2423,7 +2461,7 @@ Returns **[Promise](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Refe
|
|
|
2423
2461
|
|
|
2424
2462
|
### head
|
|
2425
2463
|
|
|
2426
|
-
[src/Particle.js:
|
|
2464
|
+
[src/Particle.js:2767-2771](https://github.com/spark/particle-api-js/blob/be140b28fba0636f389ec10a4fe492586de434c8/src/Particle.js#L2767-L2771 "Source code on GitHub")
|
|
2427
2465
|
|
|
2428
2466
|
Make a HEAD request
|
|
2429
2467
|
|
|
@@ -2440,7 +2478,7 @@ Returns **[Promise](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Refe
|
|
|
2440
2478
|
|
|
2441
2479
|
### post
|
|
2442
2480
|
|
|
2443
|
-
[src/Particle.js:
|
|
2481
|
+
[src/Particle.js:2783-2787](https://github.com/spark/particle-api-js/blob/be140b28fba0636f389ec10a4fe492586de434c8/src/Particle.js#L2783-L2787 "Source code on GitHub")
|
|
2444
2482
|
|
|
2445
2483
|
Make a POST request
|
|
2446
2484
|
|
|
@@ -2457,7 +2495,7 @@ Returns **[Promise](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Refe
|
|
|
2457
2495
|
|
|
2458
2496
|
### put
|
|
2459
2497
|
|
|
2460
|
-
[src/Particle.js:
|
|
2498
|
+
[src/Particle.js:2800-2804](https://github.com/spark/particle-api-js/blob/be140b28fba0636f389ec10a4fe492586de434c8/src/Particle.js#L2800-L2804 "Source code on GitHub")
|
|
2461
2499
|
|
|
2462
2500
|
Make a PUT request
|
|
2463
2501
|
|
|
@@ -2475,7 +2513,7 @@ Returns **[Promise](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Refe
|
|
|
2475
2513
|
|
|
2476
2514
|
### delete
|
|
2477
2515
|
|
|
2478
|
-
[src/Particle.js:
|
|
2516
|
+
[src/Particle.js:2816-2820](https://github.com/spark/particle-api-js/blob/be140b28fba0636f389ec10a4fe492586de434c8/src/Particle.js#L2816-L2820 "Source code on GitHub")
|
|
2479
2517
|
|
|
2480
2518
|
Make a DELETE request
|
|
2481
2519
|
|
|
@@ -2492,7 +2530,7 @@ Returns **[Promise](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Refe
|
|
|
2492
2530
|
|
|
2493
2531
|
### request
|
|
2494
2532
|
|
|
2495
|
-
[src/Particle.js:
|
|
2533
|
+
[src/Particle.js:2837-2841](https://github.com/spark/particle-api-js/blob/be140b28fba0636f389ec10a4fe492586de434c8/src/Particle.js#L2837-L2841 "Source code on GitHub")
|
|
2496
2534
|
|
|
2497
2535
|
**Parameters**
|
|
2498
2536
|
|