cancel
Showing results for 
Search instead for 
Did you mean: 
cancel
Showing results for 
Search instead for 
Did you mean: 

How can I set "Start Type" within a "AddPropertyDefinition" call?

mneumann
16-Pearl

How can I set "Start Type" within a "AddPropertyDefinition" call?

I have a Remote Thing and want to add its remote properties automatically via a subscription / service.

This works well so far - I go through the GetRemoteMetadata's propertyDefinition and can create a property with correct names, types, categories, thresholds etc.

 

In the AddPropertyDefinition service there is a parameter named remoteBindingAspects

I would suspect I can use it to define the remote binding aspects - as in the UI.

However, most of them have their own parameter, i.e. remotePropertyName, timeout, pushType, pushTreshold etc.

 

There no hint on where to set the Start Type.

It's a default of "Use Default Value" which I need to change to "Read Edge Value" when adding the property.

 

Any ideas or examples for the remoteBindingAspects JSON would be appreciated.

 

Thanks,

Michael

1 ACCEPTED SOLUTION

Accepted Solutions

var remoteBindingAspects = {
    "startType": "readEdgeValue"
};

me.AddPropertyDefinition({
    remoteBindingAspects: remoteBindingAspects /* JSON */,
    [...]
});

 

I browsed through the RemotePropertyDefinitions of properties I've already changed.

This allowed me to use above value to manipulate the aspects on adding a new property.

View solution in original post

1 REPLY 1

var remoteBindingAspects = {
    "startType": "readEdgeValue"
};

me.AddPropertyDefinition({
    remoteBindingAspects: remoteBindingAspects /* JSON */,
    [...]
});

 

I browsed through the RemotePropertyDefinitions of properties I've already changed.

This allowed me to use above value to manipulate the aspects on adding a new property.

Announcements