Skip to main content
Package: com.coinbase.cdp.auth
Configuration options for Wallet Auth JWT generation. Wallet JWTs are used to authenticate write operations on account endpoints. They include a hash of the request body for integrity verification. Example usage:

Constructor Details

WalletJwtOptions

Validates the wallet JWT options. Throws: [IllegalArgumentException](https://docs.oracle.com/en/java/javase/17/docs/api/java.base/java/lang/IllegalArgumentException.html "class or interface in java.lang") - if validation fails Parameters: walletSecret - String requestMethod - String requestHost - String requestPath - String requestBody - Map<String,Object>

Method Details

hasRequestData

Returns whether the request has data to hash. Returns: boolean - true if request data is non-empty

toString

Returns a string representation of this record class. The representation contains the name of the class, followed by the name and value of each of the record components. Specified by: [toString](https://docs.oracle.com/en/java/javase/17/docs/api/java.base/java/lang/Record.html#toString\(\) "class or interface in java.lang") in class [Record](https://docs.oracle.com/en/java/javase/17/docs/api/java.base/java/lang/Record.html "class or interface in java.lang") Returns: String - a string representation of this object

hashCode

Returns a hash code value for this object. The value is derived from the hash code of each of the record components. Specified by: [hashCode](https://docs.oracle.com/en/java/javase/17/docs/api/java.base/java/lang/Record.html#hashCode\(\) "class or interface in java.lang") in class [Record](https://docs.oracle.com/en/java/javase/17/docs/api/java.base/java/lang/Record.html "class or interface in java.lang") Returns: int - a hash code value for this object

equals

Indicates whether some other object is “equal to” this one. The objects are equal if the other object is of the same class and if all the record components are equal. All components in this record class are compared with Objects::equals(Object,Object). Specified by: [equals](https://docs.oracle.com/en/java/javase/17/docs/api/java.base/java/lang/Record.html#equals\(java.lang.Object\) "class or interface in java.lang") in class [Record](https://docs.oracle.com/en/java/javase/17/docs/api/java.base/java/lang/Record.html "class or interface in java.lang") Parameters: o (Object) - the object with which to compare Returns: boolean - true if this object is the same as the o argument; false otherwise.

walletSecret

Returns the value of the walletSecret record component. Returns: String - the value of the walletSecret record component

requestMethod

Returns the value of the requestMethod record component. Returns: String - the value of the requestMethod record component

requestHost

Returns the value of the requestHost record component. Returns: String - the value of the requestHost record component

requestPath

Returns the value of the requestPath record component. Returns: String - the value of the requestPath record component

requestBody

Returns the value of the requestBody record component. Returns: Map<String,Object> - the value of the requestBody record component