Research
Security News
Malicious npm Package Targets Solana Developers and Hijacks Funds
A malicious npm package targets Solana developers, rerouting funds in 2% of transactions to a hardcoded address.
@planet-a/affinity-node
Advanced tools
Node module for the Affinity CRM.
This module is incomplete; not all API endpoints are implemented. It is in active development and the API might change without notice. Contributions welcome.
Note: Currently only supporting V1. See section on V2 below.
import { Affinity } from '@planet-a/affinity-node/v1'
const { user } = await new Affinity(YOUR_API_KEY).auth.whoAmI()
console.log(`Hello ${user.firstName}`)
Have a look at the autogenerated docs for examples, etc.
A preliminary generator for V2 can be executed via
nix develop --command deno task generate-v2-client
which will generate an OpenAPI client for Node in Typescript.
If you have V2 API access, give it a try and report back here, please 🙏.
An up-to-date OpenAPI spec can be downloaded from
here. Drop it
into ./openapi
before you run the command above (remove the old version
beforehand).
Note on deno: This repository is using Deno heavily for anything dev-related. The resulting node package is meant to be agnostic of the runtime used, so there shouldn't be any deno-specific references. For the tests, etc. Deno-specific APIs, libraries and imports may be used.
nix develop
deno task test
Hint: you can do a live run via
API_KEY=<your-api-key> deno task snapshot-update
to update snapshots from your actual Affinity instance during development.⚠️ Make sure you do not commit any unsanitized data.
This repo is direnv-enabled. If you have Nix and direnv
on your system, you can ignore any nix develop --command
prefixes and just
work in the folder as if you were inside the nix flake environment. This is the
recommended way, as it greatly simplifies the handling of dev tasks and
pre-commit checks.
nix develop --command deno task build
nix develop --command deno task test:coverage
nix develop --command deno task format
nix develop --command deno task lint
nix develop --command deno task docs
open ./docs/index.html
snake_case
camelCase
snake_case
SNAKE_UPPERCASE
This repo follows the
conventional commits format. Run
nix develop --command cz commit
after staging some changes to be guided
through the process if you're unfamiliar with it.
Pre-commit hooks are managed by Nix. Once you run your commit, it will analyze the changes and run required hooks.
FAQs
API wrapper for the affinity.co API
The npm package @planet-a/affinity-node receives a total of 1 weekly downloads. As such, @planet-a/affinity-node popularity was classified as not popular.
We found that @planet-a/affinity-node demonstrated a healthy version release cadence and project activity because the last version was released less than a year ago. It has 0 open source maintainers collaborating on the project.
Did you know?
Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.
Research
Security News
A malicious npm package targets Solana developers, rerouting funds in 2% of transactions to a hardcoded address.
Security News
Research
Socket researchers have discovered malicious npm packages targeting crypto developers, stealing credentials and wallet data using spyware delivered through typosquats of popular cryptographic libraries.
Security News
Socket's package search now displays weekly downloads for npm packages, helping developers quickly assess popularity and make more informed decisions.