# Javascript for writing to InfluxDB via HTTP API

**URL:** <https://community.influxdata.com/t/javascript-for-writing-to-influxdb-via-http-api/3083>\
**Category:** Store\
**Created:** [November 14, 2017, 4:43am UTC](https://community.influxdata.com/t/javascript-for-writing-to-influxdb-via-http-api/3083 "2017-11-14T04:43:47Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![Eric](https://avatars.discourse-cdn.com/v4/letter/e/898d66/32.png) [@Eric](https://community.influxdata.com/u/Eric)\
**Post date:** [November 14, 2017, 4:43am UTC](https://community.influxdata.com/t/javascript-for-writing-to-influxdb-via-http-api/3083/1 "2017-11-14T04:43:47Z")

</div>

I see the InfluxDB documentation for using the Influxdb JavaScript library to write the database. Does anyone have any javascript code to write to inject data into a series using the HTTP API?

I’m trying to use the javascript functionality inside Text panels in Grafana to create push buttons on the dashboard. I want these push buttons to inject data into existing series. These text buttons only allow javascript for click events, so I can’t execute a shell script, for example.
