1import { ApifyClient } from 'apify-client';
2
3
4
5const client = new ApifyClient({
6 token: '<YOUR_API_TOKEN>',
7});
8
9
10const input = {
11 "joints": [
12 "M12 8.8 bolt, 2 x 15 mm steel, 10 kN per bolt",
13 "6 x M10 10.9 cap screws into cast iron, 20 mm aluminum flange, 0 to 60 kN total tension, cyclic",
14 "1/2-13 UNC grade 5, 1.5 in steel + 0.5 in aluminum, 2000 lbf per bolt, lubricated",
15 "design bolts: 4 bolts, 40 kN tension, 8 kN shear, 2 x 12 mm steel plates, safety 2",
16 {
17 "title": "Pump flange",
18 "size": "M16",
19 "grade": "8.8",
20 "count": 8,
21 "members": [
22 {
23 "thickness": "20 mm",
24 "material": "steel"
25 },
26 {
27 "thickness": "3 mm",
28 "E": "0.5 GPa",
29 "material": "gasket"
30 },
31 {
32 "thickness": "20 mm",
33 "material": "steel"
34 }
35 ],
36 "load": "120 kN",
37 "finish": "lubricated"
38 }
39 ]
40};
41
42
43const run = await client.actor("jumblemog/bolted-joint-calculator").call(input);
44
45
46console.log('Results from dataset');
47console.log(`💾 Check your data here: https://console.apify.com/storage/datasets/${run.defaultDatasetId}`);
48const { items } = await client.dataset(run.defaultDatasetId).listItems();
49items.forEach((item) => {
50 console.dir(item);
51});
52
53