@appconda/sdk 1.0.457 → 1.0.460
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/modules/emploid/schema.d.ts +194 -0
- package/dist/modules/emploid/schema.js +235 -1
- package/dist/modules/emploid/service.d.ts +39 -1
- package/dist/modules/emploid/service.js +88 -1
- package/package.json +1 -1
- package/src/modules/emploid/schema.ts +325 -1
- package/src/modules/emploid/service.ts +306 -8
|
@@ -3,7 +3,7 @@ import z from "zod";
|
|
|
3
3
|
import { ServiceClient } from "../../service-client";
|
|
4
4
|
|
|
5
5
|
|
|
6
|
-
import { CreateAgentFlowFolderSchema, CreateAgentFlowSchema, CreateAssistantSchema, CreateCommandSchema, CreateCompetencySchema, CreateConstraintSchema, CreateEmploidSchema, CreateExtensionSchema, CreateInputSchema, CreateInstructionSchema, CreateJobDefinitionSchema, CreateOccupationSchema, CreateScopeSchema, CreateSkillSchema, CreateStreamIdSchema, CreateTaskTemplateSchema, CreateTeamSchema, CreateWorkerSchema, DeleteAgentFlowFolderSchema, DeleteAssistantSchema, DeleteChatByIdSchema, DeleteCommandSchema, DeleteCompetencySchema, DeleteConstraintSchema, DeleteDocumentsByIdAfterTimestampSchema, DeleteEmploidSchema, DeleteInputSchema, DeleteInstructionSchema, DeleteJobDefinitionSchema, DeleteMessagesByChatIdAfterTimestampSchema, DeleteOccupationSchema, DeleteScopeSchema, DeleteSkillSchema, DeleteTaskTemplateSchema, DeleteTeamSchema, DeleteWorkerSchema, GetChatByIdSchema, GetChatsByUserIdSchema, GetDocumentByIdSchema, GetDocumentsByIdSchema, GetMessageByIdSchema, GetMessageCountByUserIdSchema, GetMessagesByChatIdSchema, GetStreamIdsByChatIdSchema, GetSuggestionsByDocumentIdSchema, GetVotesByChatIdSchema, ListAgentFlowFoldersSchema, ListAgentFlowsSchema, ListAssistantsSchema, ListCommandsSchema, ListCompetenciesSchema, ListConstraintsSchema, ListEmploidsPaginatedSchema, ListEmploidsSchema, ListExtensionsSchema, ListInputSchema, ListInstructionsSchema, ListJobDefinitionSchema, ListOccupationsSchema, ListScopesSchema, ListSkillsSchema, ListTaskTemplatesSchema, ListTeamsSchema, ListWorkersSchema, SaveChatSchema, SaveDocumentSchema, SaveMessagesSchema, SaveSuggestionsSchema, UpdateAgentFlowFolderSchema, UpdateAssistantSchema, UpdateChatLastContextByIdSchema, UpdateChatVisiblityByIdSchema, UpdateCommandSchema, UpdateCompetencySchema, UpdateConstraintSchema, UpdateEmploidSchema, UpdateInputSchema, UpdateInstructionSchema, UpdateJobDefinitionSchema, UpdateOccupationSchema, UpdateScopeSchema, UpdateSkillSchema, UpdateTaskTemplateSchema, UpdateTeamSchema, UpdateWorkerSchema, VoteMessageSchema } from "./schema";
|
|
6
|
+
import { AggregateRecordsSchema, BulkCreateRecordsSchema, BulkDeleteRecordsSchema, BulkUpdateRecordsSchema, CheckRecordPermissionSchema, CountRecordsSchema, CreateAgentFlowFolderSchema, CreateAgentFlowSchema, CreateAssistantSchema, CreateCollectionFieldSchema, CreateCommandSchema, CreateCompetencySchema, CreateConstraintSchema, CreateEmploidSchema, CreateExtensionSchema, CreateInputSchema, CreateInstructionSchema, CreateJobDefinitionSchema, CreateOccupationSchema, CreateRecordSchema, CreateScopeSchema, CreateSkillSchema, CreateStreamIdSchema, CreateTaskTemplateSchema, CreateTeamSchema, CreateWorkerSchema, DeleteAgentFlowFolderSchema, DeleteAssistantSchema, DeleteChatByIdSchema, DeleteCollectionFieldSchema, DeleteCommandSchema, DeleteCompetencySchema, DeleteConstraintSchema, DeleteDocumentsByIdAfterTimestampSchema, DeleteEmploidSchema, DeleteInputSchema, DeleteInstructionSchema, DeleteJobDefinitionSchema, DeleteMessagesByChatIdAfterTimestampSchema, DeleteOccupationSchema, DeleteRecordSchema, DeleteScopeSchema, DeleteSkillSchema, DeleteTaskTemplateSchema, DeleteTeamSchema, DeleteWorkerSchema, DistinctFieldValuesSchema, DuplicateRecordSchema, GetChatByIdSchema, GetChatsByUserIdSchema, GetCollectionSchemaSchema, GetDocumentByIdSchema, GetDocumentsByIdSchema, GetMessageByIdSchema, GetMessageCountByUserIdSchema, GetMessagesByChatIdSchema, GetRecordByIdSchema, GetStreamIdsByChatIdSchema, GetSuggestionsByDocumentIdSchema, GetVotesByChatIdSchema, GrantRecordPermissionSchema, GroupRecordsSchema, ListAgentFlowFoldersSchema, ListAgentFlowsSchema, ListAssistantsSchema, ListCommandsSchema, ListCompetenciesSchema, ListConstraintsSchema, ListEmploidsPaginatedSchema, ListEmploidsSchema, ListExtensionsSchema, ListInputSchema, ListInstructionsSchema, ListJobDefinitionSchema, ListOccupationsSchema, ListRecordPermissionsSchema, ListRecordsSchema, ListScopesSchema, ListSkillsSchema, ListTaskTemplatesSchema, ListTeamsSchema, ListWorkersSchema, PreviewValidationErrorsSchema, QueryRecordsSchema, ReorderCollectionFieldsSchema, RestoreRecordSchema, RevokeRecordPermissionSchema, SaveChatSchema, SaveDocumentSchema, SaveMessagesSchema, SaveSuggestionsSchema, SearchRecordsSchema, UpdateAgentFlowFolderSchema, UpdateAgentFlowSchema, UpdateAssistantSchema, UpdateChatLastContextByIdSchema, UpdateChatVisiblityByIdSchema, UpdateCollectionFieldSchema, UpdateCommandSchema, UpdateCompetencySchema, UpdateConstraintSchema, UpdateEmploidSchema, UpdateInputSchema, UpdateInstructionSchema, UpdateJobDefinitionSchema, UpdateOccupationSchema, UpdateRecordSchema, UpdateScopeSchema, UpdateSkillSchema, UpdateTaskTemplateSchema, UpdateTeamSchema, UpdateWorkerSchema, UpsertRecordSchema, ValidateRecordSchema, VoteMessageSchema } from "./schema";
|
|
7
7
|
import { TAgentFlow, TAgentFlowFolder, TAssistant, TChat, TCommand, TCompetency, TConstraint, TDocument, TEmploid, TExtension, TInput, TInstruction, TJobDefinition, TOccupation, TPaginatedEmploidsResult, TScope, TSkill, TStreamId, TTaskTemplate, TTeam, TWorker } from "./types";
|
|
8
8
|
|
|
9
9
|
export class EmploidService extends ServiceClient {
|
|
@@ -47,7 +47,7 @@ export class EmploidService extends ServiceClient {
|
|
|
47
47
|
return await this.actionCall('emploid', 'DeleteInstruction', payload);
|
|
48
48
|
}
|
|
49
49
|
|
|
50
|
-
|
|
50
|
+
public async CreateConstraint(payload: z.infer<typeof CreateConstraintSchema>): Promise<TConstraint> {
|
|
51
51
|
return await this.actionCall('emploid', 'CreateConstraint', payload);
|
|
52
52
|
}
|
|
53
53
|
|
|
@@ -147,6 +147,10 @@ export class EmploidService extends ServiceClient {
|
|
|
147
147
|
return await this.actionCall('agent-flow', 'CreateAgentFlow', payload);
|
|
148
148
|
}
|
|
149
149
|
|
|
150
|
+
public async UpdateAgentFlow(payload: z.infer<typeof UpdateAgentFlowSchema>): Promise<TAgentFlow> {
|
|
151
|
+
return await this.actionCall('agent-flow', 'UpdateAgentFlow', payload);
|
|
152
|
+
}
|
|
153
|
+
|
|
150
154
|
public async ListAgentFlows(payload: z.infer<typeof ListAgentFlowsSchema>): Promise<TAgentFlow[]> {
|
|
151
155
|
return await this.actionCall('agent-flow', 'ListAgentFlows', payload);
|
|
152
156
|
}
|
|
@@ -341,11 +345,11 @@ export class EmploidService extends ServiceClient {
|
|
|
341
345
|
return await this.actionCall('skill', 'DeleteSkill', payload);
|
|
342
346
|
}
|
|
343
347
|
|
|
344
|
-
|
|
345
|
-
|
|
346
|
-
|
|
347
|
-
|
|
348
|
-
|
|
348
|
+
public async CreateCommand(payload: z.infer<typeof CreateCommandSchema>): Promise<TCommand> {
|
|
349
|
+
/* debugger
|
|
350
|
+
if ( typeof payload.inputs === 'object' ) {
|
|
351
|
+
payload.inputs = JSON.stringify(payload.inputs) as any;
|
|
352
|
+
} */
|
|
349
353
|
return await this.actionCall('command', 'CreateCommand', payload);
|
|
350
354
|
}
|
|
351
355
|
|
|
@@ -357,7 +361,301 @@ export class EmploidService extends ServiceClient {
|
|
|
357
361
|
return await this.actionCall('command', 'UpdateCommand', payload);
|
|
358
362
|
}
|
|
359
363
|
|
|
360
|
-
public async DeleteCommand(payload: z.infer<typeof DeleteCommandSchema>): Promise<TCommand> {
|
|
364
|
+
public async DeleteCommand(payload: z.infer<typeof DeleteCommandSchema>): Promise<TCommand> {
|
|
361
365
|
return await this.actionCall('command', 'DeleteCommand', payload);
|
|
362
366
|
}
|
|
367
|
+
|
|
368
|
+
public async CreateRecord(
|
|
369
|
+
payload: z.infer<typeof CreateRecordSchema>
|
|
370
|
+
): Promise<any> {
|
|
371
|
+
return await this.actionCall(
|
|
372
|
+
"emploid",
|
|
373
|
+
"CreateRecord",
|
|
374
|
+
payload
|
|
375
|
+
);
|
|
376
|
+
}
|
|
377
|
+
|
|
378
|
+
public async GetRecordById(
|
|
379
|
+
payload: z.infer<typeof GetRecordByIdSchema>
|
|
380
|
+
): Promise<any> {
|
|
381
|
+
return await this.actionCall(
|
|
382
|
+
"emploid",
|
|
383
|
+
"GetRecordById",
|
|
384
|
+
payload
|
|
385
|
+
);
|
|
386
|
+
}
|
|
387
|
+
|
|
388
|
+
|
|
389
|
+
public async ListRecords(
|
|
390
|
+
payload: z.infer<typeof ListRecordsSchema>
|
|
391
|
+
): Promise<{
|
|
392
|
+
total: number;
|
|
393
|
+
records: any[];
|
|
394
|
+
}> {
|
|
395
|
+
return await this.actionCall(
|
|
396
|
+
"emploid",
|
|
397
|
+
"ListRecords",
|
|
398
|
+
payload
|
|
399
|
+
);
|
|
400
|
+
}
|
|
401
|
+
|
|
402
|
+
public async UpdateRecord(
|
|
403
|
+
payload: z.infer<typeof UpdateRecordSchema>
|
|
404
|
+
): Promise<any> {
|
|
405
|
+
return await this.actionCall(
|
|
406
|
+
"emploid",
|
|
407
|
+
"UpdateRecord",
|
|
408
|
+
payload
|
|
409
|
+
);
|
|
410
|
+
}
|
|
411
|
+
|
|
412
|
+
public async DeleteRecord(
|
|
413
|
+
payload: z.infer<typeof DeleteRecordSchema>
|
|
414
|
+
): Promise<any> {
|
|
415
|
+
return await this.actionCall(
|
|
416
|
+
"emploid",
|
|
417
|
+
"DeleteRecord",
|
|
418
|
+
payload
|
|
419
|
+
);
|
|
420
|
+
}
|
|
421
|
+
|
|
422
|
+
|
|
423
|
+
public async RestoreRecord(
|
|
424
|
+
payload: z.infer<typeof RestoreRecordSchema>
|
|
425
|
+
): Promise<any> {
|
|
426
|
+
return await this.actionCall(
|
|
427
|
+
"emploid",
|
|
428
|
+
"RestoreRecord",
|
|
429
|
+
payload
|
|
430
|
+
);
|
|
431
|
+
}
|
|
432
|
+
|
|
433
|
+
public async UpsertRecord(
|
|
434
|
+
payload: z.infer<typeof UpsertRecordSchema>
|
|
435
|
+
): Promise<any> {
|
|
436
|
+
return await this.actionCall(
|
|
437
|
+
"emploid",
|
|
438
|
+
"UpsertRecord",
|
|
439
|
+
payload
|
|
440
|
+
);
|
|
441
|
+
}
|
|
442
|
+
|
|
443
|
+
public async BulkCreateRecords(
|
|
444
|
+
payload: z.infer<typeof BulkCreateRecordsSchema>
|
|
445
|
+
): Promise<any> {
|
|
446
|
+
return await this.actionCall(
|
|
447
|
+
"emploid",
|
|
448
|
+
"BulkCreateRecords",
|
|
449
|
+
payload
|
|
450
|
+
);
|
|
451
|
+
}
|
|
452
|
+
|
|
453
|
+
public async BulkUpdateRecords(
|
|
454
|
+
payload: z.infer<typeof BulkUpdateRecordsSchema>
|
|
455
|
+
): Promise<any> {
|
|
456
|
+
return await this.actionCall(
|
|
457
|
+
"emploid",
|
|
458
|
+
"BulkUpdateRecords",
|
|
459
|
+
payload
|
|
460
|
+
);
|
|
461
|
+
}
|
|
462
|
+
|
|
463
|
+
public async BulkDeleteRecords(
|
|
464
|
+
payload: z.infer<typeof BulkDeleteRecordsSchema>
|
|
465
|
+
): Promise<any> {
|
|
466
|
+
return await this.actionCall(
|
|
467
|
+
"emploid",
|
|
468
|
+
"BulkDeleteRecords",
|
|
469
|
+
payload
|
|
470
|
+
);
|
|
471
|
+
}
|
|
472
|
+
public async DuplicateRecord(
|
|
473
|
+
payload: z.infer<typeof DuplicateRecordSchema>
|
|
474
|
+
): Promise<any> {
|
|
475
|
+
return await this.actionCall(
|
|
476
|
+
"emploid",
|
|
477
|
+
"DuplicateRecord",
|
|
478
|
+
payload
|
|
479
|
+
);
|
|
480
|
+
}
|
|
481
|
+
|
|
482
|
+
public async QueryRecords(
|
|
483
|
+
payload: z.infer<typeof QueryRecordsSchema>
|
|
484
|
+
): Promise<{
|
|
485
|
+
total: number;
|
|
486
|
+
records: any[];
|
|
487
|
+
}> {
|
|
488
|
+
return await this.actionCall(
|
|
489
|
+
"emploid",
|
|
490
|
+
"QueryRecords",
|
|
491
|
+
payload
|
|
492
|
+
);
|
|
493
|
+
}
|
|
494
|
+
|
|
495
|
+
public async SearchRecords(
|
|
496
|
+
payload: z.infer<typeof SearchRecordsSchema>
|
|
497
|
+
): Promise<{
|
|
498
|
+
total: number;
|
|
499
|
+
records: any[];
|
|
500
|
+
}> {
|
|
501
|
+
return await this.actionCall(
|
|
502
|
+
"emploid",
|
|
503
|
+
"SearchRecords",
|
|
504
|
+
payload
|
|
505
|
+
);
|
|
506
|
+
}
|
|
507
|
+
|
|
508
|
+
public async CountRecords(
|
|
509
|
+
payload: z.infer<typeof CountRecordsSchema>
|
|
510
|
+
): Promise<number> {
|
|
511
|
+
return await this.actionCall(
|
|
512
|
+
"emploid",
|
|
513
|
+
"CountRecords",
|
|
514
|
+
payload
|
|
515
|
+
);
|
|
516
|
+
}
|
|
517
|
+
|
|
518
|
+
public async GroupRecords(
|
|
519
|
+
payload: z.infer<typeof GroupRecordsSchema>
|
|
520
|
+
): Promise<any[]> {
|
|
521
|
+
return await this.actionCall(
|
|
522
|
+
"emploid",
|
|
523
|
+
"GroupRecords",
|
|
524
|
+
payload
|
|
525
|
+
);
|
|
526
|
+
}
|
|
527
|
+
|
|
528
|
+
public async AggregateRecords(
|
|
529
|
+
payload: z.infer<typeof AggregateRecordsSchema>
|
|
530
|
+
): Promise<any[]> {
|
|
531
|
+
return await this.actionCall(
|
|
532
|
+
"emploid",
|
|
533
|
+
"AggregateRecords",
|
|
534
|
+
payload
|
|
535
|
+
);
|
|
536
|
+
}
|
|
537
|
+
|
|
538
|
+
public async DistinctFieldValues(
|
|
539
|
+
payload: z.infer<typeof DistinctFieldValuesSchema>
|
|
540
|
+
): Promise<any[]> {
|
|
541
|
+
return await this.actionCall(
|
|
542
|
+
"emploid",
|
|
543
|
+
"DistinctFieldValues",
|
|
544
|
+
payload
|
|
545
|
+
);
|
|
546
|
+
}
|
|
547
|
+
|
|
548
|
+
public async CreateCollectionField(
|
|
549
|
+
payload: z.infer<typeof CreateCollectionFieldSchema>
|
|
550
|
+
): Promise<any> {
|
|
551
|
+
return await this.actionCall(
|
|
552
|
+
"emploid",
|
|
553
|
+
"CreateCollectionField",
|
|
554
|
+
payload
|
|
555
|
+
);
|
|
556
|
+
}
|
|
557
|
+
|
|
558
|
+
public async UpdateCollectionField(
|
|
559
|
+
payload: z.infer<typeof UpdateCollectionFieldSchema>
|
|
560
|
+
): Promise<any> {
|
|
561
|
+
return await this.actionCall(
|
|
562
|
+
"emploid",
|
|
563
|
+
"UpdateCollectionField",
|
|
564
|
+
payload
|
|
565
|
+
);
|
|
566
|
+
}
|
|
567
|
+
|
|
568
|
+
public async DeleteCollectionField(
|
|
569
|
+
payload: z.infer<typeof DeleteCollectionFieldSchema>
|
|
570
|
+
): Promise<any> {
|
|
571
|
+
return await this.actionCall(
|
|
572
|
+
"emploid",
|
|
573
|
+
"DeleteCollectionField",
|
|
574
|
+
payload
|
|
575
|
+
);
|
|
576
|
+
}
|
|
577
|
+
|
|
578
|
+
public async ReorderCollectionFields(
|
|
579
|
+
payload: z.infer<typeof ReorderCollectionFieldsSchema>
|
|
580
|
+
): Promise<any> {
|
|
581
|
+
return await this.actionCall(
|
|
582
|
+
"emploid",
|
|
583
|
+
"ReorderCollectionFields",
|
|
584
|
+
payload
|
|
585
|
+
);
|
|
586
|
+
}
|
|
587
|
+
|
|
588
|
+
public async GetCollectionSchema(
|
|
589
|
+
payload: z.infer<typeof GetCollectionSchemaSchema>
|
|
590
|
+
): Promise<any> {
|
|
591
|
+
return await this.actionCall(
|
|
592
|
+
"emploid",
|
|
593
|
+
"GetCollectionSchema",
|
|
594
|
+
payload
|
|
595
|
+
);
|
|
596
|
+
}
|
|
597
|
+
|
|
598
|
+
public async ValidateRecord(
|
|
599
|
+
payload: z.infer<typeof ValidateRecordSchema>
|
|
600
|
+
): Promise<any> {
|
|
601
|
+
return await this.actionCall(
|
|
602
|
+
"emploid",
|
|
603
|
+
"ValidateRecord",
|
|
604
|
+
payload
|
|
605
|
+
);
|
|
606
|
+
}
|
|
607
|
+
|
|
608
|
+
public async PreviewValidationErrors(
|
|
609
|
+
payload: z.infer<typeof PreviewValidationErrorsSchema>
|
|
610
|
+
): Promise<any> {
|
|
611
|
+
return await this.actionCall(
|
|
612
|
+
"emploid",
|
|
613
|
+
"PreviewValidationErrors",
|
|
614
|
+
payload
|
|
615
|
+
);
|
|
616
|
+
}
|
|
617
|
+
|
|
618
|
+
public async CheckRecordPermission(
|
|
619
|
+
payload: z.infer<typeof CheckRecordPermissionSchema>
|
|
620
|
+
): Promise<any> {
|
|
621
|
+
return await this.actionCall(
|
|
622
|
+
"emploid",
|
|
623
|
+
"CheckRecordPermission",
|
|
624
|
+
payload
|
|
625
|
+
);
|
|
626
|
+
}
|
|
627
|
+
|
|
628
|
+
public async ListRecordPermissions(
|
|
629
|
+
payload: z.infer<typeof ListRecordPermissionsSchema>
|
|
630
|
+
): Promise<any[]> {
|
|
631
|
+
return await this.actionCall(
|
|
632
|
+
"emploid",
|
|
633
|
+
"ListRecordPermissions",
|
|
634
|
+
payload
|
|
635
|
+
);
|
|
636
|
+
}
|
|
637
|
+
|
|
638
|
+
public async GrantRecordPermission(
|
|
639
|
+
payload: z.infer<typeof GrantRecordPermissionSchema>
|
|
640
|
+
): Promise<any> {
|
|
641
|
+
return await this.actionCall(
|
|
642
|
+
"emploid",
|
|
643
|
+
"GrantRecordPermission",
|
|
644
|
+
payload
|
|
645
|
+
);
|
|
646
|
+
}
|
|
647
|
+
|
|
648
|
+
|
|
649
|
+
public async RevokeRecordPermission(
|
|
650
|
+
payload: z.infer<typeof RevokeRecordPermissionSchema>
|
|
651
|
+
): Promise<any> {
|
|
652
|
+
return await this.actionCall(
|
|
653
|
+
"emploid",
|
|
654
|
+
"RevokeRecordPermission",
|
|
655
|
+
payload
|
|
656
|
+
);
|
|
657
|
+
}
|
|
658
|
+
|
|
659
|
+
|
|
660
|
+
|
|
363
661
|
}
|