Class: ModelSecurityClient
Defined in: src/model-security/client.ts:50
Client for AIRS Model Security API operations. Uses two base URLs: data plane for scans, management plane for security groups/rules. Authenticates via OAuth2 client_credentials flow (shared token for both planes).
Example
import { ModelSecurityClient } from '@cdot65/prisma-airs-sdk';
// Reads PANW_MODEL_SEC_* (falling back to PANW_MGMT_*) env vars.
const ms = new ModelSecurityClient();
const scans = await ms.scans.list({ limit: 5 });
// scans.scans => [{ uuid: '550e8400-...', eval_outcome: 'ALLOWED', ... }]
Constructors
Constructor
new ModelSecurityClient(opts?): ModelSecurityClient;
Defined in: src/model-security/client.ts:62
Parameters
| Parameter | Type |
|---|---|
opts | ModelSecurityClientOptions |
Returns
ModelSecurityClient
Properties
scans
readonly scans: ModelSecurityScansClient;
Defined in: src/model-security/client.ts:52
Data plane scan operations.
securityGroups
readonly securityGroups: ModelSecurityGroupsClient;
Defined in: src/model-security/client.ts:54
Management plane security group operations.
securityRules
readonly securityRules: ModelSecurityRulesClient;
Defined in: src/model-security/client.ts:56
Management plane security rule operations (read-only).
Methods
getPyPIAuth()
getPyPIAuth(): Promise<objectOutputType<{
url: ZodString;
expires_at: ZodString;
}, ZodTypeAny, "passthrough">>;
Defined in: src/model-security/client.ts:110
Get PyPI authentication credentials for Google Artifact Registry.
Returns
Promise<objectOutputType<{
url: ZodString;
expires_at: ZodString;
}, ZodTypeAny, "passthrough">>
PyPI auth response with URL and expiration.
Example
import { ModelSecurityClient } from '@cdot65/prisma-airs-sdk';
const ms = new ModelSecurityClient();
const auth = await ms.getPyPIAuth();
// auth =>
// { url: 'https://_token:ya29...@us-python.pkg.dev/...', expires_at: '2025-01-01T01:00:00Z' }