Add
Learn how to create a dashboard.
Endpoint
POST /api/v1/dashboards
Permissions
COMING SOON!
Responses
Status Code | Description |
---|---|
201 | indicates the request has succeeded |
400 | indicates a bad request |
401 | indicates the user does not have proper permissions |
500 | indicates a server error |
Sample
This section assumes you already know how to authenticate to the API.
To authenticate to the API, please review the authentication documentation.
File
{
"name": "test",
"created_at": 1721251709,
"created_by": "Octocat",
"updated_at": 1721251709,
"updated_by": "Octocat",
"admins": [
{
"id": 1,
"name": "Octocat",
"active": true
}
],
"repos": [
{
"name": "Octocat/myvela"
}
]
}
Request
curl \
-X POST \
-H "Authorization: Bearer <token>" \
-H "Content-Type: application/json" \
-d "@data.json" \
"http://127.0.0.1:8080/api/v1/dashboards"
Response
{
"id": "f460e0a1-a6a5-4724-89e8-4b2b39e12012",
"name": "test",
"created_at": 1721251709,
"created_by": "Octocat",
"updated_at": 1721253772,
"updated_by": "Octocat",
"admins": [
{
"id": 1,
"name": "Octocat",
"active": true
}
],
"repos": [
{
"id": 293,
"name": "Octocat/myvela"
}
]
}
Last modified July 25, 2024: chore(api): add dashboards API documentation (#421) (72d67389)