Connect WordPress to soge.dk

The Lynbro WordPress plugins read Danish vehicle (DMR) and company (CVR) data from soge.dk. They connect with an API key that you create for your site and paste into WordPress — soge.dk never gets access to your site.

Which plugins use it

  • Lynbro Soge Lookup — Plate/VIN and CVR lookup blocks and shortcodes, and automatic company prefill in WooCommerce and popular form plugins.
  • dk-accounting — CVR field in the WooCommerce checkout: the customer types a CVR number and the company name, address and VAT number are filled in.

Set it up in four steps

  1. Create a free soge.dk accountSign up with your e-mail and confirm the code we send. No card needed; the Free plan is free for good.
  2. Create an API key for this siteOpen the API-key page. When you come from the plugin, the name is filled in as "your-site.dk — WordPress". Click Create key and copy the key — it is shown only once. Use one key per website.
  3. Paste the key in WordPressIn WordPress go to Settings → Soge Lookup (or the plugin's Connection tab), paste the key into the API key field and save. The key is stored encrypted on your server and is never sent to visitors' browsers.
  4. Test the connectionClick Save and test. The plugin calls GET /api/v1/me and shows the account, plan, quota left and the data your plan includes. This call is free and does not use your quota.

What is sent to soge.dk

  • Only what is looked up: the number plate, VIN or CVR number typed into the block or form.
  • Your API key in the X-API-KEY header, plus your server's IP address and User-Agent (WordPress sends "WordPress/<version>; <your site>").
  • No visitor personal data, cookies, WordPress users, passwords or database access. soge.dk never connects to your site — all calls go from your server to soge.dk.

How the key is tied to your site

A key works from a limited number of servers at the same time (1 on Free, more on paid plans). A server's slot is released after an hour of inactivity, so moving host or adding a staging copy keeps working. If the limit is reached, only the extra server is refused (error device_limit) — the key itself is never blocked.

What each plan includes

FreeStarterBusinessPro
API calls / month1.5006.00030.000100.000
Checkout CVR lookups / month1.00010.00050.000200.000
Requests / minute201806001.200
Servers per key12410
Company owners (ownership)—YesYesYes
Annual-report figures (financials)—YesYesYes
Vehicle history (odometer, inspections, insurance…)—YesYesYes

Free stops at its monthly quota (error quota_exceeded, HTTP 402) and starts again on the 1st. Paid plans keep working past the quota. Prices: see pricing.

Owners and financials

GET /api/v1/cvr/{cvr}/ownership (owners, subsidiaries, related companies) and GET /api/v1/cvr/{cvr}/financials (revenue, profit, equity and assets from the annual reports, two-year comparison) are included in Starter, Business and Pro. A Free key gets HTTP 403 with code scope_missing — the plugin then simply leaves those sections out.

Checkout CVR lookups (dk-accounting)

GET /api/v1/checkout/cvr/{cvr} returns the company name, street address, postcode, city, VAT number (DK + CVR) and whether the company is active — the same field names as cvrapi.dk (name, address, zipcode, city, vat). It works without an API key: per server 20/minute and 500/day, and per site 100/day (send your site address in the X-Lynbro-Site header). With a key, Free included, the key has its own checkout quota (1.000/month on Free) that does not use your API calls.

curl -H "X-Lynbro-Site: https://your-shop.dk" https://soge.dk/api/v1/checkout/cvr/10007127

{"data": {"cvr": "10007127", "name": "…", "address": "…", "zipcode": "…", "city": "…",
          "vat": "DK10007127", "status": "NORMAL", "active": true, …},
 "meta": {"tier": "keyless", "remaining": 99}}

Error codes

Every error has the same shape. The message follows the Accept-Language header (da, en or uk).

{"error": {"code": "scope_missing", "message": "…",
           "details": {"scope": "companies:ownership", "upgrade_url": "https://soge.dk/en/pricing"}}}
CodeHTTPWhat it means
invalid_key401The key is missing, mistyped or revoked. Copy it again or create a new one.
scope_missing403Your plan does not include this data (details.scope). Upgrade, or the plugin skips the section.
device_limit403The key is already in use on as many servers as your plan allows. Use one key per site.
quota_exceeded402The monthly quota of the Free plan is used up (details.resets_at).
rate_limited429Too many requests in a minute or a day. Wait Retry-After seconds.
not_found404No vehicle or company with that number.
invalid_cvr422A CVR number must be exactly 8 digits.
upstream_unavailable503A public register did not answer. Retry shortly.

Revoke or replace a key

On the API-key page or in your dashboard: Revoke stops the key at once. "Use for this site (new value)" keeps the key but gives it a new value — the old value stops working immediately, so paste the new one into WordPress. Removing the plugin deletes the key from WordPress; revoke it here too.

For developers

OpenAPI: https://soge.dk/api/openapi.json · reference: https://soge.dk/api-doc · all calls server-to-server over HTTPS, base URL https://soge.dk/api/v1.

curl -H "X-API-KEY: $SOGE_KEY" https://soge.dk/api/v1/me

{"data": {"account_name": "…", "plan": "free", "plan_name": "Free",
          "quota": {"unit": "calls", "used": 12, "limit": 1500, "resets_at": "…", "hard_stop": true},
          "scopes": ["vehicles:read", "companies:read", "addresses:read", "checkout:cvr"],
          "origins": [], "key": {"id": 1, "name": "your-shop.dk — WordPress", "last4": "…"},
          "sandbox": false}}