Skip to content

Commit

Permalink
flow entry must work with core flows and all primitive types (#121)
Browse files Browse the repository at this point in the history
  • Loading branch information
yurymikhailenko authored May 31, 2021
1 parent 2585be5 commit 0f1bf99
Show file tree
Hide file tree
Showing 57 changed files with 499 additions and 272 deletions.
12 changes: 6 additions & 6 deletions GNUmakefile
Original file line number Diff line number Diff line change
Expand Up @@ -69,14 +69,14 @@ clean:
.PHONY: testacc
testacc:
(\
set -o allexport && [[ -f .env ]] && source ./.env && set +o allexport && \
set -o allexport && [[ -f .env ]] && source .env && set +o allexport || true ; \
TF_ACC=1 go test ./... -v $(TESTARGS) -timeout 120m \
)

.PHONY: example
example: install
(\
set -o allexport && [[ -f .env ]] && source ./.env && set +o allexport && \
set -o allexport && [[ -f .env ]] && source .env && set +o allexport || true ; \
pushd $(EXAMPLE) && \
(rm .terraform.lock.hcl || true) && \
terraform init && \
Expand All @@ -87,7 +87,7 @@ example: install
.PHONY: example
resource: install
(\
set -o allexport && [[ -f .env ]] && source ./.env && set +o allexport && \
set -o allexport && [[ -f .env ]] && source .env && set +o allexport || true ; \
pushd examples/resources/$(TYPE)_resource && \
(rm .terraform.lock.hcl || true) && \
terraform init && \
Expand All @@ -98,7 +98,7 @@ resource: install
.PHONY: example
data-source: install
(\
set -o allexport && [[ -f .env ]] && source ./.env && set +o allexport && \
set -o allexport && [[ -f .env ]] && source .env && set +o allexport || true ; \
pushd examples/data-sources/$(TYPE)_data_source && \
(rm .terraform.lock.hcl || true) && \
terraform init && \
Expand All @@ -110,11 +110,11 @@ data-source: install
.PHONY: docs
docs: install
(\
set -o allexport && [[ -f .env ]] && source .env && set +o allexport && \
set -o allexport && [[ -f .env ]] && source .env && set +o allexport || true ; \
(rm .terraform.lock.hcl || true) && \
terraform init && \
go generate \
)

prepare:
( terraform fmt -recursive && go fmt ./... && go generate)
( terraform fmt -recursive && go fmt ./... && go generate)
16 changes: 0 additions & 16 deletions docs/data-sources/customer_authentication_settings.md

This file was deleted.

Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
---
page_title: "epcc_account Data Source - terraform-provider-epcc"
page_title: "epcc_account Data Source - epcc-terraform-provider"
subcategory: ""
description: |-
Represents the EPCC API Account resource https://documentation.elasticpath.com/commerce-cloud/docs/api/account-management/accounts/index.html#the-account-object.
Expand Down
Original file line number Diff line number Diff line change
@@ -1,16 +1,25 @@
---
page_title: "epcc_account_authentication_settings Data Source - terraform-provider-epcc"
page_title: "epcc_account_authentication_settings Data Source - epcc-terraform-provider"
subcategory: ""
description: |- Represents the EPCC API Account Authentication Settings
description: |-
Represents the EPCC API Account Authentication Settings https://documentation.elasticpath.com/commerce-cloud/docs/api/advanced/settings/account-authentication-settings/index.html
---

# Data Source `epcc_account_authentication_settings`

Represents the EPCC API [Account Authentication Settings] (https://documentation.elasticpath.com/commerce-cloud/docs/api/advanced/settings/account-authentication-settings/index.html)



## Schema

### Optional

- **id** (String) The ID of this resource.

### Read-only

- **client_id** (String)
- **realm_id** (String)
- **client_id** (String)


Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
---
page_title: "epcc_catalog Data Source - terraform-provider-epcc"
page_title: "epcc_catalog Data Source - epcc-terraform-provider"
subcategory: ""
description: |-
Represents the EPCC API PCM Catalog Object https://documentation.elasticpath.com/commerce-cloud/docs/api/pcm/catalogs/index.html#the-catalog-object.
Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
---
page_title: "epcc_catalog_rule Data Source - terraform-provider-epcc"
page_title: "epcc_catalog_rule Data Source - epcc-terraform-provider"
subcategory: ""
description: |-
Represents the EPCC API PCM Catalog Rule Object https://documentation.elasticpath.com/commerce-cloud/docs/api/pcm/catalogs/rules/get-a-catalog-rule.html.
Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
---
page_title: "epcc_currency Data Source - terraform-provider-epcc"
page_title: "epcc_currency Data Source - epcc-terraform-provider"
subcategory: ""
description: |-
Represents the EPCC API Currency Object https://documentation.elasticpath.com/commerce-cloud/docs/api/advanced/currencies/index.html#the-currency-object.
Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
---
page_title: "epcc_customer Data Source - terraform-provider-epcc"
page_title: "epcc_customer Data Source - epcc-terraform-provider"
subcategory: ""
description: |-
Represents the EPCC API Customer Object https://documentation.elasticpath.com/commerce-cloud/docs/api/orders-and-customers/customers/index.html#the-customer-object.
Expand Down
25 changes: 25 additions & 0 deletions docs/data-sources/epcc_customer_authentication_settings.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,25 @@
---
page_title: "epcc_customer_authentication_settings Data Source - epcc-terraform-provider"
subcategory: ""
description: |-
Represents the EPCC API Customer Authentication Settings https://documentation.elasticpath.com/commerce-cloud/docs/api/advanced/settings/customer-authentication-settings/index.html
---

# Data Source `epcc_customer_authentication_settings`

Represents the EPCC API [Customer Authentication Settings] (https://documentation.elasticpath.com/commerce-cloud/docs/api/advanced/settings/customer-authentication-settings/index.html)



## Schema

### Optional

- **id** (String) The ID of this resource.

### Read-only

- **client_id** (String)
- **realm_id** (String)


Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
---
page_title: "epcc_entry Data Source - terraform-provider-epcc"
page_title: "epcc_entry Data Source - epcc-terraform-provider"
subcategory: ""
description: |-
Represents the EPCC API Entry Object https://documentation.elasticpath.com/commerce-cloud/docs/api/advanced/custom-data/entries/index.html.
Expand All @@ -16,10 +16,12 @@ Represents the EPCC API [Entry Object](https://documentation.elasticpath.com/com
### Required

- **id** (String) The ID of this resource.
- **payload** (Map of String)
- **slug** (String)

### Read-only

- **slug** (String)
- **booleans** (Map of Boolean)
- **numbers** (Map of Number)
- **strings** (Map of String)


Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
---
page_title: "epcc_field Data Source - terraform-provider-epcc"
page_title: "epcc_field Data Source - epcc-terraform-provider"
subcategory: ""
description: |-
Represents the EPCC API Fields Object https://documentation.elasticpath.com/commerce-cloud/docs/api/advanced/custom-data/fields/index.html.
Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
---
page_title: "epcc_file Data Source - terraform-provider-epcc"
page_title: "epcc_file Data Source - epcc-terraform-provider"
subcategory: ""
description: |-
Represents the EPCC API File Object https://documentation.elasticpath.com/commerce-cloud/docs/api/advanced/files/index.html#the-file-object.
Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
---
page_title: "epcc_flow Data Source - terraform-provider-epcc"
page_title: "epcc_flow Data Source - epcc-terraform-provider"
subcategory: ""
description: |-
Represents the EPCC API Flow Object https://documentation.elasticpath.com/commerce-cloud/docs/api/advanced/custom-data/flows/index.html#the-flow-object.
Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
---
page_title: "epcc_hierarchy Data Source - terraform-provider-epcc"
page_title: "epcc_hierarchy Data Source - epcc-terraform-provider"
subcategory: ""
description: |-
Represents the EPCC API Hierarchy Object https://documentation.elasticpath.com/commerce-cloud/docs/api/pcm/hierarchies/index.html#the-hierarchy-object.
Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
---
page_title: "epcc_integration Data Source - terraform-provider-epcc"
page_title: "epcc_integration Data Source - epcc-terraform-provider"
subcategory: ""
description: |-
Allows to configure webhooks
Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
---
page_title: "epcc_node Data Source - terraform-provider-epcc"
page_title: "epcc_node Data Source - epcc-terraform-provider"
subcategory: ""
description: |-
Represents the EPCC API Node Object https://documentation.elasticpath.com/commerce-cloud/docs/api/pcm/hierarchies/index.html#the-node-object.
Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
---
page_title: "epcc_node_product Data Source - terraform-provider-epcc"
page_title: "epcc_node_product Data Source - epcc-terraform-provider"
subcategory: ""
description: |-
Represents the EPCC API Node and Product Relationship https://documentation.elasticpath.com/commerce-cloud/docs/api/pcm/hierarchies/relationships/create-node-product-relationships.html.
Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
---
page_title: "epcc_payment_gateway Data Source - terraform-provider-epcc"
page_title: "epcc_payment_gateway Data Source - epcc-terraform-provider"
subcategory: ""
description: |-
Payment gateway connectivity configuration
Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
---
page_title: "epcc_pricebook Data Source - terraform-provider-epcc"
page_title: "epcc_pricebook Data Source - epcc-terraform-provider"
subcategory: ""
description: |-
Represents the EPCC API PriceBook Object https://documentation.elasticpath.com/commerce-cloud/docs/api/pcm/pricebooks/index.html#the-pricebook-object.
Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
---
page_title: "epcc_product Data Source - terraform-provider-epcc"
page_title: "epcc_product Data Source - epcc-terraform-provider"
subcategory: ""
description: |-
Allows the caller to look up details of an Elastic Path Commerce Cloud PCM product https://documentation.elasticpath.com/commerce-cloud/docs/concepts/products-pcm.html.
Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
---
page_title: "epcc_product_price Data Source - terraform-provider-epcc"
page_title: "epcc_product_price Data Source - epcc-terraform-provider"
subcategory: ""
description: |-
Represents the EPCC API Price Object https://documentation.elasticpath.com/commerce-cloud/docs/api/pcm/pricebooks/prices/create-product-prices.html.
Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
---
page_title: "epcc_profile Data Source - terraform-provider-epcc"
page_title: "epcc_profile Data Source - epcc-terraform-provider"
subcategory: ""
description: |-
Represents the EPCC API OpenID Connect Profiles https://documentation.elasticpath.com/commerce-cloud/docs/api/single-sign-on/oidc-profiles/index.html.
Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
---
page_title: "epcc_promotion Data Source - terraform-provider-epcc"
page_title: "epcc_promotion Data Source - epcc-terraform-provider"
subcategory: ""
description: |-
Represents the EPCC API Promotion Object https://documentation.elasticpath.com/commerce-cloud/docs/api/carts-and-checkout/promotions/index.html#the-promotion-object.
Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
---
page_title: "epcc_realm Data Source - terraform-provider-epcc"
page_title: "epcc_realm Data Source - epcc-terraform-provider"
subcategory: ""
description: |-
Represents the EPCC API Authentication Realms https://documentation.elasticpath.com/commerce-cloud/docs/api/single-sign-on/authentication-realms/index.html.
Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
---
page_title: "epcc_user_authentication_info Data Source - terraform-provider-epcc"
page_title: "epcc_user_authentication_info Data Source - epcc-terraform-provider"
subcategory: ""
description: |-
Represents the EPCC API User Authentication Info
Expand Down
18 changes: 14 additions & 4 deletions docs/index.md
Original file line number Diff line number Diff line change
@@ -1,19 +1,29 @@
---
page_title: "epcc Provider"
page_title: "epcc-terraform-provider Provider"
subcategory: ""
description: |-
---

# epcc Provider
# epcc-terraform-provider Provider



## Example Usage

```terraform
provider "scaffolding" {
# example configuration here
provider "epcc" {
// Can set via `EPCC_CLIENT_ID` environment variable.
client_id = "some_client_id"
// Can set via `EPCC_CLIENT_SECRET` environment variable.
client_secret = "some_client_secret"
// Can set via `EPCC_API_BASE_URL` environment variable
api_base_url = "https://api.moltin.com/"
// Can set via `EPCC_BETA_API_FEATURES` environment variable.
beta_features = "account-management"
}
```

Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
---
page_title: "epcc_account Resource - terraform-provider-epcc"
page_title: "epcc_account Resource - epcc-terraform-provider"
subcategory: ""
description: |-
Represents the EPCC API Account resource https://documentation.elasticpath.com/commerce-cloud/docs/api/account-management/accounts/index.html#the-account-object.
Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
---
page_title: "epcc_catalog Resource - terraform-provider-epcc"
page_title: "epcc_catalog Resource - epcc-terraform-provider"
subcategory: ""
description: |-
Represents the EPCC API PCM Catalog Object https://documentation.elasticpath.com/commerce-cloud/docs/api/pcm/catalogs/index.html#the-catalog-object.
Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
---
page_title: "epcc_catalog_rule Resource - terraform-provider-epcc"
page_title: "epcc_catalog_rule Resource - epcc-terraform-provider"
subcategory: ""
description: |-
Represents the EPCC API PCM Catalog Rule Object https://documentation.elasticpath.com/commerce-cloud/docs/api/pcm/catalogs/rules/get-a-catalog-rule.html.
Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
---
page_title: "epcc_currency Resource - terraform-provider-epcc"
page_title: "epcc_currency Resource - epcc-terraform-provider"
subcategory: ""
description: |-
Represents the EPCC API Currency Object https://documentation.elasticpath.com/commerce-cloud/docs/api/advanced/currencies/index.html#the-currency-object.
Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
---
page_title: "epcc_customer Resource - terraform-provider-epcc"
page_title: "epcc_customer Resource - epcc-terraform-provider"
subcategory: ""
description: |-
Represents the EPCC API Customer Object https://documentation.elasticpath.com/commerce-cloud/docs/api/orders-and-customers/customers/index.html#the-customer-object.
Expand Down
10 changes: 8 additions & 2 deletions docs/resources/entry.md → docs/resources/epcc_entry.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
---
page_title: "epcc_entry Resource - terraform-provider-epcc"
page_title: "epcc_entry Resource - epcc-terraform-provider"
subcategory: ""
description: |-
Represents the EPCC API Entry Object https://documentation.elasticpath.com/commerce-cloud/docs/api/advanced/custom-data/entries/index.html.
Expand All @@ -15,9 +15,15 @@ Represents the EPCC API [Entry Object](https://documentation.elasticpath.com/com

### Required

- **payload** (Map of String)
- **slug** (String)

### Optional

- **booleans** (Map of Boolean)
- **numbers** (Map of Number)
- **strings** (Map of String)
- **target_id** (String) Target core object identifier (can only be used for core flows)

### Read-only

- **id** (String) The ID of this resource.
Expand Down
2 changes: 1 addition & 1 deletion docs/resources/field.md → docs/resources/epcc_field.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
---
page_title: "epcc_field Resource - terraform-provider-epcc"
page_title: "epcc_field Resource - epcc-terraform-provider"
subcategory: ""
description: |-
Represents the EPCC API Fields Object https://documentation.elasticpath.com/commerce-cloud/docs/api/advanced/custom-data/fields/index.html.
Expand Down
Loading

0 comments on commit 0f1bf99

Please sign in to comment.