Set up environment
Configure the Krajowy System e-Faktur (KSeF) environment endpoint that Sovos uses to route your invoice submissions and inbound polling.
The preferred_partner value you set determines whether documents are sent to the KSeF test, pre-production, or production system.
Environment options
Test and production certificates are different. Verify you are using the correct certificate for your target environment. Submitting with a test certificate against the production endpoint causes authentication failure.
-
preferred_partner:KSEF- Test -
Use during development and testing.
KSeF endpoint:
api-test.ksef.mf.gov.pl -
preferred_partner:KSEF-PRE-PROD- Pre-production -
Use for UAT and pre-go-live validation.
KSeF endpoint:
api-demo.ksef.mf.gov.pl -
preferred_partner:KSEF- Production -
Use for live invoice submissions.
KSeF endpoint:
api.ksef.mf.gov.pl
Configure the environment for outbound submissions
Set the preferred_partner value for the outbound product to control which KSeF environment receives your submitted invoices.
POST request to the configurations endpoint. Include the preferred_partner configuration in the transmission context. Make sure productID is "pl_Faktura__2.0".
- Request sample for the production environment
-
JSON
POST https://api-test.sovos.com/v2/configurations/organizations/{orgId}/settings { "category": "PL_INV", "productId": "pl_Faktura__2.0", "scope": { "orgId": "[YOUR_ORG_ID]", "taxId": "[YOUR_TAX_ID]" }, "contexts": [ { "name": "transmission", "configurations": [ { "name": "preferred_partner", "value": { "name": "KSEF" } } ] } ] }
For credential setup steps, see Set up credentials.
Configure the environment for inbound polling
preferred_partner value for the polling product to control which KSeF environment Sovos polls for inbound invoices. Make sure productID is "pl_Faktura_Polling_2.0".
- Request sample for the production environment
-
JSON
POST https://api-test.sovos.com/v2/configurations/organizations/{orgId}/settings { "category": "PL_INV", "productId": "pl_Faktura_Polling_2.0", "scope": { "orgId": "[YOUR_ORG_ID]", "taxId": "[YOUR_TAX_ID]" }, "contexts": [ { "name": "transmission", "configurations": [ { "name": "preferred_partner", "value": { "name": "KSEF" } } ] } ] }
For polling setup and schedule configuration, see Retrieve invoices.
