mirror of
https://github.com/hasura/graphql-engine.git
synced 2024-12-15 17:31:56 +03:00
332 lines
7.1 KiB
JSON
332 lines
7.1 KiB
JSON
{
|
|
"description": "check wildcards",
|
|
"depends": [
|
|
"permission.json"
|
|
],
|
|
"items": [
|
|
{
|
|
"name": "create author B1 as admin",
|
|
"url": "/api/1/table/author/insert",
|
|
"role": "admin",
|
|
"user_id": "1",
|
|
"status_code": 200,
|
|
"request": {
|
|
"objects": [{
|
|
"name": "James Bond",
|
|
"auth_id": 1,
|
|
"email": "google@gmail.com"
|
|
}],
|
|
"returning": [
|
|
"id"
|
|
]
|
|
},
|
|
"response": {
|
|
"affected_rows": 1,
|
|
"returning": [
|
|
{
|
|
"id": 1
|
|
}
|
|
]
|
|
},
|
|
"method": "POST"
|
|
},
|
|
{
|
|
"name": "create category",
|
|
"url": "/api/1/table/category/insert",
|
|
"role": "admin",
|
|
"user_id": "1",
|
|
"status_code": 200,
|
|
"request": {
|
|
"objects": [{
|
|
"name": "Haskell",
|
|
"description": "Haskell Haskell Haskell"
|
|
}],
|
|
"returning": [
|
|
"id"
|
|
]
|
|
},
|
|
"response": {
|
|
"affected_rows": 1,
|
|
"returning": [
|
|
{
|
|
"id": 1
|
|
}
|
|
]
|
|
},
|
|
"method": "POST"
|
|
},
|
|
{
|
|
"name": "create article under B1",
|
|
"url": "/api/1/table/article/insert",
|
|
"role": "admin",
|
|
"user_id": "1",
|
|
"status_code": 200,
|
|
"request": {
|
|
"objects": [{
|
|
"title": "Dependent Haskell",
|
|
"author_id": 1,
|
|
"content": "Heloo world",
|
|
"is_published": false,
|
|
"rating": 3,
|
|
"category_id": 1
|
|
}],
|
|
"returning": [
|
|
"id"
|
|
]
|
|
},
|
|
"response": {
|
|
"affected_rows": 1,
|
|
"returning": [
|
|
{
|
|
"id": 1
|
|
}
|
|
]
|
|
},
|
|
"method": "POST"
|
|
},
|
|
{
|
|
"name": "selct * as admin",
|
|
"url": "/api/1/table/author/select",
|
|
"role": "admin",
|
|
"user_id": "1",
|
|
"status_code": 200,
|
|
"request": {
|
|
"columns": [
|
|
"*"
|
|
]
|
|
},
|
|
"response": [
|
|
{
|
|
"name": "James Bond",
|
|
"id": 1,
|
|
"auth_id": 1,
|
|
"email": "google@gmail.com"
|
|
}
|
|
],
|
|
"method": "POST"
|
|
},
|
|
{
|
|
"name": "selct *.* as admin",
|
|
"url": "/api/1/table/author/select",
|
|
"role": "admin",
|
|
"user_id": "1",
|
|
"status_code": 200,
|
|
"request": {
|
|
"columns": [
|
|
"*.*"
|
|
]
|
|
},
|
|
"response": [
|
|
{
|
|
"email": "google@gmail.com",
|
|
"auth_id": 1,
|
|
"name": "James Bond",
|
|
"articles": [
|
|
{
|
|
"rating": 3,
|
|
"author_id": 1,
|
|
"category_id": 1,
|
|
"content": "Heloo world",
|
|
"is_published": false,
|
|
"id": 1,
|
|
"title": "Dependent Haskell"
|
|
}
|
|
],
|
|
"id": 1
|
|
}
|
|
],
|
|
"method": "POST"
|
|
},
|
|
{
|
|
"name": "selct *.* as admin",
|
|
"url": "/api/1/table/author/select",
|
|
"role": "admin",
|
|
"user_id": "1",
|
|
"status_code": 200,
|
|
"request": {
|
|
"columns": [
|
|
"*.*",
|
|
"name"
|
|
]
|
|
},
|
|
"response": [
|
|
{
|
|
"email": "google@gmail.com",
|
|
"auth_id": 1,
|
|
"name": "James Bond",
|
|
"articles": [
|
|
{
|
|
"rating": 3,
|
|
"author_id": 1,
|
|
"category_id": 1,
|
|
"content": "Heloo world",
|
|
"is_published": false,
|
|
"id": 1,
|
|
"title": "Dependent Haskell"
|
|
}
|
|
],
|
|
"id": 1
|
|
}
|
|
],
|
|
"method": "POST"
|
|
},
|
|
{
|
|
"name": "selct *.* as admin",
|
|
"url": "/api/1/table/author/select",
|
|
"role": "admin",
|
|
"user_id": "1",
|
|
"status_code": 200,
|
|
"request": {
|
|
"columns": [
|
|
"*.*",
|
|
{
|
|
"name": "articles",
|
|
"columns": [
|
|
"title"
|
|
]
|
|
}
|
|
]
|
|
},
|
|
"response": [
|
|
{
|
|
"name": "James Bond",
|
|
"id": 1,
|
|
"auth_id": 1,
|
|
"email": "google@gmail.com",
|
|
"articles": [
|
|
{
|
|
"title": "Dependent Haskell"
|
|
}
|
|
]
|
|
}
|
|
],
|
|
"method": "POST"
|
|
},
|
|
{
|
|
"name": "selct *.*.* as admin",
|
|
"url": "/api/1/table/author/select",
|
|
"role": "admin",
|
|
"user_id": "1",
|
|
"status_code": 200,
|
|
"request": {
|
|
"columns": [
|
|
"*.*.*"
|
|
]
|
|
},
|
|
"response": [
|
|
{
|
|
"email": "google@gmail.com",
|
|
"auth_id": 1,
|
|
"name": "James Bond",
|
|
"articles": [
|
|
{
|
|
"rating": 3,
|
|
"author_id": 1,
|
|
"category_id": 1,
|
|
"category": {
|
|
"name": "Haskell",
|
|
"id": 1,
|
|
"description": "Haskell Haskell Haskell"
|
|
},
|
|
"content": "Heloo world",
|
|
"is_published": false,
|
|
"author": {
|
|
"email": "google@gmail.com",
|
|
"auth_id": 1,
|
|
"name": "James Bond",
|
|
"id": 1
|
|
},
|
|
"id": 1,
|
|
"title": "Dependent Haskell"
|
|
}
|
|
],
|
|
"id": 1
|
|
}
|
|
],
|
|
"method": "POST"
|
|
},
|
|
{
|
|
"name": "selct *.*.* as admin",
|
|
"url": "/api/1/table/author/select",
|
|
"role": "admin",
|
|
"user_id": "1",
|
|
"status_code": 200,
|
|
"request": {
|
|
"columns": [
|
|
"*.*.*",
|
|
"*.*"
|
|
]
|
|
},
|
|
"response": [
|
|
{
|
|
"email": "google@gmail.com",
|
|
"auth_id": 1,
|
|
"name": "James Bond",
|
|
"articles": [
|
|
{
|
|
"rating": 3,
|
|
"author_id": 1,
|
|
"category_id": 1,
|
|
"category": {
|
|
"name": "Haskell",
|
|
"id": 1,
|
|
"description": "Haskell Haskell Haskell"
|
|
},
|
|
"content": "Heloo world",
|
|
"is_published": false,
|
|
"author": {
|
|
"email": "google@gmail.com",
|
|
"auth_id": 1,
|
|
"name": "James Bond",
|
|
"id": 1
|
|
},
|
|
"id": 1,
|
|
"title": "Dependent Haskell"
|
|
}
|
|
],
|
|
"id": 1
|
|
}
|
|
],
|
|
"method": "POST"
|
|
},
|
|
{
|
|
"name": "select * (articles *) as admin",
|
|
"url": "/api/1/table/author/select",
|
|
"role": "admin",
|
|
"user_id": "1",
|
|
"status_code": 200,
|
|
"request": {
|
|
"columns": [
|
|
"*",
|
|
{
|
|
"name": "articles",
|
|
"columns": [
|
|
"*"
|
|
]
|
|
}
|
|
]
|
|
},
|
|
"response": [
|
|
{
|
|
"email": "google@gmail.com",
|
|
"auth_id": 1,
|
|
"name": "James Bond",
|
|
"articles": [
|
|
{
|
|
"rating": 3,
|
|
"author_id": 1,
|
|
"category_id": 1,
|
|
"content": "Heloo world",
|
|
"is_published": false,
|
|
"id": 1,
|
|
"title": "Dependent Haskell"
|
|
}
|
|
],
|
|
"id": 1
|
|
}
|
|
],
|
|
"method": "POST"
|
|
}
|
|
]
|
|
}
|