{"id":22608967,"url":"https://github.com/bitfinexcom/bfx-hf-util","last_synced_at":"2025-04-11T06:15:03.541Z","repository":{"id":54849237,"uuid":"143998116","full_name":"bitfinexcom/bfx-hf-util","owner":"bitfinexcom","description":null,"archived":false,"fork":false,"pushed_at":"2021-07-26T12:51:39.000Z","size":89,"stargazers_count":5,"open_issues_count":3,"forks_count":12,"subscribers_count":6,"default_branch":"master","last_synced_at":"2025-04-11T06:14:58.710Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"language":"JavaScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"apache-2.0","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/bitfinexcom.png","metadata":{"files":{"readme":"README.md","changelog":"CHANGELOG","contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2018-08-08T10:28:50.000Z","updated_at":"2021-07-26T12:51:42.000Z","dependencies_parsed_at":"2022-08-14T04:40:46.124Z","dependency_job_id":null,"html_url":"https://github.com/bitfinexcom/bfx-hf-util","commit_stats":null,"previous_names":[],"tags_count":9,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/bitfinexcom%2Fbfx-hf-util","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/bitfinexcom%2Fbfx-hf-util/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/bitfinexcom%2Fbfx-hf-util/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/bitfinexcom%2Fbfx-hf-util/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/bitfinexcom","download_url":"https://codeload.github.com/bitfinexcom/bfx-hf-util/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":248351393,"owners_count":21089272,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":[],"created_at":"2024-12-08T15:10:23.598Z","updated_at":"2025-04-11T06:15:03.517Z","avatar_url":"https://github.com/bitfinexcom.png","language":"JavaScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"## Bitfinex Honey Framework Utilities\n\n[![Build Status](https://travis-ci.org/bitfinexcom/bfx-hf-util.svg?branch=master)](https://travis-ci.org/bitfinexcom/bfx-hf-util)\n\nThis library hosts a set of utility functions used throughout the Bitfinex Honey Framework \u0026 API Libraries.\n\n### Features\n\n* Logic for processing Bitfinex candle data\n* Helper for catching uncaught errors (`require('bfx-hf-util/lib/catch_uncaught_errors)`)\n\n### Installation\n\n```bash\nnpm i --save bfx-hf-util\n```\n\n### Quickstart\n\n```js\nconst { preprocessRemoteCandles } = require('bfx-hf-util')\nconst { RESTv2 } = require('bfx-api-node-rest')\n\nconst rest = new RESTv2()\nconst candles = await rest.candles({\n  timeframe: '1m',\n  symbol: 'tBTCUSD',\n  query: {\n    start: Date.now() - (24 * 60 * 60 * 1000),\n    end: Date.now(),\n    sort: 1,\n  }\n})\n\n// Fill in empty candles to generate a consistent dataset\nconst processedCandles = preprocessRemoteCandles('1m', candles)\n\n// Do something with data\nprocessCandles.forEach(candle =\u003e console.log(JSON.stringify(candle)))\n```\n\n### Docs\n\nFor JSDoc-generated API documentation, [refer to `docs/api.md`](/docs/api.md)\n\n### Contributing\n\n1. Fork it\n2. Create your feature branch (`git checkout -b my-new-feature`)\n3. Commit your changes (`git commit -am 'Add some feature'`)\n4. Push to the branch (`git push origin my-new-feature`)\n5. Create a new Pull Request\n\n### Note\n\nThis package will be maintained only via github, please use latest relases from github instead of npm.\n\nExample on how to install specific version from github:\n```\nnpm i --save-prod https://github.com/bitfinexcom/bfx-hf-util.git#v1.0.11\n```\n\nExample on how to install it latest version from github:\n```\nnpm i --save-prod https://github.com/bitfinexcom/bfx-hf-util.git\n```\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fbitfinexcom%2Fbfx-hf-util","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fbitfinexcom%2Fbfx-hf-util","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fbitfinexcom%2Fbfx-hf-util/lists"}