Skip to main content
POST
/
integrations
/
{integration}
/
connection
Import a partner-supplied OAuth connection
curl --request POST \
  --url https://sandbox.nmbr.co/services/payroll/integrations/{integration}/connection \
  --header 'Authorization: Bearer <token>' \
  --header 'Content-Type: application/json' \
  --data '
{
  "business_entity_id": "<id>",
  "access_token": "<partner_access_token>",
  "access_token_expires_in": 3600,
  "refresh_token": "<partner_refresh_token>",
  "refresh_token_expires_in": 5184000
}
'
{
  "id": "<id>",
  "object": "integration",
  "data": {
    "label": "Xero",
    "is_enabled": true,
    "type": "accounting"
  },
  "links": {
    "self": "/integrations/xero"
  }
}

Authorizations

Authorization
string
header
required

Bearer authentication header of the form Bearer <token>, where <token> is your auth token.

Path Parameters

integration
string
required

Body

application/json
business_entity_id
string
required
access_token
string
required

OAuth access token issued by the partner's QBO/Xero app for the customer.

access_token_expires_in
number<decimal>
required

Lifetime of the access token, in seconds.

Required range: x >= 0
refresh_token
string
required

Long-lived refresh token paired with the access token.

refresh_token_expires_in
number<decimal>
required

Lifetime of the refresh token, in seconds.

Required range: x >= 0
realm_id
string

QuickBooks company id (QBO realmId). Required for QuickBooks, ignored for Xero.

Response

200 - application/json

OK

id
string
read-only

The unique identifier of the object in Nmbr.

object
string
read-only

The type of the object in Nmbr ("integration").

data
Integration · object