Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
22 changes: 12 additions & 10 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
@@ -1,9 +1,11 @@
name: ci

on:
- pull_request
- push
- workflow_dispatch
pull_request:
push:
branches:
- master
workflow_dispatch:

env:
MAVEN_FLAGS: "-B --no-transfer-progress"
Expand Down Expand Up @@ -34,8 +36,8 @@ jobs:
- name: Start stack
run: |
cd docker
docker-compose -p it -f ${{ matrix.docker-compose-file }} up --no-start
docker start it_db_1
docker compose -p it -f ${{ matrix.docker-compose-file }} up --no-start
docker start it-db-1
- name: Wait for MySQL
if: ${{ matrix.docker-compose-file == 'docker-compose.ci.mysql.yml' }}
run: |
Expand Down Expand Up @@ -80,7 +82,7 @@ jobs:
# Sometimes it gets stuck (if Kill Bill starts when the DB isn't ready?)
timeout-minutes: 4
run: |
docker start it_killbill_1
docker start it-killbill-1
count=0
until $(curl --connect-timeout 10 --max-time 30 --output /dev/null --silent --fail http://${KB_ADDRESS}:${KB_PORT}/1.0/healthcheck); do
if [[ "$count" == "180" ]]; then
Expand Down Expand Up @@ -114,10 +116,10 @@ jobs:
echo "[DEBUG] docker ps -a"
docker ps -a
echo "[DEBUG] killbill env"
docker exec it_killbill_1 env || true
docker exec it-killbill-1 env || true
echo "[DEBUG] db env"
docker exec it_db_1 env || true
docker exec it-db-1 env || true
echo "[DEBUG] killbill logs"
docker logs -t --details it_killbill_1 || true
docker logs -t --details it-killbill-1 || true
echo "[DEBUG] db logs"
docker logs -t --details it_db_1 || true
docker logs -t --details it-db-1 || true
2 changes: 1 addition & 1 deletion .swagger-codegen/VERSION
Original file line number Diff line number Diff line change
@@ -1 +1 @@
3.0.22
3.0.79
5 changes: 4 additions & 1 deletion .swagger-config.json
Original file line number Diff line number Diff line change
Expand Up @@ -7,5 +7,8 @@
"gitRepoId" : "killbill-client",
"variableNamingConvention": "camelCase",
"srcBasePath": "lib",
"httpUserAgent": "Killbill-Client/0.24.0/php"
"httpUserAgent": "Killbill-Client/0.25.0/php",
"additionalProperties": {
"backslash": "\\"
}
}
6 changes: 4 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,7 @@ PHP client library for [Kill Bill](http://killbill.io).
| 0.3.x | 0.20.z |
| 0.4.x | 0.22.z |
| 0.5.x | 0.24.z |
| 0.6.x | 0.25.z |

## Requirements

Expand Down Expand Up @@ -140,7 +141,7 @@ Feel free to ask questions on the [killbilling-users](https://groups.google.com/

This PHP package is automatically generated by the [Swagger Codegen](https://github.com/swagger-api/swagger-codegen) project:

- API version: 0.24.0
- API version: 0.25.0
- Build package: io.swagger.codegen.v3.generators.php.PhpClientCodegen

Download [swagger-codegen](https://github.com/swagger-api/swagger-codegen):
Expand Down Expand Up @@ -363,6 +364,7 @@ Class | Method | HTTP request | Description
*PluginInfoApi* | [**getPluginsInfo**](docs/Api/PluginInfoApi.md#getpluginsinfo) | **GET** /1.0/kb/pluginsInfo | Retrieve the list of registered plugins
*SecurityApi* | [**addRoleDefinition**](docs/Api/SecurityApi.md#addroledefinition) | **POST** /1.0/kb/security/roles | Add a new role definition)
*SecurityApi* | [**addUserRoles**](docs/Api/SecurityApi.md#adduserroles) | **POST** /1.0/kb/security/users | Add a new user with roles (to make api requests)
*SecurityApi* | [**getAvailableRoles**](docs/Api/SecurityApi.md#getavailableroles) | **GET** /1.0/kb/security/roles | List all active role definitions
*SecurityApi* | [**getCurrentUserPermissions**](docs/Api/SecurityApi.md#getcurrentuserpermissions) | **GET** /1.0/kb/security/permissions | List user permissions
*SecurityApi* | [**getCurrentUserSubject**](docs/Api/SecurityApi.md#getcurrentusersubject) | **GET** /1.0/kb/security/subject | Get user information
*SecurityApi* | [**getRoleDefinition**](docs/Api/SecurityApi.md#getroledefinition) | **GET** /1.0/kb/security/roles/{role} | Get role definition
Expand All @@ -374,7 +376,7 @@ Class | Method | HTTP request | Description
*SubscriptionApi* | [**addSubscriptionBlockingState**](docs/Api/SubscriptionApi.md#addsubscriptionblockingstate) | **POST** /1.0/kb/subscriptions/{subscriptionId}/block | Block a subscription
*SubscriptionApi* | [**cancelSubscriptionPlan**](docs/Api/SubscriptionApi.md#cancelsubscriptionplan) | **DELETE** /1.0/kb/subscriptions/{subscriptionId} | Cancel an entitlement plan
*SubscriptionApi* | [**changeSubscriptionPlan**](docs/Api/SubscriptionApi.md#changesubscriptionplan) | **PUT** /1.0/kb/subscriptions/{subscriptionId} | Change entitlement plan
*SubscriptionApi* | [**createSubscription**](docs/Api/SubscriptionApi.md#createsubscription) | **POST** /1.0/kb/subscriptions | Create an subscription
*SubscriptionApi* | [**createSubscription**](docs/Api/SubscriptionApi.md#createsubscription) | **POST** /1.0/kb/subscriptions | Create a subscription
*SubscriptionApi* | [**createSubscriptionCustomFields**](docs/Api/SubscriptionApi.md#createsubscriptioncustomfields) | **POST** /1.0/kb/subscriptions/{subscriptionId}/customFields | Add custom fields to subscription
*SubscriptionApi* | [**createSubscriptionTags**](docs/Api/SubscriptionApi.md#createsubscriptiontags) | **POST** /1.0/kb/subscriptions/{subscriptionId}/tags |
*SubscriptionApi* | [**createSubscriptionWithAddOns**](docs/Api/SubscriptionApi.md#createsubscriptionwithaddons) | **POST** /1.0/kb/subscriptions/createSubscriptionWithAddOns | Create an entitlement with addOn products
Expand Down
2 changes: 1 addition & 1 deletion docker/docker-compose.ci.mysql.yml
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ version: '3.8'
services:
killbill:
network_mode: host
image: killbill/killbill:0.24.0
image: xsalefter/killbill:0.25.4
environment:
- KILLBILL_CATALOG_URI=SpyCarAdvanced.xml
- KILLBILL_DAO_URL=jdbc:mysql://127.0.0.1:3306/killbill
Expand Down
6 changes: 4 additions & 2 deletions docs/Api/CreditApi.md
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ Method | HTTP request | Description
[**getCredit**](CreditApi.md#getcredit) | **GET** /1.0/kb/credits/{creditId} | Retrieve a credit by id

# **createCredits**
> \Killbill\Client\Swagger\Model\InvoiceItem[] createCredits($body, $xKillbillCreatedBy, $xKillbillReason, $xKillbillComment, $autoCommit, $pluginProperty)
> \Killbill\Client\Swagger\Model\InvoiceItem[] createCredits($body, $xKillbillCreatedBy, $xKillbillReason, $xKillbillComment, $requestedDate, $autoCommit, $pluginProperty)

Create a credit

Expand Down Expand Up @@ -38,11 +38,12 @@ $body = array(new \Killbill\Client\Swagger\Model\InvoiceItem()); // \Killbill\Cl
$xKillbillCreatedBy = "xKillbillCreatedBy_example"; // string |
$xKillbillReason = "xKillbillReason_example"; // string |
$xKillbillComment = "xKillbillComment_example"; // string |
$requestedDate = new \DateTime("2013-10-20"); // \DateTime |
$autoCommit = false; // bool |
$pluginProperty = array("pluginProperty_example"); // string[] |

try {
$result = $apiInstance->createCredits($body, $xKillbillCreatedBy, $xKillbillReason, $xKillbillComment, $autoCommit, $pluginProperty);
$result = $apiInstance->createCredits($body, $xKillbillCreatedBy, $xKillbillReason, $xKillbillComment, $requestedDate, $autoCommit, $pluginProperty);
print_r($result);
} catch (Exception $e) {
echo 'Exception when calling CreditApi->createCredits: ', $e->getMessage(), PHP_EOL;
Expand All @@ -58,6 +59,7 @@ Name | Type | Description | Notes
**xKillbillCreatedBy** | **string**| |
**xKillbillReason** | **string**| | [optional]
**xKillbillComment** | **string**| | [optional]
**requestedDate** | **\DateTime**| | [optional]
**autoCommit** | **bool**| | [optional] [default to false]
**pluginProperty** | [**string[]**](../Model/string.md)| | [optional]

Expand Down
2 changes: 0 additions & 2 deletions docs/Api/PaymentGatewayApi.md
Original file line number Diff line number Diff line change
Expand Up @@ -155,8 +155,6 @@ Name | Type | Description | Notes

Process a gateway notification

The response is built by the appropriate plugin

### Example
```php
<?php
Expand Down
50 changes: 50 additions & 0 deletions docs/Api/SecurityApi.md
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,7 @@ Method | HTTP request | Description
------------- | ------------- | -------------
[**addRoleDefinition**](SecurityApi.md#addroledefinition) | **POST** /1.0/kb/security/roles | Add a new role definition)
[**addUserRoles**](SecurityApi.md#adduserroles) | **POST** /1.0/kb/security/users | Add a new user with roles (to make api requests)
[**getAvailableRoles**](SecurityApi.md#getavailableroles) | **GET** /1.0/kb/security/roles | List all active role definitions
[**getCurrentUserPermissions**](SecurityApi.md#getcurrentuserpermissions) | **GET** /1.0/kb/security/permissions | List user permissions
[**getCurrentUserSubject**](SecurityApi.md#getcurrentusersubject) | **GET** /1.0/kb/security/subject | Get user information
[**getRoleDefinition**](SecurityApi.md#getroledefinition) | **GET** /1.0/kb/security/roles/{role} | Get role definition
Expand Down Expand Up @@ -133,6 +134,55 @@ Name | Type | Description | Notes

[[Back to top]](#) [[Back to API list]](../../README.md#documentation-for-api-endpoints) [[Back to Model list]](../../README.md#documentation-for-models) [[Back to README]](../../README.md)

# **getAvailableRoles**
> \Killbill\Client\Swagger\Model\RoleDefinition[] getAvailableRoles()

List all active role definitions

### Example
```php
<?php
require_once(__DIR__ . '/vendor/autoload.php');
// Configure HTTP basic authorization: basicAuth
$config = Killbill\Client\Swagger\Configuration::getDefaultConfiguration()
->setUsername('YOUR_USERNAME')
->setPassword('YOUR_PASSWORD');


$apiInstance = new Killbill\Client\Swagger\Api\SecurityApi(
// If you want use custom http client, pass your client which implements `GuzzleHttp\ClientInterface`.
// This is optional, `GuzzleHttp\Client` will be used as default.
new GuzzleHttp\Client(),
$config
);

try {
$result = $apiInstance->getAvailableRoles();
print_r($result);
} catch (Exception $e) {
echo 'Exception when calling SecurityApi->getAvailableRoles: ', $e->getMessage(), PHP_EOL;
}
?>
```

### Parameters
This endpoint does not need any parameter.

### Return type

[**\Killbill\Client\Swagger\Model\RoleDefinition[]**](../Model/RoleDefinition.md)

### Authorization

[basicAuth](../../README.md#basicAuth)

### HTTP request headers

- **Content-Type**: Not defined
- **Accept**: application/json

[[Back to top]](#) [[Back to API list]](../../README.md#documentation-for-api-endpoints) [[Back to Model list]](../../README.md#documentation-for-models) [[Back to README]](../../README.md)

# **getCurrentUserPermissions**
> string[] getCurrentUserPermissions()

Expand Down
4 changes: 2 additions & 2 deletions docs/Api/SubscriptionApi.md
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ Method | HTTP request | Description
[**addSubscriptionBlockingState**](SubscriptionApi.md#addsubscriptionblockingstate) | **POST** /1.0/kb/subscriptions/{subscriptionId}/block | Block a subscription
[**cancelSubscriptionPlan**](SubscriptionApi.md#cancelsubscriptionplan) | **DELETE** /1.0/kb/subscriptions/{subscriptionId} | Cancel an entitlement plan
[**changeSubscriptionPlan**](SubscriptionApi.md#changesubscriptionplan) | **PUT** /1.0/kb/subscriptions/{subscriptionId} | Change entitlement plan
[**createSubscription**](SubscriptionApi.md#createsubscription) | **POST** /1.0/kb/subscriptions | Create an subscription
[**createSubscription**](SubscriptionApi.md#createsubscription) | **POST** /1.0/kb/subscriptions | Create a subscription
[**createSubscriptionCustomFields**](SubscriptionApi.md#createsubscriptioncustomfields) | **POST** /1.0/kb/subscriptions/{subscriptionId}/customFields | Add custom fields to subscription
[**createSubscriptionTags**](SubscriptionApi.md#createsubscriptiontags) | **POST** /1.0/kb/subscriptions/{subscriptionId}/tags |
[**createSubscriptionWithAddOns**](SubscriptionApi.md#createsubscriptionwithaddons) | **POST** /1.0/kb/subscriptions/createSubscriptionWithAddOns | Create an entitlement with addOn products
Expand Down Expand Up @@ -254,7 +254,7 @@ void (empty response body)
# **createSubscription**
> \Killbill\Client\Swagger\Model\Subscription createSubscription($body, $xKillbillCreatedBy, $xKillbillReason, $xKillbillComment, $entitlementDate, $billingDate, $renameKeyIfExistsAndUnused, $migrated, $skipResponse, $callCompletion, $callTimeoutSec, $pluginProperty)

Create an subscription
Create a subscription

### Example
```php
Expand Down
2 changes: 1 addition & 1 deletion docs/Model/Entity.md
Original file line number Diff line number Diff line change
Expand Up @@ -3,9 +3,9 @@
## Properties
Name | Type | Description | Notes
------------ | ------------- | ------------- | -------------
**id** | **string** | | [optional]
**createdDate** | [**\DateTime**](\DateTime.md) | | [optional]
**updatedDate** | [**\DateTime**](\DateTime.md) | | [optional]
**id** | **string** | | [optional]

[[Back to Model list]](../../README.md#documentation-for-models) [[Back to API list]](../../README.md#documentation-for-api-endpoints) [[Back to README]](../../README.md)

4 changes: 2 additions & 2 deletions lib/Api/AccountApi.php
Original file line number Diff line number Diff line change
Expand Up @@ -14,10 +14,10 @@
*
* Kill Bill is an open-source billing and payments platform
*
* OpenAPI spec version: 0.24.0
* OpenAPI spec version: 0.25.6-SNAPSHOT
*
* Generated by: https://github.com/swagger-api/swagger-codegen.git
* Swagger Codegen version: 3.0.22
* Swagger Codegen version: 3.0.79
*/
/**
* NOTE: This class is auto generated by the swagger code generator program.
Expand Down
4 changes: 2 additions & 2 deletions lib/Api/AdminApi.php
Original file line number Diff line number Diff line change
Expand Up @@ -14,10 +14,10 @@
*
* Kill Bill is an open-source billing and payments platform
*
* OpenAPI spec version: 0.24.0
* OpenAPI spec version: 0.25.6-SNAPSHOT
*
* Generated by: https://github.com/swagger-api/swagger-codegen.git
* Swagger Codegen version: 3.0.22
* Swagger Codegen version: 3.0.79
*/
/**
* NOTE: This class is auto generated by the swagger code generator program.
Expand Down
4 changes: 2 additions & 2 deletions lib/Api/BundleApi.php
Original file line number Diff line number Diff line change
Expand Up @@ -14,10 +14,10 @@
*
* Kill Bill is an open-source billing and payments platform
*
* OpenAPI spec version: 0.24.0
* OpenAPI spec version: 0.25.6-SNAPSHOT
*
* Generated by: https://github.com/swagger-api/swagger-codegen.git
* Swagger Codegen version: 3.0.22
* Swagger Codegen version: 3.0.79
*/
/**
* NOTE: This class is auto generated by the swagger code generator program.
Expand Down
4 changes: 2 additions & 2 deletions lib/Api/CatalogApi.php
Original file line number Diff line number Diff line change
Expand Up @@ -14,10 +14,10 @@
*
* Kill Bill is an open-source billing and payments platform
*
* OpenAPI spec version: 0.24.0
* OpenAPI spec version: 0.25.6-SNAPSHOT
*
* Generated by: https://github.com/swagger-api/swagger-codegen.git
* Swagger Codegen version: 3.0.22
* Swagger Codegen version: 3.0.79
*/
/**
* NOTE: This class is auto generated by the swagger code generator program.
Expand Down
Loading
Loading