Select an item from the list at right side.

Errors

500 - InternalServerErrorJsonException

When server can not understand what is happening. See "details" field for more info. It contains field "message" with text description.

410 - OutdatedVersionJsonException

Informs user that api doesn't work anymore. The app should be updated to newest version asap! No additional details provided.

501 - NotImplementedJsonException

Thrown by any method but make sense to catch for. Happens usually for local servers: when android device is up to date, but server is not. No additional details provided.

404 - NotFoundJsonException

When requested resource wasn't found.

409 - VersionConflictJsonException

Occurs when we upload data to the server but server contains more fresh data than we send. No additional details provided. You should set actual "If-Match" header.

404 - ReferenceNotFoundJsonException

This exception occurs when SomethingInfo dto class contains a field which references to another entity and the algorithm assumes it has to be on the server but it doesn't. See details field: it contains field "entityName" to know the id of entity which is not found and optional field "identifier" of entity which is not found.

500 - ControlUnitReceiptJsonException

Thrown when Control Unit decides something is wrong according to it's internal business logic. Thrown by the control unit itself. The details contains three fields:

  1. command
  2. response
  3. name
The name is one of the following:
  • InternLoggFull24(24)
  • InternaRaknareSaturerade23(23)
  • FaltForekommerEfterSistaCRC22(22)
  • FelaktigtForhallandeForsaljRetur21(21)
  • PowerFailAbort20(20)
  • InterntSkrivfel19(19)
  • InterntSkrivfel18(18)
  • InterntSkrivfel17(17)
  • InterntSkrivfel16(16)
  • InterntSkrivfel15(15)
  • AntalAnvandareHarOverskridits14(14)
  • FelaktigMoms4_13(13)
  • FelaktigMoms3_12(12)
  • FelaktigMoms2_11(11)
  • FelaktigMoms1_10(10)
  • FelaktigtForsaljningsbelopp9(9)
  • FelaktigtReturbelopp8(8)
  • KvittotypSaknas7(7)
  • FelaktigKvittotyp6(6)
  • FelaktigtLopnummer5(5)
  • FelaktigtKassaID4(4)
  • FelaktigtOrganisationsnummer3(3)
  • FelaktigtDatumTid2(2)
  • FelAntalArgument1(1)
  • OK0(0)
  • FelaktigLangd_1(-1)
  • CRCError_2(-2)
  • OkantKommando_3(-3)

500 - ControlUnitUnavailableJsonException

