@ayurak/sdk 1.1.0 → 1.4.0

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/README.md CHANGED
@@ -443,6 +443,18 @@ input?.addEventListener('change', async (e) => {
443
443
  PROJECT_ID: ${{ vars.PROJECT_ID }}
444
444
  ```
445
445
 
446
+ ## Changelog
447
+
448
+ ### v1.4.0
449
+ - **Fixed**: Base URL corrected from `api.aribot.aristiun.com` to `api.aribot.ayurak.com`
450
+ - **Added**: AI module (`client.ai`) - usage, quota, models, configure, analyze, queue status
451
+ - **Added**: SBOM module (`client.sbom`) - document management, upload, vulnerability scanning
452
+ - **Added**: Dashboard module (`client.dashboard`) - overview, recent activity, risk summary
453
+ - **Added**: FinOps module (`client.finops`) - cost optimization, recommendations, cost breakdown
454
+ - **Added**: Marketplace module (`client.marketplace`) - templates, categories, featured items
455
+ - **Added**: API Keys module (`client.apiKeys`) - list, create, revoke API keys
456
+ - **Added**: Framework-specific compliance scoring support
457
+
446
458
  ## Support
447
459
 
448
460
  - Documentation: https://developers.aristiun.com/docs/js-sdk
package/dist/index.d.mts CHANGED
@@ -640,6 +640,288 @@ declare class EconomicsAPI {
640
640
  }>;
641
641
  }
642
642
 
643
+ interface AIUsage {
644
+ total_requests: number;
645
+ tokens_used: number;
646
+ cost: number;
647
+ period: string;
648
+ [key: string]: unknown;
649
+ }
650
+ interface AIQuota {
651
+ requests_limit: number;
652
+ requests_used: number;
653
+ tokens_limit: number;
654
+ tokens_used: number;
655
+ reset_at: string;
656
+ [key: string]: unknown;
657
+ }
658
+ interface AIModel {
659
+ id: string;
660
+ name: string;
661
+ provider: string;
662
+ capabilities: string[];
663
+ [key: string]: unknown;
664
+ }
665
+ interface AIAnalysisResult {
666
+ analysis_id: string;
667
+ status: string;
668
+ results: unknown;
669
+ [key: string]: unknown;
670
+ }
671
+ interface AIQueueStatus {
672
+ pending: number;
673
+ processing: number;
674
+ completed: number;
675
+ failed: number;
676
+ [key: string]: unknown;
677
+ }
678
+ /**
679
+ * AI usage, quota, and analysis operations
680
+ */
681
+ declare class AIAPI {
682
+ private http;
683
+ constructor(http: HttpClient);
684
+ /**
685
+ * Get AI usage statistics
686
+ */
687
+ getUsage(period?: string): Promise<AIUsage>;
688
+ /**
689
+ * Get AI quota information
690
+ */
691
+ getQuota(): Promise<AIQuota>;
692
+ /**
693
+ * List available AI models
694
+ */
695
+ listModels(): Promise<AIModel[]>;
696
+ /**
697
+ * Configure AI settings
698
+ */
699
+ configure(config: Record<string, unknown>): Promise<Record<string, unknown>>;
700
+ /**
701
+ * Run AI analysis
702
+ */
703
+ analyze(options: {
704
+ target: string;
705
+ type?: string;
706
+ model?: string;
707
+ [key: string]: unknown;
708
+ }): Promise<AIAnalysisResult>;
709
+ /**
710
+ * Get AI processing queue status
711
+ */
712
+ getQueueStatus(): Promise<AIQueueStatus>;
713
+ }
714
+
715
+ interface SBOMDocument {
716
+ id: string;
717
+ name: string;
718
+ format: string;
719
+ status: string;
720
+ created_at: string;
721
+ components_count: number;
722
+ vulnerabilities_count: number;
723
+ [key: string]: unknown;
724
+ }
725
+ interface SBOMVulnerability {
726
+ id: string;
727
+ cve_id: string;
728
+ severity: string;
729
+ description: string;
730
+ affected_component: string;
731
+ fix_available: boolean;
732
+ [key: string]: unknown;
733
+ }
734
+ /**
735
+ * SBOM document management and vulnerability scanning
736
+ */
737
+ declare class SBOMAPI {
738
+ private http;
739
+ constructor(http: HttpClient);
740
+ /**
741
+ * List SBOM documents
742
+ */
743
+ list(params?: Record<string, string | number | boolean>): Promise<SBOMDocument[]>;
744
+ /**
745
+ * Get SBOM document details
746
+ */
747
+ get(documentId: string): Promise<SBOMDocument>;
748
+ /**
749
+ * Upload an SBOM document
750
+ */
751
+ upload(file: File | Blob, options?: {
752
+ name?: string;
753
+ format?: string;
754
+ }): Promise<SBOMDocument>;
755
+ /**
756
+ * Get vulnerabilities for an SBOM document
757
+ */
758
+ getVulnerabilities(documentId: string, params?: Record<string, string | number | boolean>): Promise<SBOMVulnerability[]>;
759
+ }
760
+
761
+ interface DashboardOverview {
762
+ total_diagrams: number;
763
+ total_threats: number;
764
+ compliance_score: number;
765
+ risk_score: number;
766
+ [key: string]: unknown;
767
+ }
768
+ interface RecentActivity {
769
+ id: string;
770
+ type: string;
771
+ description: string;
772
+ timestamp: string;
773
+ [key: string]: unknown;
774
+ }
775
+ interface RiskSummary {
776
+ overall_risk: string;
777
+ critical: number;
778
+ high: number;
779
+ medium: number;
780
+ low: number;
781
+ trend: string;
782
+ [key: string]: unknown;
783
+ }
784
+ /**
785
+ * Dashboard overview, activity, and risk summary
786
+ */
787
+ declare class DashboardAPI {
788
+ private http;
789
+ constructor(http: HttpClient);
790
+ /**
791
+ * Get dashboard overview metrics
792
+ */
793
+ getOverview(): Promise<DashboardOverview>;
794
+ /**
795
+ * Get recent activity
796
+ */
797
+ getRecentActivity(params?: Record<string, string | number | boolean>): Promise<RecentActivity[]>;
798
+ /**
799
+ * Get risk summary
800
+ */
801
+ getRiskSummary(): Promise<RiskSummary>;
802
+ }
803
+
804
+ interface FinOpsRecommendation {
805
+ id: string;
806
+ type: string;
807
+ description: string;
808
+ estimated_savings: number;
809
+ priority: string;
810
+ [key: string]: unknown;
811
+ }
812
+ interface FinOpsCosts {
813
+ total: number;
814
+ by_service: Record<string, number>;
815
+ by_provider: Record<string, number>;
816
+ period: string;
817
+ [key: string]: unknown;
818
+ }
819
+ interface FinOpsOptimization {
820
+ id: string;
821
+ status: string;
822
+ savings_achieved: number;
823
+ details: string;
824
+ [key: string]: unknown;
825
+ }
826
+ /**
827
+ * FinOps cost optimization and recommendations
828
+ */
829
+ declare class FinOpsAPI {
830
+ private http;
831
+ constructor(http: HttpClient);
832
+ /**
833
+ * Get cost optimization recommendations
834
+ */
835
+ getRecommendations(params?: Record<string, string | number | boolean>): Promise<FinOpsRecommendation[]>;
836
+ /**
837
+ * Get cost breakdown
838
+ */
839
+ getCosts(params?: Record<string, string | number | boolean>): Promise<FinOpsCosts>;
840
+ /**
841
+ * Get optimization details
842
+ */
843
+ getOptimization(params?: Record<string, string | number | boolean>): Promise<FinOpsOptimization[]>;
844
+ }
845
+
846
+ interface MarketplaceTemplate {
847
+ id: string;
848
+ name: string;
849
+ description: string;
850
+ category: string;
851
+ author: string;
852
+ downloads: number;
853
+ rating: number;
854
+ [key: string]: unknown;
855
+ }
856
+ interface MarketplaceCategory {
857
+ id: string;
858
+ name: string;
859
+ description: string;
860
+ templates_count: number;
861
+ [key: string]: unknown;
862
+ }
863
+ /**
864
+ * Marketplace templates, categories, and featured items
865
+ */
866
+ declare class MarketplaceAPI {
867
+ private http;
868
+ constructor(http: HttpClient);
869
+ /**
870
+ * List marketplace templates
871
+ */
872
+ listTemplates(params?: Record<string, string | number | boolean>): Promise<MarketplaceTemplate[]>;
873
+ /**
874
+ * List marketplace categories
875
+ */
876
+ listCategories(): Promise<MarketplaceCategory[]>;
877
+ /**
878
+ * Get featured templates
879
+ */
880
+ getFeatured(): Promise<MarketplaceTemplate[]>;
881
+ }
882
+
883
+ interface APIKey {
884
+ id: string;
885
+ name: string;
886
+ prefix: string;
887
+ created_at: string;
888
+ last_used_at: string | null;
889
+ expires_at: string | null;
890
+ is_active: boolean;
891
+ [key: string]: unknown;
892
+ }
893
+ interface APIKeyCreateResult {
894
+ id: string;
895
+ name: string;
896
+ key: string;
897
+ prefix: string;
898
+ created_at: string;
899
+ [key: string]: unknown;
900
+ }
901
+ /**
902
+ * API key management operations
903
+ */
904
+ declare class APIKeysAPI {
905
+ private http;
906
+ constructor(http: HttpClient);
907
+ /**
908
+ * List API keys
909
+ */
910
+ list(params?: Record<string, string | number | boolean>): Promise<APIKey[]>;
911
+ /**
912
+ * Create a new API key
913
+ */
914
+ create(options: {
915
+ name: string;
916
+ expires_in_days?: number;
917
+ scopes?: string[];
918
+ }): Promise<APIKeyCreateResult>;
919
+ /**
920
+ * Revoke an API key
921
+ */
922
+ revoke(keyId: string): Promise<Record<string, unknown>>;
923
+ }
924
+
643
925
  interface AribotOptions {
644
926
  baseUrl?: string;
645
927
  timeout?: number;
@@ -690,6 +972,18 @@ declare class Aribot {
690
972
  digitalTwin: DigitalTwinAPI;
691
973
  /** Economics and cost analysis */
692
974
  economics: EconomicsAPI;
975
+ /** AI usage and analysis */
976
+ ai: AIAPI;
977
+ /** SBOM document management */
978
+ sbom: SBOMAPI;
979
+ /** Dashboard overview and metrics */
980
+ dashboard: DashboardAPI;
981
+ /** FinOps cost optimization */
982
+ finops: FinOpsAPI;
983
+ /** Marketplace templates */
984
+ marketplace: MarketplaceAPI;
985
+ /** API key management */
986
+ apiKeys: APIKeysAPI;
693
987
  /**
694
988
  * Create Aribot client
695
989
  *
@@ -759,4 +1053,4 @@ declare class ServerError extends AribotError {
759
1053
  constructor(message: string, statusCode?: number, response?: Record<string, unknown>);
760
1054
  }
761
1055
 
762
- export { type AnalyzeDiagramOptions, Aribot, AribotError, type AribotOptions, AuthenticationError, type CloudAccount, type CloudFinding, type CloudProvider, type CloudResource, type CloudScan, type CloudScanOptions, CloudSecurityAPI, ComplianceAPI, type ComplianceGap, type ComplianceResult, type ScanOptions$1 as ComplianceScanOptions, type ComplianceStandard, type Component, type ComponentCloudMapping, type ComponentCost, type Control, type CreateProjectOptions, type Diagram, type DiagramComponentStatus, type DiagramCostAnalysis, DigitalTwinAPI, EconomicsAPI, type EconomicsDashboard, type Finding, type GatesConfig, type GetFindingsOptions, type ListDiagramsOptions, type ListScansOptions, type MarketIntelligence, NotFoundError, PipelineAPI, type PipelineScan, type ScanOptions as PipelineScanOptions, type Project, RateLimitError, RedTeamAPI, type RedTeamMethodology, type RedTeamSimulation, ServerError, type Threat, type ThreatIntelligence, ThreatModelingAPI, ValidationError };
1056
+ export { AIAPI, type AIAnalysisResult, type AIModel, type AIQueueStatus, type AIQuota, type AIUsage, type APIKey, type APIKeyCreateResult, APIKeysAPI, type AnalyzeDiagramOptions, Aribot, AribotError, type AribotOptions, AuthenticationError, type CloudAccount, type CloudFinding, type CloudProvider, type CloudResource, type CloudScan, type CloudScanOptions, CloudSecurityAPI, ComplianceAPI, type ComplianceGap, type ComplianceResult, type ScanOptions$1 as ComplianceScanOptions, type ComplianceStandard, type Component, type ComponentCloudMapping, type ComponentCost, type Control, type CreateProjectOptions, DashboardAPI, type DashboardOverview, type Diagram, type DiagramComponentStatus, type DiagramCostAnalysis, DigitalTwinAPI, EconomicsAPI, type EconomicsDashboard, FinOpsAPI, type FinOpsCosts, type FinOpsOptimization, type FinOpsRecommendation, type Finding, type GatesConfig, type GetFindingsOptions, type ListDiagramsOptions, type ListScansOptions, type MarketIntelligence, MarketplaceAPI, type MarketplaceCategory, type MarketplaceTemplate, NotFoundError, PipelineAPI, type PipelineScan, type ScanOptions as PipelineScanOptions, type Project, RateLimitError, type RecentActivity, RedTeamAPI, type RedTeamMethodology, type RedTeamSimulation, type RiskSummary, SBOMAPI, type SBOMDocument, type SBOMVulnerability, ServerError, type Threat, type ThreatIntelligence, ThreatModelingAPI, ValidationError };
package/dist/index.d.ts CHANGED
@@ -640,6 +640,288 @@ declare class EconomicsAPI {
640
640
  }>;
641
641
  }
642
642
 
643
+ interface AIUsage {
644
+ total_requests: number;
645
+ tokens_used: number;
646
+ cost: number;
647
+ period: string;
648
+ [key: string]: unknown;
649
+ }
650
+ interface AIQuota {
651
+ requests_limit: number;
652
+ requests_used: number;
653
+ tokens_limit: number;
654
+ tokens_used: number;
655
+ reset_at: string;
656
+ [key: string]: unknown;
657
+ }
658
+ interface AIModel {
659
+ id: string;
660
+ name: string;
661
+ provider: string;
662
+ capabilities: string[];
663
+ [key: string]: unknown;
664
+ }
665
+ interface AIAnalysisResult {
666
+ analysis_id: string;
667
+ status: string;
668
+ results: unknown;
669
+ [key: string]: unknown;
670
+ }
671
+ interface AIQueueStatus {
672
+ pending: number;
673
+ processing: number;
674
+ completed: number;
675
+ failed: number;
676
+ [key: string]: unknown;
677
+ }
678
+ /**
679
+ * AI usage, quota, and analysis operations
680
+ */
681
+ declare class AIAPI {
682
+ private http;
683
+ constructor(http: HttpClient);
684
+ /**
685
+ * Get AI usage statistics
686
+ */
687
+ getUsage(period?: string): Promise<AIUsage>;
688
+ /**
689
+ * Get AI quota information
690
+ */
691
+ getQuota(): Promise<AIQuota>;
692
+ /**
693
+ * List available AI models
694
+ */
695
+ listModels(): Promise<AIModel[]>;
696
+ /**
697
+ * Configure AI settings
698
+ */
699
+ configure(config: Record<string, unknown>): Promise<Record<string, unknown>>;
700
+ /**
701
+ * Run AI analysis
702
+ */
703
+ analyze(options: {
704
+ target: string;
705
+ type?: string;
706
+ model?: string;
707
+ [key: string]: unknown;
708
+ }): Promise<AIAnalysisResult>;
709
+ /**
710
+ * Get AI processing queue status
711
+ */
712
+ getQueueStatus(): Promise<AIQueueStatus>;
713
+ }
714
+
715
+ interface SBOMDocument {
716
+ id: string;
717
+ name: string;
718
+ format: string;
719
+ status: string;
720
+ created_at: string;
721
+ components_count: number;
722
+ vulnerabilities_count: number;
723
+ [key: string]: unknown;
724
+ }
725
+ interface SBOMVulnerability {
726
+ id: string;
727
+ cve_id: string;
728
+ severity: string;
729
+ description: string;
730
+ affected_component: string;
731
+ fix_available: boolean;
732
+ [key: string]: unknown;
733
+ }
734
+ /**
735
+ * SBOM document management and vulnerability scanning
736
+ */
737
+ declare class SBOMAPI {
738
+ private http;
739
+ constructor(http: HttpClient);
740
+ /**
741
+ * List SBOM documents
742
+ */
743
+ list(params?: Record<string, string | number | boolean>): Promise<SBOMDocument[]>;
744
+ /**
745
+ * Get SBOM document details
746
+ */
747
+ get(documentId: string): Promise<SBOMDocument>;
748
+ /**
749
+ * Upload an SBOM document
750
+ */
751
+ upload(file: File | Blob, options?: {
752
+ name?: string;
753
+ format?: string;
754
+ }): Promise<SBOMDocument>;
755
+ /**
756
+ * Get vulnerabilities for an SBOM document
757
+ */
758
+ getVulnerabilities(documentId: string, params?: Record<string, string | number | boolean>): Promise<SBOMVulnerability[]>;
759
+ }
760
+
761
+ interface DashboardOverview {
762
+ total_diagrams: number;
763
+ total_threats: number;
764
+ compliance_score: number;
765
+ risk_score: number;
766
+ [key: string]: unknown;
767
+ }
768
+ interface RecentActivity {
769
+ id: string;
770
+ type: string;
771
+ description: string;
772
+ timestamp: string;
773
+ [key: string]: unknown;
774
+ }
775
+ interface RiskSummary {
776
+ overall_risk: string;
777
+ critical: number;
778
+ high: number;
779
+ medium: number;
780
+ low: number;
781
+ trend: string;
782
+ [key: string]: unknown;
783
+ }
784
+ /**
785
+ * Dashboard overview, activity, and risk summary
786
+ */
787
+ declare class DashboardAPI {
788
+ private http;
789
+ constructor(http: HttpClient);
790
+ /**
791
+ * Get dashboard overview metrics
792
+ */
793
+ getOverview(): Promise<DashboardOverview>;
794
+ /**
795
+ * Get recent activity
796
+ */
797
+ getRecentActivity(params?: Record<string, string | number | boolean>): Promise<RecentActivity[]>;
798
+ /**
799
+ * Get risk summary
800
+ */
801
+ getRiskSummary(): Promise<RiskSummary>;
802
+ }
803
+
804
+ interface FinOpsRecommendation {
805
+ id: string;
806
+ type: string;
807
+ description: string;
808
+ estimated_savings: number;
809
+ priority: string;
810
+ [key: string]: unknown;
811
+ }
812
+ interface FinOpsCosts {
813
+ total: number;
814
+ by_service: Record<string, number>;
815
+ by_provider: Record<string, number>;
816
+ period: string;
817
+ [key: string]: unknown;
818
+ }
819
+ interface FinOpsOptimization {
820
+ id: string;
821
+ status: string;
822
+ savings_achieved: number;
823
+ details: string;
824
+ [key: string]: unknown;
825
+ }
826
+ /**
827
+ * FinOps cost optimization and recommendations
828
+ */
829
+ declare class FinOpsAPI {
830
+ private http;
831
+ constructor(http: HttpClient);
832
+ /**
833
+ * Get cost optimization recommendations
834
+ */
835
+ getRecommendations(params?: Record<string, string | number | boolean>): Promise<FinOpsRecommendation[]>;
836
+ /**
837
+ * Get cost breakdown
838
+ */
839
+ getCosts(params?: Record<string, string | number | boolean>): Promise<FinOpsCosts>;
840
+ /**
841
+ * Get optimization details
842
+ */
843
+ getOptimization(params?: Record<string, string | number | boolean>): Promise<FinOpsOptimization[]>;
844
+ }
845
+
846
+ interface MarketplaceTemplate {
847
+ id: string;
848
+ name: string;
849
+ description: string;
850
+ category: string;
851
+ author: string;
852
+ downloads: number;
853
+ rating: number;
854
+ [key: string]: unknown;
855
+ }
856
+ interface MarketplaceCategory {
857
+ id: string;
858
+ name: string;
859
+ description: string;
860
+ templates_count: number;
861
+ [key: string]: unknown;
862
+ }
863
+ /**
864
+ * Marketplace templates, categories, and featured items
865
+ */
866
+ declare class MarketplaceAPI {
867
+ private http;
868
+ constructor(http: HttpClient);
869
+ /**
870
+ * List marketplace templates
871
+ */
872
+ listTemplates(params?: Record<string, string | number | boolean>): Promise<MarketplaceTemplate[]>;
873
+ /**
874
+ * List marketplace categories
875
+ */
876
+ listCategories(): Promise<MarketplaceCategory[]>;
877
+ /**
878
+ * Get featured templates
879
+ */
880
+ getFeatured(): Promise<MarketplaceTemplate[]>;
881
+ }
882
+
883
+ interface APIKey {
884
+ id: string;
885
+ name: string;
886
+ prefix: string;
887
+ created_at: string;
888
+ last_used_at: string | null;
889
+ expires_at: string | null;
890
+ is_active: boolean;
891
+ [key: string]: unknown;
892
+ }
893
+ interface APIKeyCreateResult {
894
+ id: string;
895
+ name: string;
896
+ key: string;
897
+ prefix: string;
898
+ created_at: string;
899
+ [key: string]: unknown;
900
+ }
901
+ /**
902
+ * API key management operations
903
+ */
904
+ declare class APIKeysAPI {
905
+ private http;
906
+ constructor(http: HttpClient);
907
+ /**
908
+ * List API keys
909
+ */
910
+ list(params?: Record<string, string | number | boolean>): Promise<APIKey[]>;
911
+ /**
912
+ * Create a new API key
913
+ */
914
+ create(options: {
915
+ name: string;
916
+ expires_in_days?: number;
917
+ scopes?: string[];
918
+ }): Promise<APIKeyCreateResult>;
919
+ /**
920
+ * Revoke an API key
921
+ */
922
+ revoke(keyId: string): Promise<Record<string, unknown>>;
923
+ }
924
+
643
925
  interface AribotOptions {
644
926
  baseUrl?: string;
645
927
  timeout?: number;
@@ -690,6 +972,18 @@ declare class Aribot {
690
972
  digitalTwin: DigitalTwinAPI;
691
973
  /** Economics and cost analysis */
692
974
  economics: EconomicsAPI;
975
+ /** AI usage and analysis */
976
+ ai: AIAPI;
977
+ /** SBOM document management */
978
+ sbom: SBOMAPI;
979
+ /** Dashboard overview and metrics */
980
+ dashboard: DashboardAPI;
981
+ /** FinOps cost optimization */
982
+ finops: FinOpsAPI;
983
+ /** Marketplace templates */
984
+ marketplace: MarketplaceAPI;
985
+ /** API key management */
986
+ apiKeys: APIKeysAPI;
693
987
  /**
694
988
  * Create Aribot client
695
989
  *
@@ -759,4 +1053,4 @@ declare class ServerError extends AribotError {
759
1053
  constructor(message: string, statusCode?: number, response?: Record<string, unknown>);
760
1054
  }
761
1055
 
762
- export { type AnalyzeDiagramOptions, Aribot, AribotError, type AribotOptions, AuthenticationError, type CloudAccount, type CloudFinding, type CloudProvider, type CloudResource, type CloudScan, type CloudScanOptions, CloudSecurityAPI, ComplianceAPI, type ComplianceGap, type ComplianceResult, type ScanOptions$1 as ComplianceScanOptions, type ComplianceStandard, type Component, type ComponentCloudMapping, type ComponentCost, type Control, type CreateProjectOptions, type Diagram, type DiagramComponentStatus, type DiagramCostAnalysis, DigitalTwinAPI, EconomicsAPI, type EconomicsDashboard, type Finding, type GatesConfig, type GetFindingsOptions, type ListDiagramsOptions, type ListScansOptions, type MarketIntelligence, NotFoundError, PipelineAPI, type PipelineScan, type ScanOptions as PipelineScanOptions, type Project, RateLimitError, RedTeamAPI, type RedTeamMethodology, type RedTeamSimulation, ServerError, type Threat, type ThreatIntelligence, ThreatModelingAPI, ValidationError };
1056
+ export { AIAPI, type AIAnalysisResult, type AIModel, type AIQueueStatus, type AIQuota, type AIUsage, type APIKey, type APIKeyCreateResult, APIKeysAPI, type AnalyzeDiagramOptions, Aribot, AribotError, type AribotOptions, AuthenticationError, type CloudAccount, type CloudFinding, type CloudProvider, type CloudResource, type CloudScan, type CloudScanOptions, CloudSecurityAPI, ComplianceAPI, type ComplianceGap, type ComplianceResult, type ScanOptions$1 as ComplianceScanOptions, type ComplianceStandard, type Component, type ComponentCloudMapping, type ComponentCost, type Control, type CreateProjectOptions, DashboardAPI, type DashboardOverview, type Diagram, type DiagramComponentStatus, type DiagramCostAnalysis, DigitalTwinAPI, EconomicsAPI, type EconomicsDashboard, FinOpsAPI, type FinOpsCosts, type FinOpsOptimization, type FinOpsRecommendation, type Finding, type GatesConfig, type GetFindingsOptions, type ListDiagramsOptions, type ListScansOptions, type MarketIntelligence, MarketplaceAPI, type MarketplaceCategory, type MarketplaceTemplate, NotFoundError, PipelineAPI, type PipelineScan, type ScanOptions as PipelineScanOptions, type Project, RateLimitError, type RecentActivity, RedTeamAPI, type RedTeamMethodology, type RedTeamSimulation, type RiskSummary, SBOMAPI, type SBOMDocument, type SBOMVulnerability, ServerError, type Threat, type ThreatIntelligence, ThreatModelingAPI, ValidationError };
package/dist/index.js CHANGED
@@ -20,17 +20,23 @@ var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: tru
20
20
  // src/index.ts
21
21
  var index_exports = {};
22
22
  __export(index_exports, {
23
+ AIAPI: () => AIAPI,
24
+ APIKeysAPI: () => APIKeysAPI,
23
25
  Aribot: () => Aribot,
24
26
  AribotError: () => AribotError,
25
27
  AuthenticationError: () => AuthenticationError,
26
28
  CloudSecurityAPI: () => CloudSecurityAPI,
27
29
  ComplianceAPI: () => ComplianceAPI,
30
+ DashboardAPI: () => DashboardAPI,
28
31
  DigitalTwinAPI: () => DigitalTwinAPI,
29
32
  EconomicsAPI: () => EconomicsAPI,
33
+ FinOpsAPI: () => FinOpsAPI,
34
+ MarketplaceAPI: () => MarketplaceAPI,
30
35
  NotFoundError: () => NotFoundError,
31
36
  PipelineAPI: () => PipelineAPI,
32
37
  RateLimitError: () => RateLimitError,
33
38
  RedTeamAPI: () => RedTeamAPI,
39
+ SBOMAPI: () => SBOMAPI,
34
40
  ServerError: () => ServerError,
35
41
  ThreatModelingAPI: () => ThreatModelingAPI,
36
42
  ValidationError: () => ValidationError
@@ -80,7 +86,7 @@ var ServerError = class extends AribotError {
80
86
  };
81
87
 
82
88
  // src/http.ts
83
- var DEFAULT_BASE_URL = "https://api.aribot.aristiun.com/aribot-api";
89
+ var DEFAULT_BASE_URL = "https://api.aribot.ayurak.com/aribot-api";
84
90
  var DEFAULT_TIMEOUT = 3e4;
85
91
  var MAX_RETRIES = 3;
86
92
  function sleep(ms) {
@@ -165,7 +171,7 @@ var HttpClient = class {
165
171
  }
166
172
  const headers = {
167
173
  "X-API-Key": this.apiKey,
168
- "User-Agent": "aribot-js/1.0.0"
174
+ "User-Agent": "aribot-js/1.4.0"
169
175
  };
170
176
  let body;
171
177
  if (options.formData) {
@@ -915,6 +921,239 @@ var EconomicsAPI = class {
915
921
  }
916
922
  };
917
923
 
924
+ // src/ai.ts
925
+ var AIAPI = class {
926
+ constructor(http) {
927
+ this.http = http;
928
+ }
929
+ /**
930
+ * Get AI usage statistics
931
+ */
932
+ async getUsage(period) {
933
+ const params = {};
934
+ if (period) params.period = period;
935
+ return await this.http.get("/v2/ai/usage/", params);
936
+ }
937
+ /**
938
+ * Get AI quota information
939
+ */
940
+ async getQuota() {
941
+ return await this.http.get("/v2/ai/quota/");
942
+ }
943
+ /**
944
+ * List available AI models
945
+ */
946
+ async listModels() {
947
+ const result = await this.http.get("/v2/ai/models/");
948
+ if (Array.isArray(result)) {
949
+ return result;
950
+ }
951
+ const data = result;
952
+ return data.results || data.models || [];
953
+ }
954
+ /**
955
+ * Configure AI settings
956
+ */
957
+ async configure(config) {
958
+ return await this.http.post("/v2/ai/configure/", config);
959
+ }
960
+ /**
961
+ * Run AI analysis
962
+ */
963
+ async analyze(options) {
964
+ return await this.http.post("/v2/ai/analyze/", options);
965
+ }
966
+ /**
967
+ * Get AI processing queue status
968
+ */
969
+ async getQueueStatus() {
970
+ return await this.http.get("/v2/ai/queue-status/");
971
+ }
972
+ };
973
+
974
+ // src/sbom.ts
975
+ var SBOMAPI = class {
976
+ constructor(http) {
977
+ this.http = http;
978
+ }
979
+ /**
980
+ * List SBOM documents
981
+ */
982
+ async list(params) {
983
+ const result = await this.http.get("/v2/sbom/documents/", params);
984
+ if (Array.isArray(result)) {
985
+ return result;
986
+ }
987
+ const data = result;
988
+ return data.results || data.documents || [];
989
+ }
990
+ /**
991
+ * Get SBOM document details
992
+ */
993
+ async get(documentId) {
994
+ return await this.http.get(`/v2/sbom/documents/${documentId}/`);
995
+ }
996
+ /**
997
+ * Upload an SBOM document
998
+ */
999
+ async upload(file, options) {
1000
+ const formData = new FormData();
1001
+ formData.append("file", file);
1002
+ if (options?.name) formData.append("name", options.name);
1003
+ if (options?.format) formData.append("format", options.format);
1004
+ return await this.http.post("/v2/sbom/documents/", void 0, formData);
1005
+ }
1006
+ /**
1007
+ * Get vulnerabilities for an SBOM document
1008
+ */
1009
+ async getVulnerabilities(documentId, params) {
1010
+ const result = await this.http.get(
1011
+ `/v2/sbom/documents/${documentId}/vulnerabilities/`,
1012
+ params
1013
+ );
1014
+ if (Array.isArray(result)) {
1015
+ return result;
1016
+ }
1017
+ const data = result;
1018
+ return data.results || data.vulnerabilities || [];
1019
+ }
1020
+ };
1021
+
1022
+ // src/dashboard.ts
1023
+ var DashboardAPI = class {
1024
+ constructor(http) {
1025
+ this.http = http;
1026
+ }
1027
+ /**
1028
+ * Get dashboard overview metrics
1029
+ */
1030
+ async getOverview() {
1031
+ return await this.http.get("/v2/dashboard/overview/");
1032
+ }
1033
+ /**
1034
+ * Get recent activity
1035
+ */
1036
+ async getRecentActivity(params) {
1037
+ const result = await this.http.get("/v2/dashboard/recent/", params);
1038
+ if (Array.isArray(result)) {
1039
+ return result;
1040
+ }
1041
+ const data = result;
1042
+ return data.results || data.activities || [];
1043
+ }
1044
+ /**
1045
+ * Get risk summary
1046
+ */
1047
+ async getRiskSummary() {
1048
+ return await this.http.get("/v2/dashboard/risk/");
1049
+ }
1050
+ };
1051
+
1052
+ // src/finops.ts
1053
+ var FinOpsAPI = class {
1054
+ constructor(http) {
1055
+ this.http = http;
1056
+ }
1057
+ /**
1058
+ * Get cost optimization recommendations
1059
+ */
1060
+ async getRecommendations(params) {
1061
+ const result = await this.http.get("/v2/finops/recommendations/", params);
1062
+ if (Array.isArray(result)) {
1063
+ return result;
1064
+ }
1065
+ const data = result;
1066
+ return data.results || data.recommendations || [];
1067
+ }
1068
+ /**
1069
+ * Get cost breakdown
1070
+ */
1071
+ async getCosts(params) {
1072
+ return await this.http.get("/v2/finops/costs/", params);
1073
+ }
1074
+ /**
1075
+ * Get optimization details
1076
+ */
1077
+ async getOptimization(params) {
1078
+ const result = await this.http.get("/v2/finops/optimization/", params);
1079
+ if (Array.isArray(result)) {
1080
+ return result;
1081
+ }
1082
+ const data = result;
1083
+ return data.results || data.optimizations || [];
1084
+ }
1085
+ };
1086
+
1087
+ // src/marketplace.ts
1088
+ var MarketplaceAPI = class {
1089
+ constructor(http) {
1090
+ this.http = http;
1091
+ }
1092
+ /**
1093
+ * List marketplace templates
1094
+ */
1095
+ async listTemplates(params) {
1096
+ const result = await this.http.get("/v2/marketplace/templates/", params);
1097
+ if (Array.isArray(result)) {
1098
+ return result;
1099
+ }
1100
+ const data = result;
1101
+ return data.results || data.templates || [];
1102
+ }
1103
+ /**
1104
+ * List marketplace categories
1105
+ */
1106
+ async listCategories() {
1107
+ const result = await this.http.get("/v2/marketplace/categories/");
1108
+ if (Array.isArray(result)) {
1109
+ return result;
1110
+ }
1111
+ const data = result;
1112
+ return data.results || data.categories || [];
1113
+ }
1114
+ /**
1115
+ * Get featured templates
1116
+ */
1117
+ async getFeatured() {
1118
+ const result = await this.http.get("/v2/marketplace/featured/");
1119
+ if (Array.isArray(result)) {
1120
+ return result;
1121
+ }
1122
+ const data = result;
1123
+ return data.results || data.templates || [];
1124
+ }
1125
+ };
1126
+
1127
+ // src/api-keys.ts
1128
+ var APIKeysAPI = class {
1129
+ constructor(http) {
1130
+ this.http = http;
1131
+ }
1132
+ /**
1133
+ * List API keys
1134
+ */
1135
+ async list(params) {
1136
+ const result = await this.http.get("/v2/api-keys/", params);
1137
+ if (Array.isArray(result)) {
1138
+ return result;
1139
+ }
1140
+ const data = result;
1141
+ return data.results || data.keys || [];
1142
+ }
1143
+ /**
1144
+ * Create a new API key
1145
+ */
1146
+ async create(options) {
1147
+ return await this.http.post("/v2/api-keys/", options);
1148
+ }
1149
+ /**
1150
+ * Revoke an API key
1151
+ */
1152
+ async revoke(keyId) {
1153
+ return await this.http.post(`/v2/api-keys/${keyId}/revoke/`);
1154
+ }
1155
+ };
1156
+
918
1157
  // src/client.ts
919
1158
  var Aribot = class {
920
1159
  /**
@@ -936,6 +1175,12 @@ var Aribot = class {
936
1175
  this.redTeam = new RedTeamAPI(this.http);
937
1176
  this.digitalTwin = new DigitalTwinAPI(this.http);
938
1177
  this.economics = new EconomicsAPI(this.http);
1178
+ this.ai = new AIAPI(this.http);
1179
+ this.sbom = new SBOMAPI(this.http);
1180
+ this.dashboard = new DashboardAPI(this.http);
1181
+ this.finops = new FinOpsAPI(this.http);
1182
+ this.marketplace = new MarketplaceAPI(this.http);
1183
+ this.apiKeys = new APIKeysAPI(this.http);
939
1184
  }
940
1185
  /**
941
1186
  * Check API health status
@@ -958,17 +1203,23 @@ var Aribot = class {
958
1203
  };
959
1204
  // Annotate the CommonJS export names for ESM import in node:
960
1205
  0 && (module.exports = {
1206
+ AIAPI,
1207
+ APIKeysAPI,
961
1208
  Aribot,
962
1209
  AribotError,
963
1210
  AuthenticationError,
964
1211
  CloudSecurityAPI,
965
1212
  ComplianceAPI,
1213
+ DashboardAPI,
966
1214
  DigitalTwinAPI,
967
1215
  EconomicsAPI,
1216
+ FinOpsAPI,
1217
+ MarketplaceAPI,
968
1218
  NotFoundError,
969
1219
  PipelineAPI,
970
1220
  RateLimitError,
971
1221
  RedTeamAPI,
1222
+ SBOMAPI,
972
1223
  ServerError,
973
1224
  ThreatModelingAPI,
974
1225
  ValidationError
package/dist/index.mjs CHANGED
@@ -41,7 +41,7 @@ var ServerError = class extends AribotError {
41
41
  };
42
42
 
43
43
  // src/http.ts
44
- var DEFAULT_BASE_URL = "https://api.aribot.aristiun.com/aribot-api";
44
+ var DEFAULT_BASE_URL = "https://api.aribot.ayurak.com/aribot-api";
45
45
  var DEFAULT_TIMEOUT = 3e4;
46
46
  var MAX_RETRIES = 3;
47
47
  function sleep(ms) {
@@ -126,7 +126,7 @@ var HttpClient = class {
126
126
  }
127
127
  const headers = {
128
128
  "X-API-Key": this.apiKey,
129
- "User-Agent": "aribot-js/1.0.0"
129
+ "User-Agent": "aribot-js/1.4.0"
130
130
  };
131
131
  let body;
132
132
  if (options.formData) {
@@ -876,6 +876,239 @@ var EconomicsAPI = class {
876
876
  }
877
877
  };
878
878
 
879
+ // src/ai.ts
880
+ var AIAPI = class {
881
+ constructor(http) {
882
+ this.http = http;
883
+ }
884
+ /**
885
+ * Get AI usage statistics
886
+ */
887
+ async getUsage(period) {
888
+ const params = {};
889
+ if (period) params.period = period;
890
+ return await this.http.get("/v2/ai/usage/", params);
891
+ }
892
+ /**
893
+ * Get AI quota information
894
+ */
895
+ async getQuota() {
896
+ return await this.http.get("/v2/ai/quota/");
897
+ }
898
+ /**
899
+ * List available AI models
900
+ */
901
+ async listModels() {
902
+ const result = await this.http.get("/v2/ai/models/");
903
+ if (Array.isArray(result)) {
904
+ return result;
905
+ }
906
+ const data = result;
907
+ return data.results || data.models || [];
908
+ }
909
+ /**
910
+ * Configure AI settings
911
+ */
912
+ async configure(config) {
913
+ return await this.http.post("/v2/ai/configure/", config);
914
+ }
915
+ /**
916
+ * Run AI analysis
917
+ */
918
+ async analyze(options) {
919
+ return await this.http.post("/v2/ai/analyze/", options);
920
+ }
921
+ /**
922
+ * Get AI processing queue status
923
+ */
924
+ async getQueueStatus() {
925
+ return await this.http.get("/v2/ai/queue-status/");
926
+ }
927
+ };
928
+
929
+ // src/sbom.ts
930
+ var SBOMAPI = class {
931
+ constructor(http) {
932
+ this.http = http;
933
+ }
934
+ /**
935
+ * List SBOM documents
936
+ */
937
+ async list(params) {
938
+ const result = await this.http.get("/v2/sbom/documents/", params);
939
+ if (Array.isArray(result)) {
940
+ return result;
941
+ }
942
+ const data = result;
943
+ return data.results || data.documents || [];
944
+ }
945
+ /**
946
+ * Get SBOM document details
947
+ */
948
+ async get(documentId) {
949
+ return await this.http.get(`/v2/sbom/documents/${documentId}/`);
950
+ }
951
+ /**
952
+ * Upload an SBOM document
953
+ */
954
+ async upload(file, options) {
955
+ const formData = new FormData();
956
+ formData.append("file", file);
957
+ if (options?.name) formData.append("name", options.name);
958
+ if (options?.format) formData.append("format", options.format);
959
+ return await this.http.post("/v2/sbom/documents/", void 0, formData);
960
+ }
961
+ /**
962
+ * Get vulnerabilities for an SBOM document
963
+ */
964
+ async getVulnerabilities(documentId, params) {
965
+ const result = await this.http.get(
966
+ `/v2/sbom/documents/${documentId}/vulnerabilities/`,
967
+ params
968
+ );
969
+ if (Array.isArray(result)) {
970
+ return result;
971
+ }
972
+ const data = result;
973
+ return data.results || data.vulnerabilities || [];
974
+ }
975
+ };
976
+
977
+ // src/dashboard.ts
978
+ var DashboardAPI = class {
979
+ constructor(http) {
980
+ this.http = http;
981
+ }
982
+ /**
983
+ * Get dashboard overview metrics
984
+ */
985
+ async getOverview() {
986
+ return await this.http.get("/v2/dashboard/overview/");
987
+ }
988
+ /**
989
+ * Get recent activity
990
+ */
991
+ async getRecentActivity(params) {
992
+ const result = await this.http.get("/v2/dashboard/recent/", params);
993
+ if (Array.isArray(result)) {
994
+ return result;
995
+ }
996
+ const data = result;
997
+ return data.results || data.activities || [];
998
+ }
999
+ /**
1000
+ * Get risk summary
1001
+ */
1002
+ async getRiskSummary() {
1003
+ return await this.http.get("/v2/dashboard/risk/");
1004
+ }
1005
+ };
1006
+
1007
+ // src/finops.ts
1008
+ var FinOpsAPI = class {
1009
+ constructor(http) {
1010
+ this.http = http;
1011
+ }
1012
+ /**
1013
+ * Get cost optimization recommendations
1014
+ */
1015
+ async getRecommendations(params) {
1016
+ const result = await this.http.get("/v2/finops/recommendations/", params);
1017
+ if (Array.isArray(result)) {
1018
+ return result;
1019
+ }
1020
+ const data = result;
1021
+ return data.results || data.recommendations || [];
1022
+ }
1023
+ /**
1024
+ * Get cost breakdown
1025
+ */
1026
+ async getCosts(params) {
1027
+ return await this.http.get("/v2/finops/costs/", params);
1028
+ }
1029
+ /**
1030
+ * Get optimization details
1031
+ */
1032
+ async getOptimization(params) {
1033
+ const result = await this.http.get("/v2/finops/optimization/", params);
1034
+ if (Array.isArray(result)) {
1035
+ return result;
1036
+ }
1037
+ const data = result;
1038
+ return data.results || data.optimizations || [];
1039
+ }
1040
+ };
1041
+
1042
+ // src/marketplace.ts
1043
+ var MarketplaceAPI = class {
1044
+ constructor(http) {
1045
+ this.http = http;
1046
+ }
1047
+ /**
1048
+ * List marketplace templates
1049
+ */
1050
+ async listTemplates(params) {
1051
+ const result = await this.http.get("/v2/marketplace/templates/", params);
1052
+ if (Array.isArray(result)) {
1053
+ return result;
1054
+ }
1055
+ const data = result;
1056
+ return data.results || data.templates || [];
1057
+ }
1058
+ /**
1059
+ * List marketplace categories
1060
+ */
1061
+ async listCategories() {
1062
+ const result = await this.http.get("/v2/marketplace/categories/");
1063
+ if (Array.isArray(result)) {
1064
+ return result;
1065
+ }
1066
+ const data = result;
1067
+ return data.results || data.categories || [];
1068
+ }
1069
+ /**
1070
+ * Get featured templates
1071
+ */
1072
+ async getFeatured() {
1073
+ const result = await this.http.get("/v2/marketplace/featured/");
1074
+ if (Array.isArray(result)) {
1075
+ return result;
1076
+ }
1077
+ const data = result;
1078
+ return data.results || data.templates || [];
1079
+ }
1080
+ };
1081
+
1082
+ // src/api-keys.ts
1083
+ var APIKeysAPI = class {
1084
+ constructor(http) {
1085
+ this.http = http;
1086
+ }
1087
+ /**
1088
+ * List API keys
1089
+ */
1090
+ async list(params) {
1091
+ const result = await this.http.get("/v2/api-keys/", params);
1092
+ if (Array.isArray(result)) {
1093
+ return result;
1094
+ }
1095
+ const data = result;
1096
+ return data.results || data.keys || [];
1097
+ }
1098
+ /**
1099
+ * Create a new API key
1100
+ */
1101
+ async create(options) {
1102
+ return await this.http.post("/v2/api-keys/", options);
1103
+ }
1104
+ /**
1105
+ * Revoke an API key
1106
+ */
1107
+ async revoke(keyId) {
1108
+ return await this.http.post(`/v2/api-keys/${keyId}/revoke/`);
1109
+ }
1110
+ };
1111
+
879
1112
  // src/client.ts
880
1113
  var Aribot = class {
881
1114
  /**
@@ -897,6 +1130,12 @@ var Aribot = class {
897
1130
  this.redTeam = new RedTeamAPI(this.http);
898
1131
  this.digitalTwin = new DigitalTwinAPI(this.http);
899
1132
  this.economics = new EconomicsAPI(this.http);
1133
+ this.ai = new AIAPI(this.http);
1134
+ this.sbom = new SBOMAPI(this.http);
1135
+ this.dashboard = new DashboardAPI(this.http);
1136
+ this.finops = new FinOpsAPI(this.http);
1137
+ this.marketplace = new MarketplaceAPI(this.http);
1138
+ this.apiKeys = new APIKeysAPI(this.http);
900
1139
  }
901
1140
  /**
902
1141
  * Check API health status
@@ -918,17 +1157,23 @@ var Aribot = class {
918
1157
  }
919
1158
  };
920
1159
  export {
1160
+ AIAPI,
1161
+ APIKeysAPI,
921
1162
  Aribot,
922
1163
  AribotError,
923
1164
  AuthenticationError,
924
1165
  CloudSecurityAPI,
925
1166
  ComplianceAPI,
1167
+ DashboardAPI,
926
1168
  DigitalTwinAPI,
927
1169
  EconomicsAPI,
1170
+ FinOpsAPI,
1171
+ MarketplaceAPI,
928
1172
  NotFoundError,
929
1173
  PipelineAPI,
930
1174
  RateLimitError,
931
1175
  RedTeamAPI,
1176
+ SBOMAPI,
932
1177
  ServerError,
933
1178
  ThreatModelingAPI,
934
1179
  ValidationError
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@ayurak/sdk",
3
- "version": "1.1.0",
3
+ "version": "1.4.0",
4
4
  "description": "Aribot Security Platform SDK by Aristiun & Ayurak - Threat modeling, compliance, and cloud security APIs",
5
5
  "main": "dist/index.js",
6
6
  "module": "dist/index.mjs",