{"_id":"@atlanai/sdk","_rev":"5-73e9c374282b14e0a5b7a82a4836b65a","name":"@atlanai/sdk","dist-tags":{"latest":"0.2.3"},"versions":{"0.1.0":{"name":"@atlanai/sdk","version":"0.1.0","license":"Apache-2.0","_id":"@atlanai/sdk@0.1.0","maintainers":[{"name":"atlan-engineering","email":"engineering@atlan.com"},{"name":"hrushikesh.dokala","email":"hrushikesh.dokala@atlan.com"}],"dist":{"shasum":"2ae74607f237a5f6b484a7bbc912032e0861ef5a","tarball":"https://registry.npmjs.org/@atlanai/sdk/-/sdk-0.1.0.tgz","fileCount":1044,"integrity":"sha512-+iPuEWdzt8Pq1J5ylf9ltz1kb7O0ANDRMrHDxkm/L9OOwmwq2wpIRTzP+Ufo/GmtIPoiaTtYCh4FLcMb3HylJg==","signatures":[{"sig":"MEUCIQDCHHiTCXGYpg4R7kFKrKhUJ9xvu2qSM03C5Q1eoqs2zQIgAsQBMJI71Qb7+xjXxxrQd+njqULwYudAbSK+kUyZelA=","keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U"}],"unpackedSize":4096357},"main":"./dist/index.js","type":"commonjs","types":"./dist/index.d.ts","engines":{"node":">=20"},"exports":{".":{"types":"./dist/index.d.ts","default":"./dist/index.js","require":"./dist/index.js"},"./raw/*":{"types":"./dist/raw/*/index.d.ts","default":"./dist/raw/*/index.js","require":"./dist/raw/*/index.js"},"./tracing":{"types":"./dist/tracing/index.d.ts","import":"./dist/tracing/index.js","default":"./dist/tracing/index.js"},"./manifest.json":"./dist/manifest.json","./resources.json":"./dist/resources.json"},"gitHead":"11ffce0ffc0fb0939c535558ee4a5dcc8c7b09b1","scripts":{"test":"npm run build && node --test test/*.cjs && npm run test:tracing","build":"tsc -p tsconfig.json && tsc -p tsconfig.tracing.json","pack:check":"npm pack --dry-run","test:tracing":"vitest run"},"_npmUser":{"name":"hrushikesh.dokala","email":"hrushikesh.dokala@atlan.com"},"overrides":{"postcss":"8.5.26"},"_npmVersion":"10.9.4","description":"Atlan Agent Gateway management SDK","directories":{},"_nodeVersion":"22.21.1","dependencies":{"@opentelemetry/api":"^1.9.0","@opentelemetry/core":"^2.0.1","@opentelemetry/resources":"^2.0.1","@opentelemetry/sdk-trace-base":"^2.0.1","@opentelemetry/otlp-exporter-base":">=0.200.0 <1","@opentelemetry/exporter-trace-otlp-proto":">=0.200.0 <1"},"_hasShrinkwrap":false,"devDependencies":{"ai":"6.0.271","vitest":"^3.2.4","typescript":"5.9.3","@types/node":"^22.20.1","@langfuse/otel":"^5.11.0","@langfuse/tracing":"^5.11.0"},"_npmOperationalInternal":{"tmp":"tmp/sdk_0.1.0_1788443173566_0.13616191547648326","host":"s3://npm-registry-packages-npm-production"}},"0.1.1":{"name":"@atlanai/sdk","version":"0.1.1","license":"Apache-2.0","_id":"@atlanai/sdk@0.1.1","maintainers":[{"name":"atlan-engineering","email":"engineering@atlan.com"},{"name":"hrushikesh.dokala","email":"hrushikesh.dokala@atlan.com"}],"dist":{"shasum":"08ab9394c82abf97bed9078b1b1f9ecbecd404ec","tarball":"https://registry.npmjs.org/@atlanai/sdk/-/sdk-0.1.1.tgz","fileCount":1044,"integrity":"sha512-8Up0TMiTF+I4JmZCT/5xI/VgZn4oURB631T/bhVrOkfGoFbCh8D8IoBChe4+9xXzV/nBQpd0vfdyUnQ855tWpg==","signatures":[{"sig":"MEYCIQCY3T51R6aUniZZ6xQkWson3s+AbCJaxU0v1npWiYmBiAIhAJmSc5BpMziXfR1WEIiyhIBgyRdNa0fvopYRxmkqfOld","keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U"}],"unpackedSize":4097265},"main":"./dist/index.js","type":"commonjs","_from":"file:dist/typescript/atlanai-sdk-0.1.1.tgz","types":"./dist/index.d.ts","engines":{"node":">=20"},"exports":{".":{"types":"./dist/index.d.ts","default":"./dist/index.js","require":"./dist/index.js"},"./raw/*":{"types":"./dist/raw/*/index.d.ts","default":"./dist/raw/*/index.js","require":"./dist/raw/*/index.js"},"./tracing":{"types":"./dist/tracing/index.d.ts","import":"./dist/tracing/index.js","default":"./dist/tracing/index.js"},"./manifest.json":"./dist/manifest.json","./resources.json":"./dist/resources.json"},"scripts":{"test":"npm run build && node --test test/*.cjs && npm run test:tracing","build":"tsc -p tsconfig.json && tsc -p tsconfig.tracing.json","pack:check":"npm pack --dry-run","test:tracing":"vitest run"},"_npmUser":{"name":"GitHub Actions","email":"npm-oidc-no-reply@github.com","trustedPublisher":{"id":"github","oidcConfigId":"oidc:c3f30168-af81-4a26-9348-2a4227ffec6f"}},"_resolved":"/home/runner/work/sdk/sdk/dist/typescript/atlanai-sdk-0.1.1.tgz","overrides":{"postcss":"8.5.26"},"_integrity":"sha512-8Up0TMiTF+I4JmZCT/5xI/VgZn4oURB631T/bhVrOkfGoFbCh8D8IoBChe4+9xXzV/nBQpd0vfdyUnQ855tWpg==","_npmVersion":"11.10.1","description":"Atlan Agent Gateway management SDK","directories":{},"_nodeVersion":"24.4.0","dependencies":{"@opentelemetry/api":"^1.9.0","@opentelemetry/core":"^2.0.1","@opentelemetry/resources":"^2.0.1","@opentelemetry/sdk-trace-base":"^2.0.1","@opentelemetry/otlp-exporter-base":">=0.200.0 <1","@opentelemetry/exporter-trace-otlp-proto":">=0.200.0 <1"},"_hasShrinkwrap":false,"devDependencies":{"ai":"6.0.271","vitest":"^3.2.4","typescript":"5.9.3","@types/node":"^22.20.1","@langfuse/otel":"^5.11.0","@langfuse/tracing":"^5.11.0"},"_npmOperationalInternal":{"tmp":"tmp/sdk_0.1.1_1788457365122_0.4483998636364017","host":"s3://npm-registry-packages-npm-production"}},"0.2.1":{"name":"@atlanai/sdk","version":"0.2.1","license":"Apache-2.0","_id":"@atlanai/sdk@0.2.1","maintainers":[{"name":"atlan-engineering","email":"engineering@atlan.com"},{"name":"hrushikesh.dokala","email":"hrushikesh.dokala@atlan.com"}],"dist":{"shasum":"8f645928daeaa5051561465558a09a5ba2f24db0","tarball":"https://registry.npmjs.org/@atlanai/sdk/-/sdk-0.2.1.tgz","fileCount":1260,"integrity":"sha512-AqQQ71sG5lNhPC4lFnlK9jYlc/+FylQ5P66ffK+3CKP5llwsHgBHnRVa7w8Fo8tyFscbO5LNIR9lVVLbPUAhkw==","signatures":[{"sig":"MEQCIDosBkVnKNPgndRbq21Ti61BC/5cJ7fgttLs19fg0bcNAiBqGDSCEtHxwKcvpu05p5OibqFHbTf28ti7eOg8wdt1XQ==","keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U"}],"unpackedSize":4988343},"main":"./dist/index.js","type":"commonjs","_from":"file:dist/typescript/atlanai-sdk-0.2.1.tgz","types":"./dist/index.d.ts","engines":{"node":">=20"},"exports":{".":{"types":"./dist/index.d.ts","default":"./dist/index.js","require":"./dist/index.js"},"./raw/*":{"types":"./dist/raw/*/index.d.ts","default":"./dist/raw/*/index.js","require":"./dist/raw/*/index.js"},"./tracing":{"types":"./dist/tracing/index.d.ts","import":"./dist/tracing/index.js","default":"./dist/tracing/index.js"},"./manifest.json":"./dist/manifest.json","./resources.json":"./dist/resources.json"},"scripts":{"test":"npm run build && node --test test/*.cjs && npm run test:tracing","build":"tsc -p tsconfig.json && tsc -p tsconfig.tracing.json","pack:check":"npm pack --dry-run","test:tracing":"vitest run"},"_npmUser":{"name":"GitHub Actions","email":"npm-oidc-no-reply@github.com","trustedPublisher":{"id":"github","oidcConfigId":"oidc:c3f30168-af81-4a26-9348-2a4227ffec6f"}},"_resolved":"/home/runner/work/sdk/sdk/dist/typescript/atlanai-sdk-0.2.1.tgz","overrides":{"postcss":"8.5.26"},"_integrity":"sha512-AqQQ71sG5lNhPC4lFnlK9jYlc/+FylQ5P66ffK+3CKP5llwsHgBHnRVa7w8Fo8tyFscbO5LNIR9lVVLbPUAhkw==","_npmVersion":"11.10.1","description":"Atlan Agent Gateway management SDK","directories":{},"_nodeVersion":"24.4.0","dependencies":{"@opentelemetry/api":"^1.9.0","@opentelemetry/core":"^2.0.1","@opentelemetry/resources":"^2.0.1","@opentelemetry/sdk-trace-base":"^2.0.1","@opentelemetry/otlp-exporter-base":">=0.200.0 <1","@opentelemetry/exporter-trace-otlp-proto":">=0.200.0 <1"},"_hasShrinkwrap":false,"devDependencies":{"ai":"6.0.271","vitest":"^3.2.4","typescript":"5.9.3","@types/node":"^22.20.1","@langfuse/otel":"^5.11.0","@langfuse/tracing":"^5.11.0"},"_npmOperationalInternal":{"tmp":"tmp/sdk_0.2.1_1788937057924_0.9806411129013242","host":"s3://npm-registry-packages-npm-production"}},"0.2.2":{"name":"@atlanai/sdk","version":"0.2.2","license":"Apache-2.0","_id":"@atlanai/sdk@0.2.2","maintainers":[{"name":"atlan-engineering","email":"engineering@atlan.com"},{"name":"hrushikesh.dokala","email":"hrushikesh.dokala@atlan.com"}],"dist":{"shasum":"378818a244ef1fc79419928cf35cd80201074cc9","tarball":"https://registry.npmjs.org/@atlanai/sdk/-/sdk-0.2.2.tgz","fileCount":1276,"integrity":"sha512-Phf2k2IipGiF7vySBbPXIcPZd7fth7Hcc0K3ZcKxzvHRD1V2dCTazK/+bHPNJY6nzhOfyoj7ycWFtXYnkujQOQ==","signatures":[{"sig":"MEUCIQCdTZGdURjWquXIT36bmaCk0s4ElrGxsRdQdppAYRCDeAIgdcvmgd90P/CpESZD0/MiGlAabB1FAqTSs0CJivYkxIg=","keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U"}],"unpackedSize":5219119},"main":"./dist/index.js","type":"commonjs","_from":"file:dist/typescript/atlanai-sdk-0.2.2.tgz","types":"./dist/index.d.ts","engines":{"node":">=20"},"exports":{".":{"types":"./dist/index.d.ts","default":"./dist/index.js","require":"./dist/index.js"},"./raw/*":{"types":"./dist/raw/*/index.d.ts","default":"./dist/raw/*/index.js","require":"./dist/raw/*/index.js"},"./tracing":{"types":"./dist/tracing/index.d.ts","import":"./dist/tracing/index.js","default":"./dist/tracing/index.js"},"./manifest.json":"./dist/manifest.json","./resources.json":"./dist/resources.json"},"scripts":{"test":"npm run build && node --test test/*.cjs && npm run test:tracing","build":"tsc -p tsconfig.json && tsc -p tsconfig.tracing.json","pack:check":"npm pack --dry-run","test:tracing":"vitest run"},"_npmUser":{"name":"GitHub Actions","email":"npm-oidc-no-reply@github.com","trustedPublisher":{"id":"github","oidcConfigId":"oidc:c3f30168-af81-4a26-9348-2a4227ffec6f"}},"_resolved":"/home/runner/work/sdk/sdk/dist/typescript/atlanai-sdk-0.2.2.tgz","overrides":{"postcss":"8.5.26"},"_integrity":"sha512-Phf2k2IipGiF7vySBbPXIcPZd7fth7Hcc0K3ZcKxzvHRD1V2dCTazK/+bHPNJY6nzhOfyoj7ycWFtXYnkujQOQ==","_npmVersion":"11.10.1","description":"Atlan Agent Gateway management SDK","directories":{},"_nodeVersion":"24.4.0","dependencies":{"@opentelemetry/api":"^1.9.0","@opentelemetry/core":"^2.0.1","@opentelemetry/resources":"^2.0.1","@opentelemetry/sdk-trace-base":"^2.0.1","@opentelemetry/otlp-exporter-base":">=0.200.0 <1","@opentelemetry/exporter-trace-otlp-proto":">=0.200.0 <1"},"_hasShrinkwrap":false,"devDependencies":{"ai":"6.0.271","vitest":"^3.2.4","typescript":"5.9.3","@types/node":"^22.20.1","@langfuse/otel":"^5.11.0","@langfuse/tracing":"^5.11.0"},"_npmOperationalInternal":{"tmp":"tmp/sdk_0.2.2_1789482381345_0.3496653498839106","host":"s3://npm-registry-packages-npm-production"}},"0.2.3":{"name":"@atlanai/sdk","version":"0.2.3","description":"Atlan Agent Gateway management SDK","type":"commonjs","main":"./dist/index.js","types":"./dist/index.d.ts","exports":{".":{"types":"./dist/index.d.ts","require":"./dist/index.js","default":"./dist/index.js"},"./raw/*":{"types":"./dist/raw/*/index.d.ts","require":"./dist/raw/*/index.js","default":"./dist/raw/*/index.js"},"./manifest.json":"./dist/manifest.json","./resources.json":"./dist/resources.json","./tracing":{"types":"./dist/tracing/index.d.ts","import":"./dist/tracing/index.js","default":"./dist/tracing/index.js"}},"scripts":{"build":"tsc -p tsconfig.json && tsc -p tsconfig.tracing.json","test":"npm run build && node --test test/*.cjs && npm run test:tracing","pack:check":"npm pack --dry-run","test:tracing":"vitest run"},"devDependencies":{"@langfuse/otel":"^5.11.0","@langfuse/tracing":"^5.11.0","@types/node":"^22.20.1","ai":"6.0.271","typescript":"5.9.3","vitest":"^3.2.4"},"license":"Apache-2.0","engines":{"node":">=20"},"dependencies":{"@opentelemetry/api":"^1.9.0","@opentelemetry/core":"^2.0.1","@opentelemetry/exporter-trace-otlp-proto":">=0.200.0 <1","@opentelemetry/otlp-exporter-base":">=0.200.0 <1","@opentelemetry/resources":"^2.0.1","@opentelemetry/sdk-trace-base":"^2.0.1"},"overrides":{"postcss":"8.5.26"},"_id":"@atlanai/sdk@0.2.3","_integrity":"sha512-LLAmkQQqfy0oA3WweRl6EYsFcGQa66Yg9wYTyvowPhB+66vbDXpuN8zKnRCr1WQASqpDtTt99PO4hfl1qUaDvQ==","_resolved":"/home/runner/work/sdk/sdk/dist/typescript/atlanai-sdk-0.2.3.tgz","_from":"file:dist/typescript/atlanai-sdk-0.2.3.tgz","_nodeVersion":"24.4.0","_npmVersion":"11.10.1","dist":{"integrity":"sha512-LLAmkQQqfy0oA3WweRl6EYsFcGQa66Yg9wYTyvowPhB+66vbDXpuN8zKnRCr1WQASqpDtTt99PO4hfl1qUaDvQ==","shasum":"ddf0c838a464a52de697f29f5e13608ad28c68b7","tarball":"https://registry.npmjs.org/@atlanai/sdk/-/sdk-0.2.3.tgz","fileCount":1328,"unpackedSize":5488275,"signatures":[{"keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U","sig":"MEYCIQD2esY3UGKIWdG3qaVV6ZGLZJ9Ca12gRZPt9ZfNHTbRugIhAJLkH3IwflMMVBzco1kn/jFvQzh6TwpAAc1z4tahd709"}]},"_npmUser":{"name":"GitHub Actions","email":"npm-oidc-no-reply@github.com","trustedPublisher":{"id":"github","oidcConfigId":"oidc:c3f30168-af81-4a26-9348-2a4227ffec6f"}},"directories":{},"maintainers":[{"name":"atlan-engineering","email":"engineering@atlan.com"},{"name":"hrushikesh.dokala","email":"hrushikesh.dokala@atlan.com"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages-npm-production","tmp":"tmp/sdk_0.2.3_1789653328368_0.9952604787178574"},"_hasShrinkwrap":false}},"time":{"created":"2026-09-03T13:46:13.343Z","modified":"2026-09-17T13:55:28.739Z","0.1.0":"2026-09-03T13:46:13.727Z","0.1.1":"2026-09-03T17:42:45.318Z","0.2.1":"2026-09-09T06:57:38.114Z","0.2.2":"2026-09-15T14:26:21.563Z","0.2.3":"2026-09-17T13:55:28.545Z"},"license":"Apache-2.0","description":"Atlan Agent Gateway management SDK","maintainers":[{"name":"atlan-engineering","email":"engineering@atlan.com"},{"name":"hrushikesh.dokala","email":"hrushikesh.dokala@atlan.com"}],"readme":"# @atlanai/sdk\n\nTypeScript/JavaScript SDK for the Atlan Agent Gateway: manage agents, skills,\nsessions, and workspaces, and optionally trace what your agents do.\n\n## Install\n\n```bash\nnpm install @atlanai/sdk\n```\n\n## Quickstart\n\n```typescript\nimport { AtlanClient } from \"@atlanai/sdk\";\n\nconst client = new AtlanClient({\n  gatewayOrigin: \"https://<your-gateway-host>\",\n  bearerToken: \"<your-api-token>\",\n});\n\nconst agent = await client.agents.create({\n  name: \"support-triage\",\n  workspaceId: \"workspace_01example\",\n});\n\nconst page = await client.agents.list({ limit: 10 });\nconsole.log(`${page.items.length} agents`);\n```\n\nMethods read as `client.<resource>.<action>` — `client.agents.get(agentId)`,\n`client.sessions.messages.create(sessionId, {...})`, and so on. Every public\nAgent Gateway operation is reachable this way; nothing requires reaching into\na generated client directly.\n\nPass a default workspace once instead of repeating it on every call:\n\n```typescript\nconst client = new AtlanClient({ gatewayOrigin, bearerToken, workspace: \"workspace_01example\" });\n```\n\n## Run an eval\n\n`Eval()` executes the task and scorers, creates the Registry experiment, emits\none trace per case, uploads trace-linked results, and finalizes the run. Registry\nderives the durable score summary during that finalization:\n\n```typescript\nimport { Eval } from \"@atlanai/sdk\";\n\nconst result = await Eval(\"Anthropic Evaluation\", {\n  data: () => [\n    { input: \"What is 2+2?\", expected: \"4\" },\n    { input: \"What is the capital of France?\", expected: \"Paris\" },\n  ],\n  task: async (input) => callModel(input),\n  scores: [{\n    name: \"accuracy\",\n    scorer: ({ output, expected }) => output === expected ? 1 : 0,\n  }],\n});\n\nconsole.log(result.experimentId);\n```\n\nSet `ATLAN_API_KEY` and `ATLAN_WORKSPACE_ID`. Replace inline `data` with\n`dataset: \"dataset_...\"` or one exact Registry dataset name. The runner refuses\nto proceed when tracing is disabled because trace-less eval rows break the\nevidence chain. After flushing, it reads every case trace back through the\nexperiment filter before it uploads results; a missing trace marks the\nexperiment failed.\n\n## Control an eval lifecycle directly\n\nResolve an existing dataset by artifact ID or exact name, then create the\nRegistry experiment before another runner emits any traces:\n\n```typescript\nimport { createContextManifest, startExperiment } from \"@atlanai/sdk\";\nimport { propagateAttributes } from \"@atlanai/sdk/tracing\";\n\nconst contextManifest = await createContextManifest([{\n  kind: \"file\",\n  name: \"CLAUDE.md\",\n  version: \"git:0123456789abcdef0123456789abcdef01234567\",\n  digest: `sha256:${\"0\".repeat(64)}`,\n}]);\n\nconst run = await startExperiment(\n  client,\n  \"conversational-studio-daily\", // exact name, or dataset_... ID\n  { name: \"candidate-run\", config: { model: \"example-model\" } },\n  { contextManifest },\n);\n\nawait propagateAttributes(run.traceOptions, () => existingRunner());\n```\n\n`run.experiment` is the generated create response and `run.id` is its\n`experimentId`. The helper pins the resolved dataset version and context\nmanifest in the immutable experiment config. Use it when another harness owns\nexecution, result upload, and finalization.\n\n## Tracing\n\n```typescript\nimport { initLogger, wrapTraced } from \"@atlanai/sdk/tracing\";\n\nconst logger = initLogger({ projectName: \"support-agent\" });\nconst handleRequest = wrapTraced(async (input: string) => callModel(input));\n\nawait logger.traced(async (span) => {\n  const output = await handleRequest(\"hello\");\n  span.log({ input: \"hello\", output });\n}, { name: \"handle-request\", type: \"task\" });\n\nawait logger.flush();\n```\n\nTracing has its own API key and lifecycle. It does not reuse the management\nclient's transport. It ships as a separate subpath\n(`@atlanai/sdk/tracing`) so importing it doesn't pull OpenTelemetry into a\nmanagement-only bundle. npm still installs the OpenTelemetry dependencies with\nthe package because npm cannot make dependencies conditional on an imported\nsubpath; splitting tracing into a second package would trade that install size\nfor a second version and release lifecycle.\n\nVercel AI SDK v3-v6 uses its native OpenTelemetry path:\n\n```typescript\nimport * as ai from \"ai\";\nimport { initLogger, wrapAISDK } from \"@atlanai/sdk/tracing\";\n\ninitLogger({ projectName: \"support-agent\" });\nconst { generateText, streamText } = wrapAISDK(ai);\n```\n\nSee [evals and tracing](../docs/evals-and-tracing.md) for framework setup,\ncontext manifests, serverless flushing, and the tested integration matrix.\n\n## Errors\n\nEvery non-2xx response rejects with `AtlanAPIError`, with `.status`, `.code`,\nand (where the gateway includes one) `.traceId`. A failure before any response\nis also normalized as `AtlanAPIError` with `status === 0`:\n\n```typescript\nimport { AtlanAPIError } from \"@atlanai/sdk\";\n\ntry {\n  await client.agents.get(\"agent_does_not_exist\");\n} catch (error) {\n  if (error instanceof AtlanAPIError) {\n    console.log(error.status, error.code);\n  }\n}\n```\n\n## Runtimes\n\nNode ≥20. The tracing subpath is written to also run in non-Node runtimes\nlike Cloudflare Workers — pass configuration to `init()` explicitly there\nrather than relying on environment variables, since Workers has no ambient\nenvironment.\n","readmeFilename":"README.md"}