Skip to content

Commit fd2fcdd

Browse files
committed
config prefix CSAS_USED
update for php8.4
1 parent baa3fde commit fd2fcdd

131 files changed

Lines changed: 12682 additions & 13084 deletions

File tree

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

.gitignore

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,8 @@
11
# ref: https://github.com/github/gitignore/blob/master/Composer.gitignore
22
# ref: https://mustache.github.io/mustache.5.html
33

4+
# Generated from .openapi-generator/templates/gitignore.mustache
5+
46
composer.phar
57
/vendor/
68
/node_modules/

.openapi-generator/VERSION

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
7.11.0
1+
7.10.0

.openapi-generator/templates/ApiClient.mustache

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -45,31 +45,31 @@ class ApiClient extends \GuzzleHttp\Client
4545
* $config['sandbox'] = true to use //api/csas/public/sandbox/v3/* endpoints
4646
*
4747
* @param array $config
48-
* @throws \Exception ACCESS_TOKEN is not set
49-
* @throws \Exception API_KEY is not set
48+
* @throws \Exception CSAS_ACCESS_TOKEN is not set
49+
* @throws \Exception CSAS_API_KEY is not set
5050
*/
5151
public function __construct(array $config = [])
5252
{
5353
if (array_key_exists('apikey', $config) === false) {
54-
$this->apiKey = \Ease\Shared::cfg('API_KEY');
54+
$this->apiKey = \Ease\Shared::cfg('CSAS_API_KEY');
5555
} else {
5656
$this->apiKey = $config['apikey'];
5757
}
5858

5959
if (array_key_exists('token', $config) === false) {
60-
$this->token = \Ease\Shared::cfg('API_TOKEN');
60+
$this->token = \Ease\Shared::cfg('CSAS_API_TOKEN');
6161
} else {
6262
$this->token = $config['token'];
6363
}
6464

6565
if (array_key_exists('debug', $config) === false) {
66-
$config['debug'] = \Ease\Shared::cfg('API_DEBUG', false);
66+
$config['debug'] = \Ease\Shared::cfg('CSAS_API_DEBUG', false);
6767
}
6868

6969
if (array_key_exists('sandbox', $config)) {
70-
$this->sandBoxMode = boolval($config['sandbox']);
70+
$this->sandBoxMode = strtolower((string)$config['sandbox']) == 'true';
7171
} else {
72-
$this->token = boolval(\Ease\Shared::cfg('SANDBOX_MODE'));
72+
$this->token = strtolower((string)\Ease\Shared::cfg('CSAS_SANDBOX_MODE', 'false')) == 'true';
7373
}
7474

7575
parent::__construct($config);

.openapi-generator/templates/api.mustache

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -92,9 +92,9 @@ use {{invokerPackage}}\ObjectSerializer;
9292
* @param int $hostIndex (Optional) host index to select the list of hosts if defined in the OpenAPI spec
9393
*/
9494
public function __construct(
95-
ClientInterface $client = null,
96-
Configuration $config = null,
97-
HeaderSelector $selector = null,
95+
?ClientInterface $client = null,
96+
?Configuration $config = null,
97+
?HeaderSelector $selector = null,
9898
$hostIndex = 0
9999
) {
100100
$this->client = $client ?: new ApiClient();

.php-cs-fixer.dist.php

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -3,11 +3,11 @@
33
declare(strict_types=1);
44

55
/**
6-
* This file is part of the MultiFlexi package
6+
* This file is part of the CSasWebApi package
77
*
8-
* https://multiflexi.eu/
8+
* https://github.com/Spoje-NET/php-csas-webapi
99
*
10-
* (c) Vítězslav Dvořák <http://vitexsoftware.com>
10+
* (c) SpojeNetIT <http://spoje.net/>
1111
*
1212
* For the full copyright and license information, please view the LICENSE
1313
* file that was distributed with this source code.

Examples/accounts.php

Lines changed: 187 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -21,10 +21,10 @@
2121

2222
$apiInstance = new \SpojeNET\CSas\Accounts\DefaultApi(new SpojeNET\CSas\ApiClient(
2323
[
24-
'apikey' => Shr::cfg('API_KEY'),
25-
'token' => Shr::cfg('ACCESS_TOKEN'),
26-
'debug' => Shr::cfg('API_DEBUG', false),
27-
'sandbox' => Shr::cfg('SANDBOX_MODE'),
24+
'apikey' => Shr::cfg('CSAS_API_KEY'),
25+
'token' => Shr::cfg('CSAS_ACCESS_TOKEN'),
26+
'debug' => Shr::cfg('CSAS_API_DEBUG', false),
27+
'sandbox' => Shr::cfg('CSAS_SANDBOX_MODE'),
2828
],
2929
));
3030

@@ -34,3 +34,186 @@
3434
} catch (Exception $e) {
3535
echo 'Exception when calling DefaultApi->getAccounts: ', $e->getMessage(), \PHP_EOL;
3636
}
37+
38+
/*
39+
"/usr/bin/php" "/home/vitex/Projects/SpojeNetIT/csas-accountsapi/Examples/accounts.php"
40+
SpojeNET\CSas\Model\GetAccounts200Response Object
41+
(
42+
[openAPINullablesSetToNull:protected] => Array
43+
(
44+
)
45+
46+
[container:protected] => Array
47+
(
48+
[pageNumber] => 0
49+
[pageCount] => 1
50+
[pageSize] => 2
51+
[accounts] => Array
52+
(
53+
[0] => SpojeNET\CSas\Model\Account Object
54+
(
55+
[openAPINullablesSetToNull:protected] => Array
56+
(
57+
)
58+
59+
[container:protected] => Array
60+
(
61+
[id] => AA195E7DB499B4D9F48D46C208625FF53F2245F7
62+
[identification] => SpojeNET\CSas\Model\AccountIdentification Object
63+
(
64+
[openAPINullablesSetToNull:protected] => Array
65+
(
66+
)
67+
68+
[container:protected] => Array
69+
(
70+
[iban] => CZ1208000000000259459101
71+
[other] => 0259459101/0800
72+
)
73+
74+
)
75+
76+
[currency] => CZK
77+
[servicer] => SpojeNET\CSas\Model\AccountServicer Object
78+
(
79+
[openAPINullablesSetToNull:protected] => Array
80+
(
81+
)
82+
83+
[container:protected] => Array
84+
(
85+
[bankCode] => 0800
86+
[countryCode] => CZ
87+
[bic] => GIBACZPX
88+
)
89+
90+
)
91+
92+
[nameI18N] => Jiří Spokojený
93+
[productI18N] => Osobní účet ČS II
94+
[ownersNames] => Array
95+
(
96+
[0] => Jiří Spokojený
97+
)
98+
99+
[relationship] => SpojeNET\CSas\Model\AccountRelationship Object
100+
(
101+
[openAPINullablesSetToNull:protected] => Array
102+
(
103+
)
104+
105+
[container:protected] => Array
106+
(
107+
[isOwner] => 1
108+
)
109+
110+
)
111+
112+
[suitableScope] => SpojeNET\CSas\Model\AccountSuitableScope Object
113+
(
114+
[openAPINullablesSetToNull:protected] => Array
115+
(
116+
)
117+
118+
[container:protected] => Array
119+
(
120+
[aISP] =>
121+
[pISP] =>
122+
)
123+
124+
)
125+
126+
[status] =>
127+
[relatedAgents] =>
128+
[currencyExchange] =>
129+
)
130+
131+
)
132+
133+
[1] => SpojeNET\CSas\Model\Account Object
134+
(
135+
[openAPINullablesSetToNull:protected] => Array
136+
(
137+
)
138+
139+
[container:protected] => Array
140+
(
141+
[id] => DEBCD8673D9A3F3EF3EFE4B799053FD49D2FF59F
142+
[identification] => SpojeNET\CSas\Model\AccountIdentification Object
143+
(
144+
[openAPINullablesSetToNull:protected] => Array
145+
(
146+
)
147+
148+
[container:protected] => Array
149+
(
150+
[iban] => CZ4108000000000782553098
151+
[other] => 0782553098/0800
152+
)
153+
154+
)
155+
156+
[currency] => CZK
157+
[servicer] => SpojeNET\CSas\Model\AccountServicer Object
158+
(
159+
[openAPINullablesSetToNull:protected] => Array
160+
(
161+
)
162+
163+
[container:protected] => Array
164+
(
165+
[bankCode] => 0800
166+
[countryCode] => CZ
167+
[bic] => GIBACZPX
168+
)
169+
170+
)
171+
172+
[nameI18N] => Jiří SPokojený - CM
173+
[productI18N] => Cizoměnový účet
174+
[ownersNames] => Array
175+
(
176+
[0] => Jiří Spokojený
177+
)
178+
179+
[relationship] => SpojeNET\CSas\Model\AccountRelationship Object
180+
(
181+
[openAPINullablesSetToNull:protected] => Array
182+
(
183+
)
184+
185+
[container:protected] => Array
186+
(
187+
[isOwner] =>
188+
)
189+
190+
)
191+
192+
[suitableScope] => SpojeNET\CSas\Model\AccountSuitableScope Object
193+
(
194+
[openAPINullablesSetToNull:protected] => Array
195+
(
196+
)
197+
198+
[container:protected] => Array
199+
(
200+
[aISP] =>
201+
[pISP] =>
202+
)
203+
204+
)
205+
206+
[status] =>
207+
[relatedAgents] =>
208+
[currencyExchange] =>
209+
)
210+
211+
)
212+
213+
)
214+
215+
)
216+
217+
)
218+
Done.
219+
*/

README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -179,5 +179,5 @@ vitezslav.dvorak@spojenet.cz
179179
This PHP package is automatically generated by the [OpenAPI Generator](https://openapi-generator.tech) project:
180180

181181
- API version: `1.0.0`
182-
- Generator version: `7.11.0`
182+
- Generator version: `7.10.0`
183183
- Build package: `org.openapitools.codegen.languages.PhpClientCodegen`

debian/changelog

Lines changed: 8 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,14 @@
1-
php-spojenet-csas-accountsapi (0.5.0) UNRELEASED; urgency=medium
1+
php-spojenet-csas-accountsapi (0.6.0) UNRELEASED; urgency=medium
2+
3+
* Config prefix CSAS_ used
4+
5+
-- vitex <info@vitexsoftware.cz> Sat, 08 Mar 2025 20:52:35 +0100
6+
7+
php-spojenet-csas-accountsapi (0.5.0) noble; urgency=medium
28

39
* Debianized
410

5-
-- vitex <info@vitexsoftware.cz> Wed, 26 Feb 2025 16:33:24 +0100
11+
-- vitex <info@vitexsoftware.cz> Sat, 08 Mar 2025 20:52:13 +0100
612

713
php-spojenet-csas-accountsapi (0.1.0) noble; urgency=low
814

0 commit comments

Comments
 (0)