Class: Stripe::AccountNotice
- Inherits:
-
APIResource
- Object
- StripeObject
- APIResource
- Stripe::AccountNotice
- Extended by:
- Stripe::APIOperations::List
- Includes:
- Stripe::APIOperations::Save
- Defined in:
- lib/stripe/resources/account_notice.rb
Overview
A notice to a Connected account. Notice can be sent by Stripe on your behalf or you can opt to send the notices yourself.
See the [guide to send notices](docs.stripe.com/issuing/compliance-us/issuing-regulated-customer-notices) to your connected accounts.
Defined Under Namespace
Classes: Email, LinkedObjects
Constant Summary collapse
- OBJECT_NAME =
"account_notice"
Constants inherited from StripeObject
StripeObject::RESERVED_FIELD_NAMES
Instance Attribute Summary collapse
-
#created ⇒ Object
readonly
Time at which the object was created.
-
#deadline ⇒ Object
readonly
When present, the deadline for sending the notice to meet the relevant regulations.
-
#email ⇒ Object
readonly
Information about the email when sent.
-
#id ⇒ Object
readonly
Unique identifier for the object.
-
#linked_objects ⇒ Object
readonly
Information about objects related to the notice.
-
#livemode ⇒ Object
readonly
If the object exists in live mode, the value is ‘true`.
-
#metadata ⇒ Object
readonly
Set of [key-value pairs](docs.stripe.com/api/metadata) that you can attach to an object.
-
#object ⇒ Object
readonly
String representing the object’s type.
-
#reason ⇒ Object
readonly
Reason the notice is being sent.
-
#sent_at ⇒ Object
readonly
Date when the notice was sent.
Attributes inherited from APIResource
Attributes inherited from StripeObject
Class Method Summary collapse
- .field_remappings ⇒ Object
- .inner_class_types ⇒ Object
-
.list(params = {}, opts = {}) ⇒ Object
Retrieves a list of AccountNotice objects.
- .object_name ⇒ Object
-
.update(account_notice, params = {}, opts = {}) ⇒ Object
Updates an AccountNotice object.
Methods included from Stripe::APIOperations::List
Methods included from Stripe::APIOperations::Save
Methods inherited from APIResource
class_name, custom_method, #refresh, #request_stripe_object, resource_url, #resource_url, retrieve, save_nested_resource
Methods included from Stripe::APIOperations::Request
Methods inherited from StripeObject
#==, #[], #[]=, #_get_inner_class_type, additive_object_param, additive_object_param?, #as_json, construct_from, #deleted?, #dirty!, #each, #eql?, field_encodings, #hash, #initialize, #inspect, #keys, #marshal_dump, #marshal_load, protected_fields, #serialize_params, #to_hash, #to_json, #to_s, #update_attributes, #values
Constructor Details
This class inherits a constructor from Stripe::StripeObject
Dynamic Method Handling
This class handles dynamic methods through the method_missing method in the class Stripe::StripeObject
Instance Attribute Details
#created ⇒ Object (readonly)
Time at which the object was created. Measured in seconds since the Unix epoch.
51 52 53 |
# File 'lib/stripe/resources/account_notice.rb', line 51 def created @created end |
#deadline ⇒ Object (readonly)
When present, the deadline for sending the notice to meet the relevant regulations.
53 54 55 |
# File 'lib/stripe/resources/account_notice.rb', line 53 def deadline @deadline end |
#email ⇒ Object (readonly)
Information about the email when sent.
55 56 57 |
# File 'lib/stripe/resources/account_notice.rb', line 55 def email @email end |
#id ⇒ Object (readonly)
Unique identifier for the object.
57 58 59 |
# File 'lib/stripe/resources/account_notice.rb', line 57 def id @id end |
#linked_objects ⇒ Object (readonly)
Information about objects related to the notice.
59 60 61 |
# File 'lib/stripe/resources/account_notice.rb', line 59 def linked_objects @linked_objects end |
#livemode ⇒ Object (readonly)
If the object exists in live mode, the value is ‘true`. If the object exists in test mode, the value is `false`.
61 62 63 |
# File 'lib/stripe/resources/account_notice.rb', line 61 def livemode @livemode end |
#metadata ⇒ Object (readonly)
Set of [key-value pairs](docs.stripe.com/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format.
63 64 65 |
# File 'lib/stripe/resources/account_notice.rb', line 63 def @metadata end |
#object ⇒ Object (readonly)
String representing the object’s type. Objects of the same type share the same value.
65 66 67 |
# File 'lib/stripe/resources/account_notice.rb', line 65 def object @object end |
#reason ⇒ Object (readonly)
Reason the notice is being sent. The reason determines what copy the notice must contain. See the [regulated customer notices](docs.stripe.com/issuing/compliance-us/issuing-regulated-customer-notices) guide. All reasons might not apply to your integration, and Stripe might add new reasons in the future, so we recommend an internal warning when you receive an unknown reason.
67 68 69 |
# File 'lib/stripe/resources/account_notice.rb', line 67 def reason @reason end |
#sent_at ⇒ Object (readonly)
Date when the notice was sent. When absent, you must send the notice, update the content of the email and date when it was sent.
69 70 71 |
# File 'lib/stripe/resources/account_notice.rb', line 69 def sent_at @sent_at end |
Class Method Details
.field_remappings ⇒ Object
90 91 92 |
# File 'lib/stripe/resources/account_notice.rb', line 90 def self.field_remappings @field_remappings = {} end |
.inner_class_types ⇒ Object
86 87 88 |
# File 'lib/stripe/resources/account_notice.rb', line 86 def self.inner_class_types @inner_class_types = { email: Email, linked_objects: LinkedObjects } end |
.list(params = {}, opts = {}) ⇒ Object
Retrieves a list of AccountNotice objects. The objects are sorted in descending order by creation date, with the most-recently-created object appearing first.
72 73 74 |
# File 'lib/stripe/resources/account_notice.rb', line 72 def self.list(params = {}, opts = {}) request_stripe_object(method: :get, path: "/v1/account_notices", params: params, opts: opts) end |
.object_name ⇒ Object
13 14 15 |
# File 'lib/stripe/resources/account_notice.rb', line 13 def self.object_name "account_notice" end |
.update(account_notice, params = {}, opts = {}) ⇒ Object
Updates an AccountNotice object.
77 78 79 80 81 82 83 84 |
# File 'lib/stripe/resources/account_notice.rb', line 77 def self.update(account_notice, params = {}, opts = {}) request_stripe_object( method: :post, path: format("/v1/account_notices/%<account_notice>s", { account_notice: CGI.escape(account_notice) }), params: params, opts: opts ) end |