Service Accounts
Get Logs
API Documentation
Governance
- Organisations
- Schemes
- Work Orders
- Permits
- Operations
- Properties
- Streets
Data Capture
- Forms
- Form Categories
- Submissions
- Submission Versions
Operations
- Reinstatements
Assets
- Vehicles
Admin
Service Accounts
Get Logs
Get logs for requests that have been made using the service account
GET
/
v3
/
orgs
/
{orgId}
/
iam
/
service-accounts
/
{accountId}
/
logs
curl --request GET \
--url https://api.ctrl-hub.com/v3/orgs/{orgId}/iam/service-accounts/{accountId}/logs \
--header 'Authorization: Bearer <token>'
{
"data": [
{
"type": "service-account-logs",
"id": "14b28316-9c20-8a7d-e85a-b62f29a29ac5",
"attributes": {
"actor": {
"type": "service-accounts",
"id": "12e3ff58-072b-0ea2-7079-f64748d5a16b"
},
"duration": 10,
"request": {
"time": "2024-10-16T17:12:59.953Z",
"headers": {
"Authorization": [
"redacted"
],
"Content-Type": [
"application/json; charset=utf-8"
]
},
"body": "<string>",
"path": "/path/to/endpoint",
"query": {},
"raw_query": "param1=value1¶m2=value2",
"method": "GET"
},
"response": {
"time": "2024-10-16T17:12:59.953Z",
"body": "<string>",
"status": 200,
"headers": {
"Content-Type": [
"application/json; charset=utf-8"
]
}
}
}
}
],
"meta": {
"counts": {
"limit": 10
},
"page": {
"limit": 10,
"offset": {
"current": 20,
"next": 30,
"previous": 10
}
}
},
"links": {
"current": "https://api.ctrl-hub.com/v3/orgs/7e0c875a-fd47-401d-bd25-4278ed58d721/iam/service-accounts/logs?limit=10&offset=20",
"next": "https://api.ctrl-hub.com/v3/orgs/7e0c875a-fd47-401d-bd25-4278ed58d721/iam/service-accounts/logs?limit=10&offset=30",
"previous": "https://api.ctrl-hub.com/v3/orgs/7e0c875a-fd47-401d-bd25-4278ed58d721/iam/service-accounts/logs?limit=10&offset=10"
}
}
Authorizations
To understand how to authenticate, see the auth docs
Query Parameters
Limit the number of resources returned by the API
Offset for resources returned by the API
A field in the resource to sort results with. Not all attributes are supported, please see the Object Model for sortable fields.
Response
200
application/json
Available options:
service-account-logs
The request body
Available options:
GET
, POST
, PUT
, DELETE
, PATCH
, OPTIONS
, HEAD
, CONNECT
curl --request GET \
--url https://api.ctrl-hub.com/v3/orgs/{orgId}/iam/service-accounts/{accountId}/logs \
--header 'Authorization: Bearer <token>'
{
"data": [
{
"type": "service-account-logs",
"id": "14b28316-9c20-8a7d-e85a-b62f29a29ac5",
"attributes": {
"actor": {
"type": "service-accounts",
"id": "12e3ff58-072b-0ea2-7079-f64748d5a16b"
},
"duration": 10,
"request": {
"time": "2024-10-16T17:12:59.953Z",
"headers": {
"Authorization": [
"redacted"
],
"Content-Type": [
"application/json; charset=utf-8"
]
},
"body": "<string>",
"path": "/path/to/endpoint",
"query": {},
"raw_query": "param1=value1¶m2=value2",
"method": "GET"
},
"response": {
"time": "2024-10-16T17:12:59.953Z",
"body": "<string>",
"status": 200,
"headers": {
"Content-Type": [
"application/json; charset=utf-8"
]
}
}
}
}
],
"meta": {
"counts": {
"limit": 10
},
"page": {
"limit": 10,
"offset": {
"current": 20,
"next": 30,
"previous": 10
}
}
},
"links": {
"current": "https://api.ctrl-hub.com/v3/orgs/7e0c875a-fd47-401d-bd25-4278ed58d721/iam/service-accounts/logs?limit=10&offset=20",
"next": "https://api.ctrl-hub.com/v3/orgs/7e0c875a-fd47-401d-bd25-4278ed58d721/iam/service-accounts/logs?limit=10&offset=30",
"previous": "https://api.ctrl-hub.com/v3/orgs/7e0c875a-fd47-401d-bd25-4278ed58d721/iam/service-accounts/logs?limit=10&offset=10"
}
}