No description
Find a file
Repository files (latest commit first)
Filename Latest commit message Latest commit date
Mrinali Rao 6a9e8179be
[TFECO-12319] API DOCS For Registry Tagging and Visibility (#2682)
This PR adds Registry Tagging and Visibility API documentation.

The epic can be found here:
https://hashicorp.atlassian.net/browse/TFECO-12314
Some of the RFCs and documents used to create this content can be found
here:

- [TF-1168: Tagging Registry Artifacts to enable Usage
Control](https://ibm.sharepoint.com/:w:/r/sites/hermes/_layouts/15/doc2.aspx?sourcedoc=%7B884C434C-B620-4400-9161-0A1B4DA95EC0%7D&file=TF-1168_-_Tagging_Registry_Artifacts_to_enable_Usage_Control.docx&action=default&or=WORD-WEB.BODY.NT&ct=1783581686830)
- [TF-2074: Bulk tag Registry Artifacts in HCP
Terraform](https://ibm.sharepoint.com/:w:/r/sites/hermes/_layouts/15/Doc.aspx?sourcedoc=%7BFE5DFEDB-33FB-43AB-9C1C-73786976197D%7D&file=TF-Bulk%20tag%20Registry%20Artifacts%20in%20HCP%20Terraform.docx&action=default&mobileredirect=true&DefaultItemOpen=1)
- [ PRD TF-242: Registry Access Control at the Project
Level](https://ibm.sharepoint.com/:w:/r/sites/hermes/_layouts/15/Doc.aspx?sourcedoc=%7B7B38164E-8D05-48C6-9B29-2EF4EC32E654%7D&file=TF-242_-_Registry_Access_Control_at_the_Project_Level.docx&action=default&mobileredirect=true&DefaultItemOpen=1
)


Please go to the `Preview` tab and select the appropriate template:
* [HCP services](?expand=1&template=hcp_pull_request_template.md)


### Terraform
* [HCP
Terraform](?expand=1&labels=hcp,terraform&title=HCP+Terraform+Docs&template=hcp_terraform_pull_request_template.md)


Jira Ticket - https://hashicorp.atlassian.net/browse/TFECO-12319


[TF-2074]:
https://hashicorp.atlassian.net/browse/TF-2074?atlOrigin=eyJpIjoiNWRkNTljNzYxNjVmNDY3MDlhMDU5Y2ZhYzA5YTRkZjUiLCJwIjoiZ2l0aHViLWNvbS1KU1cifQ
[TF-242]:
https://hashicorp.atlassian.net/browse/TF-242?atlOrigin=eyJpIjoiNWRkNTljNzYxNjVmNDY3MDlhMDU5Y2ZhYzA5YTRkZjUiLCJwIjoiZ2l0aHViLWNvbS1KU1cifQ
2026-07-21 11:33:07 +10:00
.githooks updating this comment to stress the importance so other agents don't skip over this 2026-06-02 10:12:44 -04:00
.github [WIP] Terraform Docs for TF policy (#2690) 2026-07-14 11:44:47 -05:00
.husky slight optimization 2026-05-28 17:57:00 -04:00
__fixtures__ [WIP] Terraform Docs for TF policy (#2690) 2026-07-14 11:44:47 -05:00
__mocks__ Prepare Release 2025-03-06 11:09:28 -05:00
agent-docs clearing this up 2026-07-13 12:09:48 -04:00
app Fix terraform-policy nesting (#2843) 2026-07-15 13:10:29 -04:00
content [TFECO-12319] API DOCS For Registry Tagging and Visibility (#2682) 2026-07-21 11:33:07 +10:00
deprecated Remove TF ent HVS pages 2026-07-07 11:57:36 -04:00
docs splitting up agents md file and moving picture references accordingly- havent read through the changes yet 2026-07-02 15:33:59 -04:00
public Replace the missing robots.txt file 2026-06-15 14:03:25 -07:00
scripts Fix release stage not working with algolia sync (#2869) 2026-07-17 10:34:42 -04:00
.copywrite.hcl adding githooks to the ignore list like husky 2026-05-28 17:52:38 -04:00
.dockerignore Prepare Release 2025-03-06 11:09:28 -05:00
.env Enable Incremental Builds Beta Test (#1912) 2026-03-16 14:07:02 +00:00
.gitignore cleaning up to use api route to serve mdx content and remove llms.txt references 2026-07-01 16:07:22 -05:00
.go-version Release of Enforced provisioner docs (#2242) 2026-04-24 12:21:29 +00:00
.npmrc Add minimum NPM package release age (#2227) 2026-04-16 09:34:31 -04:00
.nvmrc chore: upgrade to node 24 (#2092) 2026-03-31 11:08:04 -05:00
.prettierignore Prepare Release 2025-03-06 11:09:28 -05:00
.ruby-version Fix Terraform Enterprise workflow (#260) 2025-07-03 14:05:17 -04:00
AGENTS.md making the maintainence guide more explicit 2026-07-13 11:49:54 -04:00
CODEOWNERS Add team-devrel-infrastructure-education to codeowners (#2822) 2026-07-16 10:28:58 -04:00
CONTRIBUTING.md feat: add date metadata script (#1601) 2026-01-28 13:04:40 -06:00
docker-compose.yaml fix: update copyright-headers (#1721) 2026-01-28 11:47:46 -06:00
Dockerfile chore: upgrade to node 24 (#2092) 2026-03-31 11:08:04 -05:00
eslint.config.mjs fix: update copyright-headers (#1721) 2026-01-28 11:47:46 -06:00
Gemfile Remove asana gem 2025-06-16 09:18:23 +08:00
Gemfile.lock Remove asana gem 2025-06-16 09:18:23 +08:00
LICENSE Update LICENSE 2026-03-11 12:18:03 +05:30
makefile Prepare for packer release 1.15.1 (#1999) 2026-03-26 19:29:03 +05:30
next.config.js cleaning up to use api route to serve mdx content and remove llms.txt references 2026-07-01 16:07:22 -05:00
package-lock.json fix: address security tickets (#2587) 2026-06-08 11:51:03 -05:00
package.json fix: address security tickets (#2587) 2026-06-08 11:51:03 -05:00
prettier.config.js fix: update copyright-headers (#1721) 2026-01-28 11:47:46 -06:00
productConfig.mjs Fix terraform-policy nesting (#2843) 2026-07-15 13:10:29 -04:00
proxy.js Update to next.js 16 (#2568) 2026-06-04 14:17:35 -04:00
README.md Replace named links with explicit links 2026-06-09 10:47:54 -07:00
tsconfig.json fix: address security tickets (#2587) 2026-06-08 11:51:03 -05:00
vitest.config.mjs fix: update copyright-headers (#1721) 2026-01-28 11:47:46 -06:00

Web Unified Docs

Important

This README is for developers working on the documentation website. If you want to contribute docs content, refer to the Contribute to HashiCorp documentation guide.


The project in this repository, hashicorp/web-unified-docs, aims to implement DEVDOT-023: Unified Product Documentation Repository. The RFC for this project was intentionally light on implementation details, in order to foster consensus on the broad direction.

  • PR previews: Show broken links in comments for awareness (informational only, don't block PRs)
  • Production monitoring: Weekly scans create GitHub issues and send critical alerts to Datadog when users are affected

The weekly broken-link-check-full workflow generates comprehensive broken link reports with prioritization guidance. When contributors create PRs that modify content, the link checker shows any broken links in PR comments with actionable guidance without blocking development.

Quick tips for contributors:

  • Fix internal HashiCorp links (high priority)
  • Check external docs/API links (medium priority)
  • Consider removing unreliable external links (low priority)

For detailed information about the monitoring system, see Broken Link Monitoring Documentation. The EDU-053: Unified Education Style Guide for this project was intentionally light on implementation details, in order to foster consensus on the broad direction.

The existing API (content.hashicorp.com) has endpoints that serve documentation content. You can find the source code in hashicorp/mktg-content-workflows.

The goal of the unified docs API is to host all of HashiCorp's product documentation. The unified docs API will eventually replace the existing content API.

Local development

Requirements

Quick start

To get a migration preview running, run make from the root of this repo. The make command starts the unified-docs Docker profile that spins up a local instance of unified-devdot-api and dev-portal.

Once this command completes, you can access the following endpoints:

  • http://localhost:3000 - An instance of the dev-portal container configured to pull from the experimental docs API (this repo). This image depends on the unified docs API (unified-devdot-api).

  • http://localhost:8080 - An instance of the unified docs API container (this repo - unified-devdot-api) that serves content from the content directory. On startup, this container processes the content and assets in /content into public/assets and public/content. In addition, the container also generates app/api/docsPaths.json and app/api/versionMetadata.json from the contents within /content.

    Use the following example to test this endpoint: http://localhost:8080/api/content/terraform-plugin-framework/doc/latest/plugin/framework

Note

The unified docs API container takes time to process the content and assets. You must wait for both the unified-devdot-api and dev-portal containers to complete before you can successfully test content in the dev-portal preview environment (localhost:3000). Visit http://localhost:8080/api/all-docs-paths to verify the unified-devdot-api container is complete.

To spin this down gracefully, run make clean in a separate terminal.

If you wish to remove the local Docker images as well, run make clean CLEAN_OPTION=full.

More commands

The makefile serves as a convenience tool start the local preview. If you need more granular control, the package.json file contains a full list of available commands.

To use these, you will need to intentionally run npm install and npm run prebuild before anything else.

Use npm run coverage to run coverage tests.

Preview environments for unified-docs and dev-portal

Unified docs API serves as one of the content APIs for dev-portal (frontend application for DevDot). As a result, when implementing new features, you may need to modify both the backend (this repo) and the frontend (dev-portal).

If you are working on a ticket that requires changes to both the unified docs API and dev-portal, please set custom environment variables for your branch in Vercel to simplify testing instructions.

For example, in Vercel, for your dev-portal branch, you can set the following environment variables:

Environment variable Value
HASHI_ENV unified-docs-sandbox
UNIFIED_DOCS_API <UDR-Preview-URL>

Vercel will use these values to create deploy previews.

API development

Reach out to team #team-web-presence if you need to do local API development

Background

Project Rationale

  • Storing documentation in one branch of one repo dramatically simplifies the workflow for contributing documentation.
  • Publishing changes to multiple versions can be done in a single PR, as opposed to multiple PRs which is required by the current setup.
  • Finding and making the same change across multiple versions is as simple as doing a find-and-replace since all the versioned docs are on the filesystem at the same time.
  • Adding a new product is as easy as making a new folder, as opposed to the current process which requires code-changes on the API side and the installation of a GitHub App to monitor for events.
  • Sourcing from one branch in one repo eliminates the situation where a missed GitHub event can result in out-of-date documentation. If something goes wrong in the publishing process, simply run it again instead of relying on incoming commit/release events from the GitHub API.
  • Since we can make edits to all docs for all products and versions from a single PR, making platform-level changes is dramatically simplified (such as updating to MDX v2, or rewriting URLs).
  • Adding new features like content conformance (basically linting for docs) can be done for the entire codebase at once.
  • Removes the ability for docs to break the release workflow in product repos.
  • Enables us to support fully versioned deployment previews, whereas current previews are limited to the branch being modified.

Architectural Decision Records

Update product repo documentation

This script helps with product documentation migration to the web-unified-docs repository. When migrating documentation:

  1. The web-unified-docs repository becomes the source of truth
  2. Original documentation may remain temporarily as a fallback
  3. Users should be directed to make future changes in web-unified-docs only

This script automatically adds a prominent notice to all MDX files in the original location, informing contributors where to make future changes.

./scripts/update-mdx-files.sh ~/Desktop/hashicorp/terraform-plugin-framework/website/docs

Example output:

Progress:

Files processed: 135
Files updated: 135
Files with no frontmatter: 0
Files with errors: 0

Completed! All MDX files have been processed.

The repository uses a focused broken link monitoring system:

  • PR previews: Show broken links in comments for awareness (informational only, don't block PRs)
  • Production monitoring: Weekly scans create GitHub issues and Datadog alerts for user-facing problems

The weekly broken-link-check-full workflow generates comprehensive broken link reports. When contributors create PRs that modify content, the link checker shows any broken links in PR comments without blocking development.

For detailed information about the monitoring system, see Broken Link Monitoring Documentation.

For teams migrating products to UDR (Unified Docs Renderer), use the dedicated migration workflow:

  1. Go to Actions → UDR Product Link Check
  2. Click "Run workflow" and select your product
  3. Review migration-specific broken link analysis in the generated GitHub issue

This workflow provides targeted link checking with migration-focused reporting and prioritization.

Local Testing

You can also run the broken link checker locally. The following commands launch a lychee Docker container to check the content directories you specify.

Run the broken link checker on all content.

npm run broken-link

Check a specific directory within content.

npm run broken-link terraform-plugin-framework

Check multiple directories.

npm run broken-link terraform-plugin-framework-log terraform-plugin-mux

Architecture

The following diagram illustrates the relationships between the unified docs API (this repo), dev-portal, and the existing content API:

graph LR
    subgraph "Content sources (non-migrated)"
        BDY[boundary]
        CSL[consul]
        HCP[hcp-docs]
        NMD[nomad]
        PKR[packer]
        SNT[sentinel]
        TF[terraform]
        TFC[terraform-cdk]
        TFA[terraform-docs-agents]
        TFD[terraform-docs-common]
        VGT[vagrant]
        VLT[vault]
        WPT[waypoint]

        CURALL["/content or /website"]
        BDY & CSL & HCP & NMD & PKR & SNT & TF & TFC & TFA & TFD & VGT & VLT & WPT --> CURALL
    end

    subgraph "Migrated content repo"
        TPF[terraform-plugin-framework]
        TPL[terraform-plugin-log]
        TPM[terraform-plugin-mux]
        TPS[terraform-plugin-sdk]
        TPT[terraform-plugin-testing]
        TFE[terraform-enterprise]

        MIGALL["/content"]
        TPF & TPL & TPM & TPS & TPT & TFE --> MIGALL
    end

    subgraph "APIs"
        CP[Content API<br>content.hashicorp.com]
        UDR[Unified Docs Repository<br>web-unified-docs]
    end

    subgraph "Frontend"
        DP[Dev Portal<br>dev-portal]
    end

    %% BDY & CSL & HCP & NMD & PKR & PTF & SNT & TF & TFC & TFA & TFD & VGT & VLT & WPT --> CP
    %% TPF & TPL & TPM & TPS & TPT --> UDR

    CURALL -->|Current content flow| CP
    MIGALL -->|Migrated content| UDR

    CP -->|Serves most content| DP
    UDR -->|Serves unified/content content| DP

    class TPF,TPL,TPM,TPS,TPT,BDY,CSL,HCP,NMD,PKR,PTF,SNT,TF,TFC,TFA,TFD,VGT,VLT,WPT productRepo

The diagram shows:

  • The content API — the existing system that sources product documentation content from product repositories
  • The unified docs API — the new system that sources product documentation from this repo's /content directory. The migrated repos will use a directory approach to versioning (rather than the historic branch and tag strategy)
  • The Dev Portal — the frontend that serves the main DevDot interface. Dev Portal sources its content from both the existing content API and unified docs API.