Kublade API Documentation (v1.34.1)
Download OpenAPI specification:Download
Kublade Swagger API documentation
Register a new user
Register a new user.
Request Body schema: application/json
name | string |
string | |
password | string |
Responses
Request samples
- Payload
{- "name": "John Doe",
- "email": "john@example.com",
- "password": "password123"
}
Response samples
- 201
- 400
- 401
- 500
{- "status": "success",
- "message": "User registered successfully",
- "data": {
- "user": {
- "id": "1",
- "name": "John Doe",
- "email": "john.doe@example.com",
- "email_verified_at": "2021-01-01T00:00:00Z",
- "password": "password123",
- "remember_token": "remember_token123",
- "created_at": "2021-01-01 00:00:00",
- "updated_at": "2021-01-01 00:00:00"
}, - "token": "string"
}
}
Login a user
Login a user.
Request Body schema: application/json
string | |
password | string |
Responses
Request samples
- Payload
{- "email": "john@example.com",
- "password": "password123"
}
Response samples
- 200
- 400
- 401
- 500
{- "status": "success",
- "message": "Login successful",
- "data": {
- "token": "string"
}
}
Response samples
- 200
- 401
- 500
{- "status": "success",
- "message": "User authenticated",
- "data": {
- "id": "1",
- "name": "John Doe",
- "email": "john.doe@example.com",
- "email_verified_at": "2021-01-01T00:00:00Z",
- "password": "password123",
- "remember_token": "remember_token123",
- "created_at": "2021-01-01 00:00:00",
- "updated_at": "2021-01-01 00:00:00"
}
}
List clusters
List clusters.
path Parameters
project_id required | string The ID of the project |
query Parameters
cursor | string Cursor for pagination |
Responses
Response samples
- 200
- 400
- 401
- 500
{- "status": "success",
- "message": "Clusters retrieved successfully",
- "data": {
- "clusters": [
- {
- "id": "123e4567-e89b-12d3-a456-426614174000",
- "user_id": "123e4567-e89b-12d3-a456-426614174000",
- "project_id": "123e4567-e89b-12d3-a456-426614174000",
- "name": "Cluster 1",
- "created_at": "2021-01-01 00:00:00",
- "updated_at": "2021-01-01 00:00:00",
- "deleted_at": "2021-01-01 00:00:00"
}
], - "links": {
- "next": "string",
- "prev": "string"
}
}
}
Add a new cluster
Add a new cluster.
path Parameters
project_id required | string The ID of the project |
Request Body schema: application/jsonrequired
name | string |
object | |
object | |
object |
Responses
Request samples
- Payload
{- "name": "string",
- "git": {
- "url": "string",
- "branch": "string",
- "credentials": "string",
- "username": "string",
- "email": "string",
- "base_path": "string"
}, - "k8s": {
- "api_url": "string",
- "kubeconfig": "string",
- "service_account_token": "string",
- "node_prefix": "string"
}, - "namespace": {
- "utility": "string",
- "ingress": "string"
}
}
Response samples
- 201
- 400
- 401
- 500
{- "status": "success",
- "message": "Cluster created successfully",
- "data": {
- "cluster": {
- "id": "123e4567-e89b-12d3-a456-426614174000",
- "user_id": "123e4567-e89b-12d3-a456-426614174000",
- "project_id": "123e4567-e89b-12d3-a456-426614174000",
- "name": "Cluster 1",
- "created_at": "2021-01-01 00:00:00",
- "updated_at": "2021-01-01 00:00:00",
- "deleted_at": "2021-01-01 00:00:00"
}
}
}
Get a cluster
Get a cluster.
path Parameters
project_id required | string The ID of the project |
cluster_id required | string The ID of the cluster |
Responses
Response samples
- 200
- 400
- 401
- 404
- 500
{- "status": "success",
- "message": "Cluster retrieved successfully",
- "data": {
- "cluster": {
- "id": "123e4567-e89b-12d3-a456-426614174000",
- "user_id": "123e4567-e89b-12d3-a456-426614174000",
- "project_id": "123e4567-e89b-12d3-a456-426614174000",
- "name": "Cluster 1",
- "created_at": "2021-01-01 00:00:00",
- "updated_at": "2021-01-01 00:00:00",
- "deleted_at": "2021-01-01 00:00:00"
}
}
}
Delete a cluster
Delete the cluster.
path Parameters
project_id required | string The ID of the project |
cluster_id required | string The ID of the cluster |
Responses
Response samples
- 200
- 400
- 401
- 500
{- "status": "success",
- "message": "Cluster deleted successfully",
- "data": {
- "cluster": {
- "id": "123e4567-e89b-12d3-a456-426614174000",
- "user_id": "123e4567-e89b-12d3-a456-426614174000",
- "project_id": "123e4567-e89b-12d3-a456-426614174000",
- "name": "Cluster 1",
- "created_at": "2021-01-01 00:00:00",
- "updated_at": "2021-01-01 00:00:00",
- "deleted_at": "2021-01-01 00:00:00"
}
}
}
Update a cluster
Update the cluster.
path Parameters
project_id required | string The ID of the project |
cluster_id required | string The ID of the cluster |
Request Body schema: application/jsonrequired
name | string |
object | |
object | |
object |
Responses
Request samples
- Payload
{- "name": "string",
- "git": {
- "url": "string",
- "branch": "string",
- "credentials": "string",
- "username": "string",
- "email": "string",
- "base_path": "string"
}, - "k8s": {
- "api_url": "string",
- "kubeconfig": "string",
- "service_account_token": "string",
- "node_prefix": "string"
}, - "namespace": {
- "utility": "string",
- "ingress": "string"
}
}
Response samples
- 200
- 400
- 401
- 500
{- "status": "success",
- "message": "Cluster updated successfully",
- "data": {
- "cluster": {
- "id": "123e4567-e89b-12d3-a456-426614174000",
- "user_id": "123e4567-e89b-12d3-a456-426614174000",
- "project_id": "123e4567-e89b-12d3-a456-426614174000",
- "name": "Cluster 1",
- "created_at": "2021-01-01 00:00:00",
- "updated_at": "2021-01-01 00:00:00",
- "deleted_at": "2021-01-01 00:00:00"
}
}
}
List deployments for a project
List the deployments.
path Parameters
project_id required | string The ID of the project |
query Parameters
cursor | string Cursor for pagination |
Responses
Response samples
- 200
- 400
- 401
- 500
{- "status": "success",
- "message": "Deployments retrieved successfully",
- "data": {
- "deployments": [
- {
- "id": "123e4567-e89b-12d3-a456-426614174000",
- "user_id": "123e4567-e89b-12d3-a456-426614174000",
- "project_id": "123e4567-e89b-12d3-a456-426614174000",
- "namespace_id": "123e4567-e89b-12d3-a456-426614174000",
- "template_id": "123e4567-e89b-12d3-a456-426614174000",
- "cluster_id": "123e4567-e89b-12d3-a456-426614174000",
- "name": "Deployment 1",
- "uuid": "123e4567-e89b-12d3-a456-426614174000",
- "paused": false,
- "update": false,
- "delete": false,
- "deployed_at": "2021-01-01 00:00:00",
- "deployment_updated_at": "2021-01-01 00:00:00",
- "creation_dispatched_at": "2021-01-01 00:00:00",
- "update_dispatched_at": "2021-01-01 00:00:00",
- "deletion_dispatched_at": "2021-01-01 00:00:00",
- "created_at": "2021-01-01 00:00:00",
- "updated_at": "2021-01-01 00:00:00",
- "deleted_at": "2021-01-01 00:00:00"
}
], - "links": {
- "next": "string",
- "prev": "string"
}
}
}
Add a new deployment
Add the deployment.
path Parameters
project_id required | string The ID of the project |
Request Body schema: application/jsonrequired
template_id | string |
cluster_id | string |
name | string |
data | object |
Responses
Request samples
- Payload
{- "template_id": "string",
- "cluster_id": "string",
- "name": "string",
- "data": { }
}
Response samples
- 200
- 400
- 401
- 500
{- "status": "success",
- "message": "Deployment created",
- "data": {
- "deployment": {
- "id": "123e4567-e89b-12d3-a456-426614174000",
- "user_id": "123e4567-e89b-12d3-a456-426614174000",
- "project_id": "123e4567-e89b-12d3-a456-426614174000",
- "namespace_id": "123e4567-e89b-12d3-a456-426614174000",
- "template_id": "123e4567-e89b-12d3-a456-426614174000",
- "cluster_id": "123e4567-e89b-12d3-a456-426614174000",
- "name": "Deployment 1",
- "uuid": "123e4567-e89b-12d3-a456-426614174000",
- "paused": false,
- "update": false,
- "delete": false,
- "deployed_at": "2021-01-01 00:00:00",
- "deployment_updated_at": "2021-01-01 00:00:00",
- "creation_dispatched_at": "2021-01-01 00:00:00",
- "update_dispatched_at": "2021-01-01 00:00:00",
- "deletion_dispatched_at": "2021-01-01 00:00:00",
- "created_at": "2021-01-01 00:00:00",
- "updated_at": "2021-01-01 00:00:00",
- "deleted_at": "2021-01-01 00:00:00"
}
}
}
Get a deployment by ID
Get the deployment.
path Parameters
project_id required | string The ID of the project |
deployment_id required | string The ID of the deployment |
Responses
Response samples
- 200
- 400
- 401
- 404
- 500
{- "status": "success",
- "message": "Deployment details",
- "data": {
- "deployment": {
- "id": "123e4567-e89b-12d3-a456-426614174000",
- "user_id": "123e4567-e89b-12d3-a456-426614174000",
- "project_id": "123e4567-e89b-12d3-a456-426614174000",
- "namespace_id": "123e4567-e89b-12d3-a456-426614174000",
- "template_id": "123e4567-e89b-12d3-a456-426614174000",
- "cluster_id": "123e4567-e89b-12d3-a456-426614174000",
- "name": "Deployment 1",
- "uuid": "123e4567-e89b-12d3-a456-426614174000",
- "paused": false,
- "update": false,
- "delete": false,
- "deployed_at": "2021-01-01 00:00:00",
- "deployment_updated_at": "2021-01-01 00:00:00",
- "creation_dispatched_at": "2021-01-01 00:00:00",
- "update_dispatched_at": "2021-01-01 00:00:00",
- "deletion_dispatched_at": "2021-01-01 00:00:00",
- "created_at": "2021-01-01 00:00:00",
- "updated_at": "2021-01-01 00:00:00",
- "deleted_at": "2021-01-01 00:00:00"
}
}
}
Delete a deployment
Delete the deployment.
path Parameters
project_id required | string The ID of the project |
deployment_id required | string The ID of the deployment |
Responses
Response samples
- 200
- 400
- 401
- 404
- 500
{- "status": "success",
- "message": "Deployment deleted",
- "data": {
- "deployment": {
- "id": "123e4567-e89b-12d3-a456-426614174000",
- "user_id": "123e4567-e89b-12d3-a456-426614174000",
- "project_id": "123e4567-e89b-12d3-a456-426614174000",
- "namespace_id": "123e4567-e89b-12d3-a456-426614174000",
- "template_id": "123e4567-e89b-12d3-a456-426614174000",
- "cluster_id": "123e4567-e89b-12d3-a456-426614174000",
- "name": "Deployment 1",
- "uuid": "123e4567-e89b-12d3-a456-426614174000",
- "paused": false,
- "update": false,
- "delete": false,
- "deployed_at": "2021-01-01 00:00:00",
- "deployment_updated_at": "2021-01-01 00:00:00",
- "creation_dispatched_at": "2021-01-01 00:00:00",
- "update_dispatched_at": "2021-01-01 00:00:00",
- "deletion_dispatched_at": "2021-01-01 00:00:00",
- "created_at": "2021-01-01 00:00:00",
- "updated_at": "2021-01-01 00:00:00",
- "deleted_at": "2021-01-01 00:00:00"
}
}
}
Update a deployment
Update the deployment.
path Parameters
project_id required | string The ID of the project |
deployment_id required | string The ID of the deployment |
Request Body schema: application/jsonrequired
name | string |
data | object |
Responses
Request samples
- Payload
{- "name": "string",
- "data": { }
}
Response samples
- 200
- 400
- 401
- 404
- 500
{- "status": "success",
- "message": "Deployment updated",
- "data": {
- "deployment": {
- "id": "123e4567-e89b-12d3-a456-426614174000",
- "user_id": "123e4567-e89b-12d3-a456-426614174000",
- "project_id": "123e4567-e89b-12d3-a456-426614174000",
- "namespace_id": "123e4567-e89b-12d3-a456-426614174000",
- "template_id": "123e4567-e89b-12d3-a456-426614174000",
- "cluster_id": "123e4567-e89b-12d3-a456-426614174000",
- "name": "Deployment 1",
- "uuid": "123e4567-e89b-12d3-a456-426614174000",
- "paused": false,
- "update": false,
- "delete": false,
- "deployed_at": "2021-01-01 00:00:00",
- "deployment_updated_at": "2021-01-01 00:00:00",
- "creation_dispatched_at": "2021-01-01 00:00:00",
- "update_dispatched_at": "2021-01-01 00:00:00",
- "deletion_dispatched_at": "2021-01-01 00:00:00",
- "created_at": "2021-01-01 00:00:00",
- "updated_at": "2021-01-01 00:00:00",
- "deleted_at": "2021-01-01 00:00:00"
}
}
}
Create a network policy
Create the network policy.
path Parameters
project_id required | string The ID of the project |
deployment_id required | string The ID of the deployment |
network_policy_id required | string The ID of the network policy |
Request Body schema: application/jsonrequired
source_deployment_id | string |
target_deployment_id | string |
Responses
Request samples
- Payload
{- "source_deployment_id": "string",
- "target_deployment_id": "string"
}
Response samples
- 200
- 400
- 401
- 404
- 500
{- "status": "success",
- "message": "Network policy put",
- "data": {
- "network_policy": {
- "id": "123e4567-e89b-12d3-a456-426614174000",
- "source_deployment_id": "123e4567-e89b-12d3-a456-426614174000",
- "target_deployment_id": "123e4567-e89b-12d3-a456-426614174000",
- "created_at": "2021-01-01 00:00:00",
- "updated_at": "2021-01-01 00:00:00",
- "deleted_at": "2021-01-01 00:00:00"
}
}
}
Delete a network policy
Delete the network policy.
path Parameters
project_id required | string The ID of the project |
deployment_id required | string The ID of the deployment |
network_policy_id required | string The ID of the network policy |
Responses
Response samples
- 200
- 400
- 401
- 404
- 500
{- "status": "success",
- "message": "Network policy deleted",
- "data": {
- "network_policy": {
- "id": "123e4567-e89b-12d3-a456-426614174000",
- "source_deployment_id": "123e4567-e89b-12d3-a456-426614174000",
- "target_deployment_id": "123e4567-e89b-12d3-a456-426614174000",
- "created_at": "2021-01-01 00:00:00",
- "updated_at": "2021-01-01 00:00:00",
- "deleted_at": "2021-01-01 00:00:00"
}
}
}
Revert a commit
Revert the commit.
path Parameters
project_id required | string The ID of the project |
deployment_id required | string The ID of the deployment |
commit_id required | string The ID of the commit |
Responses
Response samples
- 200
- 400
- 401
- 404
- 500
{- "status": "success",
- "message": "Commit reverted",
- "data": {
- "commit": {
- "id": "123e4567-e89b-12d3-a456-426614174000",
- "deployment_id": "123e4567-e89b-12d3-a456-426614174000",
- "hash": "123e4567-e89b-12d3-a456-426614174000",
- "message": "Deployment commit message",
- "created_at": "2021-01-01 00:00:00",
- "updated_at": "2021-01-01 00:00:00",
- "deleted_at": "2021-01-01 00:00:00"
}
}
}
Response samples
- 200
- 401
- 500
{- "status": "success",
- "message": "Projects retrieved successfully",
- "data": {
- "projects": [
- {
- "id": "123e4567-e89b-12d3-a456-426614174000",
- "user_id": "1",
- "name": "Project 1",
- "created_at": "2021-01-01 00:00:00",
- "updated_at": "2021-01-01 00:00:00",
- "deleted_at": "2021-01-01 00:00:00"
}
], - "links": {
- "next": "string",
- "prev": "string"
}
}
}
Add a new project
Add a new project.
Request Body schema: application/jsonrequired
name | string |
Responses
Request samples
- Payload
{- "name": "string"
}
Response samples
- 201
- 400
- 401
- 500
{- "status": "success",
- "message": "Project added successfully",
- "data": {
- "project": {
- "id": "123e4567-e89b-12d3-a456-426614174000",
- "user_id": "1",
- "name": "Project 1",
- "created_at": "2021-01-01 00:00:00",
- "updated_at": "2021-01-01 00:00:00",
- "deleted_at": "2021-01-01 00:00:00"
}
}
}
Get a project
Get the project.
path Parameters
project_id required | string The ID of the project |
Responses
Response samples
- 200
- 400
- 401
- 404
- 500
{- "status": "success",
- "message": "Project retrieved successfully",
- "data": {
- "project": {
- "id": "123e4567-e89b-12d3-a456-426614174000",
- "user_id": "1",
- "name": "Project 1",
- "created_at": "2021-01-01 00:00:00",
- "updated_at": "2021-01-01 00:00:00",
- "deleted_at": "2021-01-01 00:00:00"
}
}
}
Delete a project
Delete the project.
path Parameters
project_id required | string The ID of the project |
Responses
Response samples
- 200
- 400
- 401
- 500
{- "status": "success",
- "message": "Project deleted successfully",
- "data": {
- "project": {
- "id": "123e4567-e89b-12d3-a456-426614174000",
- "user_id": "1",
- "name": "Project 1",
- "created_at": "2021-01-01 00:00:00",
- "updated_at": "2021-01-01 00:00:00",
- "deleted_at": "2021-01-01 00:00:00"
}
}
}
Update a project
Update the project.
path Parameters
project_id required | string The ID of the project |
Request Body schema: application/jsonrequired
name | string |
Responses
Request samples
- Payload
{- "name": "string"
}
Response samples
- 200
- 400
- 401
- 500
{- "status": "success",
- "message": "Project updated successfully",
- "data": {
- "project": {
- "id": "123e4567-e89b-12d3-a456-426614174000",
- "user_id": "1",
- "name": "Project 1",
- "created_at": "2021-01-01 00:00:00",
- "updated_at": "2021-01-01 00:00:00",
- "deleted_at": "2021-01-01 00:00:00"
}
}
}
Response samples
- 200
- 401
- 500
{- "status": "success",
- "message": "Roles retrieved successfully",
- "data": {
- "roles": [
- {
- "id": "1",
- "name": "John Doe",
- "guard_name": "api",
- "created_at": "2021-01-01 00:00:00",
- "updated_at": "2021-01-01 00:00:00"
}
], - "links": {
- "next": "string",
- "prev": "string"
}
}
}
Add a new role
Add a new role.
Request Body schema: application/jsonrequired
name | string |
permissions | Array of strings or null |
Responses
Request samples
- Payload
{- "name": "string",
- "permissions": [
- "string"
]
}
Response samples
- 200
- 400
- 401
- 500
{- "status": "success",
- "message": "Role created successfully",
- "data": {
- "role": {
- "id": "1",
- "name": "John Doe",
- "guard_name": "api",
- "created_at": "2021-01-01 00:00:00",
- "updated_at": "2021-01-01 00:00:00"
}
}
}
Response samples
- 200
- 400
- 401
- 404
- 500
{- "status": "success",
- "message": "Role retrieved successfully",
- "data": {
- "role": {
- "id": "1",
- "name": "John Doe",
- "guard_name": "api",
- "created_at": "2021-01-01 00:00:00",
- "updated_at": "2021-01-01 00:00:00"
}
}
}
Response samples
- 200
- 400
- 401
- 500
{- "status": "success",
- "message": "Role deleted successfully",
- "data": {
- "role": {
- "id": "1",
- "name": "John Doe",
- "guard_name": "api",
- "created_at": "2021-01-01 00:00:00",
- "updated_at": "2021-01-01 00:00:00"
}
}
}
Update a role
Update the role.
path Parameters
role_id required | string The ID of the role |
Request Body schema: application/jsonrequired
name | string |
permissions | Array of strings or null |
Responses
Request samples
- Payload
{- "name": "string",
- "permissions": [
- "string"
]
}
Response samples
- 200
- 400
- 401
- 500
{- "status": "success",
- "message": "Role updated successfully",
- "data": {
- "role": {
- "id": "1",
- "name": "John Doe",
- "guard_name": "api",
- "created_at": "2021-01-01 00:00:00",
- "updated_at": "2021-01-01 00:00:00"
}
}
}
Response samples
- 200
- 401
- 500
{- "status": "success",
- "message": "Templates retrieved successfully",
- "data": {
- "templates": [
- {
- "id": "123e4567-e89b-12d3-a456-426614174000",
- "user_id": "1",
- "name": "Template 1",
- "netpol": false,
- "created_at": "2021-01-01 00:00:00",
- "updated_at": "2021-01-01 00:00:00",
- "deleted_at": "2021-01-01 00:00:00"
}
], - "links": {
- "next": "string",
- "prev": "string"
}
}
}
Add a new template
Add a new template.
Request Body schema: application/jsonrequired
name | string |
netpol | boolean or null |
Responses
Request samples
- Payload
{- "name": "string",
- "netpol": true
}
Response samples
- 200
- 400
- 401
- 500
{- "status": "success",
- "message": "Template added successfully",
- "data": {
- "template": {
- "id": "123e4567-e89b-12d3-a456-426614174000",
- "user_id": "1",
- "name": "Template 1",
- "netpol": false,
- "created_at": "2021-01-01 00:00:00",
- "updated_at": "2021-01-01 00:00:00",
- "deleted_at": "2021-01-01 00:00:00"
}
}
}
Get template
Get the template.
path Parameters
template_id required | string The ID of the template |
Responses
Response samples
- 200
- 401
- 404
- 500
{- "status": "success",
- "message": "Template retrieved successfully",
- "data": {
- "template": {
- "id": "123e4567-e89b-12d3-a456-426614174000",
- "user_id": "1",
- "name": "Template 1",
- "netpol": false,
- "created_at": "2021-01-01 00:00:00",
- "updated_at": "2021-01-01 00:00:00",
- "deleted_at": "2021-01-01 00:00:00"
}
}
}
Delete the template
Delete the template.
path Parameters
template_id required | string The ID of the template |
Responses
Response samples
- 200
- 400
- 401
- 500
{- "status": "success",
- "message": "Template deleted successfully",
- "data": {
- "template": {
- "id": "123e4567-e89b-12d3-a456-426614174000",
- "user_id": "1",
- "name": "Template 1",
- "netpol": false,
- "created_at": "2021-01-01 00:00:00",
- "updated_at": "2021-01-01 00:00:00",
- "deleted_at": "2021-01-01 00:00:00"
}
}
}
Update the template
Update the template.
path Parameters
template_id required | string The ID of the template |
Request Body schema: application/jsonrequired
name | string |
netpol | boolean or null |
Responses
Request samples
- Payload
{- "name": "string",
- "netpol": true
}
Response samples
- 200
- 400
- 401
- 500
{- "status": "success",
- "message": "Template updated successfully",
- "data": {
- "template": {
- "id": "123e4567-e89b-12d3-a456-426614174000",
- "user_id": "1",
- "name": "Template 1",
- "netpol": false,
- "created_at": "2021-01-01 00:00:00",
- "updated_at": "2021-01-01 00:00:00",
- "deleted_at": "2021-01-01 00:00:00"
}
}
}
Import a new template
Import a new template.
Request Body schema: application/jsonrequired
name | string |
netpol | boolean or null |
url | string |
chart | string |
repo | string or null |
namespace | string or null |
Responses
Request samples
- Payload
{- "name": "string",
- "netpol": true,
- "url": "string",
- "chart": "string",
- "repo": "string",
- "namespace": "string"
}
Response samples
- 200
- 400
- 401
- 500
{- "status": "success",
- "message": "Template imported successfully",
- "data": {
- "template": {
- "id": "123e4567-e89b-12d3-a456-426614174000",
- "user_id": "1",
- "name": "Template 1",
- "netpol": false,
- "created_at": "2021-01-01 00:00:00",
- "updated_at": "2021-01-01 00:00:00",
- "deleted_at": "2021-01-01 00:00:00"
}
}
}
List the folders
List the folders.
path Parameters
template_id required | string The ID of the template |
query Parameters
cursor | string Cursor for pagination |
Responses
Response samples
- 200
- 401
- 500
{- "status": "success",
- "message": "Folders retrieved successfully",
- "data": {
- "folders": [
- {
- "id": "123e4567-e89b-12d3-a456-426614174000",
- "template_id": "123e4567-e89b-12d3-a456-426614174000",
- "parent_id": "123e4567-e89b-12d3-a456-426614174000",
- "name": "Directory 1",
- "created_at": "2021-01-01 00:00:00",
- "updated_at": "2021-01-01 00:00:00",
- "deleted_at": "2021-01-01 00:00:00"
}
], - "links": {
- "next": "string",
- "prev": "string"
}
}
}
Add a new folder
Add a new folder.
path Parameters
template_id required | string The ID of the template |
Request Body schema: application/jsonrequired
name | string |
parent_id | string or null |
Responses
Request samples
- Payload
{- "name": "string",
- "parent_id": "string"
}
Response samples
- 200
- 400
- 401
- 500
{- "status": "success",
- "message": "Folder added successfully",
- "data": {
- "folder": {
- "id": "123e4567-e89b-12d3-a456-426614174000",
- "template_id": "123e4567-e89b-12d3-a456-426614174000",
- "parent_id": "123e4567-e89b-12d3-a456-426614174000",
- "name": "Directory 1",
- "created_at": "2021-01-01 00:00:00",
- "updated_at": "2021-01-01 00:00:00",
- "deleted_at": "2021-01-01 00:00:00"
}
}
}
Get the folder
Get the folder.
path Parameters
template_id required | string The ID of the template |
folder_id required | string The ID of the folder |
Responses
Response samples
- 200
- 401
- 500
{- "status": "success",
- "message": "Folder retrieved successfully",
- "data": {
- "folder": {
- "id": "123e4567-e89b-12d3-a456-426614174000",
- "template_id": "123e4567-e89b-12d3-a456-426614174000",
- "parent_id": "123e4567-e89b-12d3-a456-426614174000",
- "name": "Directory 1",
- "created_at": "2021-01-01 00:00:00",
- "updated_at": "2021-01-01 00:00:00",
- "deleted_at": "2021-01-01 00:00:00"
}
}
}
Delete the folder
Delete the folder.
path Parameters
template_id required | string The ID of the template |
folder_id required | string The ID of the folder |
Responses
Response samples
- 200
- 400
- 401
- 500
{- "status": "success",
- "message": "Folder deleted successfully",
- "data": {
- "folder": {
- "id": "123e4567-e89b-12d3-a456-426614174000",
- "template_id": "123e4567-e89b-12d3-a456-426614174000",
- "parent_id": "123e4567-e89b-12d3-a456-426614174000",
- "name": "Directory 1",
- "created_at": "2021-01-01 00:00:00",
- "updated_at": "2021-01-01 00:00:00",
- "deleted_at": "2021-01-01 00:00:00"
}
}
}
Update the folder
Update the folder.
path Parameters
template_id required | string The ID of the template |
folder_id required | string The ID of the folder |
Request Body schema: application/jsonrequired
name | string |
parent_id | string or null |
Responses
Request samples
- Payload
{- "name": "string",
- "parent_id": "string"
}
Response samples
- 200
- 400
- 401
- 500
{- "status": "success",
- "message": "Folder updated successfully",
- "data": {
- "folder": {
- "id": "123e4567-e89b-12d3-a456-426614174000",
- "template_id": "123e4567-e89b-12d3-a456-426614174000",
- "parent_id": "123e4567-e89b-12d3-a456-426614174000",
- "name": "Directory 1",
- "created_at": "2021-01-01 00:00:00",
- "updated_at": "2021-01-01 00:00:00",
- "deleted_at": "2021-01-01 00:00:00"
}
}
}
List the files
List the files.
path Parameters
template_id required | string The ID of the template |
query Parameters
cursor | string Cursor for pagination |
Responses
Response samples
- 200
- 401
- 500
{- "status": "success",
- "message": "Files retrieved successfully",
- "data": {
- "files": [
- {
- "id": "123e4567-e89b-12d3-a456-426614174000",
- "template_id": "123e4567-e89b-12d3-a456-426614174000",
- "template_directory_id": "123e4567-e89b-12d3-a456-426614174000",
- "name": "File 1",
- "mime_type": "text/plain",
- "content": "Content of the file",
- "created_at": "2021-01-01 00:00:00",
- "updated_at": "2021-01-01 00:00:00",
- "deleted_at": "2021-01-01 00:00:00"
}
], - "links": {
- "next": "string",
- "prev": "string"
}
}
}
Add a new file
Add a new file.
path Parameters
template_id required | string The ID of the template |
Request Body schema: application/jsonrequired
name | string |
template_directory_id | string or null |
mime_type | string |
Responses
Request samples
- Payload
{- "name": "string",
- "template_directory_id": "string",
- "mime_type": "string"
}
Response samples
- 200
- 400
- 401
- 500
{- "status": "success",
- "message": "File added successfully",
- "data": {
- "file": {
- "id": "123e4567-e89b-12d3-a456-426614174000",
- "template_id": "123e4567-e89b-12d3-a456-426614174000",
- "template_directory_id": "123e4567-e89b-12d3-a456-426614174000",
- "name": "File 1",
- "mime_type": "text/plain",
- "content": "Content of the file",
- "created_at": "2021-01-01 00:00:00",
- "updated_at": "2021-01-01 00:00:00",
- "deleted_at": "2021-01-01 00:00:00"
}
}
}
Get the file
Get the file.
path Parameters
template_id required | string The ID of the template |
file_id required | string The ID of the file |
Responses
Response samples
- 200
- 401
- 500
{- "status": "success",
- "message": "File retrieved successfully",
- "data": {
- "file": {
- "id": "123e4567-e89b-12d3-a456-426614174000",
- "template_id": "123e4567-e89b-12d3-a456-426614174000",
- "template_directory_id": "123e4567-e89b-12d3-a456-426614174000",
- "name": "File 1",
- "mime_type": "text/plain",
- "content": "Content of the file",
- "created_at": "2021-01-01 00:00:00",
- "updated_at": "2021-01-01 00:00:00",
- "deleted_at": "2021-01-01 00:00:00"
}
}
}
Delete the file
Delete the file.
path Parameters
template_id required | string The ID of the template |
file_id required | string The ID of the file |
Responses
Response samples
- 200
- 401
- 500
{- "status": "success",
- "message": "File deleted successfully",
- "data": {
- "file": {
- "id": "123e4567-e89b-12d3-a456-426614174000",
- "template_id": "123e4567-e89b-12d3-a456-426614174000",
- "template_directory_id": "123e4567-e89b-12d3-a456-426614174000",
- "name": "File 1",
- "mime_type": "text/plain",
- "content": "Content of the file",
- "created_at": "2021-01-01 00:00:00",
- "updated_at": "2021-01-01 00:00:00",
- "deleted_at": "2021-01-01 00:00:00"
}
}
}
Update the file
Update the file.
path Parameters
template_id required | string The ID of the template |
file_id required | string The ID of the file |
Request Body schema: application/jsonrequired
name | string |
template_directory_id | string or null |
mime_type | string |
content | string or null |
Responses
Request samples
- Payload
{- "name": "string",
- "template_directory_id": "string",
- "mime_type": "string",
- "content": "string"
}
Response samples
- 200
- 400
- 401
- 500
{- "status": "success",
- "message": "File updated successfully",
- "data": {
- "file": {
- "id": "123e4567-e89b-12d3-a456-426614174000",
- "template_id": "123e4567-e89b-12d3-a456-426614174000",
- "template_directory_id": "123e4567-e89b-12d3-a456-426614174000",
- "name": "File 1",
- "mime_type": "text/plain",
- "content": "Content of the file",
- "created_at": "2021-01-01 00:00:00",
- "updated_at": "2021-01-01 00:00:00",
- "deleted_at": "2021-01-01 00:00:00"
}
}
}
List the fields
List the fields.
path Parameters
template_id required | string The ID of the template |
query Parameters
cursor | string Cursor for pagination |
Responses
Response samples
- 200
- 401
- 500
{- "status": "success",
- "message": "Fields retrieved successfully",
- "data": {
- "fields": [
- {
- "id": "123e4567-e89b-12d3-a456-426614174000",
- "template_id": "123e4567-e89b-12d3-a456-426614174000",
- "advanced": false,
- "type": "text",
- "required": false,
- "secret": false,
- "label": "Label",
- "key": "key",
- "value": "Value",
- "min": 0,
- "max": 0,
- "step": 0,
- "set_on_create": false,
- "set_on_update": false,
- "created_at": "2021-01-01 00:00:00",
- "updated_at": "2021-01-01 00:00:00",
- "deleted_at": "2021-01-01 00:00:00"
}
], - "links": {
- "next": "string",
- "prev": "string"
}
}
}
Add a new field
Add a new field.
path Parameters
template_id required | string The ID of the template |
Request Body schema: application/jsonrequired
type | string |
label | string |
key | string |
value | string or null |
required | boolean or null |
secret | boolean or null |
set_on_create | boolean or null |
set_on_update | boolean or null |
min | number or null |
max | number or null |
step | number or null |
Responses
Request samples
- Payload
{- "type": "string",
- "label": "string",
- "key": "string",
- "value": "string",
- "required": true,
- "secret": true,
- "set_on_create": true,
- "set_on_update": true,
- "min": 0,
- "max": 0,
- "step": 0
}
Response samples
- 200
- 400
- 401
- 500
{- "status": "success",
- "message": "Field added successfully",
- "data": {
- "field": {
- "id": "123e4567-e89b-12d3-a456-426614174000",
- "template_id": "123e4567-e89b-12d3-a456-426614174000",
- "advanced": false,
- "type": "text",
- "required": false,
- "secret": false,
- "label": "Label",
- "key": "key",
- "value": "Value",
- "min": 0,
- "max": 0,
- "step": 0,
- "set_on_create": false,
- "set_on_update": false,
- "created_at": "2021-01-01 00:00:00",
- "updated_at": "2021-01-01 00:00:00",
- "deleted_at": "2021-01-01 00:00:00"
}
}
}
Get the field
Get the field.
path Parameters
template_id required | string The ID of the template |
field_id required | string The ID of the field |
Responses
Response samples
- 200
- 401
- 500
{- "status": "success",
- "message": "Field retrieved successfully",
- "data": {
- "field": {
- "id": "123e4567-e89b-12d3-a456-426614174000",
- "template_id": "123e4567-e89b-12d3-a456-426614174000",
- "advanced": false,
- "type": "text",
- "required": false,
- "secret": false,
- "label": "Label",
- "key": "key",
- "value": "Value",
- "min": 0,
- "max": 0,
- "step": 0,
- "set_on_create": false,
- "set_on_update": false,
- "created_at": "2021-01-01 00:00:00",
- "updated_at": "2021-01-01 00:00:00",
- "deleted_at": "2021-01-01 00:00:00"
}
}
}
Update the field
Update the field.
path Parameters
template_id required | string The ID of the template |
field_id required | string The ID of the field |
Request Body schema: application/jsonrequired
type | string |
label | string |
key | string |
value | string or null |
required | boolean or null |
secret | boolean or null |
set_on_create | boolean or null |
set_on_update | boolean or null |
min | number or null |
max | number or null |
step | number or null |
Responses
Request samples
- Payload
{- "type": "string",
- "label": "string",
- "key": "string",
- "value": "string",
- "required": true,
- "secret": true,
- "set_on_create": true,
- "set_on_update": true,
- "min": 0,
- "max": 0,
- "step": 0
}
Response samples
- 200
- 400
- 401
- 500
{- "status": "success",
- "message": "Field updated successfully",
- "data": {
- "field": {
- "id": "123e4567-e89b-12d3-a456-426614174000",
- "template_id": "123e4567-e89b-12d3-a456-426614174000",
- "advanced": false,
- "type": "text",
- "required": false,
- "secret": false,
- "label": "Label",
- "key": "key",
- "value": "Value",
- "min": 0,
- "max": 0,
- "step": 0,
- "set_on_create": false,
- "set_on_update": false,
- "created_at": "2021-01-01 00:00:00",
- "updated_at": "2021-01-01 00:00:00",
- "deleted_at": "2021-01-01 00:00:00"
}
}
}
List the options
List the options.
path Parameters
template_id required | string The ID of the template |
field_id required | string The ID of the field |
query Parameters
cursor | string Cursor for pagination |
Responses
Response samples
- 200
- 401
- 500
{- "status": "success",
- "message": "Options retrieved successfully",
- "data": {
- "options": [
- {
- "id": "123e4567-e89b-12d3-a456-426614174000",
- "template_field_id": "123e4567-e89b-12d3-a456-426614174000",
- "label": "Label",
- "value": "Value",
- "default": false,
- "created_at": "2021-01-01 00:00:00",
- "updated_at": "2021-01-01 00:00:00",
- "deleted_at": "2021-01-01 00:00:00"
}
], - "links": {
- "next": "string",
- "prev": "string"
}
}
}
Add a new option
Add a new option.
path Parameters
template_id required | string The ID of the template |
field_id required | string The ID of the field |
Request Body schema: application/jsonrequired
label | string |
value | string |
default | boolean or null |
Responses
Request samples
- Payload
{- "label": "string",
- "value": "string",
- "default": true
}
Response samples
- 200
- 400
- 401
- 500
{- "status": "success",
- "message": "Option added successfully",
- "data": {
- "option": {
- "id": "123e4567-e89b-12d3-a456-426614174000",
- "template_field_id": "123e4567-e89b-12d3-a456-426614174000",
- "label": "Label",
- "value": "Value",
- "default": false,
- "created_at": "2021-01-01 00:00:00",
- "updated_at": "2021-01-01 00:00:00",
- "deleted_at": "2021-01-01 00:00:00"
}
}
}
Get the option
Get the option.
path Parameters
template_id required | string The ID of the template |
field_id required | string The ID of the field |
option_id required | string The ID of the option |
Responses
Response samples
- 200
- 401
- 500
{- "status": "success",
- "message": "Option retrieved successfully",
- "data": {
- "option": {
- "id": "123e4567-e89b-12d3-a456-426614174000",
- "template_field_id": "123e4567-e89b-12d3-a456-426614174000",
- "label": "Label",
- "value": "Value",
- "default": false,
- "created_at": "2021-01-01 00:00:00",
- "updated_at": "2021-01-01 00:00:00",
- "deleted_at": "2021-01-01 00:00:00"
}
}
}
Delete the option
Delete the option.
path Parameters
template_id required | string The ID of the template |
field_id required | string The ID of the field |
option_id required | string The ID of the option |
Responses
Response samples
- 200
- 401
- 500
{- "status": "success",
- "message": "Option deleted successfully",
- "data": {
- "option": {
- "id": "123e4567-e89b-12d3-a456-426614174000",
- "template_field_id": "123e4567-e89b-12d3-a456-426614174000",
- "label": "Label",
- "value": "Value",
- "default": false,
- "created_at": "2021-01-01 00:00:00",
- "updated_at": "2021-01-01 00:00:00",
- "deleted_at": "2021-01-01 00:00:00"
}
}
}
Update the option
Update the option.
path Parameters
template_id required | string The ID of the template |
field_id required | string The ID of the field |
option_id required | string The ID of the option |
Request Body schema: application/jsonrequired
label | string |
value | string |
default | boolean or null |
Responses
Request samples
- Payload
{- "label": "string",
- "value": "string",
- "default": true
}
Response samples
- 200
- 400
- 401
- 500
{- "status": "success",
- "message": "Option updated successfully",
- "data": {
- "option": {
- "id": "123e4567-e89b-12d3-a456-426614174000",
- "template_field_id": "123e4567-e89b-12d3-a456-426614174000",
- "label": "Label",
- "value": "Value",
- "default": false,
- "created_at": "2021-01-01 00:00:00",
- "updated_at": "2021-01-01 00:00:00",
- "deleted_at": "2021-01-01 00:00:00"
}
}
}
List the ports
List the ports.
path Parameters
template_id required | string The ID of the template |
query Parameters
cursor | string Cursor for pagination |
Responses
Response samples
- 200
- 401
- 500
{- "status": "success",
- "message": "Ports retrieved successfully",
- "data": {
- "ports": [
- {
- "id": "123e4567-e89b-12d3-a456-426614174000",
- "template_id": "123e4567-e89b-12d3-a456-426614174000",
- "group": "Group",
- "claim": "Claim",
- "preferred_port": 0,
- "random": false,
- "created_at": "2021-01-01 00:00:00",
- "updated_at": "2021-01-01 00:00:00",
- "deleted_at": "2021-01-01 00:00:00"
}
], - "links": {
- "next": "string",
- "prev": "string"
}
}
}
Add a new port
Add a new port.
path Parameters
template_id required | string The ID of the template |
Request Body schema: application/jsonrequired
group | string |
claim | string or null |
preferred_port | number or null |
random | boolean or null |
Responses
Request samples
- Payload
{- "group": "string",
- "claim": "string",
- "preferred_port": 0,
- "random": true
}
Response samples
- 200
- 400
- 401
- 500
{- "status": "success",
- "message": "Port added successfully",
- "data": {
- "port": {
- "id": "123e4567-e89b-12d3-a456-426614174000",
- "template_id": "123e4567-e89b-12d3-a456-426614174000",
- "group": "Group",
- "claim": "Claim",
- "preferred_port": 0,
- "random": false,
- "created_at": "2021-01-01 00:00:00",
- "updated_at": "2021-01-01 00:00:00",
- "deleted_at": "2021-01-01 00:00:00"
}
}
}
Get the port
Get the port.
path Parameters
template_id required | string The ID of the template |
port_id required | string The ID of the port |
Responses
Response samples
- 200
- 401
- 500
{- "status": "success",
- "message": "Port retrieved successfully",
- "data": {
- "port": {
- "id": "123e4567-e89b-12d3-a456-426614174000",
- "template_id": "123e4567-e89b-12d3-a456-426614174000",
- "group": "Group",
- "claim": "Claim",
- "preferred_port": 0,
- "random": false,
- "created_at": "2021-01-01 00:00:00",
- "updated_at": "2021-01-01 00:00:00",
- "deleted_at": "2021-01-01 00:00:00"
}
}
}
Delete the port
Delete the port.
path Parameters
template_id required | string The ID of the template |
port_id required | string The ID of the port |
Responses
Response samples
- 200
- 401
- 500
{- "status": "success",
- "message": "Port deleted successfully",
- "data": {
- "port": {
- "id": "123e4567-e89b-12d3-a456-426614174000",
- "template_id": "123e4567-e89b-12d3-a456-426614174000",
- "group": "Group",
- "claim": "Claim",
- "preferred_port": 0,
- "random": false,
- "created_at": "2021-01-01 00:00:00",
- "updated_at": "2021-01-01 00:00:00",
- "deleted_at": "2021-01-01 00:00:00"
}
}
}
Update the port
Update the port.
path Parameters
template_id required | string The ID of the template |
port_id required | string The ID of the port |
Request Body schema: application/jsonrequired
group | string |
claim | string or null |
preferred_port | number or null |
random | boolean or null |
Responses
Request samples
- Payload
{- "group": "string",
- "claim": "string",
- "preferred_port": 0,
- "random": true
}
Response samples
- 200
- 400
- 401
- 500
{- "status": "success",
- "message": "Port updated successfully",
- "data": {
- "port": {
- "id": "123e4567-e89b-12d3-a456-426614174000",
- "template_id": "123e4567-e89b-12d3-a456-426614174000",
- "group": "Group",
- "claim": "Claim",
- "preferred_port": 0,
- "random": false,
- "created_at": "2021-01-01 00:00:00",
- "updated_at": "2021-01-01 00:00:00",
- "deleted_at": "2021-01-01 00:00:00"
}
}
}
Add a new user
Add a new user.
Request Body schema: application/jsonrequired
name | string |
string | |
password | string or null |
password_confirmation | string or null |
roles | Array of strings or null |
permissions | Array of strings or null |
Responses
Request samples
- Payload
{- "name": "string",
- "email": "string",
- "password": "string",
- "password_confirmation": "string",
- "roles": [
- "string"
], - "permissions": [
- "string"
]
}
Response samples
- 200
- 400
- 401
- 500
{- "status": "success",
- "message": "User created successfully",
- "data": {
- "user": {
- "id": "1",
- "name": "John Doe",
- "email": "john.doe@example.com",
- "email_verified_at": "2021-01-01T00:00:00Z",
- "password": "password123",
- "remember_token": "remember_token123",
- "created_at": "2021-01-01 00:00:00",
- "updated_at": "2021-01-01 00:00:00"
}
}
}
Response samples
- 200
- 400
- 401
- 500
{- "status": "success",
- "message": "User deleted successfully",
- "data": {
- "user": {
- "id": "1",
- "name": "John Doe",
- "email": "john.doe@example.com",
- "email_verified_at": "2021-01-01T00:00:00Z",
- "password": "password123",
- "remember_token": "remember_token123",
- "created_at": "2021-01-01 00:00:00",
- "updated_at": "2021-01-01 00:00:00"
}
}
}
Update a user
Update the user.
path Parameters
user_id required | string The ID of the user |
Request Body schema: application/jsonrequired
name | string |
string | |
password | string or null |
password_confirmation | string or null |
roles | Array of strings or null |
permissions | Array of strings or null |
Responses
Request samples
- Payload
{- "name": "string",
- "email": "string",
- "password": "string",
- "password_confirmation": "string",
- "roles": [
- "string"
], - "permissions": [
- "string"
]
}
Response samples
- 200
- 400
- 401
- 500
{- "status": "success",
- "message": "User updated successfully",
- "data": {
- "user": {
- "id": "1",
- "name": "John Doe",
- "email": "john.doe@example.com",
- "email_verified_at": "2021-01-01T00:00:00Z",
- "password": "password123",
- "remember_token": "remember_token123",
- "created_at": "2021-01-01 00:00:00",
- "updated_at": "2021-01-01 00:00:00"
}
}
}