Skip to content
MyStocks Developers
API v1

API v1

Current stable contract

Versioning policyRelease changelog
Sandbox console

Get enterprise security controls

Enterprise Governance, Security & Access

GET

/security

Get enterprise security controls

Production onlygetEnterpriseSecurity

Returns the active enterprise security policy for the authenticated partner key, including IP allowlists, signed-request requirements, mTLS gateway requirements, scoped-key governance, rotation policy, and security evidence metadata.

Parameters

This endpoint has no path or query parameters.

Headers

AuthorizationstringRequired

Bearer sk_sandbox_<your_key> for sandbox requests.

Response fields

policyobject
policy.ipAllowliststring[]

Exact IP addresses or IPv4 CIDR ranges allowed to call this partner key. Empty means no IP restriction.

Example: ["203.0.113.10","198.51.100.0/24"]

policy.requireSignedRequestsboolean

Require HMAC-signed non-GET requests. Send X-MS-Timestamp (ISO-8601, within a 5-minute window) and X-MS-Signature = hex HMAC-SHA256(apiKey, "{timestamp}.{METHOD}.{path}{?query}.{sha256(body)}"). The signed path includes the query string (leading ?, empty when absent) so query-parameter tampering is detected. Signing without the query string is accepted for backward compatibility but deprecated.

Example: true

policy.requireMtlsboolean

Require upstream mTLS verification headers from the API gateway.

Example: false

policy.scopedKeysRequiredboolean

When true, API keys must carry explicit scopes — a key with no scopes is denied (403) rather than granted broad access. A key that should retain full access under this policy must hold the scope. When false (default), unscoped keys keep broad access.

Example: true

policy.keyRotationDaysinteger | null

Required API key rotation interval in days.

Example: 90

policy.oauthClientCredentialsEnabledboolean

Indicates OAuth client-credentials support is enabled for this partner.

Example: false

policy.soc2EvidenceUrlstring | null

HTTPS link to SOC 2 evidence or trust-center artifact.

policy.pentestEvidenceUrlstring | null

HTTPS link to penetration-test evidence.

policy.lastRotationAtstring | null
keyobject
key.keyIdstring
key.partnerIdstring
key.keyTypefull | data
key.scopesstring[]
key.requiredScopeForThisEndpointstring | null
key.rotationDueAtstring | null
signedRequestSpecobject
signedRequestSpec.headersstring[]
signedRequestSpec.algorithmstring

Example: "HMAC-SHA256"

signedRequestSpec.payloadstring

Example: "timestamp.method.path.sha256(raw_request_body)"

signedRequestSpec.timestampToleranceSecondsinteger

Example: 300

mtlsobject
mtls.acceptedGatewayHeadersstring[]

Response codes

200Active enterprise security policy.