Repository: firebase/firebase-admin-java
Pull request #595 (2021-09-13 22:00:38)

chore(deps): bump netty.version from 4.1.67.Final to 4.1.68.Final
Bumps `netty.version` from 4.1.67.Final to 4.1.68.Final.
Updates `netty-codec-http` from 4.1.67.Final to 4.1.68.Final
<details>
<summary>Commits</summary>
<ul>
<li><a href="https://github.com/netty/netty/commit/7d34282f9d2ffdd64c91cb4780b09902d9779b92"><code>7d34282</code></a> [maven-release-plugin] prepare release netty-4.1.68.Final</li>
<li><a href="https://github.com/netty/netty/commit/a0c9b2f9e15112cb52001f26fa3cb6772f53d674"><code>a0c9b2f</code></a> Fix netty-tcnative* entries in bom</li>
<li><a href="https://github.com/netty/netty/commit/6da4956b31023ae967451e1d94ff51a746a9194f"><code>6da4956</code></a> Merge pull request from GHSA-9vjp-v76f-g363</li>
<li><a href="https://github.com/netty/netty/commit/41d3d61a61608f2223bb364955ab2045dd5e4020"><code>41d3d61</code></a> Merge pull request from GHSA-grg4-wf29-r9vv</li>
<li><a href="https://github.com/netty/netty/commit/deb048985bd74a825131e51849446d1e905b5e93"><code>deb0489</code></a> Respect jdk.tls.namedGroups when using native SSL implementation (<a href="https://github-redirect.dependabot.com/netty/netty/issues/11660">#11660</a>)</li>
<li><a href="https://github.com/netty/netty/commit/f2de2bbe519c08f4a3269bc706e82ca94e6f29ab"><code>f2de2bb</code></a> Add support for mac m1 (<a href="https://github-redirect.dependabot.com/netty/netty/issues/11666">#11666</a>)</li>
<li><a href="https://github.com/netty/netty/commit/a53eb80901b8bf678e2ff65e4715d25c4fec638c"><code>a53eb80</code></a> Throw exceptions when rule violating UDS paths been passed in. (<a href="https://github-redirect.dependabot.com/netty/netty/issues/11663">#11663</a>)</li>
<li><a href="https://github.com/netty/netty/commit/a329857ec20cc1b93ceead6307c6849f93b3f101"><code>a329857</code></a> Updated &quot;CipherSuitesConverter&quot; to make it public. (<a href="https://github-redirect.dependabot.com/netty/netty/issues/11656">#11656</a>)</li>
<li><a href="https://github.com/netty/netty/commit/21fb48e4d22b5d030b165200e663c11f545f5576"><code>21fb48e</code></a> Deprecate UnaryPromiseNotifier (<a href="https://github-redirect.dependabot.com/netty/netty/issues/11653">#11653</a>)</li>
<li><a href="https://github.com/netty/netty/commit/37c03cce5e95fb200b3dc5b234b46fe0a281bdec"><code>37c03cc</code></a> Include number of maximum active streams in exception message (<a href="https://github-redirect.dependabot.com/netty/netty/issues/11644">#11644</a>)</li>
<li>Additional commits viewable in <a href="https://github.com/netty/netty/compare/netty-4.1.67.Final...netty-4.1.68.Final">compare view</a></li>
</ul>
</details>
<br />

Updates `netty-handler` from 4.1.67.Final to 4.1.68.Final
<details>
<summary>Commits</summary>
<ul>
<li><a href="https://github.com/netty/netty/commit/7d34282f9d2ffdd64c91cb4780b09902d9779b92"><code>7d34282</code></a> [maven-release-plugin] prepare release netty-4.1.68.Final</li>
<li><a href="https://github.com/netty/netty/commit/a0c9b2f9e15112cb52001f26fa3cb6772f53d674"><code>a0c9b2f</code></a> Fix netty-tcnative* entries in bom</li>
<li><a href="https://github.com/netty/netty/commit/6da4956b31023ae967451e1d94ff51a746a9194f"><code>6da4956</code></a> Merge pull request from GHSA-9vjp-v76f-g363</li>
<li><a href="https://github.com/netty/netty/commit/41d3d61a61608f2223bb364955ab2045dd5e4020"><code>41d3d61</code></a> Merge pull request from GHSA-grg4-wf29-r9vv</li>
<li><a href="https://github.com/netty/netty/commit/deb048985bd74a825131e51849446d1e905b5e93"><code>deb0489</code></a> Respect jdk.tls.namedGroups when using native SSL implementation (<a href="https://github-redirect.dependabot.com/netty/netty/issues/11660">#11660</a>)</li>
<li><a href="https://github.com/netty/netty/commit/f2de2bbe519c08f4a3269bc706e82ca94e6f29ab"><code>f2de2bb</code></a> Add support for mac m1 (<a href="https://github-redirect.dependabot.com/netty/netty/issues/11666">#11666</a>)</li>
<li><a href="https://github.com/netty/netty/commit/a53eb80901b8bf678e2ff65e4715d25c4fec638c"><code>a53eb80</code></a> Throw exceptions when rule violating UDS paths been passed in. (<a href="https://github-redirect.dependabot.com/netty/netty/issues/11663">#11663</a>)</li>
<li><a href="https://github.com/netty/netty/commit/a329857ec20cc1b93ceead6307c6849f93b3f101"><code>a329857</code></a> Updated &quot;CipherSuitesConverter&quot; to make it public. (<a href="https://github-redirect.dependabot.com/netty/netty/issues/11656">#11656</a>)</li>
<li><a href="https://github.com/netty/netty/commit/21fb48e4d22b5d030b165200e663c11f545f5576"><code>21fb48e</code></a> Deprecate UnaryPromiseNotifier (<a href="https://github-redirect.dependabot.com/netty/netty/issues/11653">#11653</a>)</li>
<li><a href="https://github.com/netty/netty/commit/37c03cce5e95fb200b3dc5b234b46fe0a281bdec"><code>37c03cc</code></a> Include number of maximum active streams in exception message (<a href="https://github-redirect.dependabot.com/netty/netty/issues/11644">#11644</a>)</li>
<li>Additional commits viewable in <a href="https://github.com/netty/netty/compare/netty-4.1.67.Final...netty-4.1.68.Final">compare view</a></li>
</ul>
</details>
<br />

Updates `netty-transport` from 4.1.67.Final to 4.1.68.Final
<details>
<summary>Commits</summary>
<ul>
<li><a href="https://github.com/netty/netty/commit/7d34282f9d2ffdd64c91cb4780b09902d9779b92"><code>7d34282</code></a> [maven-release-plugin] prepare release netty-4.1.68.Final</li>
<li><a href="https://github.com/netty/netty/commit/a0c9b2f9e15112cb52001f26fa3cb6772f53d674"><code>a0c9b2f</code></a> Fix netty-tcnative* entries in bom</li>
<li><a href="https://github.com/netty/netty/commit/6da4956b31023ae967451e1d94ff51a746a9194f"><code>6da4956</code></a> Merge pull request from GHSA-9vjp-v76f-g363</li>
<li><a href="https://github.com/netty/netty/commit/41d3d61a61608f2223bb364955ab2045dd5e4020"><code>41d3d61</code></a> Merge pull request from GHSA-grg4-wf29-r9vv</li>
<li><a href="https://github.com/netty/netty/commit/deb048985bd74a825131e51849446d1e905b5e93"><code>deb0489</code></a> Respect jdk.tls.namedGroups when using native SSL implementation (<a href="https://github-redirect.dependabot.com/netty/netty/issues/11660">#11660</a>)</li>
<li><a href="https://github.com/netty/netty/commit/f2de2bbe519c08f4a3269bc706e82ca94e6f29ab"><code>f2de2bb</code></a> Add support for mac m1 (<a href="https://github-redirect.dependabot.com/netty/netty/issues/11666">#11666</a>)</li>
<li><a href="https://github.com/netty/netty/commit/a53eb80901b8bf678e2ff65e4715d25c4fec638c"><code>a53eb80</code></a> Throw exceptions when rule violating UDS paths been passed in. (<a href="https://github-redirect.dependabot.com/netty/netty/issues/11663">#11663</a>)</li>
<li><a href="https://github.com/netty/netty/commit/a329857ec20cc1b93ceead6307c6849f93b3f101"><code>a329857</code></a> Updated &quot;CipherSuitesConverter&quot; to make it public. (<a href="https://github-redirect.dependabot.com/netty/netty/issues/11656">#11656</a>)</li>
<li><a href="https://github.com/netty/netty/commit/21fb48e4d22b5d030b165200e663c11f545f5576"><code>21fb48e</code></a> Deprecate UnaryPromiseNotifier (<a href="https://github-redirect.dependabot.com/netty/netty/issues/11653">#11653</a>)</li>
<li><a href="https://github.com/netty/netty/commit/37c03cce5e95fb200b3dc5b234b46fe0a281bdec"><code>37c03cc</code></a> Include number of maximum active streams in exception message (<a href="https://github-redirect.dependabot.com/netty/netty/issues/11644">#11644</a>)</li>
<li>Additional commits viewable in <a href="https://github.com/netty/netty/compare/netty-4.1.67.Final...netty-4.1.68.Final">compare view</a></li>
</ul>
</details>
<br />


Dependabot will resolve any conflicts with this PR as long as you don't alter it yourself. You can also trigger a rebase manually by commenting `@dependabot rebase`.

[//]: # (dependabot-automerge-start)
[//]: # (dependabot-automerge-end)

---

<details>
<summary>Dependabot commands and options</summary>
<br />

You can trigger Dependabot actions by commenting on this PR:
- `@dependabot rebase` will rebase this PR
- `@dependabot recreate` will recreate this PR, overwriting any edits that have been made to it
- `@dependabot merge` will merge this PR after your CI passes on it
- `@dependabot squash and merge` will squash and merge this PR after your CI passes on it
- `@dependabot cancel merge` will cancel a previously requested merge and block automerging
- `@dependabot reopen` will reopen this PR if it is closed
- `@dependabot close` will close this PR and stop Dependabot recreating it. You can achieve the same result by closing it manually
- `@dependabot ignore this major version` will close this PR and stop Dependabot creating any more for this major version (unless you reopen the PR or upgrade to it yourself)
- `@dependabot ignore this minor version` will close this PR and stop Dependabot creating any more for this minor version (unless you reopen the PR or upgrade to it yourself)
- `@dependabot ignore this dependency` will close this PR and stop Dependabot creating any more for this dependency (unless you reopen the PR or upgrade to it yourself)


</details>


Patch:
diff --git a/pom.xml b/pom.xml
index 340b59a..30d4f60 100644
--- a/pom.xml
+++ b/pom.xml
@@ -19,7 +19,7 @@
 
     <groupId>com.google.firebase</groupId>
     <artifactId>firebase-admin</artifactId>
-    <version>8.0.1</version>
+    <version>8.1.0</version>
     <packaging>jar</packaging>
 
     <name>firebase-admin</name>
@@ -59,7 +59,7 @@
         <project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
         <project.reporting.outputEncoding>UTF-8</project.reporting.outputEncoding>
         <skipUTs>${skipTests}</skipUTs>
-        <netty.version>4.1.67.Final</netty.version>
+        <netty.version>4.1.68.Final</netty.version>
     </properties>
 
     <scm>
@@ -77,16 +77,6 @@
     </distributionManagement>
 
     <profiles>
-        <profile>
-            <!-- Disable Doclint on Java 8 and higher -->
-            <id>disable-java8-doclint</id>
-            <activation>
-                <jdk>[1.8,)</jdk>
-            </activation>
-            <properties>
-                <additionalparam>-Xdoclint:none</additionalparam>
-            </properties>
-        </profile>
         <profile>
             <id>devsite-apidocs</id>
             <activation>
@@ -123,18 +113,19 @@
                                     <version>1.3</version>
                                 </additionalDependency>
                             </additionalDependencies>
-                            <additionalparam>
-                                -hdf book.path /docs/reference/_book.yaml
-                                -hdf project.path /_project.yaml
-                                -hdf devsite.path /docs/reference/admin/java/reference/
-                                -d ${project.build.directory}/apidocs
-                                -templatedir ${devsite.template}
-                                -toroot /docs/reference/admin/java/reference/
-                                -yaml _toc.yaml
-                                -warning 101
-                            </additionalparam>
+                            <additionalOptions>
+                                <additionalOption>-hdf book.path /docs/reference/_book.yaml</additionalOption>
+                                <additionalOption>-hdf project.path /_project.yaml</additionalOption>
+                                <additionalOption>-hdf devsite.path /docs/reference/admin/java/reference/</additionalOption>
+                                <additionalOption>-d ${project.build.directory}/apidocs</additionalOption>
+                                <additionalOption>-templatedir ${devsite.template}</additionalOption>
+                                <additionalOption>-toroot /docs/reference/admin/java/reference/</additionalOption>
+                                <additionalOption>-yaml _toc.yaml</additionalOption>
+                                <additionalOption>-warning 101</additionalOption>
+                            </additionalOptions>
                             <useStandardDocletOptions>false</useStandardDocletOptions>
                             <additionalJOption>-J-Xmx1024m</additionalJOption>
+                            <doclint>none</doclint>
                         </configuration>
                     </plugin>
                     <plugin>
@@ -334,11 +325,12 @@
                             <version>1.3</version>
                         </additionalDependency>
                     </additionalDependencies>
-                    <additionalparam>
-                        -warning 101
-                    </additionalparam>
+                    <additionalOptions>
+                        <additionalOption>-warning 101</additionalOption>
+                    </additionalOptions>
                     <useStandardDocletOptions>false</useStandardDocletOptions>
                     <additionalJOption>-J-Xmx1024m</additionalJOption>
+                    <doclint>none</doclint>
                 </configuration>
             </plugin>
 
diff --git a/src/main/java/com/google/firebase/remoteconfig/Parameter.java b/src/main/java/com/google/firebase/remoteconfig/Parameter.java
index d61816b..0b1ee6e 100644
--- a/src/main/java/com/google/firebase/remoteconfig/Parameter.java
+++ b/src/main/java/com/google/firebase/remoteconfig/Parameter.java
@@ -18,6 +18,7 @@ package com.google.firebase.remoteconfig;
 
 import static com.google.common.base.Preconditions.checkNotNull;
 
+import com.google.common.base.Strings;
 import com.google.firebase.internal.NonNull;
 import com.google.firebase.internal.Nullable;
 import com.google.firebase.remoteconfig.internal.TemplateResponse.ParameterResponse;
@@ -37,6 +38,7 @@ public final class Parameter {
   private ParameterValue defaultValue;
   private String description;
   private Map<String, ParameterValue> conditionalValues;
+  private ParameterValueType valueType;
 
   /**
    * Creates a new {@link Parameter}.
@@ -59,6 +61,9 @@ public final class Parameter {
     this.defaultValue = (responseDefaultValue == null) ? null
             : ParameterValue.fromParameterValueResponse(responseDefaultValue);
     this.description = parameterResponse.getDescription();
+    if (!Strings.isNullOrEmpty(parameterResponse.getValueType())) {
+      this.valueType = ParameterValueType.valueOf(parameterResponse.getValueType());
+    }
   }
 
   /**
@@ -93,6 +98,16 @@ public final class Parameter {
     return conditionalValues;
   }
 
+  /**
+   * Gets the data type of the parameter value.
+   *
+   * @return The data type of the parameter value or null.
+   */
+  @Nullable
+  public ParameterValueType getValueType() {
+    return valueType;
+  }
+
   /**
    * Sets the default value of the parameter.
    * This is the value to set the parameter to, when none of the named conditions
@@ -133,6 +148,18 @@ public final class Parameter {
     return this;
   }
 
+  /**
+   * Sets the data type of the parameter value.
+   * Defaults to `ParameterValueType.STRING` if unspecified.
+   *
+   * @param valueType The data type of the parameter value.
+   * @return This {@link Parameter}.
+   */
+  public Parameter setValueType(@Nullable ParameterValueType valueType) {
+    this.valueType = valueType;
+    return this;
+  }
+
   ParameterResponse toParameterResponse() {
     Map<String, ParameterValueResponse> conditionalResponseValues = new HashMap<>();
     for (Map.Entry<String, ParameterValue> entry : conditionalValues.entrySet()) {
@@ -143,7 +170,8 @@ public final class Parameter {
     return new ParameterResponse()
             .setDefaultValue(defaultValueResponse)
             .setDescription(description)
-            .setConditionalValues(conditionalResponseValues);
+            .setConditionalValues(conditionalResponseValues)
+            .setValueType(this.valueType == null ? null : this.valueType.getValueType());
   }
 
   @Override
@@ -157,11 +185,12 @@ public final class Parameter {
     Parameter parameter = (Parameter) o;
     return Objects.equals(defaultValue, parameter.defaultValue)
             && Objects.equals(description, parameter.description)
-            && Objects.equals(conditionalValues, parameter.conditionalValues);
+            && Objects.equals(conditionalValues, parameter.conditionalValues)
+            && Objects.equals(valueType, parameter.valueType);
   }
 
   @Override
   public int hashCode() {
-    return Objects.hash(defaultValue, description, conditionalValues);
+    return Objects.hash(defaultValue, description, conditionalValues, valueType);
   }
 }
diff --git a/src/main/java/com/google/firebase/remoteconfig/ParameterValueType.java b/src/main/java/com/google/firebase/remoteconfig/ParameterValueType.java
new file mode 100644
index 0000000..e9957cb
--- /dev/null
+++ b/src/main/java/com/google/firebase/remoteconfig/ParameterValueType.java
@@ -0,0 +1,37 @@
+/*
+ * Copyright 2021 Google LLC
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ *     http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+package com.google.firebase.remoteconfig;
+
+/**
+ * Data types that are associated with parameter values.
+ */
+public enum ParameterValueType {
+  STRING("STRING"),
+  BOOLEAN("BOOLEAN"),
+  NUMBER("NUMBER"),
+  JSON("JSON");
+
+  private final String valueType;
+
+  ParameterValueType(String valueType) {
+    this.valueType = valueType;
+  }
+
+  public String getValueType() {
+    return valueType;
+  }
+}
diff --git a/src/main/java/com/google/firebase/remoteconfig/internal/TemplateResponse.java b/src/main/java/com/google/firebase/remoteconfig/internal/TemplateResponse.java
index 09e71ef..57a066b 100644
--- a/src/main/java/com/google/firebase/remoteconfig/internal/TemplateResponse.java
+++ b/src/main/java/com/google/firebase/remoteconfig/internal/TemplateResponse.java
@@ -107,6 +107,9 @@ public final class TemplateResponse {
     @Key("conditionalValues")
     private Map<String, ParameterValueResponse> conditionalValues;
 
+    @Key("valueType")
+    private String valueType;
+
     public ParameterValueResponse getDefaultValue() {
       return defaultValue;
     }
@@ -119,6 +122,10 @@ public final class TemplateResponse {
       return conditionalValues;
     }
 
+    public String getValueType() {
+      return valueType;
+    }
+
     public ParameterResponse setDefaultValue(
             ParameterValueResponse defaultValue) {
       this.defaultValue = defaultValue;
@@ -135,6 +142,11 @@ public final class TemplateResponse {
       this.conditionalValues = conditionalValues;
       return this;
     }
+
+    public ParameterResponse setValueType(String valueType) {
+      this.valueType = valueType;
+      return this;
+    }
   }
 
   /**


Test patch:
diff --git a/src/test/java/com/google/firebase/remoteconfig/FirebaseRemoteConfigClientImplTest.java b/src/test/java/com/google/firebase/remoteconfig/FirebaseRemoteConfigClientImplTest.java
index 71e6f81..f2d5c81 100644
--- a/src/test/java/com/google/firebase/remoteconfig/FirebaseRemoteConfigClientImplTest.java
+++ b/src/test/java/com/google/firebase/remoteconfig/FirebaseRemoteConfigClientImplTest.java
@@ -85,9 +85,11 @@ public class FirebaseRemoteConfigClientImplTest {
                   .setConditionalValues(ImmutableMap.<String, ParameterValue>of(
                           "ios_en", ParameterValue.of("welcome to app en")
                   ))
-                  .setDescription("text for welcome message!"),
+                  .setDescription("text for welcome message!")
+                  .setValueType(ParameterValueType.STRING),
           "header_text", new Parameter()
                   .setDefaultValue(ParameterValue.inAppDefault())
+                  .setValueType(ParameterValueType.STRING)
   );
 
   private static final Map<String, ParameterGroup> EXPECTED_PARAMETER_GROUPS = ImmutableMap.of(
@@ -97,6 +99,7 @@ public class FirebaseRemoteConfigClientImplTest {
                           "pumpkin_spice_season", new Parameter()
                                   .setDefaultValue(ParameterValue.of("true"))
                                   .setDescription("Whether it's currently pumpkin spice season.")
+                                  .setValueType(ParameterValueType.BOOLEAN)
                           )
                   )
   );
diff --git a/src/test/java/com/google/firebase/remoteconfig/FirebaseRemoteConfigIT.java b/src/test/java/com/google/firebase/remoteconfig/FirebaseRemoteConfigIT.java
index bb90c6c..07a3c6c 100644
--- a/src/test/java/com/google/firebase/remoteconfig/FirebaseRemoteConfigIT.java
+++ b/src/test/java/com/google/firebase/remoteconfig/FirebaseRemoteConfigIT.java
@@ -249,9 +249,11 @@ public class FirebaseRemoteConfigIT {
                             "ios_en",
                             ParameterValue.of(String.format("welcome to app en %s", timestamp))
                     ))
-                    .setDescription("text for welcome message!"),
+                    .setDescription("text for welcome message!")
+                    .setValueType(ParameterValueType.STRING),
             "header_text", new Parameter()
-                    .setDefaultValue(ParameterValue.inAppDefault()));
+                    .setDefaultValue(ParameterValue.inAppDefault())
+                    .setValueType(ParameterValueType.STRING));
   }
 
   private Map<String, ParameterGroup> getParameterGroups() {
@@ -262,7 +264,8 @@ public class FirebaseRemoteConfigIT {
                     .setParameters(ImmutableMap.of(
                             "pumpkin_spice_season", new Parameter()
                                     .setDefaultValue(ParameterValue.of("true"))
-                                    .setDescription("Whether it's currently pumpkin spice season."))
+                                    .setDescription("Whether it's currently pumpkin spice season.")
+                                    .setValueType(ParameterValueType.STRING))
                     ));
   }
 
diff --git a/src/test/java/com/google/firebase/remoteconfig/ParameterTest.java b/src/test/java/com/google/firebase/remoteconfig/ParameterTest.java
index 952ea8b..7fc6ee5 100644
--- a/src/test/java/com/google/firebase/remoteconfig/ParameterTest.java
+++ b/src/test/java/com/google/firebase/remoteconfig/ParameterTest.java
@@ -38,6 +38,7 @@ public class ParameterTest {
     assertTrue(parameter.getConditionalValues().isEmpty());
     assertNull(parameter.getDefaultValue());
     assertNull(parameter.getDescription());
+    assertNull(parameter.getValueType());
   }
 
   @Test(expected = NullPointerException.class)
@@ -84,8 +85,23 @@ public class ParameterTest {
             .setConditionalValues(conditionalValues);
 
     assertEquals(parameterFive, parameterSix);
+
+    final Parameter parameterSeven = new Parameter()
+            .setDefaultValue(ParameterValue.inAppDefault())
+            .setDescription("greeting text")
+            .setConditionalValues(conditionalValues)
+            .setValueType(ParameterValueType.STRING);
+    final Parameter parameterEight = new Parameter()
+            .setDefaultValue(ParameterValue.inAppDefault())
+            .setDescription("greeting text")
+            .setConditionalValues(conditionalValues)
+            .setValueType(ParameterValueType.STRING);
+
+    assertEquals(parameterSeven, parameterEight);
     assertNotEquals(parameterOne, parameterThree);
     assertNotEquals(parameterOne, parameterFive);
+    assertNotEquals(parameterOne, parameterSeven);
     assertNotEquals(parameterThree, parameterFive);
+    assertNotEquals(parameterThree, parameterSeven);
   }
 }
diff --git a/src/test/java/com/google/firebase/remoteconfig/TemplateTest.java b/src/test/java/com/google/firebase/remoteconfig/TemplateTest.java
index ad4d48f..a3ea3e8 100644
--- a/src/test/java/com/google/firebase/remoteconfig/TemplateTest.java
+++ b/src/test/java/com/google/firebase/remoteconfig/TemplateTest.java
@@ -49,7 +49,8 @@ public class TemplateTest {
           "greeting_header", new Parameter()
                   .setDefaultValue(ParameterValue.inAppDefault())
                   .setDescription("greeting header text")
-                  .setConditionalValues(CONDITIONAL_VALUES),
+                  .setConditionalValues(CONDITIONAL_VALUES)
+                  .setValueType(ParameterValueType.STRING),
           "greeting_text", new Parameter()
                   .setDefaultValue(ParameterValue.inAppDefault())
                   .setDescription("greeting text")
@@ -274,15 +275,17 @@ public class TemplateTest {
   public void testToJSONWithParameterValues() {
     Template t = new Template();
     t.getParameters()
-            .put("with_value", new Parameter().setDefaultValue(ParameterValue.of("hello")));
+            .put("with_value", new Parameter().setDefaultValue(ParameterValue.of("hello"))
+                    .setValueType(ParameterValueType.NUMBER));
     t.getParameters()
             .put("with_inApp", new Parameter().setDefaultValue(ParameterValue.inAppDefault()));
     String jsonString = t.toJSON();
 
     assertEquals("{\"conditions\":[],\"parameterGroups\":{},"
             + "\"parameters\":{\"with_value\":{\"conditionalValues\":{},"
-            + "\"defaultValue\":{\"value\":\"hello\"}},\"with_inApp\":{\"conditionalValues\":{},"
-            + "\"defaultValue\":{\"useInAppDefault\":true}}}}", jsonString);
+            + "\"defaultValue\":{\"value\":\"hello\"},\"valueType\":\"NUMBER\"},\"with_inApp\":{"
+            + "\"conditionalValues\":{},\"defaultValue\":{\"useInAppDefault\":true}"
+            + "}}}", jsonString);
   }
 
   @Test
diff --git a/src/test/resources/getRemoteConfig.json b/src/test/resources/getRemoteConfig.json
index a4969f0..a80caa0 100644
--- a/src/test/resources/getRemoteConfig.json
+++ b/src/test/resources/getRemoteConfig.json
@@ -20,12 +20,14 @@
           "value": "welcome to app en"
         }
       },
-      "description": "text for welcome message!"
+      "description": "text for welcome message!",
+      "valueType": "STRING"
     },
     "header_text": {
       "defaultValue": {
         "useInAppDefault": true
-      }
+      },
+      "valueType": "STRING"
     }
   },
   "parameterGroups": {
@@ -36,7 +38,8 @@
           "defaultValue": {
             "value": "true"
           },
-          "description": "Whether it's currently pumpkin spice season."
+          "description": "Whether it's currently pumpkin spice season.",
+          "valueType": "BOOLEAN"
         }
       }
     }