When server is unable to reach the control unit device (for instance it's ejected from the server). No additional details provided.

500 - ControlUnitCommunicationJsonException

When error has happened during transmission data to the control unit (for instance it was ejected from the server during sending the data). No additional details provided.

400 - InvalidETagFormatJsonException

Occurs when provided ETag format is not a quoted string with version inside.

400 - NonUniqueJsonException

When passed data violates some unique constraint. Details can have more then one violated field, it means that constraint is composite.

401 - UnauthorizedJsonException

Dropped by server when user tries access resource without any authentications.

400 - MessageNotReadableJsonException

When sent JSON is failed to parse. Message is not human-readable and intended solely to give all required information to developer.

400 - HttpHeaderMissingJsonException

If request param doesn't contain required http header.

400 - RequestParameterMissingJsonException

If request parameter was missed.

400 - TypeMismatchJsonException

When some entity fails during type conversion. For example, passed String as query param is not convertible to Date.

405 - RequestMethodNotSupportedJsonException

Occurs on wrong API usage. For instance, when method GET is not supported by specified URL.

422 - UnprocessableEntityJsonException

This exception occurs when every entity field passes validation but there is a logical (semantical) violation.

All possible error codes are listed below.

TREASURER_IS_JOINED_TO_USER_ALREADY - Occurs on attempt to join treasurer which is joined already. Need to disjoin treasurer from user at first.
USER_HAS_TREASURER_WITH_SAME_SELLER_ID_ALREADY - Occurs on attempt to join treasurer, but user has treasurer with same seller id already.
TREASURER_IS_NOT_JOINED_TO_USER - Occurs on disjoin treasurer. Indicates that treasurer is not joined to any user and disjoin doesn't make any sense.
COMPANY_NAME_MUST_BE_SET_IF_NO_SELLER - Occurs if both passed seller wasn't found and company name wasn't set.
CU_LOCATION_MUST_BE_SET - Occurs on attempt to set control unit without geolocation info specified.
INSTALLATION_IS_OUT_OF_DATE - Indicates that passed production number is out of date with device since another instance of application was installed already. Reinstall of application is suggested.
CU_IS_MISSING_FOR_ACTIVATION - Indicates that control unit should be set if application is working with control unit
AUTO_ACTIVATE_IS_NOT_POSSIBLE_ON_NEW_CU - Occurs during ordering an activation. Indicates the attempt to enable auto-activation upon not yet registered control unit.
PRODUCTION_NUMBER_AND_DEVICE_ID_MISMATCH - Occurs during ordering an activation. Indicates that passed production number doesn't belong to device. Reinstall of application is suggested.
APPLICATION_PACKAGES_MISMATCH - Occurs during ordering an activation. Indicates that passed application package in the request body and another one identified by production number are not the same.
APP_DESC_HAS_REFERENCED_DATA - Occurs on attempt to remove application description which is referenced in another entities.
SOFTWARE_VENDOR_HAS_REFERENCED_DATA - Occurs on attempt to remove software vendor which is referenced in another entities.
SOFTWARE_VENDOR_IS_MISSING - Occurs on attempt to create/edit user with ROLE_SOFTWARE_VENDOR_ADMIN.
PROHIBITED_ORDER_STATUS_CHANGE - Occurs on attempt to change status of order which breaks conceived logic.
CU_HAS_REFERENCED_DATA - Occurs on attempt to delete the control unit which has referenced data.
DAY_IS_CLOSED - Occurs when current day is closed.
DAY_IS_NOT_CLOSED - Occurs when current day isn't closed.
RECEIPT_IS_PRINTED_ALREADY - Occurs when current receipt is printed already.
RECEIPT_IS_NOT_PRINTED - Occurs when current receipt is not printed yet.
REPORT_IS_PRINTED_ALREADY - Occurs when report is printed already.
REPORT_IS_NOT_PRINTED - Occurs when report is not printed yet.
ACTIVATION_IS_CLOSED_ALREADY - Occurs when activation is closed already.
ACTIVATION_IS_ACTIVE_ALREADY - Occurs when activation is active already.
ACTIVATION_IS_WORKING_ALREADY - Occurs when activation is working already.
ORDER_ALREADY_HAS_PRECEPT - Occurs when new precept is creating with order that already has precept.
SELLER_MUST_HAVE_CURRENCY - Occurs when currency is necessary for make payment and seller doesn't have it.
CONTROL_UNIT_IS_CONNECTED_ALREADY - Control unit is connected to SV already.
CONTROL_UNIT_IS_DISCONNECTED_ALREADY - Control unit is disconnected from SV already.

409 - InconsistentDataJsonException

When data sent to the server is in inconsistent state. See "details" field for more info. It contains field "message" with text description.

All possible error codes are listed below.

SV_MISMATCH_IN_APP_DESC_AND_CU - Occurs when references to software vendor in application description and control unit don't match.
VALID_FROM_AND_VALID_TO_INCONSISTENCY - Occurs when some inconsistency was detected during 'ValidFrom' or 'ValidTo' validation.
ACTIVATION_CODE_WRONG_LENGTH - Occurs during activation process when activation code is tested.
ACTIVATION_CODE_ALREADY_EXISTS - Occurs during activation process when passed activation has its signature already.
ACTIVATION_STATUS_IS_NOT_MODIFIABLE_BY_PUT - Occurs in case of attempting to modify activation status by 'PUT' http method.
QUERY_PARAM_CANT_BE_NEGATIVE - Occurs if passed query parameter is negative, but positive of zero value is expected.
SELLER_HAS_NOT_REGISTRATION - Occurs when passed by query param cash register name doesn't belong to the passed seller.
SELLER_SHOULD_BE_PROVIDED_FOR_CR - Occurs when cash register name passed as query param without specified seller.
SERVER_IS_OVERLOADED - Occurs when retrieving data bulk is too large. It signals to specify maxResults param to not greater that some limit.
IDENTIFIER_LENGTH_VIOLATION - Occurs when passed identifier (for instance, seller identifier) doesn't fit into length requirements.
SERVER_CANT_BE_REMOVED - Occurs in case of attempting to remove current working server.
URL_AND_BODY_IDENTIFIERS_MISMATCH - Occurs when identifier in URL and body is not the same. Commonly, it is used to forbid changing identifier by PUT.
LOCAL_AND_SERVER_VERSIONS_INCONSISTENCY - Occurs when passed version is more then server's one.
WORKING_WITH_CU_IS_NOT_SUPPORTED_BY_APP - Occurs when application without ability to work with control units attempts to send a kd.
PRODUCTION_NUMBER_AND_CONNECTION_MISMATCH - Occurs during connection to activation process when connection production number is not equal with installation.
PRODUCTION_NUMBER_AND_DEVICE_ID_MISMATCH - Occurs during ordering an activation. Indicates that passed production number doesn't belong to device.
REGISTRATION_EXISTS_FOR_SELLER_AND_INSTALLATION - Occurs during ordering an activation. Indicates that registration already exists for the same seller and installation.
ACTIVATION_APPLICATION_PACKAGE_MUST_BE_NULL_OR_EQUAL - Occurs during ordering an activation. ApplicationPackage must be null or equal to applicationPackage for installation from database.
ACTIVATION_PRODUCTION_NUMBER_SHOULD_BE_NULL - Occurs during ordering an activation. Production number should be null.
ACTIVATION_PRODUCTION_NUMBER_SHOULD_BE_NULL_OR_EQUAL - Occurs during ordering an activation. Production number should be null or equal to production number from database.
ACTIVATION_MUST_HAVE_INSTALLATION_OR_ACTIVATION_CODE - Occurs during creating installation, when we cannot find a installation by a seller and a registration (registration can be found by CashRegisterName or ProductionNumber) and ConnectionCode is empty

400 - ValueNotValidJsonException

Thrown when some value of field fails validation. One field can have one or more violations.

All possible error codes are listed below.

SHOULD_NOT_BE_NULL - Occurs if non-null constraint violated.
SHOULD_MATCH_PATTERN - Occurs if regex violated. See params in details by keys 'actualValue' and 'pattern'.
SIZE_SHOULD_BE_EQUAL_EXACTLY - Says that size of the field in characters should be equal to limiting number. See params in details 'actualValue', 'sizeMin' and 'sizeMax'.
SIZE_SHOULD_BE_LESS_THEN - Says that size of the field in characters should be less then limiting number. See params in details by keys 'actualValue', 'sizeMin' and 'sizeMax'.
SIZE_SHOULD_BE_MORE_THEN - Says that size of the field in characters should be more or equal then limiting number. See params in details by keys 'actualValue', 'sizeMin' and 'sizeMax'.
SIZE_SHOULD_BE_IN_RANGE - Says that size of the field in characters should be in some range. See params in details by keys actualValue' and 'pattern'.
VALUE_SHOULD_BE_GREATER_THEN - Says that numerical value should be greater or equal then some limiting value. See params in details by keys 'actualValue' and 'valueMin'.
VALUE_SHOULD_BE_LESS_THEN - Says that numerical value should be less or equal then some limiting value. See params in details by keys 'actualValue' and 'valueMax'.
VALUE_SHOULD_NOT_BE_NEGATIVE - Says that value should be positive. See params in details by keys 'actualValue' and 'valueMin'.
SHOULD_MATCH_CORPORATE_ID_VALIDATION_SWEDISH - Says that seller's corporate id failed to pass swedish validation.
SHOULD_MATCH_CORPORATE_ID_VALIDATION_LUHN - Says that seller's corporate id failed to pass Luhn-algorithm validation.
SHOULD_BE_BASE64_ENCODED - Says that value can't be decoded from base64 format.

403 - ForbiddenJsonException

When service returns 403 HTTP status name.
For instance if one seller is trying to access data of another seller. Or seller is trying to reach data available for admins only. Or trying to reach public data for non-public seller.
When trying to get user info, while the authentication is by seller role.
No additional details provided.

All possible error codes are listed below.

INSUFFICIENT_ACCESS_RIGHTS - It is most used code, which covers cases when credentials is not sufficient to perform request or, for example, on attempt to get non-public data.
ACTIVATION_CLOSED_ALREADY - If activation in credentials is closed already. I.e. it is in the CLOSED state.
ACTIVATION_STILL_ISSUED - If activation in credentials is not activated. I.e. it is in the ISSUED state.
ACTIVATION_NO_FEATURE - If activation doesn't have required feature. I.e. it is in the {@link com.srv4pos.server.api.activation.Feature} state.
SELLER_NOT_FOUND - If there is credentials and seller with given country and corporate id is not registered. If caught, you should register yourself on the server.
WRONG_ACTIVATION_PERIOD - If either activation's period haven't started yet or has expired already.
WRONG_USERNAME_OR_PASSWORD - If either username or password failed to pass authorization. User should get "Please contact sales@srv4pos.com if this error appears longer than 24h".
AUTHORIZATION_DATA_IS_NOT_VALID - When auth data doesn't pass verification. For example, if username is empty.
INCOMPATIBILITY_OF_SESSION_ID - When passed session id hasn't passed verification.
CU_ARE_NOT_MANAGEABLE_BY_SVA - When software vendor isn't able to manage CU.
REGISTRATION_IS_NOT_THINKASSAN - When used registration is not thinkassan but needs to be.
EMAIL_IS_NOT_FREE - When attempt to send a free email on non-free address.
DIBS_VERIFICATION_FAILURE - When dibs verification fails.
SELLER_IS_NOT_PUBLIC - When requested seller is not public.
OLD_PASSWORD_IS_INCORRECT - When verification on old password failed during password change operation.

503 - ServiceUnavailableJsonException

Dropped by the server if server is off (for instance server is restarting or in a service mode) or not ready.

All possible error codes are listed below.

SERVER_IS_DOWN - When server is down or under maintenance.
REQUIRES_SETUP - When local server is not ready yet.

413 - RequestEntityTooLargeJsonException

When size of passed entity is too large.

Types

identifierType

Each entity has to be identified. Server generates identifiers for every entity. String. Minimum 1 characters. Maximum 50 characters. Regular expression ^(?!^(PRN|AUX|CLOCK\$|NUL|CON|COM\d|LPT\d|\.\.?)$)[^\x00-\x1f\\?*:\";|/<>]+$ .

corporateIdType

Identifies Seller within a country. Seller is a company who sells goods or provides services. Described at Data domain page. Seller is a company who sells goods or provides services. Format of corporateId is country specific. String. Maximum 95 characters. Regular expression ^(?!^(PRN|AUX|CLOCK\$|NUL|CON|COM\d|LPT\d|\.\.?)$)[^\x00-\x1f\\?*:\";|/<>]+$ .

sellerIdType

Unique identifier of every Seller. Seller is a company who sells goods or provides services. Described at Data domain page. Format is {countryType}{corporateIdType}. String.

productionNumberType

Serial number uniquely identifies instance of every installation. It represents production number of cash register according to Swedish regulations. It has format "{softwareId}{number}" where {softwareId} is some constant which identifies vendor of POS software (the company) and the name of POS software. It must be globally unique number. For instance productionNumber PT12300000517264, {softwareId} is PT123, where PT is “PosTerm” – the name of POS software, 123 – first three letters of corporate Id of vendor of PosTerm and 00000517264 is the serial number of the Installation of PosTerm. Each cash register must have a production number. String. Maximum 25 characters.

deviceIdType

Unique number of every device that can be used as cash register or related application. It can be android, iOS, server (for thin clients), desktop PC etc. String. Minimum 1 characters. Maximum 17 characters.

applicationPackageType

A unique identifier of the software, but not it's version. For instance for Android it can be getPackageName() Normally identifier is an url composed of a software name and company website. For instance if your website is http://mycompany.com and your ECR is named "GreatPOS" then identifier will be greatpos.mycompany.com. And then you turn it back to com.mycompany.greatpos. A valid real examples are se.mobilkassan (http://mobilkassan.se) and com.pos4mobile (http://pos4mobile.com). String. Minimum 1 characters. Maximum 64 characters.

printType

The type of receipt print. One of the following values: 'Normal' (Normal receipt), 'Copy' (Receipt copy), 'Proforma'.

controlUnitLocationType

Where control unit is connected and how. One of the following values: 'DEVICE' (Control unit located at Device), 'REMOTE'.

countryType

Country where Seller with given corporateId is registered. Usually used insellerIdType. All possible values are at https://www.iso.org/... website. Preferably lowercase. String. Minimum 2 characters. Maximum 2 characters.

cashRegisterNameType

Described in swedish regulations as "cash register designation". It is defined by Seller, something simple, easy to read and understand, like “Cash1”, “Lobby22”. It is sent to Control Unit together with CorporateId to uniquely identify Cash Register. It's case insensitive. According to swedish regulations it must contain only alphanumeric characters. It must be unique withing the Seller: a single company must not have two different Cash Registers with the same Cash Register Name. It means you may buy a new Cash Register and place it at the same physical position as the old one (you still call it desk 3 or window 5), but since the log is different, you have to inform the authorities that you have installed a new Cash Register instead of the old one, you have to generate a new Cash Register Name. The field that must be printed on receipts and X- and X-reports. It can not be changed within the same Installation. If Installation wipes and there are a new Installation (or replace the Device entirely), it is a new Cash Register Name because we retain no settings and no transaction history: it is very strict with not permitting the same Installation on the same Device (with the same Control Unit) twice - it would defeat the government purpose of keeping the transaction history intact. ProductionNumber can’t be used for this purpose according to the Swedish regulations. There is a method to check the existance of that name for a Seller. String. Minimum 2 characters. Maximum 16 characters.

roleType

User role. One of the following values: 'ROLE_HYPER_ADMIN' (Can do anything), 'ROLE_SOFTWARE_VENDOR_ADMIN' ( Edit seller and seller data, who have at least one activation for his software vendor. Manage activations requested trough it's software and activate them. Activation has field activationPackages which identifies the software ), 'SELLER_ADMIN' (Role for manage by seller admin), 'ACTIVATION'.

activationStatusType

One of the following values: 'ISSUED' (The order was issued by the customer but not yet paid which means Activation can not provide), 'ACTIVE' (The order has been paid by the customer, so we can provide an Activation code to him), 'WORKING' ( Activation has been downloaded, so it can be treated as it was used We can't delete it because we assume it's out of the server ), 'CLOSED'.

imageVersionType

One of the following values: 'current', 'version'.

sellerFieldsType

One of the following values: 'COUNTRY', 'NAME'.

ticketCategoryType

One of the following values: 'CONTROL_UNIT_BROKEN', 'ACTIVATION_ISSUED', 'CONTROL_UNIT_ADDRESS_CHANGED'.

ticketStatusType

One of the following values: 'OPEN', 'CLOSED'.

salesUnitType

One of the following values: 'Piece', 'Price', 'Kilogram', 'Hektogram', 'Meters', 'Centimeters', 'Hours', 'Minutes'.

changeBalanceActionType

One of the following values: 'DEPOSIT', 'WITHDRAWAL'.

deviceFormFactorType

One of the following values: 'PHONE', 'TABLET_SMALL', 'TABLET_BIG'.

saleStateType

One of the following values: 'Open', 'Paid', 'Cancelled', 'Complete'.

deliveryType

One of the following values: 'Display', 'Print', 'SMS', 'Email', 'Discard', 'Journal'.

paymentType

One of the following values: 'Cash', 'Card', 'WyWallet', 'PayEx', 'SEQR', 'AirPay', 'ClosePayment'.

paymentStateType

One of the following values: 'SENDING', 'SENDING_FAILED', 'PENDING', 'APPROVED', 'REJECTED', 'PAUSED', 'CANCELLED', 'CHARGE_FAILED', 'CHARGE_UNKNOWN'.

keyActionType

One of the following values: 'Product', 'SaleItemsView', 'POSSaleItemsView', 'Camera', 'InitiateReturn', 'InitSaleCash', 'InitSaleCard', 'InitSaleAirpay', 'InitSaleSEQR', 'InitSaleIZettle', 'InitSaleWyWallet', 'InitSalePayex', 'SubKeyboard', 'Numeric1', 'Numeric2', 'Numeric3', 'Numeric4', 'Numeric5', 'Numeric6', 'Numeric7', 'Numeric8', 'Numeric9', 'Numeric0', 'Numeric00', 'CurrencyUnit', 'ProductUnit', 'NumericReset', 'NumericDot', 'NumericBackspace', 'NumericIndicator', 'PercentDiscount', 'CurrencyDiscount', 'SendOrder', 'GetOrders', 'SubtotalIndicator', 'ProductsSearchView', 'GroupsProductsView', 'GroupsProductsTextView', 'TablesProductsView', 'TablesProductsTextView', 'NetworkIndicator', 'PrintProforma'.

activationFeatureType

One of the following values: 'VOUCHERS', 'SEQR', 'WYWALLET', 'PAYEX', 'CLOSEPAYMENT', 'AIRPAY', 'SUPPORT', 'SYNCRONIZATION', 'IZETTLE', 'CONTROL_UNIT', 'COUPONS'.

autoActivationConditionType

This condition defines use or not use the auto activation. One of the following values: 'NEVER', 'ALWAYS', 'NO_FEATURES'.

currencyType

One of the following values: 'AED', 'AFN', 'ALL', 'AMD', 'ANG', 'AOA', 'ARS', 'AUD', 'AWG', 'AZN', 'BAM', 'BBD', 'BDT', 'BGN', 'BHD', 'BIF', 'BMD', 'BND', 'BOB', 'BRL', 'BSD', 'BTN', 'BWP', 'BYR', 'BZD', 'CAD', 'CDF', 'CHF', 'CLP', 'CNY', 'COP', 'CRC', 'CUC', 'CUP', 'CVE', 'CZK', 'DJF', 'DKK', 'DOP', 'DZD', 'EGP', 'ERN', 'ETB', 'EUR', 'FJD', 'FKP', 'GBP', 'GEL', 'GGP', 'GHS', 'GIP', 'GMD', 'GNF', 'GTQ', 'GYD', 'HKD', 'HNL', 'HRK', 'HTG', 'HUF', 'IDR', 'ILS', 'IMP', 'INR', 'IQD', 'IRR', 'ISK', 'JEP', 'JMD', 'JOD', 'JPY', 'KES', 'KGS', 'KHR', 'KMF', 'KPW', 'KRW', 'KWD', 'KYD', 'KZT', 'LAK', 'LBP', 'LKR', 'LRD', 'LSL', 'LTL', 'LVL', 'LYD', 'MAD', 'MDL', 'MGA', 'MKD', 'MMK', 'MNT', 'MOP', 'MRO', 'MUR', 'MVR', 'MWK', 'MXN', 'MYR', 'MZN', 'NAD', 'NGN', 'NIO', 'NOK', 'NPR', 'NZD', 'OMR', 'PAB', 'PEN', 'PGK', 'PHP', 'PKR', 'PLN', 'PRB', 'PYG', 'QAR', 'RON', 'RSD', 'RUB', 'RWF', 'SAR', 'SBD', 'SCR', 'SDG', 'SEK', 'SGD', 'SHP', 'SLL', 'SOS', 'SRD', 'SSP', 'STD', 'SVC', 'SYP', 'SZL', 'THB', 'TJS', 'TMT', 'TND', 'TOP', 'TRY', 'TTD', 'TWD', 'TZS', 'UAH', 'UGX', 'USD', 'UYU', 'UZS', 'VEF', 'VND', 'VUV', 'WST', 'XAF', 'XCD', 'XOF', 'XPF', 'YER', 'ZAR', 'ZMK', 'ZWL'.

corporateIdValidationMethodType

One of the following values: 'NONE', 'VALIDATE_SWEDISH'.

userRoleType

One of the following values: 'ROLE_HYPER_ADMIN', 'ROLE_SOFTWARE_VENDOR', 'ROLE_REGULAR_USER'.

mailEncryptionType

One of the following values: 'TLS' (Transport Layer Security), 'SSL_TLS' (Transport Layer Security (TLS) and its predecessor, Secure Sockets Layer (SSL)), 'NONE'.

InconsistentDataErrorType

Enum describes error codes corresponding to InconsistentDataJsonException. One of the following values: 'SV_MISMATCH_IN_APP_DESC_AND_CU' (Occurs when references to software vendor in application description and control unit don't match.), 'VALID_FROM_AND_VALID_TO_INCONSISTENCY' (Occurs when some inconsistency was detected during 'ValidFrom' or 'ValidTo' validation.), 'ACTIVATION_CODE_WRONG_LENGTH' (Occurs during activation process when activation code is tested.), 'ACTIVATION_CODE_ALREADY_EXISTS' (Occurs during activation process when passed activation has its signature already.), 'ACTIVATION_STATUS_IS_NOT_MODIFIABLE_BY_PUT' (Occurs in case of attempting to modify activation status by 'PUT' http method.), 'QUERY_PARAM_CANT_BE_NEGATIVE' (Occurs if passed query parameter is negative, but positive of zero value is expected.), 'SELLER_HAS_NOT_REGISTRATION' (Occurs when passed by query param cash register name doesn't belong to the passed seller.), 'SELLER_SHOULD_BE_PROVIDED_FOR_CR' (Occurs when cash register name passed as query param without specified seller.), 'SERVER_IS_OVERLOADED' ( Occurs when retrieving data bulk is too large. It signals to specify maxResults param to not greater that some limit. ), 'IDENTIFIER_LENGTH_VIOLATION' (Occurs when passed identifier (for instance, seller identifier) doesn't fit into length requirements.), 'SERVER_CANT_BE_REMOVED' (Occurs in case of attempting to remove current working server.), 'URL_AND_BODY_IDENTIFIERS_MISMATCH' ( Occurs when identifier in URL and body is not the same. Commonly, it is used to forbid changing identifier by PUT. ), 'LOCAL_AND_SERVER_VERSIONS_INCONSISTENCY' (Occurs when passed version is more then server's one.), 'WORKING_WITH_CU_IS_NOT_SUPPORTED_BY_APP' (Occurs when application without ability to work with control units attempts to send a kd.), 'PRODUCTION_NUMBER_AND_CONNECTION_MISMATCH' (Occurs during connection to activation process when connection production number is not equal with installation.), 'PRODUCTION_NUMBER_AND_DEVICE_ID_MISMATCH' (Occurs during ordering an activation. Indicates that passed production number doesn't belong to device.), 'REGISTRATION_EXISTS_FOR_SELLER_AND_INSTALLATION' (Occurs during ordering an activation. Indicates that registration already exists for the same seller and installation. ), 'ACTIVATION_APPLICATION_PACKAGE_MUST_BE_NULL_OR_EQUAL' (Occurs during ordering an activation. ApplicationPackage must be null or equal to applicationPackage for installation from database. ), 'ACTIVATION_PRODUCTION_NUMBER_SHOULD_BE_NULL' (Occurs during ordering an activation. Production number should be null.), 'ACTIVATION_PRODUCTION_NUMBER_SHOULD_BE_NULL_OR_EQUAL' (Occurs during ordering an activation. Production number should be null or equal to production number from database. ), 'ACTIVATION_MUST_HAVE_INSTALLATION_OR_ACTIVATION_CODE'.

UnprocessableEntityErrorType

Enum describes error codes corresponding to UnprocessableEntityJsonException. One of the following values: 'TREASURER_IS_JOINED_TO_USER_ALREADY' ( Occurs on attempt to join treasurer which is joined already. Need to disjoin treasurer from user at first. ), 'USER_HAS_TREASURER_WITH_SAME_SELLER_ID_ALREADY' (Occurs on attempt to join treasurer, but user has treasurer with same seller id already.), 'TREASURER_IS_NOT_JOINED_TO_USER' ( Occurs on disjoin treasurer. Indicates that treasurer is not joined to any user and disjoin doesn't make any sense. ), 'COMPANY_NAME_MUST_BE_SET_IF_NO_SELLER' (Occurs if both passed seller wasn't found and company name wasn't set.), 'CU_LOCATION_MUST_BE_SET' (Occurs on attempt to set control unit without geolocation info specified.), 'INSTALLATION_IS_OUT_OF_DATE' ( Indicates that passed production number is out of date with device since another instance of application was installed already. Reinstall of application is suggested. ), 'CU_IS_MISSING_FOR_ACTIVATION' (Indicates that control unit should be set if application is working with control unit), 'AUTO_ACTIVATE_IS_NOT_POSSIBLE_ON_NEW_CU' ( Occurs during ordering an activation. Indicates the attempt to enable auto-activation upon not yet registered control unit. ), 'PRODUCTION_NUMBER_AND_DEVICE_ID_MISMATCH' ( Occurs during ordering an activation. Indicates that passed production number doesn't belong to device. Reinstall of application is suggested. ), 'APPLICATION_PACKAGES_MISMATCH' ( Occurs during ordering an activation. Indicates that passed application package in the request body and another one identified by production number are not the same. ), 'APP_DESC_HAS_REFERENCED_DATA' (Occurs on attempt to remove application description which is referenced in another entities.), 'SOFTWARE_VENDOR_HAS_REFERENCED_DATA' ( Occurs on attempt to remove software vendor which is referenced in another entities. ), 'SOFTWARE_VENDOR_IS_MISSING' (Occurs on attempt to create/edit user with ROLE_SOFTWARE_VENDOR_ADMIN.), 'PROHIBITED_ORDER_STATUS_CHANGE' (Occurs on attempt to change status of order which breaks conceived logic.), 'CU_HAS_REFERENCED_DATA' ( Occurs on attempt to delete the control unit which has referenced data. ), 'DAY_IS_CLOSED' ( Occurs when current day is closed. ), 'DAY_IS_NOT_CLOSED' ( Occurs when current day isn't closed. ), 'RECEIPT_IS_PRINTED_ALREADY' ( Occurs when current receipt is printed already. ), 'RECEIPT_IS_NOT_PRINTED' ( Occurs when current receipt is not printed yet. ), 'REPORT_IS_PRINTED_ALREADY' ( Occurs when report is printed already. ), 'REPORT_IS_NOT_PRINTED' ( Occurs when report is not printed yet. ), 'ACTIVATION_IS_CLOSED_ALREADY' ( Occurs when activation is closed already. ), 'ACTIVATION_IS_ACTIVE_ALREADY' ( Occurs when activation is active already. ), 'ACTIVATION_IS_WORKING_ALREADY' ( Occurs when activation is working already. ), 'ORDER_ALREADY_HAS_PRECEPT' ( Occurs when new precept is creating with order that already has precept. ), 'SELLER_MUST_HAVE_CURRENCY' ( Occurs when currency is necessary for make payment and seller doesn't have it. ), 'CONTROL_UNIT_IS_CONNECTED_ALREADY' ( Control unit is connected to SV already. ), 'CONTROL_UNIT_IS_DISCONNECTED_ALREADY'.

ValueNotValidErrorType

Enum describes error codes corresponding to ValueNotValidJsonException. One of the following values: 'SHOULD_NOT_BE_NULL' (Occurs if non-null constraint violated.), 'SHOULD_MATCH_PATTERN' ( Occurs if regex violated. See params in details by keys 'actualValue' and 'pattern'. ), 'SIZE_SHOULD_BE_EQUAL_EXACTLY' ( Says that size of the field in characters should be equal to limiting number. See params in details 'actualValue', 'sizeMin' and 'sizeMax'. ), 'SIZE_SHOULD_BE_LESS_THEN' ( Says that size of the field in characters should be less then limiting number. See params in details by keys 'actualValue', 'sizeMin' and 'sizeMax'. ), 'SIZE_SHOULD_BE_MORE_THEN' ( Says that size of the field in characters should be more or equal then limiting number. See params in details by keys 'actualValue', 'sizeMin' and 'sizeMax'. ), 'SIZE_SHOULD_BE_IN_RANGE' ( Says that size of the field in characters should be in some range. See params in details by keys actualValue' and 'pattern'. ), 'VALUE_SHOULD_BE_GREATER_THEN' ( Says that numerical value should be greater or equal then some limiting value. See params in details by keys 'actualValue' and 'valueMin'. ), 'VALUE_SHOULD_BE_LESS_THEN' ( Says that numerical value should be less or equal then some limiting value. See params in details by keys 'actualValue' and 'valueMax'. ), 'VALUE_SHOULD_NOT_BE_NEGATIVE' ( Says that value should be positive. See params in details by keys 'actualValue' and 'valueMin'. ), 'SHOULD_MATCH_CORPORATE_ID_VALIDATION_SWEDISH' (Says that seller's corporate id failed to pass swedish validation.), 'SHOULD_MATCH_CORPORATE_ID_VALIDATION_LUHN' (Says that seller's corporate id failed to pass Luhn-algorithm validation.), 'SHOULD_BE_BASE64_ENCODED'.

ForbiddenErrorType

Enum describes error codes corresponding to ForbiddenJsonException. One of the following values: 'INSUFFICIENT_ACCESS_RIGHTS' ( It is most used code, which covers cases when credentials is not sufficient to perform request or, for example, on attempt to get non-public data. ), 'ACTIVATION_CLOSED_ALREADY' ( If activation in credentials is closed already. I.e. it is in the CLOSED state. ), 'ACTIVATION_STILL_ISSUED' ( If activation in credentials is not activated. I.e. it is in the ISSUED state. ), 'ACTIVATION_NO_FEATURE' ( If activation doesn't have required feature. I.e. it is in the {@link com.srv4pos.server.api.activation.Feature} state. ), 'SELLER_NOT_FOUND' ( If there is credentials and seller with given country and corporate id is not registered. If caught, you should register yourself on the server. ), 'WRONG_ACTIVATION_PERIOD' ( If either activation's period haven't started yet or has expired already. ), 'WRONG_USERNAME_OR_PASSWORD' ( If either username or password failed to pass authorization. User should get "Please contact sales@srv4pos.com if this error appears longer than 24h". ), 'AUTHORIZATION_DATA_IS_NOT_VALID' ( When auth data doesn't pass verification. For example, if username is empty. ), 'INCOMPATIBILITY_OF_SESSION_ID' ( When passed session id hasn't passed verification. ), 'CU_ARE_NOT_MANAGEABLE_BY_SVA' ( When software vendor isn't able to manage CU. ), 'REGISTRATION_IS_NOT_THINKASSAN' ( When used registration is not thinkassan but needs to be. ), 'EMAIL_IS_NOT_FREE' ( When attempt to send a free email on non-free address. ), 'DIBS_VERIFICATION_FAILURE' ( When dibs verification fails. ), 'SELLER_IS_NOT_PUBLIC' ( When requested seller is not public. ), 'OLD_PASSWORD_IS_INCORRECT'.

ServiceUnavailableErrorType

Represents types or error for 503 HTTP code. One of the following values: 'SERVER_IS_DOWN' ( When server is down or under maintenance. ), 'REQUIRES_SETUP'.

PictureReportErrorType

Represents error codes for pictures inconsistency for both filesystem to database and vice verse. One of the following values: 'SELLER_MISSING_IN_DB', 'ENTITY_MISSING_IN_DB', 'PIC_MISSING_IN_DB', 'PIC_VERSION_MISSING_IN_DB', 'SELLER_MISSING_IN_FS', 'ENTITY_MISSING_IN_FS', 'PIC_MISSING_IN_FS', 'PIC_VERSION_MISSING_IN_FS', 'LAST_VERSIONS_MISMATCH', 'DELETED_STATUS_MISMATCH'.

orderPaymentStatus

One of the following values: 'NEW' (The order has been created.), 'PAID' (The order has been paid.), 'REJECTED'.

dateGroupingUnit

One of the following values: 'HOUR' ( If duration of period is from 0 to 2 days. 48 grouped parts is maximum (48 hours). ), 'DAY' ( If duration of period is from 3 to 30 days. 30 grouped parts is maximum (30 days). ), 'WEEK' ( If duration of period is from 31 to 84 days. 12 grouped parts is maximum (12 weeks). ), 'MONTH' ( If duration of period is from 85 to 550 days. 18 grouped parts is maximum (18 months). ), 'QUARTER' ( If duration of period is from 551 to 1461 days. 8 grouped parts is maximum (8 quarters). ), 'YEAR'.

preceptStatusType

One of the following values: 'NEW' (Precept has been created.), 'PRINTED' (Precept has been printed.), 'READY'.

dayOfWeek

One of the following values: 'MONDAY', 'TUESDAY', 'WEDNESDAY', 'THURSDAY', 'FRIDAY', 'SATURDAY', 'SUNDAY'.

dibsResponseStatus

One of the following values: 'ACCEPT', 'DECLINE', 'ERROR'.

GET /v26/auth/handshake

This method is very useful to check authentication. Call it to make sure you are successfully authenticated.

Request

GET /v26/auth/handshake HTTP/1.1 Host: t.srv4pos.com

Response

HTTP/1.1 200 OK

Errors

403 ForbiddenJsonException

See there: SELLER_NOT_FOUND .

GET /v26/auth/user

Gets user info and connected sellers to user in credentials.

Request

GET /v26/auth/user HTTP/1.1
Authorization: RestApiTester@se9876543210:9999
Host: t.srv4pos.com

Response

HTTP/1.1 200 OK Content-Type: application/json;charset=UTF-8
{/* Describes user and sellers connected to this user. */ 'userInfo': {/* Non-public information of user for super admins. It has password hash. */ 'deleted': 'false', // True if entity was deleted.
'username': 'username', // Regular field. String. Minimum 1 characters. Maximum 50 characters. May NOT be null.
'email': 'mail@username.com', // User's email. String. Minimum 6 characters. Maximum 50 characters. Regular expression [a-zA-Z0-9\\+\\.\\_\\%\\-\\+]{1,256}\\@[a-zA-Z0-9][a-zA-Z0-9\\-]{0,64}(\\.[a-zA-Z0-9][a-zA-Z0-9\\-]{0,25})+ . May NOT be null.
'role': 'ROLE_SOFTWARE_VENDOR_ADMIN', // roleType. May NOT be null.
'softwareVendor': null // If role == ROLE_HYPER_ADMIN, then null. If role == ROLE_SOFTWARE_VENDOR_ADMIN, then not null. Integer. May be null.
}, // A complex object.
'connectedSellers': [ {/* Same set of field as in SellerLog allowed to be public. */ 'corporateId': '9876543210', // corporateIdType. May NOT be null.
'name': 'CompanyName', // String. Maximum 96 characters. May be null.
'country': 'se' // countryType. May NOT be null.
} ] // List of objects.
}

Errors

403 ForbiddenJsonException

See there: INSUFFICIENT_ACCESS_RIGHTS, WRONG_USERNAME_OR_PASSWORD .

POST /v26/activations-advanced

If current application does not have Activation the app uses this method to request (order) new one.
Seller for the activation is identified by country and corporateId.
Installation:
  • can be found as via registration (seller and cash register name); production number should be null or equal, application package should be null or equal
  • can be found as via production number; application package should be null or equal
  • can be null, if activation's application is ThinKassan; production number should be null
  • can be null, if installation will be connected to this activation via connectionCode later

Registration will be found or created by seller and installation. Note. If there is a Swedish application, ValueNotValidJsonException#SHOULD_MATCH_CORPORATE_ID_VALIDATION_SWEDISH for invalid corporate ID will be thrown.

Request

POST /v26/activations-advanced HTTP/1.1 Content-Type: application/json Host: t.srv4pos.com { 'country': 'se', // countryType. May NOT be null.
'corporateId': '9876543210', // corporateIdType. May NOT be null.
'cashRegisterName': 'Cash1', // cashRegisterNameType. May NOT be null.
'validFrom': new Date().setHours(0,0,0,0), // When activation starts being active. Date: amount of milliseconds since UNIX epoch. May NOT be null.
'validTo': new Date(new Date().getTime()+31536000000).setHours(0,0,0,0), // When activation ends being active. Date: amount of milliseconds since UNIX epoch. May NOT be null.
'features': [], // List of features. List of values. activationFeatureType. May NOT be null.
'comment': '', // Any information which user would like to tell to sales at srv4pos. String. May be null.
'contactInfo': {/* Information about person. */ 'name': 'Stefan', // Name of person who makes activation String. May NOT be null.
'phone': '56745325', // Phone number of person who requests activation String. May NOT be null.
'email': 'test@test.se' // Email of person who requests activation String. May NOT be null.
}, // Information about person who orders an activation. So sales team can contact him with invoice. A complex object. May be null.
'controlUnitSerial': null, // Serial number of contorl unit. It is null if "controlUnitLocation" == 'REMOTE' or application doesn't support control units. Otherwise it might be null too. String. May be null.
'controlUnitLocation': 'DEVICE', // Where control unit is connected and how. controlUnitLocationType. May be null.
'controlUnitGeolocation': {/* Just simple address structure. */ 'address': 'address', // String. May NOT be null.
'city': 'Koenig', // String. May NOT be null.
'postalCode': '45664' // String. May NOT be null.
}, // Where device (with control unit) is located. This information is sent to taxation authority. This field is set when customer makes an order and "controlUnitLocation" == 'DEVICE'. If this field is set and sales person makes an activation, he must check it's validity because it's content will be copied to controlUnit geolocation and will be applied for all the sellers connected to this control unit. A complex object. May be null.
'applicationPackage': 'com.pos4mobile', // applicationPackageType. May be null.
'productionNumber': null, // productionNumberType. May be null.
'installationCreationInfo': { 'deviceId': '111AAA222BBB3-022', // deviceIdType. May NOT be null.
'buildInfo': {}, // Information about the device. For instance for Android it can be taken from android.os.Build A complex object. May NOT be null.
'gcmRegistrationId': null // An identifier of the device on Google Cloud Message service String. May be null.
}, // At which device this activation should work. A complex object. May be null.
'connectionCode': null // With this connection code a new installation can be attached to this activation later String. Minimum 4 characters. Maximum 9 characters. May be null.
}

Response

HTTP/1.1 201 CREATED Content-Type: application/json;charset=UTF-8 /* ActivationSecurity - entity contains unique secure random identifier which represents activation ordered, production number and activation id. */
{ 'apiKey': '-:s854kfsdgfwqei32445u4ry9efh2o398y1r2y3hr', // Securely randomly generated number, represents the order. It has to be passed to the server to get an activation based on the order made. String. May NOT be null.
'productionNumber': 'PM22500000000000000061191', // productionNumberType. May NOT be null.
'activationId': 8071436 // Activation id. It's debug information Integer. May NOT be null.
}

Errors

404 ReferenceNotFoundJsonException

If installation by seller (by country andcorporateId) andcashRegisterName, applicationPackage or controlUnitSerial in request body weren't found.

400 NonUniqueJsonException

If cash register name is not unique within a seller.

409 InconsistentDataJsonException

See there: VALID_FROM_AND_VALID_TO_INCONSISTENCY, REGISTRATION_EXISTS_FOR_SELLER_AND_INSTALLATION, SV_MISMATCH_IN_APP_DESC_AND_CU, REGISTRATION_EXISTS_FOR_SELLER_AND_INSTALLATION, ACTIVATION_APPLICATION_PACKAGE_MUST_BE_NULL_OR_EQUAL, ACTIVATION_PRODUCTION_NUMBER_SHOULD_BE_NULL, ACTIVATION_PRODUCTION_NUMBER_SHOULD_BE_NULL_OR_EQUAL, ACTIVATION_MUST_HAVE_INSTALLATION_OR_ACTIVATION_CODE .

422 UnprocessableEntityJsonException

See there: CU_LOCATION_MUST_BE_SET, CU_IS_MISSING_FOR_ACTIVATION, INSTALLATION_IS_OUT_OF_DATE .

400 ValueNotValidJsonException

See there: SHOULD_MATCH_CORPORATE_ID_VALIDATION_SWEDISH .

POST /v26/activations-advanced

If current application does not have Activation the app uses this method to request (order) new one.
Seller and/or installation will be created, if it's needed.

Request

POST /v26/activations-advanced HTTP/1.1 Content-Type: application/json Host: t.srv4pos.com { 'country': 'se', // countryType. May NOT be null.
'corporateId': '9876543210', // corporateIdType. May NOT be null.
'cashRegisterName': 'Cash1', // cashRegisterNameType. May NOT be null.
'applicationPackage': 'com.pos4mobile', // applicationPackageType. May be null.
'features': [], // List of features. List of values. activationFeatureType. May NOT be null.
'validFrom': new Date().setHours(0,0,0,0), // When activation starts being active. Date: amount of milliseconds since UNIX epoch. May NOT be null.
'validTo': new Date(new Date().getTime()+31536000000).setHours(0,0,0,0), // When activation ends being active. Date: amount of milliseconds since UNIX epoch. May NOT be null.
'contactInfo': {/* Information about person. */ 'name': 'Stefan', // Name of person who makes activation String. May NOT be null.
'phone': '56745325', // Phone number of person who requests activation String. May NOT be null.
'email': 'test@test.se' // Email of person who requests activation String. May NOT be null.
}, // Information about person who orders an activation. So sales team can contact him with invoice. A complex object. May be null.
'comment': '', // Any information which user would like to tell to sales at srv4pos. String. May be null.
'controlUnitSerial': null, // Serial number of contorl unit. It is null if "controlUnitLocation" == 'REMOTE' or application doesn't support control units. Otherwise it might be null too. String. May be null.
'controlUnitLocation': 'DEVICE', // Where control unit is connected and how. controlUnitLocationType. May be null.
'controlUnitGeolocation': {/* Just simple address structure. */ 'address': 'address', // String. May NOT be null.
'city': 'Koenig', // String. May NOT be null.
'postalCode': '45664' // String. May NOT be null.
}, // Where device (with control unit) is located. This information is sent to taxation authority. This field is set when customer makes an order and "controlUnitLocation" == 'DEVICE'. If this field is set and sales person makes an activation, he must check it's validity because it's content will be copied to controlUnit geolocation and will be applied for all the sellers connected to this control unit. A complex object. May be null.
'installationCreationInfo': { 'deviceId': '111AAA222BBB3-022', // deviceIdType. May NOT be null.
'buildInfo': {}, // Information about the device. For instance for Android it can be taken from android.os.Build A complex object. May NOT be null.
'gcmRegistrationId': null // An identifier of the device on Google Cloud Message service String. May be null.
} // At which device this activation should work. A complex object. May be null.
}

Response

HTTP/1.1 201 CREATED Content-Type: application/json;charset=UTF-8 /* ActivationSecurity - entity contains unique secure random identifier which represents activation ordered, production number and activation id. */
{ 'apiKey': '-:s854kfsdgfwqei32445u4ry9efh2o398y1r2y3hr', // Securely randomly generated number, represents the order. It has to be passed to the server to get an activation based on the order made. String. May NOT be null.
'productionNumber': 'PM22500000000000000061191', // productionNumberType. May NOT be null.
'activationId': 8071436 // Activation id. It's debug information Integer. May NOT be null.
}

Errors

404 ReferenceNotFoundJsonException

If applicationPackage or controlUnitSerial in request body weren't found.

400 NonUniqueJsonException

If cash register name is not unique within a seller.

409 InconsistentDataJsonException

See there: VALID_FROM_AND_VALID_TO_INCONSISTENCY, REGISTRATION_EXISTS_FOR_SELLER_AND_INSTALLATION, SV_MISMATCH_IN_APP_DESC_AND_CU .

422 UnprocessableEntityJsonException

See there: CU_LOCATION_MUST_BE_SET, CU_IS_MISSING_FOR_ACTIVATION .

POST /v26/activations-advanced

If current application does not have Activation the app uses this method to request (order) new one.
Seller and/or installation will be created, if it's needed.

Request

POST /v26/activations-advanced HTTP/1.1 Content-Type: application/json Host: t.srv4pos.com { 'country': 'se', // countryType. May NOT be null.
'corporateId': '9876543210', // corporateIdType. May NOT be null.
'cashRegisterName': 'Cash1', // cashRegisterNameType. May NOT be null.
'applicationPackage': 'com.pos4mobile', // A unique identifier of the software, but not it's version. For instance for Android it can be getPackageName() String. Maximum 120 characters. May be null.
'features': [], // List of features. List of values. activationFeatureType. May NOT be null.
'validFrom': new Date().setHours(0,0,0,0), // When activation starts being active. Date: amount of milliseconds since UNIX epoch. May NOT be null.
'validTo': new Date(new Date().getTime()+31536000000).setHours(0,0,0,0), // When activation ends being active. Date: amount of milliseconds since UNIX epoch. May NOT be null.
'contactInfo': {/* Information about person. */ 'name': 'Stefan', // Name of person who makes activation String. May NOT be null.
'phone': '56745325', // Phone number of person who requests activation String. May NOT be null.
'email': 'test@test.se' // Email of person who requests activation String. May NOT be null.
}, // Information about person who orders an activation. So sales team can contact him with invoice. A complex object. May be null.
'comment': '', // Any information which user would like to tell to sales at srv4pos. String. May be null.
'installationCreationInfo': { 'deviceId': '111AAA222BBB3-022', // deviceIdType. May NOT be null.
'buildInfo': {}, // Information about the device. For instance for Android it can be taken from android.os.Build A complex object. May NOT be null.
'gcmRegistrationId': null // An identifier of the device on Google Cloud Message service String. May be null.
} // At which device this activation should work. A complex object. May be null.
}

Response

HTTP/1.1 201 CREATED Content-Type: application/json;charset=UTF-8 /* ActivationSecurity - entity contains unique secure random identifier which represents activation ordered, production number and activation id. */
{ 'apiKey': '-:s854kfsdgfwqei32445u4ry9efh2o398y1r2y3hr', // Securely randomly generated number, represents the order. It has to be passed to the server to get an activation based on the order made. String. May NOT be null.
'productionNumber': 'PM22500000000000000061191', // productionNumberType. May NOT be null.
'activationId': 8071436 // Activation id. It's debug information Integer. May NOT be null.
}

Errors

404 ReferenceNotFoundJsonException

If applicationPackage in request body wasn't found.

400 NonUniqueJsonException

If cash register name is not unique within a seller.

409 InconsistentDataJsonException

See there: VALID_FROM_AND_VALID_TO_INCONSISTENCY, REGISTRATION_EXISTS_FOR_SELLER_AND_INSTALLATION .

POST /v26/activations-advanced

Prolongation for the activation, which is identified by country, corporateId, cashRegisterName.

Request

POST /v26/activations-advanced HTTP/1.1 Content-Type: application/json Host: t.srv4pos.com { 'country': 'se', // countryType. May NOT be null.
'corporateId': '9876543210', // corporateIdType. May NOT be null.
'cashRegisterName': 'Cash1', // cashRegisterNameType. May NOT be null.
'features': [], // List of features. List of values. activationFeatureType. May NOT be null.
'validFrom': new Date().setHours(0,0,0,0), // When activation starts being active. Date: amount of milliseconds since UNIX epoch. May NOT be null.
'validTo': new Date(new Date().getTime()+31536000000).setHours(0,0,0,0), // When activation ends being active. Date: amount of milliseconds since UNIX epoch. May NOT be null.
'contactInfo': {/* Information about person. */ 'name': 'Stefan', // Name of person who makes activation String. May NOT be null.
'phone': '56745325', // Phone number of person who requests activation String. May NOT be null.
'email': 'test@test.se' // Email of person who requests activation String. May NOT be null.
}, // Information about person who orders an activation. So sales team can contact him with invoice. A complex object. May be null.
'comment': '', // Any information which user would like to tell to sales at srv4pos. String. May be null.
'controlUnitSerial': null, // Serial number of contorl unit. It is null if "controlUnitLocation" == 'REMOTE' or application doesn't support control units. Otherwise it might be null too. String. May be null.
'controlUnitLocation': 'DEVICE', // Where control unit is connected and how. controlUnitLocationType. May be null.
'controlUnitGeolocation': {/* Just simple address structure. */ 'address': 'address', // String. May NOT be null.
'city': 'Koenig', // String. May NOT be null.
'postalCode': '45664' // String. May NOT be null.
} // Where device (with control unit) is located. This information is sent to taxation authority. This field is set when customer makes an order and "controlUnitLocation" == 'DEVICE'. If this field is set and sales person makes an activation, he must check it's validity because it's content will be copied to controlUnit geolocation and will be applied for all the sellers connected to this control unit. A complex object. May be null.
}

Response

HTTP/1.1 201 CREATED Content-Type: application/json;charset=UTF-8 /* ActivationSecurity - entity contains unique secure random identifier which represents activation ordered, production number and activation id. */
{ 'apiKey': '-:s854kfsdgfwqei32445u4ry9efh2o398y1r2y3hr', // Securely randomly generated number, represents the order. It has to be passed to the server to get an activation based on the order made. String. May NOT be null.
'productionNumber': 'PM22500000000000000061191', // productionNumberType. May NOT be null.
'activationId': 8071436 // Activation id. It's debug information Integer. May NOT be null.
}

Errors

404 ReferenceNotFoundJsonException

If installation by seller (by country andcorporateId) and cashRegisterName or controlUnitSerial in request body weren't found.

400 NonUniqueJsonException

If cash register name is not unique within a seller.

409 InconsistentDataJsonException

See there: VALID_FROM_AND_VALID_TO_INCONSISTENCY, SV_MISMATCH_IN_APP_DESC_AND_CU .

422 UnprocessableEntityJsonException

See there: CU_LOCATION_MUST_BE_SET, CU_IS_MISSING_FOR_ACTIVATION, INSTALLATION_IS_OUT_OF_DATE .

POST /v26/activations-advanced

Prolongation for the activation, which is identified by country, corporateId, cashRegisterName.

Request

POST /v26/activations-advanced HTTP/1.1 Content-Type: application/json Host: t.srv4pos.com { 'country': 'se', // countryType. May NOT be null.
'corporateId': '9876543210', // corporateIdType. May NOT be null.
'cashRegisterName': 'Cash1', // cashRegisterNameType. May NOT be null.
'features': [], // List of features. List of values. activationFeatureType. May NOT be null.
'validFrom': new Date().setHours(0,0,0,0), // When activation starts being active. Date: amount of milliseconds since UNIX epoch. May NOT be null.
'validTo': new Date(new Date().getTime()+31536000000).setHours(0,0,0,0), // When activation ends being active. Date: amount of milliseconds since UNIX epoch. May NOT be null.
'contactInfo': {/* Information about person. */ 'name': 'Stefan', // Name of person who makes activation String. May NOT be null.
'phone': '56745325', // Phone number of person who requests activation String. May NOT be null.
'email': 'test@test.se' // Email of person who requests activation String. May NOT be null.
}, // Information about person who orders an activation. So sales team can contact him with invoice. A complex object. May be null.
'comment': '' // Any information which user would like to tell to sales at srv4pos. String. May be null.
}

Response

HTTP/1.1 201 CREATED Content-Type: application/json;charset=UTF-8 /* ActivationSecurity - entity contains unique secure random identifier which represents activation ordered, production number and activation id. */
{ 'apiKey': '-:s854kfsdgfwqei32445u4ry9efh2o398y1r2y3hr', // Securely randomly generated number, represents the order. It has to be passed to the server to get an activation based on the order made. String. May NOT be null.
'productionNumber': 'PM22500000000000000061191', // productionNumberType. May NOT be null.
'activationId': 8071436 // Activation id. It's debug information Integer. May NOT be null.
}

Errors

404 ReferenceNotFoundJsonException

If installation by seller (by country andcorporateId) and cashRegisterName or controlUnitSerial in request body weren't found.

400 NonUniqueJsonException

If cash register name is not unique within a seller.

409 InconsistentDataJsonException

See there: VALID_FROM_AND_VALID_TO_INCONSISTENCY .

422 UnprocessableEntityJsonException

See there: INSTALLATION_IS_OUT_OF_DATE .

POST /v26/noauth/activations/cash-register-name/existance

Checks that cash register name is unique for particular seller.

Request

POST /v26/noauth/activations/cash-register-name/existance HTTP/1.1 Content-Type: application/json Host: t.srv4pos.com {/* Parameters passed to ActivationService#cashRegisterNameExists(CashRegisterNameExistsInfo). */ 'country': 'se', // countryType. May NOT be null.
'corporateId': '9876543210', // corporateIdType. May NOT be null.
'cashRegisterName': 'Cash1' // cashRegisterNameType. May NOT be null.
}

Response

HTTP/1.1 201 CREATED Content-Type: application/json;charset=UTF-8
{ 'exists': false // True if cash register with given name is already registered for particular seller. Boolean. May NOT be null.
}

Errors

400 NonUniqueJsonException

When passed data violates some unique constraint. Details can have more then one violated field, it means that constraint is composite.

POST /v26/activations/activation-code

This method requires credentials and returns Activation Code for provided credentials.

Request

POST /v26/activations/activation-code HTTP/1.1
Authorization: -:AbcDeFgqWertY1Mxxjl74rpocd2445hfV
Host: t.srv4pos.com

Response

HTTP/1.1 201 CREATED Content-Type: application/json;charset=UTF-8
{ 'activationInfoVersion': 2, // Version of data structure, returned by. The device has to support all the previous versions to avoid reactivation. Also this version changes when public/private key for "signature" generation is changed, or algorithm of serializing "activationDescriptorInfo" is changed. Right now it is 2. Integer. May NOT be null.
'activationDescriptorInfo': 'TODO show json here', // Json serialized data returned by . String. May NOT be null.
'signature': 'TODO show signature here', // Digital signature of activationDescriptorInfo. String. May NOT be null.
'publicKeyFileName': 'file.pc' // The file name for the public key, which should be used for signature.
}

Errors

403 ForbiddenJsonException

See there: ACTIVATION_STILL_ISSUED, WRONG_USERNAME_OR_PASSWORD .

POST /v26/activations/connection

This method activate activation by code.

Request

POST /v26/activations/connection HTTP/1.1 Content-Type: application/json Host: t.srv4pos.com { 'installationInfo': { 'id': 654353, // Deprecated, please use productionNumber Integer. May be null.
'deviceId': '111AAA222BBB3-022', // deviceIdType. May NOT be null.
'buildInfo': {'KEY1':'VALUE1', 'KEY2':'VALUE2'}, // A complex object. May NOT be null.
'applicationPackage': 'package', // applicationPackageType. May NOT be null.
'gcmRegistrationId': '123', // String. Minimum 1 characters.
'productionNumber': 'TEST100000000000000000081', // productionNumberType.
'registrationDate': 45672345, // Date: amount of milliseconds since UNIX epoch.
'gcmUnsubscribeDate': 45672345 // Date: amount of milliseconds since UNIX epoch.
}, // At which device this activation should work. A complex object. May NOT be null.
'activationCode': '123456789' // String. Minimum 4 characters. Maximum 9 characters. May NOT be null.
}

Response

HTTP/1.1 201 CREATED Content-Type: application/json;charset=UTF-8
{ 'activationCodeInfo': { 'activationInfoVersion': 2, // Version of data structure, returned by. The device has to support all the previous versions to avoid reactivation. Also this version changes when public/private key for "signature" generation is changed, or algorithm of serializing "activationDescriptorInfo" is changed. Right now it is 2. Integer. May NOT be null.
'activationDescriptorInfo': 'TODO show json here', // Json serialized data returned by . String. May NOT be null.
'signature': 'TODO show signature here', // Digital signature of activationDescriptorInfo. String. May NOT be null.
'publicKeyFileName': 'file.pc' // The file name for the public key, which should be used for signature.
}, // A complex object. May NOT be null.
'activationSecurityToken': '', // String. Maximum 33 characters. May NOT be null.
'activationId': // Integer. May NOT be null.
}

Errors

404 ReferenceNotFoundJsonException

Activation not found by code.

409 InconsistentDataJsonException

See there: ACTIVATION_CODE_WRONG_LENGTH, PRODUCTION_NUMBER_AND_CONNECTION_MISMATCH, PRODUCTION_NUMBER_AND_DEVICE_ID_MISMATCH .

422 UnprocessableEntityJsonException

See there: APPLICATION_PACKAGES_MISMATCH .

POST /v26/pospluses/kd

Sends data to control unit.

Request

POST /v26/pospluses/kd HTTP/1.1 Content-Type: application/json
Authorization: -:AbcDeFgqWertY1Mxxjl74rpocd2445hfV
Host: t.srv4pos.com { 'brutto': 1000, // Integer. May NOT be null.
'vatRateToSum': {'6':1000}, // A javascript object. The key - tax value. The value - the sum. E.g. 20.12 SEK splitted between 12.05 SEK for VAT 6% and 10.07 SEK for VAT 12% will do {'6': 1205, '12': 1007}. A complex object. May NOT be null.
'refund': false, // Boolean. May NOT be null.
'printType': 'Normal', // printType. May NOT be null.
'receiptNumber': 1, // Autoincrement receipt number within one POS terminal. Integer. May be null.
'date': 1414800000001 // Date: amount of milliseconds since UNIX epoch. May NOT be null.
}

Response

HTTP/1.1 201 CREATED Content-Type: application/json;charset=UTF-8
{ 'response': 'K34P72NUH7A3HST7HY7EF6RUWJLLWVOC; MKFXCN7ENWYJS4KRP3JJ3KG64M', // String. May NOT be null.
'controlUnitSerial': 'PTEST900000000001' // String. May NOT be null.
}

Errors

500 ControlUnitReceiptJsonException

Thrown when Control Unit decides something is wrong according to it's internal business logic. Thrown by the control unit itself. The details contains three fields:

  1. command
  2. response
  3. name
The name is one of the following:
  • InternLoggFull24(24)
  • InternaRaknareSaturerade23(23)
  • FaltForekommerEfterSistaCRC22(22)
  • FelaktigtForhallandeForsaljRetur21(21)
  • PowerFailAbort20(20)
  • InterntSkrivfel19(19)
  • InterntSkrivfel18(18)
  • InterntSkrivfel17(17)
  • InterntSkrivfel16(16)
  • InterntSkrivfel15(15)
  • AntalAnvandareHarOverskridits14(14)
  • FelaktigMoms4_13(13)
  • FelaktigMoms3_12(12)
  • FelaktigMoms2_11(11)
  • FelaktigMoms1_10(10)
  • FelaktigtForsaljningsbelopp9(9)
  • FelaktigtReturbelopp8(8)
  • KvittotypSaknas7(7)
  • FelaktigKvittotyp6(6)
  • FelaktigtLopnummer5(5)
  • FelaktigtKassaID4(4)
  • FelaktigtOrganisationsnummer3(3)
  • FelaktigtDatumTid2(2)
  • FelAntalArgument1(1)
  • OK0(0)
  • FelaktigLangd_1(-1)
  • CRCError_2(-2)
  • OkantKommando_3(-3)

409 InconsistentDataJsonException

See there: WORKING_WITH_CU_IS_NOT_SUPPORTED_BY_APP .

500 ControlUnitUnavailableJsonException

When server is unable to reach the control unit device (for instance it's ejected from the server). No additional details provided.

500 ControlUnitCommunicationJsonException

When error has happened during transmission data to the control unit (for instance it was ejected from the server during sending the data). No additional details provided.

GET /v26/sellers/{sellerId}

Get latest information about the eller from the server.
sellerId Identifier of seller sellerIdType. May NOT be null.

Request

GET /v26/sellers/se9876543210 HTTP/1.1
Authorization: RestApiTester@se9876543210:9999
Host: t.srv4pos.com

Response

HTTP/1.1 200 OK Content-Type: application/json;charset=UTF-8 /* returns if request has been done anonymously and full info otherwise */
{ 'corporateId': '9876543210', // corporateIdType. May NOT be null.
'name': 'CompanyName', // String. Maximum 96 characters. May be null.
'country': 'se', // countryType. May NOT be null.
'publicAccess': true, // Boolean. May NOT be null.
'description': 'description', // String. Maximum 1024 characters. May be null.
'city': 'Koenig', // String. Maximum 255 characters. May be null.
'workHours': '24', // String. Maximum 255 characters. May be null.
'workHoursWeek': { 'MONDAY': {/* Describes work hours of specific day of week. */ 'dayOfWeek': 'TUESDAY', // dayOfWeek. May NOT be null.
'openTime': 600, // Describes the number of minutes since midnight. Integer. Minimum 0. Maximum 1920.
'closeTime': 1200 // Describes the number of minutes since midnight. Integer. Minimum 0. Maximum 1920.
}, // A complex object. May be null.
'TUESDAY': {/* Describes work hours of specific day of week. */ 'dayOfWeek': 'TUESDAY', // dayOfWeek. May NOT be null.
'openTime': 600, // Describes the number of minutes since midnight. Integer. Minimum 0. Maximum 1920.
'closeTime': 1200 // Describes the number of minutes since midnight. Integer. Minimum 0. Maximum 1920.
}, // A complex object. May be null.
'WEDNESDAY': {/* Describes work hours of specific day of week. */ 'dayOfWeek': 'TUESDAY', // dayOfWeek. May NOT be null.
'openTime': 600, // Describes the number of minutes since midnight. Integer. Minimum 0. Maximum 1920.
'closeTime': 1200 // Describes the number of minutes since midnight. Integer. Minimum 0. Maximum 1920.
}, // A complex object. May be null.
'THURSDAY': {/* Describes work hours of specific day of week. */ 'dayOfWeek': 'TUESDAY', // dayOfWeek. May NOT be null.
'openTime': 600, // Describes the number of minutes since midnight. Integer. Minimum 0. Maximum 1920.
'closeTime': 1200 // Describes the number of minutes since midnight. Integer. Minimum 0. Maximum 1920.
}, // A complex object. May be null.
'FRIDAY': {/* Describes work hours of specific day of week. */ 'dayOfWeek': 'TUESDAY', // dayOfWeek. May NOT be null.
'openTime': 600, // Describes the number of minutes since midnight. Integer. Minimum 0. Maximum 1920.
'closeTime': 1200 // Describes the number of minutes since midnight. Integer. Minimum 0. Maximum 1920.
}, // A complex object. May be null.
'SATURDAY': {/* Describes work hours of specific day of week. */ 'dayOfWeek': 'TUESDAY', // dayOfWeek. May NOT be null.
'openTime': 600, // Describes the number of minutes since midnight. Integer. Minimum 0. Maximum 1920.
'closeTime': 1200 // Describes the number of minutes since midnight. Integer. Minimum 0. Maximum 1920.
}, // A complex object. May be null.
'SUNDAY': {/* Describes work hours of specific day of week. */ 'dayOfWeek': 'TUESDAY', // dayOfWeek. May NOT be null.
'openTime': 600, // Describes the number of minutes since midnight. Integer. Minimum 0. Maximum 1920.
'closeTime': 1200 // Describes the number of minutes since midnight. Integer. Minimum 0. Maximum 1920.
} // A complex object. May be null.
}, // A complex object. May NOT be null.
'address': 'Address 1', // String. Maximum 500 characters. May be null.
'phone': '89814532074', // String. Maximum 255 characters. May be null.
'custom': 'some text', // String. Maximum 65535 characters. May be null.
'currency': 'SEK', // currencyType. May be null.
'masterPassword': '9999' // String. Minimum 1 characters. Maximum 64 characters. May be null.
}

PUT /v26/sellers/{sellerId}

Send information about seller to the server to store it.
sellerId Identifier of seller sellerIdType. May NOT be null.

Request

PUT /v26/sellers/se9876543210 HTTP/1.1 Content-Type: application/json
Authorization: RestApiTester@se9876543210:9999
Host: t.srv4pos.com { 'corporateId': '9876543210', // corporateIdType. May NOT be null.
'name': 'CompanyName', // String. Maximum 96 characters. May be null.
'country': 'se', // countryType. May NOT be null.
'publicAccess': true, // Boolean. May NOT be null.
'description': 'description', // String. Maximum 1024 characters. May be null.
'city': 'Koenig', // String. Maximum 255 characters. May be null.
'workHours': '24', // String. Maximum 255 characters. May be null.
'workHoursWeek': { 'MONDAY': {/* Describes work hours of specific day of week. */ 'dayOfWeek': 'TUESDAY', // dayOfWeek. May NOT be null.
'openTime': 600, // Describes the number of minutes since midnight. Integer. Minimum 0. Maximum 1920.
'closeTime': 1200 // Describes the number of minutes since midnight. Integer. Minimum 0. Maximum 1920.
}, // A complex object. May be null.
'TUESDAY': {/* Describes work hours of specific day of week. */ 'dayOfWeek': 'TUESDAY', // dayOfWeek. May NOT be null.
'openTime': 600, // Describes the number of minutes since midnight. Integer. Minimum 0. Maximum 1920.
'closeTime': 1200 // Describes the number of minutes since midnight. Integer. Minimum 0. Maximum 1920.
}, // A complex object. May be null.
'WEDNESDAY': {/* Describes work hours of specific day of week. */ 'dayOfWeek': 'TUESDAY', // dayOfWeek. May NOT be null.
'openTime': 600, // Describes the number of minutes since midnight. Integer. Minimum 0. Maximum 1920.
'closeTime': 1200 // Describes the number of minutes since midnight. Integer. Minimum 0. Maximum 1920.
}, // A complex object. May be null.
'THURSDAY': {/* Describes work hours of specific day of week. */ 'dayOfWeek': 'TUESDAY', // dayOfWeek. May NOT be null.
'openTime': 600, // Describes the number of minutes since midnight. Integer. Minimum 0. Maximum 1920.
'closeTime': 1200 // Describes the number of minutes since midnight. Integer. Minimum 0. Maximum 1920.
}, // A complex object. May be null.
'FRIDAY': {/* Describes work hours of specific day of week. */ 'dayOfWeek': 'TUESDAY', // dayOfWeek. May NOT be null.
'openTime': 600, // Describes the number of minutes since midnight. Integer. Minimum 0. Maximum 1920.
'closeTime': 1200 // Describes the number of minutes since midnight. Integer. Minimum 0. Maximum 1920.
}, // A complex object. May be null.
'SATURDAY': {/* Describes work hours of specific day of week. */ 'dayOfWeek': 'TUESDAY', // dayOfWeek. May NOT be null.
'openTime': 600, // Describes the number of minutes since midnight. Integer. Minimum 0. Maximum 1920.
'closeTime': 1200 // Describes the number of minutes since midnight. Integer. Minimum 0. Maximum 1920.
}, // A complex object. May be null.
'SUNDAY': {/* Describes work hours of specific day of week. */ 'dayOfWeek': 'TUESDAY', // dayOfWeek. May NOT be null.
'openTime': 600, // Describes the number of minutes since midnight. Integer. Minimum 0. Maximum 1920.
'closeTime': 1200 // Describes the number of minutes since midnight. Integer. Minimum 0. Maximum 1920.
} // A complex object. May be null.
}, // A complex object. May NOT be null.
'address': 'Address 1', // String. Maximum 500 characters. May be null.
'phone': '89814532074', // String. Maximum 255 characters. May be null.
'custom': 'some text', // String. Maximum 65535 characters. May be null.
'currency': 'SEK', // currencyType. May be null.
'masterPassword': '9999' // String. Minimum 1 characters. Maximum 64 characters. May be null.
}

Response

HTTP/1.1 204 NO CONTENT

Errors

409 VersionConflictJsonException

Occurs when we upload data to the server but server contains more fresh data than we send. No additional details provided. You should set actual "If-Match" header.

DELETE /v26/sellers/{sellerId}

Remove seller and all information that concerns seller. Works only first 5 minutes since seller creation.
sellerId Identifier of seller sellerIdType. May NOT be null.

Request

DELETE /v26/sellers/se9876543210 HTTP/1.1
Authorization: RestApiTester@se9876543210:9999
Host: t.srv4pos.com

Response

HTTP/1.1 204 NO CONTENT

GET /v26/sellers

Returns list of entities.
orderByQuery param field to order by One of the following values: 'COUNTRY', 'NAME', 'DESCRIPTION', 'CITY', 'WORK_HOURS', 'PHONE'. May be null.
orderDescQuery param field to direction of ordering Boolean. May be null.
firstResultQuery param when pagination starts or null Integer. May be null.
maxResultsQuery param amount of items per page or null Integer. May be null.
likeQuery param search string filter or null String. May be null.

Request

GET /v26/sellers HTTP/1.1 Host: t.srv4pos.com

Response

HTTP/1.1 200 OK Content-Type: application/json;charset=UTF-8 /* returns list of public sellers. Returns if request has been done anonymously and full info otherwise */
[ { 'corporateId': '9876543210', // corporateIdType. May NOT be null.
'name': 'CompanyName', // String. Maximum 96 characters. May be null.
'country': 'se', // countryType. May NOT be null.
'publicAccess': true, // Boolean. May NOT be null.
'description': 'description', // String. Maximum 1024 characters. May be null.
'city': 'Koenig', // String. Maximum 255 characters. May be null.
'workHours': '24', // String. Maximum 255 characters. May be null.
'workHoursWeek': { 'MONDAY': {/* Describes work hours of specific day of week. */ 'dayOfWeek': 'TUESDAY', // dayOfWeek. May NOT be null.
'openTime': 600, // Describes the number of minutes since midnight. Integer. Minimum 0. Maximum 1920.
'closeTime': 1200 // Describes the number of minutes since midnight. Integer. Minimum 0. Maximum 1920.
}, // A complex object. May be null.
'TUESDAY': {/* Describes work hours of specific day of week. */ 'dayOfWeek': 'TUESDAY', // dayOfWeek. May NOT be null.
'openTime': 600, // Describes the number of minutes since midnight. Integer. Minimum 0. Maximum 1920.
'closeTime': 1200 // Describes the number of minutes since midnight. Integer. Minimum 0. Maximum 1920.
}, // A complex object. May be null.
'WEDNESDAY': {/* Describes work hours of specific day of week. */ 'dayOfWeek': 'TUESDAY', // dayOfWeek. May NOT be null.
'openTime': 600, // Describes the number of minutes since midnight. Integer. Minimum 0. Maximum 1920.
'closeTime': 1200 // Describes the number of minutes since midnight. Integer. Minimum 0. Maximum 1920.
}, // A complex object. May be null.
'THURSDAY': {/* Describes work hours of specific day of week. */ 'dayOfWeek': 'TUESDAY', // dayOfWeek. May NOT be null.
'openTime': 600, // Describes the number of minutes since midnight. Integer. Minimum 0. Maximum 1920.
'closeTime': 1200 // Describes the number of minutes since midnight. Integer. Minimum 0. Maximum 1920.
}, // A complex object. May be null.
'FRIDAY': {/* Describes work hours of specific day of week. */ 'dayOfWeek': 'TUESDAY', // dayOfWeek. May NOT be null.
'openTime': 600, // Describes the number of minutes since midnight. Integer. Minimum 0. Maximum 1920.
'closeTime': 1200 // Describes the number of minutes since midnight. Integer. Minimum 0. Maximum 1920.
}, // A complex object. May be null.
'SATURDAY': {/* Describes work hours of specific day of week. */ 'dayOfWeek': 'TUESDAY', // dayOfWeek. May NOT be null.
'openTime': 600, // Describes the number of minutes since midnight. Integer. Minimum 0. Maximum 1920.
'closeTime': 1200 // Describes the number of minutes since midnight. Integer. Minimum 0. Maximum 1920.
}, // A complex object. May be null.
'SUNDAY': {/* Describes work hours of specific day of week. */ 'dayOfWeek': 'TUESDAY', // dayOfWeek. May NOT be null.
'openTime': 600, // Describes the number of minutes since midnight. Integer. Minimum 0. Maximum 1920.
'closeTime': 1200 // Describes the number of minutes since midnight. Integer. Minimum 0. Maximum 1920.
} // A complex object. May be null.
}, // A complex object. May NOT be null.
'address': 'Address 1', // String. Maximum 500 characters. May be null.
'phone': '89814532074', // String. Maximum 255 characters. May be null.
'custom': 'some text', // String. Maximum 65535 characters. May be null.
'currency': 'SEK', // currencyType. May be null.
'masterPassword': '9999' // String. Minimum 1 characters. Maximum 64 characters. May be null.
} ]

GET /v26/{sellerId}/version

Returns latest version of this seller.
sellerId Identifier of seller sellerIdType. May NOT be null.

Request

GET /v26/se9876543210/version HTTP/1.1 Host: t.srv4pos.com

Response

HTTP/1.1 200 OK Content-Type: application/json;charset=UTF-8
{ 'version': 0, // Version number. Integer. Minimum 0. May NOT be null.
'modificationApiVersion': // Greatest version of api this seller was changed by. Integer. Minimum 0. May NOT be null.
}

GET /v26/{sellerId}/stats

Gets an information about availability of local control units, expiration of activation.
sellerId Identifier of seller sellerIdType. May NOT be null.

Request

GET /v26/se9876543210/stats HTTP/1.1
Authorization: RestApiTester@se9876543210:9999
Host: t.srv4pos.com

Response

HTTP/1.1 200 OK Content-Type: application/json;charset=UTF-8
{/* Information about availability of local control units and activation expiration. */ 'hasLocalControlUnits': true, // True if at least one used activation has local control unit. Boolean. May be null.
'expiredActivations': , // Amount of "latest installations" (Device.latest) with latest activation date less then TODAY. Integer. May be null.
'expireSoonActivations': , // Amount of "latest installations" (Device.latest) with latest activation date more TODAY and less TODAY + 1 MONTH. Integer. May be null.
'hasTables': false, // Always false. Boolean. May be null.
'hasAdditives': false, // Always false. Boolean. May be null.
'hasAdditiveClasses': false // Always false. Boolean. May be null.
}

GET /v26/{sellerId}/modifications

Gets an information about all seller entities.
sellerId Identifier of seller sellerIdType. May NOT be null.
fromQuery param Min boundary version (included) Boolean. May NOT be null.
toQuery param Max boundary version (included) Integer. May NOT be null.

Request

GET /v26/se9876543210/modifications HTTP/1.1
Authorization: RestApiTester@se9876543210:9999
Host: t.srv4pos.com

Response

HTTP/1.1 200 OK

Errors

400 RequestParameterMissingJsonException

If "from" or "to" parameters were missed.

Errors

410 OutdatedVersionJsonException

If requested api is outdated.

POST /v26/{sellerId}/images

Upload an image
sellerId Identifier of seller sellerIdType. May NOT be null.

Request

POST /v26/se9876543210/images HTTP/1.1 Host: t.srv4pos.com

Response

HTTP/1.1 201 CREATED

GET /v26/{sellerId}/images

Returns body of the picture.
sellerId Identifier of seller sellerIdType. May NOT be null.

Request

GET /v26/se9876543210/images HTTP/1.1 Host: t.srv4pos.com

Response

HTTP/1.1 200 OK Content-Type: application/json;charset=UTF-8 /* List of paths for images. */
[ {/* Represents path of picture. */ 'path': 'se9876543210/images/current/MAIN.PNG' // String. May NOT be null.
} ]

GET /v26/{sellerId}/images/current/{pictureFilename}

Returns body of the picture.
sellerId Identifier of seller sellerIdType. May NOT be null.
pictureFilename Just a normal windows filename identifierType. May NOT be null.

Request

GET /v26/se9876543210/images/current/MAIN.PNG HTTP/1.1 Host: t.srv4pos.com

Response

HTTP/1.1 200 OK

GET /v26/{sellerId}/images/{pictureVersion}/{pictureFilename}

Returns body of the picture for particular version number.
sellerId Identifier of seller sellerIdType. May NOT be null.
pictureVersion Version of picture imageVersionType. May NOT be null.
pictureFilename Just a normal windows filename identifierType. May NOT be null.

Request

GET /v26/se9876543210/images/10/MAIN.PNG HTTP/1.1 Host: t.srv4pos.com

Response

HTTP/1.1 200 OK

PUT /v26/{sellerId}/images/current/{pictureFilename}

Send picture to the server.
sellerId Identifier of seller sellerIdType. May NOT be null.
pictureFilename Just a normal windows filename identifierType. May NOT be null.

Request

PUT /v26/se9876543210/images/current/MAIN.PNG HTTP/1.1 Content-Type: image/png
Authorization: RestApiTester@se9876543210:9999
Host: t.srv4pos.com

Response

HTTP/1.1 204 NO CONTENT

Errors

404 ReferenceNotFoundJsonException

If seller wasn't found.

409 VersionConflictJsonException

Occurs when we upload data to the server but server contains more fresh data than we send. No additional details provided. You should set actual "If-Match" header.

DELETE /v26/{sellerId}/images/current/{pictureFilename}

Deletes specified picture.
sellerId Identifier of seller sellerIdType. May NOT be null.
pictureFilename Just a normal windows filename identifierType. May NOT be null.

Request

DELETE /v26/se9876543210/images/current/MAIN.PNG HTTP/1.1
Authorization: RestApiTester@se9876543210:9999
Host: t.srv4pos.com

Response

HTTP/1.1 204 NO CONTENT

GET /v26/{sellerId}/seller-images-diff/{versionFrom}/{versionTo}

Returns list of seller pictures changes between two versions.
sellerId Identifier of seller sellerIdType. May NOT be null.
versionFrom Min boundary version (included) for diff Integer. May NOT be null.
versionTo Max boundary version (included) for diff Integer. May NOT be null.

Request

GET /v26/se9876543210/seller-images-diff/0/9999 HTTP/1.1 Host: t.srv4pos.com

Response

HTTP/1.1 200 OK Content-Type: application/json;charset=UTF-8
{/* Information about product's picture. */ 'deleted': 'false', // True if entity was deleted. Only possible if return diff. May NOT be null.
'filename': 'MAIN.PNG', // Filename of picture. String. Minimum 1 characters. Maximum 50 characters. Regular expression ^(?!^(PRN|AUX|CLOCK\$|NUL|CON|COM\d|LPT\d|\.\.?)$)[^\x00-\x1f\\?*:\";|/<>]+$ . May NOT be null.
'version': 12345, // Version of picture (to be able to get old version). Integer. May NOT be null.
'entityIdentifier': '12345', // This field unique identifies product. identifierType. May NOT be null.
'modified': 78953145421 // Last modified date. Date: amount of milliseconds since UNIX epoch. May NOT be null.
}

POST /v26/{sellerId}/taxes

Creates tax on the server.
sellerId Identifier of seller sellerIdType. May NOT be null.

Request

POST /v26/se9876543210/taxes HTTP/1.1 Content-Type: application/json
Authorization: RestApiTester@se9876543210:9999
Host: t.srv4pos.com { 'deleted': 'false', // true if entity was deleted. May NOT be null.
'identifier': 'TAX1', // This field uniquely identifies entity. There is no decision what is it, only the requirement - it must be unique trough one seller. identifierType. May be null.
'vat': 1, // Regular field. Integer. Minimum 0. Maximum 100. May NOT be null.
'name': 'Tax 1', // Regular field. String. Minimum 1 characters. Maximum 32 characters. May NOT be null.
'custom': '' // Custom data concerned tax. String. Maximum 65535 characters. May be null.
}

Response

HTTP/1.1 201 CREATED Content-Type: application/json;charset=UTF-8
{/* Generated unique identifier. */ 'identifier': '0-ID' // identifierType. May NOT be null.
}

Errors

409 VersionConflictJsonException

Occurs when we upload data to the server but server contains more fresh data than we send. No additional details provided. You should set actual "If-Match" header.

PUT /v26/{sellerId}/taxes/{identifier}

Put tax to the server.
sellerId Identifier of seller sellerIdType. May NOT be null.
identifier identifies entity identifierType. May NOT be null.

Request

PUT /v26/se9876543210/taxes/TAX1 HTTP/1.1 Content-Type: application/json
Authorization: RestApiTester@se9876543210:9999
Host: t.srv4pos.com { 'deleted': 'false', // true if entity was deleted. May NOT be null.
'identifier': 'TAX1', // This field uniquely identifies entity. There is no decision what is it, only the requirement - it must be unique trough one seller. identifierType. May be null.
'vat': 1, // Regular field. Integer. Minimum 0. Maximum 100. May NOT be null.
'name': 'Tax 1', // Regular field. String. Minimum 1 characters. Maximum 32 characters. May NOT be null.
'custom': '' // Custom data concerned tax. String. Maximum 65535 characters. May be null.
}

Response

HTTP/1.1 201 CREATED or HTTP/1.1 204 NO CONTENT

Errors

409 VersionConflictJsonException

Occurs when we upload data to the server but server contains more fresh data than we send. No additional details provided. You should set actual "If-Match" header.

GET /v26/{sellerId}/taxes/{identifier}

Returns an entity. Don't need an authorization.
sellerId Identifier of seller sellerIdType. May NOT be null.
identifier identifies entity identifierType. May NOT be null.

Request

GET /v26/se9876543210/taxes/TAX1 HTTP/1.1 Host: t.srv4pos.com

Response

HTTP/1.1 200 OK Content-Type: application/json;charset=UTF-8 /* Null if not modified since version or entity. If version is null then return value can not be null. */
{ 'deleted': 'false', // true if entity was deleted. May NOT be null.
'identifier': 'TAX1', // This field uniquely identifies entity. There is no decision what is it, only the requirement - it must be unique trough one seller. identifierType. May be null.
'vat': 1, // Regular field. Integer. Minimum 0. Maximum 100. May NOT be null.
'name': 'Tax 1', // Regular field. String. Minimum 1 characters. Maximum 32 characters. May NOT be null.
'custom': '' // Custom data concerned tax. String. Maximum 65535 characters. May be null.
}

Errors

409 VersionConflictJsonException

Occurs when we upload data to the server but server contains more fresh data than we send. No additional details provided. You should set actual "If-Match" header.

404 NotFoundJsonException

If entity is not found.

403 ForbiddenJsonException

See there: INSUFFICIENT_ACCESS_RIGHTS .

DELETE /v26/{sellerId}/taxes/{identifier}

Delete tax from the server.
sellerId Identifier of seller sellerIdType. May NOT be null.
identifier identifies entity identifierType. May NOT be null.

Request

DELETE /v26/se9876543210/taxes/TAX1 HTTP/1.1
Authorization: RestApiTester@se9876543210:9999
Host: t.srv4pos.com

Response

HTTP/1.1 204 NO CONTENT

Errors

409 VersionConflictJsonException

Occurs when we upload data to the server but server contains more fresh data than we send. No additional details provided. You should set actual "If-Match" header.

GET /v26/{sellerId}/taxes-diff/{versionFrom}/{versionTo}

Returns list of item changes between two versions.
sellerId Identifier of seller sellerIdType. May NOT be null.
versionFrom Min boundary version (included) for diff Integer. May NOT be null.
versionTo Max boundary version (included) for diff Integer. May NOT be null.

Request

GET /v26/se9876543210/taxes-diff/0/9999 HTTP/1.1 Host: t.srv4pos.com

Response

HTTP/1.1 200 OK Content-Type: application/json;charset=UTF-8
{ 'deleted': 'false', // true if entity was deleted. May NOT be null.
'identifier': 'TAX1', // This field uniquely identifies entity. There is no decision what is it, only the requirement - it must be unique trough one seller. identifierType. May be null.
'vat': 1, // Regular field. Integer. Minimum 0. Maximum 100. May NOT be null.
'name': 'Tax 1', // Regular field. String. Minimum 1 characters. Maximum 32 characters. May NOT be null.
'custom': '' // Custom data concerned tax. String. Maximum 65535 characters. May be null.
}

GET /v26/{sellerId}/taxes

Returns list of entities.
sellerId Identifier of seller sellerIdType. May NOT be null.
orderByQuery param field to order by One of the following values: 'IDENTIFIER', 'NAME', 'VAT'. May be null.
orderDescQuery param field to direction of ordering Boolean. May be null.
firstResultQuery param when pagination starts or null Integer. May be null.
maxResultsQuery param amount of items per page or null Integer. May be null.
likeQuery param search string filter or null String. May be null.

Request

GET /v26/se9876543210/taxes HTTP/1.1 Host: t.srv4pos.com

Response

HTTP/1.1 200 OK Content-Type: application/json;charset=UTF-8
{ 'deleted': 'false', // true if entity was deleted. May NOT be null.
'identifier': 'TAX1', // This field uniquely identifies entity. There is no decision what is it, only the requirement - it must be unique trough one seller. identifierType. May be null.
'vat': 1, // Regular field. Integer. Minimum 0. Maximum 100. May NOT be null.
'name': 'Tax 1', // Regular field. String. Minimum 1 characters. Maximum 32 characters. May NOT be null.
'custom': '' // Custom data concerned tax. String. Maximum 65535 characters. May be null.
}

GET /v26/{sellerId}/taxes/stats

Returns stats by vat.
sellerId Identifier of seller sellerIdType. May NOT be null.
periodQuery param filter by date period Integer. May be null.
cashRegisterNameQuery param filter by cash register name String. May be null.

Request

GET /v26/se9876543210/taxes/stats HTTP/1.1
Authorization: RestApiTester@se9876543210:9999
Host: t.srv4pos.com

Response

HTTP/1.1 200 OK Content-Type: application/json;charset=UTF-8
{/* Represents taxes stats. */ 'totalSum': 1200, // Total sum by vat. Integer. Minimum 0.
'taxStats': [ {/* Sales stats by taxes. */ 'vatRate': 25, // Vat rate. Integer. Minimum 0.
'vatSum': 2500 // Sum by vat for sold products. Integer. Minimum 0.
} ] // List of objects. May NOT be null.
}

Errors

400 TypeMismatchJsonException

If passed date period has incorrect format.

404 ReferenceNotFoundJsonException

If passed cash register name don't belong to seller.

POST /v26/{sellerId}/categories

Create category on the server.
sellerId Identifier of seller sellerIdType. May NOT be null.

Request

POST /v26/se9876543210/categories HTTP/1.1 Content-Type: application/json
Authorization: RestApiTester@se9876543210:9999
Host: t.srv4pos.com {/* Data to put. */ 'deleted': 'false', // True if entity was deleted. Only possible if return diff. May NOT be null.
'identifier': null, // identifierType. May be null.
'name': 'Test', // Regular field. String. Minimum 1 characters. Maximum 32 characters. May NOT be null.
'color': 0 // Regular field. Integer. May be null.
}

Response

HTTP/1.1 201 CREATED Content-Type: application/json;charset=UTF-8 /* Generated unique identifier. */
{/* Methods called "new" will return the identifier of newly created entity by using this class */ 'identifier': '0-ID' // identifierType. May NOT be null.
}

Errors

409 VersionConflictJsonException

Occurs when we upload data to the server but server contains more fresh data than we send. No additional details provided. You should set actual "If-Match" header.

PUT /v26/{sellerId}/categories/{identifier}

Put category to the server.
sellerId Identifier of seller sellerIdType. May NOT be null.
identifier Category identifier identifierType. May NOT be null.

Request

PUT /v26/se9876543210/categories/0-2U10 HTTP/1.1 Content-Type: application/json
Authorization: RestApiTester@se9876543210:9999
Host: t.srv4pos.com {/* Data to put. */ 'deleted': 'false', // True if entity was deleted. Only possible if return diff. May NOT be null.
'identifier': '0-2U10', // identifierType. May be null.
'name': 'Test1', // Regular field. String. Minimum 1 characters. Maximum 32 characters. May NOT be null.
'color': 0 // Regular field. Integer. May be null.
}

Response

HTTP/1.1 201 CREATED or HTTP/1.1 204 NO CONTENT Content-Type: application/json;charset=UTF-8
{/* Methods called "new" will return the identifier of newly created entity by using this class */ 'identifier': '0-ID' // identifierType. May NOT be null.
}

Errors

409 VersionConflictJsonException

Occurs when we upload data to the server but server contains more fresh data than we send. No additional details provided. You should set actual "If-Match" header.

GET /v26/{sellerId}/categories/{identifier}

Returns an entity.
sellerId Identifier of seller sellerIdType. May NOT be null.
identifier Category identifier identifierType. May NOT be null.

Request

GET /v26/se9876543210/categories/0-2U10 HTTP/1.1 Host: t.srv4pos.com

Response

HTTP/1.1 200 OK Content-Type: application/json;charset=UTF-8 /* Null if not modified since version or entity. If version is null then return value can not be null. */
{ 'deleted': 'false', // True if entity was deleted. Only possible if return diff. May NOT be null.
'identifier': '0-2U10', // identifierType. May be null.
'name': 'Test1', // Regular field. String. Minimum 1 characters. Maximum 32 characters. May NOT be null.
'color': 0 // Regular field. Integer. May be null.
}

Errors

409 VersionConflictJsonException

Occurs when we upload data to the server but server contains more fresh data than we send. No additional details provided. You should set actual "If-Match" header.

404 NotFoundJsonException

If entity is not found.

DELETE /v26/{sellerId}/categories/{identifier}

Delete category from the server.
sellerId Identifier of seller sellerIdType. May NOT be null.
identifier Category identifier identifierType. May NOT be null.

Request

DELETE /v26/se9876543210/categories/0-2U10 HTTP/1.1
Authorization: RestApiTester@se9876543210:9999
Host: t.srv4pos.com

Response

HTTP/1.1 204 NO CONTENT

Errors

409 VersionConflictJsonException

Occurs when we upload data to the server but server contains more fresh data than we send. No additional details provided. You should set actual "If-Match" header.

GET /v26/{sellerId}/categories-diff/{versionFrom}/{versionTo}

Returns list of item changes between two versions.
sellerId Identifier of seller sellerIdType. May NOT be null.
versionFrom Min boundary version (included) for diff Integer. May NOT be null.
versionTo Max boundary version (included) for diff Integer. May NOT be null.

Request

GET /v26/se9876543210/categories-diff/2211/9999 HTTP/1.1 Host: t.srv4pos.com

Response

HTTP/1.1 200 OK Content-Type: application/json;charset=UTF-8
{ 'deleted': 'false', // True if entity was deleted. Only possible if return diff. May NOT be null.
'identifier': 'se9876543210', // identifierType. May be null.
'name': 'Category name', // Regular field. String. Minimum 1 characters. Maximum 32 characters. May NOT be null.
'color': 0 // Regular field. Integer. May be null.
}

GET /v26/{sellerId}/categories

Returns list of entities.
sellerId Identifier of seller sellerIdType. May NOT be null.
orderByQuery param field to order by One of the following values: 'IDENTIFIER', 'NAME', 'VAT'. May be null.
orderDescQuery param field to direction of ordering Boolean. May be null.
firstResultQuery param when pagination starts or null Integer. May be null.
maxResultsQuery param amount of items per page or null Integer. May be null.
likeQuery param search string filter or null String. May be null.

Request

GET /v26/se9876543210/categories HTTP/1.1 Host: t.srv4pos.com

Response

HTTP/1.1 200 OK Content-Type: application/json;charset=UTF-8
{ 'deleted': 'false', // True if entity was deleted. Only possible if return diff. May NOT be null.
'identifier': 'se9876543210', // identifierType. May be null.
'name': 'Category name', // Regular field. String. Minimum 1 characters. Maximum 32 characters. May NOT be null.
'color': 0 // Regular field. Integer. May be null.
}

GET /v26/{sellerId}/categories/stats

Returns stats by categories.
sellerId Identifier of seller sellerIdType. May NOT be null.
periodQuery param filter by date period Integer. May be null.
cashRegisterNameQuery param filter by cash register name String. May be null.

Request

GET /v26/se9876543210/categories/stats HTTP/1.1
Authorization: RestApiTester@se9876543210:9999
Host: t.srv4pos.com

Response

HTTP/1.1 200 OK Content-Type: application/json;charset=UTF-8
{/* Represents categories stats by total brutto, amount of sold products for all categories and list of categories stats in particular. */ 'totalBrutto': 1200, // Total stats by categories brutto. Integer. Minimum 0.
'totalProductsSold': 100, // Total amount of sold products for all categories. Integer. Minimum 0.
'categoryStats': [ {/* Stats by particular categories brutto sum and amount of sold products. Contains identifier and name of category. */ 'identifier': 'UF-2', // identifierType. May NOT be null.
'name': 'Latte', // String. Minimum 1 characters. Maximum 32 characters. May NOT be null.
'brutto': 200, // Sum by brutto for sold products by current category. Integer. Minimum 0.
'count': 50, // Amount of sold product units by current category. Integer. Minimum 0.
'vatSum': 100 // Sum by vat for sold products. Integer. Minimum 0.
} ] // List of objects. May NOT be null.
}

Errors

400 TypeMismatchJsonException

If passed date period has incorrect format.

404 ReferenceNotFoundJsonException

If passed cash register name don't belong to seller.

POST /v26/{sellerId}/categories/{categoryIdentifier}/images

Upload an image
sellerId Identifier of seller sellerIdType. May NOT be null.
categoryIdentifier Category identifier identifierType. May NOT be null.

Request

POST /v26/se9876543210/categories/0-2U10/images HTTP/1.1 Host: t.srv4pos.com

Response

HTTP/1.1 201 CREATED

GET /v26/{sellerId}/categories/{categoryIdentifier}/images

Returns picture paths.
sellerId Identifier of seller sellerIdType. May NOT be null.
categoryIdentifier Category identifier identifierType. May NOT be null.

Request

GET /v26/se9876543210/categories/0-2U10/images HTTP/1.1 Host: t.srv4pos.com

Response

HTTP/1.1 200 OK Content-Type: application/json;charset=UTF-8 /* List of paths for images. */
[ {/* Represents path of picture. */ 'path': 'se9876543210/categories/0-2U10/images/current/MAIN.PNG' // String. May NOT be null.
} ]

GET /v26/{sellerId}/categories/{categoryIdentifier}/images/current/{pictureFilename}

Returns body of the picture.
sellerId Identifier of seller sellerIdType. May NOT be null.
categoryIdentifier Category identifier identifierType. May NOT be null.
pictureFilename Just a normal windows filename identifierType. May NOT be null.

Request

GET /v26/se9876543210/categories/0-2U10/images/current/MAIN.PNG HTTP/1.1 Host: t.srv4pos.com

Response

HTTP/1.1 200 OK

GET /v26/{sellerId}/categories/{categoryIdentifier}/images/{pictureVersion}/{pictureFilename}

Returns body of the picture for particular version number.
sellerId Identifier of seller sellerIdType. May NOT be null.
categoryIdentifier Category identifier identifierType. May NOT be null.
pictureVersion Version of picture imageVersionType. May NOT be null.
pictureFilename Just a normal windows filename identifierType. May NOT be null.

Request

GET /v26/se9876543210/categories/0-2U10/images/12345/MAIN.PNG HTTP/1.1 Host: t.srv4pos.com

Response

HTTP/1.1 200 OK

PUT /v26/{sellerId}/categories/{categoryIdentifier}/images/current/{pictureFilename}

Send picture to the server.
sellerId Identifier of seller sellerIdType. May NOT be null.
categoryIdentifier Category identifier identifierType. May NOT be null.
pictureFilename Just a normal windows filename identifierType. May NOT be null.

Request

PUT /v26/se9876543210/categories/0-2U10/images/current/MAIN.PNG HTTP/1.1 Content-Type: application/json Host: t.srv4pos.com

Response

HTTP/1.1 204 NO CONTENT

Errors

404 ReferenceNotFoundJsonException

If seller wasn't found.

409 VersionConflictJsonException

Occurs when we upload data to the server but server contains more fresh data than we send. No additional details provided. You should set actual "If-Match" header.

DELETE /v26/{sellerId}/categories/{categoryIdentifier}/images/current/{pictureFilename}

Deletes specified picture.
sellerId Identifier of seller sellerIdType. May NOT be null.
categoryIdentifier Category identifier identifierType. May NOT be null.
pictureFilename Just a normal windows filename identifierType. May NOT be null.

Request

DELETE /v26/se9876543210/categories/0-2U10/images/current/MAIN.PNG HTTP/1.1
Authorization: RestApiTester@se9876543210:9999
Host: t.srv4pos.com

Response

HTTP/1.1 204 NO CONTENT

GET /v26/{sellerId}/category-images-diff/{versionFrom}/{versionTo}

Returns list of seller pictures changes between two versions.
sellerId Identifier of seller sellerIdType. May NOT be null.
versionFrom Min boundary version (included) for diff imageVersionType. May NOT be null.
versionTo Max boundary version (included) for diff imageVersionType. May NOT be null.

Request

GET /v26/se9876543210/category-images-diff/0/99999 HTTP/1.1 Host: t.srv4pos.com

Response

HTTP/1.1 200 OK Content-Type: application/json;charset=UTF-8
{/* Information about product's picture. */ 'deleted': 'false', // True if entity was deleted. Only possible if return diff. May NOT be null.
'filename': 'test', // Filename of picture. String. Minimum 1 characters. Maximum 50 characters. Regular expression ^(?!^(PRN|AUX|CLOCK\$|NUL|CON|COM\d|LPT\d|\.\.?)$)[^\x00-\x1f\\?*:\";|/<>]+$ . May NOT be null.
'version': 12345, // Version of picture (to be able to get old version). Integer. May NOT be null.
'entityIdentifier': '12345', // This field unique identifies product. identifierType. May NOT be null.
'modified': 78953145421 // Last modified date. Date: amount of milliseconds since UNIX epoch. May NOT be null.
}

POST /v26/{sellerId}/products

Create product on the server.
sellerId Identifier of seller sellerIdType. May NOT be null.

Request

POST /v26/se9876543210/products HTTP/1.1 Content-Type: application/json
Authorization: RestApiTester@se9876543210:9999
Host: t.srv4pos.com { 'deleted': 'false', // True if entity was deleted. Only possible if return diff. May NOT be null.
'identifier': '0-2U12', // identifierType. May NOT be null.
'name': 'Product 1', // Regular field. String. Minimum 1 characters. Maximum 32 characters. May NOT be null.
'barcode': '012345678912', // Regular field. String. Minimum 1 characters. Maximum 32 characters. May NOT be null.
'netto': 100, // Regular field. Integer. May NOT be null.
'tax': 'TAX1', // Regular field. identifierType. May NOT be null.
'salesUnit': 'Piece', // Regular field. salesUnitType. May NOT be null.
'countedInPrice': 'false', // Regular field. May NOT be null.
'description': '', // String. Maximum 1024 characters. May be null.
'custom': '' // String. Maximum 65535 characters. May be null.
}

Response

HTTP/1.1 201 CREATED Content-Type: application/json;charset=UTF-8
{/* Methods called "new" will return the identifier of newly created entity by using this class */ 'identifier': '0-ID' // identifierType. May NOT be null.
}

Errors

409 VersionConflictJsonException

Occurs when we upload data to the server but server contains more fresh data than we send. No additional details provided. You should set actual "If-Match" header.

404 ReferenceNotFoundJsonException

If tax is not found.

400 ValueNotValidJsonException

See there: SIZE_SHOULD_BE_IN_RANGE, SHOULD_MATCH_PATTERN .

PUT /v26/{sellerId}/products/{identifier}

Put product to the server.
sellerId Identifier of seller sellerIdType. May NOT be null.
identifier Product identifier identifierType. May NOT be null.

Request

PUT /v26/se9876543210/products/0-2U12 HTTP/1.1 Content-Type: application/json
Authorization: RestApiTester@se9876543210:9999
Host: t.srv4pos.com {/* Data to put. */ 'deleted': 'false', // True if entity was deleted. Only possible if return diff. May NOT be null.
'identifier': '0-2U12', // identifierType. May NOT be null.
'name': 'Product 1', // Regular field. String. Minimum 1 characters. Maximum 32 characters. May NOT be null.
'barcode': '012345678912', // Regular field. String. Minimum 1 characters. Maximum 32 characters. May NOT be null.
'netto': 100, // Regular field. Integer. May NOT be null.
'tax': 'TAX1', // Regular field. identifierType. May NOT be null.
'salesUnit': 'Piece', // Regular field. salesUnitType. May NOT be null.
'countedInPrice': 'false', // Regular field. May NOT be null.
'description': '', // String. Maximum 1024 characters. May be null.
'custom': '' // String. Maximum 65535 characters. May be null.
}

Response

HTTP/1.1 201 CREATED or HTTP/1.1 204 NO CONTENT

Errors

409 VersionConflictJsonException

Occurs when we upload data to the server but server contains more fresh data than we send. No additional details provided. You should set actual "If-Match" header.

404 ReferenceNotFoundJsonException

If tax wasn't found.

GET /v26/{sellerId}/products/{identifier}

Returns an entity.
sellerId Identifier of seller sellerIdType. May NOT be null.
identifier Product identifier identifierType. May NOT be null.

Request

GET /v26/se9876543210/products/0-2U12 HTTP/1.1 Host: t.srv4pos.com

Response

HTTP/1.1 200 OK Content-Type: application/json;charset=UTF-8
{ 'deleted': 'false', // True if entity was deleted. Only possible if return diff. May NOT be null.
'identifier': '0-2U12', // identifierType. May NOT be null.
'name': 'Product 1', // Regular field. String. Minimum 1 characters. Maximum 32 characters. May NOT be null.
'barcode': '012345678912', // Regular field. String. Minimum 1 characters. Maximum 32 characters. May NOT be null.
'netto': 100, // Regular field. Integer. May NOT be null.
'tax': 'TAX1', // Regular field. identifierType. May NOT be null.
'salesUnit': 'Piece', // Regular field. salesUnitType. May NOT be null.
'countedInPrice': 'false', // Regular field. May NOT be null.
'description': '', // String. Maximum 1024 characters. May be null.
'custom': '' // String. Maximum 65535 characters. May be null.
}

Errors

409 VersionConflictJsonException

Occurs when we upload data to the server but server contains more fresh data than we send. No additional details provided. You should set actual "If-Match" header.

404 NotFoundJsonException

If entity is not found.

GET /v26/{sellerId}/products-diff/{versionFrom}/{versionTo}

Returns list of item changes between two versions.
sellerId Identifier of seller sellerIdType. May NOT be null.
versionFrom Min boundary version (included) for diff Integer. May NOT be null.
versionTo Max boundary version (included) for diff Integer. May NOT be null.

Request

GET /v26/se9876543210/products-diff/2211/9999 HTTP/1.1 Host: t.srv4pos.com

Response

HTTP/1.1 200 OK Content-Type: application/json;charset=UTF-8
{ 'deleted': 'false', // True if entity was deleted. Only possible if return diff. May NOT be null.
'identifier': '0-2U12', // identifierType. May NOT be null.
'name': 'Product 1', // Regular field. String. Minimum 1 characters. Maximum 32 characters. May NOT be null.
'barcode': '012345678912', // Regular field. String. Minimum 1 characters. Maximum 32 characters. May NOT be null.
'netto': 100, // Regular field. Integer. May NOT be null.
'tax': 'TAX1', // Regular field. identifierType. May NOT be null.
'salesUnit': 'Piece', // Regular field. salesUnitType. May NOT be null.
'countedInPrice': 'false', // Regular field. May NOT be null.
'description': '', // String. Maximum 1024 characters. May be null.
'custom': '' // String. Maximum 65535 characters. May be null.
}

GET /v26/{sellerId}/products

Returns list of entities.
sellerId Identifier of seller sellerIdType. May NOT be null.
orderByQuery param field to order by One of the following values: 'IDENTIFIER', 'NAME', 'BARCODE', 'NETTO', 'TAX_NAME', 'SALES_UNIT', 'COUNTED_IN_PRICE', 'PRICE', 'DESCRIPTION'. May be null.
orderDescQuery param field to direction of ordering Boolean. May be null.
firstResultQuery param when pagination starts or null Integer. May be null.
maxResultsQuery param amount of items per page or null Integer. May be null.
likeQuery param search string filter or null String. May be null.

Request

GET /v26/se9876543210/products HTTP/1.1 Host: t.srv4pos.com

Response

HTTP/1.1 200 OK Content-Type: application/json;charset=UTF-8 /* List of entities which exists on current seller or null if list of entities is not modified since version. */
[ { 'deleted': 'false', // True if entity was deleted. Only possible if return diff. May NOT be null.
'identifier': '0-2U12', // identifierType. May NOT be null.
'name': 'Product 1', // Regular field. String. Minimum 1 characters. Maximum 32 characters. May NOT be null.
'barcode': '012345678912', // Regular field. String. Minimum 1 characters. Maximum 32 characters. May NOT be null.
'netto': 100, // Regular field. Integer. May NOT be null.
'tax': 'TAX1', // Regular field. identifierType. May NOT be null.
'salesUnit': 'Piece', // Regular field. salesUnitType. May NOT be null.
'countedInPrice': 'false', // Regular field. May NOT be null.
'description': '', // String. Maximum 1024 characters. May be null.
'custom': '' // String. Maximum 65535 characters. May be null.
} ]

DELETE /v26/{sellerId}/products/{identifier}

Delete entity from the server.
sellerId Identifier of seller sellerIdType. May NOT be null.
identifier Product identifier identifierType. May NOT be null.

Request

DELETE /v26/se9876543210/products/0-2U12 HTTP/1.1
Authorization: RestApiTester@se9876543210:9999
Host: t.srv4pos.com

Response

HTTP/1.1 204 NO CONTENT

Errors

409 VersionConflictJsonException

Occurs when we upload data to the server but server contains more fresh data than we send. No additional details provided. You should set actual "If-Match" header.

GET /v26/{sellerId}/products/stats

Returns stats by products.
sellerId Identifier of seller sellerIdType. May NOT be null.
periodQuery param filter by date period Integer. May be null.
cashRegisterNameQuery param filter by cash register name String. May be null.

Request

GET /v26/se9876543210/products/stats HTTP/1.1
Authorization: RestApiTester@se9876543210:9999
Host: t.srv4pos.com

Response

HTTP/1.1 200 OK Content-Type: application/json;charset=UTF-8
{/* Represents products stats by total brutto, amount of sold products and list of product stats in particular. */ 'totalBrutto': 1200, // Total stats by products brutto. Integer. Minimum 0.
'totalProductsSold': 100, // Total amount of sold products. Integer. Minimum 0.
'productStats': [ {/* Stats by particular product by brutto and amount of sold units. Contains identifier, name and sales unit type. */ 'identifier': 'UF-2', // identifierType. May NOT be null.
'name': 'Latte', // String. Minimum 1 characters. Maximum 32 characters. May NOT be null.
'brutto': 200, // Sum by brutto for sold products. Integer. Minimum 0.
'count': 50, // Amount of sold product units. Integer. Minimum 0.
'salesUnit': 'Piece', // Sales unit type (i.e. kilogram or piece). salesUnitType.
'vatSum': 1000 // Sum by vat for sold products. Integer. Minimum 0.
} ] // List of objects. May NOT be null.
}

Errors

400 TypeMismatchJsonException

If passed date period has incorrect format.

404 ReferenceNotFoundJsonException

If passed cash register name don't belong to seller.

PUT /v26/{sellerId}/products/{productIdentifier}/images/current/{pictureFilename}

Send picture to the server.
sellerId Identifier of seller sellerIdType. May NOT be null.
productIdentifier Product identifier identifierType. May NOT be null.
pictureFilename Just a normal windows filename identifierType. May NOT be null.

Request

PUT /v26/se9876543210/products/0-2U12/images/current/MAIN.PNG HTTP/1.1 Content-Type: image/png
Authorization: RestApiTester@se9876543210:9999
Host: t.srv4pos.com

Response

HTTP/1.1 204 NO CONTENT

Errors

409 VersionConflictJsonException

Occurs when we upload data to the server but server contains more fresh data than we send. No additional details provided. You should set actual "If-Match" header.

404 ReferenceNotFoundJsonException

If product wasn't found.

GET /v26/{sellerId}/products/{productIdentifier}/images

Returns picture paths.
sellerId Identifier of seller sellerIdType. May NOT be null.
productIdentifier Product identifier identifierType. May NOT be null.

Request

GET /v26/se9876543210/products/0-2U12/images HTTP/1.1 Host: t.srv4pos.com

Response

HTTP/1.1 200 OK Content-Type: application/json;charset=UTF-8 /* List of paths for images. */
[ {/* Represents path of picture. */ 'path': 'se9876543210/products/0-2U12/images/current/MAIN.PNG' // String. May NOT be null.
} ]

GET /v26/{sellerId}/products/{productIdentifier}/images/current/{pictureFilename}

Returns body of the picture.
sellerId Identifier of seller sellerIdType. May NOT be null.
productIdentifier Product identifier identifierType. May NOT be null.
pictureFilename Just a normal windows filename identifierType. May NOT be null.

Request

GET /v26/se9876543210/products/0-2U12/images/current/MAIN.PNG HTTP/1.1 Host: t.srv4pos.com

Response

HTTP/1.1 200 OK

Errors

409 VersionConflictJsonException

Occurs when we upload data to the server but server contains more fresh data than we send. No additional details provided. You should set actual "If-Match" header.

404 ReferenceNotFoundJsonException

If product wasn't found.

GET /v26/{sellerId}/products/{productIdentifier}/images/{pictureVersion}/{pictureFilename}

Returns body of the picture for particular version number.
sellerId Identifier of seller sellerIdType. May NOT be null.
productIdentifier Product identifier identifierType. May NOT be null.
pictureVersion Version of picture imageVersionType. May NOT be null.
pictureFilename Just a normal windows filename identifierType. May NOT be null.

Request

GET /v26/se9876543210/products/0-2U12/images/20/MAIN.PNG HTTP/1.1 Host: t.srv4pos.com

Response

HTTP/1.1 200 OK

Errors

404 NotFoundJsonException

If image is not found.

404 ReferenceNotFoundJsonException

If product wasn't found.

DELETE /v26/{sellerId}/products/{productIdentifier}/images/current/{pictureFilename}

Deletes specified picture.
sellerId Identifier of seller sellerIdType. May NOT be null.
productIdentifier Product identifier identifierType. May NOT be null.
pictureFilename Just a normal windows filename identifierType. May NOT be null.

Request

DELETE /v26/se9876543210/products/0-2U12/images/current/MAIN.PNG HTTP/1.1
Authorization: RestApiTester@se9876543210:9999
Host: t.srv4pos.com

Response

HTTP/1.1 204 NO CONTENT

Errors

409 VersionConflictJsonException

Occurs when we upload data to the server but server contains more fresh data than we send. No additional details provided. You should set actual "If-Match" header.

404 ReferenceNotFoundJsonException

If product wasn't found.

GET /v26/{sellerId}/product-images-diff/{versionFrom}/{versionTo}

Returns list of product pictures changes between two versions.
sellerId Identifier of seller sellerIdType. May NOT be null.
versionFrom Min boundary version (included) for diff Integer. May NOT be null.
versionTo Max boundary version (included) for diff Integer. May NOT be null.

Request

GET /v26/se9876543210/product-images-diff/0/9999 HTTP/1.1 Host: t.srv4pos.com

Response

HTTP/1.1 200 OK Content-Type: application/json;charset=UTF-8
{/* Information about product's picture. */ 'deleted': 'false', // True if entity was deleted. Only possible if return diff. May NOT be null.
'filename': 'MAIN.PNG', // Filename of picture. String. Minimum 1 characters. Maximum 50 characters. Regular expression ^(?!^(PRN|AUX|CLOCK\$|NUL|CON|COM\d|LPT\d|\.\.?)$)[^\x00-\x1f\\?*:\";|/<>]+$ . May NOT be null.
'version': 1, // Version of picture (to be able to get old version). Integer. May NOT be null.
'entityIdentifier': '12345', // This field unique identifies product. identifierType. May NOT be null.
'modified': 78953145421 // Last modified date. Date: amount of milliseconds since UNIX epoch. May NOT be null.
}

POST /v26/{sellerId}/commodities

Create commodity on the server.
sellerId Identifier of seller sellerIdType. May NOT be null.

Request

POST /v26/se9876543210/commodities HTTP/1.1 Content-Type: application/json
Authorization: RestApiTester@se9876543210:9999
Host: t.srv4pos.com {/* Data to put. */ 'deleted': false, // True if entity was deleted. Only possible if return diff. Boolean. May NOT be null.
'identifier': null, // This field uniquely identifies entity. There is no decision what is it, only the requirement - it must be unique trough one seller. identifierType. May NOT be null.
'product': '0-2U12', // Regular field. Product identifier. String. May NOT be null.
'category': '0-2U10', // Regular field. Tax identifier. String. May NOT be null.
'custom': '', // String. Maximum 65535 characters. May be null.
'color': 0 // Regular field. Integer. May be null.
}

Response

HTTP/1.1 201 CREATED Content-Type: application/json;charset=UTF-8
{/* Methods called "new" will return the identifier of newly created entity by using this class */ 'identifier': '0-ID' // identifierType. May NOT be null.
}

Errors

409 VersionConflictJsonException

Occurs when we upload data to the server but server contains more fresh data than we send. No additional details provided. You should set actual "If-Match" header.

404 ReferenceNotFoundJsonException

If product wasn't found.

PUT /v26/{sellerId}/commodities/{identifier}

Put commodity to the server.
sellerId Identifier of seller sellerIdType. May NOT be null.
identifier Commodity identifier identifierType. May NOT be null.

Request

PUT /v26/se9876543210/commodities/0-2U18 HTTP/1.1 Content-Type: application/json
Authorization: RestApiTester@se9876543210:9999
Host: t.srv4pos.com {/* Data to put. */ 'deleted': false, // True if entity was deleted. Only possible if return diff. Boolean. May NOT be null.
'identifier': '0-2U18', // This field uniquely identifies entity. There is no decision what is it, only the requirement - it must be unique trough one seller. identifierType. May NOT be null.
'product': '0-2U12', // Regular field. Product identifier. String. May NOT be null.
'category': '0-2U10', // Regular field. Tax identifier. String. May NOT be null.
'custom': '', // String. Maximum 65535 characters. May be null.
'color': 0 // Regular field. Integer. May be null.
}

Response

HTTP/1.1 201 CREATED or HTTP/1.1 204 NO CONTENT

Errors

409 VersionConflictJsonException

Occurs when we upload data to the server but server contains more fresh data than we send. No additional details provided. You should set actual "If-Match" header.

404 ReferenceNotFoundJsonException

If product wasn't found.

GET /v26/{sellerId}/commodities/{identifier}

Returns an entity.
sellerId Identifier of seller sellerIdType. May NOT be null.
identifier Commodity identifier identifierType. May NOT be null.

Request

GET /v26/se9876543210/commodities/0-2U18 HTTP/1.1 Host: t.srv4pos.com

Response

HTTP/1.1 200 OK

Errors

404 NotFoundJsonException

If entity is not found.

GET /v26/{sellerId}/commodities

Returns list of entities.
sellerId Identifier of seller sellerIdType. May NOT be null.
orderByQuery param field to order by One of the following values: 'IDENTIFIER', 'PRODUCT_NAME', 'PRODUCT_BARCODE', 'PRODUCT_NETTO', 'CATEGORY_NAME', 'PRODUCT_SALES_UNIT', 'PRODUCT_COUNTED_IN_PRICE'. May be null.
orderDescQuery param field to direction of ordering Boolean. May be null.
firstResultQuery param when pagination starts or null Integer. May be null.
maxResultsQuery param amount of items per page or null Integer. May be null.
likeQuery param search string filter or null String. May be null.

Request

GET /v26/se9876543210/commodities HTTP/1.1 Host: t.srv4pos.com

Response

HTTP/1.1 200 OK Content-Type: application/json;charset=UTF-8 /* List of entities which exists on current seller or null if list of entities is not modified since version. */
[ { 'deleted': false, // True if entity was deleted. Only possible if return diff. Boolean. May NOT be null.
'identifier': '0-2U18', // This field uniquely identifies entity. There is no decision what is it, only the requirement - it must be unique trough one seller. identifierType. May NOT be null.
'product': '0-2U12', // Regular field. Product identifier. String. May NOT be null.
'category': '0-2U16', // Regular field. Tax identifier. String. May NOT be null.
'custom': '', // String. Maximum 65535 characters. May be null.
'color': 0 // Regular field. Integer. May be null.
} ]

GET /v26/{sellerId}/commodities-advanced

Returns list of .
sellerId Identifier of seller sellerIdType. May NOT be null.
orderByQuery param field to order by One of the following values: 'IDENTIFIER', 'PRODUCT_NAME', 'PRODUCT_BARCODE', 'PRODUCT_NETTO', 'CATEGORY_NAME', 'PRODUCT_SALES_UNIT', 'PRODUCT_COUNTED_IN_PRICE'. May be null.
orderDescQuery param field to direction of ordering Boolean. May be null.
firstResultQuery param when pagination starts or null Integer. May be null.
maxResultsQuery param amount of items per page or null Integer. May be null.
likeQuery param search string filter or null String. May be null.

Request

GET /v26/se9876543210/commodities-advanced HTTP/1.1 Host: t.srv4pos.com

Response

HTTP/1.1 200 OK Content-Type: application/json;charset=UTF-8 /* List of entities which exists on current seller or null if list of entities is not modified since version. */
[ {/* Info entity with complete Product and Category infoes instead of solely their identifiers. See Commodity for comparison. */ 'commodityInfo': { 'deleted': false, // True if entity was deleted. Only possible if return diff. Boolean. May NOT be null.
'identifier': '0-2U18', // This field uniquely identifies entity. There is no decision what is it, only the requirement - it must be unique trough one seller. identifierType. May NOT be null.
'product': '', // Regular field. Product identifier. String. May NOT be null.
'category': '', // Regular field. Tax identifier. String. May NOT be null.
'custom': '', // String. Maximum 65535 characters. May be null.
'color': 0 // Regular field. Integer. May be null.
}, // A complex object. May NOT be null.
'productAdvancedInfo': { 'deleted': 'false', // True if entity was deleted. Only possible if return diff. May NOT be null.
'product': { 'deleted': 'false', // True if entity was deleted. Only possible if return diff. May NOT be null.
'identifier': '0-2U12', // identifierType. May NOT be null.
'name': 'Product 1', // Regular field. String. Minimum 1 characters. Maximum 32 characters. May NOT be null.
'barcode': '012345678912', // Regular field. String. Minimum 1 characters. Maximum 32 characters. May NOT be null.
'netto': 100, // Regular field. Integer. May NOT be null.
'tax': 'TAX1', // Regular field. identifierType. May NOT be null.
'salesUnit': 'Piece', // Regular field. salesUnitType. May NOT be null.
'countedInPrice': 'false', // Regular field. May NOT be null.
'description': '', // String. Maximum 1024 characters. May be null.
'custom': '' // String. Maximum 65535 characters. May be null.
}, // A complex object. May NOT be null.
'tax': { 'deleted': 'false', // true if entity was deleted. May NOT be null.
'identifier': 'TAX1', // This field uniquely identifies entity. There is no decision what is it, only the requirement - it must be unique trough one seller. identifierType. May be null.
'vat': 1, // Regular field. Integer. Minimum 0. Maximum 100. May NOT be null.
'name': 'Tax 1', // Regular field. String. Minimum 1 characters. Maximum 32 characters. May NOT be null.
'custom': '' // Custom data concerned tax. String. Maximum 65535 characters. May be null.
}, // A complex object. May NOT be null.
'images': ['PRODUCT1.PNG', 'PRODUCT2.PNG'] // A complex object. May NOT be null.
}{/* Data to put. */ 'deleted': 'false', // True if entity was deleted. Only possible if return diff. May NOT be null.
'identifier': '0-2U12', // identifierType. May NOT be null.
'name': 'Product 1', // Regular field. String. Minimum 1 characters. Maximum 32 characters. May NOT be null.
'barcode': '012345678912', // Regular field. String. Minimum 1 characters. Maximum 32 characters. May NOT be null.
'netto': 100, // Regular field. Integer. May NOT be null.
'tax': 'TAX1', // Regular field. identifierType. May NOT be null.
'salesUnit': 'Piece', // Regular field. salesUnitType. May NOT be null.
'countedInPrice': 'false', // Regular field. May NOT be null.
'description': '', // String. Maximum 1024 characters. May be null.
'custom': '', // String. Maximum 65535 characters. May be null.
'price': '0' //
}, // A complex object. A complex object. May NOT be null.
'categoryInfo': {/* Data to put. */ 'deleted': 'false', // True if entity was deleted. Only possible if return diff. May NOT be null.
'identifier': null, // identifierType. May be null.
'name': 'Test', // Regular field. String. Minimum 1 characters. Maximum 32 characters. May NOT be null.
'color': 0 // Regular field. Integer. May be null.
} // A complex object. May NOT be null.
} ]

DELETE /v26/{sellerId}/commodities/{identifier}

Delete entity from the server.
sellerId Identifier of seller sellerIdType. May NOT be null.
identifier Commodity identifier identifierType. May NOT be null.

Request

DELETE /v26/se9876543210/commodities/0-2U18 HTTP/1.1
Authorization: RestApiTester@se9876543210:9999
Host: t.srv4pos.com

Response

HTTP/1.1 204 NO CONTENT

Errors

409 VersionConflictJsonException

Occurs when we upload data to the server but server contains more fresh data than we send. No additional details provided. You should set actual "If-Match" header.

GET /v26/{sellerId}/commodities-diff/{versionFrom}/{versionTo}

Returns list of item changes between two versions.
sellerId Identifier of seller sellerIdType. May NOT be null.
versionFrom Min boundary version (included) for diff Integer. May NOT be null.
versionTo Max boundary version (included) for diff Integer. May NOT be null.

Request

GET /v26/se9876543210/commodities-diff/0/9999 HTTP/1.1 Host: t.srv4pos.com

Response

HTTP/1.1 200 OK Content-Type: application/json;charset=UTF-8
{ 'deleted': false, // True if entity was deleted. Only possible if return diff. Boolean. May NOT be null.
'identifier': '1', // This field uniquely identifies entity. There is no decision what is it, only the requirement - it must be unique trough one seller. identifierType. May NOT be null.
'product': 'test product', // Regular field. Product identifier. String. May NOT be null.
'category': 'test category', // Regular field. Tax identifier. String. May NOT be null.
'custom': '', // String. Maximum 65535 characters. May be null.
'color': 0 // Regular field. Integer. May be null.
}

POST /v26/{sellerId}/keyboards

Create keyboard on the server.
sellerId Identifier of seller sellerIdType. May NOT be null.

Request

POST /v26/se9876543210/keyboards HTTP/1.1 Content-Type: application/json
Authorization: RestApiTester@se9876543210:9999
Host: t.srv4pos.com {/* Data to put. */ 'deleted': 'false', // true if entity was deleted. May NOT be null.
'identifier': null, // identifierType. May be null.
'name': 'Test', // Regular field. String. Minimum 1 characters. Maximum 32 characters. May NOT be null.
'width': 0, // Regular field. Integer. May NOT be null.
'height': 0, // Regular field. Integer. May NOT be null.
'deviceFormFactor': 'PHONE', // Regular field. deviceFormFactorType. May NOT be null.
'custom': '' // String. Maximum 65535 characters. May be null.
}

Response

HTTP/1.1 201 CREATED Content-Type: application/json;charset=UTF-8 /* Generated unique identifier. */
{/* Methods called "new" will return the identifier of newly created entity by using this class */ 'identifier': '0-ID' // identifierType. May NOT be null.
}

Errors

409 VersionConflictJsonException

Occurs when we upload data to the server but server contains more fresh data than we send. No additional details provided. You should set actual "If-Match" header.

PUT /v26/{sellerId}/keyboards/{identifier}

Put keyboard to the server.
sellerId Identifier of seller sellerIdType. May NOT be null.
identifier Keyboard identifier identifierType. May NOT be null.

Request

PUT /v26/se9876543210/keyboards/0-2U20 HTTP/1.1 Content-Type: application/json
Authorization: RestApiTester@se9876543210:9999
Host: t.srv4pos.com {/* Data to put. */ 'deleted': 'false', // true if entity was deleted. May NOT be null.
'identifier': '0-2U20', // identifierType. May be null.
'name': 'Test1', // Regular field. String. Minimum 1 characters. Maximum 32 characters. May NOT be null.
'width': 0, // Regular field. Integer. May NOT be null.
'height': 0, // Regular field. Integer. May NOT be null.
'deviceFormFactor': 'PHONE', // Regular field. deviceFormFactorType. May NOT be null.
'custom': '' // String. Maximum 65535 characters. May be null.
}

Response

HTTP/1.1 201 CREATED or HTTP/1.1 204 NO CONTENT Content-Type: application/json;charset=UTF-8
{/* Methods called "new" will return the identifier of newly created entity by using this class */ 'identifier': '0-ID' // identifierType. May NOT be null.
}

Errors

409 VersionConflictJsonException

Occurs when we upload data to the server but server contains more fresh data than we send. No additional details provided. You should set actual "If-Match" header.

GET /v26/{sellerId}/keyboards/{identifier}

Returns an entity.
sellerId Identifier of seller sellerIdType. May NOT be null.
identifier Keyboard identifier identifierType. May NOT be null.

Request

GET /v26/se9876543210/keyboards/0-2U20 HTTP/1.1
Authorization: RestApiTester@se9876543210:9999
Host: t.srv4pos.com

Response

HTTP/1.1 200 OK Content-Type: application/json;charset=UTF-8 /* Null if not modified since version or entity. If version is null then return value can not be null. */
{ 'deleted': 'false', // true if entity was deleted. May NOT be null.
'identifier': '0-2U20', // identifierType. May be null.
'name': 'Test1', // Regular field. String. Minimum 1 characters. Maximum 32 characters. May NOT be null.
'width': 0, // Regular field. Integer. May NOT be null.
'height': 0, // Regular field. Integer. May NOT be null.
'deviceFormFactor': 'PHONE', // Regular field. deviceFormFactorType. May NOT be null.
'custom': '' // String. Maximum 65535 characters. May be null.
}

Errors

409 VersionConflictJsonException

Occurs when we upload data to the server but server contains more fresh data than we send. No additional details provided. You should set actual "If-Match" header.

404 NotFoundJsonException

If entity is not found.

GET /v26/{sellerId}/keyboards

Returns list of entities.
sellerId Identifier of seller sellerIdType. May NOT be null.
orderByQuery param field to order by One of the following values: 'IDENTIFIER', 'NAME', 'WIDTH', 'HEIGHT', 'DEVICE_FORM_FACTOR'. May be null.
orderDescQuery param field to direction of ordering Boolean. May be null.
firstResultQuery param when pagination starts or null Integer. May be null.
maxResultsQuery param amount of items per page or null Integer. May be null.
likeQuery param search string filter or null String. May be null.

Request

GET /v26/se9876543210/keyboards HTTP/1.1
Authorization: RestApiTester@se9876543210:9999
Host: t.srv4pos.com

Response

HTTP/1.1 200 OK Content-Type: application/json;charset=UTF-8 /* Returns list of entities. */
[ { 'deleted': 'false', // true if entity was deleted. May NOT be null.
'identifier': '0-2U20', // identifierType. May be null.
'name': 'Test1', // Regular field. String. Minimum 1 characters. Maximum 32 characters. May NOT be null.
'width': 0, // Regular field. Integer. May NOT be null.
'height': 0, // Regular field. Integer. May NOT be null.
'deviceFormFactor': 'PHONE', // Regular field. deviceFormFactorType. May NOT be null.
'custom': '' // String. Maximum 65535 characters. May be null.
} ]

DELETE /v26/{sellerId}/keyboards/{identifier}

Delete keyboardy from the server.
sellerId Identifier of seller sellerIdType. May NOT be null.
identifier Keyboard identifier identifierType. May NOT be null.

Request

DELETE /v26/se9876543210/keyboards/0-2U20 HTTP/1.1
Authorization: RestApiTester@se9876543210:9999
Host: t.srv4pos.com

Response

HTTP/1.1 204 NO CONTENT

Errors

409 VersionConflictJsonException

Occurs when we upload data to the server but server contains more fresh data than we send. No additional details provided. You should set actual "If-Match" header.

GET /v26/{sellerId}/keyboards-diff/{versionFrom}/{versionTo}

Returns list of item changes between two versions.
sellerId Identifier of seller sellerIdType. May NOT be null.
versionFrom Min boundary version (included) for diff Integer. May NOT be null.
versionTo Max boundary version (included) for diff Integer. May NOT be null.

Request

GET /v26/se9876543210/keyboards-diff/0/9999 HTTP/1.1
Authorization: RestApiTester@se9876543210:9999
Host: t.srv4pos.com

Response

HTTP/1.1 200 OK Content-Type: application/json;charset=UTF-8 /* return list of items to be added, edited or deleted ({@link KeyboardInfo#isDeleted()} = true). */
{ 'deleted': 'false', // true if entity was deleted. May NOT be null.
'identifier': '0-2U20', // identifierType. May be null.
'name': 'Test1', // Regular field. String. Minimum 1 characters. Maximum 32 characters. May NOT be null.
'width': 0, // Regular field. Integer. May NOT be null.
'height': 0, // Regular field. Integer. May NOT be null.
'deviceFormFactor': 'PHONE', // Regular field. deviceFormFactorType. May NOT be null.
'custom': '' // String. Maximum 65535 characters. May be null.
}

POST /v26/{sellerId}/keyboard-entries

Create keyboardEntry on the server.
sellerId Identifier of seller sellerIdType. May NOT be null.

Request

POST /v26/se9876543210/keyboard-entries HTTP/1.1 Content-Type: application/json
Authorization: RestApiTester@se9876543210:9999
Host: t.srv4pos.com {/* Data to put. */ 'deleted': false, // true if entity was deleted. Boolean. May NOT be null.
'identifier': null, // This field uniquely identifies entity. There is no decision what is it, only the requirement - it must be unique trough one seller. identifierType. May NOT be null.
'product': '0-2U12', // Regular field. Product identifier. String. May NOT be null.
'keyboard': '0-2U20', // Regular field. Keyboard identifier. String. May NOT be null.
'subKeyboard': '0-2U20', // Regular field. SubKeyboard identifier. String. May be null.
'positionX': 1, // Regular field. Integer. May NOT be null.
'positionY': 1, // Regular field. Integer. May NOT be null.
'width': 1, // Regular field. Integer. May NOT be null.
'height': 1, // Regular field. Integer. May NOT be null.
'keyAction': 'Product', // Regular field. keyActionType. May NOT be null.
'label': 'KeyboardEntry 1', // Regular field. String. Minimum 1 characters. Maximum 32 characters. May NOT be null.
'custom': '' // String. Maximum 65535 characters. May be null.
}

Response

HTTP/1.1 201 CREATED Content-Type: application/json;charset=UTF-8
{/* Methods called "new" will return the identifier of newly created entity by using this class */ 'identifier': '0-ID' // identifierType. May NOT be null.
}

Errors

409 VersionConflictJsonException

Occurs when we upload data to the server but server contains more fresh data than we send. No additional details provided. You should set actual "If-Match" header.

404 ReferenceNotFoundJsonException

If product wasn't found.

PUT /v26/{sellerId}/keyboard-entries/{identifier}

Put keyboardEntry to the server.
sellerId Identifier of seller sellerIdType. May NOT be null.
identifier KeyboardEntry identifier identifierType. May NOT be null.

Request

PUT /v26/se9876543210/keyboard-entries/0-2U28 HTTP/1.1 Content-Type: application/json
Authorization: RestApiTester@se9876543210:9999
Host: t.srv4pos.com {/* Data to put. */ 'deleted': false, // true if entity was deleted. Boolean. May NOT be null.
'identifier': '0-2U28', // This field uniquely identifies entity. There is no decision what is it, only the requirement - it must be unique trough one seller. identifierType. May NOT be null.
'product': '0-2U12', // Regular field. Product identifier. String. May NOT be null.
'keyboard': '0-2U20', // Regular field. Keyboard identifier. String. May NOT be null.
'subKeyboard': '0-2U20', // Regular field. SubKeyboard identifier. String. May be null.
'positionX': 1, // Regular field. Integer. May NOT be null.
'positionY': 1, // Regular field. Integer. May NOT be null.
'width': 1, // Regular field. Integer. May NOT be null.
'height': 1, // Regular field. Integer. May NOT be null.
'keyAction': 'Product', // Regular field. keyActionType. May NOT be null.
'label': 'KeyboardEntry 1', // Regular field. String. Minimum 1 characters. Maximum 32 characters. May NOT be null.
'custom': '' // String. Maximum 65535 characters. May be null.
}

Response

HTTP/1.1 201 CREATED or HTTP/1.1 204 NO CONTENT

Errors

409 VersionConflictJsonException

Occurs when we upload data to the server but server contains more fresh data than we send. No additional details provided. You should set actual "If-Match" header.

404 ReferenceNotFoundJsonException

If product wasn't found.

GET /v26/{sellerId}/keyboard-entries/{identifier}

Returns an entity.
sellerId Identifier of seller sellerIdType. May NOT be null.
identifier KeyboardEntry identifier identifierType. May NOT be null.

Request

GET /v26/se9876543210/keyboard-entries/0-2U28 HTTP/1.1
Authorization: RestApiTester@se9876543210:9999
Host: t.srv4pos.com

Response

HTTP/1.1 200 OK

Errors

409 VersionConflictJsonException

Occurs when we upload data to the server but server contains more fresh data than we send. No additional details provided. You should set actual "If-Match" header.

404 NotFoundJsonException

If entity is not found.

DELETE /v26/{sellerId}/keyboard-entries/{identifier}

Delete entity from the server.
sellerId Identifier of seller sellerIdType. May NOT be null.
identifier KeyboardEntry identifier identifierType. May NOT be null.

Request

DELETE /v26/se9876543210/keyboard-entries/0-2U28 HTTP/1.1
Authorization: RestApiTester@se9876543210:9999
Host: t.srv4pos.com

Response

HTTP/1.1 204 NO CONTENT

Errors

409 VersionConflictJsonException

Occurs when we upload data to the server but server contains more fresh data than we send. No additional details provided. You should set actual "If-Match" header.

GET /v26/{sellerId}/keyboard-entries-diff/{versionFrom}/{versionTo}

Returns list of item changes between two versions.
sellerId Identifier of seller sellerIdType. May NOT be null.
versionFrom Min boundary version (included) for diff Integer. May NOT be null.
versionTo Max boundary version (included) for diff Integer. May NOT be null.

Request

GET /v26/se9876543210/keyboard-entries-diff/0/9999 HTTP/1.1
Authorization: RestApiTester@se9876543210:9999
Host: t.srv4pos.com

Response

HTTP/1.1 200 OK Content-Type: application/json;charset=UTF-8 /* return list of items to be added, edited or deleted ({@link KeyboardEntryInfo#isDeleted()} = true). */
{ 'deleted': false, // true if entity was deleted. Boolean. May NOT be null.
'identifier': '45а5543534', // This field uniquely identifies entity. There is no decision what is it, only the requirement - it must be unique trough one seller. identifierType. May NOT be null.
'product': 'test', // Regular field. Product identifier. String. May NOT be null.
'keyboard': 'keyboard', // Regular field. Keyboard identifier. String. May NOT be null.
'subKeyboard': 'value', // Regular field. SubKeyboard identifier. String. May be null.
'positionX': 56, // Regular field. Integer. May NOT be null.
'positionY': 89, // Regular field. Integer. May NOT be null.
'width': 123, // Regular field. Integer. May NOT be null.
'height': 675, // Regular field. Integer. May NOT be null.
'keyAction': 'Product', // Regular field. keyActionType. May NOT be null.
'label': 'test', // Regular field. String. Minimum 1 characters. Maximum 32 characters. May NOT be null.
'custom': 'test' // String. Maximum 65535 characters. May be null.
}

GET /v26/{sellerId}/keyboard-entries

Returns list of entities.
sellerId Identifier of seller sellerIdType. May NOT be null.
orderByQuery param field to order by One of the following values: 'IDENTIFIER', 'PRODUCT_NAME', 'PRODUCT_BARCODE', 'PRODUCT_NETTO', 'PRODUCT_SALES_UNIT', 'PRODUCT_COUNTED_IN_PRICE', 'KEYBOARD_NAME', 'SUB_KEYBOARD_NAME', 'POSITION_X', 'POSITION_Y', 'WIDTH', 'HEIGHT', 'KEY_ACTION', 'LABEL'. May be null.
orderDescQuery param field to direction of ordering Boolean. May be null.
firstResultQuery param when pagination starts or null Integer. May be null.
maxResultsQuery param amount of items per page or null Integer. May be null.
likeQuery param search string filter or null String. May be null.

Request

GET /v26/se9876543210/keyboard-entries HTTP/1.1
Authorization: RestApiTester@se9876543210:9999
Host: t.srv4pos.com

Response

HTTP/1.1 200 OK Content-Type: application/json;charset=UTF-8 /* return list of entities which exists on current seller or null if list of entities is not modified since version. */
{ 'deleted': false, // true if entity was deleted. Boolean. May NOT be null.
'identifier': '45а5543534', // This field uniquely identifies entity. There is no decision what is it, only the requirement - it must be unique trough one seller. identifierType. May NOT be null.
'product': 'test', // Regular field. Product identifier. String. May NOT be null.
'keyboard': 'keyboard', // Regular field. Keyboard identifier. String. May NOT be null.
'subKeyboard': 'value', // Regular field. SubKeyboard identifier. String. May be null.
'positionX': 56, // Regular field. Integer. May NOT be null.
'positionY': 89, // Regular field. Integer. May NOT be null.
'width': 123, // Regular field. Integer. May NOT be null.
'height': 675, // Regular field. Integer. May NOT be null.
'keyAction': 'Product', // Regular field. keyActionType. May NOT be null.
'label': 'test', // Regular field. String. Minimum 1 characters. Maximum 32 characters. May NOT be null.
'custom': 'test' // String. Maximum 65535 characters. May be null.
}

POST /v26/{sellerId}/orders

Sends an order.
sellerId Identifier of seller sellerIdType. May NOT be null.

Request

POST /v26/se9876543210/orders HTTP/1.1 Content-Type: application/json Host: t.srv4pos.com {/* Represents customer's order - list of order items. */ 'identifier': '0-1', // identifierType. May be null.
'orderItems': [ {/* Represents how many products of particular type was ordered. */ 'productIdentifier': 'PRODUCT1', // identifierType. May NOT be null.
'productCustomization': 'Customization A', // Any customer's wishes about product customization. String. Maximum 512 characters. May be null.
'delta': 700 // The number of products (kg, hg, hours, whatever unit) if deltaUnit is true, otherwise the amount of currency. Integer. May NOT be null.
} ], // List of objects.
'status': 'NEW', // orderPaymentStatus. May NOT be null.
'deleted': 'false', // true if entity was deleted. May NOT be null.
'booking': 'BOK1', // identifierType. May be null.
'delivery': {/* Represents information about delivery. */ 'contact': {/* Information about person. */ 'name': 'Stefan', // Name of person who makes activation String. May NOT be null.
'phone': '56745325', // Phone number of person who requests activation String. May NOT be null.
'email': 'test@test.se' // Email of person who requests activation String. May NOT be null.
}, // A complex object.
'address': '', // Delivery address. String. Maximum 255 characters.
'date': new Date().setHours(0,0,0,0), // Date and time of delivery. Date: amount of milliseconds since UNIX epoch.
'comment': '' // Additional information about delivery. String. Maximum 255 characters.
}, // A complex object. May be null.
'created': 1414800000001, // Date: amount of milliseconds since UNIX epoch. May be null.
'gcmRegistrationId': 'AaaaXxxcmMMsSss' // String. Minimum 1 characters. May be null.
}

Response

HTTP/1.1 201 CREATED Content-Type: application/json;charset=UTF-8 /* Generated unique identifier. */
{/* Methods called "new" will return the identifier of newly created entity by using this class */ 'identifier': '0-ID' // identifierType. May NOT be null.
}

Errors

404 ReferenceNotFoundJsonException

If product with passed productIdentifier or booking with passed identifier were not found.

409 VersionConflictJsonException

Occurs when we upload data to the server but server contains more fresh data than we send. No additional details provided. You should set actual "If-Match" header.

GET /v26/{sellerId}/orders

Returns a list with orders.
sellerId Identifier of seller sellerIdType. May NOT be null.
firstResultQuery param when pagination starts or null Integer. May be null.
maxResultsQuery param amount of items per page or null Integer. May be null.
orderByQuery param field to order by One of the following values: 'IDENTIFIER', 'STATUS', 'CREATED'. May be null.
orderDescQuery param field to direction of ordering Boolean. May be null.
likeQuery param search string filter or null String. May be null.
statusQuery param filter by payment status or null String. May be null.

Request

GET /v26/se9876543210/orders HTTP/1.1
Authorization: RestApiTester@se9876543210:9999
Host: t.srv4pos.com

Response

HTTP/1.1 200 OK Content-Type: application/json;charset=UTF-8
[ {/* Represents customer's order - list of order items. */ 'identifier': '0-1', // identifierType. May be null.
'orderItems': [ {/* Represents how many products of particular type was ordered. */ 'productIdentifier': 'PRODUCT1', // identifierType. May NOT be null.
'productCustomization': 'Customization A', // Any customer's wishes about product customization. String. Maximum 512 characters. May be null.
'delta': 700 // The number of products (kg, hg, hours, whatever unit) if deltaUnit is true, otherwise the amount of currency. Integer. May NOT be null.
} ], // List of objects.
'status': 'NEW', // orderPaymentStatus. May NOT be null.
'deleted': 'false', // true if entity was deleted. May NOT be null.
'booking': 'BOK1', // identifierType. May be null.
'delivery': {/* Represents information about delivery. */ 'contact': {/* Information about person. */ 'name': 'Stefan', // Name of person who makes activation String. May NOT be null.
'phone': '56745325', // Phone number of person who requests activation String. May NOT be null.
'email': 'test@test.se' // Email of person who requests activation String. May NOT be null.
}, // A complex object.
'address': '', // Delivery address. String. Maximum 255 characters.
'date': new Date().setHours(0,0,0,0), // Date and time of delivery. Date: amount of milliseconds since UNIX epoch.
'comment': '' // Additional information about delivery. String. Maximum 255 characters.
}, // A complex object. May be null.
'created': 1414800000001, // Date: amount of milliseconds since UNIX epoch. May be null.
'gcmRegistrationId': 'AaaaXxxcmMMsSss' // String. Minimum 1 characters. May be null.
} ]

GET /v26/{sellerId}/orders/{orderId}

Gets info about order.
sellerId Identifier of seller sellerIdType. May NOT be null.
orderId identifies entity identifierType. May NOT be null.

Request

GET /v26/se9876543210/orders/0-1 HTTP/1.1
Authorization: RestApiTester@se9876543210:9999
Host: t.srv4pos.com

Response

HTTP/1.1 200 OK Content-Type: application/json;charset=UTF-8
{/* Represents customer's order - list of order items. */ 'identifier': '0-1', // identifierType. May be null.
'orderItems': [ {/* Represents how many products of particular type was ordered. */ 'productIdentifier': 'PRODUCT1', // identifierType. May NOT be null.
'productCustomization': 'Customization A', // Any customer's wishes about product customization. String. Maximum 512 characters. May be null.
'delta': 700 // The number of products (kg, hg, hours, whatever unit) if deltaUnit is true, otherwise the amount of currency. Integer. May NOT be null.
} ], // List of objects.
'status': 'NEW', // orderPaymentStatus. May NOT be null.
'deleted': 'false', // true if entity was deleted. May NOT be null.
'booking': 'BOK1', // identifierType. May be null.
'delivery': {/* Represents information about delivery. */ 'contact': {/* Information about person. */ 'name': 'Stefan', // Name of person who makes activation String. May NOT be null.
'phone': '56745325', // Phone number of person who requests activation String. May NOT be null.
'email': 'test@test.se' // Email of person who requests activation String. May NOT be null.
}, // A complex object.
'address': '', // Delivery address. String. Maximum 255 characters.
'date': new Date().setHours(0,0,0,0), // Date and time of delivery. Date: amount of milliseconds since UNIX epoch.
'comment': '' // Additional information about delivery. String. Maximum 255 characters.
}, // A complex object. May be null.
'created': 1414800000001, // Date: amount of milliseconds since UNIX epoch. May be null.
'gcmRegistrationId': 'AaaaXxxcmMMsSss' // String. Minimum 1 characters. May be null.
}

Errors

409 VersionConflictJsonException

Occurs when we upload data to the server but server contains more fresh data than we send. No additional details provided. You should set actual "If-Match" header.

GET /v26/{sellerId}/orders-advanced

Returns a list with orders. Provides additional info like products and taxes.
sellerId Identifier of seller sellerIdType. May NOT be null.
firstResultQuery param when pagination starts or null Integer. May be null.
maxResultsQuery param amount of items per page or null Integer. May be null.
orderByQuery param field to order by One of the following values: 'IDENTIFIER', 'STATUS', 'CREATED'. May be null.
orderDescQuery param field to direction of ordering Boolean. May be null.
likeQuery param search string filter or null String. May be null.
statusQuery param filter by payment status or null String. May be null.

Request

GET /v26/se9876543210/orders-advanced HTTP/1.1
Authorization: RestApiTester@se9876543210:9999
Host: t.srv4pos.com

Response

HTTP/1.1 200 OK Content-Type: application/json;charset=UTF-8
[ {/* Represents customer's order - list of order items. Provides advanced information. */ 'orderInfo': {/* Represents customer's order - list of order items. */ 'identifier': '0-1', // identifierType. May be null.
'orderItems': [ {/* Represents how many products of particular type was ordered. */ 'productIdentifier': 'PRODUCT1', // identifierType. May NOT be null.
'productCustomization': 'Customization A', // Any customer's wishes about product customization. String. Maximum 512 characters. May be null.
'delta': 700 // The number of products (kg, hg, hours, whatever unit) if deltaUnit is true, otherwise the amount of currency. Integer. May NOT be null.
} ], // List of objects.
'status': 'NEW', // orderPaymentStatus. May NOT be null.
'deleted': 'false', // true if entity was deleted. May NOT be null.
'booking': 'BOK1', // identifierType. May be null.
'delivery': {/* Represents information about delivery. */ 'contact': {/* Information about person. */ 'name': 'Stefan', // Name of person who makes activation String. May NOT be null.
'phone': '56745325', // Phone number of person who requests activation String. May NOT be null.
'email': 'test@test.se' // Email of person who requests activation String. May NOT be null.
}, // A complex object.
'address': '', // Delivery address. String. Maximum 255 characters.
'date': new Date().setHours(0,0,0,0), // Date and time of delivery. Date: amount of milliseconds since UNIX epoch.
'comment': '' // Additional information about delivery. String. Maximum 255 characters.
}, // A complex object. May be null.
'created': 1414800000001, // Date: amount of milliseconds since UNIX epoch. May be null.
'gcmRegistrationId': 'AaaaXxxcmMMsSss' // String. Minimum 1 characters. May be null.
}, // A complex object. May NOT be null.
'orderItems': [ {/* Represents how many products of particular type was ordered. */ 'orderItemInfo': {/* Represents how many products of particular type was ordered. */ 'productIdentifier': 'PRODUCT1', // identifierType. May NOT be null.
'productCustomization': 'Customization A', // Any customer's wishes about product customization. String. Maximum 512 characters. May be null.
'delta': 700 // The number of products (kg, hg, hours, whatever unit) if deltaUnit is true, otherwise the amount of currency. Integer. May NOT be null.
}, // A complex object. May NOT be null.
'productInfo': { 'deleted': 'false', // True if entity was deleted. Only possible if return diff. May NOT be null.
'product': { 'deleted': 'false', // True if entity was deleted. Only possible if return diff. May NOT be null.
'identifier': '0-2U12', // identifierType. May NOT be null.
'name': 'Product 1', // Regular field. String. Minimum 1 characters. Maximum 32 characters. May NOT be null.
'barcode': '012345678912', // Regular field. String. Minimum 1 characters. Maximum 32 characters. May NOT be null.
'netto': 100, // Regular field. Integer. May NOT be null.
'tax': 'TAX1', // Regular field. identifierType. May NOT be null.
'salesUnit': 'Piece', // Regular field. salesUnitType. May NOT be null.
'countedInPrice': 'false', // Regular field. May NOT be null.
'description': '', // String. Maximum 1024 characters. May be null.
'custom': '' // String. Maximum 65535 characters. May be null.
}, // A complex object. May NOT be null.
'tax': { 'deleted': 'false', // true if entity was deleted. May NOT be null.
'identifier': 'TAX1', // This field uniquely identifies entity. There is no decision what is it, only the requirement - it must be unique trough one seller. identifierType. May be null.
'vat': 1, // Regular field. Integer. Minimum 0. Maximum 100. May NOT be null.
'name': 'Tax 1', // Regular field. String. Minimum 1 characters. Maximum 32 characters. May NOT be null.
'custom': '' // Custom data concerned tax. String. Maximum 65535 characters. May be null.
}, // A complex object. May NOT be null.
'images': ['PRODUCT1.PNG', 'PRODUCT2.PNG'] // A complex object. May NOT be null.
} // A complex object. May NOT be null.
} ], // List of objects.
'bookingInfo': { 'identifier': '', // identifierType. May be null.
'bookingDate': new Date().setHours(0,0,0,0), // Date: amount of milliseconds since UNIX epoch. May NOT be null.
'persons': , // Integer. May NOT be null.
'description': '', // String. Maximum 1024 characters.
'contactInfo': {/* Information about person. */ 'name': 'Stefan', // Name of person who makes activation String. May NOT be null.
'phone': '56745325', // Phone number of person who requests activation String. May NOT be null.
'email': 'test@test.se' // Email of person who requests activation String. May NOT be null.
}, // A complex object. May NOT be null.
'deleted': '' // true if entity was deleted. May NOT be null.
} // A complex object. May be null.
} ]

GET /v26/{sellerId}/orders-advanced/{orderId}

Gets advanced info about order.
sellerId Identifier of seller sellerIdType. May NOT be null.
orderId identifies entity identifierType. May NOT be null.

Request

GET /v26/se9876543210/orders-advanced/0-1 HTTP/1.1
Authorization: RestApiTester@se9876543210:9999
Host: t.srv4pos.com

Response

HTTP/1.1 200 OK Content-Type: application/json;charset=UTF-8
{/* Represents customer's order - list of order items. Provides advanced information. */ 'orderInfo': {/* Represents customer's order - list of order items. */ 'identifier': '0-1', // identifierType. May be null.
'orderItems': [ {/* Represents how many products of particular type was ordered. */ 'productIdentifier': 'PRODUCT1', // identifierType. May NOT be null.
'productCustomization': 'Customization A', // Any customer's wishes about product customization. String. Maximum 512 characters. May be null.
'delta': 700 // The number of products (kg, hg, hours, whatever unit) if deltaUnit is true, otherwise the amount of currency. Integer. May NOT be null.
} ], // List of objects.
'status': 'NEW', // orderPaymentStatus. May NOT be null.
'deleted': 'false', // true if entity was deleted. May NOT be null.
'booking': 'BOK1', // identifierType. May be null.
'delivery': {/* Represents information about delivery. */ 'contact': {/* Information about person. */ 'name': 'Stefan', // Name of person who makes activation String. May NOT be null.
'phone': '56745325', // Phone number of person who requests activation String. May NOT be null.
'email': 'test@test.se' // Email of person who requests activation String. May NOT be null.
}, // A complex object.
'address': '', // Delivery address. String. Maximum 255 characters.
'date': new Date().setHours(0,0,0,0), // Date and time of delivery. Date: amount of milliseconds since UNIX epoch.
'comment': '' // Additional information about delivery. String. Maximum 255 characters.
}, // A complex object. May be null.
'created': 1414800000001, // Date: amount of milliseconds since UNIX epoch. May be null.
'gcmRegistrationId': 'AaaaXxxcmMMsSss' // String. Minimum 1 characters. May be null.
}, // A complex object. May NOT be null.
'orderItems': [ {/* Represents how many products of particular type was ordered. */ 'orderItemInfo': {/* Represents how many products of particular type was ordered. */ 'productIdentifier': 'PRODUCT1', // identifierType. May NOT be null.
'productCustomization': 'Customization A', // Any customer's wishes about product customization. String. Maximum 512 characters. May be null.
'delta': 700 // The number of products (kg, hg, hours, whatever unit) if deltaUnit is true, otherwise the amount of currency. Integer. May NOT be null.
}, // A complex object. May NOT be null.
'productInfo': { 'deleted': 'false', // True if entity was deleted. Only possible if return diff. May NOT be null.
'product': { 'deleted': 'false', // True if entity was deleted. Only possible if return diff. May NOT be null.
'identifier': '0-2U12', // identifierType. May NOT be null.
'name': 'Product 1', // Regular field. String. Minimum 1 characters. Maximum 32 characters. May NOT be null.
'barcode': '012345678912', // Regular field. String. Minimum 1 characters. Maximum 32 characters. May NOT be null.
'netto': 100, // Regular field. Integer. May NOT be null.
'tax': 'TAX1', // Regular field. identifierType. May NOT be null.
'salesUnit': 'Piece', // Regular field. salesUnitType. May NOT be null.
'countedInPrice': 'false', // Regular field. May NOT be null.
'description': '', // String. Maximum 1024 characters. May be null.
'custom': '' // String. Maximum 65535 characters. May be null.
}, // A complex object. May NOT be null.
'tax': { 'deleted': 'false', // true if entity was deleted. May NOT be null.
'identifier': 'TAX1', // This field uniquely identifies entity. There is no decision what is it, only the requirement - it must be unique trough one seller. identifierType. May be null.
'vat': 1, // Regular field. Integer. Minimum 0. Maximum 100. May NOT be null.
'name': 'Tax 1', // Regular field. String. Minimum 1 characters. Maximum 32 characters. May NOT be null.
'custom': '' // Custom data concerned tax. String. Maximum 65535 characters. May be null.
}, // A complex object. May NOT be null.
'images': ['PRODUCT1.PNG', 'PRODUCT2.PNG'] // A complex object. May NOT be null.
} // A complex object. May NOT be null.
} ], // List of objects.
'bookingInfo': { 'identifier': '', // identifierType. May be null.
'bookingDate': new Date().setHours(0,0,0,0), // Date: amount of milliseconds since UNIX epoch. May NOT be null.
'persons': , // Integer. May NOT be null.
'description': '', // String. Maximum 1024 characters.
'contactInfo': {/* Information about person. */ 'name': 'Stefan', // Name of person who makes activation String. May NOT be null.
'phone': '56745325', // Phone number of person who requests activation String. May NOT be null.
'email': 'test@test.se' // Email of person who requests activation String. May NOT be null.
}, // A complex object. May NOT be null.
'deleted': '' // true if entity was deleted. May NOT be null.
} // A complex object. May be null.
}

Errors

409 VersionConflictJsonException

Occurs when we upload data to the server but server contains more fresh data than we send. No additional details provided. You should set actual "If-Match" header.

GET /v26/{sellerId}/orders-diff/{versionFrom}/{versionTo}

Returns list of item changes between two versions. Since we don't have delete and edit methods, it returns only newly created orders.
sellerId Identifier of seller sellerIdType. May NOT be null.
versionFrom Min boundary version (included) for diff Integer. May NOT be null.
versionTo Max boundary version (included) for diff Integer. May NOT be null.
statusQuery param filter by payment status or null String. May be null.

Request

GET /v26/se9876543210/orders-diff/0/9999 HTTP/1.1
Authorization: RestApiTester@se9876543210:9999
Host: t.srv4pos.com

Response

HTTP/1.1 200 OK Content-Type: application/json;charset=UTF-8
{/* Represents customer's order - list of order items. */ 'identifier': '0-1', // identifierType. May be null.
'orderItems': [ {/* Represents how many products of particular type was ordered. */ 'productIdentifier': 'PRODUCT1', // identifierType. May NOT be null.
'productCustomization': 'Customization A', // Any customer's wishes about product customization. String. Maximum 512 characters. May be null.
'delta': 700 // The number of products (kg, hg, hours, whatever unit) if deltaUnit is true, otherwise the amount of currency. Integer. May NOT be null.
} ], // List of objects.
'status': 'NEW', // orderPaymentStatus. May NOT be null.
'deleted': 'false', // true if entity was deleted. May NOT be null.
'booking': 'BOK1', // identifierType. May be null.
'delivery': {/* Represents information about delivery. */ 'contact': {/* Information about person. */ 'name': 'Stefan', // Name of person who makes activation String. May NOT be null.
'phone': '56745325', // Phone number of person who requests activation String. May NOT be null.
'email': 'test@test.se' // Email of person who requests activation String. May NOT be null.
}, // A complex object.
'address': '', // Delivery address. String. Maximum 255 characters.
'date': new Date().setHours(0,0,0,0), // Date and time of delivery. Date: amount of milliseconds since UNIX epoch.
'comment': '' // Additional information about delivery. String. Maximum 255 characters.
}, // A complex object. May be null.
'created': 1414800000001, // Date: amount of milliseconds since UNIX epoch. May be null.
'gcmRegistrationId': 'AaaaXxxcmMMsSss' // String. Minimum 1 characters. May be null.
}

PUT /v26/{sellerId}/orders/{orderId}

Change an order. Provides changes of order payment status.
sellerId Identifier of seller sellerIdType. May NOT be null.
orderId identifies entity identifierType. May NOT be null.

Request

PUT /v26/se9876543210/orders/0-1 HTTP/1.1 Content-Type: application/json
Authorization: RestApiTester@se9876543210:9999
If-Match: "0" // Value should be taken from /{sellerId}.
Host: t.srv4pos.com {/* Represents customer's order - list of order items. */ 'identifier': '0-1', // identifierType. May be null.
'orderItems': [ {/* Represents how many products of particular type was ordered. */ 'productIdentifier': 'PRODUCT1', // identifierType. May NOT be null.
'productCustomization': 'Customization A', // Any customer's wishes about product customization. String. Maximum 512 characters. May be null.
'delta': 700 // The number of products (kg, hg, hours, whatever unit) if deltaUnit is true, otherwise the amount of currency. Integer. May NOT be null.
} ], // List of objects.
'status': 'NEW', // orderPaymentStatus. May NOT be null.
'deleted': 'false', // true if entity was deleted. May NOT be null.
'booking': 'BOK1', // identifierType. May be null.
'delivery': {/* Represents information about delivery. */ 'contact': {/* Information about person. */ 'name': 'Stefan', // Name of person who makes activation String. May NOT be null.
'phone': '56745325', // Phone number of person who requests activation String. May NOT be null.
'email': 'test@test.se' // Email of person who requests activation String. May NOT be null.
}, // A complex object.
'address': '', // Delivery address. String. Maximum 255 characters.
'date': new Date().setHours(0,0,0,0), // Date and time of delivery. Date: amount of milliseconds since UNIX epoch.
'comment': '' // Additional information about delivery. String. Maximum 255 characters.
}, // A complex object. May be null.
'created': 1414800000001, // Date: amount of milliseconds since UNIX epoch. May be null.
'gcmRegistrationId': 'AaaaXxxcmMMsSss' // String. Minimum 1 characters. May be null.
}

Response

HTTP/1.1 204 NO CONTENT

Errors

404 ReferenceNotFoundJsonException

If product with passed productIdentifier or booking with passed identifier were not found.

403 ForbiddenJsonException

See there: INSUFFICIENT_ACCESS_RIGHTS .

422 UnprocessableEntityJsonException

See there: PROHIBITED_ORDER_STATUS_CHANGE .

409 VersionConflictJsonException

Occurs when we upload data to the server but server contains more fresh data than we send. No additional details provided. You should set actual "If-Match" header.

DELETE /v26/{sellerId}/orders/{orderId}

Delete order from the server.
sellerId Identifier of seller sellerIdType. May NOT be null.
orderId identifies entity identifierType. May NOT be null.

Request

DELETE /v26/se9876543210/orders/0-1 HTTP/1.1
Authorization: RestApiTester@se9876543210/CashTK:9999
Host: t.srv4pos.com

Response

HTTP/1.1 204 NO CONTENT

Errors

409 VersionConflictJsonException

Occurs when we upload data to the server but server contains more fresh data than we send. No additional details provided. You should set actual "If-Match" header.

GET /v26/{sellerId}/treasurers/{identifier}

Get latest information about seller from the server.
sellerId Identifier of seller sellerIdType. May NOT be null.
identifier Treasurer identifier identifierType. May NOT be null.

Request

GET /v26/se9876543210/treasurers/0-2U0Z HTTP/1.1
Authorization: RestApiTester@se9876543210:9999
Host: t.srv4pos.com

Response

HTTP/1.1 200 OK Content-Type: application/json;charset=UTF-8
{ 'deleted': false, // True if entity was deleted. Boolean. May NOT be null.
'identifier': '0-2U0Z', // identifierType. May NOT be null.
'name': 'test', // String. Minimum 1 characters. Maximum 32 characters. May NOT be null.
'ssn': '123423567', // Social security number of user. String. Maximum 16 characters. May NOT be null.
'custom': '', // String. Maximum 65535 characters.
'user': '', // User joined to treasurer. Readonly. String. May be null.
'pin': '8888' // Social security number of user. String. Maximum 16 characters. May NOT be null.
}

Errors

409 VersionConflictJsonException

Occurs when we upload data to the server but server contains more fresh data than we send. No additional details provided. You should set actual "If-Match" header.

404 NotFoundJsonException

When requested resource wasn't found.

PUT /v26/{sellerId}/treasurers/{identifier}

Put treasurer to the server.
sellerId Identifier of seller sellerIdType. May NOT be null.
identifier Treasurer identifier identifierType. May NOT be null.

Request

PUT /v26/se9876543210/treasurers/0-2U0Z HTTP/1.1 Content-Type: application/json
Authorization: RestApiTester@se9876543210:9999
Host: t.srv4pos.com { 'deleted': false, // Boolean.
'identifier': '0-2U0Z', // identifierType.
'name': 'test', // String. Minimum 1 characters. Maximum 32 characters.
'ssn': '123423567', // String. Minimum 1 characters. Maximum 16 characters.
'custom': '', // String. Maximum 65535 characters.
'pin': '9999' //
}

Response

HTTP/1.1 201 CREATED or HTTP/1.1 204 NO CONTENT

Errors

409 VersionConflictJsonException

Occurs when we upload data to the server but server contains more fresh data than we send. No additional details provided. You should set actual "If-Match" header.

POST /v26/{sellerId}/treasurers

Create treasurer on the server.
sellerId Identifier of seller sellerIdType. May NOT be null.

Request

POST /v26/se9876543210/treasurers HTTP/1.1 Content-Type: application/json
Authorization: RestApiTester@se9876543210:9999
Host: t.srv4pos.com { 'deleted': false, // Boolean.
'identifier': '0-2U0Z', // identifierType.
'name': 'test', // String. Minimum 1 characters. Maximum 32 characters.
'ssn': '123423567', // String. Minimum 1 characters. Maximum 16 characters.
'custom': '', // String. Maximum 65535 characters.
'pin': '9999' //
}

Response

HTTP/1.1 201 CREATED Content-Type: application/json;charset=UTF-8 /* Generated unique identifier. */
{/* Methods called "new" will return the identifier of newly created entity by using this class */ 'identifier': '0-ID' // identifierType. May NOT be null.
}

Errors

409 VersionConflictJsonException

Occurs when we upload data to the server but server contains more fresh data than we send. No additional details provided. You should set actual "If-Match" header.

DELETE /v26/{sellerId}/treasurers/{identifier}

Delete entity from the server.
sellerId Identifier of seller sellerIdType. May NOT be null.
identifier Treasurer identifier identifierType. May NOT be null.

Request

DELETE /v26/se9876543210/treasurers/0-2U0Z HTTP/1.1
Authorization: RestApiTester@se9876543210:9999
Host: t.srv4pos.com

Response

HTTP/1.1 204 NO CONTENT

Errors

404 NotFoundJsonException

When requested resource wasn't found.

GET /v26/{sellerId}/treasurers-diff/{versionFrom}/{versionTo}

Returns list of item changes between two versions.
sellerId Identifier of seller sellerIdType. May NOT be null.
versionFrom Min boundary version (included) for diff Integer. May NOT be null.
versionTo Max boundary version (included) for diff Integer. May NOT be null.

Request

GET /v26/se9876543210/treasurers-diff/0/9999 HTTP/1.1
Authorization: -:AbcDeFgqWertY1Mxxjl74rpocd2445hfV
Host: t.srv4pos.com

Response

HTTP/1.1 200 OK Content-Type: application/json;charset=UTF-8
{ 'deleted': false, // True if entity was deleted. Boolean. May NOT be null.
'identifier': '0-2U0Z', // identifierType. May NOT be null.
'name': 'test', // String. Minimum 1 characters. Maximum 32 characters. May NOT be null.
'ssn': '123423567', // Social security number of user. String. Maximum 16 characters. May NOT be null.
'custom': '', // String. Maximum 65535 characters.
'user': '', // User joined to treasurer. Readonly. String. May be null.
'pin': '8888' // Social security number of user. String. Maximum 16 characters. May NOT be null.
}

GET /v26/{sellerId}/treasurers

Returns list of entities.
sellerId Identifier of seller sellerIdType. May NOT be null.
orderByQuery param field to order by One of the following values: 'IDENTIFIER', 'NAME', 'SSN'. May be null.
orderDescQuery param field to direction of ordering Boolean. May be null.
firstResultQuery param when pagination starts or null Integer. May be null.
maxResultsQuery param amount of items per page or null Integer. May be null.
likeQuery param search string filter or null String. May be null.

Request

GET /v26/se9876543210/treasurers HTTP/1.1
Authorization: RestApiTester@se9876543210:9999
Host: t.srv4pos.com

Response

HTTP/1.1 200 OK Content-Type: application/json;charset=UTF-8
{ 'deleted': false, // True if entity was deleted. Boolean. May NOT be null.
'identifier': '0-2U0Z', // identifierType. May NOT be null.
'name': 'test', // String. Minimum 1 characters. Maximum 32 characters. May NOT be null.
'ssn': '123423567', // Social security number of user. String. Maximum 16 characters. May NOT be null.
'custom': '', // String. Maximum 65535 characters.
'user': '', // User joined to treasurer. Readonly. String. May be null.
'pin': '8888' // Social security number of user. String. Maximum 16 characters. May NOT be null.
}

GET /v26/{sellerId}/bookings/{identifier}

Gets booking.
sellerId Identifier of seller sellerIdType. May be null.
identifier Identifier of booking Integer. May be null.

Request

GET /v26/se9876543210/bookings/BOK1 HTTP/1.1
Authorization: RestApiTester@se9876543210:9999
Host: t.srv4pos.com

Response

HTTP/1.1 200 OK Content-Type: application/json;charset=UTF-8
{ 'identifier': 'BOK1', // identifierType. May be null.
'bookingDate': new Date().setHours(0,0,0,0), // Date: amount of milliseconds since UNIX epoch. May NOT be null.
'persons': 4, // Integer. May NOT be null.
'description': 'no solt in all dishes', // String. Maximum 1024 characters.
'contactInfo': {/* Information about person. */ 'name': 'Stefan', // Name of person who makes activation String. May NOT be null.
'phone': '56745325', // Phone number of person who requests activation String. May NOT be null.
'email': 'test@test.se' // Email of person who requests activation String. May NOT be null.
}, // A complex object. May NOT be null.
'deleted': 'false' // true if entity was deleted. May NOT be null.
}

Errors

404 NotFoundJsonException

If booking or seller wasn't found.

409 VersionConflictJsonException

Occurs when we upload data to the server but server contains more fresh data than we send. No additional details provided. You should set actual "If-Match" header.

403 ForbiddenJsonException

See there: INSUFFICIENT_ACCESS_RIGHTS .

PUT /v26/{sellerId}/bookings/{identifier}

Modifies booking.
sellerId Identifier of seller sellerIdType. May be null.
identifier Identifier of booking Integer. May be null.

Request

PUT /v26/se9876543210/bookings/BOK1 HTTP/1.1 Content-Type: application/json
Authorization: RestApiTester@se9876543210:9999
Host: t.srv4pos.com { 'identifier': 'BOK1', // identifierType. May be null.
'bookingDate': new Date().setHours(0,0,0,0), // Date: amount of milliseconds since UNIX epoch. May NOT be null.
'persons': 4, // Integer. May NOT be null.
'description': 'no solt in all dishes', // String. Maximum 1024 characters.
'contactInfo': {/* Information about person. */ 'name': 'Stefan', // Name of person who makes activation String. May NOT be null.
'phone': '56745325', // Phone number of person who requests activation String. May NOT be null.
'email': 'test@test.se' // Email of person who requests activation String. May NOT be null.
}, // A complex object. May NOT be null.
'deleted': 'false' // true if entity was deleted. May NOT be null.
}

Response

HTTP/1.1 204 NO CONTENT

Errors

404 NotFoundJsonException

If booking or seller wasn't found.

403 ForbiddenJsonException

See there: INSUFFICIENT_ACCESS_RIGHTS .

409 VersionConflictJsonException

Occurs when we upload data to the server but server contains more fresh data than we send. No additional details provided. You should set actual "If-Match" header.

POST /v26/{sellerId}/bookings

Create booking on the server.
sellerId Identifier of seller sellerIdType. May be null.

Request

POST /v26/se9876543210/bookings HTTP/1.1 Content-Type: application/json Host: t.srv4pos.com { 'identifier': null, // identifierType. May be null.
'bookingDate': new Date().setHours(0,0,0,0), // Date: amount of milliseconds since UNIX epoch. May NOT be null.
'persons': 4, // Integer. May NOT be null.
'description': 'no solt in all dishes', // String. Maximum 1024 characters.
'contactInfo': {/* Information about person. */ 'name': 'Stefan', // Name of person who makes activation String. May NOT be null.
'phone': '56745325', // Phone number of person who requests activation String. May NOT be null.
'email': 'test@test.se' // Email of person who requests activation String. May NOT be null.
}, // A complex object. May NOT be null.
'deleted': 'false' // true if entity was deleted. May NOT be null.
}

Response

HTTP/1.1 201 CREATED Content-Type: application/json;charset=UTF-8 /* Generated unique identifier. */
{/* Methods called "new" will return the identifier of newly created entity by using this class */ 'identifier': '0-ID' // identifierType. May NOT be null.
}

Errors

404 NotFoundJsonException

If seller wasn't found.

409 VersionConflictJsonException

Occurs when we upload data to the server but server contains more fresh data than we send. No additional details provided. You should set actual "If-Match" header.

DELETE /v26/{sellerId}/bookings/{identifier}

Delete booking from the server.
sellerId Identifier of seller sellerIdType. May be null.
identifier Identifier of booking Integer. May be null.

Request

DELETE /v26/se9876543210/bookings/BOK1 HTTP/1.1
Authorization: RestApiTester@se9876543210:9999
Host: t.srv4pos.com

Response

HTTP/1.1 204 NO CONTENT

Errors

404 NotFoundJsonException

If booking or seller wasn't found.

403 ForbiddenJsonException

See there: INSUFFICIENT_ACCESS_RIGHTS .

409 VersionConflictJsonException

Occurs when we upload data to the server but server contains more fresh data than we send. No additional details provided. You should set actual "If-Match" header.

GET /v26/{sellerId}/bookings

Get information about booking from the server.
sellerId Identifier of seller sellerIdType. May be null.
firstResultQuery param when pagination starts or null Integer. May be null.
maxResultsQuery param amount of items per page or null Integer. May be null.
likeQuery param search string filter or null String. May be null.
orderByQuery param field to order by One of the following values: 'IDENTIFIER', 'BOOKING_DATE'. May be null.
orderDescQuery param field to direction of ordering Boolean. May be null.

Request

GET /v26/se9876543210/bookings HTTP/1.1
Authorization: RestApiTester@se9876543210:9999
Host: t.srv4pos.com

Response

HTTP/1.1 200 OK Content-Type: application/json;charset=UTF-8
{ 'identifier': 'BOK1', // identifierType. May be null.
'bookingDate': new Date().setHours(0,0,0,0), // Date: amount of milliseconds since UNIX epoch. May NOT be null.
'persons': 4, // Integer. May NOT be null.
'description': 'no solt in all dishes', // String. Maximum 1024 characters.
'contactInfo': {/* Information about person. */ 'name': 'Stefan', // Name of person who makes activation String. May NOT be null.
'phone': '56745325', // Phone number of person who requests activation String. May NOT be null.
'email': 'test@test.se' // Email of person who requests activation String. May NOT be null.
}, // A complex object. May NOT be null.
'deleted': 'false' // true if entity was deleted. May NOT be null.
}

GET /v26/{sellerId}/bookings-diff/{versionFrom}/{versionTo}

Returns list of item changes between two versions.
sellerId Identifier of seller sellerIdType. May NOT be null.
versionFrom Min boundary version (included) for diff Integer. May NOT be null.
versionTo Max boundary version (included) for diff Integer. May NOT be null.

Request

GET /v26/se9876543210/bookings-diff/0/9999 HTTP/1.1
Authorization: RestApiTester@se9876543210:9999
Host: t.srv4pos.com

Response

HTTP/1.1 200 OK Content-Type: application/json;charset=UTF-8
{ 'identifier': 'BOK1', // identifierType. May be null.
'bookingDate': new Date().setHours(0,0,0,0), // Date: amount of milliseconds since UNIX epoch. May NOT be null.
'persons': 4, // Integer. May NOT be null.
'description': 'no solt in all dishes', // String. Maximum 1024 characters.
'contactInfo': {/* Information about person. */ 'name': 'Stefan', // Name of person who makes activation String. May NOT be null.
'phone': '56745325', // Phone number of person who requests activation String. May NOT be null.
'email': 'test@test.se' // Email of person who requests activation String. May NOT be null.
}, // A complex object. May NOT be null.
'deleted': 'false' // true if entity was deleted. May NOT be null.
}

GET /v26/{sellerId}/registrations

Returns list of registrations.
sellerId Identifier of seller sellerIdType. May NOT be null.
orderByQuery param field to order by One of the following values: 'CASH_REGISTER_NAME', 'CREATION_DATE'. May be null.
orderDescQuery param field to direction of ordering Boolean. May be null.
activeOnlyQuery param True if need only active registrations, otherwise all registrations Boolean. May be null.
firstResultQuery param when pagination starts or null Integer. May be null.
maxResultsQuery param amount of items per page or null Integer. May be null.

Request

GET /v26/se9876543210/registrations HTTP/1.1
Authorization: RestApiTester@se9876543210/CashTK:9999
Host: t.srv4pos.com

Response

HTTP/1.1 200 OK Content-Type: application/json;charset=UTF-8
{ 'id': 654, // Deprecated. Please identify by country, corporateId and cashRegisterName. Integer. May NOT be null.
'cashRegisterName': 'cash name', // String. Maximum 16 characters. May NOT be null.
'country': 'se', // String. Minimum 2 characters. Maximum 2 characters. May NOT be null.
'corporateId': '345342356', // corporateIdType. May NOT be null.
'productionNumber': 'TEST100000000000000000081' // productionNumberType. May be null.
}

GET /v26/{sellerId}/registrations-advanced

Returns list of registrations advanced.
sellerId Identifier of seller sellerIdType. May NOT be null.
orderByQuery param field to order by One of the following values: 'CASH_REGISTER_NAME', 'CREATION_DATE'. May be null.
orderDescQuery param field to direction of ordering Boolean. May be null.
activeOnlyQuery param True if need only active registrations, otherwise all registrations Boolean. May be null.
firstResultQuery param when pagination starts or null Integer. May be null.
maxResultsQuery param amount of items per page or null Integer. May be null.

Request

GET /v26/se9876543210/registrations-advanced HTTP/1.1
Authorization: RestApiTester@se9876543210/CashTK:9999
Host: t.srv4pos.com

Response

HTTP/1.1 200 OK Content-Type: application/json;charset=UTF-8
[ {/* Represents server-side entity available for admin. */ 'registrationInfo': { 'id': 654, // Deprecated. Please identify by country, corporateId and cashRegisterName. Integer. May NOT be null.
'cashRegisterName': 'cash name', // String. Maximum 16 characters. May NOT be null.
'country': 'se', // String. Minimum 2 characters. Maximum 2 characters. May NOT be null.
'corporateId': '345342356', // corporateIdType. May NOT be null.
'productionNumber': '' // productionNumberType. May be null.
}, // A complex object. May NOT be null.
'sellerInfo': { 'corporateId': '9876543210', // corporateIdType. May NOT be null.
'name': 'CompanyName', // String. Maximum 96 characters. May be null.
'country': 'se', // countryType. May NOT be null.
'publicAccess': true, // Boolean. May NOT be null.
'description': 'description', // String. Maximum 1024 characters. May be null.
'city': 'Koenig', // String. Maximum 255 characters. May be null.
'workHours': '24', // String. Maximum 255 characters. May be null.
'workHoursWeek': { 'MONDAY': {/* Describes work hours of specific day of week. */ 'dayOfWeek': 'TUESDAY', // dayOfWeek. May NOT be null.
'openTime': 600, // Describes the number of minutes since midnight. Integer. Minimum 0. Maximum 1920.
'closeTime': 1200 // Describes the number of minutes since midnight. Integer. Minimum 0. Maximum 1920.
}, // A complex object. May be null.
'TUESDAY': {/* Describes work hours of specific day of week. */ 'dayOfWeek': 'TUESDAY', // dayOfWeek. May NOT be null.
'openTime': 600, // Describes the number of minutes since midnight. Integer. Minimum 0. Maximum 1920.
'closeTime': 1200 // Describes the number of minutes since midnight. Integer. Minimum 0. Maximum 1920.
}, // A complex object. May be null.
'WEDNESDAY': {/* Describes work hours of specific day of week. */ 'dayOfWeek': 'TUESDAY', // dayOfWeek. May NOT be null.
'openTime': 600, // Describes the number of minutes since midnight. Integer. Minimum 0. Maximum 1920.
'closeTime': 1200 // Describes the number of minutes since midnight. Integer. Minimum 0. Maximum 1920.
}, // A complex object. May be null.
'THURSDAY': {/* Describes work hours of specific day of week. */ 'dayOfWeek': 'TUESDAY', // dayOfWeek. May NOT be null.
'openTime': 600, // Describes the number of minutes since midnight. Integer. Minimum 0. Maximum 1920.
'closeTime': 1200 // Describes the number of minutes since midnight. Integer. Minimum 0. Maximum 1920.
}, // A complex object. May be null.
'FRIDAY': {/* Describes work hours of specific day of week. */ 'dayOfWeek': 'TUESDAY', // dayOfWeek. May NOT be null.
'openTime': 600, // Describes the number of minutes since midnight. Integer. Minimum 0. Maximum 1920.
'closeTime': 1200 // Describes the number of minutes since midnight. Integer. Minimum 0. Maximum 1920.
}, // A complex object. May be null.
'SATURDAY': {/* Describes work hours of specific day of week. */ 'dayOfWeek': 'TUESDAY', // dayOfWeek. May NOT be null.
'openTime': 600, // Describes the number of minutes since midnight. Integer. Minimum 0. Maximum 1920.
'closeTime': 1200 // Describes the number of minutes since midnight. Integer. Minimum 0. Maximum 1920.
}, // A complex object. May be null.
'SUNDAY': {/* Describes work hours of specific day of week. */ 'dayOfWeek': 'TUESDAY', // dayOfWeek. May NOT be null.
'openTime': 600, // Describes the number of minutes since midnight. Integer. Minimum 0. Maximum 1920.
'closeTime': 1200 // Describes the number of minutes since midnight. Integer. Minimum 0. Maximum 1920.
} // A complex object. May be null.
}, // A complex object. May NOT be null.
'address': 'Address 1', // String. Maximum 500 characters. May be null.
'phone': '89814532074', // String. Maximum 255 characters. May be null.
'custom': 'some text', // String. Maximum 65535 characters. May be null.
'currency': 'SEK', // currencyType. May be null.
'masterPassword': '9999' // String. Minimum 1 characters. Maximum 64 characters. May be null.
}, // A complex object. May NOT be null.
'installationInfo': {/* This entity provides info about android device. */ 'installationInfo': { 'id': 654353, // Deprecated, please use productionNumber Integer. May be null.
'deviceId': '111AAA222BBB3-022', // deviceIdType. May NOT be null.
'buildInfo': {'KEY1':'VALUE1', 'KEY2':'VALUE2'}, // A complex object. May NOT be null.
'applicationPackage': 'package', // applicationPackageType. May NOT be null.
'gcmRegistrationId': '123', // String. Minimum 1 characters.
'productionNumber': 'TEST100000000000000000081', // productionNumberType.
'registrationDate': 45672345, // Date: amount of milliseconds since UNIX epoch.
'gcmUnsubscribeDate': 45672345 // Date: amount of milliseconds since UNIX epoch.
}, // A complex object.
'deviceInfo': {/* This entity provides info about android device. */ 'id': 5432, // Integer.
'deviceId': '34565673' // deviceIdType. May NOT be null.
}, // A complex object.
'applicationDescriptionInfo': {/* Information about person. */ 'applicationPackage': 'super.package', // applicationPackageType.
'productionNumberPrefix': 'PRENP', // String.
'controlUnitRequired': true, // Boolean.
'name': 'Super application', // String.
'softwareVendor': 2, // Integer.
'autoActivationCondition': 'NEVER', // autoActivationConditionType.
'corporateIdValidationMethod': 'NONE' // corporateIdValidationMethodType.
}, // A complex object.
'buildInfoes': [ {/* Information about android device taken from android.os.Build. */ 'name': '', // String. Maximum 25 characters. May NOT be null.
'value': '', // String. Maximum 1024 characters. May NOT be null.
'installation': '' // String. May NOT be null.
} ], // List of objects.
'registrationOverviewInfoes': [ {/* Represents server-side entity available for admin. */ 'registrationId': , // Integer.
'cashRegisterName': 'cash name', // String. Maximum 16 characters. May NOT be null.
'sellerOverviewInfo': { 'name': 'CompanyName', // String. Maximum 96 characters. May be null.
'country': 'se', // countryType. May NOT be null.
'corporateId': '9876543210', // corporateIdType. May NOT be null.
'currency': 'SEK', // currencyType. May be null.
'countActiveCashRegisters': , // Integer.
'turnover': // Integer.
} // A complex object. May NOT be null.
} ] // List of objects.
} // A complex object. May NOT be null.
} ]

GET /v26/{sellerId}/registrations/stats

Returns list of registrations.
sellerId Identifier of seller sellerIdType. May NOT be null.
periodQuery param filters by date period String. May be null.

Request

GET /v26/se9876543210/registrations/stats HTTP/1.1
Authorization: RestApiTester@se9876543210/CashTK:9999
Host: t.srv4pos.com

Response

HTTP/1.1 200 OK Content-Type: application/json;charset=UTF-8
[ {/* Represents stats for cash registers by total brutto. */ 'cashRegisterName': 'Cash22', // cashRegisterNameType. May NOT be null.
'total': 1200 // Total stats by sales brutto. Integer. Minimum 0.
} ]

Errors

400 TypeMismatchJsonException

If passed date period has incorrect format.

GET /v26/{sellerId}/registrations/{cashRegisterName}/balance

Returns balance of cash register.
sellerId Identifier of seller sellerIdType. May NOT be null.
cashRegisterNamecashRegisterNameType. May NOT be null.

Request

GET /v26/se9876543210/registrations/CashTK/balance HTTP/1.1
Authorization: RestApiTester@se9876543210/CashTK:9999
If-Match: "0" // Value should be taken from /{sellerId}.
Host: t.srv4pos.com

Response

HTTP/1.1 200 OK Content-Type: application/json;charset=UTF-8
{ 'amount': 10000 // Amount of money in the cash register. Integer. Minimum 0. May NOT be null.
}

Errors

404 ReferenceNotFoundJsonException

If cashRegisterName wasn't found.

422 UnprocessableEntityJsonException

See there: DAY_IS_CLOSED, DAY_IS_NOT_CLOSED, REPORT_IS_NOT_PRINTED .

POST /v26/{sellerId}/registrations/{cashRegisterName}/balance

Set cash register balance.
sellerId Identifier of seller sellerIdType. May NOT be null.
cashRegisterNamecashRegisterNameType. May NOT be null.

Request

POST /v26/se9876543210/registrations/CashTK/balance HTTP/1.1 Content-Type: application/json
Authorization: RestApiTester@se9876543210/CashTK:9999
If-Match: "0-0" // Value consists of two parts separated by dash: first part is the seller version from /{sellerId} and second part is the cash register version from .
Host: t.srv4pos.com { 'amount': 10000, // Amount of money. Integer. Minimum 0. May NOT be null.
'action': 'DEPOSIT' // Action. changeBalanceActionType. May NOT be null.
}

Response

HTTP/1.1 201 CREATED

Errors

422 UnprocessableEntityJsonException

See there: DAY_IS_CLOSED, DAY_IS_NOT_CLOSED, REPORT_IS_NOT_PRINTED .

GET /v26/{sellerId}/registrations/{cashRegisterName}

Get registration from the server.
sellerId Identifier of seller sellerIdType. May NOT be null.
cashRegisterName cash register name String. May NOT be null.

Request

GET /v26/se9876543210/registrations/Cash1 HTTP/1.1
Authorization: RestApiTester@se9876543210:9999
Host: t.srv4pos.com

Response

HTTP/1.1 200 OK Content-Type: application/json;charset=UTF-8
{ 'cashRegisterName': '', // cashRegisterNameType. May NOT be null.
'sellerOverviewInfo': { 'name': 'CompanyName', // String. Maximum 96 characters. May be null.
'country': 'se', // countryType. May NOT be null.
'corporateId': '9876543210', // corporateIdType. May NOT be null.
'currency': 'SEK', // currencyType. May be null.
'countActiveCashRegisters': , // Integer.
'turnover': // Integer.
}, // A complex object. May NOT be null.
'applicationName': '', // String. Maximum 64 characters. May NOT be null.
'installationInfo': { 'id': 654353, // Deprecated, please use productionNumber Integer. May be null.
'deviceId': '111AAA222BBB3-022', // deviceIdType. May NOT be null.
'buildInfo': {'KEY1':'VALUE1', 'KEY2':'VALUE2'}, // A complex object. May NOT be null.
'applicationPackage': 'package', // applicationPackageType. May NOT be null.
'gcmRegistrationId': '123', // String. Minimum 1 characters.
'productionNumber': 'TEST100000000000000000081', // productionNumberType.
'registrationDate': 45672345, // Date: amount of milliseconds since UNIX epoch.
'gcmUnsubscribeDate': 45672345 // Date: amount of milliseconds since UNIX epoch.
}, // A complex object. May be null.
'deviceInfo': {/* This entity provides info about android device. */ 'id': 5432, // Integer.
'deviceId': '34565673' // deviceIdType. May NOT be null.
}, // A complex object. May be null.
'buildInfoes': [ {/* Information about android device taken from android.os.Build. */ 'name': '', // String. Maximum 25 characters. May NOT be null.
'value': '', // String. Maximum 1024 characters. May NOT be null.
'installation': '' // String. May NOT be null.
} ], // List of objects. May be null.
'sellersAtSameInstallation': [ { 'name': 'CompanyName', // String. Maximum 96 characters. May be null.
'country': 'se', // countryType. May NOT be null.
'corporateId': '9876543210', // corporateIdType. May NOT be null.
'currency': 'SEK', // currencyType. May be null.
'countActiveCashRegisters': , // Integer.
'turnover': // Integer.
} ], // List of objects. May be null.
'controlUnitSerial': '', // String. Minimum 1 characters. Maximum 20 characters. May NOT be null.
'activationInfo': '', // May NOT be null.
'activationsAtSameRegistration': [ { 'name': 'CompanyName', // String. Maximum 96 characters. May be null.
'country': 'se', // countryType. May NOT be null.
'corporateId': '9876543210', // corporateIdType. May NOT be null.
'currency': 'SEK', // currencyType. May be null.
'countActiveCashRegisters': , // Integer.
'turnover': // Integer.
} ] // List of objects. May NOT be null.
}

Errors

409 VersionConflictJsonException

Occurs when we upload data to the server but server contains more fresh data than we send. No additional details provided. You should set actual "If-Match" header.

DELETE /v26/{sellerId}/registrations/{cashRegisterName}

Delete registration from the server.
sellerId Identifier of seller sellerIdType. May NOT be null.
cashRegisterName cash register name String. May NOT be null.

Request

DELETE /v26/se9876543210/registrations/Cash1 HTTP/1.1
Authorization: RestApiTester@se9876543210:9999
Host: t.srv4pos.com

Response

HTTP/1.1 204 NO CONTENT

Errors

409 VersionConflictJsonException

Occurs when we upload data to the server but server contains more fresh data than we send. No additional details provided. You should set actual "If-Match" header.

GET /v26/{sellerId}/registrations/{cashRegisterName}/version

Gets actual cash register version.
sellerIdsellerIdType. May NOT be null.
cashRegisterNameMay NOT be null.

Request

GET /v26/se9876543210/registrations/CashTK/version HTTP/1.1
Authorization: RestApiTester@se9876543210/CashTK:9999
Host: t.srv4pos.com

Response

HTTP/1.1 200 OK Content-Type: application/json;charset=UTF-8
{ 'version': 0 // Version number. Integer. Minimum 0. May NOT be null.
}

Errors

404 ReferenceNotFoundJsonException

If cash register wasn't found.

POST /v26/{sellerId}/registrations/{cashRegisterName}/sales

Create sale on the server. Only for thin kassan registrations.
sellerIdsellerIdType. May NOT be null.
cashRegisterNameMay NOT be null.

Request

POST /v26/se9876543210/registrations/CashTK/sales HTTP/1.1 Content-Type: application/json
Authorization: RestApiTester@se9876543210/CashTK:9999
If-Match: "0-0" // Value consists of two parts separated by dash: first part is the seller version from /{sellerId} and second part is the cash register version from .
Host: t.srv4pos.com { 'identifier': '', // identifierType. May be null.
'sellerIdentifier': 'se9876543210', // Seller identifier. identifierType. May NOT be null.
'saleState': 'Open', // Sale identifier. saleStateType. May NOT be null.
'refund': true, // True if it is a refund sale. Boolean. May NOT be null.
'refundFor': 123, // Identifier of refunded sale. Integer. May be null.
'absoluteDiscount': 0, // Sale absolute discount. Must be 0 if relativeDiscount is not 0. Integer. May NOT be null.
'relativeDiscount': 1000, // Sale relative discount. Must be 0 if absoluteDiscount is not 0. Integer. May NOT be null.
'vanillaBrutto': 37000, // Sum of product brutto. Integer. May NOT be null.
'discount': 3700, // Sale discount. discount = relativeDiscount != 0 ? vanillaBrutto / (1 + relativeDiscount) : absoluteDiscount Integer. May NOT be null.
'brutto': 33300, // Total sale brutto. Integer. May NOT be null.
'vat': 6660, // Total sale VAT. Integer. May NOT be null.
'controlUnitId': '123456', // Control unit Id. String. May be null.
'day': '', // Day identifer String. May be null.
'treasurer': '0-ABCD', // Treasurer name identifierType. May be null.
'close': new Date().setHours(0,0,0,0), // Close receipt date Date: amount of milliseconds since UNIX epoch. May be null.
'saleProducts': [ { 'productIdentifier': 'PRODUCT1', // Product identifier. String. May NOT be null.
'deltaUnit': false, // Boolean. May NOT be null.
'delta': 300, // The amount of products. Integer. May NOT be null.
'absoluteDiscount': 500, // Absolute discount. Must be 0 if relativeDiscount is not 0 Integer. May NOT be null.
'relativeDiscount': 0, // Relative discount. Must be 0 if absoluteDiscount is not 0 Integer. May NOT be null.
'vat': 7400, // Value-added tax. vat = brutto - brutto * 100000 / (10000 + vatRate) / 10 Integer.
'netto': 29600, // Product price without tax. netto = round(brutto * 100000 / (10000 + vatRate)) Integer.
'brutto': 37500, // Sale product price with tax. brutto = vanillaBrutto - discount Integer.
'productBrutto': 12500, // Brutto of product unit. Integer.
'vatRate': 25, // VAT rate of product. Integer.
'effectiveBrutto': 33300, // Sum of brutto of all products with sale discount. effectiveBrutto = sale#relativeDiscount} != 0 ? brutto * (10000 - sale#relativeDiscount / 10000) * : {brutto - (sale#absoluteDiscount * brutto * 10 / {sale#brutto} / 10) Integer.
'vanillaBrutto': 37500, // Sum of brutto of all products. vanillaBrutto = deltaUnit == 1 ? round(brutto * delta / 100) : delta Integer.
'discount': 500, // Sale product discount. discount = relativeDiscount != 0 ? vanillaBrutto / (1 + relativeDiscount) : absoluteDiscount Integer.
'created': 1414800000001 // Created date. Date: amount of milliseconds since UNIX epoch.
} ], // List of objects.
'prints': [ { 'receiptNumber': 1234, // Integer.
'printType': 'Normal', // printType.
'deliveryType': 'Print', // deliveryType.
'controlNumber': '123456789', // String.
'created': 1414800000001, // Created date. Integer.
'printed': false // Printed date Boolean.
} ], // List of objects.
'payments': [ { 'paymentType': 'Cash', // paymentType.
'amount': 100, // Integer.
'paymentState': 'SENDING' // paymentStateType.
} ], // List of objects.
'vatRateSums': [ { 'vatRate': 2500, // Integer.
'vanillaVat': 7400, // Total vat of all products. Integer.
'vanillaNetto': 29600, // Total netto of all products. Integer.
'vanillaBrutto': 37000, // Total brutto of all products. Integer.
'vat': 6600, // Total vat of all products with sale discount. vat = brutto - netto Integer.
'netto': 26640, // total netto of all products with sale discount. netto = round(brutto * 100000 / (10000 + vatRate) / 10) Integer.
'brutto': 33000 // total brutto of all products with sale discount. brutto = relativeDiscount == 0 ? round(Brutto - absoluteDiscount * vanillaBrutto * 10 / vanillaBrutto / 10) : round(vanillaBrutto * (10000 - relativeDiscount) / 10000) Integer.
} ] // List of objects.
}

Response

HTTP/1.1 201 CREATED Content-Type: application/json;charset=UTF-8
{/* Generated unique identifier. */ 'identifier': '0-ID' // identifierType. May NOT be null.
}

Errors

404 ReferenceNotFoundJsonException

entity "ControlUnit": if control unit is required for the application and the activation has the feature CONTROL_UNIT, but control unit with id controlUnitId is not found.

409 VersionConflictJsonException

Occurs when we upload data to the server but server contains more fresh data than we send. No additional details provided. You should set actual "If-Match" header.

422 UnprocessableEntityJsonException

See there: DAY_IS_CLOSED, DAY_IS_NOT_CLOSED, REPORT_IS_NOT_PRINTED .

PUT /v26/{sellerId}/registrations/{cashRegisterName}/sales

Create or modifies sale on the server.
sellerIdsellerIdType. May NOT be null.
cashRegisterNameMay NOT be null.

Request

PUT /v26/se9876543210/registrations/CashTK/sales HTTP/1.1 Content-Type: application/json
Authorization: RestApiTester@se9876543210/CashTK:9999
If-Match: "0-0" // Value consists of two parts separated by dash: first part is the seller version from /{sellerId} and second part is the cash register version from .
Host: t.srv4pos.com { 'identifier': '', // identifierType. May be null.
'sellerIdentifier': 'se9876543210', // Seller identifier. identifierType. May NOT be null.
'saleState': 'Open', // Sale identifier. saleStateType. May NOT be null.
'refund': true, // True if it is a refund sale. Boolean. May NOT be null.
'refundFor': 123, // Identifier of refunded sale. Integer. May be null.
'absoluteDiscount': 0, // Sale absolute discount. Must be 0 if relativeDiscount is not 0. Integer. May NOT be null.
'relativeDiscount': 1000, // Sale relative discount. Must be 0 if absoluteDiscount is not 0. Integer. May NOT be null.
'vanillaBrutto': 37000, // Sum of product brutto. Integer. May NOT be null.
'discount': 3700, // Sale discount. discount = relativeDiscount != 0 ? vanillaBrutto / (1 + relativeDiscount) : absoluteDiscount Integer. May NOT be null.
'brutto': 33300, // Total sale brutto. Integer. May NOT be null.
'vat': 6660, // Total sale VAT. Integer. May NOT be null.
'controlUnitId': '123456', // Control unit Id. String. May be null.
'day': '', // Day identifer String. May be null.
'treasurer': '0-ABCD', // Treasurer name identifierType. May be null.
'close': new Date().setHours(0,0,0,0), // Close receipt date Date: amount of milliseconds since UNIX epoch. May be null.
'saleProducts': [ { 'productIdentifier': 'PRODUCT1', // Product identifier. String. May NOT be null.
'deltaUnit': false, // Boolean. May NOT be null.
'delta': 300, // The amount of products. Integer. May NOT be null.
'absoluteDiscount': 500, // Absolute discount. Must be 0 if relativeDiscount is not 0 Integer. May NOT be null.
'relativeDiscount': 0, // Relative discount. Must be 0 if absoluteDiscount is not 0 Integer. May NOT be null.
'vat': 7400, // Value-added tax. vat = brutto - brutto * 100000 / (10000 + vatRate) / 10 Integer.
'netto': 29600, // Product price without tax. netto = round(brutto * 100000 / (10000 + vatRate)) Integer.
'brutto': 37500, // Sale product price with tax. brutto = vanillaBrutto - discount Integer.
'productBrutto': 12500, // Brutto of product unit. Integer.
'vatRate': 25, // VAT rate of product. Integer.
'effectiveBrutto': 33300, // Sum of brutto of all products with sale discount. effectiveBrutto = sale#relativeDiscount} != 0 ? brutto * (10000 - sale#relativeDiscount / 10000) * : {brutto - (sale#absoluteDiscount * brutto * 10 / {sale#brutto} / 10) Integer.
'vanillaBrutto': 37500, // Sum of brutto of all products. vanillaBrutto = deltaUnit == 1 ? round(brutto * delta / 100) : delta Integer.
'discount': 500, // Sale product discount. discount = relativeDiscount != 0 ? vanillaBrutto / (1 + relativeDiscount) : absoluteDiscount Integer.
'created': 1414800000001 // Created date. Date: amount of milliseconds since UNIX epoch.
} ], // List of objects.
'prints': [ { 'receiptNumber': 1234, // Integer.
'printType': 'Normal', // printType.
'deliveryType': 'Print', // deliveryType.
'controlNumber': '123456789', // String.
'created': 1414800000001, // Created date. Integer.
'printed': false // Printed date Boolean.
} ], // List of objects.
'payments': [ { 'paymentType': 'Cash', // paymentType.
'amount': 100, // Integer.
'paymentState': 'SENDING' // paymentStateType.
} ], // List of objects.
'vatRateSums': [ { 'vatRate': 2500, // Integer.
'vanillaVat': 7400, // Total vat of all products. Integer.
'vanillaNetto': 29600, // Total netto of all products. Integer.
'vanillaBrutto': 37000, // Total brutto of all products. Integer.
'vat': 6600, // Total vat of all products with sale discount. vat = brutto - netto Integer.
'netto': 26640, // total netto of all products with sale discount. netto = round(brutto * 100000 / (10000 + vatRate) / 10) Integer.
'brutto': 33000 // total brutto of all products with sale discount. brutto = relativeDiscount == 0 ? round(Brutto - absoluteDiscount * vanillaBrutto * 10 / vanillaBrutto / 10) : round(vanillaBrutto * (10000 - relativeDiscount) / 10000) Integer.
} ] // List of objects.
}

Response

HTTP/1.1 204 NO CONTENT Content-Type: application/json;charset=UTF-8
{/* Generated unique identifier. */ 'identifier': '0-ID' // identifierType. May NOT be null.
}

Errors

404 ReferenceNotFoundJsonException

entity "ControlUnit": if control unit is required for the application and the activation has the feature CONTROL_UNIT, but control unit with id controlUnitId is not found.

409 VersionConflictJsonException

Occurs when we upload data to the server but server contains more fresh data than we send. No additional details provided. You should set actual "If-Match" header.

422 UnprocessableEntityJsonException

See there: DAY_IS_CLOSED, DAY_IS_NOT_CLOSED, REPORT_IS_NOT_PRINTED .

GET /v26/{sellerId}/registrations/{cashRegisterName}/sales/{identifier}/receipt

Return current receipt.
sellerIdsellerIdType. May NOT be null.
cashRegisterNameMay NOT be null.
identifier identifies sale identifierType. May NOT be null.

Request

GET /v26/se9876543210/registrations/CashTK/sales/40/receipt HTTP/1.1
Accept: text/html
Authorization: RestApiTester@se9876543210/CashTK:9999
Host: t.srv4pos.com

Response

HTTP/1.1 200 OK

POST /v26/{sellerId}/registrations/{cashRegisterName}/sales/{identifier}/receipt

Confirm current receipt print.
sellerIdsellerIdType. May NOT be null.
cashRegisterNameMay NOT be null.
identifier identifies sale identifierType. May NOT be null.

Request

POST /v26/se9876543210/registrations/CashTK/sales/40/receipt HTTP/1.1
Authorization: RestApiTester@se9876543210/CashTK:9999
If-Match: "0-0" // Value consists of two parts separated by dash: first part is the seller version from /{sellerId} and second part is the cash register version from .
Host: t.srv4pos.com

Response

HTTP/1.1 204 NO CONTENT

Errors

422 UnprocessableEntityJsonException

See there: DAY_IS_NOT_CLOSED, RECEIPT_IS_PRINTED_ALREADY .

GET /v26/{sellerId}/registrations/{cashRegisterName}/sales/{saleId}/copy

Returns receipt copy.
sellerIdsellerIdType. May NOT be null.
cashRegisterNameMay NOT be null.
saleId identifies sale identifierType. May NOT be null.

Request

GET /v26/se9876543210/registrations/CashTK/sales/40/copy HTTP/1.1
Authorization: RestApiTester@se9876543210/CashTK:9999
Accept: text/html
Host: t.srv4pos.com

Response

HTTP/1.1 200 OK

Errors

404 NotFoundJsonException

If sale haven't any print.

GET /v26/{sellerId}/registrations/{cashRegisterName}/sales-diff/{versionFrom}/{versionTo}

Returns list of item changes between two versions.
sellerId Identifier of seller sellerIdType. May NOT be null.
cashRegisterNameMay NOT be null.
versionFrom Min boundary registration version (included) for diff Integer. May NOT be null.
versionTo Max boundary registration version (included) for diff Integer. May NOT be null.

Request

GET /v26/se9876543210/registrations/CashTK/sales-diff/0/9999 HTTP/1.1 Host: t.srv4pos.com

Response

HTTP/1.1 200 OK Content-Type: application/json;charset=UTF-8 /* return list of items to be added. */
{ 'identifier': '', // identifierType. May be null.
'sellerIdentifier': 'se9876543210', // Seller identifier. identifierType. May NOT be null.
'saleState': 'Open', // Sale identifier. saleStateType. May NOT be null.
'refund': true, // True if it is a refund sale. Boolean. May NOT be null.
'refundFor': 10, // Identifier of refunded sale. Integer. May be null.
'absoluteDiscount': 0, // Sale absolute discount. Must be 0 if relativeDiscount is not 0. Integer. May NOT be null.
'relativeDiscount': 50, // Sale relative discount. Must be 0 if absoluteDiscount is not 0. Integer. May NOT be null.
'vanillaBrutto': 100, // Sum of product brutto. Integer. May NOT be null.
'discount': 100, // Sale discount. discount = relativeDiscount != 0 ? vanillaBrutto / (1 + relativeDiscount) : absoluteDiscount Integer. May NOT be null.
'brutto': 50, // Total sale brutto. Integer. May NOT be null.
'vat': 25, // Total sale VAT. Integer. May NOT be null.
'controlUnitId': '123456', // Control unit Id. String. May be null.
'day': '0-DCBA', // Day identifer String. May be null.
'treasurer': '0-ABCD', // Treasurer name identifierType. May be null.
'close': new Date().setHours(0,0,0,0), // Close receipt date Date: amount of milliseconds since UNIX epoch. May be null.
'saleProducts': [ { 'productIdentifier': 'PRODUCT1', // Product identifier. String. May NOT be null.
'deltaUnit': false, // Boolean. May NOT be null.
'delta': 10, // The amount of products. Integer. May NOT be null.
'absoluteDiscount': 0, // Absolute discount. Must be 0 if relativeDiscount is not 0 Integer. May NOT be null.
'relativeDiscount': 50, // Relative discount. Must be 0 if absoluteDiscount is not 0 Integer. May NOT be null.
'vat': 25, // Value-added tax. vat = brutto - brutto * 100000 / (10000 + vatRate) / 10 Integer.
'netto': 100, // Product price without tax. netto = round(brutto * 100000 / (10000 + vatRate)) Integer.
'brutto': 125, // Sale product price with tax. brutto = vanillaBrutto - discount Integer.
'productBrutto': 12, // Brutto of product unit. Integer.
'vatRate': 50, // VAT rate of product. Integer.
'effectiveBrutto': 125, // Sum of brutto of all products with sale discount. effectiveBrutto = sale#relativeDiscount} != 0 ? brutto * (10000 - sale#relativeDiscount / 10000) * : {brutto - (sale#absoluteDiscount * brutto * 10 / {sale#brutto} / 10) Integer.
'vanillaBrutto': 125, // Sum of brutto of all products. vanillaBrutto = deltaUnit == 1 ? round(brutto * delta / 100) : delta Integer.
'discount': 50, // Sale product discount. discount = relativeDiscount != 0 ? vanillaBrutto / (1 + relativeDiscount) : absoluteDiscount Integer.
'created': 1414800000001 // Created date. Date: amount of milliseconds since UNIX epoch.
} ], // List of objects.
'prints': [ { 'receiptNumber': 1234, // Integer.
'printType': 'Normal', // printType.
'deliveryType': 'Print', // deliveryType.
'controlNumber': '123456789', // String.
'created': 1414800000001, // Created date. Integer.
'printed': false // Printed date Boolean.
} ], // List of objects.
'payments': [ { 'paymentType': 'Cash', // paymentType.
'amount': 100, // Integer.
'paymentState': 'SENDING' // paymentStateType.
} ], // List of objects.
'vatRateSums': [ { 'vatRate': 50, // Integer.
'vanillaVat': 5000, // Total vat of all products. Integer.
'vanillaNetto': 5000, // Total netto of all products. Integer.
'vanillaBrutto': 10000, // Total brutto of all products. Integer.
'vat': 500, // Total vat of all products with sale discount. vat = brutto - netto Integer.
'netto': 500, // total netto of all products with sale discount. netto = round(brutto * 100000 / (10000 + vatRate) / 10) Integer.
'brutto': 1000 // total brutto of all products with sale discount. brutto = relativeDiscount == 0 ? round(Brutto - absoluteDiscount * vanillaBrutto * 10 / vanillaBrutto / 10) : round(vanillaBrutto * (10000 - relativeDiscount) / 10000) Integer.
} ] // List of objects.
}

GET /v26/{sellerId}/sales/stats/payment-type

Returns stats by payment type.
sellerIdsellerIdType. May NOT be null.

Request

GET /v26/se9876543210/sales/stats/payment-type HTTP/1.1
Authorization: RestApiTester@se9876543210:9999
Host: t.srv4pos.com

Response

HTTP/1.1 200 OK Content-Type: application/json;charset=UTF-8
{/* Sales stats by payment type. */ 'totalSum': 1200, // Integer. Minimum 0.
'paymentTypeStats': [ {/* Sales stats by payment type. */ 'paymentType': '', // paymentType.
'vatSum': 2500, // Integer. Minimum 0.
'brutto': 1111 // Integer. Minimum 0.
} ] // List of objects. May NOT be null.
}

Errors

400 TypeMismatchJsonException

If passed date period has incorrect format.

404 ReferenceNotFoundJsonException

If passed cash register name don't belong to seller.

PUT /v26/{sellerId}/days/{identifier}

Update day.
sellerIdsellerIdType. May NOT be null.
identifier identifies day identifierType. May NOT be null.

Request

PUT /v26/se9876543210/days/DAY1 HTTP/1.1 Content-Type: application/json
Authorization: -:AbcDeFgqWertY1Mxxjl74rpocd2445hfV
If-Match: "0-0" // Value consists of two parts separated by dash: first part is the seller version from /{sellerId} and second part is the cash register version from .
Host: t.srv4pos.com { 'dayNumber': 1, // Integer. May NOT be null.
'opened': false, // Boolean. May NOT be null.
'reportPrinted': false, // Boolean. May NOT be null.
'open': 1414800000000, // Integer. May NOT be null.
'close': 1414800000000, // Integer. May be null.
'cash': 140, // Integer. May NOT be null.
'cashAtClose': 140, // Integer. May NOT be null.
'grandTotal': 140, // Integer. May NOT be null.
'grandTotalRefund': 10, // Integer. May NOT be null.
'closedDayTreasurer': 'TREASURER1', // String. May be null.
'version': 1, // Registration version Integer. May NOT be null.
'modified': 1414800000000 // Date: amount of milliseconds since UNIX epoch. May NOT be null.
}

Response

HTTP/1.1 204 NO CONTENT

Errors

409 VersionConflictJsonException

Occurs when we upload data to the server but server contains more fresh data than we send. No additional details provided. You should set actual "If-Match" header.

GET /v26/{sellerId}/registrations/{cashRegisterName}/days

Returns list of days.
sellerIdsellerIdType. May NOT be null.
cashRegisterNameMay NOT be null.
cashRegisterNameQuery param Cash register name String. May be null.
periodQuery param search period String. May be null.
firstResultQuery param when pagination starts or null Integer. May be null.
maxResultsQuery param amount of items per page or null Integer. May be null.
likeQuery param search string filter or null String. May be null.

Request

GET /v26/se9876543210/registrations/CashTK/days HTTP/1.1
Authorization: RestApiTester@se9876543210/CashTK:9999
Host: t.srv4pos.com

Response

HTTP/1.1 200 OK Content-Type: application/json;charset=UTF-8
{ 'dayNumber': 1, // Integer. May NOT be null.
'opened': false, // Boolean. May NOT be null.
'reportPrinted': false, // Boolean. May NOT be null.
'open': 1414800000000, // Integer. May NOT be null.
'close': 1414800000000, // Integer. May be null.
'cash': 140, // Integer. May NOT be null.
'cashAtClose': 140, // Integer. May NOT be null.
'grandTotal': 140, // Integer. May NOT be null.
'grandTotalRefund': 10, // Integer. May NOT be null.
'closedDayTreasurer': 'TREASURER1', // String. May be null.
'version': 1, // Registration version Integer. May NOT be null.
'modified': 1414800000000, // Date: amount of milliseconds since UNIX epoch. May NOT be null.
'id': '0', //
'date': '1414200000' //
}

GET /v26/{sellerId}/registrations/{cashRegisterName}/days-minified

Returns list of days.
sellerIdsellerIdType. May NOT be null.
cashRegisterNameMay NOT be null.
cashRegisterNameQuery param Cash register name String. May be null.
periodQuery param search period String. May be null.
firstResultQuery param when pagination starts or null Integer. May be null.
maxResultsQuery param amount of items per page or null Integer. May be null.
likeQuery param search string filter or null String. May be null.

Request

GET /v26/se9876543210/registrations/CashTK/days-minified HTTP/1.1
Authorization: RestApiTester@se9876543210/CashTK:9999
Host: t.srv4pos.com

Response

HTTP/1.1 200 OK Content-Type: application/json;charset=UTF-8
{ 'id': 0, // Integer. May NOT be null.
'date': 1414200000 // Integer. May NOT be null.
}

GET /v26/{sellerId}/registrations/{cashRegisterName}/days/{dayIdentifier}/report

Returns day report.
sellerIdsellerIdType. May NOT be null.
cashRegisterNameMay NOT be null.
dayIdentifier identifies day identifierType. May NOT be null.

Request

GET /v26/se9876543210/registrations/CashTK/days/1/report HTTP/1.1
Authorization: RestApiTester@se9876543210/CashTK:9999
Accept: text/html
Host: t.srv4pos.com

Response

HTTP/1.1 200 OK

POST /v26/{sellerId}/registrations/{cashRegisterName}/days/{dayIdentifier}/report

Confirm receipt print.
sellerIdsellerIdType. May NOT be null.
cashRegisterNameMay NOT be null.
dayIdentifier identifies day identifierType. May NOT be null.

Request

POST /v26/se9876543210/registrations/CashTK/days/1/report HTTP/1.1
Authorization: RestApiTester@se9876543210/CashTK:9999
If-Match: "0-0" // Value consists of two parts separated by dash: first part is the seller version from /{sellerId} and second part is the cash register version from .
Host: t.srv4pos.com

Response

HTTP/1.1 204 NO CONTENT

Errors

404 NotFoundJsonException

When requested resource wasn't found.

422 UnprocessableEntityJsonException

See there: DAY_IS_NOT_CLOSED, REPORT_IS_PRINTED_ALREADY .

POST /v26/{sellerId}/registrations/{cashRegisterName}/days/current

Closes current day.
sellerIdsellerIdType. May NOT be null.
cashRegisterNameMay NOT be null.

Request

POST /v26/se9876543210/registrations/CashTK/days/current HTTP/1.1
Authorization: RestApiTester@se9876543210/CashTK:9999
If-Match: "0-0" // Value consists of two parts separated by dash: first part is the seller version from /{sellerId} and second part is the cash register version from .
Host: t.srv4pos.com

Response

HTTP/1.1 204 NO CONTENT

Errors

422 UnprocessableEntityJsonException

See there: DAY_IS_CLOSED, RECEIPT_IS_NOT_PRINTED .

GET /v26/{sellerId}/registrations/{cashRegisterName}/days-diff/{versionFrom}/{versionTo}

Returns list of item changes between two versions.
sellerId Identifier of seller sellerIdType. May NOT be null.
cashRegisterNameMay NOT be null.
versionFrom Min boundary registration version (included) for diff Integer. May NOT be null.
versionTo Max boundary registration version (included) for diff Integer. May NOT be null.

Request

GET /v26/se9876543210/registrations/CashTK/days-diff/0/9999 HTTP/1.1
Authorization: RestApiTester@se9876543210/CashTK:9999
If-Match: "0-0" // Value consists of two parts separated by dash: first part is the seller version from /{sellerId} and second part is the cash register version from .
Host: t.srv4pos.com

Response

HTTP/1.1 200 OK Content-Type: application/json;charset=UTF-8 /* return list of items to be added. */
{ 'dayNumber': 1, // Integer. May NOT be null.
'opened': false, // Boolean. May NOT be null.
'reportPrinted': false, // Boolean. May NOT be null.
'open': 1414800000000, // Integer. May NOT be null.
'close': 1414800000000, // Integer. May be null.
'cash': 140, // Integer. May NOT be null.
'cashAtClose': 140, // Integer. May NOT be null.
'grandTotal': 140, // Integer. May NOT be null.
'grandTotalRefund': 10, // Integer. May NOT be null.
'closedDayTreasurer': 'TREASURER1', // String. May be null.
'version': 1, // Registration version Integer. May NOT be null.
'modified': 1414800000000 // Date: amount of milliseconds since UNIX epoch. May NOT be null.
}

GET /v26/{sellerId}/days/stats

Returns stats by Z reports..
sellerIdsellerIdType. May NOT be null.

Request

GET /v26/se9876543210/days/stats HTTP/1.1
Authorization: RestApiTester@se9876543210:9999
Host: t.srv4pos.com

Response

HTTP/1.1 200 OK Content-Type: application/json;charset=UTF-8
{/* Represents Z reports stats. */ 'totalSum': 1200, // Total sum by Z reports. Integer. Minimum 0.
'dayStats': [ {/* Sales stats by Z reports. */ 'treasurerName': 'treasurer name', // String.
'vatSum': 2500, // Integer. Minimum 0.
'brutto': 1111, // Integer. Minimum 0.
'open': 1414800000000 // Integer.
} ] // List of objects. May NOT be null.
}

Errors

400 TypeMismatchJsonException

If passed date period has incorrect format.

404 ReferenceNotFoundJsonException

If passed cash register name don't belong to seller.

PUT /v26/{sellerId}/registrations/{cashRegisterName}/sales

Creates sale on the server via PUT.
sellerIdsellerIdType. May NOT be null.
cashRegisterNameMay NOT be null.

Request

PUT /v26/se9876543210/registrations/Cash22/sales HTTP/1.1 Content-Type: application/json
Authorization: -:AbcDeFgqWertY1Mxxjl74rpocd2445hfV
If-Match: "0-0" // Value consists of two parts separated by dash: first part is the seller version from /{sellerId} and second part is the cash register version from .
Host: t.srv4pos.com { 'identifier': 'SL-22', // identifierType. May be null.
'sellerIdentifier': 'se9876543210', // Seller identifier. identifierType. May NOT be null.
'saleState': 'Open', // Sale identifier. saleStateType. May NOT be null.
'refund': true, // True if it is a refund sale. Boolean. May NOT be null.
'refundFor': 123, // Identifier of refunded sale. Integer. May be null.
'absoluteDiscount': 0, // Sale absolute discount. Must be 0 if relativeDiscount is not 0. Integer. May NOT be null.
'relativeDiscount': 1000, // Sale relative discount. Must be 0 if absoluteDiscount is not 0. Integer. May NOT be null.
'vanillaBrutto': 37000, // Sum of product brutto. Integer. May NOT be null.
'discount': 3700, // Sale discount. discount = relativeDiscount != 0 ? vanillaBrutto / (1 + relativeDiscount) : absoluteDiscount Integer. May NOT be null.
'brutto': 33300, // Total sale brutto. Integer. May NOT be null.
'vat': 6660, // Total sale VAT. Integer. May NOT be null.
'controlUnitId': '123456', // Control unit Id. String. May be null.
'day': '0-DCBA', // Day identifer String. May be null.
'treasurer': '0-ABCD', // Treasurer name identifierType. May be null.
'close': new Date().setHours(0,0,0,0), // Close receipt date Date: amount of milliseconds since UNIX epoch. May be null.
'saleProducts': [ { 'productIdentifier': 'PRODUCT1', // Product identifier. String. May NOT be null.
'deltaUnit': false, // Boolean. May NOT be null.
'delta': 300, // The amount of products. Integer. May NOT be null.
'absoluteDiscount': 500, // Absolute discount. Must be 0 if relativeDiscount is not 0 Integer. May NOT be null.
'relativeDiscount': 0, // Relative discount. Must be 0 if absoluteDiscount is not 0 Integer. May NOT be null.
'vat': 7400, // Value-added tax. vat = brutto - brutto * 100000 / (10000 + vatRate) / 10 Integer.
'netto': 29600, // Product price without tax. netto = round(brutto * 100000 / (10000 + vatRate)) Integer.
'brutto': 37500, // Sale product price with tax. brutto = vanillaBrutto - discount Integer.
'productBrutto': 12500, // Brutto of product unit. Integer.
'vatRate': 25, // VAT rate of product. Integer.
'effectiveBrutto': 33300, // Sum of brutto of all products with sale discount. effectiveBrutto = sale#relativeDiscount} != 0 ? brutto * (10000 - sale#relativeDiscount / 10000) * : {brutto - (sale#absoluteDiscount * brutto * 10 / {sale#brutto} / 10) Integer.
'vanillaBrutto': 37500, // Sum of brutto of all products. vanillaBrutto = deltaUnit == 1 ? round(brutto * delta / 100) : delta Integer.
'discount': 500, // Sale product discount. discount = relativeDiscount != 0 ? vanillaBrutto / (1 + relativeDiscount) : absoluteDiscount Integer.
'created': 1414800000001 // Created date. Date: amount of milliseconds since UNIX epoch.
} ], // List of objects.
'prints': [ { 'receiptNumber': 1234, // Integer.
'printType': 'Normal', // printType.
'deliveryType': 'Print', // deliveryType.
'controlNumber': '123456789', // String.
'created': 1414800000001, // Created date. Integer.
'printed': false // Printed date Boolean.
} ], // List of objects.
'payments': [ { 'paymentType': 'Cash', // paymentType.
'amount': 100, // Integer.
'paymentState': 'SENDING' // paymentStateType.
} ], // List of objects.
'vatRateSums': [ { 'vatRate': 2500, // Integer.
'vanillaVat': 7400, // Total vat of all products. Integer.
'vanillaNetto': 29600, // Total netto of all products. Integer.
'vanillaBrutto': 37000, // Total brutto of all products. Integer.
'vat': 6600, // Total vat of all products with sale discount. vat = brutto - netto Integer.
'netto': 26640, // total netto of all products with sale discount. netto = round(brutto * 100000 / (10000 + vatRate) / 10) Integer.
'brutto': 33000 // total brutto of all products with sale discount. brutto = relativeDiscount == 0 ? round(Brutto - absoluteDiscount * vanillaBrutto * 10 / vanillaBrutto / 10) : round(vanillaBrutto * (10000 - relativeDiscount) / 10000) Integer.
} ] // List of objects.
}

Response

HTTP/1.1 204 NO CONTENT

Errors

404 ReferenceNotFoundJsonException

entity "ControlUnit": if control unit is required for the application and the activation has the feature CONTROL_UNIT, but control unit with id controlUnitId is not found.

409 VersionConflictJsonException

Occurs when we upload data to the server but server contains more fresh data than we send. No additional details provided. You should set actual "If-Match" header.

422 UnprocessableEntityJsonException

See there: DAY_IS_CLOSED, DAY_IS_NOT_CLOSED, REPORT_IS_NOT_PRINTED .

POST /v26/{sellerId}/sales

Create sale on the server. Only for activations.
sellerIdsellerIdType. May NOT be null.

Request

POST /v26/se9876543210/sales HTTP/1.1 Content-Type: application/json
Authorization: -:AbcDeFgqWertY1Mxxjl74rpocd2445hfV
If-Match: "0-0" // Value consists of two parts separated by dash: first part is the seller version from /{sellerId} and second part is the cash register version from .
Host: t.srv4pos.com { 'identifier': '', // identifierType. May be null.
'sellerIdentifier': 'se9876543210', // Seller identifier. identifierType. May NOT be null.
'saleState': 'Open', // Sale identifier. saleStateType. May NOT be null.
'refund': true, // True if it is a refund sale. Boolean. May NOT be null.
'refundFor': 123, // Identifier of refunded sale. Integer. May be null.
'absoluteDiscount': 0, // Sale absolute discount. Must be 0 if relativeDiscount is not 0. Integer. May NOT be null.
'relativeDiscount': 1000, // Sale relative discount. Must be 0 if absoluteDiscount is not 0. Integer. May NOT be null.
'vanillaBrutto': 37000, // Sum of product brutto. Integer. May NOT be null.
'discount': 3700, // Sale discount. discount = relativeDiscount != 0 ? vanillaBrutto / (1 + relativeDiscount) : absoluteDiscount Integer. May NOT be null.
'brutto': 33300, // Total sale brutto. Integer. May NOT be null.
'vat': 6660, // Total sale VAT. Integer. May NOT be null.
'controlUnitId': '123456', // Control unit Id. String. May be null.
'day': '0-DCBA', // Day identifer String. May be null.
'treasurer': '0-ABCD', // Treasurer name identifierType. May be null.
'close': new Date().setHours(0,0,0,0), // Close receipt date Date: amount of milliseconds since UNIX epoch. May be null.
'saleProducts': [ { 'productIdentifier': 'PRODUCT1', // Product identifier. String. May NOT be null.
'deltaUnit': false, // Boolean. May NOT be null.
'delta': 300, // The amount of products. Integer. May NOT be null.
'absoluteDiscount': 500, // Absolute discount. Must be 0 if relativeDiscount is not 0 Integer. May NOT be null.
'relativeDiscount': 0, // Relative discount. Must be 0 if absoluteDiscount is not 0 Integer. May NOT be null.
'vat': 7400, // Value-added tax. vat = brutto - brutto * 100000 / (10000 + vatRate) / 10 Integer.
'netto': 29600, // Product price without tax. netto = round(brutto * 100000 / (10000 + vatRate)) Integer.
'brutto': 37500, // Sale product price with tax. brutto = vanillaBrutto - discount Integer.
'productBrutto': 12500, // Brutto of product unit. Integer.
'vatRate': 25, // VAT rate of product. Integer.
'effectiveBrutto': 33300, // Sum of brutto of all products with sale discount. effectiveBrutto = sale#relativeDiscount} != 0 ? brutto * (10000 - sale#relativeDiscount / 10000) * : {brutto - (sale#absoluteDiscount * brutto * 10 / {sale#brutto} / 10) Integer.
'vanillaBrutto': 37500, // Sum of brutto of all products. vanillaBrutto = deltaUnit == 1 ? round(brutto * delta / 100) : delta Integer.
'discount': 500, // Sale product discount. discount = relativeDiscount != 0 ? vanillaBrutto / (1 + relativeDiscount) : absoluteDiscount Integer.
'created': 1414800000001 // Created date. Date: amount of milliseconds since UNIX epoch.
} ], // List of objects.
'prints': [ { 'receiptNumber': 1234, // Integer.
'printType': 'Normal', // printType.
'deliveryType': 'Print', // deliveryType.
'controlNumber': '123456789', // String.
'created': 1414800000001, // Created date. Integer.
'printed': false // Printed date Boolean.
} ], // List of objects.
'payments': [ { 'paymentType': 'Cash', // paymentType.
'amount': 100, // Integer.
'paymentState': 'SENDING' // paymentStateType.
} ], // List of objects.
'vatRateSums': [ { 'vatRate': 2500, // Integer.
'vanillaVat': 7400, // Total vat of all products. Integer.
'vanillaNetto': 29600, // Total netto of all products. Integer.
'vanillaBrutto': 37000, // Total brutto of all products. Integer.
'vat': 6600, // Total vat of all products with sale discount. vat = brutto - netto Integer.
'netto': 26640, // total netto of all products with sale discount. netto = round(brutto * 100000 / (10000 + vatRate) / 10) Integer.
'brutto': 33000 // total brutto of all products with sale discount. brutto = relativeDiscount == 0 ? round(Brutto - absoluteDiscount * vanillaBrutto * 10 / vanillaBrutto / 10) : round(vanillaBrutto * (10000 - relativeDiscount) / 10000) Integer.
} ] // List of objects.
}

Response

HTTP/1.1 201 CREATED Content-Type: application/json;charset=UTF-8
{/* Generated unique identifier. */ 'identifier': '0-ID' // identifierType. May NOT be null.
}

Errors

404 ReferenceNotFoundJsonException

entity "ControlUnit": if control unit is required for the application and the activation has the feature CONTROL_UNIT, but control unit with id controlUnitId is not found.

409 VersionConflictJsonException

Occurs when we upload data to the server but server contains more fresh data than we send. No additional details provided. You should set actual "If-Match" header.

422 UnprocessableEntityJsonException

See there: DAY_IS_CLOSED, DAY_IS_NOT_CLOSED, REPORT_IS_NOT_PRINTED .

GET /v26/{sellerId}/sales

Get sale list.
sellerIdsellerIdType. May NOT be null.
cashRegisterNameQuery param Cash register name String. May be null.
periodQuery param search period String. May be null.
firstResultQuery param when pagination starts or null Integer. May be null.
maxResultsQuery param amount of items per page or null Integer. May be null.
likeQuery param search string filter or null String. May be null.

Request

GET /v26/se9876543210/sales HTTP/1.1 Content-Type: application/json
Authorization: RestApiTester@se9876543210/CashTK:9999
Host: t.srv4pos.com

Response

HTTP/1.1 200 OK Content-Type: application/json;charset=UTF-8
[ { 'identifier': '', // identifierType. May be null.
'sellerIdentifier': 'se9876543210', // Seller identifier. identifierType. May NOT be null.
'saleState': 'Open', // Sale identifier. saleStateType. May NOT be null.
'refund': true, // True if it is a refund sale. Boolean. May NOT be null.
'refundFor': 10, // Identifier of refunded sale. Integer. May be null.
'absoluteDiscount': 0, // Sale absolute discount. Must be 0 if relativeDiscount is not 0. Integer. May NOT be null.
'relativeDiscount': 50, // Sale relative discount. Must be 0 if absoluteDiscount is not 0. Integer. May NOT be null.
'vanillaBrutto': 100, // Sum of product brutto. Integer. May NOT be null.
'discount': 100, // Sale discount. discount = relativeDiscount != 0 ? vanillaBrutto / (1 + relativeDiscount) : absoluteDiscount Integer. May NOT be null.
'brutto': 50, // Total sale brutto. Integer. May NOT be null.
'vat': 25, // Total sale VAT. Integer. May NOT be null.
'controlUnitId': '123456', // Control unit Id. String. May be null.
'day': '0-DCBA', // Day identifer String. May be null.
'treasurer': '0-ABCD', // Treasurer name identifierType. May be null.
'close': new Date().setHours(0,0,0,0), // Close receipt date Date: amount of milliseconds since UNIX epoch. May be null.
'saleProducts': [ { 'productIdentifier': 'PRODUCT1', // Product identifier. String. May NOT be null.
'deltaUnit': false, // Boolean. May NOT be null.
'delta': 10, // The amount of products. Integer. May NOT be null.
'absoluteDiscount': 0, // Absolute discount. Must be 0 if relativeDiscount is not 0 Integer. May NOT be null.
'relativeDiscount': 50, // Relative discount. Must be 0 if absoluteDiscount is not 0 Integer. May NOT be null.
'vat': 25, // Value-added tax. vat = brutto - brutto * 100000 / (10000 + vatRate) / 10 Integer.
'netto': 100, // Product price without tax. netto = round(brutto * 100000 / (10000 + vatRate)) Integer.
'brutto': 125, // Sale product price with tax. brutto = vanillaBrutto - discount Integer.
'productBrutto': 12, // Brutto of product unit. Integer.
'vatRate': 25, // VAT rate of product. Integer.
'effectiveBrutto': 125, // Sum of brutto of all products with sale discount. effectiveBrutto = sale#relativeDiscount} != 0 ? brutto * (10000 - sale#relativeDiscount / 10000) * : {brutto - (sale#absoluteDiscount * brutto * 10 / {sale#brutto} / 10) Integer.
'vanillaBrutto': 125, // Sum of brutto of all products. vanillaBrutto = deltaUnit == 1 ? round(brutto * delta / 100) : delta Integer.
'discount': 50, // Sale product discount. discount = relativeDiscount != 0 ? vanillaBrutto / (1 + relativeDiscount) : absoluteDiscount Integer.
'created': 1414800000001 // Created date. Date: amount of milliseconds since UNIX epoch.
} ], // List of objects.
'prints': [ { 'receiptNumber': 1234, // Integer.
'printType': 'Normal', // printType.
'deliveryType': 'Print', // deliveryType.
'controlNumber': '123456789', // String.
'created': 1414800000001, // Created date. Integer.
'printed': false // Printed date Boolean.
} ], // List of objects.
'payments': [ { 'paymentType': 'Cash', // paymentType.
'amount': 100, // Integer.
'paymentState': 'SENDING' // paymentStateType.
} ], // List of objects.
'vatRateSums': [ { 'vatRate': 50, // Integer.
'vanillaVat': 5000, // Total vat of all products. Integer.
'vanillaNetto': 5000, // Total netto of all products. Integer.
'vanillaBrutto': 10000, // Total brutto of all products. Integer.
'vat': 500, // Total vat of all products with sale discount. vat = brutto - netto Integer.
'netto': 500, // total netto of all products with sale discount. netto = round(brutto * 100000 / (10000 + vatRate) / 10) Integer.
'brutto': 1000 // total brutto of all products with sale discount. brutto = relativeDiscount == 0 ? round(Brutto - absoluteDiscount * vanillaBrutto * 10 / vanillaBrutto / 10) : round(vanillaBrutto * (10000 - relativeDiscount) / 10000) Integer.
} ] // List of objects.
} ]

GET /v26/{sellerId}/sales/stats

Returns sales stats filtered by seller, cash register name and period.
sellerIdsellerIdType. May NOT be null.
cashRegisterNameQuery param filters stats by cash register name String. May be null.
periodQuery param filters by date period String. May be null.

Request

GET /v26/se9876543210/sales/stats HTTP/1.1
Authorization: RestApiTester@se9876543210:9999
Host: t.srv4pos.com

Response

HTTP/1.1 200 OK Content-Type: application/json;charset=UTF-8
{ 'total': 1200, // Total stats by sales brutto. Integer. Minimum 0.
'amountOfSales': 100, // Total amount of sales. Integer. Minimum 0.
'amountOfProducts': 150, // Total amount of sold products. Integer. Minimum 0.
'dateGroupingUnit': 'HOUR', // How sales brutto stats is grouped. dateGroupingUnit. May NOT be null.
'bruttoStats': {'2014-12-01T00:00:00.000+0000':424500} // Date-to-brutto stats grouped by some period (i.e. 'day' or 'hour'). Date has format: 'yyyy-MM-dd'T'HH:mm:ss.SSSZ'. A complex object. May NOT be null.
}

GET /v26/{sellerId}/sales-minified

Get sale list.
sellerIdsellerIdType. May NOT be null.
cashRegisterNameQuery param Cash register name String. May be null.
periodQuery param search period String. May be null.
firstResultQuery param when pagination starts or null Integer. May be null.
maxResultsQuery param amount of items per page or null Integer. May be null.
likeQuery param search string filter or null String. May be null.

Request

GET /v26/se9876543210/sales-minified HTTP/1.1 Content-Type: application/json
Authorization: RestApiTester@se9876543210/CashTK:9999
Host: t.srv4pos.com

Response

HTTP/1.1 200 OK Content-Type: application/json;charset=UTF-8
[ { 'id': 0, // Integer. May NOT be null.
'close': 1414200000, // Integer. May NOT be null.
'brutto': 100, // Integer. May NOT be null.
'receiptNumber': 100, // Integer. May NOT be null.
'cashRegisterName': 'CashTK', // String. May NOT be null.
'vatSum': 100, // Sum by vat for sold products. Integer. Minimum 0.
'treasurer': [ { 'deleted': false, // True if entity was deleted. Boolean. May NOT be null.
'identifier': '0-2U0Z', // identifierType. May NOT be null.
'name': 'test', // String. Minimum 1 characters. Maximum 32 characters. May NOT be null.
'ssn': '123423567', // Social security number of user. String. Maximum 16 characters. May NOT be null.
'custom': '', // String. Maximum 65535 characters.
'user': '', // User joined to treasurer. Readonly. String. May be null.
'pin': '8888' // Social security number of user. String. Maximum 16 characters. May NOT be null.
} ] // List of objects.
} ]

GET /v26/{sellerId}/e-journals/{cashRegisterName}

Returns e-journal.
sellerIdsellerIdType. May NOT be null.
cashRegisterNamecashRegisterNameType. May NOT be null.
orderDescQuery param direction of ordering in resulting csv lines. Available only for non-thinkassan clients May be null.

Request

GET /v26/se9876543210/e-journals/CashTK HTTP/1.1
Accept: text/csv
Authorization: RestApiTester@se9876543210/CashTK:9999
Host: t.srv4pos.com

Response

HTTP/1.1 200 OK

POST /v26/{sellerId}/e-journals/{cashRegisterName}

Appends lines to ejournal. Available only for non-thinkassan clients.
sellerIdsellerIdType. May NOT be null.
cashRegisterNamecashRegisterNameType. May NOT be null.
orderDescQuery param direction of ordering in resulting csv lines. Available only for non-thinkassan clients May be null.

Request

POST /v26/se9876543210/e-journals/Cash22 HTTP/1.1
Content-type: text/csv
Authorization: -:AbcDeFgqWertY1Mxxjl74rpocd2445hfV
Host: t.srv4pos.com

Response

HTTP/1.1 201 CREATED

POST /v26/{sellerId}/days

Create day.
sellerIdsellerIdType. May NOT be null.

Request

POST /v26/se9876543210/days HTTP/1.1 Content-Type: application/json
Authorization: -:AbcDeFgqWertY1Mxxjl74rpocd2445hfV
If-Match: "0-0" // Value consists of two parts separated by dash: first part is the seller version from /{sellerId} and second part is the cash register version from .
Host: t.srv4pos.com { 'dayNumber': 1, // Integer. May NOT be null.
'opened': false, // Boolean. May NOT be null.
'reportPrinted': false, // Boolean. May NOT be null.
'open': 1414800000000, // Integer. May NOT be null.
'close': 1414800000000, // Integer. May be null.
'cash': 140, // Integer. May NOT be null.
'cashAtClose': 140, // Integer. May NOT be null.
'grandTotal': 140, // Integer. May NOT be null.
'grandTotalRefund': 10, // Integer. May NOT be null.
'closedDayTreasurer': 'TREASURER1', // String. May be null.
'version': 1, // Registration version Integer. May NOT be null.
'modified': 1414800000000 // Date: amount of milliseconds since UNIX epoch. May NOT be null.
}

Response

HTTP/1.1 201 CREATED Content-Type: application/json;charset=UTF-8
{/* Generated unique identifier. */ 'identifier': '0-ID' // identifierType. May NOT be null.
}

Errors

409 VersionConflictJsonException

Occurs when we upload data to the server but server contains more fresh data than we send. No additional details provided. You should set actual "If-Match" header.

POST /v26/{sellerId}/precepts

Sends precept.
sellerId Identifier of seller sellerIdType. May NOT be null.

Request

POST /v26/se9876543210/precepts HTTP/1.1 Content-Type: application/json
Authorization: -:AbcDeFgqWertY1Mxxjl74rpocd2445hfV
Host: t.srv4pos.com {/* Represents instruction for kitchen. */ 'identifier': 'CashRegister-23', // String. Minimum 1 characters. Maximum 50 characters.
'treasurerName': 'Treasurer 1', // String. Minimum 1 characters. Maximum 32 characters. May NOT be null.
'preceptItems': [ {/* Represents how many products of particular type was ordered. */ 'productIdentifier': 'PRODUCT1', // identifierType. May NOT be null.
'productCustomization': 'Customization A', // Any customer's wishes about product customization. String. Maximum 512 characters. May be null.
'delta': 700 // The number of products (kg, hg, hours, whatever unit) if deltaUnit is true, otherwise the amount of currency. Integer. May NOT be null.
} ], // List of objects.
'table': 'near the entrance', // String. Maximum 50 characters.
'created': 1414800000001, // Date: amount of milliseconds since UNIX epoch. May be null.
'status': 'NEW', // preceptStatusType. May NOT be null.
'message': '', // String. Maximum 512 characters. May be null.
'order': '0-1' // String. Minimum 1 characters. Maximum 50 characters. May be null.
}

Response

HTTP/1.1 201 CREATED Content-Type: application/json;charset=UTF-8
{/* Methods called "new" will return the identifier of newly created entity by using this class */ 'identifier': '0-ID' // identifierType. May NOT be null.
}

Errors

400 NonUniqueJsonException

If identifier is not unique within a seller.

404 ReferenceNotFoundJsonException

If product with passed productIdentifier or order with passed orderIdentifier weren't found.

422 UnprocessableEntityJsonException

See there: ORDER_ALREADY_HAS_PRECEPT .

GET /v26/{sellerId}/precepts/{preceptId}

Gets info about precept.
sellerId Identifier of seller sellerIdType. May NOT be null.
preceptId Identifier of precept Integer. May NOT be null.

Request

GET /v26/se9876543210/precepts/CashRegister-23 HTTP/1.1
Authorization: -:AbcDeFgqWertY1Mxxjl74rpocd2445hfV
Host: t.srv4pos.com

Response

HTTP/1.1 200 OK Content-Type: application/json;charset=UTF-8
{/* Represents instruction for kitchen. */ 'identifier': 'CashRegister-23', // String. Minimum 1 characters. Maximum 50 characters.
'treasurerName': 'Treasurer 1', // String. Minimum 1 characters. Maximum 32 characters. May NOT be null.
'preceptItems': [ {/* Represents how many products of particular type was ordered. */ 'productIdentifier': 'PRODUCT1', // identifierType. May NOT be null.
'productCustomization': 'Customization A', // Any customer's wishes about product customization. String. Maximum 512 characters. May be null.
'delta': 700 // The number of products (kg, hg, hours, whatever unit) if deltaUnit is true, otherwise the amount of currency. Integer. May NOT be null.
} ], // List of objects.
'table': 'near the entrance', // String. Maximum 50 characters.
'created': 1414800000001, // Date: amount of milliseconds since UNIX epoch. May be null.
'status': 'NEW', // preceptStatusType. May NOT be null.
'message': '', // String. Maximum 512 characters. May be null.
'order': '0-1' // String. Minimum 1 characters. Maximum 50 characters. May be null.
}

Errors

404 NotFoundJsonException

If precept with specified id wasn't found.

GET /v26/{sellerId}/precepts

Returns a list with precepts.
sellerId Identifier of seller sellerIdType. May NOT be null.
firstResultQuery param when pagination starts or null Integer. May be null.
maxResultsQuery param amount of items per page or null Integer. May be null.
likeQuery param search string filter or null String. May be null.

Request

GET /v26/se9876543210/precepts HTTP/1.1
Authorization: -:AbcDeFgqWertY1Mxxjl74rpocd2445hfV
Host: t.srv4pos.com

Response

HTTP/1.1 200 OK Content-Type: application/json;charset=UTF-8
[ {/* Represents instruction for kitchen. */ 'identifier': 'CashRegister-23', // String. Minimum 1 characters. Maximum 50 characters.
'treasurerName': 'Treasurer 1', // String. Minimum 1 characters. Maximum 32 characters. May NOT be null.
'preceptItems': [ {/* Represents how many products of particular type was ordered. */ 'productIdentifier': 'PRODUCT1', // identifierType. May NOT be null.
'productCustomization': 'Customization A', // Any customer's wishes about product customization. String. Maximum 512 characters. May be null.
'delta': 700 // The number of products (kg, hg, hours, whatever unit) if deltaUnit is true, otherwise the amount of currency. Integer. May NOT be null.
} ], // List of objects.
'table': 'near the entrance', // String. Maximum 50 characters.
'created': 1414800000001, // Date: amount of milliseconds since UNIX epoch. May be null.
'status': 'NEW', // preceptStatusType. May NOT be null.
'message': '', // String. Maximum 512 characters. May be null.
'order': '0-1' // String. Minimum 1 characters. Maximum 50 characters. May be null.
} ]

GET /v26/{sellerId}/precepts-diff/{versionFrom}/{versionTo}

Returns list of item changes between two versions. Since we don't have delete and edit methods, it returns only newly created precepts.
sellerId Identifier of seller sellerIdType. May NOT be null.
versionFrom Min boundary version (included) for diff Integer. May NOT be null.
versionTo Max boundary version (included) for diff Integer. May NOT be null.

Request

GET /v26/se9876543210/precepts-diff/0/9999 HTTP/1.1
Authorization: -:AbcDeFgqWertY1Mxxjl74rpocd2445hfV
Host: t.srv4pos.com

Response

HTTP/1.1 200 OK Content-Type: application/json;charset=UTF-8
{/* Represents instruction for kitchen. */ 'identifier': 'CashRegister-23', // String. Minimum 1 characters. Maximum 50 characters.
'treasurerName': 'Treasurer 1', // String. Minimum 1 characters. Maximum 32 characters. May NOT be null.
'preceptItems': [ {/* Represents how many products of particular type was ordered. */ 'productIdentifier': 'PRODUCT1', // identifierType. May NOT be null.
'productCustomization': 'Customization A', // Any customer's wishes about product customization. String. Maximum 512 characters. May be null.
'delta': 700 // The number of products (kg, hg, hours, whatever unit) if deltaUnit is true, otherwise the amount of currency. Integer. May NOT be null.
} ], // List of objects.
'table': 'near the entrance', // String. Maximum 50 characters.
'created': 1414800000001, // Date: amount of milliseconds since UNIX epoch. May be null.
'status': 'NEW', // preceptStatusType. May NOT be null.
'message': '', // String. Maximum 512 characters. May be null.
'order': '0-1' // String. Minimum 1 characters. Maximum 50 characters. May be null.
}

PUT /v26/{sellerId}/precepts/{preceptId}

Creates new or makes changes of precept.
sellerId Identifier of seller sellerIdType. May NOT be null.
preceptId Identifier of precept Integer. May NOT be null.

Request

PUT /v26/se9876543210/precepts/CashRegister-23 HTTP/1.1 Content-Type: application/json
Authorization: -:AbcDeFgqWertY1Mxxjl74rpocd2445hfV
Host: t.srv4pos.com {/* Represents instruction for kitchen. */ 'identifier': 'CashRegister-23', // String. Minimum 1 characters. Maximum 50 characters.
'treasurerName': 'Treasurer 1', // String. Minimum 1 characters. Maximum 32 characters. May NOT be null.
'preceptItems': [ {/* Represents how many products of particular type was ordered. */ 'productIdentifier': 'PRODUCT1', // identifierType. May NOT be null.
'productCustomization': 'Customization A', // Any customer's wishes about product customization. String. Maximum 512 characters. May be null.
'delta': 700 // The number of products (kg, hg, hours, whatever unit) if deltaUnit is true, otherwise the amount of currency. Integer. May NOT be null.
} ], // List of objects.
'table': 'near the entrance', // String. Maximum 50 characters.
'created': 1414800000001, // Date: amount of milliseconds since UNIX epoch. May be null.
'status': 'NEW', // preceptStatusType. May NOT be null.
'message': '', // String. Maximum 512 characters. May be null.
'order': '0-1' // String. Minimum 1 characters. Maximum 50 characters. May be null.
}

Response

HTTP/1.1 204 NO CONTENT Content-Type: application/json;charset=UTF-8
{/* Methods called "new" will return the identifier of newly created entity by using this class */ 'identifier': '0-ID' // identifierType. May NOT be null.
}

Errors

400 NonUniqueJsonException

If identifier is not unique within a seller.

404 ReferenceNotFoundJsonException

If product with passed productIdentifier or order with passed orderIdentifier weren't found.

GET /v26/restaurants-overview/{sellerId}

Get information about Restaurant from the server.
sellerId Identifier of seller sellerIdType. May NOT be null.

Request

GET /v26/restaurants-overview/se9876543210 HTTP/1.1
Authorization: RestApiTester@se9876543210:9999
Host: t.srv4pos.com

Response

HTTP/1.1 200 OK Content-Type: application/json;charset=UTF-8
{/* Same set of field as in Restaurant allowed to be in restaurant info. */ 'country': 'se', // countryType. May NOT be null.
'corporateId': '9876543210', // corporateIdType. May NOT be null.
'name': 'Super Restaurant', // String. Minimum 1 characters. Maximum 96 characters. May be null.
'city': 'Stockholm', // String. Minimum 1 characters. Maximum 255 characters.
'address': 'Street 194/144', // String. Minimum 1 characters. Maximum 500 characters.
'phone': '', // String. Minimum 1 characters. Maximum 96 characters.
'workHours': '8', // String.
'workHoursWeek': { 'MONDAY': {/* Describes work hours of specific day of week. */ 'dayOfWeek': 'TUESDAY', // dayOfWeek. May NOT be null.
'openTime': 600, // Describes the number of minutes since midnight. Integer. Minimum 0. Maximum 1920.
'closeTime': 1200 // Describes the number of minutes since midnight. Integer. Minimum 0. Maximum 1920.
}, // A complex object. May be null.
'TUESDAY': {/* Describes work hours of specific day of week. */ 'dayOfWeek': 'TUESDAY', // dayOfWeek. May NOT be null.
'openTime': 600, // Describes the number of minutes since midnight. Integer. Minimum 0. Maximum 1920.
'closeTime': 1200 // Describes the number of minutes since midnight. Integer. Minimum 0. Maximum 1920.
}, // A complex object. May be null.
'WEDNESDAY': {/* Describes work hours of specific day of week. */ 'dayOfWeek': 'TUESDAY', // dayOfWeek. May NOT be null.
'openTime': 600, // Describes the number of minutes since midnight. Integer. Minimum 0. Maximum 1920.
'closeTime': 1200 // Describes the number of minutes since midnight. Integer. Minimum 0. Maximum 1920.
}, // A complex object. May be null.
'THURSDAY': {/* Describes work hours of specific day of week. */ 'dayOfWeek': 'TUESDAY', // dayOfWeek. May NOT be null.
'openTime': 600, // Describes the number of minutes since midnight. Integer. Minimum 0. Maximum 1920.
'closeTime': 1200 // Describes the number of minutes since midnight. Integer. Minimum 0. Maximum 1920.
}, // A complex object. May be null.
'FRIDAY': {/* Describes work hours of specific day of week. */ 'dayOfWeek': 'TUESDAY', // dayOfWeek. May NOT be null.
'openTime': 600, // Describes the number of minutes since midnight. Integer. Minimum 0. Maximum 1920.
'closeTime': 1200 // Describes the number of minutes since midnight. Integer. Minimum 0. Maximum 1920.
}, // A complex object. May be null.
'SATURDAY': {/* Describes work hours of specific day of week. */ 'dayOfWeek': 'TUESDAY', // dayOfWeek. May NOT be null.
'openTime': 600, // Describes the number of minutes since midnight. Integer. Minimum 0. Maximum 1920.
'closeTime': 1200 // Describes the number of minutes since midnight. Integer. Minimum 0. Maximum 1920.
}, // A complex object. May be null.
'SUNDAY': {/* Describes work hours of specific day of week. */ 'dayOfWeek': 'TUESDAY', // dayOfWeek. May NOT be null.
'openTime': 600, // Describes the number of minutes since midnight. Integer. Minimum 0. Maximum 1920.
'closeTime': 1200 // Describes the number of minutes since midnight. Integer. Minimum 0. Maximum 1920.
} // A complex object. May be null.
}, // A complex object. May NOT be null.
'description': '', // String.
'averageBill': 150, // Integer.
'menu': [ {/* Extended category info for restaurant which contains list of products and images. */ 'name': '', // String. Maximum 96 characters. May be null.
'products': [ { 'deleted': 'false', // True if entity was deleted. Only possible if return diff. May NOT be null.
'product': { 'deleted': 'false', // True if entity was deleted. Only possible if return diff. May NOT be null.
'identifier': '0-2U12', // identifierType. May NOT be null.
'name': 'Product 1', // Regular field. String. Minimum 1 characters. Maximum 32 characters. May NOT be null.
'barcode': '012345678912', // Regular field. String. Minimum 1 characters. Maximum 32 characters. May NOT be null.
'netto': 100, // Regular field. Integer. May NOT be null.
'tax': 'TAX1', // Regular field. identifierType. May NOT be null.
'salesUnit': 'Piece', // Regular field. salesUnitType. May NOT be null.
'countedInPrice': 'false', // Regular field. May NOT be null.
'description': '', // String. Maximum 1024 characters. May be null.
'custom': '' // String. Maximum 65535 characters. May be null.
}, // A complex object. May NOT be null.
'tax': { 'deleted': 'false', // true if entity was deleted. May NOT be null.
'identifier': 'TAX1', // This field uniquely identifies entity. There is no decision what is it, only the requirement - it must be unique trough one seller. identifierType. May be null.
'vat': 1, // Regular field. Integer. Minimum 0. Maximum 100. May NOT be null.
'name': 'Tax 1', // Regular field. String. Minimum 1 characters. Maximum 32 characters. May NOT be null.
'custom': '' // Custom data concerned tax. String. Maximum 65535 characters. May be null.
}, // A complex object. May NOT be null.
'images': ['PRODUCT1.PNG', 'PRODUCT2.PNG'] // A complex object. May NOT be null.
} ], // List of objects.
'images': ['PRODUCT1.PNG', 'PRODUCT2.PNG'] // A complex object.
} ], // List of objects.
'images': ['MAIN.PNG', 'SECONDARY.PNG'], // A complex object.
'custom': '', // String. Maximum 65535 characters.
'taxes': [ { 'deleted': 'false', // true if entity was deleted. May NOT be null.
'identifier': 'TAX1', // This field uniquely identifies entity. There is no decision what is it, only the requirement - it must be unique trough one seller. identifierType. May be null.
'vat': 1, // Regular field. Integer. Minimum 0. Maximum 100. May NOT be null.
'name': 'Tax 1', // Regular field. String. Minimum 1 characters. Maximum 32 characters. May NOT be null.
'custom': '' // Custom data concerned tax. String. Maximum 65535 characters. May be null.
} ], // List of objects.
'currency': 'SEK' // currencyType. May be null.
}

Errors

404 NotFoundJsonException

If entity wasn't found.

GET /v26/restaurants/{sellerId}

Get information about Restaurant from the server.
sellerId Identifier of seller sellerIdType. May NOT be null.

Request

GET /v26/restaurants/se9876543210 HTTP/1.1
Authorization: RestApiTester@se9876543210:9999
Host: t.srv4pos.com

Response

HTTP/1.1 200 OK Content-Type: application/json;charset=UTF-8
{/* Restaurant info. */ 'country': 'se', // countryType. May NOT be null.
'corporateId': '9876543210', // corporateIdType. May NOT be null.
'averageBill': 150 // Integer.
}

Errors

404 NotFoundJsonException

If entity wasn't found.

DELETE /v26/restaurants/{sellerId}

Delete information about Restaurant from the server.
sellerId Identifier of seller sellerIdType. May NOT be null.

Request

DELETE /v26/restaurants/se9876543210 HTTP/1.1
Authorization: RestApiTester@se9876543210:9999
Host: t.srv4pos.com

Response

HTTP/1.1 204 NO CONTENT

Errors

404 NotFoundJsonException

If entity wasn't found.

PUT /v26/restaurants/{sellerId}

Send information about Restaurant to the server to store it.
sellerId Identifier of seller sellerIdType. May NOT be null.

Request

PUT /v26/restaurants/se9876543210 HTTP/1.1 Content-Type: application/json
Authorization: RestApiTester@se9876543210:9999
Host: t.srv4pos.com {/* Restaurant info. */ 'country': 'se', // countryType. May NOT be null.
'corporateId': '9876543210', // corporateIdType. May NOT be null.
'averageBill': 150 // Integer.
}

Response

HTTP/1.1 204 NO CONTENT

Errors

404 NotFoundJsonException

If entity wasn't found.

403 ForbiddenJsonException

See there: INSUFFICIENT_ACCESS_RIGHTS .

GET /v26/restaurants

Returns list of entities.
orderByQuery param field to order by One of the following values: 'COUNTRY', 'NAME', 'AVERAGE_BILL', 'DESCRIPTION', 'CITY', 'WORK_HOURS', 'PHONE'. May be null.
orderDescQuery param field to direction of ordering Boolean. May be null.
firstResultQuery param when pagination starts or null Integer. May be null.
maxResultsQuery param amount of items per page or null Integer. May be null.
likeQuery param search string filter or null String. May be null.

Request

GET /v26/restaurants HTTP/1.1
Authorization: RestApiTester@se9876543210:9999
Host: t.srv4pos.com

Response

HTTP/1.1 200 OK Content-Type: application/json;charset=UTF-8
[ {/* Restaurant list info. */ 'country': 'se', // countryType. May NOT be null.
'corporateId': '9876543210', // corporateIdType. May NOT be null.
'name': 'Super Restaurant', // String. Minimum 1 characters. Maximum 96 characters. May be null.
'description': '', // String.
'city': 'Stockholm', // String. Minimum 1 characters. Maximum 255 characters.
'address': 'Street 194/144', // String. Minimum 1 characters. Maximum 500 characters.
'averageBill': 150, // Integer.
'logo': '', // String.
'custom': '' // String. Maximum 65535 characters.
} ]

GET /v26/hairdressers/{sellerId}

Get information about Hairdresser from the server.
sellerId Identifier of seller sellerIdType. May NOT be null.

Request

GET /v26/hairdressers/se9876543210 HTTP/1.1
Authorization: RestApiTester@se9876543210:9999
Host: t.srv4pos.com

Response

HTTP/1.1 200 OK Content-Type: application/json;charset=UTF-8
{/* Hairdresser info. */ 'country': 'se', // countryType. May NOT be null.
'corporateId': '9876543210' // corporateIdType. May NOT be null.
}

Errors

404 NotFoundJsonException

If entity wasn't found.

403 ForbiddenJsonException

See there: INSUFFICIENT_ACCESS_RIGHTS .

DELETE /v26/hairdressers/{sellerId}

Delete information about Hairdresser from the server.
sellerId Identifier of seller sellerIdType. May NOT be null.

Request

DELETE /v26/hairdressers/se9876543210 HTTP/1.1
Authorization: RestApiTester@se9876543210:9999
Host: t.srv4pos.com

Response

HTTP/1.1 204 NO CONTENT

Errors

404 NotFoundJsonException

If entity wasn't found.

403 ForbiddenJsonException

See there: INSUFFICIENT_ACCESS_RIGHTS .

PUT /v26/hairdressers/{sellerId}

Send information about Hairdresser to the server to store it.
sellerId Identifier of seller sellerIdType. May NOT be null.

Request

PUT /v26/hairdressers/se9876543210 HTTP/1.1 Content-Type: application/json
Authorization: RestApiTester@se9876543210:9999
Host: t.srv4pos.com {/* Hairdresser info. */ 'country': 'se', // countryType. May NOT be null.
'corporateId': '9876543210' // corporateIdType. May NOT be null.
}

Response

HTTP/1.1 204 NO CONTENT

Errors

404 NotFoundJsonException

If entity wasn't found.

403 ForbiddenJsonException

See there: INSUFFICIENT_ACCESS_RIGHTS .

GET /v26/devices-overview/{id}

Returns an device.
idMay NOT be null.

Request

GET /v26/devices-overview/0 HTTP/1.1
Authorization: RestApiTester@se9876543210:9999
Host: t.srv4pos.com

Response

HTTP/1.1 200 OK Content-Type: application/json;charset=UTF-8
{/* This entity provides info about android (and not only) device. */ 'deviceInfo': {/* This entity provides info about android device. */ 'id': 5432, // Integer.
'deviceId': '34565673' // deviceIdType. May NOT be null.
}, // A complex object.
'latestInstallationInfo': {/* This entity provides info about android device. */ 'installationInfo': { 'id': 654353, // Deprecated, please use productionNumber Integer. May be null.
'deviceId': '111AAA222BBB3-022', // deviceIdType. May NOT be null.
'buildInfo': {'KEY1':'VALUE1', 'KEY2':'VALUE2'}, // A complex object. May NOT be null.
'applicationPackage': 'package', // applicationPackageType. May NOT be null.
'gcmRegistrationId': '123', // String. Minimum 1 characters.
'productionNumber': 'TEST100000000000000000081', // productionNumberType.
'registrationDate': 45672345, // Date: amount of milliseconds since UNIX epoch.
'gcmUnsubscribeDate': 45672345 // Date: amount of milliseconds since UNIX epoch.
}, // A complex object.
'deviceInfo': {/* This entity provides info about android device. */ 'id': 5432, // Integer.
'deviceId': '34565673' // deviceIdType. May NOT be null.
}, // A complex object.
'applicationDescriptionInfo': {/* Information about person. */ 'applicationPackage': 'super.package', // applicationPackageType.
'productionNumberPrefix': 'PRENP', // String.
'controlUnitRequired': true, // Boolean.
'name': 'Super application', // String.
'softwareVendor': 2, // Integer.
'autoActivationCondition': 'NEVER', // autoActivationConditionType.
'corporateIdValidationMethod': 'NONE' // corporateIdValidationMethodType.
}, // A complex object.
'buildInfoes': [ {/* Information about android device taken from android.os.Build. */ 'name': '', // String. Maximum 25 characters. May NOT be null.
'value': '', // String. Maximum 1024 characters. May NOT be null.
'installation': '' // String. May NOT be null.
} ], // List of objects.
'registrationOverviewInfoes': [ {/* Represents server-side entity available for admin. */ 'registrationId': , // Integer.
'cashRegisterName': 'cash name', // String. Maximum 16 characters. May NOT be null.
'sellerOverviewInfo': { 'name': 'CompanyName', // String. Maximum 96 characters. May be null.
'country': 'se', // countryType. May NOT be null.
'corporateId': '9876543210', // corporateIdType. May NOT be null.
'currency': 'SEK', // currencyType. May be null.
'countActiveCashRegisters': , // Integer.
'turnover': // Integer.
} // A complex object. May NOT be null.
} ] // List of objects.
} // A complex object.
}

Errors

404 NotFoundJsonException

If device wasn't found.

GET /v26/devices

Returns list of devices.
firstResultQuery param when pagination starts or null Integer. May be null.
maxResultsQuery param amount of items per page or null Integer. May be null.
likeQuery param search string filter or null String. May be null.

Request

GET /v26/devices HTTP/1.1
Authorization: RestApiTester@se9876543210:9999
Host: t.srv4pos.com

Response

HTTP/1.1 200 OK Content-Type: application/json;charset=UTF-8
[ {/* This entity provides info about android device. */ 'id': 5432, // Integer.
'deviceId': '34565673' // deviceIdType. May NOT be null.
} ]

Errors

404 ReferenceNotFoundJsonException

If some of passed query parameters wasn't found on server.

GET /v26/devices-overview

Returns list of devices Overview.
firstResultQuery param when pagination starts or null Integer. May be null.
maxResultsQuery param amount of items per page or null Integer. May be null.
likeQuery param search string filter or null String. May be null.
sellerQuery param filters by seller id Integer. May be null.

Request

GET /v26/devices-overview HTTP/1.1
Authorization: RestApiTester@se9876543210:9999
Host: t.srv4pos.com

Response

HTTP/1.1 200 OK Content-Type: application/json;charset=UTF-8
[ {/* This entity provides info about android (and not only) device. */ 'deviceInfo': {/* This entity provides info about android device. */ 'id': 5432, // Integer.
'deviceId': '34565673' // deviceIdType. May NOT be null.
}, // A complex object.
'latestInstallationInfo': {/* This entity provides info about android device. */ 'installationInfo': { 'id': 654353, // Deprecated, please use productionNumber Integer. May be null.
'deviceId': '111AAA222BBB3-022', // deviceIdType. May NOT be null.
'buildInfo': {'KEY1':'VALUE1', 'KEY2':'VALUE2'}, // A complex object. May NOT be null.
'applicationPackage': 'package', // applicationPackageType. May NOT be null.
'gcmRegistrationId': '123', // String. Minimum 1 characters.
'productionNumber': 'TEST100000000000000000081', // productionNumberType.
'registrationDate': 45672345, // Date: amount of milliseconds since UNIX epoch.
'gcmUnsubscribeDate': 45672345 // Date: amount of milliseconds since UNIX epoch.
}, // A complex object.
'deviceInfo': {/* This entity provides info about android device. */ 'id': 5432, // Integer.
'deviceId': '34565673' // deviceIdType. May NOT be null.
}, // A complex object.
'applicationDescriptionInfo': {/* Information about person. */ 'applicationPackage': 'super.package', // applicationPackageType.
'productionNumberPrefix': 'PRENP', // String.
'controlUnitRequired': true, // Boolean.
'name': 'Super application', // String.
'softwareVendor': 2, // Integer.
'autoActivationCondition': 'NEVER', // autoActivationConditionType.
'corporateIdValidationMethod': 'NONE' // corporateIdValidationMethodType.
}, // A complex object.
'buildInfoes': [ {/* Information about android device taken from android.os.Build. */ 'name': '', // String. Maximum 25 characters. May NOT be null.
'value': '', // String. Maximum 1024 characters. May NOT be null.
'installation': '' // String. May NOT be null.
} ], // List of objects.
'registrationOverviewInfoes': [ {/* Represents server-side entity available for admin. */ 'registrationId': , // Integer.
'cashRegisterName': 'cash name', // String. Maximum 16 characters. May NOT be null.
'sellerOverviewInfo': { 'name': 'CompanyName', // String. Maximum 96 characters. May be null.
'country': 'se', // countryType. May NOT be null.
'corporateId': '9876543210', // corporateIdType. May NOT be null.
'currency': 'SEK', // currencyType. May be null.
'countActiveCashRegisters': , // Integer.
'turnover': // Integer.
} // A complex object. May NOT be null.
} ] // List of objects.
} // A complex object.
} ]

Errors

404 ReferenceNotFoundJsonException

If some of passed query parameters wasn't found on server.

GET /v26/installations/{productionNumber}/build-infoes

Returns list of build infoes by production number.
productionNumberproductionNumberType. May NOT be null.

Request

GET /v26/installations/TEST100000000000000000081/build-infoes HTTP/1.1
Authorization: RestApiTester@se9876543210:9999
Host: t.srv4pos.com

Response

HTTP/1.1 200 OK Content-Type: application/json;charset=UTF-8
[ {/* Information about android device taken from android.os.Build. */ 'name': 'KEY', // String. Maximum 25 characters. May NOT be null.
'value': 'VALUE', // String. Maximum 1024 characters. May NOT be null.
'installation': 'TEST100000000000000000081' // String. May NOT be null.
} ]

Errors

404 NotFoundJsonException

If installation wasn't found.

403 ForbiddenJsonException

See there: INSUFFICIENT_ACCESS_RIGHTS .

GET /v26/kd-facets

Returns list of kd facets. One of the filters must