const params = new URLSearchParams({
reference: 'booking_*',
maxItems: '10',
offset: '0'
});
const response = await fetch(`https://service.pcibooking.net/api/dataBlock?${params}`, {
headers: {
'Authorization': 'APIKEY your-api-key'
}
});
const data = await response.json();
console.log(data);
import requests
response = requests.get(
'https://service.pcibooking.net/api/dataBlock',
headers={
'Authorization': 'APIKEY your-api-key'
},
params={
'reference': 'booking_*',
'maxItems': 10,
'offset': 0
}
)
print(response.json())
[
{
"UserId": "Nadya",
"OwnerId": "Frodo",
"Id": "12345678",
"Reference": "ref1",
"ContentType": "application/json",
"DataSize": 140415,
"CreationTime": "2019-01-16T15:17:38.4483995Z",
"LastAccessedTime": "2019-01-17T14:17:38.4493958Z",
"LastModifiedTime": "2019-01-17T10:17:38.4493958Z",
"DataBlockLocation": "IE"
},
{
"UserId": "Nadya",
"OwnerId": "Frodo",
"Id": "11111111",
"Reference": "ref2",
"ContentType": "application/xml",
"DataSize": 2524,
"CreationTime": "2019-01-16T15:17:38.4493958Z",
"LastAccessedTime": "2019-01-17T14:17:38.4493958Z",
"LastModifiedTime": "2019-01-17T10:17:38.4493958Z",
"DataBlockLocation": "US"
},
{
"UserId": "Nadya",
"OwnerId": "Frodo",
"Id": "22222222",
"Reference": "ref1",
"ContentType": "image/png",
"DataSize": 5413,
"CreationTime": "2019-01-16T15:17:38.4493958Z",
"LastAccessedTime": "2019-01-17T14:17:38.4493958Z",
"LastModifiedTime": "2019-01-17T10:17:38.4493958Z",
"DataBlockLocation": "IE"
}
]
{
"code": -125,
"message": "Bad input data",
"moreInfo": "...",
"errorList": null
}
Empty response body.
Authentication failed: the API key, session token or access token is missing or was not accepted.
See "Authentication and Permission Failures" on the Error Handling page.
Data Blocks
Search Data Blocks
Search for data blocks by reference, with pagination support.
GET
/
api
/
dataBlock
const params = new URLSearchParams({
reference: 'booking_*',
maxItems: '10',
offset: '0'
});
const response = await fetch(`https://service.pcibooking.net/api/dataBlock?${params}`, {
headers: {
'Authorization': 'APIKEY your-api-key'
}
});
const data = await response.json();
console.log(data);
import requests
response = requests.get(
'https://service.pcibooking.net/api/dataBlock',
headers={
'Authorization': 'APIKEY your-api-key'
},
params={
'reference': 'booking_*',
'maxItems': 10,
'offset': 0
}
)
print(response.json())
[
{
"UserId": "Nadya",
"OwnerId": "Frodo",
"Id": "12345678",
"Reference": "ref1",
"ContentType": "application/json",
"DataSize": 140415,
"CreationTime": "2019-01-16T15:17:38.4483995Z",
"LastAccessedTime": "2019-01-17T14:17:38.4493958Z",
"LastModifiedTime": "2019-01-17T10:17:38.4493958Z",
"DataBlockLocation": "IE"
},
{
"UserId": "Nadya",
"OwnerId": "Frodo",
"Id": "11111111",
"Reference": "ref2",
"ContentType": "application/xml",
"DataSize": 2524,
"CreationTime": "2019-01-16T15:17:38.4493958Z",
"LastAccessedTime": "2019-01-17T14:17:38.4493958Z",
"LastModifiedTime": "2019-01-17T10:17:38.4493958Z",
"DataBlockLocation": "US"
},
{
"UserId": "Nadya",
"OwnerId": "Frodo",
"Id": "22222222",
"Reference": "ref1",
"ContentType": "image/png",
"DataSize": 5413,
"CreationTime": "2019-01-16T15:17:38.4493958Z",
"LastAccessedTime": "2019-01-17T14:17:38.4493958Z",
"LastModifiedTime": "2019-01-17T10:17:38.4493958Z",
"DataBlockLocation": "IE"
}
]
{
"code": -125,
"message": "Bad input data",
"moreInfo": "...",
"errorList": null
}
Empty response body.
Authentication failed: the API key, session token or access token is missing or was not accepted.
See "Authentication and Permission Failures" on the Error Handling page.
Data Block Tokenization Guide
Store and manage arbitrary data securely with GDPR-compliant storage locations
Error Responses
| HTTP Status | Error Code | Description |
|---|---|---|
| 400 | -125 | Validation error. A query parameter is out of range or has an invalid format (e.g. maxItems above 50 or invalid reference pattern). |
| 401 | none | Not authenticated. The API key is missing or invalid. The response body is empty. |
| 403 | -1003 | Not authorized. The API key does not have the CanRetrieveData permission. |
| 500 | -150 | Internal system error. |
Parameter Constraints
| Parameter | Constraint |
|---|---|
reference | Must match the pattern [a-zA-Z0-9_\-@#=\"']{0,64} with an optional trailing * wildcard for prefix matching. |
maxItems | Integer from 1 to 50. Defaults to 20 if omitted. |
offset | Integer from 0 upward. Zero-based index of the first result to return. |
The list of items returned to you will be sorted by the
create date of the data block.Parameters
Authentication
API key only. This endpoint does not accept access tokens or session tokens.string
required
Your API key prefixed with
APIKEY. Example: APIKEY your-api-key. The x-pcibooking-api-key header is also accepted. See the Authentication guide.Query String
string
The
reference value provided in the create method or update method. If omitted, all data blocks in your account are returned.integer
default:"20"
The maximum number of items to return. Maximum allowed value is
50.string
The zero-based offset from the first item ID to return (item IDs in PCI Booking are sequential).
const params = new URLSearchParams({
reference: 'booking_*',
maxItems: '10',
offset: '0'
});
const response = await fetch(`https://service.pcibooking.net/api/dataBlock?${params}`, {
headers: {
'Authorization': 'APIKEY your-api-key'
}
});
const data = await response.json();
console.log(data);
import requests
response = requests.get(
'https://service.pcibooking.net/api/dataBlock',
headers={
'Authorization': 'APIKEY your-api-key'
},
params={
'reference': 'booking_*',
'maxItems': 10,
'offset': 0
}
)
print(response.json())
Response
[
{
"UserId": "Nadya",
"OwnerId": "Frodo",
"Id": "12345678",
"Reference": "ref1",
"ContentType": "application/json",
"DataSize": 140415,
"CreationTime": "2019-01-16T15:17:38.4483995Z",
"LastAccessedTime": "2019-01-17T14:17:38.4493958Z",
"LastModifiedTime": "2019-01-17T10:17:38.4493958Z",
"DataBlockLocation": "IE"
},
{
"UserId": "Nadya",
"OwnerId": "Frodo",
"Id": "11111111",
"Reference": "ref2",
"ContentType": "application/xml",
"DataSize": 2524,
"CreationTime": "2019-01-16T15:17:38.4493958Z",
"LastAccessedTime": "2019-01-17T14:17:38.4493958Z",
"LastModifiedTime": "2019-01-17T10:17:38.4493958Z",
"DataBlockLocation": "US"
},
{
"UserId": "Nadya",
"OwnerId": "Frodo",
"Id": "22222222",
"Reference": "ref1",
"ContentType": "image/png",
"DataSize": 5413,
"CreationTime": "2019-01-16T15:17:38.4493958Z",
"LastAccessedTime": "2019-01-17T14:17:38.4493958Z",
"LastModifiedTime": "2019-01-17T10:17:38.4493958Z",
"DataBlockLocation": "IE"
}
]
{
"code": -125,
"message": "Bad input data",
"moreInfo": "...",
"errorList": null
}
Empty response body.
Authentication failed: the API key, session token or access token is missing or was not accepted.
See "Authentication and Permission Failures" on the Error Handling page.

