Skip to main content

Client Info

TypeBase PathTrigger Name
Single entity resource~{realm}/N/A

Normally, the client issues a GET request to this endpoint at start-up in order to fetch information about the account (and to verify the credentials).

The server also returns a set of direct API endpoints that can be used for failover handling and redundancy, if the client supports that.

Endpoints

NameMethodRelative PathPayloadResponseDescription
getClientInfoGET~{realm}/N/AClientInfoReturns information about the current client.

Permissions

No special permissions are required to access this resource.

Entities

Interface ClientInfo

interface ClientInfo {
'company': Company;
'access-token'?: Stored_AccessToken;
'till'?: Stored_Till;
'user'?: Stored_User;
'location'?: Stored_Location;
'service-endpoints': ServiceEndpoint[];
'system-params': SystemParams;
'merchant-params': MerchantParams;
'company-config': Stored_CompanyConfig;
'till-state'?: Stored_TillState;
'permissions': Permission[];
'p2p-realm'?: string;
'p2p-key'?: Base64String;
}
PropertyData TypeDescription
companyCompanyInformation about the current realm or company.
access-tokenStored_AccessToken?Information about the current access token, if any.
tillStored_Till?Information about the current trusted device, if any.
userStored_User?Information about the current user, if any.
locationStored_Location?Information about the current trusted device's location, if any.
service-endpointsServiceEndpoint[]A list of server endpoints that are available (for failover handling/redundancy).
system-paramsSystemParamsSystem parameters for clients.
merchant-paramsMerchantParamsInformation about support, sales and available features.
company-configStored_CompanyConfigThe current company configuration object.
till-stateStored_TillState?The current state of the current trusted device, if any.
permissionsPermission[]A list of all current permissions.
p2p-realmString?A unique identifier for the current trusted device's P2P realm.
p2p-keyBase64String?A unique key for the current trusted device's P2P realm.

Interface Company

namespace Company {
type Category = 'active-life' | 'arts-and-entertainment' | 'automotive' | 'beauty-and-spas' |
'education' | 'event-services' | 'food' | 'health-and-medical' | 'home-services' |
'hotels-and-travel' | 'local-services' | 'nightlife' | 'other' | 'pets' |
'professional-services' | 'public-services' | 'religious-organizations' |
'restaurants' | 'shopping';
type RegistrationType = 'backoffice' | 'developer' | 'android-tablet' | 'android-phone' | 'ios-tablet' | 'ios-phone';
type Type = 'merchant' | 'reseller';
}

interface Company {
'terminated'?: DateTime;
'name': string;
'alias': string;
'org-number': string;
'address': string;
'phone-number': string;
'web-address'?: string;
'email'?: string;
'registration-type'?: Company.RegistrationType;
'business-category'?: Company.Category;
'type'?: Company.Type;
'feature'?: CompanyFeature;
'reseller-params'?: ResellerParams;
'reseller'?: number;
'locale'?: string;
'secondary-locale'?: string;
'currency'?: string;
'time-zone'?: string;
'derivation-base-key'?: Base64String;
'id'?: number;
'created'?: DateTime;
'updated'?: DateTime;
'deleted'?: DateTime;
'updated-by'?: number;
'updated-from'?: number;
'tags'?: string[];
}
PropertyData TypeDescription
terminatedDateTime?The date the customer requested this account to be terminated. Terminated accounts are archived/backed up for a specific number of years, according to local law, before they are permanently deleted.
nameStringLegal name of company. Will be printed on all receipts.
aliasStringThe realm/company alias.
org-numberStringThe company's legal organization ID. Will be printed on all receipts.
addressStringThe company's legal address. A cash register without location will print this on receipts.
phone-numberStringThe company's phone number. A cash register without location will print this on receipts.
web-addressString?The company's web address. A cash register without location will print this on receipts, if specified.
emailString?The company's email address. A cash register without location will print this on receipts, if specified.
registration-typeCompany.RegistrationType?Information about how and from where this realm/company was created.
business-categoryCompany.Category?The company's business category.
typeCompany.Type?What kind of company this company is. Can be merchant (the default) or reseller.
featureCompanyFeature?An object holding the company's feature flags, if any.
reseller-paramsResellerParams?For reseller companies, additional reseller parameters.
localeString?The company's locale. Defines language used on receipts, localization rules for all server resources and various compliance criteria in the cash registers. Default, if unspecified, is sv-SE.
currencyString?The company's default or accounting currency. This affects the interpretation of most Money properties. Default, if unspecified, is SEK.
secondary-localeString?The company's secondary locale. Defines secondary language used on receipts. localization rules for all server resources and various compliance criteria in the cash registers.
time-zoneString?The company's preferred time zone. This affects the interpretation of all CronExpr properties that are evaluated by the server, like scheduled triggers.
sales-breakpoint-hourInt32?The hour when transactions will begin to register on the current date (according to the configured time zone). Defaults to 0 (i.e. midnight).
idInt64?The resource ID of this entity.
createdDateTime?Date and time when this entity was first created.
updatedDateTime?Date and time when this entity was last modified.
deletedDateTime?Date and time when this entity was deleted.
updated-byInt64?ID of User who last modified this entity.
updated-fromInt64?ID of Till (trusted device) which last modified this entity.

