---
title: "AWS OIDC Pulumi program in TypeScript"
description: "AWS OIDC setup for Pulumi ESC"
url: "https://www.pulumi.com/dev/examples/aws-ts-oidc-provider-pulumi-cloud/"
image: "https://www.pulumi.com/assets/og/dev/examples/aws-ts-oidc-provider-pulumi-cloud.png"
---

# AWS OIDC Pulumi program in TypeScript

AWS OIDC setup for Pulumi ESC

- Source on GitHub: https://github.com/pulumi/examples/tree/master/aws-ts-oidc-provider-pulumi-cloud
- Deploy with Pulumi: https://app.pulumi.com/new?template=https%3A%2F%2Fgithub.com%2Fpulumi%2Fexamples%2Ftree%2Fmaster%2Faws-ts-oidc-provider-pulumi-cloud

## Get started with this example

This example lives in the [pulumi/examples](https://github.com/pulumi/examples/tree/master/aws-ts-oidc-provider-pulumi-cloud) repo. Pull down just this directory to follow along:

```bash
git clone --filter=blob:none --sparse https://github.com/pulumi/examples pulumi-examples
git -C pulumi-examples sparse-checkout set aws-ts-oidc-provider-pulumi-cloud
cd pulumi-examples/aws-ts-oidc-provider-pulumi-cloud
```

A Pulumi template to:

- Create AWS resources for AWS OIDC (IdP + Role)
- Create a new Pulumi Cloud ESC Environment

Last update: September 2025

## 📋 Pre-requisites

- AWS CLI and an AWS Account configured
- [Pulumi CLI](https://www.pulumi.com/docs/get-started/install/)
- [Pulumi Cloud account](https://app.pulumi.com/signup)
- [npm](https://www.npmjs.com/get-npm)

## 👩‍🏫 Get started

This Pulumi example is written as a template. It is meant to be copied via `pulumi new`

```bash
# login to your Pulumi Cloud if you haven't already
pulumi login

# pick a name for your output directory (--dir is optional. will use current directory if omitted)
my_dir=my-aws-oidc
pulumi new https://github.com/pulumi/examples/aws-ts-oidc-provider-pulumi-cloud --dir ${my_dir}
cd ${my_dir}
```

Once copied to your machine, feel free to edit as needed.

## 🎬 How to run

This template will pick up the thumbprint from the URL that you set in the stack configuration. By default it will use the OIDC IDP URL for Pulumi Cloud.

To deploy your infrastructure, run:

```bash
$ pulumi up
# select 'yes' to confirm the expected changes
# 🎉 Ta-Da!
```

## 🧹 Clean up

To clean up your infrastructure, run:

```bash
$ pulumi destroy
# select 'yes' to confirm the expected changes
```
