Scans
Scans are created by checkin or checkout via the vivenu app or by third party systems that checkin customers and are integrated with vivenu.
Base URL: https://portier.vivenu.com/api or https://portier.vivenu.dev/api
The scan object
Required attributes
- Name
ticketId- Type
- string
- Description
- Name
eventId- Type
- string
- Description
- Name
barcode- Type
- string
- Description
- Name
ticketTypeId- Type
- string
- Description
- Name
type- Type
- enum(checkin, checkout)
- Description
- Name
scanResult- Type
- enum(approved, declined)
- Description
Optional attributes
- Name
_id- Type
- string
- Description
- Name
time- Type
- string
- Description
- Name
parentEventId- Type
- string
- Description
- Name
name- Type
- string
- Description
- Name
ticketName- Type
- string
- Description
- Name
deviceId- Type
- string
- Description
- Name
sellerId- Type
- string
- Description
- Name
scanZoneId- Type
- string
- Description
Example
{
"ticketId": "507f191e810c19729de860ea",
"eventId": "507f191e810c19729de860ea",
"barcode": "string",
"ticketTypeId": "507f191e810c19729de860ea",
"type": "checkin",
"scanResult": "approved",
"_id": "507f191e810c19729de860ea",
"time": "2030-01-23T23:00:00.123Z",
"parentEventId": "507f191e810c19729de860ea",
"name": "Example Name",
"ticketName": "string",
"deviceId": "507f191e810c19729de860ea",
"sellerId": "507f191e810c19729de860ea",
"scanZoneId": "507f191e810c19729de860ea"
}POST/api/scans
Create a Scan
Create a Scan
Request
POST
/api/scansconst response = await fetch('https://portier.vivenu.com/api/scans', {
method: 'POST',
headers: {
Authorization: 'Bearer {token}',
'Content-Type': 'application/json',
},
body: JSON.stringify( [
{
"ticketId": "507f191e810c19729de860ea",
"eventId": "507f191e810c19729de860ea",
"barcode": "string",
"ticketTypeId": "507f191e810c19729de860ea",
"type": "checkin",
"scanResult": "approved",
"_id": "507f191e810c19729de860ea",
"time": "2030-01-23T23:00:00.123Z",
"parentEventId": "507f191e810c19729de860ea",
"name": "Example Name",
"ticketName": "string",
"deviceId": "507f191e810c19729de860ea",
"sellerId": "507f191e810c19729de860ea",
"scanZoneId": "507f191e810c19729de860ea"
}
]),
})
const data = await response.json()Response (200)
{
"ticketId": "507f191e810c19729de860ea",
"eventId": "507f191e810c19729de860ea",
"barcode": "string",
"ticketTypeId": "507f191e810c19729de860ea",
"type": "checkin",
"scanResult": "approved",
"_id": "507f191e810c19729de860ea",
"time": "2030-01-23T23:00:00.123Z",
"parentEventId": "507f191e810c19729de860ea",
"name": "Example Name",
"ticketName": "string",
"deviceId": "507f191e810c19729de860ea",
"sellerId": "507f191e810c19729de860ea",
"scanZoneId": "507f191e810c19729de860ea"
}GET/api/scans
Get Scans
Get Scans
Query parameters
Optional query parameters
- Name
eventId- Type
- string
- Description
- Name
parentEventId- Type
- string
- Description
- Name
time- Type
- object
- Description
- Name
barcode- Type
- string
- Description
- Name
type- Type
- enum(checkin, checkout)
- Description
- Name
scanResult- Type
- enum(approved, declined)
- Description
- Name
top- Type
- number
- Description
- Name
skip- Type
- number
- Description
Request
GET
/api/scansconst response = await fetch('https://portier.vivenu.com/api/scans?eventId=507f191e810c19729de860ea&parentEventId=507f191e810c19729de860ea&time=2030-01-23T23%3A00%3A00.123Z&barcode=value&type=checkin&scanResult=approved&top=10.5&skip=10.5', {
method: 'GET',
headers: {
Authorization: 'Bearer {token}',
},
})
const data = await response.json()Response (200)
{
"docs": [
{
"ticketId": "507f191e810c19729de860ea",
"eventId": "507f191e810c19729de860ea",
"barcode": "string",
"ticketTypeId": "507f191e810c19729de860ea",
"type": "checkin",
"scanResult": "approved",
"_id": "507f191e810c19729de860ea",
"time": "2030-01-23T23:00:00.123Z",
"parentEventId": "507f191e810c19729de860ea",
"name": "Example Name",
"ticketName": "string",
"deviceId": "507f191e810c19729de860ea",
"sellerId": "507f191e810c19729de860ea",
"scanZoneId": "507f191e810c19729de860ea"
}
],
"total": 1
}