1.1.4 • Published 4 years ago

fortnox v1.1.4

Weekly downloads
7
License
MIT
Repository
github
Last release
4 years ago

CircleCI npm version

Fortnox Javascript API wrapper

Unofficial Javascript wrapper for Fortnox API http://developer.fortnox.se/getting-started/

Installation

$ npm install fortnox or yarn install fortnox

Get a developer account

First of all you need to register as a developer.

To register you just need to fill out this form.

Get your Access Token

You’ve got your Authorization-Code and your Client-Secret. These will be the keys to get the final Access-Token.

The Authorization-Code is valid for seven days before becoming invalid and can only be used once to retrieve the Access-Token.

If the Authorization-Code is used again after an Access-Token has been retrieved the Authorization-Code will become invalid and the integration will become deactivated.

The Access-Token combined with the Client-Secret is unique for your application and connects to a specific Fortnox account.

To retrieve your Access-Token you simply send a request to our API using the headers “Authorization-Code” and “Client-Secret”.

Here’s an example using cURL

curl -X "GET" "https://api.fortnox.se/3/" \
     -H "Authorization-Code: YOUR_AUTHORIZATION_CODE" \
     -H "Client-Secret: YOUR_CLIENT_SECRET" \
     -H "Content-Type: application/json" \
     -H "Accept: application/json"

Usage

Create a new fortnox api instance

const fortnox = require('fortnox')
const client = new Fortnox('secret', 'accessToken')

Get Customers

const customers = await client.getCustomers()    
1.1.4

4 years ago

1.1.2

4 years ago

1.1.1

4 years ago

1.1.0

5 years ago

1.0.10

6 years ago

1.0.9

6 years ago

1.0.8

6 years ago

1.0.7

6 years ago

1.0.6

6 years ago

1.0.5

6 years ago

1.0.4

6 years ago

1.0.3

6 years ago

1.0.2

6 years ago

1.0.1

6 years ago

1.0.0

6 years ago