Jump to content

Welcome to Smart Home Forum by FIBARO

Dear Guest,

 

as you can notice parts of Smart Home Forum by FIBARO is not available for you. You have to register in order to view all content and post in our community. Don't worry! Registration is a simple free process that requires minimal information for you to sign up. Become a part of of Smart Home Forum by FIBARO by creating an account.

 

As a member you can:

  •     Start new topics and reply to others
  •     Follow topics and users to get email updates
  •     Get your own profile page and make new friends
  •     Send personal messages
  •     ... and learn a lot about our system!

 

Regards,

Smart Home Forum by FIBARO Team


  • 0

Forwarding Sensor Data and Power Data to 3rd party logger


Question

Posted (edited)

Hi All,

 

I need some help on how can I forward the HC2 data sets to my splunk enterprise data lake. In splunk it has a restapi that i can post message to it.

  • Clamp Reading
  • Event (on/off switch etc)

 

i am not well verse on lua language hence would appreciate someone could let me know how do to that.

 

For example i am using curl to forward the data to my splunk logger,

 

  • curl -X POST -k -H 'Authorization: Splunk 611df2f7-xxxxx-xxxxx-xxxx-xxxxx' -i 'https://hostname:1234/services/collector/raw' --data 'field1=somedata field2=somedata field3=somedata'

 

the condition in splunk to receive the key value pair representation is "key=value" hence i believe i need to write something to copy the value from hc2 store it in a var and then change ":" to "=" to post it to my splunk

 

 

Edited by mondster

8 answers to this question

Recommended Posts

  • 0
Posted

swagger

http://192.168.1.36/docs/#!/consumption/getEnergy

 

192.168.1.36 - HC IPAdrress

  • 0
  • Inquirer
  • Posted (edited)

    I saw  a post which this person done by pulling the value from the scenes and post to the url.

     

    but i like to know if i can post using scense?

     

    i saw one example here,

     

    Please login or register to see this link.

     

    I need somehelp to convert my initial post curl into something that can work in lua scense

    Edited by mondster
    update content
    • 0
  • Inquirer
  • Posted

    got the curl script working, am able to export the sensor data out to my splunk collector and perform a live monitoring.

     

    Please login or register to see this attachment.

    • 0
  • Inquirer
  • Posted

    Manage to add in more data into my datalake. more to come.

     

    Please login or register to see this attachment.

    • 0
    Posted

    Would you mind sharing you configuration as it would be really helpful! (I am a noob)

    • 0
  • Inquirer
  • Posted

    do you already have splunk installed:?

    • 0
    Posted

    No

    • 0
  • Inquirer
  • Posted

    not sure how technical are you, but if you are very technical then you can first explore how splunk works and do a trail installation which gives you 500mb of data ingestion dialy. once you get hold of that then next step would be simple. as you are just writing your own kv and store it in splunk.

    Join the conversation

    You can post now and register later. If you have an account, sign in now to post with your account.

    Guest
    Answer this question...

    ×   Pasted as rich text.   Paste as plain text instead

      Only 75 emoji are allowed.

    ×   Your link has been automatically embedded.   Display as a link instead

    ×   Your previous content has been restored.   Clear editor

    ×   You cannot paste images directly. Upload or insert images from URL.

    ×
    ×
    • Create New...