Account & control plane
TypeScript SDK reference for the account and control plane — identity, usage, limits, billing, API keys, team, devices, audit logs, execution policy, deployments, health, and version.
This page is the AlgentaClient reference for administering your organization: who you are, what you've used, your API keys, teammates, devices, audit trail, execution policy, and managed deployments — plus health and version probes. Method names are camelCase; request bodies and query parameters stay snake_case, mirroring the HTTP contract. All examples assume a constructed client:
import { AlgentaClient } from "algenta-sdk";
const client = new AlgentaClient({
apiKey: process.env.ALGENTA_API_KEY ?? process.env.DE_API_KEY,
baseUrl: process.env.ALGENTA_BASE_URL ?? "https://api.algenta.ai",
});Identity and usage
me returns your user and organization; updateMe edits your display name or org name; usage, limits, distributions, and templates describe what your plan allows and what the engine supports.
const me = await client.me();
console.log(me.user.email, me.org.name, me.org.plan);
await client.updateMe({ name: "Ada Lovelace", org_name: "Analytical Engines" });
const usage = await client.usage();
console.log(usage.simulations_run, usage.api_calls, usage.quota_used_pct);
const limits = await client.limits();
console.log(limits.plan, limits.rate_limit_per_minute);curl -sS "$ALGENTA_BASE_URL/v1/me" \
-H "Authorization: Bearer $ALGENTA_API_KEY"me()
GET /v1/me
Current user and organization.
updateMe(request)
PATCH /v1/me
UpdateMeRequest (name, org_name).
usage()
GET /v1/usage
Simulations run, API calls, quota usage.
limits()
GET /v1/limits
Unlimited execution policy, request-shape bounds, and worker capacity.
distributions()
GET /v1/distributions
Supported distributions with example params.
templates()
GET /v1/templates
Simulation templates with example requests.
Billing and credits
getBillingInfo reports the current plan and subscription; createBillingCheckout and createBillingPortal return a hosted url to redirect to. refreshCredits and ingestMeteringEvents are generic managed-runtime compatibility methods. Self-hosted Algenta does not use them for billing or enforcement.
getBillingInfo()
GET /v1/billing/info
Plan, subscription status, current period end.
createBillingCheckout(options?)
POST /v1/billing/checkout
plan is developer or pro; returns a hosted url.
createBillingPortal()
POST /v1/billing/portal
Returns the billing-portal url.
refreshCredits(request)
POST /v1/credits/refresh
CreditRefreshRequest (device_id, billing_period, credits_used).
ingestMeteringEvents(request)
POST /v1/metering
MeteringBatchRequest (device_id, events); returns { accepted, billing_period }.
API keys
Create scoped keys, list them, and revoke them. The raw secret is returned exactly once, on creation, as raw_key.
listApiKeys()
GET /v1/api-keys
All keys with key_prefix, status, and timestamps.
createApiKey(request)
POST /v1/api-keys
CreateAPIKeyRequest (label, expires_at, device_limit); returns raw_key once.
revokeApiKey(keyId)
DELETE /v1/api-keys/{key_id}
Revoke a key.
Team
Invite teammates, list members, change roles, and remove people. Roles are owner, admin, member, or viewer.
listTeamMembers(options?)
GET /v1/team
Options: page, limit.
inviteTeamMember(request)
POST /v1/team/invite
TeamInviteRequest (email, role).
updateTeamMemberRole(userId, role)
PATCH /v1/team/{user_id}/role
role is owner, admin, member, or viewer.
removeTeamMember(userId)
DELETE /v1/team/{user_id}
Remove a member.
Devices
List devices bound to your keys and revoke a device registration.
listDevices(options?)
GET /v1/device/list
Options: page, limit. Reports device_count, device_limit, plan.
revokeDevice(registrationId)
DELETE /v1/device/{registration_id}
Revoke one device registration.
Audit logs
Read the tamper-evident audit trail, filtered by actor, action, resource, result, or provenance hashes. getAuditLogArtifacts adds a content_hash filter for artifact-level entries.
getAuditLogs(options?)
GET /v1/audit-logs
Filters: actor_email, action, resource_type, result, policy_snapshot_id, schema_snapshot_id, manifest_version, request_hash, plus pagination.
getAuditLogArtifacts(options?)
GET /v1/audit-logs/artifacts
Same filters as above plus content_hash.
Execution policy
The execution policy gates which decisions the engine may act on. Read the current policy, list its immutable snapshots, and update it — every change creates a new snapshot.
getExecutionPolicy()
GET /v1/execution/policy
Current policy and its snapshot_id.
listExecutionPolicySnapshots()
GET /v1/execution/policy/snapshots
Full snapshot history.
updateExecutionPolicy(request)
PATCH /v1/execution/policy
UpdateExecutionPolicyRequest (min_confidence, risk_floor, require_calibration, allow_reexecution).
Deployments
List regions, read your managed deployment, create or delete one, and read its cost breakdown. getDeployment returns null when no deployment exists.
listDeploymentRegions()
GET /v1/deployments/regions
Providers and their regions.
getDeployment()
GET /v1/deployments
Your deployment, or null.
createDeployment(request?)
POST /v1/deployments
CreateDeploymentRequest (provider, region, config, billing_markup_pct).
deleteDeployment(deploymentId)
DELETE /v1/deployments/{deployment_id}
Tear down a deployment.
getDeploymentCost(deploymentId)
GET /v1/deployments/{deployment_id}/cost
Cost breakdown for a deployment.
Health and version
Unauthenticated liveness and build-version probes.
health()
GET /v1/health
{ status, timestamp }.
version()
GET /v1/version
{ api_version, engine_version, environment }.
Related pages
Authentication & API keysJobs, triggers & capabilitiesTypeScript SDKLast updated
Was this helpful?