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

Community Tip - Need to share some code when posting a question or reply? Make sure to use the "Insert code sample" menu option. Learn more! X

How to get the initial creation date/time of a thing ?

orhand
2-Guest

How to get the initial creation date/time of a thing ?

Is there a way, or a service to get the initial creation date/time of a thing ?

Orhan

1 ACCEPTED SOLUTION

Accepted Solutions

Hi Orhan,

You can do it this way:

var confChanges = Things["yourThingName"].GetConfigurationChangeHistory();

confChanges.Filter({ changeAction: "CREATE"});

var creationDate = confChanges.rows[0].timestamp;

Best Regards,

Carles.

View solution in original post

2 REPLIES 2

Hi Orhan,

You can do it this way:

var confChanges = Things["yourThingName"].GetConfigurationChangeHistory();

confChanges.Filter({ changeAction: "CREATE"});

var creationDate = confChanges.rows[0].timestamp;

Best Regards,

Carles.

Thanks a lot ! It worked..

Regards,

Orhan

Top Tags