mirror of https://github.com/01-edu/public.git
You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
136 lines
3.8 KiB
136 lines
3.8 KiB
{ |
|
"search": [ |
|
"[user!]!", |
|
"[object!]!", |
|
"[transaction!]!", |
|
"[progress_view!]!", |
|
"[result!]!", |
|
"query", |
|
"arguments" |
|
], |
|
"root_types": [{ "query": "query" }, { "arguments": "arguments" }], |
|
"query": { |
|
"user": "[user!]!", |
|
"object": "[object!]!", |
|
"transaction": "[transaction!]!", |
|
"progress_view": "[progress_view!]!", |
|
"result": "[result!]!" |
|
}, |
|
"types": [ |
|
{ |
|
"user": { |
|
"id": "ID!", |
|
"attrs": "Jsonb!", |
|
"createdAt": "String!", |
|
"discordDMChannelId": "String!", |
|
"discordId": "String!", |
|
"discordLogin": "String!", |
|
"githubId": "String!", |
|
"githubLogin": "String!", |
|
"profile": "Jsonb!", |
|
"updatedAt": "String!" |
|
}, |
|
"comment": "Fetch data from the table: \"user\"\nThis table will have information about the user" |
|
}, |
|
{ |
|
"object": { |
|
"id": "ID!", |
|
"attrs": "Jsonb!", |
|
"authorId": "String!", |
|
"childrenAttrs": "String!", |
|
"createdAt": "String!", |
|
"externalRelationUrl": "String!", |
|
"name": "String!", |
|
"type": "String!", |
|
"status": "String!", |
|
"updatedAt": "String!" |
|
}, |
|
"comment": "Fetch data from the table: \"object\"\nThis table will give you information about all objects (exercises/projects)" |
|
}, |
|
{ |
|
"transaction": { |
|
"id": "ID!", |
|
"attrs": "Jsonb!", |
|
"amount": "Int!", |
|
"createdAt": "String!", |
|
"type": "String!", |
|
"userId": "Int!" |
|
}, |
|
"comment": "Fetch data from the table: \"transaction\"\nThis table will give you access to XP and audits ratio" |
|
}, |
|
{ |
|
"progress_view": { |
|
"id": "ID!", |
|
"attrs": "Jsonb!", |
|
"bestResultId": "Int!", |
|
"createdAt": "String!", |
|
"eventId": "Int!", |
|
"groupId": "Int!", |
|
"objectId": "Int!", |
|
"updatedAt": "String!", |
|
"userId": "Int!" |
|
}, |
|
"comment": "Fetch data from the table: \"progress\"\nBoth progress and result table will give you the student progression" |
|
}, |
|
{ |
|
"result": { |
|
"id": "ID!", |
|
"progressId": "Int!", |
|
"attrs": "Jsonb!", |
|
"createdAt": "String!", |
|
"grade": "Int!", |
|
"updatedAt": "String!" |
|
}, |
|
"comment": "Fetch data from the table: \"result\"\nBoth progress and result table will give you the student progression" |
|
} |
|
], |
|
"arguments": { |
|
"where": { |
|
"description": "bool_exp", |
|
"expressions": [ |
|
"_eq (equal)", |
|
"_gt (grater then)", |
|
"_gte (grater then equal)", |
|
"_in (in)", |
|
"_is_null (boolean)", |
|
"_lt (lower then)", |
|
"_lte (lower then equal)", |
|
"_neq (not equal)", |
|
"_nin (not in)" |
|
], |
|
"example": "user(where: {id: { _eq: x } }){\n id \n}", |
|
"comment": "filter the rows returned" |
|
}, |
|
"order_by": { |
|
"description": "[order_by!]", |
|
"expressions": [ |
|
"asc (ascending)", |
|
"asc_nulls_first", |
|
"asc_nulls_last", |
|
"desc (descending)", |
|
"desc_nulls_first", |
|
"asc_nulls_last" |
|
], |
|
"example": "user(order_by: {id: desc }){\n id \n}", |
|
"comment": "sort the rows by one or more columns" |
|
}, |
|
"limit": { |
|
"description": "Int", |
|
"expressions": ["Int"], |
|
"example": "user(limit: 1 ){\n id \n}", |
|
"comment": "limit the number of rows returned" |
|
}, |
|
"distinct_on": { |
|
"description": "column name", |
|
"expressions": ["column name"], |
|
"example": "object(distinct_on: name, where: { name:{ _eq:\"forum\" } }){\n name \n}", |
|
"comment": "distinct select on columns" |
|
}, |
|
"offset": { |
|
"description": "int", |
|
"expressions": ["Int"], |
|
"example": "object(distinct_on: name, where: { name:{ _eq:\"forum\" } }){\n name\n }", |
|
"comment": "skip the first n rows by one or more columns" |
|
} |
|
} |
|
}
|
|
|