Skip to content
This repository has been archived by the owner on Jan 16, 2022. It is now read-only.

Latest commit

 

History

History
42 lines (28 loc) · 1.05 KB

using.md

File metadata and controls

42 lines (28 loc) · 1.05 KB

jsondecode Provider

The Terraform jsondecode provider decodes a JSON string.

It provides a stopgap until this is supported in the Terraform configuration language; See hashicorp/terraform#10363.

This provider requires no configuration.

Example Usage

provider "jsondecode" {}

data "jsondecode_decode" "foo" {
  input =<<EOS
{
  "name": "Seattle",
  "state": "WA"
}
EOS
}

Data Sources

jsondecode_decode

Argument Reference

The following arguments are supported:

  • input - (Required, string) The JSON string that is to be decoded. The subset of JSON that can be decoded is limited - boolean, number, string, object with string values and array of strings.

Attributes Reference

The following attributes are exported in addition to the above configuration:

  • boolean - (boolean) Boolean
  • number - (float) Number
  • string - (string) String
  • object - (map) Object with string values
  • string_array - (list) Array of strings