Inventory transactions
Count inventory transactions with a request body
POST
/
inventory-transaction
/
count
Count inventory transactions with a request body
curl --request POST \
--url https://{instance}/api/v2/inventory-transaction/count \
--header 'Content-Type: application/json' \
--header 'X-API-Key: <api-key>' \
--data '
{
"filter": "<string>",
"search": "<string>",
"page": 1,
"pageSize": 100,
"orderBy": "<string>",
"select": [
"<string>"
]
}
'const options = {
method: 'POST',
headers: {'X-API-Key': '<api-key>', 'Content-Type': 'application/json'},
body: JSON.stringify({
filter: '<string>',
search: '<string>',
page: 1,
pageSize: 100,
orderBy: '<string>',
select: ['<string>']
})
};
fetch('https://{instance}/api/v2/inventory-transaction/count', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));import requests
url = "https://{instance}/api/v2/inventory-transaction/count"
payload = {
"filter": "<string>",
"search": "<string>",
"page": 1,
"pageSize": 100,
"orderBy": "<string>",
"select": ["<string>"]
}
headers = {
"X-API-Key": "<api-key>",
"Content-Type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text){
"count": 123
}{
"error": {
"message": "<string>",
"code": "BAD_REQUEST",
"requestId": "<string>",
"details": [
{
"path": "<string>",
"message": "<string>",
"code": "<string>"
}
],
"missingPermissions": [
"<string>"
]
},
"context": {}
}{
"error": {
"message": "<string>",
"code": "BAD_REQUEST",
"requestId": "<string>",
"details": [
{
"path": "<string>",
"message": "<string>",
"code": "<string>"
}
],
"missingPermissions": [
"<string>"
]
},
"context": {}
}{
"error": {
"message": "<string>",
"code": "BAD_REQUEST",
"requestId": "<string>",
"details": [
{
"path": "<string>",
"message": "<string>",
"code": "<string>"
}
],
"missingPermissions": [
"<string>"
]
},
"context": {}
}{
"error": {
"message": "<string>",
"code": "BAD_REQUEST",
"requestId": "<string>",
"details": [
{
"path": "<string>",
"message": "<string>",
"code": "<string>"
}
],
"missingPermissions": [
"<string>"
]
},
"context": {}
}Authorizations
Organization-scoped API key. Create one in the BuildingSwell app under Organization settings, API keys.
Body
application/json
The same options the list endpoint takes in the query string. Any additional key is read as a field filter.
AND/OR filter expression.
Full-text search term.
Page to return, starting at 1.
Records per page. Defaults to 100 when omitted.
Sort as field:asc or field:desc.
Return only these fields.
Field name.
Response
Successful response.
⌘I
Count inventory transactions with a request body
curl --request POST \
--url https://{instance}/api/v2/inventory-transaction/count \
--header 'Content-Type: application/json' \
--header 'X-API-Key: <api-key>' \
--data '
{
"filter": "<string>",
"search": "<string>",
"page": 1,
"pageSize": 100,
"orderBy": "<string>",
"select": [
"<string>"
]
}
'const options = {
method: 'POST',
headers: {'X-API-Key': '<api-key>', 'Content-Type': 'application/json'},
body: JSON.stringify({
filter: '<string>',
search: '<string>',
page: 1,
pageSize: 100,
orderBy: '<string>',
select: ['<string>']
})
};
fetch('https://{instance}/api/v2/inventory-transaction/count', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));import requests
url = "https://{instance}/api/v2/inventory-transaction/count"
payload = {
"filter": "<string>",
"search": "<string>",
"page": 1,
"pageSize": 100,
"orderBy": "<string>",
"select": ["<string>"]
}
headers = {
"X-API-Key": "<api-key>",
"Content-Type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text){
"count": 123
}{
"error": {
"message": "<string>",
"code": "BAD_REQUEST",
"requestId": "<string>",
"details": [
{
"path": "<string>",
"message": "<string>",
"code": "<string>"
}
],
"missingPermissions": [
"<string>"
]
},
"context": {}
}{
"error": {
"message": "<string>",
"code": "BAD_REQUEST",
"requestId": "<string>",
"details": [
{
"path": "<string>",
"message": "<string>",
"code": "<string>"
}
],
"missingPermissions": [
"<string>"
]
},
"context": {}
}{
"error": {
"message": "<string>",
"code": "BAD_REQUEST",
"requestId": "<string>",
"details": [
{
"path": "<string>",
"message": "<string>",
"code": "<string>"
}
],
"missingPermissions": [
"<string>"
]
},
"context": {}
}{
"error": {
"message": "<string>",
"code": "BAD_REQUEST",
"requestId": "<string>",
"details": [
{
"path": "<string>",
"message": "<string>",
"code": "<string>"
}
],
"missingPermissions": [
"<string>"
]
},
"context": {}
}