36 lines
646 B
YAML
36 lines
646 B
YAML
info:
|
|
name: Login
|
|
type: http
|
|
seq: 1
|
|
|
|
http:
|
|
method: POST
|
|
url: "{{BASE_URL}}/{{SECTOR}}/login"
|
|
headers:
|
|
- name: Content-Type
|
|
value: application/json
|
|
body:
|
|
type: json
|
|
data: |-
|
|
{
|
|
"email":"james@dardry.com",
|
|
"password":"Foobar"
|
|
}
|
|
auth: inherit
|
|
|
|
runtime:
|
|
scripts:
|
|
- type: after-response
|
|
code: |-
|
|
function onResponse(res) {
|
|
console.log(res.getHeader('set-cookie'));
|
|
bru.setEnvVar("REFRESH_COOKIE", res.getHeader('set-cookie'));
|
|
}
|
|
onResponse(res);
|
|
|
|
settings:
|
|
encodeUrl: true
|
|
timeout: 0
|
|
followRedirects: true
|
|
maxRedirects: 5
|