# Vend\PartnerBillingApi



All URIs are relative to https://example.retail.lightspeed.app/api/2026-07, except if the operation defines another base path.

| Method | HTTP request | Description |
| ------------- | ------------- | ------------- |
| [**partnerSubscription()**](PartnerBillingApi.md#partnerSubscription) | **GET** /partner/billing/subscriptions/{subscription_id} | Get a partner subscription |
| [**partnerSubscriptions()**](PartnerBillingApi.md#partnerSubscriptions) | **GET** /partner/billing/subscriptions | List partner subscriptions |
| [**partnerToken()**](PartnerBillingApi.md#partnerToken) | **POST** /partner/billing/token | Create a partner subscription token |
| [**partnerTokenGet()**](PartnerBillingApi.md#partnerTokenGet) | **GET** /partner/billing/token/{partner_subscription_token} | Get subscription by token |
| [**partnerUpdateSubscriptionToken()**](PartnerBillingApi.md#partnerUpdateSubscriptionToken) | **POST** /partner/billing/update-subscription/token | Create a partner update subscription token |


## `partnerSubscription()`

```php
partnerSubscription($subscription_id): \Vend\Model\PartnerSubscription200Response
```

Get a partner subscription

Returns a specific partner subscription of the retailer  🔒 Requires: `billing:partner_subscription:read` scope

### Example

```php
<?php
require_once(__DIR__ . '/vendor/autoload.php');


// Configure Bearer (JWT) authorization: bearerAuth
$config = Vend\Configuration::getDefaultConfiguration()->setAccessToken('YOUR_ACCESS_TOKEN');


$apiInstance = new Vend\Api\PartnerBillingApi(
    // 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
);
$subscription_id = 'subscription_id_example'; // string

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

### Parameters

| Name | Type | Description  | Notes |
| ------------- | ------------- | ------------- | ------------- |
| **subscription_id** | **string**|  | |

### Return type

[**\Vend\Model\PartnerSubscription200Response**](../Model/PartnerSubscription200Response.md)

### Authorization

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

### HTTP request headers

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

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

## `partnerSubscriptions()`

```php
partnerSubscriptions(): \Vend\Model\PartnerSubscriptions200Response
```

List partner subscriptions

Returns list of partner's subscriptions of the retailer  🔒 Requires: `billing:partner_subscription:read` scope

### Example

```php
<?php
require_once(__DIR__ . '/vendor/autoload.php');


// Configure Bearer (JWT) authorization: bearerAuth
$config = Vend\Configuration::getDefaultConfiguration()->setAccessToken('YOUR_ACCESS_TOKEN');


$apiInstance = new Vend\Api\PartnerBillingApi(
    // 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->partnerSubscriptions();
    print_r($result);
} catch (Exception $e) {
    echo 'Exception when calling PartnerBillingApi->partnerSubscriptions: ', $e->getMessage(), PHP_EOL;
}
```

### Parameters

This endpoint does not need any parameter.

### Return type

[**\Vend\Model\PartnerSubscriptions200Response**](../Model/PartnerSubscriptions200Response.md)

### Authorization

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

### HTTP request headers

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

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

## `partnerToken()`

```php
partnerToken($partner_subscription_token_request): \Vend\Model\PartnerToken200Response
```

Create a partner subscription token

Creates a partner subscription token (called by partner using retailer's access token)  🔒 Requires: `billing:partner_subscription:write` scope

### Example

```php
<?php
require_once(__DIR__ . '/vendor/autoload.php');


// Configure Bearer (JWT) authorization: bearerAuth
$config = Vend\Configuration::getDefaultConfiguration()->setAccessToken('YOUR_ACCESS_TOKEN');


$apiInstance = new Vend\Api\PartnerBillingApi(
    // 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
);
$partner_subscription_token_request = new \Vend\Model\PartnerSubscriptionTokenRequest(); // \Vend\Model\PartnerSubscriptionTokenRequest

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

### Parameters

| Name | Type | Description  | Notes |
| ------------- | ------------- | ------------- | ------------- |
| **partner_subscription_token_request** | [**\Vend\Model\PartnerSubscriptionTokenRequest**](../Model/PartnerSubscriptionTokenRequest.md)|  | |

### Return type

[**\Vend\Model\PartnerToken200Response**](../Model/PartnerToken200Response.md)

### Authorization

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

### HTTP request headers

- **Content-Type**: `application/json`
- **Accept**: `application/json`

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

## `partnerTokenGet()`

```php
partnerTokenGet($partner_subscription_token): \Vend\Model\PartnerTokenGet200Response
```

Get subscription by token

Returns a subscription token data  🔒 Requires: `billing:partner_subscription:read` scope

### Example

```php
<?php
require_once(__DIR__ . '/vendor/autoload.php');


// Configure Bearer (JWT) authorization: bearerAuth
$config = Vend\Configuration::getDefaultConfiguration()->setAccessToken('YOUR_ACCESS_TOKEN');


$apiInstance = new Vend\Api\PartnerBillingApi(
    // 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
);
$partner_subscription_token = 'partner_subscription_token_example'; // string | The partner subscription token

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

### Parameters

| Name | Type | Description  | Notes |
| ------------- | ------------- | ------------- | ------------- |
| **partner_subscription_token** | **string**| The partner subscription token | |

### Return type

[**\Vend\Model\PartnerTokenGet200Response**](../Model/PartnerTokenGet200Response.md)

### Authorization

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

### HTTP request headers

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

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

## `partnerUpdateSubscriptionToken()`

```php
partnerUpdateSubscriptionToken($partner_update_subscription_token_request): \Vend\Model\PartnerToken200Response
```

Create a partner update subscription token

Creates a partner subscription token with the intention of updating a subscription (called by partner using retailer's access token)  🔒 Requires: `billing:partner_subscription:write` scope

### Example

```php
<?php
require_once(__DIR__ . '/vendor/autoload.php');


// Configure Bearer (JWT) authorization: bearerAuth
$config = Vend\Configuration::getDefaultConfiguration()->setAccessToken('YOUR_ACCESS_TOKEN');


$apiInstance = new Vend\Api\PartnerBillingApi(
    // 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
);
$partner_update_subscription_token_request = new \Vend\Model\PartnerUpdateSubscriptionTokenRequest(); // \Vend\Model\PartnerUpdateSubscriptionTokenRequest

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

### Parameters

| Name | Type | Description  | Notes |
| ------------- | ------------- | ------------- | ------------- |
| **partner_update_subscription_token_request** | [**\Vend\Model\PartnerUpdateSubscriptionTokenRequest**](../Model/PartnerUpdateSubscriptionTokenRequest.md)|  | |

### Return type

[**\Vend\Model\PartnerToken200Response**](../Model/PartnerToken200Response.md)

### Authorization

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

### HTTP request headers

- **Content-Type**: `application/json`
- **Accept**: `application/json`

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