Skip to content

Commit 6691ed9

Browse files
committed
debianization phase II
1 parent ae9d7a8 commit 6691ed9

130 files changed

Lines changed: 30872 additions & 2 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: 16 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -19,4 +19,19 @@ package-lock.json
1919
# PHPUnit cache
2020
.phpunit.result.cache
2121
composer.lock
22-
/.env
22+
/.env
23+
24+
/debian/php-spojenet-csas-accountsapi-dev/
25+
/debian/php-spojenet-csas-accountsapi-dev.debhelper.log
26+
/debian/php-spojenet-csas-accountsapi-dev.substvars
27+
28+
/debian/php-spojenet-csas-accountsapi-doc/
29+
/debian/php-spojenet-csas-accountsapi-doc.debhelper.log
30+
/debian/php-spojenet-csas-accountsapi-doc.substvars
31+
32+
/debian/php-spojenet-csas-accountsapi/
33+
/debian/php-spojenet-csas-accountsapi.debhelper.log
34+
/debian/php-spojenet-csas-accountsapi.substvars
35+
/debian/debhelper-build-stamp
36+
/debian/.debhelper/
37+
/debian/files

.openapi-generator/templates/gitignore.mustache

Lines changed: 18 additions & 1 deletion
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/
@@ -19,4 +21,19 @@ package-lock.json
1921
# PHPUnit cache
2022
.phpunit.result.cache
2123
composer.lock
22-
/.env
24+
/.env
25+
26+
/debian/php-spojenet-csas-accountsapi-dev/
27+
/debian/php-spojenet-csas-accountsapi-dev.debhelper.log
28+
/debian/php-spojenet-csas-accountsapi-dev.substvars
29+
30+
/debian/php-spojenet-csas-accountsapi-doc/
31+
/debian/php-spojenet-csas-accountsapi-doc.debhelper.log
32+
/debian/php-spojenet-csas-accountsapi-doc.substvars
33+
34+
/debian/php-spojenet-csas-accountsapi/
35+
/debian/php-spojenet-csas-accountsapi.debhelper.log
36+
/debian/php-spojenet-csas-accountsapi.substvars
37+
/debian/debhelper-build-stamp
38+
/debian/.debhelper/
39+
/debian/files

README.md

