Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

@incodelang/accounts

Package Overview
Dependencies
Maintainers
1
Versions
22
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@incodelang/accounts

An API for simple Account Management

  • 1.0.13
  • Source
  • npm
  • Socket score

Version published
Weekly downloads
3
decreased by-40%
Maintainers
1
Weekly downloads
 
Created
Source

@incodelang/accounts

A simple account management server for your node.js application.

Installation

Install @incodelang/accounts with npm

  npm install @incodelang/accounts

Install @incodelang/accounts with yarn

  yarn add @incodelang/accounts

Usage/Examples

Integrate in your own express.js application

const { accountServer } = require('@incodelang/accounts')
const express = require('express')

const app = express();

app.listen(3000, "0.0.0.0");

accountServer({
    app: app
})

Standalone express.js application

const { accountServer, sampleApp } = require('@incodelang/accounts')

accountServer({
    app: sampleApp(
        3000, // port [default] = 3000
        "0.0.0.0" // host [default] = "0.0.0.0"
    )
})

API Reference

The parameters must be send in the request body as JSON format.

User API

ResponseDescription
{"error": false, "message": "response message, e.g. data"}The request was successful
{"error": true, "message": "errror message"}The request failed
Create a user
  POST /api/v1/user/users/create
ParameterTypeDescription
usernamestringThe name of the user
passwordstringThe password of the user
Delete a user
  POST /api/v1/user/users/delete
ParameterTypeDescription
usernamestringThe name of the user
passwordstringThe password of the user
Login
  POST /api/v1/user/users/login
ParameterTypeDescription
usernamestringThe name of the user
passwordstringThe password of the user
Check if a User exists
  POST /api/v1/user/users/exists
ParameterTypeDescription
usernamestringThe name of the user
Update Username
  POST /api/v1/user/users/update/username
ParameterTypeDescription
oldstringThe current name of the user
usernamestringThe new name of the user
passwordstringThe password of the user
Update Password
  POST /api/v1/user/users/update/password
ParameterTypeDescription
usernamestringThe name of the user
passwordstringThe new password of the user
oldstringThe current password of the user
User Data API
Store Data
  POST /api/v1/user/users/data/store
ParameterTypeDescription
usernamestringThe name of the user
passwordstringThe password of the user
datastringThe actual data
dataNamestringThe name of the data
Delete Data
  POST /api/v1/user/users/data/delete
ParameterTypeDescription
usernamestringThe name of the user
passwordstringThe password of the user
dataNamestringThe name of the data
Get Data
  POST /api/v1/user/users/data
ParameterTypeDescription
usernamestringThe name of the user
passwordstringThe password of the user
dataNamestringThe name of the data
Get All Data
  POST /api/v1/user/users/data/delete
ParameterTypeDescription
usernamestringThe name of the user
passwordstringThe password of the user
Global Data API
Set Data
  POST /api/v1/user/data/set
ParameterTypeDescription
usernamestringThe name of the user
passwordstringThe password of the user
valuestringThe actual data
keystringThe name of the data
Delete Data
  POST /api/v1/user/data/delete
ParameterTypeDescription
usernamestringThe name of the user
passwordstringThe password of the user
keystringThe name of the data
Grant Access
  POST /api/v1/user/data/allow
ParameterTypeDescription
usernamestringThe name of the user
passwordstringThe password of the user
keystringThe name of the data
newUserstringThe name of the new user
Revoke Access
  POST /api/v1/user/data/disallow
ParameterTypeDescription
usernamestringThe name of the user
passwordstringThe password of the user
keystringThe name of the data
newUserstringThe name of the new user
Get Public Data
  POST /api/v1/user/data/get
ParameterTypeDescription
usernamestringThe name of the user
passwordstringThe password of the user
keystringThe name of the data
Postboxes API
Create a Postbox
  POST /api/v1/user/postboxes/create
ParameterTypeDescription
usernamestringThe name of the user
passwordstringThe password of the user
namestringThe name of the postbox
Delete a Postbox
  POST /api/v1/user/postboxes/delete
ParameterTypeDescription
usernamestringThe name of the user
passwordstringThe password of the user
namestringThe name of the postbox
Add Data to a Postbox
  POST /api/v1/user/postboxes/add
ParameterTypeDescription
usernamestringThe name of the user
passwordstringThe password of the user
namestringThe name of the postbox
ownerstringThe owner of the postbox
entrystring or objectThe data you want to add
Clear a Postbox
  POST /api/v1/user/postboxes/clear
ParameterTypeDescription
usernamestringThe name of the user
passwordstringThe password of the user
namestringThe name of the postbox
Read a Postbox
  POST /api/v1/user/postboxes/read
ParameterTypeDescription
usernamestringThe name of the user
passwordstringThe password of the user
namestringThe name of the postbox
Check if a Postbox exists
  POST /api/v1/user/postboxes/exists
ParameterTypeDescription
ownerstringThe owner of the postbox
namestringThe name of the postbox

Authors

  • @mctzock

License

GPL-3.0

Keywords

FAQs

Package last updated on 13 Oct 2021

Did you know?

Socket

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.

Install

Related posts

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc