Skip to content

Commit 4494c83

Browse files
docs: swap examples used in readme (#585)
docs: document how to forcibly omit required field
1 parent 1b36ef9 commit 4494c83

1 file changed

Lines changed: 13 additions & 0 deletions

File tree

README.md

Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -452,6 +452,19 @@ JsonValue complexValue = JsonValue.from(Map.of(
452452
));
453453
```
454454

455+
Normally a `Builder` class's `build` method will throw [`IllegalStateException`](https://docs.oracle.com/javase/8/docs/api/java/lang/IllegalStateException.html) if any required parameter or property is unset.
456+
457+
To forcibly omit a required parameter or property, pass [`JsonMissing`](lithic-java-core/src/main/kotlin/com/lithic/api/core/Values.kt):
458+
459+
```java
460+
import com.lithic.api.core.JsonMissing;
461+
import com.lithic.api.models.CardCreateParams;
462+
463+
CardCreateParams params = CardCreateParams.builder()
464+
.type(JsonMissing.of())
465+
.build();
466+
```
467+
455468
### Response properties
456469

457470
To access undocumented response properties, call the `_additionalProperties()` method:

0 commit comments

Comments
 (0)