From 4f9f4320ef3d11e150d89ba86e9b7d99aab78ee0 Mon Sep 17 00:00:00 2001 From: Guy Korland Date: Mon, 9 Sep 2024 11:05:09 +0300 Subject: [PATCH] format json --- integration/rest.md | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) diff --git a/integration/rest.md b/integration/rest.md index 5072efb..12e4254 100644 --- a/integration/rest.md +++ b/integration/rest.md @@ -7,7 +7,14 @@ parent: "integration" | Request Name | Request Endpoint | Request Method | Request Headers | Request Parameters | Body | Successful Response | Description| | ------------- | ---------------- | -------------- | --------------- | ------------------ | ---- | ------------------- | ---------- | -| Login | [/api/auth/providers](http://localhost:3000/api/auth/providers) | GET | None | None | None | Status Code: 200
{
"credentials": {
"id": "credentials",
"name": "Credentials",
"type": "credentials",
"signinUrl": "http://localhost:3000/api/auth/signin/credentials",
"callbackUrl": "http://localhost:3000/api/auth/callback/credentials"
}
}
| This request is used for user authentication. | +| Login | [/api/auth/providers](http://localhost:3000/api/auth/providers) | GET | None | None | None | Status Code: 200
{"credentials": {\
+"id": "credentials",\
+"name": "Credentials",\
+"type": "credentials",\
+"signinUrl": "http://localhost:3000/api/auth/signin/credentials",\
+"callbackUrl": "http://localhost:3000/api/auth/callback/credentials"\
+}\
+}
| This request is used for user authentication. | | Logout | [/api/auth/signout](http://localhost:3000/api/auth/signout) | POST | Content-Type: application/x-www-form-urlencoded | None | x-www-form-urlencoded:
1- Key: csrfToken – value: insert csrfToken
2- Key: callbackUrl – value: /login
3- Key: json - value: true | Status Code: 200
{
"url": "http://localhost:3000/api/auth/signout?csrf=true"
} |
This request is used to sign out users, ending their current authenticated session and logging them out of the system | | Modify config role | [/api/graph?config=MAX_QUEUED_QUERIES&value=10](http://localhost:3000/api/graph?config=MAX_QUEUED_QUERIES&value=10) | POST | Authorization: Cookie | 1\. Key: config - Value: MAX_QUEUED_QUERIES (required)
2\. Key: value - Value: A number (required) | None | Status Code: 200
Response Body:
{ "config": "OK" } | This request is used to set a configuration value for MAX_QUEUED_QUERIES. It accepts a number as the value for the configuration and requires authorization via a cookie in the headers. | | Get config role value | [/api/graph?config=MAX_QUEUED_QUERIES](http://localhost:3000/api/graph?config=MAX_QUEUED_QUERIES) | GET | Authorization: Cookie | 1\. Key: config - Value: MAX_QUEUED_QUERIES (required)
2\. Key: value - Value: A number (required) | None | Status code: 200
{"config": [ "MAX_QUEUED_QUERIES",25 ]} | This request is used to get a configuration value for MAX_QUEUED_QUERIES. It accepts a number as the value for the configuration and requires authorization via a cookie in the headers. |