intial setting and auth intergrated
This commit is contained in:
33
brunoApi/auth/Login.bru
Normal file
33
brunoApi/auth/Login.bru
Normal file
@@ -0,0 +1,33 @@
|
||||
meta {
|
||||
name: Login
|
||||
type: http
|
||||
seq: 1
|
||||
}
|
||||
|
||||
post {
|
||||
url: {{url}}/lst/api/authentication/login
|
||||
body: json
|
||||
auth: inherit
|
||||
}
|
||||
|
||||
body:json {
|
||||
{
|
||||
"username": "matthes01",
|
||||
"password": "nova0511"
|
||||
}
|
||||
}
|
||||
|
||||
script:post-response {
|
||||
// // grab the raw Set-Cookie header
|
||||
// const cookies = res.headers["set-cookie"];
|
||||
|
||||
// const sessionCookie = cookies[0].split(";")[0];
|
||||
|
||||
// // Save it as an environment variable
|
||||
// bru.setEnvVar("session_cookie", sessionCookie);
|
||||
}
|
||||
|
||||
settings {
|
||||
encodeUrl: true
|
||||
timeout: 0
|
||||
}
|
||||
8
brunoApi/auth/folder.bru
Normal file
8
brunoApi/auth/folder.bru
Normal file
@@ -0,0 +1,8 @@
|
||||
meta {
|
||||
name: auth
|
||||
seq: 5
|
||||
}
|
||||
|
||||
auth {
|
||||
mode: inherit
|
||||
}
|
||||
0
brunoApi/collection.bru
Normal file
0
brunoApi/collection.bru
Normal file
@@ -1,3 +1,4 @@
|
||||
vars {
|
||||
url: http://localhost:3000
|
||||
~session_cookie:
|
||||
}
|
||||
|
||||
16
brunoApi/system/Get Settings.bru
Normal file
16
brunoApi/system/Get Settings.bru
Normal file
@@ -0,0 +1,16 @@
|
||||
meta {
|
||||
name: Get Settings
|
||||
type: http
|
||||
seq: 3
|
||||
}
|
||||
|
||||
get {
|
||||
url: {{url}}/lst/api/settings
|
||||
body: none
|
||||
auth: inherit
|
||||
}
|
||||
|
||||
settings {
|
||||
encodeUrl: true
|
||||
timeout: 0
|
||||
}
|
||||
23
brunoApi/system/updateSetting.bru
Normal file
23
brunoApi/system/updateSetting.bru
Normal file
@@ -0,0 +1,23 @@
|
||||
meta {
|
||||
name: updateSetting
|
||||
type: http
|
||||
seq: 2
|
||||
}
|
||||
|
||||
patch {
|
||||
url: {{url}}/lst/api/settings/something
|
||||
body: json
|
||||
auth: inherit
|
||||
}
|
||||
|
||||
body:json {
|
||||
{
|
||||
"value" : "true",
|
||||
"active": "false"
|
||||
}
|
||||
}
|
||||
|
||||
settings {
|
||||
encodeUrl: true
|
||||
timeout: 0
|
||||
}
|
||||
Reference in New Issue
Block a user