Security News
Oracle Drags Its Feet in the JavaScript Trademark Dispute
Oracle seeks to dismiss fraud claims in the JavaScript trademark dispute, delaying the case and avoiding questions about its right to the name.
##About
###Description A nodejs module for interacting with the Circle API.
Donations welcomed at: 1CniXdfgpAbM3pYbbLvooRZAGhTEpTMjkN
![1CniXdfgpAbM3pYbbLvooRZAGhTEpTMjkN] (http://chart.apis.google.com/chart?chs=250x250&cht=qr&chld=|1&chl=bitcoin%3A1CniXdfgpAbM3pYbbLvooRZAGhTEpTMjkN)
###Author Norman Joyner - norman.joyner@gmail.com
##Getting Started
###Installation
npm install circle-api
###Configuration Simply require the circle-api module, instantiate a new Circle-Api object, configure it if necessary, and start making calls. The mfa secret and api version are configurable. Your Circle account must be set up to use Google Authenticator, rather than text messaged based MFA.
New Circle-Api objects can be instantiated with configuration parameters. Here is an example:
var CircleApi = require("circle-api");
var circle_api = new CircleApi({
api_version: "v2",
mfa_secret: "NVTGCX3TMVRXEZLU"
});
Circle-Api objects can also be configured via the .configure(options)
method. Here is an exmaple:
var CirlceApi = require("circle-api");
var circle_api = new CircleApi();
var options = {
mfa_secret: "NVTGCX3TMVRXEZLU"
}
circle_api.configure(options);
####Options
api_version
- [optional, defaults to "v2"] version of the API to use
mfa_secret
- [required] totp secret
####Finding MFA Secret Before scanning the Google Authenticator code with your application of choice, first scan the QR code with a QR code app. View the url the QR contains and you will see something similar to: otpauth://totp/Circle%3Ayour%40email.com?secret=NVTGCX3TMVRXEZLU&issuer=Circle
Take notice to what 'secret' is equal to in the url and use this as the mfa_secret
.
###Supported API versions
###Supported API Methods
circle_api.login(options, fn)
circle_api.get_account(fn)
cirlce_api.get_activities(fn)
cirlce_api.get_history(fn)
circle_api.get_address(fn)
circle_api.get_personal_information(fn)
circle_api.get_fiat_accounts(fn)
circle_api.deposit(options, fn)
circle_api.send(options, fn)
circle_api.request(options, fn)
###Examples Before making future API calls, you must first login:
circle_api.login({email: "your@email.com", password: "yourpassword"}, function(err){
if(err)
throw err;
});
Once logged in you can make additional calls.
Fetch account information, and print response:
circle_api.get_account(function(err, account_info){
if(err)
throw err;
console.log(account_info);
});
Fetch account activities, and print response:
circle_api.get_activities(function(err, activities){
if(err)
throw err;
console.log(activities);
});
Fetch account activities, and print response:
circle_api.get_activities(function(err, activities){
if(err)
throw err;
console.log(activities);
});
Fetch account history, and print response:
circle_api.get_history(function(err, history){
if(err)
throw err;
console.log(history);
});
Get bitcoin address, and print response:
circle_api.get_address(function(err, address){
if(err)
throw err;
console.log(address);
});
Get personal information, and print response:
circle_api.get_personal_information(function(err, pii){
if(err)
throw err;
console.log(pii);
});
Get fiat accounts, and print response:
circle_api.get_fiat_accounts(function(err, accounts){
if(err)
throw err;
console.log(accounts);
});
Deposit $1 from fiat account, and print response:
circle_api.deposit({"fiat_address": "fiat-account-address", amount: 1.0}, function(err, response){
if(err)
throw err;
console.log(response);
});
Send $1 to bitcoin address (or email address), and print response:
circle_api.send({"address": "1CniXdfgpAbM3pYbbLvooRZAGhTEpTMjkN", amount: 1.0}, function(err, response){
if(err)
throw err;
console.log(response);
});
Request $1 from email address, and print response:
circle_api.request({"email": "someones@email.com", amount: 1.0}, function(err, response){
if(err)
throw err;
console.log(response);
});
FAQs
A nodejs module for interacting with the Circle API
The npm package circle-api receives a total of 0 weekly downloads. As such, circle-api popularity was classified as not popular.
We found that circle-api demonstrated a not healthy version release cadence and project activity because the last version was released a year ago. It has 1 open source maintainer 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.
Security News
Oracle seeks to dismiss fraud claims in the JavaScript trademark dispute, delaying the case and avoiding questions about its right to the name.
Security News
The Linux Foundation is warning open source developers that compliance with global sanctions is mandatory, highlighting legal risks and restrictions on contributions.
Security News
Maven Central now validates Sigstore signatures, making it easier for developers to verify the provenance of Java packages.