POS
A Point of Sale represents a physical device for selling tickets at a venue.
The POS object
Required attributes
- Name
_id- Type
- string
- Description
The ID of the POS
- Name
active- Type
- boolean
- Description
Whether the POS is active or not
- Name
name- Type
- string
- Description
The name of the POS
- Name
posNo- Type
- string
- Description
The number of the POS
- Name
printingType- Type
- enum(EXTERNAL, DIRECT)
- Description
The printing type of the POS. DIRECT = direct printing. EXTERNAL = extenral printing.
Optional attributes
- Name
sellerId- Type
- string
- Description
The ID of the seller owning this POS
- Name
restrictions- Type
- object
- Description
Restrictions of the POS
Optional nested attributes (9)
- Name
restrictXReportAccess- Type
- boolean
- Description
Whether the code must be inserted in order to see the x reports
- Name
restrictZReportAccess- Type
- boolean
- Description
Whether the code must be inserted in order to generate a z report and to finish the session
- Name
restrictDashboardAccess- Type
- boolean
- Description
Whether the POS user can see the dashboard
- Name
restrictInstantCancellation- Type
- boolean
- Description
Whether POS user can cancel a transaction immediately
- Name
code- Type
- string
- Description
Code to unlock x and z reports if restricted
- Name
restrictEventAccess- Type
- boolean
- Description
Whether the POS user can only choose specific events and/or specific secret shops
- Name
restrictPurchaseIntents- Type
- boolean
- Description
Whether the POS user can manage purchase intents
- Name
restrictCustomerAccess- Type
- boolean
- Description
Whether the POS user can manage customers and select them during transactions
- Name
allowedEvents- Type
- array<string>
- Description
An array of IDs of allowed events
- Name
signature- Type
- object
- Description
POS signature settings
Optional nested attributes (1)
- Name
fiskaly- Type
- object
- Description
Fiskaly settings
Optional nested attributes (3)
- Name
tssId- Type
- string
- Description
The ID of the TSS
- Name
clientId- Type
- string
- Description
The ID of the client
- Name
state- Type
- enum(UNINITIALIZED, INITIALIZED, DISABLED)
- Description
The state of the TSS
- Name
state- Type
- enum(disabled, active)
- Description
The state of the POS
- Name
createdAt- Type
- string
- Description
An ISO timestamp indicating when the POS was created
- Name
updatedAt- Type
- string
- Description
An ISO timestamp indicating when the POS was updated
Example
{
"_id": "507f191e810c19729de860ea",
"active": true,
"name": "Example Name",
"posNo": "string",
"printingType": "EXTERNAL",
"sellerId": "507f191e810c19729de860ea",
"restrictions": {
"restrictXReportAccess": true,
"restrictZReportAccess": true,
"restrictDashboardAccess": true,
"restrictInstantCancellation": true,
"code": "string",
"restrictEventAccess": true,
"restrictPurchaseIntents": true,
"restrictCustomerAccess": true,
"allowedEvents": [
"string"
]
},
"signature": {
"fiskaly": {
"tssId": "507f191e810c19729de860ea",
"clientId": "507f191e810c19729de860ea",
"state": "UNINITIALIZED"
}
},
"state": "disabled",
"createdAt": "2030-01-23T23:00:00.123Z",
"updatedAt": "2030-01-23T23:00:00.123Z"
}Create a POS
Create a POS
Payload
Required attributes
- Name
name- Type
- string
- Description
- Name
printingType- Type
- string
- Description
Optional attributes
- Name
posNo- Type
- string
- Description
Request
const response = await fetch('https://vivenu.com/api/pos', {
method: 'POST',
headers: {
Authorization: 'Bearer {token}',
'Content-Type': 'application/json',
},
body: JSON.stringify( {
"name": "Example Name",
"printingType": "string",
"posNo": "string"
}),
})
const data = await response.json()Response (201)
{
"_id": "507f191e810c19729de860ea",
"active": true,
"name": "Example Name",
"posNo": "string",
"printingType": "EXTERNAL",
"sellerId": "507f191e810c19729de860ea",
"restrictions": {
"restrictXReportAccess": true,
"restrictZReportAccess": true,
"restrictDashboardAccess": true,
"restrictInstantCancellation": true,
"code": "string",
"restrictEventAccess": true,
"restrictPurchaseIntents": true,
"restrictCustomerAccess": true,
"allowedEvents": [
"string"
]
},
"signature": {
"fiskaly": {
"tssId": "507f191e810c19729de860ea",
"clientId": "507f191e810c19729de860ea",
"state": "UNINITIALIZED"
}
},
"state": "disabled",
"createdAt": "2030-01-23T23:00:00.123Z",
"updatedAt": "2030-01-23T23:00:00.123Z"
}Update POS
Update POS
Payload
Required attributes
- Name
name- Type
- string
- Description
- Name
posNo- Type
- string
- Description
- Name
active- Type
- boolean
- Description
- Name
printingType- Type
- string
- Description
Optional attributes
- Name
restrictions- Type
- object
- Description
Optional nested attributes (10)
- Name
restrictXReportAccess- Type
- boolean
- Description
- Name
restrictZReportAccess- Type
- boolean
- Description
- Name
code- Type
- string
- Description
- Name
restrictDashboardAccess- Type
- boolean
- Description
- Name
restrictInstantCancellation- Type
- boolean
- Description
- Name
restrictEventAccess- Type
- boolean
- Description
- Name
restrictPurchaseIntents- Type
- boolean
- Description
- Name
restrictCustomerAccess- Type
- boolean
- Description
- Name
allowedEvents- Type
- array<oneOf>
- Description
- Name
allowedPaymentMethods- Type
- array<string>
- Description
Request
const response = await fetch('https://vivenu.com/api/pos/507f191e810c19729de860ea', {
method: 'PUT',
headers: {
Authorization: 'Bearer {token}',
'Content-Type': 'application/json',
},
body: JSON.stringify( {
"name": "Example Name",
"posNo": "string",
"active": true,
"printingType": "string",
"restrictions": {
"restrictXReportAccess": true,
"restrictZReportAccess": true,
"code": "string",
"restrictDashboardAccess": true,
"restrictInstantCancellation": true,
"restrictEventAccess": true,
"restrictPurchaseIntents": true,
"restrictCustomerAccess": true,
"allowedEvents": [
"string"
],
"allowedPaymentMethods": [
"cash",
"ec",
"creditcard"
]
}
}),
})
const data = await response.json()Response (200)
{
"_id": "507f191e810c19729de860ea",
"active": true,
"name": "Example Name",
"posNo": "string",
"printingType": "EXTERNAL",
"sellerId": "507f191e810c19729de860ea",
"restrictions": {
"restrictXReportAccess": true,
"restrictZReportAccess": true,
"restrictDashboardAccess": true,
"restrictInstantCancellation": true,
"code": "string",
"restrictEventAccess": true,
"restrictPurchaseIntents": true,
"restrictCustomerAccess": true,
"allowedEvents": [
"string"
]
},
"signature": {
"fiskaly": {
"tssId": "507f191e810c19729de860ea",
"clientId": "507f191e810c19729de860ea",
"state": "UNINITIALIZED"
}
},
"state": "disabled",
"createdAt": "2030-01-23T23:00:00.123Z",
"updatedAt": "2030-01-23T23:00:00.123Z"
}Get POS
Get POS
Request
const response = await fetch('https://vivenu.com/api/pos/507f191e810c19729de860ea', {
method: 'GET',
headers: {
Authorization: 'Bearer {token}',
},
})
const data = await response.json()Response (200)
{
"_id": "507f191e810c19729de860ea",
"active": true,
"name": "Example Name",
"posNo": "string",
"printingType": "EXTERNAL",
"sellerId": "507f191e810c19729de860ea",
"restrictions": {
"restrictXReportAccess": true,
"restrictZReportAccess": true,
"restrictDashboardAccess": true,
"restrictInstantCancellation": true,
"code": "string",
"restrictEventAccess": true,
"restrictPurchaseIntents": true,
"restrictCustomerAccess": true,
"allowedEvents": [
"string"
]
},
"signature": {
"fiskaly": {
"tssId": "507f191e810c19729de860ea",
"clientId": "507f191e810c19729de860ea",
"state": "UNINITIALIZED"
}
},
"state": "disabled",
"createdAt": "2030-01-23T23:00:00.123Z",
"updatedAt": "2030-01-23T23:00:00.123Z"
}Get all POS
Get all POS
Query parameters
Optional query parameters
- Name
top- Type
- number
- Description
- Name
skip- Type
- number
- Description
- Name
sellerId- Type
- string
- Description
Request
const response = await fetch('https://vivenu.com/api/pos?top=10.5&skip=10.5&sellerId=507f191e810c19729de860ea', {
method: 'GET',
headers: {
Authorization: 'Bearer {token}',
},
})
const data = await response.json()Response (200)
[]Disable POS
Disable POS
Request
const response = await fetch('https://vivenu.com/api/pos/507f191e810c19729de860ea/disable', {
method: 'POST',
headers: {
Authorization: 'Bearer {token}',
},
})
const data = await response.json()Response (200)
{
"_id": "507f191e810c19729de860ea",
"active": true,
"name": "Example Name",
"posNo": "string",
"printingType": "EXTERNAL",
"sellerId": "507f191e810c19729de860ea",
"restrictions": {
"restrictXReportAccess": true,
"restrictZReportAccess": true,
"restrictDashboardAccess": true,
"restrictInstantCancellation": true,
"code": "string",
"restrictEventAccess": true,
"restrictPurchaseIntents": true,
"restrictCustomerAccess": true,
"allowedEvents": [
"string"
]
},
"signature": {
"fiskaly": {
"tssId": "507f191e810c19729de860ea",
"clientId": "507f191e810c19729de860ea",
"state": "UNINITIALIZED"
}
},
"state": "disabled",
"createdAt": "2030-01-23T23:00:00.123Z",
"updatedAt": "2030-01-23T23:00:00.123Z"
}Get POS sessions
Get POS sessions
Request
const response = await fetch('https://vivenu.com/api/pos/507f191e810c19729de860ea/sessions', {
method: 'GET',
headers: {
Authorization: 'Bearer {token}',
},
})
const data = await response.json()Response (200)
[]Get POS journal logs
Get POS journal logs
Query parameters
Optional query parameters
- Name
top- Type
- number
- Description
- Name
skip- Type
- number
- Description
- Name
type- Type
- enum(SALE, CANCELLATION, SESSION_CREATED, SESSION_CLOSED)
- Description
- Name
referenceId- Type
- string
- Description
Request
const response = await fetch('https://vivenu.com/api/pos/507f191e810c19729de860ea/logs?top=10.5&skip=10.5&type=SALE&referenceId=507f191e810c19729de860ea', {
method: 'GET',
headers: {
Authorization: 'Bearer {token}',
},
})
const data = await response.json()Response (200)
{
"rows": [],
"total": 1
}Export POS journal logs
Export POS journal logs
Query parameters
Required query parameters
- Name
start- Type
- string
- Description
- Name
end- Type
- string
- Description
Request
const response = await fetch('https://vivenu.com/api/pos/507f191e810c19729de860ea/export/journallogs?start=value&end=value', {
method: 'GET',
headers: {
Authorization: 'Bearer {token}',
},
})
const data = await response.json()Export POS cancellations
Export POS cancellations
Query parameters
Required query parameters
- Name
start- Type
- string
- Description
- Name
end- Type
- string
- Description
Request
const response = await fetch('https://vivenu.com/api/pos/507f191e810c19729de860ea/export/cancellations?start=value&end=value', {
method: 'GET',
headers: {
Authorization: 'Bearer {token}',
},
})
const data = await response.json()Export POS orders
Export POS orders
Query parameters
Required query parameters
- Name
start- Type
- string
- Description
- Name
end- Type
- string
- Description
Request
const response = await fetch('https://vivenu.com/api/pos/507f191e810c19729de860ea/export/orders?start=value&end=value', {
method: 'GET',
headers: {
Authorization: 'Bearer {token}',
},
})
const data = await response.json()Export POS order items
Export POS order items
Query parameters
Required query parameters
- Name
start- Type
- string
- Description
- Name
end- Type
- string
- Description
Request
const response = await fetch('https://vivenu.com/api/pos/507f191e810c19729de860ea/export/orderitems?start=value&end=value', {
method: 'GET',
headers: {
Authorization: 'Bearer {token}',
},
})
const data = await response.json()Export POS order discounts
Export POS order discounts
Query parameters
Required query parameters
- Name
start- Type
- string
- Description
- Name
end- Type
- string
- Description
Request
const response = await fetch('https://vivenu.com/api/pos/507f191e810c19729de860ea/export/orderdiscounts?start=value&end=value', {
method: 'GET',
headers: {
Authorization: 'Bearer {token}',
},
})
const data = await response.json()