Use the Salesforce IoT REST API to create and manage your orchestrations and contexts and retrieve usage data. An orchestration is the business logic that processes incoming events by using states. A context specifies the data that the orchestration can access: one or more platform events, and optionally, data from an associated Salesforce object. With the Salesforce IoT REST API, you can create, retrieve, update, and delete your orchestrations and contexts. You can retrieve an orchestration instance, delete an instance, and retrieve traffic data. Other tasks that you can perform with an orchestration include activation and deactivation. Monitor your event and instance usage by retrieving usage data.
The Salesforce IoT REST API enables you to get a list of all activities that correlates to matching filter parameters, return a list of all the activities matching the filter designations, create, retrieve, update, and delete orchestrations, contexts and more. Salesforce is a customer relationship management services company that provides a platform for developers to create and scale trusted applications.
Delete the specified context.
Name | Data Type | Description |
---|---|---|
contextId
|
string |
ID of the context to update. |
Get the specified context.
Name | Data Type | Description |
---|---|---|
contextId
|
string |
ID of the context to update. |
Name | Data Type | Description |
---|---|---|
ContextDetailRepresentation
|
Update the designated context using the full context definition specified.
Name | Data Type | Description |
---|---|---|
contextId
|
string |
ID of the context to update. |
Name | Data Type | Description |
---|---|---|
ContextInputRepresentation
|
object |
An input representation of a context. |
description
|
string |
The description of this context. |
events
|
array [object] |
The events used by this context. |
label
|
string |
Context label. |
name
|
string |
Context name. |
referenceData
|
array [object] |
The datasets that are referenced by this context. |
runtime
|
string Allowed values: - HighVolume - Standard |
The runtime for this context. |
Name | Data Type | Description |
---|---|---|
ContextDetailRepresentation
|
List all contexts that have been defined in your org.
Name | Data Type | Description |
---|---|---|
page
|
string |
For internal use only. |
pageSize
|
integer |
The number of contexts returned per page. When one page is returned, it contains the URL in the nextPageUrl property that you use to get the next page of results. |
runtime
|
string Allowed values: - HighVolume - Standard |
The Salesforce IoT runtime used. |
sort
|
string Allowed values: - ContextLabel - Label - LastModified - Status |
Sorting direction, either ascending or descending. |
sortDirection
|
string Allowed values: - Ascending - Descending |
Field name to be sorted. |
Name | Data Type | Description |
---|---|---|
ContextCollectionRepresentation
|
Creates a context.
Name | Data Type | Description |
---|---|---|
ContextInputRepresentation
|
object |
An input representation of a context. |
description
|
string |
The description of this context. |
events
|
array [object] |
The events used by this context. |
label
|
string |
Context label. |
name
|
string |
Context name. |
referenceData
|
array [object] |
The datasets that are referenced by this context. |
runtime
|
string Allowed values: - HighVolume - Standard |
The runtime for this context. |
Name | Data Type | Description |
---|---|---|
ContextDetailRepresentation
|
Get the orchestration activation that was most recently created for this orchestration ID.
Name | Data Type | Description |
---|---|---|
orchestrationId
|
string |
ID of the orchestration to deactivate. |
Name | Data Type | Description |
---|---|---|
OrchestrationActivationDetailRepresentation
|
Deactivate the specified orchestration. Use only to deactivate an active orchestration.
Name | Data Type | Description |
---|---|---|
orchestrationId
|
string |
ID of the orchestration to deactivate. |
Name | Data Type | Description |
---|---|---|
OrchestrationActivationInputRepresentation
|
object |
An orchestration activation request. |
options
|
object |
The orchestration activation options. |
status
|
string Allowed values: - Activating - Active - Deactivating - Error - Inactive - Unknown |
The orchestration activation status. |
Name | Data Type | Description |
---|---|---|
OrchestrationActivationDetailRepresentation
|
Get activation information for the specified orchestration and activation.
Name | Data Type | Description |
---|---|---|
activationId
|
string |
ID of the activation for which to get details. |
orchestrationId
|
string |
ID of the orchestration for which to get activation information. |
Name | Data Type | Description |
---|---|---|
OrchestrationActivationDetailRepresentation
|
Deactivate the specified orchestration activation. No other updates are supported.
Name | Data Type | Description |
---|---|---|
activationId
|
string |
ID of the activation for which to get details. |
orchestrationId
|
string |
ID of the orchestration for which to get activation information. |
Name | Data Type | Description |
---|---|---|
OrchestrationActivationInputRepresentation
|
object |
An orchestration activation request. |
options
|
object |
The orchestration activation options. |
status
|
string Allowed values: - Activating - Active - Deactivating - Error - Inactive - Unknown |
The orchestration activation status. |
Name | Data Type | Description |
---|---|---|
OrchestrationActivationDetailRepresentation
|
Get the activation history for the specified orchestration. The activations are sorted by creation date in descending order.
Name | Data Type | Description |
---|---|---|
orchestrationId
|
string |
ID of the orchestration for which to get the activation history. |
Name | Data Type | Description |
---|---|---|
page
|
string |
For internal use only. |
pageSize
|
integer |
The number of activations returned per page. When a page of the response is returned, it contains the nextPageUrl property which is the URL that you use to get the next page of results. |
Name | Data Type | Description |
---|---|---|
OrchestrationActivationCollectionRepresentation
|
Activate the specified orchestration, optionally using activation options.
Name | Data Type | Description |
---|---|---|
orchestrationId
|
string |
ID of the orchestration for which to get the activation history. |
Name | Data Type | Description |
---|---|---|
OrchestrationActivationInputRepresentation
|
object |
An orchestration activation request. |
options
|
object |
The orchestration activation options. |
status
|
string Allowed values: - Activating - Active - Deactivating - Error - Inactive - Unknown |
The orchestration activation status. |
Name | Data Type | Description |
---|---|---|
OrchestrationActivationDetailRepresentation
|
Delete the orchestration instance corresponding to the specified orchestration and instance key.
Name | Data Type | Description |
---|---|---|
instanceKey
|
string |
The orchestration instance key. The instanceKey is the value of the event key field. |
orchestrationId
|
string |
The orchestration instance ID. |
Get the orchestration instance corresponding to the specified orchestration and instance key.
Name | Data Type | Description |
---|---|---|
instanceKey
|
string |
The orchestration instance key. The instanceKey is the value of the event key field. |
orchestrationId
|
string |
The orchestration instance ID. |
Name | Data Type | Description |
---|---|---|
OrchestrationInstanceDetailRepresentation
|
Get state transition counts for the specified orchestration.
Name | Data Type | Description |
---|---|---|
orchestrationId
|
string |
ID of the orchestration to get transition counts for. |
Name | Data Type | Description |
---|---|---|
OrchestrationTransitionCountCollectionRepresentation
|
object |
A list of orchestration transition counts. |
metrics
|
array [OrchestrationTransitionCountRepresentation] |
A list of orchestration transition counts. |
||||||||||||||||
Properties
|
Delete the orchestration with the specified ID.
Name | Data Type | Description |
---|---|---|
orchestrationId
|
string |
ID of the orchestration to retrieve. |
Get the orchestration for the designated ID.
Name | Data Type | Description |
---|---|---|
orchestrationId
|
string |
ID of the orchestration to retrieve. |
Name | Data Type | Description |
---|---|---|
OrchestrationDetailRepresentation
|
Update the specified orchestration using the full orchestration definition.
Name | Data Type | Description |
---|---|---|
orchestrationId
|
string |
ID of the orchestration to retrieve. |
Name | Data Type | Description |
---|---|---|
OrchestrationInputRepresentation
|
object |
Input representation of an orchestration. |
definition
|
object |
The orchestration definition. |
description
|
string |
The orchestration description. |
label
|
string |
The orchestration label. |
name
|
string |
The orchestration name. |
orchestrationContext
|
object |
The context that is referenced by this orchestration. |
Name | Data Type | Description |
---|---|---|
OrchestrationDetailRepresentation
|
Get a list of Salesforce IoT orchestrations.
Name | Data Type | Description |
---|---|---|
contextId
|
string |
ID of the context to retrieve. |
page
|
string |
For internal use only. |
pageSize
|
integer |
The number of contexts returned per page. When one page is returned, it contains the URL in the nextPageUrl property that you use to get the next page of contexts. |
runtime
|
string Allowed values: - HighVolume - Standard |
The Salesforce IoT runtime used. |
sort
|
string Allowed values: - ContextLabel - Label - LastModified - Status |
Sorting direction, either ascending or descending. |
sortDirection
|
string Allowed values: - Ascending - Descending |
Field name to be sorted. |
Name | Data Type | Description |
---|---|---|
OrchestrationCollectionRepresentation
|
Create an IoT orchestration.
Name | Data Type | Description |
---|---|---|
OrchestrationInputRepresentation
|
object |
Input representation of an orchestration. |
definition
|
object |
The orchestration definition. |
description
|
string |
The orchestration description. |
label
|
string |
The orchestration label. |
name
|
string |
The orchestration name. |
orchestrationContext
|
object |
The context that is referenced by this orchestration. |
Name | Data Type | Description |
---|---|---|
OrchestrationDetailRepresentation
|
Get usage data for each orchestration in the org, including the number of instances, and the number of processed events per orchestration.
Name | Data Type | Description |
---|---|---|
page
|
string |
For internal use only. |
pageSize
|
integer |
The number of items returned per page. When one page is returned, it contains the URL in the nextPageUrl property that you use to get the next page of results. |
Name | Data Type | Description |
---|---|---|
OrchestrationUsageCollectionRepresentation
|
Get the current org-level usage and allocations.
Name | Data Type | Description |
---|---|---|
UsageDetailRepresentation
|
object |
Current org-level usage information. |
allocations
|
AllocationsRepresentation |
Current org-level allocations. |
||||||||||
Properties
|
||||||||||||
eventUsage
|
EventUsageRepresentation |
Current org-level event usage. |
||||||||||
Properties
|
||||||||||||
orchestrationUsageUrl
|
string |
URL for current orchestration usage. |
Org-level allocations for the number of events that can be processed.
Name | Data Type | Description |
---|---|---|
eventAllocation
|
AllocationCountRepresentation |
Allocation for maximum number of events that can be processed by orchestrations in an org. |
instanceAllocation
|
AllocationCountRepresentation |
Allocation for maximum number of instances per orchestration. |
Name | Data Type | Description |
---|---|---|
ContextCollectionRepresentation
|
Name | Data Type | Description |
---|---|---|
ContextDetailRepresentation
|
An input representation of a context.
Name | Data Type | Description |
---|---|---|
description
|
string |
The description of this context. |
events
|
array [object] |
The events used by this context. |
label
|
string |
Context label. |
name
|
string |
Context name. |
referenceData
|
array [object] |
The datasets that are referenced by this context. |
runtime
|
string Allowed values: - HighVolume - Standard |
The runtime for this context. |
Current org-level event usage.
Name | Data Type | Description |
---|---|---|
processedEventCount
|
long |
Number of events processed in the last 24 hours. |
rejectedEventCount
|
long |
Number of events rejected in the last 24 hours. |
Name | Data Type | Description |
---|---|---|
OrchestrationActivationCollectionRepresentation
|
Name | Data Type | Description |
---|---|---|
OrchestrationActivationDetailRepresentation
|
An orchestration activation request.
Name | Data Type | Description |
---|---|---|
options
|
object |
The orchestration activation options. |
status
|
string Allowed values: - Activating - Active - Deactivating - Error - Inactive - Unknown |
The orchestration activation status. |
Name | Data Type | Description |
---|---|---|
OrchestrationCollectionRepresentation
|
Name | Data Type | Description |
---|---|---|
OrchestrationDetailRepresentation
|
Input representation of an orchestration.
Name | Data Type | Description |
---|---|---|
definition
|
object |
The orchestration definition. |
description
|
string |
The orchestration description. |
label
|
string |
The orchestration label. |
name
|
string |
The orchestration name. |
orchestrationContext
|
object |
The context that is referenced by this orchestration. |
Name | Data Type | Description |
---|---|---|
OrchestrationInstanceDetailRepresentation
|
A list of orchestration transition counts.
Name | Data Type | Description | ||||||||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
metrics
|
array [OrchestrationTransitionCountRepresentation] |
A list of orchestration transition counts. |
||||||||||||||||
Properties
|
Orchestration transition count.
Name | Data Type | Description |
---|---|---|
action
|
string |
Transition action. |
count
|
long |
Count. |
fromStateId
|
integer |
From state ID. |
toStateId
|
integer |
To state ID. |
Name | Data Type | Description |
---|---|---|
OrchestrationUsageCollectionRepresentation
|
Current org-level usage information.
Name | Data Type | Description | ||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|---|
allocations
|
AllocationsRepresentation |
Current org-level allocations. |
||||||||||
Properties
|
||||||||||||
eventUsage
|
EventUsageRepresentation |
Current org-level event usage. |
||||||||||
Properties
|
||||||||||||
orchestrationUsageUrl
|
string |
URL for current orchestration usage. |
API Version | 42.0-2018.10.30.10.45 |