losant_rest 1.9.1 → 1.9.2
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +5 -5
- data/LICENSE +1 -1
- data/README.md +1 -1
- data/docs/_schemas.md +8502 -580
- data/docs/application.md +45 -3
- data/docs/applications.md +46 -0
- data/docs/experienceEndpoint.md +43 -0
- data/docs/experienceEndpoints.md +1 -1
- data/docs/experienceView.md +43 -0
- data/lib/losant_rest.rb +1 -1
- data/lib/losant_rest/application.rb +52 -4
- data/lib/losant_rest/application_api_token.rb +1 -1
- data/lib/losant_rest/application_api_tokens.rb +1 -1
- data/lib/losant_rest/application_certificate.rb +1 -1
- data/lib/losant_rest/application_certificate_authorities.rb +1 -1
- data/lib/losant_rest/application_certificate_authority.rb +1 -1
- data/lib/losant_rest/application_certificates.rb +1 -1
- data/lib/losant_rest/application_key.rb +1 -1
- data/lib/losant_rest/application_keys.rb +1 -1
- data/lib/losant_rest/applications.rb +1 -1
- data/lib/losant_rest/audit_log.rb +1 -1
- data/lib/losant_rest/audit_logs.rb +1 -1
- data/lib/losant_rest/auth.rb +1 -1
- data/lib/losant_rest/client.rb +3 -3
- data/lib/losant_rest/dashboard.rb +1 -1
- data/lib/losant_rest/dashboards.rb +1 -1
- data/lib/losant_rest/data.rb +1 -1
- data/lib/losant_rest/data_table.rb +1 -1
- data/lib/losant_rest/data_table_row.rb +1 -1
- data/lib/losant_rest/data_table_rows.rb +1 -1
- data/lib/losant_rest/data_tables.rb +1 -1
- data/lib/losant_rest/device.rb +1 -1
- data/lib/losant_rest/device_recipe.rb +1 -1
- data/lib/losant_rest/device_recipes.rb +1 -1
- data/lib/losant_rest/devices.rb +1 -1
- data/lib/losant_rest/edge_deployments.rb +1 -1
- data/lib/losant_rest/error.rb +1 -1
- data/lib/losant_rest/event.rb +1 -1
- data/lib/losant_rest/events.rb +1 -1
- data/lib/losant_rest/experience.rb +1 -1
- data/lib/losant_rest/experience_domain.rb +1 -1
- data/lib/losant_rest/experience_domains.rb +1 -1
- data/lib/losant_rest/experience_endpoint.rb +51 -1
- data/lib/losant_rest/experience_endpoints.rb +1 -1
- data/lib/losant_rest/experience_group.rb +1 -1
- data/lib/losant_rest/experience_groups.rb +1 -1
- data/lib/losant_rest/experience_slug.rb +1 -1
- data/lib/losant_rest/experience_slugs.rb +1 -1
- data/lib/losant_rest/experience_user.rb +1 -1
- data/lib/losant_rest/experience_users.rb +1 -1
- data/lib/losant_rest/experience_version.rb +1 -1
- data/lib/losant_rest/experience_versions.rb +1 -1
- data/lib/losant_rest/experience_view.rb +51 -1
- data/lib/losant_rest/experience_views.rb +1 -1
- data/lib/losant_rest/file.rb +1 -1
- data/lib/losant_rest/files.rb +1 -1
- data/lib/losant_rest/flow.rb +1 -1
- data/lib/losant_rest/flow_version.rb +1 -1
- data/lib/losant_rest/flow_versions.rb +1 -1
- data/lib/losant_rest/flows.rb +1 -1
- data/lib/losant_rest/integration.rb +1 -1
- data/lib/losant_rest/integrations.rb +1 -1
- data/lib/losant_rest/me.rb +1 -1
- data/lib/losant_rest/notebook.rb +1 -1
- data/lib/losant_rest/notebooks.rb +1 -1
- data/lib/losant_rest/org.rb +1 -1
- data/lib/losant_rest/org_invites.rb +1 -1
- data/lib/losant_rest/orgs.rb +1 -1
- data/lib/losant_rest/utils.rb +1 -1
- data/lib/losant_rest/version.rb +1 -1
- data/lib/losant_rest/webhook.rb +1 -1
- data/lib/losant_rest/webhooks.rb +1 -1
- data/schemas/application.json +3 -3
- data/schemas/applicationApiTokenPost.json +3 -0
- data/schemas/applicationCertificate.json +34 -0
- data/schemas/applicationCertificatePatch.json +34 -0
- data/schemas/applicationCertificatePost.json +34 -0
- data/schemas/applicationCertificates.json +34 -0
- data/schemas/{applicationCloneResult.json → applicationCreationByTemplateResult.json} +14 -6
- data/schemas/applicationExportPost.json +24 -0
- data/schemas/applicationExportResult.json +10 -0
- data/schemas/applicationKey.json +34 -0
- data/schemas/applicationKeyPatch.json +34 -0
- data/schemas/applicationKeyPost.json +34 -0
- data/schemas/applicationKeyPostResponse.json +34 -0
- data/schemas/applicationKeys.json +34 -0
- data/schemas/applicationPatch.json +3 -3
- data/schemas/applicationPost.json +3 -3
- data/schemas/applications.json +3 -3
- data/schemas/authedDevice.json +34 -0
- data/schemas/dashboard.json +76 -0
- data/schemas/dashboardPatch.json +76 -0
- data/schemas/dashboardPost.json +76 -0
- data/schemas/dashboards.json +76 -0
- data/schemas/experienceLinkedResources.json +6353 -0
- data/schemas/githubLogin.json +4 -0
- data/schemas/integration.json +4 -4
- data/schemas/integrationPatch.json +4 -4
- data/schemas/integrationPost.json +4 -4
- data/schemas/integrations.json +4 -4
- data/schemas/{applicationCloneEnqueued.json → jobEnqueuedResult.json} +0 -0
- data/schemas/notebook.json +198 -34
- data/schemas/notebookDataExportOptions.json +4 -0
- data/schemas/notebookExecutionLogs.json +4 -0
- data/schemas/notebookExecutionOptions.json +4 -0
- data/schemas/notebookPatch.json +198 -34
- data/schemas/notebookPost.json +198 -34
- data/schemas/notebooks.json +198 -34
- data/schemas/userCredentials.json +4 -0
- data/schemas/userPost.json +4 -0
- data/schemas/{validationCloneErrors.json → validationErrors.json} +9 -2
- metadata +9 -6
data/lib/losant_rest/client.rb
CHANGED
@@ -1,6 +1,6 @@
|
|
1
1
|
# The MIT License (MIT)
|
2
2
|
#
|
3
|
-
# Copyright (c)
|
3
|
+
# Copyright (c) 2020 Losant IoT, Inc.
|
4
4
|
#
|
5
5
|
# Permission is hereby granted, free of charge, to any person obtaining a copy
|
6
6
|
# of this software and associated documentation files (the "Software"), to deal
|
@@ -27,7 +27,7 @@ module LosantRest
|
|
27
27
|
#
|
28
28
|
# User API for accessing Losant data
|
29
29
|
#
|
30
|
-
# Built For Version 1.16.
|
30
|
+
# Built For Version 1.16.2
|
31
31
|
class Client
|
32
32
|
attr_accessor :auth_token, :url
|
33
33
|
|
@@ -274,7 +274,7 @@ module LosantRest
|
|
274
274
|
|
275
275
|
headers["Accept"] = "application/json"
|
276
276
|
headers["Content-Type"] = "application/json"
|
277
|
-
headers["Accept-Version"] = "^1.16.
|
277
|
+
headers["Accept-Version"] = "^1.16.2"
|
278
278
|
headers["Authorization"] = "Bearer #{self.auth_token}" if self.auth_token
|
279
279
|
path = self.url + options.fetch(:path, "")
|
280
280
|
|
@@ -1,6 +1,6 @@
|
|
1
1
|
# The MIT License (MIT)
|
2
2
|
#
|
3
|
-
# Copyright (c)
|
3
|
+
# Copyright (c) 2020 Losant IoT, Inc.
|
4
4
|
#
|
5
5
|
# Permission is hereby granted, free of charge, to any person obtaining a copy
|
6
6
|
# of this software and associated documentation files (the "Software"), to deal
|
@@ -1,6 +1,6 @@
|
|
1
1
|
# The MIT License (MIT)
|
2
2
|
#
|
3
|
-
# Copyright (c)
|
3
|
+
# Copyright (c) 2020 Losant IoT, Inc.
|
4
4
|
#
|
5
5
|
# Permission is hereby granted, free of charge, to any person obtaining a copy
|
6
6
|
# of this software and associated documentation files (the "Software"), to deal
|
data/lib/losant_rest/data.rb
CHANGED
@@ -1,6 +1,6 @@
|
|
1
1
|
# The MIT License (MIT)
|
2
2
|
#
|
3
|
-
# Copyright (c)
|
3
|
+
# Copyright (c) 2020 Losant IoT, Inc.
|
4
4
|
#
|
5
5
|
# Permission is hereby granted, free of charge, to any person obtaining a copy
|
6
6
|
# of this software and associated documentation files (the "Software"), to deal
|
@@ -1,6 +1,6 @@
|
|
1
1
|
# The MIT License (MIT)
|
2
2
|
#
|
3
|
-
# Copyright (c)
|
3
|
+
# Copyright (c) 2020 Losant IoT, Inc.
|
4
4
|
#
|
5
5
|
# Permission is hereby granted, free of charge, to any person obtaining a copy
|
6
6
|
# of this software and associated documentation files (the "Software"), to deal
|
@@ -1,6 +1,6 @@
|
|
1
1
|
# The MIT License (MIT)
|
2
2
|
#
|
3
|
-
# Copyright (c)
|
3
|
+
# Copyright (c) 2020 Losant IoT, Inc.
|
4
4
|
#
|
5
5
|
# Permission is hereby granted, free of charge, to any person obtaining a copy
|
6
6
|
# of this software and associated documentation files (the "Software"), to deal
|
@@ -1,6 +1,6 @@
|
|
1
1
|
# The MIT License (MIT)
|
2
2
|
#
|
3
|
-
# Copyright (c)
|
3
|
+
# Copyright (c) 2020 Losant IoT, Inc.
|
4
4
|
#
|
5
5
|
# Permission is hereby granted, free of charge, to any person obtaining a copy
|
6
6
|
# of this software and associated documentation files (the "Software"), to deal
|
@@ -1,6 +1,6 @@
|
|
1
1
|
# The MIT License (MIT)
|
2
2
|
#
|
3
|
-
# Copyright (c)
|
3
|
+
# Copyright (c) 2020 Losant IoT, Inc.
|
4
4
|
#
|
5
5
|
# Permission is hereby granted, free of charge, to any person obtaining a copy
|
6
6
|
# of this software and associated documentation files (the "Software"), to deal
|
data/lib/losant_rest/device.rb
CHANGED
@@ -1,6 +1,6 @@
|
|
1
1
|
# The MIT License (MIT)
|
2
2
|
#
|
3
|
-
# Copyright (c)
|
3
|
+
# Copyright (c) 2020 Losant IoT, Inc.
|
4
4
|
#
|
5
5
|
# Permission is hereby granted, free of charge, to any person obtaining a copy
|
6
6
|
# of this software and associated documentation files (the "Software"), to deal
|
@@ -1,6 +1,6 @@
|
|
1
1
|
# The MIT License (MIT)
|
2
2
|
#
|
3
|
-
# Copyright (c)
|
3
|
+
# Copyright (c) 2020 Losant IoT, Inc.
|
4
4
|
#
|
5
5
|
# Permission is hereby granted, free of charge, to any person obtaining a copy
|
6
6
|
# of this software and associated documentation files (the "Software"), to deal
|
@@ -1,6 +1,6 @@
|
|
1
1
|
# The MIT License (MIT)
|
2
2
|
#
|
3
|
-
# Copyright (c)
|
3
|
+
# Copyright (c) 2020 Losant IoT, Inc.
|
4
4
|
#
|
5
5
|
# Permission is hereby granted, free of charge, to any person obtaining a copy
|
6
6
|
# of this software and associated documentation files (the "Software"), to deal
|
data/lib/losant_rest/devices.rb
CHANGED
@@ -1,6 +1,6 @@
|
|
1
1
|
# The MIT License (MIT)
|
2
2
|
#
|
3
|
-
# Copyright (c)
|
3
|
+
# Copyright (c) 2020 Losant IoT, Inc.
|
4
4
|
#
|
5
5
|
# Permission is hereby granted, free of charge, to any person obtaining a copy
|
6
6
|
# of this software and associated documentation files (the "Software"), to deal
|
@@ -1,6 +1,6 @@
|
|
1
1
|
# The MIT License (MIT)
|
2
2
|
#
|
3
|
-
# Copyright (c)
|
3
|
+
# Copyright (c) 2020 Losant IoT, Inc.
|
4
4
|
#
|
5
5
|
# Permission is hereby granted, free of charge, to any person obtaining a copy
|
6
6
|
# of this software and associated documentation files (the "Software"), to deal
|
data/lib/losant_rest/error.rb
CHANGED
@@ -1,6 +1,6 @@
|
|
1
1
|
# The MIT License (MIT)
|
2
2
|
#
|
3
|
-
# Copyright (c)
|
3
|
+
# Copyright (c) 2020 Losant IoT, Inc.
|
4
4
|
#
|
5
5
|
# Permission is hereby granted, free of charge, to any person obtaining a copy
|
6
6
|
# of this software and associated documentation files (the "Software"), to deal
|
data/lib/losant_rest/event.rb
CHANGED
@@ -1,6 +1,6 @@
|
|
1
1
|
# The MIT License (MIT)
|
2
2
|
#
|
3
|
-
# Copyright (c)
|
3
|
+
# Copyright (c) 2020 Losant IoT, Inc.
|
4
4
|
#
|
5
5
|
# Permission is hereby granted, free of charge, to any person obtaining a copy
|
6
6
|
# of this software and associated documentation files (the "Software"), to deal
|
data/lib/losant_rest/events.rb
CHANGED
@@ -1,6 +1,6 @@
|
|
1
1
|
# The MIT License (MIT)
|
2
2
|
#
|
3
|
-
# Copyright (c)
|
3
|
+
# Copyright (c) 2020 Losant IoT, Inc.
|
4
4
|
#
|
5
5
|
# Permission is hereby granted, free of charge, to any person obtaining a copy
|
6
6
|
# of this software and associated documentation files (the "Software"), to deal
|
@@ -1,6 +1,6 @@
|
|
1
1
|
# The MIT License (MIT)
|
2
2
|
#
|
3
|
-
# Copyright (c)
|
3
|
+
# Copyright (c) 2020 Losant IoT, Inc.
|
4
4
|
#
|
5
5
|
# Permission is hereby granted, free of charge, to any person obtaining a copy
|
6
6
|
# of this software and associated documentation files (the "Software"), to deal
|
@@ -1,6 +1,6 @@
|
|
1
1
|
# The MIT License (MIT)
|
2
2
|
#
|
3
|
-
# Copyright (c)
|
3
|
+
# Copyright (c) 2020 Losant IoT, Inc.
|
4
4
|
#
|
5
5
|
# Permission is hereby granted, free of charge, to any person obtaining a copy
|
6
6
|
# of this software and associated documentation files (the "Software"), to deal
|
@@ -1,6 +1,6 @@
|
|
1
1
|
# The MIT License (MIT)
|
2
2
|
#
|
3
|
-
# Copyright (c)
|
3
|
+
# Copyright (c) 2020 Losant IoT, Inc.
|
4
4
|
#
|
5
5
|
# Permission is hereby granted, free of charge, to any person obtaining a copy
|
6
6
|
# of this software and associated documentation files (the "Software"), to deal
|
@@ -1,6 +1,6 @@
|
|
1
1
|
# The MIT License (MIT)
|
2
2
|
#
|
3
|
-
# Copyright (c)
|
3
|
+
# Copyright (c) 2020 Losant IoT, Inc.
|
4
4
|
#
|
5
5
|
# Permission is hereby granted, free of charge, to any person obtaining a copy
|
6
6
|
# of this software and associated documentation files (the "Software"), to deal
|
@@ -125,6 +125,56 @@ module LosantRest
|
|
125
125
|
body: body)
|
126
126
|
end
|
127
127
|
|
128
|
+
# Retrieves information on resources linked to an experience endpoint
|
129
|
+
#
|
130
|
+
# Authentication:
|
131
|
+
# The client must be configured with a valid api
|
132
|
+
# access token to call this action. The token
|
133
|
+
# must include at least one of the following scopes:
|
134
|
+
# all.Application, all.Application.read, all.Organization, all.Organization.read, all.User, all.User.read, experienceEndpoint.*, or experienceEndpoint.linkedResources.
|
135
|
+
#
|
136
|
+
# Parameters:
|
137
|
+
# * {string} applicationId - ID associated with the application
|
138
|
+
# * {string} experienceEndpointId - ID associated with the experience endpoint
|
139
|
+
# * {string} version - Version of this experience endpoint to query
|
140
|
+
# * {string} includeCustomNodes - If the result of the request should also include the details of any custom nodes referenced by returned workflows
|
141
|
+
# * {string} losantdomain - Domain scope of request (rarely needed)
|
142
|
+
# * {boolean} _actions - Return resource actions in response
|
143
|
+
# * {boolean} _links - Return resource link in response
|
144
|
+
# * {boolean} _embedded - Return embedded resources in response
|
145
|
+
#
|
146
|
+
# Responses:
|
147
|
+
# * 200 - Linked resource information (https://api.losant.com/#/definitions/experienceLinkedResources)
|
148
|
+
#
|
149
|
+
# Errors:
|
150
|
+
# * 400 - Error if malformed request (https://api.losant.com/#/definitions/error)
|
151
|
+
# * 404 - Error if experience endpoint was not found (https://api.losant.com/#/definitions/error)
|
152
|
+
def linked_resources(params = {})
|
153
|
+
params = Utils.symbolize_hash_keys(params)
|
154
|
+
query_params = { _actions: false, _links: true, _embedded: true }
|
155
|
+
headers = {}
|
156
|
+
body = nil
|
157
|
+
|
158
|
+
raise ArgumentError.new("applicationId is required") unless params.has_key?(:applicationId)
|
159
|
+
raise ArgumentError.new("experienceEndpointId is required") unless params.has_key?(:experienceEndpointId)
|
160
|
+
|
161
|
+
query_params[:version] = params[:version] if params.has_key?(:version)
|
162
|
+
query_params[:includeCustomNodes] = params[:includeCustomNodes] if params.has_key?(:includeCustomNodes)
|
163
|
+
headers[:losantdomain] = params[:losantdomain] if params.has_key?(:losantdomain)
|
164
|
+
query_params[:_actions] = params[:_actions] if params.has_key?(:_actions)
|
165
|
+
query_params[:_links] = params[:_links] if params.has_key?(:_links)
|
166
|
+
query_params[:_embedded] = params[:_embedded] if params.has_key?(:_embedded)
|
167
|
+
|
168
|
+
path = "/applications/#{params[:applicationId]}/experience/endpoints/#{params[:experienceEndpointId]}/linkedResources"
|
169
|
+
|
170
|
+
@client.request(
|
171
|
+
method: :get,
|
172
|
+
path: path,
|
173
|
+
query: query_params,
|
174
|
+
headers: headers,
|
175
|
+
body: body)
|
176
|
+
end
|
177
|
+
|
128
178
|
# Updates information about an experience endpoint
|
129
179
|
#
|
130
180
|
# Authentication:
|
@@ -1,6 +1,6 @@
|
|
1
1
|
# The MIT License (MIT)
|
2
2
|
#
|
3
|
-
# Copyright (c)
|
3
|
+
# Copyright (c) 2020 Losant IoT, Inc.
|
4
4
|
#
|
5
5
|
# Permission is hereby granted, free of charge, to any person obtaining a copy
|
6
6
|
# of this software and associated documentation files (the "Software"), to deal
|
@@ -1,6 +1,6 @@
|
|
1
1
|
# The MIT License (MIT)
|
2
2
|
#
|
3
|
-
# Copyright (c)
|
3
|
+
# Copyright (c) 2020 Losant IoT, Inc.
|
4
4
|
#
|
5
5
|
# Permission is hereby granted, free of charge, to any person obtaining a copy
|
6
6
|
# of this software and associated documentation files (the "Software"), to deal
|
@@ -1,6 +1,6 @@
|
|
1
1
|
# The MIT License (MIT)
|
2
2
|
#
|
3
|
-
# Copyright (c)
|
3
|
+
# Copyright (c) 2020 Losant IoT, Inc.
|
4
4
|
#
|
5
5
|
# Permission is hereby granted, free of charge, to any person obtaining a copy
|
6
6
|
# of this software and associated documentation files (the "Software"), to deal
|
@@ -1,6 +1,6 @@
|
|
1
1
|
# The MIT License (MIT)
|
2
2
|
#
|
3
|
-
# Copyright (c)
|
3
|
+
# Copyright (c) 2020 Losant IoT, Inc.
|
4
4
|
#
|
5
5
|
# Permission is hereby granted, free of charge, to any person obtaining a copy
|
6
6
|
# of this software and associated documentation files (the "Software"), to deal
|
@@ -1,6 +1,6 @@
|
|
1
1
|
# The MIT License (MIT)
|
2
2
|
#
|
3
|
-
# Copyright (c)
|
3
|
+
# Copyright (c) 2020 Losant IoT, Inc.
|
4
4
|
#
|
5
5
|
# Permission is hereby granted, free of charge, to any person obtaining a copy
|
6
6
|
# of this software and associated documentation files (the "Software"), to deal
|
@@ -1,6 +1,6 @@
|
|
1
1
|
# The MIT License (MIT)
|
2
2
|
#
|
3
|
-
# Copyright (c)
|
3
|
+
# Copyright (c) 2020 Losant IoT, Inc.
|
4
4
|
#
|
5
5
|
# Permission is hereby granted, free of charge, to any person obtaining a copy
|
6
6
|
# of this software and associated documentation files (the "Software"), to deal
|
@@ -1,6 +1,6 @@
|
|
1
1
|
# The MIT License (MIT)
|
2
2
|
#
|
3
|
-
# Copyright (c)
|
3
|
+
# Copyright (c) 2020 Losant IoT, Inc.
|
4
4
|
#
|
5
5
|
# Permission is hereby granted, free of charge, to any person obtaining a copy
|
6
6
|
# of this software and associated documentation files (the "Software"), to deal
|
@@ -1,6 +1,6 @@
|
|
1
1
|
# The MIT License (MIT)
|
2
2
|
#
|
3
|
-
# Copyright (c)
|
3
|
+
# Copyright (c) 2020 Losant IoT, Inc.
|
4
4
|
#
|
5
5
|
# Permission is hereby granted, free of charge, to any person obtaining a copy
|
6
6
|
# of this software and associated documentation files (the "Software"), to deal
|
@@ -1,6 +1,6 @@
|
|
1
1
|
# The MIT License (MIT)
|
2
2
|
#
|
3
|
-
# Copyright (c)
|
3
|
+
# Copyright (c) 2020 Losant IoT, Inc.
|
4
4
|
#
|
5
5
|
# Permission is hereby granted, free of charge, to any person obtaining a copy
|
6
6
|
# of this software and associated documentation files (the "Software"), to deal
|
@@ -1,6 +1,6 @@
|
|
1
1
|
# The MIT License (MIT)
|
2
2
|
#
|
3
|
-
# Copyright (c)
|
3
|
+
# Copyright (c) 2020 Losant IoT, Inc.
|
4
4
|
#
|
5
5
|
# Permission is hereby granted, free of charge, to any person obtaining a copy
|
6
6
|
# of this software and associated documentation files (the "Software"), to deal
|
@@ -125,6 +125,56 @@ module LosantRest
|
|
125
125
|
body: body)
|
126
126
|
end
|
127
127
|
|
128
|
+
# Retrieves information on resources linked to an experience view
|
129
|
+
#
|
130
|
+
# Authentication:
|
131
|
+
# The client must be configured with a valid api
|
132
|
+
# access token to call this action. The token
|
133
|
+
# must include at least one of the following scopes:
|
134
|
+
# all.Application, all.Application.read, all.Organization, all.Organization.read, all.User, all.User.read, experienceView.*, or experienceView.linkedResources.
|
135
|
+
#
|
136
|
+
# Parameters:
|
137
|
+
# * {string} applicationId - ID associated with the application
|
138
|
+
# * {string} experienceViewId - ID associated with the experience view
|
139
|
+
# * {string} version - Version of this experience view to query
|
140
|
+
# * {string} includeCustomNodes - If the result of the request should also include the details of any custom nodes referenced by returned workflows
|
141
|
+
# * {string} losantdomain - Domain scope of request (rarely needed)
|
142
|
+
# * {boolean} _actions - Return resource actions in response
|
143
|
+
# * {boolean} _links - Return resource link in response
|
144
|
+
# * {boolean} _embedded - Return embedded resources in response
|
145
|
+
#
|
146
|
+
# Responses:
|
147
|
+
# * 200 - Linked resource information (https://api.losant.com/#/definitions/experienceLinkedResources)
|
148
|
+
#
|
149
|
+
# Errors:
|
150
|
+
# * 400 - Error if malformed request (https://api.losant.com/#/definitions/error)
|
151
|
+
# * 404 - Error if experience view was not found (https://api.losant.com/#/definitions/error)
|
152
|
+
def linked_resources(params = {})
|
153
|
+
params = Utils.symbolize_hash_keys(params)
|
154
|
+
query_params = { _actions: false, _links: true, _embedded: true }
|
155
|
+
headers = {}
|
156
|
+
body = nil
|
157
|
+
|
158
|
+
raise ArgumentError.new("applicationId is required") unless params.has_key?(:applicationId)
|
159
|
+
raise ArgumentError.new("experienceViewId is required") unless params.has_key?(:experienceViewId)
|
160
|
+
|
161
|
+
query_params[:version] = params[:version] if params.has_key?(:version)
|
162
|
+
query_params[:includeCustomNodes] = params[:includeCustomNodes] if params.has_key?(:includeCustomNodes)
|
163
|
+
headers[:losantdomain] = params[:losantdomain] if params.has_key?(:losantdomain)
|
164
|
+
query_params[:_actions] = params[:_actions] if params.has_key?(:_actions)
|
165
|
+
query_params[:_links] = params[:_links] if params.has_key?(:_links)
|
166
|
+
query_params[:_embedded] = params[:_embedded] if params.has_key?(:_embedded)
|
167
|
+
|
168
|
+
path = "/applications/#{params[:applicationId]}/experience/views/#{params[:experienceViewId]}/linkedResources"
|
169
|
+
|
170
|
+
@client.request(
|
171
|
+
method: :get,
|
172
|
+
path: path,
|
173
|
+
query: query_params,
|
174
|
+
headers: headers,
|
175
|
+
body: body)
|
176
|
+
end
|
177
|
+
|
128
178
|
# Updates information about an experience view
|
129
179
|
#
|
130
180
|
# Authentication:
|
@@ -1,6 +1,6 @@
|
|
1
1
|
# The MIT License (MIT)
|
2
2
|
#
|
3
|
-
# Copyright (c)
|
3
|
+
# Copyright (c) 2020 Losant IoT, Inc.
|
4
4
|
#
|
5
5
|
# Permission is hereby granted, free of charge, to any person obtaining a copy
|
6
6
|
# of this software and associated documentation files (the "Software"), to deal
|
data/lib/losant_rest/file.rb
CHANGED
@@ -1,6 +1,6 @@
|
|
1
1
|
# The MIT License (MIT)
|
2
2
|
#
|
3
|
-
# Copyright (c)
|
3
|
+
# Copyright (c) 2020 Losant IoT, Inc.
|
4
4
|
#
|
5
5
|
# Permission is hereby granted, free of charge, to any person obtaining a copy
|
6
6
|
# of this software and associated documentation files (the "Software"), to deal
|
data/lib/losant_rest/files.rb
CHANGED
@@ -1,6 +1,6 @@
|
|
1
1
|
# The MIT License (MIT)
|
2
2
|
#
|
3
|
-
# Copyright (c)
|
3
|
+
# Copyright (c) 2020 Losant IoT, Inc.
|
4
4
|
#
|
5
5
|
# Permission is hereby granted, free of charge, to any person obtaining a copy
|
6
6
|
# of this software and associated documentation files (the "Software"), to deal
|
data/lib/losant_rest/flow.rb
CHANGED
@@ -1,6 +1,6 @@
|
|
1
1
|
# The MIT License (MIT)
|
2
2
|
#
|
3
|
-
# Copyright (c)
|
3
|
+
# Copyright (c) 2020 Losant IoT, Inc.
|
4
4
|
#
|
5
5
|
# Permission is hereby granted, free of charge, to any person obtaining a copy
|
6
6
|
# of this software and associated documentation files (the "Software"), to deal
|
@@ -1,6 +1,6 @@
|
|
1
1
|
# The MIT License (MIT)
|
2
2
|
#
|
3
|
-
# Copyright (c)
|
3
|
+
# Copyright (c) 2020 Losant IoT, Inc.
|
4
4
|
#
|
5
5
|
# Permission is hereby granted, free of charge, to any person obtaining a copy
|
6
6
|
# of this software and associated documentation files (the "Software"), to deal
|
@@ -1,6 +1,6 @@
|
|
1
1
|
# The MIT License (MIT)
|
2
2
|
#
|
3
|
-
# Copyright (c)
|
3
|
+
# Copyright (c) 2020 Losant IoT, Inc.
|
4
4
|
#
|
5
5
|
# Permission is hereby granted, free of charge, to any person obtaining a copy
|
6
6
|
# of this software and associated documentation files (the "Software"), to deal
|