Deployments
Vercel
Read Bulgur secrets inside Vercel Functions with OIDC, or use a separate sync integration.
Choose runtime OIDC or sync
Vercel OIDC reads selected values from Bulgur at request time. It does not copy them into Vercel. The separate Vercel sync integration copies values to Vercel's environment settings instead; choose it when the application needs platform-managed variables at build or startup.
Configure Vercel OIDC
Enable OIDC for the Vercel project. In Bulgur Settings, an owner or admin creates a Vercel workload identity bound to one concrete Bulgur environment. Match Vercel's stable owner_id (team_…), project_id (prj_…), and exactly preview or production. Development and custom Vercel environments are not supported by this policy.
Select team issuer mode with the exact team slug, or global issuer mode without a team slug. The SDK requests the fixed https://api.bulgur.dev audience; the identity does not accept an audience override. Configure separate identities and Bulgur targets for Preview and Production.
| Vercel claim | Bulgur policy field |
|---|---|
| owner_id | vercelOwnerId (stable team ID) |
| project_id | vercelProjectId (stable project ID) |
| environment | vercelEnvironment: preview or production |
| issuer | vercelIssuerMode and, for team mode, vercelTeamSlug |
Load per request
Use Node.js 20 or newer with bulgur@^1.3.0 and the optional @vercel/oidc helper. Put the identity UUID in the Vercel Function environment, then call loadValues inside each request handler. It returns a request-local object and does not change process.env.
npm install bulgur@^1.3.0 @vercel/oidc@^4.0.7import { loadValues } from "bulgur";
export async function GET() {
const values = await loadValues({
auth: "vercel-oidc",
identityId: process.env.BULGUR_IDENTITY_ID,
});
return Response.json({ connected: Boolean(values.DATABASE_URL) });
}Keep returned values on the server. Do not put secrets into NEXT_PUBLIC_ variables or a browser bundle. Explicit OIDC failures do not fall back to token credentials.