API Documentation
Governance
- Organisations
- Schemes
- Work Orders
- Permits
- Operations
- Properties
- Streets
Data Capture
- Forms
- Form Categories
- Submissions
- Submission Versions
Operations
- Reinstatements
Assets
- Vehicles
Admin
- IAM
Get Forms
Returns all forms for an organisation that the caller has access to
curl --request GET \
--url https://api.ctrl-hub.com/v3/orgs/{orgId}/data-capture/forms \
--header 'Authorization: Bearer <token>'
{
"data": [
{
"type": "forms",
"id": "92dbb844-8524-60bf-c12e-1eaf5c04",
"attributes": {
"name": "My Form",
"description": "This is a form which captures lots of useful information",
"status": "published"
},
"meta": {
"created_at": "2024-06-13T08:28:17.000Z"
},
"relationships": {
"categories": {
"data": [
{
"type": "form_categories",
"id": "b60e2af5-6a84-0eb0-feaa-84384a94"
}
]
}
},
"links": {
"self": "https://api.ctrl-hub.com/v3/orgs/7e0c875a-fd47-401d-bd25-4278ed58d721/data-capture/forms/92dbb844-8524-60bf-c12e-1eaf5c04"
}
}
],
"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/data-capture/forms?limit=10&offset=20",
"next": "https://api.ctrl-hub.com/v3/orgs/7e0c875a-fd47-401d-bd25-4278ed58d721/data-capture/forms?limit=10&offset=30",
"previous": "https://api.ctrl-hub.com/v3/orgs/7e0c875a-fd47-401d-bd25-4278ed58d721/data-capture/forms?limit=10&offset=10"
}
}
Authorizations
To understand how to authenticate, see the auth docs
Path Parameters
The ID of the organisation
"cc9746e0-9286-4575-ae0b-ac1b0fe873a6"
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
The resource type
forms
"forms"
The ID of the form
"92dbb844-8524-60bf-c12e-1eaf5c04"
The name of the form
"My Form"
Additional description of the form, for example, what it is used for
"This is a form which captures lots of useful information"
The current status of the form
published
, draft
, hidden
, archived
"published"
"https://api.ctrl-hub.com/v3/orgs/7e0c875a-fd47-401d-bd25-4278ed58d721/data-capture/forms?limit=10&offset=20"
"https://api.ctrl-hub.com/v3/orgs/7e0c875a-fd47-401d-bd25-4278ed58d721/data-capture/forms?limit=10&offset=30"
"https://api.ctrl-hub.com/v3/orgs/7e0c875a-fd47-401d-bd25-4278ed58d721/data-capture/forms?limit=10&offset=10"
curl --request GET \
--url https://api.ctrl-hub.com/v3/orgs/{orgId}/data-capture/forms \
--header 'Authorization: Bearer <token>'
{
"data": [
{
"type": "forms",
"id": "92dbb844-8524-60bf-c12e-1eaf5c04",
"attributes": {
"name": "My Form",
"description": "This is a form which captures lots of useful information",
"status": "published"
},
"meta": {
"created_at": "2024-06-13T08:28:17.000Z"
},
"relationships": {
"categories": {
"data": [
{
"type": "form_categories",
"id": "b60e2af5-6a84-0eb0-feaa-84384a94"
}
]
}
},
"links": {
"self": "https://api.ctrl-hub.com/v3/orgs/7e0c875a-fd47-401d-bd25-4278ed58d721/data-capture/forms/92dbb844-8524-60bf-c12e-1eaf5c04"
}
}
],
"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/data-capture/forms?limit=10&offset=20",
"next": "https://api.ctrl-hub.com/v3/orgs/7e0c875a-fd47-401d-bd25-4278ed58d721/data-capture/forms?limit=10&offset=30",
"previous": "https://api.ctrl-hub.com/v3/orgs/7e0c875a-fd47-401d-bd25-4278ed58d721/data-capture/forms?limit=10&offset=10"
}
}