HCP Terraform + Memtro

Ask why a Terraform run failed, who applied last and which workspaces are locked.

Connect HCP Terraform with an API token and Memtro reads projects, workspaces with Terraform version, lock and resource count, runs, run comments, and the names of each workspace's variables. Variable values and state are never read. It reads on demand, with no hourly sync. When you ask, and once an administrator has granted the action by name, it can comment on runs, queue a plan, apply a confirmed run, which changes real infrastructure and may spend cloud money, discard or cancel runs, and lock a workspace or lift its lock. An applied run is undone only by another run.

In Memtro

What you can do with HCP Terraform in Memtro

Ask in plain English from chat, your editor, a scheduled job or your own agent. The model picks the right HCP Terraform tool, reads what it needs, and answers with the source cited.

What it does

  1. 01Workspaces by name, tag, project or run status, with version, lock, resource count and VCS repo
  2. 02Runs newest first with status, message, trigger, whether they change or destroy, and timing
  3. 03One run in full: every status timestamp and the comments left on it
  4. 04Variable names with category and whether sensitive, never their values or state
  5. 05When asked and granted, queues a run or a plan-only run, and applies a run waiting for confirmation, which changes real infrastructure, may spend cloud money and notifies the workspace's run subscribers
  6. 06When asked and granted, discards or cancels a run, locks a workspace or lifts its lock, and adds a run comment that cannot be edited or deleted through the API

Acts when asked

When you ask it to

These tools change something in HCP Terraform. The model is told to use them only when you ask for exactly that, and an administrator grants each one by name to the teams that may use it; a personal connection acts only after its owner allows it.

  1. 01Add a comment to a Terraform run
  2. 02Queue a Terraform run (a plan, and an apply unless plan-only) on a workspace
  3. 03Apply a Terraform run waiting for confirmation
  4. 04Discard a Terraform run waiting for confirmation
  5. 05Cancel a Terraform run that is planning or applying
  6. 06Lock a Terraform workspace
  7. 07Unlock a Terraform workspace

Events

When it happens

Turn events on in the connection's Events tab on the Connections page, then add the address it shows as a webhook in HCP Terraform, choosing the same kinds; the tab shows HCP Terraform's own steps. Each event can start a job, with the event as its input. HCP Terraform signs every delivery, and one whose signature does not check out is refused before it is read.

Events and webhooks
  • 01Run created
  • 02Run planning
  • 03Run needs attention (approval or policy override)
  • 04Run waiting for apply approval
  • 05Run cost estimated
  • 06Run needs a policy override
  • 07Run policies checked
  • 08Run applying
  • 09Run completed
  • 10Run errored (any early end)
  • 11Run terminated by an error
  • 12Run canceled
  • 13Run failed a soft-mandatory policy
  • 14Drift detected
  • 15Continuous validation checks failed
  • 16Health assessment failed
  • 17Auto-destroy run is imminent
  • 18Auto-destroy run attempted
  • 19Workspace deleted
In practice

Ask it like you would a colleague

Once HCP Terraform is connected, these are the kinds of things people ask. Plain questions, no syntax. If the answer lives partly in another system you have connected, Memtro looks there too.

HCP Terraform + Memtro
  • Why did the last run on the networking workspace error?

  • Who applied last on production, and when?

  • Which workspaces are locked right now?

  • Is AWS_REGION set on the billing workspace?

  • Apply the pending run on the Northwind database workspace

01

Why did it fail

Dan Fletcher asks why this morning's plan on Acme's production workspace errored. Memtro finds the run with its message, trigger and status timestamps, shows it failed at the policy check, and lists the comment Priya Nair left on the previous run.

02

Applying after approval

After the change meeting the platform lead, Sam Okafor, asks Memtro to apply the Northwind database run. Memtro reads the plan, confirms it adds one replica and destroys nothing, then applies it and comments the approval on the run. HCP Terraform notifies the workspace's run subscribers.

Teams

Where it fits

The teams that lean on HCP Terraform most, a question each of them asks, and what they connect beside it.

Better together

Works with

A record in HCP Terraform is rarely the whole story. Connect the systems that hold the rest and Memtro checks them together, then remembers what it learned so the next question starts further along.

Also in Engineering and operations

Using something else for the same job, or both? Each connector has its own tools; connect as many as you like.

Setup

How to connect

Connect withAPI token
  1. 1

    In app.terraform.io open Account settings → Tokens and create an API token. Copy it: it is shown once

  2. 2

    A user token acts as you and sees every organisation you are in. An organisation token sees one organisation and cannot queue, apply, discard or cancel runs: use a user or team token for those

  3. 3

    In Memtro open Connections → HCP Terraform, paste the API token, add the Organisation name from its URLs if the token sees more than one, and set a host only for self-hosted Terraform Enterprise

  4. 4

    Ask why the last run on your production workspace failed

Also works from

Chat in the dashboard, the OpenAI-compatible API, scheduled jobs, and any MCP client: Claude Code, OpenCode, Cursor, Claude Desktop. The HCP Terraform tools are the same everywhere.

FAQ

Questions

Can Memtro change anything in HCP Terraform?+

Only when you ask, and only what it has been granted: add a comment to a Terraform run; queue a Terraform run (a plan, and an apply unless plan-only) on a workspace; apply a Terraform run waiting for confirmation; discard a Terraform run waiting for confirmation; cancel a Terraform run that is planning or applying; lock a Terraform workspace; unlock a Terraform workspace. Every other tool reads, searches or lists. The Connections page labels the tools that act, an administrator grants each one by name to the teams that may use it, and a personal connection acts only after its owner allows it.

Who can use a HCP Terraform connection?+

A personal connection serves only your own requests. A shared connection serves the organisation: everyone, or only the teams an admin chooses. Admins can always add shared connections; other members need the permission.

Does Memtro store my HCP Terraform data?+

Credentials are encrypted at rest. Tool results are cached briefly so agent loops do not repeat identical calls, and the facts the model extracts are saved to your organisation's memory with provenance (system, record and link) so they can be checked and superseded.

How do I connect HCP Terraform?+

API token. In app.terraform.io open Account settings → Tokens and create an API token. Copy it: it is shown once.

Can HCP Terraform start a job?+

Yes. Turn events on in the connection's Events tab on the Connections page, then add the address it shows as a webhook in HCP Terraform, choosing the same kinds; the tab shows HCP Terraform's own steps. A job set to start "When an event arrives" then runs once for each matching event, with the event as its input. The run treats the event as outside data, never as instructions, and anything the run remembers is kept as unverified.

Connect HCP Terraform in a few minutes

Seven-day free trial, then one monthly price per organisation. Connectors, jobs and memory are never metered.

Where agents remember your company

Sign in, add a provider key, create an API key and point your tools at Memtro. It takes about five minutes.

7-day free trial · card on file, nothing charged until it ends · cancel any time