PluginProbe
Charitable – Donation & Fundraising Platform (Donation Forms, Recurring Donations & Fundraising Campaigns) / 1.8.13
Charitable – Donation & Fundraising Platform (Donation Forms, Recurring Donations & Fundraising Campaigns) v1.8.13
1.8.13 1.8.12.3 1.8.12.2 1.8.12.1 1.8.12 1.8.11.3 1.8.11.2 1.8.11.1 1.8.11 1.6.6 1.6.60 1.6.7 1.6.8 1.6.9 1.7.0 1.7.0.1 1.7.0.11 1.7.0.12 1.7.0.14 1.7.0.2 1.7.0.3 1.7.0.5 1.7.0.6 1.7.0.7 1.7.0.9 All 211 releases
charitable / vendor / stripe / stripe-php / lib / Apps / Secret.php

Secret.php in Charitable – Donation & Fundraising Platform (Donation Forms, Recurring Donations & Fundraising Campaigns) 1.8.13, at vendor/stripe/stripe-php/lib/Apps/Secret.php

79 lines 2.9 KB
No matching file
Up and down to move Enter to open Esc to close
Raw Download Zip
1 <?php
2
3 // File generated from our OpenAPI spec
4
5 namespace Stripe\Apps;
6
7 /**
8 * Secret Store is an API that allows Stripe Apps developers to securely persist
9 * secrets for use by UI Extensions and app backends.
10 *
11 * The primary resource in Secret Store is a <code>secret</code>. Other apps can't
12 * view secrets created by an app. Additionally, secrets are scoped to provide
13 * further permission control.
14 *
15 * All Dashboard users and the app backend share <code>account</code> scoped
16 * secrets. Use the <code>account</code> scope for secrets that don't change
17 * per-user, like a third-party API key.
18 *
19 * A <code>user</code> scoped secret is accessible by the app backend and one
20 * specific Dashboard user. Use the <code>user</code> scope for per-user secrets
21 * like per-user OAuth tokens, where different users might have different
22 * permissions.
23 *
24 * Related guide: <a
25 * href="https://stripe.com/docs/stripe-apps/store-auth-data-custom-objects">Store
26 * data between page reloads</a>.
27 *
28 * @property string $id Unique identifier for the object.
29 * @property string $object String representing the object's type. Objects of the same type share the same value.
30 * @property int $created Time at which the object was created. Measured in seconds since the Unix epoch.
31 * @property bool $livemode Has the value <code>true</code> if the object exists in live mode or the value <code>false</code> if the object exists in test mode.
32 * @property string $name A name for the secret that's unique within the scope.
33 * @property null|string $payload The plaintext secret value to be stored.
34 * @property \Stripe\StripeObject $scope
35 */
36 class Secret extends \Stripe\ApiResource
37 {
38 const OBJECT_NAME = 'apps.secret';
39
40 use \Stripe\ApiOperations\All;
41 use \Stripe\ApiOperations\Create;
42
43 /**
44 * @param null|array $params
45 * @param null|array|string $opts
46 *
47 * @throws \Stripe\Exception\ApiErrorException if the request fails
48 *
49 * @return \Stripe\Apps\Secret the deleted secret
50 */
51 public static function deleteWhere($params = null, $opts = null)
52 {
53 $url = static::classUrl() . '/delete';
54 list($response, $opts) = static::_staticRequest('post', $url, $params, $opts);
55 $obj = \Stripe\Util\Util::convertToStripeObject($response->json, $opts);
56 $obj->setLastResponse($response);
57
58 return $obj;
59 }
60
61 /**
62 * @param null|array $params
63 * @param null|array|string $opts
64 *
65 * @throws \Stripe\Exception\ApiErrorException if the request fails
66 *
67 * @return \Stripe\Apps\Secret the finded secret
68 */
69 public static function find($params = null, $opts = null)
70 {
71 $url = static::classUrl() . '/find';
72 list($response, $opts) = static::_staticRequest('get', $url, $params, $opts);
73 $obj = \Stripe\Util\Util::convertToStripeObject($response->json, $opts);
74 $obj->setLastResponse($response);
75
76 return $obj;
77 }
78 }
79