1import { ApifyClient } from 'apify-client';
2
3
4
5const client = new ApifyClient({
6 token: '<YOUR_API_TOKEN>',
7});
8
9
10const input = {
11 "schemaVersion": "1.1.0",
12 "mode": "decision",
13 "requestId": "rq_0123456789abcdef0123456789abcdef",
14 "reportingYear": 2026,
15 "ruleVersion": "eu-ets-maritime-2026-v2",
16 "vessel": {
17 "imoNumber": "1234567",
18 "grossTonnage": 5000,
19 "shipCategory": "cargo",
20 "excludedClass": "none",
21 "article12Treatment": "none_declared"
22 },
23 "portCalls": [
24 {
25 "portCallId": "p1",
26 "unlocode": "NLRTM",
27 "memberStatePort": true,
28 "isPortOfCall": true,
29 "specialTreatment": "ordinary",
30 "startedAt": "2026-03-01T00:00:00Z",
31 "endedAt": "2026-03-01T12:00:00Z"
32 },
33 {
34 "portCallId": "p2",
35 "unlocode": "USLAX",
36 "memberStatePort": false,
37 "isPortOfCall": true,
38 "specialTreatment": "ordinary",
39 "startedAt": "2026-03-05T00:00:00Z",
40 "endedAt": "2026-03-05T12:00:00Z"
41 }
42 ],
43 "legs": [
44 {
45 "legId": "l1",
46 "departurePortCallId": "p1",
47 "arrivalPortCallId": "p2",
48 "departureAt": "2026-03-01T12:00:00Z",
49 "arrivalAt": "2026-03-05T00:00:00Z",
50 "fuelRecords": [
51 {
52 "recordId": "f1",
53 "consumptionStartAt": "2026-03-01T12:00:00Z",
54 "consumptionEndAt": "2026-03-04T12:00:00Z",
55 "fuelType": "HFO",
56 "massTonnes": "100",
57 "dataTruth": "measured"
58 }
59 ]
60 }
61 ],
62 "berthRecords": [
63 {
64 "recordId": "b1",
65 "portCallId": "p1",
66 "consumptionStartAt": "2026-03-01T01:00:00Z",
67 "consumptionEndAt": "2026-03-01T03:00:00Z",
68 "fuelType": "MDO_MGO",
69 "massTonnes": "10",
70 "dataTruth": "measured"
71 }
72 ],
73 "priceInput": {
74 "currency": "USD",
75 "usdPerAllowance": "100",
76 "priceDate": "2026-03-05",
77 "priceObservedAt": "2026-03-05T12:00:00Z",
78 "dataTruth": "buyer_reported"
79 },
80 "scenario": {
81 "alternativeFuelMassMultiplier": "1"
82 }
83};
84
85
86const run = await client.actor("zinin/voyage-carbon-compliance-evidence").call(input);
87
88
89console.log('Results from dataset');
90console.log(`💾 Check your data here: https://console.apify.com/storage/datasets/${run.defaultDatasetId}`);
91const { items } = await client.dataset(run.defaultDatasetId).listItems();
92items.forEach((item) => {
93 console.dir(item);
94});
95
96