Svea Checkout Adapter
Overview Document: Payment Adapters Overview
Overview and Unique Capabilities
The Svea Checkout Adapter integrates Svea Checkout with Norce Checkout. This page focuses on the unique technical details and configuration for Svea.
Supported payment methods and other features: Features Overview
Configuration in Norce Admin
The adapter is configured using the following details obtained from Svea and your storefront URLs:
Required Settings
| Field | Description | Example Value |
|---|---|---|
apiUrl | Svea Checkout API URL (test or production). | https://checkoutapistage.svea.com |
orderManagementApiUrl | Svea Payment Admin API URL for order management operations. | https://paymentadminapistage.svea.com |
merchantId | Your Svea merchant identifier. | 12345 |
apiSecret | Your Svea API secret key. | xyz123abc |
checkoutUrl | URL to your checkout page where the Svea iframe is displayed. | https://your-store.com/checkout |
confirmationUrl | URL to redirect customers after successful payment. | https://your-store.com/confirmation |
merchantTermsUrl | URL to your terms and conditions page. | https://your-store.com/terms |
Optional Settings
| Field | Description | Example Value |
|---|---|---|
useDeliveryModule | Set to true if using Svea's integrated Delivery Module (nShift). | false |
minAge | Minimum age requirement for purchases (shop-wide). Not supported for B2B orders. | 18 |
activePartPaymentCampaigns | Comma-separated list of valid CampaignIDs to filter part payment options. | 111,222,333 |
promotedPartPaymentCampaign | CampaignID to promote first in payment method lists. | 222 |
useRecurringPayment | Enable recurring/subscription payments. | false |
discountLocalizations | Localized labels for discount rows by culture. | {"sv-SE": "Rabatt"} |
voucherLocalizations | Localized labels for voucher rows by culture. | {"sv-SE": "Presentkort"} |
Svea API Environments
In addition to the generic Norce Adapter URLs (see Payment Adapters Overview), Svea uses the following external API environments:
| Environment | Svea Checkout API | Svea Payment Admin API |
|---|---|---|
| Production | https://checkoutapi.svea.com | https://paymentadminapi.svea.com |
| Stage/Test | https://checkoutapistage.svea.com | https://paymentadminapistage.svea.com |
B2B vs B2C Handling
The adapter automatically detects whether the customer is a business (B2B) or private consumer (B2C) based on the customer.type field in the Norce order. When the customer type is Organization, the adapter sets the IsCompany preset value to true in the Svea checkout session.
Key differences for B2B orders:
- The
minAgevalidation option is not supported for B2B orders (Svea limitation) - PEPPOL invoicing is available for B2B customers
Note that the adapter always sends prices including VAT to Svea. The VAT rate is calculated from each item's vatRate field. For discounts, the VAT rate is derived from the difference between includingVat and excludingVat values.
Merchant Settings (Auto-generated Callbacks)
When creating a Svea checkout session, the adapter automatically generates the following callback URLs. These are sent to Svea as part of the merchantSettings and do not need to be configured manually:
| Callback | Purpose |
|---|---|
checkoutValidationCallBackUri | Called by Svea before payment confirmation to validate stock and discounts. |
pushUri | Called by Svea when the order status changes (e.g., payment confirmed). |
webhookUri | Called by Svea for shipping-related events when using the Delivery Module. |
Creating a Recurring Payment
To create an order using a previously stored recurring token:
POST /api/checkout/v1/orders/{order_id}/payments/recurring
Host: {slug}.api-se.stage.norce.tech
x-merchant: {merchant}
x-channel: {channel}
Authorization: Bearer {token}
Content-Type: application/json
{
"token": "cd45444b-e125-4660-b5c0-08dce7ff05be"
}Token usage is capped at three orders per day in the production environment. Additionally, recurring orders cannot be created when the merchant uses nShift shipping.
Troubleshooting (Svea Specific)
In addition to the generic troubleshooting steps:
- Review the order status directly in Svea's Payment Admin.
- If Capture fails, verify the Norce order is in the reserved state and that the Svea order status is Final.
- Use the Svea-specific refresh call to update available payment actions:
POST /api/order/v1/orders/{order_id}/payments/{payment_id}/refresh
Host: {slug}.api-se.stage.norce.tech
x-merchant: {merchant}
x-channel: {channel}
Authorization: Bearer {token}