Skip to content

Accounting firm account creation ​

If your customers are accounting firms that serve further companies, each firm gets its own accounting firm account in Salaxy. The firm then sees only its own customer companies, in the Salaxy Pro site or through the Pro API. You create the firm account first, and then create its customer companies under it. Examples use the test environment; see Environments for demo and production.

Customer companies under an accounting firmThree tiers. Your technical account is at the top. Under it sits an accounting firm account for each accounting firm, created first. Under each accounting firm account sit the customer companies of that firm, created with the accounting firm's account id as proxyPartner. Every customer company has exactly one parent.Your technical account1 create the firmAccounting firm account2 proxyPartnerCustomer companyCustomer company
Create the accounting firm account first. Then create each customer company with the accounting firm's account id as `proxyPartner`.

Which fits you? ​

Three tiers: accounting firms under you ​

Use this when your customers are accounting firms that run payroll for their own customer companies. Each firm is an accounting firm account, and its companies sit under it. The firm works in Salaxy Pro or through the Pro API. Everything below is for you.

Two tiers: companies directly under you ​

Use this when you onboard the companies yourself, with no third-party accounting firm in between, even if a company is itself an accounting firm. Create every company as a regular customer: Customer account creation, without proxyPartner. Skip this page.

Three tiers: how it works

A customer company has exactly one parent: your technical account, or an accounting firm account, never both. The payment channel belongs to your technical account and flows down to every tier through service models. The tiers are explained in Account structure.

How it works ​

The accounting firm is created with the same call as a customer company.

MethodPathPurpose
POST/v03/api/partner/companyAssure the accounting firm account for the firm's Business ID
POST/v03/api/partner/company with proxyPartnerCreate a customer company under that accounting firm (see Customer account creation)

The same call exists as /v04/api/partner/company. The fields, response and errors are in Partner-initiated account creation. The account type follows from the Business ID: an accounting firm gets the accounting firm role (Tilitoimisto).

  1. Create the firm. Call with the firm's Business ID as officialId. Do not set proxyPartner: the firm is itself the proxy tier.
  2. Store accountId. It becomes the proxyPartner value for the firm's customers.
  3. Create each customer with proxyPartner set to that accountId.
http
POST https://test-secure.salaxy.com/v03/api/partner/company
Authorization: Bearer {technical-account-token}
Content-Type: application/json
json
{
  "officialId": "7654321-1",
  "partnerAccountId": "firm-42",
  "language": "fi",
  "email": "firm@example.com"
}
json
{
  "accountId": "FI00POYA0007654321",
  "avatar": { "displayName": "Example Accounting Oy", "initials": "EA" },
  "isVerified": false,
  "isAuthorized": true,
  "partnerAccountId": "firm-42"
}

Then create a customer company under the firm:

json
{
  "officialId": "1234567-8",
  "partnerAccountId": "customer-4711",
  "proxyPartner": "FI00POYA0007654321"
}

Rules ​

  • Trusted partner role. Required in production, not in test.
  • The accounting firm role. The account must carry the accounting firm (Tilitoimisto) role. It is normally enabled in test. In production, ask Salaxy if the role has to be granted.
  • Safe to repeat. A second call with the same officialId returns the existing account. A partnerAccountId, once set, must be sent on every later call for that account.
  • You must be authorised to the firm. proxyPartner fails with 400 if the account does not exist, or if you do not have access to it.
  • The parent is set only once. Salaxy sets the parent on creation only for a company that has none. A company that already sits under another provider keeps it. To move a company to a firm, or to detach it, use POST or DELETE /v01/api/pro/accounts/{accountId}/partner (Pro API). The caller of that endpoint becomes the parent, and must already have access to the company.
  • Service model. After creating the firm, ask Salaxy to give it its own default service model, so that its customers inherit the payment channel and the accounting model: Service models.

After creation ​

  • Acting as the firm. With the Pro API token endpoint, a token for the firm is minted from your technical account, and a token for one of its customers from the firm's token, level by level; that endpoint cannot skip a level. See Pro API. With the JWT flow you can instead sign in as the customer directly and name the firm in the salaxy_proxy_act claim: Impersonation.
  • The firm's view. The firm's users, or you acting for them, list the customers with GET /v01/api/pro/accounts and search across them with the other Pro endpoints.
  • Certificate. A firm that files under its own Business ID needs a valid Incomes Register certificate, or its customers' payments are refused. See Customer account creation.

Test it ​

  • Create the firm on test-secure.salaxy.com with a Business ID of a company that really exists: the trade register is the production one, and a made-up ID is refused.
  • Create a customer company with proxyPartner set to the firm's accountId. Then list the firm's customers with the Pro API and check that the company is there.
  • Create a second customer without proxyPartner and check that it is not in the firm's list.
  • Call the firm creation twice and check that the accountId is the same.

Checklist ​

  • You create the accounting firm account before its customers, and store its accountId.
  • You never set proxyPartner on the firm's own creation call.
  • You pass the firm's accountId as proxyPartner on every customer creation.
  • You use the Pro API re-point, not a second creation call, to move an existing company.
  • In a two-tier set-up you skip this page.

Next: Pro API (accounting firm tier)

Every page is also available as Markdown: add .md to its URL — a folder page such as white-label/ is white-label/index.md. Index for LLMs: llms.txt. Questions: Support.