npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2026 – Pkg Stats / Ryan Hefner

@datafire/nexmo_subaccounts

v3.0.0

Published

DataFire integration for Subaccounts API

Downloads

7

Readme

@datafire/nexmo_subaccounts

Client library for Subaccounts API

Installation and Usage

npm install --save @datafire/nexmo_subaccounts
let nexmo_subaccounts = require('@datafire/nexmo_subaccounts').create({
  username: "",
  password: ""
});

.then(data => {
  console.log(data);
});

Description

The Subaccounts API enables you to create subaccounts under your primary account. Subaccounts facilitate differential product configuration, reporting, and billing. The Subaccounts API is released initially with restricted availability. You can read more about the API in the Subaccounts documentation.

Actions

retrieveBalanceTransfers

Retrieve a list of balance transfers that have taken place for a primary account within a specified time period.

nexmo_subaccounts.retrieveBalanceTransfers({
  "api_key": "",
  "start_date": ""
}, context)

Input

  • input object
    • api_key required string: ID of the primary account.
    • start_date required string: Start of the retrieval period.
    • end_date string: End of the retrieval period. If absent then all transfers until now is returned.
    • subaccount string: Subaccount to filter by. You may send this multiple times to filter on multiple subaccounts

Output

transferBalance

Transfer balance between a primary account and one of its subaccounts. Note that balance_available_for_transfer = |account_balance - credit_limit| of the source account.

nexmo_subaccounts.transferBalance({
  "api_key": "",
  "body": {
    "from": "",
    "to": "",
    "amount": 0
  }
}, context)

Input

Output

retrieveCreditTransfers

Retrieve a list of credit transfers that have taken place for a primary account within a specified time period.

nexmo_subaccounts.retrieveCreditTransfers({
  "api_key": "",
  "start_date": ""
}, context)

Input

  • input object
    • api_key required string: ID of the primary account.
    • start_date required string: Start of the retrieval period.
    • end_date string: End of the retrieval period. If absent then all transfers until now is returned.
    • subaccount string: Subaccount to filter by. You may send this multiple times to filter on multiple subaccounts

Output

transferCredit

Transfer credit limit between a primary account and one of its subaccounts.

nexmo_subaccounts.transferCredit({
  "api_key": "",
  "body": {
    "from": "",
    "to": "",
    "amount": 0
  }
}, context)

Input

Output

retrieveSubaccountsList

Get the information of all the subaccounts owned by the primary account.

nexmo_subaccounts.retrieveSubaccountsList({
  "api_key": ""
}, context)

Input

  • input object
    • api_key required string: ID of the primary account

Output

createSubAccount

Create a subaccount for a given primary account.

nexmo_subaccounts.createSubAccount({
  "api_key": "",
  "body": {
    "name": ""
  }
}, context)

Input

Output

retrieveSubaccount

Get the information of a subaccount specified with its API key.

nexmo_subaccounts.retrieveSubaccount({
  "api_key": "",
  "subaccount_key": ""
}, context)

Input

  • input object
    • api_key required string: ID of the primary account
    • subaccount_key required string: ID of the subaccount

Output

modifySubaccount

Change one or more properties of a subaccount.

nexmo_subaccounts.modifySubaccount({
  "api_key": "",
  "subaccount_key": "",
  "body": {}
}, context)

Input

  • input object
    • api_key required string: ID of the primary account
    • subaccount_key required string: ID of the subaccount
    • body required ModifySubaccountRequest

Output

Definitions

ListBalanceTransfersResponse

ListCreditTransfersResponse

ModifySubaccountRequest

  • ModifySubaccountRequest object
    • name string
    • suspended boolean
    • use_primary_account_balance boolean

NewSubaccountRequest

  • NewSubaccountRequest object
    • name required string
    • secret string
    • use_primary_account_balance boolean

SubaccountCreateResponse

  • SubaccountCreateResponse
    • secret string: API secret of the subaccount.
    • api_key string: Unique subaccount ID.
    • balance number: Balance of the subAccount. Value is null if balance is shared with primary account.
    • created_at string: Subaccount creation date and time.
    • credit_limit number: Credit limit of the subAccount. Value is null if balance is shared with primary account.
    • name string: Name of the subaccount.
    • primary_account_api_key string: Unique primary account ID.
    • suspended boolean: Subaccount suspension status.
    • use_primary_account_balance boolean: Flag showing if balance is shared with primary account.

SubaccountResponse

  • SubaccountResponse object
    • api_key string: Unique subaccount ID.
    • balance number: Balance of the subAccount. Value is null if balance is shared with primary account.
    • created_at string: Subaccount creation date and time.
    • credit_limit number: Credit limit of the subAccount. Value is null if balance is shared with primary account.
    • name string: Name of the subaccount.
    • primary_account_api_key string: Unique primary account ID.
    • suspended boolean: Subaccount suspension status.
    • use_primary_account_balance boolean: Flag showing if balance is shared with primary account.

SubaccountsAllResponse

TransferBalanceOrCreditRequest

  • TransferBalanceOrCreditRequest object
    • amount required number
    • from required string
    • reference string
    • to required string

TransferBalanceResponse

  • TransferBalanceResponse object
    • amount number: Balance transfer amount
    • balance_transfer_id string: Unique balance transfer ID
    • created_at string: The date and time when the balance transfer was executed
    • from string: Account the balance is transferred from
    • reference string: Reference for the balance transfer
    • to string: Account the balance is transferred to

TransferCreditResponse

  • TransferCreditResponse object
    • amount number: Credit transfer amount
    • created_at string: The date and time when the credit transfer was executed
    • credit_transfer_id string: Unique credit transfer ID
    • from string: Account the credit is transferred from
    • reference string: Reference for the credit transfer
    • to string: Account the credit is transferred to