You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Keep in mind that there are different method signatures depending on the action:
121
-
122
-
- When operating on a collection (e.g. `.list`, `.create`) the method signature is
123
-
`method(params, opts)`.
124
-
- When operating on resource (e.g. `.capture`, `.update`) the method signature is
125
-
`method(id, params, opts)`.
126
-
- One exception is that `retrieve`, despite being an operation on a resource, has the signature
127
-
`retrieve(id, opts)`. In addition, it will accept a Hash for the `id` param but will extract the
128
-
`id` key out and use the others as options.
129
-
130
94
### StripeClient vs legacy pattern
131
95
132
96
We introduced the `StripeClient` class in v13 of the Ruby SDK. The legacy pattern used prior to that version is still available to use but will be marked as deprecated soon. Review the [migration guide to use StripeClient](https://github.com/stripe/stripe-ruby/wiki/Migration-guide-for-v13) to move from the legacy pattern.
@@ -138,15 +102,15 @@ Once the legacy pattern is deprecated, new API endpoints will only be accessible
138
102
Both indexer and accessors can be used to retrieve values of resource properties.
0 commit comments