Download OpenAPI specification:Download
API for managing Receipts, Discounts, Customers, Wallets and Webhooks
The Dintero API is organized around REST. Our API has predictable, resource-oriented URLs, and uses HTTP response codes to indicate API errors. We use built-in HTTP features, like HTTP authentication and HTTP verbs, which are understood by off-the-shelf HTTP clients. We support cross-origin resource sharing, allowing you to interact securely with our API from a client-side web application (though you should never expose your secret API key in any public website's client-side code). JSON is returned by all API responses, including errors.
To make the API as explorable as possible, accounts have test mode and live mode API keys. There is no "switch" for changing between modes, just use the appropriate key to perform a live or test transaction. Requests made with test mode incur no cost.
Download the OpenAPI specification
Use this endpoint to obtains an access token by presenting its authorization grant
scopes:
oid required | string <^[PT]{1}(?=(?:.{3}|.{8})$)[0-9]*$> An id that uniquely identifies the account or owner (partner) |
audience required | string The unique identifier of the target API you want to access.
The audience must be a grant associated with the client that
has |
code required | string |
grant_type required | string Value: "authorization_code" |
client_id required | string |
redirect_uri | string The redirect URL which the user agent is redirected to after finishing a login. |
{- "grant_type": "authorization_code",
- "code": "string",
- "client_id": "string",
- "redirect_uri": "string",
}
{- "access_token": "eyJhbGci...t7P4",
- "token_type": "Bearer",
- "expires_in": 86400,
- "user_info": {
- "value": {
- "sub": "c06c4afe-d9e1-4c5d-939a-177d752a0944",
- "name": "Ada Lovelace"
}
}
}
Passwordless connections do not require the user to remember a password. Instead, another mechanism is used to prove identity, such as a one-time code sent through email or SMS, every time the account user logs in.
authorization_code
to allow sending verification-codescopes:
oid required | string <^[PT]{1}(?=(?:.{3}|.{8})$)[0-9]*$> An id that uniquely identifies the account or owner (partner) |
client_id required | string |
connection required | string Enum: "email" "sms" How to send the code to the user. |
audience required | string The unique identifier of the target API you want to access. |
string The user's email address | |
type | string Default: "customer" Enum: "company" "customer" Passwordless for type company/customer requires that the email is registered to a customers users |
send | string Default: "code" Value: "code" Use |
login_session_id | string Use |
{- "audience": "string",
- "client_id": "string",
- "connection": "email",
- "email": "string",
- "type": "company",
- "send": "code",
- "login_session_id": "string"
}
{- "error": {
- "code": "string",
- "errors": [
- { }
], - "message": "string"
}
}
Passwordless connections do not require the user to remember a password. Instead, another mechanism is used to prove identity, such as a one-time code sent through email or SMS, every time the account user logs in.
Use this endpoint to generate a one-time verification-code that can be sent to the user.
The client_id/audience must have a grant with type
authorization_code
to allow creating a verification-code
scopes:
oid required | string <^[PT]{1}(?=(?:.{3}|.{8})$)[0-9]*$> An id that uniquely identifies the account or owner (partner) |
audience required | string The unique identifier of the target API you want to grant the user |
client_id required | string The client whoose grants will be granted to the user, the |
user_id required | string The user_id / subject to grant access |
{- "audience": "string",
- "client_id": "string",
- "user_id": "string"
}
{- "verification_code": "string"
}
Use this endpoint to redirect to an URL with a ID token added.
oid required | string <^[PT]{1}(?=(?:.{3}|.{8})$)[0-9]*$> An id that uniquely identifies the account or owner (partner) |
redirect_uri required | string <uri> ^https?://.* The HTTP URL to redirect to |
object <= 5 properties Include custom claims to the ID token. Custom claims will be
prefixed by | |
claims | Array of strings Items Enum: "name" "email" Specify optional claims to include in the ID token |
{- "custom_claims": {
- "property1": "string",
- "property2": "string"
}, - "claims": [
- "name"
]
}
{
}
Use this endpoint to invalidate a Refresh Token if it has been compromised.
scopes:
oid required | string <^[PT]{1}(?=(?:.{3}|.{8})$)[0-9]*$> An id that uniquely identifies the account or owner (partner) |
token required | string |
{- "token": "YOUR_REFRESH_TOKEN"
}
{ }
Use this endpoint to directly request an access_token
Use HTTP Basic authentication scheme for
authenticating grant_type client_credentials
, use
client_id/client_secret as user/password.
Use HTTP Bearer authentication scheme for authenticating
grant_type authorization_code
or password
, where the
Bearer value must be a JWT toke with access to the token
endpoint.
Use HTTP Bearer authentication scheme for authenticating
grant_type account_user_token
, where the Bearer value
must be a account user JWT token.
Use ID token as Bearer toke if the user was authenticated externally. The ID must include a
Use HTTP Bearer authentication scheme for authenticating
grant_type refresh_token
where the Bearer value must
be an Access Token for the clients that was used to create
the Refresh Token.
When a request is made to the endpoint to get an access token,
normally you either get an error, or you get an access token.
However, when the MFA is enabled, the endpoint may return a new
error with error.code: mfa_required
.
When an mfa_required
error is returned, the client must perform
a challenge
. This is done by sending a request to the
auth/mfa/challenge endpoint
To verify MFA using an OOB challenge, the client must make a request to
this endpoint with grant_type=mfa-oob
. Include the oob_code
you
received from the challenge response, as well as the mfa_token
you
received as part of mfa_required error.
scopes:
oid required | string <^[PT]{1}(?=(?:.{3}|.{8})$)[0-9]*$> An id that uniquely identifies the account or owner (partner) |
grant_type required | string |
{- "grant_type": "account_user"
}
{- "access_token": "eyJhbGci...t7P4",
- "token_type": "Bearer",
- "expires_in": 86400,
- "refresh_token": "string"
}
Use this endpoint to exchange access_token to a sub-account
scopes:
partner_id required | string <^[PT]{1}\d{3}00000$> = 9 characters An id that uniquely identifies the partner account |
account_id required | string <^[PT]{1}\d{8}$> The account_id to create exchange access_token for |
{- "account_id": "string"
}
{- "access_token": "eyJhbGci...t7P4",
- "token_type": "Bearer",
- "expires_in": 86400,
- "refresh_token": "string"
}
Retrieve a list of all client applications
scopes:
oid required | string <^[PT]{1}(?=(?:.{3}|.{8})$)[0-9]*$> An id that uniquely identifies the account or owner (partner) |
[- {
- "id": "497f6eca-6276-4993-bfeb-53cbbbba6f08",
- "created_at": "2019-08-24T14:15:22Z",
- "created_by": "1c92f7e1-2897-4d46-bdcc-c127a914fb4e",
- "updated_at": "2019-08-24T14:15:22Z",
- "deleted_by": "1c92f7e1-2897-4d46-bdcc-c127a914fb4e",
- "deleted_at": "2019-08-24T14:15:22Z",
- "name": "string",
- "description": "string",
- "client_id": "string",
- "callbacks": [
- "string"
]
}
]
Creates a new client application.
scopes:
oid required | string <^[PT]{1}(?=(?:.{3}|.{8})$)[0-9]*$> An id that uniquely identifies the account or owner (partner) |
name | string |
description | string |
client_id | string Your client ID. |
callbacks | Array of strings |
{- "name": "string",
- "description": "string",
- "client_id": "string",
- "callbacks": [
- "string"
]
}
{- "id": "497f6eca-6276-4993-bfeb-53cbbbba6f08",
- "created_at": "2019-08-24T14:15:22Z",
- "created_by": "1c92f7e1-2897-4d46-bdcc-c127a914fb4e",
- "updated_at": "2019-08-24T14:15:22Z",
- "deleted_by": "1c92f7e1-2897-4d46-bdcc-c127a914fb4e",
- "deleted_at": "2019-08-24T14:15:22Z",
- "name": "string",
- "description": "string",
- "client_id": "string",
- "callbacks": [
- "string"
], - "client_secret": "JYCRP/x7iBGWA1fun0J9laH5sEg5cP9g/4QivhfGzm4"
}
Retrieves a client by its id.
scopes:
oid required | string <^[PT]{1}(?=(?:.{3}|.{8})$)[0-9]*$> An id that uniquely identifies the account or owner (partner) |
id required | string The id of the client |
{- "id": "497f6eca-6276-4993-bfeb-53cbbbba6f08",
- "created_at": "2019-08-24T14:15:22Z",
- "created_by": "1c92f7e1-2897-4d46-bdcc-c127a914fb4e",
- "updated_at": "2019-08-24T14:15:22Z",
- "deleted_by": "1c92f7e1-2897-4d46-bdcc-c127a914fb4e",
- "deleted_at": "2019-08-24T14:15:22Z",
- "name": "string",
- "description": "string",
- "client_id": "string",
- "callbacks": [
- "string"
]
}
Deletes a client and all its related assets
scopes:
oid required | string <^[PT]{1}(?=(?:.{3}|.{8})$)[0-9]*$> An id that uniquely identifies the account or owner (partner) |
id required | string The id of the client |
{- "id": "497f6eca-6276-4993-bfeb-53cbbbba6f08",
- "created_at": "2019-08-24T14:15:22Z",
- "created_by": "1c92f7e1-2897-4d46-bdcc-c127a914fb4e",
- "updated_at": "2019-08-24T14:15:22Z",
- "deleted_by": "1c92f7e1-2897-4d46-bdcc-c127a914fb4e",
- "deleted_at": "2019-08-24T14:15:22Z",
- "name": "string",
- "description": "string",
- "client_id": "string",
- "callbacks": [
- "string"
]
}
Rotate a client secret.
scopes:
oid required | string <^[PT]{1}(?=(?:.{3}|.{8})$)[0-9]*$> An id that uniquely identifies the account or owner (partner) |
id required | string The id of the client |
{- "id": "497f6eca-6276-4993-bfeb-53cbbbba6f08",
- "created_at": "2019-08-24T14:15:22Z",
- "created_by": "1c92f7e1-2897-4d46-bdcc-c127a914fb4e",
- "updated_at": "2019-08-24T14:15:22Z",
- "deleted_by": "1c92f7e1-2897-4d46-bdcc-c127a914fb4e",
- "deleted_at": "2019-08-24T14:15:22Z",
- "name": "string",
- "description": "string",
- "client_id": "string",
- "callbacks": [
- "string"
], - "client_secret": "JYCRP/x7iBGWA1fun0J9laH5sEg5cP9g/4QivhfGzm4"
}
Manage your Client Grants (also called Client Credentials Grants). Using Client Grants, your Client can request an access token using its credentials (a Client ID and a Client Secret). The access token then represents your Client during API calls.
Use the Grant type to limit how the grant can be used when requesting
an access token. A Grant with type password
can only be used when
requesting an access token with grant_type set to password
.
scopes:
oid required | string <^[PT]{1}(?=(?:.{3}|.{8})$)[0-9]*$> An id that uniquely identifies the account or owner (partner) |
audience | string <= 1 filter client grants by audience |
client_id | string <= 1 filter client grants by client_id |
[- {
- "id": "497f6eca-6276-4993-bfeb-53cbbbba6f08",
- "created_at": "2019-08-24T14:15:22Z",
- "created_by": "1c92f7e1-2897-4d46-bdcc-c127a914fb4e",
- "updated_at": "2019-08-24T14:15:22Z",
- "deleted_by": "1c92f7e1-2897-4d46-bdcc-c127a914fb4e",
- "deleted_at": "2019-08-24T14:15:22Z",
- "client_id": "string",
- "scope": [
- "receipts:write"
], - "type": "any",
- "oidc": {
- "client_id": "string",
- "client_secret": "string",
}
}
]
scopes:
oid required | string <^[PT]{1}(?=(?:.{3}|.{8})$)[0-9]*$> An id that uniquely identifies the account or owner (partner) |
client_id required | string |
audience required | string |
scope required | Array of strings[ items non-empty ] |
type | string Default: "any" Enum: "any" "authorization_code" "client_credentials" "password" Limit the usage of the grant. A grant with grant_types set
to only |
object Open ID connect configuration for the Grant. The option enables client to verify the identify of the End-User based on the authentication performed by an authorization server The grant type must be set to |
{- "client_id": "string",
- "scope": [
- "receipts:write"
], - "type": "any",
- "oidc": {
- "client_id": "string",
- "client_secret": "string",
}
}
{- "id": "497f6eca-6276-4993-bfeb-53cbbbba6f08",
- "created_at": "2019-08-24T14:15:22Z",
- "created_by": "1c92f7e1-2897-4d46-bdcc-c127a914fb4e",
- "updated_at": "2019-08-24T14:15:22Z",
- "deleted_by": "1c92f7e1-2897-4d46-bdcc-c127a914fb4e",
- "deleted_at": "2019-08-24T14:15:22Z",
- "client_id": "string",
- "scope": [
- "receipts:write"
], - "type": "any",
- "oidc": {
- "client_id": "string",
- "client_secret": "string",
}
}
scopes:
oid required | string <^[PT]{1}(?=(?:.{3}|.{8})$)[0-9]*$> An id that uniquely identifies the account or owner (partner) |
id required | string The id of the client grant to delete |
{- "id": "497f6eca-6276-4993-bfeb-53cbbbba6f08",
- "created_at": "2019-08-24T14:15:22Z",
- "created_by": "1c92f7e1-2897-4d46-bdcc-c127a914fb4e",
- "updated_at": "2019-08-24T14:15:22Z",
- "deleted_by": "1c92f7e1-2897-4d46-bdcc-c127a914fb4e",
- "deleted_at": "2019-08-24T14:15:22Z",
- "client_id": "string",
- "scope": [
- "receipts:write"
], - "type": "any",
- "oidc": {
- "client_id": "string",
- "client_secret": "string",
}
}
Retrieve filtered list of roles that can be assigned to users.
scopes:
oid required | string <^[PT]{1}(?=(?:.{3}|.{8})$)[0-9]*$> An id that uniquely identifies the account or owner (partner) |
search | string lookup roles matching id, name and description |
name | string lookup roles by name |
include_deleted | boolean Default: false include deleted roles in the response |
limit | integer [ 1 .. 100 ] Default: 10 A limit on the number of objects to be returned. Limit can range between 1 and 100 items, and the default is 10 items. |
starting_after | string cursor for use in pagination. starting_after is an object ID
that defines your place in the list. For instance, if you make
a list request and receive 100 objects, end the result contains
|
[- {
- "id": "497f6eca-6276-4993-bfeb-53cbbbba6f08",
- "created_at": "2019-08-24T14:15:22Z",
- "created_by": "1c92f7e1-2897-4d46-bdcc-c127a914fb4e",
- "updated_at": "2019-08-24T14:15:22Z",
- "deleted_by": "1c92f7e1-2897-4d46-bdcc-c127a914fb4e",
- "deleted_at": "2019-08-24T14:15:22Z",
- "name": "order support",
- "description": "Administrate orders",
- "scope": [
- "read:accounts",
- "read:billing",
- "admin:shopping"
]
}
]
scopes:
oid required | string <^[PT]{1}(?=(?:.{3}|.{8})$)[0-9]*$> An id that uniquely identifies the account or owner (partner) |
scope required | Array of strings[ items non-empty ] |
name | string |
description | string |
{- "name": "order support",
- "description": "Administrate orders",
- "scope": [
- "read:accounts",
- "read:billing",
- "admin:shopping"
]
}
{- "id": "497f6eca-6276-4993-bfeb-53cbbbba6f08",
- "created_at": "2019-08-24T14:15:22Z",
- "created_by": "1c92f7e1-2897-4d46-bdcc-c127a914fb4e",
- "updated_at": "2019-08-24T14:15:22Z",
- "deleted_by": "1c92f7e1-2897-4d46-bdcc-c127a914fb4e",
- "deleted_at": "2019-08-24T14:15:22Z",
- "name": "order support",
- "description": "Administrate orders",
- "scope": [
- "read:accounts",
- "read:billing",
- "admin:shopping"
]
}
scopes:
oid required | string <^[PT]{1}(?=(?:.{3}|.{8})$)[0-9]*$> An id that uniquely identifies the account or owner (partner) |
role_id required | string The id of the rule to delete |
{- "id": "497f6eca-6276-4993-bfeb-53cbbbba6f08",
- "created_at": "2019-08-24T14:15:22Z",
- "created_by": "1c92f7e1-2897-4d46-bdcc-c127a914fb4e",
- "updated_at": "2019-08-24T14:15:22Z",
- "deleted_by": "1c92f7e1-2897-4d46-bdcc-c127a914fb4e",
- "deleted_at": "2019-08-24T14:15:22Z",
- "name": "order support",
- "description": "Administrate orders",
- "scope": [
- "read:accounts",
- "read:billing",
- "admin:shopping"
]
}
scopes:
oid required | string <^[PT]{1}(?=(?:.{3}|.{8})$)[0-9]*$> An id that uniquely identifies the account or owner (partner) |
role_id required | string The id of the rule to delete |
scope required | Array of strings[ items non-empty ] |
name | string |
description | string |
{- "name": "order support",
- "description": "Administrate orders",
- "scope": [
- "read:accounts",
- "read:billing",
- "admin:shopping"
]
}
{- "id": "497f6eca-6276-4993-bfeb-53cbbbba6f08",
- "created_at": "2019-08-24T14:15:22Z",
- "created_by": "1c92f7e1-2897-4d46-bdcc-c127a914fb4e",
- "updated_at": "2019-08-24T14:15:22Z",
- "deleted_by": "1c92f7e1-2897-4d46-bdcc-c127a914fb4e",
- "deleted_at": "2019-08-24T14:15:22Z",
- "name": "order support",
- "description": "Administrate orders",
- "scope": [
- "read:accounts",
- "read:billing",
- "admin:shopping"
]
}
scopes:
oid required | string <^[PT]{1}(?=(?:.{3}|.{8})$)[0-9]*$> An id that uniquely identifies the account or owner (partner) |
role_id required | string The id of the rule to delete |
{- "id": "497f6eca-6276-4993-bfeb-53cbbbba6f08",
- "created_at": "2019-08-24T14:15:22Z",
- "created_by": "1c92f7e1-2897-4d46-bdcc-c127a914fb4e",
- "updated_at": "2019-08-24T14:15:22Z",
- "deleted_by": "1c92f7e1-2897-4d46-bdcc-c127a914fb4e",
- "deleted_at": "2019-08-24T14:15:22Z",
- "name": "order support",
- "description": "Administrate orders",
- "scope": [
- "read:accounts",
- "read:billing",
- "admin:shopping"
]
}
Retrieve the JSON Web Key Set (JWKS) that can be used
to validate access_token
scopes:
oid required | string <^[PT]{1}(?=(?:.{3}|.{8})$)[0-9]*$> An id that uniquely identifies the account or owner (partner) |
[- {
- "alg": "RS256",
- "kty": "RSA",
- "use": "sig",
- "n": "lC4ehVB6W0OCtNPnz8udYH9Ao83B6EKnHA5eTcMOap_lQZ-nKtS1lZwBj4wXRVc1XmS0d2OQFA1VMQ-dHLDE3CiGfsGqWbaiZFdW7U\nGLO1nAwfDdH6xp3xwpKOMewDXbAHJlXdYYAe2ap-CE9c5WLTUBU6JROuWcorHCNJisj1aExyiY5t3JQQVGpBz2oUIHo7NRzQoKimvp\ndMvMzcYnTlk1dhlG11b1GTkBclprm1BmOP7Ltjd7aEumOJWS67nKcAZzl48Zyg5KtV11V9F9dkGt25qHauqFKL7w3wu-DYhT0hmyFc\nwn-tXS6e6HQbfHhR_MQxysLtDGOk2ViWv8AQ\n",
- "e": "AQAB",
- "kid": "a8fdc205a9f19cc1c7507a60c4f01b13d11d7fd0"
}
]
Create a new user
scopes:
aid required | string <^[PT]{1}\d{8}$> = 9 characters An id that uniquely identifies the account. |
username required | string [ 1 .. 255 ] characters The user's username. |
password required | string >= 8 characters The user's password |
Array of objects (AuthUserLinks) Links to resources related to the user, links is required when MFA is enabled. | |
object (AuthUserMfa) Require Multi-factor authentication (MFA) for the user |
{- "username": "string",
- "links": [
- {
- "rel": "phone_number",
- "href": "tel:+4799999999"
}, - {
- "rel": "email",
- "href": "mailto:name@email.com"
}
], - "mfa": {
- "challenge_type": "string",
- "oob_channels": [
- "sms"
]
}, - "password": "stringst"
}
{- "id": "497f6eca-6276-4993-bfeb-53cbbbba6f08",
- "created_at": "2019-08-24T14:15:22Z",
- "created_by": "1c92f7e1-2897-4d46-bdcc-c127a914fb4e",
- "updated_at": "2019-08-24T14:15:22Z",
- "deleted_by": "1c92f7e1-2897-4d46-bdcc-c127a914fb4e",
- "deleted_at": "2019-08-24T14:15:22Z",
- "username": "string",
- "links": [
- {
- "rel": "phone_number",
- "href": "tel:+4799999999"
}, - {
- "rel": "email",
- "href": "mailto:name@email.com"
}
], - "mfa": {
- "challenge_type": "string",
- "oob_channels": [
- "sms"
]
}
}
Update existing user with new password
scopes:
aid required | string <^[PT]{1}\d{8}$> = 9 characters An id that uniquely identifies the account. |
username required | string <= 255 characters Username identifying the user |
password required | string >= 8 characters The user's password |
Array of objects (AuthUserLinks) Links to resources related to the user, links is required when MFA is enabled. | |
object (AuthUserMfa) Require Multi-factor authentication (MFA) for the user |
{- "password": "stringst",
- "links": [
- {
- "rel": "phone_number",
- "href": "tel:+4799999999"
}, - {
- "rel": "email",
- "href": "mailto:name@email.com"
}
], - "mfa": {
- "challenge_type": "string",
- "oob_channels": [
- "sms"
]
}
}
{- "id": "497f6eca-6276-4993-bfeb-53cbbbba6f08",
- "created_at": "2019-08-24T14:15:22Z",
- "created_by": "1c92f7e1-2897-4d46-bdcc-c127a914fb4e",
- "updated_at": "2019-08-24T14:15:22Z",
- "deleted_by": "1c92f7e1-2897-4d46-bdcc-c127a914fb4e",
- "deleted_at": "2019-08-24T14:15:22Z",
- "username": "string",
- "links": [
- {
- "rel": "phone_number",
- "href": "tel:+4799999999"
}, - {
- "rel": "email",
- "href": "mailto:name@email.com"
}
], - "mfa": {
- "challenge_type": "string",
- "oob_channels": [
- "sms"
]
}
}
Delete existing user
scopes:
aid required | string <^[PT]{1}\d{8}$> = 9 characters An id that uniquely identifies the account. |
username required | string <= 255 characters Username identifying the user |
{- "id": "497f6eca-6276-4993-bfeb-53cbbbba6f08",
- "created_at": "2019-08-24T14:15:22Z",
- "created_by": "1c92f7e1-2897-4d46-bdcc-c127a914fb4e",
- "updated_at": "2019-08-24T14:15:22Z",
- "deleted_by": "1c92f7e1-2897-4d46-bdcc-c127a914fb4e",
- "deleted_at": "2019-08-24T14:15:22Z",
- "username": "string",
- "links": [
- {
- "rel": "phone_number",
- "href": "tel:+4799999999"
}, - {
- "rel": "email",
- "href": "mailto:name@email.com"
}
], - "mfa": {
- "challenge_type": "string",
- "oob_channels": [
- "sms"
]
}
}
Update existing users username
scopes:
aid required | string <^[PT]{1}\d{8}$> = 9 characters An id that uniquely identifies the account. |
username required | string <= 255 characters Username identifying the user |
username required | string [ 1 .. 255 ] characters The user's new usernname |
{- "username": "string"
}
{- "id": "497f6eca-6276-4993-bfeb-53cbbbba6f08",
- "created_at": "2019-08-24T14:15:22Z",
- "created_by": "1c92f7e1-2897-4d46-bdcc-c127a914fb4e",
- "updated_at": "2019-08-24T14:15:22Z",
- "deleted_by": "1c92f7e1-2897-4d46-bdcc-c127a914fb4e",
- "deleted_at": "2019-08-24T14:15:22Z",
- "username": "string",
- "links": [
- {
- "rel": "phone_number",
- "href": "tel:+4799999999"
}, - {
- "rel": "email",
- "href": "mailto:name@email.com"
}
], - "mfa": {
- "challenge_type": "string",
- "oob_channels": [
- "sms"
]
}
}
Request a challenge for multi-factor authentication (MFA) based on the challenge types supported by the user.
The challenge_type is how the user will get the challenge and prove possession. Supported challenge types include:
oob
: for SMS messages or out-of-band (OOB)Use the response to request access token from the
auth/token endpoint
with grant_type=mfa_oob
scopes:
aid required | string <^[PT]{1}\d{8}$> = 9 characters An id that uniquely identifies the account. |
challenge_type required | string Value: "oob" The challenge type accepted by your application |
mfa_token required | string The token received from |
oob_channel | string Default: "sms" Enum: "sms" "email" The channel to use for OOB. Can only be provided when
|
{- "challenge_type": "oob",
- "oob_channel": "sms",
- "mfa_token": "string"
}
{- "challenge_type": "oob",
- "binding_method": "prompt",
- "oob_code": "bkaiew...akas"
}
Request a recovery for user with multi-factor authentication (MFA) enabled.
A recovery is done with two out-of-band (OOB) challenges over different channels.
Use the response to request access token from the
auth/token endpoint
with grant_type=mfa_oob
.
A 403 status
with mfa_required
error will be returned on success,
use the response to request a new challenge from the
auth/mfa/challenge endpoint.
scopes:
aid required | string <^[PT]{1}\d{8}$> = 9 characters An id that uniquely identifies the account. |
challenge_type required | string Value: "oob" The challenge type accepted by your application |
username required | string The end user's identifier. |
audience required | string The unique identifier of the target API you want to access. The audience must be a grant associated with the client used in the request |
oob_channel | string Default: "sms" Enum: "sms" "email" The channel to use for OOB. Can only be provided when
|
{- "challenge_type": "oob",
- "oob_channel": "sms",
- "username": "string",
}
{- "challenge_type": "oob",
- "binding_method": "prompt",
- "oob_code": "bkaiew...akas",
- "mfa_token": "string"
}
Create a new customer, customer_id
, email
and phone_number
must
be unique if specified.
scopes:
aid required | string <^[PT]{1}\d{8}$> = 9 characters An id that uniquely identifies the account. |
customer to create
type required | string Default: "customer" Enum: "customer" "company" "contact" "employee" "other" Describe type of a user.
|
metadata | object <= 40 properties A set of key/value pairs that you can attach to a customer object. It can be useful for storing additional information about the customer in a structured format. You can unset an individual key by setting its value to null and then saving. To clear all keys, set metadata to null |
first_name | string or null |
last_name | string or null |
string or null customer email,
case insensitive duplication control prevents
multiple user with same customer@example.com is equal to CUStOMer@EXAMPLE.com | |
phone_number | string or null <^\+?[1-9]\d{1,14}$> A phone number in E.164 number formatting. |
attributes | object Custom attributes |
status | string or null Status of the customer |
favorite_store | string or null customer favorite store |
object The source that recruited the customer | |
object Customers consent for marketing in different channels | |
Array of objects (CustomerAddress) | |
object (CustomerTerm) | |
object Company details, supported when type is Company | |
gender | string or null |
date_of_birth | string or null <date> |
Array of objects The users that it is a contact for, supported when type is | |
customer_id | string <= 255 characters The customer id you have defined for the customer. (must not have trailing or leading spaces) An auto-generated customer_id will be created if no customer_id is provided. |
password | string [ 8 .. 255 ] characters The customer password. The caller must have scope
|
pin | string = 6 characters ^\d{6}$ 6 digit customer pin, can only used for MFA login. The caller must have scope
|
{- "metadata": {
- "dob_year": 1985
}, - "first_name": "John",
- "last_name": "Doe",
- "email": "customer@example.com",
- "phone_number": "+4799999999",
- "attributes": { },
- "status": "string",
- "favorite_store": "string",
- "marketing_consent": {
- "sms": {
- "consent": true
}, - "email": {
- "consent": true
}
}, - "type": "customer",
- "addresses": [
- {
- "address_line": "Sommerkroveien 34",
- "address_line_2": "PB 123",
- "postal_code": "0349",
- "postal_place": "Oslo",
- "country": "NO",
- "latitude": 59.942112,
- "longitude": 10.716991,
- "type": "custom",
- "custom_type": "string",
- "comment": "5th floor, use doorbell."
}
], - "term": {
- "id": "497f6eca-6276-4993-bfeb-53cbbbba6f08"
}, - "company": {
- "organization_number": "123456789MVA",
- "bussiness_name": "TKP tech AS",
- "department": "sales department",
- "industry": "computer industry",
- "website": "string",
- "number_of_employees": "string"
}, - "gender": "male",
- "date_of_birth": "1990-09-20",
- "contact_for": [
- {
- "customer_id": "string"
}
], - "customer_id": "string",
- "password": "stringst",
- "pin": "string"
}
{- "metadata": {
- "dob_year": 1985
}, - "id": "497f6eca-6276-4993-bfeb-53cbbbba6f08",
- "created_at": "2019-08-24T14:15:22Z",
- "created_by": "1c92f7e1-2897-4d46-bdcc-c127a914fb4e",
- "updated_at": "2019-08-24T14:15:22Z",
- "deleted_by": "1c92f7e1-2897-4d46-bdcc-c127a914fb4e",
- "deleted_at": "2019-08-24T14:15:22Z",
- "first_name": "John",
- "last_name": "Doe",
- "email": "customer@example.com",
- "phone_number": "+4799999999",
- "attributes": { },
- "status": "string",
- "favorite_store": "string",
- "marketing_consent": {
- "sms": {
- "consent": true,
- "updated_at": "2018-01-12T13:42:00Z"
}, - "email": {
- "consent": true,
- "updated_at": "2018-01-12T13:42:00Z"
}
}, - "type": "customer",
- "addresses": [
- {
- "address_line": "Sommerkroveien 34",
- "address_line_2": "PB 123",
- "postal_code": "0349",
- "postal_place": "Oslo",
- "country": "NO",
- "latitude": 59.942112,
- "longitude": 10.716991,
- "type": "custom",
- "custom_type": "string",
- "comment": "5th floor, use doorbell."
}
], - "term": {
- "id": "497f6eca-6276-4993-bfeb-53cbbbba6f08",
- "accepted_at": "2019-08-24T14:15:22Z"
}, - "company": {
- "organization_number": "123456789MVA",
- "bussiness_name": "TKP tech AS",
- "department": "sales department",
- "industry": "computer industry",
- "website": "string",
- "number_of_employees": "string"
}, - "gender": "male",
- "date_of_birth": "1990-09-20",
- "contact_for": [
- {
- "customer_id": "string"
}
], - "customer_id": "string"
}
Check if there is users that match the parameters. The result will
match all parameters with AND
.
This endpoint must be enabled from PUT /customers/settings
scopes:
aid required | string <^[PT]{1}\d{8}$> = 9 characters An id that uniquely identifies the account. |
string lookup customer by email | |
phone_number | string lookup customer by phone_number |
{- "error": {
- "code": "string",
- "errors": [
- { }
], - "message": "string"
}
}
Get all customers, limited by parameters. The result will
match all parameters with AND
.
Search is done by prefix match, and +
in phone_number/email
must be URL encoded, (+4799999999 => %2B4799999999)
Users with type contact
are by default excluded from the result,
use type=contact
or type=any
to include contact users
The response from a request that match contact users will include the users that are linked from the contact
scopes:
aid required | string <^[PT]{1}\d{8}$> = 9 characters An id that uniquely identifies the account. |
token_value | string lookup customers by token value |
token_type | string lookup customer by token type |
string lookup customer by email | |
phone_number | string lookup customer by phone_number |
type | string Enum: "customer" "company" "contact" "employee" "other" "any" lookup customer by type |
search | string lookup customer where search term match name, phone number, customer_id or email. The search term will be matched with the user details |
tag_id | string lookup customers by tag id |
include_deleted | boolean Default: false include deleted customers in the response. A deleted user will only have an id/customer_id, created_at/created_by and deleted_at/deleted_by set All other details of a customer, like email or phone_number will be deleted. |
attributes_keys | Array of strings <= 4 items include customers that has all the attributes. |
attributes_values | Array of strings <= 4 items Combine with |
since_datetime | string <date-time> lookup customers that has been added or modified
since an ISO timestamp. NOTE: this parameter can't be combined
with |
limit | integer [ 1 .. 100 ] Default: 10 A limit on the number of objects to be returned. Limit can range between 1 and 100 items, and the default is 10 items. |
starting_after | string cursor for use in pagination. starting_after is an object ID
that defines your place in the list. For instance, if you make
a list request and receive 100 objects, end the result contains
|
total | boolean Default: false include |
[- {
- "metadata": {
- "dob_year": 1985
}, - "id": "497f6eca-6276-4993-bfeb-53cbbbba6f08",
- "created_at": "2019-08-24T14:15:22Z",
- "created_by": "1c92f7e1-2897-4d46-bdcc-c127a914fb4e",
- "updated_at": "2019-08-24T14:15:22Z",
- "deleted_by": "1c92f7e1-2897-4d46-bdcc-c127a914fb4e",
- "deleted_at": "2019-08-24T14:15:22Z",
- "first_name": "John",
- "last_name": "Doe",
- "email": "customer@example.com",
- "phone_number": "+4799999999",
- "attributes": { },
- "status": "string",
- "favorite_store": "string",
- "marketing_consent": {
- "sms": {
- "consent": true,
- "updated_at": "2018-01-12T13:42:00Z"
}, - "email": {
- "consent": true,
- "updated_at": "2018-01-12T13:42:00Z"
}
}, - "type": "customer",
- "addresses": [
- {
- "address_line": "Sommerkroveien 34",
- "address_line_2": "PB 123",
- "postal_code": "0349",
- "postal_place": "Oslo",
- "country": "NO",
- "latitude": 59.942112,
- "longitude": 10.716991,
- "type": "custom",
- "custom_type": "string",
- "comment": "5th floor, use doorbell."
}
], - "term": {
- "id": "497f6eca-6276-4993-bfeb-53cbbbba6f08",
- "accepted_at": "2019-08-24T14:15:22Z"
}, - "company": {
- "organization_number": "123456789MVA",
- "bussiness_name": "TKP tech AS",
- "department": "sales department",
- "industry": "computer industry",
- "website": "string",
- "number_of_employees": "string"
}, - "gender": "male",
- "date_of_birth": "1990-09-20",
- "contact_for": [
- {
- "customer_id": "string"
}
], - "customer_id": "string"
}
]
Customer details scopes:
aid required | string <^[PT]{1}\d{8}$> = 9 characters An id that uniquely identifies the account. |
customer_id required | string <= 255 characters The customer id you have defined for the customer. (must not have trailing or leading spaces) |
{- "metadata": {
- "dob_year": 1985
}, - "id": "497f6eca-6276-4993-bfeb-53cbbbba6f08",
- "created_at": "2019-08-24T14:15:22Z",
- "created_by": "1c92f7e1-2897-4d46-bdcc-c127a914fb4e",
- "updated_at": "2019-08-24T14:15:22Z",
- "deleted_by": "1c92f7e1-2897-4d46-bdcc-c127a914fb4e",
- "deleted_at": "2019-08-24T14:15:22Z",
- "first_name": "John",
- "last_name": "Doe",
- "email": "customer@example.com",
- "phone_number": "+4799999999",
- "attributes": { },
- "status": "string",
- "favorite_store": "string",
- "marketing_consent": {
- "sms": {
- "consent": true,
- "updated_at": "2018-01-12T13:42:00Z"
}, - "email": {
- "consent": true,
- "updated_at": "2018-01-12T13:42:00Z"
}
}, - "type": "customer",
- "addresses": [
- {
- "address_line": "Sommerkroveien 34",
- "address_line_2": "PB 123",
- "postal_code": "0349",
- "postal_place": "Oslo",
- "country": "NO",
- "latitude": 59.942112,
- "longitude": 10.716991,
- "type": "custom",
- "custom_type": "string",
- "comment": "5th floor, use doorbell."
}
], - "term": {
- "id": "497f6eca-6276-4993-bfeb-53cbbbba6f08",
- "accepted_at": "2019-08-24T14:15:22Z"
}, - "company": {
- "organization_number": "123456789MVA",
- "bussiness_name": "TKP tech AS",
- "department": "sales department",
- "industry": "computer industry",
- "website": "string",
- "number_of_employees": "string"
}, - "gender": "male",
- "date_of_birth": "1990-09-20",
- "contact_for": [
- {
- "customer_id": "string"
}
], - "customer_id": "string"
}
Update customer properties, properties not included in the body will remain unchanged. scopes:
aid required | string <^[PT]{1}\d{8}$> = 9 characters An id that uniquely identifies the account. |
customer_id required | string <= 255 characters The customer id you have defined for the customer. (must not have trailing or leading spaces) |
Customer update
first_name | string or null |
last_name | string or null |
string or null customer email,
case insensitive duplication control prevents
multiple user with same customer@example.com is equal to CUStOMer@EXAMPLE.com | |
phone_number | string or null <^\+?[1-9]\d{1,14}$> A phone number in E.164 number formatting. |
attributes | object Custom attributes |
status | string or null Status of the customer |
favorite_store | string or null customer favorite store |
object The source that recruited the customer | |
object Customers consent for marketing in different channels | |
type | string Default: "customer" Enum: "customer" "company" "contact" "employee" "other" Describe type of a user.
|
Array of objects (CustomerAddress) | |
object (CustomerTerm) | |
object Company details, supported when type is Company | |
gender | string or null |
date_of_birth | string or null <date> |
Array of objects The users that it is a contact for, supported when type is | |
password | string [ 8 .. 255 ] characters The customer password. The caller must have scope
|
pin | string = 6 characters ^\d{6}$ 6 digit customer pin, can only be used for MFA login. The caller must have scope
|
{- "first_name": "John",
- "last_name": "Doe",
- "email": "customer@example.com",
- "phone_number": "+4799999999",
- "attributes": { },
- "status": "string",
- "favorite_store": "string",
- "marketing_consent": {
- "sms": {
- "consent": true
}, - "email": {
- "consent": true
}
}, - "type": "customer",
- "addresses": [
- {
- "address_line": "Sommerkroveien 34",
- "address_line_2": "PB 123",
- "postal_code": "0349",
- "postal_place": "Oslo",
- "country": "NO",
- "latitude": 59.942112,
- "longitude": 10.716991,
- "type": "custom",
- "custom_type": "string",
- "comment": "5th floor, use doorbell."
}
], - "term": {
- "id": "497f6eca-6276-4993-bfeb-53cbbbba6f08"
}, - "company": {
- "organization_number": "123456789MVA",
- "bussiness_name": "TKP tech AS",
- "department": "sales department",
- "industry": "computer industry",
- "website": "string",
- "number_of_employees": "string"
}, - "gender": "male",
- "date_of_birth": "1990-09-20",
- "contact_for": [
- {
- "customer_id": "string"
}
], - "password": "stringst",
- "pin": "string"
}
{- "metadata": {
- "dob_year": 1985
}, - "id": "497f6eca-6276-4993-bfeb-53cbbbba6f08",
- "created_at": "2019-08-24T14:15:22Z",
- "created_by": "1c92f7e1-2897-4d46-bdcc-c127a914fb4e",
- "updated_at": "2019-08-24T14:15:22Z",
- "deleted_by": "1c92f7e1-2897-4d46-bdcc-c127a914fb4e",
- "deleted_at": "2019-08-24T14:15:22Z",
- "first_name": "John",
- "last_name": "Doe",
- "email": "customer@example.com",
- "phone_number": "+4799999999",
- "attributes": { },
- "status": "string",
- "favorite_store": "string",
- "marketing_consent": {
- "sms": {
- "consent": true,
- "updated_at": "2018-01-12T13:42:00Z"
}, - "email": {
- "consent": true,
- "updated_at": "2018-01-12T13:42:00Z"
}
}, - "type": "customer",
- "addresses": [
- {
- "address_line": "Sommerkroveien 34",
- "address_line_2": "PB 123",
- "postal_code": "0349",
- "postal_place": "Oslo",
- "country": "NO",
- "latitude": 59.942112,
- "longitude": 10.716991,
- "type": "custom",
- "custom_type": "string",
- "comment": "5th floor, use doorbell."
}
], - "term": {
- "id": "497f6eca-6276-4993-bfeb-53cbbbba6f08",
- "accepted_at": "2019-08-24T14:15:22Z"
}, - "company": {
- "organization_number": "123456789MVA",
- "bussiness_name": "TKP tech AS",
- "department": "sales department",
- "industry": "computer industry",
- "website": "string",
- "number_of_employees": "string"
}, - "gender": "male",
- "date_of_birth": "1990-09-20",
- "contact_for": [
- {
- "customer_id": "string"
}
], - "customer_id": "string"
}
Delete single customer scopes:
aid required | string <^[PT]{1}\d{8}$> = 9 characters An id that uniquely identifies the account. |
customer_id required | string <= 255 characters The customer id you have defined for the customer. (must not have trailing or leading spaces) |
delete_tokens | boolean Default: false Delete all tokens owned by the customer |
{- "metadata": {
- "dob_year": 1985
}, - "id": "497f6eca-6276-4993-bfeb-53cbbbba6f08",
- "created_at": "2019-08-24T14:15:22Z",
- "created_by": "1c92f7e1-2897-4d46-bdcc-c127a914fb4e",
- "updated_at": "2019-08-24T14:15:22Z",
- "deleted_by": "1c92f7e1-2897-4d46-bdcc-c127a914fb4e",
- "deleted_at": "2019-08-24T14:15:22Z",
- "first_name": "John",
- "last_name": "Doe",
- "email": "customer@example.com",
- "phone_number": "+4799999999",
- "attributes": { },
- "status": "string",
- "favorite_store": "string",
- "marketing_consent": {
- "sms": {
- "consent": true,
- "updated_at": "2018-01-12T13:42:00Z"
}, - "email": {
- "consent": true,
- "updated_at": "2018-01-12T13:42:00Z"
}
}, - "type": "customer",
- "addresses": [
- {
- "address_line": "Sommerkroveien 34",
- "address_line_2": "PB 123",
- "postal_code": "0349",
- "postal_place": "Oslo",
- "country": "NO",
- "latitude": 59.942112,
- "longitude": 10.716991,
- "type": "custom",
- "custom_type": "string",
- "comment": "5th floor, use doorbell."
}
], - "term": {
- "id": "497f6eca-6276-4993-bfeb-53cbbbba6f08",
- "accepted_at": "2019-08-24T14:15:22Z"
}, - "company": {
- "organization_number": "123456789MVA",
- "bussiness_name": "TKP tech AS",
- "department": "sales department",
- "industry": "computer industry",
- "website": "string",
- "number_of_employees": "string"
}, - "gender": "male",
- "date_of_birth": "1990-09-20",
- "contact_for": [
- {
- "customer_id": "string"
}
], - "customer_id": "string"
}
Update customer_id for an customer
warning: Any external resources "owned" by the user, i.e
receipts, discounts etc. will not be updated with the new
customer_id.
A new metadata property dintero_change_customer_id_{timestamp}.{hash}
will be added everytime the customer_id is changed
Following data will be included in the metadata property
aid required | string <^[PT]{1}\d{8}$> = 9 characters An id that uniquely identifies the account. |
customer_id required | string <= 255 characters The customer id you have defined for the customer. (must not have trailing or leading spaces) |
Customer update
customer_id | string [ 1 .. 255 ] characters New customer_id (must not have trailing or leading spaces). |
{- "customer_id": "string"
}
{- "metadata": {
- "dob_year": 1985
}, - "id": "497f6eca-6276-4993-bfeb-53cbbbba6f08",
- "created_at": "2019-08-24T14:15:22Z",
- "created_by": "1c92f7e1-2897-4d46-bdcc-c127a914fb4e",
- "updated_at": "2019-08-24T14:15:22Z",
- "deleted_by": "1c92f7e1-2897-4d46-bdcc-c127a914fb4e",
- "deleted_at": "2019-08-24T14:15:22Z",
- "first_name": "John",
- "last_name": "Doe",
- "email": "customer@example.com",
- "phone_number": "+4799999999",
- "attributes": { },
- "status": "string",
- "favorite_store": "string",
- "marketing_consent": {
- "sms": {
- "consent": true,
- "updated_at": "2018-01-12T13:42:00Z"
}, - "email": {
- "consent": true,
- "updated_at": "2018-01-12T13:42:00Z"
}
}, - "type": "customer",
- "addresses": [
- {
- "address_line": "Sommerkroveien 34",
- "address_line_2": "PB 123",
- "postal_code": "0349",
- "postal_place": "Oslo",
- "country": "NO",
- "latitude": 59.942112,
- "longitude": 10.716991,
- "type": "custom",
- "custom_type": "string",
- "comment": "5th floor, use doorbell."
}
], - "term": {
- "id": "497f6eca-6276-4993-bfeb-53cbbbba6f08",
- "accepted_at": "2019-08-24T14:15:22Z"
}, - "company": {
- "organization_number": "123456789MVA",
- "bussiness_name": "TKP tech AS",
- "department": "sales department",
- "industry": "computer industry",
- "website": "string",
- "number_of_employees": "string"
}, - "gender": "male",
- "date_of_birth": "1990-09-20",
- "contact_for": [
- {
- "customer_id": "string"
}
], - "customer_id": "string"
}
Get the token events scopes:
aid required | string <^[PT]{1}\d{8}$> = 9 characters An id that uniquely identifies the account. |
limit | integer [ 1 .. 100 ] Default: 10 A limit on the number of objects to be returned. Limit can range between 1 and 100 items, and the default is 10 items. |
starting_after | string cursor for use in pagination. starting_after is an object ID
that defines your place in the list. For instance, if you make
a list request and receive 100 objects, end the result contains
|
since_datetime | string <date-time> Only token events added/updated at or after this time is returned
NOTE: this parameter can't be combined with |
deleted_since | string <date-time> return only token events that has been deleted |
[- {
- "id": "string",
- "status": "DELETED",
- "events": [
- {
- "created_at": "2018-01-31T16:56:33Z",
- "event": "anonymous token",
- "status": "PENDING"
}, - {
- "created_at": "2018-02-05T00:00:00Z",
- "event": "reqruited",
- "status": "DELETED"
}
]
}
]
Delete the connection between token (type/value) and list of events. Include an event in the request to store the reason for the request scopes:
aid required | string <^[PT]{1}\d{8}$> = 9 characters An id that uniquely identifies the account. |
required | object (TokenTypeValue) Lookup by token type and value |
object Record an delete event, the status will be set to DELETED. |
{- "token": {
- "type": "string",
- "value": "string"
}, - "event": {
- "event": "customer registered in webshop",
- "metadata": { }
}
}
Find details about a token, inclusive details about any customer the token belongs to and any token events recorded Include event in the request to update the status of the token scopes:
aid required | string <^[PT]{1}\d{8}$> = 9 characters An id that uniquely identifies the account. |
required | object (TokenTypeValue) Lookup by token type and value |
object (TokenEvent) Record event data about a token An event can be created before the customer exist and before the token has been added to the customer |
{- "token": {
- "type": "string",
- "value": "string"
}, - "event": {
- "event": "customer declined signup in store",
- "status": "OPT_OUT",
- "metadata": {
- "store_id": "SID1234"
}
}
}
{- "id": "string",
- "customer": {
- "metadata": {
- "dob_year": 1985
}, - "id": "497f6eca-6276-4993-bfeb-53cbbbba6f08",
- "created_at": "2019-08-24T14:15:22Z",
- "created_by": "1c92f7e1-2897-4d46-bdcc-c127a914fb4e",
- "updated_at": "2019-08-24T14:15:22Z",
- "deleted_by": "1c92f7e1-2897-4d46-bdcc-c127a914fb4e",
- "deleted_at": "2019-08-24T14:15:22Z",
- "first_name": "John",
- "last_name": "Doe",
- "email": "customer@example.com",
- "phone_number": "+4799999999",
- "attributes": { },
- "status": "string",
- "favorite_store": "string",
- "marketing_consent": {
- "sms": {
- "consent": true,
- "updated_at": "2018-01-12T13:42:00Z"
}, - "email": {
- "consent": true,
- "updated_at": "2018-01-12T13:42:00Z"
}
}, - "type": "customer",
- "addresses": [
- {
- "address_line": "Sommerkroveien 34",
- "address_line_2": "PB 123",
- "postal_code": "0349",
- "postal_place": "Oslo",
- "country": "NO",
- "latitude": 59.942112,
- "longitude": 10.716991,
- "type": "custom",
- "custom_type": "string",
- "comment": "5th floor, use doorbell."
}
], - "term": {
- "id": "497f6eca-6276-4993-bfeb-53cbbbba6f08",
- "accepted_at": "2019-08-24T14:15:22Z"
}, - "company": {
- "organization_number": "123456789MVA",
- "bussiness_name": "TKP tech AS",
- "department": "sales department",
- "industry": "computer industry",
- "website": "string",
- "number_of_employees": "string"
}, - "gender": "male",
- "date_of_birth": "1990-09-20",
- "contact_for": [
- {
- "customer_id": "string"
}
], - "customer_id": "string"
}, - "token": {
- "id": "497f6eca-6276-4993-bfeb-53cbbbba6f08",
- "created_at": "2019-08-24T14:15:22Z",
- "created_by": "1c92f7e1-2897-4d46-bdcc-c127a914fb4e",
- "updated_at": "2019-08-24T14:15:22Z",
- "deleted_by": "1c92f7e1-2897-4d46-bdcc-c127a914fb4e",
- "deleted_at": "2019-08-24T14:15:22Z",
- "token_id": "string",
- "type": "sha1:email",
- "value": "a1b79ef1a62d94ffa86b3f3d846df0ee3993af92",
- "metadata": {
- "exp_month": 10,
- "exp_year": 20,
- "mask_pan": "**** **** **** 3477"
}
}, - "status": "OPT_OUT",
- "events": [
- {
- "expires_at": "2019-08-24T14:15:22Z",
- "created_at": "2019-08-24T14:15:22Z",
- "event": "customer declined signup in store",
- "status": "OPT_OUT",
- "metadata": {
- "store_id": "SID1234"
}
}
]
}
Get all tokens for a Customer scopes:
aid required | string <^[PT]{1}\d{8}$> = 9 characters An id that uniquely identifies the account. |
customer_id required | string <= 255 characters The customer id you have defined for the customer. (must not have trailing or leading spaces) |
type | string filter tokens on type |
limit | integer [ 1 .. 100 ] Default: 10 A limit on the number of objects to be returned. Limit can range between 1 and 100 items, and the default is 10 items. |
starting_after | string cursor for use in pagination. starting_after is an object ID
that defines your place in the list. For instance, if you make
a list request and receive 100 objects, end the result contains
|
total | boolean Default: false include |
include_deleted | boolean Default: true include deleted tokens in the response. |
[- {
- "id": "497f6eca-6276-4993-bfeb-53cbbbba6f08",
- "created_at": "2019-08-24T14:15:22Z",
- "created_by": "1c92f7e1-2897-4d46-bdcc-c127a914fb4e",
- "updated_at": "2019-08-24T14:15:22Z",
- "deleted_by": "1c92f7e1-2897-4d46-bdcc-c127a914fb4e",
- "deleted_at": "2019-08-24T14:15:22Z",
- "token_id": "string",
- "type": "sha1:email",
- "value": "a1b79ef1a62d94ffa86b3f3d846df0ee3993af92",
- "metadata": {
- "exp_month": 10,
- "exp_year": 20,
- "mask_pan": "**** **** **** 3477"
}
}
]
Create a new customer token scopes:
aid required | string <^[PT]{1}\d{8}$> = 9 characters An id that uniquely identifies the account. |
customer_id required | string <= 255 characters The customer id you have defined for the customer. (must not have trailing or leading spaces) |
delete_token_events | boolean Default: false delete all token events recorded on token type/value before creating new customer token |
customer token to add
type required | string non-empty identifies how or who is resposible for the token value |
value required | string non-empty |
token_id | string [ 1 .. 255 ] characters The token id you have defined for the token. (must not have trailing or leading spaces). An auto-generated token_id will be created if no token_id is provided. |
metadata | object Additional metadata about the token or the entity the token was created from |
{- "token_id": "string",
- "type": "sha1:email",
- "value": "a1b79ef1a62d94ffa86b3f3d846df0ee3993af92",
- "metadata": {
- "exp_month": 10,
- "exp_year": 20,
- "mask_pan": "**** **** **** 3477"
}
}
{- "id": "497f6eca-6276-4993-bfeb-53cbbbba6f08",
- "created_at": "2019-08-24T14:15:22Z",
- "created_by": "1c92f7e1-2897-4d46-bdcc-c127a914fb4e",
- "updated_at": "2019-08-24T14:15:22Z",
- "deleted_by": "1c92f7e1-2897-4d46-bdcc-c127a914fb4e",
- "deleted_at": "2019-08-24T14:15:22Z",
- "token_id": "string",
- "type": "sha1:email",
- "value": "a1b79ef1a62d94ffa86b3f3d846df0ee3993af92",
- "metadata": {
- "exp_month": 10,
- "exp_year": 20,
- "mask_pan": "**** **** **** 3477"
}
}
Delete Token
scopes:
aid required | string <^[PT]{1}\d{8}$> = 9 characters An id that uniquely identifies the account. |
customer_id required | string <= 255 characters The customer id you have defined for the customer. (must not have trailing or leading spaces) |
tid required | string <= 255 characters The token id you have defined for the token. (must not have trailing or leading spaces) |
{- "id": "497f6eca-6276-4993-bfeb-53cbbbba6f08",
- "created_at": "2019-08-24T14:15:22Z",
- "created_by": "1c92f7e1-2897-4d46-bdcc-c127a914fb4e",
- "updated_at": "2019-08-24T14:15:22Z",
- "deleted_by": "1c92f7e1-2897-4d46-bdcc-c127a914fb4e",
- "deleted_at": "2019-08-24T14:15:22Z",
- "token_id": "string",
- "type": "sha1:email",
- "value": "a1b79ef1a62d94ffa86b3f3d846df0ee3993af92",
- "metadata": {
- "exp_month": 10,
- "exp_year": 20,
- "mask_pan": "**** **** **** 3477"
}
}
Specify the email address of the user whose password you
would like to reset. If the call is successful, the user
will receive an email prompting them to change their password.
The caller must have scope write:accounts:/auth/users
to perform a
change password request.
scopes:
aid required | string <^[PT]{1}\d{8}$> = 9 characters An id that uniquely identifies the account. |
audience required | string The unique identifier of the target API you want to access. The audience must be a grant associated with the client used when calling this resource. |
email required | string |
type required | string Enum: "customer" "company" user type to login, required as users with different type can share email |
{- "email": "string",
- "audience": "string",
- "type": "customer"
}
{- "error": {
- "code": "string",
- "errors": [
- { }
], - "message": "string"
}
}
Login a customer user, the caller must have scope
write:accounts:/auth/users
.
If MFA is enabled on account, use
write:accounts:/auth/users/no-mfa
to skip MFA.
scopes:
aid required | string <^[PT]{1}\d{8}$> = 9 characters An id that uniquely identifies the account. |
credentials
audience required | string The unique identifier of the target API you want to access. The audience must be a grant associated with the client used when calling this resource. |
type required | string Enum: "customer" "company" user type to login, required as users with different type can share email |
password required | string [ 4 .. 255 ] characters The customer pin or password. The caller must have scope
|
string Required if | |
ident_type | string Enum: "phone_number" "email" Required if |
ident | string Email or phone_number, depending on the Required if |
{- "email": "string",
- "ident_type": "phone_number",
- "ident": "string",
- "audience": "string",
- "type": "customer",
- "password": "string"
}
{- "access_token": "eyJhbGci...t7P4",
- "token_type": "Bearer",
- "expires_in": 86400,
- "refresh_token": "string"
}
Initiate a Multi-Factor Authentication for a customer user, the caller must
have scope write:accounts:/auth/users
to perform a login.
Post the ident_type
, along with the ident
and secret
.
The server will return a challenge response specifying the
challenge_type
that will have to be completed to when getting an access
token from the POST /v1/accounts/{oid}/auth/token
endpoint.
scopes:
aid required | string <^[PT]{1}\d{8}$> = 9 characters An id that uniquely identifies the account. |
credentials
audience required | string The unique identifier of the target API you want to access. The audience must be a grant associated with the client used when calling this resource. |
ident_type required | string Enum: "phone_number" "email" |
ident required | string Email or phone_number, depending on the |
type required | string Enum: "customer" "company" user type to login, required as users with different type can share email |
secret required | string The customers pin or password. |
{- "ident_type": "phone_number",
- "ident": "string",
- "audience": "string",
- "type": "customer",
- "secret": "string"
}
{- "links": [
- {
- "rel": "mfa_challenge",
},
], - "mfa_token": "string",
- "challenge_type": "oob",
- "oob_channel": "sms"
}
Initiate a Multi-Factor Authentication recovery login for a customer user
that has forgotten/lost their secret
.
Specify the ident_type and the ident (email or phone_number) of the user. If
the call is successful, the user will get an email with an one time recovery
code that has to be submitted to the mfa_recovery endpoint.
When a valid one time recovery has been posted the server response with a
regular MFA challenge.
Once authenticated the password or pin can be changed by updating the
customer.
scopes:
aid required | string <^[PT]{1}\d{8}$> = 9 characters An id that uniquely identifies the account. |
audience required | string The unique identifier of the target API you want to access. The audience must be a grant associated with the client used when calling this resource. |
ident_type required | string Enum: "phone_number" "email" |
ident required | string Email or phone_number, depending on the |
type required | string Enum: "customer" "company" user type to login, required as users with different type can share email |
{- "ident_type": "phone_number",
- "ident": "string",
- "audience": "string",
- "type": "customer"
}
{- "links": [
- {
- "rel": "mfa_oob",
- "href": "string"
}
], - "binding_method": "prompt",
- "oob_code": "bkaiew...akas",
- "mfa_token": "string",
- "challenge_type": "oob"
}
Get the status of customer email / phone_number communication scopes:
aid required | string <^[PT]{1}\d{8}$> = 9 characters An id that uniquely identifies the account. |
customer_id required | string <= 255 characters The customer id you have defined for the customer. (must not have trailing or leading spaces) |
{- "id": "497f6eca-6276-4993-bfeb-53cbbbba6f08",
- "created_at": "2019-08-24T14:15:22Z",
- "created_by": "1c92f7e1-2897-4d46-bdcc-c127a914fb4e",
- "updated_at": "2019-08-24T14:15:22Z",
- "deleted_by": "1c92f7e1-2897-4d46-bdcc-c127a914fb4e",
- "deleted_at": "2019-08-24T14:15:22Z",
- "communication": {
- "email": {
- "verified_at": "2019-08-24T14:15:22Z",
- "allowed": true
}, - "phone_number": {
- "verified_at": "2019-08-24T14:15:22Z",
- "allowed": true
}
}
}
Verify customer email/phone_number field. Consist of to steps:
aid required | string <^[PT]{1}\d{8}$> = 9 characters An id that uniquely identifies the account. |
customer_id required | string <= 255 characters The customer id you have defined for the customer. (must not have trailing or leading spaces) |
field required | string Enum: "email" "phone_number" field to verify |
operation required | string Enum: "send-verification-code" "confirm-verification-code" Verify operation |
verification code
code | string Verification code sent to customer |
{- "code": "string"
}
{- "error": {
- "code": "string",
- "errors": [
- { }
], - "message": "string"
}
}
Create customer terms and conditions scopes:
aid required | string <^[PT]{1}\d{8}$> = 9 characters An id that uniquely identifies the account. |
terms to create
terms required | string |
{- "terms": "string"
}
{- "id": "497f6eca-6276-4993-bfeb-53cbbbba6f08",
- "created_at": "2019-08-24T14:15:22Z",
- "created_by": "1c92f7e1-2897-4d46-bdcc-c127a914fb4e",
- "updated_at": "2019-08-24T14:15:22Z",
- "deleted_by": "1c92f7e1-2897-4d46-bdcc-c127a914fb4e",
- "deleted_at": "2019-08-24T14:15:22Z",
- "terms": "string"
}
Get all customer terms and conditions scopes:
aid required | string <^[PT]{1}\d{8}$> = 9 characters An id that uniquely identifies the account. |
limit | integer [ 1 .. 100 ] Default: 10 A limit on the number of objects to be returned. Limit can range between 1 and 100 items, and the default is 10 items. |
starting_after | string cursor for use in pagination. starting_after is an object ID
that defines your place in the list. For instance, if you make
a list request and receive 100 objects, end the result contains
|
include_deleted | boolean Default: false include deleted terms in the response |
[- {
- "id": "497f6eca-6276-4993-bfeb-53cbbbba6f08",
- "created_at": "2019-08-24T14:15:22Z",
- "created_by": "1c92f7e1-2897-4d46-bdcc-c127a914fb4e",
- "updated_at": "2019-08-24T14:15:22Z",
- "deleted_by": "1c92f7e1-2897-4d46-bdcc-c127a914fb4e",
- "deleted_at": "2019-08-24T14:15:22Z",
- "terms": "string"
}
]
Get single terms and conditions scopes:
aid required | string <^[PT]{1}\d{8}$> = 9 characters An id that uniquely identifies the account. |
tid required | string <uuid> terms id |
{- "id": "497f6eca-6276-4993-bfeb-53cbbbba6f08",
- "created_at": "2019-08-24T14:15:22Z",
- "created_by": "1c92f7e1-2897-4d46-bdcc-c127a914fb4e",
- "updated_at": "2019-08-24T14:15:22Z",
- "deleted_by": "1c92f7e1-2897-4d46-bdcc-c127a914fb4e",
- "deleted_at": "2019-08-24T14:15:22Z",
- "terms": "string"
}
Delete the customer term scopes:
aid required | string <^[PT]{1}\d{8}$> = 9 characters An id that uniquely identifies the account. |
tid required | string <uuid> terms id |
{- "id": "497f6eca-6276-4993-bfeb-53cbbbba6f08",
- "created_at": "2019-08-24T14:15:22Z",
- "created_by": "1c92f7e1-2897-4d46-bdcc-c127a914fb4e",
- "updated_at": "2019-08-24T14:15:22Z",
- "deleted_by": "1c92f7e1-2897-4d46-bdcc-c127a914fb4e",
- "deleted_at": "2019-08-24T14:15:22Z",
- "terms": "string"
}
Get customers settings
scopes:
aid required | string <^[PT]{1}\d{8}$> = 9 characters An id that uniquely identifies the account. |
{- "users": {
- "head": {
- "enabled": false
}, - "phone_number_validation": {
- "allow_duplicates": false
}, - "customer_id_format": "uuid",
- "mfa": {
- "enabled": false,
- "login": {
- "challenge_type": "oob",
- "oob_channel": "sms"
}, - "login_recovery": {
- "challenge_type": "oob",
- "oob_channel": "sms"
}
}, - "verifications": {
- "phone_number": "sms"
}
}, - "auto_tokens": {
- "phone_number": [
- {
- "type": "SHA256"
}
], - "email": [
- {
- "type": "SHA256"
}
]
}, - "tokens": {
- "event_expiry": [
- {
- "status": "OPT_OUT",
- "time_to_live": 15780000
}
]
}, - "attributes": [
- {
- "name": "string",
- "type": "string",
- "multiple_values": false,
- "private": false
}
]
}
Update customers settings
scopes:
aid required | string <^[PT]{1}\d{8}$> = 9 characters An id that uniquely identifies the account. |
customers settings
object customers user configurations | |
object Automatically generate tokens for these properties on the customer | |
object tokens configuration | |
Array of objects user attributes |
{- "users": {
- "head": {
- "enabled": false
}, - "phone_number_validation": {
- "allow_duplicates": false
}, - "customer_id_format": "uuid",
- "mfa": {
- "enabled": false,
- "login": {
- "challenge_type": "oob",
- "oob_channel": "sms"
}, - "login_recovery": {
- "challenge_type": "oob",
- "oob_channel": "sms"
}
}, - "verifications": {
- "phone_number": "sms"
}
}, - "auto_tokens": {
- "phone_number": [
- {
- "type": "SHA256"
}
], - "email": [
- {
- "type": "SHA256"
}
]
}, - "tokens": {
- "event_expiry": [
- {
- "status": "OPT_OUT",
- "time_to_live": 15780000
}
]
}, - "attributes": [
- {
- "name": "string",
- "type": "string",
- "multiple_values": false,
- "private": false
}
]
}
{- "users": {
- "head": {
- "enabled": false
}, - "phone_number_validation": {
- "allow_duplicates": false
}, - "customer_id_format": "uuid",
- "mfa": {
- "enabled": false,
- "login": {
- "challenge_type": "oob",
- "oob_channel": "sms"
}, - "login_recovery": {
- "challenge_type": "oob",
- "oob_channel": "sms"
}
}, - "verifications": {
- "phone_number": "sms"
}
}, - "auto_tokens": {
- "phone_number": [
- {
- "type": "SHA256"
}
], - "email": [
- {
- "type": "SHA256"
}
]
}, - "tokens": {
- "event_expiry": [
- {
- "status": "OPT_OUT",
- "time_to_live": 15780000
}
]
}, - "attributes": [
- {
- "name": "string",
- "type": "string",
- "multiple_values": false,
- "private": false
}
]
}
Get all discounts available for any customer given current date, result will exclude expired and inactive discounts
Use value of ref_id
as parameter value of starting_after
scopes:
aid required | string <^[PT]{1}\d{8}$> = 9 characters An id that uniquely identifies the account. |
limit | integer [ 1 .. 100 ] Default: 10 A limit on the number of objects to be returned. Limit can range between 1 and 100 items, and the default is 10 items. |
starting_after | string cursor for use in pagination. starting_after is an object ID
that defines your place in the list. For instance, if you make
a list request and receive 100 objects, end the result contains
|
no_customer_id | boolean Default: false List rules available for purchase where no customer id is provided. |
campaign_id | Array of strings |
[- {
- "id": "497f6eca-6276-4993-bfeb-53cbbbba6f08",
- "created_at": "2019-08-24T14:15:22Z",
- "created_by": "1c92f7e1-2897-4d46-bdcc-c127a914fb4e",
- "updated_at": "2019-08-24T14:15:22Z",
- "deleted_by": "1c92f7e1-2897-4d46-bdcc-c127a914fb4e",
- "deleted_at": "2019-08-24T14:15:22Z",
- "campaign_id": "string",
- "active": true,
- "private": false,
- "updated_by": "3d1e4824-5474-48e7-a369-4f603fa4c5b8",
- "type": "item",
- "name": "Spar 100,-",
- "receipt_text": "Mai Salg",
- "visible_from": "2019-08-24T14:15:22Z",
- "description": "Gjør et Stablestol kupp!",
- "limitation": {
- "discount_activation": [
- {
- "type": "deactivate_if_discount_active",
- "value": "string"
}
], - "discount_hours": {
- "timezone": "Europe/Oslo",
- "hours": [
- {
- "day": "mon",
- "start": "10:00",
- "end": "20:00"
}
]
}, - "discount_reward_usage": 1,
- "discount_combination": -1,
- "discount_eligible": "item_eligible_for_discount",
- "discount_repeat_usage": -1,
- "stamp_expire_days": 100,
- "blacklist": [
- {
- "id": "b714118",
- "group_id": "B1"
}
]
}, - "requirement": {
- "customer": {
- "addresses": [
- {
- "country": [
- "NO"
], - "postal_code": [
- "0349"
], - "postal_place": [
- "Oslo"
], - "custom_type": [
- "offsite"
], - "type": [
- "custom"
]
}
], - "company": {
- "bussiness_name": [
- "TKP tech AS"
], - "department": [
- "production",
- "research"
], - "industry": [
- "J62.0.1",
- "J62.0.2"
], - "number_of_employees": [
- "20"
], - "organization_number": [
- "123456789MVA"
],
}, - "date_of_birth": [
- "1990-09-20",
- "1990-05-10"
], - "favorite_store": [
- "sc029"
], - "first_name": [
- "John"
], - "gender": [
- "male"
], - "last_name": [
- "Doe"
], - "marketing_consent": {
- "email": {
- "consent": [
- "true"
]
}, - "sms": {
- "consent": [
- "true"
]
}
}, - "status": [
- "vip"
], - "term": {
- "id": [
- "string"
]
}, - "type": [
- "string"
], - "attributes": {
- "property1": [
- "string"
], - "property2": [
- "string"
]
}
}, - "item": {
- "quantity": 0,
- "mixes": [
- {
- "items": [
- {
- "id": "b714118"
}, - {
- "group_id": "g4"
}
], - "quantity": 0,
- "reward_eligible": true
}
], - "items": [
- {
- "id": "b714118",
- "group_id": "B1"
}
]
}, - "store_ids": [
- "sc029"
], - "gross_amount": 0,
- "currencies": [
- {
- "anything-but": [
- "NOK"
]
}
], - "stamp": 5,
- "discount_code": "TACO",
- "store": {
- "id": [
- "sc029"
], - "name": [
- "SC Oslo"
], - "business_name": [
- "SC Oslo AS"
], - "address": {
- "country": [
- "NO"
], - "postal_code": [
- "0349"
], - "postal_place": [
- "Oslo"
]
}, - "chain": [
- "SuperChain"
], - "email": [
- "contact@superchain.com"
], - "gln": [
- "5790001398644"
], - "organization_number": [
- "123456789MVA"
], - "phone_number": [
- "+4738260107"
], - "mcc": [
- 5814
], - "mcc_ranges": [
- {
- "start": 5814,
- "end": 5815
}
], - "bax": [
- "102603"
], - "terminal_id": [
- "T0292"
]
}, - "purchase_from": "2019-08-24T14:15:22Z",
- "purchase_to": "2019-08-24T14:15:22Z"
}, - "reward": {
- "type": "discount_amount",
- "value": 10000,
- "values": [
- {
- "items": [
- {
- "id": "b714118",
- "group_id": "B1"
}
], - "value": 0
}
], - "base": "net",
- "effect": "discount"
}, - "metadata": {
- "campaign_id": "V101",
- "is_featured": true,
- "dintero:private_text:kind": "Gold"
}, - "links": [
- {
- "rel": "thumbnail_discount_image"
}, - {
- "rel": "medium_discount_image"
}, - {
- "rel": "webshoop"
}, - {
- "rel": "newletter",
- "type": "application/pdf"
}
], - "ref_id": "string"
}
]
Create a new discount for an account.
A new discount will be unavailable for purchases until the discount is given to one or more customer.
Discount can be given to a customer by either adding a automation to the discount that will grant the discount to the customer from events received or by adding customers to the discount.
scopes:
aid required | string <^[PT]{1}\d{8}$> = 9 characters An id that uniquely identifies the account. |
Discount to create
required | object (Requirement) Discount base requirement |
required | object (Reward) |
campaign_id | string The campaign the rule belongs to |
active | boolean Default: true the discount is active and can be available for purchase (if given to any or all customers) |
private | boolean Default: false the discount will be excluded from public discount collection (GET /discounts/public/rules). |
name | string |
receipt_text | string Text that should be used when displaying the discount, e.g. on receipt |
visible_from | string <date-time> Make the discount visible to the customer from given date. Default behavior is to only return discount to the customer where the current time is between purchase_from and purchase_to |
description | string |
object (Limitation) | |
metadata | object <= 10 properties Additional metadata about the discount Metadata prefixed with and included in all other endpoints that returns discount rules |
Array of objects (Links) [ items <= 10 items ] Links to resources related to the discount |
{- "campaign_id": "string",
- "active": true,
- "private": false,
- "name": "Spar 100,-",
- "receipt_text": "Mai Salg",
- "visible_from": "2019-08-24T14:15:22Z",
- "description": "Gjør et Stablestol kupp!",
- "limitation": {
- "discount_activation": [
- {
- "type": "deactivate_if_discount_active",
- "value": "string"
}
], - "discount_hours": {
- "timezone": "Europe/Oslo",
- "hours": [
- {
- "day": "mon",
- "start": "10:00",
- "end": "20:00"
}
]
}, - "discount_reward_usage": 1,
- "discount_combination": -1,
- "discount_eligible": "item_eligible_for_discount",
- "discount_repeat_usage": -1,
- "stamp_expire_days": 100,
- "blacklist": [
- {
- "id": "b714118",
- "group_id": "B1"
}
]
}, - "requirement": {
- "customer": {
- "addresses": [
- {
- "country": [
- "NO"
], - "postal_code": [
- "0349"
], - "postal_place": [
- "Oslo"
], - "custom_type": [
- "offsite"
], - "type": [
- "custom"
]
}
], - "company": {
- "bussiness_name": [
- "TKP tech AS"
], - "department": [
- "production",
- "research"
], - "industry": [
- "J62.0.1",
- "J62.0.2"
], - "number_of_employees": [
- "20"
], - "organization_number": [
- "123456789MVA"
],
}, - "date_of_birth": [
- "1990-09-20",
- "1990-05-10"
], - "favorite_store": [
- "sc029"
], - "first_name": [
- "John"
], - "gender": [
- "male"
], - "last_name": [
- "Doe"
], - "marketing_consent": {
- "email": {
- "consent": [
- "true"
]
}, - "sms": {
- "consent": [
- "true"
]
}
}, - "status": [
- "vip"
], - "term": {
- "id": [
- "string"
]
}, - "type": [
- "string"
], - "attributes": {
- "property1": [
- "string"
], - "property2": [
- "string"
]
}
}, - "item": {
- "quantity": 0,
- "mixes": [
- {
- "items": [
- {
- "id": "b714118"
}, - {
- "group_id": "g4"
}
], - "quantity": 0,
- "reward_eligible": true
}
], - "items": [
- {
- "id": "b714118",
- "group_id": "B1"
}
]
}, - "store_ids": [
- "sc029"
], - "gross_amount": 0,
- "currencies": [
- {
- "anything-but": [
- "NOK"
]
}
], - "stamp": 5,
- "discount_code": "TACO",
- "store": {
- "id": [
- "sc029"
], - "name": [
- "SC Oslo"
], - "business_name": [
- "SC Oslo AS"
], - "address": {
- "country": [
- "NO"
], - "postal_code": [
- "0349"
], - "postal_place": [
- "Oslo"
]
}, - "chain": [
- "SuperChain"
], - "email": [
- "contact@superchain.com"
], - "gln": [
- "5790001398644"
], - "organization_number": [
- "123456789MVA"
], - "phone_number": [
- "+4738260107"
], - "mcc": [
- 5814
], - "mcc_ranges": [
- {
- "start": 5814,
- "end": 5815
}
], - "bax": [
- "102603"
], - "terminal_id": [
- "T0292"
]
}, - "purchase_from": "2019-08-24T14:15:22Z",
- "purchase_to": "2019-08-24T14:15:22Z"
}, - "reward": {
- "type": "discount_amount",
- "value": 10000,
- "values": [
- {
- "items": [
- {
- "id": "b714118",
- "group_id": "B1"
}
], - "value": 0
}
], - "base": "net",
- "effect": "discount"
}, - "metadata": {
- "campaign_id": "V101",
- "is_featured": true,
- "dintero:private_text:kind": "Gold"
}, - "links": [
- {
- "rel": "thumbnail_discount_image"
}, - {
- "rel": "medium_discount_image"
}, - {
- "rel": "webshoop"
}, - {
- "rel": "newletter",
- "type": "application/pdf"
}
]
}
{- "id": "497f6eca-6276-4993-bfeb-53cbbbba6f08",
- "created_at": "2019-08-24T14:15:22Z",
- "created_by": "1c92f7e1-2897-4d46-bdcc-c127a914fb4e",
- "updated_at": "2019-08-24T14:15:22Z",
- "deleted_by": "1c92f7e1-2897-4d46-bdcc-c127a914fb4e",
- "deleted_at": "2019-08-24T14:15:22Z",
- "campaign_id": "string",
- "active": true,
- "private": false,
- "updated_by": "3d1e4824-5474-48e7-a369-4f603fa4c5b8",
- "type": "item",
- "name": "Spar 100,-",
- "receipt_text": "Mai Salg",
- "visible_from": "2019-08-24T14:15:22Z",
- "description": "Gjør et Stablestol kupp!",
- "limitation": {
- "discount_activation": [
- {
- "type": "deactivate_if_discount_active",
- "value": "string"
}
], - "discount_hours": {
- "timezone": "Europe/Oslo",
- "hours": [
- {
- "day": "mon",
- "start": "10:00",
- "end": "20:00"
}
]
}, - "discount_reward_usage": 1,
- "discount_combination": -1,
- "discount_eligible": "item_eligible_for_discount",
- "discount_repeat_usage": -1,
- "stamp_expire_days": 100,
- "blacklist": [
- {
- "id": "b714118",
- "group_id": "B1"
}
]
}, - "requirement": {
- "customer": {
- "addresses": [
- {
- "country": [
- "NO"
], - "postal_code": [
- "0349"
], - "postal_place": [
- "Oslo"
], - "custom_type": [
- "offsite"
], - "type": [
- "custom"
]
}
], - "company": {
- "bussiness_name": [
- "TKP tech AS"
], - "department": [
- "production",
- "research"
], - "industry": [
- "J62.0.1",
- "J62.0.2"
], - "number_of_employees": [
- "20"
], - "organization_number": [
- "123456789MVA"
],
}, - "date_of_birth": [
- "1990-09-20",
- "1990-05-10"
], - "favorite_store": [
- "sc029"
], - "first_name": [
- "John"
], - "gender": [
- "male"
], - "last_name": [
- "Doe"
], - "marketing_consent": {
- "email": {
- "consent": [
- "true"
]
}, - "sms": {
- "consent": [
- "true"
]
}
}, - "status": [
- "vip"
], - "term": {
- "id": [
- "string"
]
}, - "type": [
- "string"
], - "attributes": {
- "property1": [
- "string"
], - "property2": [
- "string"
]
}
}, - "item": {
- "quantity": 0,
- "mixes": [
- {
- "items": [
- {
- "id": "b714118"
}, - {
- "group_id": "g4"
}
], - "quantity": 0,
- "reward_eligible": true
}
], - "items": [
- {
- "id": "b714118",
- "group_id": "B1"
}
]
}, - "store_ids": [
- "sc029"
], - "gross_amount": 0,
- "currencies": [
- {
- "anything-but": [
- "NOK"
]
}
], - "stamp": 5,
- "discount_code": "TACO",
- "store": {
- "id": [
- "sc029"
], - "name": [
- "SC Oslo"
], - "business_name": [
- "SC Oslo AS"
], - "address": {
- "country": [
- "NO"
], - "postal_code": [
- "0349"
], - "postal_place": [
- "Oslo"
]
}, - "chain": [
- "SuperChain"
], - "email": [
- "contact@superchain.com"
], - "gln": [
- "5790001398644"
], - "organization_number": [
- "123456789MVA"
], - "phone_number": [
- "+4738260107"
], - "mcc": [
- 5814
], - "mcc_ranges": [
- {
- "start": 5814,
- "end": 5815
}
], - "bax": [
- "102603"
], - "terminal_id": [
- "T0292"
]
}, - "purchase_from": "2019-08-24T14:15:22Z",
- "purchase_to": "2019-08-24T14:15:22Z"
}, - "reward": {
- "type": "discount_amount",
- "value": 10000,
- "values": [
- {
- "items": [
- {
- "id": "b714118",
- "group_id": "B1"
}
], - "value": 0
}
], - "base": "net",
- "effect": "discount"
}, - "metadata": {
- "campaign_id": "V101",
- "is_featured": true,
- "dintero:private_text:kind": "Gold"
}, - "links": [
- {
- "rel": "thumbnail_discount_image"
}, - {
- "rel": "medium_discount_image"
}, - {
- "rel": "webshoop"
}, - {
- "rel": "newletter",
- "type": "application/pdf"
}
]
}
List discounts available for the account scopes:
aid required | string <^[PT]{1}\d{8}$> = 9 characters An id that uniquely identifies the account. |
limit | integer [ 1 .. 100 ] Default: 10 A limit on the number of objects to be returned. Limit can range between 1 and 100 items, and the default is 10 items. |
starting_after | string cursor for use in pagination. starting_after is an object ID
that defines your place in the list. For instance, if you make
a list request and receive 100 objects, end the result contains
|
since_datetime | string <date-time> Only discounts added/updated/delete at or after this time is returned.
NOTE: this parameter can't be combined with |
purchase_from | string <date-time> Only discounts with requirement purchase_from at or after this time is returned. |
purchase_to | string <date-time> Only discounts with requirement purchase_to at or before this time is returned. |
state | string Default: "all" Enum: "all" "available" "deleted" "inactive" Indicate the state of the discounts to return |
campaign_id | Array of strings |
include | Array of strings Items Value: "statistics" Additional fields to include for each discount |
[- {
- "id": "497f6eca-6276-4993-bfeb-53cbbbba6f08",
- "created_at": "2019-08-24T14:15:22Z",
- "created_by": "1c92f7e1-2897-4d46-bdcc-c127a914fb4e",
- "updated_at": "2019-08-24T14:15:22Z",
- "deleted_by": "1c92f7e1-2897-4d46-bdcc-c127a914fb4e",
- "deleted_at": "2019-08-24T14:15:22Z",
- "campaign_id": "string",
- "active": true,
- "private": false,
- "updated_by": "3d1e4824-5474-48e7-a369-4f603fa4c5b8",
- "type": "item",
- "name": "Spar 100,-",
- "receipt_text": "Mai Salg",
- "visible_from": "2019-08-24T14:15:22Z",
- "description": "Gjør et Stablestol kupp!",
- "limitation": {
- "discount_activation": [
- {
- "type": "deactivate_if_discount_active",
- "value": "string"
}
], - "discount_hours": {
- "timezone": "Europe/Oslo",
- "hours": [
- {
- "day": "mon",
- "start": "10:00",
- "end": "20:00"
}
]
}, - "discount_reward_usage": 1,
- "discount_combination": -1,
- "discount_eligible": "item_eligible_for_discount",
- "discount_repeat_usage": -1,
- "stamp_expire_days": 100,
- "blacklist": [
- {
- "id": "b714118",
- "group_id": "B1"
}
]
}, - "requirement": {
- "customer": {
- "addresses": [
- {
- "country": [
- "NO"
], - "postal_code": [
- "0349"
], - "postal_place": [
- "Oslo"
], - "custom_type": [
- "offsite"
], - "type": [
- "custom"
]
}
], - "company": {
- "bussiness_name": [
- "TKP tech AS"
], - "department": [
- "production",
- "research"
], - "industry": [
- "J62.0.1",
- "J62.0.2"
], - "number_of_employees": [
- "20"
], - "organization_number": [
- "123456789MVA"
],
}, - "date_of_birth": [
- "1990-09-20",
- "1990-05-10"
], - "favorite_store": [
- "sc029"
], - "first_name": [
- "John"
], - "gender": [
- "male"
], - "last_name": [
- "Doe"
], - "marketing_consent": {
- "email": {
- "consent": [
- "true"
]
}, - "sms": {
- "consent": [
- "true"
]
}
}, - "status": [
- "vip"
], - "term": {
- "id": [
- "string"
]
}, - "type": [
- "string"
], - "attributes": {
- "property1": [
- "string"
], - "property2": [
- "string"
]
}
}, - "item": {
- "quantity": 0,
- "mixes": [
- {
- "items": [
- {
- "id": "b714118"
}, - {
- "group_id": "g4"
}
], - "quantity": 0,
- "reward_eligible": true
}
], - "items": [
- {
- "id": "b714118",
- "group_id": "B1"
}
]
}, - "store_ids": [
- "sc029"
], - "gross_amount": 0,
- "currencies": [
- {
- "anything-but": [
- "NOK"
]
}
], - "stamp": 5,
- "discount_code": "TACO",
- "store": {
- "id": [
- "sc029"
], - "name": [
- "SC Oslo"
], - "business_name": [
- "SC Oslo AS"
], - "address": {
- "country": [
- "NO"
], - "postal_code": [
- "0349"
], - "postal_place": [
- "Oslo"
]
}, - "chain": [
- "SuperChain"
], - "email": [
- "contact@superchain.com"
], - "gln": [
- "5790001398644"
], - "organization_number": [
- "123456789MVA"
], - "phone_number": [
- "+4738260107"
], - "mcc": [
- 5814
], - "mcc_ranges": [
- {
- "start": 5814,
- "end": 5815
}
], - "bax": [
- "102603"
], - "terminal_id": [
- "T0292"
]
}, - "purchase_from": "2019-08-24T14:15:22Z",
- "purchase_to": "2019-08-24T14:15:22Z"
}, - "reward": {
- "type": "discount_amount",
- "value": 10000,
- "values": [
- {
- "items": [
- {
- "id": "b714118",
- "group_id": "B1"
}
], - "value": 0
}
], - "base": "net",
- "effect": "discount"
}, - "metadata": {
- "campaign_id": "V101",
- "is_featured": true,
- "dintero:private_text:kind": "Gold"
}, - "links": [
- {
- "rel": "thumbnail_discount_image"
}, - {
- "rel": "medium_discount_image"
}, - {
- "rel": "webshoop"
}, - {
- "rel": "newletter",
- "type": "application/pdf"
}
], - "statistics": {
- "stamp": 0,
- "used": 28,
- "usage": 28,
- "amount": 280000,
- "debit_balance": 12350
}
}
]
Get more details about a discount, includes statistics about the discount scopes:
aid required | string <^[PT]{1}\d{8}$> = 9 characters An id that uniquely identifies the account. |
did required | string <uuid> An UUID that uniquely identifies the discount |
{- "id": "497f6eca-6276-4993-bfeb-53cbbbba6f08",
- "created_at": "2019-08-24T14:15:22Z",
- "created_by": "1c92f7e1-2897-4d46-bdcc-c127a914fb4e",
- "updated_at": "2019-08-24T14:15:22Z",
- "deleted_by": "1c92f7e1-2897-4d46-bdcc-c127a914fb4e",
- "deleted_at": "2019-08-24T14:15:22Z",
- "campaign_id": "string",
- "active": true,
- "private": false,
- "updated_by": "3d1e4824-5474-48e7-a369-4f603fa4c5b8",
- "type": "item",
- "name": "Spar 100,-",
- "receipt_text": "Mai Salg",
- "visible_from": "2019-08-24T14:15:22Z",
- "description": "Gjør et Stablestol kupp!",
- "limitation": {
- "discount_activation": [
- {
- "type": "deactivate_if_discount_active",
- "value": "string"
}
], - "discount_hours": {
- "timezone": "Europe/Oslo",
- "hours": [
- {
- "day": "mon",
- "start": "10:00",
- "end": "20:00"
}
]
}, - "discount_reward_usage": 1,
- "discount_combination": -1,
- "discount_eligible": "item_eligible_for_discount",
- "discount_repeat_usage": -1,
- "stamp_expire_days": 100,
- "blacklist": [
- {
- "id": "b714118",
- "group_id": "B1"
}
]
}, - "requirement": {
- "customer": {
- "addresses": [
- {
- "country": [
- "NO"
], - "postal_code": [
- "0349"
], - "postal_place": [
- "Oslo"
], - "custom_type": [
- "offsite"
], - "type": [
- "custom"
]
}
], - "company": {
- "bussiness_name": [
- "TKP tech AS"
], - "department": [
- "production",
- "research"
], - "industry": [
- "J62.0.1",
- "J62.0.2"
], - "number_of_employees": [
- "20"
], - "organization_number": [
- "123456789MVA"
],
}, - "date_of_birth": [
- "1990-09-20",
- "1990-05-10"
], - "favorite_store": [
- "sc029"
], - "first_name": [
- "John"
], - "gender": [
- "male"
], - "last_name": [
- "Doe"
], - "marketing_consent": {
- "email": {
- "consent": [
- "true"
]
}, - "sms": {
- "consent": [
- "true"
]
}
}, - "status": [
- "vip"
], - "term": {
- "id": [
- "string"
]
}, - "type": [
- "string"
], - "attributes": {
- "property1": [
- "string"
], - "property2": [
- "string"
]
}
}, - "item": {
- "quantity": 0,
- "mixes": [
- {
- "items": [
- {
- "id": "b714118"
}, - {
- "group_id": "g4"
}
], - "quantity": 0,
- "reward_eligible": true
}
], - "items": [
- {
- "id": "b714118",
- "group_id": "B1"
}
]
}, - "store_ids": [
- "sc029"
], - "gross_amount": 0,
- "currencies": [
- {
- "anything-but": [
- "NOK"
]
}
], - "stamp": 5,
- "discount_code": "TACO",
- "store": {
- "id": [
- "sc029"
], - "name": [
- "SC Oslo"
], - "business_name": [
- "SC Oslo AS"
], - "address": {
- "country": [
- "NO"
], - "postal_code": [
- "0349"
], - "postal_place": [
- "Oslo"
]
}, - "chain": [
- "SuperChain"
], - "email": [
- "contact@superchain.com"
], - "gln": [
- "5790001398644"
], - "organization_number": [
- "123456789MVA"
], - "phone_number": [
- "+4738260107"
], - "mcc": [
- 5814
], - "mcc_ranges": [
- {
- "start": 5814,
- "end": 5815
}
], - "bax": [
- "102603"
], - "terminal_id": [
- "T0292"
]
}, - "purchase_from": "2019-08-24T14:15:22Z",
- "purchase_to": "2019-08-24T14:15:22Z"
}, - "reward": {
- "type": "discount_amount",
- "value": 10000,
- "values": [
- {
- "items": [
- {
- "id": "b714118",
- "group_id": "B1"
}
], - "value": 0
}
], - "base": "net",
- "effect": "discount"
}, - "metadata": {
- "campaign_id": "V101",
- "is_featured": true,
- "dintero:private_text:kind": "Gold"
}, - "links": [
- {
- "rel": "thumbnail_discount_image"
}, - {
- "rel": "medium_discount_image"
}, - {
- "rel": "webshoop"
}, - {
- "rel": "newletter",
- "type": "application/pdf"
}
], - "statistics": {
- "stamp": 0,
- "used": 28,
- "usage": 28,
- "amount": 280000,
- "debit_balance": 12350
}
}
Update discount details.
Caution: Update of non-meta properties, properties that changes requirement or limitation can create conflict with the usage history of the discount.
Example is to change requirement.item.items, such change would mean that purchases before the change would not be correcly rewarded given the new version of the discount.
We recomment to limit the update of a discount to meta only properties if the discount has previously been used in a purchase.
Update on requirement purchase_to
is only supported when
the new value that is after current value.
Update of requirement purchase_from
and reward
is not supported.
Update discount.active
to toggle if an discount is active
and available for purchase.
Update discount.private
to toggle if an discount is included
in public discount collection if given to all customers
scopes:
aid required | string <^[PT]{1}\d{8}$> = 9 characters An id that uniquely identifies the account. |
did required | string <uuid> An UUID that uniquely identifies the discount |
Discount properties to update
campaign_id | string or null The campaign the rule belongs to, use |
active | boolean Default: true the discount is active and can be available for purchase |
private | boolean the discount is private and will not be included in public discount collection |
Array of objects (Links) [ items <= 10 items ] Links to resources related to the discount | |
object (Limitation) | |
object Discount base requirement | |
object | |
description | string |
metadata | object <= 10 properties Additional metadata about the discount |
name | string |
receipt_text | string Text that should be used when displaying the discount, e.g. on receipt |
{- "campaign_id": "string",
- "active": true,
- "private": false,
- "links": [
- {
- "rel": "thumbnail_discount_image"
}, - {
- "rel": "medium_discount_image"
}, - {
- "rel": "webshoop"
}, - {
- "rel": "newletter",
- "type": "application/pdf"
}
], - "limitation": {
- "discount_activation": [
- {
- "type": "deactivate_if_discount_active",
- "value": "string"
}
], - "discount_hours": {
- "timezone": "Europe/Oslo",
- "hours": [
- {
- "day": "mon",
- "start": "10:00",
- "end": "20:00"
}
]
}, - "discount_reward_usage": 1,
- "discount_combination": -1,
- "discount_eligible": "item_eligible_for_discount",
- "discount_repeat_usage": -1,
- "stamp_expire_days": 100,
- "blacklist": [
- {
- "id": "b714118",
- "group_id": "B1"
}
]
}, - "requirement": {
- "customer": {
- "addresses": [
- {
- "country": [
- "NO"
], - "postal_code": [
- "0349"
], - "postal_place": [
- "Oslo"
], - "custom_type": [
- "offsite"
], - "type": [
- "custom"
]
}
], - "company": {
- "bussiness_name": [
- "TKP tech AS"
], - "department": [
- "production",
- "research"
], - "industry": [
- "J62.0.1",
- "J62.0.2"
], - "number_of_employees": [
- "20"
], - "organization_number": [
- "123456789MVA"
],
}, - "date_of_birth": [
- "1990-09-20",
- "1990-05-10"
], - "favorite_store": [
- "sc029"
], - "first_name": [
- "John"
], - "gender": [
- "male"
], - "last_name": [
- "Doe"
], - "marketing_consent": {
- "email": {
- "consent": [
- "true"
]
}, - "sms": {
- "consent": [
- "true"
]
}
}, - "status": [
- "vip"
], - "term": {
- "id": [
- "string"
]
}, - "type": [
- "string"
], - "attributes": {
- "property1": [
- "string"
], - "property2": [
- "string"
]
}
}, - "item": {
- "quantity": 0,
- "mixes": [
- {
- "items": [
- {
- "id": "b714118"
}, - {
- "group_id": "g4"
}
], - "quantity": 0,
- "reward_eligible": true
}
], - "items": [
- {
- "id": "b714118",
- "group_id": "B1"
}
]
}, - "store_ids": [
- "sc029"
], - "gross_amount": 0,
- "currencies": [
- {
- "anything-but": [
- "NOK"
]
}
], - "stamp": 5,
- "discount_code": "TACO",
- "store": {
- "id": [
- "sc029"
], - "name": [
- "SC Oslo"
], - "business_name": [
- "SC Oslo AS"
], - "address": {
- "country": [
- "NO"
], - "postal_code": [
- "0349"
], - "postal_place": [
- "Oslo"
]
}, - "chain": [
- "SuperChain"
], - "email": [
- "contact@superchain.com"
], - "gln": [
- "5790001398644"
], - "organization_number": [
- "123456789MVA"
], - "phone_number": [
- "+4738260107"
], - "mcc": [
- 5814
], - "mcc_ranges": [
- {
- "start": 5814,
- "end": 5815
}
], - "bax": [
- "102603"
], - "terminal_id": [
- "T0292"
]
}, - "purchase_to": "2019-08-24T14:15:22Z"
}, - "reward": {
- "base": "net"
}, - "description": "Gjør et Stablestol kupp!",
- "metadata": {
- "campaign_id": "V101",
- "is_featured": true
}, - "name": "Spar 100,-",
- "receipt_text": "Mai Salg"
}
{- "id": "497f6eca-6276-4993-bfeb-53cbbbba6f08",
- "created_at": "2019-08-24T14:15:22Z",
- "created_by": "1c92f7e1-2897-4d46-bdcc-c127a914fb4e",
- "updated_at": "2019-08-24T14:15:22Z",
- "deleted_by": "1c92f7e1-2897-4d46-bdcc-c127a914fb4e",
- "deleted_at": "2019-08-24T14:15:22Z",
- "campaign_id": "string",
- "active": true,
- "private": false,
- "updated_by": "3d1e4824-5474-48e7-a369-4f603fa4c5b8",
- "type": "item",
- "name": "Spar 100,-",
- "receipt_text": "Mai Salg",
- "visible_from": "2019-08-24T14:15:22Z",
- "description": "Gjør et Stablestol kupp!",
- "limitation": {
- "discount_activation": [
- {
- "type": "deactivate_if_discount_active",
- "value": "string"
}
], - "discount_hours": {
- "timezone": "Europe/Oslo",
- "hours": [
- {
- "day": "mon",
- "start": "10:00",
- "end": "20:00"
}
]
}, - "discount_reward_usage": 1,
- "discount_combination": -1,
- "discount_eligible": "item_eligible_for_discount",
- "discount_repeat_usage": -1,
- "stamp_expire_days": 100,
- "blacklist": [
- {
- "id": "b714118",
- "group_id": "B1"
}
]
}, - "requirement": {
- "customer": {
- "addresses": [
- {
- "country": [
- "NO"
], - "postal_code": [
- "0349"
], - "postal_place": [
- "Oslo"
], - "custom_type": [
- "offsite"
], - "type": [
- "custom"
]
}
], - "company": {
- "bussiness_name": [
- "TKP tech AS"
], - "department": [
- "production",
- "research"
], - "industry": [
- "J62.0.1",
- "J62.0.2"
], - "number_of_employees": [
- "20"
], - "organization_number": [
- "123456789MVA"
],
}, - "date_of_birth": [
- "1990-09-20",
- "1990-05-10"
], - "favorite_store": [
- "sc029"
], - "first_name": [
- "John"
], - "gender": [
- "male"
], - "last_name": [
- "Doe"
], - "marketing_consent": {
- "email": {
- "consent": [
- "true"
]
}, - "sms": {
- "consent": [
- "true"
]
}
}, - "status": [
- "vip"
], - "term": {
- "id": [
- "string"
]
}, - "type": [
- "string"
], - "attributes": {
- "property1": [
- "string"
], - "property2": [
- "string"
]
}
}, - "item": {
- "quantity": 0,
- "mixes": [
- {
- "items": [
- {
- "id": "b714118"
}, - {
- "group_id": "g4"
}
], - "quantity": 0,
- "reward_eligible": true
}
], - "items": [
- {
- "id": "b714118",
- "group_id": "B1"
}
]
}, - "store_ids": [
- "sc029"
], - "gross_amount": 0,
- "currencies": [
- {
- "anything-but": [
- "NOK"
]
}
], - "stamp": 5,
- "discount_code": "TACO",
- "store": {
- "id": [
- "sc029"
], - "name": [
- "SC Oslo"
], - "business_name": [
- "SC Oslo AS"
], - "address": {
- "country": [
- "NO"
], - "postal_code": [
- "0349"
], - "postal_place": [
- "Oslo"
]
}, - "chain": [
- "SuperChain"
], - "email": [
- "contact@superchain.com"
], - "gln": [
- "5790001398644"
], - "organization_number": [
- "123456789MVA"
], - "phone_number": [
- "+4738260107"
], - "mcc": [
- 5814
], - "mcc_ranges": [
- {
- "start": 5814,
- "end": 5815
}
], - "bax": [
- "102603"
], - "terminal_id": [
- "T0292"
]
}, - "purchase_from": "2019-08-24T14:15:22Z",
- "purchase_to": "2019-08-24T14:15:22Z"
}, - "reward": {
- "type": "discount_amount",
- "value": 10000,
- "values": [
- {
- "items": [
- {
- "id": "b714118",
- "group_id": "B1"
}
], - "value": 0
}
], - "base": "net",
- "effect": "discount"
}, - "metadata": {
- "campaign_id": "V101",
- "is_featured": true,
- "dintero:private_text:kind": "Gold"
}, - "links": [
- {
- "rel": "thumbnail_discount_image"
}, - {
- "rel": "medium_discount_image"
}, - {
- "rel": "webshoop"
}, - {
- "rel": "newletter",
- "type": "application/pdf"
}
], - "statistics": {
- "stamp": 0,
- "used": 28,
- "usage": 28,
- "amount": 280000,
- "debit_balance": 12350
}
}
Delete a discount
scopes:
aid required | string <^[PT]{1}\d{8}$> = 9 characters An id that uniquely identifies the account. |
did required | string <uuid> An UUID that uniquely identifies the discount |
{- "statistics": {
- "stamp": 0,
- "used": 28,
- "usage": 28,
- "amount": 280000,
- "debit_balance": 12350
}, - "id": "497f6eca-6276-4993-bfeb-53cbbbba6f08",
- "created_at": "2019-08-24T14:15:22Z",
- "created_by": "1c92f7e1-2897-4d46-bdcc-c127a914fb4e",
- "updated_at": "2019-08-24T14:15:22Z",
- "deleted_by": "1c92f7e1-2897-4d46-bdcc-c127a914fb4e",
- "deleted_at": "2019-08-24T14:15:22Z",
- "campaign_id": "string",
- "active": true,
- "private": false,
- "updated_by": "3d1e4824-5474-48e7-a369-4f603fa4c5b8",
- "type": "item",
- "name": "Spar 100,-",
- "receipt_text": "Mai Salg",
- "visible_from": "2019-08-24T14:15:22Z",
- "description": "Gjør et Stablestol kupp!",
- "limitation": {
- "discount_activation": [
- {
- "type": "deactivate_if_discount_active",
- "value": "string"
}
], - "discount_hours": {
- "timezone": "Europe/Oslo",
- "hours": [
- {
- "day": "mon",
- "start": "10:00",
- "end": "20:00"
}
]
}, - "discount_reward_usage": 1,
- "discount_combination": -1,
- "discount_eligible": "item_eligible_for_discount",
- "discount_repeat_usage": -1,
- "stamp_expire_days": 100,
- "blacklist": [
- {
- "id": "b714118",
- "group_id": "B1"
}
]
}, - "requirement": {
- "customer": {
- "addresses": [
- {
- "country": [
- "NO"
], - "postal_code": [
- "0349"
], - "postal_place": [
- "Oslo"
], - "custom_type": [
- "offsite"
], - "type": [
- "custom"
]
}
], - "company": {
- "bussiness_name": [
- "TKP tech AS"
], - "department": [
- "production",
- "research"
], - "industry": [
- "J62.0.1",
- "J62.0.2"
], - "number_of_employees": [
- "20"
], - "organization_number": [
- "123456789MVA"
],
}, - "date_of_birth": [
- "1990-09-20",
- "1990-05-10"
], - "favorite_store": [
- "sc029"
], - "first_name": [
- "John"
], - "gender": [
- "male"
], - "last_name": [
- "Doe"
], - "marketing_consent": {
- "email": {
- "consent": [
- "true"
]
}, - "sms": {
- "consent": [
- "true"
]
}
}, - "status": [
- "vip"
], - "term": {
- "id": [
- "string"
]
}, - "type": [
- "string"
], - "attributes": {
- "property1": [
- "string"
], - "property2": [
- "string"
]
}
}, - "item": {
- "quantity": 0,
- "mixes": [
- {
- "items": [
- {
- "id": "b714118"
}, - {
- "group_id": "g4"
}
], - "quantity": 0,
- "reward_eligible": true
}
], - "items": [
- {
- "id": "b714118",
- "group_id": "B1"
}
]
}, - "store_ids": [
- "sc029"
], - "gross_amount": 0,
- "currencies": [
- {
- "anything-but": [
- "NOK"
]
}
], - "stamp": 5,
- "discount_code": "TACO",
- "store": {
- "id": [
- "sc029"
], - "name": [
- "SC Oslo"
], - "business_name": [
- "SC Oslo AS"
], - "address": {
- "country": [
- "NO"
], - "postal_code": [
- "0349"
], - "postal_place": [
- "Oslo"
]
}, - "chain": [
- "SuperChain"
], - "email": [
- "contact@superchain.com"
], - "gln": [
- "5790001398644"
], - "organization_number": [
- "123456789MVA"
], - "phone_number": [
- "+4738260107"
], - "mcc": [
- 5814
], - "mcc_ranges": [
- {
- "start": 5814,
- "end": 5815
}
], - "bax": [
- "102603"
], - "terminal_id": [
- "T0292"
]
}, - "purchase_from": "2019-08-24T14:15:22Z",
- "purchase_to": "2019-08-24T14:15:22Z"
}, - "reward": {
- "type": "discount_amount",
- "value": 10000,
- "values": [
- {
- "items": [
- {
- "id": "b714118",
- "group_id": "B1"
}
], - "value": 0
}
], - "base": "net",
- "effect": "discount"
}, - "metadata": {
- "campaign_id": "V101",
- "is_featured": true,
- "dintero:private_text:kind": "Gold"
}, - "links": [
- {
- "rel": "thumbnail_discount_image"
}, - {
- "rel": "medium_discount_image"
}, - {
- "rel": "webshoop"
}, - {
- "rel": "newletter",
- "type": "application/pdf"
}
]
}
Add stamps and usage to a discount ref. scopes:
aid required | string <^[PT]{1}\d{8}$> = 9 characters An id that uniquely identifies the account. |
customer_id required | string <= 255 characters The customer id you have defined for the customer. (must not have trailing or leading spaces) |
ref_id required | string A string that uniquely identifies a customer discount reference |
update usage, stamps and amount
object (UsageRefWrite) |
{- "usage_ref": {
- "ref": "fe35e8ed-3fd3-4b04-acdd-6f1d7d7ca7c9",
- "ref_type": "receipt_add",
- "usage": 1,
- "stamp": 4,
- "amount": 12000
}
}
{- "id": "497f6eca-6276-4993-bfeb-53cbbbba6f08",
- "created_at": "2019-08-24T14:15:22Z",
- "created_by": "1c92f7e1-2897-4d46-bdcc-c127a914fb4e",
- "updated_at": "2019-08-24T14:15:22Z",
- "deleted_by": "1c92f7e1-2897-4d46-bdcc-c127a914fb4e",
- "deleted_at": "2019-08-24T14:15:22Z",
- "campaign_id": "string",
- "active": true,
- "private": false,
- "updated_by": "3d1e4824-5474-48e7-a369-4f603fa4c5b8",
- "type": "item",
- "name": "Spar 100,-",
- "receipt_text": "Mai Salg",
- "visible_from": "2019-08-24T14:15:22Z",
- "description": "Gjør et Stablestol kupp!",
- "limitation": {
- "discount_activation": [
- {
- "type": "deactivate_if_discount_active",
- "value": "string"
}
], - "discount_hours": {
- "timezone": "Europe/Oslo",
- "hours": [
- {
- "day": "mon",
- "start": "10:00",
- "end": "20:00"
}
]
}, - "discount_reward_usage": 1,
- "discount_combination": -1,
- "discount_eligible": "item_eligible_for_discount",
- "discount_repeat_usage": -1,
- "stamp_expire_days": 100,
- "blacklist": [
- {
- "id": "b714118",
- "group_id": "B1"
}
]
}, - "requirement": {
- "customer": {
- "addresses": [
- {
- "country": [
- "NO"
], - "postal_code": [
- "0349"
], - "postal_place": [
- "Oslo"
], - "custom_type": [
- "offsite"
], - "type": [
- "custom"
]
}
], - "company": {
- "bussiness_name": [
- "TKP tech AS"
], - "department": [
- "production",
- "research"
], - "industry": [
- "J62.0.1",
- "J62.0.2"
], - "number_of_employees": [
- "20"
], - "organization_number": [
- "123456789MVA"
],
}, - "date_of_birth": [
- "1990-09-20",
- "1990-05-10"
], - "favorite_store": [
- "sc029"
], - "first_name": [
- "John"
], - "gender": [
- "male"
], - "last_name": [
- "Doe"
], - "marketing_consent": {
- "email": {
- "consent": [
- "true"
]
}, - "sms": {
- "consent": [
- "true"
]
}
}, - "status": [
- "vip"
], - "term": {
- "id": [
- "string"
]
}, - "type": [
- "string"
], - "attributes": {
- "property1": [
- "string"
], - "property2": [
- "string"
]
}
}, - "item": {
- "quantity": 0,
- "mixes": [
- {
- "items": [
- {
- "id": "b714118"
}, - {
- "group_id": "g4"
}
], - "quantity": 0,
- "reward_eligible": true
}
], - "items": [
- {
- "id": "b714118",
- "group_id": "B1"
}
]
}, - "store_ids": [
- "sc029"
], - "gross_amount": 0,
- "currencies": [
- {
- "anything-but": [
- "NOK"
]
}
], - "stamp": 5,
- "discount_code": "TACO",
- "store": {
- "id": [
- "sc029"
], - "name": [
- "SC Oslo"
], - "business_name": [
- "SC Oslo AS"
], - "address": {
- "country": [
- "NO"
], - "postal_code": [
- "0349"
], - "postal_place": [
- "Oslo"
]
}, - "chain": [
- "SuperChain"
], - "email": [
- "contact@superchain.com"
], - "gln": [
- "5790001398644"
], - "organization_number": [
- "123456789MVA"
], - "phone_number": [
- "+4738260107"
], - "mcc": [
- 5814
], - "mcc_ranges": [
- {
- "start": 5814,
- "end": 5815
}
], - "bax": [
- "102603"
], - "terminal_id": [
- "T0292"
]
}, - "purchase_from": "2019-08-24T14:15:22Z",
- "purchase_to": "2019-08-24T14:15:22Z"
}, - "reward": {
- "type": "discount_amount",
- "value": 10000,
- "values": [
- {
- "items": [
- {
- "id": "b714118",
- "group_id": "B1"
}
], - "value": 0
}
], - "base": "net",
- "effect": "discount"
}, - "metadata": {
- "campaign_id": "V101",
- "is_featured": true,
- "dintero:private_text:kind": "Gold"
}, - "links": [
- {
- "rel": "thumbnail_discount_image"
}, - {
- "rel": "medium_discount_image"
}, - {
- "rel": "webshoop"
}, - {
- "rel": "newletter",
- "type": "application/pdf"
}
], - "statistics": {
- "stamp": 0,
- "used": 28,
- "usage": 28,
- "amount": 280000,
- "debit_balance": 12350
}, - "ref_id": "string"
}
Get a customer discount ref. scopes:
aid required | string <^[PT]{1}\d{8}$> = 9 characters An id that uniquely identifies the account. |
customer_id required | string <= 255 characters The customer id you have defined for the customer. (must not have trailing or leading spaces) |
ref_id required | string A string that uniquely identifies a customer discount reference |
{- "id": "497f6eca-6276-4993-bfeb-53cbbbba6f08",
- "created_at": "2019-08-24T14:15:22Z",
- "created_by": "1c92f7e1-2897-4d46-bdcc-c127a914fb4e",
- "updated_at": "2019-08-24T14:15:22Z",
- "deleted_by": "1c92f7e1-2897-4d46-bdcc-c127a914fb4e",
- "deleted_at": "2019-08-24T14:15:22Z",
- "campaign_id": "string",
- "active": true,
- "private": false,
- "updated_by": "3d1e4824-5474-48e7-a369-4f603fa4c5b8",
- "type": "item",
- "name": "Spar 100,-",
- "receipt_text": "Mai Salg",
- "visible_from": "2019-08-24T14:15:22Z",
- "description": "Gjør et Stablestol kupp!",
- "limitation": {
- "discount_activation": [
- {
- "type": "deactivate_if_discount_active",
- "value": "string"
}
], - "discount_hours": {
- "timezone": "Europe/Oslo",
- "hours": [
- {
- "day": "mon",
- "start": "10:00",
- "end": "20:00"
}
]
}, - "discount_reward_usage": 1,
- "discount_combination": -1,
- "discount_eligible": "item_eligible_for_discount",
- "discount_repeat_usage": -1,
- "stamp_expire_days": 100,
- "blacklist": [
- {
- "id": "b714118",
- "group_id": "B1"
}
]
}, - "requirement": {
- "customer": {
- "addresses": [
- {
- "country": [
- "NO"
], - "postal_code": [
- "0349"
], - "postal_place": [
- "Oslo"
], - "custom_type": [
- "offsite"
], - "type": [
- "custom"
]
}
], - "company": {
- "bussiness_name": [
- "TKP tech AS"
], - "department": [
- "production",
- "research"
], - "industry": [
- "J62.0.1",
- "J62.0.2"
], - "number_of_employees": [
- "20"
], - "organization_number": [
- "123456789MVA"
],
}, - "date_of_birth": [
- "1990-09-20",
- "1990-05-10"
], - "favorite_store": [
- "sc029"
], - "first_name": [
- "John"
], - "gender": [
- "male"
], - "last_name": [
- "Doe"
], - "marketing_consent": {
- "email": {
- "consent": [
- "true"
]
}, - "sms": {
- "consent": [
- "true"
]
}
}, - "status": [
- "vip"
], - "term": {
- "id": [
- "string"
]
}, - "type": [
- "string"
], - "attributes": {
- "property1": [
- "string"
], - "property2": [
- "string"
]
}
}, - "item": {
- "quantity": 0,
- "mixes": [
- {
- "items": [
- {
- "id": "b714118"
}, - {
- "group_id": "g4"
}
], - "quantity": 0,
- "reward_eligible": true
}
], - "items": [
- {
- "id": "b714118",
- "group_id": "B1"
}
]
}, - "store_ids": [
- "sc029"
], - "gross_amount": 0,
- "currencies": [
- {
- "anything-but": [
- "NOK"
]
}
], - "stamp": 5,
- "discount_code": "TACO",
- "store": {
- "id": [
- "sc029"
], - "name": [
- "SC Oslo"
], - "business_name": [
- "SC Oslo AS"
], - "address": {
- "country": [
- "NO"
], - "postal_code": [
- "0349"
], - "postal_place": [
- "Oslo"
]
}, - "chain": [
- "SuperChain"
], - "email": [
- "contact@superchain.com"
], - "gln": [
- "5790001398644"
], - "organization_number": [
- "123456789MVA"
], - "phone_number": [
- "+4738260107"
], - "mcc": [
- 5814
], - "mcc_ranges": [
- {
- "start": 5814,
- "end": 5815
}
], - "bax": [
- "102603"
], - "terminal_id": [
- "T0292"
]
}, - "purchase_from": "2019-08-24T14:15:22Z",
- "purchase_to": "2019-08-24T14:15:22Z"
}, - "reward": {
- "type": "discount_amount",
- "value": 10000,
- "values": [
- {
- "items": [
- {
- "id": "b714118",
- "group_id": "B1"
}
], - "value": 0
}
], - "base": "net",
- "effect": "discount"
}, - "metadata": {
- "campaign_id": "V101",
- "is_featured": true,
- "dintero:private_text:kind": "Gold"
}, - "links": [
- {
- "rel": "thumbnail_discount_image"
}, - {
- "rel": "medium_discount_image"
}, - {
- "rel": "webshoop"
}, - {
- "rel": "newletter",
- "type": "application/pdf"
}
], - "statistics": {
- "stamp": 0,
- "used": 28,
- "usage": 28,
- "amount": 280000,
- "debit_balance": 12350,
- "current_stamp": 0
}, - "ref_id": "string"
}
Delete a customer discount ref. The discount will no longer be available on purchase (Post receipt for discount)
scopes:
aid required | string <^[PT]{1}\d{8}$> = 9 characters An id that uniquely identifies the account. |
customer_id required | string <= 255 characters The customer id you have defined for the customer. (must not have trailing or leading spaces) |
ref_id required | string A string that uniquely identifies a customer discount reference |
{- "id": "497f6eca-6276-4993-bfeb-53cbbbba6f08",
- "created_at": "2019-08-24T14:15:22Z",
- "created_by": "1c92f7e1-2897-4d46-bdcc-c127a914fb4e",
- "updated_at": "2019-08-24T14:15:22Z",
- "deleted_by": "1c92f7e1-2897-4d46-bdcc-c127a914fb4e",
- "deleted_at": "2019-08-24T14:15:22Z",
- "campaign_id": "string",
- "active": true,
- "private": false,
- "updated_by": "3d1e4824-5474-48e7-a369-4f603fa4c5b8",
- "type": "item",
- "name": "Spar 100,-",
- "receipt_text": "Mai Salg",
- "visible_from": "2019-08-24T14:15:22Z",
- "description": "Gjør et Stablestol kupp!",
- "limitation": {
- "discount_activation": [
- {
- "type": "deactivate_if_discount_active",
- "value": "string"
}
], - "discount_hours": {
- "timezone": "Europe/Oslo",
- "hours": [
- {
- "day": "mon",
- "start": "10:00",
- "end": "20:00"
}
]
}, - "discount_reward_usage": 1,
- "discount_combination": -1,
- "discount_eligible": "item_eligible_for_discount",
- "discount_repeat_usage": -1,
- "stamp_expire_days": 100,
- "blacklist": [
- {
- "id": "b714118",
- "group_id": "B1"
}
]
}, - "requirement": {
- "customer": {
- "addresses": [
- {
- "country": [
- "NO"
], - "postal_code": [
- "0349"
], - "postal_place": [
- "Oslo"
], - "custom_type": [
- "offsite"
], - "type": [
- "custom"
]
}
], - "company": {
- "bussiness_name": [
- "TKP tech AS"
], - "department": [
- "production",
- "research"
], - "industry": [
- "J62.0.1",
- "J62.0.2"
], - "number_of_employees": [
- "20"
], - "organization_number": [
- "123456789MVA"
],
}, - "date_of_birth": [
- "1990-09-20",
- "1990-05-10"
], - "favorite_store": [
- "sc029"
], - "first_name": [
- "John"
], - "gender": [
- "male"
], - "last_name": [
- "Doe"
], - "marketing_consent": {
- "email": {
- "consent": [
- "true"
]
}, - "sms": {
- "consent": [
- "true"
]
}
}, - "status": [
- "vip"
], - "term": {
- "id": [
- "string"
]
}, - "type": [
- "string"
], - "attributes": {
- "property1": [
- "string"
], - "property2": [
- "string"
]
}
}, - "item": {
- "quantity": 0,
- "mixes": [
- {
- "items": [
- {
- "id": "b714118"
}, - {
- "group_id": "g4"
}
], - "quantity": 0,
- "reward_eligible": true
}
], - "items": [
- {
- "id": "b714118",
- "group_id": "B1"
}
]
}, - "store_ids": [
- "sc029"
], - "gross_amount": 0,
- "currencies": [
- {
- "anything-but": [
- "NOK"
]
}
], - "stamp": 5,
- "discount_code": "TACO",
- "store": {
- "id": [
- "sc029"
], - "name": [
- "SC Oslo"
], - "business_name": [
- "SC Oslo AS"
], - "address": {
- "country": [
- "NO"
], - "postal_code": [
- "0349"
], - "postal_place": [
- "Oslo"
]
}, - "chain": [
- "SuperChain"
], - "email": [
- "contact@superchain.com"
], - "gln": [
- "5790001398644"
], - "organization_number": [
- "123456789MVA"
], - "phone_number": [
- "+4738260107"
], - "mcc": [
- 5814
], - "mcc_ranges": [
- {
- "start": 5814,
- "end": 5815
}
], - "bax": [
- "102603"
], - "terminal_id": [
- "T0292"
]
}, - "purchase_from": "2019-08-24T14:15:22Z",
- "purchase_to": "2019-08-24T14:15:22Z"
}, - "reward": {
- "type": "discount_amount",
- "value": 10000,
- "values": [
- {
- "items": [
- {
- "id": "b714118",
- "group_id": "B1"
}
], - "value": 0
}
], - "base": "net",
- "effect": "discount"
}, - "metadata": {
- "campaign_id": "V101",
- "is_featured": true,
- "dintero:private_text:kind": "Gold"
}, - "links": [
- {
- "rel": "thumbnail_discount_image"
}, - {
- "rel": "medium_discount_image"
}, - {
- "rel": "webshoop"
}, - {
- "rel": "newletter",
- "type": "application/pdf"
}
], - "statistics": {
- "stamp": 0,
- "used": 28,
- "usage": 28,
- "amount": 280000,
- "debit_balance": 12350
}, - "ref_id": "string",
- "debit_balance": 0
}
Get all discounts available for a customer, result will exclude expired and inactive discounts
Expired discounts are:
Inactive discounts are:
active
property set to false.Use value of ref_id
as parameter value of starting_after
scopes:
aid required | string <^[PT]{1}\d{8}$> = 9 characters An id that uniquely identifies the account. |
customer_id required | string <= 255 characters The customer id you have defined for the customer. (must not have trailing or leading spaces) |
limit | integer [ 1 .. 100 ] Default: 10 A limit on the number of objects to be returned. Limit can range between 1 and 100 items, and the default is 10 items. |
starting_after | string cursor for use in pagination. starting_after is an object ID
that defines your place in the list. For instance, if you make
a list request and receive 100 objects, end the result contains
|
[- {
- "id": "497f6eca-6276-4993-bfeb-53cbbbba6f08",
- "created_at": "2019-08-24T14:15:22Z",
- "created_by": "1c92f7e1-2897-4d46-bdcc-c127a914fb4e",
- "updated_at": "2019-08-24T14:15:22Z",
- "deleted_by": "1c92f7e1-2897-4d46-bdcc-c127a914fb4e",
- "deleted_at": "2019-08-24T14:15:22Z",
- "campaign_id": "string",
- "active": true,
- "private": false,
- "updated_by": "3d1e4824-5474-48e7-a369-4f603fa4c5b8",
- "type": "item",
- "name": "Spar 100,-",
- "receipt_text": "Mai Salg",
- "visible_from": "2019-08-24T14:15:22Z",
- "description": "Gjør et Stablestol kupp!",
- "limitation": {
- "discount_activation": [
- {
- "type": "deactivate_if_discount_active",
- "value": "string"
}
], - "discount_hours": {
- "timezone": "Europe/Oslo",
- "hours": [
- {
- "day": "mon",
- "start": "10:00",
- "end": "20:00"
}
]
}, - "discount_reward_usage": 1,
- "discount_combination": -1,
- "discount_eligible": "item_eligible_for_discount",
- "discount_repeat_usage": -1,
- "stamp_expire_days": 100,
- "blacklist": [
- {
- "id": "b714118",
- "group_id": "B1"
}
]
}, - "requirement": {
- "customer": {
- "addresses": [
- {
- "country": [
- "NO"
], - "postal_code": [
- "0349"
], - "postal_place": [
- "Oslo"
], - "custom_type": [
- "offsite"
], - "type": [
- "custom"
]
}
], - "company": {
- "bussiness_name": [
- "TKP tech AS"
], - "department": [
- "production",
- "research"
], - "industry": [
- "J62.0.1",
- "J62.0.2"
], - "number_of_employees": [
- "20"
], - "organization_number": [
- "123456789MVA"
],
}, - "date_of_birth": [
- "1990-09-20",
- "1990-05-10"
], - "favorite_store": [
- "sc029"
], - "first_name": [
- "John"
], - "gender": [
- "male"
], - "last_name": [
- "Doe"
], - "marketing_consent": {
- "email": {
- "consent": [
- "true"
]
}, - "sms": {
- "consent": [
- "true"
]
}
}, - "status": [
- "vip"
], - "term": {
- "id": [
- "string"
]
}, - "type": [
- "string"
], - "attributes": {
- "property1": [
- "string"
], - "property2": [
- "string"
]
}
}, - "item": {
- "quantity": 0,
- "mixes": [
- {
- "items": [
- {
- "id": "b714118"
}, - {
- "group_id": "g4"
}
], - "quantity": 0,
- "reward_eligible": true
}
], - "items": [
- {
- "id": "b714118",
- "group_id": "B1"
}
]
}, - "store_ids": [
- "sc029"
], - "gross_amount": 0,
- "currencies": [
- {
- "anything-but": [
- "NOK"
]
}
], - "stamp": 5,
- "discount_code": "TACO",
- "store": {
- "id": [
- "sc029"
], - "name": [
- "SC Oslo"
], - "business_name": [
- "SC Oslo AS"
], - "address": {
- "country": [
- "NO"
], - "postal_code": [
- "0349"
], - "postal_place": [
- "Oslo"
]
}, - "chain": [
- "SuperChain"
], - "email": [
- "contact@superchain.com"
], - "gln": [
- "5790001398644"
], - "organization_number": [
- "123456789MVA"
], - "phone_number": [
- "+4738260107"
], - "mcc": [
- 5814
], - "mcc_ranges": [
- {
- "start": 5814,
- "end": 5815
}
], - "bax": [
- "102603"
], - "terminal_id": [
- "T0292"
]
}, - "purchase_from": "2019-08-24T14:15:22Z",
- "purchase_to": "2019-08-24T14:15:22Z"
}, - "reward": {
- "type": "discount_amount",
- "value": 10000,
- "values": [
- {
- "items": [
- {
- "id": "b714118",
- "group_id": "B1"
}
], - "value": 0
}
], - "base": "net",
- "effect": "discount"
}, - "metadata": {
- "campaign_id": "V101",
- "is_featured": true,
- "dintero:private_text:kind": "Gold"
}, - "links": [
- {
- "rel": "thumbnail_discount_image"
}, - {
- "rel": "medium_discount_image"
}, - {
- "rel": "webshoop"
}, - {
- "rel": "newletter",
- "type": "application/pdf"
}
], - "statistics": {
- "stamp": 0,
- "used": 28,
- "usage": 28,
- "amount": 280000,
- "debit_balance": 12350,
- "current_stamp": 0
}, - "ref_id": "string"
}
]
Give the Discount to one or more customers
scopes:
aid required | string <^[PT]{1}\d{8}$> = 9 characters An id that uniquely identifies the account. |
did required | string <uuid> An UUID that uniquely identifies the discount |
Customers to give the discount to
customers required | Array of strings Array of customer IDs (must not have trailing or leading spaces) Following values are reserved:
|
offering_constraint_id | string Use the |
{- "offering_constraint_id": "stamp-2020",
- "customers": [
- "12397af6e5e"
]
}
{- "statistics": {
- "stamp": 0,
- "used": 28,
- "usage": 28,
- "amount": 280000,
- "debit_balance": 12350
}, - "id": "497f6eca-6276-4993-bfeb-53cbbbba6f08",
- "created_at": "2019-08-24T14:15:22Z",
- "created_by": "1c92f7e1-2897-4d46-bdcc-c127a914fb4e",
- "updated_at": "2019-08-24T14:15:22Z",
- "deleted_by": "1c92f7e1-2897-4d46-bdcc-c127a914fb4e",
- "deleted_at": "2019-08-24T14:15:22Z",
- "campaign_id": "string",
- "active": true,
- "private": false,
- "updated_by": "3d1e4824-5474-48e7-a369-4f603fa4c5b8",
- "type": "item",
- "name": "Spar 100,-",
- "receipt_text": "Mai Salg",
- "visible_from": "2019-08-24T14:15:22Z",
- "description": "Gjør et Stablestol kupp!",
- "limitation": {
- "discount_activation": [
- {
- "type": "deactivate_if_discount_active",
- "value": "string"
}
], - "discount_hours": {
- "timezone": "Europe/Oslo",
- "hours": [
- {
- "day": "mon",
- "start": "10:00",
- "end": "20:00"
}
]
}, - "discount_reward_usage": 1,
- "discount_combination": -1,
- "discount_eligible": "item_eligible_for_discount",
- "discount_repeat_usage": -1,
- "stamp_expire_days": 100,
- "blacklist": [
- {
- "id": "b714118",
- "group_id": "B1"
}
]
}, - "requirement": {
- "customer": {
- "addresses": [
- {
- "country": [
- "NO"
], - "postal_code": [
- "0349"
], - "postal_place": [
- "Oslo"
], - "custom_type": [
- "offsite"
], - "type": [
- "custom"
]
}
], - "company": {
- "bussiness_name": [
- "TKP tech AS"
], - "department": [
- "production",
- "research"
], - "industry": [
- "J62.0.1",
- "J62.0.2"
], - "number_of_employees": [
- "20"
], - "organization_number": [
- "123456789MVA"
],
}, - "date_of_birth": [
- "1990-09-20",
- "1990-05-10"
], - "favorite_store": [
- "sc029"
], - "first_name": [
- "John"
], - "gender": [
- "male"
], - "last_name": [
- "Doe"
], - "marketing_consent": {
- "email": {
- "consent": [
- "true"
]
}, - "sms": {
- "consent": [
- "true"
]
}
}, - "status": [
- "vip"
], - "term": {
- "id": [
- "string"
]
}, - "type": [
- "string"
], - "attributes": {
- "property1": [
- "string"
], - "property2": [
- "string"
]
}
}, - "item": {
- "quantity": 0,
- "mixes": [
- {
- "items": [
- {
- "id": "b714118"
}, - {
- "group_id": "g4"
}
], - "quantity": 0,
- "reward_eligible": true
}
], - "items": [
- {
- "id": "b714118",
- "group_id": "B1"
}
]
}, - "store_ids": [
- "sc029"
], - "gross_amount": 0,
- "currencies": [
- {
- "anything-but": [
- "NOK"
]
}
], - "stamp": 5,
- "discount_code": "TACO",
- "store": {
- "id": [
- "sc029"
], - "name": [
- "SC Oslo"
], - "business_name": [
- "SC Oslo AS"
], - "address": {
- "country": [
- "NO"
], - "postal_code": [
- "0349"
], - "postal_place": [
- "Oslo"
]
}, - "chain": [
- "SuperChain"
], - "email": [
- "contact@superchain.com"
], - "gln": [
- "5790001398644"
], - "organization_number": [
- "123456789MVA"
], - "phone_number": [
- "+4738260107"
], - "mcc": [
- 5814
], - "mcc_ranges": [
- {
- "start": 5814,
- "end": 5815
}
], - "bax": [
- "102603"
], - "terminal_id": [
- "T0292"
]
}, - "purchase_from": "2019-08-24T14:15:22Z",
- "purchase_to": "2019-08-24T14:15:22Z"
}, - "reward": {
- "type": "discount_amount",
- "value": 10000,
- "values": [
- {
- "items": [
- {
- "id": "b714118",
- "group_id": "B1"
}
], - "value": 0
}
], - "base": "net",
- "effect": "discount"
}, - "metadata": {
- "campaign_id": "V101",
- "is_featured": true,
- "dintero:private_text:kind": "Gold"
}, - "links": [
- {
- "rel": "thumbnail_discount_image"
}, - {
- "rel": "medium_discount_image"
}, - {
- "rel": "webshoop"
}, - {
- "rel": "newletter",
- "type": "application/pdf"
}
]
}
Get list of customers refs for a discount. A ref is an instant
of discount given to a customer or all customers
. See
Add customers
scopes:
aid required | string <^[PT]{1}\d{8}$> = 9 characters An id that uniquely identifies the account. |
did required | string <uuid> An UUID that uniquely identifies the discount |
limit | integer [ 1 .. 1000 ] Default: 10 A limit on the number of refs to be returned. Limit can range between 1 and 1000, the default is 10 items. |
starting_after | string cursor for use in pagination. starting_after is an object ID
that defines your place in the list. For instance, if you make
a list request and receive 100 objects, end the result contains
|
state | string Default: "all" Enum: "all" "available" "deleted" "inactive" limit by state of customer ref, note, a customer ref will continue to be active after the discount has been deleted.
Use state |
[- {
- "id": "497f6eca-6276-4993-bfeb-53cbbbba6f08",
- "created_at": "2019-08-24T14:15:22Z",
- "created_by": "1c92f7e1-2897-4d46-bdcc-c127a914fb4e",
- "updated_at": "2019-08-24T14:15:22Z",
- "deleted_by": "1c92f7e1-2897-4d46-bdcc-c127a914fb4e",
- "deleted_at": "2019-08-24T14:15:22Z",
- "customer_id": "string"
}
]
Remove Discount from one or more customers
scopes:
aid required | string <^[PT]{1}\d{8}$> = 9 characters An id that uniquely identifies the account. |
did required | string <uuid> An UUID that uniquely identifies the discount |
Customers to give the discount to
###
Use value '*
' to remove the discounts from all customers
###
customers required | Array of strings |
{- "customers": [
- "102997af6e5e"
]
}
{- "statistics": {
- "stamp": 0,
- "used": 28,
- "usage": 28,
- "amount": 280000,
- "debit_balance": 12350
}, - "id": "497f6eca-6276-4993-bfeb-53cbbbba6f08",
- "created_at": "2019-08-24T14:15:22Z",
- "created_by": "1c92f7e1-2897-4d46-bdcc-c127a914fb4e",
- "updated_at": "2019-08-24T14:15:22Z",
- "deleted_by": "1c92f7e1-2897-4d46-bdcc-c127a914fb4e",
- "deleted_at": "2019-08-24T14:15:22Z",
- "campaign_id": "string",
- "active": true,
- "private": false,
- "updated_by": "3d1e4824-5474-48e7-a369-4f603fa4c5b8",
- "type": "item",
- "name": "Spar 100,-",
- "receipt_text": "Mai Salg",
- "visible_from": "2019-08-24T14:15:22Z",
- "description": "Gjør et Stablestol kupp!",
- "limitation": {
- "discount_activation": [
- {
- "type": "deactivate_if_discount_active",
- "value": "string"
}
], - "discount_hours": {
- "timezone": "Europe/Oslo",
- "hours": [
- {
- "day": "mon",
- "start": "10:00",
- "end": "20:00"
}
]
}, - "discount_reward_usage": 1,
- "discount_combination": -1,
- "discount_eligible": "item_eligible_for_discount",
- "discount_repeat_usage": -1,
- "stamp_expire_days": 100,
- "blacklist": [
- {
- "id": "b714118",
- "group_id": "B1"
}
]
}, - "requirement": {
- "customer": {
- "addresses": [
- {
- "country": [
- "NO"
], - "postal_code": [
- "0349"
], - "postal_place": [
- "Oslo"
], - "custom_type": [
- "offsite"
], - "type": [
- "custom"
]
}
], - "company": {
- "bussiness_name": [
- "TKP tech AS"
], - "department": [
- "production",
- "research"
], - "industry": [
- "J62.0.1",
- "J62.0.2"
], - "number_of_employees": [
- "20"
], - "organization_number": [
- "123456789MVA"
],
}, - "date_of_birth": [
- "1990-09-20",
- "1990-05-10"
], - "favorite_store": [
- "sc029"
], - "first_name": [
- "John"
], - "gender": [
- "male"
], - "last_name": [
- "Doe"
], - "marketing_consent": {
- "email": {
- "consent": [
- "true"
]
}, - "sms": {
- "consent": [
- "true"
]
}
}, - "status": [
- "vip"
], - "term": {
- "id": [
- "string"
]
}, - "type": [
- "string"
], - "attributes": {
- "property1": [
- "string"
], - "property2": [
- "string"
]
}
}, - "item": {
- "quantity": 0,
- "mixes": [
- {
- "items": [
- {
- "id": "b714118"
}, - {
- "group_id": "g4"
}
], - "quantity": 0,
- "reward_eligible": true
}
], - "items": [
- {
- "id": "b714118",
- "group_id": "B1"
}
]
}, - "store_ids": [
- "sc029"
], - "gross_amount": 0,
- "currencies": [
- {
- "anything-but": [
- "NOK"
]
}
], - "stamp": 5,
- "discount_code": "TACO",
- "store": {
- "id": [
- "sc029"
], - "name": [
- "SC Oslo"
], - "business_name": [
- "SC Oslo AS"
], - "address": {
- "country": [
- "NO"
], - "postal_code": [
- "0349"
], - "postal_place": [
- "Oslo"
]
}, - "chain": [
- "SuperChain"
], - "email": [
- "contact@superchain.com"
], - "gln": [
- "5790001398644"
], - "organization_number": [
- "123456789MVA"
], - "phone_number": [
- "+4738260107"
], - "mcc": [
- 5814
], - "mcc_ranges": [
- {
- "start": 5814,
- "end": 5815
}
], - "bax": [
- "102603"
], - "terminal_id": [
- "T0292"
]
}, - "purchase_from": "2019-08-24T14:15:22Z",
- "purchase_to": "2019-08-24T14:15:22Z"
}, - "reward": {
- "type": "discount_amount",
- "value": 10000,
- "values": [
- {
- "items": [
- {
- "id": "b714118",
- "group_id": "B1"
}
], - "value": 0
}
], - "base": "net",
- "effect": "discount"
}, - "metadata": {
- "campaign_id": "V101",
- "is_featured": true,
- "dintero:private_text:kind": "Gold"
}, - "links": [
- {
- "rel": "thumbnail_discount_image"
}, - {
- "rel": "medium_discount_image"
}, - {
- "rel": "webshoop"
}, - {
- "rel": "newletter",
- "type": "application/pdf"
}
]
}
Get list of discount refs usages. scopes:
aid required | string <^[PT]{1}\d{8}$> = 9 characters An id that uniquely identifies the account. |
did required | string <uuid> An UUID that uniquely identifies the discount |
limit | integer [ 1 .. 1000 ] Default: 10 A limit on the number of refs to be returned. Limit can range between 1 and 1000, the default is 10 items. |
starting_after | string cursor for use in pagination. starting_after is an object ID
that defines your place in the list. For instance, if you make
a list request and receive 100 objects, end the result contains
|
[- {
- "statistics": {
- "stamp": 0,
- "used": 28,
- "usage": 28,
- "amount": 280000,
- "debit_balance": 12350,
- "current_stamp": 0
}
}
]
Find discounts available for the receipt
customer_id
will be used to find active discounts for the purchase.customer.token
will be used to resolve customer_id
if no customer_id
is provided.customer_id
and no customer.token
will only be applicable for
active discounts given to /
(see)eligible_for_discount
set to enable for discountgross_amount
to qualify for discountnet
base discount reward requires the receipt to include existing
discounts as discount_lines (on item) in order to calculate netA receipt that qualified for discount will have the is_change
property set to true. Any items that has received a discount will be
flagged by is_change
and have one or more new entries to its
discount_lines.
The receipt discounts
list will be populated with all discounts the
receipt is qualified to receive
scopes:
aid required | string <^[PT]{1}\d{8}$> = 9 characters An id that uniquely identifies the account. |
receipt
required | object (Store) |
receipt_id required | string |
purchase_at required | string <date-time> The date and time for the receipt purchase |
Array of objects (DiscountRefs) List all discounts referenced in discount_lines | |
Array of objects (ReceiptItem) | |
object Details for the delivery | |
customer_id | string <= 255 characters The customer id identifying the customer. (must not have trailing or leading spaces) |
object The customer, owner of the receipt | |
gross_amount | integer Monetary amount in smallest unit for the currency before discounts |
gross_amount_dwh | string Monetary amount in smallest unit for the currency before discounts with decimal |
net_amount | integer Monetary amount in smallest unit for the currency after discounts |
net_amount_dwh | string Monetary value in smallest unit for the currency after discounts with decimal |
round_off_to_coin | integer |
currency | string The three-character ISO-4217 currency. https://en.wikipedia.org/wiki/ISO_4217 |
order_number | string |
transaction_date | string <date-time> |
amount_due | integer How much more need to be paid before the transaction is completed. Monetary amount in smallest unit for the currency |
amount_due_dwh | string Monetary value with decimal |
no_of_items | number How many items did the customer buy |
is_changed | boolean Discount applied to gross amount |
transaction_id | string |
total_discount | integer |
total_manual_discount_amount | integer Monetary amount in smallest unit for the currency |
total_manual_percentage_discount | integer |
operator_id | string POS user |
operator_name | string Name of the POS user |
salesperson_id | string ID of the POS user |
salesperson_name | string |
entry_status | string Enum: "None" "Voided" "Posted" "Concluded" "Cancelled" "OnHold" "Training" Status for the transaction |
comment | string |
Array of objects (TaxItem) Breakdown of the tax to different tax groups | |
Array of objects (PaymentItem) | |
Array of objects (InfoCodeItem) | |
receipt_text | string |
discount_code | Array of strings |
Array of objects (ExtraInfo) |
{- "discounts": [
- {
- "campaign_id": "string",
- "active": true,
- "private": false,
- "name": "Spar 100,-",
- "receipt_text": "Mai Salg",
- "visible_from": "2019-08-24T14:15:22Z",
- "description": "Gjør et Stablestol kupp!",
- "limitation": {
- "discount_activation": [
- {
- "type": "deactivate_if_discount_active",
- "value": "string"
}
], - "discount_hours": {
- "timezone": "Europe/Oslo",
- "hours": [
- {
- "day": "mon",
- "start": "10:00",
- "end": "20:00"
}
]
}, - "discount_reward_usage": 1,
- "discount_combination": -1,
- "discount_eligible": "item_eligible_for_discount",
- "discount_repeat_usage": -1,
- "stamp_expire_days": 100,
- "blacklist": [
- {
- "id": "b714118",
- "group_id": "B1"
}
]
}, - "requirement": {
- "customer": {
- "addresses": [
- {
- "country": [
- "NO"
], - "postal_code": [
- "0349"
], - "postal_place": [
- "Oslo"
], - "custom_type": [
- "offsite"
], - "type": [
- "custom"
]
}
], - "company": {
- "bussiness_name": [
- "TKP tech AS"
], - "department": [
- "production",
- "research"
], - "industry": [
- "J62.0.1",
- "J62.0.2"
], - "number_of_employees": [
- "20"
], - "organization_number": [
- "123456789MVA"
],
}, - "date_of_birth": [
- "1990-09-20",
- "1990-05-10"
], - "favorite_store": [
- "sc029"
], - "first_name": [
- "John"
], - "gender": [
- "male"
], - "last_name": [
- "Doe"
], - "marketing_consent": {
- "email": {
- "consent": [
- "true"
]
}, - "sms": {
- "consent": [
- "true"
]
}
}, - "status": [
- "vip"
], - "term": {
- "id": [
- "string"
]
}, - "type": [
- "string"
], - "attributes": {
- "property1": [
- "string"
], - "property2": [
- "string"
]
}
}, - "item": {
- "quantity": 0,
- "mixes": [
- {
- "items": [
- {
- "id": "b714118"
}, - {
- "group_id": "g4"
}
], - "quantity": 0,
- "reward_eligible": true
}
], - "items": [
- {
- "id": "b714118",
- "group_id": "B1"
}
]
}, - "store_ids": [
- "sc029"
], - "gross_amount": 0,
- "currencies": [
- {
- "anything-but": [
- "NOK"
]
}
], - "stamp": 5,
- "discount_code": "TACO",
- "store": {
- "id": [
- "sc029"
], - "name": [
- "SC Oslo"
], - "business_name": [
- "SC Oslo AS"
], - "address": {
- "country": [
- "NO"
], - "postal_code": [
- "0349"
], - "postal_place": [
- "Oslo"
]
}, - "chain": [
- "SuperChain"
], - "email": [
- "contact@superchain.com"
], - "gln": [
- "5790001398644"
], - "organization_number": [
- "123456789MVA"
], - "phone_number": [
- "+4738260107"
], - "mcc": [
- 5814
], - "mcc_ranges": [
- {
- "start": 5814,
- "end": 5815
}
], - "bax": [
- "102603"
], - "terminal_id": [
- "T0292"
]
}, - "purchase_from": "2019-08-24T14:15:22Z",
- "purchase_to": "2019-08-24T14:15:22Z"
}, - "reward": {
- "type": "discount_amount",
- "value": 10000,
- "values": [
- {
- "items": [
- {
- "id": "b714118",
- "group_id": "B1"
}
], - "value": 0
}
], - "base": "net",
- "effect": "discount"
}, - "metadata": {
- "campaign_id": "V101",
- "is_featured": true,
- "dintero:private_text:kind": "Gold"
}, - "links": [
- {
- "rel": "thumbnail_discount_image"
}, - {
- "rel": "medium_discount_image"
}, - {
- "rel": "webshoop"
}, - {
- "rel": "newletter",
- "type": "application/pdf"
}
], - "refs": [
- {
- "id": "e3da6be5-d8e0-466c-af66-b7f69472ebb5",
- "stamp": 0,
- "amount": 10000,
- "bonus": 9050,
- "statistics": {
- "amount": 15050,
- "bonus": 11050,
- "debit_balance": 12350,
- "stamp": 11,
- "usage": 2
}, - "items": [
- {
- "line_id": 1,
- "amount": 3000
}, - {
- "line_id": 5,
- "amount": 7000
}
], - "usage": 1
}
]
}
], - "store": {
- "id": "sc029",
- "name": "SC Oslo",
- "business_name": "SC Oslo AS",
- "address": {
- "address_line": "Sommerkroveien 34",
- "address_line_2": "PB 123",
- "postal_code": "0349",
- "postal_place": "Oslo",
- "country": "NO"
}, - "chain": "SuperChain",
- "email": "contact@superchain.com",
- "gln": "5790001398644",
- "organization_number": "123456789MVA",
- "phone_number": "+4738260107",
- "mcc": "5814",
- "bax": "102603",
- "terminal_id": "T0292"
}, - "items": [
- {
- "id": "175938",
- "groups": [
- {
- "id": "B234",
- "name": "Stol"
}, - {
- "id": "B1",
- "name": "Møbel"
}
], - "quantity": 2,
- "unit": "stk",
- "description": "Stablestol for utendørsbruk",
- "description_alias": "Stablestol",
- "net_amount": 27840,
- "net_amount_dwh": "27840.10",
- "gross_amount": 39800,
- "gross_amount_dwh": "34800.12",
- "unit_gross_price": 10900,
- "tax_percent": 25,
- "line_id": 1,
- "barcode": "3123212343212",
- "cost_price": 2033,
- "voided": false,
- "scale_item": false,
- "eligible_for_discount": true,
- "included_in_total_discount": true,
- "price_has_been_keyedIn": false,
- "discount_has_been_keyedIn": false,
- "is_return_item": false,
- "is_linked_item": false,
- "is_virtual_product": false,
- "is_changed": true,
- "salesperson_id": "000111",
- "salesperson_name": "Jesper",
- "serial_id": "32424234231312312",
- "comment": "Kan være hva som helst",
- "infocode_lines": [
- {
- "line_id": 1,
- "amount": 0,
- "amount_dwh": "1.14",
- "infocode_id": "string",
- "sub_infocode_id": "string",
- "information": "string",
- "input_type": 0,
- "withdrawal_from_stock": false
}
], - "tax_lines": [
- {
- "amount": 5584,
- "amount_dwh": "5584.0440",
- "exempt": false,
- "included_in_price": true,
- "percentage": 25,
- "tax_basis": 27920,
- "tax_basis_dwh": "27920.22",
- "tax_code": "3",
- "tax_group": "Vmva-høy"
}
], - "dimension": {
- "color": "string",
- "size": "string",
- "style": "string",
- "config": "string",
- "variant": "string"
}, - "discount_lines": [
- {
- "amount": 4400,
- "percentage": 44,
- "discount_type": "customer",
- "discount_id": "766da0ef-9283-42bd-b012-0582344ec53c",
- "description": "string",
- "line_id": 1
}
], - "bonus_lines": [
- {
- "bonus": 3130,
- "percentage": 10,
- "discount_type": "customer",
- "discount_id": "766da0ef-9283-42bd-b012-0582344ec53c",
- "description": "string",
- "line_id": 1
}
], - "extra_info": [
- {
- "key": "string",
- "value": "string",
- "value_type": "string"
}
]
}
], - "receipt_id": "714118",
- "delivery": {
- "first_name": "John",
- "last_name": "Doe",
- "email": "customer@example.com",
- "phone_number": "+4799999999",
- "address": {
- "address_line": "Sommerkroveien 34",
- "address_line_2": "PB 123",
- "postal_code": "0349",
- "postal_place": "Oslo",
- "country": "NO"
}
}, - "customer_id": "C13db4f63",
- "customer": {
- "gender": "male",
- "first_name": "John",
- "last_name": "Doe",
- "email": "customer@example.com",
- "metadata": {
- "dob_year": 1985
}, - "phone_number": "+4799999999",
- "addresses": [
- {
- "address_line": "Sommerkroveien 34",
- "address_line_2": "PB 123",
- "postal_code": "0349",
- "postal_place": "Oslo",
- "country": "NO",
- "type": "string",
- "custom_type": "string"
}
], - "pays_tax": false,
- "date_of_birth": "1990-09-20",
- "favorite_store": "string",
- "company": {
- "organization_number": "123456789MVA",
- "bussiness_name": "TKP tech AS",
- "department": "sales department",
- "industry": "computer industry",
- "website": "string",
- "number_of_employees": "string"
}, - "marketing_consent": {
- "sms": {
- "consent": true
}, - "email": {
- "consent": true
}
}, - "status": "string",
- "term": {
- "id": "string"
}, - "type": "customer",
- "token": {
- "token_id": "983558fe-05bd-495f-92b5-9075d085db32",
- "value": "5345346544ffea22",
- "type": "VIPPS"
}
}, - "gross_amount": 59800,
- "gross_amount_dwh": "59800.01",
- "net_amount": 47840,
- "net_amount_dwh": "47840.01",
- "round_off_to_coin": 100,
- "currency": "NOK",
- "purchase_at": "2019-08-24T14:15:22Z",
- "order_number": "order12345",
- "transaction_date": "2019-08-24T14:15:22Z",
- "amount_due": 2050,
- "amount_due_dwh": "2050.10",
- "no_of_items": 4,
- "is_changed": true,
- "transaction_id": "SC999-9991-1828",
- "total_discount": 0,
- "total_manual_discount_amount": 0,
- "total_manual_percentage_discount": 0,
- "operator_id": "000210",
- "operator_name": "Ole Anders",
- "salesperson_id": "000111",
- "salesperson_name": "Jesper",
- "entry_status": "None",
- "comment": "Kunden ønsker mer for info",
- "tax_lines": [
- {
- "amount": 5584,
- "amount_dwh": "5584.0440",
- "exempt": false,
- "included_in_price": true,
- "percentage": 25,
- "tax_basis": 27920,
- "tax_basis_dwh": "27920.22",
- "tax_code": "3",
- "tax_group": "Vmva-høy"
}
], - "payments": [
- {
- "line_id": 1,
- "amount": 0,
- "type_id": "string",
- "token_id": "983558fe-05bd-495f-92b5-9075d085db32",
- "token_type": "VIPPS",
- "description": "string",
- "voided": true,
- "card_info": {
- "balance_amount": 0,
- "card_amount": 0,
- "issuer_id": 0,
- "issuer_name": "Barcley",
- "session_id": "022",
- "terminal_id": "71015233",
- "card_number": "************00198-1",
- "card_type": "VISA",
- "receipt": "BAX: 111010-71015233\\n\\r\\11/11/2015 14:41\\n\\r\\345849\\n\\r\\ VISA CLASSIC\\n\\r\\************5671\\n\\r\\AID:A0000000031010\\n\\r\\ REF:011 006687000000\\n\\r\\RESP:00 GODKJENT\\n\\r\\RETUR AV VARER\\n\\r \\NOK= 50.00\\n\\r\\SIGNATUR................\\n\\r \\KORTHOLDERS KOPI\n"
}, - "reference_id": "B00668107235",
- "infocode_lines": [
- {
- "line_id": 1,
- "amount": 0,
- "amount_dwh": "1.14",
- "infocode_id": "string",
- "sub_infocode_id": "string",
- "information": "string",
- "input_type": 0,
- "withdrawal_from_stock": false
}
]
}
], - "infocode_items": [
- {
- "line_id": 1,
- "amount": 0,
- "amount_dwh": "1.14",
- "infocode_id": "string",
- "sub_infocode_id": "string",
- "information": "string",
- "input_type": 0,
- "withdrawal_from_stock": false
}
], - "receipt_text": "string",
- "discount_code": [
- "string"
], - "extra_info": [
- {
- "key": "string",
- "value": "string",
- "value_type": "string"
}
]
}
{- "id": "497f6eca-6276-4993-bfeb-53cbbbba6f08",
- "created_at": "2019-08-24T14:15:22Z",
- "created_by": "1c92f7e1-2897-4d46-bdcc-c127a914fb4e",
- "updated_at": "2019-08-24T14:15:22Z",
- "deleted_by": "1c92f7e1-2897-4d46-bdcc-c127a914fb4e",
- "deleted_at": "2019-08-24T14:15:22Z",
- "discounts": [
- {
- "id": "497f6eca-6276-4993-bfeb-53cbbbba6f08",
- "created_at": "2019-08-24T14:15:22Z",
- "created_by": "1c92f7e1-2897-4d46-bdcc-c127a914fb4e",
- "updated_at": "2019-08-24T14:15:22Z",
- "deleted_by": "1c92f7e1-2897-4d46-bdcc-c127a914fb4e",
- "deleted_at": "2019-08-24T14:15:22Z",
- "campaign_id": "string",
- "active": true,
- "private": false,
- "updated_by": "3d1e4824-5474-48e7-a369-4f603fa4c5b8",
- "type": "item",
- "name": "Spar 100,-",
- "receipt_text": "Mai Salg",
- "visible_from": "2019-08-24T14:15:22Z",
- "description": "Gjør et Stablestol kupp!",
- "limitation": {
- "discount_activation": [
- {
- "type": "deactivate_if_discount_active",
- "value": "string"
}
], - "discount_hours": {
- "timezone": "Europe/Oslo",
- "hours": [
- {
- "day": "mon",
- "start": "10:00",
- "end": "20:00"
}
]
}, - "discount_reward_usage": 1,
- "discount_combination": -1,
- "discount_eligible": "item_eligible_for_discount",
- "discount_repeat_usage": -1,
- "stamp_expire_days": 100,
- "blacklist": [
- {
- "id": "b714118",
- "group_id": "B1"
}
]
}, - "requirement": {
- "customer": {
- "addresses": [
- {
- "country": [
- "NO"
], - "postal_code": [
- "0349"
], - "postal_place": [
- "Oslo"
], - "custom_type": [
- "offsite"
], - "type": [
- "custom"
]
}
], - "company": {
- "bussiness_name": [
- "TKP tech AS"
], - "department": [
- "production",
- "research"
], - "industry": [
- "J62.0.1",
- "J62.0.2"
], - "number_of_employees": [
- "20"
], - "organization_number": [
- "123456789MVA"
],
}, - "date_of_birth": [
- "1990-09-20",
- "1990-05-10"
], - "favorite_store": [
- "sc029"
], - "first_name": [
- "John"
], - "gender": [
- "male"
], - "last_name": [
- "Doe"
], - "marketing_consent": {
- "email": {
- "consent": [
- "true"
]
}, - "sms": {
- "consent": [
- "true"
]
}
}, - "status": [
- "vip"
], - "term": {
- "id": [
- "string"
]
}, - "type": [
- "string"
], - "attributes": {
- "property1": [
- "string"
], - "property2": [
- "string"
]
}
}, - "item": {
- "quantity": 0,
- "mixes": [
- {
- "items": [
- {
- "id": "b714118"
}, - {
- "group_id": "g4"
}
], - "quantity": 0,
- "reward_eligible": true
}
], - "items": [
- {
- "id": "b714118",
- "group_id": "B1"
}
]
}, - "store_ids": [
- "sc029"
], - "gross_amount": 0,
- "currencies": [
- {
- "anything-but": [
- "NOK"
]
}
], - "stamp": 5,
- "discount_code": "TACO",
- "store": {
- "id": [
- "sc029"
], - "name": [
- "SC Oslo"
], - "business_name": [
- "SC Oslo AS"
], - "address": {
- "country": [
- "NO"
], - "postal_code": [
- "0349"
], - "postal_place": [
- "Oslo"
]
}, - "chain": [
- "SuperChain"
], - "email": [
- "contact@superchain.com"
], - "gln": [
- "5790001398644"
], - "organization_number": [
- "123456789MVA"
], - "phone_number": [
- "+4738260107"
], - "mcc": [
- 5814
], - "mcc_ranges": [
- {
- "start": 5814,
- "end": 5815
}
], - "bax": [
- "102603"
], - "terminal_id": [
- "T0292"
]
}, - "purchase_from": "2019-08-24T14:15:22Z",
- "purchase_to": "2019-08-24T14:15:22Z"
}, - "reward": {
- "type": "discount_amount",
- "value": 10000,
- "values": [
- {
- "items": [
- {
- "id": "b714118",
- "group_id": "B1"
}
], - "value": 0
}
], - "base": "net",
- "effect": "discount"
}, - "metadata": {
- "campaign_id": "V101",
- "is_featured": true,
- "dintero:private_text:kind": "Gold"
}, - "links": [
- {
- "rel": "thumbnail_discount_image"
}, - {
- "rel": "medium_discount_image"
}, - {
- "rel": "webshoop"
}, - {
- "rel": "newletter",
- "type": "application/pdf"
}
], - "refs": [
- {
- "id": "e3da6be5-d8e0-466c-af66-b7f69472ebb5",
- "stamp": 0,
- "amount": 10000,
- "bonus": 9050,
- "statistics": {
- "amount": 15050,
- "bonus": 11050,
- "debit_balance": 12350,
- "stamp": 11,
- "usage": 2
}, - "items": [
- {
- "line_id": 1,
- "amount": 3000
}, - {
- "line_id": 5,
- "amount": 7000
}
], - "usage": 1
}
]
}
], - "store": {
- "id": "sc029",
- "name": "SC Oslo",
- "business_name": "SC Oslo AS",
- "address": {
- "address_line": "Sommerkroveien 34",
- "address_line_2": "PB 123",
- "postal_code": "0349",
- "postal_place": "Oslo",
- "country": "NO"
}, - "chain": "SuperChain",
- "email": "contact@superchain.com",
- "gln": "5790001398644",
- "organization_number": "123456789MVA",
- "phone_number": "+4738260107",
- "mcc": "5814",
- "bax": "102603",
- "terminal_id": "T0292"
}, - "items": [
- {
- "id": "175938",
- "groups": [
- {
- "id": "B234",
- "name": "Stol"
}, - {
- "id": "B1",
- "name": "Møbel"
}
], - "quantity": 2,
- "unit": "stk",
- "description": "Stablestol for utendørsbruk",
- "description_alias": "Stablestol",
- "net_amount": 27840,
- "net_amount_dwh": "27840.10",
- "gross_amount": 39800,
- "gross_amount_dwh": "34800.12",
- "unit_gross_price": 10900,
- "tax_percent": 25,
- "line_id": 1,
- "barcode": "3123212343212",
- "cost_price": 2033,
- "voided": false,
- "scale_item": false,
- "eligible_for_discount": true,
- "included_in_total_discount": true,
- "price_has_been_keyedIn": false,
- "discount_has_been_keyedIn": false,
- "is_return_item": false,
- "is_linked_item": false,
- "is_virtual_product": false,
- "is_changed": true,
- "salesperson_id": "000111",
- "salesperson_name": "Jesper",
- "serial_id": "32424234231312312",
- "comment": "Kan være hva som helst",
- "infocode_lines": [
- {
- "line_id": 1,
- "amount": 0,
- "amount_dwh": "1.14",
- "infocode_id": "string",
- "sub_infocode_id": "string",
- "information": "string",
- "input_type": 0,
- "withdrawal_from_stock": false
}
], - "tax_lines": [
- {
- "amount": 5584,
- "amount_dwh": "5584.0440",
- "exempt": false,
- "included_in_price": true,
- "percentage": 25,
- "tax_basis": 27920,
- "tax_basis_dwh": "27920.22",
- "tax_code": "3",
- "tax_group": "Vmva-høy"
}
], - "dimension": {
- "color": "string",
- "size": "string",
- "style": "string",
- "config": "string",
- "variant": "string"
}, - "discount_lines": [
- {
- "amount": 4400,
- "percentage": 44,
- "discount_type": "customer",
- "discount_id": "766da0ef-9283-42bd-b012-0582344ec53c",
- "description": "string",
- "line_id": 1
}
], - "bonus_lines": [
- {
- "bonus": 3130,
- "percentage": 10,
- "discount_type": "customer",
- "discount_id": "766da0ef-9283-42bd-b012-0582344ec53c",
- "description": "string",
- "line_id": 1
}
], - "extra_info": [
- {
- "key": "string",
- "value": "string",
- "value_type": "string"
}
]
}
], - "receipt_id": "714118",
- "delivery": {
- "first_name": "John",
- "last_name": "Doe",
- "email": "customer@example.com",
- "phone_number": "+4799999999",
- "address": {
- "address_line": "Sommerkroveien 34",
- "address_line_2": "PB 123",
- "postal_code": "0349",
- "postal_place": "Oslo",
- "country": "NO"
}
}, - "customer_id": "C13db4f63",
- "customer": {
- "gender": "male",
- "first_name": "John",
- "last_name": "Doe",
- "email": "customer@example.com",
- "metadata": {
- "dob_year": 1985
}, - "phone_number": "+4799999999",
- "addresses": [
- {
- "address_line": "Sommerkroveien 34",
- "address_line_2": "PB 123",
- "postal_code": "0349",
- "postal_place": "Oslo",
- "country": "NO",
- "type": "string",
- "custom_type": "string"
}
], - "pays_tax": false,
- "date_of_birth": "1990-09-20",
- "favorite_store": "string",
- "company": {
- "organization_number": "123456789MVA",
- "bussiness_name": "TKP tech AS",
- "department": "sales department",
- "industry": "computer industry",
- "website": "string",
- "number_of_employees": "string"
}, - "marketing_consent": {
- "sms": {
- "consent": true,
- "updated_at": "2018-01-12T13:42:00Z"
}, - "email": {
- "consent": true,
- "updated_at": "2018-01-12T13:42:00Z"
}
}, - "status": "string",
- "term": {
- "id": "string"
}, - "type": "customer",
- "token": {
- "token_id": "983558fe-05bd-495f-92b5-9075d085db32",
- "value": "5345346544ffea22",
- "type": "VIPPS"
}
}, - "gross_amount": 59800,
- "gross_amount_dwh": "59800.01",
- "net_amount": 47840,
- "net_amount_dwh": "47840.01",
- "round_off_to_coin": 100,
- "currency": "NOK",
- "purchase_at": "2019-08-24T14:15:22Z",
- "order_number": "order12345",
- "transaction_date": "2019-08-24T14:15:22Z",
- "amount_due": 2050,
- "amount_due_dwh": "2050.10",
- "no_of_items": 4,
- "is_changed": true,
- "transaction_id": "SC999-9991-1828",
- "total_discount": 0,
- "total_manual_discount_amount": 0,
- "total_manual_percentage_discount": 0,
- "operator_id": "000210",
- "operator_name": "Ole Anders",
- "salesperson_id": "000111",
- "salesperson_name": "Jesper",
- "entry_status": "None",
- "comment": "Kunden ønsker mer for info",
- "tax_lines": [
- {
- "amount": 5584,
- "amount_dwh": "5584.0440",
- "exempt": false,
- "included_in_price": true,
- "percentage": 25,
- "tax_basis": 27920,
- "tax_basis_dwh": "27920.22",
- "tax_code": "3",
- "tax_group": "Vmva-høy"
}
], - "payments": [
- {
- "line_id": 1,
- "amount": 0,
- "type_id": "string",
- "token_id": "983558fe-05bd-495f-92b5-9075d085db32",
- "token_type": "VIPPS",
- "description": "string",
- "voided": true,
- "card_info": {
- "balance_amount": 0,
- "card_amount": 0,
- "issuer_id": 0,
- "issuer_name": "Barcley",
- "session_id": "022",
- "terminal_id": "71015233",
- "card_number": "************00198-1",
- "card_type": "VISA",
- "receipt": "BAX: 111010-71015233\\n\\r\\11/11/2015 14:41\\n\\r\\345849\\n\\r\\ VISA CLASSIC\\n\\r\\************5671\\n\\r\\AID:A0000000031010\\n\\r\\ REF:011 006687000000\\n\\r\\RESP:00 GODKJENT\\n\\r\\RETUR AV VARER\\n\\r \\NOK= 50.00\\n\\r\\SIGNATUR................\\n\\r \\KORTHOLDERS KOPI\n"
}, - "reference_id": "B00668107235",
- "infocode_lines": [
- {
- "line_id": 1,
- "amount": 0,
- "amount_dwh": "1.14",
- "infocode_id": "string",
- "sub_infocode_id": "string",
- "information": "string",
- "input_type": 0,
- "withdrawal_from_stock": false
}
]
}
], - "infocode_items": [
- {
- "line_id": 1,
- "amount": 0,
- "amount_dwh": "1.14",
- "infocode_id": "string",
- "sub_infocode_id": "string",
- "information": "string",
- "input_type": 0,
- "withdrawal_from_stock": false
}
], - "receipt_text": "string",
- "discount_code": [
- "string"
], - "extra_info": [
- {
- "key": "string",
- "value": "string",
- "value_type": "string"
}
]
}
Get all claims, limited by parameters. The result will
match all parameters with AND
scopes:
aid required | string <^[PT]{1}\d{8}$> = 9 characters An id that uniquely identifies the account. |
limit | integer [ 1 .. 100 ] Default: 10 A limit on the number of objects to be returned. Limit can range between 1 and 100 items, and the default is 10 items. |
starting_after | string cursor for use in pagination. starting_after is an object ID
that defines your place in the list. For instance, if you make
a list request and receive 100 objects, end the result contains
|
ref | string filter claims by ref |
customer_id | string filter claims by customer_id |
total | boolean Default: false include |
[- {
- "id": "497f6eca-6276-4993-bfeb-53cbbbba6f08",
- "created_at": "2019-08-24T14:15:22Z",
- "created_by": "1c92f7e1-2897-4d46-bdcc-c127a914fb4e",
- "updated_at": "2019-08-24T14:15:22Z",
- "deleted_by": "1c92f7e1-2897-4d46-bdcc-c127a914fb4e",
- "deleted_at": "2019-08-24T14:15:22Z",
- "ref": "transactionid1",
- "type": "pos",
- "purchase_at": "2019-08-24T14:15:22Z",
- "customer_id": "string",
- "discounts": [
- {
- "id": "string",
- "refs": [
- {
- "id": "string",
- "amount": 0,
- "usage": 1
}
]
}
]
}
]
Claim discount rewards, checks will be done to ensure that all discount limitation are uphold
Note, only the following discount limitation will affect the success of a claim
scopes:
aid required | string <^[PT]{1}\d{8}$> = 9 characters An id that uniquely identifies the account. |
discounts to claim
customer_id required | string <= 255 characters The customer id you have defined for the customer. (must not have trailing or leading spaces) |
required | Array of objects non-empty Discounts to claim |
purchase_at required | string <date-time> The date and time for the purchase the claim is done for. |
ref | string an external reference for the claim. Must be unique for the claim, reuse of ref will result in conflict |
type | string an external type for the claim |
{- "ref": "transactionid1",
- "type": "pos",
- "purchase_at": "2019-08-24T14:15:22Z",
- "customer_id": "string",
- "discounts": [
- {
- "id": "string",
- "refs": [
- {
- "id": "string",
- "amount": 0,
- "usage": 1
}
]
}
]
}
{- "id": "497f6eca-6276-4993-bfeb-53cbbbba6f08",
- "created_at": "2019-08-24T14:15:22Z",
- "created_by": "1c92f7e1-2897-4d46-bdcc-c127a914fb4e",
- "updated_at": "2019-08-24T14:15:22Z",
- "deleted_by": "1c92f7e1-2897-4d46-bdcc-c127a914fb4e",
- "deleted_at": "2019-08-24T14:15:22Z",
- "ref": "transactionid1",
- "type": "pos",
- "purchase_at": "2019-08-24T14:15:22Z",
- "customer_id": "string",
- "discounts": [
- {
- "id": "string",
- "refs": [
- {
- "id": "string",
- "amount": 0,
- "usage": 1
}
]
}
]
}
Release claim on discounts, revert previously claimed discount and make them available for future purchase
scopes:
aid required | string <^[PT]{1}\d{8}$> = 9 characters An id that uniquely identifies the account. |
claim_id required | string A string that uniquely identifies claim |
{- "id": "497f6eca-6276-4993-bfeb-53cbbbba6f08",
- "created_at": "2019-08-24T14:15:22Z",
- "created_by": "1c92f7e1-2897-4d46-bdcc-c127a914fb4e",
- "updated_at": "2019-08-24T14:15:22Z",
- "deleted_by": "1c92f7e1-2897-4d46-bdcc-c127a914fb4e",
- "deleted_at": "2019-08-24T14:15:22Z",
- "ref": "transactionid1",
- "type": "pos",
- "purchase_at": "2019-08-24T14:15:22Z",
- "customer_id": "string",
- "discounts": [
- {
- "id": "string",
- "refs": [
- {
- "id": "string",
- "amount": 0,
- "usage": 1
}
]
}
]
}
Get details about a claim
scopes:
aid required | string <^[PT]{1}\d{8}$> = 9 characters An id that uniquely identifies the account. |
claim_id required | string A string that uniquely identifies claim |
{- "id": "497f6eca-6276-4993-bfeb-53cbbbba6f08",
- "created_at": "2019-08-24T14:15:22Z",
- "created_by": "1c92f7e1-2897-4d46-bdcc-c127a914fb4e",
- "updated_at": "2019-08-24T14:15:22Z",
- "deleted_by": "1c92f7e1-2897-4d46-bdcc-c127a914fb4e",
- "deleted_at": "2019-08-24T14:15:22Z",
- "ref": "transactionid1",
- "type": "pos",
- "purchase_at": "2019-08-24T14:15:22Z",
- "customer_id": "string",
- "discounts": [
- {
- "id": "string",
- "refs": [
- {
- "id": "string",
- "amount": 0,
- "usage": 1
}
]
}
]
}
Send an Event to the service.
rules automations will receive the event and give its discount to the customer found in the event
Token received will be stored to support resolving customer from token when handling discounts available for receipt
scopes:
aid required | string <^[PT]{1}\d{8}$> = 9 characters An id that uniquely identifies the account. |
event required | string Enum: "token_add" "token_remove" "receipt_add" The event type that was sent |
event-delivery required | string <uuid> UUID to identify the payload and event being sent. |
The event payload, e.g. a Customer, Receipt or Token
object (Receipt) | |
object |
{- "receipt": {
- "id": "string",
- "discounts": [
- {
- "campaign_id": "string",
- "active": true,
- "private": false,
- "name": "Spar 100,-",
- "receipt_text": "Mai Salg",
- "visible_from": "2019-08-24T14:15:22Z",
- "description": "Gjør et Stablestol kupp!",
- "limitation": {
- "discount_activation": [
- {
- "type": "deactivate_if_discount_active",
- "value": "string"
}
], - "discount_hours": {
- "timezone": "Europe/Oslo",
- "hours": [
- {
- "day": "mon",
- "start": "10:00",
- "end": "20:00"
}
]
}, - "discount_reward_usage": 1,
- "discount_combination": -1,
- "discount_eligible": "item_eligible_for_discount",
- "discount_repeat_usage": -1,
- "stamp_expire_days": 100,
- "blacklist": [
- {
- "id": "b714118",
- "group_id": "B1"
}
]
}, - "requirement": {
- "customer": {
- "addresses": [
- {
- "country": [
- "NO"
], - "postal_code": [
- "0349"
], - "postal_place": [
- "Oslo"
], - "custom_type": [
- "offsite"
], - "type": [
- "custom"
]
}
], - "company": {
- "bussiness_name": [
- "TKP tech AS"
], - "department": [
- "production",
- "research"
], - "industry": [
- "J62.0.1",
- "J62.0.2"
], - "number_of_employees": [
- "20"
], - "organization_number": [
- "123456789MVA"
],
}, - "date_of_birth": [
- "1990-09-20",
- "1990-05-10"
], - "favorite_store": [
- "sc029"
], - "first_name": [
- "John"
], - "gender": [
- "male"
], - "last_name": [
- "Doe"
], - "marketing_consent": {
- "email": {
- "consent": [
- "true"
]
}, - "sms": {
- "consent": [
- "true"
]
}
}, - "status": [
- "vip"
], - "term": {
- "id": [
- "string"
]
}, - "type": [
- "string"
], - "attributes": {
- "property1": [
- "string"
], - "property2": [
- "string"
]
}
}, - "item": {
- "quantity": 0,
- "mixes": [
- {
- "items": [
- {
- "id": "b714118"
}, - {
- "group_id": "g4"
}
], - "quantity": 0,
- "reward_eligible": true
}
], - "items": [
- {
- "id": "b714118",
- "group_id": "B1"
}
]
}, - "store_ids": [
- "sc029"
], - "gross_amount": 0,
- "currencies": [
- {
- "anything-but": [
- "NOK"
]
}
], - "stamp": 5,
- "discount_code": "TACO",
- "store": {
- "id": [
- "sc029"
], - "name": [
- "SC Oslo"
], - "business_name": [
- "SC Oslo AS"
], - "address": {
- "country": [
- "NO"
], - "postal_code": [
- "0349"
], - "postal_place": [
- "Oslo"
]
}, - "chain": [
- "SuperChain"
], - "email": [
- "contact@superchain.com"
], - "gln": [
- "5790001398644"
], - "organization_number": [
- "123456789MVA"
], - "phone_number": [
- "+4738260107"
], - "mcc": [
- 5814
], - "mcc_ranges": [
- {
- "start": 5814,
- "end": 5815
}
], - "bax": [
- "102603"
], - "terminal_id": [
- "T0292"
]
}, - "purchase_from": "2019-08-24T14:15:22Z",
- "purchase_to": "2019-08-24T14:15:22Z"
}, - "reward": {
- "type": "discount_amount",
- "value": 10000,
- "values": [
- {
- "items": [
- {
- "id": "b714118",
- "group_id": "B1"
}
], - "value": 0
}
], - "base": "net",
- "effect": "discount"
}, - "metadata": {
- "campaign_id": "V101",
- "is_featured": true,
- "dintero:private_text:kind": "Gold"
}, - "links": [
- {
- "rel": "thumbnail_discount_image"
}, - {
- "rel": "medium_discount_image"
}, - {
- "rel": "webshoop"
}, - {
- "rel": "newletter",
- "type": "application/pdf"
}
], - "refs": [
- {
- "id": "e3da6be5-d8e0-466c-af66-b7f69472ebb5",
- "stamp": 0,
- "amount": 10000,
- "bonus": 9050,
- "statistics": {
- "amount": 15050,
- "bonus": 11050,
- "debit_balance": 12350,
- "stamp": 11,
- "usage": 2
}, - "items": [
- {
- "line_id": 1,
- "amount": 3000
}, - {
- "line_id": 5,
- "amount": 7000
}
], - "usage": 1
}
]
}
], - "store": {
- "id": "sc029",
- "name": "SC Oslo",
- "business_name": "SC Oslo AS",
- "address": {
- "address_line": "Sommerkroveien 34",
- "address_line_2": "PB 123",
- "postal_code": "0349",
- "postal_place": "Oslo",
- "country": "NO"
}, - "chain": "SuperChain",
- "email": "contact@superchain.com",
- "gln": "5790001398644",
- "organization_number": "123456789MVA",
- "phone_number": "+4738260107",
- "mcc": "5814",
- "bax": "102603",
- "terminal_id": "T0292"
}, - "items": [
- {
- "id": "175938",
- "groups": [
- {
- "id": "B234",
- "name": "Stol"
}, - {
- "id": "B1",
- "name": "Møbel"
}
], - "quantity": 2,
- "unit": "stk",
- "description": "Stablestol for utendørsbruk",
- "description_alias": "Stablestol",
- "net_amount": 27840,
- "net_amount_dwh": "27840.10",
- "gross_amount": 39800,
- "gross_amount_dwh": "34800.12",
- "unit_gross_price": 10900,
- "tax_percent": 25,
- "line_id": 1,
- "barcode": "3123212343212",
- "cost_price": 2033,
- "voided": false,
- "scale_item": false,
- "eligible_for_discount": true,
- "included_in_total_discount": true,
- "price_has_been_keyedIn": false,
- "discount_has_been_keyedIn": false,
- "is_return_item": false,
- "is_linked_item": false,
- "is_virtual_product": false,
- "is_changed": true,
- "salesperson_id": "000111",
- "salesperson_name": "Jesper",
- "serial_id": "32424234231312312",
- "comment": "Kan være hva som helst",
- "infocode_lines": [
- {
- "line_id": 1,
- "amount": 0,
- "amount_dwh": "1.14",
- "infocode_id": "string",
- "sub_infocode_id": "string",
- "information": "string",
- "input_type": 0,
- "withdrawal_from_stock": false
}
], - "tax_lines": [
- {
- "amount": 5584,
- "amount_dwh": "5584.0440",
- "exempt": false,
- "included_in_price": true,
- "percentage": 25,
- "tax_basis": 27920,
- "tax_basis_dwh": "27920.22",
- "tax_code": "3",
- "tax_group": "Vmva-høy"
}
], - "dimension": {
- "color": "string",
- "size": "string",
- "style": "string",
- "config": "string",
- "variant": "string"
}, - "discount_lines": [
- {
- "amount": 4400,
- "percentage": 44,
- "discount_type": "customer",
- "discount_id": "766da0ef-9283-42bd-b012-0582344ec53c",
- "description": "string",
- "line_id": 1
}
], - "bonus_lines": [
- {
- "bonus": 3130,
- "percentage": 10,
- "discount_type": "customer",
- "discount_id": "766da0ef-9283-42bd-b012-0582344ec53c",
- "description": "string",
- "line_id": 1
}
], - "extra_info": [
- {
- "key": "string",
- "value": "string",
- "value_type": "string"
}
]
}
], - "receipt_id": "714118",
- "delivery": {
- "first_name": "John",
- "last_name": "Doe",
- "email": "customer@example.com",
- "phone_number": "+4799999999",
- "address": {
- "address_line": "Sommerkroveien 34",
- "address_line_2": "PB 123",
- "postal_code": "0349",
- "postal_place": "Oslo",
- "country": "NO"
}
}, - "customer_id": "C13db4f63",
- "customer": {
- "gender": "male",
- "first_name": "John",
- "last_name": "Doe",
- "email": "customer@example.com",
- "metadata": {
- "dob_year": 1985
}, - "phone_number": "+4799999999",
- "addresses": [
- {
- "address_line": "Sommerkroveien 34",
- "address_line_2": "PB 123",
- "postal_code": "0349",
- "postal_place": "Oslo",
- "country": "NO",
- "type": "string",
- "custom_type": "string"
}
], - "pays_tax": false,
- "date_of_birth": "1990-09-20",
- "favorite_store": "string",
- "company": {
- "organization_number": "123456789MVA",
- "bussiness_name": "TKP tech AS",
- "department": "sales department",
- "industry": "computer industry",
- "website": "string",
- "number_of_employees": "string"
}, - "marketing_consent": {
- "sms": {
- "consent": true
}, - "email": {
- "consent": true
}
}, - "status": "string",
- "term": {
- "id": "string"
}, - "type": "customer",
- "token": {
- "token_id": "983558fe-05bd-495f-92b5-9075d085db32",
- "value": "5345346544ffea22",
- "type": "VIPPS"
}
}, - "gross_amount": 59800,
- "gross_amount_dwh": "59800.01",
- "net_amount": 47840,
- "net_amount_dwh": "47840.01",
- "round_off_to_coin": 100,
- "currency": "NOK",
- "purchase_at": "2019-08-24T14:15:22Z",
- "order_number": "order12345",
- "transaction_date": "2019-08-24T14:15:22Z",
- "amount_due": 2050,
- "amount_due_dwh": "2050.10",
- "no_of_items": 4,
- "is_changed": true,
- "transaction_id": "SC999-9991-1828",
- "total_discount": 0,
- "total_manual_discount_amount": 0,
- "total_manual_percentage_discount": 0,
- "operator_id": "000210",
- "operator_name": "Ole Anders",
- "salesperson_id": "000111",
- "salesperson_name": "Jesper",
- "entry_status": "None",
- "comment": "Kunden ønsker mer for info",
- "tax_lines": [
- {
- "amount": 5584,
- "amount_dwh": "5584.0440",
- "exempt": false,
- "included_in_price": true,
- "percentage": 25,
- "tax_basis": 27920,
- "tax_basis_dwh": "27920.22",
- "tax_code": "3",
- "tax_group": "Vmva-høy"
}
], - "payments": [
- {
- "line_id": 1,
- "amount": 0,
- "type_id": "string",
- "token_id": "983558fe-05bd-495f-92b5-9075d085db32",
- "token_type": "VIPPS",
- "description": "string",
- "voided": true,
- "card_info": {
- "balance_amount": 0,
- "card_amount": 0,
- "issuer_id": 0,
- "issuer_name": "Barcley",
- "session_id": "022",
- "terminal_id": "71015233",
- "card_number": "************00198-1",
- "card_type": "VISA",
- "receipt": "BAX: 111010-71015233\\n\\r\\11/11/2015 14:41\\n\\r\\345849\\n\\r\\ VISA CLASSIC\\n\\r\\************5671\\n\\r\\AID:A0000000031010\\n\\r\\ REF:011 006687000000\\n\\r\\RESP:00 GODKJENT\\n\\r\\RETUR AV VARER\\n\\r \\NOK= 50.00\\n\\r\\SIGNATUR................\\n\\r \\KORTHOLDERS KOPI\n"
}, - "reference_id": "B00668107235",
- "infocode_lines": [
- {
- "line_id": 1,
- "amount": 0,
- "amount_dwh": "1.14",
- "infocode_id": "string",
- "sub_infocode_id": "string",
- "information": "string",
- "input_type": 0,
- "withdrawal_from_stock": false
}
]
}
], - "infocode_items": [
- {
- "line_id": 1,
- "amount": 0,
- "amount_dwh": "1.14",
- "infocode_id": "string",
- "sub_infocode_id": "string",
- "information": "string",
- "input_type": 0,
- "withdrawal_from_stock": false
}
], - "receipt_text": "string",
- "discount_code": [
- "string"
], - "extra_info": [
- {
- "key": "string",
- "value": "string",
- "value_type": "string"
}
]
}, - "token": {
- "token_id": "string",
- "type": "sha1:email",
- "value": "a1b79ef1a62d94ffa86b3f3d846df0ee3993af92",
- "customer_id": "string"
}
}
{- "error": {
- "code": "string",
- "errors": [
- { }
], - "message": "string"
}
}
Create a new campaign to group discount rules
scopes:
aid required | string <^[PT]{1}\d{8}$> = 9 characters An id that uniquely identifies the account. |
Campaign to create
name required | string |
campaign_id | string <= 255 characters |
description | string |
private | boolean Default: false The campaign is private and will be excluded from public rules when filtered by campaign_id |
metadata | object <= 10 properties Additional metadata about the campaign |
{- "campaign_id": "string",
- "name": "string",
- "description": "string",
- "private": false,
- "metadata": {
- "sponsor": "Solo",
- "is_featured": true
}
}
{- "id": "497f6eca-6276-4993-bfeb-53cbbbba6f08",
- "created_at": "2019-08-24T14:15:22Z",
- "created_by": "1c92f7e1-2897-4d46-bdcc-c127a914fb4e",
- "updated_at": "2019-08-24T14:15:22Z",
- "deleted_by": "1c92f7e1-2897-4d46-bdcc-c127a914fb4e",
- "deleted_at": "2019-08-24T14:15:22Z",
- "campaign_id": "string",
- "name": "string",
- "description": "string",
- "private": false,
- "metadata": {
- "sponsor": "Solo",
- "is_featured": true
}
}
List campaigns
scopes:
aid required | string <^[PT]{1}\d{8}$> = 9 characters An id that uniquely identifies the account. |
limit | integer [ 1 .. 100 ] Default: 10 A limit on the number of objects to be returned. Limit can range between 1 and 100 items, and the default is 10 items. |
starting_after | string cursor for use in pagination. starting_after is an object ID
that defines your place in the list. For instance, if you make
a list request and receive 100 objects, end the result contains
|
state | string Default: "all" Enum: "all" "public" "private" "deleted" Indicate the state of the campaign to return |
[- {
- "id": "497f6eca-6276-4993-bfeb-53cbbbba6f08",
- "created_at": "2019-08-24T14:15:22Z",
- "created_by": "1c92f7e1-2897-4d46-bdcc-c127a914fb4e",
- "updated_at": "2019-08-24T14:15:22Z",
- "deleted_by": "1c92f7e1-2897-4d46-bdcc-c127a914fb4e",
- "deleted_at": "2019-08-24T14:15:22Z",
- "campaign_id": "string",
- "name": "string",
- "description": "string",
- "private": false,
- "metadata": {
- "sponsor": "Solo",
- "is_featured": true
}
}
]
Get more details about a campaign
scopes:
aid required | string <^[PT]{1}\d{8}$> = 9 characters An id that uniquely identifies the account. |
campaign_id required | string <= 255 characters |
{- "id": "497f6eca-6276-4993-bfeb-53cbbbba6f08",
- "created_at": "2019-08-24T14:15:22Z",
- "created_by": "1c92f7e1-2897-4d46-bdcc-c127a914fb4e",
- "updated_at": "2019-08-24T14:15:22Z",
- "deleted_by": "1c92f7e1-2897-4d46-bdcc-c127a914fb4e",
- "deleted_at": "2019-08-24T14:15:22Z",
- "campaign_id": "string",
- "name": "string",
- "description": "string",
- "private": false,
- "metadata": {
- "sponsor": "Solo",
- "is_featured": true
}
}
Update campaign details. Undeletes a deleted campaign.
scopes:
aid required | string <^[PT]{1}\d{8}$> = 9 characters An id that uniquely identifies the account. |
campaign_id required | string <= 255 characters |
Campaign properties to update
name | string |
description | string |
private | any The campaign is private and will be excluded from public rules when filtered by campaign_id |
{- "name": "string",
- "description": "string",
- "private": null
}
{- "id": "497f6eca-6276-4993-bfeb-53cbbbba6f08",
- "created_at": "2019-08-24T14:15:22Z",
- "created_by": "1c92f7e1-2897-4d46-bdcc-c127a914fb4e",
- "updated_at": "2019-08-24T14:15:22Z",
- "deleted_by": "1c92f7e1-2897-4d46-bdcc-c127a914fb4e",
- "deleted_at": "2019-08-24T14:15:22Z",
- "campaign_id": "string",
- "name": "string",
- "description": "string",
- "private": false,
- "metadata": {
- "sponsor": "Solo",
- "is_featured": true
}
}
Delete a campagn.
Deleting a campagn does not affect its discount rules. i.e. active campagn rules will continue to be active after deleting the campagn
scopes:
aid required | string <^[PT]{1}\d{8}$> = 9 characters An id that uniquely identifies the account. |
campaign_id required | string <= 255 characters |
{- "id": "497f6eca-6276-4993-bfeb-53cbbbba6f08",
- "created_at": "2019-08-24T14:15:22Z",
- "created_by": "1c92f7e1-2897-4d46-bdcc-c127a914fb4e",
- "updated_at": "2019-08-24T14:15:22Z",
- "deleted_by": "1c92f7e1-2897-4d46-bdcc-c127a914fb4e",
- "deleted_at": "2019-08-24T14:15:22Z",
- "campaign_id": "string",
- "name": "string",
- "description": "string",
- "private": false,
- "metadata": {
- "sponsor": "Solo",
- "is_featured": true
}
}
Create a discount automation to apply on events received.
A automation can be used to automate the task of giving discount to customers. The customer found in the event will receive the discount.
Welcome discount: give discount to new user
{
"requirement": {
"events": ["customer_add"],
"automation_from": "2018-05-07T08:54:31Z",
"automation_to": "2018-06-07T08:54:31Z"
},
"actions": [
{
"type": "discount",
"id": "cae3e485-0e15-4afa-bc66-472f843efb84"
}
]
}
Purchase discount: give discount on first purchase at store
{
"name": "purchase at store sc029",
"requirement": {
"events": ["receipt_add"],
"automation_from": "2018-05-07T08:54:31Z",
"automation_to": "2018-06-07T08:54:31Z",
"filters": {
"$.store.id": ["sc029"]
}
},
"actions": [
{
"type": "discount",
"id": "cae3e485-0e15-4afa-bc66-472f843efb84"
}
],
"limitation": {
"automation_repeat": 1
}
}
scopes:
aid required | string <^[PT]{1}\d{8}$> = 9 characters An id that uniquely identifies the account. |
Automation to create
required | object |
required | Array of objects (AutomationAction) = 1 items Actions to perform if the automation is triggered (given events, limitation and filter) |
name | string Optinal name for the automation rule |
description | string Optional description for the automation rule |
object |
{- "name": "Company Automation",
- "description": "Automation for non blocked companies with postal_code 0342 or 6901",
- "requirement": {
- "automation_from": "2019-08-24T14:15:22Z",
- "automation_to": "2019-08-24T14:15:22Z",
- "events": [
- "customer_add"
], - "filter": {
- "$.type": [
- "company"
], - "$.status": [
- {
- "anything-but": "blocked"
}
], - "$.addresses[*].postal_code": [
- "0342",
- "6901"
]
}
}, - "limitation": {
- "automation_repeat": 1
}, - "actions": [
- {
- "type": "string"
}
]
}
{- "id": "497f6eca-6276-4993-bfeb-53cbbbba6f08",
- "created_at": "2019-08-24T14:15:22Z",
- "created_by": "1c92f7e1-2897-4d46-bdcc-c127a914fb4e",
- "updated_at": "2019-08-24T14:15:22Z",
- "deleted_by": "1c92f7e1-2897-4d46-bdcc-c127a914fb4e",
- "deleted_at": "2019-08-24T14:15:22Z",
- "name": "Company Automation",
- "description": "Automation for non blocked companies with postal_code 0342 or 6901",
- "requirement": {
- "automation_from": "2019-08-24T14:15:22Z",
- "automation_to": "2019-08-24T14:15:22Z",
- "events": [
- "customer_add"
], - "filter": {
- "$.type": [
- "company"
], - "$.status": [
- {
- "anything-but": "blocked"
}
], - "$.addresses[*].postal_code": [
- "0342",
- "6901"
]
}
}, - "limitation": {
- "automation_repeat": 1
}, - "actions": [
- {
- "type": "string"
}
]
}
Get available automations for the account
scopes:
aid required | string <^[PT]{1}\d{8}$> = 9 characters An id that uniquely identifies the account. |
limit | integer [ 1 .. 100 ] Default: 10 A limit on the number of objects to be returned. Limit can range between 1 and 100 items, and the default is 10 items. |
starting_after | string cursor for use in pagination. starting_after is an object ID
that defines your place in the list. For instance, if you make
a list request and receive 100 objects, end the result contains
|
state | string Default: "all" Enum: "all" "available" "deleted" Indicate the state of the automation to return |
[- {
- "id": "497f6eca-6276-4993-bfeb-53cbbbba6f08",
- "created_at": "2019-08-24T14:15:22Z",
- "created_by": "1c92f7e1-2897-4d46-bdcc-c127a914fb4e",
- "updated_at": "2019-08-24T14:15:22Z",
- "deleted_by": "1c92f7e1-2897-4d46-bdcc-c127a914fb4e",
- "deleted_at": "2019-08-24T14:15:22Z",
- "name": "Company Automation",
- "description": "Automation for non blocked companies with postal_code 0342 or 6901",
- "requirement": {
- "automation_from": "2019-08-24T14:15:22Z",
- "automation_to": "2019-08-24T14:15:22Z",
- "events": [
- "customer_add"
], - "filter": {
- "$.type": [
- "company"
], - "$.status": [
- {
- "anything-but": "blocked"
}
], - "$.addresses[*].postal_code": [
- "0342",
- "6901"
]
}
}, - "limitation": {
- "automation_repeat": 1
}, - "actions": [
- {
- "type": "string"
}
]
}
]
Delete an automation rule.
scopes:
aid required | string <^[PT]{1}\d{8}$> = 9 characters An id that uniquely identifies the account. |
arid required | string <uuid> An UUID that uniquely identifies the automation |
{- "id": "497f6eca-6276-4993-bfeb-53cbbbba6f08",
- "created_at": "2019-08-24T14:15:22Z",
- "created_by": "1c92f7e1-2897-4d46-bdcc-c127a914fb4e",
- "updated_at": "2019-08-24T14:15:22Z",
- "deleted_by": "1c92f7e1-2897-4d46-bdcc-c127a914fb4e",
- "deleted_at": "2019-08-24T14:15:22Z",
- "name": "Company Automation",
- "description": "Automation for non blocked companies with postal_code 0342 or 6901",
- "requirement": {
- "automation_from": "2019-08-24T14:15:22Z",
- "automation_to": "2019-08-24T14:15:22Z",
- "events": [
- "customer_add"
], - "filter": {
- "$.type": [
- "company"
], - "$.status": [
- {
- "anything-but": "blocked"
}
], - "$.addresses[*].postal_code": [
- "0342",
- "6901"
]
}
}, - "limitation": {
- "automation_repeat": 1
}, - "actions": [
- {
- "type": "string"
}
]
}
Get details about an automations
scopes:
aid required | string <^[PT]{1}\d{8}$> = 9 characters An id that uniquely identifies the account. |
arid required | string <uuid> An UUID that uniquely identifies the automation |
{- "id": "497f6eca-6276-4993-bfeb-53cbbbba6f08",
- "created_at": "2019-08-24T14:15:22Z",
- "created_by": "1c92f7e1-2897-4d46-bdcc-c127a914fb4e",
- "updated_at": "2019-08-24T14:15:22Z",
- "deleted_by": "1c92f7e1-2897-4d46-bdcc-c127a914fb4e",
- "deleted_at": "2019-08-24T14:15:22Z",
- "name": "Company Automation",
- "description": "Automation for non blocked companies with postal_code 0342 or 6901",
- "requirement": {
- "automation_from": "2019-08-24T14:15:22Z",
- "automation_to": "2019-08-24T14:15:22Z",
- "events": [
- "customer_add"
], - "filter": {
- "$.type": [
- "company"
], - "$.status": [
- {
- "anything-but": "blocked"
}
], - "$.addresses[*].postal_code": [
- "0342",
- "6901"
]
}
}, - "limitation": {
- "automation_repeat": 1
}, - "actions": [
- {
- "type": "string"
}
]
}
Get catalogs from account based on query parameters
scopes:
aid required | string <^[PT]{1}\d{8}$> = 9 characters An id that uniquely identifies the account. |
limit | integer [ 1 .. 100 ] Default: 10 A limit on the number of objects to be returned. Limit can range between 1 and 100 items, and the default is 10 items. |
starting_after | string cursor for use in pagination. starting_after is an object ID
that defines your place in the list. For instance, if you make
a list request and receive 100 objects, end the result contains
|
{- "catalogs": [
- {
- "catalog_id": "S23",
- "catalog_name": "Sommer",
- "id": "497f6eca-6276-4993-bfeb-53cbbbba6f08",
- "created_at": "2019-08-24T14:15:22Z",
- "created_by": "1c92f7e1-2897-4d46-bdcc-c127a914fb4e",
- "updated_at": "2019-08-24T14:15:22Z",
- "deleted_by": "1c92f7e1-2897-4d46-bdcc-c127a914fb4e",
- "deleted_at": "2019-08-24T14:15:22Z"
}
], - "starting_after": "string"
}
Create a new product catalog
scopes:
aid required | string <^[PT]{1}\d{8}$> = 9 characters An id that uniquely identifies the account. |
catalogs
catalog_id | string <= 255 characters The id you have defined for the catalog. (must not have trailing or leading spaces). An auto-generated catalog_id will be created if no catalog_id is provided |
catalog_name | string The catalog's name that will be shown customers |
{- "catalog_name": "Sommer"
}
{- "id": "497f6eca-6276-4993-bfeb-53cbbbba6f08",
- "created_at": "2019-08-24T14:15:22Z",
- "created_by": "1c92f7e1-2897-4d46-bdcc-c127a914fb4e",
- "updated_at": "2019-08-24T14:15:22Z",
- "deleted_by": "1c92f7e1-2897-4d46-bdcc-c127a914fb4e",
- "deleted_at": "2019-08-24T14:15:22Z",
- "catalog_id": "S23",
- "catalog_name": "Sommer"
}
Update an existing catalog
scopes:
aid required | string <^[PT]{1}\d{8}$> = 9 characters An id that uniquely identifies the account. |
catalog_id required | string <= 255 characters An id that uniquely identifies the catalog. (must not have trailing or leading spaces) |
catalog
catalog_name | string The catalog's name that will be shown customers |
{- "catalog_name": "Sommer"
}
{- "id": "497f6eca-6276-4993-bfeb-53cbbbba6f08",
- "created_at": "2019-08-24T14:15:22Z",
- "created_by": "1c92f7e1-2897-4d46-bdcc-c127a914fb4e",
- "updated_at": "2019-08-24T14:15:22Z",
- "deleted_by": "1c92f7e1-2897-4d46-bdcc-c127a914fb4e",
- "deleted_at": "2019-08-24T14:15:22Z",
- "catalog_id": "S23",
- "catalog_name": "Sommer"
}
Delete catalog and all corresponding products
scopes:
aid required | string <^[PT]{1}\d{8}$> = 9 characters An id that uniquely identifies the account. |
catalog_id required | string <= 255 characters An id that uniquely identifies the catalog. (must not have trailing or leading spaces) |
{- "id": "497f6eca-6276-4993-bfeb-53cbbbba6f08",
- "created_at": "2019-08-24T14:15:22Z",
- "created_by": "1c92f7e1-2897-4d46-bdcc-c127a914fb4e",
- "updated_at": "2019-08-24T14:15:22Z",
- "deleted_by": "1c92f7e1-2897-4d46-bdcc-c127a914fb4e",
- "deleted_at": "2019-08-24T14:15:22Z",
- "catalog_id": "S23",
- "catalog_name": "Sommer"
}
Get products in a catalog based on query parameters
scopes:
aid required | string <^[PT]{1}\d{8}$> = 9 characters An id that uniquely identifies the account. |
catalog_id required | string <= 255 characters An id that uniquely identifies the catalog. (must not have trailing or leading spaces) |
product_id | string A string that uniquely identifies the product. (must not have trailing or leading spaces) |
product_name | string Lookup on product name |
limit | integer [ 1 .. 100 ] Default: 10 A limit on the number of objects to be returned. Limit can range between 1 and 100 items, and the default is 10 items. |
starting_after | string cursor for use in pagination. starting_after is an object ID
that defines your place in the list. For instance, if you make
a list request and receive 100 objects, end the result contains
|
{- "products": [
- {
- "id": "497f6eca-6276-4993-bfeb-53cbbbba6f08",
- "created_at": "2019-08-24T14:15:22Z",
- "created_by": "1c92f7e1-2897-4d46-bdcc-c127a914fb4e",
- "updated_at": "2019-08-24T14:15:22Z",
- "deleted_by": "1c92f7e1-2897-4d46-bdcc-c127a914fb4e",
- "deleted_at": "2019-08-24T14:15:22Z",
- "product_name": "Stablestol",
- "description": "Stablestol for utendørsbruk",
- "is_virtual_product": false,
- "unit_gross_price": 10900,
- "unit": "stk",
- "currency": "NOK",
- "starting_at": "2019-08-24T14:15:22Z",
- "stopping_at": "2019-08-24T14:15:22Z",
- "dimension": {
- "color": "string",
- "size": "string",
- "style": "string",
- "config": "string",
- "variant": "string"
}, - "images": [
- {
- "rel": "thumbnail_image",
- "caption": "Image of current discount"
},
], - "locations": [
- {
- "location_id": "SC_Oslo",
- "location_name": "SuperChain Oslo",
- "is_available_for_shipping": false,
- "is_available_for_pickup": true,
- "number_of_items_in_storage": 15
}, - {
- "location_id": "SC_web",
- "location_name": "SuperChain Webshop",
- "is_available_for_shipping": true,
- "is_available_for_pickup": false,
- "number_of_items_in_storage": 500
}
], - "product_id": "Stol22",
- "catalog_id": "S23",
- "catalog_name": "Sommer",
- "groups": [
- {
- "group_id": "B1",
- "group_name": "Møbel"
}
]
}
], - "starting_after": "string"
}
Create a new product
scopes:
aid required | string <^[PT]{1}\d{8}$> = 9 characters An id that uniquely identifies the account. |
catalog_id required | string <= 255 characters An id that uniquely identifies the catalog. (must not have trailing or leading spaces) |
product to create
product_name | string The products name which is shown to customers |
description | string |
is_virtual_product | boolean Default: false |
unit_gross_price | integer |
unit | string Unit type |
currency | string The three-character ISO-4217 currency. https://en.wikipedia.org/wiki/ISO_4217 |
starting_at | string <date-time> The product will not be visible until this time |
stopping_at | string <date-time> The product will not be visible after this time |
object (Dimension) Identify item attributes, such as size and color | |
Array of objects (Images) [ items <= 10 items ] Links to images of product | |
Array of objects (Location) All locations connected to the product | |
product_id | string The id to define the product. An auto-generated product_id will be created if no product_id is provided |
Array of objects Array containing relevant product groups and sub-groups to be upserted. New groups will be inserted, existing groups will be updated and deleted groups will be revived. |
{- "product_name": "Stablestol",
- "description": "Stablestol for utendørsbruk",
- "is_virtual_product": false,
- "unit_gross_price": 10900,
- "unit": "stk",
- "currency": "NOK",
- "starting_at": "2019-08-24T14:15:22Z",
- "stopping_at": "2019-08-24T14:15:22Z",
- "dimension": {
- "color": "string",
- "size": "string",
- "style": "string",
- "config": "string",
- "variant": "string"
}, - "images": [
- {
- "rel": "thumbnail_image",
- "caption": "Image of current discount"
},
], - "locations": [
- {
- "location_id": "SC_Oslo",
- "location_name": "SuperChain Oslo",
- "is_available_for_shipping": false,
- "is_available_for_pickup": true,
- "number_of_items_in_storage": 15
}, - {
- "location_id": "SC_web",
- "location_name": "SuperChain Webshop",
- "is_available_for_shipping": true,
- "is_available_for_pickup": false,
- "number_of_items_in_storage": 500
}
], - "product_id": "Stol22",
- "groups": [
- {
- "id": "B234",
- "name": "Stol"
}, - {
- "id": "B1",
- "name": "Møbel"
}
]
}
{- "id": "497f6eca-6276-4993-bfeb-53cbbbba6f08",
- "created_at": "2019-08-24T14:15:22Z",
- "created_by": "1c92f7e1-2897-4d46-bdcc-c127a914fb4e",
- "updated_at": "2019-08-24T14:15:22Z",
- "deleted_by": "1c92f7e1-2897-4d46-bdcc-c127a914fb4e",
- "deleted_at": "2019-08-24T14:15:22Z",
- "product_name": "Stablestol",
- "description": "Stablestol for utendørsbruk",
- "is_virtual_product": false,
- "unit_gross_price": 10900,
- "unit": "stk",
- "currency": "NOK",
- "starting_at": "2019-08-24T14:15:22Z",
- "stopping_at": "2019-08-24T14:15:22Z",
- "dimension": {
- "color": "string",
- "size": "string",
- "style": "string",
- "config": "string",
- "variant": "string"
}, - "images": [
- {
- "rel": "thumbnail_image",
- "caption": "Image of current discount"
},
], - "locations": [
- {
- "location_id": "SC_Oslo",
- "location_name": "SuperChain Oslo",
- "is_available_for_shipping": false,
- "is_available_for_pickup": true,
- "number_of_items_in_storage": 15
}, - {
- "location_id": "SC_web",
- "location_name": "SuperChain Webshop",
- "is_available_for_shipping": true,
- "is_available_for_pickup": false,
- "number_of_items_in_storage": 500
}
], - "product_id": "Stol22",
- "catalog_id": "S23",
- "catalog_name": "Sommer",
- "groups": [
- {
- "group_id": "B1",
- "group_name": "Møbel"
}
]
}
Update an existing product
scopes:
aid required | string <^[PT]{1}\d{8}$> = 9 characters An id that uniquely identifies the account. |
catalog_id required | string <= 255 characters An id that uniquely identifies the catalog. (must not have trailing or leading spaces) |
product_id required | string <= 255 characters A string that uniquely identifies the product. (must not have trailing or leading spaces) |
products
product_name | string The products name which is shown to customers |
description | string |
is_virtual_product | boolean Default: false |
unit_gross_price | integer |
unit | string Unit type |
currency | string The three-character ISO-4217 currency. https://en.wikipedia.org/wiki/ISO_4217 |
starting_at | string <date-time> The product will not be visible until this time |
stopping_at | string <date-time> The product will not be visible after this time |
object (Dimension) Identify item attributes, such as size and color | |
Array of objects (Images) [ items <= 10 items ] Links to images of product | |
Array of objects (Location) All locations connected to the product |
{- "product_name": "Stablestol",
- "description": "Stablestol for utendørsbruk",
- "is_virtual_product": false,
- "unit_gross_price": 10900,
- "unit": "stk",
- "currency": "NOK",
- "starting_at": "2019-08-24T14:15:22Z",
- "stopping_at": "2019-08-24T14:15:22Z",
- "dimension": {
- "color": "string",
- "size": "string",
- "style": "string",
- "config": "string",
- "variant": "string"
}, - "images": [
- {
- "rel": "thumbnail_image",
- "caption": "Image of current discount"
},
], - "locations": [
- {
- "location_id": "SC_Oslo",
- "location_name": "SuperChain Oslo",
- "is_available_for_shipping": false,
- "is_available_for_pickup": true,
- "number_of_items_in_storage": 15
}, - {
- "location_id": "SC_web",
- "location_name": "SuperChain Webshop",
- "is_available_for_shipping": true,
- "is_available_for_pickup": false,
- "number_of_items_in_storage": 500
}
]
}
{- "id": "497f6eca-6276-4993-bfeb-53cbbbba6f08",
- "created_at": "2019-08-24T14:15:22Z",
- "created_by": "1c92f7e1-2897-4d46-bdcc-c127a914fb4e",
- "updated_at": "2019-08-24T14:15:22Z",
- "deleted_by": "1c92f7e1-2897-4d46-bdcc-c127a914fb4e",
- "deleted_at": "2019-08-24T14:15:22Z",
- "product_name": "Stablestol",
- "description": "Stablestol for utendørsbruk",
- "is_virtual_product": false,
- "unit_gross_price": 10900,
- "unit": "stk",
- "currency": "NOK",
- "starting_at": "2019-08-24T14:15:22Z",
- "stopping_at": "2019-08-24T14:15:22Z",
- "dimension": {
- "color": "string",
- "size": "string",
- "style": "string",
- "config": "string",
- "variant": "string"
}, - "images": [
- {
- "rel": "thumbnail_image",
- "caption": "Image of current discount"
},
], - "locations": [
- {
- "location_id": "SC_Oslo",
- "location_name": "SuperChain Oslo",
- "is_available_for_shipping": false,
- "is_available_for_pickup": true,
- "number_of_items_in_storage": 15
}, - {
- "location_id": "SC_web",
- "location_name": "SuperChain Webshop",
- "is_available_for_shipping": true,
- "is_available_for_pickup": false,
- "number_of_items_in_storage": 500
}
], - "product_id": "Stol22",
- "catalog_id": "S23",
- "catalog_name": "Sommer"
}
Delete product in a given catalog
scopes:
aid required | string <^[PT]{1}\d{8}$> = 9 characters An id that uniquely identifies the account. |
catalog_id required | string <= 255 characters An id that uniquely identifies the catalog. (must not have trailing or leading spaces) |
product_id required | string <= 255 characters A string that uniquely identifies the product. (must not have trailing or leading spaces) |
{- "id": "497f6eca-6276-4993-bfeb-53cbbbba6f08",
- "created_at": "2019-08-24T14:15:22Z",
- "created_by": "1c92f7e1-2897-4d46-bdcc-c127a914fb4e",
- "updated_at": "2019-08-24T14:15:22Z",
- "deleted_by": "1c92f7e1-2897-4d46-bdcc-c127a914fb4e",
- "deleted_at": "2019-08-24T14:15:22Z",
- "product_name": "Stablestol",
- "description": "Stablestol for utendørsbruk",
- "is_virtual_product": false,
- "unit_gross_price": 10900,
- "unit": "stk",
- "currency": "NOK",
- "starting_at": "2019-08-24T14:15:22Z",
- "stopping_at": "2019-08-24T14:15:22Z",
- "dimension": {
- "color": "string",
- "size": "string",
- "style": "string",
- "config": "string",
- "variant": "string"
}, - "images": [
- {
- "rel": "thumbnail_image",
- "caption": "Image of current discount"
},
], - "locations": [
- {
- "location_id": "SC_Oslo",
- "location_name": "SuperChain Oslo",
- "is_available_for_shipping": false,
- "is_available_for_pickup": true,
- "number_of_items_in_storage": 15
}, - {
- "location_id": "SC_web",
- "location_name": "SuperChain Webshop",
- "is_available_for_shipping": true,
- "is_available_for_pickup": false,
- "number_of_items_in_storage": 500
}
], - "product_id": "Stol22",
- "catalog_id": "S23",
- "catalog_name": "Sommer"
}
Lists all taxgroups
aid required | string <^[PT]{1}\d{8}$> = 9 characters An id that uniquely identifies the account. |
limit | integer [ 1 .. 100 ] Default: 10 A limit on the number of objects to be returned. Limit can range between 1 and 100 items, and the default is 10 items. |
starting_after | string cursor for use in pagination. starting_after is an object ID
that defines your place in the list. For instance, if you make
a list request and receive 100 objects, end the result contains
|
{- "tax_groups": [
- {
- "id": "497f6eca-6276-4993-bfeb-53cbbbba6f08",
- "created_at": "2019-08-24T14:15:22Z",
- "created_by": "1c92f7e1-2897-4d46-bdcc-c127a914fb4e",
- "updated_at": "2019-08-24T14:15:22Z",
- "deleted_by": "1c92f7e1-2897-4d46-bdcc-c127a914fb4e",
- "deleted_at": "2019-08-24T14:15:22Z",
- "tax_id": "vmva1",
- "tax_group": "Vmva-høy",
- "description": "Taxgroup for food. Currently 12%",
- "amount": 10000,
- "percentage": 12,
- "tax_code": 3
}
], - "starting_after": "string"
}
Insert a new taxgroup
aid required | string <^[PT]{1}\d{8}$> = 9 characters An id that uniquely identifies the account. |
tax_group
tax_id | string <= 255 characters The id you have defined for the taxgroup (must not have training or leading spaces). An auto-generated tax_id will be created if not provided |
tax_group | string The taxgroup name which is usually shown |
description | string |
amount | number |
percentage | number |
tax_code | string |
{- "tax_group": "Vmva-høy",
- "description": "Taxgroup for food. Currently 12%",
- "amount": 10000,
- "percentage": 12,
- "tax_code": 3
}
{- "id": "497f6eca-6276-4993-bfeb-53cbbbba6f08",
- "created_at": "2019-08-24T14:15:22Z",
- "created_by": "1c92f7e1-2897-4d46-bdcc-c127a914fb4e",
- "updated_at": "2019-08-24T14:15:22Z",
- "deleted_by": "1c92f7e1-2897-4d46-bdcc-c127a914fb4e",
- "deleted_at": "2019-08-24T14:15:22Z",
- "tax_id": "vmva1",
- "tax_group": "Vmva-høy",
- "description": "Taxgroup for food. Currently 12%",
- "amount": 10000,
- "percentage": 12,
- "tax_code": 3
}
Update an existing taxgroup
aid required | string <^[PT]{1}\d{8}$> = 9 characters An id that uniquely identifies the account. |
tax_id required | string <= 255 characters A string that uniquely identifies the tax. (must not have trailing or leading spaces) |
tax_group
tax_group | string The taxgroup name which is usually shown |
description | string |
amount | number |
percentage | number |
tax_code | string |
{- "tax_group": "Vmva-høy",
- "description": "Taxgroup for food. Currently 12%",
- "amount": 10000,
- "percentage": 12,
- "tax_code": 3
}
{- "id": "497f6eca-6276-4993-bfeb-53cbbbba6f08",
- "created_at": "2019-08-24T14:15:22Z",
- "created_by": "1c92f7e1-2897-4d46-bdcc-c127a914fb4e",
- "updated_at": "2019-08-24T14:15:22Z",
- "deleted_by": "1c92f7e1-2897-4d46-bdcc-c127a914fb4e",
- "deleted_at": "2019-08-24T14:15:22Z",
- "tax_id": "vmva1",
- "tax_group": "Vmva-høy",
- "description": "Taxgroup for food. Currently 12%",
- "amount": 10000,
- "percentage": 12,
- "tax_code": 3
}
Delete an existing taxgroup
aid required | string <^[PT]{1}\d{8}$> = 9 characters An id that uniquely identifies the account. |
tax_id required | string <= 255 characters A string that uniquely identifies the tax. (must not have trailing or leading spaces) |
{- "id": "497f6eca-6276-4993-bfeb-53cbbbba6f08",
- "created_at": "2019-08-24T14:15:22Z",
- "created_by": "1c92f7e1-2897-4d46-bdcc-c127a914fb4e",
- "updated_at": "2019-08-24T14:15:22Z",
- "deleted_by": "1c92f7e1-2897-4d46-bdcc-c127a914fb4e",
- "deleted_at": "2019-08-24T14:15:22Z",
- "tax_id": "vmva1",
- "tax_group": "Vmva-høy",
- "description": "Taxgroup for food. Currently 12%",
- "amount": 10000,
- "percentage": 12,
- "tax_code": 3
}
Post receipts
scopes:
aid required | string <^[PT]{1}\d{8}$> = 9 characters An id that uniquely identifies the account. |
token_expire_days | integer >= 1 Generate tokens for the receipts created, the token can be used to retrieve the receipt from: Following values will be added to
|
receipt
required | object (Store) |
receipt_id required | string non-empty |
purchase_at required | string <date-time> The date and time for the receipt purchase |
Array of objects (DiscountRefs) List all discounts referenced in discount_lines | |
Array of objects (ReceiptItem) | |
object Details for the delivery | |
customer_id | string <= 255 characters The customer id identifying the customer. (must not have trailing or leading spaces) |
object The customer, owner of the receipt | |
gross_amount | integer Monetary amount in smallest unit for the currency before discounts |
gross_amount_dwh | string Monetary amount in smallest unit for the currency before discounts with decimal |
net_amount | integer Monetary amount in smallest unit for the currency after discounts |
net_amount_dwh | string Monetary value in smallest unit for the currency after discounts with decimal |
round_off_to_coin | integer |
currency | string The three-character ISO-4217 currency. https://en.wikipedia.org/wiki/ISO_4217 |
order_number | string |
transaction_date | string <date-time> |
amount_due | integer How much more need to be paid before the transaction is completed. Monetary amount in smallest unit for the currency |
amount_due_dwh | string Monetary value with decimal |
no_of_items | number How many items did the customer buy |
is_changed | boolean Discount applied to gross amount |
transaction_id | string |
total_discount | integer |
total_manual_discount_amount | integer Monetary amount in smallest unit for the currency |
total_manual_percentage_discount | integer |
operator_id | string POS user |
operator_name | string Name of the POS user |
salesperson_id | string ID of the POS user |
salesperson_name | string |
entry_status | string Enum: "None" "Voided" "Posted" "Concluded" "Cancelled" "OnHold" "Training" Status for the transaction |
comment | string |
Array of objects (TaxItem) Breakdown of the tax to different tax groups | |
Array of objects (PaymentItem) | |
Array of objects (InfoCodeItem) | |
receipt_text | string |
discount_code | Array of strings |
Array of objects (ExtraInfo) |
[- {
- "discounts": [
- {
- "campaign_id": "string",
- "active": true,
- "private": false,
- "name": "Spar 100,-",
- "receipt_text": "Mai Salg",
- "visible_from": "2019-08-24T14:15:22Z",
- "description": "Gjør et Stablestol kupp!",
- "limitation": {
- "discount_activation": [
- {
- "type": "deactivate_if_discount_active",
- "value": "string"
}
], - "discount_hours": {
- "timezone": "Europe/Oslo",
- "hours": [
- {
- "day": "mon",
- "start": "10:00",
- "end": "20:00"
}
]
}, - "discount_reward_usage": 1,
- "discount_combination": -1,
- "discount_eligible": "item_eligible_for_discount",
- "discount_repeat_usage": -1,
- "stamp_expire_days": 100,
- "blacklist": [
- {
- "id": "b714118",
- "group_id": "B1"
}
]
}, - "requirement": {
- "customer": {
- "addresses": [
- {
- "country": [
- "NO"
], - "postal_code": [
- "0349"
], - "postal_place": [
- "Oslo"
], - "custom_type": [
- "offsite"
], - "type": [
- "custom"
]
}
], - "company": {
- "bussiness_name": [
- "TKP tech AS"
], - "department": [
- "production",
- "research"
], - "industry": [
- "J62.0.1",
- "J62.0.2"
], - "number_of_employees": [
- "20"
], - "organization_number": [
- "123456789MVA"
],
}, - "date_of_birth": [
- "1990-09-20",
- "1990-05-10"
], - "favorite_store": [
- "sc029"
], - "first_name": [
- "John"
], - "gender": [
- "male"
], - "last_name": [
- "Doe"
], - "marketing_consent": {
- "email": {
- "consent": [
- "true"
]
}, - "sms": {
- "consent": [
- "true"
]
}
}, - "status": [
- "vip"
], - "term": {
- "id": [
- "string"
]
}, - "type": [
- "string"
], - "attributes": {
- "property1": [
- "string"
], - "property2": [
- "string"
]
}
}, - "item": {
- "quantity": 0,
- "mixes": [
- {
- "items": [
- {
- "id": "b714118"
}, - {
- "group_id": "g4"
}
], - "quantity": 0,
- "reward_eligible": true
}
], - "items": [
- {
- "id": "b714118",
- "group_id": "B1"
}
]
}, - "store_ids": [
- "sc029"
], - "gross_amount": 0,
- "currencies": [
- {
- "anything-but": [
- "NOK"
]
}
], - "stamp": 5,
- "discount_code": "TACO",
- "store": {
- "id": [
- "sc029"
], - "name": [
- "SC Oslo"
], - "business_name": [
- "SC Oslo AS"
], - "address": {
- "country": [
- "NO"
], - "postal_code": [
- "0349"
], - "postal_place": [
- "Oslo"
]
}, - "chain": [
- "SuperChain"
], - "email": [
- "contact@superchain.com"
], - "gln": [
- "5790001398644"
], - "organization_number": [
- "123456789MVA"
], - "phone_number": [
- "+4738260107"
], - "mcc": [
- 5814
], - "mcc_ranges": [
- {
- "start": 5814,
- "end": 5815
}
], - "bax": [
- "102603"
], - "terminal_id": [
- "T0292"
]
}, - "purchase_from": "2019-08-24T14:15:22Z",
- "purchase_to": "2019-08-24T14:15:22Z"
}, - "reward": {
- "type": "discount_amount",
- "value": 10000,
- "values": [
- {
- "items": [
- {
- "id": "b714118",
- "group_id": "B1"
}
], - "value": 0
}
], - "base": "net",
- "effect": "discount"
}, - "metadata": {
- "campaign_id": "V101",
- "is_featured": true,
- "dintero:private_text:kind": "Gold"
}, - "links": [
- {
- "rel": "thumbnail_discount_image"
}, - {
- "rel": "medium_discount_image"
}, - {
- "rel": "webshoop"
}, - {
- "rel": "newletter",
- "type": "application/pdf"
}
], - "refs": [
- {
- "id": "e3da6be5-d8e0-466c-af66-b7f69472ebb5",
- "stamp": 0,
- "amount": 10000,
- "bonus": 9050,
- "statistics": {
- "amount": 15050,
- "bonus": 11050,
- "debit_balance": 12350,
- "stamp": 11,
- "usage": 2
}, - "items": [
- {
- "line_id": 1,
- "amount": 3000
}, - {
- "line_id": 5,
- "amount": 7000
}
], - "usage": 1
}
]
}
], - "store": {
- "id": "sc029",
- "name": "SC Oslo",
- "business_name": "SC Oslo AS",
- "address": {
- "address_line": "Sommerkroveien 34",
- "address_line_2": "PB 123",
- "postal_code": "0349",
- "postal_place": "Oslo",
- "country": "NO"
}, - "chain": "SuperChain",
- "email": "contact@superchain.com",
- "gln": "5790001398644",
- "organization_number": "123456789MVA",
- "phone_number": "+4738260107",
- "mcc": "5814",
- "bax": "102603",
- "terminal_id": "T0292"
}, - "items": [
- {
- "id": "175938",
- "groups": [
- {
- "id": "B234",
- "name": "Stol"
}, - {
- "id": "B1",
- "name": "Møbel"
}
], - "quantity": 2,
- "unit": "stk",
- "description": "Stablestol for utendørsbruk",
- "description_alias": "Stablestol",
- "net_amount": 27840,
- "net_amount_dwh": "27840.10",
- "gross_amount": 39800,
- "gross_amount_dwh": "34800.12",
- "unit_gross_price": 10900,
- "tax_percent": 25,
- "line_id": 1,
- "barcode": "3123212343212",
- "cost_price": 2033,
- "voided": false,
- "scale_item": false,
- "eligible_for_discount": true,
- "included_in_total_discount": true,
- "price_has_been_keyedIn": false,
- "discount_has_been_keyedIn": false,
- "is_return_item": false,
- "is_linked_item": false,
- "is_virtual_product": false,
- "is_changed": true,
- "salesperson_id": "000111",
- "salesperson_name": "Jesper",
- "serial_id": "32424234231312312",
- "comment": "Kan være hva som helst",
- "infocode_lines": [
- {
- "line_id": 1,
- "amount": 0,
- "amount_dwh": "1.14",
- "infocode_id": "string",
- "sub_infocode_id": "string",
- "information": "string",
- "input_type": 0,
- "withdrawal_from_stock": false
}
], - "tax_lines": [
- {
- "amount": 5584,
- "amount_dwh": "5584.0440",
- "exempt": false,
- "included_in_price": true,
- "percentage": 25,
- "tax_basis": 27920,
- "tax_basis_dwh": "27920.22",
- "tax_code": "3",
- "tax_group": "Vmva-høy"
}
], - "dimension": {
- "color": "string",
- "size": "string",
- "style": "string",
- "config": "string",
- "variant": "string"
}, - "discount_lines": [
- {
- "amount": 4400,
- "percentage": 44,
- "discount_type": "customer",
- "discount_id": "766da0ef-9283-42bd-b012-0582344ec53c",
- "description": "string",
- "line_id": 1
}
], - "bonus_lines": [
- {
- "bonus": 3130,
- "percentage": 10,
- "discount_type": "customer",
- "discount_id": "766da0ef-9283-42bd-b012-0582344ec53c",
- "description": "string",
- "line_id": 1
}
], - "extra_info": [
- {
- "key": "string",
- "value": "string",
- "value_type": "string"
}
]
}
], - "receipt_id": "string",
- "delivery": {
- "first_name": "John",
- "last_name": "Doe",
- "email": "customer@example.com",
- "phone_number": "+4799999999",
- "address": {
- "address_line": "Sommerkroveien 34",
- "address_line_2": "PB 123",
- "postal_code": "0349",
- "postal_place": "Oslo",
- "country": "NO"
}
}, - "customer_id": "C13db4f63",
- "customer": {
- "gender": "male",
- "first_name": "John",
- "last_name": "Doe",
- "email": "customer@example.com",
- "metadata": {
- "dob_year": 1985
}, - "phone_number": "+4799999999",
- "addresses": [
- {
- "address_line": "Sommerkroveien 34",
- "address_line_2": "PB 123",
- "postal_code": "0349",
- "postal_place": "Oslo",
- "country": "NO",
- "type": "string",
- "custom_type": "string"
}
], - "pays_tax": false,
- "date_of_birth": "1990-09-20",
- "favorite_store": "string",
- "company": {
- "organization_number": "123456789MVA",
- "bussiness_name": "TKP tech AS",
- "department": "sales department",
- "industry": "computer industry",
- "website": "string",
- "number_of_employees": "string"
}, - "marketing_consent": {
- "sms": {
- "consent": true
}, - "email": {
- "consent": true
}
}, - "status": "string",
- "term": {
- "id": "string"
}, - "type": "customer",
- "token": {
- "token_id": "983558fe-05bd-495f-92b5-9075d085db32",
- "value": "5345346544ffea22",
- "type": "VIPPS"
}
}, - "gross_amount": 59800,
- "gross_amount_dwh": "59800.01",
- "net_amount": 47840,
- "net_amount_dwh": "47840.01",
- "round_off_to_coin": 100,
- "currency": "NOK",
- "purchase_at": "2019-08-24T14:15:22Z",
- "order_number": "order12345",
- "transaction_date": "2019-08-24T14:15:22Z",
- "amount_due": 2050,
- "amount_due_dwh": "2050.10",
- "no_of_items": 4,
- "is_changed": true,
- "transaction_id": "SC999-9991-1828",
- "total_discount": 0,
- "total_manual_discount_amount": 0,
- "total_manual_percentage_discount": 0,
- "operator_id": "000210",
- "operator_name": "Ole Anders",
- "salesperson_id": "000111",
- "salesperson_name": "Jesper",
- "entry_status": "None",
- "comment": "Kunden ønsker mer for info",
- "tax_lines": [
- {
- "amount": 5584,
- "amount_dwh": "5584.0440",
- "exempt": false,
- "included_in_price": true,
- "percentage": 25,
- "tax_basis": 27920,
- "tax_basis_dwh": "27920.22",
- "tax_code": "3",
- "tax_group": "Vmva-høy"
}
], - "payments": [
- {
- "line_id": 1,
- "amount": 0,
- "type_id": "string",
- "token_id": "983558fe-05bd-495f-92b5-9075d085db32",
- "token_type": "VIPPS",
- "description": "string",
- "voided": true,
- "card_info": {
- "balance_amount": 0,
- "card_amount": 0,
- "issuer_id": 0,
- "issuer_name": "Barcley",
- "session_id": "022",
- "terminal_id": "71015233",
- "card_number": "************00198-1",
- "card_type": "VISA",
- "receipt": "BAX: 111010-71015233\\n\\r\\11/11/2015 14:41\\n\\r\\345849\\n\\r\\ VISA CLASSIC\\n\\r\\************5671\\n\\r\\AID:A0000000031010\\n\\r\\ REF:011 006687000000\\n\\r\\RESP:00 GODKJENT\\n\\r\\RETUR AV VARER\\n\\r \\NOK= 50.00\\n\\r\\SIGNATUR................\\n\\r \\KORTHOLDERS KOPI\n"
}, - "reference_id": "B00668107235",
- "infocode_lines": [
- {
- "line_id": 1,
- "amount": 0,
- "amount_dwh": "1.14",
- "infocode_id": "string",
- "sub_infocode_id": "string",
- "information": "string",
- "input_type": 0,
- "withdrawal_from_stock": false
}
]
}
], - "infocode_items": [
- {
- "line_id": 1,
- "amount": 0,
- "amount_dwh": "1.14",
- "infocode_id": "string",
- "sub_infocode_id": "string",
- "information": "string",
- "input_type": 0,
- "withdrawal_from_stock": false
}
], - "receipt_text": "string",
- "discount_code": [
- "string"
], - "extra_info": [
- {
- "key": "string",
- "value": "string",
- "value_type": "string"
}
]
}
]
{- "receipts": [
- {
- "id": "497f6eca-6276-4993-bfeb-53cbbbba6f08",
- "created_at": "2019-08-24T14:15:22Z",
- "created_by": "1c92f7e1-2897-4d46-bdcc-c127a914fb4e",
- "updated_at": "2019-08-24T14:15:22Z",
- "deleted_by": "1c92f7e1-2897-4d46-bdcc-c127a914fb4e",
- "deleted_at": "2019-08-24T14:15:22Z"
}
], - "duplicates": 0
}
Update existing anonymous receipt.
scopes:
aid required | string <^[PT]{1}\d{8}$> = 9 characters An id that uniquely identifies the account. |
receipt_id required | string A string that uniquely identifies POS receipt |
changes
customer_id required | string <= 255 characters Add customer_id to existing receipt. The customer id identifying the customer. (must not have trailing or leading spaces) |
Array of objects (DiscountRefs) Add discount to existing receipt. |
{- "customer_id": "C13db4f63",
- "discounts": [
- {
- "campaign_id": "string",
- "active": true,
- "private": false,
- "name": "Spar 100,-",
- "receipt_text": "Mai Salg",
- "visible_from": "2019-08-24T14:15:22Z",
- "description": "Gjør et Stablestol kupp!",
- "limitation": {
- "discount_activation": [
- {
- "type": "deactivate_if_discount_active",
- "value": "string"
}
], - "discount_hours": {
- "timezone": "Europe/Oslo",
- "hours": [
- {
- "day": "mon",
- "start": "10:00",
- "end": "20:00"
}
]
}, - "discount_reward_usage": 1,
- "discount_combination": -1,
- "discount_eligible": "item_eligible_for_discount",
- "discount_repeat_usage": -1,
- "stamp_expire_days": 100,
- "blacklist": [
- {
- "id": "b714118",
- "group_id": "B1"
}
]
}, - "requirement": {
- "customer": {
- "addresses": [
- {
- "country": [
- "NO"
], - "postal_code": [
- "0349"
], - "postal_place": [
- "Oslo"
], - "custom_type": [
- "offsite"
], - "type": [
- "custom"
]
}
], - "company": {
- "bussiness_name": [
- "TKP tech AS"
], - "department": [
- "production",
- "research"
], - "industry": [
- "J62.0.1",
- "J62.0.2"
], - "number_of_employees": [
- "20"
], - "organization_number": [
- "123456789MVA"
],
}, - "date_of_birth": [
- "1990-09-20",
- "1990-05-10"
], - "favorite_store": [
- "sc029"
], - "first_name": [
- "John"
], - "gender": [
- "male"
], - "last_name": [
- "Doe"
], - "marketing_consent": {
- "email": {
- "consent": [
- "true"
]
}, - "sms": {
- "consent": [
- "true"
]
}
}, - "status": [
- "vip"
], - "term": {
- "id": [
- "string"
]
}, - "type": [
- "string"
], - "attributes": {
- "property1": [
- "string"
], - "property2": [
- "string"
]
}
}, - "item": {
- "quantity": 0,
- "mixes": [
- {
- "items": [
- {
- "id": "b714118"
}, - {
- "group_id": "g4"
}
], - "quantity": 0,
- "reward_eligible": true
}
], - "items": [
- {
- "id": "b714118",
- "group_id": "B1"
}
]
}, - "store_ids": [
- "sc029"
], - "gross_amount": 0,
- "currencies": [
- {
- "anything-but": [
- "NOK"
]
}
], - "stamp": 5,
- "discount_code": "TACO",
- "store": {
- "id": [
- "sc029"
], - "name": [
- "SC Oslo"
], - "business_name": [
- "SC Oslo AS"
], - "address": {
- "country": [
- "NO"
], - "postal_code": [
- "0349"
], - "postal_place": [
- "Oslo"
]
}, - "chain": [
- "SuperChain"
], - "email": [
- "contact@superchain.com"
], - "gln": [
- "5790001398644"
], - "organization_number": [
- "123456789MVA"
], - "phone_number": [
- "+4738260107"
], - "mcc": [
- 5814
], - "mcc_ranges": [
- {
- "start": 5814,
- "end": 5815
}
], - "bax": [
- "102603"
], - "terminal_id": [
- "T0292"
]
}, - "purchase_from": "2019-08-24T14:15:22Z",
- "purchase_to": "2019-08-24T14:15:22Z"
}, - "reward": {
- "type": "discount_amount",
- "value": 10000,
- "values": [
- {
- "items": [
- {
- "id": "b714118",
- "group_id": "B1"
}
], - "value": 0
}
], - "base": "net",
- "effect": "discount"
}, - "metadata": {
- "campaign_id": "V101",
- "is_featured": true,
- "dintero:private_text:kind": "Gold"
}, - "links": [
- {
- "rel": "thumbnail_discount_image"
}, - {
- "rel": "medium_discount_image"
}, - {
- "rel": "webshoop"
}, - {
- "rel": "newletter",
- "type": "application/pdf"
}
], - "refs": [
- {
- "id": "e3da6be5-d8e0-466c-af66-b7f69472ebb5",
- "stamp": 0,
- "amount": 10000,
- "bonus": 9050,
- "statistics": {
- "amount": 15050,
- "bonus": 11050,
- "debit_balance": 12350,
- "stamp": 11,
- "usage": 2
}, - "items": [
- {
- "line_id": 1,
- "amount": 3000
}, - {
- "line_id": 5,
- "amount": 7000
}
], - "usage": 1
}
]
}
]
}
{- "id": "497f6eca-6276-4993-bfeb-53cbbbba6f08",
- "created_at": "2019-08-24T14:15:22Z",
- "created_by": "1c92f7e1-2897-4d46-bdcc-c127a914fb4e",
- "updated_at": "2019-08-24T14:15:22Z",
- "deleted_by": "1c92f7e1-2897-4d46-bdcc-c127a914fb4e",
- "deleted_at": "2019-08-24T14:15:22Z",
- "discounts": [
- {
- "id": "497f6eca-6276-4993-bfeb-53cbbbba6f08",
- "created_at": "2019-08-24T14:15:22Z",
- "created_by": "1c92f7e1-2897-4d46-bdcc-c127a914fb4e",
- "updated_at": "2019-08-24T14:15:22Z",
- "deleted_by": "1c92f7e1-2897-4d46-bdcc-c127a914fb4e",
- "deleted_at": "2019-08-24T14:15:22Z",
- "campaign_id": "string",
- "active": true,
- "private": false,
- "updated_by": "3d1e4824-5474-48e7-a369-4f603fa4c5b8",
- "type": "item",
- "name": "Spar 100,-",
- "receipt_text": "Mai Salg",
- "visible_from": "2019-08-24T14:15:22Z",
- "description": "Gjør et Stablestol kupp!",
- "limitation": {
- "discount_activation": [
- {
- "type": "deactivate_if_discount_active",
- "value": "string"
}
], - "discount_hours": {
- "timezone": "Europe/Oslo",
- "hours": [
- {
- "day": "mon",
- "start": "10:00",
- "end": "20:00"
}
]
}, - "discount_reward_usage": 1,
- "discount_combination": -1,
- "discount_eligible": "item_eligible_for_discount",
- "discount_repeat_usage": -1,
- "stamp_expire_days": 100,
- "blacklist": [
- {
- "id": "b714118",
- "group_id": "B1"
}
]
}, - "requirement": {
- "customer": {
- "addresses": [
- {
- "country": [
- "NO"
], - "postal_code": [
- "0349"
], - "postal_place": [
- "Oslo"
], - "custom_type": [
- "offsite"
], - "type": [
- "custom"
]
}
], - "company": {
- "bussiness_name": [
- "TKP tech AS"
], - "department": [
- "production",
- "research"
], - "industry": [
- "J62.0.1",
- "J62.0.2"
], - "number_of_employees": [
- "20"
], - "organization_number": [
- "123456789MVA"
],
}, - "date_of_birth": [
- "1990-09-20",
- "1990-05-10"
], - "favorite_store": [
- "sc029"
], - "first_name": [
- "John"
], - "gender": [
- "male"
], - "last_name": [
- "Doe"
], - "marketing_consent": {
- "email": {
- "consent": [
- "true"
]
}, - "sms": {
- "consent": [
- "true"
]
}
}, - "status": [
- "vip"
], - "term": {
- "id": [
- "string"
]
}, - "type": [
- "string"
], - "attributes": {
- "property1": [
- "string"
], - "property2": [
- "string"
]
}
}, - "item": {
- "quantity": 0,
- "mixes": [
- {
- "items": [
- {
- "id": "b714118"
}, - {
- "group_id": "g4"
}
], - "quantity": 0,
- "reward_eligible": true
}
], - "items": [
- {
- "id": "b714118",
- "group_id": "B1"
}
]
}, - "store_ids": [
- "sc029"
], - "gross_amount": 0,
- "currencies": [
- {
- "anything-but": [
- "NOK"
]
}
], - "stamp": 5,
- "discount_code": "TACO",
- "store": {
- "id": [
- "sc029"
], - "name": [
- "SC Oslo"
], - "business_name": [
- "SC Oslo AS"
], - "address": {
- "country": [
- "NO"
], - "postal_code": [
- "0349"
], - "postal_place": [
- "Oslo"
]
}, - "chain": [
- "SuperChain"
], - "email": [
- "contact@superchain.com"
], - "gln": [
- "5790001398644"
], - "organization_number": [
- "123456789MVA"
], - "phone_number": [
- "+4738260107"
], - "mcc": [
- 5814
], - "mcc_ranges": [
- {
- "start": 5814,
- "end": 5815
}
], - "bax": [
- "102603"
], - "terminal_id": [
- "T0292"
]
}, - "purchase_from": "2019-08-24T14:15:22Z",
- "purchase_to": "2019-08-24T14:15:22Z"
}, - "reward": {
- "type": "discount_amount",
- "value": 10000,
- "values": [
- {
- "items": [
- {
- "id": "b714118",
- "group_id": "B1"
}
], - "value": 0
}
], - "base": "net",
- "effect": "discount"
}, - "metadata": {
- "campaign_id": "V101",
- "is_featured": true,
- "dintero:private_text:kind": "Gold"
}, - "links": [
- {
- "rel": "thumbnail_discount_image"
}, - {
- "rel": "medium_discount_image"
}, - {
- "rel": "webshoop"
}, - {
- "rel": "newletter",
- "type": "application/pdf"
}
], - "refs": [
- {
- "id": "e3da6be5-d8e0-466c-af66-b7f69472ebb5",
- "stamp": 0,
- "amount": 10000,
- "bonus": 9050,
- "statistics": {
- "amount": 15050,
- "bonus": 11050,
- "debit_balance": 12350,
- "stamp": 11,
- "usage": 2
}, - "items": [
- {
- "line_id": 1,
- "amount": 3000
}, - {
- "line_id": 5,
- "amount": 7000
}
], - "usage": 1
}
]
}
], - "store": {
- "id": "sc029",
- "name": "SC Oslo",
- "business_name": "SC Oslo AS",
- "address": {
- "address_line": "Sommerkroveien 34",
- "address_line_2": "PB 123",
- "postal_code": "0349",
- "postal_place": "Oslo",
- "country": "NO"
}, - "chain": "SuperChain",
- "email": "contact@superchain.com",
- "gln": "5790001398644",
- "organization_number": "123456789MVA",
- "phone_number": "+4738260107",
- "mcc": "5814",
- "bax": "102603",
- "terminal_id": "T0292"
}, - "items": [
- {
- "id": "175938",
- "groups": [
- {
- "id": "B234",
- "name": "Stol"
}, - {
- "id": "B1",
- "name": "Møbel"
}
], - "quantity": 2,
- "unit": "stk",
- "description": "Stablestol for utendørsbruk",
- "description_alias": "Stablestol",
- "net_amount": 27840,
- "net_amount_dwh": "27840.10",
- "gross_amount": 39800,
- "gross_amount_dwh": "34800.12",
- "unit_gross_price": 10900,
- "tax_percent": 25,
- "line_id": 1,
- "barcode": "3123212343212",
- "cost_price": 2033,
- "voided": false,
- "scale_item": false,
- "eligible_for_discount": true,
- "included_in_total_discount": true,
- "price_has_been_keyedIn": false,
- "discount_has_been_keyedIn": false,
- "is_return_item": false,
- "is_linked_item": false,
- "is_virtual_product": false,
- "is_changed": true,
- "salesperson_id": "000111",
- "salesperson_name": "Jesper",
- "serial_id": "32424234231312312",
- "comment": "Kan være hva som helst",
- "infocode_lines": [
- {
- "line_id": 1,
- "amount": 0,
- "amount_dwh": "1.14",
- "infocode_id": "string",
- "sub_infocode_id": "string",
- "information": "string",
- "input_type": 0,
- "withdrawal_from_stock": false
}
], - "tax_lines": [
- {
- "amount": 5584,
- "amount_dwh": "5584.0440",
- "exempt": false,
- "included_in_price": true,
- "percentage": 25,
- "tax_basis": 27920,
- "tax_basis_dwh": "27920.22",
- "tax_code": "3",
- "tax_group": "Vmva-høy"
}
], - "dimension": {
- "color": "string",
- "size": "string",
- "style": "string",
- "config": "string",
- "variant": "string"
}, - "discount_lines": [
- {
- "amount": 4400,
- "percentage": 44,
- "discount_type": "customer",
- "discount_id": "766da0ef-9283-42bd-b012-0582344ec53c",
- "description": "string",
- "line_id": 1
}
], - "bonus_lines": [
- {
- "bonus": 3130,
- "percentage": 10,
- "discount_type": "customer",
- "discount_id": "766da0ef-9283-42bd-b012-0582344ec53c",
- "description": "string",
- "line_id": 1
}
], - "extra_info": [
- {
- "key": "string",
- "value": "string",
- "value_type": "string"
}
]
}
], - "receipt_id": "714118",
- "delivery": {
- "first_name": "John",
- "last_name": "Doe",
- "email": "customer@example.com",
- "phone_number": "+4799999999",
- "address": {
- "address_line": "Sommerkroveien 34",
- "address_line_2": "PB 123",
- "postal_code": "0349",
- "postal_place": "Oslo",
- "country": "NO"
}
}, - "customer_id": "C13db4f63",
- "customer": {
- "gender": "male",
- "first_name": "John",
- "last_name": "Doe",
- "email": "customer@example.com",
- "metadata": {
- "dob_year": 1985
}, - "phone_number": "+4799999999",
- "addresses": [
- {
- "address_line": "Sommerkroveien 34",
- "address_line_2": "PB 123",
- "postal_code": "0349",
- "postal_place": "Oslo",
- "country": "NO",
- "type": "string",
- "custom_type": "string"
}
], - "pays_tax": false,
- "date_of_birth": "1990-09-20",
- "favorite_store": "string",
- "company": {
- "organization_number": "123456789MVA",
- "bussiness_name": "TKP tech AS",
- "department": "sales department",
- "industry": "computer industry",
- "website": "string",
- "number_of_employees": "string"
}, - "marketing_consent": {
- "sms": {
- "consent": true,
- "updated_at": "2018-01-12T13:42:00Z"
}, - "email": {
- "consent": true,
- "updated_at": "2018-01-12T13:42:00Z"
}
}, - "status": "string",
- "term": {
- "id": "string"
}, - "type": "customer",
- "token": {
- "token_id": "983558fe-05bd-495f-92b5-9075d085db32",
- "value": "5345346544ffea22",
- "type": "VIPPS"
}
}, - "gross_amount": 59800,
- "gross_amount_dwh": "59800.01",
- "net_amount": 47840,
- "net_amount_dwh": "47840.01",
- "round_off_to_coin": 100,
- "currency": "NOK",
- "purchase_at": "2019-08-24T14:15:22Z",
- "order_number": "order12345",
- "transaction_date": "2019-08-24T14:15:22Z",
- "amount_due": 2050,
- "amount_due_dwh": "2050.10",
- "no_of_items": 4,
- "is_changed": true,
- "transaction_id": "SC999-9991-1828",
- "total_discount": 0,
- "total_manual_discount_amount": 0,
- "total_manual_percentage_discount": 0,
- "operator_id": "000210",
- "operator_name": "Ole Anders",
- "salesperson_id": "000111",
- "salesperson_name": "Jesper",
- "entry_status": "None",
- "comment": "Kunden ønsker mer for info",
- "tax_lines": [
- {
- "amount": 5584,
- "amount_dwh": "5584.0440",
- "exempt": false,
- "included_in_price": true,
- "percentage": 25,
- "tax_basis": 27920,
- "tax_basis_dwh": "27920.22",
- "tax_code": "3",
- "tax_group": "Vmva-høy"
}
], - "payments": [
- {
- "line_id": 1,
- "amount": 0,
- "type_id": "string",
- "token_id": "983558fe-05bd-495f-92b5-9075d085db32",
- "token_type": "VIPPS",
- "description": "string",
- "voided": true,
- "card_info": {
- "balance_amount": 0,
- "card_amount": 0,
- "issuer_id": 0,
- "issuer_name": "Barcley",
- "session_id": "022",
- "terminal_id": "71015233",
- "card_number": "************00198-1",
- "card_type": "VISA",
- "receipt": "BAX: 111010-71015233\\n\\r\\11/11/2015 14:41\\n\\r\\345849\\n\\r\\ VISA CLASSIC\\n\\r\\************5671\\n\\r\\AID:A0000000031010\\n\\r\\ REF:011 006687000000\\n\\r\\RESP:00 GODKJENT\\n\\r\\RETUR AV VARER\\n\\r \\NOK= 50.00\\n\\r\\SIGNATUR................\\n\\r \\KORTHOLDERS KOPI\n"
}, - "reference_id": "B00668107235",
- "infocode_lines": [
- {
- "line_id": 1,
- "amount": 0,
- "amount_dwh": "1.14",
- "infocode_id": "string",
- "sub_infocode_id": "string",
- "information": "string",
- "input_type": 0,
- "withdrawal_from_stock": false
}
]
}
], - "infocode_items": [
- {
- "line_id": 1,
- "amount": 0,
- "amount_dwh": "1.14",
- "infocode_id": "string",
- "sub_infocode_id": "string",
- "information": "string",
- "input_type": 0,
- "withdrawal_from_stock": false
}
], - "receipt_text": "string",
- "discount_code": [
- "string"
], - "extra_info": [
- {
- "key": "string",
- "value": "string",
- "value_type": "string"
}
]
}
Update customer_id
on receipt identified by token. The token will be
invalid after the claim.
scopes:
aid required | string <^[PT]{1}\d{8}$> = 9 characters An id that uniquely identifies the account. |
token required | string JWT token for receipt |
new customer id
customer_id required | string |
{- "customer_id": "string"
}
{- "id": "497f6eca-6276-4993-bfeb-53cbbbba6f08",
- "created_at": "2019-08-24T14:15:22Z",
- "created_by": "1c92f7e1-2897-4d46-bdcc-c127a914fb4e",
- "updated_at": "2019-08-24T14:15:22Z",
- "deleted_by": "1c92f7e1-2897-4d46-bdcc-c127a914fb4e",
- "deleted_at": "2019-08-24T14:15:22Z",
- "discounts": [
- {
- "id": "497f6eca-6276-4993-bfeb-53cbbbba6f08",
- "created_at": "2019-08-24T14:15:22Z",
- "created_by": "1c92f7e1-2897-4d46-bdcc-c127a914fb4e",
- "updated_at": "2019-08-24T14:15:22Z",
- "deleted_by": "1c92f7e1-2897-4d46-bdcc-c127a914fb4e",
- "deleted_at": "2019-08-24T14:15:22Z",
- "campaign_id": "string",
- "active": true,
- "private": false,
- "updated_by": "3d1e4824-5474-48e7-a369-4f603fa4c5b8",
- "type": "item",
- "name": "Spar 100,-",
- "receipt_text": "Mai Salg",
- "visible_from": "2019-08-24T14:15:22Z",
- "description": "Gjør et Stablestol kupp!",
- "limitation": {
- "discount_activation": [
- {
- "type": "deactivate_if_discount_active",
- "value": "string"
}
], - "discount_hours": {
- "timezone": "Europe/Oslo",
- "hours": [
- {
- "day": "mon",
- "start": "10:00",
- "end": "20:00"
}
]
}, - "discount_reward_usage": 1,
- "discount_combination": -1,
- "discount_eligible": "item_eligible_for_discount",
- "discount_repeat_usage": -1,
- "stamp_expire_days": 100,
- "blacklist": [
- {
- "id": "b714118",
- "group_id": "B1"
}
]
}, - "requirement": {
- "customer": {
- "addresses": [
- {
- "country": [
- "NO"
], - "postal_code": [
- "0349"
], - "postal_place": [
- "Oslo"
], - "custom_type": [
- "offsite"
], - "type": [
- "custom"
]
}
], - "company": {
- "bussiness_name": [
- "TKP tech AS"
], - "department": [
- "production",
- "research"
], - "industry": [
- "J62.0.1",
- "J62.0.2"
], - "number_of_employees": [
- "20"
], - "organization_number": [
- "123456789MVA"
],
}, - "date_of_birth": [
- "1990-09-20",
- "1990-05-10"
], - "favorite_store": [
- "sc029"
], - "first_name": [
- "John"
], - "gender": [
- "male"
], - "last_name": [
- "Doe"
], - "marketing_consent": {
- "email": {
- "consent": [
- "true"
]
}, - "sms": {
- "consent": [
- "true"
]
}
}, - "status": [
- "vip"
], - "term": {
- "id": [
- "string"
]
}, - "type": [
- "string"
], - "attributes": {
- "property1": [
- "string"
], - "property2": [
- "string"
]
}
}, - "item": {
- "quantity": 0,
- "mixes": [
- {
- "items": [
- {
- "id": "b714118"
}, - {
- "group_id": "g4"
}
], - "quantity": 0,
- "reward_eligible": true
}
], - "items": [
- {
- "id": "b714118",
- "group_id": "B1"
}
]
}, - "store_ids": [
- "sc029"
], - "gross_amount": 0,
- "currencies": [
- {
- "anything-but": [
- "NOK"
]
}
], - "stamp": 5,
- "discount_code": "TACO",
- "store": {
- "id": [
- "sc029"
], - "name": [
- "SC Oslo"
], - "business_name": [
- "SC Oslo AS"
], - "address": {
- "country": [
- "NO"
], - "postal_code": [
- "0349"
], - "postal_place": [
- "Oslo"
]
}, - "chain": [
- "SuperChain"
], - "email": [
- "contact@superchain.com"
], - "gln": [
- "5790001398644"
], - "organization_number": [
- "123456789MVA"
], - "phone_number": [
- "+4738260107"
], - "mcc": [
- 5814
], - "mcc_ranges": [
- {
- "start": 5814,
- "end": 5815
}
], - "bax": [
- "102603"
], - "terminal_id": [
- "T0292"
]
}, - "purchase_from": "2019-08-24T14:15:22Z",
- "purchase_to": "2019-08-24T14:15:22Z"
}, - "reward": {
- "type": "discount_amount",
- "value": 10000,
- "values": [
- {
- "items": [
- {
- "id": "b714118",
- "group_id": "B1"
}
], - "value": 0
}
], - "base": "net",
- "effect": "discount"
}, - "metadata": {
- "campaign_id": "V101",
- "is_featured": true,
- "dintero:private_text:kind": "Gold"
}, - "links": [
- {
- "rel": "thumbnail_discount_image"
}, - {
- "rel": "medium_discount_image"
}, - {
- "rel": "webshoop"
}, - {
- "rel": "newletter",
- "type": "application/pdf"
}
], - "refs": [
- {
- "id": "e3da6be5-d8e0-466c-af66-b7f69472ebb5",
- "stamp": 0,
- "amount": 10000,
- "bonus": 9050,
- "statistics": {
- "amount": 15050,
- "bonus": 11050,
- "debit_balance": 12350,
- "stamp": 11,
- "usage": 2
}, - "items": [
- {
- "line_id": 1,
- "amount": 3000
}, - {
- "line_id": 5,
- "amount": 7000
}
], - "usage": 1
}
]
}
], - "store": {
- "id": "sc029",
- "name": "SC Oslo",
- "business_name": "SC Oslo AS",
- "address": {
- "address_line": "Sommerkroveien 34",
- "address_line_2": "PB 123",
- "postal_code": "0349",
- "postal_place": "Oslo",
- "country": "NO"
}, - "chain": "SuperChain",
- "email": "contact@superchain.com",
- "gln": "5790001398644",
- "organization_number": "123456789MVA",
- "phone_number": "+4738260107",
- "mcc": "5814",
- "bax": "102603",
- "terminal_id": "T0292"
}, - "items": [
- {
- "id": "175938",
- "groups": [
- {
- "id": "B234",
- "name": "Stol"
}, - {
- "id": "B1",
- "name": "Møbel"
}
], - "quantity": 2,
- "unit": "stk",
- "description": "Stablestol for utendørsbruk",
- "description_alias": "Stablestol",
- "net_amount": 27840,
- "net_amount_dwh": "27840.10",
- "gross_amount": 39800,
- "gross_amount_dwh": "34800.12",
- "unit_gross_price": 10900,
- "tax_percent": 25,
- "line_id": 1,
- "barcode": "3123212343212",
- "cost_price": 2033,
- "voided": false,
- "scale_item": false,
- "eligible_for_discount": true,
- "included_in_total_discount": true,
- "price_has_been_keyedIn": false,
- "discount_has_been_keyedIn": false,
- "is_return_item": false,
- "is_linked_item": false,
- "is_virtual_product": false,
- "is_changed": true,
- "salesperson_id": "000111",
- "salesperson_name": "Jesper",
- "serial_id": "32424234231312312",
- "comment": "Kan være hva som helst",
- "infocode_lines": [
- {
- "line_id": 1,
- "amount": 0,
- "amount_dwh": "1.14",
- "infocode_id": "string",
- "sub_infocode_id": "string",
- "information": "string",
- "input_type": 0,
- "withdrawal_from_stock": false
}
], - "tax_lines": [
- {
- "amount": 5584,
- "amount_dwh": "5584.0440",
- "exempt": false,
- "included_in_price": true,
- "percentage": 25,
- "tax_basis": 27920,
- "tax_basis_dwh": "27920.22",
- "tax_code": "3",
- "tax_group": "Vmva-høy"
}
], - "dimension": {
- "color": "string",
- "size": "string",
- "style": "string",
- "config": "string",
- "variant": "string"
}, - "discount_lines": [
- {
- "amount": 4400,
- "percentage": 44,
- "discount_type": "customer",
- "discount_id": "766da0ef-9283-42bd-b012-0582344ec53c",
- "description": "string",
- "line_id": 1
}
], - "bonus_lines": [
- {
- "bonus": 3130,
- "percentage": 10,
- "discount_type": "customer",
- "discount_id": "766da0ef-9283-42bd-b012-0582344ec53c",
- "description": "string",
- "line_id": 1
}
], - "extra_info": [
- {
- "key": "string",
- "value": "string",
- "value_type": "string"
}
]
}
], - "receipt_id": "714118",
- "delivery": {
- "first_name": "John",
- "last_name": "Doe",
- "email": "customer@example.com",
- "phone_number": "+4799999999",
- "address": {
- "address_line": "Sommerkroveien 34",
- "address_line_2": "PB 123",
- "postal_code": "0349",
- "postal_place": "Oslo",
- "country": "NO"
}
}, - "customer_id": "C13db4f63",
- "customer": {
- "gender": "male",
- "first_name": "John",
- "last_name": "Doe",
- "email": "customer@example.com",
- "metadata": {
- "dob_year": 1985
}, - "phone_number": "+4799999999",
- "addresses": [
- {
- "address_line": "Sommerkroveien 34",
- "address_line_2": "PB 123",
- "postal_code": "0349",
- "postal_place": "Oslo",
- "country": "NO",
- "type": "string",
- "custom_type": "string"
}
], - "pays_tax": false,
- "date_of_birth": "1990-09-20",
- "favorite_store": "string",
- "company": {
- "organization_number": "123456789MVA",
- "bussiness_name": "TKP tech AS",
- "department": "sales department",
- "industry": "computer industry",
- "website": "string",
- "number_of_employees": "string"
}, - "marketing_consent": {
- "sms": {
- "consent": true,
- "updated_at": "2018-01-12T13:42:00Z"
}, - "email": {
- "consent": true,
- "updated_at": "2018-01-12T13:42:00Z"
}
}, - "status": "string",
- "term": {
- "id": "string"
}, - "type": "customer",
- "token": {
- "token_id": "983558fe-05bd-495f-92b5-9075d085db32",
- "value": "5345346544ffea22",
- "type": "VIPPS"
}
}, - "gross_amount": 59800,
- "gross_amount_dwh": "59800.01",
- "net_amount": 47840,
- "net_amount_dwh": "47840.01",
- "round_off_to_coin": 100,
- "currency": "NOK",
- "purchase_at": "2019-08-24T14:15:22Z",
- "order_number": "order12345",
- "transaction_date": "2019-08-24T14:15:22Z",
- "amount_due": 2050,
- "amount_due_dwh": "2050.10",
- "no_of_items": 4,
- "is_changed": true,
- "transaction_id": "SC999-9991-1828",
- "total_discount": 0,
- "total_manual_discount_amount": 0,
- "total_manual_percentage_discount": 0,
- "operator_id": "000210",
- "operator_name": "Ole Anders",
- "salesperson_id": "000111",
- "salesperson_name": "Jesper",
- "entry_status": "None",
- "comment": "Kunden ønsker mer for info",
- "tax_lines": [
- {
- "amount": 5584,
- "amount_dwh": "5584.0440",
- "exempt": false,
- "included_in_price": true,
- "percentage": 25,
- "tax_basis": 27920,
- "tax_basis_dwh": "27920.22",
- "tax_code": "3",
- "tax_group": "Vmva-høy"
}
], - "payments": [
- {
- "line_id": 1,
- "amount": 0,
- "type_id": "string",
- "token_id": "983558fe-05bd-495f-92b5-9075d085db32",
- "token_type": "VIPPS",
- "description": "string",
- "voided": true,
- "card_info": {
- "balance_amount": 0,
- "card_amount": 0,
- "issuer_id": 0,
- "issuer_name": "Barcley",
- "session_id": "022",
- "terminal_id": "71015233",
- "card_number": "************00198-1",
- "card_type": "VISA",
- "receipt": "BAX: 111010-71015233\\n\\r\\11/11/2015 14:41\\n\\r\\345849\\n\\r\\ VISA CLASSIC\\n\\r\\************5671\\n\\r\\AID:A0000000031010\\n\\r\\ REF:011 006687000000\\n\\r\\RESP:00 GODKJENT\\n\\r\\RETUR AV VARER\\n\\r \\NOK= 50.00\\n\\r\\SIGNATUR................\\n\\r \\KORTHOLDERS KOPI\n"
}, - "reference_id": "B00668107235",
- "infocode_lines": [
- {
- "line_id": 1,
- "amount": 0,
- "amount_dwh": "1.14",
- "infocode_id": "string",
- "sub_infocode_id": "string",
- "information": "string",
- "input_type": 0,
- "withdrawal_from_stock": false
}
]
}
], - "infocode_items": [
- {
- "line_id": 1,
- "amount": 0,
- "amount_dwh": "1.14",
- "infocode_id": "string",
- "sub_infocode_id": "string",
- "information": "string",
- "input_type": 0,
- "withdrawal_from_stock": false
}
], - "receipt_text": "string",
- "discount_code": [
- "string"
], - "extra_info": [
- {
- "key": "string",
- "value": "string",
- "value_type": "string"
}
]
}
Get receipt from token. The token must be a signed JWT token
containing the customer_id
and receipt_id
to fetch.
scopes:
aid required | string <^[PT]{1}\d{8}$> = 9 characters An id that uniquely identifies the account. |
token required | string JWT token for receipt |
{- "id": "497f6eca-6276-4993-bfeb-53cbbbba6f08",
- "created_at": "2019-08-24T14:15:22Z",
- "created_by": "1c92f7e1-2897-4d46-bdcc-c127a914fb4e",
- "updated_at": "2019-08-24T14:15:22Z",
- "deleted_by": "1c92f7e1-2897-4d46-bdcc-c127a914fb4e",
- "deleted_at": "2019-08-24T14:15:22Z",
- "discounts": [
- {
- "id": "497f6eca-6276-4993-bfeb-53cbbbba6f08",
- "created_at": "2019-08-24T14:15:22Z",
- "created_by": "1c92f7e1-2897-4d46-bdcc-c127a914fb4e",
- "updated_at": "2019-08-24T14:15:22Z",
- "deleted_by": "1c92f7e1-2897-4d46-bdcc-c127a914fb4e",
- "deleted_at": "2019-08-24T14:15:22Z",
- "campaign_id": "string",
- "active": true,
- "private": false,
- "updated_by": "3d1e4824-5474-48e7-a369-4f603fa4c5b8",
- "type": "item",
- "name": "Spar 100,-",
- "receipt_text": "Mai Salg",
- "visible_from": "2019-08-24T14:15:22Z",
- "description": "Gjør et Stablestol kupp!",
- "limitation": {
- "discount_activation": [
- {
- "type": "deactivate_if_discount_active",
- "value": "string"
}
], - "discount_hours": {
- "timezone": "Europe/Oslo",
- "hours": [
- {
- "day": "mon",
- "start": "10:00",
- "end": "20:00"
}
]
}, - "discount_reward_usage": 1,
- "discount_combination": -1,
- "discount_eligible": "item_eligible_for_discount",
- "discount_repeat_usage": -1,
- "stamp_expire_days": 100,
- "blacklist": [
- {
- "id": "b714118",
- "group_id": "B1"
}
]
}, - "requirement": {
- "customer": {
- "addresses": [
- {
- "country": [
- "NO"
], - "postal_code": [
- "0349"
], - "postal_place": [
- "Oslo"
], - "custom_type": [
- "offsite"
], - "type": [
- "custom"
]
}
], - "company": {
- "bussiness_name": [
- "TKP tech AS"
], - "department": [
- "production",
- "research"
], - "industry": [
- "J62.0.1",
- "J62.0.2"
], - "number_of_employees": [
- "20"
], - "organization_number": [
- "123456789MVA"
],
}, - "date_of_birth": [
- "1990-09-20",
- "1990-05-10"
], - "favorite_store": [
- "sc029"
], - "first_name": [
- "John"
], - "gender": [
- "male"
], - "last_name": [
- "Doe"
], - "marketing_consent": {
- "email": {
- "consent": [
- "true"
]
}, - "sms": {
- "consent": [
- "true"
]
}
}, - "status": [
- "vip"
], - "term": {
- "id": [
- "string"
]
}, - "type": [
- "string"
], - "attributes": {
- "property1": [
- "string"
], - "property2": [
- "string"
]
}
}, - "item": {
- "quantity": 0,
- "mixes": [
- {
- "items": [
- {
- "id": "b714118"
}, - {
- "group_id": "g4"
}
], - "quantity": 0,
- "reward_eligible": true
}
], - "items": [
- {
- "id": "b714118",
- "group_id": "B1"
}
]
}, - "store_ids": [
- "sc029"
], - "gross_amount": 0,
- "currencies": [
- {
- "anything-but": [
- "NOK"
]
}
], - "stamp": 5,
- "discount_code": "TACO",
- "store": {
- "id": [
- "sc029"
], - "name": [
- "SC Oslo"
], - "business_name": [
- "SC Oslo AS"
], - "address": {
- "country": [
- "NO"
], - "postal_code": [
- "0349"
], - "postal_place": [
- "Oslo"
]
}, - "chain": [
- "SuperChain"
], - "email": [
- "contact@superchain.com"
], - "gln": [
- "5790001398644"
], - "organization_number": [
- "123456789MVA"
], - "phone_number": [
- "+4738260107"
], - "mcc": [
- 5814
], - "mcc_ranges": [
- {
- "start": 5814,
- "end": 5815
}
], - "bax": [
- "102603"
], - "terminal_id": [
- "T0292"
]
}, - "purchase_from": "2019-08-24T14:15:22Z",
- "purchase_to": "2019-08-24T14:15:22Z"
}, - "reward": {
- "type": "discount_amount",
- "value": 10000,
- "values": [
- {
- "items": [
- {
- "id": "b714118",
- "group_id": "B1"
}
], - "value": 0
}
], - "base": "net",
- "effect": "discount"
}, - "metadata": {
- "campaign_id": "V101",
- "is_featured": true,
- "dintero:private_text:kind": "Gold"
}, - "links": [
- {
- "rel": "thumbnail_discount_image"
}, - {
- "rel": "medium_discount_image"
}, - {
- "rel": "webshoop"
}, - {
- "rel": "newletter",
- "type": "application/pdf"
}
], - "refs": [
- {
- "id": "e3da6be5-d8e0-466c-af66-b7f69472ebb5",
- "stamp": 0,
- "amount": 10000,
- "bonus": 9050,
- "statistics": {
- "amount": 15050,
- "bonus": 11050,
- "debit_balance": 12350,
- "stamp": 11,
- "usage": 2
}, - "items": [
- {
- "line_id": 1,
- "amount": 3000
}, - {
- "line_id": 5,
- "amount": 7000
}
], - "usage": 1
}
]
}
], - "store": {
- "id": "sc029",
- "name": "SC Oslo",
- "business_name": "SC Oslo AS",
- "address": {
- "address_line": "Sommerkroveien 34",
- "address_line_2": "PB 123",
- "postal_code": "0349",
- "postal_place": "Oslo",
- "country": "NO"
}, - "chain": "SuperChain",
- "email": "contact@superchain.com",
- "gln": "5790001398644",
- "organization_number": "123456789MVA",
- "phone_number": "+4738260107",
- "mcc": "5814",
- "bax": "102603",
- "terminal_id": "T0292"
}, - "items": [
- {
- "id": "175938",
- "groups": [
- {
- "id": "B234",
- "name": "Stol"
}, - {
- "id": "B1",
- "name": "Møbel"
}
], - "quantity": 2,
- "unit": "stk",
- "description": "Stablestol for utendørsbruk",
- "description_alias": "Stablestol",
- "net_amount": 27840,
- "net_amount_dwh": "27840.10",
- "gross_amount": 39800,
- "gross_amount_dwh": "34800.12",
- "unit_gross_price": 10900,
- "tax_percent": 25,
- "line_id": 1,
- "barcode": "3123212343212",
- "cost_price": 2033,
- "voided": false,
- "scale_item": false,
- "eligible_for_discount": true,
- "included_in_total_discount": true,
- "price_has_been_keyedIn": false,
- "discount_has_been_keyedIn": false,
- "is_return_item": false,
- "is_linked_item": false,
- "is_virtual_product": false,
- "is_changed": true,
- "salesperson_id": "000111",
- "salesperson_name": "Jesper",
- "serial_id": "32424234231312312",
- "comment": "Kan være hva som helst",
- "infocode_lines": [
- {
- "line_id": 1,
- "amount": 0,
- "amount_dwh": "1.14",
- "infocode_id": "string",
- "sub_infocode_id": "string",
- "information": "string",
- "input_type": 0,
- "withdrawal_from_stock": false
}
], - "tax_lines": [
- {
- "amount": 5584,
- "amount_dwh": "5584.0440",
- "exempt": false,
- "included_in_price": true,
- "percentage": 25,
- "tax_basis": 27920,
- "tax_basis_dwh": "27920.22",
- "tax_code": "3",
- "tax_group": "Vmva-høy"
}
], - "dimension": {
- "color": "string",
- "size": "string",
- "style": "string",
- "config": "string",
- "variant": "string"
}, - "discount_lines": [
- {
- "amount": 4400,
- "percentage": 44,
- "discount_type": "customer",
- "discount_id": "766da0ef-9283-42bd-b012-0582344ec53c",
- "description": "string",
- "line_id": 1
}
], - "bonus_lines": [
- {
- "bonus": 3130,
- "percentage": 10,
- "discount_type": "customer",
- "discount_id": "766da0ef-9283-42bd-b012-0582344ec53c",
- "description": "string",
- "line_id": 1
}
], - "extra_info": [
- {
- "key": "string",
- "value": "string",
- "value_type": "string"
}
]
}
], - "receipt_id": "714118",
- "delivery": {
- "first_name": "John",
- "last_name": "Doe",
- "email": "customer@example.com",
- "phone_number": "+4799999999",
- "address": {
- "address_line": "Sommerkroveien 34",
- "address_line_2": "PB 123",
- "postal_code": "0349",
- "postal_place": "Oslo",
- "country": "NO"
}
}, - "customer_id": "C13db4f63",
- "customer": {
- "gender": "male",
- "first_name": "John",
- "last_name": "Doe",
- "email": "customer@example.com",
- "metadata": {
- "dob_year": 1985
}, - "phone_number": "+4799999999",
- "addresses": [
- {
- "address_line": "Sommerkroveien 34",
- "address_line_2": "PB 123",
- "postal_code": "0349",
- "postal_place": "Oslo",
- "country": "NO",
- "type": "string",
- "custom_type": "string"
}
], - "pays_tax": false,
- "date_of_birth": "1990-09-20",
- "favorite_store": "string",
- "company": {
- "organization_number": "123456789MVA",
- "bussiness_name": "TKP tech AS",
- "department": "sales department",
- "industry": "computer industry",
- "website": "string",
- "number_of_employees": "string"
}, - "marketing_consent": {
- "sms": {
- "consent": true,
- "updated_at": "2018-01-12T13:42:00Z"
}, - "email": {
- "consent": true,
- "updated_at": "2018-01-12T13:42:00Z"
}
}, - "status": "string",
- "term": {
- "id": "string"
}, - "type": "customer",
- "token": {
- "token_id": "983558fe-05bd-495f-92b5-9075d085db32",
- "value": "5345346544ffea22",
- "type": "VIPPS"
}
}, - "gross_amount": 59800,
- "gross_amount_dwh": "59800.01",
- "net_amount": 47840,
- "net_amount_dwh": "47840.01",
- "round_off_to_coin": 100,
- "currency": "NOK",
- "purchase_at": "2019-08-24T14:15:22Z",
- "order_number": "order12345",
- "transaction_date": "2019-08-24T14:15:22Z",
- "amount_due": 2050,
- "amount_due_dwh": "2050.10",
- "no_of_items": 4,
- "is_changed": true,
- "transaction_id": "SC999-9991-1828",
- "total_discount": 0,
- "total_manual_discount_amount": 0,
- "total_manual_percentage_discount": 0,
- "operator_id": "000210",
- "operator_name": "Ole Anders",
- "salesperson_id": "000111",
- "salesperson_name": "Jesper",
- "entry_status": "None",
- "comment": "Kunden ønsker mer for info",
- "tax_lines": [
- {
- "amount": 5584,
- "amount_dwh": "5584.0440",
- "exempt": false,
- "included_in_price": true,
- "percentage": 25,
- "tax_basis": 27920,
- "tax_basis_dwh": "27920.22",
- "tax_code": "3",
- "tax_group": "Vmva-høy"
}
], - "payments": [
- {
- "line_id": 1,
- "amount": 0,
- "type_id": "string",
- "token_id": "983558fe-05bd-495f-92b5-9075d085db32",
- "token_type": "VIPPS",
- "description": "string",
- "voided": true,
- "card_info": {
- "balance_amount": 0,
- "card_amount": 0,
- "issuer_id": 0,
- "issuer_name": "Barcley",
- "session_id": "022",
- "terminal_id": "71015233",
- "card_number": "************00198-1",
- "card_type": "VISA",
- "receipt": "BAX: 111010-71015233\\n\\r\\11/11/2015 14:41\\n\\r\\345849\\n\\r\\ VISA CLASSIC\\n\\r\\************5671\\n\\r\\AID:A0000000031010\\n\\r\\ REF:011 006687000000\\n\\r\\RESP:00 GODKJENT\\n\\r\\RETUR AV VARER\\n\\r \\NOK= 50.00\\n\\r\\SIGNATUR................\\n\\r \\KORTHOLDERS KOPI\n"
}, - "reference_id": "B00668107235",
- "infocode_lines": [
- {
- "line_id": 1,
- "amount": 0,
- "amount_dwh": "1.14",
- "infocode_id": "string",
- "sub_infocode_id": "string",
- "information": "string",
- "input_type": 0,
- "withdrawal_from_stock": false
}
]
}
], - "infocode_items": [
- {
- "line_id": 1,
- "amount": 0,
- "amount_dwh": "1.14",
- "infocode_id": "string",
- "sub_infocode_id": "string",
- "information": "string",
- "input_type": 0,
- "withdrawal_from_stock": false
}
], - "receipt_text": "string",
- "discount_code": [
- "string"
], - "extra_info": [
- {
- "key": "string",
- "value": "string",
- "value_type": "string"
}
]
}
Get receipts matching receipt_id (POS id)
scopes:
aid required | string <^[PT]{1}\d{8}$> = 9 characters An id that uniquely identifies the account. |
receipt_id required | string A string that uniquely identifies POS receipt |
{- "receipts": [
- {
- "id": "497f6eca-6276-4993-bfeb-53cbbbba6f08",
- "created_at": "2019-08-24T14:15:22Z",
- "created_by": "1c92f7e1-2897-4d46-bdcc-c127a914fb4e",
- "updated_at": "2019-08-24T14:15:22Z",
- "deleted_by": "1c92f7e1-2897-4d46-bdcc-c127a914fb4e",
- "deleted_at": "2019-08-24T14:15:22Z",
- "discounts": [
- {
- "id": "497f6eca-6276-4993-bfeb-53cbbbba6f08",
- "created_at": "2019-08-24T14:15:22Z",
- "created_by": "1c92f7e1-2897-4d46-bdcc-c127a914fb4e",
- "updated_at": "2019-08-24T14:15:22Z",
- "deleted_by": "1c92f7e1-2897-4d46-bdcc-c127a914fb4e",
- "deleted_at": "2019-08-24T14:15:22Z",
- "campaign_id": "string",
- "active": true,
- "private": false,
- "updated_by": "3d1e4824-5474-48e7-a369-4f603fa4c5b8",
- "type": "item",
- "name": "Spar 100,-",
- "receipt_text": "Mai Salg",
- "visible_from": "2019-08-24T14:15:22Z",
- "description": "Gjør et Stablestol kupp!",
- "limitation": {
- "discount_activation": [
- {
- "type": "deactivate_if_discount_active",
- "value": "string"
}
], - "discount_hours": {
- "timezone": "Europe/Oslo",
- "hours": [
- {
- "day": "mon",
- "start": "10:00",
- "end": "20:00"
}
]
}, - "discount_reward_usage": 1,
- "discount_combination": -1,
- "discount_eligible": "item_eligible_for_discount",
- "discount_repeat_usage": -1,
- "stamp_expire_days": 100,
- "blacklist": [
- {
- "id": "b714118",
- "group_id": "B1"
}
]
}, - "requirement": {
- "customer": {
- "addresses": [
- {
- "country": [
- "NO"
], - "postal_code": [
- "0349"
], - "postal_place": [
- "Oslo"
], - "custom_type": [
- "offsite"
], - "type": [
- "custom"
]
}
], - "company": {
- "bussiness_name": [
- "TKP tech AS"
], - "department": [
- "production",
- "research"
], - "industry": [
- "J62.0.1",
- "J62.0.2"
], - "number_of_employees": [
- "20"
], - "organization_number": [
- "123456789MVA"
],
}, - "date_of_birth": [
- "1990-09-20",
- "1990-05-10"
], - "favorite_store": [
- "sc029"
], - "first_name": [
- "John"
], - "gender": [
- "male"
], - "last_name": [
- "Doe"
], - "marketing_consent": {
- "email": {
- "consent": [
- "true"
]
}, - "sms": {
- "consent": [
- "true"
]
}
}, - "status": [
- "vip"
], - "term": {
- "id": [
- "string"
]
}, - "type": [
- "string"
], - "attributes": {
- "property1": [
- "string"
], - "property2": [
- "string"
]
}
}, - "item": {
- "quantity": 0,
- "mixes": [
- {
- "items": [
- {
- "id": "b714118"
}, - {
- "group_id": "g4"
}
], - "quantity": 0,
- "reward_eligible": true
}
], - "items": [
- {
- "id": "b714118",
- "group_id": "B1"
}
]
}, - "store_ids": [
- "sc029"
], - "gross_amount": 0,
- "currencies": [
- {
- "anything-but": [
- "NOK"
]
}
], - "stamp": 5,
- "discount_code": "TACO",
- "store": {
- "id": [
- "sc029"
], - "name": [
- "SC Oslo"
], - "business_name": [
- "SC Oslo AS"
], - "address": {
- "country": [
- "NO"
], - "postal_code": [
- "0349"
], - "postal_place": [
- "Oslo"
]
}, - "chain": [
- "SuperChain"
], - "email": [
- "contact@superchain.com"
], - "gln": [
- "5790001398644"
], - "organization_number": [
- "123456789MVA"
], - "phone_number": [
- "+4738260107"
], - "mcc": [
- 5814
], - "mcc_ranges": [
- {
- "start": 5814,
- "end": 5815
}
], - "bax": [
- "102603"
], - "terminal_id": [
- "T0292"
]
}, - "purchase_from": "2019-08-24T14:15:22Z",
- "purchase_to": "2019-08-24T14:15:22Z"
}, - "reward": {
- "type": "discount_amount",
- "value": 10000,
- "values": [
- {
- "items": [
- {
- "id": null,
- "group_id": null
}
], - "value": 0
}
], - "base": "net",
- "effect": "discount"
}, - "metadata": {
- "campaign_id": "V101",
- "is_featured": true,
- "dintero:private_text:kind": "Gold"
}, - "links": [
- {
- "rel": "thumbnail_discount_image"
}, - {
- "rel": "medium_discount_image"
}, - {
- "rel": "webshoop"
}, - {
- "rel": "newletter",
- "type": "application/pdf"
}
], - "refs": [
- {
- "id": "e3da6be5-d8e0-466c-af66-b7f69472ebb5",
- "stamp": 0,
- "amount": 10000,
- "bonus": 9050,
- "statistics": {
- "amount": 15050,
- "bonus": 11050,
- "debit_balance": 12350,
- "stamp": 11,
- "usage": 2
}, - "items": [
- {
- "line_id": 1,
- "amount": 3000
}, - {
- "line_id": 5,
- "amount": 7000
}
], - "usage": 1
}
]
}
], - "store": {
- "id": "sc029",
- "name": "SC Oslo",
- "business_name": "SC Oslo AS",
- "address": {
- "address_line": "Sommerkroveien 34",
- "address_line_2": "PB 123",
- "postal_code": "0349",
- "postal_place": "Oslo",
- "country": "NO"
}, - "chain": "SuperChain",
- "email": "contact@superchain.com",
- "gln": "5790001398644",
- "organization_number": "123456789MVA",
- "phone_number": "+4738260107",
- "mcc": "5814",
- "bax": "102603",
- "terminal_id": "T0292"
}, - "items": [
- {
- "id": "175938",
- "groups": [
- {
- "id": "B234",
- "name": "Stol"
}, - {
- "id": "B1",
- "name": "Møbel"
}
], - "quantity": 2,
- "unit": "stk",
- "description": "Stablestol for utendørsbruk",
- "description_alias": "Stablestol",
- "net_amount": 27840,
- "net_amount_dwh": "27840.10",
- "gross_amount": 39800,
- "gross_amount_dwh": "34800.12",
- "unit_gross_price": 10900,
- "tax_percent": 25,
- "line_id": 1,
- "barcode": "3123212343212",
- "cost_price": 2033,
- "voided": false,
- "scale_item": false,
- "eligible_for_discount": true,
- "included_in_total_discount": true,
- "price_has_been_keyedIn": false,
- "discount_has_been_keyedIn": false,
- "is_return_item": false,
- "is_linked_item": false,
- "is_virtual_product": false,
- "is_changed": true,
- "salesperson_id": "000111",
- "salesperson_name": "Jesper",
- "serial_id": "32424234231312312",
- "comment": "Kan være hva som helst",
- "infocode_lines": [
- {
- "line_id": 1,
- "amount": 0,
- "amount_dwh": "1.14",
- "infocode_id": "string",
- "sub_infocode_id": "string",
- "information": "string",
- "input_type": 0,
- "withdrawal_from_stock": false
}
], - "tax_lines": [
- {
- "amount": 5584,
- "amount_dwh": "5584.0440",
- "exempt": false,
- "included_in_price": true,
- "percentage": 25,
- "tax_basis": 27920,
- "tax_basis_dwh": "27920.22",
- "tax_code": "3",
- "tax_group": "Vmva-høy"
}
], - "dimension": {
- "color": "string",
- "size": "string",
- "style": "string",
- "config": "string",
- "variant": "string"
}, - "discount_lines": [
- {
- "amount": 4400,
- "percentage": 44,
- "discount_type": "customer",
- "discount_id": "766da0ef-9283-42bd-b012-0582344ec53c",
- "description": "string",
- "line_id": 1
}
], - "bonus_lines": [
- {
- "bonus": 3130,
- "percentage": 10,
- "discount_type": "customer",
- "discount_id": "766da0ef-9283-42bd-b012-0582344ec53c",
- "description": "string",
- "line_id": 1
}
], - "extra_info": [
- {
- "key": "string",
- "value": "string",
- "value_type": "string"
}
]
}
], - "receipt_id": "714118",
- "delivery": {
- "first_name": "John",
- "last_name": "Doe",
- "email": "customer@example.com",
- "phone_number": "+4799999999",
- "address": {
- "address_line": "Sommerkroveien 34",
- "address_line_2": "PB 123",
- "postal_code": "0349",
- "postal_place": "Oslo",
- "country": "NO"
}
}, - "customer_id": "C13db4f63",
- "customer": {
- "gender": "male",
- "first_name": "John",
- "last_name": "Doe",
- "email": "customer@example.com",
- "metadata": {
- "dob_year": 1985
}, - "phone_number": "+4799999999",
- "addresses": [
- {
- "address_line": "Sommerkroveien 34",
- "address_line_2": "PB 123",
- "postal_code": "0349",
- "postal_place": "Oslo",
- "country": "NO",
- "type": "string",
- "custom_type": "string"
}
], - "pays_tax": false,
- "date_of_birth": "1990-09-20",
- "favorite_store": "string",
- "company": {
- "organization_number": "123456789MVA",
- "bussiness_name": "TKP tech AS",
- "department": "sales department",
- "industry": "computer industry",
- "website": "string",
- "number_of_employees": "string"
}, - "marketing_consent": {
- "sms": {
- "consent": true,
- "updated_at": "2018-01-12T13:42:00Z"
}, - "email": {
- "consent": true,
- "updated_at": "2018-01-12T13:42:00Z"
}
}, - "status": "string",
- "term": {
- "id": "string"
}, - "type": "customer",
- "token": {
- "token_id": "983558fe-05bd-495f-92b5-9075d085db32",
- "value": "5345346544ffea22",
- "type": "VIPPS"
}
}, - "gross_amount": 59800,
- "gross_amount_dwh": "59800.01",
- "net_amount": 47840,
- "net_amount_dwh": "47840.01",
- "round_off_to_coin": 100,
- "currency": "NOK",
- "purchase_at": "2019-08-24T14:15:22Z",
- "order_number": "order12345",
- "transaction_date": "2019-08-24T14:15:22Z",
- "amount_due": 2050,
- "amount_due_dwh": "2050.10",
- "no_of_items": 4,
- "is_changed": true,
- "transaction_id": "SC999-9991-1828",
- "total_discount": 0,
- "total_manual_discount_amount": 0,
- "total_manual_percentage_discount": 0,
- "operator_id": "000210",
- "operator_name": "Ole Anders",
- "salesperson_id": "000111",
- "salesperson_name": "Jesper",
- "entry_status": "None",
- "comment": "Kunden ønsker mer for info",
- "tax_lines": [
- {
- "amount": 5584,
- "amount_dwh": "5584.0440",
- "exempt": false,
- "included_in_price": true,
- "percentage": 25,
- "tax_basis": 27920,
- "tax_basis_dwh": "27920.22",
- "tax_code": "3",
- "tax_group": "Vmva-høy"
}
], - "payments": [
- {
- "line_id": 1,
- "amount": 0,
- "type_id": "string",
- "token_id": "983558fe-05bd-495f-92b5-9075d085db32",
- "token_type": "VIPPS",
- "description": "string",
- "voided": true,
- "card_info": {
- "balance_amount": 0,
- "card_amount": 0,
- "issuer_id": 0,
- "issuer_name": "Barcley",
- "session_id": "022",
- "terminal_id": "71015233",
- "card_number": "************00198-1",
- "card_type": "VISA",
- "receipt": "BAX: 111010-71015233\\n\\r\\11/11/2015 14:41\\n\\r\\345849\\n\\r\\ VISA CLASSIC\\n\\r\\************5671\\n\\r\\AID:A0000000031010\\n\\r\\ REF:011 006687000000\\n\\r\\RESP:00 GODKJENT\\n\\r\\RETUR AV VARER\\n\\r \\NOK= 50.00\\n\\r\\SIGNATUR................\\n\\r \\KORTHOLDERS KOPI\n"
}, - "reference_id": "B00668107235",
- "infocode_lines": [
- {
- "line_id": 1,
- "amount": 0,
- "amount_dwh": "1.14",
- "infocode_id": "string",
- "sub_infocode_id": "string",
- "information": "string",
- "input_type": 0,
- "withdrawal_from_stock": false
}
]
}
], - "infocode_items": [
- {
- "line_id": 1,
- "amount": 0,
- "amount_dwh": "1.14",
- "infocode_id": "string",
- "sub_infocode_id": "string",
- "information": "string",
- "input_type": 0,
- "withdrawal_from_stock": false
}
], - "receipt_text": "string",
- "discount_code": [
- "string"
], - "extra_info": [
- {
- "key": "string",
- "value": "string",
- "value_type": "string"
}
]
}
], - "starting_after": "string"
}
Get the receipts for a customer
scopes:
aid required | string <^[PT]{1}\d{8}$> = 9 characters An id that uniquely identifies the account. |
customer_id required | string <= 255 characters The customer id you have defined for the customer. (must not have trailing or leading spaces) |
limit | integer [ 1 .. 100 ] Default: 10 A limit on the number of objects to be returned. Limit can range between 1 and 100 items, and the default is 10 items. |
starting_after | string cursor for use in pagination. starting_after is an object ID
that defines your place in the list. For instance, if you make
a list request and receive 100 objects, end the result contains
|
{- "receipts": [
- {
- "id": "497f6eca-6276-4993-bfeb-53cbbbba6f08",
- "created_at": "2019-08-24T14:15:22Z",
- "created_by": "1c92f7e1-2897-4d46-bdcc-c127a914fb4e",
- "updated_at": "2019-08-24T14:15:22Z",
- "deleted_by": "1c92f7e1-2897-4d46-bdcc-c127a914fb4e",
- "deleted_at": "2019-08-24T14:15:22Z",
- "store": {
- "id": "sc029",
- "name": "SC Oslo",
- "business_name": "SC Oslo AS",
- "address": {
- "address_line": "Sommerkroveien 34",
- "address_line_2": "PB 123",
- "postal_code": "0349",
- "postal_place": "Oslo",
- "country": "NO"
}, - "chain": "SuperChain",
- "email": "contact@superchain.com",
- "gln": "5790001398644",
- "organization_number": "123456789MVA",
- "phone_number": "+4738260107",
- "mcc": "5814",
- "bax": "102603",
- "terminal_id": "T0292"
}, - "items": [
- {
- "id": "175938",
- "groups": [
- {
- "id": "B234",
- "name": "Stol"
}, - {
- "id": "B1",
- "name": "Møbel"
}
], - "quantity": 2,
- "unit": "stk",
- "description": "Stablestol for utendørsbruk",
- "description_alias": "Stablestol",
- "net_amount": 27840,
- "net_amount_dwh": "27840.10",
- "gross_amount": 39800,
- "gross_amount_dwh": "34800.12",
- "unit_gross_price": 10900,
- "tax_percent": 25,
- "line_id": 1,
- "barcode": "3123212343212",
- "cost_price": 2033,
- "voided": false,
- "scale_item": false,
- "eligible_for_discount": true,
- "included_in_total_discount": true,
- "price_has_been_keyedIn": false,
- "discount_has_been_keyedIn": false,
- "is_return_item": false,
- "is_linked_item": false,
- "is_virtual_product": false,
- "is_changed": true,
- "salesperson_id": "000111",
- "salesperson_name": "Jesper",
- "serial_id": "32424234231312312",
- "comment": "Kan være hva som helst",
- "infocode_lines": [
- {
- "line_id": 1,
- "amount": 0,
- "amount_dwh": "1.14",
- "infocode_id": "string",
- "sub_infocode_id": "string",
- "information": "string",
- "input_type": 0,
- "withdrawal_from_stock": false
}
], - "tax_lines": [
- {
- "amount": 5584,
- "amount_dwh": "5584.0440",
- "exempt": false,
- "included_in_price": true,
- "percentage": 25,
- "tax_basis": 27920,
- "tax_basis_dwh": "27920.22",
- "tax_code": "3",
- "tax_group": "Vmva-høy"
}
], - "dimension": {
- "color": "string",
- "size": "string",
- "style": "string",
- "config": "string",
- "variant": "string"
}, - "discount_lines": [
- {
- "amount": 4400,
- "percentage": 44,
- "discount_type": "customer",
- "discount_id": "766da0ef-9283-42bd-b012-0582344ec53c",
- "description": "string",
- "line_id": 1
}
], - "bonus_lines": [
- {
- "bonus": 3130,
- "percentage": 10,
- "discount_type": "customer",
- "discount_id": "766da0ef-9283-42bd-b012-0582344ec53c",
- "description": "string",
- "line_id": 1
}
], - "extra_info": [
- {
- "key": "string",
- "value": "string",
- "value_type": "string"
}
]
}
], - "gross_amount": 47840,
- "net_amount": 38000,
- "currency": "NOK",
- "purchase_at": "2019-08-24T14:15:22Z"
}
], - "starting_after": "string"
}
Get a customer receipt
scopes:
aid required | string <^[PT]{1}\d{8}$> = 9 characters An id that uniquely identifies the account. |
customer_id required | string <= 255 characters The customer id you have defined for the customer. (must not have trailing or leading spaces) |
receipt_id required | string A string that uniquely identifies POS receipt |
{- "id": "497f6eca-6276-4993-bfeb-53cbbbba6f08",
- "created_at": "2019-08-24T14:15:22Z",
- "created_by": "1c92f7e1-2897-4d46-bdcc-c127a914fb4e",
- "updated_at": "2019-08-24T14:15:22Z",
- "deleted_by": "1c92f7e1-2897-4d46-bdcc-c127a914fb4e",
- "deleted_at": "2019-08-24T14:15:22Z",
- "discounts": [
- {
- "id": "497f6eca-6276-4993-bfeb-53cbbbba6f08",
- "created_at": "2019-08-24T14:15:22Z",
- "created_by": "1c92f7e1-2897-4d46-bdcc-c127a914fb4e",
- "updated_at": "2019-08-24T14:15:22Z",
- "deleted_by": "1c92f7e1-2897-4d46-bdcc-c127a914fb4e",
- "deleted_at": "2019-08-24T14:15:22Z",
- "campaign_id": "string",
- "active": true,
- "private": false,
- "updated_by": "3d1e4824-5474-48e7-a369-4f603fa4c5b8",
- "type": "item",
- "name": "Spar 100,-",
- "receipt_text": "Mai Salg",
- "visible_from": "2019-08-24T14:15:22Z",
- "description": "Gjør et Stablestol kupp!",
- "limitation": {
- "discount_activation": [
- {
- "type": "deactivate_if_discount_active",
- "value": "string"
}
], - "discount_hours": {
- "timezone": "Europe/Oslo",
- "hours": [
- {
- "day": "mon",
- "start": "10:00",
- "end": "20:00"
}
]
}, - "discount_reward_usage": 1,
- "discount_combination": -1,
- "discount_eligible": "item_eligible_for_discount",
- "discount_repeat_usage": -1,
- "stamp_expire_days": 100,
- "blacklist": [
- {
- "id": "b714118",
- "group_id": "B1"
}
]
}, - "requirement": {
- "customer": {
- "addresses": [
- {
- "country": [
- "NO"
], - "postal_code": [
- "0349"
], - "postal_place": [
- "Oslo"
], - "custom_type": [
- "offsite"
], - "type": [
- "custom"
]
}
], - "company": {
- "bussiness_name": [
- "TKP tech AS"
], - "department": [
- "production",
- "research"
], - "industry": [
- "J62.0.1",
- "J62.0.2"
], - "number_of_employees": [
- "20"
], - "organization_number": [
- "123456789MVA"
],
}, - "date_of_birth": [
- "1990-09-20",
- "1990-05-10"
], - "favorite_store": [
- "sc029"
], - "first_name": [
- "John"
], - "gender": [
- "male"
], - "last_name": [
- "Doe"
], - "marketing_consent": {
- "email": {
- "consent": [
- "true"
]
}, - "sms": {
- "consent": [
- "true"
]
}
}, - "status": [
- "vip"
], - "term": {
- "id": [
- "string"
]
}, - "type": [
- "string"
], - "attributes": {
- "property1": [
- "string"
], - "property2": [
- "string"
]
}
}, - "item": {
- "quantity": 0,
- "mixes": [
- {
- "items": [
- {
- "id": "b714118"
}, - {
- "group_id": "g4"
}
], - "quantity": 0,
- "reward_eligible": true
}
], - "items": [
- {
- "id": "b714118",
- "group_id": "B1"
}
]
}, - "store_ids": [
- "sc029"
], - "gross_amount": 0,
- "currencies": [
- {
- "anything-but": [
- "NOK"
]
}
], - "stamp": 5,
- "discount_code": "TACO",
- "store": {
- "id": [
- "sc029"
], - "name": [
- "SC Oslo"
], - "business_name": [
- "SC Oslo AS"
], - "address": {
- "country": [
- "NO"
], - "postal_code": [
- "0349"
], - "postal_place": [
- "Oslo"
]
}, - "chain": [
- "SuperChain"
], - "email": [
- "contact@superchain.com"
], - "gln": [
- "5790001398644"
], - "organization_number": [
- "123456789MVA"
], - "phone_number": [
- "+4738260107"
], - "mcc": [
- 5814
], - "mcc_ranges": [
- {
- "start": 5814,
- "end": 5815
}
], - "bax": [
- "102603"
], - "terminal_id": [
- "T0292"
]
}, - "purchase_from": "2019-08-24T14:15:22Z",
- "purchase_to": "2019-08-24T14:15:22Z"
}, - "reward": {
- "type": "discount_amount",
- "value": 10000,
- "values": [
- {
- "items": [
- {
- "id": "b714118",
- "group_id": "B1"
}
], - "value": 0
}
], - "base": "net",
- "effect": "discount"
}, - "metadata": {
- "campaign_id": "V101",
- "is_featured": true,
- "dintero:private_text:kind": "Gold"
}, - "links": [
- {
- "rel": "thumbnail_discount_image"
}, - {
- "rel": "medium_discount_image"
}, - {
- "rel": "webshoop"
}, - {
- "rel": "newletter",
- "type": "application/pdf"
}
], - "refs": [
- {
- "id": "e3da6be5-d8e0-466c-af66-b7f69472ebb5",
- "stamp": 0,
- "amount": 10000,
- "bonus": 9050,
- "statistics": {
- "amount": 15050,
- "bonus": 11050,
- "debit_balance": 12350,
- "stamp": 11,
- "usage": 2
}, - "items": [
- {
- "line_id": 1,
- "amount": 3000
}, - {
- "line_id": 5,
- "amount": 7000
}
], - "usage": 1
}
]
}
], - "store": {
- "id": "sc029",
- "name": "SC Oslo",
- "business_name": "SC Oslo AS",
- "address": {
- "address_line": "Sommerkroveien 34",
- "address_line_2": "PB 123",
- "postal_code": "0349",
- "postal_place": "Oslo",
- "country": "NO"
}, - "chain": "SuperChain",
- "email": "contact@superchain.com",
- "gln": "5790001398644",
- "organization_number": "123456789MVA",
- "phone_number": "+4738260107",
- "mcc": "5814",
- "bax": "102603",
- "terminal_id": "T0292"
}, - "items": [
- {
- "id": "175938",
- "groups": [
- {
- "id": "B234",
- "name": "Stol"
}, - {
- "id": "B1",
- "name": "Møbel"
}
], - "quantity": 2,
- "unit": "stk",
- "description": "Stablestol for utendørsbruk",
- "description_alias": "Stablestol",
- "net_amount": 27840,
- "net_amount_dwh": "27840.10",
- "gross_amount": 39800,
- "gross_amount_dwh": "34800.12",
- "unit_gross_price": 10900,
- "tax_percent": 25,
- "line_id": 1,
- "barcode": "3123212343212",
- "cost_price": 2033,
- "voided": false,
- "scale_item": false,
- "eligible_for_discount": true,
- "included_in_total_discount": true,
- "price_has_been_keyedIn": false,
- "discount_has_been_keyedIn": false,
- "is_return_item": false,
- "is_linked_item": false,
- "is_virtual_product": false,
- "is_changed": true,
- "salesperson_id": "000111",
- "salesperson_name": "Jesper",
- "serial_id": "32424234231312312",
- "comment": "Kan være hva som helst",
- "infocode_lines": [
- {
- "line_id": 1,
- "amount": 0,
- "amount_dwh": "1.14",
- "infocode_id": "string",
- "sub_infocode_id": "string",
- "information": "string",
- "input_type": 0,
- "withdrawal_from_stock": false
}
], - "tax_lines": [
- {
- "amount": 5584,
- "amount_dwh": "5584.0440",
- "exempt": false,
- "included_in_price": true,
- "percentage": 25,
- "tax_basis": 27920,
- "tax_basis_dwh": "27920.22",
- "tax_code": "3",
- "tax_group": "Vmva-høy"
}
], - "dimension": {
- "color": "string",
- "size": "string",
- "style": "string",
- "config": "string",
- "variant": "string"
}, - "discount_lines": [
- {
- "amount": 4400,
- "percentage": 44,
- "discount_type": "customer",
- "discount_id": "766da0ef-9283-42bd-b012-0582344ec53c",
- "description": "string",
- "line_id": 1
}
], - "bonus_lines": [
- {
- "bonus": 3130,
- "percentage": 10,
- "discount_type": "customer",
- "discount_id": "766da0ef-9283-42bd-b012-0582344ec53c",
- "description": "string",
- "line_id": 1
}
], - "extra_info": [
- {
- "key": "string",
- "value": "string",
- "value_type": "string"
}
]
}
], - "receipt_id": "714118",
- "delivery": {
- "first_name": "John",
- "last_name": "Doe",
- "email": "customer@example.com",
- "phone_number": "+4799999999",
- "address": {
- "address_line": "Sommerkroveien 34",
- "address_line_2": "PB 123",
- "postal_code": "0349",
- "postal_place": "Oslo",
- "country": "NO"
}
}, - "customer_id": "C13db4f63",
- "customer": {
- "gender": "male",
- "first_name": "John",
- "last_name": "Doe",
- "email": "customer@example.com",
- "metadata": {
- "dob_year": 1985
}, - "phone_number": "+4799999999",
- "addresses": [
- {
- "address_line": "Sommerkroveien 34",
- "address_line_2": "PB 123",
- "postal_code": "0349",
- "postal_place": "Oslo",
- "country": "NO",
- "type": "string",
- "custom_type": "string"
}
], - "pays_tax": false,
- "date_of_birth": "1990-09-20",
- "favorite_store": "string",
- "company": {
- "organization_number": "123456789MVA",
- "bussiness_name": "TKP tech AS",
- "department": "sales department",
- "industry": "computer industry",
- "website": "string",
- "number_of_employees": "string"
}, - "marketing_consent": {
- "sms": {
- "consent": true,
- "updated_at": "2018-01-12T13:42:00Z"
}, - "email": {
- "consent": true,
- "updated_at": "2018-01-12T13:42:00Z"
}
}, - "status": "string",
- "term": {
- "id": "string"
}, - "type": "customer",
- "token": {
- "token_id": "983558fe-05bd-495f-92b5-9075d085db32",
- "value": "5345346544ffea22",
- "type": "VIPPS"
}
}, - "gross_amount": 59800,
- "gross_amount_dwh": "59800.01",
- "net_amount": 47840,
- "net_amount_dwh": "47840.01",
- "round_off_to_coin": 100,
- "currency": "NOK",
- "purchase_at": "2019-08-24T14:15:22Z",
- "order_number": "order12345",
- "transaction_date": "2019-08-24T14:15:22Z",
- "amount_due": 2050,
- "amount_due_dwh": "2050.10",
- "no_of_items": 4,
- "is_changed": true,
- "transaction_id": "SC999-9991-1828",
- "total_discount": 0,
- "total_manual_discount_amount": 0,
- "total_manual_percentage_discount": 0,
- "operator_id": "000210",
- "operator_name": "Ole Anders",
- "salesperson_id": "000111",
- "salesperson_name": "Jesper",
- "entry_status": "None",
- "comment": "Kunden ønsker mer for info",
- "tax_lines": [
- {
- "amount": 5584,
- "amount_dwh": "5584.0440",
- "exempt": false,
- "included_in_price": true,
- "percentage": 25,
- "tax_basis": 27920,
- "tax_basis_dwh": "27920.22",
- "tax_code": "3",
- "tax_group": "Vmva-høy"
}
], - "payments": [
- {
- "line_id": 1,
- "amount": 0,
- "type_id": "string",
- "token_id": "983558fe-05bd-495f-92b5-9075d085db32",
- "token_type": "VIPPS",
- "description": "string",
- "voided": true,
- "card_info": {
- "balance_amount": 0,
- "card_amount": 0,
- "issuer_id": 0,
- "issuer_name": "Barcley",
- "session_id": "022",
- "terminal_id": "71015233",
- "card_number": "************00198-1",
- "card_type": "VISA",
- "receipt": "BAX: 111010-71015233\\n\\r\\11/11/2015 14:41\\n\\r\\345849\\n\\r\\ VISA CLASSIC\\n\\r\\************5671\\n\\r\\AID:A0000000031010\\n\\r\\ REF:011 006687000000\\n\\r\\RESP:00 GODKJENT\\n\\r\\RETUR AV VARER\\n\\r \\NOK= 50.00\\n\\r\\SIGNATUR................\\n\\r \\KORTHOLDERS KOPI\n"
}, - "reference_id": "B00668107235",
- "infocode_lines": [
- {
- "line_id": 1,
- "amount": 0,
- "amount_dwh": "1.14",
- "infocode_id": "string",
- "sub_infocode_id": "string",
- "information": "string",
- "input_type": 0,
- "withdrawal_from_stock": false
}
]
}
], - "infocode_items": [
- {
- "line_id": 1,
- "amount": 0,
- "amount_dwh": "1.14",
- "infocode_id": "string",
- "sub_infocode_id": "string",
- "information": "string",
- "input_type": 0,
- "withdrawal_from_stock": false
}
], - "receipt_text": "string",
- "discount_code": [
- "string"
], - "extra_info": [
- {
- "key": "string",
- "value": "string",
- "value_type": "string"
}
]
}
Update customer_id for an receipt, i.e. move the receipt to a new customer
warning: The receipt will no longer be accessible by the previous customer_id
Following extra_info field will be added to the receipt when customer_id is changed using key
dintero.receipts.change_customer_id.{timestamp}.{hash}
The content of the extra_info will be a JSON string containing:
scopes:
aid required | string <^[PT]{1}\d{8}$> = 9 characters An id that uniquely identifies the account. |
customer_id required | string <= 255 characters The customer id you have defined for the customer. (must not have trailing or leading spaces) |
receipt_id required | string A string that uniquely identifies POS receipt |
Receipt update
customer_id | string [ 1 .. 255 ] characters New customer_id (must not have trailing or leading spaces). |
{- "customer_id": "string"
}
{- "id": "497f6eca-6276-4993-bfeb-53cbbbba6f08",
- "created_at": "2019-08-24T14:15:22Z",
- "created_by": "1c92f7e1-2897-4d46-bdcc-c127a914fb4e",
- "updated_at": "2019-08-24T14:15:22Z",
- "deleted_by": "1c92f7e1-2897-4d46-bdcc-c127a914fb4e",
- "deleted_at": "2019-08-24T14:15:22Z",
- "discounts": [
- {
- "id": "497f6eca-6276-4993-bfeb-53cbbbba6f08",
- "created_at": "2019-08-24T14:15:22Z",
- "created_by": "1c92f7e1-2897-4d46-bdcc-c127a914fb4e",
- "updated_at": "2019-08-24T14:15:22Z",
- "deleted_by": "1c92f7e1-2897-4d46-bdcc-c127a914fb4e",
- "deleted_at": "2019-08-24T14:15:22Z",
- "campaign_id": "string",
- "active": true,
- "private": false,
- "updated_by": "3d1e4824-5474-48e7-a369-4f603fa4c5b8",
- "type": "item",
- "name": "Spar 100,-",
- "receipt_text": "Mai Salg",
- "visible_from": "2019-08-24T14:15:22Z",
- "description": "Gjør et Stablestol kupp!",
- "limitation": {
- "discount_activation": [
- {
- "type": "deactivate_if_discount_active",
- "value": "string"
}
], - "discount_hours": {
- "timezone": "Europe/Oslo",
- "hours": [
- {
- "day": "mon",
- "start": "10:00",
- "end": "20:00"
}
]
}, - "discount_reward_usage": 1,
- "discount_combination": -1,
- "discount_eligible": "item_eligible_for_discount",
- "discount_repeat_usage": -1,
- "stamp_expire_days": 100,
- "blacklist": [
- {
- "id": "b714118",
- "group_id": "B1"
}
]
}, - "requirement": {
- "customer": {
- "addresses": [
- {
- "country": [
- "NO"
], - "postal_code": [
- "0349"
], - "postal_place": [
- "Oslo"
], - "custom_type": [
- "offsite"
], - "type": [
- "custom"
]
}
], - "company": {
- "bussiness_name": [
- "TKP tech AS"
], - "department": [
- "production",
- "research"
], - "industry": [
- "J62.0.1",
- "J62.0.2"
], - "number_of_employees": [
- "20"
], - "organization_number": [
- "123456789MVA"
],
}, - "date_of_birth": [
- "1990-09-20",
- "1990-05-10"
], - "favorite_store": [
- "sc029"
], - "first_name": [
- "John"
], - "gender": [
- "male"
], - "last_name": [
- "Doe"
], - "marketing_consent": {
- "email": {
- "consent": [
- "true"
]
}, - "sms": {
- "consent": [
- "true"
]
}
}, - "status": [
- "vip"
], - "term": {
- "id": [
- "string"
]
}, - "type": [
- "string"
], - "attributes": {
- "property1": [
- "string"
], - "property2": [
- "string"
]
}
}, - "item": {
- "quantity": 0,
- "mixes": [
- {
- "items": [
- {
- "id": "b714118"
}, - {
- "group_id": "g4"
}
], - "quantity": 0,
- "reward_eligible": true
}
], - "items": [
- {
- "id": "b714118",
- "group_id": "B1"
}
]
}, - "store_ids": [
- "sc029"
], - "gross_amount": 0,
- "currencies": [
- {
- "anything-but": [
- "NOK"
]
}
], - "stamp": 5,
- "discount_code": "TACO",
- "store": {
- "id": [
- "sc029"
], - "name": [
- "SC Oslo"
], - "business_name": [
- "SC Oslo AS"
], - "address": {
- "country": [
- "NO"
], - "postal_code": [
- "0349"
], - "postal_place": [
- "Oslo"
]
}, - "chain": [
- "SuperChain"
], - "email": [
- "contact@superchain.com"
], - "gln": [
- "5790001398644"
], - "organization_number": [
- "123456789MVA"
], - "phone_number": [
- "+4738260107"
], - "mcc": [
- 5814
], - "mcc_ranges": [
- {
- "start": 5814,
- "end": 5815
}
], - "bax": [
- "102603"
], - "terminal_id": [
- "T0292"
]
}, - "purchase_from": "2019-08-24T14:15:22Z",
- "purchase_to": "2019-08-24T14:15:22Z"
}, - "reward": {
- "type": "discount_amount",
- "value": 10000,
- "values": [
- {
- "items": [
- {
- "id": "b714118",
- "group_id": "B1"
}
], - "value": 0
}
], - "base": "net",
- "effect": "discount"
}, - "metadata": {
- "campaign_id": "V101",
- "is_featured": true,
- "dintero:private_text:kind": "Gold"
}, - "links": [
- {
- "rel": "thumbnail_discount_image"
}, - {
- "rel": "medium_discount_image"
}, - {
- "rel": "webshoop"
}, - {
- "rel": "newletter",
- "type": "application/pdf"
}
], - "refs": [
- {
- "id": "e3da6be5-d8e0-466c-af66-b7f69472ebb5",
- "stamp": 0,
- "amount": 10000,
- "bonus": 9050,
- "statistics": {
- "amount": 15050,
- "bonus": 11050,
- "debit_balance": 12350,
- "stamp": 11,
- "usage": 2
}, - "items": [
- {
- "line_id": 1,
- "amount": 3000
}, - {
- "line_id": 5,
- "amount": 7000
}
], - "usage": 1
}
]
}
], - "store": {
- "id": "sc029",
- "name": "SC Oslo",
- "business_name": "SC Oslo AS",
- "address": {
- "address_line": "Sommerkroveien 34",
- "address_line_2": "PB 123",
- "postal_code": "0349",
- "postal_place": "Oslo",
- "country": "NO"
}, - "chain": "SuperChain",
- "email": "contact@superchain.com",
- "gln": "5790001398644",
- "organization_number": "123456789MVA",
- "phone_number": "+4738260107",
- "mcc": "5814",
- "bax": "102603",
- "terminal_id": "T0292"
}, - "items": [
- {
- "id": "175938",
- "groups": [
- {
- "id": "B234",
- "name": "Stol"
}, - {
- "id": "B1",
- "name": "Møbel"
}
], - "quantity": 2,
- "unit": "stk",
- "description": "Stablestol for utendørsbruk",
- "description_alias": "Stablestol",
- "net_amount": 27840,
- "net_amount_dwh": "27840.10",
- "gross_amount": 39800,
- "gross_amount_dwh": "34800.12",
- "unit_gross_price": 10900,
- "tax_percent": 25,
- "line_id": 1,
- "barcode": "3123212343212",
- "cost_price": 2033,
- "voided": false,
- "scale_item": false,
- "eligible_for_discount": true,
- "included_in_total_discount": true,
- "price_has_been_keyedIn": false,
- "discount_has_been_keyedIn": false,
- "is_return_item": false,
- "is_linked_item": false,
- "is_virtual_product": false,
- "is_changed": true,
- "salesperson_id": "000111",
- "salesperson_name": "Jesper",
- "serial_id": "32424234231312312",
- "comment": "Kan være hva som helst",
- "infocode_lines": [
- {
- "line_id": 1,
- "amount": 0,
- "amount_dwh": "1.14",
- "infocode_id": "string",
- "sub_infocode_id": "string",
- "information": "string",
- "input_type": 0,
- "withdrawal_from_stock": false
}
], - "tax_lines": [
- {
- "amount": 5584,
- "amount_dwh": "5584.0440",
- "exempt": false,
- "included_in_price": true,
- "percentage": 25,
- "tax_basis": 27920,
- "tax_basis_dwh": "27920.22",
- "tax_code": "3",
- "tax_group": "Vmva-høy"
}
], - "dimension": {
- "color": "string",
- "size": "string",
- "style": "string",
- "config": "string",
- "variant": "string"
}, - "discount_lines": [
- {
- "amount": 4400,
- "percentage": 44,
- "discount_type": "customer",
- "discount_id": "766da0ef-9283-42bd-b012-0582344ec53c",
- "description": "string",
- "line_id": 1
}
], - "bonus_lines": [
- {
- "bonus": 3130,
- "percentage": 10,
- "discount_type": "customer",
- "discount_id": "766da0ef-9283-42bd-b012-0582344ec53c",
- "description": "string",
- "line_id": 1
}
], - "extra_info": [
- {
- "key": "string",
- "value": "string",
- "value_type": "string"
}
]
}
], - "receipt_id": "714118",
- "delivery": {
- "first_name": "John",
- "last_name": "Doe",
- "email": "customer@example.com",
- "phone_number": "+4799999999",
- "address": {
- "address_line": "Sommerkroveien 34",
- "address_line_2": "PB 123",
- "postal_code": "0349",
- "postal_place": "Oslo",
- "country": "NO"
}
}, - "customer_id": "C13db4f63",
- "customer": {
- "gender": "male",
- "first_name": "John",
- "last_name": "Doe",
- "email": "customer@example.com",
- "metadata": {
- "dob_year": 1985
}, - "phone_number": "+4799999999",
- "addresses": [
- {
- "address_line": "Sommerkroveien 34",
- "address_line_2": "PB 123",
- "postal_code": "0349",
- "postal_place": "Oslo",
- "country": "NO",
- "type": "string",
- "custom_type": "string"
}
], - "pays_tax": false,
- "date_of_birth": "1990-09-20",
- "favorite_store": "string",
- "company": {
- "organization_number": "123456789MVA",
- "bussiness_name": "TKP tech AS",
- "department": "sales department",
- "industry": "computer industry",
- "website": "string",
- "number_of_employees": "string"
}, - "marketing_consent": {
- "sms": {
- "consent": true,
- "updated_at": "2018-01-12T13:42:00Z"
}, - "email": {
- "consent": true,
- "updated_at": "2018-01-12T13:42:00Z"
}
}, - "status": "string",
- "term": {
- "id": "string"
}, - "type": "customer",
- "token": {
- "token_id": "983558fe-05bd-495f-92b5-9075d085db32",
- "value": "5345346544ffea22",
- "type": "VIPPS"
}
}, - "gross_amount": 59800,
- "gross_amount_dwh": "59800.01",
- "net_amount": 47840,
- "net_amount_dwh": "47840.01",
- "round_off_to_coin": 100,
- "currency": "NOK",
- "purchase_at": "2019-08-24T14:15:22Z",
- "order_number": "order12345",
- "transaction_date": "2019-08-24T14:15:22Z",
- "amount_due": 2050,
- "amount_due_dwh": "2050.10",
- "no_of_items": 4,
- "is_changed": true,
- "transaction_id": "SC999-9991-1828",
- "total_discount": 0,
- "total_manual_discount_amount": 0,
- "total_manual_percentage_discount": 0,
- "operator_id": "000210",
- "operator_name": "Ole Anders",
- "salesperson_id": "000111",
- "salesperson_name": "Jesper",
- "entry_status": "None",
- "comment": "Kunden ønsker mer for info",
- "tax_lines": [
- {
- "amount": 5584,
- "amount_dwh": "5584.0440",
- "exempt": false,
- "included_in_price": true,
- "percentage": 25,
- "tax_basis": 27920,
- "tax_basis_dwh": "27920.22",
- "tax_code": "3",
- "tax_group": "Vmva-høy"
}
], - "payments": [
- {
- "line_id": 1,
- "amount": 0,
- "type_id": "string",
- "token_id": "983558fe-05bd-495f-92b5-9075d085db32",
- "token_type": "VIPPS",
- "description": "string",
- "voided": true,
- "card_info": {
- "balance_amount": 0,
- "card_amount": 0,
- "issuer_id": 0,
- "issuer_name": "Barcley",
- "session_id": "022",
- "terminal_id": "71015233",
- "card_number": "************00198-1",
- "card_type": "VISA",
- "receipt": "BAX: 111010-71015233\\n\\r\\11/11/2015 14:41\\n\\r\\345849\\n\\r\\ VISA CLASSIC\\n\\r\\************5671\\n\\r\\AID:A0000000031010\\n\\r\\ REF:011 006687000000\\n\\r\\RESP:00 GODKJENT\\n\\r\\RETUR AV VARER\\n\\r \\NOK= 50.00\\n\\r\\SIGNATUR................\\n\\r \\KORTHOLDERS KOPI\n"
}, - "reference_id": "B00668107235",
- "infocode_lines": [
- {
- "line_id": 1,
- "amount": 0,
- "amount_dwh": "1.14",
- "infocode_id": "string",
- "sub_infocode_id": "string",
- "information": "string",
- "input_type": 0,
- "withdrawal_from_stock": false
}
]
}
], - "infocode_items": [
- {
- "line_id": 1,
- "amount": 0,
- "amount_dwh": "1.14",
- "infocode_id": "string",
- "sub_infocode_id": "string",
- "information": "string",
- "input_type": 0,
- "withdrawal_from_stock": false
}
], - "receipt_text": "string",
- "discount_code": [
- "string"
], - "extra_info": [
- {
- "key": "string",
- "value": "string",
- "value_type": "string"
}
]
}
Segment customer by receipt data
scopes:
aid required | string <^[PT]{1}\d{8}$> = 9 characters An id that uniquely identifies the account. |
segmentation on receipt data
purchase_from | string <date-time> |
purchase_to | string <date-time> |
store_ids | Array of strings |
Array of objects |
{- "purchase_from": "2019-08-24T14:15:22Z",
- "purchase_to": "2019-08-24T14:15:22Z",
- "store_ids": [
- "string"
], - "items": [
- {
- "id": "string",
- "group": "string"
}
]
}
{- "customers": [
- {
- "customer_id": "160c0c4b-9966-4dc1-a916-8407eb10d74e",
- "purchases": 5
}
]
}
Create a new card
scopes:
aid required | string <^[PT]{1}\d{8}$> = 9 characters An id that uniquely identifies the account. |
card details
card_id required | string <= 255 characters The card id you have defined for the card. (must not have trailing or leading spaces) |
amount required | integer >= 0 Monetary amount in smallest unit for the currency |
currency required | string Enum: "NOK" "SEK" "DKK" "EUR" "USD" The three-character ISO-4217 currency. https://en.wikipedia.org/wiki/ISO_4217 |
customer_id | string <= 255 characters The customer id you have defined as the owner of the card. (must not have trailing or leading spaces) |
name | string Display name for the card |
type | string Enum: "gift_card" "credit_note" The type of the card. The value is one of the following:
Defaults to |
metadata | object A key-value JSON object to store any additional information. The dintero_* namespace for keys is reserved |
active_from | string <date-time> Optional time when the card is activated. No |
expires_at | string <date-time> Optional expiration time for the card. No transaction will be allowed on an expired card |
object (PinGenerator) How the PIN should be generated. | |
object (TokenGenerator) Specify how token should be generated |
{- "card_id": "string",
- "customer_id": "string",
- "name": "string",
- "type": "gift_card",
- "metadata": {
- "order_id": "xk39592f"
}, - "amount": 50000,
- "currency": "NOK",
- "active_from": "2019-08-24T14:15:22Z",
- "expires_at": "2019-08-24T14:15:22Z",
- "pin": {
- "format": {
- "length": 36,
- "prefix": "DINCARD:",
- "symbols": true,
- "numbers": true,
- "characters": true,
- "barcode": false
}
}, - "card_token": {
- "format": {
- "length": 36,
- "prefix": "DINCARD:",
- "symbols": true,
- "numbers": true,
- "characters": true,
- "barcode": false
}, - "expires_after_transaction": true,
- "expires_in": 1
}
}
{- "card_id": "string",
- "customer_id": "string",
- "name": "string",
- "type": "gift_card",
- "id": "497f6eca-6276-4993-bfeb-53cbbbba6f08",
- "created_at": "2019-08-24T14:15:22Z",
- "created_by": "1c92f7e1-2897-4d46-bdcc-c127a914fb4e",
- "metadata": {
- "order_id": "xk39592f"
}, - "amount": 50000,
- "currency": "NOK",
- "amount_balance": 50000,
- "amount_available": 50000,
- "active_from": "2019-08-24T14:15:22Z",
- "expires_at": "2019-08-24T14:15:22Z",
- "pin": {
- "format": {
- "length": 36,
- "prefix": "DINCARD:",
- "symbols": true,
- "numbers": true,
- "characters": true,
- "barcode": false
}, - "pin": {
- "value": "012345",
- "barcode_128": "data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAADIA..."
}
}, - "card_token": {
- "format": {
- "length": 36,
- "prefix": "DINCARD:",
- "symbols": true,
- "numbers": true,
- "characters": true,
- "barcode": false
}, - "expires_after_transaction": true,
- "expires_in": 1,
- "token": {
- "value": "DINCARD:6ccfec5d-3a53-47de-910a-97d6dda22e5f",
- "barcode_128": "data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAADIA..."
}
}
}
Get all cards for an account
scopes:
aid required | string <^[PT]{1}\d{8}$> = 9 characters An id that uniquely identifies the account. |
limit | integer [ 1 .. 100 ] Default: 10 A limit on the number of objects to be returned. Limit can range between 1 and 100 items, and the default is 10 items. |
starting_after | string cursor for use in pagination. starting_after is an object ID
that defines your place in the list. For instance, if you make
a list request and receive 100 objects, end the result contains
|
search | string Will try to match the search to either |
created_at.gte | string <isodate> Card created after (ISO 8601. We recommend using a localised ISO 8601 datetime like |
created_at.lte | string <isodate> Card created before a date (ISO 8601. We recommend using a localised ISO 8601 datetime like |
type | string Enum: "gift_card" "credit_note" Filter cards by type |
status | string Enum: "unused" "partially_used" "used" "expired" Filter cards by amount and expiry status |
expired_at.gte | string <isodate> Card expires after (ISO 8601. We recommend using a localised ISO 8601 datetime like |
expired_at.lte | string <isodate> Card expires before a date (ISO 8601. We recommend using a localised ISO 8601 datetime like |
amount | integer Exact card amount |
amount.gte | integer Lower limit for filtering on card amount. |
amount.lte | integer Upper limit for filtering on card amount. |
currency | Array of strings The currency of the card. |
customer | string Filter cards by |
[- {
- "card_id": "string",
- "customer_id": "string",
- "name": "string",
- "type": "gift_card",
- "id": "497f6eca-6276-4993-bfeb-53cbbbba6f08",
- "created_at": "2019-08-24T14:15:22Z",
- "created_by": "1c92f7e1-2897-4d46-bdcc-c127a914fb4e",
- "metadata": {
- "order_id": "xk39592f"
}, - "amount": 50000,
- "currency": "NOK",
- "amount_balance": 50000,
- "amount_available": 50000,
- "active_from": "2019-08-24T14:15:22Z",
- "expires_at": "2019-08-24T14:15:22Z"
}
]
Get all details about a card
scopes:
aid required | string <^[PT]{1}\d{8}$> = 9 characters An id that uniquely identifies the account. |
card_id required | string <= 255 characters The card id you have defined for the card. (must not have trailing or leading spaces) |
{- "card_id": "string",
- "customer_id": "string",
- "name": "string",
- "type": "gift_card",
- "id": "497f6eca-6276-4993-bfeb-53cbbbba6f08",
- "created_at": "2019-08-24T14:15:22Z",
- "created_by": "1c92f7e1-2897-4d46-bdcc-c127a914fb4e",
- "metadata": {
- "order_id": "xk39592f"
}, - "amount": 50000,
- "currency": "NOK",
- "amount_balance": 50000,
- "amount_available": 50000,
- "active_from": "2019-08-24T14:15:22Z",
- "expires_at": "2019-08-24T14:15:22Z",
- "tokens": [
- {
- "expires_at": "2019-08-24T14:15:22Z",
- "masked_code": "DINCARD:********-****-****-91**-*******22e5f"
}
]
}
Create a temporary token
(also referred as Card Code)
for the card, an temporary alias that must be used when
when creating a drawdown transaction
The token can be stored in a barcode to allow use of virtuell card in purchase in POS or webstore
scopes:
aid required | string <^[PT]{1}\d{8}$> = 9 characters An id that uniquely identifies the account. |
card_id required | string <= 255 characters The card id you have defined for the card. (must not have trailing or leading spaces) |
token details
ref_id required | string Unique ref ID provided by the client to support safely retrying requests without accidentally performing the same operation twice All card transaction must have a unique ref ID, but it is not required that the ref ID is globally unique. |
expires_in required | integer >= 1 The lifetime in seconds for the card token. For example, the value "3600" denotes that the token will expire in one hour from the time the response was generated. |
metadata | object A key-value JSON object to store any additional information. The dintero_* namespace for keys is reserved |
object specify the format for to generate | |
expires_after_transaction | boolean Default: true The token can only be used to create one transaction, card lookup by token will be available until token expires by date |
{- "metadata": {
- "order_id": "xk39592f"
}, - "ref_id": "string",
- "format": {
- "length": 36,
- "prefix": "DINCARD:",
- "symbols": true,
- "numbers": true,
- "characters": true,
- "barcode": false
}, - "expires_after_transaction": true,
- "expires_in": 1
}
{- "id": "497f6eca-6276-4993-bfeb-53cbbbba6f08",
- "created_at": "2019-08-24T14:15:22Z",
- "created_by": "1c92f7e1-2897-4d46-bdcc-c127a914fb4e",
- "metadata": {
- "order_id": "xk39592f"
}, - "ref_id": "string",
- "format": {
- "length": 36,
- "prefix": "DINCARD:",
- "symbols": true,
- "numbers": true,
- "characters": true,
- "barcode": false
}, - "expires_after_transaction": true,
- "expires_in": 1,
- "token": {
- "value": "DINCARD:6ccfec5d-3a53-47de-910a-97d6dda22e5f",
- "barcode_128": "data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAADIA..."
}
}
Get details about a card, including the current balance and available funds. No details will be returned for expired tokens
scopes:
aid required | string <^[PT]{1}\d{8}$> = 9 characters An id that uniquely identifies the account. |
token required | string temporary token for a Card |
pin | string PIN for the Card |
{- "token": "string",
- "pin": "string"
}
{- "card_id": "string",
- "customer_id": "string",
- "name": "string",
- "type": "gift_card",
- "id": "497f6eca-6276-4993-bfeb-53cbbbba6f08",
- "created_at": "2019-08-24T14:15:22Z",
- "created_by": "1c92f7e1-2897-4d46-bdcc-c127a914fb4e",
- "metadata": {
- "order_id": "xk39592f"
}, - "amount": 50000,
- "currency": "NOK",
- "amount_balance": 50000,
- "amount_available": 50000,
- "active_from": "2019-08-24T14:15:22Z",
- "expires_at": "2019-08-24T14:15:22Z"
}
Get the cards active for a customer
scopes:
aid required | string <^[PT]{1}\d{8}$> = 9 characters An id that uniquely identifies the account. |
customer_id required | string <= 255 characters The customer id you have defined for the customer. (must not have trailing or leading spaces) |
limit | integer [ 1 .. 100 ] Default: 10 A limit on the number of objects to be returned. Limit can range between 1 and 100 items, and the default is 10 items. |
starting_after | string cursor for use in pagination. starting_after is an object ID
that defines your place in the list. For instance, if you make
a list request and receive 100 objects, end the result contains
|
[- {
- "id": "497f6eca-6276-4993-bfeb-53cbbbba6f08",
- "created_at": "2019-08-24T14:15:22Z",
- "created_by": "1c92f7e1-2897-4d46-bdcc-c127a914fb4e",
- "metadata": {
- "order_id": "xk39592f"
}, - "active_from": "2019-08-24T14:15:22Z",
- "expires_at": "2019-08-24T14:15:22Z",
- "card_id": "string",
- "customer_id": "string",
- "name": "string",
- "type": "gift_card"
}
]
Get all details about a customer card
scopes:
aid required | string <^[PT]{1}\d{8}$> = 9 characters An id that uniquely identifies the account. |
customer_id required | string <= 255 characters The customer id you have defined for the customer. (must not have trailing or leading spaces) |
card_id required | string <= 255 characters The card id you have defined for the card. (must not have trailing or leading spaces) |
{- "id": "497f6eca-6276-4993-bfeb-53cbbbba6f08",
- "created_at": "2019-08-24T14:15:22Z",
- "created_by": "1c92f7e1-2897-4d46-bdcc-c127a914fb4e",
- "metadata": {
- "order_id": "xk39592f"
}, - "active_from": "2019-08-24T14:15:22Z",
- "expires_at": "2019-08-24T14:15:22Z",
- "card_id": "string",
- "customer_id": "string",
- "name": "string",
- "type": "gift_card",
- "tokens": [
- {
- "expires_at": "2019-08-24T14:15:22Z",
- "masked_code": "DINCARD:********-****-****-91**-*******22e5f"
}
], - "amount_balance": 50000,
- "amount_available": 50000,
- "currency": "NOK"
}
Retrieve a list of Card's Transaction based on card id
scopes:
aid required | string <^[PT]{1}\d{8}$> = 9 characters An id that uniquely identifies the account. |
card_id required | string <= 255 characters The card id you have defined for the card. (must not have trailing or leading spaces) |
[- {
- "id": "497f6eca-6276-4993-bfeb-53cbbbba6f08",
- "created_at": "2019-08-24T14:15:22Z",
- "created_by": "1c92f7e1-2897-4d46-bdcc-c127a914fb4e",
- "metadata": {
- "order_id": "xk39592f"
}, - "ref_id": "string",
- "amount": 50000,
- "currency": "NOK",
- "type": "drawdown",
- "parent_id": "1c6ca187-e61f-4301-8dcb-0e9749e89eef"
}
]
Create a transaction against a Card using token
or card_id
.
If the Transactions is created as pending, the value will
be locked until it is either captured or voided. Transaction ID must
be used when capturing or voiding a transaction.
Using
card_id
or creating afund
transaction requires authorization scopeadmin:wallets
orwrite:wallets
scopes:
aid required | string <^[PT]{1}\d{8}$> = 9 characters An id that uniquely identifies the account. |
transaction details
ref_id required | string Unique ref ID provided by the client to support safely retrying requests without accidentally performing the same operation twice All card transaction must have a unique ref ID, but it is not required that the ref ID is globally unique. |
amount required | integer >= 0 Monetary amount in smallest unit for the currency |
currency required | string Enum: "NOK" "SEK" "DKK" "EUR" "USD" The three-character ISO-4217 currency. https://en.wikipedia.org/wiki/ISO_4217 |
token | string required if |
card_id | string required if |
metadata | object A key-value JSON object to store any additional information. The dintero_* namespace for keys is reserved |
type | string Default: "drawdown" Enum: "drawdown" "fund" |
pending | boolean Default: false If true, the transaction will be created as pending, i.e. the value will be locked until it is either captured or voided.
|
{- "token": "string",
- "card_id": "string",
- "metadata": {
- "order_id": "xk39592f"
}, - "ref_id": "string",
- "amount": 50000,
- "currency": "NOK",
- "type": "drawdown",
- "pending": false
}
{- "id": "497f6eca-6276-4993-bfeb-53cbbbba6f08",
- "created_at": "2019-08-24T14:15:22Z",
- "created_by": "1c92f7e1-2897-4d46-bdcc-c127a914fb4e",
- "metadata": {
- "order_id": "xk39592f"
}, - "ref_id": "string",
- "amount": 50000,
- "currency": "NOK",
- "type": "drawdown",
- "parent_id": "1c6ca187-e61f-4301-8dcb-0e9749e89eef"
}
Capture a pending Transaction, thereby collection the amount withheld by the pending transaction.
Option to specify an amount that should be captured. Defaults to capture the full transaction. When the amount specified is less than the reserved/pending, the remaining amount will still be reserved/pending and can be captured later.
scopes:
aid required | string <^[PT]{1}\d{8}$> = 9 characters An id that uniquely identifies the account. |
transaction_id required | string <uuid> An id that uniqely idetifies a transaction |
capture details
ref_id required | string Unique ref ID provided by the client to support safely retrying requests without accidentally performing the same operation twice All card transaction must have a unique ref ID, but it is not required that the ref ID is globally unique. |
metadata | object A key-value JSON object to store any additional information. The dintero_* namespace for keys is reserved |
amount | integer >= 0 Monetary amount in smallest unit for the currency |
{- "metadata": {
- "order_id": "xk39592f"
}, - "ref_id": "string",
- "amount": 50000
}
{- "id": "497f6eca-6276-4993-bfeb-53cbbbba6f08",
- "created_at": "2019-08-24T14:15:22Z",
- "created_by": "1c92f7e1-2897-4d46-bdcc-c127a914fb4e",
- "metadata": {
- "order_id": "xk39592f"
}, - "ref_id": "string",
- "amount": 50000,
- "currency": "NOK",
- "type": "drawdown",
- "parent_id": "1c6ca187-e61f-4301-8dcb-0e9749e89eef"
}
Void a pending Transaction by unlocking the amount withheld by the pending transaction
scopes:
aid required | string <^[PT]{1}\d{8}$> = 9 characters An id that uniquely identifies the account. |
transaction_id required | string <uuid> An id that uniqely idetifies a transaction |
void details
ref_id required | string Unique ref ID provided by the client to support safely retrying requests without accidentally performing the same operation twice All card transaction must have a unique ref ID, but it is not required that the ref ID is globally unique. |
metadata | object A key-value JSON object to store any additional information. The dintero_* namespace for keys is reserved |
{- "metadata": {
- "order_id": "xk39592f"
}, - "ref_id": "string"
}
{- "id": "497f6eca-6276-4993-bfeb-53cbbbba6f08",
- "created_at": "2019-08-24T14:15:22Z",
- "created_by": "1c92f7e1-2897-4d46-bdcc-c127a914fb4e",
- "metadata": {
- "order_id": "xk39592f"
}, - "ref_id": "string",
- "amount": 50000,
- "currency": "NOK",
- "type": "drawdown",
- "parent_id": "1c6ca187-e61f-4301-8dcb-0e9749e89eef"
}
Get all sales locations, the starting_after have to be set to location_id scopes:
aid required | string <^[PT]{1}\d{8}$> = 9 characters An id that uniquely identifies the account. |
limit | integer [ 1 .. 100 ] Default: 10 A limit on the number of objects to be returned. Limit can range between 1 and 100 items, and the default is 10 items. |
starting_after | string cursor for use in pagination. starting_after is an object ID
that defines your place in the list. For instance, if you make
a list request and receive 100 objects, end the result contains
|
search | string lookup locations where search term match name, phone_number, email, organization_number and business_name |
status | Array of strings filter locations by status |
country | Array of strings filter locations by country |
phone_number | Array of strings filter locations by phone_number |
organization_number | Array of strings filter locations by organization_number |
Array of strings filter locations by email | |
type | Array of strings filter locations by type |
[- {
- "id": "497f6eca-6276-4993-bfeb-53cbbbba6f08",
- "created_at": "2019-08-24T14:15:22Z",
- "created_by": "1c92f7e1-2897-4d46-bdcc-c127a914fb4e",
- "updated_at": "2019-08-24T14:15:22Z",
- "deleted_by": "1c92f7e1-2897-4d46-bdcc-c127a914fb4e",
- "deleted_at": "2019-08-24T14:15:22Z",
- "location_id": "S01923",
- "name": "TKP Store",
- "timezone": "Europe/Oslo",
- "status": "Active",
- "language_code": "string",
- "currency": "NOK",
- "phone_number": "+4799999999",
- "chain": "SuperChain",
- "email": "saleslocation@example.com",
- "mcc": "5814",
- "gln": "string",
- "organization_number": "123456789MVA",
- "business_name": "TKP technology AS",
- "franchise": "Subway",
- "type": "string",
- "website_url": "string",
- "address": {
- "address_line": "Sommerkroveien 34",
- "address_line_2": "PB 123",
- "postal_code": "0349",
- "postal_place": "Oslo",
- "country": "NO",
- "latitude": 0,
- "longitude": 0
}
}
]
Create a sales location scopes:
aid required | string <^[PT]{1}\d{8}$> = 9 characters An id that uniquely identifies the account. |
location to create
location_id | string <= 255 characters The id you have defined for the sales location. (must not have trailing or leading spaces). An auto-generated location_id will be created if no location_id is provided |
name | string The location's trade name which is shown to its customers (receipt/signs) |
timezone | string The location's timezone (IANA Timezone) |
status | string The location's status |
language_code | string Language code of the localized company info, as defined by BCP 47 (IETF BCP 47, "Tags for Identifying Languages"). |
currency | string The three-character ISO-4217 currency. https://en.wikipedia.org/wiki/ISO_4217 |
phone_number | string <^\+?[1-9]\d{1,14}$> A phone number in E.164 number formatting. |
chain | string |
string | |
mcc | string <iso-18245> [ 4 .. 4 ] A four-digit Merchant Category Code (MCC) for the store ISO 18245:2003 |
gln | string Company Global Location Number |
organization_number | string Company identification number |
business_name | string The location's legal name |
franchise | string The location is part of a franchise. |
type | string The location type (Physical, Mobile) |
website_url | string The location's website |
object |
{- "name": "TKP Store",
- "timezone": "Europe/Oslo",
- "status": "Active",
- "language_code": "string",
- "currency": "NOK",
- "phone_number": "+4799999999",
- "chain": "SuperChain",
- "email": "saleslocation@example.com",
- "mcc": "5814",
- "gln": "string",
- "organization_number": "123456789MVA",
- "business_name": "TKP technology AS",
- "franchise": "Subway",
- "type": "string",
- "website_url": "string",
- "address": {
- "address_line": "Sommerkroveien 34",
- "address_line_2": "PB 123",
- "postal_code": "0349",
- "postal_place": "Oslo",
- "country": "NO",
- "latitude": 0,
- "longitude": 0
}
}
{- "id": "497f6eca-6276-4993-bfeb-53cbbbba6f08",
- "created_at": "2019-08-24T14:15:22Z",
- "created_by": "1c92f7e1-2897-4d46-bdcc-c127a914fb4e",
- "updated_at": "2019-08-24T14:15:22Z",
- "deleted_by": "1c92f7e1-2897-4d46-bdcc-c127a914fb4e",
- "deleted_at": "2019-08-24T14:15:22Z",
- "location_id": "S01923",
- "name": "TKP Store",
- "timezone": "Europe/Oslo",
- "status": "Active",
- "language_code": "string",
- "currency": "NOK",
- "phone_number": "+4799999999",
- "chain": "SuperChain",
- "email": "saleslocation@example.com",
- "mcc": "5814",
- "gln": "string",
- "organization_number": "123456789MVA",
- "business_name": "TKP technology AS",
- "franchise": "Subway",
- "type": "string",
- "website_url": "string",
- "address": {
- "address_line": "Sommerkroveien 34",
- "address_line_2": "PB 123",
- "postal_code": "0349",
- "postal_place": "Oslo",
- "country": "NO",
- "latitude": 0,
- "longitude": 0
}
}
Get single sales location scopes:
aid required | string <^[PT]{1}\d{8}$> = 9 characters An id that uniquely identifies the account. |
lid required | string <= 255 characters location id |
{- "id": "497f6eca-6276-4993-bfeb-53cbbbba6f08",
- "created_at": "2019-08-24T14:15:22Z",
- "created_by": "1c92f7e1-2897-4d46-bdcc-c127a914fb4e",
- "updated_at": "2019-08-24T14:15:22Z",
- "deleted_by": "1c92f7e1-2897-4d46-bdcc-c127a914fb4e",
- "deleted_at": "2019-08-24T14:15:22Z",
- "location_id": "S01923",
- "name": "TKP Store",
- "timezone": "Europe/Oslo",
- "status": "Active",
- "language_code": "string",
- "currency": "NOK",
- "phone_number": "+4799999999",
- "chain": "SuperChain",
- "email": "saleslocation@example.com",
- "mcc": "5814",
- "gln": "string",
- "organization_number": "123456789MVA",
- "business_name": "TKP technology AS",
- "franchise": "Subway",
- "type": "string",
- "website_url": "string",
- "address": {
- "address_line": "Sommerkroveien 34",
- "address_line_2": "PB 123",
- "postal_code": "0349",
- "postal_place": "Oslo",
- "country": "NO",
- "latitude": 0,
- "longitude": 0
}
}
Update location properties scopes:
aid required | string <^[PT]{1}\d{8}$> = 9 characters An id that uniquely identifies the account. |
lid required | string <= 255 characters location id |
Location update
name | string The location's trade name which is shown to its customers (receipt/signs) |
timezone | string The location's timezone (IANA Timezone) |
status | string The location's status |
language_code | string Language code of the localized company info, as defined by BCP 47 (IETF BCP 47, "Tags for Identifying Languages"). |
currency | string The three-character ISO-4217 currency. https://en.wikipedia.org/wiki/ISO_4217 |
phone_number | string <^\+?[1-9]\d{1,14}$> A phone number in E.164 number formatting. |
chain | string |
string | |
mcc | string <iso-18245> [ 4 .. 4 ] A four-digit Merchant Category Code (MCC) for the store ISO 18245:2003 |
gln | string Company Global Location Number |
organization_number | string Company identification number |
business_name | string The location's legal name |
franchise | string The location is part of a franchise. |
type | string The location type (Physical, Mobile) |
website_url | string The location's website |
object |
{- "name": "TKP Store",
- "timezone": "Europe/Oslo",
- "status": "Active",
- "language_code": "string",
- "currency": "NOK",
- "phone_number": "+4799999999",
- "chain": "SuperChain",
- "email": "saleslocation@example.com",
- "mcc": "5814",
- "gln": "string",
- "organization_number": "123456789MVA",
- "business_name": "TKP technology AS",
- "franchise": "Subway",
- "type": "string",
- "website_url": "string",
- "address": {
- "address_line": "Sommerkroveien 34",
- "address_line_2": "PB 123",
- "postal_code": "0349",
- "postal_place": "Oslo",
- "country": "NO",
- "latitude": 0,
- "longitude": 0
}
}
{- "id": "497f6eca-6276-4993-bfeb-53cbbbba6f08",
- "created_at": "2019-08-24T14:15:22Z",
- "created_by": "1c92f7e1-2897-4d46-bdcc-c127a914fb4e",
- "updated_at": "2019-08-24T14:15:22Z",
- "deleted_by": "1c92f7e1-2897-4d46-bdcc-c127a914fb4e",
- "deleted_at": "2019-08-24T14:15:22Z",
- "location_id": "S01923",
- "name": "TKP Store",
- "timezone": "Europe/Oslo",
- "status": "Active",
- "language_code": "string",
- "currency": "NOK",
- "phone_number": "+4799999999",
- "chain": "SuperChain",
- "email": "saleslocation@example.com",
- "mcc": "5814",
- "gln": "string",
- "organization_number": "123456789MVA",
- "business_name": "TKP technology AS",
- "franchise": "Subway",
- "type": "string",
- "website_url": "string",
- "address": {
- "address_line": "Sommerkroveien 34",
- "address_line_2": "PB 123",
- "postal_code": "0349",
- "postal_place": "Oslo",
- "country": "NO",
- "latitude": 0,
- "longitude": 0
}
}
Delete single location scopes:
aid required | string <^[PT]{1}\d{8}$> = 9 characters An id that uniquely identifies the account. |
lid required | string <= 255 characters location id |
{- "id": "497f6eca-6276-4993-bfeb-53cbbbba6f08",
- "created_at": "2019-08-24T14:15:22Z",
- "created_by": "1c92f7e1-2897-4d46-bdcc-c127a914fb4e",
- "updated_at": "2019-08-24T14:15:22Z",
- "deleted_by": "1c92f7e1-2897-4d46-bdcc-c127a914fb4e",
- "deleted_at": "2019-08-24T14:15:22Z",
- "location_id": "S01923",
- "name": "TKP Store",
- "timezone": "Europe/Oslo",
- "status": "Active",
- "language_code": "string",
- "currency": "NOK",
- "phone_number": "+4799999999",
- "chain": "SuperChain",
- "email": "saleslocation@example.com",
- "mcc": "5814",
- "gln": "string",
- "organization_number": "123456789MVA",
- "business_name": "TKP technology AS",
- "franchise": "Subway",
- "type": "string",
- "website_url": "string",
- "address": {
- "address_line": "Sommerkroveien 34",
- "address_line_2": "PB 123",
- "postal_code": "0349",
- "postal_place": "Oslo",
- "country": "NO",
- "latitude": 0,
- "longitude": 0
}
}
When you create a new webhook, we'll send you a simple ping event to let you know you've set up the webhook correctly. You can trigger a ping again by calling the ping endpoint.
In order for Dintero to send webhook payloads, your server needs to be accessible from the Internet. We also highly suggest using SSL so that we can send encrypted payloads over HTTPS.
Your webhook acknowledges that it received data by sending a 200 OK response. Any response outside of the 200 range will let Dintero know that you did not receive your webhook, including 301 Redirect. Dintero does not follow redirects for webhook notifications and will consider a redirection as an error response.
Dintero has implemented a 60-second timeout period and a retry period for subscriptions. We wait 120 seconds for a response to each request, and if there isn't one or we get an error, we retry the connection to a total of 5 times. A webhook will be deleted if there are consecutive failures for the exact same webhook. You should monitor the admin of your webhook tool for failing webhooks.
Dintero will send along several HTTP headers to differentiate between event types and payload identifiers.
Name | Description |
---|---|
event | The event type |
event-delivery | A guid to indentify the payload and event being sent |
event-signature | The value of this header is computed as the HMAC SHA1 hex digest of the body, using the secret config option as the key. |
scopes:
aid required | string <^[PT]{1}\d{8}$> = 9 characters An id that uniquely identifies the account. |
subscription configuration
required | object |
events required | Array of strings[ items non-empty ] Items Enum: "account_add" "account_update" "receipt_add" "receipt_update" "customer_add" "customer_update" "customer_delete" "customer_change_password" "token_add" "token_remove" "transaction" "wallet_transaction" "discount_add" "discount_update" "discount_delete" "discount_add_customers" "discount_customer_update" "shopping_draft_add" "shopping_draft_update" "shopping_draft_complete" "shopping_order_update" "shopping_order_event_add" "shopping_order_delete" "settlement_add" "location_add" "location_delete" "location_update" "cdd_case_update" "approval_payout_destination_update" "approval_payout_destination_delete" "checkout_transaction" |
active | boolean Default: true Determines whether the hook is actually triggered. |
fields | string <field-mask> Limit the event data included in the delivery The syntax is loosely based on XPath:
|
{- "active": true,
- "config": {
- "url": "string",
- "content_type": "application/json",
- "secret": {
- "type": "HMAC-SHA1"
}, - "insecure_ssl": 0
}, - "fields": "account(partner_id,account_id,created_at)",
- "events": [
- "account_add"
]
}
{- "id": "497f6eca-6276-4993-bfeb-53cbbbba6f08",
- "created_at": "2019-08-24T14:15:22Z",
- "created_by": "1c92f7e1-2897-4d46-bdcc-c127a914fb4e",
- "updated_at": "2019-08-24T14:15:22Z",
- "deleted_by": "1c92f7e1-2897-4d46-bdcc-c127a914fb4e",
- "deleted_at": "2019-08-24T14:15:22Z",
- "active": true,
- "config": {
- "url": "string",
- "content_type": "application/json",
- "secret": {
- "type": "HMAC-SHA1"
}, - "insecure_ssl": 0
}, - "fields": "account(partner_id,account_id,created_at)",
- "events": [
- "account_add"
]
}
Get all subscriptions
scopes:
aid required | string <^[PT]{1}\d{8}$> = 9 characters An id that uniquely identifies the account. |
include_deleted | boolean Default: false include deleted subscriptions in the response. |
limit | integer [ 1 .. 100 ] Default: 10 A limit on the number of objects to be returned. Limit can range between 1 and 100 items, and the default is 10 items. |
starting_after | string cursor for use in pagination. starting_after is an object ID
that defines your place in the list. For instance, if you make
a list request and receive 100 objects, end the result contains
|
total | boolean Default: false include |
[- {
- "id": "497f6eca-6276-4993-bfeb-53cbbbba6f08",
- "created_at": "2019-08-24T14:15:22Z",
- "created_by": "1c92f7e1-2897-4d46-bdcc-c127a914fb4e",
- "updated_at": "2019-08-24T14:15:22Z",
- "deleted_by": "1c92f7e1-2897-4d46-bdcc-c127a914fb4e",
- "deleted_at": "2019-08-24T14:15:22Z",
- "active": true,
- "config": {
- "url": "string",
- "content_type": "application/json",
- "secret": {
- "type": "HMAC-SHA1"
}, - "insecure_ssl": 0
}, - "fields": "account(partner_id,account_id,created_at)",
- "events": [
- "account_add"
]
}
]
Get subscription details
scopes:
aid required | string <^[PT]{1}\d{8}$> = 9 characters An id that uniquely identifies the account. |
hid required | string <uuid> subscription id |
{- "id": "497f6eca-6276-4993-bfeb-53cbbbba6f08",
- "created_at": "2019-08-24T14:15:22Z",
- "created_by": "1c92f7e1-2897-4d46-bdcc-c127a914fb4e",
- "updated_at": "2019-08-24T14:15:22Z",
- "deleted_by": "1c92f7e1-2897-4d46-bdcc-c127a914fb4e",
- "deleted_at": "2019-08-24T14:15:22Z",
- "active": true,
- "config": {
- "url": "string",
- "content_type": "application/json",
- "secret": {
- "type": "HMAC-SHA1"
}, - "insecure_ssl": 0
}, - "fields": "account(partner_id,account_id,created_at)",
- "events": [
- "account_add"
]
}
Delete a webhook subscription
No more events will be sent to the webhook
scopes:
aid required | string <^[PT]{1}\d{8}$> = 9 characters An id that uniquely identifies the account. |
hid required | string <uuid> subscription id |
{- "id": "497f6eca-6276-4993-bfeb-53cbbbba6f08",
- "created_at": "2019-08-24T14:15:22Z",
- "created_by": "1c92f7e1-2897-4d46-bdcc-c127a914fb4e",
- "updated_at": "2019-08-24T14:15:22Z",
- "deleted_by": "1c92f7e1-2897-4d46-bdcc-c127a914fb4e",
- "deleted_at": "2019-08-24T14:15:22Z",
- "active": true,
- "config": {
- "url": "string",
- "content_type": "application/json",
- "secret": {
- "type": "HMAC-SHA1"
}, - "insecure_ssl": 0
}, - "fields": "account(partner_id,account_id,created_at)",
- "events": [
- "account_add"
]
}
Get recent subscription deliveries
scopes:
aid required | string <^[PT]{1}\d{8}$> = 9 characters An id that uniquely identifies the account. |
hid required | string <uuid> subscription id |
[- {
- "id": "string",
- "event_delivery": "string",
- "created_at": "2019-08-24T14:15:22Z",
- "status": 200
}
]
Get subscription delivery details
scopes:
aid required | string <^[PT]{1}\d{8}$> = 9 characters An id that uniquely identifies the account. |
hid required | string <uuid> subscription id |
delivery_id required | string delivery id |
{- "id": "string",
- "event_delivery": "string",
- "created_at": "2019-08-24T14:15:22Z",
- "status": 200,
- "url": "string",
- "request": {
- "headers": {
- "event": "string",
- "event-delivery": "string",
- "event-signature": "string"
}, - "body": { }
}, - "response": {
- "headers": { },
- "body": "string"
}, - "details": {
- "delivery_at": "2019-08-24T14:15:22Z",
- "delivery_duration": 848,
- "delivery_success": true
}
}
This will trigger a ping event to be sent to the subscription URL.
POST /
User-Agent: Dintero-Hook/0c9ad03b
Content-Type: application/json
event: ping
event-delivery: cfedde7e-b088-415e-ad5b-cbe54acbb6f9
{
"created_at": "2017-12-06T15:36:43Z",
"created_by": "1c92f7e1-2897-4d46-bdcc-c127a914fb4e",
"id": "string",
"updated_at": "2017-12-06T15:36:43Z",
"active": true,
"config": {
"content_type": "application/json",
"insecure_ssl": 0,
"secret": { ... }
"url": "string"
},
"events": ["receipt_add"]
}
scopes:
aid required | string <^[PT]{1}\d{8}$> = 9 characters An id that uniquely identifies the account. |
hid required | string <uuid> subscription id |
{- "error": {
- "code": "string",
- "errors": [
- { }
], - "message": "string"
}
}
Endpoint intended for Dintero frontend to report any error raised during operation
account_id | string |
request_id | string request-id received from Dintero API request |
client_session_id | string frontend session id |
Array of objects Additional metadata about the error event | |
message | string |
error | string |
{- "account_id": "string",
- "request_id": "string",
- "client_session_id": "string",
- "metadata": [
- {
- "key": "origin",
- "value": "iframe"
},
], - "message": "string",
- "error": "string"
}
{- "error": {
- "code": "string",
- "errors": [
- { }
], - "message": "string"
}
}