Skip to content

Commit 59b3849

Browse files
authored
Add views API (#331)
1 parent 2f8331c commit 59b3849

File tree

7 files changed

+191
-0
lines changed

7 files changed

+191
-0
lines changed

docs.json

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -718,6 +718,16 @@
718718
"restapi/endpoints/removeUserFromOrg"
719719
]
720720
},
721+
{
722+
"group": "Views endpoints",
723+
"pages": [
724+
"restapi/endpoints/getViews",
725+
"restapi/endpoints/getView",
726+
"restapi/endpoints/createView",
727+
"restapi/endpoints/updateView",
728+
"restapi/endpoints/deleteView"
729+
]
730+
},
721731
{
722732
"group": "Virtual fields endpoints",
723733
"pages": [

restapi/endpoints/createView.mdx

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,4 @@
1+
---
2+
title: Create view
3+
openapi: "v2 post /views"
4+
---

restapi/endpoints/deleteView.mdx

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,4 @@
1+
---
2+
title: Delete view
3+
openapi: "v2 delete /views/{id}"
4+
---

restapi/endpoints/getView.mdx

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,4 @@
1+
---
2+
title: Retrieve view
3+
openapi: "v2 get /views/{id}"
4+
---

restapi/endpoints/getViews.mdx

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,4 @@
1+
---
2+
title: List all views
3+
openapi: "v2 get /views"
4+
---

restapi/endpoints/updateView.mdx

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,4 @@
1+
---
2+
title: Update view
3+
openapi: "v2 put /views/{id}"
4+
---

restapi/versions/v2.json

Lines changed: 161 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2566,6 +2566,167 @@
25662566
}
25672567
}
25682568
}
2569+
},
2570+
"/views": {
2571+
"get": {
2572+
"security": [
2573+
{
2574+
"Auth": [
2575+
"views|read"
2576+
]
2577+
}
2578+
],
2579+
"tags": [
2580+
"views"
2581+
],
2582+
"operationId": "getViews",
2583+
"responses": {
2584+
"200": {
2585+
"description": "View",
2586+
"content": {
2587+
"application/json": {
2588+
"schema": {
2589+
"type": "array",
2590+
"items": {
2591+
"$ref": "#/components/schemas/View"
2592+
}
2593+
}
2594+
}
2595+
}
2596+
}
2597+
}
2598+
},
2599+
"post": {
2600+
"security": [
2601+
{
2602+
"Auth": [
2603+
"views|create"
2604+
]
2605+
}
2606+
],
2607+
"tags": [
2608+
"views"
2609+
],
2610+
"operationId": "createView",
2611+
"requestBody": {
2612+
"$ref": "#/components/requestBodies/View"
2613+
},
2614+
"responses": {
2615+
"200": {
2616+
"description": "View",
2617+
"content": {
2618+
"application/json": {
2619+
"schema": {
2620+
"$ref": "#/components/schemas/View"
2621+
}
2622+
}
2623+
}
2624+
}
2625+
}
2626+
}
2627+
},
2628+
"/views/{id}": {
2629+
"get": {
2630+
"security": [
2631+
{
2632+
"Auth": [
2633+
"views|read"
2634+
]
2635+
}
2636+
],
2637+
"tags": [
2638+
"views"
2639+
],
2640+
"operationId": "getView",
2641+
"parameters": [
2642+
{
2643+
"name": "id",
2644+
"in": "path",
2645+
"required": true,
2646+
"schema": {
2647+
"type": "string"
2648+
}
2649+
}
2650+
],
2651+
"responses": {
2652+
"200": {
2653+
"description": "View",
2654+
"content": {
2655+
"application/json": {
2656+
"schema": {
2657+
"$ref": "#/components/schemas/View"
2658+
}
2659+
}
2660+
}
2661+
}
2662+
}
2663+
},
2664+
"put": {
2665+
"security": [
2666+
{
2667+
"Auth": [
2668+
"views|update"
2669+
]
2670+
}
2671+
],
2672+
"tags": [
2673+
"views"
2674+
],
2675+
"operationId": "updateView",
2676+
"parameters": [
2677+
{
2678+
"name": "id",
2679+
"in": "path",
2680+
"required": true,
2681+
"schema": {
2682+
"type": "string"
2683+
}
2684+
}
2685+
],
2686+
"requestBody": {
2687+
"$ref": "#/components/requestBodies/View"
2688+
},
2689+
"responses": {
2690+
"200": {
2691+
"description": "View",
2692+
"content": {
2693+
"application/json": {
2694+
"schema": {
2695+
"$ref": "#/components/schemas/View"
2696+
}
2697+
}
2698+
}
2699+
}
2700+
}
2701+
},
2702+
"delete": {
2703+
"security": [
2704+
{
2705+
"Auth": [
2706+
"views|delete"
2707+
]
2708+
}
2709+
],
2710+
"tags": [
2711+
"views"
2712+
],
2713+
"operationId": "deleteView",
2714+
"parameters": [
2715+
{
2716+
"name": "id",
2717+
"in": "path",
2718+
"required": true,
2719+
"schema": {
2720+
"type": "string"
2721+
}
2722+
}
2723+
],
2724+
"responses": {
2725+
"204": {
2726+
"description": "(empty)"
2727+
}
2728+
}
2729+
}
25692730
}
25702731
},
25712732
"components": {

0 commit comments

Comments
 (0)