losant_rest 1.16.5 → 1.16.6
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.
- checksums.yaml +4 -4
- data/docs/_schemas.md +578 -283
- data/docs/dataTableRows.md +1 -1
- data/docs/device.md +4 -4
- data/docs/deviceRecipe.md +4 -0
- data/docs/deviceRecipes.md +4 -0
- data/docs/devices.md +4 -4
- data/docs/embeddedDeployments.md +1 -1
- data/docs/notebook.md +44 -1
- data/docs/notebooks.md +1 -1
- data/lib/losant_rest/client.rb +2 -2
- data/lib/losant_rest/data_table_rows.rb +1 -1
- data/lib/losant_rest/device.rb +4 -4
- data/lib/losant_rest/device_recipe.rb +8 -0
- data/lib/losant_rest/device_recipes.rb +8 -0
- data/lib/losant_rest/devices.rb +4 -4
- data/lib/losant_rest/embedded_deployments.rb +1 -1
- data/lib/losant_rest/notebook.rb +50 -1
- data/lib/losant_rest/notebooks.rb +1 -1
- data/lib/losant_rest/version.rb +1 -1
- data/schemas/advancedApplicationKeyQuery.json +1 -1
- data/schemas/advancedDeviceQuery.json +1 -1
- data/schemas/advancedEventQuery.json +1 -1
- data/schemas/advancedFlowByVersionQuery.json +1 -1
- data/schemas/advancedFlowQuery.json +1 -1
- data/schemas/advancedFlowVersionQuery.json +1 -1
- data/schemas/advancedQuery.json +1 -1
- data/schemas/apiToken.json +1 -1
- data/schemas/apiTokenPatch.json +1 -1
- data/schemas/apiTokenPost.json +1 -1
- data/schemas/apiTokens.json +1 -1
- data/schemas/application.json +1 -1
- data/schemas/applicationApplyTemplatePatch.json +1 -1
- data/schemas/applicationCertificate.json +1 -1
- data/schemas/applicationCertificateAuthorities.json +1 -1
- data/schemas/applicationCertificateAuthority.json +1 -1
- data/schemas/applicationCertificateAuthorityPatch.json +1 -1
- data/schemas/applicationCertificateAuthorityPost.json +1 -1
- data/schemas/applicationCertificatePatch.json +1 -1
- data/schemas/applicationCertificatePost.json +1 -1
- data/schemas/applicationCertificates.json +1 -1
- data/schemas/applicationCloneDryRunResult.json +1 -1
- data/schemas/applicationClonePost.json +5 -1
- data/schemas/applicationCreationByTemplateResult.json +1 -1
- data/schemas/applicationDashboardPost.json +33 -2
- data/schemas/applicationExportPost.json +1 -1
- data/schemas/applicationExportResult.json +1 -1
- data/schemas/applicationGlobalPatch.json +1 -1
- data/schemas/applicationKey.json +1 -1
- data/schemas/applicationKeyPatch.json +1 -1
- data/schemas/applicationKeyPost.json +1 -1
- data/schemas/applicationKeyPostResponse.json +1 -1
- data/schemas/applicationKeys.json +1 -1
- data/schemas/applicationPatch.json +1 -1
- data/schemas/applicationPost.json +1 -1
- data/schemas/applicationReadme.json +1 -1
- data/schemas/applicationReadmePatch.json +1 -1
- data/schemas/applicationSearchResult.json +1 -1
- data/schemas/applicationTemplate.json +1 -1
- data/schemas/applicationTemplateCategories.json +1 -1
- data/schemas/applicationTemplateCategory.json +1 -1
- data/schemas/applicationTemplates.json +1 -1
- data/schemas/applications.json +1 -1
- data/schemas/attributeNamesResponse.json +1 -1
- data/schemas/auditLog.json +1 -1
- data/schemas/auditLogFilter.json +1 -1
- data/schemas/auditLogs.json +1 -1
- data/schemas/authedDevice.json +1 -1
- data/schemas/authedUser.json +1 -1
- data/schemas/bulkDeleteResponse.json +1 -1
- data/schemas/changePassword.json +1 -1
- data/schemas/compositeDeviceState.json +1 -1
- data/schemas/dashboard.json +33 -2
- data/schemas/dashboardContextInstance.json +1 -1
- data/schemas/dashboardPatch.json +33 -2
- data/schemas/dashboardPost.json +33 -2
- data/schemas/dashboardSendReport.json +33 -2
- data/schemas/dashboardUpdateEvents.json +1 -1
- data/schemas/dashboards.json +33 -2
- data/schemas/dataExport.json +1 -1
- data/schemas/dataTable.json +1 -1
- data/schemas/dataTableColumn.json +1 -1
- data/schemas/dataTablePatch.json +1 -1
- data/schemas/dataTablePost.json +1 -1
- data/schemas/dataTableRow.json +1 -1
- data/schemas/dataTableRowInMultiple.json +1 -1
- data/schemas/dataTableRowInsert.json +1 -1
- data/schemas/dataTableRowInsertResult.json +1 -1
- data/schemas/dataTableRowInsertUpdate.json +1 -1
- data/schemas/dataTableRows.json +1 -1
- data/schemas/dataTableRowsDelete.json +1 -1
- data/schemas/dataTableRowsExport.json +1 -1
- data/schemas/dataTables.json +1 -1
- data/schemas/device.json +1 -1
- data/schemas/deviceAttributeDataTypeFilter.json +1 -1
- data/schemas/deviceClassFilter.json +1 -1
- data/schemas/deviceCommand.json +1 -1
- data/schemas/deviceCommands.json +1 -1
- data/schemas/deviceConnectionStatus.json +1 -1
- data/schemas/deviceCredentials.json +1 -1
- data/schemas/deviceLog.json +1 -1
- data/schemas/deviceNamesResponse.json +1 -1
- data/schemas/devicePatch.json +1 -1
- data/schemas/devicePayloadCounts.json +1 -1
- data/schemas/devicePost.json +1 -1
- data/schemas/deviceRecipe.json +1 -1
- data/schemas/deviceRecipeBulkCreate.json +1 -1
- data/schemas/deviceRecipeBulkCreateEnqueued.json +5 -1
- data/schemas/deviceRecipeBulkCreatePost.json +1 -1
- data/schemas/deviceRecipePatch.json +1 -1
- data/schemas/deviceRecipePost.json +1 -1
- data/schemas/deviceRecipes.json +1 -1
- data/schemas/deviceState.json +1 -1
- data/schemas/deviceStateOrStates.json +1 -1
- data/schemas/deviceStates.json +1 -1
- data/schemas/deviceTagFilter.json +1 -1
- data/schemas/devices.json +1 -1
- data/schemas/devicesDataRemoved.json +1 -1
- data/schemas/devicesDeletePost.json +1 -1
- data/schemas/devicesExportPayloadCountPost.json +1 -1
- data/schemas/devicesExportPost.json +1 -1
- data/schemas/devicesPatch.json +1 -1
- data/schemas/devicesRemoveDataPost.json +1 -1
- data/schemas/devicesUpdated.json +1 -1
- data/schemas/disableTwoFactorAuth.json +1 -1
- data/schemas/edgeDeployment.json +1 -1
- data/schemas/edgeDeploymentRelease.json +1 -1
- data/schemas/edgeDeploymentRemove.json +1 -1
- data/schemas/edgeDeploymentReplace.json +1 -1
- data/schemas/edgeDeployments.json +1 -1
- data/schemas/emailVerificationVerify.json +1 -1
- data/schemas/embeddedDeployment.json +1 -1
- data/schemas/embeddedDeploymentExport.json +1 -1
- data/schemas/embeddedDeploymentRelease.json +1 -1
- data/schemas/embeddedDeploymentRemove.json +1 -1
- data/schemas/embeddedDeploymentReplace.json +1 -1
- data/schemas/embeddedDeployments.json +1 -1
- data/schemas/enableTwoFactorAuth.json +1 -1
- data/schemas/error.json +1 -1
- data/schemas/event.json +1 -1
- data/schemas/eventPatch.json +1 -1
- data/schemas/eventPost.json +1 -1
- data/schemas/eventTagsSummary.json +1 -1
- data/schemas/events.json +1 -1
- data/schemas/eventsDeleted.json +1 -1
- data/schemas/eventsExport.json +1 -1
- data/schemas/experienceBootstrapOptions.json +1 -1
- data/schemas/experienceBootstrapResult.json +1 -1
- data/schemas/experienceDomain.json +1 -1
- data/schemas/experienceDomainPatch.json +1 -1
- data/schemas/experienceDomainPost.json +1 -1
- data/schemas/experienceDomains.json +1 -1
- data/schemas/experienceEndpoint.json +1 -1
- data/schemas/experienceEndpointPatch.json +1 -1
- data/schemas/experienceEndpointPost.json +1 -1
- data/schemas/experienceEndpointStats.json +1 -1
- data/schemas/experienceEndpoints.json +1 -1
- data/schemas/experienceGroup.json +1 -1
- data/schemas/experienceGroupPatch.json +1 -1
- data/schemas/experienceGroupPost.json +1 -1
- data/schemas/experienceGroups.json +1 -1
- data/schemas/experienceLinkedResources.json +1 -1
- data/schemas/experienceSlug.json +1 -1
- data/schemas/experienceSlugPatch.json +1 -1
- data/schemas/experienceSlugPost.json +1 -1
- data/schemas/experienceSlugs.json +1 -1
- data/schemas/experienceUser.json +1 -1
- data/schemas/experienceUserPatch.json +1 -1
- data/schemas/experienceUserPost.json +1 -1
- data/schemas/experienceUsers.json +1 -1
- data/schemas/experienceVersion.json +1 -1
- data/schemas/experienceVersionPatch.json +1 -1
- data/schemas/experienceVersionPost.json +1 -1
- data/schemas/experienceVersions.json +1 -1
- data/schemas/experienceView.json +1 -1
- data/schemas/experienceViewPatch.json +1 -1
- data/schemas/experienceViewPost.json +1 -1
- data/schemas/experienceViews.json +1 -1
- data/schemas/file.json +1 -1
- data/schemas/filePatch.json +1 -1
- data/schemas/filePost.json +1 -1
- data/schemas/fileUploadPostResponse.json +1 -1
- data/schemas/files.json +1 -1
- data/schemas/flow.json +1 -1
- data/schemas/flowErrors.json +1 -1
- data/schemas/flowLog.json +1 -1
- data/schemas/flowPatch.json +1 -1
- data/schemas/flowPost.json +1 -1
- data/schemas/flowStats.json +1 -1
- data/schemas/flowStorageEntries.json +1 -1
- data/schemas/flowStorageEntry.json +1 -1
- data/schemas/flowStorageMetadata.json +1 -1
- data/schemas/flowTriggerFilter.json +1 -1
- data/schemas/flowVersion.json +1 -1
- data/schemas/flowVersionPatch.json +1 -1
- data/schemas/flowVersionPost.json +1 -1
- data/schemas/flowVersions.json +1 -1
- data/schemas/flowVersionsDeletePost.json +1 -1
- data/schemas/flows.json +1 -1
- data/schemas/flowsImportPost.json +1 -1
- data/schemas/flowsImportResult.json +1 -1
- data/schemas/githubLogin.json +1 -1
- data/schemas/historicalSummaries.json +1 -1
- data/schemas/historicalSummary.json +1 -1
- data/schemas/importIntoApplicationOptions.json +3 -2
- data/schemas/importNewApplicationOptions.json +1 -1
- data/schemas/instance.json +1 -1
- data/schemas/instanceCustomNode.json +1 -1
- data/schemas/instanceCustomNodePatch.json +1 -1
- data/schemas/instanceCustomNodePost.json +1 -1
- data/schemas/instanceCustomNodes.json +1 -1
- data/schemas/instanceMember.json +1 -1
- data/schemas/instanceMemberPatch.json +1 -1
- data/schemas/instanceMemberPost.json +1 -1
- data/schemas/instanceMembers.json +1 -1
- data/schemas/instanceOrg.json +1 -1
- data/schemas/instanceOrgMember.json +1 -1
- data/schemas/instanceOrgMemberPatch.json +1 -1
- data/schemas/instanceOrgMemberPost.json +1 -1
- data/schemas/instanceOrgMembers.json +1 -1
- data/schemas/instanceOrgPatch.json +3 -2
- data/schemas/instanceOrgPost.json +3 -2
- data/schemas/instanceOrgs.json +1 -1
- data/schemas/instancePatch.json +1 -1
- data/schemas/instanceReportOptionsPost.json +1 -1
- data/schemas/instanceSandbox.json +1 -1
- data/schemas/instanceSandboxes.json +1 -1
- data/schemas/instances.json +1 -1
- data/schemas/integration.json +1 -1
- data/schemas/integrationPatch.json +1 -1
- data/schemas/integrationPost.json +1 -1
- data/schemas/integrations.json +1 -1
- data/schemas/jobEnqueuedResult.json +5 -1
- data/schemas/lastValueData.json +1 -1
- data/schemas/lastValueQuery.json +1 -1
- data/schemas/me.json +1 -1
- data/schemas/mePatch.json +1 -1
- data/schemas/mqttPublishBody.json +1 -1
- data/schemas/multiDeviceCommand.json +1 -1
- data/schemas/notebook.json +1 -1
- data/schemas/notebookDataExportOptions.json +1 -1
- data/schemas/notebookExecutionLogs.json +1 -1
- data/schemas/notebookExecutionOptions.json +1 -1
- data/schemas/notebookPatch.json +1 -1
- data/schemas/notebookPost.json +1 -1
- data/schemas/notebooks.json +1 -1
- data/schemas/org.json +1 -1
- data/schemas/orgInvite.json +1 -1
- data/schemas/orgInviteAction.json +1 -1
- data/schemas/orgInviteCollection.json +1 -1
- data/schemas/orgInviteInfo.json +1 -1
- data/schemas/orgInvitePost.json +1 -1
- data/schemas/orgInviteResult.json +1 -1
- data/schemas/orgInvites.json +1 -1
- data/schemas/orgMemberPatch.json +1 -1
- data/schemas/orgPatch.json +1 -1
- data/schemas/orgPost.json +1 -1
- data/schemas/orgRoleInfo.json +1 -1
- data/schemas/orgs.json +1 -1
- data/schemas/paletteResponse.json +1 -1
- data/schemas/passwordResetFinish.json +1 -1
- data/schemas/passwordResetInput.json +1 -1
- data/schemas/passwordResetResponse.json +1 -1
- data/schemas/payloadStats.json +1 -1
- data/schemas/recentItem.json +1 -1
- data/schemas/recentItemList.json +1 -1
- data/schemas/resourceTransfer.json +1 -1
- data/schemas/samlResponse.json +1 -1
- data/schemas/ssoRequest.json +1 -1
- data/schemas/success.json +1 -1
- data/schemas/successWithExecutionId.json +16 -0
- data/schemas/successWithJobId.json +16 -0
- data/schemas/tagKeysResponse.json +1 -1
- data/schemas/tagValuesResponse.json +1 -1
- data/schemas/templateKeywords.json +1 -1
- data/schemas/timeSeriesData.json +1 -1
- data/schemas/timeSeriesQuery.json +1 -1
- data/schemas/twoFactorAuthInfo.json +1 -1
- data/schemas/userCredentials.json +1 -1
- data/schemas/userPost.json +1 -1
- data/schemas/validateContextError.json +26 -2
- data/schemas/validateContextSuccess.json +1 -1
- data/schemas/validationErrors.json +1 -1
- data/schemas/virtualButtonPress.json +1 -1
- data/schemas/webhook.json +1 -1
- data/schemas/webhookPatch.json +1 -1
- data/schemas/webhookPost.json +1 -1
- data/schemas/webhooks.json +1 -1
- metadata +4 -2
data/docs/dataTableRows.md
CHANGED
|
@@ -88,7 +88,7 @@ all.Application, all.Application.read, all.Organization, all.Organization.read,
|
|
|
88
88
|
|
|
89
89
|
| Code | Type | Description |
|
|
90
90
|
| ---- | ---- | ----------- |
|
|
91
|
-
| 200 | [Success](_schemas.md#success) | If request was successfully queued |
|
|
91
|
+
| 200 | [Success With Job ID](_schemas.md#success-with-job-id) | If request was successfully queued |
|
|
92
92
|
|
|
93
93
|
#### Error Responses
|
|
94
94
|
|
data/docs/device.md
CHANGED
|
@@ -131,8 +131,8 @@ all.Application, all.Application.read, all.Device, all.Device.read, all.Organiza
|
|
|
131
131
|
| applicationId | string | Y | ID associated with the application | | 575ec8687ae143cd83dc4a97 |
|
|
132
132
|
| deviceId | string | Y | ID associated with the device | | 575ecf887ae143cd83dc4aa2 |
|
|
133
133
|
| excludeConnectionInfo | string | N | If set, do not return connection info | | true |
|
|
134
|
-
| tagsAsObject | string | N | Return tags as an object map instead of an array
|
|
135
|
-
| attributesAsObject | string | N | Return attributes as an object map instead of an array
|
|
134
|
+
| tagsAsObject | string | N | Return tags as an object map instead of an array | | true |
|
|
135
|
+
| attributesAsObject | string | N | Return attributes as an object map instead of an array | | false |
|
|
136
136
|
| losantdomain | string | N | Domain scope of request (rarely needed) | | example.com |
|
|
137
137
|
|
|
138
138
|
#### Successful Responses
|
|
@@ -347,8 +347,8 @@ all.Application, all.Organization, all.User, device.*, or device.patch.
|
|
|
347
347
|
| applicationId | string | Y | ID associated with the application | | 575ec8687ae143cd83dc4a97 |
|
|
348
348
|
| deviceId | string | Y | ID associated with the device | | 575ecf887ae143cd83dc4aa2 |
|
|
349
349
|
| device | [Device Patch](_schemas.md#device-patch) | Y | Object containing new properties of the device | | [Device Patch Example](_schemas.md#device-patch-example) |
|
|
350
|
-
| tagsAsObject | string | N | Return tags as an object map instead of an array
|
|
351
|
-
| attributesAsObject | string | N | Return attributes as an object map instead of an array
|
|
350
|
+
| tagsAsObject | string | N | Return tags as an object map instead of an array | | true |
|
|
351
|
+
| attributesAsObject | string | N | Return attributes as an object map instead of an array | | false |
|
|
352
352
|
| losantdomain | string | N | Domain scope of request (rarely needed) | | example.com |
|
|
353
353
|
|
|
354
354
|
#### Successful Responses
|
data/docs/deviceRecipe.md
CHANGED
|
@@ -119,6 +119,8 @@ all.Application, all.Application.read, all.Organization, all.Organization.read,
|
|
|
119
119
|
| ---- | ---- | -------- | ----------- | ------- | ------- |
|
|
120
120
|
| applicationId | string | Y | ID associated with the application | | 575ec8687ae143cd83dc4a97 |
|
|
121
121
|
| deviceRecipeId | string | Y | ID associated with the device recipe | | 575ecec57ae143cd83dc4a9f |
|
|
122
|
+
| tagsAsObject | string | N | Return tags as an object map instead of an array | | true |
|
|
123
|
+
| attributesAsObject | string | N | Return attributes as an object map instead of an array | | true |
|
|
122
124
|
| losantdomain | string | N | Domain scope of request (rarely needed) | | example.com |
|
|
123
125
|
|
|
124
126
|
#### Successful Responses
|
|
@@ -161,6 +163,8 @@ all.Application, all.Organization, all.User, deviceRecipe.*, or deviceRecipe.pat
|
|
|
161
163
|
| applicationId | string | Y | ID associated with the application | | 575ec8687ae143cd83dc4a97 |
|
|
162
164
|
| deviceRecipeId | string | Y | ID associated with the device recipe | | 575ecec57ae143cd83dc4a9f |
|
|
163
165
|
| deviceRecipe | [Device Recipe Patch](_schemas.md#device-recipe-patch) | Y | Object containing new properties of the device recipe | | [Device Recipe Patch Example](_schemas.md#device-recipe-patch-example) |
|
|
166
|
+
| tagsAsObject | string | N | Return tags as an object map instead of an array | | false |
|
|
167
|
+
| attributesAsObject | string | N | Return attributes as an object map instead of an array | | false |
|
|
164
168
|
| losantdomain | string | N | Domain scope of request (rarely needed) | | example.com |
|
|
165
169
|
|
|
166
170
|
#### Successful Responses
|
data/docs/deviceRecipes.md
CHANGED
|
@@ -37,6 +37,8 @@ all.Application, all.Application.read, all.Organization, all.Organization.read,
|
|
|
37
37
|
| perPage | string | N | How many items to return per page | 100 | 10 |
|
|
38
38
|
| filterField | string | N | Field to filter the results by. Blank or not provided means no filtering. Accepted values are: name | | name |
|
|
39
39
|
| filter | string | N | Filter to apply against the filtered field. Supports globbing. Blank or not provided means no filtering. | | my * recipe |
|
|
40
|
+
| tagsAsObject | string | N | Return tags as an object map instead of an array | | false |
|
|
41
|
+
| attributesAsObject | string | N | Return attributes as an object map instead of an array | | true |
|
|
40
42
|
| losantdomain | string | N | Domain scope of request (rarely needed) | | example.com |
|
|
41
43
|
|
|
42
44
|
#### Successful Responses
|
|
@@ -77,6 +79,8 @@ all.Application, all.Organization, all.User, deviceRecipes.*, or deviceRecipes.p
|
|
|
77
79
|
| ---- | ---- | -------- | ----------- | ------- | ------- |
|
|
78
80
|
| applicationId | string | Y | ID associated with the application | | 575ec8687ae143cd83dc4a97 |
|
|
79
81
|
| deviceRecipe | [Device Recipe Post](_schemas.md#device-recipe-post) | Y | New device recipe information | | [Device Recipe Post Example](_schemas.md#device-recipe-post-example) |
|
|
82
|
+
| tagsAsObject | string | N | Return tags as an object map instead of an array | | false |
|
|
83
|
+
| attributesAsObject | string | N | Return attributes as an object map instead of an array | | true |
|
|
80
84
|
| losantdomain | string | N | Domain scope of request (rarely needed) | | example.com |
|
|
81
85
|
|
|
82
86
|
#### Successful Responses
|
data/docs/devices.md
CHANGED
|
@@ -212,8 +212,8 @@ all.Application, all.Application.read, all.Device, all.Device.read, all.Organiza
|
|
|
212
212
|
| excludeConnectionInfo | string | N | If set, do not return connection info | | true |
|
|
213
213
|
| parentId | string | N | Filter devices as children of a given system id | | 575ecf887ae143cd83dc4aa2 |
|
|
214
214
|
| query | [Advanced Device Query](_schemas.md#advanced-device-query) | N | Device filter JSON object which overrides the filterField, filter, deviceClass, tagFilter, and parentId parameters. | | [Advanced Device Query Example](_schemas.md#advanced-device-query-example) |
|
|
215
|
-
| tagsAsObject | string | N | Return tags as an object map instead of an array
|
|
216
|
-
| attributesAsObject | string | N | Return attributes as an object map instead of an array
|
|
215
|
+
| tagsAsObject | string | N | Return tags as an object map instead of an array | | true |
|
|
216
|
+
| attributesAsObject | string | N | Return attributes as an object map instead of an array | | false |
|
|
217
217
|
| losantdomain | string | N | Domain scope of request (rarely needed) | | example.com |
|
|
218
218
|
|
|
219
219
|
#### Successful Responses
|
|
@@ -333,8 +333,8 @@ all.Application, all.Organization, all.User, devices.*, or devices.post.
|
|
|
333
333
|
| ---- | ---- | -------- | ----------- | ------- | ------- |
|
|
334
334
|
| applicationId | string | Y | ID associated with the application | | 575ec8687ae143cd83dc4a97 |
|
|
335
335
|
| device | [Device Post](_schemas.md#device-post) | Y | New device information | | [Device Post Example](_schemas.md#device-post-example) |
|
|
336
|
-
| tagsAsObject | string | N | Return tags as an object map instead of an array
|
|
337
|
-
| attributesAsObject | string | N | Return attributes as an object map instead of an array
|
|
336
|
+
| tagsAsObject | string | N | Return tags as an object map instead of an array | | true |
|
|
337
|
+
| attributesAsObject | string | N | Return attributes as an object map instead of an array | | false |
|
|
338
338
|
| losantdomain | string | N | Domain scope of request (rarely needed) | | example.com |
|
|
339
339
|
|
|
340
340
|
#### Successful Responses
|
data/docs/embeddedDeployments.md
CHANGED
|
@@ -41,7 +41,7 @@ all.Application, all.Application.read, all.Organization, all.Organization.read,
|
|
|
41
41
|
|
|
42
42
|
| Code | Type | Description |
|
|
43
43
|
| ---- | ---- | ----------- |
|
|
44
|
-
| 200 | [Success](_schemas.md#success) | If generation of export was successfully started |
|
|
44
|
+
| 200 | [Success With Job ID](_schemas.md#success-with-job-id) | If generation of export was successfully started |
|
|
45
45
|
|
|
46
46
|
#### Error Responses
|
|
47
47
|
|
data/docs/notebook.md
CHANGED
|
@@ -6,6 +6,7 @@ parameters and the potential responses.
|
|
|
6
6
|
|
|
7
7
|
##### Contents
|
|
8
8
|
|
|
9
|
+
* [Cancel Execution](#cancel-execution)
|
|
9
10
|
* [Delete](#delete)
|
|
10
11
|
* [Execute](#execute)
|
|
11
12
|
* [Get](#get)
|
|
@@ -16,6 +17,48 @@ parameters and the potential responses.
|
|
|
16
17
|
|
|
17
18
|
<br/>
|
|
18
19
|
|
|
20
|
+
## Cancel Execution
|
|
21
|
+
|
|
22
|
+
Marks a specific notebook execution for cancellation
|
|
23
|
+
|
|
24
|
+
```ruby
|
|
25
|
+
result = client.notebook.cancel_execution(
|
|
26
|
+
applicationId: my_application_id,
|
|
27
|
+
notebookId: my_notebook_id,
|
|
28
|
+
executionId: my_execution_id)
|
|
29
|
+
|
|
30
|
+
puts result
|
|
31
|
+
```
|
|
32
|
+
|
|
33
|
+
#### Authentication
|
|
34
|
+
The client must be configured with a valid api access token to call this
|
|
35
|
+
action. The token must include at least one of the following scopes:
|
|
36
|
+
all.Application, all.Organization, all.User, notebook.*, or notebook.execute.
|
|
37
|
+
|
|
38
|
+
#### Available Parameters
|
|
39
|
+
|
|
40
|
+
| Name | Type | Required | Description | Default | Example |
|
|
41
|
+
| ---- | ---- | -------- | ----------- | ------- | ------- |
|
|
42
|
+
| applicationId | string | Y | ID associated with the application | | 575ec8687ae143cd83dc4a97 |
|
|
43
|
+
| notebookId | string | Y | ID associated with the notebook | | 575ed78e7ae143cd83dc4aab |
|
|
44
|
+
| executionId | undefined | Y | The ID of the execution to cancel | | 632e18632f59592e773a4153 |
|
|
45
|
+
| losantdomain | string | N | Domain scope of request (rarely needed) | | example.com |
|
|
46
|
+
|
|
47
|
+
#### Successful Responses
|
|
48
|
+
|
|
49
|
+
| Code | Type | Description |
|
|
50
|
+
| ---- | ---- | ----------- |
|
|
51
|
+
| 200 | [Success](_schemas.md#success) | If the execution was successfully marked for cancellation |
|
|
52
|
+
|
|
53
|
+
#### Error Responses
|
|
54
|
+
|
|
55
|
+
| Code | Type | Description |
|
|
56
|
+
| ---- | ---- | ----------- |
|
|
57
|
+
| 400 | [Error](_schemas.md#error) | Error if malformed request |
|
|
58
|
+
| 404 | [Error](_schemas.md#error) | Error if execution was not found |
|
|
59
|
+
|
|
60
|
+
<br/>
|
|
61
|
+
|
|
19
62
|
## Delete
|
|
20
63
|
|
|
21
64
|
Deletes a notebook
|
|
@@ -253,7 +296,7 @@ all.Application, all.Application.read, all.Organization, all.Organization.read,
|
|
|
253
296
|
|
|
254
297
|
| Code | Type | Description |
|
|
255
298
|
| ---- | ---- | ----------- |
|
|
256
|
-
| 200 | [Success](_schemas.md#success) | If export request was accepted and successfully queued |
|
|
299
|
+
| 200 | [Success With Job ID](_schemas.md#success-with-job-id) | If export request was accepted and successfully queued |
|
|
257
300
|
|
|
258
301
|
#### Error Responses
|
|
259
302
|
|
data/docs/notebooks.md
CHANGED
|
@@ -31,7 +31,7 @@ all.Application, all.Application.read, all.Organization, all.Organization.read,
|
|
|
31
31
|
| Name | Type | Required | Description | Default | Example |
|
|
32
32
|
| ---- | ---- | -------- | ----------- | ------- | ------- |
|
|
33
33
|
| applicationId | string | Y | ID associated with the application | | 575ec8687ae143cd83dc4a97 |
|
|
34
|
-
| sortField | string | N | Field to sort the results by. Accepted values are: name, id, creationDate, lastUpdated | name | name |
|
|
34
|
+
| sortField | string | N | Field to sort the results by. Accepted values are: name, id, creationDate, lastUpdated, lastExecutionRequested | name | name |
|
|
35
35
|
| sortDirection | string | N | Direction to sort the results by. Accepted values are: asc, desc | asc | asc |
|
|
36
36
|
| page | string | N | Which page of results to return | 0 | 0 |
|
|
37
37
|
| perPage | string | N | How many items to return per page | 100 | 10 |
|
data/lib/losant_rest/client.rb
CHANGED
|
@@ -27,7 +27,7 @@ module LosantRest
|
|
|
27
27
|
#
|
|
28
28
|
# User API for accessing Losant data
|
|
29
29
|
#
|
|
30
|
-
# Built For Version 1.23.
|
|
30
|
+
# Built For Version 1.23.6
|
|
31
31
|
class Client
|
|
32
32
|
attr_accessor :auth_token, :url
|
|
33
33
|
|
|
@@ -374,7 +374,7 @@ module LosantRest
|
|
|
374
374
|
|
|
375
375
|
headers["Accept"] = "application/json"
|
|
376
376
|
headers["Content-Type"] = "application/json"
|
|
377
|
-
headers["Accept-Version"] = "^1.23.
|
|
377
|
+
headers["Accept-Version"] = "^1.23.6"
|
|
378
378
|
headers["Authorization"] = "Bearer #{self.auth_token}" if self.auth_token
|
|
379
379
|
path = self.url + options.fetch(:path, "")
|
|
380
380
|
|
|
@@ -99,7 +99,7 @@ module LosantRest
|
|
|
99
99
|
# * {boolean} _embedded - Return embedded resources in response
|
|
100
100
|
#
|
|
101
101
|
# Responses:
|
|
102
|
-
# * 200 - If request was successfully queued (https://api.losant.com/#/definitions/
|
|
102
|
+
# * 200 - If request was successfully queued (https://api.losant.com/#/definitions/successWithJobId)
|
|
103
103
|
#
|
|
104
104
|
# Errors:
|
|
105
105
|
# * 400 - Error if malformed request (https://api.losant.com/#/definitions/error)
|
data/lib/losant_rest/device.rb
CHANGED
|
@@ -145,8 +145,8 @@ module LosantRest
|
|
|
145
145
|
# * {string} applicationId - ID associated with the application
|
|
146
146
|
# * {string} deviceId - ID associated with the device
|
|
147
147
|
# * {string} excludeConnectionInfo - If set, do not return connection info
|
|
148
|
-
# * {string} tagsAsObject - Return tags as an object map instead of an array
|
|
149
|
-
# * {string} attributesAsObject - Return attributes as an object map instead of an array
|
|
148
|
+
# * {string} tagsAsObject - Return tags as an object map instead of an array
|
|
149
|
+
# * {string} attributesAsObject - Return attributes as an object map instead of an array
|
|
150
150
|
# * {string} losantdomain - Domain scope of request (rarely needed)
|
|
151
151
|
# * {boolean} _actions - Return resource actions in response
|
|
152
152
|
# * {boolean} _links - Return resource link in response
|
|
@@ -405,8 +405,8 @@ module LosantRest
|
|
|
405
405
|
# * {string} applicationId - ID associated with the application
|
|
406
406
|
# * {string} deviceId - ID associated with the device
|
|
407
407
|
# * {hash} device - Object containing new properties of the device (https://api.losant.com/#/definitions/devicePatch)
|
|
408
|
-
# * {string} tagsAsObject - Return tags as an object map instead of an array
|
|
409
|
-
# * {string} attributesAsObject - Return attributes as an object map instead of an array
|
|
408
|
+
# * {string} tagsAsObject - Return tags as an object map instead of an array
|
|
409
|
+
# * {string} attributesAsObject - Return attributes as an object map instead of an array
|
|
410
410
|
# * {string} losantdomain - Domain scope of request (rarely needed)
|
|
411
411
|
# * {boolean} _actions - Return resource actions in response
|
|
412
412
|
# * {boolean} _links - Return resource link in response
|
|
@@ -138,6 +138,8 @@ module LosantRest
|
|
|
138
138
|
# Parameters:
|
|
139
139
|
# * {string} applicationId - ID associated with the application
|
|
140
140
|
# * {string} deviceRecipeId - ID associated with the device recipe
|
|
141
|
+
# * {string} tagsAsObject - Return tags as an object map instead of an array
|
|
142
|
+
# * {string} attributesAsObject - Return attributes as an object map instead of an array
|
|
141
143
|
# * {string} losantdomain - Domain scope of request (rarely needed)
|
|
142
144
|
# * {boolean} _actions - Return resource actions in response
|
|
143
145
|
# * {boolean} _links - Return resource link in response
|
|
@@ -158,6 +160,8 @@ module LosantRest
|
|
|
158
160
|
raise ArgumentError.new("applicationId is required") unless params.has_key?(:applicationId)
|
|
159
161
|
raise ArgumentError.new("deviceRecipeId is required") unless params.has_key?(:deviceRecipeId)
|
|
160
162
|
|
|
163
|
+
query_params[:tagsAsObject] = params[:tagsAsObject] if params.has_key?(:tagsAsObject)
|
|
164
|
+
query_params[:attributesAsObject] = params[:attributesAsObject] if params.has_key?(:attributesAsObject)
|
|
161
165
|
headers[:losantdomain] = params[:losantdomain] if params.has_key?(:losantdomain)
|
|
162
166
|
query_params[:_actions] = params[:_actions] if params.has_key?(:_actions)
|
|
163
167
|
query_params[:_links] = params[:_links] if params.has_key?(:_links)
|
|
@@ -185,6 +189,8 @@ module LosantRest
|
|
|
185
189
|
# * {string} applicationId - ID associated with the application
|
|
186
190
|
# * {string} deviceRecipeId - ID associated with the device recipe
|
|
187
191
|
# * {hash} deviceRecipe - Object containing new properties of the device recipe (https://api.losant.com/#/definitions/deviceRecipePatch)
|
|
192
|
+
# * {string} tagsAsObject - Return tags as an object map instead of an array
|
|
193
|
+
# * {string} attributesAsObject - Return attributes as an object map instead of an array
|
|
188
194
|
# * {string} losantdomain - Domain scope of request (rarely needed)
|
|
189
195
|
# * {boolean} _actions - Return resource actions in response
|
|
190
196
|
# * {boolean} _links - Return resource link in response
|
|
@@ -207,6 +213,8 @@ module LosantRest
|
|
|
207
213
|
raise ArgumentError.new("deviceRecipe is required") unless params.has_key?(:deviceRecipe)
|
|
208
214
|
|
|
209
215
|
body = params[:deviceRecipe] if params.has_key?(:deviceRecipe)
|
|
216
|
+
query_params[:tagsAsObject] = params[:tagsAsObject] if params.has_key?(:tagsAsObject)
|
|
217
|
+
query_params[:attributesAsObject] = params[:attributesAsObject] if params.has_key?(:attributesAsObject)
|
|
210
218
|
headers[:losantdomain] = params[:losantdomain] if params.has_key?(:losantdomain)
|
|
211
219
|
query_params[:_actions] = params[:_actions] if params.has_key?(:_actions)
|
|
212
220
|
query_params[:_links] = params[:_links] if params.has_key?(:_links)
|
|
@@ -47,6 +47,8 @@ module LosantRest
|
|
|
47
47
|
# * {string} perPage - How many items to return per page
|
|
48
48
|
# * {string} filterField - Field to filter the results by. Blank or not provided means no filtering. Accepted values are: name
|
|
49
49
|
# * {string} filter - Filter to apply against the filtered field. Supports globbing. Blank or not provided means no filtering.
|
|
50
|
+
# * {string} tagsAsObject - Return tags as an object map instead of an array
|
|
51
|
+
# * {string} attributesAsObject - Return attributes as an object map instead of an array
|
|
50
52
|
# * {string} losantdomain - Domain scope of request (rarely needed)
|
|
51
53
|
# * {boolean} _actions - Return resource actions in response
|
|
52
54
|
# * {boolean} _links - Return resource link in response
|
|
@@ -72,6 +74,8 @@ module LosantRest
|
|
|
72
74
|
query_params[:perPage] = params[:perPage] if params.has_key?(:perPage)
|
|
73
75
|
query_params[:filterField] = params[:filterField] if params.has_key?(:filterField)
|
|
74
76
|
query_params[:filter] = params[:filter] if params.has_key?(:filter)
|
|
77
|
+
query_params[:tagsAsObject] = params[:tagsAsObject] if params.has_key?(:tagsAsObject)
|
|
78
|
+
query_params[:attributesAsObject] = params[:attributesAsObject] if params.has_key?(:attributesAsObject)
|
|
75
79
|
headers[:losantdomain] = params[:losantdomain] if params.has_key?(:losantdomain)
|
|
76
80
|
query_params[:_actions] = params[:_actions] if params.has_key?(:_actions)
|
|
77
81
|
query_params[:_links] = params[:_links] if params.has_key?(:_links)
|
|
@@ -98,6 +102,8 @@ module LosantRest
|
|
|
98
102
|
# Parameters:
|
|
99
103
|
# * {string} applicationId - ID associated with the application
|
|
100
104
|
# * {hash} deviceRecipe - New device recipe information (https://api.losant.com/#/definitions/deviceRecipePost)
|
|
105
|
+
# * {string} tagsAsObject - Return tags as an object map instead of an array
|
|
106
|
+
# * {string} attributesAsObject - Return attributes as an object map instead of an array
|
|
101
107
|
# * {string} losantdomain - Domain scope of request (rarely needed)
|
|
102
108
|
# * {boolean} _actions - Return resource actions in response
|
|
103
109
|
# * {boolean} _links - Return resource link in response
|
|
@@ -119,6 +125,8 @@ module LosantRest
|
|
|
119
125
|
raise ArgumentError.new("deviceRecipe is required") unless params.has_key?(:deviceRecipe)
|
|
120
126
|
|
|
121
127
|
body = params[:deviceRecipe] if params.has_key?(:deviceRecipe)
|
|
128
|
+
query_params[:tagsAsObject] = params[:tagsAsObject] if params.has_key?(:tagsAsObject)
|
|
129
|
+
query_params[:attributesAsObject] = params[:attributesAsObject] if params.has_key?(:attributesAsObject)
|
|
122
130
|
headers[:losantdomain] = params[:losantdomain] if params.has_key?(:losantdomain)
|
|
123
131
|
query_params[:_actions] = params[:_actions] if params.has_key?(:_actions)
|
|
124
132
|
query_params[:_links] = params[:_links] if params.has_key?(:_links)
|
data/lib/losant_rest/devices.rb
CHANGED
|
@@ -250,8 +250,8 @@ module LosantRest
|
|
|
250
250
|
# * {string} excludeConnectionInfo - If set, do not return connection info
|
|
251
251
|
# * {string} parentId - Filter devices as children of a given system id
|
|
252
252
|
# * {hash} query - Device filter JSON object which overrides the filterField, filter, deviceClass, tagFilter, and parentId parameters. (https://api.losant.com/#/definitions/advancedDeviceQuery)
|
|
253
|
-
# * {string} tagsAsObject - Return tags as an object map instead of an array
|
|
254
|
-
# * {string} attributesAsObject - Return attributes as an object map instead of an array
|
|
253
|
+
# * {string} tagsAsObject - Return tags as an object map instead of an array
|
|
254
|
+
# * {string} attributesAsObject - Return attributes as an object map instead of an array
|
|
255
255
|
# * {string} losantdomain - Domain scope of request (rarely needed)
|
|
256
256
|
# * {boolean} _actions - Return resource actions in response
|
|
257
257
|
# * {boolean} _links - Return resource link in response
|
|
@@ -405,8 +405,8 @@ module LosantRest
|
|
|
405
405
|
# Parameters:
|
|
406
406
|
# * {string} applicationId - ID associated with the application
|
|
407
407
|
# * {hash} device - New device information (https://api.losant.com/#/definitions/devicePost)
|
|
408
|
-
# * {string} tagsAsObject - Return tags as an object map instead of an array
|
|
409
|
-
# * {string} attributesAsObject - Return attributes as an object map instead of an array
|
|
408
|
+
# * {string} tagsAsObject - Return tags as an object map instead of an array
|
|
409
|
+
# * {string} attributesAsObject - Return attributes as an object map instead of an array
|
|
410
410
|
# * {string} losantdomain - Domain scope of request (rarely needed)
|
|
411
411
|
# * {boolean} _actions - Return resource actions in response
|
|
412
412
|
# * {boolean} _links - Return resource link in response
|
|
@@ -48,7 +48,7 @@ module LosantRest
|
|
|
48
48
|
# * {boolean} _embedded - Return embedded resources in response
|
|
49
49
|
#
|
|
50
50
|
# Responses:
|
|
51
|
-
# * 200 - If generation of export was successfully started (https://api.losant.com/#/definitions/
|
|
51
|
+
# * 200 - If generation of export was successfully started (https://api.losant.com/#/definitions/successWithJobId)
|
|
52
52
|
#
|
|
53
53
|
# Errors:
|
|
54
54
|
# * 400 - Error if malformed request (https://api.losant.com/#/definitions/error)
|
data/lib/losant_rest/notebook.rb
CHANGED
|
@@ -31,6 +31,55 @@ module LosantRest
|
|
|
31
31
|
@client = client
|
|
32
32
|
end
|
|
33
33
|
|
|
34
|
+
# Marks a specific notebook execution for cancellation
|
|
35
|
+
#
|
|
36
|
+
# Authentication:
|
|
37
|
+
# The client must be configured with a valid api
|
|
38
|
+
# access token to call this action. The token
|
|
39
|
+
# must include at least one of the following scopes:
|
|
40
|
+
# all.Application, all.Organization, all.User, notebook.*, or notebook.execute.
|
|
41
|
+
#
|
|
42
|
+
# Parameters:
|
|
43
|
+
# * {string} applicationId - ID associated with the application
|
|
44
|
+
# * {string} notebookId - ID associated with the notebook
|
|
45
|
+
# * {undefined} executionId - The ID of the execution to cancel
|
|
46
|
+
# * {string} losantdomain - Domain scope of request (rarely needed)
|
|
47
|
+
# * {boolean} _actions - Return resource actions in response
|
|
48
|
+
# * {boolean} _links - Return resource link in response
|
|
49
|
+
# * {boolean} _embedded - Return embedded resources in response
|
|
50
|
+
#
|
|
51
|
+
# Responses:
|
|
52
|
+
# * 200 - If the execution was successfully marked for cancellation (https://api.losant.com/#/definitions/success)
|
|
53
|
+
#
|
|
54
|
+
# Errors:
|
|
55
|
+
# * 400 - Error if malformed request (https://api.losant.com/#/definitions/error)
|
|
56
|
+
# * 404 - Error if execution was not found (https://api.losant.com/#/definitions/error)
|
|
57
|
+
def cancel_execution(params = {})
|
|
58
|
+
params = Utils.symbolize_hash_keys(params)
|
|
59
|
+
query_params = { _actions: false, _links: true, _embedded: true }
|
|
60
|
+
headers = {}
|
|
61
|
+
body = nil
|
|
62
|
+
|
|
63
|
+
raise ArgumentError.new("applicationId is required") unless params.has_key?(:applicationId)
|
|
64
|
+
raise ArgumentError.new("notebookId is required") unless params.has_key?(:notebookId)
|
|
65
|
+
raise ArgumentError.new("executionId is required") unless params.has_key?(:executionId)
|
|
66
|
+
|
|
67
|
+
query_params[:executionId] = params[:executionId] if params.has_key?(:executionId)
|
|
68
|
+
headers[:losantdomain] = params[:losantdomain] if params.has_key?(:losantdomain)
|
|
69
|
+
query_params[:_actions] = params[:_actions] if params.has_key?(:_actions)
|
|
70
|
+
query_params[:_links] = params[:_links] if params.has_key?(:_links)
|
|
71
|
+
query_params[:_embedded] = params[:_embedded] if params.has_key?(:_embedded)
|
|
72
|
+
|
|
73
|
+
path = "/applications/#{params[:applicationId]}/notebooks/#{params[:notebookId]}/cancelExecution"
|
|
74
|
+
|
|
75
|
+
@client.request(
|
|
76
|
+
method: :post,
|
|
77
|
+
path: path,
|
|
78
|
+
query: query_params,
|
|
79
|
+
headers: headers,
|
|
80
|
+
body: body)
|
|
81
|
+
end
|
|
82
|
+
|
|
34
83
|
# Deletes a notebook
|
|
35
84
|
#
|
|
36
85
|
# Authentication:
|
|
@@ -289,7 +338,7 @@ module LosantRest
|
|
|
289
338
|
# * {boolean} _embedded - Return embedded resources in response
|
|
290
339
|
#
|
|
291
340
|
# Responses:
|
|
292
|
-
# * 200 - If export request was accepted and successfully queued (https://api.losant.com/#/definitions/
|
|
341
|
+
# * 200 - If export request was accepted and successfully queued (https://api.losant.com/#/definitions/successWithJobId)
|
|
293
342
|
#
|
|
294
343
|
# Errors:
|
|
295
344
|
# * 400 - Error if malformed request (https://api.losant.com/#/definitions/error)
|
|
@@ -41,7 +41,7 @@ module LosantRest
|
|
|
41
41
|
#
|
|
42
42
|
# Parameters:
|
|
43
43
|
# * {string} applicationId - ID associated with the application
|
|
44
|
-
# * {string} sortField - Field to sort the results by. Accepted values are: name, id, creationDate, lastUpdated
|
|
44
|
+
# * {string} sortField - Field to sort the results by. Accepted values are: name, id, creationDate, lastUpdated, lastExecutionRequested
|
|
45
45
|
# * {string} sortDirection - Direction to sort the results by. Accepted values are: asc, desc
|
|
46
46
|
# * {string} page - Which page of results to return
|
|
47
47
|
# * {string} perPage - How many items to return per page
|
data/lib/losant_rest/version.rb
CHANGED
data/schemas/advancedQuery.json
CHANGED
data/schemas/apiToken.json
CHANGED
data/schemas/apiTokenPatch.json
CHANGED
data/schemas/apiTokenPost.json
CHANGED
data/schemas/apiTokens.json
CHANGED
data/schemas/application.json
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
{
|
|
2
|
-
"$schema": "http://json-schema.org/draft-
|
|
2
|
+
"$schema": "http://json-schema.org/draft-07/schema#",
|
|
3
3
|
"type": "object",
|
|
4
4
|
"properties": {
|
|
5
5
|
"dryRun": {
|
|
@@ -45,6 +45,10 @@
|
|
|
45
45
|
"type": "string",
|
|
46
46
|
"format": "uri",
|
|
47
47
|
"maxLength": 1024
|
|
48
|
+
},
|
|
49
|
+
"forceJob": {
|
|
50
|
+
"type": "boolean",
|
|
51
|
+
"default": false
|
|
48
52
|
}
|
|
49
53
|
},
|
|
50
54
|
"additionalProperties": false
|