Interface CompanyFeature

namespace CompanyFeature {
type Flag =
| 'archived-account'
| 'control-unit-not-required'
| 'demo-account'
| 'restricted-version'
| 'auto-close-batch'
| 'barcode-scanners'
| 'campaigns'
| 'cloud-control-unit'
| 'coupon-vouchers'
| 'custom-payment-methods'
| 'digital-receipt-sms'
| 'direct-marketing-campaigns'
| 'entertainment-bills'
| 'erp-bl'
| 'erp-fortnox'
| 'erp-personalkollen'
| 'erp-planday'
| 'erp-visma'
| 'erp-zoined'
| `external-journal`
| 'foreign-currencies'
| 'host2t-terminals'
| 'kitchen-tickets'
| 'payment-invoices'
| 'payment-swish'
| 'payment-vouchers'
| 'shifts'
| 'stock-balances'
| 'table-service'
| 'take-out-orders'
| 'verifone-terminals'
| 'viva-wallet-terminals'
| 'wisepay-terminals'
;
}

interface CompanyFeature {
'flags': CompanyFeature.Flag[];
`viva-wallet-fee-rate`: number;
}
PropertyData TypeDescription
flagsCompanyFeature.Flag[]A set of feature flags that are currently active for this realm or company.
viva-wallet-fee-rateFloat32Fee rate for Viva.com transactions, in percent.

The following table describes all available feature flags.

Feature FlagDescription
archived-accountIf set, this account is disabled and read-only, but still available (for compliance).
control-unit-not-requiredIf set, the cash register operates even if a fiscal control unit is not present or configured. For markets where fiscal control units are not used, this flag can be forced via the ResellerParams.
demo-accountIf set, the account is a non-production, demonstration-only account.
restricted-versionIf set, the cash register operates in locked down or "demo" mode, which the customer may then unlock by subscribing to a service.
auto-close-batchEnables cash registers to automatically close the batch and print a Z-report at a specified schedule.
barcode-scannersEnables cash registers to use barcode scanners and external keypads.
campaignsEnables automatic discount rules/promotions.
cloud-control-unitEnables cash registers to use cloud-based fiscal control units.
coupon-vouchersEnables support for server-side coupon vouchers where the system keeps track of registered coupons, quantities and credit limits.
custom-payment-methodsEnables the customer to define custom payment methods, like mobile payments or coupons.
digital-receipt-smsEnables digital receipts to be sent via SMS.
direct-marketing-campaignsEnables direct marketing campaigns, i.e. the ability to send marketing SMS messages to registered customers from Backoffice or cash registers.
entertainment-billsEnables the possibility to print entertainment bills (Bewirtungs-Beleg) from the cash register.
erp-blEnables invoicing and automatic uploading of Z-Reports to Björn Lundén.
erp-fortnoxEnables invoicing and automatic uploading of Z-Reports to Fortnox.
erp-personalkollenEnables automatic uploading of receipts to Personalkollen.
erp-plandayEnables automatic uploading of Z-Reports to Planday.
erp-vismaEnables invoicing and automatic uploading of Z-Reports to Visma.
erp-zoinedEnables automatic uploading of receipts to Zoined.
external-journalEnables external journals, i.e. support for third party integrations injecting external sales data into the system.
foreign-currenciesEnables the customer to use foreign currencies in the cash registers.
host2t-terminalsEnables support for Host2T credit card terminals from Worldline.
kitchen-ticketsEnables printing of food orders to a kitchen ticket.
payment-invoicesEnables support for invoicing. Also requires one of the invoicing-enabled erp-* flags to be set.
payment-swishEnables Swish Handel as an available payment method.
payment-vouchersEnables support for payment vouchers where the system keeps track of registered vouchers, balances and credit limits.
shiftsEnables the Attendance Recorder module in the cash register.
stock-balancesEnables per-location tracking of stock balances for all enabled products.
table-serviceEnables extended support for restaurants, including a visual table layout and multiple tabs per table.
take-out-ordersEnables support for take out orders submitted from external order forms or sites.
verifone-terminalsEnables support for Verifone credit card terminals.
viva-wallet-terminalsEnables support for Viva.com Soft POS apps on phones and terminals.
wisepay-terminalsEnables support for Wisepay credit card terminals.

