[@vercel/aws] introduce package with createOpenSearch()#16443
Conversation
Adds the `@vercel/aws` package with a `createOpenSearch()` factory that
wires up an `@opensearch-project/opensearch` client using the env vars
Vercel injects for a Marketplace OpenSearch Serverless resource
(`OPENSEARCH_DASHBOARD_ENDPOINT`, `OPENSEARCH_REGION`, `AWS_ROLE_ARN`).
Credentials are resolved via Vercel OIDC + AssumeRoleWithWebIdentity,
so customers can go from ~10 lines of AWS SDK setup to two:
import { createOpenSearch } from '@vercel/aws';
const os = createOpenSearch();
Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
🦋 Changeset detectedLatest commit: bb2988d The changes in this PR will be included in the next version bump. This PR includes changesets to release 1 package
Not sure what this means? Click here to learn what changesets are. Click here if you're a maintainer who wants to add another changeset to this PR |
🧪 Unit Test StrategyComparing: Strategy: Code changed outside of a package - running all unit tests Affected packages - 45 (100%)
Results
This comment is automatically generated based on the affected testing strategy |
|
Review the following changes in direct dependencies. Learn more about Socket for GitHub.
|
The initial commit pinned typedoc 0.24.6 + typedoc-plugin-markdown 4.1.2
+ typedoc-plugin-mdn-links 3.2.3, which forced a duplicate older typedoc
resolution into the lockfile. pnpm's peer-dep hoisting then wired the
typedoc 0.28.19 binary to the 4.1.2 plugin in @vercel/firewall (and
others), breaking `pnpm run build` across CI ("modules.map is not a
function" inside typedoc).
Bumps to typedoc 0.28.19 / plugin-markdown 4.11.0 / plugin-mdn-links
5.1.1 — matching every other docs-building package — and adds prettier
3.8.3 so `build:docs` resolves consistently. Also drops a `{@link
ClientOptions}` from the CreateOpenSearchOptions doc comment that
typedoc couldn't resolve and commits the generated docs/ tree, matching
the convention used by sibling packages.
Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
📦 CLI Tarball ReadyThe Vercel CLI tarball for this PR is now available! Quick TestYou can test this PR's CLI directly by running: npx https://vercel-pc2lmshwq.vercel.sh/tarballs/vercel.tgz --helpUse in vercel.jsonTo use this CLI version in your project builds, add to your {
"build": {
"env": {
"VERCEL_CLI_VERSION": "vercel@https://vercel-pc2lmshwq.vercel.sh/tarballs/vercel.tgz"
}
}
}Python Runtime WheelA Python Workers WheelA This comment is automatically generated |
Why
customers go from this:
to this:
Summary
@vercel/aws@0.1.0atpackages/aws/.createOpenSearch(opts?). Defaultsendpoint,region,roleArntoOPENSEARCH_DASHBOARD_ENDPOINT/OPENSEARCH_REGION/AWS_ROLE_ARN(the env vars Vercel injects when a Marketplace OpenSearch resource is connected). Explicit options override env. Helpful error names the specific missing var(s).@vercel/oidc-aws-credentials-provider(existing workspace package) → STSAssumeRoleWithWebIdentity.@opensearch-project/opensearchis a peer dependency (optional) so consumers pin their own version.Validation
pnpm --filter @vercel/aws build:codeclean (tsc + esbuild).pnpm --filter @vercel/aws exec vitest run— 4/4 pass: env defaults applied, explicit overrides, full-missing error message, partial-missing names only the missing var.pnpm biome check packages/aws/src packages/aws/package.jsonclean.