Aller au contenu
Log in

Account

Ce contenu n’est pas encore disponible dans votre langue.

The Accounts API allows you to list, create, retrieve, update, delete, and unarchive accounts.

Since functionality varies between eDocSync and eDocExchange subscriptions, it’s important to understand how adding accounts may impact your subscription’s costs and limits.

With eDocSync, you can create and manage accounts for your users directly via the API.

Things to consider before adding accounts:

  • Cost: Adding accounts may result in additional charges, depending on your current subscription and total number of accounts.
  • Transaction limit: The group of accounts has a shared transaction limit. With eDocSync, the group limit is the number of transactions included per account in your subscription multiplied by the number of accounts in the group: with n accounts and q included transactions per account, the group limit is n × q. This is why the limit rises on its own every time you create an account, and an archived account keeps counting until the current billing period ends. If the group exceeds the limit, extra charges will be applied per transaction.
  • Modifications: The subscription transaction limit cannot be changed through the API. To request a change, please submit a support ticket to request a change in your subscription.

With eDocExchange, you cannot create, delete/archive or unarchive accounts via the API. Instead, this must be done through the web application:

  1. Go to the Developers tab.
  2. Click the Edit group icon next to your group name.
  3. From there, you can add or delete accounts.

Notes: To add or remove accounts, you must have Admin or Owner permissions of the account with the subscription and the account you want to add. Before adding an account to the group, make sure it has been created with the Basic plan.

Things to consider before adding accounts:

  • Cost: Adding an account results in a one-time additional cost.
  • Transaction limit: The group of accounts has a shared transaction limit. With eDocExchange, the group limit is the one of your subscription: a single total for the whole group, not multiplied by the number of accounts. Adding accounts does not raise it. If the group exceeds the limit, extra charges will be applied per transaction.
  • Modifications: The transaction limit cannot be changed through the API. If the web application doesn’t offer the option to upgrade your tier in the subscription section, please submit a support ticket to request a change in your subscription.

Every account returned by GET /accounts and GET /accounts/{id} carries three fields about transactions. Read them this way:

  • transactions_limit is the limit of the group, not of that account. This is why every account in the group shows the same value.
  • transactions_count and transactions_count_previous_period are the consumption of that account, in the current and in the previous billing period.

The limit applies to the consumption of the whole group. See what counts as a billable transaction and an example response in Transaction.

Example request:

Terminal window
curl --request POST \
--url https://api-staging.b2brouter.net/accounts \
--header 'X-B2B-API-KEY: {API_KEY}' \
--header 'X-B2B-API-Version: {API_VERSION}' \
--header 'accept: application/json' \
--header 'content-type: application/json' \
--data '{
"account": {
"country": "de",
"rounding_method": "half_up",
"tin_scheme": 9930,
"tin_value": "DE123456789",
"name": "Muster GmbH",
"address": "Musterstraße 45",
"city": "Berlin",
"postalcode": "10115",
"province": "Berlin",
"email": "jane.doe@example.com"
}
}'