feat: Add Be and tbd skill, also added Roadmap file

This commit is contained in:
2026-05-10 16:32:12 -04:00
parent 3500ade13f
commit 0bb8885802
29587 changed files with 10611695 additions and 0 deletions

View File

@@ -0,0 +1 @@
node_modules

108
Skills/@be/node_modules/@jibo/analytics-node/History.md generated vendored Normal file
View File

@@ -0,0 +1,108 @@
2.4.1 / 2017-05-05
==================
* Preventing webpack to bundle all lodash lib (#94)
* README: fix header
* README: fix badge
* package: upgrade dependencies (#89)
* standard (#88)
* yarn (#85)
* analytics-node.js@2.4.0 [ci skip]
2.4.0 / 2017-03-13
==================
* test: add `_metadata` to "screen" assertion (#87)
* replace Travis with CircleCI (#86)
* add support for screen events (#82)
* use correct optional syntax for JSDOC (#83)
2.3.0 / 2017-03-13
==================
* Add node version to messages via _metadata (#84)
* remove trailing slash on `.host` (#81)
2.2.0 / 2017-02-06
==================
* Replace validation with `@segment/loosely-validate-event`
* add releasing notes
2.1.1 / 2017-01-31
==================
* Merge pull request #74 from alexstrat/master
* Update dependencies
2.1.0 / 2016-03-31
==================
* adding a cli
2.0.2 / 2016-03-03
==================
* updating travis.yml
* increase messageId entropy, and include one id per message
2.0.1 / 2015-12-11
==================
* makefile: changing bin paths and nsp target
* Upgraded vulnerable dependencies and minor change in the tests to support them
* Adding Node Security Project support
2.0.0 / 2015-09-21
==================
* update analytics-node.js
* Remove proxy support
* Merge pull request #47 from yorkie/patch-1
* remove the duplicated keyword
1.2.2 / 2015-03-19
==================
* Update analytics-node.js
1.2.1 / 2015-03-19
==================
* Try to retry a few times before responding
1.2.0 / 2015-02-18
==================
* add browserify support
* Add installation instructions to readme
1.1.1 / 2015-02-03
==================
* Add sentAt
1.l.0 - 2014-08-22
==================
* add: proxy requests
1.0.4 - 2014-08-14
==================
* fix: given contexts to extended and not wiped out
1.0.3 - 2014-08-05
==================
* fix: context data being added to messages
1.0.2 - 2014-07-23
==================
* update: debug dependency
0.6.0 - February 19, 2014
-------------------------
* add group method

37
Skills/@be/node_modules/@jibo/analytics-node/README.md generated vendored Normal file
View File

@@ -0,0 +1,37 @@
# analytics-node
[![CircleCI](https://circleci.com/gh/segmentio/analytics-node.svg?style=svg&circle-token=68654e8cd0fcd16b1f3ae9943a1d8e20e36ae6c5)](https://circleci.com/gh/segmentio/analytics-node)
A node.js client for [Segment](https://segment.com) — The hassle-free way to integrate analytics into any application.
## Installation
```bash
$ yarn install --save analytics-node
```
## Documentation
Documentation is available at [https://segment.com/libraries/node](https://segment.com/libraries/node).
## License (MIT)
WWWWWW||WWWWWW
W W W||W W W
||
( OO )__________
/ | \
/o o| MIT \
\___/||_||__||_|| *
|| || || ||
_||_|| _||_||
(__|__|(__|__|
Copyright &copy; 2013 Segment Inc. \<friends@segment.com\>
Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the 'Software'), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions:
The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.
THE SOFTWARE IS PROVIDED 'AS IS', WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.

View File

@@ -0,0 +1,73 @@
interface Integrations {
[index: string]: boolean;
}
declare class Analytics {
constructor(writeKey: string, opts?: {
flushAt?: number,
flushAfter?: number
});
/* The identify method lets you tie a user to their actions and record
traits about them. */
identify(message: {
userId: string | number;
traits?: Object;
timestamp?: Date;
context?: Object;
integrations?: Integrations;
}): Analytics;
/* The track method lets you record the actions your users perform. */
track(message: {
userId: string | number;
event: string;
properties?: Object;
timestamp?: Date;
context?: Object;
integrations?: Integrations;
}): Analytics;
/* The page method lets you record page views on your website, along with
optional extra information about the page being viewed. */
page(message: {
userId: string | number;
category?: string;
name?: string;
properties?: Object;
timestamp?: Date;
context?: Object;
integrations?: Integrations;
}): Analytics;
/* alias is how you associate one identity with another. */
alias(message: {
previousId: string | number;
userId: string | number;
integrations?: Integrations;
}): Analytics;
/* Group calls can be used to associate individual users with shared
accounts or companies. */
group(message: {
userId: string | number;
groupId: string | number;
traits?: Object;
context?: Object;
timestamp?: Date;
anonymous_id?: string | number;
integrations?: Integrations;
}): Analytics;
/* Flush batched calls to make sure nothing is left in the queue */
flush(fn?: (err: Error, batch: {
batch: Array<{
type: string;
}>;
messageId: string;
sentAt: Date;
timestamp: Date;
}) => void): Analytics;
}
export = Analytics;

View File

@@ -0,0 +1,238 @@
var assert = require('assert')
var axios = require('axios');
var clone = require('clone')
var noop = function () {}
var uid = require('crypto-token')
var version = require('../package.json').version
var validate = require('@segment/loosely-validate-event')
var removeSlash = require('remove-trailing-slash')
global.setImmediate = global.setImmediate || process.nextTick.bind(process)
/**
* Expose an `Analytics` client.
*/
module.exports = Analytics
/**
* Initialize a new `Analytics` with your Segment project's `writeKey` and an
* optional dictionary of `options`.
*
* @param {String} writeKey
* @param {Object} [options] (optional)
* @property {Number} flushAt (default: 20)
* @property {Number} flushAfter (default: 10000)
* @property {String} host (default: 'https://api.segment.io')
*/
function Analytics (writeKey, options) {
if (!(this instanceof Analytics)) return new Analytics(writeKey, options)
assert(writeKey, 'You must pass your Segment project\'s write key.')
options = options || {}
this.queue = []
this.writeKey = writeKey
this.host = removeSlash(options.host || 'https://api.segment.io')
this.flushAt = Math.max(options.flushAt, 1) || 20
this.flushAfter = options.flushAfter || 10000
}
/**
* Send an identify `message`.
*
* @param {Object} message
* @param {Function} [fn] (optional)
* @return {Analytics}
*/
Analytics.prototype.identify = function (message, fn) {
validate(message, 'identify')
this.enqueue('identify', message, fn)
return this
}
/**
* Send a group `message`.
*
* @param {Object} message
* @param {Function} [fn] (optional)
* @return {Analytics}
*/
Analytics.prototype.group = function (message, fn) {
validate(message, 'group')
this.enqueue('group', message, fn)
return this
}
/**
* Send a track `message`.
*
* @param {Object} message
* @param {Function} [fn] (optional)
* @return {Analytics}
*/
Analytics.prototype.track = function (message, fn) {
validate(message, 'track')
this.enqueue('track', message, fn)
return this
}
/**
* Send a page `message`.
*
* @param {Object} message
* @param {Function} [fn] (optional)
* @return {Analytics}
*/
Analytics.prototype.page = function (message, fn) {
validate(message, 'page')
this.enqueue('page', message, fn)
return this
}
/**
* Send a screen `message`.
*
* @param {Object} message
* @param {Function} fn (optional)
* @return {Analytics}
*/
Analytics.prototype.screen = function (message, fn) {
validate(message, 'screen')
this.enqueue('screen', message, fn)
return this
}
/**
* Send an alias `message`.
*
* @param {Object} message
* @param {Function} [fn] (optional)
* @return {Analytics}
*/
Analytics.prototype.alias = function (message, fn) {
validate(message, 'alias')
this.enqueue('alias', message, fn)
return this
}
/**
* Flush the current queue and callback `fn(err, batch)`.
*
* @param {Function} [fn] (optional)
* @return {Analytics}
*/
Analytics.prototype.flush = function (fn) {
fn = fn || noop
if (!this.queue.length) return setImmediate(fn)
var items = this.queue.splice(0, this.flushAt)
var fns = items.map(function (_) { return _.callback })
var batch = items.map(function (_) { return _.message })
var data = {
batch: batch,
timestamp: new Date(),
sentAt: new Date()
}
var retries = 3;
var errCodes = [
'ECONNRESET',//Connection reset
'ECONNREFUSED',//Connection refused
'ETIMEDOUT',//Timeout
'EADDRINFO',//Can't get address info
'ESOCKETTIMEDOUT'//Socket timeout
];
var responseErrs = [
500,//internal server error
502,//Bad gateway error
503,
504
];
var _this = this;
function send() {
let err, response;
axios.post(_this.host + '/v1/batch', data, {
auth: {
username: _this.writeKey,
password: ''
},
})
.then(r => response = r)
.catch(e => {
response = e.response
err = e
})
.then(() => {
//if further retries allowed and we think that trying again could succeed, then try again
if (retries-- > 0 &&
((err && errCodes.indexOf(err.code) >= 0) ||
(response && responseErrs.indexOf(response.status) >= 0))) {
send();
} else {
err = err || error(response)
fns.push(fn)
fns.forEach(function (fn) { fn(err, data) })
}
});
}
//send the first time
send();
}
/**
* Add a `message` of type `type` to the queue and check whether it should be
* flushed.
*
* @param {String} type
* @param {Object} message
* @param {Functino} [fn] (optional)
* @api private
*/
Analytics.prototype.enqueue = function (type, message, fn) {
fn = fn || noop
message = clone(message)
message.type = type
message.context = Object.assign(message.context || {}, {
library: {
name: 'analytics-node',
version: version
}
})
message._metadata = Object.assign(message._metadata || {}, { nodeVersion: process.versions.node })
if (!message.timestamp) message.timestamp = new Date()
if (!message.messageId) message.messageId = 'node-' + uid(32)
this.queue.push({
message: message,
callback: fn
})
if (this.queue.length >= this.flushAt) this.flush()
if (this.timer) clearTimeout(this.timer)
if (this.flushAfter) this.timer = setTimeout(this.flush.bind(this), this.flushAfter)
}
/**
* Get an error from a `res`.
*
* @param {Object} res
* @return {String}
*/
function error (res) {
if (!res || !res.body || !res.body.error) return
var body = res.data
var msg = (body.error && body.error.message) || res.statusText + ' ' + res.data
return new Error(msg)
}

View File

@@ -0,0 +1,39 @@
{
"name": "@jibo/analytics-node",
"version": "3.0.6",
"description": "The hassle-free way to integrate analytics into any node application.",
"keywords": [
"analytics",
"segment.io",
"segmentio",
"client",
"driver"
],
"typings": "index.d.ts",
"main": "lib/index.js",
"dependencies": {
"@segment/loosely-validate-event": "^1.1.2",
"axios": "mividtim/axios#jibo",
"clone": "^2.1.1",
"crypto-token": "^1.0.1",
"remove-trailing-slash": "^0.1.0"
},
"engines": {
"node": ">= 0.12.x"
},
"repository": {
"type": "git",
"url": "git@github.jibo.com:sdk/sdk.git"
},
"publishConfig": {
"registry": "http://npm.jibo.com:8080"
},
"files": [
"lib/index.js",
"index.d.ts",
"package.json"
],
"license": "UNLICENSED",
"distribution": "PROPRIETARY AND CONFIDENTIAL - NOT FOR DISTRIBUTION",
"copyright": "Copyright (c) 2014-2018 Jibo, Inc. All Rights Reserved"
}