File tree Expand file tree Collapse file tree 1 file changed +26
-28
lines changed
playground/javascript/node Expand file tree Collapse file tree 1 file changed +26
-28
lines changed Original file line number Diff line number Diff line change @@ -9,37 +9,35 @@ const client = compositionClient(appId, apiKey);
9
9
10
10
async function testComposition ( ) {
11
11
try {
12
+ console . log ( appId , apiKey )
12
13
// create a new composition
13
- /*
14
- const res = await client.multipleBatch({
15
- requests: [
16
- {
17
- action: 'upsert',
18
- body: {
19
- objectID: 'id1',
20
- name: 'my first composition',
21
- description: 'the first ever composition from the client',
22
- behavior: {
23
- injection: {
24
- main: {
25
- source: {
26
- search: {
27
- index: 'cts_e2e_small',
28
- },
29
- },
30
- },
31
- },
32
- },
33
- },
34
- },
35
- ],
36
- });
37
- console.log(`[OK]`, res);
38
- */
14
+ // const res = await client.multipleBatch({
15
+ // requests: [
16
+ // {
17
+ // action: 'upsert',
18
+ // body: {
19
+ // objectID: 'id1',
20
+ // name: 'my first composition',
21
+ // description: 'the first ever composition from the client',
22
+ // behavior: {
23
+ // injection: {
24
+ // main: {
25
+ // source: {
26
+ // search: {
27
+ // index: 'cts_e2e_small',
28
+ // },
29
+ // },
30
+ // },
31
+ // },
32
+ // },
33
+ // },
34
+ // },
35
+ // ],
36
+ // });
37
+ // console.log(`[OK]`, res);
39
38
40
- const compos = await client . listCompositions ( ) ;
39
+ console . log ( await client . listCompositions ( ) )
41
40
42
- console . log ( `[OK]` , compos ) ;
43
41
} catch ( e ) {
44
42
if ( e instanceof ApiError ) {
45
43
return console . log ( `[${ e . status } ] ${ e . message } ` , e . stackTrace , e ) ;
You can’t perform that action at this time.
0 commit comments