Skip to content

Commit dc693d8

Browse files
committed
SDK version dependency updated
1 parent a565f72 commit dc693d8

3 files changed

Lines changed: 19 additions & 16 deletions

File tree

package-lock.json

Lines changed: 6 additions & 6 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

package.json

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "@linkedapi/linkedin-cli",
3-
"version": "1.0.12",
3+
"version": "1.0.13",
44
"description": "AI-agent-friendly CLI for controlling LinkedIn accounts and retrieving real-time data.",
55
"author": "Linked API",
66
"license": "MIT",
@@ -43,7 +43,7 @@
4343
"ai-agent"
4444
],
4545
"dependencies": {
46-
"@linkedapi/node": "^2.0.0",
46+
"@linkedapi/node": "^2.0.1",
4747
"@oclif/core": "^4.2.10"
4848
},
4949
"devDependencies": {

src/core/workflow/workflow-details.ts

Lines changed: 11 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -8,12 +8,12 @@ async function executeWorkflowWithDetails<TParams, TResult>(
88
operation: Operation<TParams, TResult>,
99
params: TParams,
1010
): Promise<TWorkflowStartedDetails> {
11-
const workflowId = await operation.execute(params);
11+
const workflow = await operation.execute(params);
1212

1313
return {
14-
workflowId,
15-
workflowStatus: 'pending',
16-
message: '',
14+
workflowId: workflow.workflowId,
15+
workflowStatus: workflow.workflowStatus,
16+
message: workflow.message ?? '',
1717
};
1818
}
1919

@@ -22,17 +22,20 @@ async function getWorkflowStatusDetails<TParams, TResult>(
2222
workflowId: string,
2323
): Promise<TMappedResponse<TResult> | TWorkflowInProgressDetails> {
2424
const status = await operation.status(workflowId);
25-
if (isWorkflowInProgressStatus(status)) {
25+
26+
if (isWorkflowInProgress(status)) {
2627
return {
27-
workflowStatus: status,
28-
message: '',
28+
workflowStatus: status.workflowStatus,
29+
message: status.message ?? '',
2930
};
3031
}
3132

3233
return status;
3334
}
3435

35-
function isWorkflowInProgress(status: unknown): status is TWorkflowInProgressDetails {
36+
function isWorkflowInProgress(
37+
status: unknown,
38+
): status is { workflowStatus: TWorkflowInProgressStatus; message?: string } {
3639
if (!status || typeof status !== 'object') {
3740
return false;
3841
}

0 commit comments

Comments
 (0)