Skip to content
Latchkey

GitHub Actions composite action "Input required and not supplied" in CI

A composite or JavaScript action that reads core.getInput("x", { required: true }), or declares inputs.x.required: true, fails when the step that uses it does not supply that input under with.

What this error means

The step using the action fails with "Error: Input required and not supplied: X" before the action does its work.

GitHub Actions
Error: Input required and not supplied: token

Common causes

The step omitted a required input

The action declares inputs.token.required: true, but the with block has no token.

The input name does not match

A typo under with means the declared required input is still unfilled.

How to fix it

Supply the required input under with

  1. Read the action's action.yml for required inputs.
  2. Add each one under with in the calling step.
  3. Match names exactly.
.github/workflows/ci.yml
- uses: ./.github/actions/notify
  with:
    token: ${{ secrets.GITHUB_TOKEN }}

Provide a default in action.yml if optional

If the input is not strictly required, set required: false and a default.

action.yml
inputs:
  token:
    required: false
    default: ''

How to prevent it

  • Document required inputs in the action README.
  • Keep with keys aligned to the action's inputs.
  • Default inputs that have a sensible fallback.

Frequently asked questions

What causes ""Input required and not supplied""?
The action declares inputs.token.required: true, but the with block has no token.
How do I fix "Input required and not supplied"?
Supply the required input under with

Related guides

References

Latchkey auto-heals failures like this one - detected, fixed, and retried without you. Start free → 30-day trial · No credit card