-
Notifications
You must be signed in to change notification settings - Fork 18
Expand file tree
/
Copy pathsingle-page.ts
More file actions
39 lines (38 loc) 路 1018 Bytes
/
Copy pathsingle-page.ts
File metadata and controls
39 lines (38 loc) 路 1018 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
import { Scenario } from "../scenario.js";
import { sample1 } from "./fixtures/books.js";
import { defaultRequestBody } from "./fixtures/default-request-body.js";
import { sessionToken } from "./fixtures/tokens.js";
export const singlePages = {
firstPage: {
request: {
method: "post",
url: "http://localhost:8080/api/forward",
body: {
...defaultRequestBody,
requestUrl:
"https://read.amazon.com/kindle-library/search?query=&libraryType=BOOKS&sortType=acquisition_desc&querySize=50",
headers: {
...defaultRequestBody.headers,
"x-amzn-sessionid": "2",
"x-adp-session-token": sessionToken,
},
},
},
response: {
headers: {},
status: 200,
body: {
status: 200,
cookies: {
"session-id": "2",
},
body: JSON.stringify({
itemsList: [sample1],
}),
},
meta: {
books: [sample1],
},
},
},
} satisfies Scenario;