Interface ResellerParams

interface ResellerParams {
'available-features': CompanyFeature.Flag[];
'required-features': CompanyFeature.Flag[];
'merchant-config': MerchantConfig;
'alias-prefix': string;
}
PropertyData TypeDescription
available-featuresCompanyFeature.Flag[]A set of feature flags that this merchant may enable for itself and its customers.
required-featuresCompanyFeature.Flag[]A set of feature flags that are automatically set for all merchants.
merchant-configMerchantConfigMerchantConfig is a subset of MerchantParams.
alias-prefixStringA (preferably) short prefix that is appended to the realm/company alias of all this reseller's merchants and sub-resellers. Think of it like an alias prefix namespace.

Interface MerchantParams

interface MerchantParams {
'reseller-alias'?: string;
'available-features': CompanyFeature.Flag[];
'required-features': CompanyFeature.Flag[];
'support-phone': string;
'support-email': string;
'sales-phone': string;
'sales-email': string;
'reseller-name': string;
'web': string;
'terms-and-conditions-uri': string;
'vat-rates': number[];
'general-info'?: string;
}
PropertyData TypeDescription
reseller-aliasStringAlias (realm) for partner. Allowed characters are [a-z0-9].
available-featuresCompanyFeature.Flag[]List of flags that are available. Note that merchant may not have access to all of them. Active flags are found in company.feature.flags of ClientInfo.
required-featuresCompanyFeature.Flag[]Subset of available-features that will automatically be set by the server.
support-phoneStringTelephone number for support questions.
support-emailStringEmail for support questions.
sales-phoneStringTelephone number for sales related questions.
sales-emailStringEmail for sales related questions.
reseller-nameStringName of partner for support and sales texts.
webStringSupport web address for partner.
terms-and-conditions-uriURIURI to terms and conditions page.
vat-ratesStringList of valid VAT rates. Only these VAT rates should be used.
general-infoStringGeneral information from reseller.

Interface ServiceEndpoint

interface ServiceEndpoint {
'uri': string;
}
PropertyData TypeDescription
uriURIA base URL pointing to an individual API server.

Interface SystemParams

interface SystemParams {
'backoffice-uri': string;
'slipp'?: SlippConfig;
'viva-wallet'?: VivaWalletConfig;
}
PropertyData TypeDescription
backoffice-uriURIThe location of the Onslip 360 Backoffice site.
slippSlippConfig?Slipp.ID configuration.
viva-walletVivaWalletConfig?Viva.com configuration.

Interface SlippConfig

export interface SlippConfig {
'ws-uri': string;
}
PropertyData TypeDescription
ws-uriURIThe URL pointing to Slipp.ID WebSocket API.

Interface VivaWalletConfig

interface VivaWalletConfig {
'client-id': string;
'client-secret': string;
}
PropertyData TypeDescription
client-idStringViva.com ISV Client ID.
client-secretStringViva.com ISV Client Secret.