Lines changed: 183 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,183 @@
1+
# Premium - Accounts API
2+
3+
API for managing production accounts.
4+
5+
For more information, please visit [https://www.csas.cz/content/dam/cz/csas/www_csas_cz/dokumenty/obecne/how-to-connect-to-api-of-cs.pdf](https://www.csas.cz/content/dam/cz/csas/www_csas_cz/dokumenty/obecne/how-to-connect-to-api-of-cs.pdf).
6+
7+
## Installation & Usage
8+
9+
### Requirements
10+
11+
PHP 7.4 and later.
12+
Should also work with PHP 8.0.
13+
14+
### Composer
15+
16+
To install the bindings via [Composer](https://getcomposer.org/), add the following to `composer.json`:
17+
18+
```json
19+
{
20+
"repositories": [
21+
{
22+
"type": "vcs",
23+
"url": "https://github.com/Spoje-NET/php-csas-webapi.git"
24+
}
25+
],
26+
"require": {
27+
"Spoje-NET/php-csas-webapi": "*@dev"
28+
}
29+
}
30+
```
31+
32+
Then run `composer install`
33+
34+
### Manual Installation
35+
36+
Download the files and include `autoload.php`:
37+
38+
```php
39+
<?php
40+
require_once('/path/to/Premium - Accounts API/vendor/autoload.php');
41+
```
42+
43+
## Getting Started
44+
45+
Please follow the [installation procedure](#installation--usage) and then run the following:
46+
47+
```php
48+
<?php
49+
require_once(__DIR__ . '/vendor/autoload.php');
50+
51+
52+
53+
// Configure API key authorization: ApiKeyAuth
54+
$config = SpojeNET\Csas\Configuration::getDefaultConfiguration()->setApiKey('WEB-API-key', 'YOUR_API_KEY');
55+
// Uncomment below to setup prefix (e.g. Bearer) for API key, if needed
56+
// $config = SpojeNET\Csas\Configuration::getDefaultConfiguration()->setApiKeyPrefix('WEB-API-key', 'Bearer');
57+
58+
// Configure Bearer (JWT) authorization: bearerAuth
59+
$config = SpojeNET\Csas\Configuration::getDefaultConfiguration()->setAccessToken('YOUR_ACCESS_TOKEN');
60+
61+
62+
$apiInstance = new SpojeNET\Csas\Api\DefaultApi(
63+
// If you want use custom http client, pass your client which implements `GuzzleHttp\ClientInterface`.
64+
// This is optional, `GuzzleHttp\Client` will be used as default.
65+
new GuzzleHttp\Client(),
66+
$config
67+
);
68+
$id = 'id_example'; // string | The ID of the account
69+
70+
try {
71+
$result = $apiInstance->getAccountBalance($id);
72+
print_r($result);
73+
} catch (Exception $e) {
74+
echo 'Exception when calling DefaultApi->getAccountBalance: ', $e->getMessage(), PHP_EOL;
75+
}
76+
77+
```
78+
79+
## API Endpoints
80+
81+
All URIs are relative to *https://www.csas.cz/webapi/api/v3/accounts*
82+
83+
Class | Method | HTTP request | Description
84+
------------ | ------------- | ------------- | -------------
85+
*DefaultApi* | [**getAccountBalance**](docs/Api/DefaultApi.md#getaccountbalance) | **GET** /my/accounts/{id}/balance | Get account balance
86+
*DefaultApi* | [**getAccountStatements**](docs/Api/DefaultApi.md#getaccountstatements) | **GET** /my/accounts/{id}/statements | Get account statements
87+
*DefaultApi* | [**getAccounts**](docs/Api/DefaultApi.md#getaccounts) | **GET** /my/accounts | Get account details
88+
*DefaultApi* | [**getTransactions**](docs/Api/DefaultApi.md#gettransactions) | **GET** /my/accounts/{id}/transactions | Overview of transactions
89+
90+
## Models
91+
92+
- [Account](docs/Model/Account.md)
93+
- [AccountBalance](docs/Model/AccountBalance.md)
94+
- [AccountCurrencyExchange](docs/Model/AccountCurrencyExchange.md)
95+
- [AccountIdentification](docs/Model/AccountIdentification.md)
96+
- [AccountRelatedAgents](docs/Model/AccountRelatedAgents.md)
97+
- [AccountRelationship](docs/Model/AccountRelationship.md)
98+
- [AccountServicer](docs/Model/AccountServicer.md)
99+
- [AccountSuitableScope](docs/Model/AccountSuitableScope.md)
100+
- [GetAccountBalance200Response](docs/Model/GetAccountBalance200Response.md)
101+
- [GetAccountBalance200ResponseBalancesInner](docs/Model/GetAccountBalance200ResponseBalancesInner.md)
102+
- [GetAccountBalance200ResponseBalancesInnerAmount](docs/Model/GetAccountBalance200ResponseBalancesInnerAmount.md)
103+
- [GetAccountBalance200ResponseBalancesInnerDate](docs/Model/GetAccountBalance200ResponseBalancesInnerDate.md)
104+
- [GetAccountBalance200ResponseBalancesInnerType](docs/Model/GetAccountBalance200ResponseBalancesInnerType.md)
105+
- [GetAccountBalance200ResponseBalancesInnerTypeCodeOrProprietary](docs/Model/GetAccountBalance200ResponseBalancesInnerTypeCodeOrProprietary.md)
106+
- [GetAccountStatements200Response](docs/Model/GetAccountStatements200Response.md)
107+
- [GetAccountStatements200ResponseStatementsInner](docs/Model/GetAccountStatements200ResponseStatementsInner.md)
108+
- [GetAccountStatements200ResponseStatementsInnerPeriod](docs/Model/GetAccountStatements200ResponseStatementsInnerPeriod.md)
109+
- [GetAccounts200Response](docs/Model/GetAccounts200Response.md)
110+
- [GetAccounts403Response](docs/Model/GetAccounts403Response.md)
111+
- [GetAccounts403ResponseErrorsInner](docs/Model/GetAccounts403ResponseErrorsInner.md)
112+
- [GetTransactions200Response](docs/Model/GetTransactions200Response.md)
113+
- [GetTransactions200ResponseTransactionsInner](docs/Model/GetTransactions200ResponseTransactionsInner.md)
114+
- [GetTransactions200ResponseTransactionsInnerAmount](docs/Model/GetTransactions200ResponseTransactionsInnerAmount.md)
115+
- [GetTransactions200ResponseTransactionsInnerBankTransactionCode](docs/Model/GetTransactions200ResponseTransactionsInnerBankTransactionCode.md)
116+
- [GetTransactions200ResponseTransactionsInnerBankTransactionCodeProprietary](docs/Model/GetTransactions200ResponseTransactionsInnerBankTransactionCodeProprietary.md)
117+
- [GetTransactions200ResponseTransactionsInnerBookingDate](docs/Model/GetTransactions200ResponseTransactionsInnerBookingDate.md)
118+
- [GetTransactions200ResponseTransactionsInnerEntryDetails](docs/Model/GetTransactions200ResponseTransactionsInnerEntryDetails.md)
119+
- [GetTransactions200ResponseTransactionsInnerEntryDetailsTransactionDetails](docs/Model/GetTransactions200ResponseTransactionsInnerEntryDetailsTransactionDetails.md)
120+
- [GetTransactions200ResponseTransactionsInnerEntryDetailsTransactionDetailsAmountDetails](docs/Model/GetTransactions200ResponseTransactionsInnerEntryDetailsTransactionDetailsAmountDetails.md)
121+
- [GetTransactions200ResponseTransactionsInnerEntryDetailsTransactionDetailsAmountDetailsCounterValueAmount](docs/Model/GetTransactions200ResponseTransactionsInnerEntryDetailsTransactionDetailsAmountDetailsCounterValueAmount.md)
122+
- [GetTransactions200ResponseTransactionsInnerEntryDetailsTransactionDetailsAmountDetailsCounterValueAmountAmount](docs/Model/GetTransactions200ResponseTransactionsInnerEntryDetailsTransactionDetailsAmountDetailsCounterValueAmountAmount.md)
123+
- [GetTransactions200ResponseTransactionsInnerEntryDetailsTransactionDetailsAmountDetailsCounterValueAmountCurrencyExchange](docs/Model/GetTransactions200ResponseTransactionsInnerEntryDetailsTransactionDetailsAmountDetailsCounterValueAmountCurrencyExchange.md)
124+
- [GetTransactions200ResponseTransactionsInnerEntryDetailsTransactionDetailsAmountDetailsInstructedAmount](docs/Model/GetTransactions200ResponseTransactionsInnerEntryDetailsTransactionDetailsAmountDetailsInstructedAmount.md)
125+
- [GetTransactions200ResponseTransactionsInnerEntryDetailsTransactionDetailsAmountDetailsInstructedAmountAmount](docs/Model/GetTransactions200ResponseTransactionsInnerEntryDetailsTransactionDetailsAmountDetailsInstructedAmountAmount.md)
126+
- [GetTransactions200ResponseTransactionsInnerEntryDetailsTransactionDetailsReferences](docs/Model/GetTransactions200ResponseTransactionsInnerEntryDetailsTransactionDetailsReferences.md)
127+
- [GetTransactions200ResponseTransactionsInnerEntryDetailsTransactionDetailsRelatedAgents](docs/Model/GetTransactions200ResponseTransactionsInnerEntryDetailsTransactionDetailsRelatedAgents.md)
128+
- [GetTransactions200ResponseTransactionsInnerEntryDetailsTransactionDetailsRelatedAgentsCreditorAgent](docs/Model/GetTransactions200ResponseTransactionsInnerEntryDetailsTransactionDetailsRelatedAgentsCreditorAgent.md)
129+
- [GetTransactions200ResponseTransactionsInnerEntryDetailsTransactionDetailsRelatedAgentsCreditorAgentFinancialInstitutionIdentification](docs/Model/GetTransactions200ResponseTransactionsInnerEntryDetailsTransactionDetailsRelatedAgentsCreditorAgentFinancialInstitutionIdentification.md)
130+
- [GetTransactions200ResponseTransactionsInnerEntryDetailsTransactionDetailsRelatedAgentsDebtorAgent](docs/Model/GetTransactions200ResponseTransactionsInnerEntryDetailsTransactionDetailsRelatedAgentsDebtorAgent.md)
131+
- [GetTransactions200ResponseTransactionsInnerEntryDetailsTransactionDetailsRelatedAgentsDebtorAgentFinancialInstitutionIdentification](docs/Model/GetTransactions200ResponseTransactionsInnerEntryDetailsTransactionDetailsRelatedAgentsDebtorAgentFinancialInstitutionIdentification.md)
132+
- [GetTransactions200ResponseTransactionsInnerEntryDetailsTransactionDetailsRelatedParties](docs/Model/GetTransactions200ResponseTransactionsInnerEntryDetailsTransactionDetailsRelatedParties.md)
133+
- [GetTransactions200ResponseTransactionsInnerEntryDetailsTransactionDetailsRelatedPartiesCreditor](docs/Model/GetTransactions200ResponseTransactionsInnerEntryDetailsTransactionDetailsRelatedPartiesCreditor.md)
134+
- [GetTransactions200ResponseTransactionsInnerEntryDetailsTransactionDetailsRelatedPartiesCreditorAccount](docs/Model/GetTransactions200ResponseTransactionsInnerEntryDetailsTransactionDetailsRelatedPartiesCreditorAccount.md)
135+
- [GetTransactions200ResponseTransactionsInnerEntryDetailsTransactionDetailsRelatedPartiesCreditorAccountIdentification](docs/Model/GetTransactions200ResponseTransactionsInnerEntryDetailsTransactionDetailsRelatedPartiesCreditorAccountIdentification.md)
136+
- [GetTransactions200ResponseTransactionsInnerEntryDetailsTransactionDetailsRelatedPartiesCreditorAccountIdentificationOther](docs/Model/GetTransactions200ResponseTransactionsInnerEntryDetailsTransactionDetailsRelatedPartiesCreditorAccountIdentificationOther.md)
137+
- [GetTransactions200ResponseTransactionsInnerEntryDetailsTransactionDetailsRelatedPartiesDebtor](docs/Model/GetTransactions200ResponseTransactionsInnerEntryDetailsTransactionDetailsRelatedPartiesDebtor.md)
138+
- [GetTransactions200ResponseTransactionsInnerEntryDetailsTransactionDetailsRelatedPartiesDebtorAccount](docs/Model/GetTransactions200ResponseTransactionsInnerEntryDetailsTransactionDetailsRelatedPartiesDebtorAccount.md)
139+
- [GetTransactions200ResponseTransactionsInnerEntryDetailsTransactionDetailsRelatedPartiesDebtorAccountIdentification](docs/Model/GetTransactions200ResponseTransactionsInnerEntryDetailsTransactionDetailsRelatedPartiesDebtorAccountIdentification.md)
140+
- [GetTransactions200ResponseTransactionsInnerEntryDetailsTransactionDetailsRelatedPartiesDebtorAccountIdentificationOther](docs/Model/GetTransactions200ResponseTransactionsInnerEntryDetailsTransactionDetailsRelatedPartiesDebtorAccountIdentificationOther.md)
141+
- [GetTransactions200ResponseTransactionsInnerEntryDetailsTransactionDetailsRemittanceInformation](docs/Model/GetTransactions200ResponseTransactionsInnerEntryDetailsTransactionDetailsRemittanceInformation.md)
142+
- [GetTransactions200ResponseTransactionsInnerEntryDetailsTransactionDetailsRemittanceInformationStructured](docs/Model/GetTransactions200ResponseTransactionsInnerEntryDetailsTransactionDetailsRemittanceInformationStructured.md)
143+
- [GetTransactions200ResponseTransactionsInnerEntryDetailsTransactionDetailsRemittanceInformationStructuredCreditorReferenceInformation](docs/Model/GetTransactions200ResponseTransactionsInnerEntryDetailsTransactionDetailsRemittanceInformationStructuredCreditorReferenceInformation.md)
144+
- [GetTransactions200ResponseTransactionsInnerValueDate](docs/Model/GetTransactions200ResponseTransactionsInnerValueDate.md)
145+
- [StatementList](docs/Model/StatementList.md)
146+
- [StatementListAccountStatementsInner](docs/Model/StatementListAccountStatementsInner.md)
147+
- [TransactionList](docs/Model/TransactionList.md)
148+
- [TransactionListTransactionsInner](docs/Model/TransactionListTransactionsInner.md)
149+
150+
## Authorization
151+
152+
Authentication schemes defined for the API:
153+
### bearerAuth
154+
155+
- **Type**: Bearer authentication (JWT)
156+
157+
### ApiKeyAuth
158+
159+
- **Type**: API key
160+
- **API key parameter name**: WEB-API-key
161+
- **Location**: HTTP header
162+
163+
164+
## Tests
165+
166+
To run the tests, use:
167+
168+
```bash
169+
composer install
170+
vendor/bin/phpunit
171+
```
172+
173+
## Author
174+
175+
vitezslav.dvorak@spojenet.cz
176+
177+
## About this package
178+
179+
This PHP package is automatically generated by the [OpenAPI Generator](https://openapi-generator.tech) project:
180+
181+
- API version: `1.0.0`
182+
- Generator version: `7.11.0`
183+
- Build package: `org.openapitools.codegen.languages.PhpClientCodegen`

debian/README.Debian

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,8 @@
1+
php-spojenet-csas-accountsapi for Debian
2+
3+
Please edit this to provide information specific to
4+
this php-spojenet-csas-accountsapi Debian package.
5+
6+
(Automatically generated by debmake Version 4.4.0)
7+
8+
-- Vítězslav Dvořák <info@vitexsoftware.cz> Wed, 26 Feb 2025 10:04:09 +0100

debian/changelog

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,6 @@
1+
php-spojenet-csas-accountsapi (0.1.0) UNRELEASED; urgency=low
2+
3+
* Initial release. Closes: #nnnn
4+
<nnnn is the bug number of your ITP>
5+
6+
-- Vítězslav Dvořák <info@vitexsoftware.cz> Wed, 26 Feb 2025 10:04:09 +0100

debian/composer.json

Lines changed: 45 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,45 @@
1+
{
2+
"name": "deb/csas-accountsapi",
3+
"description": "An Core of PHP Framework for Ease of writing Applications (debianized)",
4+
"version": "0.1.0",
5+
"authors": [
6+
{
7+
"name": "Vítězslav Dvořák",
8+
"email": "info@vitexsoftware.cz",
9+
"homepage": "https://vitexsoftware.com/"
10+
}
11+
],
12+
"config": {
13+
"vendor-dir": "/var/lib/composer/php-spojenet-csas-accountsapi"
14+
},
15+
"autoload": {
16+
"psr-4": {
17+
"VitexSoftware\\Raiffeisenbank\\": "./",
18+
"VitexSoftware\\Raiffeisenbank\\Model\\": "./Model/",
19+
"VitexSoftware\\Raiffeisenbank\\PremiumAPI\\": "./PremiumAPI/"
20+
}
21+
},
22+
"minimum-stability": "dev",
23+
"require": {
24+
"php": ">=7.1",
25+
"guzzlehttp/guzzle": "^7.3",
26+
"deb/ease-core": "*"
27+
},
28+
"repositories": [
29+
{
30+
"type": "path",
31+
"url": "/usr/share/php/EaseCore"
32+
},
33+
{
34+
"type": "path",
35+
"url": "/usr/share/php/CSas"
36+
},
37+
{
38+
"type": "path",
39+
"url": "/usr/share/php/GuzzleHttp"
40+
}
41+
],
42+
"type": "library",
43+
"homepage": "https://github.com/Spoje-NET/php-csas-accountsapi",
44+
"license": "MIT"
45+
}
Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,4 @@
1+
lib/*.php /usr/share/php/CSas/
2+
lib/Accounts/*.php /usr/share/php/CSas/Accounts/
3+
lib/Model/*.php /usr/share/php/CSas/Model/
4+
debian/composer.json /usr/share/php/CSas/
Lines changed: 43 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,43 @@
1+
#!/bin/sh
2+
3+
#DEBHELPER#
4+
5+
# postinst script for php-spojenet-csas-accountsapi
6+
#
7+
# see: dh_installdeb(1)
8+
9+
set -e
10+
11+
# summary of how this script can be called:
12+
# * <postinst> `configure' <most-recently-configured-version>
13+
# * <old-postinst> `abort-upgrade' <new version>
14+
# * <conflictor's-postinst> `abort-remove' `in-favour' <package>
15+
# <new-version>
16+
# * <postinst> `abort-remove'
17+
# * <deconfigured's-postinst> `abort-deconfigure' `in-favour'
18+
# <failed-install-package> <version> `removing'
19+
# <conflicting-package> <version>
20+
# for details, see http://www.debian.org/doc/debian-policy/ or
21+
# the debian-policy package
22+
23+
24+
case "$1" in
25+
configure)
26+
composer-global-update deb/csas-accountsapi
27+
;;
28+
29+
abort-upgrade|abort-remove|abort-deconfigure)
30+
;;
31+
32+
*)
33+
echo "postinst called with unknown argument \`$1'" >&2
34+
exit 1
35+
;;
36+
esac
37+
38+
# dh_installdeb will replace this with shell code automatically
39+
# generated by other debhelper scripts.
40+
41+
exit 0
42+
43+
#DEBHELPER#

0 commit comments

Comments
 (0)