Package com.stripe.model
Class EphemeralKey
java.lang.Object
com.stripe.model.StripeObject
com.stripe.net.ApiResource
com.stripe.model.EphemeralKey
- All Implemented Interfaces:
HasId
,StripeObjectInterface
-
Nested Class Summary
Nested classes/interfaces inherited from class com.stripe.net.ApiResource
ApiResource.RequestMethod
-
Field Summary
Fields inherited from class com.stripe.net.ApiResource
CHARSET, GSON
Fields inherited from class com.stripe.model.StripeObject
PRETTY_PRINT_GSON
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionprotected boolean
static EphemeralKey
create
(EphemeralKeyCreateParams params, RequestOptions options) Creates an ephemeral API key for a given resource.static EphemeralKey
create
(Map<String, Object> params, RequestOptions options) Creates an ephemeral API key for a given resource.delete()
Invalidates an ephemeral API key for a given resource.delete
(RequestOptions options) Invalidates an ephemeral API key for a given resource.boolean
Time at which the object was created.Time at which the key will expire.getId()
Unique identifier for the object.Has the valuetrue
if the object exists in live mode or the valuefalse
if the object exists in test mode.String representing the object's type.The key's secret.int
hashCode()
void
setAssociatedObjects
(List<EphemeralKey.AssociatedObject> associatedObjects) void
setCreated
(Long created) Time at which the object was created.void
setExpires
(Long expires) Time at which the key will expire.void
Unique identifier for the object.void
setLivemode
(Boolean livemode) Has the valuetrue
if the object exists in live mode or the valuefalse
if the object exists in test mode.void
String representing the object's type.void
setRawJson
(String rawJson) void
The key's secret.Methods inherited from class com.stripe.net.ApiResource
checkNullTypedParams, classUrl, classUrl, instanceUrl, instanceUrl, request, request, requestCollection, requestCollection, requestSearchResult, requestSearchResult, requestStream, requestStream, setExpandableFieldId, setStripeResponseGetter, singleClassUrl, singleClassUrl, subresourceUrl, urlEncode, urlEncodeId
Methods inherited from class com.stripe.model.StripeObject
equals, getLastResponse, getRawJsonObject, setLastResponse, toJson, toString
-
Constructor Details
-
EphemeralKey
public EphemeralKey()
-
-
Method Details
-
create
public static EphemeralKey create(EphemeralKeyCreateParams params, RequestOptions options) throws StripeException Creates an ephemeral API key for a given resource.- Parameters:
params
- request parametersoptions
- request options.stripeVersion
is required when creating ephemeral keys. it must have non-nullRequestOptions.getStripeVersionOverride()
.- Returns:
- the new ephemeral key
- Throws:
StripeException
-
create
public static EphemeralKey create(Map<String, Object> params, RequestOptions options) throws StripeExceptionCreates an ephemeral API key for a given resource.- Parameters:
params
- request parametersoptions
- request options.stripeVersion
is required when creating ephemeral keys. it must have non-nullRequestOptions.getStripeVersionOverride()
.- Returns:
- the new ephemeral key
- Throws:
StripeException
-
delete
Invalidates an ephemeral API key for a given resource.- Throws:
StripeException
-
delete
Invalidates an ephemeral API key for a given resource.- Throws:
StripeException
-
getCreated
Time at which the object was created. Measured in seconds since the Unix epoch. -
getExpires
Time at which the key will expire. Measured in seconds since the Unix epoch. -
getLivemode
Has the valuetrue
if the object exists in live mode or the valuefalse
if the object exists in test mode. -
getObject
String representing the object's type. Objects of the same type share the same value. -
getSecret
The key's secret. You can use this value to make authorized requests to the Stripe API. -
getAssociatedObjects
-
getRawJson
-
setCreated
Time at which the object was created. Measured in seconds since the Unix epoch. -
setExpires
Time at which the key will expire. Measured in seconds since the Unix epoch. -
setId
Unique identifier for the object. -
setLivemode
Has the valuetrue
if the object exists in live mode or the valuefalse
if the object exists in test mode. -
setObject
String representing the object's type. Objects of the same type share the same value. -
setSecret
The key's secret. You can use this value to make authorized requests to the Stripe API. -
setAssociatedObjects
-
setRawJson
-
equals
-
canEqual
-
hashCode
public int hashCode() -
getId
Unique identifier for the object.
-